Index: .hgtags
===================================================================
--- .hgtags	(revision 2659)
+++ .hgtags	(revision 2659)
@@ -0,0 +1,6 @@
+207efbaea2695c603f139c524d974ab6d52be5c5 lemon-0.7
+2f51fccbc2618bf03501326c669dadd8d5f1947b lemon-0.3
+5be9c1ca025221f567042b4ca49e6887c17e863c lemon-0.5
+71dc900ee30f95efebcd329b209a7d51f1b5dd5b lemon-0.2
+dc726706ea65cc41ac996e9742b8aad6ff6871bc lemon-0.6
+e31b5799b884b755ab86512c81b467f7f6c9ef6e lemon-0.4
Index: AUTHORS
===================================================================
--- AUTHORS	(revision 925)
+++ AUTHORS	(revision 925)
@@ -0,0 +1,64 @@
+LEMON was started as an inter-university project from two
+universities: BME (Budapest University of Technology and Economics,
+Hungary) and ELTE (Eötvös Loránd University, Budapest, Hungary) and
+sponsored by ETIK (Inter-University Centre for Telecommunications and
+Informatics).
+
+Other supporters and sponsors of this project are:
+
+* Communication Networks Laboratory, Eötvös University,
+  Pázmány Péter sétány 1/A, Budapest, Hungary, H-1117
+
+* Department of Operations Research and Egervary Research Group on
+  Combinatorial Optimization (EGRES, http://www.cs.elte.hu/egres/),
+  Eötvös University, Pázmány Péter sétány 1/C, Budapest, Hungary, H-1117
+
+* Ericsson Research Hungary,
+  Irinyi J. u. 4-20, Budapest, Hungary H-1117.
+
+
+So here is (hopefully sooner of later becoming complete) list of
+contributors of the LEMON (in alphabetical order). The fields are:
+name (N), email (E), web-address (W), PGP key ID and fingerprint (P),
+description (D), snail-mail address (A), Subversion commit name (C),
+and the list of supporters or affiliations (S)
+
+
+===========================================================================
+
+N: Mihaly Barasz
+E: klao@cs.elte.hu
+C: klao
+D: ide majd leiras
+A: Budapest
+S: EGRES, ETIK, ELTE
+
+N: Johanna Becker
+E: beckerjc@cs.elte.hu
+C: johanna
+A: Budapest
+S: ETIK, EGRES, ELTE
+
+N: Attila Bernath
+E: athos@cs.elte.hu
+C: athos
+A: Cegled
+S: ETIK, ELTE
+
+N: Alpar Juttner
+E: alpar@cs.elte.hu
+C: alpar
+A: Budabest
+S: ETIK, ELTE, Ericsson
+
+N: Marton Makai
+E: marci@cs.elte.hu
+C: marci
+A: Hajduszoboszlo
+S: CNL, EGRES
+
+N: Jacint Szabo
+E: jacint@cs.elte.hu
+C: jacint
+A: Budapest
+S: EGRES, ELTE, ETIK
Index: COPYING
===================================================================
--- COPYING	(revision 922)
+++ COPYING	(revision 922)
@@ -0,0 +1,17 @@
+LEMON as a whole is copyrighted by Egerváry Jenõ Kombinatorikus
+Optimalizálási Kutatócsoport (Egervary Combinatorial Optimization
+Research Group, EGRES).
+
+You are free to use, modify and distribute LEMON under the terms
+described in the LICENSE file.
+
+This project is supported by
+
+* Egyetemközi Távközlési és Informatikai Központ (Inter-University
+  Centre for Telecommunications and Informatics, Hungary)
+
+* Traffic Analysis and Network Performance Laboratory,
+  Ericsson Research, Hungary
+
+* Department of Operations Research, Eötvös Loránd University,
+  Budapest
Index: INSTALL
===================================================================
--- INSTALL	(revision 2139)
+++ INSTALL	(revision 2139)
@@ -0,0 +1,117 @@
+Installation Instructions
+=========================
+
+   Since you are reading this I assume you already obtained one of the release
+tarballs and successfully extracted it. The latest version of LEMON is
+available at our webpage (http://lemon.cs.elte.hu/).
+
+   In order to install LEMON from the extracted source tarball you have to
+issue the following commands:
+
+  1. `cd lemon-x.y.z'
+
+     This changes to the directory which was created when you extracted the
+     sources. The x.y.z part is a version number.
+
+  2. `./configure'
+
+     This runs the configure shell script, which does some checks and
+     configuration (creates makefiles etc).
+
+  3. `make'
+
+     This command compiles the non-template part of LEMON into libemon.a file.
+     It also compiles the benchmark and demo programs when enabled.
+
+  4. `make check'
+
+     This step is optional, but recommended. It runs the test programs that we
+     developed for LEMON to check whether the library works properly on your
+     platform.
+
+  5. `make install'
+
+     This command installs LEMON under /usr/local (you will need root
+     privileges to be able to do that). If you want to install it to some
+     other location, then pass the --prefix=DIRECTORY flag to configure in
+     step 1. For example: `./configure --prefix=/home/username/lemon'
+
+
+Configure Flags
+===============
+
+   You can pass the following flags to configure in step 1
+(see ./configure --help for more):
+
+CXX=comp
+
+  Change the C++ compiler to 'comp'.
+
+CXXFLAGS='flags'
+
+  Pass the 'flags' to the compiler. For example
+  CXXFLAGS='-O3 -march=pentium-m'
+  turns  on generation of aggressively optimized
+  Pentium-M specific code.
+
+--enable-demo
+
+   Build the demo programs too.
+
+--disable-demo
+
+   Do not build the demo programs (default).
+
+--enable-benchmark
+
+   Build the benchmark programs too.
+
+--disable-benchmark
+
+   Do not build the benchmark programs (default).
+
+--with-glpk[=PREFIX]
+
+   Enable GLPK support (default). You should specify the prefix too if
+   you installed GLPK to some non-standard location (e.g. your home
+   directory). If it is not found, GLPK support will be disabled.
+
+--with-glpk-includedir=DIR
+
+   The directory where the GLPK header files are located. This is only
+   useful when the GLPK headers and libraries are not under the same
+   prefix (which is unlikely).
+
+--with-glpk-libdir=DIR
+
+   The directory where the GLPK libraries are located. This is only
+   useful when the GLPK headers and libraries are not under the same
+   prefix (which is unlikely).
+
+--without-glpk
+
+   Disable GLPK support.
+
+--with-cplex[=PREFIX]
+
+   Enable CPLEX support (default). You should specify the prefix too
+   if you installed CPLEX to some non-standard location
+   (e.g. /opt/ilog/cplex75). If it is not found, CPLEX support will be
+   disabled.
+
+--with-cplex-includedir=DIR
+
+   The directory where the CPLEX header files are located. This is
+   only useful when the CPLEX headers and libraries are not under the
+   same prefix (e.g.  /usr/local/cplex/cplex75/include).
+
+--with-cplex-libdir=DIR
+
+   The directory where the CPLEX libraries are located. This is only
+   useful when the CPLEX headers and libraries are not under the same
+   prefix (e.g.
+   /usr/local/cplex/cplex75/lib/i86_linux2_glibc2.2_gcc3.0/static_pic_mt).
+
+--without-cplex
+
+   Disable CPLEX support.
Index: LICENSE
===================================================================
--- LICENSE	(revision 2391)
+++ LICENSE	(revision 2391)
@@ -0,0 +1,33 @@
+LEMON code without an explicit copyright is covered by the following
+copyright/license:
+
+Copyright (C) 2003-2007 Egervary Jeno Kombinatorikus Optimalizalasi
+Kutatocsoport (Egervary Combinatorial Optimization Research Group,
+EGRES).
+
+Permission is hereby granted, free of charge, to any person or organization
+obtaining a copy of the software and accompanying documentation covered by
+this license (the "Software") to use, reproduce, display, distribute,
+execute, and transmit the Software, and to prepare derivative works of the
+Software, and to permit third-parties to whom the Software is furnished to
+do so, all subject to the following:
+
+The copyright notices in the Software and this entire statement, including
+the above license grant, this restriction and the following disclaimer,
+must be included in all copies of the Software, in whole or in part, and
+all derivative works of the Software, unless such copies or derivative
+works are solely in the form of machine-executable object code generated by
+a source language processor.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
+SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
+FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
+ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+DEALINGS IN THE SOFTWARE.
+
+===========================================================================
+This license is a verbatim copy of the Boost Software License, Version 1.0.
+
+
Index: Makefile.am
===================================================================
--- Makefile.am	(revision 2649)
+++ Makefile.am	(revision 2572)
@@ -1,18 +1,19 @@
 ACLOCAL_AMFLAGS = -I m4
 
-AM_CPPFLAGS = -I$(top_srcdir)
+AM_CPPFLAGS = -I$(top_srcdir) -I$(top_builddir)
 LDADD = $(top_builddir)/lemon/libemon.la
 
 EXTRA_DIST = \
+	LICENSE \
+	lemon.spec \
+	autopackage/default.apspec.in \
 	m4/lx_check_cplex.m4 \
-	m4/lx_check_glpk.m4
-##	LICENSE \
-##	lemon.spec \
-##	autopackage/default.apspec.in
+	m4/lx_check_glpk.m4 \
+	m4/lx_check_soplex.m4
 
 pkgconfigdir = $(libdir)/pkgconfig
 lemondir = $(pkgincludedir)
 bitsdir = $(lemondir)/bits
-conceptdir = $(lemondir)/concept
+conceptdir = $(lemondir)/concepts
 pkgconfig_DATA =
 lib_LTLIBRARIES =
@@ -22,4 +23,5 @@
 noinst_HEADERS =
 noinst_PROGRAMS =
+bin_PROGRAMS =
 check_PROGRAMS =
 TESTS =
@@ -31,4 +33,5 @@
 include demo/Makefile.am
 include benchmark/Makefile.am
+include tools/Makefile.am
 
 MRPROPERFILES = \
@@ -61,5 +64,4 @@
 rpm: dist
 	rpmbuild -ta $(PACKAGE)-$(VERSION).tar.gz
-	@rm -f $(PACKAGE)-$(VERSION).tar.gz
 
 dist-bz2: dist
Index: NEWS
===================================================================
--- NEWS	(revision 2607)
+++ NEWS	(revision 2607)
@@ -0,0 +1,323 @@
+2008-02-08 Version 0.7 released
+	New Features
+		+ new data structures
+			* classes
+				StaticGraph
+				ExtendFindEnum
+				BfsVisitor class
+					Bipartite partitions based on visitors
+			* helper class for checking existence of a nested class
+			* general mapping based variant type
+			* IntegerMap
+		+ new algoritmhs
+			* Lagrange relaxation based algorithm for the delay constrained least cost path problem
+			* a preflow based general network circulation algorithm
+			* 2-approximation of Steiner-tree problem
+			* two heuristics for minimum cut algorithms (http://www.avglab.com/andrew/pub/neci-tr-96-132.ps)
+			* Gomory-Hu tree algorithm
+			* Edmond's Blossom shrinking algorithm
+			* minimum mean cycle algorithm
+			* Goldberg-Tarjan algorithm (Preflow with Dynamic Trees)
+			* Dinitz-Sleator-Tarjan (Blocking flow with Dynamic Tree)
+			* min cost flow algorithms:
+				* successive shortest path algorithm
+				* capacity scaling algorithm
+				* simple cycle canceling algorithm
+				* minimum mean cycle canceling algorithm
+				* cost scaling algorithm
+				* network simplex algorithm
+			* min cost maximum flow algorithm
+		+ new functions and tools
+			* ArgParser, a command line argument parser
+			* DistLog, a tool for measuring one and two dimensional distributions
+			* undirected minimum cut benchmarking
+			* tools/lgf-gen.cc, a random graph generator
+			* BpUGraphReader and Writer
+			* DynEdgeLookUp implementation based on splay trees
+			* MACROS for debug map usage
+		+ new distributions (Gaussian, exponential, Gamma, two dimensional random, buffered bit generation)
+		+ push-relabel type algorithm related additions
+			* Elevator, a class for handling item labels in push-relabel type algorithms
+			* a push/relabel type max cardinality matching implementation
+			* some query function for push-relabel based matching
+		+ LP related additions
+			* Soplex support
+			* ColIt class
+			* new functions (simplify(), isFinite(), row and col getter function)
+			* _setColCoeff and _setRowCoeff parameters
+			* section reader and writer for LEMON IO
+			* equality-type constraint can now be added to a LP
+			* virtual functions of class LpCplex
+			* some query functions for GLPK
+		+ demos
+			* preflow based general network circulation demo
+			* Steiner 2-approximation demo
+			* demo for SAT problems
+			* sample input for sat-2 and sat demos
+		+ tests for
+			* graph copies
+			* random.h
+			* max weighted matchings
+		+ planarity related additions
+			* checking and embedding
+			* planar grid embedding
+			* planar graph coloring
+		+ bipartite matchings
+			* common interface
+			* Query functions: aMatching and bMatching
+			* ANodeMap<UEdge> matching map
+			* BNodeMap<bool> barrier map
+	Repository reorganization
+		* script for automatic checking of SVN commit's consistency
+		* automatic doc generation from the SVN trunk
+		* check for gcc version 3.3, 3.4, 4.0 and 4.1.2 as well
+		* reorganization of the modules and groups
+		* a tools directory added for useful executables codes
+		* doxygen
+			* renaming topology doxygen group to graph_prop doxygen group
+			* introducing planar doxygen group
+	Changes
+		*  redesigned
+			* undirected edgesets (like the smart graph or ugraph)
+			* interface of MaxMatching and UnionFindEnum
+			* interface of maximum flow algorithms
+			* Kruskal algorithm
+			* augmenting path based bipartite matching
+	Improvements
+		* graph copy
+			* preliminary support for static graphs
+			* added BpUGraphCopy
+		* Bfs/Dfs/Dijkstra
+			* conditional execution until the target is reached 
+			* modified start() function in Dfs and Dijkstra classes to give back reached edge/node
+			* return the temporary distance of the current node
+			* using operation traits in Dijkstra
+			* patch for retrieving reached/processed node
+		* prescaling can be turned off in GraphToEps
+		* better handling of inexact computations
+		* easier inverse
+		* faster geometric minimum spanning tree algorithm
+		* new implementation of undirected graphs
+		* Hao-Orlin algorithm became epsilon-safe
+		* LpSoplex
+			* added getter functions
+			* better m4 file
+			* better handling of unsolved lps
+		* allowing 'string' type quoting for item reading and writing
+		* clear() function for union-find structures
+		* hacking MIP is possible without integer variables
+		* space reservation for SmartGraph
+		* path
+			* PathNodeIt
+				PathWriter/Reader structures
+				Distinct MapSet readers and writers
+			* more simple interface for PathDumper
+	Updated
+		* tutorial for
+			* algorithms
+			* graph visualization
+		* documentation
+	Backward incompatibilities/changed namings
+		* min_cut.h => nagamochi_ibaraki.h
+		* clone => build
+		* RevIt => RevEdgeIt
+		* _FixId => LpId
+		* setObj => obj
+		* is_min => isMin
+		* is_max => isMax
+		* ball2() => disc()
+		* state_enum => State
+		* getNotifier => notifier
+		* using LEMON_ASSERT instead of LogicError()
+		* uedgeset is an alias for edgeset
+		* CPXMIP_OPTIMAL_TOL status is considered as OPTIMAL too
+		* removed "Type" suffix from typedefs
+		* lower case local variables
+	Removed
+		- SspMinCostFlow
+		- template Map template parameter from InvertableMaps
+		- union-find Item template parameter
+		- strict checking
+		- some automatic callback generation 
+		- '-Wshadow' seemed too strict therefore removed
+	Several bugfixes
+
+2006-10-31  Version 0.6 Released
+	GLEMON has moved to a separate repository
+		(https://hugo.cs.elte.hu/svn/glemon/trunk)
+	New Features
+		+ Mixed Integer Programming (MIP) support
+		+ interface to GLPK and CPLEX MIP solvers
+		+ Data structures
+			* Bipatrite graph concepts and implementations
+			* a Polinomial template class
+			* RefPtr: a reference counted pointer class
+			* SimpleBucketHeap  
+		+ random.h: Mersenne Twister random number generator
+		+ EdgeLookUp and AllEdgeLookUp
+		+ Tools to find edges between to nodes in time O(log d) 
+		+ new matching algorithms
+		+ Bipartite Graph Max Cardinality Matching (Hopcroft-Karp)
+		+ MaxWeightedBipartiteMatching
+		+ MinCostMaxBipartiteMatching
+		+ MaxCardinalitySearch
+		+ MinimalCut in UGraph
+		+ Tabu Search framework 
+		+ Minimum Cost Arborescence algorithm 
+		+ Edmonds-Karp MaxFlow
+		+ Hao-Orlin algorithm
+		+ eps.h: A simple tool to create .eps pictures.
+	Backward incompatibilities/changed namings:
+		* UndirXyz -> UXyz
+		* UNDIRGRAPH_TYPEDEFS -> UGRAPH_TYPEDEFS
+		* GridGraph -> GridUGraph
+		* LinearHeap -> BucketHeap
+		* ColorSet -> Palette
+		* xy -> dim2::Point
+		* DirPath -> Path
+		* concept -> concepts (namespace & directory)
+		* LpSolverBase
+			* ColName() -> colName
+			* Coeff() -> coeff()
+		* MinCostFlow -> SspMinCostFlow
+	Repository reorganization:
+		* compilation is conducted by a single makefile
+		* internal building blocks are now in a separate directory
+		(lemon/bits)
+	Major improvements of many algorithms and data structures
+	Several bugfixes
+	Compatibility issues:
+		* known to compile with
+			* GCC 3.3, 3.4, 4.0, 4.1 
+			* MinGW, MinGW32
+			* Intel C++ 9.x support
+
+2006-02-03  Version 0.5 Released
+	New features
+		+ Shortest paths algorithms
+			* bellman_ford.h
+			* floyd_warshall.h
+			* johnson.h
+		+ Euler tour iterator for directed and undirected graphs
+		+ Other algorithms:
+			* dag_shortest_path.h
+			* fredman_tarjan.h and prim.h for min cost trees
+		+ Bipartite graph concept and implementations
+		+ Graph maps:
+			* template assign operator
+			* specialized iterable bool map
+			* potential difference map
+			* NodeMatrixMap -- Matrix over the nodes
+		+ Maps:
+			* IterableIntMap
+		+ Tools:
+			* Timer can be stop()ed and (re)start()ed
+			* radix sort algorithm
+			* tolerance.h for working with imprecise numbers
+	New demos, benchmarks and tools
+		+ graph_orientation.cc: A thoroughly documented demo application
+		+ runningTimeTest(): a tool to measure running times more precisely
+		+ Demo for topology
+		+ counter.h: a tool to measure the number of steps of algorithms
+		+ Some useful scripts: check-compiler, check-integrity
+	Improvements
+		+ Bfs/Dfs/Dijkstra
+			* query functions for the next node/edge to be processed
+			* visitor interface for dfs
+		+ topology.h: small functions for discovering graph topology
+			* connected components, strongly connected components
+			* bipartiteness testing
+		+ GUI:
+			* NewMap window in MapSelector
+			* Algorithm window and some algorithms (eg. Kruskal) added
+		+ LemonReader:
+			* exception on non-existent files
+		+ LP interface:
+			* (Dual)Expr::simplify(double tolerance) added
+			* getDual()
+		+ GraphToEps:
+			* negateY() opt
+			* male/female node shapes :)
+			* correct %%BoundingBox handling
+	Backward incompatibilities/changed namings:
+		* Access functions of TimeStamp/Timer
+		* Undirected graph interface: findUEdge, ConUEdgeIt
+		* pred -> predEdge renaming in search algorithms
+		* SnapShot -> Snapshot in {List,Smart}Graph
+		* NewEdgeSetAdaptor -> ListEdgeSet
+		* LP: set{Obj,Row,Col}() -> {obj,row,col}()
+		* "label" instead of "id" inside the LGF files
+		* UndirGraph -> UGraph, UndirEdge* -> UEdge*
+		* BipartiteGraph -> BpGraph, Lower/UpperNode* -> A/BNode*
+	Bugfixes in
+		* DFS
+		* Preflow
+		* x86_64 connected bugfixes (lemon_reader.h)
+		* lp.h
+	Other changes
+		* Demos and benchmarks are not built by default now. They can be
+			* enabled with the --enable-demo and --enable-benchmark
+			* configure flags.
+		* GCC 4.0.3 and ICC 9.0 compatibility
+
+2005-08-27  Version 0.4 Released
+	New features
+		+ More and better graph I/O functionalities
+		+ High level uniform LP solver interface to CPLEX and GLKP
+		+ New map adaptors
+		+ New convenience maps
+			* IdMap, DescriptorMap
+			* InDegMap, OutDegMap
+			* XMap, YMap
+		+ Default graph maps are iterable
+		+ glemon: a graph editor
+		+ Some new demo codes added, the old ones got polished.
+	Improvements
+		+ graphToEps()
+			* Automatic node size and edge width scaling
+			* Simple color palette tool (ColorSet)
+		+ Bfs/Dfs/Dijkstra
+			* Step-by-step execution
+			* Run from multiple sources
+			* Used define stop condition
+			* Improved "named parameters"
+		+ Preflow
+			* Changed interface
+			* Function type interface
+		+ ListGraph/SmartGraph
+			* split() splits a node
+			* SnapShot
+	Changes
+		* Changed namings:
+			* Wrapper -> Adaptor
+			* kruskalEdgeMap() -> kruskal()
+			* kruskalEdgeMap_IteratorOut() -> kruskal()
+		* BoundingBox<>
+			* operator+=() -> add()
+			+ clear()
+		* Better documentation
+		* Several important bugfixes
+		* Now LEMON should compile without warnings with
+			* gcc 3.3, 3.4, 4.0
+			* Intel C++ Compiler v9.0 
+
+2005-03-19  Version 0.3.1 Released
+	This release fixes a compilation failure bug under cygwin. 
+
+2005-02-21  Version 0.3 released
+	New features
+		+ Standardized LEMON exceptions
+		+ Undirected Graph
+		+ Standard graph file format, input and output classes for it
+		+ GraphToEps: A simple graph drawer
+	Changes
+		* Redesigned Graph infrastructures
+		* head() -> target(), tail() -> source()
+		* Some standard namings have changes:
+			ValueType -> Value, 
+			KeyType -> Key,
+			ReferenceType -> Reference,
+			PointerType -> Pointer
+		* Better documentation
+
+2004-09-30  Version 0.2 released
Index: README
===================================================================
--- README	(revision 2563)
+++ README	(revision 2563)
@@ -0,0 +1,60 @@
+------------------------------------------------------------------
+LEMON - a Library of Efficient Models and Optimization in Networks
+------------------------------------------------------------------
+
+LEMON is the abbreviation of Library of Efficient Models and
+Optimization in Networks. It is an open source library written in
+C++. It provides a set of easy-to-use implementation of common data
+structures and algorithms in the area of optimization and helps
+implementing new ones. It is an especially suitable tool to solve the
+design and optimization problems of telecommunications networks. To
+achieve wide usability, a fundamental design requirement is the
+genericity of interface of data structures and algorithms. LEMON is an
+open source library end invites people all around the world in its
+development.
+
+--------
+Contents
+--------
+
+COPYING, LICENSE
+
+  Copying, distribution and modification conditions and terms.
+
+INSTALL
+
+  For general building and installation instructions, see the file.
+
+lemon/
+
+  Source code of LEMON itself.
+
+doc/
+
+  Documentation of LEMON. The starting page is doc/html/index.html.
+  The documentation installs into the directory
+
+    /usr/local/share/doc/lemon/html
+
+  or -- if you use different prefix -- into
+
+    ${prefix}/share/doc/lemon/html
+
+  (see also INSTALL).
+
+demo/
+
+  Some demonstration programs to make you easier to get familiar with
+  LEMON. Use --enable-demo configure option to also compile these codes
+  (see also INSTALL).
+
+test/
+
+  Contains programs to check the integrity and correctness of
+  LEMON. The command 'make check' performs these tests.
+
+benchmark/
+  
+  Contains programs measuring the performance of LEMON. Use
+  --enable-benchmark configure option to also compile these codes (see
+  also INSTALL).
Index: autopackage/default.apspec.in
===================================================================
--- autopackage/default.apspec.in	(revision 2270)
+++ autopackage/default.apspec.in	(revision 2270)
@@ -0,0 +1,46 @@
+# -*-shell-script-*-
+
+[Meta]
+RootName: @lemon.cs.elte.hu/lemon:$SOFTWAREVERSION
+DisplayName: Lemon Library
+ShortName: lemon
+Maintainer: The LEMON Developers - http://lemon.cs.elte.hu/
+Packager: Alpar Juttner <alpar@cs.elte.hu>
+Summary: LEMON library
+SoftwareVersion: @VERSION@
+AutopackageTarget: 1.2
+
+# Only uncomment InterfaceVersion if your package exposes interfaces to other software,
+# for instance if it includes DSOs or python/perl modules. See the developer guide for more info,
+# or ask on autopackage-dev if you don't understand interface versioning in autopackage.
+#
+InterfaceVersion: 1.0
+
+PackageVersion: 1
+
+[Description]
+LEMON stands for Library of Efficient Models and Optimization in Networks.
+It is a C++ template library aimed at combinatorial optimization tasks,
+primaliry those involved in working with graphs.
+
+[BuildPrepare]
+prepareBuild
+
+[BuildUnprepare]
+unprepareBuild
+
+[Imports]
+echo '*' | import
+
+[Prepare]
+# Dependency checking
+require @lemon.cs.elte.hu/GLPK:4.11
+
+[Install]
+# Put your installation script here
+#installExe bin/*
+copyFiles * $PREFIX
+
+[Uninstall]
+# Usually just the following line is enough to uninstall everything
+uninstallFromLog
Index: benchmark/Makefile.am
===================================================================
--- benchmark/Makefile.am	(revision 2652)
+++ benchmark/Makefile.am	(revision 2341)
@@ -1,27 +1,36 @@
 EXTRA_DIST += \
 	benchmark/Makefile
+	benchmark/edge_lookup_test
 
-noinst_HEADERS +=
-##	benchmark/bench_tools.h
+noinst_HEADERS += benchmark/bench_tools.h
 
 if WANT_BENCHMARK
 
-noinst_PROGRAMS +=
-##	benchmark/graph-bench \
-##	benchmark/hcube \
-##	benchmark/swap_bipartite_bench \
-##	benchmark/bfs-bench \
-##	benchmark/radix_sort-bench \
-##	benchmark/swap_bipartite_bench
+noinst_PROGRAMS += \
+	benchmark/graph-bench \
+	benchmark/hcube \
+	benchmark/swap_bipartite_bench \
+	benchmark/bfs-bench \
+	benchmark/radix_sort-bench \
+	benchmark/swap_bipartite_bench \
+	benchmark/random_bench \
+	benchmark/edge_lookup \
+	benchmark/min_cut
 
 endif WANT_BENCHMARK
 
-##benchmark_graph_bench_SOURCES = benchmark/graph-bench.cc
+benchmark_graph_bench_SOURCES = benchmark/graph-bench.cc
 
-##benchmark_hcube_SOURCES = benchmark/hcube.cc
+benchmark_hcube_SOURCES = benchmark/hcube.cc
 
-##benchmark_bfs_bench_SOURCES = benchmark/bfs-bench.cc
+benchmark_bfs_bench_SOURCES = benchmark/bfs-bench.cc
 
-##benchmark_radix_sort_bench_SOURCES = benchmark/radix_sort-bench.cc
+benchmark_radix_sort_bench_SOURCES = benchmark/radix_sort-bench.cc
 
-##benchmark_swap_bipartite_bench_SOURCES = benchmark/swap_bipartite_bench.cc
+benchmark_swap_bipartite_bench_SOURCES = benchmark/swap_bipartite_bench.cc
+
+benchmark_random_bench_SOURCES = benchmark/random_bench.cc
+
+benchmark_edge_lookup_SOURCES = benchmark/edge_lookup.cc
+
+benchmark_min_cut_SOURCES = benchmark/min_cut.cc
Index: benchmark/bench_tools.h
===================================================================
--- benchmark/bench_tools.h	(revision 2553)
+++ benchmark/bench_tools.h	(revision 2553)
@@ -0,0 +1,128 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BENCH_TEST_H
+#define LEMON_BENCH_TEST_H
+
+#include<vector>
+#include<iostream>
+
+#include<lemon/graph_utils.h>
+#include<lemon/time_measure.h>
+
+///A primitive primtest
+
+///\bug 2 is not a prime according to this function!
+///
+///\bug This function should go out of header file. I'm making it
+/// inline for now.
+inline bool isPrim(int n)
+{
+  if(n%2) {
+    for(int k=3;n/k>=k;k+=2)
+      if(!(n%k)) return false;
+    return true;
+  }
+  return false;
+}
+
+///Finds the smallest prime not less then \c n.
+
+///\bug This function should go out of header file. I'm making it
+/// inline for now.
+inline int nextPrim(int n)
+{
+  for(n+=!(n%2);!isPrim(n);n+=2) ;
+  return n;
+}
+
+
+/// Class to generate consecutive primes
+class Primes 
+{
+  std::vector<int> primes;
+  int n;
+  
+  bool isPrime(int m) 
+  {
+    for(int i=0;m<primes[i]*primes[i];i++) if(!(m%primes[i])) return false;
+    return true;
+  }
+public:
+  Primes() : n(1) {}
+  
+  int operator() ()
+    {
+      if(primes.size()==0) {
+	primes.push_back(2);
+	return 2;
+      }
+      else {
+	do n+=2; while(!isPrime(n));
+	primes.push_back(n);
+	return n;
+      }
+    }
+};
+
+inline void PrintTime(const char *ID, lemon::Timer &T) 
+{
+  lemon::TimeStamp S(T);
+  std::cout << ID << ' ' << S.userTime() << ' '
+	    << S.systemTime() << ' ' << S.realTime() << std::endl;
+}
+
+
+
+///
+template<class Graph>
+void addHyperCube(Graph &G,int dim,std::vector<typename Graph::Node> &nodes)
+{
+  GRAPH_TYPEDEFS(typename Graph);
+  
+  std::vector<int> bits(dim+1);
+  bits[0]=1;
+  for(int i=1;i<=dim;i++) bits[i]=2*bits[i-1];
+  
+  for(int i=0;i<bits[dim];i++) {
+    nodes.push_back(G.addNode());
+    for(int j=0;j<dim;j++) if(i&bits[j]) G.addEdge(nodes[i-bits[j]],nodes[i]);
+  }
+}
+
+///
+template<class Graph>
+void addBiDirHyperCube(Graph &G,int dim,std::vector<typename Graph::Node>&nodes)
+{
+  GRAPH_TYPEDEFS(typename Graph);
+  
+  std::vector<int> bits(dim+1);
+  bits[0]=1;
+  for(int i=1;i<=dim;i++) bits[i]=2*bits[i-1];
+  
+  for(int i=0;i<bits[dim];i++) {
+    nodes.push_back(G.addNode());
+    for(int j=0;j<dim;j++) if(i&bits[j]) {
+      G.addEdge(nodes[i-bits[j]],nodes[i]);
+      G.addEdge(nodes[i],nodes[i-bits[j]]);
+    }
+    
+  }
+}  
+
+#endif
Index: benchmark/benchmark
===================================================================
--- benchmark/benchmark	(revision 1435)
+++ benchmark/benchmark	(revision 1435)
@@ -0,0 +1,41 @@
+#!/bin/bash
+
+function runtest () # prefix, prog, args
+{
+    echo $1 1>&2
+    $2 $3 $4 $5 $6 $7 $8 $9 >/dev/null;
+    for ((i=1;i<=3;i++))
+      do
+      $2 $3 $4 $5 $6 $7 $8 $9;
+    done |
+    awk '{print "'$1'",$0}'
+}
+
+function runalltest() #postfix, CXX, CXXFLAGS
+{
+    echo $1 1>&2
+    make clean >/dev/null
+    make CXX="$2" CXXFLAGS="$3"  >/dev/null
+    {
+	runtest HCUBE19 hcube 19
+	runtest BFS13-5000 hcube 13 5000
+	runtest BFS10-50000 hcube 10 50000
+	runtest GRBENCH graph-bench
+    } | awk "{print \$0, \"$1\"}"
+}
+
+runalltest "gcc-3.3 -O2"                 g++ "-O2"
+runalltest "gcc-3.3 -O2-march=pentium-m" g++ "-O2 -march=pentium-m"
+runalltest "gcc-3.3 -O3"                 g++ "-O3"
+runalltest "gcc-3.3 -O3-march=pentium-m" g++ "-O3 -march=pentium-m"
+
+runalltest "gcc-3.4 -O2"                 g++-3.4 "-O2"
+runalltest "gcc-3.4 -O2-march=pentium-m" g++-3.4 "-O2 -march=pentium-m"
+runalltest "gcc-3.4 -O3"                 g++-3.4 "-O3"
+runalltest "gcc-3.4 -O3-march=pentium-m" g++-3.4 "-O3 -march=pentium-m"
+         
+runalltest "icc -O2"                 icc "-O2"
+runalltest "icc -O2-march=pentium-m" icc "-O2 -march=pentium-m"
+runalltest "icc -O3"                 icc "-O3"
+runalltest "icc -O3-march=pentium-m" icc "-O3 -march=pentium-m"
+
Index: benchmark/bfs-bench.cc
===================================================================
--- benchmark/bfs-bench.cc	(revision 2569)
+++ benchmark/bfs-bench.cc	(revision 2569)
@@ -0,0 +1,159 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<queue>
+#include<lemon/math.h>
+#include<lemon/smart_graph.h>
+#include"bench_tools.h"
+
+using namespace std;
+using namespace lemon;
+
+inline int numOfOnes(int n,int dim)
+{
+  int s=0;
+  for(int i=0;i<dim;i++) {
+    s+=n%2;
+    n>>=1;
+  }
+  return s;
+}
+
+inline int numOfZeros(int n,int dim)
+{
+  int s=dim;
+  for(int i=0;i<dim;i++) {
+    s-=n&1;
+    n>>=1;
+  }
+  return s;
+}
+
+template<class Graph>
+void bfsStlQueue(Graph &G,typename Graph::Node source)
+{
+  GRAPH_TYPEDEFS(typename Graph);
+
+  using namespace std;
+  
+  typename Graph::template NodeMap<bool> visited(G,false);
+    
+  queue<typename Graph::Node> Q;
+    
+  Q.push(source);
+  visited[source]=true;
+  do {
+    Node n(Q.front());
+    Node m;
+    Q.pop();
+    for(OutEdgeIt e(G,n);e!=INVALID;++e)
+      if(!visited[m=G.target(e)]) {
+	Q.push(m);
+	visited.set(m,true);
+      }
+  } while(!Q.empty());
+}
+
+template<class Graph>
+void bfsOwnQueue(Graph &G,typename Graph::Node source)
+{
+  GRAPH_TYPEDEFS(typename Graph);
+
+  using namespace std;
+  
+  typename Graph::template NodeMap<bool> visited(G,false);
+  
+  int N=G.nodeNum();
+  vector<typename Graph::Node> Q(N);
+  int Qh=0;
+  int Qt=0;
+  
+
+  Q[Qh++]=source;
+  visited.set(source,true);
+  do {
+    Node m;
+    Node n=Q[Qt++];
+    for(OutEdgeIt e(G,n);e!=INVALID;++e)
+      if(!visited[m=G.target(e)]) {
+	Q[Qh++]=m;
+	visited.set(m,true);
+      }
+  } while(Qt!=Qh);
+}
+
+template<class Graph>
+void iteratorBench(Graph &G)
+{
+  GRAPH_TYPEDEFS(typename Graph);
+
+  int i=0;
+  
+  for(NodeIt n(G);n!=INVALID;++n)
+    for(OutEdgeIt e(G,n);e!=INVALID;++e)
+      i++;
+}
+
+int main(int argc, char *argv[])
+{
+  typedef SmartGraph Graph;
+
+  GRAPH_TYPEDEFS(Graph);
+
+  Graph G;
+  
+  Timer T;
+  
+  if(argc!=3) {
+    cout << "Usage: " << argv[0] << " dim mul\n";
+    return 1;
+  }
+  
+  int dim=atoi(argv[1]);
+  int mul=atoi(argv[2]);
+  
+//   cout << "Creating Hipercube ("<< (1<<dim) << " nodes, "
+//        << dim*(1<<dim) << " edges):";
+
+  T.restart();
+  vector<Node> nodes;
+  addBiDirHyperCube(G,dim,nodes);
+
+  PrintTime("GENGRAPH",T);
+
+  T.restart();
+  {
+    for(int i=0;i<mul;i++)
+      bfsStlQueue(G,nodes[0]);
+  }
+  PrintTime("BFS-STL",T);
+  T.restart();
+  {
+    for(int i=0;i<mul;i++)
+      bfsOwnQueue(G,nodes[0]);
+  }
+  PrintTime("BFS-OWN",T);
+  T.restart();
+  {
+    for(int i=0;i<mul;i++)
+      iteratorBench(G);
+  }
+  PrintTime("ITERATE",T);
+
+
+}
Index: benchmark/edge_lookup.cc
===================================================================
--- benchmark/edge_lookup.cc	(revision 2553)
+++ benchmark/edge_lookup.cc	(revision 2553)
@@ -0,0 +1,556 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<lemon/smart_graph.h>
+#include<vector>
+#include<lemon/time_measure.h>
+#include<lemon/random.h>
+#include<lemon/graph_utils.h>
+#include<algorithm>
+
+using namespace lemon;
+
+  template<class G>
+  class EdgeLookUp2
+  {
+  public:
+    GRAPH_TYPEDEFS(typename G);
+    typedef G Graph;
+
+  private:
+    const Graph &_g;
+    typename Graph::template NodeMap<int> _start;
+    typename Graph::template NodeMap<int> _end;
+    std::vector<Edge> _edges;
+    
+    class EdgeLess {
+      const Graph &g;
+    public:
+      EdgeLess(const Graph &_g) : g(_g) {}
+      bool operator()(Edge a,Edge b) const 
+      {
+	return g.target(a)<g.target(b);
+      }
+    };
+    
+  public:
+    
+    ///Constructor
+    EdgeLookUp2(const Graph &g) :_g(g),_start(g),_end(g) {refresh();}
+    
+  public:
+    ///Refresh the data structure at a node.
+    void refresh(Node n) 
+    {
+      const int bi = _start[n] = _edges.size();
+      for(OutEdgeIt e(_g,n);e!=INVALID;++e) _edges.push_back(e);
+      const typename std::vector<Edge>::iterator ei=_edges.end();
+      _end[n]=_edges.size();
+      std::sort(_edges.begin()+bi,ei,EdgeLess(_g));
+    }
+    ///Refresh the full data structure.
+    void refresh() 
+    {
+      _edges.clear();
+      for(NodeIt n(_g);n!=INVALID;++n) refresh(n);
+    }
+    
+    ///Find an edge between two nodes.
+    
+    ///Find an edge between two nodes.
+    ///\param s The source node
+    ///\param t The target node
+    ///\return An edge from \c s to \c t if there exists,
+    ///\ref INVALID otherwise.
+
+    Edge operator()(Node s, Node t) 
+    {
+      int a=_start[s];
+      int b=_end[s];
+      while(a<b) 
+	{
+	  int n=(a+b)/2;
+	  Node tt = _g.target(_edges[n]);
+	  if(tt==t) return _edges[n];
+	  else if(tt<t) a=n+1;
+	  else b=n;
+	}
+      return INVALID;
+    }
+
+    ///Find the next edge
+      
+      ///\warning This function is unimplemented.
+    Edge operator()(Node s, Node t, Edge prev) 
+    {
+      return prev==INVALID?(*this)(s,t):INVALID;
+    }
+      
+  };
+
+  template<class G>
+  class EdgeLookUp3
+  {
+  public:
+    GRAPH_TYPEDEFS(typename G);
+    typedef G Graph;
+
+  private:
+    const Graph &_g;
+    typename Graph::template NodeMap<Edge*> _start;
+    typename Graph::template NodeMap<Edge*> _end;
+    std::vector<Edge> _edges;
+    
+    class EdgeLess {
+      const Graph &g;
+    public:
+      EdgeLess(const Graph &_g) : g(_g) {}
+      bool operator()(Edge a,Edge b) const 
+      {
+	return g.target(a)<g.target(b);
+      }
+    };
+    
+  public:
+    
+    ///Constructor
+    EdgeLookUp3(const Graph &g) :_g(g),_start(g),_end(g) {refresh();}
+    
+  public:
+    ///Refresh the data structure at a node.
+    void refresh(Node n) 
+    {
+      const int bi = _start[n] = _edges.size();
+      for(OutEdgeIt e(_g,n);e!=INVALID;++e) _edges.push_back(e);
+      const typename std::vector<Edge>::iterator ei=_edges.end();
+      _end[n]=_edges.size();
+      std::sort(_edges.begin()+bi,ei,EdgeLess(_g));
+    }
+    ///Refresh the full data structure.
+    void refresh() 
+    {
+      _edges.resize(countEdges(_g));
+      int l=0;
+      for(NodeIt n(_g);n!=INVALID;++n)
+	{
+	  int ls = l;
+	  _start[n]=&(_edges[l]);	
+	  for(OutEdgeIt e(_g,n);e!=INVALID;++e) _edges[l++]=e;
+	  _end[n]=&(_edges[l]);
+	  std::sort(_edges.begin()+ls,_edges.begin()+l,EdgeLess(_g));
+	}
+      
+    }
+    
+    ///Find an edge between two nodes.
+    
+    ///Find an edge between two nodes.
+    ///\param s The source node
+    ///\param t The target node
+    ///\return An edge from \c s to \c t if there exists,
+    ///\ref INVALID otherwise.
+
+    Edge operator()(Node s, Node t) 
+    {
+      Edge *a=_start[s];
+      Edge *b=_end[s];
+      while(a!=b) 
+	{
+ 	  Edge *m=a+((b-a)/2);
+	  Node tt = _g.target(*m);
+	  if(tt==t) return *m;
+	  else if(tt<t) a=m+1;
+	  else b=m;
+	}
+      return INVALID;
+    }
+
+    ///Find the next edge
+      
+      ///\warning This function is unimplemented.
+    Edge operator()(Node s, Node t, Edge prev) 
+    {
+      return prev==INVALID?(*this)(s,t):INVALID;
+    }
+      
+  };
+
+//   template<class G>
+//   class EdgeLookUp4
+//   {
+//   public:
+//     GRAPH_TYPEDEFS(typename G);
+//     typedef G Graph;
+    
+//   private:
+//     const Graph &_g;
+//     typename Graph::template NodeMap<Edge*> _start;
+//     typename Graph::template NodeMap<Edge*> _end;
+//     std::vector<Edge> _edges;
+    
+//     class EdgeLess {
+//       const Graph &g;
+//     public:
+//       EdgeLess(const Graph &_g) : g(_g) {}
+//       bool operator()(Edge a,Edge b) const 
+//       {
+// 	return g.target(a)<g.target(b);
+//       }
+//     };
+    
+//   public:
+    
+//     ///Constructor
+//     EdgeLookUp4(const Graph &g) :_g(g),_start(g),_end(g) {refresh();}
+    
+//   public:
+//     ///Refresh the data structure at a node.
+//     void refresh(Node n) 
+//     {
+//       const int bi = _start[n] = _edges.size();
+//       for(OutEdgeIt e(_g,n);e!=INVALID;++e) _edges.push_back(e);
+//       const typename std::vector<Edge>::iterator ei=_edges.end();
+//       _end[n]=_edges.size();
+//       std::sort(_edges.begin()+bi,ei,EdgeLess(_g));
+//     }
+//     ///Refresh the full data structure.
+//     void refresh() 
+//     {
+//       _edges.resize(countEdges(_g));
+//       int l=0;
+//       for(NodeIt n(_g);n!=INVALID;++n)
+// 	{
+// 	  int ls = l;
+// 	  _start[n]=&(_edges[l]);	
+// 	  for(OutEdgeIt e(_g,n);e!=INVALID;++e) _edges[l++]=e;
+// 	  _end[n]=&(_edges[l]);
+// 	  std::sort(_edges.begin()+ls,_edges.begin()+l,EdgeLess(_g));
+// 	}
+      
+//     }
+    
+//     ///Find an edge between two nodes.
+    
+//     ///Find an edge between two nodes.
+//     ///\param s The source node
+//     ///\param t The target node
+//     ///\return An edge from \c s to \c t if there exists,
+//     ///\ref INVALID otherwise.
+
+//     Edge operator()(Node s, Node t) 
+//     {
+//       Edge *a=_start[s];
+//       Edge *b=_end[s];
+//       while(a!=b) 
+// 	{
+// // #ifdef X86
+//  	  Edge *m=(Edge*)(((unsigned int)a+(unsigned int)b)/2 & 0xfffffffc);
+// // #elif X86_64
+// // 	  Edge *m=(Edge*)(((unsigned long)a+(undigned long)b)/2 & 0xfffffffc);
+// // #else
+// //  	  Edge *m=a+((b-a)/2);
+// // #endif
+// 	  Node tt = _g.target(*m);
+// 	  if(tt==t) return *m;
+// 	  else if(tt<t) a=m+1;
+// 	  else b=m;
+// 	}
+//       return INVALID;
+//     }
+
+//     ///Find the next edge
+      
+//       ///\warning This function is unimplemented.
+//     Edge operator()(Node s, Node t, Edge prev) 
+//     {
+//       return prev==INVALID?(*this)(s,t):INVALID;
+//     }
+      
+//   };
+
+//   template<class G>
+//   class EdgeLookUp5
+//   {
+//   public:
+//     GRAPH_TYPEDEFS(typename G);
+//     typedef G Graph;
+    
+//   private:
+//     const Graph &_g;
+//     typename Graph::template NodeMap<Edge*> _start;
+//     typename Graph::template NodeMap<Edge*> _end;
+//     std::vector<Edge> _edges;
+    
+//     class EdgeLess {
+//       const Graph &g;
+//     public:
+//       EdgeLess(const Graph &_g) : g(_g) {}
+//       bool operator()(Edge a,Edge b) const 
+//       {
+// 	return g.target(a)<g.target(b);
+//       }
+//     };
+    
+//   public:
+    
+//     ///Constructor
+//     EdgeLookUp5(const Graph &g) :_g(g),_start(g),_end(g) {refresh();}
+    
+//   public:
+//     ///Refresh the data structure at a node.
+//     void refresh(Node n) 
+//     {
+//       const int bi = _start[n] = _edges.size();
+//       for(OutEdgeIt e(_g,n);e!=INVALID;++e) _edges.push_back(e);
+//       const typename std::vector<Edge>::iterator ei=_edges.end();
+//       _end[n]=_edges.size();
+//       std::sort(_edges.begin()+bi,ei,EdgeLess(_g));
+//     }
+//     ///Refresh the full data structure.
+//     void refresh() 
+//     {
+//       _edges.resize(countEdges(_g));
+//       int l=0;
+//       for(NodeIt n(_g);n!=INVALID;++n)
+// 	{
+// 	  int ls = l;
+// 	  _start[n]=&(_edges[l]);	
+// 	  for(OutEdgeIt e(_g,n);e!=INVALID;++e) _edges[l++]=e;
+// 	  _end[n]=&(_edges[l]);
+// 	  std::sort(_edges.begin()+ls,_edges.begin()+l,EdgeLess(_g));
+// 	}
+      
+//     }
+    
+//     ///Find an edge between two nodes.
+    
+//     ///Find an edge between two nodes.
+//     ///\param s The source node
+//     ///\param t The target node
+//     ///\return An edge from \c s to \c t if there exists,
+//     ///\ref INVALID otherwise.
+
+//     Edge operator()(Node s, Node t) 
+//     {
+//       Edge *a=_start[s];
+//       Edge *b=_end[s];
+//       while(a!=b) 
+// 	{
+// // #ifdef X86
+//  	  Edge *m=(Edge*)((((unsigned int)a>>1)+((unsigned int)b)>>1)
+// 			  & 0xfffffffc);
+// // #elif X86_64
+// // 	  Edge *m=(Edge*)(((unsigned long)a>>1+(undigned long)b)>>1)&0xfffffffc);
+// // #else
+// //  	  Edge *m=a+((b-a)/2);
+// // #endif
+// 	  Node tt = _g.target(*m);
+// 	  if(tt==t) return *m;
+// 	  else if(tt<t) a=m+1;
+// 	  else b=m;
+// 	}
+//       return INVALID;
+//     }
+
+//     ///Find the next edge
+      
+//       ///\warning This function is unimplemented.
+//     Edge operator()(Node s, Node t, Edge prev) 
+//     {
+//       return prev==INVALID?(*this)(s,t):INVALID;
+//     }
+      
+//   };
+
+GRAPH_TYPEDEFS(SmartGraph);
+typedef SmartGraph Graph;
+
+class FE 
+{
+public:
+  Graph &_g;
+  FE(Graph &g) :_g(g) {}
+  void operator()() 
+  {
+    Edge e;
+    
+    for(NodeIt v(_g);v!=INVALID;++v)
+      for(NodeIt u(_g);u!=INVALID;++u)
+	e=findEdge(_g,u,v);
+  }
+  
+};
+
+class EL 
+{
+public:
+  Graph &_g;
+  EdgeLookUp<Graph> _el;
+  EL(Graph &g) :_g(g), _el(g) {}
+  void operator()() 
+  {
+    Edge e;
+    
+    for(NodeIt v(_g);v!=INVALID;++v)
+      for(NodeIt u(_g);u!=INVALID;++u)
+	e=_el(u,v);
+  }
+  
+};
+
+class DEL 
+{
+public:
+  Graph &_g;
+  DynEdgeLookUp<Graph> _el;
+  DEL(Graph &g) :_g(g), _el(g) {}
+  void operator()() 
+  {
+    Edge e;
+    
+    for(NodeIt v(_g);v!=INVALID;++v)
+      for(NodeIt u(_g);u!=INVALID;++u)
+	e=_el(u,v);
+  }
+  
+};
+
+class EL2
+{
+public:
+  Graph &_g;
+  EdgeLookUp2<Graph> _el;
+  EL2(Graph &g) :_g(g), _el(g) {}
+  void operator()() 
+  {
+    Edge e;
+    
+    for(NodeIt v(_g);v!=INVALID;++v)
+      for(NodeIt u(_g);u!=INVALID;++u)
+	e=_el(u,v);
+  }
+  
+};
+
+class EL3
+{
+public:
+  Graph &_g;
+  EdgeLookUp3<Graph> _el;
+  EL3(Graph &g) :_g(g), _el(g) {}
+  void operator()() 
+  {
+    Edge e;
+    
+    for(NodeIt v(_g);v!=INVALID;++v)
+      for(NodeIt u(_g);u!=INVALID;++u)
+	e=_el(u,v);
+  }
+  
+};
+
+// class EL4
+// {
+// public:
+//   Graph &_g;
+//   EdgeLookUp4<Graph> _el;
+//   EL4(Graph &g) :_g(g), _el(g) {}
+//   void operator()() 
+//   {
+//     Edge e;
+    
+//     for(NodeIt v(_g);v!=INVALID;++v)
+//       for(NodeIt u(_g);u!=INVALID;++u)
+// 	e=_el(u,v);
+//   }
+  
+// };
+
+// class EL5
+// {
+// public:
+//   Graph &_g;
+//   EdgeLookUp5<Graph> _el;
+//   EL5(Graph &g) :_g(g), _el(g) {}
+//   void operator()() 
+//   {
+//     Edge e;
+    
+//     for(NodeIt v(_g);v!=INVALID;++v)
+//       for(NodeIt u(_g);u!=INVALID;++u)
+// 	e=_el(u,v);
+//   }
+  
+// };
+
+int main(int, char**argv)
+{
+  int N=atoi(argv[1]);
+  int M=int(N*atof(argv[2]));
+  
+  Graph g;
+  
+  std::vector<Node> v;
+  for(int i=0;i<N;i++) v.push_back(g.addNode());
+  for(int i=0;i<M;i++) g.addEdge(v[rnd[N]],v[rnd[N]]);
+
+//   {
+//     Edge e;
+    
+//     TimeReport t("findEdge: ");
+//     for(NodeIt u(g);u!=INVALID;++u)
+//       for(NodeIt v(g);v!=INVALID;++v)
+// 	e=findEdge(g,u,v);
+//   }
+//   {
+//     Edge e;
+//     EdgeLookUp<Graph> el(g);
+    
+//     TimeReport t("EdgeLookUp: ");
+//     for(NodeIt u(g);u!=INVALID;++u)
+//       for(NodeIt v(g);v!=INVALID;++v)
+// 	e=el(u,v);
+//   }
+
+
+  TimeStamp t1 = runningTimeTest(FE(g),1);
+  TimeStamp t2 = runningTimeTest(EL(g),1);
+  TimeStamp t3 = runningTimeTest(DEL(g),1);
+  TimeStamp t4 = runningTimeTest(EL2(g),1);
+  TimeStamp t5 = runningTimeTest(EL3(g),1);
+//   TimeStamp t5 = runningTimeTest(EL4(g),1);
+//   TimeStamp t6 = runningTimeTest(EL5(g),1);
+
+  std::cout << t1.userTime() << ' ' 
+	    << t2.userTime() << ' '
+	    << t3.userTime() << ' '
+	    << t4.userTime() << ' '
+	    << t5.userTime() << ' '
+// 	    << t5.userTime() << ' '
+//  	    << t6.userTime()
+	    << std::endl;
+  std::cout << t1.userTime()/N/N << ' ' 
+	    << t2.userTime()/N/N << ' '
+	    << t3.userTime()/N/N << ' '
+	    << t4.userTime()/N/N << ' '
+	    << t5.userTime()/N/N << ' '
+// 	    << t5.userTime()/N/N << ' '
+//  	    << t6.userTime()/N/N
+	    << std::endl;
+}
+
Index: benchmark/edge_lookup_test
===================================================================
--- benchmark/edge_lookup_test	(revision 2235)
+++ benchmark/edge_lookup_test	(revision 2235)
@@ -0,0 +1,7 @@
+#!/bin/bash
+
+for((i=1;i<50;i++))
+do
+    echo -n $i ''
+    edge_lookup 100 $i
+done
Index: benchmark/graph-bench.cc
===================================================================
--- benchmark/graph-bench.cc	(revision 2592)
+++ benchmark/graph-bench.cc	(revision 2592)
@@ -0,0 +1,76 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<lemon/list_graph.h>
+
+#include"bench_tools.h"
+
+using namespace lemon;
+
+///Makes a full graph by adding and deleting a lot of edges;
+
+///\param n Number of nodes.
+///\param rat The funcion will make \f$rat\timesn^2\f$ edge addition and
+///\f$(rat-1)\timesn^2\f$ deletion.
+///\param p Tuning parameters.
+///\warning \c rat, \c p, and \c n must be pairwise relative primes. 
+template <class Graph>
+void makeFullGraph(int n, int rat, int p)
+{
+  GRAPH_TYPEDEFS(typename Graph);
+
+  Graph G;
+  
+  //  Node nodes[n];
+  std::vector<Node> nodes(n);
+  for(int i=0;i<n;i++) nodes[i]=G.addNode();
+  
+  //Edge equ[rat];
+  std::vector<Edge> equ(rat);
+  
+  /// \bug There is no long long int type in C++98.
+  long long int count;
+  
+  for(count=0;count<rat;count++) {
+    equ[int(count%rat)]=G.addEdge(nodes[int((count*p)%n)],
+				  nodes[int((count*p/n)%n)]);
+  }
+  for(;(count%rat)||((count*p)%n)||((count*p/n)%n);count++) {
+    //    if(!(count%1000000)) fprintf(stderr,"%d\r",count);
+    if(count%rat) G.erase(equ[count%rat]);
+    equ[int(count%rat)]=G.addEdge(nodes[int((count*p)%n)],
+				  nodes[int((count*p/n)%n)]);
+  }
+//   std::cout << "Added " << count
+// 	    << " ( " << n << "^2 * " << rat << " ) edges\n";
+
+
+  //  for(int i=0;1;i++) ;
+}
+
+int main()
+{
+  lemon::Timer T;
+  makeFullGraph<ListGraph>(nextPrim(1000),nextPrim(300),nextPrim(100));
+  
+  PrintTime("BIG",T);
+  T.restart();
+  makeFullGraph<ListGraph>(nextPrim(100),nextPrim(30000),nextPrim(150));
+
+  PrintTime("SMALL",T);
+}
Index: benchmark/hcube.cc
===================================================================
--- benchmark/hcube.cc	(revision 2569)
+++ benchmark/hcube.cc	(revision 2569)
@@ -0,0 +1,121 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<lemon/math.h>
+#include<lemon/list_graph.h>
+#include<lemon/smart_graph.h>
+#include<lemon/dijkstra.h>
+#include<lemon/preflow.h>
+
+#include"bench_tools.h"
+
+using namespace std;
+using namespace lemon;
+
+inline int numOfOnes(int n,int dim)
+{
+  int s=0;
+  for(int i=0;i<dim;i++) {
+    s+=n%2;
+    n>>=1;
+  }
+  return s;
+}
+
+inline int numOfZeros(int n,int dim)
+{
+  int s=dim;
+  for(int i=0;i<dim;i++) {
+    s-=n&1;
+    n>>=1;
+  }
+  return s;
+}
+
+int main(int argc, char *argv[])
+{
+  //  typedef ListGraph Graph;
+  typedef SmartGraph Graph;
+
+  GRAPH_TYPEDEFS(Graph);
+
+  Graph G;
+  
+  Timer T;
+  
+  if(argc!=2) {
+    cout << "Usage: " << argv[0] << " dim\n";
+    return 1;
+  }
+  
+  int dim=atoi(argv[1]);
+  
+//   cout << "Creating Hipercube ("<< (1<<dim) << " nodes, "
+//        << dim*(1<<dim) << " edges):";
+
+  T.restart();
+  vector<Node> nodes;
+  addBiDirHyperCube(G,dim,nodes);
+
+  PrintTime("GENGRAPH",T);
+
+  T.restart();
+  Graph::EdgeMap<int> map(G);
+  for(int i=0;i<5;i++) {
+    Primes P;
+    for(int j=0;j<dim*(1<<dim);j++) P();
+    
+    //  for(EdgeIt e(G);G.valid(e);G.next(e)) map[e]=P();
+
+    ///\todo It must have been commented out because of
+    ///setToId
+//     Edge te;
+//     for(int i=0;i<dim*(1<<dim);i++) {
+//       te.setToId(((long long int)(i)*93505)%(dim*(1<<dim)));
+//       //    map[Edge(((long long int)(i)*2987)%(dim*(1<<dim)))]=P();
+//       map[te]=P();
+//     }
+    
+//     for(int i=0;i<(1<<dim);i++) {
+//       int mul= (1<<(numOfZeros(i,dim)/4));
+//       for(OutEdgeIt e(G,nodes[i]);G.valid(e);G.next(e))
+// 	map[e]*=mul;
+//     }
+  }
+  
+  PrintTime("GENLENGTHS",T);
+
+  T.restart();
+  {
+    Dijkstra<Graph> Dij(G,map);
+    for(int i=0;i<10;i++)
+      Dij.run(nodes[0]);
+  }
+  PrintTime("DIJKSTRA",T);
+
+  T.restart();
+  {
+   Graph::EdgeMap<int> flow(G);
+   
+    Preflow<Graph> MF(G,map,nodes[0],nodes[1<<dim-1]);
+    for(int i=0;i<10;i++)
+      MF.run();
+  }
+  PrintTime("PREFLOW",T);
+
+}
Index: benchmark/min_cut.cc
===================================================================
--- benchmark/min_cut.cc	(revision 2553)
+++ benchmark/min_cut.cc	(revision 2553)
@@ -0,0 +1,187 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/list_graph.h>
+
+#include <lemon/hao_orlin.h>
+#include <lemon/nagamochi_ibaraki.h>
+#include <lemon/time_measure.h>
+
+using namespace lemon;
+
+#include "min_cut_graphs.h"
+
+
+void testRegUGraph();
+void testNoiUGraph();
+void testBikeWheelUGraph();
+
+int main() {
+  testRegUGraph();
+  testNoiUGraph();
+  testBikeWheelUGraph();
+  return 0;
+}
+
+//#define int long long
+
+
+int cutValue(const ListUGraph& g, const ListUGraph::UEdgeMap<int>& c,
+           const ListUGraph::NodeMap<bool>& n) {
+  int v = 0;
+  for (ListUGraph::UEdgeIt e(g); e != INVALID; ++e) {
+    if (n[g.source(e)] != n[g.target(e)]) {
+      v += c[e];
+    }
+  }
+  return v;
+}
+
+int cutSize(const ListUGraph& g, const ListUGraph::NodeMap<bool>& nm) {
+  int m = 0;
+  for (ListUGraph::NodeIt n(g); n != INVALID; ++n) {
+    if (nm[n]) {
+      ++m;
+    }
+  }
+  return m;
+}
+
+int testNI(const ListUGraph& g, const ListUGraph::UEdgeMap<int>& c) {
+  TimeReport tr("Nagamochi-Ibaraki : ");
+  NagamochiIbaraki<ListUGraph, ListUGraph::UEdgeMap<int> > alg(g, c);
+  alg.run();
+  ListUGraph::NodeMap<bool> n(g);
+  alg.minCut(n);
+  std::cout << "Check : " << cutValue(g, c, n) << ' '
+            << cutSize(g, n) << std::endl;
+  return alg.minCut();
+}
+
+int testHO(const ListUGraph& g, const ListUGraph::UEdgeMap<int>& c) {
+  TimeReport tr("Hao-Orlin : ");
+  HaoOrlin<ListUGraph, ListUGraph::UEdgeMap<int> > alg(g, c);
+  alg.init();
+  alg.calculateOut();
+  ListUGraph::NodeMap<bool> n(g);
+  alg.minCut(n);
+  std::cout << "Check : " << cutValue(g, c, n) << ' '
+            << cutSize(g, n) << std::endl;
+  return alg.minCut();
+}
+
+void testBikeWheelUGraph(int n) {
+  ListUGraph g;
+  ListUGraph::UEdgeMap<int> c(g);
+  genBikeWheelUGraph(g, c, n);
+  std::cout << "Node number : " << n << std::endl;
+  std::cout << "Hao-Orlin : " << testHO(g, c) << std::endl;
+  std::cout << "Nagamochi-Ibaraki : " << testNI(g, c) << std::endl;
+}
+
+void testBikeWheelUGraph() {
+  std::cout << "BikeWheelUGraph : " << std::endl;
+  for (int k = 10; k <= 13; ++k) {
+    int n = 1 << k;
+    testBikeWheelUGraph(n);
+  }
+}
+
+void testNoiUGraph(int n, int d, int k, int p) {
+  ListUGraph g;
+  ListUGraph::UEdgeMap<int> c(g);
+  genNoiUGraph(g, c, n, d, k, p);
+  std::cout << "Node number : " << n << std::endl;
+  std::cout << "Density : " << d << std::endl;
+  std::cout << "Tight components : " << k << std::endl;
+  std::cout << "Scale : " << p << std::endl;
+  std::cout << "Hao-Orlin : " << testHO(g, c) << std::endl;
+  std::cout << "Nagamochi-Ibaraki : " << testNI(g, c) << std::endl;
+}
+
+
+void testNoiUGraph() {
+  std::cout << "NoiUGraph : " << std::endl; 
+  std::cout << "Serial 1 : " << std::endl;
+  for (int n = 300; n <= 1000; n += 100) {
+    testNoiUGraph(n, 50, 1, n);
+  }
+  std::cout << "Serial 2 : " << std::endl;
+  for (int n = 300; n <= 1000; n += 100) {
+    testNoiUGraph(n, 50, 2, n);
+  }
+  std::cout << "Serial 3 : " << std::endl;
+  int da3[] = { 5, 10, 25, 50, 75, 100 };
+  int dn3 = sizeof(da3) / sizeof(da3[0]);
+  for (int d = 0; d < dn3; ++d) {
+    testNoiUGraph(1000, da3[d], 1, 1000);
+  }
+  std::cout << "Serial 4 : " << std::endl;
+  for (int d = 0; d < dn3; ++d) {
+    testNoiUGraph(1000, da3[d], 2, 1000);
+  }
+  std::cout << "Serial 5 : " << std::endl;
+  int ka5[] = {1, 2, 3, 5, 7, 10, 20, 30, 33, 35, 
+               40, 50, 100, 200, 300, 400, 500};
+  int kn5 = sizeof(ka5) / sizeof(ka5[0]);
+  for (int k = 0; k < kn5; ++k) {
+    testNoiUGraph(1000, 50, ka5[k], 1000);
+  }
+  std::cout << "Serial 6 : " << std::endl;
+  int pa6[] = { 5000, 2000, 1000, 500, 250, 100, 50, 10, 1};
+  int pn6 = sizeof(pa6) / sizeof(pa6[0]);
+  for (int p = 0; p < pn6; ++p) {
+    testNoiUGraph(1000, 50, 2, pa6[p]);
+  }  
+  
+}
+
+void testRegUGraph(int n, int d) {
+  ListUGraph g;
+  ListUGraph::UEdgeMap<int> c(g);
+  genRegUGraph(g, c, n, d);
+  std::cout << "Node number : " << n << std::endl;
+  std::cout << "Number of cycles : " << d << std::endl;
+  std::cout << "Hao-Orlin : " << testHO(g, c) << std::endl;
+  std::cout << "Nagamochi-Ibaraki : " << testNI(g, c) << std::endl;
+}
+
+void testRegUGraph() {
+  std::cout << "RegUGraph : " << std::endl; 
+  std::cout << "Serial 1 : " << std::endl;
+  int da1[] = { 1, 3, 10, 33, 100, 333, 1000};
+  int dn1 = sizeof(da1) / sizeof(da1[0]);
+  for (int d = 0; d < dn1; ++d) {
+    testRegUGraph(1001, da1[d]);
+  }
+  std::cout << "Serial 2 : " << std::endl;
+  int na2[] = { 50, 100, 200, 400, 800};
+  int nn2 = sizeof(na2) / sizeof(na2[0]);
+  for (int n = 0; n < nn2; ++n) {
+    testRegUGraph(na2[n], 50);
+  }
+  std::cout << "Serial 3 : " << std::endl;
+  for (int n = 8; n <= 14; ++n) {
+    testRegUGraph(1 << n, 2);
+  }
+  std::cout << "Serial 4 : " << std::endl;
+  for (int n = 7; n <= 11; ++n) {
+    testRegUGraph(1 << n, 1 << (n - 4));
+  }  
+}
+
Index: benchmark/min_cut_graphs.h
===================================================================
--- benchmark/min_cut_graphs.h	(revision 2553)
+++ benchmark/min_cut_graphs.h	(revision 2553)
@@ -0,0 +1,99 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/random.h>
+
+
+template <typename UGraph, typename CapacityMap>
+void genNoiUGraph(UGraph& g, CapacityMap& c, 
+                  int n, int d, int k, int p) {
+  std::vector<typename UGraph::Node> nodes(n);
+  for (int i = 0; i < n; ++i) {
+    nodes[i] = g.addNode();
+  }
+  typename UGraph::template NodeMap<int> comp(g);
+  for (int i = 0; i < n; ++i) {
+    comp[nodes[i]] = rnd[k];
+  }
+  int m = (n * (n - 1) * d) / 200;
+  for (int i = 0; i < m; ++i) {
+    int s = rnd[n], t = rnd[n];
+    c[g.addEdge(nodes[s], nodes[t])] =
+      rnd[(comp[nodes[s]] == comp[nodes[t]] ? p : 1) * 100]; 
+  }
+}
+
+template <typename UGraph, typename CapacityMap>
+void genBikeWheelUGraph(UGraph& g, CapacityMap& c, int n) {
+  std::vector<typename UGraph::Node> nodes(n);
+  for (int i = 0; i < n; ++i) {
+    nodes[i] = g.addNode();
+  }
+  for (int i = 0; i < n - 2; ++i) {
+    c[g.addEdge(nodes[i], nodes[n - 1 - (i % 2)])] = 2;
+  }
+  for (int i = 1; i < n - 2; ++i) {
+    c[g.addEdge(nodes[i - 1], nodes[i])] = n - 1;
+  }
+  c[g.addEdge(nodes[n - 3], nodes[0])] = n - 1;
+  c[g.addEdge(nodes[n - 2], nodes[n - 1])] = 2;
+}
+
+template <typename UGraph, typename CapacityMap>
+void genRegUGraph(UGraph& g, CapacityMap& c, int n, int d) {
+  std::vector<typename UGraph::Node> nodes(n);
+  for (int i = 0; i < n; ++i) {
+    nodes[i] = g.addNode();
+  }
+  for (int k = 0; k < d; ++k) {
+    for (int i = 0; i < n; ++i) {
+      int r = rnd[n];
+      typename UGraph::Node t = nodes[r];
+      nodes[r] = nodes[i];
+      nodes[i] = t;
+    }
+    for (int i = 1; i < n; ++i) {
+      c[g.addEdge(nodes[i - 1], nodes[i])] = 1;
+    }
+    c[g.addEdge(nodes[n - 1], nodes[0])] = 1;
+  }
+}
+
+template <typename UGraph, typename CapacityMap>
+void genCdgUGraph(UGraph& g, CapacityMap& c, int n, int d) {
+  std::vector<typename UGraph::Node> nodes(n);
+  for (int i = 0; i < n; ++i) {
+    nodes[i] = g.addNode();
+  }
+  std::vector<typename UGraph::Node> mix(n * d);
+  for (int i = 0; i < n; ++i) {
+    for (int j = 0; j < d; ++j) {
+      mix[i * d + j] = nodes[i];
+    }
+  }
+  while (mix.size() >= 2) {
+    int r;
+    r = rnd[mix.size()];
+    typename UGraph::Node s = mix[r];
+    mix[r] = mix.back(); mix.pop_back();
+    r = rnd[mix.size()];
+    typename UGraph::Node t = mix[r];
+    mix[r] = mix.back(); mix.pop_back();
+    c[g.addEdge(s, t)] = 1;
+  }
+}
Index: benchmark/radix_sort-bench.cc
===================================================================
--- benchmark/radix_sort-bench.cc	(revision 2569)
+++ benchmark/radix_sort-bench.cc	(revision 2569)
@@ -0,0 +1,90 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#define NDEBUG
+
+#include <lemon/time_measure.h>
+#include <lemon/smart_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/maps.h>
+#include <lemon/error.h>
+
+#include <lemon/radix_sort.h>
+
+#include <lemon/random.h>
+
+#include <vector>
+#include <algorithm>
+#include <lemon/math.h>
+
+using namespace std;
+using namespace lemon;
+
+void testRadixSort() {
+  int n = 10000000;
+  vector<int> data(n);
+  for (int i = 0; i < n; ++i) {
+    data[i] = rnd[1000] - 500;
+  }
+  radixSort(data.begin(), data.end());
+}
+
+
+void testCounterSort() {
+  int n = 10000000;
+  vector<int> data(n);
+  for (int i = 0; i < n; ++i) {
+    data[i] = rnd[1000] - 500;
+  }
+  counterSort(data.begin(), data.end());
+}
+
+void testSort() {
+  int n = 10000000;
+  vector<int> data(n);
+  for (int i = 0; i < n; ++i) {
+    data[i] = rnd[1000] - 500;
+  }
+  sort(data.begin(), data.end());
+}
+
+void testStableSort() {
+  int n = 10000000;
+  vector<int> data(n);
+  for (int i = 0; i < n; ++i) {
+    data[i] = rnd[1000] - 500;
+  }
+  stable_sort(data.begin(), data.end());
+}
+
+void testSorts() {
+  {
+    int n = 10000000;
+    vector<int> data(n);
+  }
+  cout << "Radix sort: " << runningTimeTest(testRadixSort, 60) << endl;
+  cout << "Counter sort: " << runningTimeTest(testCounterSort, 60) << endl;
+  cout << "Standard sort: " << runningTimeTest(testSort, 60) << endl;
+  cout << "Stable sort: " << runningTimeTest(testStableSort, 60) << endl;
+}
+
+
+int main() {
+  testSorts();
+  return 0;
+}
Index: benchmark/random_bench.cc
===================================================================
--- benchmark/random_bench.cc	(revision 2553)
+++ benchmark/random_bench.cc	(revision 2553)
@@ -0,0 +1,151 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<stdlib.h>
+#include<lemon/random.h>
+#include<lemon/time_measure.h>
+
+using namespace lemon;
+
+void f_no() 
+{
+}
+
+inline void f_noi() 
+{
+}
+
+inline void f_i() 
+{
+  static int r;  
+  r=5;
+}
+
+inline void f_l() 
+{
+  static long int r;
+  r=5;
+}
+
+inline void f_d() 
+{
+  static double r;
+  r=5;
+}
+
+inline void f_rand() 
+{
+  static int r;  
+  r=rand();
+}
+
+inline void f_random() 
+{
+  static long int r;
+  r=random();
+}
+
+inline void f_drand48() 
+{
+  static double r;
+  r=drand48();
+}
+
+inline void f_rnd_d() 
+{
+  static double r;
+  r=rnd();
+}
+inline void f_rnd_int1000() 
+{
+  static int r;
+  r=rnd[1000];
+}
+inline void f_rnd_bool() 
+{
+  static bool r;
+  r=rnd.boolean();
+}
+
+// inline void f_() 
+// {
+//   static double r;
+//   r=;
+// }
+
+int main()
+{
+  TimeStamp full;
+  TimeStamp t;
+  unsigned int n;
+  
+  const double TEST_DURATION=10;
+
+  t=runningTimeTest(f_no,2,&n,&full);
+
+  t=runningTimeTest(f_no,TEST_DURATION,&n,&full); 
+  std::cout << "EMPTY:         ";
+  std::cout << t.userTime() << " (" << n << " tests)\n";
+  
+  t=runningTimeTest(f_noi,TEST_DURATION,&n,&full);
+  std::cout << "INLINED EMPTY: ";
+  std::cout << t.userTime() << " (" << n << " tests)\n";
+  
+  TimeStamp ti=t=runningTimeTest(f_i,TEST_DURATION,&n,&full);
+  std::cout << "INT COPY:      ";
+  std::cout << t.userTime() << " (" << n << " tests)\n";
+  
+  TimeStamp tl=t=runningTimeTest(f_l,TEST_DURATION,&n,&full);
+  std::cout << "LONG COPY:     ";
+  std::cout << t.userTime() << " (" << n << " tests)\n";
+  
+  TimeStamp td=t=runningTimeTest(f_d,TEST_DURATION,&n,&full);
+  std::cout << "DOUBLE COPY:   ";
+  std::cout << t.userTime() << " (" << n << " tests)\n";
+  
+  t=runningTimeTest(f_rand,TEST_DURATION,&n,&full);
+  std::cout << "rand():        ";
+  std::cout << (t-ti).userTime() << " (" << n << " tests)\n";
+  
+  t=runningTimeTest(f_random,TEST_DURATION,&n,&full);
+  std::cout << "random():      ";
+  std::cout << (t-tl).userTime() << " (" << n << " tests)\n";
+  
+  t=runningTimeTest(f_drand48,TEST_DURATION,&n,&full);
+  std::cout << "drand48():     ";
+  std::cout << (t-td).userTime() << " (" << n << " tests)\n";
+  
+  t=runningTimeTest(f_rnd_d,TEST_DURATION,&n,&full);
+  std::cout << "rnd():         ";
+  std::cout << (t-td).userTime() << " (" << n << " tests)\n";
+  
+  t=runningTimeTest(f_rnd_int1000,TEST_DURATION,&n,&full);
+  std::cout << "rnd[1000]:     ";
+  std::cout << (t-ti).userTime() << " (" << n << " tests)\n";
+  
+  t=runningTimeTest(f_rnd_bool,TEST_DURATION,&n,&full);
+  std::cout << "rnd.boolean(): ";
+  std::cout << (t-ti).userTime() << " (" << n << " tests)\n";
+  
+//   t=runningTimeTest(f_,TEST_DURATION,&n,&full);
+//   std::cout << "\n";
+//   std::cout << t << " (" << n << " tests)\n";
+//   std::cout << "Total: " << full << "\n\n";
+  
+  return 0;
+}
Index: benchmark/swap_bipartite_bench.cc
===================================================================
--- benchmark/swap_bipartite_bench.cc	(revision 2553)
+++ benchmark/swap_bipartite_bench.cc	(revision 2553)
@@ -0,0 +1,135 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <cstdlib>
+#include <iostream>
+#include <sstream>
+
+#include <lemon/smart_graph.h>
+#include <lemon/list_graph.h>
+
+#include <lemon/bpugraph_adaptor.h>
+#include <lemon/bipartite_matching.h>
+
+#include <lemon/graph_utils.h>
+#include <lemon/graph_to_eps.h>
+
+#include <lemon/time_measure.h>
+#include <lemon/random.h>
+
+using namespace std;
+using namespace lemon;
+
+typedef SmartBpUGraph Graph;
+typedef ListBpUGraph LGraph;
+BPUGRAPH_TYPEDEFS(Graph);
+
+
+int main() {
+
+  for (int k = 1; k < 100; ++k) {
+    
+    int n = k * 100;
+    int m = (100 - k) * 100;
+    int e = 20000;
+    int s = 100;
+    
+    Timer nt(false), st(false);
+    Timer lnt(false), lst(false);
+    
+    for (int i = 0; i < s; ++i) {
+      Graph graph;
+      LGraph lgraph;
+      vector<Node> aNodes;
+      vector<Node> bNodes;  
+      vector<LGraph::Node> laNodes;
+      vector<LGraph::Node> lbNodes;  
+      
+      for (int j = 0; j < n; ++j) {
+        Node node = graph.addANode();
+        aNodes.push_back(node);
+        LGraph::Node lnode = lgraph.addANode();
+        laNodes.push_back(lnode);
+      }
+      for (int j = 0; j < m; ++j) {
+        Node node = graph.addBNode();
+        bNodes.push_back(node);
+        LGraph::Node lnode = lgraph.addBNode();
+        lbNodes.push_back(lnode);
+      }
+      for (int j = 0; j < e; ++j) {
+        int a,b;
+	Node aNode = aNodes[a=rnd[n]];
+        Node bNode = bNodes[b=rnd[m]];
+        graph.addEdge(aNode, bNode);
+	LGraph::Node laNode = laNodes[a];
+        LGraph::Node lbNode = lbNodes[b];
+        lgraph.addEdge(laNode, lbNode);
+      }
+
+      {
+        MaxBipartiteMatching<Graph> bpmatch(graph);
+        
+        nt.start();
+        bpmatch.init();
+        bpmatch.start();
+        nt.stop();
+        
+      }
+
+      {
+        typedef SwapBpUGraphAdaptor<Graph> SGraph;
+        SGraph sgraph(graph);
+        MaxBipartiteMatching<SGraph> bpmatch(sgraph);
+
+        st.start();
+        bpmatch.init();
+        bpmatch.start();
+        st.stop();
+        
+      }                 
+      {
+        MaxBipartiteMatching<LGraph> bpmatch(lgraph);
+        
+        lnt.start();
+        bpmatch.init();
+        bpmatch.start();
+        lnt.stop();
+        
+      }
+
+      {
+        typedef SwapBpUGraphAdaptor<LGraph> SGraph;
+        SGraph sgraph(lgraph);
+        MaxBipartiteMatching<SGraph> bpmatch(sgraph);
+
+        lst.start();
+        bpmatch.init();
+        bpmatch.start();
+        lst.stop();
+        
+      }
+     }
+
+    cout << k * 100 << ' ' << nt.realTime() << ' ' << st.realTime()
+	 << ' ' << lnt.realTime() << ' ' << lst.realTime()<< endl;
+
+  }
+
+  return 0;
+}
Index: configure.ac
===================================================================
--- configure.ac	(revision 2647)
+++ configure.ac	(revision 2614)
@@ -1,9 +1,19 @@
 dnl Process this file with autoconf to produce a configure script.
+
+dnl Version information.
+m4_define([lemon_version_major], [0])
+m4_define([lemon_version_minor], [7])
+m4_define([lemon_version_micro], [90])
+m4_define([lemon_version_nano], [])
+m4_define([lemon_version_tag], [svn])
+m4_define([lemon_svn_revision], [m4_normalize(esyscmd([svn info |grep ^Revision |cut -d ' ' -f 2]))])
+m4_define([lemon_version], [lemon_version_major().lemon_version_minor()ifelse(lemon_version_micro(), [], [], [.lemon_version_micro()])ifelse(lemon_version_nano(), [], [], [.lemon_version_nano()])ifelse(lemon_version_tag(), [], [], lemon_version_tag(), [svn], [[_]lemon_version_tag()[]lemon_svn_revision()], [[_]lemon_version_tag()])])
+
 AC_PREREQ([2.59])
-AC_INIT([LEMON], [svn-head], [etik-ol@cs.elte.hu], [lemon])
+AC_INIT([LEMON], [lemon_version()], [etik-ol@cs.elte.hu], [lemon])
 AC_CONFIG_AUX_DIR([build-aux])
 AC_CONFIG_MACRO_DIR([m4])
-AM_INIT_AUTOMAKE([-Wall -Werror foreign subdir-objects])
-dnl AC_CONFIG_SRCDIR([lemon/list_graph.h])
+AM_INIT_AUTOMAKE([-Wall -Werror foreign subdir-objects nostdinc])
+AC_CONFIG_SRCDIR([lemon/list_graph.h])
 AC_CONFIG_HEADERS([config.h lemon/config.h])
 
@@ -18,5 +28,5 @@
 
 if test x"$lx_cmdline_cxxflags_set" != x"set" -a "$GXX" = yes; then
-  CXXFLAGS="$CXXFLAGS -Wall -W"
+  CXXFLAGS="$CXXFLAGS -Wall -W -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 -Woverloaded-virtual -ansi -fno-strict-aliasing -Wold-style-cast -Wno-unknown-pragmas"
 fi
 
@@ -26,4 +36,5 @@
 LX_CHECK_GLPK
 LX_CHECK_CPLEX
+LX_CHECK_SOPLEX
 
 dnl Enable/disable installing the documentation
@@ -67,4 +78,17 @@
 AM_CONDITIONAL([WANT_DEMO], [test x"$enable_demo" != x"no"])
 
+dnl Disable/enable building the binary tools
+AC_ARG_ENABLE([tools],
+AS_HELP_STRING([--enable-tools], [build additional tools @<:@default@:>@])
+AS_HELP_STRING([--disable-tools], [do not build additional tools]),
+              [], [enable_tools=yes])
+AC_MSG_CHECKING([whether to build the additional tools])
+if test x"$enable_tools" != x"no"; then
+  AC_MSG_RESULT([yes])
+else
+  AC_MSG_RESULT([no])
+fi
+AM_CONDITIONAL([WANT_TOOLS], [test x"$enable_tools" != x"no"])
+
 dnl Disable/enable building the benchmarks
 AC_ARG_ENABLE([benchmark],
@@ -96,9 +120,9 @@
 AC_CONFIG_FILES([
 Makefile
+lemon.spec
+autopackage/default.apspec
 doc/Doxyfile
 lemon/lemon.pc
 ])
-dnl lemon.spec
-dnl autopackage/default.apspec
 
 AC_OUTPUT
@@ -114,7 +138,9 @@
 echo GLPK support.................. : $lx_glpk_found
 echo CPLEX support................. : $lx_cplex_found
+echo SOPLEX support................ : $lx_soplex_found
 echo
 echo build benchmarks.............. : $enable_benchmark
 echo build demo programs........... : $enable_demo
+echo build additional tools........ : $enable_tools
 echo
 echo The packace will be installed in
Index: debian/README.Debian
===================================================================
--- debian/README.Debian	(revision 1490)
+++ debian/README.Debian	(revision 1490)
@@ -0,0 +1,6 @@
+lemon for Debian
+----------------
+
+<possible notes regarding this package - if none, delete this file>
+
+ -- LEMON Development Team <etik-ol@cs.elte.hu>, Tue, 14 Jun 2005 08:29:34 +0200
Index: debian/changelog
===================================================================
--- debian/changelog	(revision 1926)
+++ debian/changelog	(revision 1926)
@@ -0,0 +1,6 @@
+lemon (0.5-1) unstable; urgency=low
+
+  * Initial Release.
+
+ -- LEMON Development Team <etik-ol@cs.elte.hu>  Tue, 14 Jun 2005 08:29:34 +0200
+
Index: debian/compat
===================================================================
--- debian/compat	(revision 1490)
+++ debian/compat	(revision 1490)
@@ -0,0 +1,1 @@
+4
Index: debian/control
===================================================================
--- debian/control	(revision 1917)
+++ debian/control	(revision 1917)
@@ -0,0 +1,15 @@
+Source: lemon
+Section: unknown
+Priority: optional
+Maintainer: LEMON Development Team <etik-ol@cs.elte.hu>
+Build-Depends: debhelper (>= 4.0.0), glpk, libgnomecanvasmm-2.6-dev
+Standards-Version: 3.6.1
+
+Package: lemon
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}, libgnomecanvasmm-2.6
+Description: A C++ template library aimed at combinatorial optimization tasks.
+ LEMON stands for Library of Efficient Models and
+ Optimization in Networks. It is a C++ template
+ library aimed at combinatorial optimization tasks,
+ especially those working with graphs and networks.
Index: debian/copyright
===================================================================
--- debian/copyright	(revision 1490)
+++ debian/copyright	(revision 1490)
@@ -0,0 +1,43 @@
+This package was debianized by LEMON Development Team <etik-ol@cs.elte.hu> on
+Tue, 14 Jun 2005 08:29:34 +0200.
+
+It was downloaded from http://lemon.cs.elte.hu
+
+Copyright:
+
+Copyright (C) 2003-2005 Egervary Jeno Kombinatorikus Optimalizalasi
+Kutatocsoport (Egervary Combinatorial Optimization Research Group,
+EGRES).
+
+Upstream Author(s):
+
+Mihaly Barasz <klao@cs.elte.hu>
+Johanna Becker <beckerjc@cs.elte.hu>
+Attila Bernath <athos@cs.elte.hu>
+Alpar Juttner <alpar@cs.elte.hu>
+Marton Makai <marci@cs.elte.hu>
+Jacint Szabo <jacint@cs.elte.hu>
+
+License:
+
+Permission is hereby granted, free of charge, to any person or organization
+obtaining a copy of the software and accompanying documentation covered by
+this license (the "Software") to use, reproduce, display, distribute,
+execute, and transmit the Software, and to prepare derivative works of the
+Software, and to permit third-parties to whom the Software is furnished to
+do so, all subject to the following:
+
+The copyright notices in the Software and this entire statement, including
+the above license grant, this restriction and the following disclaimer,
+must be included in all copies of the Software, in whole or in part, and
+all derivative works of the Software, unless such copies or derivative
+works are solely in the form of machine-executable object code generated by
+a source language processor.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
+SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
+FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
+ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+DEALINGS IN THE SOFTWARE.
Index: debian/dirs
===================================================================
--- debian/dirs	(revision 1490)
+++ debian/dirs	(revision 1490)
@@ -0,0 +1,2 @@
+usr/bin
+usr/sbin
Index: debian/docs
===================================================================
--- debian/docs	(revision 1490)
+++ debian/docs	(revision 1490)
@@ -0,0 +1,5 @@
+AUTHORS
+COPYING
+LICENSE
+NEWS
+README
Index: debian/lemon.doc-base
===================================================================
--- debian/lemon.doc-base	(revision 1490)
+++ debian/lemon.doc-base	(revision 1490)
@@ -0,0 +1,9 @@
+Document: lemon-refman
+Title: LEMON Reference Manual
+Author: LEMON Development Team
+Abstract: Documentation of LEMON.
+Section: unknown
+
+Format: HTML
+Index: /usr/share/doc/lemon/html/index.html
+Files: /usr/share/doc/lemon/html/*.html
Index: debian/rules
===================================================================
--- debian/rules	(revision 1926)
+++ debian/rules	(revision 1926)
@@ -0,0 +1,107 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+# Sample debian/rules that uses debhelper.
+# This file was originally written by Joey Hess and Craig Small.
+# As a special exception, when this file is copied by dh-make into a
+# dh-make output file, you may use that output file without restriction.
+# This special exception was added by Craig Small in version 0.37 of dh-make.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+
+# These are used for cross-compiling and for saving the configure script
+# from having to guess our platform (since we know it already)
+DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+
+
+CFLAGS = -Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+	CFLAGS += -O0
+else
+	CFLAGS += -O2
+endif
+
+config.status: configure
+	dh_testdir
+	# Add here commands to configure the package.
+	CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info --enable-gui --with-glpk --without-cplex
+
+
+build: build-stamp
+
+build-stamp:  config.status
+	dh_testdir
+
+	# Add here commands to compile the package.
+	$(MAKE)
+	#docbook-to-man debian/lemon.sgml > lemon.1
+
+	touch build-stamp
+
+clean:
+	dh_testdir
+	dh_testroot
+	rm -f build-stamp 
+
+	# Add here commands to clean up after the build process.
+	-$(MAKE) distclean
+ifneq "$(wildcard /usr/share/misc/config.sub)" ""
+	cp -f /usr/share/misc/config.sub config.sub
+endif
+ifneq "$(wildcard /usr/share/misc/config.guess)" ""
+	cp -f /usr/share/misc/config.guess config.guess
+endif
+
+
+	dh_clean 
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_clean -k 
+	dh_installdirs
+
+	# Add here commands to install the package into debian/lemon.
+	$(MAKE) install DESTDIR=$(CURDIR)/debian/lemon
+
+
+# Build architecture-independent files here.
+binary-indep: build install
+# We have nothing to do by default.
+
+# Build architecture-dependent files here.
+binary-arch: build install
+	dh_testdir
+	dh_testroot
+	dh_installchangelogs ChangeLog
+	dh_installdocs
+	dh_installexamples
+#	dh_install
+#	dh_installmenu
+#	dh_installdebconf	
+#	dh_installlogrotate
+#	dh_installemacsen
+#	dh_installpam
+#	dh_installmime
+#	dh_installinit
+#	dh_installcron
+#	dh_installinfo
+#	dh_installman
+	dh_link
+	dh_strip
+	dh_compress
+	dh_fixperms
+#	dh_perl
+#	dh_python
+#	dh_makeshlibs
+	dh_installdeb
+	dh_shlibdeps
+	dh_gencontrol
+	dh_md5sums
+	dh_builddeb
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install 
Index: debian/watch
===================================================================
--- debian/watch	(revision 1490)
+++ debian/watch	(revision 1490)
@@ -0,0 +1,2 @@
+version=2
+http://lemon.cs.elte.hu/data/lemon-(.*)\.tar\.gz	debian	uupdate
Index: demo/Makefile.am
===================================================================
--- demo/Makefile.am	(revision 2652)
+++ demo/Makefile.am	(revision 2497)
@@ -1,32 +1,53 @@
 EXTRA_DIST += \
-	demo/Makefile
-##	demo/sub_graph_adaptor_demo.dim
+	demo/Makefile \
+	demo/sub_graph_adaptor_demo.dim \
+	demo/circulation-input.lgf \
+	demo/coloring.lgf \
+	demo/dir_components.lgf \
+	demo/disjoint_paths_demo.lgf \
+	demo/graph_orientation.lgf \
+	demo/partitions.lgf \
+	demo/route.lgf \
+	demo/sample.lgf \
+	demo/simann_maxcut_demo.lgf \
+	demo/strongly_connected_orientation.lgf \
+	demo/sub_gad_input.lgf \
+	demo/u_components.lgf \
+	demo/steiner.lgf \
+	demo/sat-2.in
 
 if WANT_DEMO
 
-noinst_PROGRAMS +=
-##	demo/dim_to_dot \
-##	demo/dijkstra_demo \
-##	demo/reader_writer_demo \
-##	demo/dim_to_lgf \
-##	demo/eps_demo \
-##	demo/graph_to_eps_demo \
-##	demo/graph_orientation \
-##	demo/min_route \
-##	demo/hello_lemon \
-##	demo/sub_graph_adaptor_demo \
-##	demo/descriptor_map_demo \
-##	demo/coloring \
-##	demo/grid_ugraph_demo \
-##	demo/topology_demo \
-##	demo/simann_maxcut_demo \
-##	demo/disjoint_paths_demo \
-##	demo/strongly_connected_orientation
+noinst_PROGRAMS += \
+	demo/arg_parser_demo \
+	demo/circulation_demo \
+	demo/csp_demo \
+	demo/dim_to_dot \
+	demo/dijkstra_demo \
+	demo/reader_writer_demo \
+	demo/eps_demo \
+	demo/graph_to_eps_demo \
+	demo/graph_orientation \
+	demo/min_route \
+	demo/hello_lemon \
+	demo/hello_world \
+	demo/maps_summary \
+	demo/sub_graph_adaptor_demo \
+	demo/descriptor_map_demo \
+	demo/coloring \
+	demo/grid_ugraph_demo \
+	demo/topology_demo \
+	demo/topological_ordering \
+	demo/simann_maxcut_demo \
+	demo/disjoint_paths_demo \
+	demo/strongly_connected_orientation \
+	demo/steiner_demo \
+	demo/sat-2
 
 if HAVE_GLPK
-##noinst_PROGRAMS += demo/lp_demo demo/lp_maxflow_demo
+noinst_PROGRAMS += demo/lp_demo demo/lp_maxflow_demo demo/mip_demo demo/sat
 else !HAVE_GLPK
 if HAVE_CPLEX
-##noinst_PROGRAMS += demo/lp_demo demo/lp_maxflow_demo
+noinst_PROGRAMS += demo/lp_demo demo/lp_maxflow_demo
 endif HAVE_CPLEX
 endif !HAVE_GLPK
@@ -34,43 +55,63 @@
 endif WANT_DEMO
 
-##demo_dim_to_dot_SOURCES = demo/dim_to_dot.cc
+demo_arg_parser_demo_SOURCES = demo/arg_parser_demo.cc
 
-##demo_dijkstra_demo_SOURCES = demo/dijkstra_demo.cc
+demo_csp_demo_SOURCES = demo/csp_demo.cc
 
-##demo_eps_demo_SOURCES = demo/eps_demo.cc
+demo_circulation_demo_SOURCES = demo/circulation_demo.cc
 
-##demo_reader_writer_demo_SOURCES = demo/reader_writer_demo.cc
+demo_dim_to_dot_SOURCES = demo/dim_to_dot.cc
 
-##demo_dim_to_lgf_SOURCES = demo/dim_to_lgf.cc
+demo_dijkstra_demo_SOURCES = demo/dijkstra_demo.cc
 
-##demo_coloring_SOURCES = demo/coloring.cc
+demo_eps_demo_SOURCES = demo/eps_demo.cc
 
-##demo_graph_to_eps_demo_SOURCES = demo/graph_to_eps_demo.cc
+demo_reader_writer_demo_SOURCES = demo/reader_writer_demo.cc
 
-##demo_grid_ugraph_demo_SOURCES = demo/grid_ugraph_demo.cc
+demo_coloring_SOURCES = demo/coloring.cc
 
-##demo_graph_orientation_SOURCES = demo/graph_orientation.cc
+demo_maps_summary_SOURCES = demo/maps_summary.cc
 
-##demo_min_route_SOURCES = demo/min_route.cc
+demo_graph_to_eps_demo_SOURCES = demo/graph_to_eps_demo.cc
 
-##demo_hello_lemon_SOURCES = demo/hello_lemon.cc
+demo_grid_ugraph_demo_SOURCES = demo/grid_ugraph_demo.cc
 
-##demo_sub_graph_adaptor_demo_SOURCES = \
-##	demo/sub_graph_adaptor_demo.cc \
-##	demo/tight_edge_filter_map.h
+demo_graph_orientation_SOURCES = demo/graph_orientation.cc
 
-##demo_lp_demo_SOURCES = demo/lp_demo.cc
-##demo_lp_demo_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS)
+demo_min_route_SOURCES = demo/min_route.cc
 
-##demo_lp_maxflow_demo_SOURCES = demo/lp_maxflow_demo.cc
-##demo_lp_maxflow_demo_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS)
+demo_hello_lemon_SOURCES = demo/hello_lemon.cc
 
-##demo_descriptor_map_demo_SOURCES = demo/descriptor_map_demo.cc
+demo_hello_world_SOURCES = demo/hello_world.cc
 
-##demo_topology_demo_SOURCES = demo/topology_demo.cc
+demo_sub_graph_adaptor_demo_SOURCES = \
+	demo/sub_graph_adaptor_demo.cc \
+	demo/tight_edge_filter_map.h
 
-##demo_simann_maxcut_demo_SOURCES = demo/simann_maxcut_demo.cc
+demo_lp_demo_SOURCES = demo/lp_demo.cc
+demo_lp_demo_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS)
 
-##demo_disjoint_paths_demo_SOURCES = demo/disjoint_paths_demo.cc
+demo_mip_demo_SOURCES = demo/mip_demo.cc
+demo_mip_demo_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS)
 
-##demo_strongly_connected_orientation_SOURCES = demo/strongly_connected_orientation.cc
+demo_lp_maxflow_demo_SOURCES = demo/lp_maxflow_demo.cc
+demo_lp_maxflow_demo_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS)
+
+demo_descriptor_map_demo_SOURCES = demo/descriptor_map_demo.cc
+
+demo_topology_demo_SOURCES = demo/topology_demo.cc
+
+demo_topological_ordering_SOURCES = demo/topological_ordering.cc
+
+demo_simann_maxcut_demo_SOURCES = demo/simann_maxcut_demo.cc
+
+demo_disjoint_paths_demo_SOURCES = demo/disjoint_paths_demo.cc
+
+demo_strongly_connected_orientation_SOURCES = demo/strongly_connected_orientation.cc
+
+demo_steiner_demo_SOURCES=demo/steiner_demo.cc
+
+demo_sat_2_SOURCES=demo/sat-2.cc
+
+demo_sat_SOURCES=demo/sat.cc
+demo_sat_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS)
Index: demo/arg_parser_demo.cc
===================================================================
--- demo/arg_parser_demo.cc	(revision 2553)
+++ demo/arg_parser_demo.cc	(revision 2553)
@@ -0,0 +1,79 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Argument parser demo
+///
+/// This example shows how can the argument parser used.
+///
+/// \include arg_parser.cc
+
+#include <lemon/arg_parser.h>
+
+using namespace lemon;
+int main(int argc, const char **argv)
+{
+  ArgParser ap(argc,argv);
+  int i;
+  std::string s;
+  double d;
+  bool b,sil;
+  bool g1,g2,g3;
+  ap.refOption("n", "an integer input", i, true)
+    .refOption("val", "a double input", d)
+    .synonym("vals","val")
+    .refOption("name", "a string input", s)
+    .refOption("f", "a switch", b)
+    .refOption("nohelp", "", sil)
+    .refOption("gra","Choise A",g1)
+    .refOption("grb","Choise B",g2)
+    .refOption("grc","Choise C",g3)
+    .optionGroup("gr","gra")
+    .optionGroup("gr","grb")
+    .optionGroup("gr","grc")
+    .mandatoryGroup("gr")
+    .onlyOneGroup("gr")
+    .other("infile","The input file")
+    .other("...");
+  
+  ap.parse();
+
+  std::cout << "Parameters of '" << ap.commandName() << "':\n";
+
+  if(ap.given("n")) std::cout << "  Value of -n: " << i << std::endl;
+  if(ap.given("val")) std::cout << "  Value of -val: " << d << std::endl;
+  if(ap.given("name")) std::cout << "  Value of -name: " << s << std::endl;
+  if(ap.given("f")) std::cout << "  -f is given\n";
+  if(ap.given("nohelp")) std::cout << "  Value of -nohelp: " << sil << std::endl;
+
+  switch(ap.files().size()) {
+  case 0:
+    std::cout << "  No file argument was given.\n";
+    break;
+  case 1:
+    std::cout << "  1 file argument was given. It is:\n";
+    break;
+  default:
+    std::cout << "  "
+	      << ap.files().size() << " file arguments were given. They are:\n";
+  }
+  for(unsigned int i=0;i<ap.files().size();++i)
+    std::cout << "    '" << ap.files()[i] << "'\n";
+  
+}
Index: demo/circulation-input.lgf
===================================================================
--- demo/circulation-input.lgf	(revision 2452)
+++ demo/circulation-input.lgf	(revision 2452)
@@ -0,0 +1,165 @@
+@nodeset 
+coordinates_x	coordinates_y	delta	label	
+-396.638	-311.798	0	0	
+154.409	-214.714	13	1	
+-378.119	-135.808	0	2	
+-138.182	-58.0452	0	3	
+55	-76.1018	0	4	
+-167.302	169.88	0	5	
+71.6876	38.7452	0	6	
+-328.784	257.777	0	7	
+354.242	67.9628	-13	8	
+147	266	0	9	
+@edgeset 
+		label	lo_cap	up_cap	
+0	1	0	0	20	
+0	2	1	0	0	
+1	1	2	0	3	
+1	2	3	0	8	
+1	3	4	0	8	
+2	5	5	0	5	
+3	2	6	0	5	
+3	5	7	0	5	
+3	6	8	0	5	
+4	3	9	0	3	
+5	7	10	0	3	
+5	6	11	0	10	
+5	8	12	0	10	
+6	8	13	0	8	
+8	9	14	0	20	
+8	1	15	0	5	
+9	5	16	0	5	
+@gui
+<arrow_pos>
+ <item>
+  <first>0</first>
+  <second>
+   <x>-121.114</x><y>-263.256</y>
+  </second>
+ </item>
+ <item>
+  <first>1</first>
+  <second>
+   <x>-387.378</x><y>-223.803</y>
+  </second>
+ </item>
+ <item>
+  <first>2</first>
+  <second>
+   <x>253.622</x><y>-301.284</y>
+  </second>
+ </item>
+ <item>
+  <first>3</first>
+  <second>
+   <x>-111.855</x><y>-175.261</y>
+  </second>
+ </item>
+ <item>
+  <first>4</first>
+  <second>
+   <x>8.1134</x><y>-136.379</y>
+  </second>
+ </item>
+ <item>
+  <first>5</first>
+  <second>
+   <x>-272.71</x><y>17.0361</y>
+  </second>
+ </item>
+ <item>
+  <first>6</first>
+  <second>
+   <x>-258.151</x><y>-96.9267</y>
+  </second>
+ </item>
+ <item>
+  <first>7</first>
+  <second>
+   <x>-152.742</x><y>55.9176</y>
+  </second>
+ </item>
+ <item>
+  <first>8</first>
+  <second>
+   <x>-33.2474</x><y>-9.64996</y>
+  </second>
+ </item>
+ <item>
+  <first>9</first>
+  <second>
+   <x>-41.5912</x><y>-67.0735</y>
+  </second>
+ </item>
+ <item>
+  <first>10</first>
+  <second>
+   <x>-248.043</x><y>213.829</y>
+  </second>
+ </item>
+ <item>
+  <first>11</first>
+  <second>
+   <x>-47.8072</x><y>104.313</y>
+  </second>
+ </item>
+ <item>
+  <first>12</first>
+  <second>
+   <x>93.4701</x><y>118.922</y>
+  </second>
+ </item>
+ <item>
+  <first>13</first>
+  <second>
+   <x>212.965</x><y>53.354</y>
+  </second>
+ </item>
+ <item>
+  <first>14</first>
+  <second>
+   <x>250.621</x><y>166.981</y>
+  </second>
+ </item>
+ <item>
+  <first>15</first>
+  <second>
+   <x>254.326</x><y>-73.3755</y>
+  </second>
+ </item>
+ <item>
+  <first>16</first>
+  <second>
+   <x>-10.1511</x><y>217.94</y>
+  </second>
+ </item>
+</arrow_pos>
+<active_nodemaps>
+ <item>
+  <first>0</first>
+  <second></second>
+ </item>
+ <item>
+  <first>1</first>
+  <second>delta</second>
+ </item>
+ <item>
+  <first>2</first>
+  <second>label</second>
+ </item>
+</active_nodemaps>
+<active_edgemaps>
+ <item>
+  <first>0</first>
+  <second>up_cap</second>
+ </item>
+ <item>
+  <first>1</first>
+  <second></second>
+ </item>
+ <item>
+  <first>2</first>
+  <second>up_cap</second>
+ </item>
+</active_edgemaps>
+@end
Index: demo/circulation_demo.cc
===================================================================
--- demo/circulation_demo.cc	(revision 2553)
+++ demo/circulation_demo.cc	(revision 2553)
@@ -0,0 +1,107 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Demonstrating the usage of LEMON's General Flow algorithm
+///
+/// This demo program reads a general network circulation problem from the
+/// file 'circulation-input.lgf', runs the preflow based algorithm for
+/// finding a feasible solution and writes the output
+/// to 'circulation-input.lgf'
+///
+/// \include circulation_demo.cc
+
+#include <iostream>
+
+#include <lemon/list_graph.h>
+#include <lemon/circulation.h>
+#include <lemon/graph_reader.h>
+#include <lemon/graph_writer.h>
+
+using namespace lemon;
+
+
+int main (int, char*[])
+{
+
+    typedef ListGraph Graph;
+    typedef Graph::Node Node;
+    typedef Graph::NodeIt NodeIt;
+    typedef Graph::Edge Edge;
+    typedef Graph::EdgeIt EdgeIt;
+    typedef Graph::EdgeMap<int> EdgeMap;
+    typedef Graph::NodeMap<int> NodeMap;
+    typedef Graph::NodeMap<double> DNodeMap;
+
+    Graph g;
+    EdgeMap lo(g);
+    EdgeMap up(g);
+    NodeMap delta(g);
+    NodeMap nid(g);
+    EdgeMap eid(g);
+    DNodeMap cx(g);
+    DNodeMap cy(g);
+    
+    GraphReader<Graph>("circulation-input.lgf", g).
+      readEdgeMap("lo_cap", lo).
+      readEdgeMap("up_cap", up).
+      readNodeMap("delta", delta).
+      readEdgeMap("label", eid).
+      readNodeMap("label", nid).
+      readNodeMap("coordinates_x", cx).
+      readNodeMap("coordinates_y", cy).
+      run();
+
+    Circulation<Graph> gen(g,lo,up,delta);
+    bool ret=gen.run();
+    if(ret)
+      {
+	std::cout << "\nA feasible flow has been found.\n";
+	if(!gen.checkFlow()) std::cerr << "Oops!!!\n";
+	GraphWriter<Graph>("circulation-output.lgf", g).
+	  writeEdgeMap("lo_cap", lo).
+	  writeEdgeMap("up_cap", up).
+	  writeEdgeMap("flow", gen.flowMap()).
+	  writeNodeMap("delta", delta).
+	  writeEdgeMap("label", eid).
+	  writeNodeMap("label", nid).
+	  writeNodeMap("coordinates_x", cx).
+	  writeNodeMap("coordinates_y", cy).
+	  run();
+      }
+    else {
+      std::cout << "\nThere is no such a flow\n";
+      Graph::NodeMap<int> bar(g);
+      gen.barrierMap(bar);
+      if(!gen.checkBarrier()) std::cerr << "Dual Oops!!!\n";
+
+      GraphWriter<Graph>("circulation-output.lgf", g).
+	writeEdgeMap("lo_cap", lo).
+	writeEdgeMap("up_cap", up).
+	writeNodeMap("barrier", bar).
+	writeNodeMap("delta", delta).
+	writeEdgeMap("label", eid).
+	writeNodeMap("label", nid).
+	writeNodeMap("coordinates_x", cx).
+	writeNodeMap("coordinates_y", cy).
+	run();
+    }
+  std::cout << "The output is written to file 'circulation-output.lgf'\n\n";
+    
+}
Index: demo/coloring.cc
===================================================================
--- demo/coloring.cc	(revision 2553)
+++ demo/coloring.cc	(revision 2553)
@@ -0,0 +1,109 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Coloring of a graph.
+///
+/// This example shows how can we color the nodes of a planar graph efficiently
+/// with six colors.
+///
+/// \include coloring.cc
+
+#include <vector>
+
+#include <iostream>
+
+#include <lemon/smart_graph.h>
+#include <lemon/bucket_heap.h>
+#include <lemon/graph_reader.h>
+#include <lemon/graph_to_eps.h>
+
+#include <fstream>
+
+
+using namespace std;
+using namespace lemon;
+
+int main() {
+
+  typedef SmartUGraph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::UEdge UEdge;
+  typedef Graph::IncEdgeIt IncEdgeIt;
+
+  std::cout << "Six coloring of a planar graph" << std::endl;
+  std::cout << "Input file: coloring.lgf" << std::endl;
+  std::cout << "Output file: coloring.eps" << std::endl;
+
+  Graph graph;
+
+  UGraphReader<Graph> reader("coloring.lgf", graph);
+  Graph::NodeMap<dim2::Point<double> > coords(graph);
+  reader.readNodeMap("coords", coords);
+  
+  reader.run();
+
+  Graph::NodeMap<int> color(graph, -2);
+  
+  Graph::NodeMap<int> heapMap(graph, -1);
+  BucketHeap<Graph::NodeMap<int> > heap(heapMap);
+  
+  for (NodeIt it(graph); it != INVALID; ++it) {
+    heap.push(it, countOutEdges(graph, it));
+  }
+
+  vector<Node> order;
+
+  while (!heap.empty()) {
+    Node node = heap.top();
+    heap.pop();
+    color[node] = -1;
+    order.push_back(node);
+    for (IncEdgeIt it(graph, node); it != INVALID; ++it) {
+      Node target = graph.runningNode(it); 
+      if (color[target] == -2) {
+	heap.decrease(target, heap[target] - 1);
+      }
+    }
+  }
+
+  for (int i = order.size() - 1; i >= 0; --i) {
+    set<int> forbidden;
+    for (IncEdgeIt it(graph, order[i]); it != INVALID; ++it) {
+      Node target = graph.runningNode(it); 
+      if (color[target] != -1) {
+	forbidden.insert(color[target]);
+      }
+    }
+    int current = 0;
+    while (forbidden.find(current) != forbidden.end()) ++current;
+    color[order[i]] = current;
+  }
+
+  Palette palette;
+
+  graphToEps(graph, "coloring.eps").
+    title("Six Colored Planar Graph").
+    copyright("(C) 2003-2007 LEMON Project").
+    coords(coords).nodeColors(composeMap(palette, color)).
+    nodeScale(5.0).scaleToA4().run();
+
+  return 0;
+}
Index: demo/coloring.lgf
===================================================================
--- demo/coloring.lgf	(revision 1909)
+++ demo/coloring.lgf	(revision 1909)
@@ -0,0 +1,36 @@
+@nodeset 
+coords	label	
+(162, 142)	10	
+(169, -35)	9	
+(-154, -37)	8	
+(-1, 12)	7	
+(-87, -197)	6	
+(360, 54)	5	
+(193, 257)	4	
+(-89, 224)	3	
+(-327, 46)	2	
+(157, -150)	1	
+(-282, -149)	0	
+@uedgeset 
+		label	
+9	10	17	
+1	9	15	
+3	9	14	
+2	8	4	
+6	8	1	
+0	8	0	
+8	7	7	
+0	6	2	
+9	5	16	
+4	5	13	
+1	5	12	
+10	4	18	
+3	4	11	
+10	3	19	
+7	3	10	
+1	3	6	
+2	3	3	
+0	2	5	
+7	1	9	
+6	1	8	
+@end
Index: demo/csp_demo.cc
===================================================================
--- demo/csp_demo.cc	(revision 2553)
+++ demo/csp_demo.cc	(revision 2553)
@@ -0,0 +1,80 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Demonstrating the usage of LEMON's algorithm for solving the
+/// Constrained shortest Path Problem 
+///
+/// \include csp_demo.cc
+
+#include <iostream>
+#include <lemon/list_graph.h>
+#include <lemon/csp.h>
+#include <lemon/random.h>
+
+
+using namespace lemon;
+
+
+int main (int, char*[])
+{
+
+    typedef ListGraph Graph;
+    typedef Graph::Node Node;
+    typedef Graph::Edge Edge;
+    typedef Graph::EdgeIt EdgeIt;
+    typedef Graph::EdgeMap<double> LengthMap;
+
+    Graph g;
+
+    const int N=100;
+    const int M=20000;
+    std::vector<Node> nodes;
+    std::vector<Edge> edges;
+    
+    for(int i=0;i<N;i++) nodes.push_back(g.addNode());
+
+    for(int i=0;i<M;i++)
+      edges.push_back(g.addEdge(nodes[rnd[N]],nodes[rnd[N]]));
+    
+    LengthMap cost(g);
+    LengthMap delay(g);
+    for(EdgeIt e(g);e!=INVALID;++e)
+      {
+	cost[e]=0.01+rnd(.99);
+	delay[e]=0.01+rnd(.99);
+      }
+    
+    ConstrainedShortestPath<Graph,LengthMap,LengthMap> csp(g,cost,delay);
+    for(double d=0;d<2;d+=.001)
+      {
+	double lo_bo;
+	std::cout << d << ": ";
+	SimplePath<Graph> r = csp.larac(nodes[0],nodes[1],d,lo_bo);
+	if(r.empty()) std::cout << "INFEASIBLE\n";
+	else std::cout << "delay: " << csp.delay(r)
+		       << " cost: " << csp.cost(r)
+		       << " (lb: " << lo_bo
+		       << " gap: " << csp.cost(r)-lo_bo
+		       << " , " << (csp.cost(r)-lo_bo)/csp.cost(r)*100
+		       << "%)" << std::endl;
+      }
+    			
+    return 0;
+}
Index: demo/descriptor_map_demo.cc
===================================================================
--- demo/descriptor_map_demo.cc	(revision 2569)
+++ demo/descriptor_map_demo.cc	(revision 2569)
@@ -0,0 +1,133 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup demos
+/// \file
+/// \brief Using descriptor map and own special map types.
+///
+/// This demo shows how can be used the DescriptorMap class
+/// which helps to use unique label for each node or edge.
+/// And it gives an example how easy is creating own map types.
+///
+/// \include descriptor_map_demo.cc
+
+#include <lemon/list_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/graph_writer.h>
+#include <lemon/dim2.h>
+#include <lemon/graph_to_eps.h>
+
+#include <lemon/random.h>
+
+#include <iostream>
+
+#include <lemon/math.h>
+
+
+using namespace lemon;
+
+// Special dim2::Point<double> map type 
+//
+// It gives back a position for each node. The position of the nodes
+// are on the circle with the given center and radius.
+//
+// Because we use the descriptor map it will hold the proprty
+// described above even if a node added or deleted.
+template <typename Graph>
+class CircleMap {
+public:
+
+  typedef dim2::Point<double> Value;
+  typedef typename Graph::Node Key;
+
+  CircleMap(const Graph& _graph, 
+	    const Value& _center = Value(0.0, 0.0), 
+	    double _radius = 1.0) 
+    : descriptor(_graph), center(_center), radius(_radius) {}
+
+  Value operator[](const Key& key) const {
+    double angle = descriptor[key] * 2 * PI 
+      / double(descriptor.inverse().size());
+    double x = std::cos(angle) * radius + center.x;
+    double y = std::sin(angle) * radius + center.y;
+    return Value(x, y);
+  }
+
+private:
+  
+  DescriptorMap<Graph, typename Graph::Node> descriptor;
+  Value center;
+  double radius;
+};
+
+int main() {
+  typedef ListGraph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::Edge Edge;
+  
+  // Generating a graph
+
+  std::cout << "Generating graph: " << std::endl;
+
+  Graph graph;
+  
+  const int NODE = 16;
+  for (int i = 0; i < NODE; ++i) {
+    graph.addNode();
+  } 
+
+  // Creating descriptor map and inverse
+  DescriptorMap<Graph, Node> nodeDesc(graph);
+  DescriptorMap<Graph, Node>::InverseMap nodeInv(nodeDesc);
+
+  // Adding edges
+  // The descriptor map always maps an integer value for each node.
+  // The range of the values is always [0..n - 1] where n is the
+  // number of the nodes of the graph. The inverse map gives back the
+  // the node by its descriptor value. 
+  //
+  // The inversemap cannot works without its DescriptorMap because
+  // it holds reference to it. 
+  const int EDGE = int(NODE * std::log(double(NODE)));
+  for (int i = 0; i < EDGE; ++i) {
+    int si = rnd[NODE];
+    int ti = rnd[NODE];
+      
+    graph.addEdge(nodeInv[si], nodeInv[ti]);
+  }
+
+  GraphWriter<Graph>(std::cout, graph).run();
+
+  std::cout << std::endl;
+  std::cout << "Postscript file: descriptor_map_demo.eps" << std::endl;
+
+  // Make postscript from the graph.
+    
+  CircleMap<Graph> coords(graph, dim2::Point<double>(0.0, 0.0), 10.0);
+    
+  graphToEps(graph,"descriptor_map_demo.eps").scaleToA4().
+    title("Generated graph").
+    copyright("(C) 2003-2007 LEMON Project").
+    coords(coords).
+    nodeScale(1.0).
+    enableParallel().parEdgeDist(1).
+    drawArrows().arrowWidth(1).arrowLength(1).
+    run();
+ 
+  return 0;
+}
Index: demo/dijkstra_demo.cc
===================================================================
--- demo/dijkstra_demo.cc	(revision 2553)
+++ demo/dijkstra_demo.cc	(revision 2553)
@@ -0,0 +1,106 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Demonstrating the usage of LEMON's Dijkstra algorithm
+///
+/// Dijkstra's algorithm computes shortest paths between two nodes in
+/// a graph with edge lengths. Here we only show some of the
+/// facilities supplied by our implementation: for the detailed
+/// documentation of the LEMON Dijkstra class read \ref lemon::Dijkstra "this".
+///
+/// \include dijkstra_demo.cc
+
+#include <iostream>
+
+#include <lemon/list_graph.h>
+#include <lemon/dijkstra.h>
+
+using namespace lemon;
+
+
+int main (int, char*[])
+{
+
+    typedef ListGraph Graph;
+    typedef Graph::Node Node;
+    typedef Graph::Edge Edge;
+    typedef Graph::EdgeMap<int> LengthMap;
+
+    Graph g;
+
+    //An example from Ahuja's book
+
+    Node s=g.addNode();
+    Node v2=g.addNode();
+    Node v3=g.addNode();
+    Node v4=g.addNode();
+    Node v5=g.addNode();
+    Node t=g.addNode();
+
+    Edge s_v2=g.addEdge(s, v2);
+    Edge s_v3=g.addEdge(s, v3);
+    Edge v2_v4=g.addEdge(v2, v4);
+    Edge v2_v5=g.addEdge(v2, v5);
+    Edge v3_v5=g.addEdge(v3, v5);
+    Edge v4_t=g.addEdge(v4, t);
+    Edge v5_t=g.addEdge(v5, t);
+  
+    LengthMap len(g);
+
+    len.set(s_v2, 10);
+    len.set(s_v3, 10);
+    len.set(v2_v4, 5);
+    len.set(v2_v5, 8);
+    len.set(v3_v5, 5);
+    len.set(v4_t, 8);
+    len.set(v5_t, 8);
+
+    std::cout << "This program is a simple demo of the LEMON Dijkstra class."
+	      << std::endl;
+    std::cout <<
+      "We calculate the shortest path from node s to node t in a graph."
+	      << std::endl;
+    std::cout << std::endl;
+
+
+    std::cout << "The id of s is " << g.id(s)<< ", the id of t is "
+	      << g.id(t) << "." << std::endl;
+
+    std::cout << "Dijkstra algorithm demo..." << std::endl;
+
+    Dijkstra<Graph, LengthMap> dijkstra_test(g,len);
+    
+    dijkstra_test.run(s);
+    
+    std::cout << "The distance of node t from node s: "
+	      << dijkstra_test.dist(t) << std::endl;
+
+    std::cout << "The shortest path from s to t goes through the following "
+	      << "nodes (the first one is t, the last one is s): "
+	      << std::endl;
+
+    for (Node v=t;v != s; v=dijkstra_test.predNode(v)) {
+      std::cout << g.id(v) << "<-";
+    }
+    
+    std::cout << g.id(s) << std::endl;	
+    
+    return 0;
+}
Index: demo/dim_to_dot.cc
===================================================================
--- demo/dim_to_dot.cc	(revision 2553)
+++ demo/dim_to_dot.cc	(revision 2553)
@@ -0,0 +1,92 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\file
+///\brief Dim (DIMACS) to Dot (Graphviz) converter
+///
+/// This program can convert the DIMACS format to Graphviz format.
+///
+/// <tt>dim_to_dot dimacs_max_flow_file > dot_output_file</tt>
+///
+/// This program makes a dot file from a DIMACS max flow file. 
+/// This program can be an aid in making up to date visualized 
+/// documantation of demo programs.
+///
+/// \include dim_to_dot.cc
+
+#include <iostream>
+#include <fstream>
+
+#include <lemon/smart_graph.h>
+#include <lemon/dimacs.h>
+
+using namespace lemon;
+
+using std::cout;
+using std::endl;
+
+int main(int argc, char *argv[]) 
+{
+  if(argc<2)
+  {
+      std::cerr << "USAGE: dim_to_dot input_file.dim" << std::endl;
+      std::cerr << "The file 'input_file.dim' has to contain a max flow instance in DIMACS format (e.g. sub_graph_adaptor_demo.dim is such a file)." << std::endl;
+      return 0;
+  }
+
+  //input stream to read the graph from
+  std::ifstream is(argv[1]);
+
+  typedef SmartGraph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeMap<int> LengthMap;
+
+  Graph g;
+  Node s, t;
+  LengthMap length(g);
+
+  readDimacs(is, g, length, s, t);
+
+  cout << "digraph lemon_dot_example {" << endl;
+  cout << "  node [ shape=ellipse, fontname=Helvetica, fontsize=10 ];" << endl;
+  for(NodeIt n(g); n!=INVALID; ++n) {
+    if (n==s) {
+      cout << "  n" << g.id(n) 
+	   << " [ label=\"" << g.id(n) << " (s)\" ]; " << endl;
+    } else {
+      if (n==t) {
+	cout << "  n" << g.id(n) 
+	     << " [ label=\"" << g.id(n) << " (t)\" ]; " << endl; 
+      } else {
+	cout << "  n" << g.id(n) 
+	     << " [ label=\"" << g.id(n) << "\" ]; " << endl; 
+      }
+    }
+  }
+  cout << "  edge [ shape=ellipse, fontname=Helvetica, fontsize=10 ];" << endl;
+  for(EdgeIt e(g); e!=INVALID; ++e) {
+    cout << "  n" << g.id(g.source(e)) << " -> " << " n" << g.id(g.target(e))
+	 << " [ label=\"" << g.id(e) 
+	 << ", length:" << length[e] << "\" ]; " << endl;
+  } 
+  cout << "}" << endl;
+}
Index: demo/dir_components.lgf
===================================================================
--- demo/dir_components.lgf	(revision 1901)
+++ demo/dir_components.lgf	(revision 1901)
@@ -0,0 +1,52 @@
+@nodeset 
+coordinates_x	coordinates_y	label	
+218.178	27.2723	19	
+157.79	-130.517	18	
+44.8044	15.5841	17	
+-465.576	-42.8564	16	
+-675.963	-3.89604	15	
+-574.666	-153.893	14	
+-490.901	120.777	13	
+-368.176	331.163	12	
+-266.879	114.933	11	
+-251.294	-335.059	10	
+-173.374	377.916	9	
+169.478	311.683	8	
+5.84406	175.322	7	
+342.851	111.037	6	
+670.118	-118.829	5	
+364.28	-222.074	4	
+-105.193	-261.035	3	
+-227.918	-40.9084	2	
+-389.604	-136.361	1	
+@edgeset 
+		label	
+17	19	23	
+19	18	24	
+18	17	25	
+3	17	21	
+14	16	18	
+13	16	17	
+16	15	19	
+15	14	20	
+11	13	15	
+13	12	16	
+12	11	14	
+1	10	1	
+11	9	13	
+7	9	12	
+6	8	10	
+8	7	11	
+7	6	9	
+4	6	6	
+6	5	7	
+19	4	22	
+5	4	8	
+3	4	5	
+10	3	2	
+3	2	3	
+2	1	4	
+@nodes 
+@edges 
+@attributes 
+@end
Index: demo/disjoint_paths_demo.cc
===================================================================
--- demo/disjoint_paths_demo.cc	(revision 2553)
+++ demo/disjoint_paths_demo.cc	(revision 2553)
@@ -0,0 +1,111 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup demos
+/// \file
+/// \brief Node and edge disjoint paths in directed graph.
+///
+/// This demo program calculates how many edge disjoint and node disjoint
+/// paths are in a directed graph between a source and a target node.
+/// The edge disjoint paths can be computed with a flow algorithm,
+/// in this example we use the Preflow algorithm class. To get the node
+/// disjoint paths we should first adapt the graph with the SplitGraphAdaptor
+/// and just then calculate the flow.  
+///
+/// \include disjoint_paths_demo.cc
+
+#include <iostream>
+
+#include <lemon/smart_graph.h>
+#include <lemon/graph_adaptor.h>
+#include <lemon/graph_reader.h>
+#include <lemon/preflow.h>
+#include <lemon/graph_to_eps.h>
+
+using namespace lemon;
+using namespace std;
+
+Color color(bool b) {
+  return b ? RED : BLACK;
+}
+
+int main() {
+  cout << "This program calculates the number " 
+    "disjoint paths in a graph" << endl;
+  cout << "The graph is read from the disjoint_paths_demo.lgf file" << endl;
+  typedef SmartGraph Graph;
+
+  Graph graph;
+
+  Graph::NodeMap<dim2::Point<double> > coords(graph);
+  Graph::Node source, target;
+  GraphReader<Graph>("disjoint_paths_demo.lgf", graph).
+    readNodeMap("coords", coords).
+    readNode("source", source).readNode("target", target).run();
+
+  typedef ConstMap<Graph::Edge, int> Capacity;
+  Capacity capacity(1);
+
+  Graph::EdgeMap<int> flow(graph);
+
+  Preflow<Graph, Capacity> preflow(graph, capacity, source, target); 
+  
+  preflow.run();
+
+  cout << "Number of edge disjoint paths: " << preflow.flowValue() << endl;
+
+  graphToEps(graph, "edge_disjoint_paths.eps").
+    title("edge disjoint paths").scaleToA4().
+    copyright("(C) 2003-2007 LEMON Project").drawArrows().
+    edgeColors(composeMap(functorMap(color), preflow.flowMap())).
+    coords(coords).run();
+
+
+  cout << "The paths are written into edge_disjoint_paths.eps" << endl;
+
+  typedef SplitGraphAdaptor<SmartGraph> SGraph;
+
+  SGraph sgraph(graph);
+
+  typedef ConstMap<SGraph::Edge, int> SCapacity;
+  SCapacity scapacity(1);
+
+  SGraph::EdgeMap<int> sflow(sgraph);
+
+  Preflow<SGraph, SCapacity> spreflow(sgraph, scapacity, 
+				      SGraph::outNode(source), 
+				      SGraph::inNode(target));
+
+  spreflow.run();
+
+  cout << "Number of node disjoint paths: " << spreflow.flowValue() << endl;
+
+
+  graphToEps(sgraph, "node_disjoint_paths.eps").
+    title("node disjoint paths").scaleToA4().
+    copyright("(C) 2003-2007 LEMON Project").drawArrows().
+    edgeColors(composeMap(functorMap(color), spreflow.flowMap())).
+    coords(SGraph::combinedNodeMap(coords,
+				   shiftMap(coords,
+					    dim2::Point<double>(5, 0)))).
+    run();
+
+  cout << "The paths are written into node_disjoint_paths.eps" << endl;
+  
+  return 0;
+}
Index: demo/disjoint_paths_demo.lgf
===================================================================
--- demo/disjoint_paths_demo.lgf	(revision 2084)
+++ demo/disjoint_paths_demo.lgf	(revision 2084)
@@ -0,0 +1,46 @@
+@nodeset 
+coords	label	
+(-20,17)	15	
+(39,13) 	14	
+(39,-11)	13	
+(-12,7)	        12	
+(25,-15)        11	
+(-18,-14)	10	
+(45,3)          9	
+(28,13)         8	
+(25,-5)         7	
+(1,21)          6	
+(3,3)           5	
+(3,-9)          4	
+(-9,15)         3	
+(-13,-4)        2	
+(-27,5)         1	
+@edgeset 
+		label	
+1	15	22	
+8	14	20	
+11	13	18	
+1	12	8	
+4	11	14	
+1	10	1	
+14	9	21	
+13	9	19	
+8	9	17	
+7	9	16	
+11	9	15	
+5	8	12	
+6	8	11	
+5	7	13	
+3	6	4	
+12	5	9	
+2	5	6	
+3	5	5	
+2	4	10	
+10	4	7	
+15	3	23	
+1	3	3	
+1	2	2	
+@nodes
+source 1
+target 9
+@end
Index: demo/eps_demo.cc
===================================================================
--- demo/eps_demo.cc	(revision 2569)
+++ demo/eps_demo.cc	(revision 2569)
@@ -0,0 +1,115 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup demos
+/// \file
+/// \brief Demo of the EPS grawing class \ref lemon::EpsDrawer "EpsDrawer".
+///
+/// This demo program shows examples how to use the class \ref
+/// lemon::EpsDrawer "EpsDrawer". It takes no input but simply creates
+/// a file <tt>eps_demo.eps</tt> demonstrating the capability of \ref
+/// lemon::EpsDrawer "EpsDrawer".
+///
+/// \include eps_demo.cc
+
+#include <lemon/math.h>
+#include <lemon/eps.h>
+
+using namespace lemon;
+
+void kosar(EpsDrawer &ed)
+{
+  double d,r;
+  
+  r = sqrt(2);
+  
+  ed.save();
+  
+  ed.translate(256,256).scale(256,256);
+  ed.lineWidth(1/256);
+  
+  ed.collect();
+  
+  ed.moveTo(0,1);
+  
+  for(d=0;d<PI*2*5;d+=.1)
+    {
+      ed.lineTo(sin(d*3),cos(d*5));
+    }
+  
+  ed.stroke();
+  ed.restore();
+  
+}
+
+void fonts(EpsDrawer &ed)
+{
+  ed.save().centerMode(true);
+  
+  ed.font("Helvetica").fontSize(90);
+  ed.moveTo(256,512/3*2+50) << "Helvetica";
+  ed.font("Courier");
+  ed.moveTo(256,512/3+50) << "Courier" ;
+  ed.font("Times-Roman");
+  ed.moveTo(256,50) << "Times-Roman";
+  
+  ed.centerMode(false).restore();
+}
+
+int main()
+{
+
+  EpsDrawer ed("eps_demo.eps",512,512);
+  ed.scale(1,1);
+  
+  ed.color(0,0,0).collect();
+  ed.moveTo(0,0).lineTo(0,512).lineTo(512,512).lineTo(512,0).closePath().fill();
+  
+  ed.lineWidth(4);
+  
+  for(double r=0;r<=256;r+=2)
+    {
+      ed.color(r/256.0,0,1-r/256.0).circle(256,256,r);
+    }
+  
+  
+  ed.save();
+  ed.color(0,0,0);
+  ed.translate(256,256);
+  
+  for(int i=0;i<18;i++)
+    {
+      ed.rotate(20);
+      
+      for(double r=0;r<=256;r+=20)
+	ed.fontSize(r/10+1).rotate(2).moveTo(0,r) << r;
+      ed.rotate(-26);
+      
+    }
+  
+  ed.restore();
+  
+  fonts(ed.color(.7,.7,.7));
+  ed.color(0,1,0);
+
+  ed.node(ed.CIRCLE,128,333,25);
+  ed.node(ed.SQUARE,256,333,25);
+  ed.node(ed.DIAMOND,128+256,333,25);
+
+  kosar(ed);
+}
Index: demo/graph_orientation.cc
===================================================================
--- demo/graph_orientation.cc	(revision 2553)
+++ demo/graph_orientation.cc	(revision 2553)
@@ -0,0 +1,120 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/list_graph.h>
+#include <lemon/graph_reader.h>
+#include <lemon/iterable_maps.h>
+#include <lemon/dim2.h>
+#include <lemon/graph_to_eps.h>
+
+
+using namespace lemon;
+ 
+GRAPH_TYPEDEFS(ListGraph);
+
+int main(int argc, char** argv) 
+{
+  if(argc!=2) {
+    std::cerr << "\n  USAGE: " << argv[0]
+	      << " input_file.lgf" << std::endl << std::endl;
+    std::cerr << "  The file 'input_file.lgf' has to contain "
+	      << "at least three node maps called \n  'f', 'coordinates_x' "
+	      << "and 'coordinates_y'.\n"
+	      << "  The in-degree requirement is given by 'f', while the two "
+	      << "others is used\n  to create to output drawing."
+	      << std::endl;
+    return 1;
+  }
+  
+  ListGraph g;
+
+  ListGraph::NodeMap<int> f(g); //in-deg requirement;
+  ListGraph::NodeMap<int> label(g);
+  ListGraph::NodeMap<dim2::Point<double> > coords(g);
+  
+  try {
+    GraphReader<ListGraph> reader(argv[1],g);
+    reader.readNodeMap("f",f);
+    reader.readNodeMap("label",label);
+    reader.readNodeMap("coordinates_x",xMap(coords));
+    reader.readNodeMap("coordinates_y",yMap(coords));
+    reader.run();
+  } catch (DataFormatError& error) {
+    std::cerr << error.what() << std::endl;
+    return 1;
+  }
+
+  
+  ListGraph::NodeMap<int> level(g,0);
+  
+  ListGraph::NodeMap<int> def(g); //deficiency of the nodes
+  def = subMap(f,InDegMap<ListGraph>(g));
+  
+  IterableBoolMap<ListGraph, Node> active(g,false);
+  for(NodeIt n(g);n!=INVALID;++n) active[n]=(def[n]>0);
+  
+  ListGraph::EdgeMap<bool> rev(g,false); // rev[e]==true <=> e is to be 
+                                         //                  reversed
+
+  int nodeNum=countNodes(g);
+  
+  Node act;
+  while((act=IterableBoolMap<ListGraph, Node>::TrueIt(active))!=INVALID) {
+    std::cout << "Process node " << label[act]
+	      << " (def=" << def[act]
+	      << " lev=" << level[act] << "): ";
+    OutEdgeIt e(g,act);
+    while(e!=INVALID && level[g.target(e)]>=level[act]) ++e;
+    if(e!=INVALID) {
+      std::cout << " REVERT EDGE " << g.id(e)
+		<< " (" << label[g.source(e)] << "---"
+		<< label[g.target(e)] << ")"
+		<< std::endl;
+      if(--def[act]==0) active[act]=false;
+      if(++def[g.target(e)]>0) active[g.target(e)]=true;
+      g.reverseEdge(e);
+      rev[e]=!rev[e];
+    }
+    else {
+      std::cout << " LIFT" << std::endl;
+      if(++level[act]>nodeNum) {
+	std::cout << "NINCS ILYEN\n";
+	return 1;
+      }
+    }
+  }
+  
+  //Show the graph
+
+  graphToEps(g,"graph_orientation.eps").scaleToA4().
+    title("Sample .eps figure (fits to A4)").
+    copyright("(C) 2003-2007 LEMON Project").
+    absoluteNodeSizes().absoluteEdgeWidths().
+    nodeScale(15).
+    coords(coords).
+    negateY().
+    edgeColors(composeMap(Palette(),rev)).
+    edgeWidthScale(1).
+    nodeTexts(f).nodeTextSize(20).
+    drawArrows().arrowWidth(10).arrowLength(10).
+    run();
+
+  
+} //end of main()
+
+
Index: demo/graph_orientation.lgf
===================================================================
--- demo/graph_orientation.lgf	(revision 1901)
+++ demo/graph_orientation.lgf	(revision 1901)
@@ -0,0 +1,27 @@
+@nodeset 
+coordinates_x	coordinates_y	f	label	
+-198	-73	2	7	
+120	30	4	6	
+-17	222	1	5	
+328	147	1	4	
+247	-179	0	3	
+-28	-93	1	2	
+-131	83	3	1	
+@edgeset 
+		label	
+7	6	3	
+1	6	2	
+2	6	1	
+4	5	10	
+6	5	6	
+3	4	9	
+6	4	7	
+2	3	12	
+6	3	8	
+7	2	4	
+5	1	11	
+7	1	5	
+@nodes 
+@edges 
+@attributes 
+@end
Index: demo/graph_to_eps_demo.cc
===================================================================
--- demo/graph_to_eps_demo.cc	(revision 2569)
+++ demo/graph_to_eps_demo.cc	(revision 2569)
@@ -0,0 +1,208 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup demos
+/// \file
+/// \brief Demo of the graph grawing function \ref graphToEps()
+///
+/// This demo program shows examples how to  use the function \ref
+/// graphToEps(). It takes no input but simply creates  six
+/// <tt>.eps</tt> files demonstrating the capability of \ref
+/// graphToEps(), and showing how to draw directed/undirected graphs,
+/// how to handle parallel egdes, how to change the properties (like
+/// color, shape, size, title etc.) of nodes and edges individually
+/// using appropriate \ref maps-page "graph maps".
+///
+/// \include graph_to_eps_demo.cc
+
+#include <lemon/math.h>
+
+#include<lemon/graph_to_eps.h>
+#include<lemon/list_graph.h>
+#include<lemon/graph_utils.h>
+
+using namespace std;
+using namespace lemon;
+
+int main()
+{
+  Palette palette;
+  Palette paletteW(true);
+
+  ListGraph g;
+  typedef ListGraph::Node Node;
+  typedef ListGraph::NodeIt NodeIt;
+  typedef ListGraph::Edge Edge;
+  typedef dim2::Point<int> Point;
+  
+  Node n1=g.addNode();
+  Node n2=g.addNode();
+  Node n3=g.addNode();
+  Node n4=g.addNode();
+  Node n5=g.addNode();
+
+  ListGraph::NodeMap<Point> coords(g);
+  ListGraph::NodeMap<double> sizes(g);
+  ListGraph::NodeMap<int> colors(g);
+  ListGraph::NodeMap<int> shapes(g);
+  ListGraph::EdgeMap<int> ecolors(g);
+  ListGraph::EdgeMap<int> widths(g);
+  
+  coords[n1]=Point(50,50);  sizes[n1]=1; colors[n1]=1; shapes[n1]=0;
+  coords[n2]=Point(50,70);  sizes[n2]=2; colors[n2]=2; shapes[n2]=2;
+  coords[n3]=Point(70,70);  sizes[n3]=1; colors[n3]=3; shapes[n3]=0;
+  coords[n4]=Point(70,50);  sizes[n4]=2; colors[n4]=4; shapes[n4]=1;
+  coords[n5]=Point(85,60);  sizes[n5]=3; colors[n5]=5; shapes[n5]=2;
+  
+  Edge e;
+
+  e=g.addEdge(n1,n2); ecolors[e]=0; widths[e]=1;
+  e=g.addEdge(n2,n3); ecolors[e]=0; widths[e]=1;
+  e=g.addEdge(n3,n5); ecolors[e]=0; widths[e]=3;
+  e=g.addEdge(n5,n4); ecolors[e]=0; widths[e]=1;
+  e=g.addEdge(n4,n1); ecolors[e]=0; widths[e]=1;
+  e=g.addEdge(n2,n4); ecolors[e]=1; widths[e]=2;
+  e=g.addEdge(n3,n4); ecolors[e]=2; widths[e]=1;
+  
+  IdMap<ListGraph,Node> id(g);
+
+  cout << "Create 'graph_to_eps_demo_out_pure.eps'" << endl;
+  graphToEps(g,"graph_to_eps_demo_out_pure.eps").
+    //scale(10).
+    coords(coords).
+    title("Sample .eps figure").
+    copyright("(C) 2003-2007 LEMON Project").
+    run();
+
+  cout << "Create 'graph_to_eps_demo_out.eps'" << endl;
+  graphToEps(g,"graph_to_eps_demo_out.eps").
+    //scale(10).
+    coords(coords).
+    title("Sample .eps figure").
+    copyright("(C) 2003-2007 LEMON Project").
+    absoluteNodeSizes().absoluteEdgeWidths().
+    nodeScale(2).nodeSizes(sizes).
+    nodeShapes(shapes).
+    nodeColors(composeMap(palette,colors)).
+    edgeColors(composeMap(palette,ecolors)).
+    edgeWidthScale(.4).edgeWidths(widths).
+    nodeTexts(id).nodeTextSize(3).
+    run();
+
+
+  cout << "Create 'graph_to_eps_demo_out_arr.eps'" << endl;
+  graphToEps(g,"graph_to_eps_demo_out_arr.eps").
+    //scale(10).
+    title("Sample .eps figure (with arrowheads)").
+    copyright("(C) 2003-2007 LEMON Project").
+    absoluteNodeSizes().absoluteEdgeWidths().
+    nodeColors(composeMap(palette,colors)).
+    coords(coords).
+    nodeScale(2).nodeSizes(sizes).
+    nodeShapes(shapes).
+    edgeColors(composeMap(palette,ecolors)).
+    edgeWidthScale(.4).edgeWidths(widths).
+    nodeTexts(id).nodeTextSize(3).
+    drawArrows().arrowWidth(1).arrowLength(1).
+    run();
+
+  e=g.addEdge(n1,n4); ecolors[e]=2; widths[e]=1;
+  e=g.addEdge(n4,n1); ecolors[e]=1; widths[e]=2;
+
+  e=g.addEdge(n1,n2); ecolors[e]=1; widths[e]=1;
+  e=g.addEdge(n1,n2); ecolors[e]=2; widths[e]=1;
+  e=g.addEdge(n1,n2); ecolors[e]=3; widths[e]=1;
+  e=g.addEdge(n1,n2); ecolors[e]=4; widths[e]=1;
+  e=g.addEdge(n1,n2); ecolors[e]=5; widths[e]=1;
+  e=g.addEdge(n1,n2); ecolors[e]=6; widths[e]=1;
+  e=g.addEdge(n1,n2); ecolors[e]=7; widths[e]=1;
+
+  cout << "Create 'graph_to_eps_demo_out_par.eps'" << endl;
+  graphToEps(g,"graph_to_eps_demo_out_par.eps").
+    //scale(10).
+    title("Sample .eps figure (parallel edges)").
+    copyright("(C) 2003-2007 LEMON Project").
+    absoluteNodeSizes().absoluteEdgeWidths().
+    nodeShapes(shapes).
+    coords(coords).
+    nodeScale(2).nodeSizes(sizes).
+    nodeColors(composeMap(palette,colors)).
+    edgeColors(composeMap(palette,ecolors)).
+    edgeWidthScale(.4).edgeWidths(widths).
+    nodeTexts(id).nodeTextSize(3).
+    enableParallel().parEdgeDist(1.5).
+    run();
+  
+  cout << "Create 'graph_to_eps_demo_out_par_arr.eps'" << endl;
+  graphToEps(g,"graph_to_eps_demo_out_par_arr.eps").
+    //scale(10).
+    title("Sample .eps figure (parallel edges and arrowheads)").
+    copyright("(C) 2003-2007 LEMON Project").
+    absoluteNodeSizes().absoluteEdgeWidths().
+    nodeScale(2).nodeSizes(sizes).
+    coords(coords).
+    nodeShapes(shapes).
+    nodeColors(composeMap(palette,colors)).
+    edgeColors(composeMap(palette,ecolors)).
+    edgeWidthScale(.3).edgeWidths(widths).
+    nodeTexts(id).nodeTextSize(3).
+    enableParallel().parEdgeDist(1).
+    drawArrows().arrowWidth(1).arrowLength(1).
+    run();
+
+  cout << "Create 'graph_to_eps_demo_out_a4.eps'" << endl;
+  graphToEps(g,"graph_to_eps_demo_out_a4.eps").scaleToA4().
+    title("Sample .eps figure (fits to A4)").
+    copyright("(C) 2003-2007 LEMON Project").
+    absoluteNodeSizes().absoluteEdgeWidths().
+    nodeScale(2).nodeSizes(sizes).
+    coords(coords).
+    nodeShapes(shapes).
+    nodeColors(composeMap(palette,colors)).
+    edgeColors(composeMap(palette,ecolors)).
+    edgeWidthScale(.3).edgeWidths(widths).
+    nodeTexts(id).nodeTextSize(3).
+    enableParallel().parEdgeDist(1).
+    drawArrows().arrowWidth(1).arrowLength(1).
+    run();
+
+  ListGraph h;
+  ListGraph::NodeMap<int> hcolors(h);
+  ListGraph::NodeMap<Point> hcoords(h);
+  
+  int cols=int(sqrt(double(palette.size())));
+  for(int i=0;i<int(paletteW.size());i++) {
+    Node n=h.addNode();
+    hcoords[n]=Point(i%cols,i/cols);
+    hcolors[n]=i;
+  }
+  
+  cout << "Create 'graph_to_eps_demo_out_colors.eps'" << endl;
+  graphToEps(h,"graph_to_eps_demo_out_colors.eps").
+    //scale(60).
+    title("Sample .eps figure (Palette demo)").
+    copyright("(C) 2003-2007 LEMON Project").
+    coords(hcoords).
+    absoluteNodeSizes().absoluteEdgeWidths().
+    nodeScale(45).
+    distantColorNodeTexts().
+    //    distantBWNodeTexts().
+    nodeTexts(hcolors).nodeTextSize(.6).
+    nodeColors(composeMap(paletteW,hcolors)).
+    run();
+}
Index: demo/grid_ugraph_demo.cc
===================================================================
--- demo/grid_ugraph_demo.cc	(revision 2553)
+++ demo/grid_ugraph_demo.cc	(revision 2553)
@@ -0,0 +1,102 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/grid_ugraph.h>
+#include <lemon/graph_adaptor.h>
+#include <lemon/graph_to_eps.h>
+#include <lemon/bfs.h>
+#include <lemon/dim2.h>
+
+#include <iostream>
+#include <fstream>
+
+///\ingroup demos
+///\file
+///\brief Labirinth example with grid ugraph.
+///
+///  Labirinth example with grid ugraph.
+///
+/// The input file is:
+///
+/// \include grid_ugraph_demo.in
+///
+/// The result:
+///
+/// \image html grid_ugraph_demo.png
+/// \image latex grid_ugraph_demo.eps "The labirinth" width=\textwidth
+///
+/// The source:
+///
+/// \include grid_ugraph_demo.cc
+
+using namespace lemon;
+using namespace std;
+
+int main() {
+  ifstream in("grid_ugraph_demo.in");
+  int width, height;
+  in >> width >> height;
+  int start_x, start_y;
+  in >> start_x >> start_y;
+  int stop_x, stop_y;
+  in >> stop_x >> stop_y;
+
+  GridUGraph ugraph(width, height);
+  GridUGraph::Node start = ugraph(start_x - 1, start_y - 1);
+  GridUGraph::Node stop = ugraph(stop_x - 1, stop_y - 1);
+  GridUGraph::NodeMap<bool> filter(ugraph);
+
+  for (int j = 0; j < height; ++j) {
+    in >> ws;
+    for (int i = 0; i < width; ++i) {
+      char c; in >> c;
+      filter[ugraph(i, j)] = (c == '.');
+    }
+  }
+
+  typedef NodeSubGraphAdaptor<GridUGraph,
+    GridUGraph::NodeMap<bool> > FilteredGraph;
+
+  FilteredGraph filtered(ugraph, filter);
+
+  Bfs<FilteredGraph> bfs(filtered);
+  std::cout << "The length of shortest path: " << 
+    bfs.run(start, stop) << std::endl;
+
+  FilteredGraph::EdgeMap<bool> path(filtered, false);
+  
+  for (GridUGraph::Node node = stop; 
+       node != start; node = bfs.predNode(node)) {
+    path[bfs.predEdge(node)] = true;
+  }
+  
+  graphToEps(filtered, "grid_ugraph_demo.eps").scaleToA4().
+    title("Grid ugraph").
+    copyright("(C) 2003-2007 LEMON Project").
+    coords(scaleMap(indexMap(ugraph), 10)).
+    enableParallel().
+    nodeScale(0.5).
+    drawArrows().
+    edgeColors(composeMap(Palette(), path)).
+    run();
+  
+  std::cout << "The shortest path is written to grid_ugraph_demo.eps" 
+	    << std::endl;
+
+  return 0;
+}
Index: demo/grid_ugraph_demo.in
===================================================================
--- demo/grid_ugraph_demo.in	(revision 1979)
+++ demo/grid_ugraph_demo.in	(revision 1979)
@@ -0,0 +1,10 @@
+10 8
+1 1 10 8
+..X....X.X
+.XX.X.XX..
+....X..XX.
+XXXXXX.X..
+.........X
+.X.XXXXXXX
+.X...XX...
+.X.X....X.
Index: demo/hello_lemon.cc
===================================================================
--- demo/hello_lemon.cc	(revision 2553)
+++ demo/hello_lemon.cc	(revision 2553)
@@ -0,0 +1,93 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief LEMON style "Hello World!" program
+///
+/// This program is intended to be a "Hello World!" program that shows
+/// the very basic notions of the LEMON library: \ref graphs "graphs" and
+/// \ref maps-page "maps". Click on the links to read more about these.
+///
+/// \include hello_lemon.cc
+
+#include <iostream>
+#include <lemon/list_graph.h>
+
+int main()
+{
+  typedef lemon::ListGraph Graph;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::Edge Edge;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeMap<int> LengthMap;
+  using lemon::INVALID;
+
+  Graph g;
+  
+  Node s=g.addNode();
+  Node v2=g.addNode();
+  Node v3=g.addNode();
+  Node v4=g.addNode();
+  Node v5=g.addNode();
+  Node t=g.addNode();
+
+  Edge s_v2=g.addEdge(s, v2);
+  Edge s_v3=g.addEdge(s, v3);
+  Edge v2_v4=g.addEdge(v2, v4);
+  Edge v2_v5=g.addEdge(v2, v5);
+  Edge v3_v5=g.addEdge(v3, v5);
+  Edge v4_t=g.addEdge(v4, t);
+  Edge v5_t=g.addEdge(v5, t);
+  
+  LengthMap length(g);
+
+  length[s_v2]=10;
+  length[s_v3]=10;
+  length[v2_v4]=5;
+  length[v2_v5]=8;
+  length[v3_v5]=5;
+  length[v4_t]=8;
+  length[v5_t]=8;
+
+  std::cout << "Hello World!" << std::endl;
+  std::cout <<  std::endl;
+  std::cout << "This is library LEMON here! We have a graph!" << std::endl;
+  std::cout <<  std::endl;
+
+  std::cout << "Nodes:";
+  for (NodeIt i(g); i!=INVALID; ++i)
+    std::cout << " " << g.id(i);
+  std::cout << std::endl;
+
+  std::cout << "Edges:";
+  for (EdgeIt i(g); i!=INVALID; ++i)
+    std::cout << " (" << g.id(g.source(i)) << "," << g.id(g.target(i)) << ")";
+  std::cout << std::endl;
+  std::cout <<  std::endl;
+
+  std::cout << "There is a map on the edges (length)!" << std::endl;
+  std::cout <<  std::endl;
+  for (EdgeIt i(g); i!=INVALID; ++i)
+    std::cout << "length(" << g.id(g.source(i)) << ","
+	      << g.id(g.target(i)) << ")="<<length[i]<<std::endl;
+
+  std::cout << std::endl;
+
+}
Index: demo/hello_world.cc
===================================================================
--- demo/hello_world.cc	(revision 2553)
+++ demo/hello_world.cc	(revision 2553)
@@ -0,0 +1,125 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief LEMON style "Hello World!" program
+///
+/// This program is intended to be a "Hello World!" program that shows
+/// the very basic notions of the LEMON library: \ref graphs "graphs" and
+/// \ref maps-page "maps". Click on the links to read more about these.
+///
+/// \include hello_world.cc
+
+#include <iostream>
+#include <lemon/list_graph.h>
+
+using namespace lemon;
+
+typedef ListGraph::Node  Node;
+typedef ListGraph::Edge  Edge;
+
+
+int main()
+{
+  // Declare the graph itself and a NodeMap, witch will store the characters
+  // assigned to the nodes
+  ListGraph  graph;
+  ListGraph::NodeMap<char>  char_map(graph);
+
+  // Add nodes
+  Node  new_node = graph.addNode();
+  char_map[new_node] = 'H';
+
+  // Store the start node
+  Node  start_node = new_node;
+
+  Node  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = 'e';
+
+  // Here we add the first edge...
+  graph.addEdge( from_node, new_node );
+
+  // ... and we add some more nodes and edges to the graph
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = 'l';
+  graph.addEdge( from_node, new_node );
+
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = 'l';
+  graph.addEdge( from_node, new_node );
+
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = 'o';
+  graph.addEdge( from_node, new_node );
+
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = ' ';
+  graph.addEdge( from_node, new_node );
+
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = 'W';
+  graph.addEdge( from_node, new_node );
+
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = 'o';
+  graph.addEdge( from_node, new_node );
+
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = 'r';
+  graph.addEdge( from_node, new_node );
+
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = 'l';
+  graph.addEdge( from_node, new_node );
+
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = 'd';
+  graph.addEdge( from_node, new_node );
+
+  from_node = new_node;
+  new_node = graph.addNode();
+  char_map[new_node] = '\n';
+  graph.addEdge( from_node, new_node );
+
+
+  // iterating
+  Node  current_node = start_node;
+  while( current_node != INVALID )
+  {
+    std::cout << char_map[current_node] << std::flush;
+
+    ListGraph::OutEdgeIt  edge(graph, current_node);
+    if( edge != INVALID )
+      current_node = graph.target( edge );
+    else
+      current_node = INVALID;
+  }
+  
+  return 0;
+}
Index: demo/kruskal_demo.cc
===================================================================
--- demo/kruskal_demo.cc	(revision 2553)
+++ demo/kruskal_demo.cc	(revision 2553)
@@ -0,0 +1,134 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Minimum weight spanning tree by Kruskal algorithm (demo).
+///
+/// This demo program shows how to find a minimum weight spanning tree
+/// in a graph by using the Kruskal algorithm. 
+///
+/// \include kruskal_demo.cc
+
+#include <iostream>
+#include <vector>
+
+#include <lemon/maps.h>
+#include <lemon/kruskal.h>
+#include <lemon/list_graph.h>
+
+
+using namespace std;
+using namespace lemon;
+
+
+int main() {
+
+  typedef ListGraph::Node Node;
+  typedef ListGraph::Edge Edge;
+  typedef ListGraph::NodeIt NodeIt;
+  typedef ListGraph::EdgeIt EdgeIt;
+
+  ListGraph g;
+  //Make an example graph g.
+  Node s=g.addNode();
+  Node v1=g.addNode();
+  Node v2=g.addNode();
+  Node v3=g.addNode();
+  Node v4=g.addNode();
+  Node t=g.addNode();
+  
+  Edge e1 = g.addEdge(s, v1);
+  Edge e2 = g.addEdge(s, v2);
+  Edge e3 = g.addEdge(v1, v2);
+  Edge e4 = g.addEdge(v2, v1);
+  Edge e5 = g.addEdge(v1, v3);
+  Edge e6 = g.addEdge(v3, v2);
+  Edge e7 = g.addEdge(v2, v4);
+  Edge e8 = g.addEdge(v4, v3);
+  Edge e9 = g.addEdge(v3, t);
+  Edge e10 = g.addEdge(v4, t);
+
+  //Make the input for the kruskal.
+  typedef ListGraph::EdgeMap<int> ECostMap;
+  ECostMap edge_cost_map(g);
+
+  // Fill the edge_cost_map. 
+  edge_cost_map.set(e1, -10);
+  edge_cost_map.set(e2, -9);
+  edge_cost_map.set(e3, -8);
+  edge_cost_map.set(e4, -7);
+  edge_cost_map.set(e5, -6);
+  edge_cost_map.set(e6, -5);
+  edge_cost_map.set(e7, -4);
+  edge_cost_map.set(e8, -3);
+  edge_cost_map.set(e9, -2);
+  edge_cost_map.set(e10, -1);
+
+  // Make the map or the vector, which will contain the edges of the minimum
+  // spanning tree.
+
+  typedef ListGraph::EdgeMap<bool> EBoolMap;
+  EBoolMap tree_map(g);
+
+  vector<Edge> tree_edge_vec;
+
+
+  //Kruskal Algorithm.  
+
+  //Input: a graph (g); a costmap of the graph (edge_cost_map); a
+  //boolmap (tree_map) or a vector (tree_edge_vec) to store the edges
+  //of the output tree;
+
+  //Output: it gives back the value of the minimum spanning tree, and
+  //set true for the edges of the tree in the edgemap tree_map or
+  //store the edges of the tree in the vector tree_edge_vec;
+
+
+  // Kruskal with boolmap;
+  std::cout << "The weight of the minimum spanning tree is " << 
+    kruskal(g, edge_cost_map, tree_map)<<std::endl;
+
+  int k=0;
+  std::cout << "The edges of the tree:" ;
+  for(EdgeIt i(g); i!=INVALID; ++i)
+    if (tree_map[i]) { 
+      std::cout << g.id(i) <<";";
+      ++k;
+    }
+
+  std::cout << std::endl;
+  std::cout << "The size of the tree is: "<< k << std::endl;
+
+
+  // Kruskal with vector;
+  std::cout << "The weight of the minimum spanning tree again is " << 
+    kruskal(g, edge_cost_map, std::back_inserter(tree_edge_vec)) <<std::endl;
+
+
+
+  std::cout << "The edges of the tree again: " ;
+  for(int i=tree_edge_vec.size()-1; i>=0;  i--)
+    std::cout << g.id(tree_edge_vec[i]) << ";" ;
+  std::cout << std::endl;
+  std::cout << "The size of the tree again is: "<< tree_edge_vec.size()
+	    << std::endl; 
+
+  
+  return 0;
+}
Index: demo/lp_demo.cc
===================================================================
--- demo/lp_demo.cc	(revision 2553)
+++ demo/lp_demo.cc	(revision 2553)
@@ -0,0 +1,131 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup demos
+/// \file
+/// \brief A program demonstrating the LEMON LP solver interface
+///
+/// This program is a simple application of the LEMON LP solver
+/// interface: we formulate a linear programming (LP) problem and then
+/// solve it using the underlying solver (GLPK or CPLEX for
+/// example). For the detailed documentation of the LEMON LP solver
+/// interface read \ref lemon::LpSolverBase "this".
+///
+/// \include lp_demo.cc
+
+#include <lemon/lp.h>
+
+#include <iostream>
+
+using namespace lemon;
+
+int main()
+{     
+ //The following example is taken from the documentation of the GLPK library.
+ //See it in the GLPK reference manual and among the GLPK sample files (sample.c)
+
+  //A default solver is taken
+  Lp lp;
+  typedef Lp::Row Row;
+  typedef Lp::Col Col;
+  
+
+  std::cout<<"A program demonstrating the LEMON LP solver interface"<<std::endl; 
+  std::cout<<"Solver used: "<<default_solver_name<<std::endl;
+
+  //This will be a maximization
+  lp.max();
+
+  //We add coloumns (variables) to our problem
+  Col x1 = lp.addCol();
+  Col x2 = lp.addCol();
+  Col x3 = lp.addCol();
+
+  //Constraints
+  lp.addRow(x1+x2+x3 <=100);  
+  lp.addRow(10*x1+4*x2+5*x3<=600);  
+  lp.addRow(2*x1+2*x2+6*x3<=300);  
+  //Nonnegativity of the variables
+  lp.colLowerBound(x1, 0);
+  lp.colLowerBound(x2, 0);
+  lp.colLowerBound(x3, 0);
+  //Objective function
+  lp.obj(10*x1+6*x2+4*x3);
+  
+  //Call the routine of the underlying LP solver
+  lp.solve();
+
+  //Print results
+  if (lp.primalStatus()==LpSolverBase::OPTIMAL){
+    std::cout<<"Optimal solution found!"<<std::endl;
+    printf("optimum value = %g; x1 = %g; x2 = %g; x3 = %g\n", 
+	   lp.primalValue(), 
+	   lp.primal(x1), lp.primal(x2), lp.primal(x3));
+  }
+  else{
+    std::cout<<"Optimal solution not found!"<<std::endl;
+  }
+
+  //End of LEMON style code
+
+  //Here comes the same problem written in C using GLPK API routines
+
+//   LPX *lp;
+//       int ia[1+1000], ja[1+1000];
+//       double ar[1+1000], Z, x1, x2, x3;
+// s1:   lp = lpx_create_prob();
+// s2:   lpx_set_prob_name(lp, "sample");
+// s3:   lpx_set_obj_dir(lp, LPX_MAX);
+// s4:   lpx_add_rows(lp, 3);
+// s5:   lpx_set_row_name(lp, 1, "p");
+// s6:   lpx_set_row_bnds(lp, 1, LPX_UP, 0.0, 100.0);
+// s7:   lpx_set_row_name(lp, 2, "q");
+// s8:   lpx_set_row_bnds(lp, 2, LPX_UP, 0.0, 600.0);
+// s9:   lpx_set_row_name(lp, 3, "r");
+// s10:  lpx_set_row_bnds(lp, 3, LPX_UP, 0.0, 300.0);
+// s11:  lpx_add_cols(lp, 3);
+// s12:  lpx_set_col_name(lp, 1, "x1");
+// s13:  lpx_set_col_bnds(lp, 1, LPX_LO, 0.0, 0.0);
+// s14:  lpx_set_obj_coef(lp, 1, 10.0);
+// s15:  lpx_set_col_name(lp, 2, "x2");
+// s16:  lpx_set_col_bnds(lp, 2, LPX_LO, 0.0, 0.0);
+// s17:  lpx_set_obj_coef(lp, 2, 6.0);
+// s18:  lpx_set_col_name(lp, 3, "x3");
+// s19:  lpx_set_col_bnds(lp, 3, LPX_LO, 0.0, 0.0);
+// s20:  lpx_set_obj_coef(lp, 3, 4.0);
+// s21:  ia[1] = 1, ja[1] = 1, ar[1] =  1.0; /* a[1,1] =  1 */
+// s22:  ia[2] = 1, ja[2] = 2, ar[2] =  1.0; /* a[1,2] =  1 */
+// s23:  ia[3] = 1, ja[3] = 3, ar[3] =  1.0; /* a[1,3] =  1 */
+// s24:  ia[4] = 2, ja[4] = 1, ar[4] = 10.0; /* a[2,1] = 10 */
+// s25:  ia[5] = 3, ja[5] = 1, ar[5] =  2.0; /* a[3,1] =  2 */
+// s26:  ia[6] = 2, ja[6] = 2, ar[6] =  4.0; /* a[2,2] =  4 */
+// s27:  ia[7] = 3, ja[7] = 2, ar[7] =  2.0; /* a[3,2] =  2 */
+// s28:  ia[8] = 2, ja[8] = 3, ar[8] =  5.0; /* a[2,3] =  5 */
+// s29:  ia[9] = 3, ja[9] = 3, ar[9] =  6.0; /* a[3,3] =  6 */
+// s30:  lpx_load_matrix(lp, 9, ia, ja, ar);
+// s31:  lpx_simplex(lp);
+// s32:  Z = lpx_get_obj_val(lp);
+// s33:  x1 = lpx_get_col_prim(lp, 1);
+// s34:  x2 = lpx_get_col_prim(lp, 2);
+// s35:  x3 = lpx_get_col_prim(lp, 3);
+// s36:  printf("\nZ = %g; x1 = %g; x2 = %g; x3 = %g\n", Z, x1, x2, x3);
+// s37:  lpx_delete_prob(lp);
+//       return 0;
+
+  return 0;
+}
Index: demo/lp_maxflow_demo.cc
===================================================================
--- demo/lp_maxflow_demo.cc	(revision 2553)
+++ demo/lp_maxflow_demo.cc	(revision 2553)
@@ -0,0 +1,125 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Max flow problem solved with an LP solver (demo).
+///
+/// This demo program shows how to solve a maximum (or maximal) flow
+/// problem using the LEMON LP solver interface. We would like to lay
+/// the emphasis on the simplicity of the way one can formulate LP
+/// constraints that arise in graph theory in our library LEMON .
+///
+/// \include lp_maxflow_demo.cc
+
+#include<lemon/graph_reader.h>
+#include<lemon/list_graph.h>
+#include <lemon/lp.h>
+
+#include <fstream>
+#include <iostream>
+
+
+
+using namespace lemon;
+
+template<class G,class C>
+double maxFlow(const G &g,const C &cap,typename G::Node s,typename G::Node t)
+{
+  Lp lp;
+  
+  typedef G Graph;
+  typedef typename G::Node Node;
+  typedef typename G::NodeIt NodeIt;
+  typedef typename G::Edge Edge;
+  typedef typename G::EdgeIt EdgeIt;
+  typedef typename G::OutEdgeIt OutEdgeIt;
+  typedef typename G::InEdgeIt InEdgeIt;
+  
+  //Define a map on the edges for the variables of the LP problem
+  typename G::template EdgeMap<Lp::Col> x(g);
+  lp.addColSet(x);
+  
+  //Nonnegativity and capacity constraints
+  for(EdgeIt e(g);e!=INVALID;++e) {
+    lp.colUpperBound(x[e],cap[e]);
+    lp.colLowerBound(x[e],0);
+  }
+
+
+  //Flow conservation constraints for the nodes (except for 's' and 't')
+  for(NodeIt n(g);n!=INVALID;++n) if(n!=s&&n!=t) {
+    Lp::Expr ex;
+    for(InEdgeIt  e(g,n);e!=INVALID;++e) ex+=x[e];
+    for(OutEdgeIt e(g,n);e!=INVALID;++e) ex-=x[e];
+    lp.addRow(ex==0);
+  }
+  
+  //Objective function: the flow value entering 't'
+  Lp::Expr obj;
+  for(InEdgeIt  e(g,t);e!=INVALID;++e) obj+=x[e];
+  for(OutEdgeIt e(g,t);e!=INVALID;++e) obj-=x[e];
+  lp.obj(obj);
+
+
+  //Maximization
+  lp.max();
+
+#if DEFAULT_LP==GLPK
+  lp.presolver(true);
+  lp.messageLevel(3);
+#endif
+
+  std::cout<<"Solver used: "<<default_solver_name<<std::endl;
+
+  //Solve with the underlying solver
+  lp.solve();
+
+  return lp.primalValue();
+}
+
+int main(int argc, char *argv[]) 
+{
+  if(argc<2)
+  {
+      std::cerr << "  USAGE: lp_maxflow_demo input_file.lgf" << std::endl;
+      std::cerr << "  The file 'input_file.lgf' has to contain a max "
+		<< "flow instance in\n"
+		<< "  LEMON format (e.g. sample.lgf is such a file)."
+		<< std::endl;
+      return 0;
+  }
+
+
+  //input stream to read the graph from
+  std::ifstream is(argv[1]);
+
+
+  ListGraph g;
+  ListGraph::Node s;
+  ListGraph::Node t;
+  
+  ListGraph::EdgeMap<double> cap(g);
+  
+  GraphReader<ListGraph> reader(is,g);
+  reader.readNode("source",s).readNode("target",t)
+    .readEdgeMap("capacity",cap).run();
+  
+  std::cout << "Max flow value = " << maxFlow(g,cap,s,t) << std::endl;
+
+}
Index: demo/maps_summary.cc
===================================================================
--- demo/maps_summary.cc	(revision 2553)
+++ demo/maps_summary.cc	(revision 2553)
@@ -0,0 +1,53 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief An introduction to LEMON maps
+///
+/// \include maps_summary.cc
+
+#include <iostream>
+#include <lemon/list_graph.h>
+
+using namespace lemon;
+
+
+template < typename GRAPH, typename MAP >
+typename MAP::Value  summary( GRAPH& gr, MAP& m )
+{
+  typename MAP::Value  summ = typename MAP::Value();
+  
+  for( typename GRAPH::NodeIt  n(gr); n != lemon::INVALID; ++n )
+    summ += m[n];
+
+  return summ;
+}
+
+
+int  main()
+{
+  ListGraph  gr;
+  ListGraph::NodeMap<double>  value(gr, 0.0);
+
+  //TODO: build a graph  
+  
+  std::cout << "The summary of assigned values is " << summary(gr,value) << std::endl;
+
+  return 0;
+}
Index: demo/min_route.cc
===================================================================
--- demo/min_route.cc	(revision 2569)
+++ demo/min_route.cc	(revision 2569)
@@ -0,0 +1,140 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <fstream>
+
+#include <lemon/smart_graph.h>
+#include <lemon/dijkstra.h>
+#include <lemon/maps.h>
+#include <lemon/dim2.h>
+#include <lemon/graph_reader.h>
+
+#include <lemon/time_measure.h>
+
+#include <lemon/math.h>
+
+/// \ingroup demos
+/// \file
+/// \brief Minimal route on a planar graph with eucledian distances.
+///
+/// Minimal route on a planar graph with eucledian distances.
+///
+/// \include min_route.cc
+
+
+using namespace lemon;
+
+template <typename CoordMap>
+class PotentialMap {
+public:
+  typedef double Value;
+  typedef typename CoordMap::Key Key;
+
+  PotentialMap(const CoordMap& _coord, const dim2::Point<double>& _target)
+    : coord(_coord), target(_target) {}
+
+  double operator[](const Key& node) const {
+    return std::sqrt((coord[node].x - target.x) * (coord[node].x - target.x) + 
+		     (coord[node].y - target.y) * (coord[node].y - target.y));
+  }
+private:
+  const CoordMap& coord;
+  dim2::Point<double> target;
+};
+
+template <typename Graph, typename LengthMap, typename PotentialMap>
+class ReducedLengthMap {
+public:
+  typedef double Value;
+  typedef typename LengthMap::Key Key;
+
+  ReducedLengthMap(const Graph& _graph, const LengthMap& _length, 
+		   const PotentialMap& _pot) 
+    : graph(_graph), length(_length), pot(_pot) {}
+
+  Value operator[](const Key& edge) const {
+    return length[edge] - (pot[graph.source(edge)] - pot[graph.target(edge)]);
+  }
+
+private:
+  const Graph& graph;
+  const LengthMap& length;
+  const PotentialMap& pot;
+};
+
+int main() {
+  typedef SmartGraph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeMap<double> LengthMap;
+  typedef Graph::NodeMap<dim2::Point<double> > CoordMap;
+
+  SmartGraph graph;
+
+  std::ifstream is("route.lgf");
+  GraphReader<Graph> reader(is, graph);
+  
+  CoordMap coord(graph);
+  dim2::XMap<CoordMap> xcoord = xMap(coord);
+  reader.readNodeMap("coordinates_x", xcoord);
+  dim2::YMap<CoordMap> ycoord = yMap(coord);
+  reader.readNodeMap("coordinates_y", ycoord);
+
+  LengthMap length(graph);
+  reader.readEdgeMap("length", length);
+
+  Node source, target;
+  reader.readNode("source", source);
+  reader.readNode("target", target);
+
+  reader.run();
+
+  {
+    Timer timer;
+    Dijkstra<Graph, LengthMap> dijkstra(graph, length);
+    dijkstra.init();
+    dijkstra.addSource(source);
+    dijkstra.start(target);
+
+    std::cout << dijkstra.dist(target) << std::endl;
+    std::cout << timer << std::endl;
+  }
+  {
+    Timer timer;
+    typedef PotentialMap<CoordMap> Potential;
+    Potential potential(coord, coord[target]);
+
+    typedef ReducedLengthMap<Graph, LengthMap, Potential> ReducedLength;
+    ReducedLength reduced(graph, length, potential);
+
+    Dijkstra<Graph, ReducedLength> dijkstra(graph, reduced);
+
+    dijkstra.init();
+    dijkstra.addSource(source);
+    dijkstra.start(target);
+  
+    std::cout << dijkstra.dist(target) + potential[source] << std::endl;
+    std::cout << timer << std::endl;
+  }
+
+  return 0;
+}
Index: demo/mip_demo.cc
===================================================================
--- demo/mip_demo.cc	(revision 2553)
+++ demo/mip_demo.cc	(revision 2553)
@@ -0,0 +1,74 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Mixed integer program solver demo
+///
+/// This example shows how can we solve an integer program with lemon
+/// \c Mip interface and with default solver.
+///
+/// \include mip_demo.cc
+
+#include <lemon/lp.h>
+
+using namespace lemon;
+
+int main(){
+
+   Mip ilp;
+
+
+  typedef Mip::Row Row;
+  typedef Mip::Col Col;
+  
+  ilp.max();
+  
+  Col x1 = ilp.addCol();
+  Col x2 = ilp.addCol();
+  Col x3 = ilp.addCol();
+  
+  ilp.integer(x1,true);
+  ilp.integer(x2,true);
+  ilp.integer(x3,true);
+  
+  ilp.addRow(x1+x2+x3 <=100);  
+  ilp.addRow(10*x1+4*x2+5*x3<=600);  
+  ilp.addRow(2*x1+2*x2+6*x3<=300); 
+  
+  ilp.colLowerBound(x1, 0);
+  ilp.colLowerBound(x2, 0);
+  ilp.colLowerBound(x3, 0);
+  //Objective function
+  ilp.obj(10*x1+6*x2+4*x3);
+  
+  //Call the routine of the underlying LP solver
+  ilp.solve();
+  
+  //Print results
+  if (ilp.primalStatus()==LpSolverBase::OPTIMAL){
+    std::cout<<"Optimal solution found!"<<std::endl;
+    printf("optimum value = %g; x1 = %g; x2 = %g; x3 = %g\n", 
+           ilp.primalValue(), 
+           ilp.primal(x1), ilp.primal(x2), ilp.primal(x3));
+  }
+  else{
+    std::cout<<"Optimal solution not found!"<<std::endl;
+  }
+
+}
Index: demo/partitions.lgf
===================================================================
--- demo/partitions.lgf	(revision 1909)
+++ demo/partitions.lgf	(revision 1909)
@@ -0,0 +1,58 @@
+@nodeset 
+coordinates_x	coordinates_y	label	
+513.857		-446.322	23	
+393.468		566.711		22	
+869.153		52.8539		21	
+596.074		302.442		20	
+-82.2171	593.138		19	
+-663.61		546.157		18	
+-1077.63	161.498		17	
+-1177.47	-234.906	16	
+-880.898	-528.539	15	
+-499.175	-499.175	14	
+79.2808		-528.539	13	
+637.183		-184.989	12	
+205.543		-322.996	11	
+399.34		88.0898		10	
+-842.726	243.715		9	
+-860.344	-29.3633	8	
+-211.415	-452.194	7	
+-99.8351	99.8351		6	
+120.389		-129.198	5	
+108.644		334.741		4	
+-484.494	328.869		3	
+-607.82		-246.651	2	
+-274		-131		1	
+@uedgeset 
+		label	
+12	23	15	
+13	23	14	
+4	22	23	
+20	21	20	
+12	21	19	
+22	20	22	
+22	19	25	
+6	19	24	
+9	18	28	
+16	15	1	
+2	14	8	
+7	13	13	
+11	12	16	
+5	10	18	
+17	9	5	
+17	8	3	
+16	8	2	
+14	7	10	
+3	6	30	
+9	6	27	
+11	5	17	
+7	5	12	
+6	4	26	
+10	4	21	
+18	3	29	
+15	2	7	
+8	2	6	
+5	1	11	
+14	1	9	
+9	1	4	
+@end
Index: demo/reader_writer_demo.cc
===================================================================
--- demo/reader_writer_demo.cc	(revision 2553)
+++ demo/reader_writer_demo.cc	(revision 2553)
@@ -0,0 +1,65 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Demonstrating graph input and output
+///
+/// This simple demo program gives an example of how to read and write
+/// a graph and additional maps (on the nodes or the edges) from/to a
+/// stream. 
+///
+/// \include reader_writer_demo.cc
+
+#include <iostream>
+#include <lemon/smart_graph.h>
+#include <lemon/graph_reader.h>
+#include <lemon/graph_writer.h>
+
+
+using namespace lemon;
+
+int main() {
+  SmartGraph graph;
+
+  try {
+    std::string filename="sample.lgf";
+    std::string name;
+    GraphReader<SmartGraph> reader(filename,graph);
+    SmartGraph::EdgeMap<int> cap(graph);
+    reader.readEdgeMap("capacity",cap);
+    reader.readAttribute("name",name);
+    reader.run();
+
+    std::cout << "Hello! We have read a graph from file " << filename<< 
+      " and some maps on it:\n now we write it to the standard output!" << 
+      std::endl;
+
+
+    GraphWriter<SmartGraph> writer(std::cout, graph);
+    writer.writeEdgeMap("multiplicity", cap);
+    writer.writeAttribute("name",name);
+    writer.run();
+     
+  } catch (DataFormatError& error) {
+    std::cerr << error.what() << std::endl;
+  }
+
+
+  return 0;
+}
Index: demo/route.lgf
===================================================================
--- demo/route.lgf	(revision 1901)
+++ demo/route.lgf	(revision 1901)
@@ -0,0 +1,43 @@
+@nodeset
+label	coordinates_x	coordinates_y	
+9	447.907	578.328	
+8	79.2573	909.464	
+7	878.677	960.04	
+6	11.5504	938.413	
+5	327.398	815.035	
+4	427.002	954.002	
+3	148.549	753.748	
+2	903.889	326.476	
+1	408.248	577.327	
+0	189.239	92.5316	
+@edgeset
+		length	label	
+2	3	901.074	0	
+8	5	270.85	1	
+6	9	601.553	2	
+5	9	285.022	3	
+9	4	408.091	4	
+3	0	719.712	5	
+7	5	612.836	6	
+0	4	933.353	7	
+5	0	778.871	8	
+5	5	0	9	
+7	1	664.049	10	
+5	5	0	11	
+0	9	560.464	12	
+4	8	352.36	13	
+4	9	399.625	14	
+4	1	402.171	15	
+1	2	591.688	16	
+3	8	182.376	17	
+4	5	180.254	18	
+3	1	345.283	19	
+5	4	184.511	20	
+6	2	1112.45	21	
+0	1	556.624	22	
+@nodes
+source	1	
+target	8	
+@edges 
+@attributes 
+@end
Index: demo/sample.lgf
===================================================================
--- demo/sample.lgf	(revision 2416)
+++ demo/sample.lgf	(revision 2416)
@@ -0,0 +1,26 @@
+@nodeset
+label      coordinates_x   coordinates_y
+5       796.398 208.035
+4       573.002 63.002
+3       568.549 401.748
+2       277.889 68.476
+1       288.248 397.327
+0       102.239 257.532
+@edgeset
+                label      capacity
+4       5       6       8
+3       5       5       8
+2       4       4       5
+1       4       3       8
+1       3       2       5
+0       2       1       10
+0       1       0       10
+#This is a comment here
+@nodes
+source 0
+target 5
+@edges 
+@attributes
+name "Simple Sample Graph"
+author "Attila BERNATH"
+@end
Index: demo/sat-2.cc
===================================================================
--- demo/sat-2.cc	(revision 2553)
+++ demo/sat-2.cc	(revision 2553)
@@ -0,0 +1,157 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup demos
+/// \file
+/// \brief Solver for SAT-2 problems.
+///
+/// This demo progam solves the SAT-2 problem, i.e. the boolean
+/// satisfiability problem where each disjuction consists at most 2
+/// terms.
+///
+/// The program generates a graph from the boolean expression. Two
+/// nodes are assigned to each boolean variable, an <tt>x</tt> and a
+/// <tt>not x</tt> nodes. If there is an <tt>x or y</tt> disjunction
+/// in the formula, then the <tt>not x => y</tt> and the <tt>not y =>
+/// x</tt> edges are added to the graph. If there is a single
+/// <tt>x</tt> term disjunction in the formula then the <tt>not x
+/// =>x</tt> edge is added to the graph.
+///
+/// The boolean formula could be satified if and only if the
+/// <tt>x</tt> and <tt>not x</tt> nodes are in different strongly connected
+/// components. A feasible solution could be get from the current
+/// component numbering.
+///
+/// \include sat-2.cc
+
+#include <iostream>
+#include <fstream>
+#include <sstream>
+#include <string>
+#include <map>
+
+#include <lemon/smart_graph.h>
+#include <lemon/topology.h>
+
+using namespace std;
+using namespace lemon;
+
+
+int main(int argc, const char *argv[]) {
+  if (argc != 2) {
+    std::cerr << "The SAT-2 solver demo" << std::endl << std::endl;
+    std::cerr << "The  parameter should be a filename" << std::endl;
+    std::cerr << "Each line of the file should contain a bool expression:" 
+              << std::endl;
+    std::cerr << "  [not] <variable> [or [not] <variable>]" << std::endl;
+    std::cerr << "The program prints a feasible solution if it exists" 
+              << std::endl;
+    return -1;
+  }
+  ifstream is(argv[1]);
+
+  SmartGraph graph;
+  map<string, pair<SmartGraph::Node, SmartGraph::Node> > var;
+
+  string line;
+  while (getline(is, line)) {
+    istringstream ls(line);
+    string var1, var2, op;
+    bool neg1 = false, neg2 = false;
+
+    ls >> var1;
+    if (var1 == "not") {
+      neg1 = true;
+      ls >> var1;
+    }
+    if (ls >> op) {
+      if (op != "or") {
+        cerr << "Wrong bool expression" << std::endl;
+        return -1;
+      } else {
+        ls >> var2;
+        if (var2 == "not") {
+          neg2 = true;
+          ls >> var2;
+        }
+      }
+      if (ls >> op) {
+        cerr << "Wrong bool expression" << std::endl;
+        return -1;
+      }
+
+      map<string, pair<SmartGraph::Node, SmartGraph::Node> >::iterator it1;
+      map<string, pair<SmartGraph::Node, SmartGraph::Node> >::iterator it2;    
+      it1 = var.find(var1);
+      if (it1 == var.end()) {
+        SmartGraph::Node node = graph.addNode();
+        SmartGraph::Node negNode = graph.addNode();
+        it1 = var.insert(make_pair(var1, make_pair(node, negNode))).first;
+      }
+
+      it2 = var.find(var2);
+      if (it2 == var.end()) {
+        SmartGraph::Node node = graph.addNode();
+        SmartGraph::Node negNode = graph.addNode();
+        it2 = var.insert(make_pair(var2, make_pair(node, negNode))).first;
+      }
+
+      graph.addEdge(neg1 ? it1->second.first : it1->second.second, 
+                    neg2 ? it2->second.second : it2->second.first);
+
+      graph.addEdge(neg2 ? it2->second.first : it2->second.second, 
+                    neg1 ? it1->second.second : it1->second.first);
+    } else {
+
+      map<string, pair<SmartGraph::Node, SmartGraph::Node> >::iterator it1;
+      it1 = var.find(var1);
+      if (it1 == var.end()) {
+        SmartGraph::Node node = graph.addNode();
+        SmartGraph::Node negNode = graph.addNode();
+        it1 = var.insert(make_pair(var1, make_pair(node, negNode))).first;
+      }
+      graph.addEdge(neg1 ? it1->second.first : it1->second.second, 
+                    neg1 ? it1->second.second : it1->second.first);
+      
+    }
+    
+  }
+  
+  SmartGraph::NodeMap<int> comp(graph);
+
+  stronglyConnectedComponents(graph, comp); 
+
+  for (map<string, pair<SmartGraph::Node, SmartGraph::Node> >::iterator
+         it = var.begin(); it != var.end(); ++it) {
+    if (comp[it->second.first] == comp[it->second.second]) {
+      std::cout << "There is no feasible solution." << std::endl;
+      return 0;
+    }
+  }
+
+  for (map<string, pair<SmartGraph::Node, SmartGraph::Node> >::iterator
+         it = var.begin(); it != var.end(); ++it) {
+    if (comp[it->second.first] < comp[it->second.second]) {
+      std::cout << it->first << " = false " << std::endl;
+    } else {
+      std::cout << it->first << " = true " << std::endl;
+    }
+  }
+  
+  return 0;
+}
Index: demo/sat-2.in
===================================================================
--- demo/sat-2.in	(revision 2459)
+++ demo/sat-2.in	(revision 2459)
@@ -0,0 +1,3 @@
+x1 or x2
+x2 or not x3
+x3 or not x1
Index: demo/sat.cc
===================================================================
--- demo/sat.cc	(revision 2553)
+++ demo/sat.cc	(revision 2553)
@@ -0,0 +1,115 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup demos
+/// \file
+/// \brief Solver for SAT problems.
+///
+/// This demo progam solves the SAT problem, i.e. the boolean
+/// satisfiability problem. The problem in general case is
+/// NP-complete.
+///
+/// The program uses an integer linear program solver. A <tt>{0,
+/// 1}</tt> variable is assigned to each boolean variable. The
+/// disjunctions are converted to linear inequalities as each negation
+/// is replaced with a substraction from one and each disjunction is
+/// converted to addition. The generated linear expression should be
+/// at least one.
+///
+/// \include sat.cc
+
+#include <iostream>
+#include <fstream>
+#include <sstream>
+#include <string>
+
+#include <lemon/lp.h>
+
+using namespace std;
+using namespace lemon;
+
+
+int main(int argc, const char *argv[]) {
+  if (argc != 2) {
+    std::cerr << "The SAT solver demo" << std::endl << std::endl;
+    std::cerr << "The  parameter should be a filename" << std::endl;
+    std::cerr << "Each line of the file should contain a bool expression:" 
+              << std::endl;
+    std::cerr << "  [not] <variable> [or [not] <variable>]..." << std::endl;
+    std::cerr << "The program prints a feasible solution if it exists" 
+              << std::endl;
+    return -1;
+  }
+  ifstream is(argv[1]);
+
+  Mip mip;
+  mip.max();
+  mip.obj(0);
+
+  string line;
+  while (getline(is, line)) {
+    istringstream ls(line);
+
+    Mip::Expr expr;
+
+
+    string op;
+    do {
+      string var;
+      bool neg = false;
+
+      ls >> var;
+      if (var == "not") {
+        neg = true;
+        ls >> var;
+      }
+
+      Mip::Col col = mip.colByName(var);
+
+      if (col == INVALID) {
+        col = mip.addCol();
+        mip.colName(col, var);
+        mip.colLowerBound(col, 0);
+        mip.colUpperBound(col, 1);
+        mip.integer(col, true);        
+      }
+      
+      expr += (neg ? 1 - col : col);
+
+    } while (ls >> op && op == "or");
+    if (ls) {
+      std::cerr << "Wrong bool expression" << std::endl;
+      return -1;
+    }
+    mip.addRow(expr >= 1);
+  }
+
+  mip.solve();
+
+  if (mip.mipStatus() == Mip::OPTIMAL) {
+    for (Mip::ColIt it(mip); it != INVALID; ++it) {
+      std::cout << mip.colName(it) << " = " 
+                << (mip.primal(it) == 1 ? "true" : "false")
+                << std::endl;
+    }
+  } else {
+    std::cout << "There is no feasible solution." << std::endl;
+  }
+  
+  return 0;
+}
Index: demo/simann_maxcut_demo.cc
===================================================================
--- demo/simann_maxcut_demo.cc	(revision 2553)
+++ demo/simann_maxcut_demo.cc	(revision 2553)
@@ -0,0 +1,124 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup demos
+/// \file
+/// \brief A program demonstrating the simulated annealing algorithm class.
+///
+/// This program tries to find a maximal cut in a graph using simulated
+/// annealing. It starts from a random solution and then in each step it
+/// chooses a node and moves it to the other side of the cut.
+///
+/// \include simann_maxcut_demo.cc
+
+#include <iostream>
+#include <cstdlib>
+
+#include <lemon/simann.h>
+#include <lemon/list_graph.h>
+#include <lemon/graph_reader.h>
+
+using namespace lemon;
+
+typedef ListGraph Graph;
+typedef Graph::Node Node;
+typedef Graph::Edge Edge;
+typedef Graph::NodeIt NodeIt;
+typedef Graph::EdgeIt EdgeIt;
+typedef Graph::OutEdgeIt OutEdgeIt;
+typedef Graph::InEdgeIt InEdgeIt;
+
+class Entity : public EntityBase
+{
+  public:
+    Graph& g;
+    Graph::EdgeMap<int>& w;
+    Graph::NodeMap<bool> a;
+    int sum;
+    Node last_moved;
+    Entity(Graph& _g, Graph::EdgeMap<int>& _w) : g(_g), w(_w), a(_g) {}
+    double mutate() {
+      static const int node_num = countNodes(g);
+      int i = 1 + rnd[node_num];
+      NodeIt n(g);
+      int j = 1;
+      while (j < i) {
+        ++n;
+        ++j;
+      }
+      for (OutEdgeIt e(g, n); e != INVALID; ++e) {
+        if (a[n] != a[g.target(e)]) sum -= w[e];
+        if (a[n] == a[g.target(e)]) sum += w[e];
+      }
+      for (InEdgeIt e(g, n); e != INVALID; ++e) {
+        if (a[g.source(e)] != a[n]) sum -= w[e];
+        if (a[g.source(e)] == a[n]) sum += w[e];
+      }
+      bool b = a[n];
+      a[n] = !b;
+      last_moved = n;
+      return -sum;
+    }
+    void revert() {
+      for (OutEdgeIt e(g, last_moved); e != INVALID; ++e) {
+        if (a[last_moved] != a[g.target(e)]) sum -= w[e];
+        if (a[last_moved] == a[g.target(e)]) sum += w[e];
+      }
+      for (InEdgeIt e(g, last_moved); e != INVALID; ++e) {
+        if (a[g.source(e)] != a[last_moved]) sum -= w[e];
+        if (a[g.source(e)] == a[last_moved]) sum += w[e];
+      }
+      bool b = a[last_moved];
+      a[last_moved] = !b;
+    }
+    Entity* clone() { return new Entity(*this); }
+    void randomize() {
+      for (NodeIt n(g); n != INVALID; ++n)
+        a[n] = false;
+      for (NodeIt n(g); n != INVALID; ++n)
+        if (rnd.boolean(0.5)) a[n] = true;
+      sum = 0;
+      for (EdgeIt e(g); e != INVALID; ++e)
+        if (a[g.source(e)] != a[g.target(e)])
+          sum += w[e];
+    }
+};
+
+int main()
+{
+  Graph g;
+  Graph::EdgeMap<int> w(g);
+
+  GraphReader<Graph> reader("simann_maxcut_demo.lgf", g);
+  reader.readEdgeMap("weight", w);
+  reader.run();
+
+  Entity e(g, w);
+
+  SimAnn simann;
+  SimpleController ctrl;
+  simann.setController(ctrl);
+  simann.setEntity(e);
+  simann.run();
+  
+  Entity* be = static_cast<Entity*>(simann.getBestEntity());
+  std::cout << be->sum << std::endl;
+  for (NodeIt n(g); n != INVALID; ++n)
+    if (be->a[n]) std::cout << g.id(n) << ": 1" << std::endl;
+    else std::cout << g.id(n) << ": 0" << std::endl;
+}
Index: demo/simann_maxcut_demo.lgf
===================================================================
--- demo/simann_maxcut_demo.lgf	(revision 1919)
+++ demo/simann_maxcut_demo.lgf	(revision 1919)
@@ -0,0 +1,22 @@
+@nodeset
+label
+0
+1
+2
+3
+4
+5
+6
+@edgeset
+        weight
+0   3   1
+0   4   1
+1   5   1
+5   2   1
+6   2   1
+0   1   1
+2   1   1
+3   4   1
+4   5   1
+5   6   1
+@end
Index: demo/steiner.lgf
===================================================================
--- demo/steiner.lgf	(revision 2400)
+++ demo/steiner.lgf	(revision 2400)
@@ -0,0 +1,303 @@
+@nodeset 
+coordinates_x	coordinates_y	label	terminal	
+-251.856	-202.321	0	1	
+-331.765	100.719 	1	0	
+-273.677	-294.883	2	0	
+-377.147	-85.369 	3	0	
+169.068	        132.547 	4	0	
+453.494	        43.7303 	5	0	
+350.694	        -81.2848	6	0	
+-295.393	211.455 	7	0	
+-231.281	-62.2543	8	0	
+275.941	        118.221 	9	0	
+311.816	        220.248 	10	0	
+234.152	        -433.718	11	0	
+146.458	        422.137 	12	0	
+105.796	        -281.078	13	0	
+-284.598	-120.027	14	0	
+321.329	        295.308 	15	0	
+47.3951	        306.406 	16	0	
+-189.908	-188.032	17	0	
+-15.3932	-179.904	18	0	
+-178.559	80.3029 	19	0	
+231.219	        332.276 	20	0	
+314.277	        -37.9572	21	0	
+412.918	        91.483  	22	1	
+-288.281	10.409  	23	0	
+-265.853	-415.164	24	1	
+357.609	        -190.755	25	0	
+170.989	        275.074 	26	1	
+-454.346	132.702 	27	1	
+37.385	        -21.8462	28	0	
+157.624	        325.213 	29	0	
+349.774	        22.435  	30	0	
+-53.4642	-78.4002	31	0	
+-209.404	-275.264	32	0	
+226.943	        93.2239 	33	0	
+-415.266	-226.887	34	0	
+-268.299	152.735 	35	0	
+80.0752	        337.882 	36	0	
+-107.322	-328.854	37	0	
+118.71	        -56.0308	38	1	
+257.804	        417.75  	39	0	
+-5.41726	302.825 	40	0	
+-319.74	        -186.925	41	0	
+275.381	        277.069 	42	0	
+-273.248	319.744 	43	0	
+-43.6017	-208.328	44	0	
+166.639	        -134.903	45	0	
+-54.1813	323.637 	46	0	
+286.634	        57.5531 	47	0	
+426.828	        245.989 	48	0	
+-357.602	220.391 	49	0	
+135.626	        372.331 	50	0	
+-21.8318	430.892 	51	0	
+-406.689	46.2421 	52	0	
+-246.874	262.591 	53	0	
+-370.766	-20.5267	54	0	
+-14.7567	-328.157	55	0	
+387.598	        40.9046 	56	0	
+-279.35	        -247.789	57	1	
+116.726	        284.452 	58	0	
+440.353	        141.885 	59	0	
+-171.65	        355.372 	60	1	
+-207.145	-368.556	61	0	
+-369.168	178.735 	62	1	
+-45.5162	85.4527 	63	0	
+135.203 	71.4192 	64	0	
+-351.597	-250.799	65	0	
+-453.398	-15.6638	66	0	
+234.039	        -359.178	67	0	
+-346.344	349.928 	68	0	
+4.38307	        40.7204 	69	0	
+224.516	        249.259 	70	0	
+-105.49	        22.5721 	71	1	
+147.119 	-215.924	72	0	
+-408.527       	96.861  	73	0	
+-99.522 	268.879 	74	0	
+-1.57169	363.155 	75	0	
+347.538 	92.4063 	76	0	
+353.409 	183.093 	77	0	
+416.442 	-69.8499	78	0	
+-58.1027        -422.666	79	0	
+227.968 	-76.286 	80	0	
+-323.979        42.9237 	81	0	
+84.2308 	-199.473	82	0	
+56.538  	-83.469 	83	0	
+244.34  	-234.403	84	0	
+-361.409        -146.916	85	0	
+395.636 	189.561 	86	0	
+-89.832 	464.4   	87	0	
+230.042 	199.124 	88	0	
+-93.6872	145.66  	89	1	
+-202.746	-118.087	90	0	
+-57.6298 	207.792 	91	0	
+377.074 	298.05  	92	0	
+-111.722	83.101  	93	0	
+279.51  	-133.648	94	0	
+66.5975 	494.601 	95	1	
+105.518 	204.789 	96	0	
+-324.108	-84.4418	97	1	
+-183.456	440.555 	98	0	
+177.565 	215.632 	99	0	
+@uedgeset 
+		label	
+38	28	0	
+56	5	2	
+75	16	3	
+40	16	4	
+92	48	5	
+74	53	8	
+88	70	9	
+68	43	10	
+58	26	11	
+69	31	12	
+14	0	13	
+61	37	14	
+73	27	16	
+59	5	17	
+17	0	18	
+29	26	19	
+56	22	21	
+21	6	22	
+55	37	24	
+61	32	26	
+57	0	27	
+93	89	28	
+82	45	29	
+94	80	30	
+38	31	31	
+91	89	32	
+37	32	33	
+66	52	34	
+59	22	35	
+65	41	36	
+99	58	37	
+44	18	38	
+62	49	40	
+83	45	41	
+33	4	42	
+93	63	43	
+50	29	44	
+85	3	45	
+98	87	46	
+81	23	47	
+9	4	48	
+86	48	49	
+69	28	50	
+81	54	51	
+46	40	52	
+84	67	53	
+75	36	56	
+47	33	58	
+77	10	59	
+90	14	60	
+75	46	62	
+81	1	63	
+26	20	64	
+70	4	65	
+97	3	66	
+88	10	67	
+58	50	68	
+92	86	70	
+47	9	71	
+90	8	75	
+49	7	76	
+54	23	77	
+91	35	79	
+42	10	80	
+65	34	81	
+51	50	82	
+86	77	83	
+76	30	84	
+99	20	86	
+42	15	87	
+42	20	88	
+64	38	89	
+78	6	90	
+47	30	91	
+67	11	93	
+78	30	94	
+64	28	95	
+82	72	96	
+76	9	97	
+72	13	98	
+86	59	100	
+69	63	102	
+91	74	103	
+62	7	105	
+44	37	106	
+51	12	107	
+76	56	108	
+50	12	109	
+95	51	110	
+35	19	111	
+30	21	112	
+88	9	113	
+98	60	114	
+73	62	115	
+70	42	117	
+71	63	118	
+85	34	121	
+97	54	122	
+20	15	123	
+39	20	124	
+65	2	125	
+76	59	126	
+90	17	127	
+77	76	129	
+57	41	130	
+23	8	131	
+71	19	132	
+78	56	133	
+91	53	134	
+53	46	135	
+80	21	137	
+72	45	138	
+97	8	139	
+94	25	141	
+62	27	142	
+58	36	144	
+93	71	145	
+57	2	146	
+92	10	147	
+88	77	148	
+91	63	149	
+17	2	152	
+73	1	153	
+55	18	155	
+50	20	157	
+66	54	158	
+51	36	159	
+78	5	160	
+99	70	161	
+87	60	162	
+60	53	163	
+97	85	164	
+97	14	166	
+89	19	167	
+82	18	169	
+85	41	170	
+99	96	171	
+73	52	172	
+92	15	173	
+81	52	174	
+83	18	176	
+41	14	178	
+32	17	179	
+96	36	180	
+74	40	182	
+7	1	183	
+39	12	185	
+94	6	187	
+83	38	188	
+24	2	189	
+32	18	190	
+66	3	192	
+71	31	194	
+68	49	203	
+23	19	204	
+43	7	208	
+96	16	209	
+61	2	210	
+96	4	211	
+64	45	212	
+91	16	213	
+84	72	214	
+66	27	215	
+67	13	216	
+71	8	217	
+19	1	218	
+87	46	219	
+94	72	220	
+84	25	221	
+60	43	222	
+18	13	225	
+35	7	226	
+51	46	227	
+80	47	229	
+80	45	230	
+79	55	231	
+90	71	232	
+64	47	233	
+64	4	234	
+53	7	236	
+64	63	237	
+98	68	238	
+79	61	239	
+96	63	242	
+78	25	243	
+31	18	244	
+90	18	245	
+13	11	246	
+95	39	247	
+95	87	250	
+79	24	251	
+66	34	252	
+92	39	253	
+79	13	254	
+34	24	255	
+68	27	256	
+25	11	257	
+24	11	259	
+@end
Index: demo/steiner_demo.cc
===================================================================
--- demo/steiner_demo.cc	(revision 2569)
+++ demo/steiner_demo.cc	(revision 2569)
@@ -0,0 +1,109 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Calculating an approximate Steiner-tree.
+///
+/// Calculating an approximate Steiner-tree.
+///
+/// \include steiner_demo.cc
+
+#include <lemon/smart_graph.h>
+#include <lemon/kruskal.h>
+#include <lemon/graph_reader.h>
+#include <lemon/time_measure.h>
+#include <lemon/graph_to_eps.h>
+#include <lemon/steiner.h>
+#include <lemon/math.h>
+
+#include <cstdlib>
+
+using namespace lemon;
+using namespace lemon::dim2;
+
+using namespace std;
+
+int main(int argc, const char *argv[]) {
+  std::string lgf = argc > 1 ? argv[1] : "steiner.lgf";
+  std::string eps = argc > 2 ? argv[2] : "steiner.eps";
+
+  SmartUGraph graph;
+  SmartUGraph::NodeMap<bool> terminal(graph);
+  SmartUGraph::NodeMap<int> label(graph);
+  SmartUGraph::NodeMap<Point<double> > coord(graph);
+  
+  UGraphReader<SmartUGraph>(lgf, graph).
+    readNodeMap("coordinates_x", xMap(coord)).
+    readNodeMap("coordinates_y", yMap(coord)).
+    readNodeMap("terminal", terminal).run();
+
+  SmartUGraph::UEdgeMap<double> cost(graph);
+  for (SmartUGraph::UEdgeIt it(graph); it != INVALID; ++it) {
+    cost[it] = sqrt((coord[graph.target(it)] - 
+                     coord[graph.source(it)]).normSquare());
+  }
+  
+  SteinerTree<SmartUGraph> steiner(graph, cost);
+  steiner.init();
+
+  for (SmartUGraph::NodeIt it(graph); it != INVALID; ++it) {
+    if (terminal[it]) {
+      steiner.addTerminal(it);
+    }
+  }
+  steiner.start();
+
+
+  Palette nodepalette(0);
+  nodepalette.add(Color(1.0, 1.0, 1.0));
+  nodepalette.add(Color(0.0, 1.0, 0.0));
+  nodepalette.add(Color(0.5, 0.5, 0.5));
+  SmartUGraph::NodeMap<int> nodecolor(graph);
+  for (SmartUGraph::NodeIt it(graph); it != INVALID; ++it) {
+    if (steiner.terminal(it)) {
+      nodecolor[it] = 1;
+    } else if (steiner.steiner(it)) {
+      nodecolor[it] = 2;
+    } else {
+      nodecolor[it] = 0;
+    }
+  }
+
+
+  Palette edgepalette(0);
+  edgepalette.add(Color(0.0, 0.0, 0.0));
+  edgepalette.add(Color(1.0, 0.0, 0.0));
+  SmartUGraph::UEdgeMap<int> edgecolor(graph);
+  for (SmartUGraph::UEdgeIt it(graph); it != INVALID; ++it) {
+    edgecolor[it] = steiner.tree(it) ? 1 : 0;
+  }
+
+
+  graphToEps(graph, eps).
+    coords(coord).undirected().
+    nodeScale(1.0).scaleToA4().
+    nodeColors(composeMap(nodepalette, nodecolor)).
+    edgeColors(composeMap(edgepalette, edgecolor)).
+    nodeTexts(label).nodeTextSize(8).run();
+
+  std::cout << "The tree constructed: " << eps << std::endl;
+  std::cout << "The cost of the tree: " << steiner.treeValue() << std::endl;
+
+  return 0;
+}
Index: demo/strongly_connected_orientation.cc
===================================================================
--- demo/strongly_connected_orientation.cc	(revision 2553)
+++ demo/strongly_connected_orientation.cc	(revision 2553)
@@ -0,0 +1,112 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+
+#include <lemon/smart_graph.h>
+#include <lemon/graph_reader.h>
+#include <lemon/ugraph_adaptor.h>
+#include <lemon/graph_to_eps.h>
+#include <lemon/dfs.h>
+#include <lemon/topology.h>
+
+
+/// \ingroup demos
+/// \file
+/// \brief Strongly connected orientation
+///
+/// This example demonstrates the usage of the DirUGraphAdaptor,
+/// the DfsVisitor and some topology functions. The program reads
+/// an input undirected graph and with a DfsVisit it orients each edge
+/// to minimize the strongly connected components in the graph. At least
+/// it checks the result of the orientation with to topology functions.
+///
+/// \include strongly_connected_orientation.cc
+
+using namespace lemon;
+using namespace std;
+
+typedef SmartUGraph UGraph;
+UGRAPH_TYPEDEFS(UGraph);
+
+Color color(bool c) {
+  return c ? BLACK : RED;
+}
+
+template <typename DirMap>
+class OrientVisitor : public DfsVisitor<UGraph> {
+public:
+
+  OrientVisitor(const UGraph& ugraph, DirMap& dirMap)
+    : _ugraph(ugraph), _dirMap(dirMap), _processed(ugraph, false) {}
+
+  void discover(const Edge& edge) {
+    _processed.set(edge, true);
+    _dirMap.set(edge, _ugraph.direction(edge));
+  }
+
+  void examine(const Edge& edge) {
+    if (_processed[edge]) return;
+    _processed.set(edge, true);
+    _dirMap.set(edge, _ugraph.direction(edge));
+  }  
+
+private:
+  const UGraph& _ugraph;  
+  DirMap& _dirMap;
+  UGraph::UEdgeMap<bool> _processed;
+};
+
+
+int main() {
+  cout << "Orientation of the strongly_connected_orientation.lgf "
+       << "to be strongly connected" << endl;
+
+  UGraph ugraph;
+  UGraph::NodeMap<dim2::Point<double> > coords(ugraph);
+  UGraphReader<UGraph>("strongly_connected_orientation.lgf", ugraph).
+    readNodeMap("coords", coords).run();
+
+  UGraph::UEdgeMap<bool> dmap(ugraph);
+
+  typedef OrientVisitor<UGraph::UEdgeMap<bool> > Visitor;
+  Visitor visitor(ugraph, dmap);
+
+  DfsVisit<UGraph, Visitor> dfs(ugraph, visitor);
+
+  dfs.run();
+
+  typedef DirUGraphAdaptor<UGraph> DGraph;
+  DGraph dgraph(ugraph, dmap);
+
+  cout << "The result written into the " 
+       << "strongly_connected_orientation.eps file" << endl;
+
+  graphToEps(dgraph, "strongly_connected_orientation.eps").
+    drawArrows().coords(coords).scaleToA4().enableParallel().
+    autoNodeScale().autoEdgeWidthScale().run();
+
+  int num_scc = countStronglyConnectedComponents(dgraph);
+  int num_becc = countBiEdgeConnectedComponents(ugraph);
+
+  if (num_scc != num_becc) {
+    std::cerr << "Wrong Orientation" << std::endl;
+  }
+  
+  return 0;
+}
Index: demo/strongly_connected_orientation.lgf
===================================================================
--- demo/strongly_connected_orientation.lgf	(revision 2084)
+++ demo/strongly_connected_orientation.lgf	(revision 2084)
@@ -0,0 +1,26 @@
+@nodeset 
+coords  	label	
+(12,6)	        9	
+(-12,3)	        8	
+(-34,6)	        7	
+(-23,22)	6	
+(16,26)	        5	
+(43,8)	        4	
+(24,-8)	        3	
+(-4,-14)	2	
+(-29,-11)	1	
+@uedgeset 
+		label	
+5	9	9	
+9	8	5	
+7	6	7	
+8	6	6	
+4	5	11	
+6	5	8	
+3	4	12	
+9	4	10	
+3	2	4	
+8	2	3	
+1	2	2	
+7	1	1	
+@end
Index: demo/sub_gad_input.lgf
===================================================================
--- demo/sub_gad_input.lgf	(revision 1901)
+++ demo/sub_gad_input.lgf	(revision 1901)
@@ -0,0 +1,27 @@
+@nodeset 
+label
+6
+5
+4
+3
+2
+1
+0
+@edgeset 
+                label      length
+5       6       9       4
+4       6       8       2
+3       5       7       1
+2       5       6       3
+2       6       5       5
+2       4       4       2
+1       4       3       3
+0       3       2       1
+0       2       1       2
+0       1       0       3
+@nodes 
+source 0
+target 6
+@edges 
+@attributes 
+@end
Index: demo/sub_graph_adaptor_demo.cc
===================================================================
--- demo/sub_graph_adaptor_demo.cc	(revision 2553)
+++ demo/sub_graph_adaptor_demo.cc	(revision 2553)
@@ -0,0 +1,125 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Computing maximum number of edge-disjoint shortest paths
+///
+/// This program computes a maximum number of edge-disjoint shortest paths
+/// between nodes \c s and \c t.
+///
+/// \include sub_graph_adaptor_demo.cc
+
+// Use a DIMACS max flow file as input.
+// sub_graph_adaptor_demo < dimacs_max_flow_file
+// Modified to eat lemon graph format! 
+
+
+#include <iostream>
+#include <fstream>
+
+#include <lemon/smart_graph.h>
+#include <lemon/dijkstra.h>
+#include <lemon/maps.h>
+#include <lemon/graph_adaptor.h>
+#include <lemon/dimacs.h>
+#include <lemon/preflow.h>
+#include "tight_edge_filter_map.h"
+
+#include <lemon/graph_reader.h>
+
+
+using namespace lemon;
+
+using std::cout;
+using std::endl;
+
+int main(int argc, char *argv[]) 
+{
+  if(argc<2)
+  {
+      std::cerr << "USAGE: sub_graph_adaptor_demo input_file.lgf" << std::endl;
+      std::cerr << "The file 'input_file.lgf' has to contain a max flow "
+		<< "instance in \n LEMON format "
+		<< "(e.g. sub_gad_input.lgf is such a file)." 
+		<< std::endl;
+      return 0;
+  }
+
+
+  //input stream to read the graph from
+  std::ifstream is(argv[1]);
+
+  typedef SmartGraph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeMap<int> LengthMap;
+
+  Graph g;
+  Node s, t;
+  LengthMap length(g);
+
+  //readDimacs(is, g, length, s, t);
+
+
+  GraphReader<SmartGraph> reader(is,g);
+  reader.readNode("source",s).readNode("target",t)
+    .readEdgeMap("length",length).run();
+
+  cout << "edges with lengths (of form id, source--length->target): " << endl;
+  for(EdgeIt e(g); e!=INVALID; ++e) 
+    cout << " " << g.id(e) << ", " << g.id(g.source(e)) << "--" 
+	 << length[e] << "->" << g.id(g.target(e)) << endl;
+
+  cout << "s: " << g.id(s) << " t: " << g.id(t) << endl;
+
+  typedef Dijkstra<Graph, LengthMap> Dijkstra;
+  Dijkstra dijkstra(g, length);
+  dijkstra.run(s);
+
+  // This map returns true exactly for those edges which are 
+  // tight w.r.t the length funcion and the potential 
+  // given by the dijkstra algorithm.
+  typedef TightEdgeFilterMap<Graph, const Dijkstra::DistMap, LengthMap> 
+    TightEdgeFilter;
+  TightEdgeFilter tight_edge_filter(g, dijkstra.distMap(), length);
+
+//  ConstMap<Node, bool> const_true_map(true);
+  // This graph contains exaclty the tight edges.
+// typedef SubGraphAdaptor<Graph, ConstMap<Node, bool>, TightEdgeFilter> SubGW;
+  typedef EdgeSubGraphAdaptor<Graph, TightEdgeFilter> SubGW;
+  SubGW gw(g, tight_edge_filter);
+
+  ConstMap<Edge, int> const_1_map(1);
+  // Max flow between s and t in the graph of tight edges.
+  Preflow<SubGW, ConstMap<Edge, int> > preflow(gw, const_1_map, s, t);
+  preflow.run();
+
+  cout << "maximum number of edge-disjoint shortest paths: " 
+       << preflow.flowValue() << endl;
+  cout << "edges of the maximum number of edge-disjoint shortest s-t paths: " 
+       << endl;
+  for(EdgeIt e(g); e!=INVALID; ++e) 
+    if (preflow.flow(e) != 0)
+      cout << " " << g.id(e) << ", "
+	   << g.id(g.source(e)) << "--" 
+	   << length[e] << "->" << g.id(g.target(e)) << endl;
+}
Index: demo/sub_graph_adaptor_demo.dim
===================================================================
--- demo/sub_graph_adaptor_demo.dim	(revision 1435)
+++ demo/sub_graph_adaptor_demo.dim	(revision 1435)
@@ -0,0 +1,14 @@
+c LEMON max flow problem
+p max 7 9
+n 1 s
+n 7 t
+a 1 2 3
+a 1 3 2
+a 1 4 1
+a 2 5 3
+a 3 5 2
+a 3 7 5
+a 3 6 3
+a 4 6 1
+a 5 7 2
+a 6 7 4
Index: demo/tight_edge_filter_map.h
===================================================================
--- demo/tight_edge_filter_map.h	(revision 2553)
+++ demo/tight_edge_filter_map.h	(revision 2553)
@@ -0,0 +1,72 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef DEMO_TIGHT_EDGE_FILTER_MAP_H
+#define DEMO_TIGHT_EDGE_FILTER_MAP_H
+
+#include <lemon/maps.h>
+
+/// \file
+/// \brief Tight edge filter map.
+///
+/// Tight edge filter map is bool map on the edges of the graph
+/// which filters the edges which are not tight for a node-potential.
+/// It is used in the \ref sub_graph_adaptor_demo.cc file. 
+///
+/// \include tight_edge_filter_map.h
+
+namespace lemon {
+
+  /// \brief A map for filtering the edge-set to those edges 
+  /// which are tight w.r.t. a node-potential and 
+  /// edge-distance.
+  /// 
+  /// Let \f$ G=(V,A) \f$ be a directed graph (graph for short) and 
+  /// let \f$ \mathbb{F} \f$ be a number type. 
+  /// Given a distance function 
+  /// \f$ d:E\to\mathbb{F} \f$, 
+  /// \f$ \pi:V\to\mathbb{F} \f$ is said to be a potetial 
+  /// w.r.t. \f$ d \f$ 
+  /// if and only if 
+  /// \f$ \pi(v)\le d(uv)+\pi(u) \f$ holds for each edge \f$ uv\in E \f$ 
+  /// (or the reverse inequality holds for each edge). 
+  /// An edge is said to be tight if this inequality holds with equality, 
+  /// and the map returns \c true exactly for those edges. 
+  /// To avoid rounding errors, it is recommended to use this class with exact 
+  /// number types, e.g. with \c int.
+  template<typename Graph, 
+	   typename NodePotentialMap, typename EdgeDistanceMap>
+  class TightEdgeFilterMap : public MapBase<typename Graph::Edge, bool> {
+  protected:
+    const Graph* g;
+    NodePotentialMap* node_potential;
+    EdgeDistanceMap* edge_distance;
+  public:
+    TightEdgeFilterMap(Graph& _g, NodePotentialMap& _node_potential, 
+		       EdgeDistanceMap& _edge_distance) : 
+      g(&_g), node_potential(&_node_potential), 
+      edge_distance(&_edge_distance) { }
+    bool operator[](const typename Graph::Edge& e) const {
+      return ((*node_potential)[g->target(e)] == 
+	      (*edge_distance)[e]+(*node_potential)[g->source(e)]);
+    }
+  };
+
+} //namespace lemon
+
+#endif //DEMO_TIGHT_EDGE_FILTER_MAP_H
Index: demo/topological_ordering.cc
===================================================================
--- demo/topological_ordering.cc	(revision 2553)
+++ demo/topological_ordering.cc	(revision 2553)
@@ -0,0 +1,115 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup demos
+///\file
+///\brief Demonstrating the Dfs class with topological ordering
+///
+///\include topological_ordering.cc
+
+#include <iostream>
+#include <string>
+#include <list>
+#include <lemon/list_graph.h>
+#include <lemon/maps.h>
+#include <lemon/dfs.h>
+
+using namespace lemon;
+
+
+template< typename GR >
+class SerializingWriteMap
+{
+public:
+  typedef typename GR::Node  Key;
+  typedef bool  Value;
+  typedef std::list<Key>  OrderedList;
+
+  OrderedList  order;
+
+  SerializingWriteMap( const GR& ) {}
+
+  void  set( const Key& k, const Value& v ) {
+    if( v ) order.push_front(k);
+  }
+
+  Value  operator[] ( const Key& ) {
+    return false;
+  }
+};
+
+
+int main()
+{
+  std::cout << "Topological Ordering demo" << std::endl;
+
+  // Create and build the graph
+  ListGraph  gr;
+  ListGraph::NodeMap<std::string>  label(gr);
+  typedef ListGraph::Node  Node;
+
+  // This DAG example for topological ordering is from the book New Algorithms
+  // (Thomas H. Cormen, Charles E. Leiserson, Ronald L. Rivest, Clifford Stein)
+  {
+    Node  belt = gr.addNode();
+    Node  trousers = gr.addNode();
+    Node  necktie = gr.addNode();
+    Node  coat = gr.addNode();
+    Node  socks = gr.addNode();
+    Node  shirt = gr.addNode();
+    Node  shoe = gr.addNode();
+    Node  watch = gr.addNode();
+    Node  pants = gr.addNode();
+
+    label[belt] = "Belt";
+    label[trousers] = "Trousers";
+    label[necktie] = "Necktie";
+    label[coat] = "Coat";
+    label[socks] = "Socks";
+    label[shirt] = "Shirt";
+    label[shoe] = "Shoe";
+    label[watch] = "Watch";
+    label[pants] = "Pants";
+
+    // Here we use a directed edge to indicate precedenc.
+    // The source must precede the target.
+    gr.addEdge( socks, shoe );
+    gr.addEdge( pants, shoe );
+    gr.addEdge( pants, trousers );
+    gr.addEdge( trousers, shoe );
+    gr.addEdge( trousers, belt );
+    gr.addEdge( belt, coat );
+    gr.addEdge( shirt, belt );
+    gr.addEdge( shirt, necktie );
+    gr.addEdge( necktie, coat );
+  }
+
+  // Calculate topological order
+  Dfs<ListGraph, Dfs<ListGraph>::DefProcessedMapTraits<SerializingWriteMap<ListGraph> > >  dfs(gr);
+  SerializingWriteMap<ListGraph>  list(gr);
+  dfs.processedMap(list);
+  dfs.run();
+
+  // Write out the result
+  std::cout << "One possible order to dress up:";
+  for( SerializingWriteMap<ListGraph>::OrderedList::iterator  it = list.order.begin(); it != list.order.end(); ++it )
+    std::cout << "  " << label[*it];
+  std::cout << std::endl;
+
+  return 0;
+}
Index: demo/topology_demo.cc
===================================================================
--- demo/topology_demo.cc	(revision 2553)
+++ demo/topology_demo.cc	(revision 2553)
@@ -0,0 +1,188 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/list_graph.h>
+#include <lemon/topology.h>
+#include <lemon/graph_to_eps.h>
+#include <lemon/graph_reader.h>
+#include <lemon/dim2.h>
+
+#include <iostream>
+
+#include <cstdlib>
+#include <ctime>
+
+/// \ingroup demos
+/// \file
+/// \brief Demo what shows the result of some topology functions.
+///
+///  Demo what shows the result of some topology functions.
+///
+/// \include topology_demo.cc
+
+using namespace lemon;
+using namespace lemon::dim2;
+using namespace std;
+
+
+Color color(bool val) {
+  return val ? RED : BLUE;
+}
+
+
+void drawConnectedComponents() {
+  typedef ListUGraph Graph;
+  typedef Graph::Node Node;
+
+  Graph graph;
+  Graph::NodeMap<Point<double> > coords(graph);
+
+  UGraphReader<Graph>("u_components.lgf", graph).
+    readNodeMap("coordinates_x", xMap(coords)).
+    readNodeMap("coordinates_y", yMap(coords)).
+    run();
+  
+  Palette palette;
+
+  Graph::NodeMap<int> compMap(graph);
+  connectedComponents(graph, compMap);
+
+  graphToEps(graph, "connected_components.eps").undirected().
+    coords(coords).scaleToA4().enableParallel().
+    nodeColors(composeMap(palette, compMap)).run();
+
+  std::cout << "Result: connected_components.eps" << std::endl;
+}
+
+void drawStronglyConnectedComponents() {
+  typedef ListGraph Graph;
+  typedef Graph::Node Node;
+
+  Graph graph;
+  Graph::NodeMap<Point<double> > coords(graph);
+
+  GraphReader<Graph>("dir_components.lgf", graph).
+    readNodeMap("coordinates_x", xMap(coords)).
+    readNodeMap("coordinates_y", yMap(coords)).
+    run();
+  
+  Palette palette;
+
+  Graph::NodeMap<int> compMap(graph);
+  Graph::EdgeMap<bool> cutMap(graph);
+  stronglyConnectedComponents(graph, compMap);
+  stronglyConnectedCutEdges(graph, cutMap);
+
+  graphToEps(graph, "strongly_connected_components.eps").
+    coords(coords).scaleToA4().enableParallel().drawArrows().
+    nodeColors(composeMap(palette, compMap)).
+    edgeColors(composeMap(functorMap(&color), cutMap)).run();
+
+  std::cout << "Result: strongly_connected_components.eps" << std::endl;
+}
+
+void drawNodeBiconnectedComponents() {
+  typedef ListUGraph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::UEdge UEdge;
+
+  Graph graph;
+  Graph::NodeMap<Point<double> > coords(graph);
+
+  UGraphReader<Graph>("u_components.lgf", graph).
+    readNodeMap("coordinates_x", xMap(coords)).
+    readNodeMap("coordinates_y", yMap(coords)).
+    run();
+
+  Palette palette;
+
+  Graph::UEdgeMap<int> compMap(graph);
+  Graph::NodeMap<bool> cutMap(graph);
+  biNodeConnectedComponents(graph, compMap);
+  biNodeConnectedCutNodes(graph, cutMap);
+
+  graphToEps(graph, "bi_node_connected_components.eps").undirected().
+    coords(coords).scaleToA4().enableParallel().
+    edgeColors(composeMap(palette, compMap)).
+    nodeColors(composeMap(functorMap(&color), cutMap)).
+    run();
+
+  std::cout << "Result: bi_node_connected_components.eps" << std::endl;
+}
+
+void drawEdgeBiconnectedComponents() {
+  typedef ListUGraph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::UEdge UEdge;
+
+  Graph graph;
+  Graph::NodeMap<Point<double> > coords(graph);
+
+  UGraphReader<Graph>("u_components.lgf", graph).
+    readNodeMap("coordinates_x", xMap(coords)).
+    readNodeMap("coordinates_y", yMap(coords)).
+    run();
+  
+  Palette palette;
+
+  Graph::NodeMap<int> compMap(graph);
+  Graph::UEdgeMap<bool> cutMap(graph);
+  biEdgeConnectedComponents(graph, compMap);
+  biEdgeConnectedCutEdges(graph, cutMap);
+
+  graphToEps(graph, "bi_edge_connected_components.eps").undirected().
+    coords(coords).scaleToA4().enableParallel().
+    nodeColors(composeMap(palette, compMap)).
+    edgeColors(composeMap(functorMap(&color), cutMap)).run();
+  
+  std::cout << "Result: bi_edge_connected_components.eps" << std::endl;
+}
+
+void drawBipartitePartitions() {
+  typedef ListUGraph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::UEdge UEdge;
+
+  Graph graph;
+  Graph::NodeMap<Point<double> > coords(graph);
+
+  UGraphReader<Graph>("partitions.lgf", graph).
+    readNodeMap("coordinates_x", xMap(coords)).
+    readNodeMap("coordinates_y", yMap(coords)).
+    run();
+  
+  Palette palette;
+
+  Graph::NodeMap<bool> partMap(graph);
+  bipartitePartitions(graph, partMap);
+
+  graphToEps(graph, "bipartite_partitions.eps").undirected().
+    coords(coords).scaleToA4().enableParallel().
+    nodeColors(composeMap(functorMap(&color), partMap)).run();
+  
+  std::cout << "Result: bipartite_partitions.eps" << std::endl;
+} 
+
+int main() {
+  drawConnectedComponents();
+  drawStronglyConnectedComponents();
+  drawNodeBiconnectedComponents();
+  drawEdgeBiconnectedComponents();
+  drawBipartitePartitions();
+  return 0;
+}
Index: demo/u_components.lgf
===================================================================
--- demo/u_components.lgf	(revision 1969)
+++ demo/u_components.lgf	(revision 1969)
@@ -0,0 +1,103 @@
+@nodeset 
+coordinates_x	coordinates_y	label	
+574.035	177.301	44	
+694.579	115.483	43	
+280.402	10.3938	42	
+212.403	-23.6057	41	
+286.584	-48.3327	40	
+438.037	-88.514	39	
+397.855	-196.694	38	
+366.947	-110.15	37	
+271.13	-175.058	36	
+277.311	-252.33	35	
+206.221	-205.967	34	
+-840.856	-246.718	18	
+-579.033	445.603	17	
+-767.847	113.289	16	
+906.312	201.403	15	
+986.873	-115.807	14	
+-470.779	158.605	13	
+422.945	521.129	12	
+-5.03507	561.41	11	
+329.797	314.692	10	
+-67.9734	319.727	9	
+762.812	-17.6227	8	
+526.164	32.7279	7	
+730.084	-307.139	6	
+415.393	-289.516	5	
+-67.9734	-347.42	4	
+-309.657	-57.9033	3	
+-323.543	-433.964	2	
+-539.894	-262.64	1	
+-26.6953	-19.9585	19	
+116.407	-173.66	20	
+201.208	38.3422	21	
+-262.548	107.243	22	
+-13.4452	133.743	23	
+-180.397	245.045	24	
+-416.25	345.746	26	
+-132.697	451.748	27	
+-371.2	568.349	28	
+670.264	274.195	29	
+588.113	544.499	30	
+924.667	409.347	31	
+-689.204	-237.261	32	
+-567.302	43.6423	33	
+@uedgeset 
+		label	
+41	42	44	
+40	42	43	
+37	40	49	
+36	40	47	
+41	40	42	
+38	39	46	
+38	37	53	
+36	37	48	
+39	37	45	
+35	36	51	
+34	36	50	
+34	35	52	
+16	17	1	
+18	16	2	
+14	15	3	
+8	15	4	
+8	14	5	
+17	13	6	
+16	13	7	
+3	13	8	
+11	12	9	
+10	12	10	
+9	11	11	
+9	10	12	
+6	8	13	
+7	8	14	
+5	7	15	
+9	7	16	
+12	7	17	
+5	6	18	
+4	5	19	
+2	4	20	
+1	3	21	
+4	3	22	
+1	2	23	
+22	19	24	
+19	20	25	
+21	20	26	
+19	21	27	
+22	23	28	
+19	23	29	
+22	24	30	
+23	24	31	
+26	27	32	
+24	27	33	
+24	27	34	
+27	28	35	
+26	28	36	
+44	29	55	
+43	29	54	
+29	30	37	
+29	31	38	
+30	31	39	
+32	33	40	
+32	33	41	
+@end
Index: doc/Doxyfile.in
===================================================================
--- doc/Doxyfile.in	(revision 2649)
+++ doc/Doxyfile.in	(revision 2627)
@@ -1,1226 +1,265 @@
-# Doxyfile 1.4.2
+# Doxyfile 1.5.7.1
 
-# This file describes the settings to be used by the documentation system
-# doxygen (www.doxygen.org) for a project
-#
-# All text after a hash (#) is considered a comment and will be ignored
-# The format is:
-#       TAG = value [value, ...]
-# For lists items can also be appended using:
-#       TAG += value [value, ...]
-# Values that contain spaces should be placed between quotes (" ")
-
 #---------------------------------------------------------------------------
 # Project related configuration options
 #---------------------------------------------------------------------------
-
-# The PROJECT_NAME tag is a single word (or a sequence of words surrounded 
-# by quotes) that should identify the project.
-
+DOXYFILE_ENCODING      = UTF-8
 PROJECT_NAME           = @PACKAGE_NAME@
-
-# The PROJECT_NUMBER tag can be used to enter a project or revision number. 
-# This could be handy for archiving the generated documentation or 
-# if some version control system is used.
-
 PROJECT_NUMBER         = @PACKAGE_VERSION@
-
-# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) 
-# base path where the generated documentation will be put. 
-# If a relative path is entered, it will be relative to the location 
-# where doxygen was started. If left blank the current directory will be used.
-
 OUTPUT_DIRECTORY       = 
-
-# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 
-# 4096 sub-directories (in 2 levels) under the output directory of each output 
-# format and will distribute the generated files over these directories. 
-# Enabling this option can be useful when feeding doxygen a huge amount of 
-# source files, where putting all generated files in the same directory would 
-# otherwise cause performance problems for the file system.
-
 CREATE_SUBDIRS         = NO
-
-# The OUTPUT_LANGUAGE tag is used to specify the language in which all 
-# documentation generated by doxygen is written. Doxygen will use this 
-# information to generate all constant output in the proper language. 
-# The default language is English, other supported languages are: 
-# Brazilian, Catalan, Chinese, Chinese-Traditional, Croatian, Czech, Danish, 
-# Dutch, Finnish, French, German, Greek, Hungarian, Italian, Japanese, 
-# Japanese-en (Japanese with English messages), Korean, Korean-en, Norwegian, 
-# Polish, Portuguese, Romanian, Russian, Serbian, Slovak, Slovene, Spanish, 
-# Swedish, and Ukrainian.
-
 OUTPUT_LANGUAGE        = English
-
-# This tag can be used to specify the encoding used in the generated output. 
-# The encoding is not always determined by the language that is chosen, 
-# but also whether or not the output is meant for Windows or non-Windows users. 
-# In case there is a difference, setting the USE_WINDOWS_ENCODING tag to YES 
-# forces the Windows encoding (this is the default for the Windows binary), 
-# whereas setting the tag to NO uses a Unix-style encoding (the default for 
-# all platforms other than Windows).
-
-USE_WINDOWS_ENCODING   = NO
-
-# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will 
-# include brief member descriptions after the members that are listed in 
-# the file and class documentation (similar to JavaDoc). 
-# Set to NO to disable this.
-
 BRIEF_MEMBER_DESC      = YES
-
-# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend 
-# the brief description of a member or function before the detailed description. 
-# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the 
-# brief descriptions will be completely suppressed.
-
 REPEAT_BRIEF           = NO
-
-# This tag implements a quasi-intelligent brief description abbreviator 
-# that is used to form the text in various listings. Each string 
-# in this list, if found as the leading text of the brief description, will be 
-# stripped from the text and the result after processing the whole list, is 
-# used as the annotated text. Otherwise, the brief description is used as-is. 
-# If left blank, the following values are used ("$name" is automatically 
-# replaced with the name of the entity): "The $name class" "The $name widget" 
-# "The $name file" "is" "provides" "specifies" "contains" 
-# "represents" "a" "an" "the"
-
 ABBREVIATE_BRIEF       = 
-
-# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then 
-# Doxygen will generate a detailed section even if there is only a brief 
-# description.
-
 ALWAYS_DETAILED_SEC    = NO
-
-# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all 
-# inherited members of a class in the documentation of that class as if those 
-# members were ordinary class members. Constructors, destructors and assignment 
-# operators of the base classes will not be shown.
-
 INLINE_INHERITED_MEMB  = NO
-
-# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full 
-# path before files name in the file list and in the header files. If set 
-# to NO the shortest path that makes the file name unique will be used.
-
 FULL_PATH_NAMES        = YES
-
-# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag 
-# can be used to strip a user-defined part of the path. Stripping is 
-# only done if one of the specified strings matches the left-hand part of 
-# the path. The tag can be used to show relative paths in the file list. 
-# If left blank the directory from which doxygen is run is used as the 
-# path to strip.
-
-STRIP_FROM_PATH        = @abs_top_srcdir@
-
-# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of 
-# the path mentioned in the documentation of a class, which tells 
-# the reader which header file to include in order to use a class. 
-# If left blank only the name of the header file containing the class 
-# definition is used. Otherwise one should specify the include paths that 
-# are normally passed to the compiler using the -I flag.
-
-STRIP_FROM_INC_PATH    = @abs_top_srcdir@
-
-# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter 
-# (but less readable) file names. This can be useful is your file systems 
-# doesn't support long names like on DOS, Mac, or CD-ROM.
-
+STRIP_FROM_PATH        = "@abs_top_srcdir@"
+STRIP_FROM_INC_PATH    = "@abs_top_srcdir@"
 SHORT_NAMES            = YES
-
-# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen 
-# will interpret the first line (until the first dot) of a JavaDoc-style 
-# comment as the brief description. If set to NO, the JavaDoc 
-# comments will behave just like the Qt-style comments (thus requiring an 
-# explicit @brief command for a brief description.
-
 JAVADOC_AUTOBRIEF      = NO
-
-# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen 
-# treat a multi-line C++ special comment block (i.e. a block of //! or /// 
-# comments) as a brief description. This used to be the default behaviour. 
-# The new default is to treat a multi-line C++ comment block as a detailed 
-# description. Set this tag to YES if you prefer the old behaviour instead.
-
+QT_AUTOBRIEF           = NO
 MULTILINE_CPP_IS_BRIEF = NO
-
-# If the DETAILS_AT_TOP tag is set to YES then Doxygen 
-# will output the detailed description near the top, like JavaDoc.
-# If set to NO, the detailed description appears after the member 
-# documentation.
-
 DETAILS_AT_TOP         = YES
-
-# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented 
-# member inherits the documentation from any documented member that it 
-# re-implements.
-
 INHERIT_DOCS           = NO
-
-# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC 
-# tag is set to YES, then doxygen will reuse the documentation of the first 
-# member in the group (if any) for the other members of the group. By default 
-# all members of a group must be documented explicitly.
-
+SEPARATE_MEMBER_PAGES  = NO
+TAB_SIZE               = 8
+ALIASES                = 
+OPTIMIZE_OUTPUT_FOR_C  = NO
+OPTIMIZE_OUTPUT_JAVA   = NO
+OPTIMIZE_FOR_FORTRAN   = NO
+OPTIMIZE_OUTPUT_VHDL   = NO
+BUILTIN_STL_SUPPORT    = YES
+CPP_CLI_SUPPORT        = NO
+SIP_SUPPORT            = NO
+IDL_PROPERTY_SUPPORT   = YES
 DISTRIBUTE_GROUP_DOC   = NO
-
-# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce 
-# a new page for each member. If set to NO, the documentation of a member will 
-# be part of the file/class/namespace that contains it.
-
-SEPARATE_MEMBER_PAGES  = NO
-
-# The TAB_SIZE tag can be used to set the number of spaces in a tab. 
-# Doxygen uses this value to replace tabs by spaces in code fragments.
-
-TAB_SIZE               = 8
-
-# This tag can be used to specify a number of aliases that acts 
-# as commands in the documentation. An alias has the form "name=value". 
-# For example adding "sideeffect=\par Side Effects:\n" will allow you to 
-# put the command \sideeffect (or @sideeffect) in the documentation, which 
-# will result in a user-defined paragraph with heading "Side Effects:". 
-# You can put \n's in the value part of an alias to insert newlines.
-
-ALIASES                = 
-
-# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C 
-# sources only. Doxygen will then generate output that is more tailored for C. 
-# For instance, some of the names that are used will be different. The list 
-# of all members will be omitted, etc.
-
-OPTIMIZE_OUTPUT_FOR_C  = NO
-
-# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java sources 
-# only. Doxygen will then generate output that is more tailored for Java. 
-# For instance, namespaces will be presented as packages, qualified scopes 
-# will look different, etc.
-
-OPTIMIZE_OUTPUT_JAVA   = NO
-
-# Set the SUBGROUPING tag to YES (the default) to allow class member groups of 
-# the same type (for instance a group of public functions) to be put as a 
-# subgroup of that type (e.g. under the Public Functions section). Set it to 
-# NO to prevent subgrouping. Alternatively, this can be done per class using 
-# the \nosubgrouping command.
-
 SUBGROUPING            = YES
-
+TYPEDEF_HIDES_STRUCT   = NO
+SYMBOL_CACHE_SIZE      = 0
 #---------------------------------------------------------------------------
 # Build related configuration options
 #---------------------------------------------------------------------------
-
-# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in 
-# documentation are documented, even if no documentation was available. 
-# Private class members and static file members will be hidden unless 
-# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES
-
 EXTRACT_ALL            = NO
-
-# If the EXTRACT_PRIVATE tag is set to YES all private members of a class 
-# will be included in the documentation.
-
-EXTRACT_PRIVATE        = NO
-
-# If the EXTRACT_STATIC tag is set to YES all static members of a file 
-# will be included in the documentation.
-
-EXTRACT_STATIC         = NO
-
-# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) 
-# defined locally in source files will be included in the documentation. 
-# If set to NO only classes defined in header files are included.
-
+EXTRACT_PRIVATE        = YES
+EXTRACT_STATIC         = YES
 EXTRACT_LOCAL_CLASSES  = NO
-
-# This flag is only useful for Objective-C code. When set to YES local 
-# methods, which are defined in the implementation section but not in 
-# the interface are included in the documentation. 
-# If set to NO (the default) only methods in the interface are included.
-
 EXTRACT_LOCAL_METHODS  = NO
-
-# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all 
-# undocumented members of documented classes, files or namespaces. 
-# If set to NO (the default) these members will be included in the 
-# various overviews, but no documentation section is generated. 
-# This option has no effect if EXTRACT_ALL is enabled.
-
+EXTRACT_ANON_NSPACES   = NO
 HIDE_UNDOC_MEMBERS     = YES
-
-# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all 
-# undocumented classes that are normally visible in the class hierarchy. 
-# If set to NO (the default) these classes will be included in the various 
-# overviews. This option has no effect if EXTRACT_ALL is enabled.
-
 HIDE_UNDOC_CLASSES     = YES
-
-# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all 
-# friend (class|struct|union) declarations. 
-# If set to NO (the default) these declarations will be included in the 
-# documentation.
-
 HIDE_FRIEND_COMPOUNDS  = NO
-
-# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any 
-# documentation blocks found inside the body of a function. 
-# If set to NO (the default) these blocks will be appended to the 
-# function's detailed documentation block.
-
 HIDE_IN_BODY_DOCS      = NO
-
-# The INTERNAL_DOCS tag determines if documentation 
-# that is typed after a \internal command is included. If the tag is set 
-# to NO (the default) then the documentation will be excluded. 
-# Set it to YES to include the internal documentation.
-
-INTERNAL_DOCS          = @DOXYGEN_INTERNAL_DOCS@
-
-# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate 
-# file names in lower-case letters. If set to YES upper-case letters are also 
-# allowed. This is useful if you have classes or files whose names only differ 
-# in case and if your file system supports case sensitive file names. Windows 
-# and Mac users are advised to set this option to NO.
-
+INTERNAL_DOCS          = NO
 CASE_SENSE_NAMES       = YES
-
-# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen 
-# will show members with their full class and namespace scopes in the 
-# documentation. If set to YES the scope will be hidden.
-
 HIDE_SCOPE_NAMES       = YES
-
-# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen 
-# will put a list of the files that are included by a file in the documentation 
-# of that file.
-
 SHOW_INCLUDE_FILES     = YES
-
-# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] 
-# is inserted in the documentation for inline members.
-
 INLINE_INFO            = YES
-
-# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen 
-# will sort the (detailed) documentation of file and class members 
-# alphabetically by member name. If set to NO the members will appear in 
-# declaration order.
-
 SORT_MEMBER_DOCS       = NO
-
-# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the 
-# brief documentation of file, namespace and class members alphabetically 
-# by member name. If set to NO (the default) the members will appear in 
-# declaration order.
-
 SORT_BRIEF_DOCS        = NO
-
-# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be 
-# sorted by fully-qualified names, including namespaces. If set to 
-# NO (the default), the class list will be sorted only by class name, 
-# not including the namespace part. 
-# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES.
-# Note: This option applies only to the class list, not to the 
-# alphabetical list.
-
+SORT_GROUP_NAMES       = NO
 SORT_BY_SCOPE_NAME     = NO
-
-# The GENERATE_TODOLIST tag can be used to enable (YES) or 
-# disable (NO) the todo list. This list is created by putting \todo 
-# commands in the documentation.
-
 GENERATE_TODOLIST      = YES
-
-# The GENERATE_TESTLIST tag can be used to enable (YES) or 
-# disable (NO) the test list. This list is created by putting \test 
-# commands in the documentation.
-
 GENERATE_TESTLIST      = YES
-
-# The GENERATE_BUGLIST tag can be used to enable (YES) or 
-# disable (NO) the bug list. This list is created by putting \bug 
-# commands in the documentation.
-
 GENERATE_BUGLIST       = YES
-
-# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or 
-# disable (NO) the deprecated list. This list is created by putting 
-# \deprecated commands in the documentation.
-
 GENERATE_DEPRECATEDLIST= YES
-
-# The ENABLED_SECTIONS tag can be used to enable conditional 
-# documentation sections, marked by \if sectionname ... \endif.
-
 ENABLED_SECTIONS       = 
-
-# The MAX_INITIALIZER_LINES tag determines the maximum number of lines 
-# the initial value of a variable or define consists of for it to appear in 
-# the documentation. If the initializer consists of more lines than specified 
-# here it will be hidden. Use a value of 0 to hide initializers completely. 
-# The appearance of the initializer of individual variables and defines in the 
-# documentation can be controlled using \showinitializer or \hideinitializer 
-# command in the documentation regardless of this setting.
-
 MAX_INITIALIZER_LINES  = 5
-
-# Set the SHOW_USED_FILES tag to NO to disable the list of files generated 
-# at the bottom of the documentation of classes and structs. If set to YES the 
-# list will mention the files that were used to generate the documentation.
-
-SHOW_USED_FILES        = YES
-
-# If the sources in your project are distributed over multiple directories 
-# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy 
-# in the documentation.
-
+SHOW_USED_FILES        = NO
 SHOW_DIRECTORIES       = YES
-
-# The FILE_VERSION_FILTER tag can be used to specify a program or script that 
-# doxygen should invoke to get the current version for each file (typically from the 
-# version control system). Doxygen will invoke the program by executing (via 
-# popen()) the command <command> <input-file>, where <command> is the value of 
-# the FILE_VERSION_FILTER tag, and <input-file> is the name of an input file 
-# provided by doxygen. Whatever the progam writes to standard output 
-# is used as the file version. See the manual for examples.
-
+SHOW_FILES             = YES
+SHOW_NAMESPACES        = YES
 FILE_VERSION_FILTER    = 
-
+LAYOUT_FILE            = DoxygenLayout.xml
 #---------------------------------------------------------------------------
 # configuration options related to warning and progress messages
 #---------------------------------------------------------------------------
-
-# The QUIET tag can be used to turn on/off the messages that are generated 
-# by doxygen. Possible values are YES and NO. If left blank NO is used.
-
 QUIET                  = NO
-
-# The WARNINGS tag can be used to turn on/off the warning messages that are 
-# generated by doxygen. Possible values are YES and NO. If left blank 
-# NO is used.
-
 WARNINGS               = YES
-
-# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings 
-# for undocumented members. If EXTRACT_ALL is set to YES then this flag will 
-# automatically be disabled.
-
 WARN_IF_UNDOCUMENTED   = YES
-
-# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for 
-# potential errors in the documentation, such as not documenting some 
-# parameters in a documented function, or documenting parameters that 
-# don't exist or using markup commands wrongly.
-
 WARN_IF_DOC_ERROR      = YES
-
-# This WARN_NO_PARAMDOC option can be abled to get warnings for 
-# functions that are documented, but have no documentation for their parameters 
-# or return value. If set to NO (the default) doxygen will only warn about 
-# wrong or incomplete parameter documentation, but not about the absence of 
-# documentation.
-
 WARN_NO_PARAMDOC       = NO
-
-# The WARN_FORMAT tag determines the format of the warning messages that 
-# doxygen can produce. The string should contain the $file, $line, and $text 
-# tags, which will be replaced by the file and line number from which the 
-# warning originated and the warning text. Optionally the format may contain 
-# $version, which will be replaced by the version of the file (if it could 
-# be obtained via FILE_VERSION_FILTER)
-
 WARN_FORMAT            = "$file:$line: $text"
-
-# The WARN_LOGFILE tag can be used to specify a file to which warning 
-# and error messages should be written. If left blank the output is written 
-# to stderr.
-
 WARN_LOGFILE           = doxygen.log
-
 #---------------------------------------------------------------------------
 # configuration options related to the input files
 #---------------------------------------------------------------------------
-
-# The INPUT tag can be used to specify the files and/or directories that contain 
-# documented source files. You may enter file names like "myfile.cpp" or 
-# directories like "/usr/src/myproject". Separate the files or directories 
-# with spaces.
-
-INPUT                  = @abs_top_srcdir@/doc \
-                         @abs_top_srcdir@/lemon \
-                         @abs_top_srcdir@/lemon/bits \
-                         @abs_top_srcdir@/lemon/concept \
-                         @abs_top_srcdir@/demo \
-#                         @abs_top_srcdir@/test/test_tools.h
-
-# If the value of the INPUT tag contains directories, you can use the 
-# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 
-# and *.h) to filter out the source-files in the directories. If left 
-# blank the following patterns are tested: 
-# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx 
-# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm
-
-FILE_PATTERNS          = *.h *.cc *.dox
-
-# The RECURSIVE tag can be used to turn specify whether or not subdirectories 
-# should be searched for input files as well. Possible values are YES and NO. 
-# If left blank NO is used.
-
+INPUT                  = "@abs_top_srcdir@/doc" \
+                         "@abs_top_srcdir@/lemon" \
+                         "@abs_top_srcdir@/lemon/bits" \
+                         "@abs_top_srcdir@/lemon/concepts" \
+                         "@abs_top_srcdir@/demo" \
+                         "@abs_top_srcdir@/tools" \
+                         "@abs_top_srcdir@/test/test_tools.h"
+INPUT_ENCODING         = UTF-8
+FILE_PATTERNS          = *.h \
+                         *.cc \
+                         *.dox
 RECURSIVE              = NO
-
-# The EXCLUDE tag can be used to specify files and/or directories that should 
-# excluded from the INPUT source files. This way you can easily exclude a 
-# subdirectory from a directory tree whose root is specified with the INPUT tag.
-
 EXCLUDE                = 
-
-# The EXCLUDE_SYMLINKS tag can be used select whether or not files or 
-# directories that are symbolic links (a Unix filesystem feature) are excluded 
-# from the input.
-
 EXCLUDE_SYMLINKS       = NO
-
-# If the value of the INPUT tag contains directories, you can use the 
-# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude 
-# certain files from those directories.
-
 EXCLUDE_PATTERNS       = 
-
-# The EXAMPLE_PATH tag can be used to specify one or more files or 
-# directories that contain example code fragments that are included (see 
-# the \include command).
-
-EXAMPLE_PATH           = ../demo \
-                         ../LICENSE \
-                         .
-
-# If the value of the EXAMPLE_PATH tag contains directories, you can use the 
-# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 
-# and *.h) to filter out the source-files in the directories. If left 
-# blank all files are included.
-
+EXCLUDE_SYMBOLS        = 
+EXAMPLE_PATH           = "@abs_top_srcdir@/demo" \
+                         "@abs_top_srcdir@/LICENSE" \
+                         "@abs_top_srcdir@/doc"
 EXAMPLE_PATTERNS       = 
-
-# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be 
-# searched for input files to be used with the \include or \dontinclude 
-# commands irrespective of the value of the RECURSIVE tag. 
-# Possible values are YES and NO. If left blank NO is used.
-
 EXAMPLE_RECURSIVE      = NO
-
-# The IMAGE_PATH tag can be used to specify one or more files or 
-# directories that contain image that are included in the documentation (see 
-# the \image command).
-
-IMAGE_PATH             = images
-
-# The INPUT_FILTER tag can be used to specify a program that doxygen should 
-# invoke to filter for each input file. Doxygen will invoke the filter program 
-# by executing (via popen()) the command <filter> <input-file>, where <filter> 
-# is the value of the INPUT_FILTER tag, and <input-file> is the name of an 
-# input file. Doxygen will then use the output that the filter program writes 
-# to standard output.  If FILTER_PATTERNS is specified, this tag will be 
-# ignored.
-
+IMAGE_PATH             = "@abs_top_srcdir@/doc/images"
 INPUT_FILTER           = 
-
-# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern 
-# basis.  Doxygen will compare the file name with each pattern and apply the 
-# filter if there is a match.  The filters are a list of the form: 
-# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further 
-# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER 
-# is applied to all files.
-
 FILTER_PATTERNS        = 
-
-# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using 
-# INPUT_FILTER) will be used to filter the input files when producing source 
-# files to browse (i.e. when SOURCE_BROWSER is set to YES).
-
 FILTER_SOURCE_FILES    = NO
-
 #---------------------------------------------------------------------------
 # configuration options related to source browsing
 #---------------------------------------------------------------------------
-
-# If the SOURCE_BROWSER tag is set to YES then a list of source files will 
-# be generated. Documented entities will be cross-referenced with these sources. 
-# Note: To get rid of all source code in the generated output, make sure also 
-# VERBATIM_HEADERS is set to NO.
-
 SOURCE_BROWSER         = NO
-
-# Setting the INLINE_SOURCES tag to YES will include the body 
-# of functions and classes directly in the documentation.
-
 INLINE_SOURCES         = NO
-
-# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct 
-# doxygen to hide any special comment blocks from generated source code 
-# fragments. Normal C and C++ comments will always remain visible.
-
 STRIP_CODE_COMMENTS    = YES
-
-# If the REFERENCED_BY_RELATION tag is set to YES (the default) 
-# then for each documented function all documented 
-# functions referencing it will be listed.
-
 REFERENCED_BY_RELATION = NO
-
-# If the REFERENCES_RELATION tag is set to YES (the default) 
-# then for each documented function all documented entities 
-# called/used by that function will be listed.
-
 REFERENCES_RELATION    = NO
-
-# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen 
-# will generate a verbatim copy of the header file for each class for 
-# which an include is specified. Set to NO to disable this.
-
-VERBATIM_HEADERS       = YES
-
+REFERENCES_LINK_SOURCE = YES
+USE_HTAGS              = NO
+VERBATIM_HEADERS       = NO
 #---------------------------------------------------------------------------
 # configuration options related to the alphabetical class index
 #---------------------------------------------------------------------------
-
-# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index 
-# of all compounds will be generated. Enable this if the project 
-# contains a lot of classes, structs, unions or interfaces.
-
 ALPHABETICAL_INDEX     = YES
-
-# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then 
-# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns 
-# in which this list will be split (can be a number in the range [1..20])
-
 COLS_IN_ALPHA_INDEX    = 2
-
-# In case all classes in a project start with a common prefix, all 
-# classes will be put under the same header in the alphabetical index. 
-# The IGNORE_PREFIX tag can be used to specify one or more prefixes that 
-# should be ignored while generating the index headers.
-
 IGNORE_PREFIX          = 
-
 #---------------------------------------------------------------------------
 # configuration options related to the HTML output
 #---------------------------------------------------------------------------
-
-# If the GENERATE_HTML tag is set to YES (the default) Doxygen will 
-# generate HTML output.
-
 GENERATE_HTML          = YES
-
-# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `html' will be used as the default path.
-
 HTML_OUTPUT            = html
-
-# The HTML_FILE_EXTENSION tag can be used to specify the file extension for 
-# each generated HTML page (for example: .htm,.php,.asp). If it is left blank 
-# doxygen will generate files with .html extension.
-
 HTML_FILE_EXTENSION    = .html
-
-# The HTML_HEADER tag can be used to specify a personal HTML header for 
-# each generated HTML page. If it is left blank doxygen will generate a 
-# standard header.
-
 HTML_HEADER            = 
-
-# The HTML_FOOTER tag can be used to specify a personal HTML footer for 
-# each generated HTML page. If it is left blank doxygen will generate a 
-# standard footer.
-
 HTML_FOOTER            = 
-
-# The HTML_STYLESHEET tag can be used to specify a user-defined cascading 
-# style sheet that is used by each HTML page. It can be used to 
-# fine-tune the look of the HTML output. If the tag is left blank doxygen 
-# will generate a default style sheet. Note that doxygen will try to copy 
-# the style sheet file to the HTML output directory, so don't put your own 
-# stylesheet in the HTML output directory as well, or it will be erased!
-
 HTML_STYLESHEET        = 
-
-# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, 
-# files or namespaces will be aligned in HTML using tables. If set to 
-# NO a bullet list will be used.
-
 HTML_ALIGN_MEMBERS     = YES
-
-# If the GENERATE_HTMLHELP tag is set to YES, additional index files 
-# will be generated that can be used as input for tools like the 
-# Microsoft HTML help workshop to generate a compressed HTML help file (.chm) 
-# of the generated HTML documentation.
-
+HTML_DYNAMIC_SECTIONS  = NO
+GENERATE_DOCSET        = NO
+DOCSET_FEEDNAME        = "Doxygen generated docs"
+DOCSET_BUNDLE_ID       = org.doxygen.Project
 GENERATE_HTMLHELP      = NO
-
-# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can 
-# be used to specify the file name of the resulting .chm file. You 
-# can add a path in front of the file if the result should not be 
-# written to the html output directory.
-
 CHM_FILE               = 
-
-# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can 
-# be used to specify the location (absolute path including file name) of 
-# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run 
-# the HTML help compiler on the generated index.hhp.
-
 HHC_LOCATION           = 
-
-# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag 
-# controls if a separate .chi index file is generated (YES) or that 
-# it should be included in the master .chm file (NO).
-
 GENERATE_CHI           = NO
-
-# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag 
-# controls whether a binary table of contents is generated (YES) or a 
-# normal table of contents (NO) in the .chm file.
-
+CHM_INDEX_ENCODING     = 
 BINARY_TOC             = NO
-
-# The TOC_EXPAND flag can be set to YES to add extra items for group members 
-# to the contents of the HTML help documentation and to the tree view.
-
 TOC_EXPAND             = NO
-
-# The DISABLE_INDEX tag can be used to turn on/off the condensed index at 
-# top of each HTML page. The value NO (the default) enables the index and 
-# the value YES disables it.
-
+GENERATE_QHP           = NO
+QCH_FILE               = 
+QHP_NAMESPACE          = org.doxygen.Project
+QHP_VIRTUAL_FOLDER     = doc
+QHG_LOCATION           = 
 DISABLE_INDEX          = NO
-
-# This tag can be used to set the number of enum values (range [1..20]) 
-# that doxygen will group on one line in the generated HTML documentation.
-
 ENUM_VALUES_PER_LINE   = 4
-
-# If the GENERATE_TREEVIEW tag is set to YES, a side panel will be
-# generated containing a tree-like index structure (just like the one that 
-# is generated for HTML Help). For this to work a browser that supports 
-# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+, 
-# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are 
-# probably better off using the HTML help feature.
-
-GENERATE_TREEVIEW      = YES
-
-# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be 
-# used to set the initial width (in pixels) of the frame in which the tree 
-# is shown.
-
+GENERATE_TREEVIEW      = NO
 TREEVIEW_WIDTH         = 250
-
+FORMULA_FONTSIZE       = 10
 #---------------------------------------------------------------------------
 # configuration options related to the LaTeX output
 #---------------------------------------------------------------------------
-
-# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will 
-# generate Latex output.
-
 GENERATE_LATEX         = NO
-
-# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `latex' will be used as the default path.
-
 LATEX_OUTPUT           = latex
-
-# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be 
-# invoked. If left blank `latex' will be used as the default command name.
-
 LATEX_CMD_NAME         = latex
-
-# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to 
-# generate index for LaTeX. If left blank `makeindex' will be used as the 
-# default command name.
-
 MAKEINDEX_CMD_NAME     = makeindex
-
-# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact 
-# LaTeX documents. This may be useful for small projects and may help to 
-# save some trees in general.
-
 COMPACT_LATEX          = YES
-
-# The PAPER_TYPE tag can be used to set the paper type that is used 
-# by the printer. Possible values are: a4, a4wide, letter, legal and 
-# executive. If left blank a4wide will be used.
-
 PAPER_TYPE             = a4wide
-
-# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX 
-# packages that should be included in the LaTeX output.
-
 EXTRA_PACKAGES         = amsmath \
                          amssymb
-
-# The LATEX_HEADER tag can be used to specify a personal LaTeX header for 
-# the generated latex document. The header should contain everything until 
-# the first chapter. If it is left blank doxygen will generate a 
-# standard header. Notice: only use this tag if you know what you are doing!
-
 LATEX_HEADER           = 
-
-# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated 
-# is prepared for conversion to pdf (using ps2pdf). The pdf file will 
-# contain links (just like the HTML output) instead of page references 
-# This makes the output suitable for online browsing using a pdf viewer.
-
 PDF_HYPERLINKS         = YES
-
-# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of 
-# plain latex in the generated Makefile. Set this option to YES to get a 
-# higher quality PDF documentation.
-
 USE_PDFLATEX           = YES
-
-# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. 
-# command to the generated LaTeX files. This will instruct LaTeX to keep 
-# running if errors occur, instead of asking the user for help. 
-# This option is also used when generating formulas in HTML.
-
 LATEX_BATCHMODE        = NO
-
-# If LATEX_HIDE_INDICES is set to YES then doxygen will not 
-# include the index chapters (such as File Index, Compound Index, etc.) 
-# in the output.
-
 LATEX_HIDE_INDICES     = NO
-
 #---------------------------------------------------------------------------
 # configuration options related to the RTF output
 #---------------------------------------------------------------------------
-
-# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output 
-# The RTF output is optimized for Word 97 and may not look very pretty with 
-# other RTF readers or editors.
-
 GENERATE_RTF           = NO
-
-# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `rtf' will be used as the default path.
-
 RTF_OUTPUT             = rtf
-
-# If the COMPACT_RTF tag is set to YES Doxygen generates more compact 
-# RTF documents. This may be useful for small projects and may help to 
-# save some trees in general.
-
 COMPACT_RTF            = NO
-
-# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated 
-# will contain hyperlink fields. The RTF file will 
-# contain links (just like the HTML output) instead of page references. 
-# This makes the output suitable for online browsing using WORD or other 
-# programs which support those fields. 
-# Note: wordpad (write) and others do not support links.
-
 RTF_HYPERLINKS         = NO
-
-# Load stylesheet definitions from file. Syntax is similar to doxygen's 
-# config file, i.e. a series of assignments. You only have to provide 
-# replacements, missing definitions are set to their default value.
-
 RTF_STYLESHEET_FILE    = 
-
-# Set optional variables used in the generation of an rtf document. 
-# Syntax is similar to doxygen's config file.
-
 RTF_EXTENSIONS_FILE    = 
-
 #---------------------------------------------------------------------------
 # configuration options related to the man page output
 #---------------------------------------------------------------------------
-
-# If the GENERATE_MAN tag is set to YES (the default) Doxygen will 
-# generate man pages
-
 GENERATE_MAN           = NO
-
-# The MAN_OUTPUT tag is used to specify where the man pages will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `man' will be used as the default path.
-
 MAN_OUTPUT             = man
-
-# The MAN_EXTENSION tag determines the extension that is added to 
-# the generated man pages (default is the subroutine's section .3)
-
 MAN_EXTENSION          = .3
-
-# If the MAN_LINKS tag is set to YES and Doxygen generates man output, 
-# then it will generate one additional man file for each entity 
-# documented in the real man page(s). These additional files 
-# only source the real man page, but without them the man command 
-# would be unable to find the correct page. The default is NO.
-
 MAN_LINKS              = NO
-
 #---------------------------------------------------------------------------
 # configuration options related to the XML output
 #---------------------------------------------------------------------------
-
-# If the GENERATE_XML tag is set to YES Doxygen will 
-# generate an XML file that captures the structure of 
-# the code including all documentation.
-
 GENERATE_XML           = NO
-
-# The XML_OUTPUT tag is used to specify where the XML pages will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `xml' will be used as the default path.
-
 XML_OUTPUT             = xml
-
-# The XML_SCHEMA tag can be used to specify an XML schema, 
-# which can be used by a validating XML parser to check the 
-# syntax of the XML files.
-
 XML_SCHEMA             = 
-
-# The XML_DTD tag can be used to specify an XML DTD, 
-# which can be used by a validating XML parser to check the 
-# syntax of the XML files.
-
 XML_DTD                = 
-
-# If the XML_PROGRAMLISTING tag is set to YES Doxygen will 
-# dump the program listings (including syntax highlighting 
-# and cross-referencing information) to the XML output. Note that 
-# enabling this will significantly increase the size of the XML output.
-
 XML_PROGRAMLISTING     = YES
-
 #---------------------------------------------------------------------------
 # configuration options for the AutoGen Definitions output
 #---------------------------------------------------------------------------
-
-# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will 
-# generate an AutoGen Definitions (see autogen.sf.net) file 
-# that captures the structure of the code including all 
-# documentation. Note that this feature is still experimental 
-# and incomplete at the moment.
-
 GENERATE_AUTOGEN_DEF   = NO
-
 #---------------------------------------------------------------------------
 # configuration options related to the Perl module output
 #---------------------------------------------------------------------------
-
-# If the GENERATE_PERLMOD tag is set to YES Doxygen will 
-# generate a Perl module file that captures the structure of 
-# the code including all documentation. Note that this 
-# feature is still experimental and incomplete at the 
-# moment.
-
 GENERATE_PERLMOD       = NO
-
-# If the PERLMOD_LATEX tag is set to YES Doxygen will generate 
-# the necessary Makefile rules, Perl scripts and LaTeX code to be able 
-# to generate PDF and DVI output from the Perl module output.
-
 PERLMOD_LATEX          = NO
-
-# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be 
-# nicely formatted so it can be parsed by a human reader.  This is useful 
-# if you want to understand what is going on.  On the other hand, if this 
-# tag is set to NO the size of the Perl module output will be much smaller 
-# and Perl will parse it just the same.
-
 PERLMOD_PRETTY         = YES
-
-# The names of the make variables in the generated doxyrules.make file 
-# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. 
-# This is useful so different doxyrules.make files included by the same 
-# Makefile don't overwrite each other's variables.
-
 PERLMOD_MAKEVAR_PREFIX = 
-
 #---------------------------------------------------------------------------
 # Configuration options related to the preprocessor   
 #---------------------------------------------------------------------------
-
-# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will 
-# evaluate all C-preprocessor directives found in the sources and include 
-# files.
-
 ENABLE_PREPROCESSING   = YES
-
-# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro 
-# names in the source code. If set to NO (the default) only conditional 
-# compilation will be performed. Macro expansion can be done in a controlled 
-# way by setting EXPAND_ONLY_PREDEF to YES.
-
 MACRO_EXPANSION        = NO
-
-# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES 
-# then the macro expansion is limited to the macros specified with the 
-# PREDEFINED and EXPAND_AS_PREDEFINED tags.
-
 EXPAND_ONLY_PREDEF     = NO
-
-# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files 
-# in the INCLUDE_PATH (see below) will be search if a #include is found.
-
 SEARCH_INCLUDES        = YES
-
-# The INCLUDE_PATH tag can be used to specify one or more directories that 
-# contain include files that are not input files but should be processed by 
-# the preprocessor.
-
 INCLUDE_PATH           = 
-
-# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard 
-# patterns (like *.h and *.hpp) to filter out the header-files in the 
-# directories. If left blank, the patterns specified with FILE_PATTERNS will 
-# be used.
-
 INCLUDE_FILE_PATTERNS  = 
-
-# The PREDEFINED tag can be used to specify one or more macro names that 
-# are defined before the preprocessor is started (similar to the -D option of 
-# gcc). The argument of the tag is a list of macros of the form: name 
-# or name=definition (no spaces). If the definition and the = are 
-# omitted =1 is assumed. To prevent a macro definition from being 
-# undefined via #undef or recursively expanded use the := operator 
-# instead of the = operator.
-
 PREDEFINED             = DOXYGEN
-
-# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then 
-# this tag can be used to specify a list of macro names that should be expanded. 
-# The macro definition that is found in the sources will be used. 
-# Use the PREDEFINED tag if you want to use a different macro definition.
-
 EXPAND_AS_DEFINED      = 
-
-# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then 
-# doxygen's preprocessor will remove all function-like macros that are alone 
-# on a line, have an all uppercase name, and do not end with a semicolon. Such 
-# function macros are typically used for boiler-plate code, and will confuse 
-# the parser if not removed.
-
 SKIP_FUNCTION_MACROS   = YES
-
 #---------------------------------------------------------------------------
 # Configuration::additions related to external references   
 #---------------------------------------------------------------------------
-
-# The TAGFILES option can be used to specify one or more tagfiles. 
-# Optionally an initial location of the external documentation 
-# can be added for each tagfile. The format of a tag file without 
-# this location is as follows: 
-#   TAGFILES = file1 file2 ... 
-# Adding location for the tag files is done as follows: 
-#   TAGFILES = file1=loc1 "file2 = loc2" ... 
-# where "loc1" and "loc2" can be relative or absolute paths or 
-# URLs. If a location is present for each tag, the installdox tool 
-# does not have to be run to correct the links.
-# Note that each tag file must have a unique name
-# (where the name does NOT include the path)
-# If a tag file is not located in the directory in which doxygen 
-# is run, you must also specify the path to the tagfile here.
-
-TAGFILES               = "libstdc++.tag = http://gcc.gnu.org/onlinedocs/libstdc++/latest-doxygen/"
-
-# When a file name is specified after GENERATE_TAGFILE, doxygen will create 
-# a tag file that is based on the input files it reads.
-
+TAGFILES               = "@abs_top_srcdir@/doc/libstdc++.tag = http://gcc.gnu.org/onlinedocs/libstdc++/latest-doxygen/  "
 GENERATE_TAGFILE       = html/lemon.tag
-
-# If the ALLEXTERNALS tag is set to YES all external classes will be listed 
-# in the class index. If set to NO only the inherited external classes 
-# will be listed.
-
 ALLEXTERNALS           = NO
-
-# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed 
-# in the modules index. If set to NO, only the current project's groups will 
-# be listed.
-
 EXTERNAL_GROUPS        = NO
-
-# The PERL_PATH should be the absolute path and name of the perl script 
-# interpreter (i.e. the result of `which perl').
-
 PERL_PATH              = /usr/bin/perl
-
 #---------------------------------------------------------------------------
 # Configuration options related to the dot tool   
 #---------------------------------------------------------------------------
-
-# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will 
-# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base 
-# or super classes. Setting the tag to NO turns the diagrams off. Note that 
-# this option is superseded by the HAVE_DOT option below. This is only a 
-# fallback. It is recommended to install and use dot, since it yields more 
-# powerful graphs.
-
-CLASS_DIAGRAMS         = NO
-
-# If set to YES, the inheritance and collaboration graphs will hide 
-# inheritance and usage relations if the target is undocumented 
-# or is not a class.
-
+CLASS_DIAGRAMS         = YES
+MSCGEN_PATH            = 
 HIDE_UNDOC_RELATIONS   = YES
-
-# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is 
-# available from the path. This tool is part of Graphviz, a graph visualization 
-# toolkit from AT&T and Lucent Bell Labs. The other options in this section 
-# have no effect if this option is set to NO (the default)
-
 HAVE_DOT               = YES
-
-# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for each documented class showing the direct and 
-# indirect inheritance relations. Setting this tag to YES will force the 
-# the CLASS_DIAGRAMS tag to NO.
-
+DOT_FONTNAME           = FreeSans
+DOT_FONTSIZE           = 10
+DOT_FONTPATH           = 
 CLASS_GRAPH            = YES
-
-# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for each documented class showing the direct and 
-# indirect implementation dependencies (inheritance, containment, and 
-# class references variables) of the class with other documented classes.
-
 COLLABORATION_GRAPH    = NO
-
-# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for groups, showing the direct groups dependencies
-
 GROUP_GRAPHS           = NO
-
-# If the UML_LOOK tag is set to YES doxygen will generate inheritance and 
-# collaboration diagrams in a style similar to the OMG's Unified Modeling 
-# Language.
-
 UML_LOOK               = NO
-
-# If set to YES, the inheritance and collaboration graphs will show the 
-# relations between templates and their instances.
-
 TEMPLATE_RELATIONS     = NO
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT 
-# tags are set to YES then doxygen will generate a graph for each documented 
-# file showing the direct and indirect include dependencies of the file with 
-# other documented files.
-
 INCLUDE_GRAPH          = NO
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and 
-# HAVE_DOT tags are set to YES then doxygen will generate a graph for each 
-# documented header file showing the documented files that directly or 
-# indirectly include this file.
-
 INCLUDED_BY_GRAPH      = NO
-
-# If the CALL_GRAPH and HAVE_DOT tags are set to YES then doxygen will 
-# generate a call dependency graph for every global function or class method. 
-# Note that enabling this option will significantly increase the time of a run. 
-# So in most cases it will be better to enable call graphs for selected 
-# functions only using the \callgraph command.
-
 CALL_GRAPH             = NO
-
-# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen 
-# will graphical hierarchy of all classes instead of a textual one.
-
+CALLER_GRAPH           = NO
 GRAPHICAL_HIERARCHY    = NO
-
-# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES 
-# then doxygen will show the dependencies a directory has on other directories 
-# in a graphical way. The dependency relations are determined by the #include
-# relations between the files in the directories.
-
 DIRECTORY_GRAPH        = NO
-
-# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images 
-# generated by dot. Possible values are png, jpg, or gif
-# If left blank png will be used.
-
 DOT_IMAGE_FORMAT       = png
-
-# The tag DOT_PATH can be used to specify the path where the dot tool can be 
-# found. If left blank, it is assumed the dot tool can be found in the path.
-
 DOT_PATH               = 
-
-# The DOTFILE_DIRS tag can be used to specify one or more directories that 
-# contain dot files that are included in the documentation (see the 
-# \dotfile command).
-
 DOTFILE_DIRS           = 
-
-# The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width 
-# (in pixels) of the graphs generated by dot. If a graph becomes larger than 
-# this value, doxygen will try to truncate the graph, so that it fits within 
-# the specified constraint. Beware that most browsers cannot cope with very 
-# large images.
-
-MAX_DOT_GRAPH_WIDTH    = 1024
-
-# The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height 
-# (in pixels) of the graphs generated by dot. If a graph becomes larger than 
-# this value, doxygen will try to truncate the graph, so that it fits within 
-# the specified constraint. Beware that most browsers cannot cope with very 
-# large images.
-
-MAX_DOT_GRAPH_HEIGHT   = 1024
-
-# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the 
-# graphs generated by dot. A depth value of 3 means that only nodes reachable 
-# from the root by following a path via at most 3 edges will be shown. Nodes 
-# that lay further from the root node will be omitted. Note that setting this 
-# option to 1 or 2 may greatly reduce the computation time needed for large 
-# code bases. Also note that a graph may be further truncated if the graph's 
-# image dimensions are not sufficient to fit the graph (see MAX_DOT_GRAPH_WIDTH 
-# and MAX_DOT_GRAPH_HEIGHT). If 0 is used for the depth value (the default), 
-# the graph is not depth-constrained.
-
+DOT_GRAPH_MAX_NODES    = 50
 MAX_DOT_GRAPH_DEPTH    = 0
-
-# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent 
-# background. This is disabled by default, which results in a white background. 
-# Warning: Depending on the platform used, enabling this option may lead to 
-# badly anti-aliased labels on the edges of a graph (i.e. they become hard to 
-# read).
-
 DOT_TRANSPARENT        = NO
-
-# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output 
-# files in one run (i.e. multiple -o and -T options on the command line). This 
-# makes dot run faster, but since only newer versions of dot (>1.8.10) 
-# support this, this feature is disabled by default.
-
 DOT_MULTI_TARGETS      = NO
-
-# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will 
-# generate a legend page explaining the meaning of the various boxes and 
-# arrows in the dot generated graphs.
-
 GENERATE_LEGEND        = YES
-
-# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will 
-# remove the intermediate dot files that are used to generate 
-# the various graphs.
-
 DOT_CLEANUP            = YES
-
 #---------------------------------------------------------------------------
 # Configuration::additions related to the search engine   
 #---------------------------------------------------------------------------
-
-# The SEARCHENGINE tag specifies whether or not a search engine should be 
-# used. If set to NO the values of all tags below this one will be ignored.
-
 SEARCHENGINE           = NO
Index: doc/DoxygenLayout.xml
===================================================================
--- doc/DoxygenLayout.xml	(revision 2627)
+++ doc/DoxygenLayout.xml	(revision 2627)
@@ -0,0 +1,182 @@
+<doxygenlayout version="1.0">
+  <!-- Navigation index tabs for HTML output -->
+  <navindex>
+    <tab type="mainpage" visible="yes" title=""/>
+    <tab type="modules" visible="yes" title=""/>
+    <tab type="classes" visible="yes" title="">
+      <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=""/>
+      <tab type="namespacemembers" visible="yes" title=""/>
+    </tab>
+    <tab type="files" visible="yes" title="">
+      <tab type="files" visible="yes" title=""/>
+      <tab type="globals" visible="yes" title=""/>
+    </tab>
+    <tab type="dirs" visible="yes" title=""/>
+    <tab type="examples" visible="yes" title=""/>  
+    <tab type="pages" visible="yes" title=""/>
+  </navindex>
+
+  <!-- Layout definition for a class page -->
+  <class>
+    <briefdescription visible="no"/>
+    <detaileddescription title=""/>
+    <includes visible="$SHOW_INCLUDE_FILES"/>
+    <inheritancegraph visible="$CLASS_GRAPH"/>
+    <collaborationgraph visible="$COLLABORATION_GRAPH"/>
+    <allmemberslink visible="yes"/>
+    <memberdecl>
+      <membergroups visible="yes"/>
+      <nestedclasses visible="yes" title=""/>
+      <publictypes title=""/>
+      <publicslots title=""/>
+      <signals title=""/>
+      <publicmethods title=""/>
+      <publicstaticmethods title=""/>
+      <publicattributes title=""/>
+      <publicstaticattributes title=""/>
+      <protectedtypes title=""/>
+      <protectedslots title=""/>
+      <protectedmethods title=""/>
+      <protectedstaticmethods title=""/>
+      <protectedattributes title=""/>
+      <protectedstaticattributes title=""/>
+      <packagetypes title=""/>
+      <packagemethods title=""/>
+      <packagestaticmethods title=""/>
+      <packageattributes title=""/>
+      <packagestaticattributes title=""/>
+      <properties title=""/>
+      <events title=""/>
+      <privatetypes title=""/>
+      <privateslots title=""/>
+      <privatemethods title=""/>
+      <privatestaticmethods title=""/>
+      <privateattributes title=""/>
+      <privatestaticattributes title=""/>
+      <friends title=""/>
+      <related title="" subtitle=""/>
+    </memberdecl>
+    <memberdef>
+      <typedefs title=""/>
+      <enums title=""/>
+      <constructors title=""/>
+      <functions title=""/>
+      <related title=""/>
+      <variables title=""/>
+      <properties title=""/>
+      <events title=""/>
+    </memberdef>
+    <usedfiles visible="$SHOW_USED_FILES"/>
+    <authorsection visible="yes"/>
+  </class>
+
+  <!-- Layout definition for a namespace page -->
+  <namespace>
+    <briefdescription visible="no"/>
+    <detaileddescription title=""/>
+    <memberdecl>
+      <nestednamespaces visible="yes" title=""/>
+      <classes visible="yes" title=""/>
+      <membergroups visible="yes"/>
+      <typedefs title=""/>
+      <enums title=""/>
+      <functions title=""/>
+      <variables title=""/>
+    </memberdecl>
+    <memberdef>
+      <typedefs title=""/>
+      <enums title=""/>
+      <functions title=""/>
+      <variables title=""/>
+    </memberdef>
+    <authorsection visible="yes"/>
+  </namespace>
+
+  <!-- Layout definition for a file page -->
+  <file>
+    <briefdescription visible="no"/>
+    <detaileddescription title=""/>
+    <includes visible="$SHOW_INCLUDE_FILES"/>
+    <includegraph visible="$INCLUDE_GRAPH"/>
+    <includedbygraph visible="$INCLUDED_BY_GRAPH"/>
+    <sourcelink visible="yes"/>
+    <memberdecl>
+      <classes visible="yes" title=""/>
+      <namespaces visible="yes" title=""/>
+      <defines title=""/>
+      <typedefs title=""/>
+      <enums title=""/>
+      <functions title=""/>
+      <variables title=""/>
+    </memberdecl>
+    <memberdef>
+      <defines title=""/>
+      <typedefs title=""/>
+      <enums title=""/>
+      <functions title=""/>
+      <variables title=""/>
+    </memberdef>
+    <authorsection/>
+  </file>
+
+  <!-- Layout definition for a group page -->
+  <group>
+    <briefdescription visible="no"/>
+    <detaileddescription title=""/>
+    <groupgraph visible="$GROUP_GRAPHS"/>
+    <memberdecl>
+      <classes visible="yes" title=""/>
+      <namespaces visible="yes" title=""/>
+      <dirs visible="yes" title=""/>
+      <nestedgroups visible="yes" title=""/>
+      <files visible="yes" title=""/>
+      <defines title=""/>
+      <typedefs title=""/>
+      <enums title=""/>
+      <enumvalues title=""/>
+      <functions title=""/>
+      <variables title=""/>
+      <signals title=""/>
+      <publicslots title=""/>
+      <protectedslots title=""/>
+      <privateslots title=""/>
+      <events title=""/>
+      <properties title=""/>
+      <friends title=""/>
+    </memberdecl>
+    <memberdef>
+      <pagedocs/>
+      <defines title=""/>
+      <typedefs title=""/>
+      <enums title=""/>
+      <enumvalues title=""/>
+      <functions title=""/>
+      <variables title=""/>
+      <signals title=""/>
+      <publicslots title=""/>
+      <protectedslots title=""/>
+      <privateslots title=""/>
+      <events title=""/>
+      <properties title=""/>
+      <friends title=""/>
+    </memberdef>
+    <authorsection visible="yes"/>
+  </group>
+
+  <!-- Layout definition for a directory page -->
+  <directory>
+    <briefdescription visible="no"/>
+    <detaileddescription title=""/>
+    <directorygraph visible="yes"/>
+    <memberdecl>
+      <dirs visible="yes"/>
+      <files visible="yes"/>
+    </memberdecl>
+  </directory>
+</doxygenlayout>
Index: doc/Makefile.am
===================================================================
--- doc/Makefile.am	(revision 2652)
+++ doc/Makefile.am	(revision 2503)
@@ -3,24 +3,30 @@
 EXTRA_DIST += \
 	doc/Makefile \
+	doc/Doxyfile.in \
 	doc/html \
-	doc/Doxyfile.in
-##	doc/icons/geom/ftv2doc.png \
-##	doc/icons/geom/ftv2folderclosed.png \
-##	doc/icons/geom/ftv2folderopen.png \
-##	doc/coding_style.dox \
-##	doc/developers_interface.dox \
-##	doc/dirs.dox \
-##	doc/getstart.dox \
-##	doc/graph-adaptors.dox \
-##	doc/graph_io.dox \
-##	doc/graphs.dox \
-##	doc/groups.dox \
-##	doc/license.dox \
-##	doc/mainpage.dox \
-##	doc/maps.dox \
-##	doc/named-param.dox \
-##	doc/namespaces.dox \
-##	doc/quicktour.dox \
-##	doc/ugraphs.dox
+	doc/icons/geom/ftv2doc.png \
+	doc/icons/geom/ftv2folderclosed.png \
+	doc/icons/geom/ftv2folderopen.png \
+	doc/algorithms.dox \
+	doc/coding_style.dox \
+	doc/developers_interface.dox \
+	doc/developers.dox \
+	doc/dirs.dox \
+	doc/getstart.dox \
+	doc/graph-adaptors.dox \
+	doc/graph_io.dox \
+	doc/graphs.dox \
+	doc/groups.dox \
+	doc/lemon_file_format.dox \
+	doc/license.dox \
+	doc/mainpage.dox \
+	doc/maps.dox \
+	doc/maps1.dox \
+	doc/maps2.dox \
+	doc/named-param.dox \
+	doc/namespaces.dox \
+	doc/quicktour.dox \
+	doc/read_write_bg.dox \
+	doc/ugraphs.dox
 
 doc:
@@ -49,4 +55,6 @@
 	$(MAKE) $(AM_MAKEFLAGS) doc-clean
 
+if WANT_DOC
+
 install-data-local: doc/html
 	@$(NORMAL_INSTALL)
@@ -66,3 +74,5 @@
 	done
 
+endif WANT_DOC
+
 .PHONY: doc doc-clean
Index: doc/algorithms.dox
===================================================================
--- doc/algorithms.dox	(revision 2553)
+++ doc/algorithms.dox	(revision 2553)
@@ -0,0 +1,156 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+/**
+\page algorithms Algorithms
+
+\section algo_bfs_dfs Bfs/Dfs
+Both \ref lemon::Bfs "Bfs" and \ref lemon::Dfs "Dfs" are highly adaptable and efficient
+implementations of the well known algorithms. The algorithms are placed most cases in
+separated files named after the algorithm itself but lower case as all other header file names.
+For example the next Bfs class is in the \c lemon/bfs.h.
+
+\subsection Bfs
+The algorithm is implemented in the \ref lemon::Bfs "Bfs" template class - rather than as function.
+The class has two template parameters: \b GR and \b TR.<br>
+GR is the graph the algorithm runs on. It has \ref lemon::ListGraph "ListGraph" as default type.
+TR is a Traits class commonly used to easy the parametrization of templates. In most cases you
+wont need to modify the default type \ref lemon::BfsDefaultTraits "BfsDefaultTraits<GR>".
+
+To use the class, declare it!
+\code
+Bfs<ListUGraph>  bfs(gr);
+\endcode
+Note the lack of second template argument because of the default parameter.
+
+It provides a simple but powerful interface to control the execution.
+\code
+int dist = bfs.run(s,t);
+\endcode
+It finds the shortest path from node \c s to node \c t and returns it, or zero
+if there is no path from \c s to \c t.<br>
+If you want the shortest path from a specified node to all other node, just write:
+\code
+bfs.run(s);
+\endcode
+Now the distances and path information are stored in maps which you can access with
+member functions like \ref lemon::Bfs::distMap "distMap()" or \ref lemon::Bfs::predMap "predMap()".<br>
+Or more directly with other member functions like \ref lemon::Bfs::predNode "predNode()". Once the algorithm
+is finished (or to be precise reached that node) \ref lemon::Bfs::dist "dist()" or \ref lemon::Bfs::predNode
+"predNode()" can be called.
+
+For an example let's say we want to print the shortest path of those nodes which
+are in a certain distance.
+\code
+bfs.run(s);
+
+for( ListUGraph::NodeIt  n(gr); n != INVALID; ++n ) {
+  if( bfs.reached(n) && bfs.dist(n) <= max_dist ) {
+    std::cout << gr.id(n);
+
+    Node  prev = bfs.prevNode(n);
+    while( prev != INVALID ) {
+      std::cout << "<-" << gr.id(prev);
+      prev = bfs.prevNode(n);
+    }
+    
+    std::cout << std::endl;
+  }
+}
+\endcode
+
+\subsubsection bfs_adv_control Advanced control
+In the previous code we only used \c run(). Now we introduce the way you can directly
+control the execution of the algorithm.
+
+First you have to initialize the variables with \ref lemon::Bfs::init "init()".
+\code
+  bfs.init();
+\endcode
+
+Then you add one or more source nodes to the queue. They will be processed, as they would
+be reached by the algorithm before. And yes - you can add more sources during the execution.
+\code
+  bfs.addSource(node_1);
+  bfs.addSource(node_2);
+  ...
+\endcode
+
+And finally you can start the process with \ref lemon::Bfs::start "start()", or
+you can write your own loop to process the nodes one-by-one.
+
+\todo Demo for Bfs advanced control.
+
+\subsection Dfs
+Since Dfs is very similar to Bfs with a few tiny differences we only see a bit more complex example
+to demonstrate Dfs's capabilities.
+
+We will see a program, which solves the problem of <b>topological ordering</b>.
+We need to know in which order we should put on our clothes. The program will do the following:
+<ol>
+<li>We run the dfs algorithm to all nodes.
+<li>Put every node into a list when processed completely.
+<li>Write out the list in reverse order.
+</ol>
+
+\dontinclude topological_ordering.cc
+First of all we will need an own \ref lemon::Dfs::ProcessedMap "ProcessedMap". The ordering
+will be done through it.
+\skip MyOrdererMap
+\until };
+The class meets the \ref concepts::WriteMap "WriteMap" concept. In it's \c set() method the only thing
+we need to do is insert the key - that is the node whose processing just finished - into the beginning
+of the list.<br>
+Although we implemented this needed helper class ourselves it was not necessary.
+The \ref lemon::FrontInserterBoolMap "FrontInserterBoolMap" class does exactly
+what we needed. To be correct it's more general - and it's all in \c LEMON. But
+we wanted to show you, how easy is to add additional functionality.
+
+First we declare the needed data structures: the graph and a map to store the nodes' label.
+\skip ListGraph
+\until label
+
+Now we build a graph. But keep in mind that it must be DAG because cyclic graphs has no topological
+ordering.
+\skip belt
+\until trousers
+We label them...
+\skip label
+\until trousers
+Then add directed edges which represent the precedences between those items.
+\skip trousers, belt
+\until );
+
+See how easy is to access the internal information of this algorithm trough maps.
+We only need to set our own map as the class's \ref lemon::Dfs::ProcessedMap "ProcessedMap".
+\skip Dfs
+\until run
+
+And now comes the third part. Write out the list in reverse order. But the list was
+composed in reverse way (with \c push_front() instead of \c push_back() so we just iterate it.
+\skip std
+\until endl
+
+The program is to be found in the \ref demo directory: \ref topological_ordering.cc
+
+\todo Check the linking of the demo file, the code samples are missing.
+
+More algorithms are described in the \ref algorithms2 "second part".
+*/
+}
Index: doc/basic_concepts.dox
===================================================================
--- doc/basic_concepts.dox	(revision 2553)
+++ doc/basic_concepts.dox	(revision 2553)
@@ -0,0 +1,143 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+
+/**
+\page basic_concepts Basic concepts
+
+\section basic_graph The graph classes
+The most important classes in LEMON are the graph classes. An instance of a graph
+class is the representation of the mathematical graph. It holds the topology and
+every structural information of the graph. The structural manipulations are also
+provided by the graph object. There is no universal graph class instead we have
+different classes for different purposes. They can differ in many ways, but all
+have to satisfy one or more \ref concept "graph concepts" which are standardized
+interfaces to work with the rest of the library. The most basic concept is the
+\ref concepts::Graph "Graph".<br>
+A good example is the \ref ListGraph which we already know from Hello World and
+will be used in our examples as well.
+
+One main advantage of the templates are, that you can write your own graph classes.
+As long as they provide the interface a concept is defining all the LEMON algorithms
+and classes will work with it properly - no representation or implementation is
+written into stone.
+
+
+\subsection basic_node Nodes
+To refer to a node of a graph we need some kind of typed variable. Graph classes
+have the Node public type for this purpose. Stacking by the last example:
+\code lemon::ListGraph::Node \endcode
+
+If the graph fits the ExtendableGraphComponent concept, then you can add new nodes
+to the graph with the addNode() member function. It returns the newly added node
+(as value). So if you need the new node to do something useful with, for example
+create an edge, assign a value to it through \ref maps1 maps.
+\code lemon::ListGraph::Node  new_node = graph.addNode(); \endcode
+
+If the graph fits into the ErasableGraphComponent concept you can also remove nodes
+from the graph with the erase() member function.
+\code graph.erase( new_node ); \endcode
+
+You don't have to store every node in a variable, you can access individual nodes
+with node iterators discussed in the next section. But how do you know which
+node is which?<br>
+The graph class has the id( Node n ) member function providing an unique identifier
+assigned to every node.
+
+
+\subsection basic_edge Edges
+An Edge is what you think it is. It goes from one node to another node (they can
+be identical if the edge is a loop). If the graph class is directed, the Edge is directed too. Otherwise
+the edge is considered undirected and called UEdge.
+\code lemon::ListUGraph::UEdge \endcode
+
+The addEdge() member function will create a new edge. It has two arguments, the
+source node and the target node. The graph class must be extendable.
+\code lemon::ListGraph::Edge  new_edge = graph.addEdge( src_node, trg_node ); \endcode
+You can handle edges similar as nodes. The erase() member function has an edge taking
+overload too.
+
+You can ask for the source or target node of the edge by the corresponding member
+functions:
+\code
+graph.source( new_edge );
+lemon::ListGraph::Node  n = graph.target( new_edge ); \endcode
+These functions are always legal even if the graph is undirected. UEdge has a
+default direction.
+
+
+\section basic_iterators Iterators
+Graphs are some kind of containers. And as you expect they have iterator types.
+One for nodes and a couple for edges - and special classes can have additional
+iterators too. An example:
+\code lemon::ListGraph::NodeIt \endcode
+This is a node iterator. Every iterator type starts with a name that refers to
+the iterated object, and ends with 'It'.
+
+LEMON style iterators differ from \c stl or \c boost iterators in a very tasty
+way. A graph has no begin or end - or at least a generic graph class has none.
+If by some topology you could pick a good begin node, it would be misleading and
+incorrect. A LEMON style iterator must be initialized at construction time.
+The constructor takes the needed parameters - by a node iterator it's the graph
+object. And will be compared to the lemon::INVALID to check if it's still valid.
+Every iterator can be compared to INVALID. No \c begin() or \c end() needed.<br>
+Let's see these things working together:
+\code
+for( ListGraph::NodeIt n(graph); n != INVALID; ++n )
+    do_useful_things_with_node(n);
+\endcode
+Note that the function \c do_useful_things_with_node() expects a Node type argument
+ad we just gave him the iterator. LEMON style iterators must provide "on demand
+dereferencing". For example a NodeIt can be used everywhere a Node could. (In some
+graph classes Node is the base class of NodeIt. But in other cases this is implemented
+through typecast operator.)
+
+<b>Very important!</b> The iteration has no defined order. There is absolutely no
+warranty that the next time the iteration will give us the nodes in the same order.
+Don't use this order to identify nodes! Use the \c id() member function of the
+graph class described above. (There is a powerful technique using maps right in
+the next page.)
+
+The \ref concepts::Graph::EdgeIt "EdgeIt" works exactly the same - nothing more to say.
+But there are \ref concepts::Graph::InEdgeIt "InEdgeIt" and
+\ref concepts::Graph::OutEdgeIt "OutEdgeIt" by directed graphs and
+\ref concepts::UGraph::IncEdgeIt "IncEdgeIt" by undirected graphs.
+They take two arguments. The first is a graph, the second is certain node of the
+graph. InEdgeIt iterates on the incoming edges of that node and OutEdgeIt does it
+on the outgoing edges. The IncEdgeIt of course iterates every edge connecting to
+the given node.
+
+\code
+for( ListGraph::NodeIt n(graph); n != INVALID; ++n ) {
+  int in = 0, out = 0;
+  for( ListGraph::InEdgeIt e(graph,n); e != INVALID; ++e ) ++in;
+  for( ListGraph::OutEdgeIt e(graph,n); e != INVALID; ++e ) ++out;
+
+  std::cout << "#" << graph.id(n) << " node has " << in << " incoming and "
+    << out << "outgoing edges." << std::endl;
+}
+\endcode
+
+
+\section basic_ListGraph ListGraph - a versatile directed graph
+As you see ListGraph satisfies most of the basic concepts and ideal for general
+graph representations. It has an undirected version too: ListUGraph.
+*/
+
+}
Index: doc/coding_style.dox
===================================================================
--- doc/coding_style.dox	(revision 2553)
+++ doc/coding_style.dox	(revision 2553)
@@ -0,0 +1,118 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/*!
+
+\page coding_style LEMON Coding Style 
+
+\section naming_conv Naming Conventions
+
+In order to make development easier we have made some conventions
+according to coding style. These include names of types, classes,
+functions, variables, constants and exceptions. If these conventions
+are met in one's code then it is easier to read and maintain
+it. Please comply with these conventions if you want to contribute
+developing LEMON library.
+
+\note When the coding style requires the capitalization of an abbreviation,
+only the first letter should be upper case.
+
+\code
+XmlReader
+\endcode
+
+
+\warning In some cases we diverge from these rules.
+This primary done because STL uses different naming convention and
+in certain cases
+it is beneficial to provide STL compatible interface.
+
+\subsection cs-files File Names
+
+The header file names should look like the following.
+
+\code
+header_file.h
+\endcode
+
+Note that all standard LEMON headers are located in the \c lemon subdirectory,
+so you should include them from C++ source like this:
+
+\code
+#include <lemon/header_file.h>
+\endcode
+
+The source code files use the same style and they have '.cc' extension.
+
+\code
+source_code.cc
+\endcode
+
+\subsection cs-class Classes and other types
+
+The name of a class or any type should look like the following.
+
+\code
+AllWordsCapitalizedWithoutUnderscores 
+\endcode
+
+\subsection cs-func Methods and other functions
+
+The name of a function should look like the following.
+
+\code
+firstWordLowerCaseRestCapitalizedWithoutUnderscores 
+\endcode
+
+\subsection cs-funcs Constants, Macros
+
+The names of constants and macros should look like the following.
+
+\code
+ALL_UPPER_CASE_WITH_UNDERSCORES 
+\endcode
+
+\subsection cs-loc-var Class and instance member variables, auto variables 
+
+The names of class and instance member variables and auto variables (=variables used locally in methods) should look like the following.
+
+\code
+all_lower_case_with_underscores 
+\endcode
+
+\subsection cs-excep Exceptions
+
+When writing exceptions please comply the following naming conventions.
+
+\code
+ClassNameEndsWithException
+\endcode
+
+or
+
+\code
+ClassNameEndsWithError
+\endcode
+
+\section header-template Template Header File
+
+Each LEMON header file should look like this:
+
+\include template.h
+
+*/
Index: doc/developers.dox
===================================================================
--- doc/developers.dox	(revision 2553)
+++ doc/developers.dox	(revision 2553)
@@ -0,0 +1,41 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+/*!
+
+
+\page developers LEMON Developers
+
+\li Mihaly Barasz
+\li Johanna Becker
+\li Attila Bernath
+\li Balazs Dezso
+\li Peter Hegyi
+\li Alpar Juttner
+\li Peter Kovacs
+\li Akos Ladanyi
+\li Marton Makai
+\li Balazs Attila Mihaly
+\li Janos Nagy
+\li Jacint Szabo
+\li Zsuzsanna Vaik
+
+*/
+}
+
Index: doc/developers_interface.dox
===================================================================
--- doc/developers_interface.dox	(revision 2553)
+++ doc/developers_interface.dox	(revision 2553)
@@ -0,0 +1,25 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/*!
+
+\page developers_interface Developers' interface to graph structures
+
+Under construction
+
+*/
Index: doc/dirs.dox
===================================================================
--- doc/dirs.dox	(revision 2553)
+++ doc/dirs.dox	(revision 2553)
@@ -0,0 +1,79 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/**
+\dir demo
+\brief A collection of demo application.
+
+This directory contains several simple demo application, mainly
+for educational purposes.
+*/
+
+/**
+\dir doc
+\brief Auxiliary (and the whole generated) documentation.
+
+Auxiliary (and the whole generated) documentation.
+*/
+
+/**
+\dir test
+\brief Test programs.
+
+This directory contains several test programs that check the consistency
+of the code.
+*/
+
+/**
+\dir tools
+\brief Some useful executables
+
+This directory contains the sources of some useful complete executables.
+
+*/
+
+
+
+/**
+\dir lemon
+\brief Base include directory of LEMON
+
+This is the base directory of lemon includes, so each include file must be
+prefixed with this, e.g.
+\code
+#include<lemon/list_graph.h>
+#include<lemon/dijkstra.h>
+\endcode
+*/
+
+/**
+\dir concepts
+\brief Concept descriptors and checking classes
+
+This directory contains the concept descriptors and concept checkers. As a user
+you typically don't have to deal with these files.
+*/
+
+/**
+\dir bits
+\brief Implementation helper files
+
+This directory contains some helper classes to implement graphs, maps and
+some other classes. As a user you typically don't have to deal with these 
+files.
+*/
Index: doc/getstart.dox
===================================================================
--- doc/getstart.dox	(revision 2553)
+++ doc/getstart.dox	(revision 2553)
@@ -0,0 +1,313 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/**
+\page getstart How to start using LEMON
+
+In this page we detail how to start using LEMON, from downloading it to
+your computer, through the steps of installation, to showing a simple
+"Hello World" type program that already uses LEMON. We assume that you
+have a basic knowledge of your operating system and \c C++ programming
+language. The procedure is pretty straightforward, but if you have any
+difficulties don't hesitate to 
+<a href="mailto:lemon-user@lemon.cs.elte.hu">ask</a>.
+
+
+\section requirementsLEMON Hardware and software requirements
+
+In LEMON we use C++ templates heavily, thus compilation takes a
+considerable amount of time and memory. So some decent box would be
+advantageous. But otherwise there are no special hardware requirements.
+
+You will need a recent C++ compiler. Our primary target is the GNU C++
+Compiler (g++), from version 3.3 upwards. We also checked the Intel C++
+Compiler (icc). Microsoft Visual C++ .NET 2003 was also reported to
+work (but not the earlier versions). If you want to develop with LEMON
+under Windows you could consider using Cygwin.
+
+In this description we will suppose a Linux environment and GNU C++ Compiler.
+
+
+\subsection requirementsLP LP solver requirements
+
+The LEMON LP solver interface can use the GLPK (GNU Linear Programming
+Kit) ,CPLEX (was tested with CPLEX 7.5) and SoPlex solver. If you want
+to use it you will need at least one of these. See \ref configureFlags
+how to enable these at compile time.
+
+
+\section downloadLEMON How to download LEMON
+
+You can download LEMON from the LEMON web site:
+<a href="https://lemon.cs.elte.hu/site/products/">
+https://lemon.cs.elte.hu/site/products/</a> .
+There you will find released versions in form of <tt>.tar.gz</tt> files.
+If you want a developer version (for example you want to contribute in
+developing the library LEMON) then you might want to use our Subversion
+repository. This case is detailed later, so from now on we suppose that
+you downloaded a <tt>.tar.gz</tt> file.
+
+
+\section installLEMON How to install LEMON
+
+In order to install LEMON you have to do the following steps.
+
+Download the tarball (named <tt>lemon-x.y.z.tar.gz</tt> where \c x,\c y
+and \c z are numbers indicating the version of the library: in our example
+we will have <tt>lemon-0.3.1.tar.gz</tt>) and issue the following
+commands:
+
+\verbatim
+tar xvzf lemon-0.3.1.tar.gz
+cd lemon-0.3.1
+./configure
+make
+make check   #(This is optional, but recommended. It runs a bunch of tests.)
+make install
+\endverbatim
+
+These commands install LEMON under \c /usr/local (you will
+need root privileges to be able to install to that
+directory). If you want to install it to some other place, then
+pass the \c --prefix=DIRECTORY flag to <tt>./configure</tt>, for example:
+
+\verbatim
+./configure --prefix=/home/username/lemon
+\endverbatim
+
+In what follows we will assume that you were able to install to directory
+\c /usr/local, otherwise some extra care is to be taken to use the
+library.
+
+We briefly explain these commands below.
+
+\verbatim
+tar xvzf lemon-0.3.1.tar.gz
+\endverbatim
+This command untars the <tt>tar.gz</tt> file into a directory named <tt>
+lemon-0.3.1</tt>.
+
+\verbatim
+cd lemon-0.3.1
+\endverbatim
+Enters the directory.
+
+\verbatim
+./configure
+\endverbatim
+Does some configuration (creates makefiles etc).
+
+\verbatim
+make
+\endverbatim
+This command compiles the non-template part of LEMON into
+<b>libemon.a</b> file. It also compiles some benchmark and demo
+programs.
+
+\verbatim
+make check
+\endverbatim
+This is an optional step: it runs the test programs that we
+developed for LEMON to check whether the library works properly on
+your platform.
+
+\verbatim
+make install
+\endverbatim
+This will copy the directory structure to its final destination (e.g. to \c
+/usr/local) so that your system can access it. This command should
+be issued as "root", unless you provided a \c --prefix switch to
+the \c configure to install the library in non-default location.
+
+
+\subsection configureFlags Configure flags
+
+You can pass the following flags to <tt>./configure</tt> (see <tt>./configure</tt> --help
+for more):
+
+\verbatim
+--with-glpk[=PREFIX]
+\endverbatim
+Enable GLPK support (default). You should specify the prefix too if you
+installed it to some non-standard location (e.g. your home directory). If
+GLPK is not found, then GLPK support will be disabled.
+
+\verbatim
+--with-glpk-includedir=DIR
+\endverbatim
+The directory where the GLPK header files are located. This is only useful when
+the GLPK headers and libraries are not under the same prefix (which is
+unlikely).
+
+\verbatim
+--with-glpk-libdir=DIR
+\endverbatim
+The directory where the GLPK libraries are located. This is only useful when
+the GLPK headers and libraries are not under the same prefix (which is
+unlikely).
+
+\verbatim
+--without-glpk
+\endverbatim
+Disable GLPK support.
+
+\verbatim
+--with-cplex[=PREFIX]
+\endverbatim
+Enable CPLEX support (default). You should specify the prefix too if you
+installed it to some non-standard location (e.g. \c /opt/ilog/cplex75). If
+CPLEX is not found, then CPLEX support will be disabled.
+
+\verbatim
+--with-cplex-includedir=DIR
+\endverbatim
+The directory where the CPLEX header files are located. This is only useful
+when the CPLEX headers and libraries are not under the same prefix.
+
+\verbatim
+--with-cplex-libdir=DIR
+\endverbatim
+The directory where the CPLEX libraries are located. This is only useful when
+the CPLEX headers and libraries are not under the same prefix.
+
+\verbatim
+--without-cplex
+\endverbatim
+Disable CPLEX support.
+
+\verbatim 
+--with-soplex[=PREFIX] 
+\endverbatim 
+Enable SoPlex support (default). You should specify the prefix too if
+you installed it to some non-standard location. If SoPlex is not
+found, then SoPlex support will be disabled.
+
+\verbatim
+--with-soplex-includedir=DIR
+\endverbatim
+The directory where the SoPlex header files are located. This is only useful
+when the SoPlex headers and libraries are not under the same prefix.
+
+\verbatim
+--with-soplex-libdir=DIR
+\endverbatim
+The directory where the SoPlex libraries are located. This is only useful when
+the SoPlex headers and libraries are not under the same prefix.
+
+\verbatim
+--without-soplex
+\endverbatim
+Disable SoPlex support.
+
+
+\section svnCheckout How to checkout LEMON form our Subversion repository
+
+You can obtain the latest version of LEMON from our Subversion repository. To
+do this issue the following command:
+\verbatim
+svn co https://lemon.cs.elte.hu/svn/lemon/trunk lemon-src
+\endverbatim
+Use "lemon" as username, the password is empty.
+
+
+\section svnCompile How to compile the source from the repository
+
+You can compile the code from the repository similarly to the packaged
+version, but you will need to run \c autoreconf \c -vi or 
+<tt>./bootstrap</tt> in some older environment before <tt>./configure</tt>. See \c
+./configure \c --help for options. For bootstrapping you will need the
+following tools:
+
+ - <a href="http://www.gnu.org/software/automake/">automake</a> (1.7 or newer)
+ - <a href="http://www.gnu.org/software/autoconf/">autoconf</a> (2.59 or newer)
+ - <a href="http://www.gnu.org/software/libtool/">libtool</a>
+ - <a href="http://pkgconfig.freedesktop.org/">pkgconfig</a>
+
+To generate the documentation, run \c make \c doc. You will need
+<a href="http://www.doxygen.org/">Doxygen</a> for this.
+
+You can pass the \c --enable-doc=full flag to <tt>./configure</tt> to generate the
+internal documentation too.
+
+If you pass the \c --disable-doc flag to <tt>./configure</tt> then the documentation
+won't be installed, when you run \c make \c install (this speeds things up a
+bit).
+
+\section helloworld My first program using LEMON
+
+If you have installed LEMON on your system you can paste the
+following code segment into a file (you can find it as \c
+demo/hello_lemon.cc in the LEMON package) to have a first working
+program that uses library LEMON.
+
+\dontinclude hello_lemon.cc
+\skip include
+\until }
+
+First let us briefly explain how this program works.
+
+ListGraph is one of LEMON's graph classes. It is based on linked lists,
+therefore iterating throuh its edges and nodes is fast.
+
+After some convenience typedefs we create a graph and add three nodes to it.
+Then we add edges to it to form a complete graph.
+
+Then we iterate through all nodes of the graph. We use a constructor of the
+node iterator to initialize it to the first node. The operator++ is used to
+step to the next node. Using operator++ on the iterator pointing to the last
+node invalidates the iterator i.e. sets its value to
+\ref lemon::INVALID "INVALID". This is what we exploit in the stop condition.
+
+We can also iterate through all edges of the graph very similarly. The 
+\c target and
+\c source member functions can be used to access the endpoints of an edge.
+
+If your installation of LEMON into directory \c /usr/local was
+successful, then it is very easy to compile this program with the
+following command (the argument <tt>-lemon</tt> tells the compiler
+that we are using the installed library LEMON):
+
+\verbatim
+g++ hello_lemon.cc -o hello_lemon -lemon
+\endverbatim
+
+As a result you will get the exacutable \c hello_lemon in
+this directory that you can run by the command 
+\verbatim
+./hello_lemon
+\endverbatim
+
+
+If everything has gone well then the previous code fragment prints
+out the following:
+
+\verbatim
+Nodes: 2 1 0
+
+Edges: (0,2) (1,2) (0,1) (2,1) (1,0) (2,0)
+\endverbatim
+
+Congratulations!
+
+If you want to see more features, go to the
+\ref quicktour "Quick Tour to LEMON",
+if you want to see some demo programs then go to our 
+\ref demoprograms "Demo Programs" page! 
+
+
+*/
Index: doc/getting_started.dox
===================================================================
--- doc/getting_started.dox	(revision 2553)
+++ doc/getting_started.dox	(revision 2553)
@@ -0,0 +1,122 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/**
+\page getting_started Getting Started
+
+At the beginning we strongly suggest that you open your favorite text
+editor and enter the code simultaneously as you read it. Compiling the
+demos is also a good exercise.
+
+As the first example we show you a lemon style "Hello World"
+program. Now we explain almost every line, but later we will skip the
+basics and focus on new things.
+
+\section hello_world Hello World in LEMON
+
+In this little program we give you a taste of the LEMON programming.
+
+Let's see the code fragment to fragment!
+
+\dontinclude hello_world.cc
+\skip include
+\until iostream
+
+We want to use a \c lemon::ListGraph so the include goes like this:
+\skip include
+\until list_graph
+
+The next few lines are not necessary but useful shortcuts, if you don't
+want to type \c lemon::ListGraph::Node every time.
+\skip using
+\until Edge
+
+For this demo we need to declare a ListGraph and a special NodeMap to
+store the characters associated to the graph's nodes.  
+\skip main
+\until char_map
+
+Adding nodes to the graph is very easy.
+\skip new_node
+\until addNode
+
+When a new node or edge is added to the graph the assigned maps are automatically resized.
+So graphs can be built dynamically. The usage of a map is very natural.
+\skip char_map
+\until char_map
+
+Notice that no reference or additional assignment is needed to work with nodes.
+They won't become illegal or won't lead to throwing any exceptions.
+You can declare and handle a node like every other basic type such as \c int.
+\skip Store
+\until char_map
+
+As one expects adding an Edge is similar. You need to define the \b source node
+and the \b destination node. The nodes must belong to the graph of course. The
+Edge has the direction from the source to the destination. In some cases you don't
+want the edges to be directed - then you use an undirected graph. For example
+lemon::ListUGraph.
+\skip addEdge
+\until addEdge
+
+In the next few lines we add some more nodes and edges and to the graph we need.
+Those lines are not very interesting so we skip them, but you find the whole
+working program in file hello_world.cc in the demo section.
+
+The next statement must be familiar. But what is that INVALID in the \c while
+test statement? In LEMON we usually use the INVALID to check if an object
+contains valid information.
+\skip current_node
+\until {
+
+We take the current node and write out the character assigned to it. Is's easy
+with the \c char_map.
+\skip std
+\until std
+
+And here comes the trick. OutEdgeIt iterates on outgoing edges of a given node.
+We pass the current node as argument to it, so the \c edge iterator will stand
+on the first outgoing edge of the current node, or will be INVALID if the node
+has no outgoing edges.
+\skip edge
+\until edge
+
+The graph we built before is linear, so we know that it ends, when no more outgoing
+edges found. Otherwise the current node must be the node the edge points to.
+Basic information about an edge can be requested from the graph.
+\skip if
+\until }
+
+Finish the code, just to be precise.
+\skip return
+\until }
+
+
+\section compile_hw Compiling Hello World
+To compile this program all you have to do is type in
+\code g++ -ohello_world hello_world.cc \endcode
+and press \c Enter! This is the case if you installed LEMON on your system.
+(For more information see the LEMON installation instructions.)
+
+This is because LEMON is template library and most of it's code has to be available
+as source code during compilation.
+ 
+Most programs using LEMON will compile as easy as this one unless you want to
+use some performance measuring tools LEMON can provide. Then you need to link
+an additional library against your program.
+*/
Index: doc/graph-adaptors.dox
===================================================================
--- doc/graph-adaptors.dox	(revision 2553)
+++ doc/graph-adaptors.dox	(revision 2553)
@@ -0,0 +1,98 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/**
+   @defgroup graph_adaptors Adaptor Classes for Graphs
+   @ingroup graphs
+   \brief This group contains several adaptor classes for graphs
+   
+   The main parts of LEMON are the different graph structures, 
+   generic graph algorithms, graph concepts which couple these, and 
+   graph adaptors. While the previous notions are more or less clear, the 
+   latter one needs further explanation. 
+   Graph adaptors are graph classes which serve for considering graph 
+   structures in different ways. 
+
+   A short example makes this much 
+   clearer. 
+   Suppose that we have an instance \c g of a directed graph
+   type say ListGraph and an algorithm 
+   \code template<typename Graph> int algorithm(const Graph&); \endcode 
+   is needed to run on the reversed oriented graph. 
+   It may be expensive (in time or in memory usage) to copy 
+   \c g with the reversed orientation. 
+   In this case, an adaptor class is used, which 
+   (according to LEMON graph concepts) works as a graph. 
+   The adaptor uses 
+   the original graph structure and graph operations when methods of the 
+   reversed oriented graph are called. 
+   This means that the adaptor have minor memory usage, 
+   and do not perform sophisticated algorithmic actions. 
+   The purpose of it is to give a tool for the cases when 
+   a graph have to be used in a specific alteration. 
+   If this alteration is obtained by a usual construction 
+   like filtering the edge-set or considering a new orientation, then 
+   an adaptor is worthwhile to use. 
+   To come back to the reversed oriented graph, in this situation 
+   \code template<typename Graph> class RevGraphAdaptor; \endcode 
+   template class can be used. 
+   The code looks as follows 
+   \code
+   ListGraph g;
+   RevGraphAdaptor<ListGraph> rga(g);
+   int result=algorithm(rga);
+   \endcode
+   After running the algorithm, the original graph \c g 
+   is untouched. 
+   This techniques gives rise to an elegant code, and 
+   based on stable graph adaptors, complex algorithms can be 
+   implemented easily. 
+
+   In flow, circulation and bipartite matching problems, the residual 
+   graph is of particular importance. Combining an adaptor implementing 
+   this, shortest path algorithms and minimum mean cycle algorithms, 
+   a range of weighted and cardinality optimization algorithms can be 
+   obtained. 
+   For other examples, 
+   the interested user is referred to the detailed documentation of 
+   particular adaptors. 
+
+   The behavior of graph adaptors can be very different. Some of them keep 
+   capabilities of the original graph while in other cases this would be 
+   meaningless. This means that the concepts that they are models of depend 
+   on the graph adaptor, and the wrapped graph(s). 
+   If an edge of \c rga is deleted, this is carried out by 
+   deleting the corresponding edge of \c g, thus the adaptor modifies the 
+   original graph. 
+   But for a residual 
+   graph, this operation has no sense. 
+   Let us stand one more example here to simplify your work. 
+   RevGraphAdaptor has constructor 
+   \code 
+   RevGraphAdaptor(Graph& _g);
+   \endcode
+   This means that in a situation, 
+   when a <tt> const ListGraph& </tt> reference to a graph is given, 
+   then it have to be instantiated with <tt>Graph=const ListGraph</tt>.
+   \code
+   int algorithm1(const ListGraph& g) {
+   RevGraphAdaptor<const ListGraph> rga(g);
+   return algorithm2(rga);
+   }
+   \endcode
+*/
Index: doc/graph_io.dox
===================================================================
--- doc/graph_io.dox	(revision 2553)
+++ doc/graph_io.dox	(revision 2553)
@@ -0,0 +1,531 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+/*!
+
+
+\page graph-io-page Graph Input-Output
+
+The standard graph IO enables one to store graphs and additional maps
+(i.e. functions on the nodes or edges) in a flexible and efficient way. 
+Before you read this page you should be familiar with LEMON 
+\ref graphs "graphs" and \ref maps-page "maps".
+
+\section format The general file format
+
+The file contains sections in the following order:
+
+\li nodeset
+\li edgeset
+\li nodes
+\li edges
+\li attributes
+
+Some of these sections can be omitted, but you will basicly need the nodeset
+section (unless your graph has no nodes at all) and the edgeset section
+(unless your graph has no edges at all). 
+
+The nodeset section describes the nodes of your graph: it identifies the nodes
+and gives the maps defined on them, if any. It starts with the
+following line:
+
+<tt>\@nodeset</tt>
+
+The next line contains the names of the nodemaps, separated by whitespaces.  Each
+following line describes a node in the graph: it contains the values of the
+maps in the right order. The map named "label" should contain unique values
+because it is regarded as a label map. These labels need not be numbers but they
+must identify the nodes uniquely for later reference. For example:
+
+\code
+@nodeset
+label  x-coord  y-coord  color
+3   1.0      4.0      blue
+5   2.3      5.7      red
+12  7.8      2.3      green
+\endcode
+
+The edgeset section is very similar to the nodeset section, it has
+the same coloumn oriented structure. It starts with the line 
+
+<tt>\@edgeset</tt>
+
+The next line contains the whitespace separated list of names of the edge
+maps.  Each of the next lines describes one edge. The first two elements in
+the line are the labels of the source and target (or tail and head) nodes of the
+edge as they occur in the label node map of the nodeset section. You can also
+have an optional label map on the edges for later reference (which has to be
+unique in this case).
+
+\code
+@edgeset
+             label      weight   note
+3   5        a          4.3      a-edge
+5   12       c          2.6      c-edge
+3   12       g          3.4      g-edge
+\endcode
+
+The \e nodes section contains <em>labeled (distinguished) nodes</em> 
+(i.e. nodes having a special
+label on them). The section starts with
+
+<tt> \@nodes </tt>
+
+Each of the next lines contains a label for a node in the graph 
+and then the label as described in the \e nodeset section.
+
+\code
+@nodes 
+source 3
+target 12
+\endcode
+
+The last section describes the <em>labeled (distinguished) edges</em>
+(i.e. edges having a special label on them). It starts with \c \@edges
+and then each line contains the name of the edge and the label.
+
+\code
+@edges 
+observed c
+\endcode
+
+
+The file may contain empty lines and comment lines. The comment lines
+start with an \c # character.
+
+The attributes section can handle some information about the graph. It
+contains key-value pairs in each line (a key and the mapped value to key). The
+key should be a string without whitespaces, the value can be of various types.
+
+\code
+@attributes
+title "Four colored planar graph"
+author "Balazs DEZSO"
+copyright "Lemon Library"
+version 12
+\endcode
+
+Finally, the file should be closed with \c \@end line.
+
+
+\section use Using graph input-output
+
+
+The graph input and output is based on <em> reading and writing
+commands</em>. The user gives reading and writing commands to the reader or
+writer class, then he calls the \c run() method that executes all the given
+commands.
+
+\subsection write Writing a graph
+
+The \ref lemon::GraphWriter "GraphWriter" template class
+provides the graph output. To write a graph
+you should first give writing commands to the writer. You can declare
+writing command as \c NodeMap or \c EdgeMap writing and labeled Node and
+Edge writing.
+
+\code
+GraphWriter<ListGraph> writer(std::cout, graph);
+\endcode
+
+The \ref lemon::GraphWriter::writeNodeMap() "writeNodeMap()"
+function declares a \c NodeMap writing command in the
+\ref lemon::GraphWriter "GraphWriter".
+You should give a name to the map and the map
+object as parameters. The NodeMap writing command with name "label" should write a 
+unique map because it will be regarded as a label map.
+
+\see IdMap, DescriptorMap  
+
+\code
+IdMap<ListGraph, Node> nodeLabelMap;
+writer.writeNodeMap("label", nodeLabelMap);
+
+writer.writeNodeMap("x-coord", xCoordMap);
+writer.writeNodeMap("y-coord", yCoordMap);
+writer.writeNodeMap("color", colorMap);
+\endcode
+
+With the \ref lemon::GraphWriter::writeEdgeMap() "writeEdgeMap()"
+member function you can give an edge map
+writing command similar to the NodeMaps.
+
+\see IdMap, DescriptorMap  
+
+\code
+DescriptorMap<ListGraph, Edge, ListGraph::EdgeMap<int> > edgeDescMap(graph);
+writer.writeEdgeMap("descriptor", edgeDescMap);
+
+writer.writeEdgeMap("weight", weightMap);
+writer.writeEdgeMap("note", noteMap);
+\endcode
+
+With \ref lemon::GraphWriter::writeNode() "writeNode()"
+and \ref lemon::GraphWriter::writeEdge() "writeEdge()"
+functions you can designate Nodes and
+Edges in the graph. For example, you can write out the source and target node
+of a maximum flow instance.
+
+\code
+writer.writeNode("source", sourceNode);
+writer.writeNode("target", targetNode);
+
+writer.writeEdge("observed", edge);
+\endcode
+
+With \ref lemon::GraphWriter::writeAttribute() "writeAttribute()"
+function you can write an attribute to the file.
+
+\code
+writer.writeAttribute("author", "Balazs DEZSO");
+writer.writeAttribute("version", 12);
+\endcode
+
+After you give all write commands you must call the
+\ref lemon::GraphWriter::run() "run()" member
+function, which executes all the writing commands.
+
+\code
+writer.run();
+\endcode
+
+\subsection reading Reading a graph
+
+The file to be read may contain several maps and labeled nodes or edges.
+If you read a graph you need not read all the maps and items just those
+that you need. The interface of the \ref lemon::GraphReader "GraphReader"
+is very similar to
+the \ref lemon::GraphWriter "GraphWriter"
+but the reading method does not depend on the order of the
+given commands.
+
+The reader object assumes that each not read value does not contain 
+whitespaces, therefore it has some extra possibilities to control how
+it should skip the values when the string representation contains spaces.
+
+\code
+GraphReader<ListGraph> reader(std::cin, graph);
+\endcode
+
+The \ref lemon::GraphReader::readNodeMap() "readNodeMap()"
+function reads a map from the \c nodeset section.
+If there is a map that you do not want to read from the file and there are
+whitespaces in the string represenation of the values then you should
+call the \ref lemon::GraphReader::skipNodeMap() "skipNodeMap()"
+template member function with proper parameters.
+
+\see QuotedStringReader
+
+\code
+reader.readNodeMap("x-coord", xCoordMap);
+reader.readNodeMap("y-coord", yCoordMap);
+
+reader.readNodeMap<QuotedStringReader>("label", labelMap);
+reader.skipNodeMap<QuotedStringReader>("description");
+
+reader.readNodeMap("color", colorMap);
+\endcode
+
+With the \ref lemon::GraphReader::readEdgeMap() "readEdgeMap()"
+member function you can give an edge map
+reading command similar to the NodeMaps. 
+
+\code
+reader.readEdgeMap("weight", weightMap);
+reader.readEdgeMap("label", labelMap);
+\endcode
+
+With \ref lemon::GraphReader::readNode() "readNode()"
+and \ref lemon::GraphReader::readEdge() "readEdge()"
+functions you can read labeled Nodes and
+Edges.
+
+\code
+reader.readNode("source", sourceNode);
+reader.readNode("target", targetNode);
+
+reader.readEdge("observed", edge);
+\endcode
+
+With \ref lemon::GraphReader::readAttribute() "readAttribute()"
+function you can read an attribute from the file.
+
+\code
+std::string author;
+writer.readAttribute("author", author);
+int version;
+writer.writeAttribute("version", version);
+\endcode
+
+After you give all read commands you must call the
+\ref lemon::GraphReader::run() "run()" member
+function, which executes all the commands.
+
+\code
+reader.run();
+\endcode
+
+\anchor rwbackground
+\section types Background of Reading and Writing
+
+
+To read a map (on the nodes or edges)
+the \ref lemon::GraphReader "GraphReader"
+should know how to read a Value from the given map.
+By the default implementation the input operator reads a value from
+the stream and the type of the read value is the value type of the given map.
+When the reader should skip a value in the stream, because you do not
+want to store it in a map, the reader skips a character sequence without 
+whitespaces. 
+
+If you want to change the functionality of the reader, you can use
+template parameters to specialize it. When you give a reading
+command for a map you can give a Reader type as template parameter.
+With this template parameter you can control how the Reader reads
+a value from the stream.
+
+The reader has the next structure: 
+\code
+struct TypeReader {
+  typedef TypeName Value;
+
+  void read(std::istream& is, Value& value);
+};
+\endcode
+
+For example, the \c "strings" nodemap contains strings and you do not need
+the value of the string just the length. Then you can implement an own Reader
+struct.
+
+\code
+struct LengthReader {
+  typedef int Value;
+
+  void read(std::istream& is, Value& value) {
+    std::string tmp;
+    is >> tmp;
+    value = tmp.length();
+  }
+};
+...
+reader.readNodeMap<LengthReader>("strings", lengthMap);
+\endcode  
+
+The global functionality of the reader class can be changed by giving a
+special template parameter to the GraphReader class. By default, the
+template parameter is \c DefaultReaderTraits. A reader traits class 
+should provide a nested template class Reader for each type, and a 
+DefaultReader for skipping a value.
+
+The specialization of writing is very similar to that of reading.
+
+\section undir Undirected and Bipartite graphs
+
+In a file describing an undirected graph (ugraph, for short) you find an
+\c uedgeset section instead of the \c edgeset section. The first line of
+the section describes the names of the maps on the undirected egdes and all
+next lines describe one undirected edge with the the incident nodes and the
+values of the map.
+
+The format could store directed edge maps, if there are two maps with 
+names being the same with a \c '+' and a \c '-' prefix then this could 
+be read as such a map.
+
+\code
+@uedgeset
+             label      capacity        +flow   -flow
+32   2       1          4.3             2.0     0.0
+21   21      5          2.6             0.0     2.6
+21   12      8          3.4             0.0     0.0
+\endcode
+
+The \c edges section is changed to \c uedges section. This section
+describes labeled edges and undirected edges. The directed edge label
+should start with a \c '+' or a \c '-' prefix to decide the direction
+of the edge. 
+
+\code
+@uedges
+uedge 1
++edge 5
+-back 5
+\endcode
+
+There are similar classes to the \ref lemon::GraphReader "GraphReader" and
+\ref lemon::GraphWriter "GraphWriter" which
+handle the undirected graphs. These classes are
+the \ref lemon::UGraphReader "UGraphReader"
+and \ref lemon::UGraphWriter "UGraphWriter".
+
+The \ref lemon::UGraphReader::readUEdgeMap() "readUEdgeMap()"
+function reads an undirected map and the
+\ref lemon::UGraphReader::readUEdge() "readUEdge()"
+reads an undirected edge from the file, 
+
+\code
+reader.readUEdgeMap("capacity", capacityMap);
+reader.readEdgeMap("flow", flowMap);
+...
+reader.readUEdge("u_edge", u_edge);
+reader.readEdge("edge", edge);
+\endcode
+
+The undirected bipartite graphs could be read with the \c BpUGraph
+class and it has specialized nodeset section, which should be start
+with \c "@bpnodeset". This section is separated to two
+subsections. The header line of these sections start with "&anodeset"
+or "&bnodeset" and after that the line contains the names of the
+regular and A-node or B-node maps accordingly. The lines of each
+section contains the mapped values. The labels of the graph should be
+unique overall both subsections.
+
+\code
+@bpnodeset
+&anodeset label   coords	radius
+	  0       (0, 0)	14.0
+	  1       (0, 1)	12.0
+&bnodeset label	  coords
+	  2       (1, 0)
+	  3       (1, 1)
+\endcode
+
+The reading can be done with \ref lemon::BpUGraphReader::readANodeMap() 
+"readANodeMap()", \ref lemon::BpUGraphReader::readBNodeMap() 
+"readBNodeMap()" or \ref lemon::BpUGraphReader::readNodeMap() 
+"readNodeMap()" members.
+
+\code
+reader.readNodeMap("coords", coords);
+reader.readAnodeMap("radius", radius);
+\endcode
+
+\section advanced Advanced features
+
+The graph reader and writer classes give an easy way to read and write
+graphs. But sometimes we want more advanced features. In this case we can
+use the more general <tt>lemon reader and writer</tt> interface.
+
+The LEMON file format is a section oriented file format. It contains one or
+more sections, each starting with a line identifying its type 
+(the word starting with the \c \@  character).
+The content of the section this way cannot contain line with \c \@ first
+character. The file may contains comment lines with \c # first character.
+
+The \ref lemon::LemonReader "LemonReader"
+and \ref lemon::LemonWriter "LemonWriter"
+gives a framework to read and
+write sections. There are various section reader and section writer
+classes which can be attached to a \ref lemon::LemonReader "LemonReader"
+or a \ref lemon::LemonWriter "LemonWriter".
+
+There are default section readers and writers for reading and writing
+item sets, and labeled items in the graph. These read and write
+the format described above. Other type of data can be handled with own
+section reader and writer classes which are inherited from the
+\c LemonReader::SectionReader or the
+\ref lemon::LemonWriter::SectionWriter "LemonWriter::SectionWriter"
+classes.
+
+The next example defines a special section reader which reads the
+\c \@description sections into a string:
+
+\code 
+class DescriptionReader : LemonReader::SectionReader {
+protected:
+  virtual bool header(const std::string& line) {
+    std::istringstream ls(line);
+    std::string head;
+    ls >> head;
+    return head == "@description";
+  }
+
+  virtual void read(std::istream& is) {
+    std::string line;
+    while (getline(is, line)) {
+      desc += line;
+    }
+  }
+public:
+
+  typedef LemonReader::SectionReader Parent;
+  
+  DescriptionReader(LemonReader& reader) : Parent(reader) {}
+
+  const std::string& description() const {
+    return description;
+  }
+
+private:
+  std::string desc;
+};
+\endcode
+
+The other advanced stuff of the generalized file format is that 
+multiple edgesets can be stored to the same nodeset. It can be used 
+for example as a network traffic matrix.
+
+In our example there is a network with symmetric links and there are assymetric
+traffic request on the network. This construction can be stored in an
+undirected graph and in a directed \c ListEdgeSet class. The example
+shows the input with the \ref lemon::LemonReader "LemonReader" class:
+
+\code
+ListUGraph network;
+ListUGraph::UEdgeMap<double> capacity;
+ListEdgeSet<ListUGraph> traffic(network);
+ListEdgeSet<ListUGraph>::EdgeMap<double> request(network);
+
+LemonReader reader(std::cin);
+NodeSetReader<ListUGraph> nodesetReader(reader, network);
+UEdgeSetReader<ListUGraph> 
+  uEdgesetReader(reader, network, nodesetReader);
+uEdgesetReader.readEdgeMap("capacity", capacity);
+EdgeSetReader<ListEdgeSet<ListUGraph> > 
+  edgesetReader(reader, traffic, nodesetReader, "traffic");
+edgesetReader.readEdgeMap("request", request);
+
+reader.run();
+\endcode
+
+Because both the \ref lemon::GraphReader "GraphReader"
+and the \ref lemon::UGraphReader "UGraphReader" can be converted
+to \ref lemon::LemonReader "LemonReader"
+and it can resolve the label's of the items, the previous
+result can be achived with the \ref lemon::UGraphReader "UGraphReader"
+class, too.
+
+
+\code
+ListUGraph network;
+ListUGraph::UEdgeSet<double> capacity;
+ListEdgeSet<ListUGraph> traffic(network);
+ListEdgeSet<ListUGraph>::EdgeMap<double> request(network);
+
+UGraphReader<ListUGraph> reader(std::cin, network);
+reader.readEdgeMap("capacity", capacity);
+EdgeSetReader<ListEdgeSet<ListUGraph> > 
+  edgesetReader(reader, traffic, reader, "traffic");
+edgesetReader.readEdgeMap("request", request);
+
+reader.run();
+\endcode
+
+\author Balazs Dezso
+*/
+}
Index: doc/graph_orientation.dox
===================================================================
--- doc/graph_orientation.dox	(revision 2553)
+++ doc/graph_orientation.dox	(revision 2553)
@@ -0,0 +1,201 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+/**
+
+\ingroup demos
+\file graph_orientation.cc
+\brief Graph orientation with lower bound requirement on the
+in-degree of the nodes.
+
+This demo shows an adaptation of the well-known "preflow push" algorithm to
+a simple graph orientation problem.
+
+The input of the problem is a(n undirected) graph and an integer value
+<i>f(n)</i> assigned to each node \e n. The task is to find an orientation
+of the edges for which the number of edge arriving at each node \e n is at
+least least <i>f(n)</i>.
+
+In fact, the algorithm reads a directed graph and computes a set of edges to
+be reversed in order to achieve the in-degree requirement.
+This input is given using 
+\ref graph-io-page ".lgf (Lemon Graph Format)" file. It should contain
+three node maps. The one called "f" contains the in-degree requirements, while
+"coordinate_x" and "coordinate_y" indicate the position of the nodes. These
+latter ones are used to generate the output, which is a <tt>.eps</tt> file.
+
+
+\section go-alg-dec The C++ source file
+
+Here you find how to solve the problem above using lemon.
+
+\subsection go-alg-head Headers and convenience typedefs
+
+First we include some important headers.
+
+The first one defines \ref lemon::ListGraph "ListGraph",
+the "Swiss army knife" graph implementation.
+\dontinclude graph_orientation.cc
+\skipline list_graph
+
+The next is  to read a \ref graph-io-page ".lgf" (Lemon Graph Format) file.
+\skipline reader
+
+This provides us with some special purpose graph \ref maps "maps".
+\skipline iterable
+
+The following header defines a simple data structure to store and manipulate
+planar coordinates. It will be used to draw the result.
+\skipline dim2
+
+And finally, this header contains a simple graph drawing utility.
+\skipline eps
+
+As we don't want to type in \ref lemon "lemon::" million times, the
+following line seems to be useful.
+\skipline namespace
+
+The following macro will also save a lot of typing by defining some
+convenience <tt>typedef</tt>s.
+
+\skipline TYPEDEF
+
+Actually, the macro above would be equivalent with the following
+<tt>typedef</tt>s.
+
+\code
+typedef ListGraph::Node Node;
+typedef ListGraph::NodeIt NodeIt;
+typedef ListGraph::Edge Edge;
+typedef ListGraph::EdgeIt EdgeIt;
+typedef ListGraph::OutEdgeIt OutEdgeIt;
+typedef ListGraph::InEdgeIt InEdgeIt;
+\endcode
+
+\subsection go-alg-main The main() function
+
+Well, we are ready to start <tt>main()</tt>.
+\skip main
+\until {
+
+First we check whether the program is called with exactly one parameter.
+If it isn't, we print a short help message end exit.
+The vast majority of people would probably skip this block.
+\skip if
+\until }
+
+Now, we read a graph \c g, and a map \c f containing
+the in-deg requirements from a \ref graph-io-page ".lgf (Lemon Graph Format)"
+file. To generate the output picture, we also read the node titles (\c label)
+and
+coordinates (\c coords).
+So, first we create the graph
+\skipline ListGraph
+and the corresponding NodeMaps.
+\skipline NodeMap
+\until coords
+\note The graph must be given to the maps' constructor.
+
+Then, the following block will read these data from the file, or exit if
+the file is missing or corrupt.
+\skip try
+\until }
+\until }
+
+The algorithm needs an integer value assigned to each node. We call this "level" and the nodes are on level 0 at the
+beginning of the execution.
+
+\skipline level
+
+The deficiency (\c def) of a node is the in-degree requirement minus the 
+actual in-degree.
+
+\skip def
+\until subMap
+
+A node is \e active if its deficiency is positive (i.e. if it doesn't meet
+the degree requirement).
+\skip active
+\until def
+
+We also store a bool map indicating which edges are reverted.
+Actually this map called \c rev is only
+used to draw these edges with different color in the output picture. The
+algorithm updates this map, but will not use it otherwise.
+\skip rev
+\until reversed
+
+The variable \c nodeNum will refer to the number of nodes.
+\skipline nodeNum
+
+Here comes the algorithm itself. 
+In each iteration we choose an active node (\c act will do it for us).
+If there is
+no such a node, then the orientation is feasible so we are done.
+\skip act
+\until while
+
+Then we check if there exists an edge leaving this node and
+stepping down exactly
+one level.
+\skip OutEdge
+\until while
+
+If there exists, we decrease the "activity" of the node \c act by reverting
+this egde.
+Fortunately, \ref lemon::ListGraph "ListGraph"
+has a special function \ref lemon::ListGraph::reverseEdge() "reverseEdge()"
+that makes this easy.
+We also have to update the maps \c def and
+\c rev.
+\skipline if
+\skip if
+\until }
+Otherwise (i.e. if there is no edge stepping down one level) we lift up the
+current active node \c act. If it reaches level \c nodeNum, then there
+exists no appropriate orientation so we stop.
+\skipline else
+\skipline if
+\skipline return
+\until }
+\until }
+\until }
+
+Believe it or not, this algorithm works and runs fast.
+
+Finally, we print the obtained orientation. Note, how the different
+\c bool values of
+\c rev are transformed into different \ref lemon::Color "RGB color"s
+using the class
+\ref lemon::Palette "Palette"
+and the \ref map_adaptors "map adaptor" called
+\ref lemon::ComposeMap "composeMap".
+
+\skip graphToEps
+\until run
+
+
+\until end of main
+
+Finally here are again the list of the used include files (because I can't turn
+this section off.)
+
+*/
+
+}
Index: doc/graphs.dox
===================================================================
--- doc/graphs.dox	(revision 2553)
+++ doc/graphs.dox	(revision 2553)
@@ -0,0 +1,204 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+
+/*!
+\page graphs Graphs
+
+\todo Write a new Graphs page. I think it should be contain the Graph,
+UGraph and BpUGraph concept. It should be describe the iterators and
+the basic functions and the differences of the implementations.
+
+The primary data structures of LEMON are the graph classes. They all
+provide a node list - edge list interface, i.e. they have
+functionalities to list the nodes and the edges of the graph as well
+as  incoming and outgoing edges of a given node. 
+
+Each graph should meet the \ref concepts::Graph "Graph" concept.
+This concept does not make it possible to change the graph (i.e. it is
+not possible to add or delete edges or nodes). Most of the graph
+algorithms will run on these graphs.
+
+
+In case of graphs meeting the full feature
+\ref concepts::ErasableGraph "ErasableGraph" concept
+you can also erase individual edges and nodes in arbitrary order.
+
+The implemented graph structures are the following.
+\li \ref ListGraph is the most versatile graph class. It meets
+the \ref concepts::ErasableGraph "ErasableGraph" concept
+and it also has some convenient extra features.
+\li \ref SmartGraph is a more memory efficient version of \ref ListGraph.
+The price of this is that it only meets the
+\ref concepts::ExtendableGraph "ExtendableGraph" concept,
+so you cannot delete individual edges or nodes.
+\li \ref FullGraph "FullGraph"
+implements a complete graph. It is a
+\ref concepts::Graph "Graph", so you cannot
+change the number of nodes once it is constructed. It is extremely memory
+efficient: it uses constant amount of memory independently from the number of
+the nodes of the graph. Of course, the size of the \ref maps-page "NodeMap"'s and
+\ref maps-page "EdgeMap"'s will depend on the number of nodes.
+
+\li \ref NodeSet "NodeSet" implements a graph with no edges. This class
+can be used as a base class of \ref lemon::EdgeSet "EdgeSet".
+\li \ref EdgeSet "EdgeSet" can be used to create a new graph on
+the node set of another graph. The base graph can be an arbitrary graph and it
+is possible to attach several \ref EdgeSet "EdgeSet"'s to a base graph.
+
+\todo Don't we need SmartNodeSet and SmartEdgeSet?
+\todo Some cross-refs are wrong.
+
+The graph structures themselves can not store data attached
+to the edges and nodes. However they all provide
+\ref maps-page "map classes"
+to dynamically attach data the to graph components.
+
+The following program demonstrates the basic features of LEMON's graph
+structures.
+
+\code
+#include <iostream>
+#include <lemon/list_graph.h>
+
+using namespace lemon;
+
+int main()
+{
+  typedef ListGraph Graph;
+\endcode
+
+ListGraph is one of LEMON's graph classes. It is based on linked lists,
+therefore iterating throuh its edges and nodes is fast.
+
+\code
+  typedef Graph::Edge Edge;
+  typedef Graph::InEdgeIt InEdgeIt;
+  typedef Graph::OutEdgeIt OutEdgeIt;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::Node Node;
+  typedef Graph::NodeIt NodeIt;
+
+  Graph g;
+  
+  for (int i = 0; i < 3; i++)
+    g.addNode();
+  
+  for (NodeIt i(g); i!=INVALID; ++i)
+    for (NodeIt j(g); j!=INVALID; ++j)
+      if (i != j) g.addEdge(i, j);
+\endcode
+
+After some convenient typedefs we create a graph and add three nodes to it.
+Then we add edges to it to form a complete graph.
+
+\code
+  std::cout << "Nodes:";
+  for (NodeIt i(g); i!=INVALID; ++i)
+    std::cout << " " << g.id(i);
+  std::cout << std::endl;
+\endcode
+
+Here we iterate through all nodes of the graph. We use a constructor of the
+node iterator to initialize it to the first node. The operator++ is used to
+step to the next node. Using operator++ on the iterator pointing to the last
+node invalidates the iterator i.e. sets its value to
+\ref INVALID. This is what we exploit in the stop condition.
+
+The previous code fragment prints out the following:
+
+\code
+Nodes: 2 1 0
+\endcode
+
+\code
+  std::cout << "Edges:";
+  for (EdgeIt i(g); i!=INVALID; ++i)
+    std::cout << " (" << g.id(g.source(i)) << "," << g.id(g.target(i)) << ")";
+  std::cout << std::endl;
+\endcode
+
+\code
+Edges: (0,2) (1,2) (0,1) (2,1) (1,0) (2,0)
+\endcode
+
+We can also iterate through all edges of the graph very similarly. The 
+\c target and
+\c source member functions can be used to access the endpoints of an edge.
+
+\code
+  NodeIt first_node(g);
+
+  std::cout << "Out-edges of node " << g.id(first_node) << ":";
+  for (OutEdgeIt i(g, first_node); i!=INVALID; ++i)
+    std::cout << " (" << g.id(g.source(i)) << "," << g.id(g.target(i)) << ")"; 
+  std::cout << std::endl;
+
+  std::cout << "In-edges of node " << g.id(first_node) << ":";
+  for (InEdgeIt i(g, first_node); i!=INVALID; ++i)
+    std::cout << " (" << g.id(g.source(i)) << "," << g.id(g.target(i)) << ")"; 
+  std::cout << std::endl;
+\endcode
+
+\code
+Out-edges of node 2: (2,0) (2,1)
+In-edges of node 2: (0,2) (1,2)
+\endcode
+
+We can also iterate through the in and out-edges of a node. In the above
+example we print out the in and out-edges of the first node of the graph.
+
+\code
+  Graph::EdgeMap<int> m(g);
+
+  for (EdgeIt e(g); e!=INVALID; ++e)
+    m.set(e, 10 - g.id(e));
+  
+  std::cout << "Id Edge  Value" << std::endl;
+  for (EdgeIt e(g); e!=INVALID; ++e)
+    std::cout << g.id(e) << "  (" << g.id(g.source(e)) << "," << g.id(g.target(e))
+      << ") " << m[e] << std::endl;
+\endcode
+
+\code
+Id Edge  Value
+4  (0,2) 6
+2  (1,2) 8
+5  (0,1) 5
+0  (2,1) 10
+3  (1,0) 7
+1  (2,0) 9
+\endcode
+
+As we mentioned above, graphs are not containers rather
+incidence structures which are iterable in many ways. LEMON introduces
+concepts that allow us to attach containers to graphs. These containers are
+called maps.
+
+In the example above we create an EdgeMap which assigns an integer value to all
+edges of the graph. We use the set member function of the map to write values
+into the map and the operator[] to retrieve them.
+
+Here we used the maps provided by the ListGraph class, but you can also write
+your own maps. You can read more about using maps \ref maps-page "here".
+
+*/
+
+}
+
Index: doc/groups.dox
===================================================================
--- doc/groups.dox	(revision 2566)
+++ doc/groups.dox	(revision 2566)
@@ -0,0 +1,582 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/**
+@defgroup datas Data Structures
+This group describes the several data structures implemented in LEMON.
+*/
+
+/**
+@defgroup graphs Graph Structures
+@ingroup datas
+\brief Graph structures implemented in LEMON.
+
+The implementation of combinatorial algorithms heavily relies on 
+efficient graph implementations. LEMON offers data structures which are 
+planned to be easily used in an experimental phase of implementation studies, 
+and thereafter the program code can be made efficient by small modifications. 
+
+The most efficient implementation of diverse applications require the
+usage of different physical graph implementations. These differences
+appear in the size of graph we require to handle, memory or time usage
+limitations or in the set of operations through which the graph can be
+accessed.  LEMON provides several physical graph structures to meet
+the diverging requirements of the possible users.  In order to save on
+running time or on memory usage, some structures may fail to provide
+some graph features like edge or node deletion.
+
+Alteration of standard containers need a very limited number of 
+operations, these together satisfy the everyday requirements. 
+In the case of graph structures, different operations are needed which do 
+not alter the physical graph, but gives another view. If some nodes or 
+edges have to be hidden or the reverse oriented graph have to be used, then 
+this is the case. It also may happen that in a flow implementation 
+the residual graph can be accessed by another algorithm, or a node-set 
+is to be shrunk for another algorithm. 
+LEMON also provides a variety of graphs for these requirements called 
+\ref graph_adaptors "graph adaptors". Adaptors cannot be used alone but only 
+in conjunction with other graph representations. 
+
+You are free to use the graph structure that fit your requirements
+the best, most graph algorithms and auxiliary data structures can be used
+with any graph structures. 
+*/
+
+/**
+@defgroup semi_adaptors Semi-Adaptor Classes for Graphs
+@ingroup graphs
+\brief Graph types between real graphs and graph adaptors.
+
+This group describes some graph types between real graphs and graph adaptors.
+These classes wrap graphs to give new functionality as the adaptors do it. 
+On the other hand they are not light-weight structures as the adaptors.
+*/
+
+/**
+@defgroup maps Maps 
+@ingroup datas
+\brief Map structures implemented in LEMON.
+
+This group describes the map structures implemented in LEMON.
+
+LEMON provides several special purpose maps that e.g. combine
+new maps from existing ones.
+*/
+
+/**
+@defgroup graph_maps Graph Maps 
+@ingroup maps
+\brief Special Graph-Related Maps.
+
+This group describes maps that are specifically designed to assign
+values to the nodes and edges of graphs.
+*/
+
+
+/**
+\defgroup map_adaptors Map Adaptors
+\ingroup maps
+\brief Tools to create new maps from existing ones
+
+This group describes map adaptors that are used to create "implicit"
+maps from other maps.
+
+Most of them are \ref lemon::concepts::ReadMap "ReadMap"s. They can
+make arithmetic operations between one or two maps (negation, scaling,
+addition, multiplication etc.) or e.g. convert a map to another one
+of different Value type.
+
+The typical usage of this classes is passing implicit maps to
+algorithms.  If a function type algorithm is called then the function
+type map adaptors can be used comfortable. For example let's see the
+usage of map adaptors with the \c graphToEps() function:
+\code
+  Color nodeColor(int deg) {
+    if (deg >= 2) {
+      return Color(0.5, 0.0, 0.5);
+    } else if (deg == 1) {
+      return Color(1.0, 0.5, 1.0);
+    } else {
+      return Color(0.0, 0.0, 0.0);
+    }
+  }
+  
+  Graph::NodeMap<int> degree_map(graph);
+  
+  graphToEps(graph, "graph.eps")
+    .coords(coords).scaleToA4().undirected()
+    .nodeColors(composeMap(functorMap(nodeColor), degree_map)) 
+    .run();
+\endcode 
+The \c functorMap() function makes an \c int to \c Color map from the
+\e nodeColor() function. The \c composeMap() compose the \e degree_map
+and the previous created map. The composed map is proper function to
+get color of each node.
+
+The usage with class type algorithms is little bit harder. In this
+case the function type map adaptors can not be used, because the
+function map adaptors give back temporary objects.
+\code
+  Graph graph;
+  
+  typedef Graph::EdgeMap<double> DoubleEdgeMap;
+  DoubleEdgeMap length(graph);
+  DoubleEdgeMap speed(graph);
+  
+  typedef DivMap<DoubleEdgeMap, DoubleEdgeMap> TimeMap;
+  
+  TimeMap time(length, speed);
+  
+  Dijkstra<Graph, TimeMap> dijkstra(graph, time);
+  dijkstra.run(source, target);
+\endcode
+
+We have a length map and a maximum speed map on a graph. The minimum
+time to pass the edge can be calculated as the division of the two
+maps which can be done implicitly with the \c DivMap template
+class. We use the implicit minimum time map as the length map of the
+\c Dijkstra algorithm.
+*/
+
+/**
+@defgroup matrices Matrices 
+@ingroup datas
+\brief Two dimensional data storages implemented in LEMON.
+
+This group describes two dimensional data storages implemented in LEMON.
+*/
+
+/**
+@defgroup paths Path Structures
+@ingroup datas
+\brief Path structures implemented in LEMON.
+
+This group describes the path structures implemented in LEMON.
+
+LEMON provides flexible data structures to work with paths.
+All of them have similar interfaces and they can be copied easily with
+assignment operators and copy constructors. This makes it easy and
+efficient to have e.g. the Dijkstra algorithm to store its result in
+any kind of path structure.
+
+\sa lemon::concepts::Path
+
+*/
+
+/**
+@defgroup auxdat Auxiliary Data Structures
+@ingroup datas
+\brief Auxiliary data structures implemented in LEMON.
+
+This group describes some data structures implemented in LEMON in
+order to make it easier to implement combinatorial algorithms.
+*/
+
+
+/**
+@defgroup algs Algorithms
+\brief This group describes the several algorithms
+implemented in LEMON.
+
+This group describes the several algorithms
+implemented in LEMON.
+*/
+
+/**
+@defgroup search Graph Search
+@ingroup algs
+\brief Common graph search algorithms.
+
+This group describes the common graph search algorithms like 
+Breadth-first search (Bfs) and Depth-first search (Dfs).
+*/
+
+/**
+@defgroup shortest_path Shortest Path algorithms
+@ingroup algs
+\brief Algorithms for finding shortest paths.
+
+This group describes the algorithms for finding shortest paths in graphs.
+*/
+
+/** 
+@defgroup max_flow Maximum Flow algorithms 
+@ingroup algs 
+\brief Algorithms for finding maximum flows.
+
+This group describes the algorithms for finding maximum flows and
+feasible circulations.
+
+The maximum flow problem is to find a flow between a single source and
+a single target that is maximum. Formally, there is a \f$G=(V,A)\f$
+directed graph, an \f$c_a:A\rightarrow\mathbf{R}^+_0\f$ capacity
+function and given \f$s, t \in V\f$ source and target node. The
+maximum flow is the \f$f_a\f$ solution of the next optimization problem:
+
+\f[ 0 \le f_a \le c_a \f]
+\f[ \sum_{v\in\delta^{-}(u)}f_{vu}=\sum_{v\in\delta^{+}(u)}f_{uv} \qquad \forall u \in V \setminus \{s,t\}\f]
+\f[ \max \sum_{v\in\delta^{+}(s)}f_{uv} - \sum_{v\in\delta^{-}(s)}f_{vu}\f]
+
+LEMON contains several algorithms for solving maximum flow problems:
+- \ref lemon::EdmondsKarp "Edmonds-Karp" 
+- \ref lemon::Preflow "Goldberg's Preflow algorithm"
+- \ref lemon::DinitzSleatorTarjan "Dinitz's blocking flow algorithm with dynamic trees"
+- \ref lemon::GoldbergTarjan "Preflow algorithm with dynamic trees"
+
+In most cases the \ref lemon::Preflow "Preflow" algorithm provides the
+fastest method to compute the maximum flow. All impelementations
+provides functions to query the minimum cut, which is the dual linear
+programming problem of the maximum flow.
+
+*/
+
+/**
+@defgroup min_cost_flow Minimum Cost Flow algorithms
+@ingroup algs
+
+\brief Algorithms for finding minimum cost flows and circulations.
+
+This group describes the algorithms for finding minimum cost flows and
+circulations.  
+*/
+
+/**
+@defgroup min_cut Minimum Cut algorithms 
+@ingroup algs 
+
+\brief Algorithms for finding minimum cut in graphs.
+
+This group describes the algorithms for finding minimum cut in graphs.
+
+The minimum cut problem is to find a non-empty and non-complete
+\f$X\f$ subset of the vertices with minimum overall capacity on
+outgoing arcs. Formally, there is \f$G=(V,A)\f$ directed graph, an
+\f$c_a:A\rightarrow\mathbf{R}^+_0\f$ capacity function. The minimum
+cut is the \f$X\f$ solution of the next optimization problem:
+
+\f[ \min_{X \subset V, X\not\in \{\emptyset, V\}}\sum_{uv\in A, u\in X, v\not\in X}c_{uv}\f]
+
+LEMON contains several algorithms related to minimum cut problems:
+
+- \ref lemon::HaoOrlin "Hao-Orlin algorithm" to calculate minimum cut
+  in directed graphs  
+- \ref lemon::NagamochiIbaraki "Nagamochi-Ibaraki algorithm" to
+  calculate minimum cut in undirected graphs
+- \ref lemon::GomoryHuTree "Gomory-Hu tree computation" to calculate all
+  pairs minimum cut in undirected graphs
+
+If you want to find minimum cut just between two distinict nodes,
+please see the \ref max_flow "Maximum Flow page".
+
+*/
+
+/**
+@defgroup graph_prop Connectivity and other graph properties
+@ingroup algs
+\brief Algorithms for discovering the graph properties
+
+This group describes the algorithms for discovering the graph properties
+like connectivity, bipartiteness, euler property, simplicity etc.
+
+\image html edge_biconnected_components.png
+\image latex edge_biconnected_components.eps "bi-edge-connected components" width=\textwidth
+*/
+
+/**
+@defgroup planar Planarity embedding and drawing
+@ingroup algs
+\brief Algorithms for planarity checking, embedding and drawing
+
+This group describes the algorithms for planarity checking, embedding and drawing.
+
+\image html planar.png
+\image latex planar.eps "Plane graph" width=\textwidth
+*/
+
+/**
+@defgroup matching Matching algorithms 
+@ingroup algs
+\brief Algorithms for finding matchings in graphs and bipartite graphs.
+
+This group contains algorithm objects and functions to calculate
+matchings in graphs and bipartite graphs. The general matching problem is
+finding a subset of the edges which does not shares common endpoints.
+ 
+There are several different algorithms for calculate matchings in
+graphs.  The matching problems in bipartite graphs are generally
+easier than in general graphs. The goal of the matching optimization
+can be the finding maximum cardinality, maximum weight or minimum cost
+matching. The search can be constrained to find perfect or
+maximum cardinality matching.
+
+Lemon contains the next algorithms:
+- \ref lemon::MaxBipartiteMatching "MaxBipartiteMatching" Hopcroft-Karp 
+  augmenting path algorithm for calculate maximum cardinality matching in 
+  bipartite graphs
+- \ref lemon::PrBipartiteMatching "PrBipartiteMatching" Push-Relabel 
+  algorithm for calculate maximum cardinality matching in bipartite graphs 
+- \ref lemon::MaxWeightedBipartiteMatching "MaxWeightedBipartiteMatching" 
+  Successive shortest path algorithm for calculate maximum weighted matching 
+  and maximum weighted bipartite matching in bipartite graph
+- \ref lemon::MinCostMaxBipartiteMatching "MinCostMaxBipartiteMatching" 
+  Successive shortest path algorithm for calculate minimum cost maximum 
+  matching in bipartite graph
+- \ref lemon::MaxMatching "MaxMatching" Edmond's blossom shrinking algorithm
+  for calculate maximum cardinality matching in general graph
+- \ref lemon::MaxWeightedMatching "MaxWeightedMatching" Edmond's blossom
+  shrinking algorithm for calculate maximum weighted matching in general
+  graph
+- \ref lemon::MaxWeightedPerfectMatching "MaxWeightedPerfectMatching"
+  Edmond's blossom shrinking algorithm for calculate maximum weighted
+  perfect matching in general graph
+
+\image html bipartite_matching.png
+\image latex bipartite_matching.eps "Bipartite Matching" width=\textwidth
+
+*/
+
+/**
+@defgroup spantree Minimum Spanning Tree algorithms
+@ingroup algs
+\brief Algorithms for finding a minimum cost spanning tree in a graph.
+
+This group describes the algorithms for finding a minimum cost spanning
+tree in a graph
+*/
+
+
+/**
+@defgroup auxalg Auxiliary algorithms
+@ingroup algs
+\brief Auxiliary algorithms implemented in LEMON.
+
+This group describes some algorithms implemented in LEMON
+in order to make it easier to implement complex algorithms.
+*/
+
+/**
+@defgroup approx Approximation algorithms
+\brief Approximation algorithms.
+
+This group describes the approximation and heuristic algorithms
+implemented in LEMON.
+*/
+
+/**
+@defgroup gen_opt_group General Optimization Tools
+\brief This group describes some general optimization frameworks
+implemented in LEMON.
+
+This group describes some general optimization frameworks
+implemented in LEMON.
+
+*/
+
+/**
+@defgroup lp_group Lp and Mip solvers
+@ingroup gen_opt_group
+\brief Lp and Mip solver interfaces for LEMON.
+
+This group describes Lp and Mip solver interfaces for LEMON. The
+various LP solvers could be used in the same manner with this
+interface.
+
+*/
+
+/** 
+@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 describes some metaheuristic optimization tools.
+*/
+
+/**
+@defgroup utils Tools and Utilities 
+\brief Tools and utilities for programming in LEMON
+
+Tools and utilities for programming in LEMON.
+*/
+
+/**
+@defgroup gutils Basic Graph Utilities
+@ingroup utils
+\brief Simple basic graph utilities.
+
+This group describes some simple basic graph utilities.
+*/
+
+/**
+@defgroup misc Miscellaneous Tools
+@ingroup utils
+\brief Tools for development, debugging and testing.
+
+This group describes several useful tools for development,
+debugging and testing.
+*/
+
+/**
+@defgroup timecount Time measuring and Counting
+@ingroup misc
+\brief Simple tools for measuring the performance of algorithms.
+
+This group describes simple tools for measuring the performance
+of algorithms.
+*/
+
+/**
+@defgroup graphbits Tools for Graph Implementation
+@ingroup utils
+\brief Tools to make it easier to create graphs.
+
+This group describes the tools that makes it easier to create graphs and
+the maps that dynamically update with the graph changes.
+*/
+
+/**
+@defgroup exceptions Exceptions
+@ingroup utils
+\brief Exceptions defined in LEMON.
+
+This group describes the exceptions defined in LEMON.
+*/
+
+/**
+@defgroup io_group Input-Output
+\brief Graph Input-Output methods
+
+This group describes the tools for importing and exporting graphs 
+and graph related data. Now it supports the LEMON format, the
+\c DIMACS format and the encapsulated postscript (EPS) format.
+*/
+
+/**
+@defgroup lemon_io Lemon Input-Output
+@ingroup io_group
+\brief Reading and writing LEMON format
+
+This group describes methods for reading and writing LEMON format. 
+You can find more about this format on the \ref graph-io-page "Graph Input-Output"
+tutorial pages.
+*/
+
+/**
+@defgroup section_io Section readers and writers
+@ingroup lemon_io
+\brief Section readers and writers for LEMON Input-Output.
+
+This group describes section reader and writer classes that can be 
+attached to \ref LemonReader and \ref LemonWriter.
+*/
+
+/**
+@defgroup item_io Item readers and writers
+@ingroup lemon_io
+\brief Item readers and writers for LEMON Input-Output.
+
+This group describes reader and writer classes for various data types
+(e.g. map or attribute values). These classes can be attached to
+\ref LemonReader and \ref LemonWriter.
+*/
+
+/**
+@defgroup eps_io Postscript exporting
+@ingroup io_group
+\brief General \c EPS drawer and graph exporter
+
+This group describes general \c EPS drawing methods and special
+graph exporting tools. 
+*/
+
+
+/**
+@defgroup concept Concepts
+\brief Skeleton classes and concept checking classes
+
+This group describes the data/algorithm skeletons and concept checking
+classes implemented in LEMON.
+
+The purpose of the classes in this group is fourfold.
+ 
+- These classes contain the documentations of the concepts. In order
+  to avoid document multiplications, an implementation of a concept
+  simply refers to the corresponding concept class.
+
+- These classes declare every functions, <tt>typedef</tt>s etc. an
+  implementation of the concepts should provide, however completely
+  without implementations and real data structures behind the
+  interface. On the other hand they should provide nothing else. All
+  the algorithms working on a data structure meeting a certain concept
+  should compile with these classes. (Though it will not run properly,
+  of course.) In this way it is easily to check if an algorithm
+  doesn't use any extra feature of a certain implementation.
+
+- The concept descriptor classes also provide a <em>checker class</em>
+  that makes it possible to check whether a certain implementation of a
+  concept indeed provides all the required features.
+
+- Finally, They can serve as a skeleton of a new implementation of a concept.
+
+*/
+
+
+/**
+@defgroup graph_concepts Graph Structure Concepts
+@ingroup concept
+\brief Skeleton and concept checking classes for graph structures
+
+This group describes the skeletons and concept checking classes of LEMON's
+graph structures and helper classes used to implement these.
+*/
+
+/* --- Unused group
+@defgroup experimental Experimental Structures and Algorithms
+This group describes some Experimental structures and algorithms.
+The stuff here is subject to change.
+*/
+
+/**
+\anchor demoprograms
+
+@defgroup demos Demo programs
+
+Some demo programs are listed here. Their full source codes can be found in
+the \c demo subdirectory of the source tree.
+
+It order to compile them, use <tt>--enable-demo</tt> configure option when
+build the library.
+*/
+
+/**
+@defgroup tools Standalone utility applications
+
+Some utility applications are listed here. 
+
+The standard compilation procedure (<tt>./configure;make</tt>) will compile
+them, as well. 
+*/
+
Index: doc/images/bipartite_matching.eps
===================================================================
--- doc/images/bipartite_matching.eps	(revision 2060)
+++ doc/images/bipartite_matching.eps	(revision 2060)
@@ -0,0 +1,586 @@
+%!PS-Adobe-3.0 EPSF-3.0
+%%BoundingBox: 15 18 829 570
+%%HiResBoundingBox: 15.1913 18.4493 828.078 569.438
+%%Creator: Karbon14 EPS Exportfilter 0.5
+%%CreationDate: (04/15/06 15:20:26)
+%%For: (Balazs Dezso) ()
+%%Title: ()
+
+/N {newpath} def
+/C {closepath} def
+/m {moveto} def
+/c {curveto} def
+/l {lineto} def
+/s {stroke} def
+/f {fill} def
+/w {setlinewidth} def
+/d {setdash} def
+/r {setrgbcolor} def
+/S {gsave} def
+/R {grestore} def
+
+N
+251.402 32.047 m
+532.945 293.946 814.484 555.844 814.484 555.844 c
+[] 0 d 1 0 0 r 3.92814 w s
+
+N
+749.012 32.047 m
+742.465 293.946 735.918 555.844 735.918 555.844 c
+[] 0 d 0 0 0 r 1.96407 w s
+
+N
+539.492 32.047 m
+637.703 293.946 735.918 555.844 735.918 555.844 c
+[] 0 d 0 0 0 r 1.96407 w s
+
+N
+172.832 32.047 m
+454.375 293.946 735.918 555.844 735.918 555.844 c
+[] 0 d 0 0 0 r 1.96407 w s
+
+N
+107.355 32.047 m
+421.637 293.946 735.918 555.844 735.918 555.844 c
+[] 0 d 1 0 0 r 3.92814 w s
+
+N
+644.25 555.844 m
+696.633 293.946 749.012 32.047 749.012 32.047 c
+[] 0 d 0 0 0 r 1.96407 w s
+
+N
+474.016 555.844 m
+611.516 293.946 749.012 32.047 749.012 32.047 c
+[] 0 d 1 0 0 r 3.92814 w s
+
+N
+683.535 32.047 m
+663.894 293.946 644.25 555.844 644.25 555.844 c
+[] 0 d 0 0 0 r 1.96407 w s
+
+N
+120.453 555.844 m
+401.992 293.946 683.535 32.047 683.535 32.047 c
+[] 0 d 0 0 0 r 1.96407 w s
+
+N
+28.7853 555.844 m
+356.16 293.946 683.535 32.047 683.535 32.047 c
+[] 0 d 1 0 0 r 3.92814 w s
+
+N
+539.492 32.047 m
+546.039 293.946 552.586 555.844 552.586 555.844 c
+[] 0 d 1 0 0 r 3.92814 w s
+
+N
+316.875 32.047 m
+349.613 293.946 382.351 555.844 382.351 555.844 c
+[] 0 d 1 0 0 r 3.92814 w s
+
+N
+107.355 32.047 m
+244.855 293.946 382.351 555.844 382.351 555.844 c
+[] 0 d 0 0 0 r 1.96407 w s
+
+N
+290.687 555.844 m
+375.805 293.946 460.922 32.047 460.922 32.047 c
+[] 0 d 1 0 0 r 3.92814 w s
+
+N
+120.453 555.844 m
+290.687 293.946 460.922 32.047 460.922 32.047 c
+[] 0 d 0 0 0 r 1.96407 w s
+
+N
+172.832 32.047 m
+146.64 293.946 120.453 555.844 120.453 555.844 c
+[] 0 d 1 0 0 r 3.92814 w s
+
+N
+15.6913 555.844 m
+15.6913 555.844 l
+15.6913 548.614 21.5553 542.75 28.7853 542.75 c
+36.0163 542.75 41.8833 548.614 41.8833 555.844 c
+41.8833 563.075 36.0163 568.938 28.7853 568.938 c
+21.5553 568.938 15.6913 563.075 15.6913 555.844 c
+15.6913 555.844 l
+C
+S 0 0 0 r f R
+
+N
+16.8833 555.844 m
+16.8833 555.844 l
+16.8833 549.27 22.2113 543.942 28.7853 543.942 c
+35.3593 543.942 40.6913 549.27 40.6913 555.844 c
+40.6913 562.418 35.3593 567.747 28.7853 567.747 c
+22.2113 567.747 16.8833 562.418 16.8833 555.844 c
+16.8833 555.844 l
+C
+S 1 0.5 1 r f R
+
+N
+107.355 555.844 m
+107.355 555.844 l
+107.355 548.614 113.223 542.75 120.453 542.75 c
+127.683 542.75 133.547 548.614 133.547 555.844 c
+133.547 563.075 127.683 568.938 120.453 568.938 c
+113.223 568.938 107.355 563.075 107.355 555.844 c
+107.355 555.844 l
+C
+S 0 0 0 r f R
+
+N
+108.547 555.844 m
+108.547 555.844 l
+108.547 549.27 113.879 543.942 120.453 543.942 c
+127.027 543.942 132.355 549.27 132.355 555.844 c
+132.355 562.418 127.027 567.747 120.453 567.747 c
+113.879 567.747 108.547 562.418 108.547 555.844 c
+108.547 555.844 l
+C
+S 1 0 1 r f R
+
+N
+199.019 555.844 m
+199.019 555.844 l
+199.019 548.614 204.887 542.75 212.117 542.75 c
+219.348 542.75 225.211 548.614 225.211 555.844 c
+225.211 563.075 219.348 568.938 212.117 568.938 c
+204.887 568.938 199.019 563.075 199.019 555.844 c
+199.019 555.844 l
+C
+S 0 0 0 r f R
+
+N
+200.211 555.844 m
+200.211 555.844 l
+200.211 549.27 205.543 543.942 212.117 543.942 c
+218.691 543.942 224.019 549.27 224.019 555.844 c
+224.019 562.418 218.691 567.747 212.117 567.747 c
+205.543 567.747 200.211 562.418 200.211 555.844 c
+200.211 555.844 l
+C
+S 1 0.5 1 r f R
+
+N
+277.59 555.844 m
+277.59 555.844 l
+277.59 548.614 283.457 542.75 290.687 542.75 c
+297.918 542.75 303.781 548.614 303.781 555.844 c
+303.781 563.075 297.918 568.938 290.687 568.938 c
+283.457 568.938 277.59 563.075 277.59 555.844 c
+277.59 555.844 l
+C
+S 0 0 0 r f R
+
+N
+278.781 555.844 m
+278.781 555.844 l
+278.781 549.27 284.113 543.942 290.687 543.942 c
+297.262 543.942 302.59 549.27 302.59 555.844 c
+302.59 562.418 297.262 567.747 290.687 567.747 c
+284.113 567.747 278.781 562.418 278.781 555.844 c
+278.781 555.844 l
+C
+S 1 0 1 r f R
+
+N
+369.258 555.844 m
+369.258 555.844 l
+369.258 548.614 375.121 542.75 382.351 542.75 c
+389.582 542.75 395.445 548.614 395.445 555.844 c
+395.445 563.075 389.582 568.938 382.351 568.938 c
+375.121 568.938 369.258 563.075 369.258 555.844 c
+369.258 555.844 l
+C
+S 0 0 0 r f R
+
+N
+370.445 555.844 m
+370.445 555.844 l
+370.445 549.27 375.777 543.942 382.351 543.942 c
+388.926 543.942 394.258 549.27 394.258 555.844 c
+394.258 562.418 388.926 567.747 382.351 567.747 c
+375.777 567.747 370.445 562.418 370.445 555.844 c
+370.445 555.844 l
+C
+S 1 0 1 r f R
+
+N
+460.922 555.844 m
+460.922 555.844 l
+460.922 548.614 466.785 542.75 474.016 542.75 c
+481.246 542.75 487.109 548.614 487.109 555.844 c
+487.109 563.075 481.246 568.938 474.016 568.938 c
+466.785 568.938 460.922 563.075 460.922 555.844 c
+460.922 555.844 l
+C
+S 0 0 0 r f R
+
+N
+462.113 555.844 m
+462.113 555.844 l
+462.113 549.27 467.441 543.942 474.016 543.942 c
+480.59 543.942 485.922 549.27 485.922 555.844 c
+485.922 562.418 480.59 567.747 474.016 567.747 c
+467.441 567.747 462.113 562.418 462.113 555.844 c
+462.113 555.844 l
+C
+S 1 0.5 1 r f R
+
+N
+539.492 555.844 m
+539.492 555.844 l
+539.492 548.614 545.355 542.75 552.586 542.75 c
+559.816 542.75 565.68 548.614 565.68 555.844 c
+565.68 563.075 559.816 568.938 552.586 568.938 c
+545.355 568.938 539.492 563.075 539.492 555.844 c
+539.492 555.844 l
+C
+S 0 0 0 r f R
+
+N
+540.683 555.844 m
+540.683 555.844 l
+540.683 549.27 546.012 543.942 552.586 543.942 c
+559.16 543.942 564.492 549.27 564.492 555.844 c
+564.492 562.418 559.16 567.747 552.586 567.747 c
+546.012 567.747 540.683 562.418 540.683 555.844 c
+540.683 555.844 l
+C
+S 1 0 1 r f R
+
+N
+631.156 555.844 m
+631.156 555.844 l
+631.156 548.614 637.019 542.75 644.25 542.75 c
+651.48 542.75 657.348 548.614 657.348 555.844 c
+657.348 563.075 651.48 568.938 644.25 568.938 c
+637.019 568.938 631.156 563.075 631.156 555.844 c
+631.156 555.844 l
+C
+S 0 0 0 r f R
+
+N
+632.348 555.844 m
+632.348 555.844 l
+632.348 549.27 637.676 543.942 644.25 543.942 c
+650.824 543.942 656.156 549.27 656.156 555.844 c
+656.156 562.418 650.824 567.747 644.25 567.747 c
+637.676 567.747 632.348 562.418 632.348 555.844 c
+632.348 555.844 l
+C
+S 1 0.5 1 r f R
+
+N
+722.82 555.844 m
+722.82 555.844 l
+722.82 548.614 728.687 542.75 735.918 542.75 c
+743.149 542.75 749.012 548.614 749.012 555.844 c
+749.012 563.075 743.149 568.938 735.918 568.938 c
+728.687 568.938 722.82 563.075 722.82 555.844 c
+722.82 555.844 l
+C
+S 0 0 0 r f R
+
+N
+724.012 555.844 m
+724.012 555.844 l
+724.012 549.27 729.344 543.942 735.918 543.942 c
+742.492 543.942 747.82 549.27 747.82 555.844 c
+747.82 562.418 742.492 567.747 735.918 567.747 c
+729.344 567.747 724.012 562.418 724.012 555.844 c
+724.012 555.844 l
+C
+S 1 0 1 r f R
+
+N
+801.391 555.844 m
+801.391 555.844 l
+801.391 548.614 807.254 542.75 814.484 542.75 c
+821.715 542.75 827.578 548.614 827.578 555.844 c
+827.578 563.075 821.715 568.938 814.484 568.938 c
+807.254 568.938 801.391 563.075 801.391 555.844 c
+801.391 555.844 l
+C
+S 0 0 0 r f R
+
+N
+802.582 555.844 m
+802.582 555.844 l
+802.582 549.27 807.91 543.942 814.484 543.942 c
+821.059 543.942 826.387 549.27 826.387 555.844 c
+826.387 562.418 821.059 567.747 814.484 567.747 c
+807.91 567.747 802.582 562.418 802.582 555.844 c
+802.582 555.844 l
+C
+S 1 0 1 r f R
+
+N
+15.6913 32.047 m
+15.6913 32.047 l
+15.6913 24.8165 21.5553 18.9493 28.7853 18.9493 c
+36.0163 18.9493 41.8833 24.8165 41.8833 32.047 c
+41.8833 39.2775 36.0163 45.1407 28.7853 45.1407 c
+21.5553 45.1407 15.6913 39.2775 15.6913 32.047 c
+15.6913 32.047 l
+C
+S 0 0 0 r f R
+
+N
+16.8833 32.047 m
+16.8833 32.047 l
+16.8833 25.4728 22.2113 20.1407 28.7853 20.1407 c
+35.3593 20.1407 40.6913 25.4728 40.6913 32.047 c
+40.6913 38.6212 35.3593 43.9493 28.7853 43.9493 c
+22.2113 43.9493 16.8833 38.6212 16.8833 32.047 c
+16.8833 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+N
+94.2623 32.047 m
+94.2623 32.047 l
+94.2623 24.8165 100.125 18.9493 107.355 18.9493 c
+114.586 18.9493 120.453 24.8165 120.453 32.047 c
+120.453 39.2775 114.586 45.1407 107.355 45.1407 c
+100.125 45.1407 94.2623 39.2775 94.2623 32.047 c
+94.2623 32.047 l
+C
+S 0 0 0 r f R
+
+N
+95.4533 32.047 m
+95.4533 32.047 l
+95.4533 25.4728 100.781 20.1407 107.355 20.1407 c
+113.93 20.1407 119.262 25.4728 119.262 32.047 c
+119.262 38.6212 113.93 43.9493 107.355 43.9493 c
+100.781 43.9493 95.4533 38.6212 95.4533 32.047 c
+95.4533 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+N
+159.734 32.047 m
+159.734 32.047 l
+159.734 24.8165 165.601 18.9493 172.832 18.9493 c
+180.062 18.9493 185.926 24.8165 185.926 32.047 c
+185.926 39.2775 180.062 45.1407 172.832 45.1407 c
+165.601 45.1407 159.734 39.2775 159.734 32.047 c
+159.734 32.047 l
+C
+S 0 0 0 r f R
+
+N
+160.926 32.047 m
+160.926 32.047 l
+160.926 25.4728 166.258 20.1407 172.832 20.1407 c
+179.406 20.1407 184.734 25.4728 184.734 32.047 c
+184.734 38.6212 179.406 43.9493 172.832 43.9493 c
+166.258 43.9493 160.926 38.6212 160.926 32.047 c
+160.926 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+N
+238.305 32.047 m
+238.305 32.047 l
+238.305 24.8165 244.172 18.9493 251.402 18.9493 c
+258.633 18.9493 264.496 24.8165 264.496 32.047 c
+264.496 39.2775 258.633 45.1407 251.402 45.1407 c
+244.172 45.1407 238.305 39.2775 238.305 32.047 c
+238.305 32.047 l
+C
+S 0 0 0 r f R
+
+N
+239.496 32.047 m
+239.496 32.047 l
+239.496 25.4728 244.828 20.1407 251.402 20.1407 c
+257.976 20.1407 263.305 25.4728 263.305 32.047 c
+263.305 38.6212 257.976 43.9493 251.402 43.9493 c
+244.828 43.9493 239.496 38.6212 239.496 32.047 c
+239.496 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+N
+303.781 32.047 m
+303.781 32.047 l
+303.781 24.8165 309.644 18.9493 316.875 18.9493 c
+324.105 18.9493 329.973 24.8165 329.973 32.047 c
+329.973 39.2775 324.105 45.1407 316.875 45.1407 c
+309.644 45.1407 303.781 39.2775 303.781 32.047 c
+303.781 32.047 l
+C
+S 0 0 0 r f R
+
+N
+304.973 32.047 m
+304.973 32.047 l
+304.973 25.4728 310.301 20.1407 316.875 20.1407 c
+323.449 20.1407 328.781 25.4728 328.781 32.047 c
+328.781 38.6212 323.449 43.9493 316.875 43.9493 c
+310.301 43.9493 304.973 38.6212 304.973 32.047 c
+304.973 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+N
+382.351 32.047 m
+382.351 32.047 l
+382.351 24.8165 388.215 18.9493 395.445 18.9493 c
+402.676 18.9493 408.543 24.8165 408.543 32.047 c
+408.543 39.2775 402.676 45.1407 395.445 45.1407 c
+388.215 45.1407 382.351 39.2775 382.351 32.047 c
+382.351 32.047 l
+C
+S 0 0 0 r f R
+
+N
+383.543 32.047 m
+383.543 32.047 l
+383.543 25.4728 388.871 20.1407 395.445 20.1407 c
+402.019 20.1407 407.351 25.4728 407.351 32.047 c
+407.351 38.6212 402.019 43.9493 395.445 43.9493 c
+388.871 43.9493 383.543 38.6212 383.543 32.047 c
+383.543 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+N
+447.828 32.047 m
+447.828 32.047 l
+447.828 24.8165 453.691 18.9493 460.922 18.9493 c
+468.152 18.9493 474.016 24.8165 474.016 32.047 c
+474.016 39.2775 468.152 45.1407 460.922 45.1407 c
+453.691 45.1407 447.828 39.2775 447.828 32.047 c
+447.828 32.047 l
+C
+S 0 0 0 r f R
+
+N
+449.016 32.047 m
+449.016 32.047 l
+449.016 25.4728 454.348 20.1407 460.922 20.1407 c
+467.496 20.1407 472.824 25.4728 472.824 32.047 c
+472.824 38.6212 467.496 43.9493 460.922 43.9493 c
+454.348 43.9493 449.016 38.6212 449.016 32.047 c
+449.016 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+N
+526.394 32.047 m
+526.394 32.047 l
+526.394 24.8165 532.262 18.9493 539.492 18.9493 c
+546.723 18.9493 552.586 24.8165 552.586 32.047 c
+552.586 39.2775 546.723 45.1407 539.492 45.1407 c
+532.262 45.1407 526.394 39.2775 526.394 32.047 c
+526.394 32.047 l
+C
+S 0 0 0 r f R
+
+N
+527.586 32.047 m
+527.586 32.047 l
+527.586 25.4728 532.918 20.1407 539.492 20.1407 c
+546.066 20.1407 551.394 25.4728 551.394 32.047 c
+551.394 38.6212 546.066 43.9493 539.492 43.9493 c
+532.918 43.9493 527.586 38.6212 527.586 32.047 c
+527.586 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+N
+591.871 32.047 m
+591.871 32.047 l
+591.871 24.8165 597.734 18.9493 604.965 18.9493 c
+612.195 18.9493 618.062 24.8165 618.062 32.047 c
+618.062 39.2775 612.195 45.1407 604.965 45.1407 c
+597.734 45.1407 591.871 39.2775 591.871 32.047 c
+591.871 32.047 l
+C
+S 0 0 0 r f R
+
+N
+593.062 32.047 m
+593.062 32.047 l
+593.062 25.4728 598.39 20.1407 604.965 20.1407 c
+611.539 20.1407 616.871 25.4728 616.871 32.047 c
+616.871 38.6212 611.539 43.9493 604.965 43.9493 c
+598.39 43.9493 593.062 38.6212 593.062 32.047 c
+593.062 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+N
+670.441 32.047 m
+670.441 32.047 l
+670.441 24.8165 676.305 18.9493 683.535 18.9493 c
+690.766 18.9493 696.633 24.8165 696.633 32.047 c
+696.633 39.2775 690.766 45.1407 683.535 45.1407 c
+676.305 45.1407 670.441 39.2775 670.441 32.047 c
+670.441 32.047 l
+C
+S 0 0 0 r f R
+
+N
+671.633 32.047 m
+671.633 32.047 l
+671.633 25.4728 676.961 20.1407 683.535 20.1407 c
+690.109 20.1407 695.441 25.4728 695.441 32.047 c
+695.441 38.6212 690.109 43.9493 683.535 43.9493 c
+676.961 43.9493 671.633 38.6212 671.633 32.047 c
+671.633 32.047 l
+C
+S 0 0 1 r f R
+
+N
+735.918 32.047 m
+735.918 32.047 l
+735.918 24.8165 741.781 18.9493 749.012 18.9493 c
+756.242 18.9493 762.106 24.8165 762.106 32.047 c
+762.106 39.2775 756.242 45.1407 749.012 45.1407 c
+741.781 45.1407 735.918 39.2775 735.918 32.047 c
+735.918 32.047 l
+C
+S 0 0 0 r f R
+
+N
+737.105 32.047 m
+737.105 32.047 l
+737.105 25.4728 742.437 20.1407 749.012 20.1407 c
+755.586 20.1407 760.914 25.4728 760.914 32.047 c
+760.914 38.6212 755.586 43.9493 749.012 43.9493 c
+742.437 43.9493 737.105 38.6212 737.105 32.047 c
+737.105 32.047 l
+C
+S 0 0 1 r f R
+
+N
+801.391 32.047 m
+801.391 32.047 l
+801.391 24.8165 807.254 18.9493 814.484 18.9493 c
+821.715 18.9493 827.578 24.8165 827.578 32.047 c
+827.578 39.2775 821.715 45.1407 814.484 45.1407 c
+807.254 45.1407 801.391 39.2775 801.391 32.047 c
+801.391 32.047 l
+C
+S 0 0 0 r f R
+
+N
+802.582 32.047 m
+802.582 32.047 l
+802.582 25.4728 807.91 20.1407 814.484 20.1407 c
+821.059 20.1407 826.387 25.4728 826.387 32.047 c
+826.387 38.6212 821.059 43.9493 814.484 43.9493 c
+807.91 43.9493 802.582 38.6212 802.582 32.047 c
+802.582 32.047 l
+C
+S 0.5 0.5 1 r f R
+
+%%EOF
Index: doc/images/bipartite_partitions.eps
===================================================================
--- doc/images/bipartite_partitions.eps	(revision 1801)
+++ doc/images/bipartite_partitions.eps	(revision 1801)
@@ -0,0 +1,113 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Tue Nov 15 16:51:43 2005
+%%BoundingBox: 0 0 596 842
+%%DocumentPaperSizes: a4
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+71.6378 15 translate
+0.389093 dup scale
+90 rotate
+1197.47 -613.138 translate
+%Edges:
+gsave
+513.857 -446.322 296.569 -487.43 79.2808 -528.539 0 0 0 2 lb
+513.857 -446.322 575.52 -315.655 637.183 -184.989 0 0 0 2 lb
+393.468 566.711 494.771 434.577 596.074 302.442 0 0 0 2 lb
+393.468 566.711 155.625 579.925 -82.2171 593.138 0 0 0 2 lb
+393.468 566.711 251.056 450.726 108.644 334.741 0 0 0 2 lb
+869.153 52.8539 732.613 177.648 596.074 302.442 0 0 0 2 lb
+869.153 52.8539 753.168 -66.0676 637.183 -184.989 0 0 0 2 lb
+-82.2171 593.138 -91.0261 346.487 -99.8351 99.8351 0 0 0 2 lb
+-663.61 546.157 -753.168 394.936 -842.726 243.715 0 0 0 2 lb
+-663.61 546.157 -574.052 437.513 -484.494 328.869 0 0 0 2 lb
+-1077.63 161.498 -960.178 202.606 -842.726 243.715 0 0 0 2 lb
+-1077.63 161.498 -968.987 66.0674 -860.344 -29.3633 0 0 0 2 lb
+-1177.47 -234.906 -1029.18 -381.722 -880.898 -528.539 0 0 0 2 lb
+-1177.47 -234.906 -1018.91 -132.135 -860.344 -29.3633 0 0 0 2 lb
+-880.898 -528.539 -744.359 -387.595 -607.82 -246.651 0 0 0 2 lb
+-499.175 -499.175 -355.295 -475.685 -211.415 -452.194 0 0 0 2 lb
+-499.175 -499.175 -553.498 -372.913 -607.82 -246.651 0 0 0 2 lb
+-499.175 -499.175 -386.587 -315.087 -274 -131 0 0 0 2 lb
+79.2808 -528.539 -66.0671 -490.366 -211.415 -452.194 0 0 0 2 lb
+637.183 -184.989 421.363 -253.993 205.543 -322.996 0 0 0 2 lb
+205.543 -322.996 162.966 -226.097 120.389 -129.198 0 0 0 2 lb
+399.34 88.0898 259.865 -20.5541 120.389 -129.198 0 0 0 2 lb
+399.34 88.0898 253.992 211.415 108.644 334.741 0 0 0 2 lb
+-842.726 243.715 -471.281 171.775 -99.8351 99.8351 0 0 0 2 lb
+-842.726 243.715 -558.363 56.3575 -274 -131 0 0 0 2 lb
+-860.344 -29.3633 -734.082 -138.007 -607.82 -246.651 0 0 0 2 lb
+-211.415 -452.194 -45.513 -290.696 120.389 -129.198 0 0 0 2 lb
+-99.8351 99.8351 4.40445 217.288 108.644 334.741 0 0 0 2 lb
+-99.8351 99.8351 -292.165 214.352 -484.494 328.869 0 0 0 2 lb
+120.389 -129.198 -76.8055 -130.099 -274 -131 0 0 0 2 lb
+grestore
+%Nodes:
+gsave
+-274 -131 20 1 0 0 nc
+-607.82 -246.651 20 1 0 0 nc
+-484.494 328.869 20 0 0 1 nc
+108.644 334.741 20 0 0 1 nc
+120.389 -129.198 20 0 0 1 nc
+-99.8351 99.8351 20 1 0 0 nc
+-211.415 -452.194 20 1 0 0 nc
+-860.344 -29.3633 20 0 0 1 nc
+-842.726 243.715 20 0 0 1 nc
+399.34 88.0898 20 1 0 0 nc
+205.543 -322.996 20 1 0 0 nc
+637.183 -184.989 20 0 0 1 nc
+79.2808 -528.539 20 0 0 1 nc
+-499.175 -499.175 20 0 0 1 nc
+-880.898 -528.539 20 0 0 1 nc
+-1177.47 -234.906 20 1 0 0 nc
+-1077.63 161.498 20 1 0 0 nc
+-663.61 546.157 20 1 0 0 nc
+-82.2171 593.138 20 0 0 1 nc
+596.074 302.442 20 0 0 1 nc
+869.153 52.8539 20 1 0 0 nc
+393.468 566.711 20 1 0 0 nc
+513.857 -446.322 20 1 0 0 nc
+grestore
+grestore
+showpage
Index: doc/images/connected_components.eps
===================================================================
--- doc/images/connected_components.eps	(revision 1789)
+++ doc/images/connected_components.eps	(revision 1789)
@@ -0,0 +1,158 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Fri Nov  4 13:47:12 2005
+%%BoundingBox: 0 0 596 842
+%%DocumentPaperSizes: a4
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+71.0944 15 translate
+0.434694 dup scale
+90 rotate
+860.856 -588.349 translate
+%Edges:
+gsave
+574.035 177.301 622.149 225.748 670.264 274.195 0 0 0 2 lb
+694.579 115.483 682.421 194.839 670.264 274.195 0 0 0 2 lb
+280.402 10.3938 246.402 -6.60595 212.403 -23.6057 0 0 0 2 lb
+280.402 10.3938 283.493 -18.9695 286.584 -48.3327 0 0 0 2 lb
+212.403 -23.6057 249.493 -35.9692 286.584 -48.3327 0 0 0 2 lb
+286.584 -48.3327 326.765 -79.2414 366.947 -110.15 0 0 0 2 lb
+286.584 -48.3327 278.857 -111.695 271.13 -175.058 0 0 0 2 lb
+438.037 -88.514 417.946 -142.604 397.855 -196.694 0 0 0 2 lb
+438.037 -88.514 402.492 -99.332 366.947 -110.15 0 0 0 2 lb
+397.855 -196.694 382.401 -153.422 366.947 -110.15 0 0 0 2 lb
+366.947 -110.15 319.038 -142.604 271.13 -175.058 0 0 0 2 lb
+271.13 -175.058 274.221 -213.694 277.311 -252.33 0 0 0 2 lb
+271.13 -175.058 238.675 -190.512 206.221 -205.967 0 0 0 2 lb
+277.311 -252.33 241.766 -229.149 206.221 -205.967 0 0 0 2 lb
+-840.856 -246.718 -804.351 -66.7145 -767.847 113.289 0 0 0 2 lb
+-579.033 445.603 -673.44 279.446 -767.847 113.289 0 0 0 2 lb
+-579.033 445.603 -524.906 302.104 -470.779 158.605 0 0 0 2 lb
+-767.847 113.289 -619.313 135.947 -470.779 158.605 0 0 0 2 lb
+906.312 201.403 946.592 42.798 986.873 -115.807 0 0 0 2 lb
+906.312 201.403 834.562 91.8901 762.812 -17.6227 0 0 0 2 lb
+986.873 -115.807 874.842 -66.7148 762.812 -17.6227 0 0 0 2 lb
+-470.779 158.605 -390.218 50.3508 -309.657 -57.9033 0 0 0 2 lb
+422.945 521.129 208.955 541.269 -5.03507 561.41 0 0 0 2 lb
+422.945 521.129 376.371 417.911 329.797 314.692 0 0 0 2 lb
+422.945 521.129 474.554 276.928 526.164 32.7279 0 0 0 2 lb
+-5.03507 561.41 -36.5042 440.568 -67.9734 319.727 0 0 0 2 lb
+329.797 314.692 130.912 317.209 -67.9734 319.727 0 0 0 2 lb
+-67.9734 319.727 229.095 176.227 526.164 32.7279 0 0 0 2 lb
+762.812 -17.6227 644.488 7.5526 526.164 32.7279 0 0 0 2 lb
+762.812 -17.6227 746.448 -162.381 730.084 -307.139 0 0 0 2 lb
+526.164 32.7279 470.779 -128.394 415.393 -289.516 0 0 0 2 lb
+730.084 -307.139 572.738 -298.327 415.393 -289.516 0 0 0 2 lb
+415.393 -289.516 173.71 -318.468 -67.9734 -347.42 0 0 0 2 lb
+-67.9734 -347.42 -188.815 -202.662 -309.657 -57.9033 0 0 0 2 lb
+-67.9734 -347.42 -195.758 -390.692 -323.543 -433.964 0 0 0 2 lb
+-309.657 -57.9033 -424.775 -160.272 -539.894 -262.64 0 0 0 2 lb
+-323.543 -433.964 -431.719 -348.302 -539.894 -262.64 0 0 0 2 lb
+-26.6953 -19.9585 44.8558 -96.8093 116.407 -173.66 0 0 0 2 lb
+-26.6953 -19.9585 87.2563 9.19185 201.208 38.3422 0 0 0 2 lb
+-26.6953 -19.9585 -144.622 43.6422 -262.548 107.243 0 0 0 2 lb
+-26.6953 -19.9585 -20.0703 56.8923 -13.4452 133.743 0 0 0 2 lb
+116.407 -173.66 158.808 -67.6589 201.208 38.3422 0 0 0 2 lb
+-262.548 107.243 -137.997 120.493 -13.4452 133.743 0 0 0 2 lb
+-262.548 107.243 -221.472 176.144 -180.397 245.045 0 0 0 2 lb
+-13.4452 133.743 -96.9211 189.394 -180.397 245.045 0 0 0 2 lb
+-180.397 245.045 -142.256 345.099 -132.697 451.748 0 0 0 2 lb
+-180.397 245.045 -170.838 351.694 -132.697 451.748 0 0 0 2 lb
+-416.25 345.746 -274.474 398.747 -132.697 451.748 0 0 0 2 lb
+-416.25 345.746 -393.725 457.048 -371.2 568.349 0 0 0 2 lb
+-132.697 451.748 -251.948 510.048 -371.2 568.349 0 0 0 2 lb
+670.264 274.195 629.188 409.347 588.113 544.499 0 0 0 2 lb
+670.264 274.195 797.466 341.771 924.667 409.347 0 0 0 2 lb
+588.113 544.499 756.39 476.923 924.667 409.347 0 0 0 2 lb
+-689.204 -237.261 -614.799 -102.648 -567.302 43.6423 0 0 0 2 lb
+-689.204 -237.261 -641.707 -90.9706 -567.302 43.6423 0 0 0 2 lb
+grestore
+%Nodes:
+gsave
+-567.302 43.6423 20 0 0 0 nc
+-689.204 -237.261 20 0 0 0 nc
+924.667 409.347 20 1 0 0 nc
+588.113 544.499 20 1 0 0 nc
+670.264 274.195 20 1 0 0 nc
+-371.2 568.349 20 0 1 0 nc
+-132.697 451.748 20 0 1 0 nc
+-416.25 345.746 20 0 1 0 nc
+-180.397 245.045 20 0 1 0 nc
+-13.4452 133.743 20 0 1 0 nc
+-262.548 107.243 20 0 1 0 nc
+201.208 38.3422 20 0 1 0 nc
+116.407 -173.66 20 0 1 0 nc
+-26.6953 -19.9585 20 0 1 0 nc
+-539.894 -262.64 20 0 0 1 nc
+-323.543 -433.964 20 0 0 1 nc
+-309.657 -57.9033 20 0 0 1 nc
+-67.9734 -347.42 20 0 0 1 nc
+415.393 -289.516 20 0 0 1 nc
+730.084 -307.139 20 0 0 1 nc
+526.164 32.7279 20 0 0 1 nc
+762.812 -17.6227 20 0 0 1 nc
+-67.9734 319.727 20 0 0 1 nc
+329.797 314.692 20 0 0 1 nc
+-5.03507 561.41 20 0 0 1 nc
+422.945 521.129 20 0 0 1 nc
+-470.779 158.605 20 0 0 1 nc
+986.873 -115.807 20 0 0 1 nc
+906.312 201.403 20 0 0 1 nc
+-767.847 113.289 20 0 0 1 nc
+-579.033 445.603 20 0 0 1 nc
+-840.856 -246.718 20 0 0 1 nc
+206.221 -205.967 20 1 1 0 nc
+277.311 -252.33 20 1 1 0 nc
+271.13 -175.058 20 1 1 0 nc
+366.947 -110.15 20 1 1 0 nc
+397.855 -196.694 20 1 1 0 nc
+438.037 -88.514 20 1 1 0 nc
+286.584 -48.3327 20 1 1 0 nc
+212.403 -23.6057 20 1 1 0 nc
+280.402 10.3938 20 1 1 0 nc
+694.579 115.483 20 1 0 0 nc
+574.035 177.301 20 1 0 0 nc
+grestore
+grestore
+showpage
Index: doc/images/edge_biconnected_components.eps
===================================================================
--- doc/images/edge_biconnected_components.eps	(revision 1789)
+++ doc/images/edge_biconnected_components.eps	(revision 1789)
@@ -0,0 +1,158 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Fri Nov  4 13:47:12 2005
+%%BoundingBox: 0 0 596 842
+%%DocumentPaperSizes: a4
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+71.0944 15 translate
+0.434694 dup scale
+90 rotate
+860.856 -588.349 translate
+%Edges:
+gsave
+574.035 177.301 622.149 225.748 670.264 274.195 1 0 0 2 lb
+694.579 115.483 682.421 194.839 670.264 274.195 1 0 0 2 lb
+280.402 10.3938 246.402 -6.60595 212.403 -23.6057 0 0 1 2 lb
+280.402 10.3938 283.493 -18.9695 286.584 -48.3327 0 0 1 2 lb
+212.403 -23.6057 249.493 -35.9692 286.584 -48.3327 0 0 1 2 lb
+286.584 -48.3327 326.765 -79.2414 366.947 -110.15 0 0 1 2 lb
+286.584 -48.3327 278.857 -111.695 271.13 -175.058 0 0 1 2 lb
+438.037 -88.514 417.946 -142.604 397.855 -196.694 0 0 1 2 lb
+438.037 -88.514 402.492 -99.332 366.947 -110.15 0 0 1 2 lb
+397.855 -196.694 382.401 -153.422 366.947 -110.15 0 0 1 2 lb
+366.947 -110.15 319.038 -142.604 271.13 -175.058 0 0 1 2 lb
+271.13 -175.058 274.221 -213.694 277.311 -252.33 0 0 1 2 lb
+271.13 -175.058 238.675 -190.512 206.221 -205.967 0 0 1 2 lb
+277.311 -252.33 241.766 -229.149 206.221 -205.967 0 0 1 2 lb
+-840.856 -246.718 -804.351 -66.7145 -767.847 113.289 1 0 0 2 lb
+-579.033 445.603 -673.44 279.446 -767.847 113.289 0 0 1 2 lb
+-579.033 445.603 -524.906 302.104 -470.779 158.605 0 0 1 2 lb
+-767.847 113.289 -619.313 135.947 -470.779 158.605 0 0 1 2 lb
+906.312 201.403 946.592 42.798 986.873 -115.807 0 0 1 2 lb
+906.312 201.403 834.562 91.8901 762.812 -17.6227 0 0 1 2 lb
+986.873 -115.807 874.842 -66.7148 762.812 -17.6227 0 0 1 2 lb
+-470.779 158.605 -390.218 50.3508 -309.657 -57.9033 1 0 0 2 lb
+422.945 521.129 208.955 541.269 -5.03507 561.41 0 0 1 2 lb
+422.945 521.129 376.371 417.911 329.797 314.692 0 0 1 2 lb
+422.945 521.129 474.554 276.928 526.164 32.7279 0 0 1 2 lb
+-5.03507 561.41 -36.5042 440.568 -67.9734 319.727 0 0 1 2 lb
+329.797 314.692 130.912 317.209 -67.9734 319.727 0 0 1 2 lb
+-67.9734 319.727 229.095 176.227 526.164 32.7279 0 0 1 2 lb
+762.812 -17.6227 644.488 7.5526 526.164 32.7279 0 0 1 2 lb
+762.812 -17.6227 746.448 -162.381 730.084 -307.139 0 0 1 2 lb
+526.164 32.7279 470.779 -128.394 415.393 -289.516 0 0 1 2 lb
+730.084 -307.139 572.738 -298.327 415.393 -289.516 0 0 1 2 lb
+415.393 -289.516 173.71 -318.468 -67.9734 -347.42 1 0 0 2 lb
+-67.9734 -347.42 -188.815 -202.662 -309.657 -57.9033 0 0 1 2 lb
+-67.9734 -347.42 -195.758 -390.692 -323.543 -433.964 0 0 1 2 lb
+-309.657 -57.9033 -424.775 -160.272 -539.894 -262.64 0 0 1 2 lb
+-323.543 -433.964 -431.719 -348.302 -539.894 -262.64 0 0 1 2 lb
+-26.6953 -19.9585 44.8558 -96.8093 116.407 -173.66 0 0 1 2 lb
+-26.6953 -19.9585 87.2563 9.19185 201.208 38.3422 0 0 1 2 lb
+-26.6953 -19.9585 -144.622 43.6422 -262.548 107.243 0 0 1 2 lb
+-26.6953 -19.9585 -20.0703 56.8923 -13.4452 133.743 0 0 1 2 lb
+116.407 -173.66 158.808 -67.6589 201.208 38.3422 0 0 1 2 lb
+-262.548 107.243 -137.997 120.493 -13.4452 133.743 0 0 1 2 lb
+-262.548 107.243 -221.472 176.144 -180.397 245.045 0 0 1 2 lb
+-13.4452 133.743 -96.9211 189.394 -180.397 245.045 0 0 1 2 lb
+-180.397 245.045 -142.256 345.099 -132.697 451.748 0 0 1 2 lb
+-180.397 245.045 -170.838 351.694 -132.697 451.748 0 0 1 2 lb
+-416.25 345.746 -274.474 398.747 -132.697 451.748 0 0 1 2 lb
+-416.25 345.746 -393.725 457.048 -371.2 568.349 0 0 1 2 lb
+-132.697 451.748 -251.948 510.048 -371.2 568.349 0 0 1 2 lb
+670.264 274.195 629.188 409.347 588.113 544.499 0 0 1 2 lb
+670.264 274.195 797.466 341.771 924.667 409.347 0 0 1 2 lb
+588.113 544.499 756.39 476.923 924.667 409.347 0 0 1 2 lb
+-689.204 -237.261 -614.799 -102.648 -567.302 43.6423 0 0 1 2 lb
+-689.204 -237.261 -641.707 -90.9706 -567.302 43.6423 0 0 1 2 lb
+grestore
+%Nodes:
+gsave
+-567.302 43.6423 20 0 0 0 nc
+-689.204 -237.261 20 0 0 0 nc
+924.667 409.347 20 0 0 1 nc
+588.113 544.499 20 0 0 1 nc
+670.264 274.195 20 0 0 1 nc
+-371.2 568.349 20 1 1 0 nc
+-132.697 451.748 20 1 1 0 nc
+-416.25 345.746 20 1 1 0 nc
+-180.397 245.045 20 1 1 0 nc
+-13.4452 133.743 20 1 1 0 nc
+-262.548 107.243 20 1 1 0 nc
+201.208 38.3422 20 1 1 0 nc
+116.407 -173.66 20 1 1 0 nc
+-26.6953 -19.9585 20 1 1 0 nc
+-539.894 -262.64 20 0 0.5 0 nc
+-323.543 -433.964 20 0 0.5 0 nc
+-309.657 -57.9033 20 0 0.5 0 nc
+-67.9734 -347.42 20 0 0.5 0 nc
+415.393 -289.516 20 0.5 0 0 nc
+730.084 -307.139 20 0.5 0 0 nc
+526.164 32.7279 20 0.5 0 0 nc
+762.812 -17.6227 20 0.5 0 0 nc
+-67.9734 319.727 20 0.5 0 0 nc
+329.797 314.692 20 0.5 0 0 nc
+-5.03507 561.41 20 0.5 0 0 nc
+422.945 521.129 20 0.5 0 0 nc
+-470.779 158.605 20 0 1 1 nc
+986.873 -115.807 20 0.5 0 0 nc
+906.312 201.403 20 0.5 0 0 nc
+-767.847 113.289 20 0 1 1 nc
+-579.033 445.603 20 0 1 1 nc
+-840.856 -246.718 20 1 0 1 nc
+206.221 -205.967 20 0 0 0.5 nc
+277.311 -252.33 20 0 0 0.5 nc
+271.13 -175.058 20 0 0 0.5 nc
+366.947 -110.15 20 0 0 0.5 nc
+397.855 -196.694 20 0 0 0.5 nc
+438.037 -88.514 20 0 0 0.5 nc
+286.584 -48.3327 20 0 0 0.5 nc
+212.403 -23.6057 20 0 0 0.5 nc
+280.402 10.3938 20 0 0 0.5 nc
+694.579 115.483 20 1 0 0 nc
+574.035 177.301 20 0 1 0 nc
+grestore
+grestore
+showpage
Index: doc/images/edge_disjoint.eps
===================================================================
--- doc/images/edge_disjoint.eps	(revision 2079)
+++ doc/images/edge_disjoint.eps	(revision 2079)
@@ -0,0 +1,116 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: edge disjoint path
+%%Copyright: (C) 2006 LEMON Project
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Fri May 12 01:53:21 2006
+%%BoundingBox: -290 -170 470 230
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/nfemale { 0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto 5 index 5 index 5 index 3.01 mul sub
+  lineto 5 index 4 index .7 mul sub 5 index 5 index 2.2 mul sub moveto
+  5 index 4 index .7 mul add 5 index 5 index 2.2 mul sub lineto stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/nmale {
+  0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto
+  5 index 4 index 1 mul 1.5 mul add
+  5 index 5 index 3 sqrt 1.5 mul mul add
+  1 index 1 index lineto
+  1 index 1 index 7 index sub moveto
+  1 index 1 index lineto
+  exch 5 index 3 sqrt .5 mul mul sub exch 5 index .5 mul sub lineto
+  stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+10 dup scale
+%Edges:
+gsave
+15.6433 0.3 0.841178 -0.540758 -27 5 1 0 0 arr
+19.5913 0.3 0.874157 0.485643 -27 5 1 0 0 arr
+10.1803 0.3 0.98387 -0.178885 -20 17 1 0 0 arr
+20.587 0.3 0.972806 0.231621 -18 -14 1 0 0 arr
+15.7631 0.3 0.95448 -0.298275 -13 -4 0 0 0 arr
+15.9706 0.3 0.707107 -0.707107 -9 15 1 0 0 arr
+16.4642 0.3 0.916157 0.400819 -13 -4 1 0 0 arr
+14.5242 0.3 0.966235 -0.257663 -12 7 0 0 0 arr
+10.6619 0.3 0.857493 0.514496 -9 15 1 0 0 arr
+22.4094 0.3 0.939793 -0.341743 3 3 1 0 0 arr
+27.1602 0.3 0.958798 -0.284088 1 21 1 0 0 arr
+25.9258 0.3 0.928477 0.371391 3 3 1 0 0 arr
+25.9072 0.3 0.743294 0.668965 25 -15 1 0 0 arr
+20.5407 0.3 0.928477 0.371391 25 -5 1 0 0 arr
+18.7231 0.3 0.861934 -0.50702 28 13 1 0 0 arr
+14.2315 0.3 0.393919 0.919145 39 -11 0 0 0 arr
+10.6619 0.3 0.514496 -0.857493 39 13 1 0 0 arr
+20.0238 0.3 0.428086 -0.903738 -27 5 1 0 0 arr
+21.8035 0.3 0.964764 -0.263117 3 -9 1 0 0 arr
+14.1328 0.3 0.991228 0.132164 -27 5 0 0 0 arr
+13.5602 0.3 0.961524 0.274721 25 -15 0 0 0 arr
+10 0.3 1 0 28 13 1 0 0 arr
+12.8924 0.3 0.503871 0.863779 -27 5 1 0 0 arr
+grestore
+%Nodes:
+gsave
+-27 5 1 1 1 1 nc
+-13 -4 1 1 1 1 nc
+-9 15 1 1 1 1 nc
+3 -9 1 1 1 1 nc
+3 3 1 1 1 1 nc
+1 21 1 1 1 1 nc
+25 -5 1 1 1 1 nc
+28 13 1 1 1 1 nc
+45 3 1 1 1 1 nc
+-18 -14 1 1 1 1 nc
+25 -15 1 1 1 1 nc
+-12 7 1 1 1 1 nc
+39 -11 1 1 1 1 nc
+39 13 1 1 1 1 nc
+-20 17 1 1 1 1 nc
+grestore
+grestore
+showpage
Index: doc/images/grid_ugraph.eps
===================================================================
--- doc/images/grid_ugraph.eps	(revision 2223)
+++ doc/images/grid_ugraph.eps	(revision 2223)
@@ -0,0 +1,303 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: Grid undirected graph
+%%Copyright: (C) 2006 LEMON Project
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Fri Sep 29 11:55:56 2006
+%%BoundingBox: 0 0 596 842
+%%DocumentPaperSizes: a4
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/nfemale { 0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto 5 index 5 index 5 index 3.01 mul sub
+  lineto 5 index 4 index .7 mul sub 5 index 5 index 2.2 mul sub moveto
+  5 index 4 index .7 mul add 5 index 5 index 2.2 mul sub lineto stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/nmale {
+  0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto
+  5 index 4 index 1 mul 1.5 mul add
+  5 index 5 index 3 sqrt 1.5 mul mul add
+  1 index 1 index lineto
+  1 index 1 index 7 index sub moveto
+  1 index 1 index lineto
+  exch 5 index 3 sqrt .5 mul mul sub exch 5 index .5 mul sub lineto
+  stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+15 60.1011 translate
+7.8206 dup scale
+1.14018 1.14018 translate
+%Edges:
+gsave
+70 80 70 90 0 0 0 0.342053 l
+70 70 70 80 0 0 0 0.342053 l
+70 60 70 70 0 0 0 0.342053 l
+70 50 70 60 0 0 0 0.342053 l
+70 40 70 50 0 0 0 0.342053 l
+70 30 70 40 0 0 0 0.342053 l
+70 20 70 30 0 0 0 0.342053 l
+70 10 70 20 0 0 0 0.342053 l
+70 0 70 10 0 0 0 0.342053 l
+60 80 60 90 0 0 0 0.342053 l
+60 70 60 80 0 0 0 0.342053 l
+60 60 60 70 0 0 0 0.342053 l
+60 50 60 60 0 0 0 0.342053 l
+60 40 60 50 0 0 0 0.342053 l
+60 30 60 40 0 0 0 0.342053 l
+60 20 60 30 0 0 0 0.342053 l
+60 10 60 20 0 0 0 0.342053 l
+60 0 60 10 0 0 0 0.342053 l
+50 80 50 90 0 0 0 0.342053 l
+50 70 50 80 0 0 0 0.342053 l
+50 60 50 70 0 0 0 0.342053 l
+50 50 50 60 0 0 0 0.342053 l
+50 40 50 50 0 0 0 0.342053 l
+50 30 50 40 0 0 0 0.342053 l
+50 20 50 30 0 0 0 0.342053 l
+50 10 50 20 0 0 0 0.342053 l
+50 0 50 10 0 0 0 0.342053 l
+40 80 40 90 0 0 0 0.342053 l
+40 70 40 80 0 0 0 0.342053 l
+40 60 40 70 0 0 0 0.342053 l
+40 50 40 60 0 0 0 0.342053 l
+40 40 40 50 0 0 0 0.342053 l
+40 30 40 40 0 0 0 0.342053 l
+40 20 40 30 0 0 0 0.342053 l
+40 10 40 20 0 0 0 0.342053 l
+40 0 40 10 0 0 0 0.342053 l
+30 80 30 90 0 0 0 0.342053 l
+30 70 30 80 0 0 0 0.342053 l
+30 60 30 70 0 0 0 0.342053 l
+30 50 30 60 0 0 0 0.342053 l
+30 40 30 50 0 0 0 0.342053 l
+30 30 30 40 0 0 0 0.342053 l
+30 20 30 30 0 0 0 0.342053 l
+30 10 30 20 0 0 0 0.342053 l
+30 0 30 10 0 0 0 0.342053 l
+20 80 20 90 0 0 0 0.342053 l
+20 70 20 80 0 0 0 0.342053 l
+20 60 20 70 0 0 0 0.342053 l
+20 50 20 60 0 0 0 0.342053 l
+20 40 20 50 0 0 0 0.342053 l
+20 30 20 40 0 0 0 0.342053 l
+20 20 20 30 0 0 0 0.342053 l
+20 10 20 20 0 0 0 0.342053 l
+20 0 20 10 0 0 0 0.342053 l
+10 80 10 90 0 0 0 0.342053 l
+10 70 10 80 0 0 0 0.342053 l
+10 60 10 70 0 0 0 0.342053 l
+10 50 10 60 0 0 0 0.342053 l
+10 40 10 50 0 0 0 0.342053 l
+10 30 10 40 0 0 0 0.342053 l
+10 20 10 30 0 0 0 0.342053 l
+10 10 10 20 0 0 0 0.342053 l
+10 0 10 10 0 0 0 0.342053 l
+0 80 0 90 0 0 0 0.342053 l
+0 70 0 80 0 0 0 0.342053 l
+0 60 0 70 0 0 0 0.342053 l
+0 50 0 60 0 0 0 0.342053 l
+0 40 0 50 0 0 0 0.342053 l
+0 30 0 40 0 0 0 0.342053 l
+0 20 0 30 0 0 0 0.342053 l
+0 10 0 20 0 0 0 0.342053 l
+0 0 0 10 0 0 0 0.342053 l
+60 90 70 90 0 0 0 0.342053 l
+60 80 70 80 0 0 0 0.342053 l
+60 70 70 70 0 0 0 0.342053 l
+60 60 70 60 0 0 0 0.342053 l
+60 50 70 50 0 0 0 0.342053 l
+60 40 70 40 0 0 0 0.342053 l
+60 30 70 30 0 0 0 0.342053 l
+60 20 70 20 0 0 0 0.342053 l
+60 10 70 10 0 0 0 0.342053 l
+60 0 70 0 0 0 0 0.342053 l
+50 90 60 90 0 0 0 0.342053 l
+50 80 60 80 0 0 0 0.342053 l
+50 70 60 70 0 0 0 0.342053 l
+50 60 60 60 0 0 0 0.342053 l
+50 50 60 50 0 0 0 0.342053 l
+50 40 60 40 0 0 0 0.342053 l
+50 30 60 30 0 0 0 0.342053 l
+50 20 60 20 0 0 0 0.342053 l
+50 10 60 10 0 0 0 0.342053 l
+50 0 60 0 0 0 0 0.342053 l
+40 90 50 90 0 0 0 0.342053 l
+40 80 50 80 0 0 0 0.342053 l
+40 70 50 70 0 0 0 0.342053 l
+40 60 50 60 0 0 0 0.342053 l
+40 50 50 50 0 0 0 0.342053 l
+40 40 50 40 0 0 0 0.342053 l
+40 30 50 30 0 0 0 0.342053 l
+40 20 50 20 0 0 0 0.342053 l
+40 10 50 10 0 0 0 0.342053 l
+40 0 50 0 0 0 0 0.342053 l
+30 90 40 90 0 0 0 0.342053 l
+30 80 40 80 0 0 0 0.342053 l
+30 70 40 70 0 0 0 0.342053 l
+30 60 40 60 0 0 0 0.342053 l
+30 50 40 50 0 0 0 0.342053 l
+30 40 40 40 0 0 0 0.342053 l
+30 30 40 30 0 0 0 0.342053 l
+30 20 40 20 0 0 0 0.342053 l
+30 10 40 10 0 0 0 0.342053 l
+30 0 40 0 0 0 0 0.342053 l
+20 90 30 90 0 0 0 0.342053 l
+20 80 30 80 0 0 0 0.342053 l
+20 70 30 70 0 0 0 0.342053 l
+20 60 30 60 0 0 0 0.342053 l
+20 50 30 50 0 0 0 0.342053 l
+20 40 30 40 0 0 0 0.342053 l
+20 30 30 30 0 0 0 0.342053 l
+20 20 30 20 0 0 0 0.342053 l
+20 10 30 10 0 0 0 0.342053 l
+20 0 30 0 0 0 0 0.342053 l
+10 90 20 90 0 0 0 0.342053 l
+10 80 20 80 0 0 0 0.342053 l
+10 70 20 70 0 0 0 0.342053 l
+10 60 20 60 0 0 0 0.342053 l
+10 50 20 50 0 0 0 0.342053 l
+10 40 20 40 0 0 0 0.342053 l
+10 30 20 30 0 0 0 0.342053 l
+10 20 20 20 0 0 0 0.342053 l
+10 10 20 10 0 0 0 0.342053 l
+10 0 20 0 0 0 0 0.342053 l
+0 90 10 90 0 0 0 0.342053 l
+0 80 10 80 0 0 0 0.342053 l
+0 70 10 70 0 0 0 0.342053 l
+0 60 10 60 0 0 0 0.342053 l
+0 50 10 50 0 0 0 0.342053 l
+0 40 10 40 0 0 0 0.342053 l
+0 30 10 30 0 0 0 0.342053 l
+0 20 10 20 0 0 0 0.342053 l
+0 10 10 10 0 0 0 0.342053 l
+0 0 10 0 0 0 0 0.342053 l
+grestore
+%Nodes:
+gsave
+70 90 1.14018 1 1 1 nc
+70 80 1.14018 1 1 1 nc
+70 70 1.14018 1 1 1 nc
+70 60 1.14018 1 1 1 nc
+70 50 1.14018 1 1 1 nc
+70 40 1.14018 1 1 1 nc
+70 30 1.14018 1 1 1 nc
+70 20 1.14018 1 1 1 nc
+70 10 1.14018 1 1 1 nc
+70 0 1.14018 1 1 1 nc
+60 90 1.14018 1 1 1 nc
+60 80 1.14018 1 1 1 nc
+60 70 1.14018 1 1 1 nc
+60 60 1.14018 1 1 1 nc
+60 50 1.14018 1 1 1 nc
+60 40 1.14018 1 1 1 nc
+60 30 1.14018 1 1 1 nc
+60 20 1.14018 1 1 1 nc
+60 10 1.14018 1 1 1 nc
+60 0 1.14018 1 1 1 nc
+50 90 1.14018 1 1 1 nc
+50 80 1.14018 1 1 1 nc
+50 70 1.14018 1 1 1 nc
+50 60 1.14018 1 1 1 nc
+50 50 1.14018 1 1 1 nc
+50 40 1.14018 1 1 1 nc
+50 30 1.14018 1 1 1 nc
+50 20 1.14018 1 1 1 nc
+50 10 1.14018 1 1 1 nc
+50 0 1.14018 1 1 1 nc
+40 90 1.14018 1 1 1 nc
+40 80 1.14018 1 1 1 nc
+40 70 1.14018 1 1 1 nc
+40 60 1.14018 1 1 1 nc
+40 50 1.14018 1 1 1 nc
+40 40 1.14018 1 1 1 nc
+40 30 1.14018 1 1 1 nc
+40 20 1.14018 1 1 1 nc
+40 10 1.14018 1 1 1 nc
+40 0 1.14018 1 1 1 nc
+30 90 1.14018 1 1 1 nc
+30 80 1.14018 1 1 1 nc
+30 70 1.14018 1 1 1 nc
+30 60 1.14018 1 1 1 nc
+30 50 1.14018 1 1 1 nc
+30 40 1.14018 1 1 1 nc
+30 30 1.14018 1 1 1 nc
+30 20 1.14018 1 1 1 nc
+30 10 1.14018 1 1 1 nc
+30 0 1.14018 1 1 1 nc
+20 90 1.14018 1 1 1 nc
+20 80 1.14018 1 1 1 nc
+20 70 1.14018 1 1 1 nc
+20 60 1.14018 1 1 1 nc
+20 50 1.14018 1 1 1 nc
+20 40 1.14018 1 1 1 nc
+20 30 1.14018 1 1 1 nc
+20 20 1.14018 1 1 1 nc
+20 10 1.14018 1 1 1 nc
+20 0 1.14018 1 1 1 nc
+10 90 1.14018 1 1 1 nc
+10 80 1.14018 1 1 1 nc
+10 70 1.14018 1 1 1 nc
+10 60 1.14018 1 1 1 nc
+10 50 1.14018 1 1 1 nc
+10 40 1.14018 1 1 1 nc
+10 30 1.14018 1 1 1 nc
+10 20 1.14018 1 1 1 nc
+10 10 1.14018 1 1 1 nc
+10 0 1.14018 1 1 1 nc
+0 90 1.14018 1 1 1 nc
+0 80 1.14018 1 1 1 nc
+0 70 1.14018 1 1 1 nc
+0 60 1.14018 1 1 1 nc
+0 50 1.14018 1 1 1 nc
+0 40 1.14018 1 1 1 nc
+0 30 1.14018 1 1 1 nc
+0 20 1.14018 1 1 1 nc
+0 10 1.14018 1 1 1 nc
+0 0 1.14018 1 1 1 nc
+grestore
+grestore
+showpage
Index: doc/images/grid_ugraph_demo.eps
===================================================================
--- doc/images/grid_ugraph_demo.eps	(revision 2011)
+++ doc/images/grid_ugraph_demo.eps	(revision 2011)
@@ -0,0 +1,476 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: Grid graph
+%%Copyright: (C) 2005 LEMON Project
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Wed Oct  5 09:42:13 2005
+%%BoundingBox: 0 0 596 842
+%%DocumentPaperSizes: a4
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+15 58.6908 translate
+7.96163 dup scale
+0.5 0.5 translate
+%Edges:
+gsave
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+0 0 moveto
+0.749815 4.32585 0.850912 4.90911 0.303291 8.22573 curveto stroke
+newpath 0.0853272 9.50734 moveto 0.746921 8.30118 lineto -0.140339 8.15028 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+0 10 moveto
+-0.749815 5.67415 -0.850912 5.09089 -0.303291 1.77427 curveto stroke
+newpath -0.0853272 0.492664 moveto -0.746921 1.69882 lineto 0.140339 1.84972 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+0 0 moveto
+4.32585 -0.749815 4.90911 -0.850912 8.22573 -0.303291 curveto stroke
+newpath 9.50734 -0.0853272 moveto 8.30118 -0.746921 lineto 8.15028 0.140339 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+10 0 moveto
+5.67415 0.749815 5.09089 0.850912 1.77427 0.303291 curveto stroke
+newpath 0.492664 0.0853272 moveto 1.69882 0.746921 lineto 1.84972 -0.140339 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+0 30 moveto
+0.749815 34.3259 0.850912 34.9091 0.303291 38.2257 curveto stroke
+newpath 0.0853272 39.5073 moveto 0.746921 38.3012 lineto -0.140339 38.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+0 40 moveto
+-0.749815 35.6741 -0.850912 35.0909 -0.303291 31.7743 curveto stroke
+newpath -0.0853272 30.4927 moveto -0.746921 31.6988 lineto 0.140339 31.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+0 30 moveto
+4.32585 29.2502 4.90911 29.1491 8.22573 29.6967 curveto stroke
+newpath 9.50734 29.9147 moveto 8.30118 29.2531 lineto 8.15028 30.1403 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+10 30 moveto
+5.67415 30.7498 5.09089 30.8509 1.77427 30.3033 curveto stroke
+newpath 0.492664 30.0853 moveto 1.69882 30.7469 lineto 1.84972 29.8597 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+0 40 moveto
+0.749815 44.3259 0.850912 44.9091 0.303291 48.2257 curveto stroke
+newpath 0.0853272 49.5073 moveto 0.746921 48.3012 lineto -0.140339 48.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+0 50 moveto
+-0.749815 45.6741 -0.850912 45.0909 -0.303291 41.7743 curveto stroke
+newpath -0.0853272 40.4927 moveto -0.746921 41.6988 lineto 0.140339 41.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+0 50 moveto
+0.749815 54.3259 0.850912 54.9091 0.303291 58.2257 curveto stroke
+newpath 0.0853272 59.5073 moveto 0.746921 58.3012 lineto -0.140339 58.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+0 60 moveto
+-0.749815 55.6741 -0.850912 55.0909 -0.303291 51.7743 curveto stroke
+newpath -0.0853272 50.4927 moveto -0.746921 51.6988 lineto 0.140339 51.8497 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+0 50 moveto
+4.32585 49.2502 4.90911 49.1491 8.22573 49.6967 curveto stroke
+newpath 9.50734 49.9147 moveto 8.30118 49.2531 lineto 8.15028 50.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+10 50 moveto
+5.67415 50.7498 5.09089 50.8509 1.77427 50.3033 curveto stroke
+newpath 0.492664 50.0853 moveto 1.69882 50.7469 lineto 1.84972 49.8597 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+0 80 moveto
+4.32585 79.2502 4.90911 79.1491 8.22573 79.6967 curveto stroke
+newpath 9.50734 79.9147 moveto 8.30118 79.2531 lineto 8.15028 80.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+10 80 moveto
+5.67415 80.7498 5.09089 80.8509 1.77427 80.3033 curveto stroke
+newpath 0.492664 80.0853 moveto 1.69882 80.7469 lineto 1.84972 79.8597 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+10 0 moveto
+14.3259 -0.749815 14.9091 -0.850912 18.2257 -0.303291 curveto stroke
+newpath 19.5073 -0.0853272 moveto 18.3012 -0.746921 lineto 18.1503 0.140339 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+20 0 moveto
+15.6741 0.749815 15.0909 0.850912 11.7743 0.303291 curveto stroke
+newpath 10.4927 0.0853272 moveto 11.6988 0.746921 lineto 11.8497 -0.140339 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+10 30 moveto
+14.3259 29.2502 14.9091 29.1491 18.2257 29.6967 curveto stroke
+newpath 19.5073 29.9147 moveto 18.3012 29.2531 lineto 18.1503 30.1403 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+20 30 moveto
+15.6741 30.7498 15.0909 30.8509 11.7743 30.3033 curveto stroke
+newpath 10.4927 30.0853 moveto 11.6988 30.7469 lineto 11.8497 29.8597 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+10 50 moveto
+14.3259 49.2502 14.9091 49.1491 18.2257 49.6967 curveto stroke
+newpath 19.5073 49.9147 moveto 18.3012 49.2531 lineto 18.1503 50.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+20 50 moveto
+15.6741 50.7498 15.0909 50.8509 11.7743 50.3033 curveto stroke
+newpath 10.4927 50.0853 moveto 11.6988 50.7469 lineto 11.8497 49.8597 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+10 80 moveto
+10.7498 84.3259 10.8509 84.9091 10.3033 88.2257 curveto stroke
+newpath 10.0853 89.5073 moveto 10.7469 88.3012 lineto 9.85966 88.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+10 90 moveto
+9.25019 85.6741 9.14909 85.0909 9.69671 81.7743 curveto stroke
+newpath 9.91467 80.4927 moveto 9.25308 81.6988 lineto 10.1403 81.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+10 90 moveto
+14.3259 89.2502 14.9091 89.1491 18.2257 89.6967 curveto stroke
+newpath 19.5073 89.9147 moveto 18.3012 89.2531 lineto 18.1503 90.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+20 90 moveto
+15.6741 90.7498 15.0909 90.8509 11.7743 90.3033 curveto stroke
+newpath 10.4927 90.0853 moveto 11.6988 90.7469 lineto 11.8497 89.8597 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+20 0 moveto
+20.7498 4.32585 20.8509 4.90911 20.3033 8.22573 curveto stroke
+newpath 20.0853 9.50734 moveto 20.7469 8.30118 lineto 19.8597 8.15028 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+20 10 moveto
+19.2502 5.67415 19.1491 5.09089 19.6967 1.77427 curveto stroke
+newpath 19.9147 0.492664 moveto 19.2531 1.69882 lineto 20.1403 1.84972 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+20 10 moveto
+20.7498 14.3259 20.8509 14.9091 20.3033 18.2257 curveto stroke
+newpath 20.0853 19.5073 moveto 20.7469 18.3012 lineto 19.8597 18.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+20 20 moveto
+19.2502 15.6741 19.1491 15.0909 19.6967 11.7743 curveto stroke
+newpath 19.9147 10.4927 moveto 19.2531 11.6988 lineto 20.1403 11.8497 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+20 20 moveto
+20.7498 24.3259 20.8509 24.9091 20.3033 28.2257 curveto stroke
+newpath 20.0853 29.5073 moveto 20.7469 28.3012 lineto 19.8597 28.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+20 30 moveto
+19.2502 25.6741 19.1491 25.0909 19.6967 21.7743 curveto stroke
+newpath 19.9147 20.4927 moveto 19.2531 21.6988 lineto 20.1403 21.8497 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+20 50 moveto
+20.7498 54.3259 20.8509 54.9091 20.3033 58.2257 curveto stroke
+newpath 20.0853 59.5073 moveto 20.7469 58.3012 lineto 19.8597 58.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+20 60 moveto
+19.2502 55.6741 19.1491 55.0909 19.6967 51.7743 curveto stroke
+newpath 19.9147 50.4927 moveto 19.2531 51.6988 lineto 20.1403 51.8497 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+20 60 moveto
+24.3259 59.2502 24.9091 59.1491 28.2257 59.6967 curveto stroke
+newpath 29.5073 59.9147 moveto 28.3012 59.2531 lineto 28.1503 60.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+30 60 moveto
+25.6741 60.7498 25.0909 60.8509 21.7743 60.3033 curveto stroke
+newpath 20.4927 60.0853 moveto 21.6988 60.7469 lineto 21.8497 59.8597 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+20 90 moveto
+24.3259 89.2502 24.9091 89.1491 28.2257 89.6967 curveto stroke
+newpath 29.5073 89.9147 moveto 28.3012 89.2531 lineto 28.1503 90.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+30 90 moveto
+25.6741 90.7498 25.0909 90.8509 21.7743 90.3033 curveto stroke
+newpath 20.4927 90.0853 moveto 21.6988 90.7469 lineto 21.8497 89.8597 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+30 60 moveto
+34.3259 59.2502 34.9091 59.1491 38.2257 59.6967 curveto stroke
+newpath 39.5073 59.9147 moveto 38.3012 59.2531 lineto 38.1503 60.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 60 moveto
+35.6741 60.7498 35.0909 60.8509 31.7743 60.3033 curveto stroke
+newpath 30.4927 60.0853 moveto 31.6988 60.7469 lineto 31.8497 59.8597 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+30 80 moveto
+30.7498 84.3259 30.8509 84.9091 30.3033 88.2257 curveto stroke
+newpath 30.0853 89.5073 moveto 30.7469 88.3012 lineto 29.8597 88.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+30 90 moveto
+29.2502 85.6741 29.1491 85.0909 29.6967 81.7743 curveto stroke
+newpath 29.9147 80.4927 moveto 29.2531 81.6988 lineto 30.1403 81.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+30 80 moveto
+34.3259 79.2502 34.9091 79.1491 38.2257 79.6967 curveto stroke
+newpath 39.5073 79.9147 moveto 38.3012 79.2531 lineto 38.1503 80.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 80 moveto
+35.6741 80.7498 35.0909 80.8509 31.7743 80.3033 curveto stroke
+newpath 30.4927 80.0853 moveto 31.6988 80.7469 lineto 31.8497 79.8597 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 0 moveto
+40.7498 4.32585 40.8509 4.90911 40.3033 8.22573 curveto stroke
+newpath 40.0853 9.50734 moveto 40.7469 8.30118 lineto 39.8597 8.15028 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 10 moveto
+39.2502 5.67415 39.1491 5.09089 39.6967 1.77427 curveto stroke
+newpath 39.9147 0.492664 moveto 39.2531 1.69882 lineto 40.1403 1.84972 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 0 moveto
+44.3259 -0.749815 44.9091 -0.850912 48.2257 -0.303291 curveto stroke
+newpath 49.5073 -0.0853272 moveto 48.3012 -0.746921 lineto 48.1503 0.140339 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+50 0 moveto
+45.6741 0.749815 45.0909 0.850912 41.7743 0.303291 curveto stroke
+newpath 40.4927 0.0853272 moveto 41.6988 0.746921 lineto 41.8497 -0.140339 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 10 moveto
+40.7498 14.3259 40.8509 14.9091 40.3033 18.2257 curveto stroke
+newpath 40.0853 19.5073 moveto 40.7469 18.3012 lineto 39.8597 18.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 20 moveto
+39.2502 15.6741 39.1491 15.0909 39.6967 11.7743 curveto stroke
+newpath 39.9147 10.4927 moveto 39.2531 11.6988 lineto 40.1403 11.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 20 moveto
+40.7498 24.3259 40.8509 24.9091 40.3033 28.2257 curveto stroke
+newpath 40.0853 29.5073 moveto 40.7469 28.3012 lineto 39.8597 28.1503 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+40 30 moveto
+39.2502 25.6741 39.1491 25.0909 39.6967 21.7743 curveto stroke
+newpath 39.9147 20.4927 moveto 39.2531 21.6988 lineto 40.1403 21.8497 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+40 20 moveto
+44.3259 19.2502 44.9091 19.1491 48.2257 19.6967 curveto stroke
+newpath 49.5073 19.9147 moveto 48.3012 19.2531 lineto 48.1503 20.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+50 20 moveto
+45.6741 20.7498 45.0909 20.8509 41.7743 20.3033 curveto stroke
+newpath 40.4927 20.0853 moveto 41.6988 20.7469 lineto 41.8497 19.8597 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 30 moveto
+40.7498 34.3259 40.8509 34.9091 40.3033 38.2257 curveto stroke
+newpath 40.0853 39.5073 moveto 40.7469 38.3012 lineto 39.8597 38.1503 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+40 40 moveto
+39.2502 35.6741 39.1491 35.0909 39.6967 31.7743 curveto stroke
+newpath 39.9147 30.4927 moveto 39.2531 31.6988 lineto 40.1403 31.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 40 moveto
+40.7498 44.3259 40.8509 44.9091 40.3033 48.2257 curveto stroke
+newpath 40.0853 49.5073 moveto 40.7469 48.3012 lineto 39.8597 48.1503 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+40 50 moveto
+39.2502 45.6741 39.1491 45.0909 39.6967 41.7743 curveto stroke
+newpath 39.9147 40.4927 moveto 39.2531 41.6988 lineto 40.1403 41.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 50 moveto
+40.7498 54.3259 40.8509 54.9091 40.3033 58.2257 curveto stroke
+newpath 40.0853 59.5073 moveto 40.7469 58.3012 lineto 39.8597 58.1503 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+40 60 moveto
+39.2502 55.6741 39.1491 55.0909 39.6967 51.7743 curveto stroke
+newpath 39.9147 50.4927 moveto 39.2531 51.6988 lineto 40.1403 51.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 60 moveto
+40.7498 64.3259 40.8509 64.9091 40.3033 68.2257 curveto stroke
+newpath 40.0853 69.5073 moveto 40.7469 68.3012 lineto 39.8597 68.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 70 moveto
+39.2502 65.6741 39.1491 65.0909 39.6967 61.7743 curveto stroke
+newpath 39.9147 60.4927 moveto 39.2531 61.6988 lineto 40.1403 61.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 70 moveto
+40.7498 74.3259 40.8509 74.9091 40.3033 78.2257 curveto stroke
+newpath 40.0853 79.5073 moveto 40.7469 78.3012 lineto 39.8597 78.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+40 80 moveto
+39.2502 75.6741 39.1491 75.0909 39.6967 71.7743 curveto stroke
+newpath 39.9147 70.4927 moveto 39.2531 71.6988 lineto 40.1403 71.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+50 0 moveto
+54.3259 -0.749815 54.9091 -0.850912 58.2257 -0.303291 curveto stroke
+newpath 59.5073 -0.0853272 moveto 58.3012 -0.746921 lineto 58.1503 0.140339 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+60 0 moveto
+55.6741 0.749815 55.0909 0.850912 51.7743 0.303291 curveto stroke
+newpath 50.4927 0.0853272 moveto 51.6988 0.746921 lineto 51.8497 -0.140339 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+50 20 moveto
+54.3259 19.2502 54.9091 19.1491 58.2257 19.6967 curveto stroke
+newpath 59.5073 19.9147 moveto 58.3012 19.2531 lineto 58.1503 20.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+60 20 moveto
+55.6741 20.7498 55.0909 20.8509 51.7743 20.3033 curveto stroke
+newpath 50.4927 20.0853 moveto 51.6988 20.7469 lineto 51.8497 19.8597 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+60 0 moveto
+64.3259 -0.749815 64.9091 -0.850912 68.2257 -0.303291 curveto stroke
+newpath 69.5073 -0.0853272 moveto 68.3012 -0.746921 lineto 68.1503 0.140339 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+70 0 moveto
+65.6741 0.749815 65.0909 0.850912 61.7743 0.303291 curveto stroke
+newpath 60.4927 0.0853272 moveto 61.6988 0.746921 lineto 61.8497 -0.140339 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+60 20 moveto
+60.7498 24.3259 60.8509 24.9091 60.3033 28.2257 curveto stroke
+newpath 60.0853 29.5073 moveto 60.7469 28.3012 lineto 59.8597 28.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+60 30 moveto
+59.2502 25.6741 59.1491 25.0909 59.6967 21.7743 curveto stroke
+newpath 59.9147 20.4927 moveto 59.2531 21.6988 lineto 60.1403 21.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+60 20 moveto
+64.3259 19.2502 64.9091 19.1491 68.2257 19.6967 curveto stroke
+newpath 69.5073 19.9147 moveto 68.3012 19.2531 lineto 68.1503 20.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+70 20 moveto
+65.6741 20.7498 65.0909 20.8509 61.7743 20.3033 curveto stroke
+newpath 60.4927 20.0853 moveto 61.6988 20.7469 lineto 61.8497 19.8597 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+60 30 moveto
+60.7498 34.3259 60.8509 34.9091 60.3033 38.2257 curveto stroke
+newpath 60.0853 39.5073 moveto 60.7469 38.3012 lineto 59.8597 38.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+60 40 moveto
+59.2502 35.6741 59.1491 35.0909 59.6967 31.7743 curveto stroke
+newpath 59.9147 30.4927 moveto 59.2531 31.6988 lineto 60.1403 31.8497 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+60 40 moveto
+64.3259 39.2502 64.9091 39.1491 68.2257 39.6967 curveto stroke
+newpath 69.5073 39.9147 moveto 68.3012 39.2531 lineto 68.1503 40.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+70 40 moveto
+65.6741 40.7498 65.0909 40.8509 61.7743 40.3033 curveto stroke
+newpath 60.4927 40.0853 moveto 61.6988 40.7469 lineto 61.8497 39.8597 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+60 70 moveto
+60.7498 74.3259 60.8509 74.9091 60.3033 78.2257 curveto stroke
+newpath 60.0853 79.5073 moveto 60.7469 78.3012 lineto 59.8597 78.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+60 80 moveto
+59.2502 75.6741 59.1491 75.0909 59.6967 71.7743 curveto stroke
+newpath 59.9147 70.4927 moveto 59.2531 71.6988 lineto 60.1403 71.8497 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+60 70 moveto
+64.3259 69.2502 64.9091 69.1491 68.2257 69.6967 curveto stroke
+newpath 69.5073 69.9147 moveto 68.3012 69.2531 lineto 68.1503 70.1403 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+70 70 moveto
+65.6741 70.7498 65.0909 70.8509 61.7743 70.3033 curveto stroke
+newpath 60.4927 70.0853 moveto 61.6988 70.7469 lineto 61.8497 69.8597 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+60 80 moveto
+60.7498 84.3259 60.8509 84.9091 60.3033 88.2257 curveto stroke
+newpath 60.0853 89.5073 moveto 60.7469 88.3012 lineto 59.8597 88.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+60 90 moveto
+59.2502 85.6741 59.1491 85.0909 59.6967 81.7743 curveto stroke
+newpath 59.9147 80.4927 moveto 59.2531 81.6988 lineto 60.1403 81.8497 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+60 90 moveto
+64.3259 89.2502 64.9091 89.1491 68.2257 89.6967 curveto stroke
+newpath 69.5073 89.9147 moveto 68.3012 89.2531 lineto 68.1503 90.1403 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+70 90 moveto
+65.6741 90.7498 65.0909 90.8509 61.7743 90.3033 curveto stroke
+newpath 60.4927 90.0853 moveto 61.6988 90.7469 lineto 61.8497 89.8597 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+70 40 moveto
+70.7498 44.3259 70.8509 44.9091 70.3033 48.2257 curveto stroke
+newpath 70.0853 49.5073 moveto 70.7469 48.3012 lineto 69.8597 48.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+70 50 moveto
+69.2502 45.6741 69.1491 45.0909 69.6967 41.7743 curveto stroke
+newpath 69.9147 40.4927 moveto 69.2531 41.6988 lineto 70.1403 41.8497 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+70 50 moveto
+70.7498 54.3259 70.8509 54.9091 70.3033 58.2257 curveto stroke
+newpath 70.0853 59.5073 moveto 70.7469 58.3012 lineto 69.8597 58.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+70 60 moveto
+69.2502 55.6741 69.1491 55.0909 69.6967 51.7743 curveto stroke
+newpath 69.9147 50.4927 moveto 69.2531 51.6988 lineto 70.1403 51.8497 lineto closepath fill
+0.3 setlinewidth 1 0 0 setrgbcolor newpath
+70 60 moveto
+70.7498 64.3259 70.8509 64.9091 70.3033 68.2257 curveto stroke
+newpath 70.0853 69.5073 moveto 70.7469 68.3012 lineto 69.8597 68.1503 lineto closepath fill
+0.3 setlinewidth 0 0 0 setrgbcolor newpath
+70 70 moveto
+69.2502 65.6741 69.1491 65.0909 69.6967 61.7743 curveto stroke
+newpath 69.9147 60.4927 moveto 69.2531 61.6988 lineto 70.1403 61.8497 lineto closepath fill
+grestore
+%Nodes:
+gsave
+70 90 0.5 1 1 1 nc
+70 70 0.5 1 1 1 nc
+70 60 0.5 1 1 1 nc
+70 50 0.5 1 1 1 nc
+70 40 0.5 1 1 1 nc
+70 20 0.5 1 1 1 nc
+70 0 0.5 1 1 1 nc
+60 90 0.5 1 1 1 nc
+60 80 0.5 1 1 1 nc
+60 70 0.5 1 1 1 nc
+60 40 0.5 1 1 1 nc
+60 30 0.5 1 1 1 nc
+60 20 0.5 1 1 1 nc
+60 0 0.5 1 1 1 nc
+50 20 0.5 1 1 1 nc
+50 0 0.5 1 1 1 nc
+40 80 0.5 1 1 1 nc
+40 70 0.5 1 1 1 nc
+40 60 0.5 1 1 1 nc
+40 50 0.5 1 1 1 nc
+40 40 0.5 1 1 1 nc
+40 30 0.5 1 1 1 nc
+40 20 0.5 1 1 1 nc
+40 10 0.5 1 1 1 nc
+40 0 0.5 1 1 1 nc
+30 90 0.5 1 1 1 nc
+30 80 0.5 1 1 1 nc
+30 60 0.5 1 1 1 nc
+20 90 0.5 1 1 1 nc
+20 60 0.5 1 1 1 nc
+20 50 0.5 1 1 1 nc
+20 30 0.5 1 1 1 nc
+20 20 0.5 1 1 1 nc
+20 10 0.5 1 1 1 nc
+20 0 0.5 1 1 1 nc
+10 90 0.5 1 1 1 nc
+10 80 0.5 1 1 1 nc
+10 50 0.5 1 1 1 nc
+10 30 0.5 1 1 1 nc
+10 0 0.5 1 1 1 nc
+0 80 0.5 1 1 1 nc
+0 60 0.5 1 1 1 nc
+0 50 0.5 1 1 1 nc
+0 40 0.5 1 1 1 nc
+0 30 0.5 1 1 1 nc
+0 10 0.5 1 1 1 nc
+0 0 0.5 1 1 1 nc
+grestore
+grestore
+showpage
Index: doc/images/node_biconnected_components.eps
===================================================================
--- doc/images/node_biconnected_components.eps	(revision 1789)
+++ doc/images/node_biconnected_components.eps	(revision 1789)
@@ -0,0 +1,158 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Fri Nov  4 13:47:12 2005
+%%BoundingBox: 0 0 596 842
+%%DocumentPaperSizes: a4
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+71.0944 15 translate
+0.434694 dup scale
+90 rotate
+860.856 -588.349 translate
+%Edges:
+gsave
+574.035 177.301 622.149 225.748 670.264 274.195 0 1 0 5 lb
+694.579 115.483 682.421 194.839 670.264 274.195 1 0 0 5 lb
+280.402 10.3938 246.402 -6.60595 212.403 -23.6057 1 1 0.5 5 lb
+280.402 10.3938 283.493 -18.9695 286.584 -48.3327 1 1 0.5 5 lb
+212.403 -23.6057 249.493 -35.9692 286.584 -48.3327 1 1 0.5 5 lb
+286.584 -48.3327 326.765 -79.2414 366.947 -110.15 1 0.5 1 5 lb
+286.584 -48.3327 278.857 -111.695 271.13 -175.058 1 0.5 1 5 lb
+438.037 -88.514 417.946 -142.604 397.855 -196.694 0.5 0.5 1 5 lb
+438.037 -88.514 402.492 -99.332 366.947 -110.15 0.5 0.5 1 5 lb
+397.855 -196.694 382.401 -153.422 366.947 -110.15 0.5 0.5 1 5 lb
+366.947 -110.15 319.038 -142.604 271.13 -175.058 1 0.5 1 5 lb
+271.13 -175.058 274.221 -213.694 277.311 -252.33 0.5 1 1 5 lb
+271.13 -175.058 238.675 -190.512 206.221 -205.967 0.5 1 1 5 lb
+277.311 -252.33 241.766 -229.149 206.221 -205.967 0.5 1 1 5 lb
+-840.856 -246.718 -804.351 -66.7145 -767.847 113.289 0 0.5 0 5 lb
+-579.033 445.603 -673.44 279.446 -767.847 113.289 0 0 0.5 5 lb
+-579.033 445.603 -524.906 302.104 -470.779 158.605 0 0 0.5 5 lb
+-767.847 113.289 -619.313 135.947 -470.779 158.605 0 0 0.5 5 lb
+906.312 201.403 946.592 42.798 986.873 -115.807 0 0.5 0.5 5 lb
+906.312 201.403 834.562 91.8901 762.812 -17.6227 0 0.5 0.5 5 lb
+986.873 -115.807 874.842 -66.7148 762.812 -17.6227 0 0.5 0.5 5 lb
+-470.779 158.605 -390.218 50.3508 -309.657 -57.9033 0.5 0.5 0 5 lb
+422.945 521.129 208.955 541.269 -5.03507 561.41 0.5 0 0.5 5 lb
+422.945 521.129 376.371 417.911 329.797 314.692 0.5 0 0.5 5 lb
+422.945 521.129 474.554 276.928 526.164 32.7279 0.5 0 0.5 5 lb
+-5.03507 561.41 -36.5042 440.568 -67.9734 319.727 0.5 0 0.5 5 lb
+329.797 314.692 130.912 317.209 -67.9734 319.727 0.5 0 0.5 5 lb
+-67.9734 319.727 229.095 176.227 526.164 32.7279 0.5 0 0.5 5 lb
+762.812 -17.6227 644.488 7.5526 526.164 32.7279 0.5 0.5 0.5 5 lb
+762.812 -17.6227 746.448 -162.381 730.084 -307.139 0.5 0.5 0.5 5 lb
+526.164 32.7279 470.779 -128.394 415.393 -289.516 0.5 0.5 0.5 5 lb
+730.084 -307.139 572.738 -298.327 415.393 -289.516 0.5 0.5 0.5 5 lb
+415.393 -289.516 173.71 -318.468 -67.9734 -347.42 1 0.5 0.5 5 lb
+-67.9734 -347.42 -188.815 -202.662 -309.657 -57.9033 0.5 1 0.5 5 lb
+-67.9734 -347.42 -195.758 -390.692 -323.543 -433.964 0.5 1 0.5 5 lb
+-309.657 -57.9033 -424.775 -160.272 -539.894 -262.64 0.5 1 0.5 5 lb
+-323.543 -433.964 -431.719 -348.302 -539.894 -262.64 0.5 1 0.5 5 lb
+-26.6953 -19.9585 44.8558 -96.8093 116.407 -173.66 1 1 0 5 lb
+-26.6953 -19.9585 87.2563 9.19185 201.208 38.3422 1 1 0 5 lb
+-26.6953 -19.9585 -144.622 43.6422 -262.548 107.243 1 0 1 5 lb
+-26.6953 -19.9585 -20.0703 56.8923 -13.4452 133.743 1 0 1 5 lb
+116.407 -173.66 158.808 -67.6589 201.208 38.3422 1 1 0 5 lb
+-262.548 107.243 -137.997 120.493 -13.4452 133.743 1 0 1 5 lb
+-262.548 107.243 -221.472 176.144 -180.397 245.045 1 0 1 5 lb
+-13.4452 133.743 -96.9211 189.394 -180.397 245.045 1 0 1 5 lb
+-180.397 245.045 -140.307 344.649 -132.697 451.748 0 1 1 5 lb
+-180.397 245.045 -172.787 352.144 -132.697 451.748 0 1 1 5 lb
+-416.25 345.746 -274.474 398.747 -132.697 451.748 0.5 0 0 5 lb
+-416.25 345.746 -393.725 457.048 -371.2 568.349 0.5 0 0 5 lb
+-132.697 451.748 -251.948 510.048 -371.2 568.349 0.5 0 0 5 lb
+670.264 274.195 629.188 409.347 588.113 544.499 0 0 1 5 lb
+670.264 274.195 797.466 341.771 924.667 409.347 0 0 1 5 lb
+588.113 544.499 756.39 476.923 924.667 409.347 0 0 1 5 lb
+-689.204 -237.261 -612.964 -103.444 -567.302 43.6423 0 0 0 5 lb
+-689.204 -237.261 -643.542 -90.1744 -567.302 43.6423 0 0 0 5 lb
+grestore
+%Nodes:
+gsave
+-567.302 43.6423 20 0 0 1 nc
+-689.204 -237.261 20 0 0 1 nc
+924.667 409.347 20 0 0 1 nc
+588.113 544.499 20 0 0 1 nc
+670.264 274.195 20 1 0 0 nc
+-371.2 568.349 20 0 0 1 nc
+-132.697 451.748 20 1 0 0 nc
+-416.25 345.746 20 0 0 1 nc
+-180.397 245.045 20 1 0 0 nc
+-13.4452 133.743 20 0 0 1 nc
+-262.548 107.243 20 0 0 1 nc
+201.208 38.3422 20 0 0 1 nc
+116.407 -173.66 20 0 0 1 nc
+-26.6953 -19.9585 20 1 0 0 nc
+-539.894 -262.64 20 0 0 1 nc
+-323.543 -433.964 20 0 0 1 nc
+-309.657 -57.9033 20 1 0 0 nc
+-67.9734 -347.42 20 1 0 0 nc
+415.393 -289.516 20 1 0 0 nc
+730.084 -307.139 20 0 0 1 nc
+526.164 32.7279 20 1 0 0 nc
+762.812 -17.6227 20 1 0 0 nc
+-67.9734 319.727 20 0 0 1 nc
+329.797 314.692 20 0 0 1 nc
+-5.03507 561.41 20 0 0 1 nc
+422.945 521.129 20 0 0 1 nc
+-470.779 158.605 20 1 0 0 nc
+986.873 -115.807 20 0 0 1 nc
+906.312 201.403 20 0 0 1 nc
+-767.847 113.289 20 1 0 0 nc
+-579.033 445.603 20 0 0 1 nc
+-840.856 -246.718 20 0 0 1 nc
+206.221 -205.967 20 0 0 1 nc
+277.311 -252.33 20 0 0 1 nc
+271.13 -175.058 20 1 0 0 nc
+366.947 -110.15 20 1 0 0 nc
+397.855 -196.694 20 0 0 1 nc
+438.037 -88.514 20 0 0 1 nc
+286.584 -48.3327 20 1 0 0 nc
+212.403 -23.6057 20 0 0 1 nc
+280.402 10.3938 20 0 0 1 nc
+694.579 115.483 20 0 0 1 nc
+574.035 177.301 20 0 0 1 nc
+grestore
+grestore
+showpage
Index: doc/images/node_disjoint.eps
===================================================================
--- doc/images/node_disjoint.eps	(revision 2079)
+++ doc/images/node_disjoint.eps	(revision 2079)
@@ -0,0 +1,146 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: node disjoint path
+%%Copyright: (C) 2006 LEMON Project
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Fri May 12 01:53:21 2006
+%%BoundingBox: -290 -170 520 230
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/nfemale { 0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto 5 index 5 index 5 index 3.01 mul sub
+  lineto 5 index 4 index .7 mul sub 5 index 5 index 2.2 mul sub moveto
+  5 index 4 index .7 mul add 5 index 5 index 2.2 mul sub lineto stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/nmale {
+  0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto
+  5 index 4 index 1 mul 1.5 mul add
+  5 index 5 index 3 sqrt 1.5 mul mul add
+  1 index 1 index lineto
+  1 index 1 index 7 index sub moveto
+  1 index 1 index lineto
+  exch 5 index 3 sqrt .5 mul mul sub exch 5 index .5 mul sub lineto
+  stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+10 dup scale
+%Edges:
+gsave
+4 0.3 1 0 -27 5 0 0 0 arr
+4 0.3 1 0 -13 -4 1 0 0 arr
+4 0.3 1 0 -9 15 1 0 0 arr
+4 0.3 1 0 3 -9 1 0 0 arr
+4 0.3 1 0 3 3 1 0 0 arr
+4 0.3 1 0 1 21 1 0 0 arr
+4 0.3 1 0 25 -5 1 0 0 arr
+4 0.3 1 0 28 13 1 0 0 arr
+4 0.3 1 0 45 3 0 0 0 arr
+4 0.3 1 0 -18 -14 1 0 0 arr
+4 0.3 1 0 25 -15 1 0 0 arr
+4 0.3 1 0 -12 7 0 0 0 arr
+4 0.3 1 0 39 -11 0 0 0 arr
+4 0.3 1 0 39 13 0 0 0 arr
+4 0.3 1 0 -20 17 1 0 0 arr
+11.7279 0.3 0.707107 -0.707107 -22 5 1 0 0 arr
+15.4012 0.3 0.792624 0.609711 -22 5 0 0 0 arr
+5.32455 0.3 0.948683 -0.316228 -15 17 1 0 0 arr
+15.7631 0.3 0.95448 0.298275 -13 -14 1 0 0 arr
+11.083 0.3 0.910366 -0.413803 -8 -4 0 0 0 arr
+12.8924 0.3 0.503871 -0.863779 -4 15 0 0 0 arr
+12.0384 0.3 0.843661 0.536875 -8 -4 1 0 0 arr
+9.77033 0.3 0.928477 -0.371391 -7 7 0 0 0 arr
+6.81025 0.3 0.640184 0.768221 -4 15 1 0 0 arr
+17.7883 0.3 0.904819 -0.425797 8 3 1 0 0 arr
+22.4094 0.3 0.939793 -0.341743 6 21 1 0 0 arr
+21.3607 0.3 0.894427 0.447214 8 3 0 0 0 arr
+22.4307 0.3 0.640184 0.768221 30 -15 1 0 0 arr
+16 0.3 0.882353 0.470588 30 -5 1 0 0 arr
+14.6205 0.3 0.768221 -0.640184 33 13 1 0 0 arr
+13.0357 0.3 0.071247 0.997459 44 -11 0 0 0 arr
+9.04987 0.3 0.0995037 -0.995037 44 13 0 0 0 arr
+18.4165 0.3 0.20601 -0.97855 -22 5 1 0 0 arr
+17.0278 0.3 0.94299 -0.33282 8 -9 1 0 0 arr
+9.19804 0.3 0.980581 0.196116 -22 5 0 0 0 arr
+8.84886 0.3 0.913812 0.406138 30 -15 0 0 0 arr
+5 0.3 1 0 33 13 0 0 0 arr
+11.1655 0.3 0.164399 0.986394 -22 5 1 0 0 arr
+grestore
+%Nodes:
+gsave
+-27 5 1 1 1 1 nc
+-22 5 1 1 1 1 nc
+-13 -4 1 1 1 1 nc
+-8 -4 1 1 1 1 nc
+-9 15 1 1 1 1 nc
+-4 15 1 1 1 1 nc
+3 -9 1 1 1 1 nc
+8 -9 1 1 1 1 nc
+3 3 1 1 1 1 nc
+8 3 1 1 1 1 nc
+1 21 1 1 1 1 nc
+6 21 1 1 1 1 nc
+25 -5 1 1 1 1 nc
+30 -5 1 1 1 1 nc
+28 13 1 1 1 1 nc
+33 13 1 1 1 1 nc
+45 3 1 1 1 1 nc
+50 3 1 1 1 1 nc
+-18 -14 1 1 1 1 nc
+-13 -14 1 1 1 1 nc
+25 -15 1 1 1 1 nc
+30 -15 1 1 1 1 nc
+-12 7 1 1 1 1 nc
+-7 7 1 1 1 1 nc
+39 -11 1 1 1 1 nc
+44 -11 1 1 1 1 nc
+39 13 1 1 1 1 nc
+44 13 1 1 1 1 nc
+-20 17 1 1 1 1 nc
+-15 17 1 1 1 1 nc
+grestore
+grestore
+showpage
Index: doc/images/nodeshape_0.eps
===================================================================
--- doc/images/nodeshape_0.eps	(revision 1107)
+++ doc/images/nodeshape_0.eps	(revision 1107)
@@ -0,0 +1,57 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: LEMON GraphToEps figure
+%%Creator: LEMON GraphToEps function
+%%BoundingBox: 0 0 200 200
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+100 dup scale
+%Edges:
+gsave
+grestore
+%Nodes:
+gsave
+1 1 1 0.2 1 0.2 nc
+grestore
+grestore
+showpage
Index: doc/images/nodeshape_1.eps
===================================================================
--- doc/images/nodeshape_1.eps	(revision 1107)
+++ doc/images/nodeshape_1.eps	(revision 1107)
@@ -0,0 +1,57 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: LEMON GraphToEps figure
+%%Creator: LEMON GraphToEps function
+%%BoundingBox: 0 0 200 200
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+100 dup scale
+%Edges:
+gsave
+grestore
+%Nodes:
+gsave
+1 1 1 0.2 1 0.2 nsq
+grestore
+grestore
+showpage
Index: doc/images/nodeshape_2.eps
===================================================================
--- doc/images/nodeshape_2.eps	(revision 1107)
+++ doc/images/nodeshape_2.eps	(revision 1107)
@@ -0,0 +1,57 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: LEMON GraphToEps figure
+%%Creator: LEMON GraphToEps function
+%%BoundingBox: 0 0 200 200
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+100 dup scale
+%Edges:
+gsave
+grestore
+%Nodes:
+gsave
+1 1 1 0.2 1 0.2 ndi
+grestore
+grestore
+showpage
Index: doc/images/nodeshape_3.eps
===================================================================
--- doc/images/nodeshape_3.eps	(revision 1907)
+++ doc/images/nodeshape_3.eps	(revision 1907)
@@ -0,0 +1,77 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: LEMON GraphToEps figure
+%%Creator: LEMON GraphToEps function
+%%BoundingBox: 0 0 256 372
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/nfemale { 0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto 5 index 5 index 5 index 3.01 mul sub
+  lineto 5 index 4 index .7 mul sub 5 index 5 index 2.2 mul sub moveto
+  5 index 4 index .7 mul add 5 index 5 index 2.2 mul sub lineto stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/nmale {
+  0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto
+  5 index 4 index 1 mul 1.5 mul add
+  5 index 5 index 3 sqrt 1.5 mul mul add
+  1 index 1 index lineto
+  1 index 1 index 7 index sub moveto
+  1 index 1 index lineto
+  exch 5 index 3 sqrt .5 mul mul sub exch 5 index .5 mul sub lineto
+  stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+100 dup scale
+%Edges:
+gsave
+grestore
+%Nodes:
+gsave
+1 1 1 0.2 1 0.2 nmale
+grestore
+grestore
+showpage
Index: doc/images/nodeshape_4.eps
===================================================================
--- doc/images/nodeshape_4.eps	(revision 1907)
+++ doc/images/nodeshape_4.eps	(revision 1907)
@@ -0,0 +1,77 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: LEMON GraphToEps figure
+%%Creator: LEMON GraphToEps function
+%%BoundingBox: 0 -199 200 200
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/nfemale { 0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto 5 index 5 index 5 index 3.01 mul sub
+  lineto 5 index 4 index .7 mul sub 5 index 5 index 2.2 mul sub moveto
+  5 index 4 index .7 mul add 5 index 5 index 2.2 mul sub lineto stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/nmale {
+  0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto
+  5 index 4 index 1 mul 1.5 mul add
+  5 index 5 index 3 sqrt 1.5 mul mul add
+  1 index 1 index lineto
+  1 index 1 index 7 index sub moveto
+  1 index 1 index lineto
+  exch 5 index 3 sqrt .5 mul mul sub exch 5 index .5 mul sub lineto
+  stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+100 dup scale
+%Edges:
+gsave
+grestore
+%Nodes:
+gsave
+1 1 1 0.2 1 0.2 nfemale
+grestore
+grestore
+showpage
Index: doc/images/planar.eps
===================================================================
--- doc/images/planar.eps	(revision 2501)
+++ doc/images/planar.eps	(revision 2501)
@@ -0,0 +1,181 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Fri Oct 19 18:32:32 2007
+%%BoundingBox: 0 0 596 842
+%%DocumentPaperSizes: a4
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/nfemale { 0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto 5 index 5 index 5 index 3.01 mul sub
+  lineto 5 index 4 index .7 mul sub 5 index 5 index 2.2 mul sub moveto
+  5 index 4 index .7 mul add 5 index 5 index 2.2 mul sub lineto stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/nmale {
+  0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto
+  5 index 4 index 1 mul 1.5 mul add
+  5 index 5 index 3 sqrt 1.5 mul mul add
+  1 index 1 index lineto
+  1 index 1 index 7 index sub moveto
+  1 index 1 index lineto
+  exch 5 index 3 sqrt .5 mul mul sub exch 5 index .5 mul sub lineto
+  stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+15 138.307 translate
+12.7843 dup scale
+90 rotate
+0.608112 -43.6081 translate
+%Edges:
+gsave
+9 31 9.5 30.5 10 30 0 0 0 0.091217 lb
+9 31 5.5 34.5 2 38 0 0 0 0.091217 lb
+9 31 25.5 16 42 1 0 0 0 0.091217 lb
+3 40 23 20.5 43 1 0 0 0 0.091217 lb
+3 40 22.5 20.5 42 1 0 0 0 0.091217 lb
+3 40 2.5 40.5 2 41 0 0 0 0.091217 lb
+13 25 10.5 24.5 8 24 0 0 0 0.091217 lb
+13 25 12 27 11 29 0 0 0 0.091217 lb
+3 4 2.5 3 2 2 0 0 0 0.091217 lb
+3 4 4.5 3 6 2 0 0 0 0.091217 lb
+6 25 7 24.5 8 24 0 0 0 0.091217 lb
+6 25 6 24.5 6 24 0 0 0 0.091217 lb
+34 2 33.5 2 33 2 0 0 0 0.091217 lb
+34 2 35 2 36 2 0 0 0 0.091217 lb
+6 8 16 9 26 10 0 0 0 0.091217 lb
+6 8 6 10.5 6 13 0 0 0 0.091217 lb
+6 8 6 7.5 6 7 0 0 0 0.091217 lb
+26 10 27.5 8.5 29 7 0 0 0 0.091217 lb
+26 10 27.5 9 29 8 0 0 0 0.091217 lb
+10 30 10.5 29.5 11 29 0 0 0 0.091217 lb
+8 24 7 23.5 6 23 0 0 0 0.091217 lb
+8 24 8 24.5 8 25 0 0 0 0.091217 lb
+33 2 32.5 2 32 2 0 0 0 0.091217 lb
+29 7 17.5 7 6 7 0 0 0 0.091217 lb
+2 2 1.5 22 1 42 0 0 0 0.091217 lb
+2 2 3.5 2 5 2 0 0 0 0.091217 lb
+21 15 13.5 14.5 6 14 0 0 0 0.091217 lb
+21 15 21 15.5 21 16 0 0 0 0.091217 lb
+1 42 0.5 42.5 0 43 0 0 0 0.091217 lb
+1 42 1.5 41.5 2 41 0 0 0 0.091217 lb
+6 15 6 15.5 6 16 0 0 0 0.091217 lb
+6 15 6 14.5 6 14 0 0 0 0.091217 lb
+43 1 22 0.5 1 0 0 0 0 0.091217 lb
+31 2 18.5 2 6 2 0 0 0 0.091217 lb
+31 2 31.5 2 32 2 0 0 0 0.091217 lb
+6 24 6 23.5 6 23 0 0 0 0.091217 lb
+6 16 6 16.5 6 17 0 0 0 0.091217 lb
+6 23 6 20 6 17 0 0 0 0.091217 lb
+6 2 5.5 2 5 2 0 0 0 0.091217 lb
+6 2 6 4.5 6 7 0 0 0 0.091217 lb
+0 43 0.5 21.5 1 0 0 0 0 0.091217 lb
+1 1 19.5 1.5 38 2 0 0 0 0.091217 lb
+1 1 1 0.5 1 0 0 0 0 0.091217 lb
+2 38 5.5 31.5 9 25 0 0 0 0.091217 lb
+25 13 15.5 13 6 13 0 0 0 0.091217 lb
+25 13 15.5 13.5 6 14 0 0 0 0.091217 lb
+8 25 8.5 25 9 25 0 0 0 0.091217 lb
+11 29 24.5 15.5 38 2 0 0 0 0.091217 lb
+6 17 11.5 18 17 19 0 0 0 0.091217 lb
+16 23 26.5 12.5 37 2 0 0 0 0.091217 lb
+16 23 18.5 19.5 21 16 0 0 0 0.091217 lb
+36 2 36.5 2 37 2 0 0 0 0.091217 lb
+36 2 32.5 5 29 8 0 0 0 0.091217 lb
+6 13 6 13.5 6 14 0 0 0 0.091217 lb
+37 2 37.5 2 38 2 0 0 0 0.091217 lb
+21 16 19 17.5 17 19 0 0 0 0.091217 lb
+grestore
+%Nodes:
+gsave
+29 8 0.304556 1 1 1 nc
+2 41 0.304556 1 1 1 nc
+6 7 0.304556 1 1 1 nc
+5 2 0.304556 1 1 1 nc
+17 19 0.304556 1 1 1 nc
+21 16 0.304556 1 1 1 nc
+1 0 0.304556 1 1 1 nc
+9 25 0.304556 1 1 1 nc
+6 14 0.304556 1 1 1 nc
+42 1 0.304556 1 1 1 nc
+38 2 0.304556 1 1 1 nc
+37 2 0.304556 1 1 1 nc
+6 13 0.304556 1 1 1 nc
+36 2 0.304556 1 1 1 nc
+16 23 0.304556 1 1 1 nc
+6 17 0.304556 1 1 1 nc
+11 29 0.304556 1 1 1 nc
+8 25 0.304556 1 1 1 nc
+32 2 0.304556 1 1 1 nc
+25 13 0.304556 1 1 1 nc
+2 38 0.304556 1 1 1 nc
+1 1 0.304556 1 1 1 nc
+0 43 0.304556 1 1 1 nc
+6 2 0.304556 1 1 1 nc
+6 23 0.304556 1 1 1 nc
+6 16 0.304556 1 1 1 nc
+6 24 0.304556 1 1 1 nc
+31 2 0.304556 1 1 1 nc
+43 1 0.304556 1 1 1 nc
+6 15 0.304556 1 1 1 nc
+1 42 0.304556 1 1 1 nc
+21 15 0.304556 1 1 1 nc
+2 2 0.304556 1 1 1 nc
+29 7 0.304556 1 1 1 nc
+33 2 0.304556 1 1 1 nc
+8 24 0.304556 1 1 1 nc
+10 30 0.304556 1 1 1 nc
+26 10 0.304556 1 1 1 nc
+6 8 0.304556 1 1 1 nc
+34 2 0.304556 1 1 1 nc
+6 25 0.304556 1 1 1 nc
+3 4 0.304556 1 1 1 nc
+13 25 0.304556 1 1 1 nc
+3 40 0.304556 1 1 1 nc
+9 31 0.304556 1 1 1 nc
+grestore
+grestore
+showpage
Index: doc/images/plane_tree.eps
===================================================================
--- doc/images/plane_tree.eps	(revision 2491)
+++ doc/images/plane_tree.eps	(revision 2491)
@@ -0,0 +1,20074 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Tue Oct  9 18:30:00 2007
+%%BoundingBox: 0 0 596 842
+%%DocumentPaperSizes: a4
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/nfemale { 0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto 5 index 5 index 5 index 3.01 mul sub
+  lineto 5 index 4 index .7 mul sub 5 index 5 index 2.2 mul sub moveto
+  5 index 4 index .7 mul add 5 index 5 index 2.2 mul sub lineto stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/nmale {
+  0 0 0 setrgbcolor 3 index 0.0909091 1.5 mul mul setlinewidth
+  newpath 5 index 5 index moveto
+  5 index 4 index 1 mul 1.5 mul add
+  5 index 5 index 3 sqrt 1.5 mul mul add
+  1 index 1 index lineto
+  1 index 1 index 7 index sub moveto
+  1 index 1 index lineto
+  exch 5 index 3 sqrt .5 mul mul sub exch 5 index .5 mul sub lineto
+  stroke
+  5 index 5 index 5 index c fill
+  setrgbcolor 1.1 div c fill
+  } bind def
+/arrl 1 def
+/arrw 0.3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+15 137.385 translate
+282.443 dup scale
+1.0003 1.00413 translate
+%Edges:
+gsave
+0.892377 0.314377 0.899132 0.315069 0 0 0 0.00281905 l
+0.892377 0.314377 0.879312 0.313061 0 0 0 0.00281905 l
+-0.378148 0.591999 -0.377706 0.59345 0 0 0 0.00281905 l
+0.142679 0.765803 0.137983 0.756011 0 0 0 0.00281905 l
+0.142679 0.765803 0.135384 0.769731 0 0 0 0.00281905 l
+-0.573977 0.787683 -0.568555 0.775531 0 0 0 0.00281905 l
+-0.573977 0.787683 -0.576103 0.793548 0 0 0 0.00281905 l
+0.361697 0.627478 0.36624 0.645527 0 0 0 0.00281905 l
+0.361697 0.627478 0.359161 0.621443 0 0 0 0.00281905 l
+-0.0648853 0.255454 -0.0655355 0.246514 0 0 0 0.00281905 l
+-0.0648853 0.255454 -0.0694484 0.260371 0 0 0 0.00281905 l
+0.489531 0.625336 0.484444 0.624981 0 0 0 0.00281905 l
+-0.827483 -0.43727 -0.813228 -0.438529 0 0 0 0.00281905 l
+-0.827483 -0.43727 -0.836076 -0.44529 0 0 0 0.00281905 l
+-0.27923 -0.630758 -0.260306 -0.641201 0 0 0 0.00281905 l
+-0.27923 -0.630758 -0.286551 -0.635721 0 0 0 0.00281905 l
+-0.27923 -0.630758 -0.284254 -0.619588 0 0 0 0.00281905 l
+-0.715659 0.606144 -0.714406 0.588104 0 0 0 0.00281905 l
+-0.715659 0.606144 -0.72131 0.620969 0 0 0 0.00281905 l
+-0.715659 0.606144 -0.736173 0.602223 0 0 0 0.00281905 l
+0.00123777 0.178034 -0.00196712 0.167491 0 0 0 0.00281905 l
+0.00123777 0.178034 0.0029867 0.189186 0 0 0 0.00281905 l
+0.00123777 0.178034 0.0173259 0.179161 0 0 0 0.00281905 l
+0.0344357 -0.826531 0.0403615 -0.819917 0 0 0 0.00281905 l
+0.0344357 -0.826531 0.0445223 -0.846144 0 0 0 0.00281905 l
+0.0344357 -0.826531 0.0289148 -0.822333 0 0 0 0.00281905 l
+0.688691 0.317485 0.688901 0.311103 0 0 0 0.00281905 l
+-0.599054 -0.538011 -0.585245 -0.525197 0 0 0 0.00281905 l
+-0.599054 -0.538011 -0.606868 -0.52957 0 0 0 0.00281905 l
+-0.187192 -0.968067 -0.182237 -0.976054 0 0 0 0.00281905 l
+-0.187192 -0.968067 -0.206498 -0.978179 0 0 0 0.00281905 l
+-0.364811 0.405046 -0.374543 0.392668 0 0 0 0.00281905 l
+-0.364811 0.405046 -0.373027 0.421394 0 0 0 0.00281905 l
+-0.364811 0.405046 -0.353341 0.412346 0 0 0 0.00281905 l
+-0.87753 -0.359045 -0.874466 -0.347796 0 0 0 0.00281905 l
+-0.87753 -0.359045 -0.874931 -0.360026 0 0 0 0.00281905 l
+-0.87753 -0.359045 -0.887786 -0.365061 0 0 0 0.00281905 l
+0.537528 -0.244047 0.547597 -0.246631 0 0 0 0.00281905 l
+0.537528 -0.244047 0.534126 -0.238873 0 0 0 0.00281905 l
+0.517552 0.349638 0.525126 0.347219 0 0 0 0.00281905 l
+0.663086 -0.163838 0.67232 -0.159013 0 0 0 0.00281905 l
+0.663086 -0.163838 0.66809 -0.172299 0 0 0 0.00281905 l
+0.79628 -0.464702 0.79775 -0.469434 0 0 0 0.00281905 l
+0.79628 -0.464702 0.789381 -0.458025 0 0 0 0.00281905 l
+0.910713 0.0296029 0.907007 0.020923 0 0 0 0.00281905 l
+0.910713 0.0296029 0.904646 0.0320615 0 0 0 0.00281905 l
+-0.779532 -0.24478 -0.770354 -0.231486 0 0 0 0.00281905 l
+-0.779532 -0.24478 -0.785787 -0.244363 0 0 0 0.00281905 l
+-0.462461 -0.301226 -0.459951 -0.305005 0 0 0 0.00281905 l
+-0.462461 -0.301226 -0.455688 -0.29497 0 0 0 0.00281905 l
+0.882629 0.0689667 0.879374 0.0548496 0 0 0 0.00281905 l
+0.882629 0.0689667 0.884434 0.0693095 0 0 0 0.00281905 l
+-0.390433 -0.118897 -0.379645 -0.106963 0 0 0 0.00281905 l
+-0.390433 -0.118897 -0.40367 -0.110635 0 0 0 0.00281905 l
+0.585351 0.0759399 0.589856 0.0697154 0 0 0 0.00281905 l
+0.585351 0.0759399 0.586955 0.0783149 0 0 0 0.00281905 l
+0.0102529 0.297858 0.0111923 0.303376 0 0 0 0.00281905 l
+0.0102529 0.297858 0.00447014 0.295747 0 0 0 0.00281905 l
+0.485734 0.0600073 0.478707 0.0443429 0 0 0 0.00281905 l
+0.485734 0.0600073 0.502249 0.0650232 0 0 0 0.00281905 l
+0.485734 0.0600073 0.479699 0.0626173 0 0 0 0.00281905 l
+-0.258711 0.378563 -0.256929 0.372516 0 0 0 0.00281905 l
+-0.258711 0.378563 -0.274509 0.376069 0 0 0 0.00281905 l
+0.198372 0.396263 0.20979 0.398424 0 0 0 0.00281905 l
+0.198372 0.396263 0.198122 0.396891 0 0 0 0.00281905 l
+-0.548872 0.620259 -0.55359 0.609783 0 0 0 0.00281905 l
+-0.548872 0.620259 -0.562737 0.628839 0 0 0 0.00281905 l
+0.332938 0.271198 0.348506 0.281343 0 0 0 0.00281905 l
+0.332938 0.271198 0.324698 0.269985 0 0 0 0.00281905 l
+-0.0254182 0.300329 -0.0265918 0.291939 0 0 0 0.00281905 l
+0.0805016 -0.739182 0.0926123 -0.74928 0 0 0 0.00281905 l
+0.0805016 -0.739182 0.0753081 -0.742728 0 0 0 0.00281905 l
+0.157892 0.0372881 0.163718 0.0233704 0 0 0 0.00281905 l
+0.157892 0.0372881 0.164655 0.0450256 0 0 0 0.00281905 l
+0.157892 0.0372881 0.141878 0.0287438 0 0 0 0.00281905 l
+0.373701 -0.182546 0.370282 -0.171548 0 0 0 0.00281905 l
+0.373701 -0.182546 0.380626 -0.182453 0 0 0 0.00281905 l
+0.0484154 -0.367749 0.0575837 -0.369061 0 0 0 0.00281905 l
+0.0484154 -0.367749 0.0433193 -0.37552 0 0 0 0.00281905 l
+-0.284258 -0.64961 -0.294095 -0.665844 0 0 0 0.00281905 l
+-0.284258 -0.64961 -0.294257 -0.643241 0 0 0 0.00281905 l
+0.183478 -0.239425 0.19566 -0.230072 0 0 0 0.00281905 l
+0.183478 -0.239425 0.179976 -0.240723 0 0 0 0.00281905 l
+-0.193769 -0.526706 -0.191946 -0.516594 0 0 0 0.00281905 l
+-0.193769 -0.526706 -0.176436 -0.530245 0 0 0 0.00281905 l
+0.946869 -0.0360685 0.959507 -0.0461685 0 0 0 0.00281905 l
+0.946869 -0.0360685 0.936504 -0.0513468 0 0 0 0.00281905 l
+0.946869 -0.0360685 0.932883 -0.0293105 0 0 0 0.00281905 l
+-0.186377 -0.697726 -0.175121 -0.704277 0 0 0 0.00281905 l
+-0.186377 -0.697726 -0.191776 -0.708298 0 0 0 0.00281905 l
+-0.00418032 -0.196153 -0.00285242 -0.184346 0 0 0 0.00281905 l
+-0.00418032 -0.196153 0.00180936 -0.199822 0 0 0 0.00281905 l
+-0.00418032 -0.196153 -0.0074707 -0.204966 0 0 0 0.00281905 l
+0.344232 -0.0756216 0.342159 -0.0682193 0 0 0 0.00281905 l
+0.344232 -0.0756216 0.345161 -0.0875764 0 0 0 0.00281905 l
+-0.146624 -0.768533 -0.146222 -0.766371 0 0 0 0.00281905 l
+-0.43689 -0.574383 -0.43427 -0.567725 0 0 0 0.00281905 l
+-0.43689 -0.574383 -0.423156 -0.581974 0 0 0 0.00281905 l
+-0.43689 -0.574383 -0.4471 -0.582873 0 0 0 0.00281905 l
+-0.392881 0.598454 -0.391989 0.606799 0 0 0 0.00281905 l
+-0.392881 0.598454 -0.377706 0.59345 0 0 0 0.00281905 l
+-0.392881 0.598454 -0.398185 0.597353 0 0 0 0.00281905 l
+-0.472664 0.641365 -0.4704 0.643535 0 0 0 0.00281905 l
+-0.472664 0.641365 -0.492694 0.645639 0 0 0 0.00281905 l
+0.319802 -0.0770073 0.310962 -0.0655643 0 0 0 0.00281905 l
+0.319802 -0.0770073 0.329383 -0.0691895 0 0 0 0.00281905 l
+-0.304515 -0.174461 -0.298834 -0.182428 0 0 0 0.00281905 l
+-0.304515 -0.174461 -0.312765 -0.175179 0 0 0 0.00281905 l
+0.547444 -0.592761 0.547688 -0.603287 0 0 0 0.00281905 l
+-0.585223 0.596996 -0.579142 0.614841 0 0 0 0.00281905 l
+-0.585223 0.596996 -0.578719 0.587806 0 0 0 0.00281905 l
+-0.585223 0.596996 -0.587102 0.597113 0 0 0 0.00281905 l
+0.479873 0.0318322 0.478707 0.0443429 0 0 0 0.00281905 l
+0.479873 0.0318322 0.467472 0.0223417 0 0 0 0.00281905 l
+0.587995 -0.730842 0.595041 -0.730904 0 0 0 0.00281905 l
+-0.0939756 -0.791091 -0.0857093 -0.791865 0 0 0 0.00281905 l
+-0.0939756 -0.791091 -0.106892 -0.79253 0 0 0 0.00281905 l
+-0.361644 -0.410231 -0.374647 -0.396082 0 0 0 0.00281905 l
+0.66338 0.0550395 0.657276 0.0673793 0 0 0 0.00281905 l
+0.66338 0.0550395 0.660006 0.0471852 0 0 0 0.00281905 l
+-0.653746 -0.0680466 -0.650096 -0.0707802 0 0 0 0.00281905 l
+-0.0711508 0.470514 -0.0693729 0.480832 0 0 0 0.00281905 l
+-0.0711508 0.470514 -0.054016 0.470261 0 0 0 0.00281905 l
+-0.0711508 0.470514 -0.0752377 0.460833 0 0 0 0.00281905 l
+-0.625953 0.589286 -0.635834 0.600135 0 0 0 0.00281905 l
+-0.625953 0.589286 -0.61753 0.57557 0 0 0 0.00281905 l
+0.495719 -0.433143 0.509363 -0.429853 0 0 0 0.00281905 l
+0.465762 0.527534 0.453563 0.516157 0 0 0 0.00281905 l
+0.465762 0.527534 0.465141 0.538864 0 0 0 0.00281905 l
+0.465762 0.527534 0.476574 0.52699 0 0 0 0.00281905 l
+-0.477554 0.611506 -0.463205 0.602987 0 0 0 0.00281905 l
+-0.477554 0.611506 -0.484983 0.613739 0 0 0 0.00281905 l
+-0.0074707 -0.204966 -0.00418032 -0.196153 0 0 0 0.00281905 l
+-0.0074707 -0.204966 -0.0154171 -0.212508 0 0 0 0.00281905 l
+0.102008 0.706537 0.102012 0.702991 0 0 0 0.00281905 l
+0.102008 0.706537 0.111753 0.721165 0 0 0 0.00281905 l
+0.102008 0.706537 0.0891672 0.707587 0 0 0 0.00281905 l
+0.285095 -0.650682 0.278515 -0.642057 0 0 0 0.00281905 l
+0.171294 -0.00601238 0.163962 -0.00261265 0 0 0 0.00281905 l
+0.641023 -0.0101347 0.634276 -0.0121349 0 0 0 0.00281905 l
+-0.221643 -0.551992 -0.226829 -0.567501 0 0 0 0.00281905 l
+-0.221643 -0.551992 -0.227965 -0.549005 0 0 0 0.00281905 l
+0.0358706 -0.890694 0.0396419 -0.892074 0 0 0 0.00281905 l
+0.0358706 -0.890694 0.0291673 -0.900703 0 0 0 0.00281905 l
+-0.256243 0.601545 -0.264443 0.583477 0 0 0 0.00281905 l
+-0.256243 0.601545 -0.26188 0.604139 0 0 0 0.00281905 l
+-0.256243 0.601545 -0.25576 0.602377 0 0 0 0.00281905 l
+-0.839881 -0.402361 -0.845006 -0.381534 0 0 0 0.00281905 l
+-0.839881 -0.402361 -0.81965 -0.39331 0 0 0 0.00281905 l
+-0.71196 -0.0641645 -0.71913 -0.0477793 0 0 0 0.00281905 l
+-0.71196 -0.0641645 -0.697077 -0.0698009 0 0 0 0.00281905 l
+-0.71196 -0.0641645 -0.728379 -0.0701402 0 0 0 0.00281905 l
+0.881237 -0.0195923 0.876144 -0.0122709 0 0 0 0.00281905 l
+0.881237 -0.0195923 0.879916 -0.0335789 0 0 0 0.00281905 l
+-0.516771 0.291747 -0.514077 0.276042 0 0 0 0.00281905 l
+-0.516771 0.291747 -0.520297 0.29151 0 0 0 0.00281905 l
+-0.516771 0.291747 -0.510603 0.299714 0 0 0 0.00281905 l
+0.501581 -0.643777 0.516224 -0.646126 0 0 0 0.00281905 l
+-0.117615 -0.664964 -0.118721 -0.655345 0 0 0 0.00281905 l
+-0.117615 -0.664964 -0.116191 -0.675018 0 0 0 0.00281905 l
+0.0225929 -0.537784 0.0245737 -0.542746 0 0 0 0.00281905 l
+0.0225929 -0.537784 0.020818 -0.531706 0 0 0 0.00281905 l
+0.633789 0.0880051 0.640516 0.097134 0 0 0 0.00281905 l
+0.724323 -0.338883 0.733725 -0.332131 0 0 0 0.00281905 l
+0.724323 -0.338883 0.716229 -0.336557 0 0 0 0.00281905 l
+-0.51419 0.239071 -0.526248 0.228606 0 0 0 0.00281905 l
+-0.51419 0.239071 -0.524339 0.246836 0 0 0 0.00281905 l
+0.24087 0.520442 0.242945 0.534337 0 0 0 0.00281905 l
+0.24087 0.520442 0.234858 0.500228 0 0 0 0.00281905 l
+0.659074 0.224573 0.658198 0.207619 0 0 0 0.00281905 l
+0.659074 0.224573 0.641067 0.23596 0 0 0 0.00281905 l
+0.289252 -0.0410934 0.303046 -0.0269853 0 0 0 0.00281905 l
+0.289252 -0.0410934 0.279404 -0.0458935 0 0 0 0.00281905 l
+-0.0336384 -0.257983 -0.0306524 -0.25522 0 0 0 0.00281905 l
+-0.0336384 -0.257983 -0.0511313 -0.260431 0 0 0 0.00281905 l
+-0.289121 0.746069 -0.290157 0.761985 0 0 0 0.00281905 l
+-0.289121 0.746069 -0.28512 0.744758 0 0 0 0.00281905 l
+-0.421886 0.488646 -0.418003 0.481581 0 0 0 0.00281905 l
+-0.421886 0.488646 -0.43363 0.481924 0 0 0 0.00281905 l
+0.974544 0.0834857 0.983838 0.0666955 0 0 0 0.00281905 l
+0.974544 0.0834857 0.957023 0.085221 0 0 0 0.00281905 l
+0.138926 -0.115009 0.141791 -0.124999 0 0 0 0.00281905 l
+0.138926 -0.115009 0.123972 -0.107649 0 0 0 0.00281905 l
+0.302232 -0.270151 0.305731 -0.258657 0 0 0 0.00281905 l
+0.302232 -0.270151 0.298834 -0.274908 0 0 0 0.00281905 l
+0.363052 0.669687 0.367063 0.671708 0 0 0 0.00281905 l
+0.363052 0.669687 0.360501 0.666707 0 0 0 0.00281905 l
+0.718407 0.672556 0.707428 0.678021 0 0 0 0.00281905 l
+0.718407 0.672556 0.724431 0.672511 0 0 0 0.00281905 l
+0.718407 0.672556 0.712108 0.666206 0 0 0 0.00281905 l
+-0.6973 -0.624367 -0.692573 -0.626879 0 0 0 0.00281905 l
+-0.6973 -0.624367 -0.708656 -0.617941 0 0 0 0.00281905 l
+-0.0107231 -0.718546 -0.00185276 -0.710262 0 0 0 0.00281905 l
+-0.0107231 -0.718546 -0.0149834 -0.722587 0 0 0 0.00281905 l
+0.648165 -0.294344 0.663176 -0.289408 0 0 0 0.00281905 l
+0.648165 -0.294344 0.656959 -0.305592 0 0 0 0.00281905 l
+0.648165 -0.294344 0.633164 -0.295608 0 0 0 0.00281905 l
+0.0173174 0.826207 0.00664457 0.837468 0 0 0 0.00281905 l
+0.0173174 0.826207 0.0118304 0.8226 0 0 0 0.00281905 l
+-0.831251 0.288925 -0.827296 0.286213 0 0 0 0.00281905 l
+-0.831251 0.288925 -0.833396 0.29143 0 0 0 0.00281905 l
+0.0504919 -0.984968 0.0460058 -0.976684 0 0 0 0.00281905 l
+0.609722 0.166727 0.615484 0.182329 0 0 0 0.00281905 l
+0.609722 0.166727 0.602944 0.168561 0 0 0 0.00281905 l
+-0.0330348 -0.986124 -0.0397814 -0.978229 0 0 0 0.00281905 l
+0.421707 0.655813 0.434441 0.645359 0 0 0 0.00281905 l
+0.421707 0.655813 0.425751 0.670064 0 0 0 0.00281905 l
+-0.184112 0.293467 -0.18381 0.297756 0 0 0 0.00281905 l
+-0.184112 0.293467 -0.190965 0.286471 0 0 0 0.00281905 l
+0.767002 0.262985 0.769588 0.266076 0 0 0 0.00281905 l
+0.767002 0.262985 0.744644 0.262738 0 0 0 0.00281905 l
+-0.313403 -0.044924 -0.311092 -0.0578662 0 0 0 0.00281905 l
+-0.313403 -0.044924 -0.309744 -0.0378772 0 0 0 0.00281905 l
+-0.207633 -0.158163 -0.195935 -0.16256 0 0 0 0.00281905 l
+0.521226 0.582454 0.53825 0.581333 0 0 0 0.00281905 l
+-0.40092 0.279217 -0.401378 0.285835 0 0 0 0.00281905 l
+-0.40092 0.279217 -0.405122 0.274907 0 0 0 0.00281905 l
+0.110915 0.724717 0.107425 0.732874 0 0 0 0.00281905 l
+0.110915 0.724717 0.111753 0.721165 0 0 0 0.00281905 l
+0.126259 -0.808334 0.140723 -0.814096 0 0 0 0.00281905 l
+0.126259 -0.808334 0.117494 -0.823148 0 0 0 0.00281905 l
+0.882604 -0.19464 0.888053 -0.183183 0 0 0 0.00281905 l
+0.882604 -0.19464 0.864756 -0.202048 0 0 0 0.00281905 l
+0.585116 -0.429371 0.592781 -0.434856 0 0 0 0.00281905 l
+0.585116 -0.429371 0.580269 -0.443817 0 0 0 0.00281905 l
+-0.661313 -0.575778 -0.651511 -0.565413 0 0 0 0.00281905 l
+-0.661313 -0.575778 -0.662789 -0.581957 0 0 0 0.00281905 l
+-0.0615094 0.746148 -0.0611782 0.746094 0 0 0 0.00281905 l
+-0.0615094 0.746148 -0.0678142 0.750581 0 0 0 0.00281905 l
+0.112057 -0.456275 0.108018 -0.453934 0 0 0 0.00281905 l
+-0.457775 -0.227992 -0.453983 -0.220396 0 0 0 0.00281905 l
+-0.457775 -0.227992 -0.470154 -0.234332 0 0 0 0.00281905 l
+-0.540706 0.524958 -0.533087 0.526448 0 0 0 0.00281905 l
+-0.181808 -0.0866542 -0.185372 -0.0804114 0 0 0 0.00281905 l
+-0.181808 -0.0866542 -0.168607 -0.0811395 0 0 0 0.00281905 l
+0.722759 0.120093 0.718057 0.132256 0 0 0 0.00281905 l
+0.722759 0.120093 0.731846 0.124674 0 0 0 0.00281905 l
+-0.320403 0.137847 -0.315402 0.138071 0 0 0 0.00281905 l
+-0.320403 0.137847 -0.328946 0.135076 0 0 0 0.00281905 l
+0.253448 -0.27984 0.253131 -0.271794 0 0 0 0.00281905 l
+0.253448 -0.27984 0.246323 -0.284371 0 0 0 0.00281905 l
+0.77145 -0.544199 0.781743 -0.532412 0 0 0 0.00281905 l
+0.77145 -0.544199 0.766365 -0.543123 0 0 0 0.00281905 l
+-0.359283 -0.208361 -0.354364 -0.222368 0 0 0 0.00281905 l
+-0.359283 -0.208361 -0.368079 -0.195 0 0 0 0.00281905 l
+-0.359283 -0.208361 -0.373365 -0.214269 0 0 0 0.00281905 l
+-0.517601 0.394785 -0.517191 0.375073 0 0 0 0.00281905 l
+-0.517601 0.394785 -0.515777 0.398971 0 0 0 0.00281905 l
+0.281511 0.700095 0.286838 0.718016 0 0 0 0.00281905 l
+0.660929 -0.0380969 0.671448 -0.0334163 0 0 0 0.00281905 l
+0.660929 -0.0380969 0.647748 -0.0480882 0 0 0 0.00281905 l
+-0.427755 -0.327327 -0.428882 -0.333464 0 0 0 0.00281905 l
+-0.111745 -0.794424 -0.109836 -0.798251 0 0 0 0.00281905 l
+-0.111745 -0.794424 -0.121946 -0.793189 0 0 0 0.00281905 l
+0.172151 0.837416 0.189765 0.832063 0 0 0 0.00281905 l
+0.172151 0.837416 0.169456 0.83357 0 0 0 0.00281905 l
+0.212597 -0.0909193 0.210368 -0.109028 0 0 0 0.00281905 l
+0.212597 -0.0909193 0.216764 -0.0842968 0 0 0 0.00281905 l
+-0.128671 -0.643142 -0.118721 -0.655345 0 0 0 0.00281905 l
+-0.128671 -0.643142 -0.138697 -0.638894 0 0 0 0.00281905 l
+-0.558519 -0.707002 -0.555181 -0.720769 0 0 0 0.00281905 l
+-0.558519 -0.707002 -0.538745 -0.703241 0 0 0 0.00281905 l
+0.410947 -0.396509 0.41265 -0.390204 0 0 0 0.00281905 l
+0.410947 -0.396509 0.413299 -0.415955 0 0 0 0.00281905 l
+0.410947 -0.396509 0.399481 -0.394353 0 0 0 0.00281905 l
+0.0659407 0.614678 0.0776234 0.623132 0 0 0 0.00281905 l
+0.0659407 0.614678 0.0545468 0.61495 0 0 0 0.00281905 l
+-0.634403 -0.23306 -0.630034 -0.220034 0 0 0 0.00281905 l
+-0.634403 -0.23306 -0.617945 -0.242948 0 0 0 0.00281905 l
+-0.634403 -0.23306 -0.638719 -0.234543 0 0 0 0.00281905 l
+-0.75693 -0.515937 -0.75439 -0.513988 0 0 0 0.00281905 l
+-0.75693 -0.515937 -0.764021 -0.518381 0 0 0 0.00281905 l
+-0.75095 -0.438058 -0.735877 -0.440541 0 0 0 0.00281905 l
+-0.75095 -0.438058 -0.765033 -0.453068 0 0 0 0.00281905 l
+-0.75095 -0.438058 -0.751593 -0.436417 0 0 0 0.00281905 l
+-0.430726 -0.689184 -0.421323 -0.67407 0 0 0 0.00281905 l
+-0.430726 -0.689184 -0.417619 -0.697159 0 0 0 0.00281905 l
+-0.430726 -0.689184 -0.43249 -0.705028 0 0 0 0.00281905 l
+-0.430726 -0.689184 -0.433485 -0.688395 0 0 0 0.00281905 l
+-0.070794 -0.328827 -0.0633404 -0.340589 0 0 0 0.00281905 l
+0.111441 0.849678 0.120056 0.86288 0 0 0 0.00281905 l
+0.111441 0.849678 0.0981779 0.866614 0 0 0 0.00281905 l
+0.111441 0.849678 0.0967379 0.843532 0 0 0 0.00281905 l
+-0.898325 -0.158439 -0.895315 -0.154381 0 0 0 0.00281905 l
+-0.898325 -0.158439 -0.886975 -0.165767 0 0 0 0.00281905 l
+-0.369281 -0.672753 -0.353627 -0.664887 0 0 0 0.00281905 l
+-0.369281 -0.672753 -0.383187 -0.663101 0 0 0 0.00281905 l
+-0.39064 -0.597497 -0.376371 -0.585005 0 0 0 0.00281905 l
+-0.39064 -0.597497 -0.399047 -0.580146 0 0 0 0.00281905 l
+-0.39064 -0.597497 -0.389098 -0.600396 0 0 0 0.00281905 l
+-0.103904 -0.0118689 -0.116723 -0.0085806 0 0 0 0.00281905 l
+0.0683795 -0.780394 0.0809075 -0.78458 0 0 0 0.00281905 l
+0.0683795 -0.780394 0.0715648 -0.773352 0 0 0 0.00281905 l
+0.0683795 -0.780394 0.0613402 -0.786317 0 0 0 0.00281905 l
+-0.372484 0.140811 -0.374461 0.153265 0 0 0 0.00281905 l
+-0.372484 0.140811 -0.370043 0.135253 0 0 0 0.00281905 l
+-0.372484 0.140811 -0.37702 0.138379 0 0 0 0.00281905 l
+-0.457782 -0.82472 -0.459282 -0.830735 0 0 0 0.00281905 l
+-0.457782 -0.82472 -0.454125 -0.817719 0 0 0 0.00281905 l
+-0.0356111 0.0664645 -0.0504062 0.0642808 0 0 0 0.00281905 l
+-0.816974 -0.340654 -0.800148 -0.350436 0 0 0 0.00281905 l
+0.387205 0.85976 0.388484 0.841124 0 0 0 0.00281905 l
+0.387205 0.85976 0.403211 0.873554 0 0 0 0.00281905 l
+0.387205 0.85976 0.378493 0.867154 0 0 0 0.00281905 l
+-0.451385 0.246788 -0.454904 0.232475 0 0 0 0.00281905 l
+0.283473 0.425608 0.284737 0.417406 0 0 0 0.00281905 l
+0.283473 0.425608 0.278626 0.44116 0 0 0 0.00281905 l
+0.296988 0.391246 0.300813 0.377633 0 0 0 0.00281905 l
+0.296988 0.391246 0.286925 0.389536 0 0 0 0.00281905 l
+0.695807 0.0525798 0.703022 0.0382721 0 0 0 0.00281905 l
+-0.963998 -0.0237917 -0.957476 -0.00905659 0 0 0 0.00281905 l
+-0.963998 -0.0237917 -0.952215 -0.027516 0 0 0 0.00281905 l
+-0.963998 -0.0237917 -0.979359 -0.0342607 0 0 0 0.00281905 l
+0.562304 0.531496 0.579909 0.534159 0 0 0 0.00281905 l
+0.562304 0.531496 0.551585 0.546655 0 0 0 0.00281905 l
+-0.542721 -0.576151 -0.538924 -0.564821 0 0 0 0.00281905 l
+-0.0575648 -0.791976 -0.0604881 -0.785019 0 0 0 0.00281905 l
+-0.322456 -0.0570458 -0.333743 -0.0734285 0 0 0 0.00281905 l
+-0.322456 -0.0570458 -0.316533 -0.0584141 0 0 0 0.00281905 l
+-0.594434 0.353836 -0.586558 0.351725 0 0 0 0.00281905 l
+0.65422 0.661116 0.653521 0.656916 0 0 0 0.00281905 l
+0.65422 0.661116 0.641966 0.670411 0 0 0 0.00281905 l
+0.195911 -0.320588 0.199684 -0.309589 0 0 0 0.00281905 l
+0.323835 0.84685 0.329852 0.834859 0 0 0 0.00281905 l
+0.323835 0.84685 0.31349 0.852219 0 0 0 0.00281905 l
+-0.0687606 0.820359 -0.0638899 0.835924 0 0 0 0.00281905 l
+0.676104 -0.416441 0.66384 -0.415708 0 0 0 0.00281905 l
+-0.412373 0.0777009 -0.409843 0.0917576 0 0 0 0.00281905 l
+-0.412373 0.0777009 -0.408193 0.0708045 0 0 0 0.00281905 l
+0.798373 0.578077 0.811635 0.57243 0 0 0 0.00281905 l
+0.798373 0.578077 0.786329 0.566404 0 0 0 0.00281905 l
+0.798373 0.578077 0.792462 0.584123 0 0 0 0.00281905 l
+-0.778927 0.0803473 -0.762908 0.0832709 0 0 0 0.00281905 l
+-0.778927 0.0803473 -0.79091 0.0824744 0 0 0 0.00281905 l
+-0.628733 -0.0582704 -0.629075 -0.0599193 0 0 0 0.00281905 l
+0.172476 -0.328893 0.173643 -0.34033 0 0 0 0.00281905 l
+0.172476 -0.328893 0.159245 -0.322939 0 0 0 0.00281905 l
+0.615357 0.0775967 0.603143 0.0773387 0 0 0 0.00281905 l
+-0.470723 0.204716 -0.466617 0.209667 0 0 0 0.00281905 l
+-0.0679505 0.532613 -0.0620178 0.514304 0 0 0 0.00281905 l
+-0.0679505 0.532613 -0.0702927 0.538948 0 0 0 0.00281905 l
+-0.472835 0.0365135 -0.459085 0.0310881 0 0 0 0.00281905 l
+-0.472835 0.0365135 -0.479277 0.0306757 0 0 0 0.00281905 l
+0.225389 -0.785862 0.215019 -0.775333 0 0 0 0.00281905 l
+0.225389 -0.785862 0.233989 -0.795961 0 0 0 0.00281905 l
+0.268951 -0.239451 0.270602 -0.239736 0 0 0 0.00281905 l
+0.268951 -0.239451 0.260383 -0.248829 0 0 0 0.00281905 l
+0.715525 -0.409416 0.724993 -0.420938 0 0 0 0.00281905 l
+0.715525 -0.409416 0.708548 -0.42369 0 0 0 0.00281905 l
+0.715525 -0.409416 0.712591 -0.406759 0 0 0 0.00281905 l
+-0.429033 -0.645016 -0.41998 -0.650518 0 0 0 0.00281905 l
+-0.429033 -0.645016 -0.436571 -0.641834 0 0 0 0.00281905 l
+0.330889 -0.254308 0.334964 -0.258363 0 0 0 0.00281905 l
+0.330889 -0.254308 0.33027 -0.253005 0 0 0 0.00281905 l
+-0.561719 0.432825 -0.555642 0.432886 0 0 0 0.00281905 l
+-0.561719 0.432825 -0.576291 0.435622 0 0 0 0.00281905 l
+-0.0962162 -0.693002 -0.0865676 -0.703775 0 0 0 0.00281905 l
+-0.0962162 -0.693002 -0.0960864 -0.676841 0 0 0 0.00281905 l
+0.195913 0.483755 0.209381 0.502582 0 0 0 0.00281905 l
+0.195913 0.483755 0.197503 0.470117 0 0 0 0.00281905 l
+0.195913 0.483755 0.185919 0.490962 0 0 0 0.00281905 l
+-0.851938 0.303416 -0.842705 0.306046 0 0 0 0.00281905 l
+-0.851938 0.303416 -0.867436 0.292915 0 0 0 0.00281905 l
+0.945454 0.0688078 0.938527 0.0517995 0 0 0 0.00281905 l
+0.945454 0.0688078 0.951404 0.0753673 0 0 0 0.00281905 l
+0.599835 -0.217792 0.611341 -0.219099 0 0 0 0.00281905 l
+0.14889 -0.354705 0.159673 -0.360021 0 0 0 0.00281905 l
+0.14889 -0.354705 0.141916 -0.345739 0 0 0 0.00281905 l
+-0.570906 0.746253 -0.560918 0.746387 0 0 0 0.00281905 l
+0.582653 0.407763 0.588809 0.403292 0 0 0 0.00281905 l
+0.582653 0.407763 0.573556 0.413521 0 0 0 0.00281905 l
+0.43425 0.601834 0.438294 0.582879 0 0 0 0.00281905 l
+0.43425 0.601834 0.436464 0.611864 0 0 0 0.00281905 l
+0.43425 0.601834 0.422983 0.600975 0 0 0 0.00281905 l
+0.0326577 -0.320622 0.0409017 -0.320211 0 0 0 0.00281905 l
+0.0326577 -0.320622 0.0287414 -0.306426 0 0 0 0.00281905 l
+0.0816094 0.338024 0.0832575 0.326865 0 0 0 0.00281905 l
+0.0816094 0.338024 0.0788964 0.344692 0 0 0 0.00281905 l
+-0.20408 -0.50884 -0.191946 -0.516594 0 0 0 0.00281905 l
+-0.20408 -0.50884 -0.222689 -0.516962 0 0 0 0.00281905 l
+0.261716 0.00869818 0.262516 -0.0152054 0 0 0 0.00281905 l
+0.261716 0.00869818 0.26696 0.0175563 0 0 0 0.00281905 l
+-0.715119 0.509589 -0.726206 0.503545 0 0 0 0.00281905 l
+-0.715119 0.509589 -0.716445 0.512732 0 0 0 0.00281905 l
+-0.132413 -0.256717 -0.126286 -0.269057 0 0 0 0.00281905 l
+-0.132413 -0.256717 -0.132623 -0.247644 0 0 0 0.00281905 l
+0.903845 0.322358 0.913129 0.325407 0 0 0 0.00281905 l
+0.903845 0.322358 0.899132 0.315069 0 0 0 0.00281905 l
+0.327238 0.332559 0.338865 0.346673 0 0 0 0.00281905 l
+0.327238 0.332559 0.311781 0.339964 0 0 0 0.00281905 l
+0.0364645 -0.486172 0.0267073 -0.50005 0 0 0 0.00281905 l
+0.0364645 -0.486172 0.0388771 -0.486795 0 0 0 0.00281905 l
+0.0364645 -0.486172 0.0342533 -0.480061 0 0 0 0.00281905 l
+0.305731 -0.258657 0.302232 -0.270151 0 0 0 0.00281905 l
+0.305731 -0.258657 0.316047 -0.25641 0 0 0 0.00281905 l
+0.305731 -0.258657 0.29342 -0.248933 0 0 0 0.00281905 l
+-0.639332 -0.637713 -0.63308 -0.624807 0 0 0 0.00281905 l
+-0.639332 -0.637713 -0.630639 -0.655819 0 0 0 0.00281905 l
+0.714029 0.0443691 0.703022 0.0382721 0 0 0 0.00281905 l
+-0.0134509 0.884671 -0.00540737 0.878479 0 0 0 0.00281905 l
+-0.0134509 0.884671 -0.0102136 0.887686 0 0 0 0.00281905 l
+-0.0134509 0.884671 -0.0342956 0.881365 0 0 0 0.00281905 l
+0.0480267 -0.883697 0.0522422 -0.891731 0 0 0 0.00281905 l
+0.0480267 -0.883697 0.0396419 -0.892074 0 0 0 0.00281905 l
+0.0480267 -0.883697 0.0399745 -0.877483 0 0 0 0.00281905 l
+0.423628 0.781456 0.414591 0.783417 0 0 0 0.00281905 l
+0.141578 -0.951739 0.121146 -0.966807 0 0 0 0.00281905 l
+0.517652 -0.321857 0.509573 -0.307295 0 0 0 0.00281905 l
+0.517652 -0.321857 0.524454 -0.321198 0 0 0 0.00281905 l
+0.517652 -0.321857 0.511854 -0.325838 0 0 0 0.00281905 l
+0.771576 -0.562159 0.756041 -0.577051 0 0 0 0.00281905 l
+0.771576 -0.562159 0.781183 -0.554729 0 0 0 0.00281905 l
+0.771576 -0.562159 0.764574 -0.557277 0 0 0 0.00281905 l
+-0.611521 -0.553951 -0.603225 -0.554774 0 0 0 0.00281905 l
+-0.611521 -0.553951 -0.616718 -0.554948 0 0 0 0.00281905 l
+0.588218 -0.290661 0.592899 -0.296266 0 0 0 0.00281905 l
+-0.820564 -0.194413 -0.808262 -0.199351 0 0 0 0.00281905 l
+-0.820564 -0.194413 -0.82867 -0.198986 0 0 0 0.00281905 l
+-0.408294 -0.0114624 -0.402087 -0.013 0 0 0 0.00281905 l
+-0.408294 -0.0114624 -0.412622 -0.00813736 0 0 0 0.00281905 l
+-0.826251 0.00630673 -0.813494 0.00301869 0 0 0 0.00281905 l
+-0.826251 0.00630673 -0.837386 0.00531087 0 0 0 0.00281905 l
+-0.75439 -0.513988 -0.752244 -0.509145 0 0 0 0.00281905 l
+-0.75439 -0.513988 -0.75693 -0.515937 0 0 0 0.00281905 l
+0.107767 -0.936606 0.113151 -0.947652 0 0 0 0.00281905 l
+0.107767 -0.936606 0.102106 -0.935774 0 0 0 0.00281905 l
+-0.131039 0.778038 -0.117836 0.77589 0 0 0 0.00281905 l
+-0.131039 0.778038 -0.135291 0.7704 0 0 0 0.00281905 l
+-0.797203 -0.0612036 -0.779455 -0.0515826 0 0 0 0.00281905 l
+-0.797203 -0.0612036 -0.806212 -0.052957 0 0 0 0.00281905 l
+-0.420234 0.904953 -0.410544 0.891817 0 0 0 0.00281905 l
+-0.420234 0.904953 -0.432749 0.893366 0 0 0 0.00281905 l
+-0.413061 -0.295541 -0.418711 -0.285416 0 0 0 0.00281905 l
+-0.413061 -0.295541 -0.404596 -0.290831 0 0 0 0.00281905 l
+-0.413061 -0.295541 -0.410324 -0.299672 0 0 0 0.00281905 l
+-0.431284 -0.605059 -0.428617 -0.61074 0 0 0 0.00281905 l
+-0.0672167 0.115005 -0.0614377 0.121701 0 0 0 0.00281905 l
+0.443819 0.36135 0.449126 0.360789 0 0 0 0.00281905 l
+-0.278163 0.701217 -0.274973 0.710267 0 0 0 0.00281905 l
+-0.278163 0.701217 -0.292166 0.698567 0 0 0 0.00281905 l
+0.900335 0.0165146 0.907007 0.020923 0 0 0 0.00281905 l
+-0.343115 0.656944 -0.330332 0.662231 0 0 0 0.00281905 l
+-0.343115 0.656944 -0.354134 0.649266 0 0 0 0.00281905 l
+0.337558 0.922349 0.343923 0.927884 0 0 0 0.00281905 l
+0.337558 0.922349 0.329436 0.916026 0 0 0 0.00281905 l
+0.532601 0.412757 0.532065 0.407789 0 0 0 0.00281905 l
+0.0578319 -0.204478 0.0619061 -0.204734 0 0 0 0.00281905 l
+0.0578319 -0.204478 0.057302 -0.203303 0 0 0 0.00281905 l
+0.728006 0.637086 0.735806 0.63952 0 0 0 0.00281905 l
+0.728006 0.637086 0.718854 0.629992 0 0 0 0.00281905 l
+0.791256 0.493034 0.788649 0.494744 0 0 0 0.00281905 l
+0.791256 0.493034 0.796931 0.495703 0 0 0 0.00281905 l
+-0.433371 0.0615073 -0.443444 0.0722929 0 0 0 0.00281905 l
+-0.324343 -0.661009 -0.325687 -0.670572 0 0 0 0.00281905 l
+-0.445777 0.542124 -0.438136 0.531604 0 0 0 0.00281905 l
+-0.445777 0.542124 -0.435547 0.54589 0 0 0 0.00281905 l
+-0.445777 0.542124 -0.453386 0.535503 0 0 0 0.00281905 l
+-0.357973 0.326126 -0.356382 0.304641 0 0 0 0.00281905 l
+-0.357973 0.326126 -0.34242 0.332796 0 0 0 0.00281905 l
+-0.357973 0.326126 -0.36336 0.330211 0 0 0 0.00281905 l
+-0.539033 -0.284288 -0.538638 -0.287643 0 0 0 0.00281905 l
+-0.539033 -0.284288 -0.537074 -0.266389 0 0 0 0.00281905 l
+-0.539033 -0.284288 -0.557523 -0.283606 0 0 0 0.00281905 l
+-0.161064 0.260104 -0.154783 0.256784 0 0 0 0.00281905 l
+-0.161064 0.260104 -0.168417 0.250935 0 0 0 0.00281905 l
+-0.161064 0.260104 -0.163204 0.26456 0 0 0 0.00281905 l
+0.351245 -0.208525 0.354077 -0.188918 0 0 0 0.00281905 l
+0.351245 -0.208525 0.344723 -0.218604 0 0 0 0.00281905 l
+0.787593 -0.368328 0.784177 -0.353295 0 0 0 0.00281905 l
+0.787593 -0.368328 0.802743 -0.371897 0 0 0 0.00281905 l
+0.787593 -0.368328 0.776361 -0.373834 0 0 0 0.00281905 l
+0.292883 0.12219 0.292639 0.128123 0 0 0 0.00281905 l
+0.292883 0.12219 0.295553 0.121061 0 0 0 0.00281905 l
+0.432164 -0.451936 0.439044 -0.465089 0 0 0 0.00281905 l
+0.432164 -0.451936 0.418042 -0.438294 0 0 0 0.00281905 l
+0.432164 -0.451936 0.422909 -0.462562 0 0 0 0.00281905 l
+0.305646 0.700255 0.30739 0.705442 0 0 0 0.00281905 l
+-0.284027 -0.00818105 -0.277271 -0.0106778 0 0 0 0.00281905 l
+-0.284027 -0.00818105 -0.288595 0.00379277 0 0 0 0.00281905 l
+-0.284027 -0.00818105 -0.296246 -0.0121887 0 0 0 0.00281905 l
+-0.33694 -0.578202 -0.316056 -0.583319 0 0 0 0.00281905 l
+-0.33694 -0.578202 -0.349437 -0.567291 0 0 0 0.00281905 l
+0.79775 -0.469434 0.79628 -0.464702 0 0 0 0.00281905 l
+0.435434 0.299367 0.456049 0.29366 0 0 0 0.00281905 l
+0.435434 0.299367 0.429398 0.303165 0 0 0 0.00281905 l
+-0.139771 0.0526833 -0.124159 0.0552155 0 0 0 0.00281905 l
+-0.139771 0.0526833 -0.139392 0.0499299 0 0 0 0.00281905 l
+-0.139771 0.0526833 -0.141746 0.0601798 0 0 0 0.00281905 l
+-0.0128192 0.899165 -0.0102136 0.887686 0 0 0 0.00281905 l
+-0.0128192 0.899165 -0.0305158 0.912857 0 0 0 0.00281905 l
+-0.184919 -0.656242 -0.175458 -0.657824 0 0 0 0.00281905 l
+-0.184919 -0.656242 -0.199851 -0.65383 0 0 0 0.00281905 l
+0.149476 0.93484 0.147178 0.934427 0 0 0 0.00281905 l
+0.149476 0.93484 0.151419 0.937909 0 0 0 0.00281905 l
+-0.612655 -0.173906 -0.614974 -0.184413 0 0 0 0.00281905 l
+-0.612655 -0.173906 -0.609486 -0.166932 0 0 0 0.00281905 l
+0.0114837 -0.727832 0.0263655 -0.724008 0 0 0 0.00281905 l
+0.0114837 -0.727832 0.00131251 -0.716806 0 0 0 0.00281905 l
+0.0114837 -0.727832 0.00672245 -0.733663 0 0 0 0.00281905 l
+0.647396 0.256202 0.657387 0.247274 0 0 0 0.00281905 l
+0.647396 0.256202 0.653088 0.261671 0 0 0 0.00281905 l
+-0.0702927 0.538948 -0.0679505 0.532613 0 0 0 0.00281905 l
+-0.0702927 0.538948 -0.0760159 0.540889 0 0 0 0.00281905 l
+0.635856 0.306672 0.645407 0.298348 0 0 0 0.00281905 l
+0.635856 0.306672 0.622274 0.311939 0 0 0 0.00281905 l
+-0.0863585 0.206015 -0.100373 0.208031 0 0 0 0.00281905 l
+-0.0453286 0.311044 -0.045084 0.32164 0 0 0 0.00281905 l
+-0.0453286 0.311044 -0.0413975 0.30903 0 0 0 0.00281905 l
+-0.0453286 0.311044 -0.0573185 0.301684 0 0 0 0.00281905 l
+0.545584 0.316875 0.553809 0.323095 0 0 0 0.00281905 l
+0.545584 0.316875 0.538833 0.321194 0 0 0 0.00281905 l
+-0.224606 0.583983 -0.220655 0.572396 0 0 0 0.00281905 l
+-0.68813 -0.231961 -0.69185 -0.235383 0 0 0 0.00281905 l
+0.375036 0.650233 0.377868 0.658179 0 0 0 0.00281905 l
+0.375036 0.650233 0.379374 0.646196 0 0 0 0.00281905 l
+0.375036 0.650233 0.368586 0.645902 0 0 0 0.00281905 l
+-0.791309 -0.189634 -0.78696 -0.203352 0 0 0 0.00281905 l
+-0.791309 -0.189634 -0.785914 -0.181396 0 0 0 0.00281905 l
+-0.256029 0.270828 -0.241008 0.27807 0 0 0 0.00281905 l
+0.978848 0.178185 0.986945 0.150489 0 0 0 0.00281905 l
+-0.357323 -0.0240345 -0.363994 -0.0365987 0 0 0 0.00281905 l
+-0.357323 -0.0240345 -0.366591 -0.0177968 0 0 0 0.00281905 l
+-0.106219 -0.948816 -0.0988007 -0.942085 0 0 0 0.00281905 l
+-0.106219 -0.948816 -0.111163 -0.941424 0 0 0 0.00281905 l
+-0.106219 -0.948816 -0.102681 -0.953888 0 0 0 0.00281905 l
+-0.106219 -0.948816 -0.11671 -0.956021 0 0 0 0.00281905 l
+-0.034261 -0.573736 -0.0223632 -0.577535 0 0 0 0.00281905 l
+-0.034261 -0.573736 -0.0498468 -0.566282 0 0 0 0.00281905 l
+-0.191776 -0.708298 -0.186377 -0.697726 0 0 0 0.00281905 l
+-0.191776 -0.708298 -0.199499 -0.715209 0 0 0 0.00281905 l
+-0.191776 -0.708298 -0.202719 -0.703829 0 0 0 0.00281905 l
+-0.589373 0.381651 -0.580683 0.372237 0 0 0 0.00281905 l
+0.59351 -0.378382 0.597771 -0.399542 0 0 0 0.00281905 l
+0.59351 -0.378382 0.588543 -0.359538 0 0 0 0.00281905 l
+0.59351 -0.378382 0.599145 -0.376025 0 0 0 0.00281905 l
+-0.760269 0.269954 -0.759496 0.290101 0 0 0 0.00281905 l
+-0.760269 0.269954 -0.751768 0.268491 0 0 0 0.00281905 l
+-0.760269 0.269954 -0.760521 0.261933 0 0 0 0.00281905 l
+0.879196 -0.174847 0.883458 -0.164857 0 0 0 0.00281905 l
+0.879196 -0.174847 0.888053 -0.183183 0 0 0 0.00281905 l
+0.879196 -0.174847 0.871446 -0.174197 0 0 0 0.00281905 l
+0.230098 0.29353 0.225558 0.307164 0 0 0 0.00281905 l
+0.230098 0.29353 0.249118 0.295657 0 0 0 0.00281905 l
+0.343923 0.927884 0.337558 0.922349 0 0 0 0.00281905 l
+-0.464658 -0.0316159 -0.461883 -0.023583 0 0 0 0.00281905 l
+-0.464658 -0.0316159 -0.45184 -0.0423567 0 0 0 0.00281905 l
+-0.464658 -0.0316159 -0.471891 -0.0322007 0 0 0 0.00281905 l
+-0.0375404 0.0891898 -0.0401609 0.0814154 0 0 0 0.00281905 l
+-0.0375404 0.0891898 -0.038905 0.0946904 0 0 0 0.00281905 l
+0.188143 -0.0920435 0.176014 -0.0790242 0 0 0 0.00281905 l
+0.188143 -0.0920435 0.195337 -0.104477 0 0 0 0.00281905 l
+-0.847293 0.146122 -0.859048 0.154908 0 0 0 0.00281905 l
+0.627785 0.749832 0.631603 0.763807 0 0 0 0.00281905 l
+0.627785 0.749832 0.620507 0.748928 0 0 0 0.00281905 l
+-0.0651223 0.00827818 -0.0544496 0.00872464 0 0 0 0.00281905 l
+-0.0651223 0.00827818 -0.074392 0.00717552 0 0 0 0.00281905 l
+-0.26188 0.604139 -0.256243 0.601545 0 0 0 0.00281905 l
+-0.26188 0.604139 -0.283313 0.605428 0 0 0 0.00281905 l
+0.718057 0.132256 0.71628 0.144743 0 0 0 0.00281905 l
+0.718057 0.132256 0.722759 0.120093 0 0 0 0.00281905 l
+-0.489709 0.38149 -0.48173 0.380035 0 0 0 0.00281905 l
+-0.489709 0.38149 -0.496301 0.392848 0 0 0 0.00281905 l
+0.114246 0.910178 0.113321 0.90287 0 0 0 0.00281905 l
+-0.0461062 -0.075782 -0.0458544 -0.0798258 0 0 0 0.00281905 l
+-0.0971836 0.568136 -0.0896443 0.579323 0 0 0 0.00281905 l
+-0.0971836 0.568136 -0.0898826 0.559066 0 0 0 0.00281905 l
+-0.0971836 0.568136 -0.0983433 0.56889 0 0 0 0.00281905 l
+0.7918 0.0742006 0.798278 0.0781186 0 0 0 0.00281905 l
+0.7918 0.0742006 0.780967 0.0702956 0 0 0 0.00281905 l
+-0.881043 -0.0119759 -0.883816 -0.0236089 0 0 0 0.00281905 l
+-0.881043 -0.0119759 -0.884227 -0.00884595 0 0 0 0.00281905 l
+0.800641 0.49229 0.805232 0.474603 0 0 0 0.00281905 l
+0.800641 0.49229 0.796931 0.495703 0 0 0 0.00281905 l
+0.419064 -0.112711 0.426473 -0.120629 0 0 0 0.00281905 l
+0.419064 -0.112711 0.413871 -0.115406 0 0 0 0.00281905 l
+0.571655 -0.0268387 0.576692 -0.0350918 0 0 0 0.00281905 l
+0.571655 -0.0268387 0.575323 -0.0253196 0 0 0 0.00281905 l
+0.571655 -0.0268387 0.559005 -0.018311 0 0 0 0.00281905 l
+0.912548 -0.00556433 0.913723 0.0158251 0 0 0 0.00281905 l
+0.0773097 -0.42781 0.0854947 -0.423539 0 0 0 0.00281905 l
+0.0773097 -0.42781 0.0764977 -0.426921 0 0 0 0.00281905 l
+-0.388216 0.638614 -0.376286 0.649711 0 0 0 0.00281905 l
+-0.388216 0.638614 -0.371242 0.627117 0 0 0 0.00281905 l
+-0.655543 0.399722 -0.655043 0.392471 0 0 0 0.00281905 l
+-0.655543 0.399722 -0.652297 0.407991 0 0 0 0.00281905 l
+-0.0551557 0.444567 -0.0589306 0.433507 0 0 0 0.00281905 l
+-0.0551557 0.444567 -0.0668578 0.458783 0 0 0 0.00281905 l
+-0.00612641 -0.912337 0.00219534 -0.910376 0 0 0 0.00281905 l
+-0.00612641 -0.912337 -0.0177342 -0.924899 0 0 0 0.00281905 l
+-0.859556 -0.413875 -0.862578 -0.417462 0 0 0 0.00281905 l
+-0.859556 -0.413875 -0.860894 -0.4124 0 0 0 0.00281905 l
+0.37556 0.784279 0.387118 0.785956 0 0 0 0.00281905 l
+0.37556 0.784279 0.374876 0.781573 0 0 0 0.00281905 l
+0.0565317 0.422664 0.059776 0.421073 0 0 0 0.00281905 l
+0.0565317 0.422664 0.0495605 0.412473 0 0 0 0.00281905 l
+0.155029 -0.474446 0.156211 -0.475113 0 0 0 0.00281905 l
+0.155029 -0.474446 0.146779 -0.475542 0 0 0 0.00281905 l
+0.850917 0.463601 0.850005 0.479454 0 0 0 0.00281905 l
+0.850917 0.463601 0.840238 0.457341 0 0 0 0.00281905 l
+-0.223605 -0.933207 -0.218732 -0.934028 0 0 0 0.00281905 l
+-0.223605 -0.933207 -0.231127 -0.943403 0 0 0 0.00281905 l
+-0.416449 -0.793478 -0.416487 -0.787284 0 0 0 0.00281905 l
+-0.416449 -0.793478 -0.396012 -0.796179 0 0 0 0.00281905 l
+-0.416449 -0.793478 -0.420041 -0.795592 0 0 0 0.00281905 l
+0.518565 -0.748736 0.520544 -0.758228 0 0 0 0.00281905 l
+0.518565 -0.748736 0.525164 -0.738775 0 0 0 0.00281905 l
+0.317542 -0.551965 0.325664 -0.556123 0 0 0 0.00281905 l
+0.317542 -0.551965 0.305077 -0.550722 0 0 0 0.00281905 l
+-0.074392 0.00717552 -0.0651223 0.00827818 0 0 0 0.00281905 l
+-0.074392 0.00717552 -0.0798379 0.00702604 0 0 0 0.00281905 l
+-0.765284 -0.0678209 -0.751952 -0.07178 0 0 0 0.00281905 l
+-0.765284 -0.0678209 -0.775189 -0.0704009 0 0 0 0.00281905 l
+0.752506 0.168586 0.744661 0.156336 0 0 0 0.00281905 l
+0.752506 0.168586 0.751678 0.172211 0 0 0 0.00281905 l
+-0.38004 -0.142378 -0.378745 -0.142461 0 0 0 0.00281905 l
+-0.38004 -0.142378 -0.381436 -0.142291 0 0 0 0.00281905 l
+-0.656864 -0.271333 -0.666978 -0.27837 0 0 0 0.00281905 l
+-0.38382 0.0844554 -0.367017 0.072606 0 0 0 0.00281905 l
+-0.38382 0.0844554 -0.391931 0.0930126 0 0 0 0.00281905 l
+-0.38382 0.0844554 -0.386684 0.0793454 0 0 0 0.00281905 l
+0.368493 0.916552 0.386987 0.918334 0 0 0 0.00281905 l
+0.368493 0.916552 0.359181 0.893379 0 0 0 0.00281905 l
+-0.924426 -0.264798 -0.923414 -0.25199 0 0 0 0.00281905 l
+-0.435295 0.599677 -0.428635 0.621301 0 0 0 0.00281905 l
+-0.435295 0.599677 -0.446563 0.586575 0 0 0 0.00281905 l
+-0.0318552 -0.602183 -0.0318264 -0.620569 0 0 0 0.00281905 l
+0.644107 -0.419988 0.654945 -0.435469 0 0 0 0.00281905 l
+-0.408127 0.871623 -0.397071 0.879742 0 0 0 0.00281905 l
+-0.408127 0.871623 -0.414765 0.86798 0 0 0 0.00281905 l
+-0.972589 0.0717203 -0.969187 0.0641001 0 0 0 0.00281905 l
+-0.377706 0.59345 -0.369939 0.598466 0 0 0 0.00281905 l
+-0.377706 0.59345 -0.392881 0.598454 0 0 0 0.00281905 l
+-0.377706 0.59345 -0.378148 0.591999 0 0 0 0.00281905 l
+-0.48241 -0.341168 -0.489254 -0.354504 0 0 0 0.00281905 l
+-0.48241 -0.341168 -0.476571 -0.342684 0 0 0 0.00281905 l
+-0.48241 -0.341168 -0.480187 -0.337708 0 0 0 0.00281905 l
+-0.0161561 0.213599 -0.000454341 0.217395 0 0 0 0.00281905 l
+-0.0161561 0.213599 -0.0166495 0.220013 0 0 0 0.00281905 l
+-0.0161561 0.213599 -0.0298518 0.211894 0 0 0 0.00281905 l
+0.0389374 -0.686031 0.0313305 -0.697146 0 0 0 0.00281905 l
+0.0389374 -0.686031 0.0445895 -0.677521 0 0 0 0.00281905 l
+0.0389374 -0.686031 0.0276884 -0.68313 0 0 0 0.00281905 l
+0.894183 0.103661 0.899766 0.0965962 0 0 0 0.00281905 l
+0.894183 0.103661 0.900254 0.109507 0 0 0 0.00281905 l
+0.218971 0.614714 0.213089 0.635254 0 0 0 0.00281905 l
+0.218971 0.614714 0.229789 0.613911 0 0 0 0.00281905 l
+0.218971 0.614714 0.20415 0.606996 0 0 0 0.00281905 l
+0.636954 -0.648631 0.626885 -0.636392 0 0 0 0.00281905 l
+-0.331569 0.429098 -0.329793 0.422705 0 0 0 0.00281905 l
+-0.331569 0.429098 -0.319903 0.43632 0 0 0 0.00281905 l
+0.302631 0.012745 0.3082 0.0141989 0 0 0 0.00281905 l
+0.302631 0.012745 0.304682 0.0049123 0 0 0 0.00281905 l
+0.455007 -0.717542 0.460335 -0.724432 0 0 0 0.00281905 l
+0.455007 -0.717542 0.443349 -0.7284 0 0 0 0.00281905 l
+-0.797912 0.353186 -0.786839 0.35449 0 0 0 0.00281905 l
+-0.797912 0.353186 -0.800987 0.350457 0 0 0 0.00281905 l
+-0.797912 0.353186 -0.800159 0.355545 0 0 0 0.00281905 l
+0.288716 0.55399 0.304837 0.554532 0 0 0 0.00281905 l
+0.288716 0.55399 0.282609 0.558838 0 0 0 0.00281905 l
+0.493169 -0.315467 0.495351 -0.308538 0 0 0 0.00281905 l
+0.104848 0.12868 0.0991834 0.118971 0 0 0 0.00281905 l
+0.104848 0.12868 0.108528 0.135144 0 0 0 0.00281905 l
+0.104848 0.12868 0.0881119 0.132518 0 0 0 0.00281905 l
+0.736852 0.451863 0.742542 0.464396 0 0 0 0.00281905 l
+0.736852 0.451863 0.740074 0.447286 0 0 0 0.00281905 l
+0.736852 0.451863 0.735504 0.450538 0 0 0 0.00281905 l
+-0.389306 0.00564745 -0.402087 -0.013 0 0 0 0.00281905 l
+-0.389306 0.00564745 -0.393523 0.011131 0 0 0 0.00281905 l
+0.88256 0.368883 0.881109 0.35713 0 0 0 0.00281905 l
+0.88256 0.368883 0.895049 0.370642 0 0 0 0.00281905 l
+0.721461 -0.639918 0.721115 -0.646881 0 0 0 0.00281905 l
+0.721461 -0.639918 0.724085 -0.63314 0 0 0 0.00281905 l
+0.34495 -0.892724 0.347043 -0.881234 0 0 0 0.00281905 l
+0.34495 -0.892724 0.363415 -0.890585 0 0 0 0.00281905 l
+0.34495 -0.892724 0.335273 -0.886784 0 0 0 0.00281905 l
+-0.108488 -0.394721 -0.101609 -0.399938 0 0 0 0.00281905 l
+-0.108488 -0.394721 -0.116002 -0.398511 0 0 0 0.00281905 l
+0.695318 0.117938 0.692175 0.124878 0 0 0 0.00281905 l
+0.695318 0.117938 0.702572 0.113352 0 0 0 0.00281905 l
+0.695318 0.117938 0.685739 0.110695 0 0 0 0.00281905 l
+-0.599565 -0.708621 -0.595858 -0.713065 0 0 0 0.00281905 l
+-0.599565 -0.708621 -0.602122 -0.706662 0 0 0 0.00281905 l
+0.871962 0.0878966 0.872109 0.0907807 0 0 0 0.00281905 l
+-0.378824 0.553336 -0.372858 0.566488 0 0 0 0.00281905 l
+-0.378824 0.553336 -0.365632 0.548029 0 0 0 0.00281905 l
+-0.378824 0.553336 -0.390932 0.539945 0 0 0 0.00281905 l
+-0.596973 0.250855 -0.600701 0.264152 0 0 0 0.00281905 l
+-0.596973 0.250855 -0.583096 0.24908 0 0 0 0.00281905 l
+-0.596973 0.250855 -0.597354 0.250663 0 0 0 0.00281905 l
+-0.17578 -0.0324139 -0.160551 -0.0239264 0 0 0 0.00281905 l
+-0.279961 0.775062 -0.265711 0.771821 0 0 0 0.00281905 l
+-0.279961 0.775062 -0.276495 0.786795 0 0 0 0.00281905 l
+-0.279961 0.775062 -0.290157 0.761985 0 0 0 0.00281905 l
+0.0119278 0.330984 0.011891 0.335676 0 0 0 0.00281905 l
+0.169456 0.83357 0.172151 0.837416 0 0 0 0.00281905 l
+0.169456 0.83357 0.155878 0.83676 0 0 0 0.00281905 l
+0.722765 -0.185184 0.711148 -0.192842 0 0 0 0.00281905 l
+0.722765 -0.185184 0.71342 -0.17814 0 0 0 0.00281905 l
+0.232531 -0.825849 0.24156 -0.83257 0 0 0 0.00281905 l
+0.817785 0.191548 0.827815 0.197654 0 0 0 0.00281905 l
+0.817785 0.191548 0.80382 0.184186 0 0 0 0.00281905 l
+0.345285 -0.256722 0.350173 -0.242906 0 0 0 0.00281905 l
+0.345285 -0.256722 0.35069 -0.261634 0 0 0 0.00281905 l
+0.345285 -0.256722 0.334964 -0.258363 0 0 0 0.00281905 l
+-0.544116 0.795363 -0.557956 0.799333 0 0 0 0.00281905 l
+0.621978 0.629656 0.617338 0.619792 0 0 0 0.00281905 l
+-0.398576 0.148482 -0.394787 0.149718 0 0 0 0.00281905 l
+-0.704245 0.319587 -0.697663 0.317113 0 0 0 0.00281905 l
+-0.704245 0.319587 -0.719672 0.315816 0 0 0 0.00281905 l
+0.59493 -0.500403 0.606935 -0.513012 0 0 0 0.00281905 l
+0.59493 -0.500403 0.581845 -0.492748 0 0 0 0.00281905 l
+0.500749 0.470675 0.505134 0.468774 0 0 0 0.00281905 l
+0.500749 0.470675 0.496445 0.455707 0 0 0 0.00281905 l
+0.500749 0.470675 0.484806 0.478211 0 0 0 0.00281905 l
+-0.678831 -0.390101 -0.679858 -0.377469 0 0 0 0.00281905 l
+-0.678831 -0.390101 -0.677682 -0.393258 0 0 0 0.00281905 l
+-0.877035 -0.121115 -0.866412 -0.109302 0 0 0 0.00281905 l
+0.577515 0.669629 0.586849 0.656822 0 0 0 0.00281905 l
+0.577515 0.669629 0.566307 0.681343 0 0 0 0.00281905 l
+0.577515 0.669629 0.571978 0.663119 0 0 0 0.00281905 l
+-0.151187 -0.511663 -0.155542 -0.495157 0 0 0 0.00281905 l
+-0.151187 -0.511663 -0.133424 -0.504989 0 0 0 0.00281905 l
+-0.151187 -0.511663 -0.160028 -0.515332 0 0 0 0.00281905 l
+0.224296 -0.121657 0.233387 -0.133339 0 0 0 0.00281905 l
+0.224296 -0.121657 0.218517 -0.129387 0 0 0 0.00281905 l
+0.274699 0.251315 0.283247 0.240802 0 0 0 0.00281905 l
+0.274699 0.251315 0.265244 0.237757 0 0 0 0.00281905 l
+0.338135 -0.818073 0.338071 -0.810925 0 0 0 0.00281905 l
+0.338135 -0.818073 0.330579 -0.823376 0 0 0 0.00281905 l
+-0.17402 0.0217113 -0.171585 0.0379873 0 0 0 0.00281905 l
+-0.764021 -0.518381 -0.76701 -0.513317 0 0 0 0.00281905 l
+-0.764021 -0.518381 -0.75693 -0.515937 0 0 0 0.00281905 l
+-0.764021 -0.518381 -0.760404 -0.522621 0 0 0 0.00281905 l
+-0.252748 -0.468563 -0.261521 -0.452681 0 0 0 0.00281905 l
+-0.252748 -0.468563 -0.245788 -0.472229 0 0 0 0.00281905 l
+-0.495373 0.103805 -0.498813 0.116143 0 0 0 0.00281905 l
+-0.495373 0.103805 -0.490305 0.0998989 0 0 0 0.00281905 l
+-0.495373 0.103805 -0.502375 0.091121 0 0 0 0.00281905 l
+0.0256832 0.512626 0.024476 0.51887 0 0 0 0.00281905 l
+0.0256832 0.512626 0.0319384 0.515609 0 0 0 0.00281905 l
+0.204618 -0.71277 0.216334 -0.703435 0 0 0 0.00281905 l
+0.204618 -0.71277 0.214702 -0.720671 0 0 0 0.00281905 l
+0.204618 -0.71277 0.192654 -0.713142 0 0 0 0.00281905 l
+-0.182237 -0.976054 -0.172394 -0.981374 0 0 0 0.00281905 l
+-0.182237 -0.976054 -0.187192 -0.968067 0 0 0 0.00281905 l
+0.844266 -0.0844103 0.842953 -0.0767061 0 0 0 0.00281905 l
+0.844266 -0.0844103 0.841886 -0.0852088 0 0 0 0.00281905 l
+-0.394787 0.149718 -0.390638 0.13884 0 0 0 0.00281905 l
+-0.394787 0.149718 -0.398576 0.148482 0 0 0 0.00281905 l
+-0.389546 -0.908246 -0.373643 -0.895131 0 0 0 0.00281905 l
+-0.389546 -0.908246 -0.388642 -0.911226 0 0 0 0.00281905 l
+-0.389546 -0.908246 -0.404163 -0.905133 0 0 0 0.00281905 l
+-0.270134 0.245492 -0.286284 0.235084 0 0 0 0.00281905 l
+-0.635834 0.600135 -0.624878 0.609407 0 0 0 0.00281905 l
+-0.635834 0.600135 -0.625953 0.589286 0 0 0 0.00281905 l
+-0.635834 0.600135 -0.64448 0.602419 0 0 0 0.00281905 l
+-0.151423 0.799081 -0.146837 0.795197 0 0 0 0.00281905 l
+-0.151423 0.799081 -0.164327 0.803985 0 0 0 0.00281905 l
+-0.130867 -0.584762 -0.13057 -0.590787 0 0 0 0.00281905 l
+-0.130867 -0.584762 -0.125784 -0.581691 0 0 0 0.00281905 l
+-0.102301 0.482668 -0.0897377 0.477298 0 0 0 0.00281905 l
+-0.102301 0.482668 -0.107992 0.481642 0 0 0 0.00281905 l
+-0.798803 0.0566113 -0.79091 0.0824744 0 0 0 0.00281905 l
+-0.798803 0.0566113 -0.795576 0.0552122 0 0 0 0.00281905 l
+0.326858 -0.267852 0.334964 -0.258363 0 0 0 0.00281905 l
+0.886794 -0.0987549 0.89326 -0.0987694 0 0 0 0.00281905 l
+-0.252554 0.693479 -0.267285 0.709923 0 0 0 0.00281905 l
+-0.252554 0.693479 -0.241742 0.700025 0 0 0 0.00281905 l
+0.87853 -0.255731 0.871261 -0.26879 0 0 0 0.00281905 l
+0.981623 0.0303927 0.985674 0.0352875 0 0 0 0.00281905 l
+0.981623 0.0303927 0.976819 0.0281726 0 0 0 0.00281905 l
+0.106574 -0.822047 0.111144 -0.826232 0 0 0 0.00281905 l
+0.106574 -0.822047 0.0929661 -0.816806 0 0 0 0.00281905 l
+-0.318288 -0.798664 -0.327799 -0.780081 0 0 0 0.00281905 l
+-0.318288 -0.798664 -0.310009 -0.796644 0 0 0 0.00281905 l
+-0.0292952 -0.647671 -0.0248214 -0.654944 0 0 0 0.00281905 l
+0.356768 0.00409432 0.355975 -0.0113779 0 0 0 0.00281905 l
+0.356768 0.00409432 0.371717 0.0118229 0 0 0 0.00281905 l
+-0.288603 -0.556037 -0.299807 -0.556487 0 0 0 0.00281905 l
+-0.0769398 -0.892899 -0.077995 -0.885597 0 0 0 0.00281905 l
+-0.0769398 -0.892899 -0.0733442 -0.897057 0 0 0 0.00281905 l
+0.347043 -0.881234 0.344979 -0.873333 0 0 0 0.00281905 l
+0.347043 -0.881234 0.34495 -0.892724 0 0 0 0.00281905 l
+-0.515813 0.309736 -0.510603 0.299714 0 0 0 0.00281905 l
+-0.515813 0.309736 -0.507934 0.326344 0 0 0 0.00281905 l
+-0.515813 0.309736 -0.52491 0.316803 0 0 0 0.00281905 l
+-0.905777 0.118332 -0.894323 0.117195 0 0 0 0.00281905 l
+-0.905777 0.118332 -0.925487 0.123232 0 0 0 0.00281905 l
+0.789875 -0.0873253 0.798795 -0.0878288 0 0 0 0.00281905 l
+0.789875 -0.0873253 0.791927 -0.0975185 0 0 0 0.00281905 l
+0.199909 0.419481 0.206638 0.420826 0 0 0 0.00281905 l
+0.199909 0.419481 0.199785 0.417592 0 0 0 0.00281905 l
+0.0742174 0.251437 0.0804247 0.242859 0 0 0 0.00281905 l
+0.0742174 0.251437 0.0765299 0.262166 0 0 0 0.00281905 l
+0.0949823 0.348378 0.0984295 0.334889 0 0 0 0.00281905 l
+0.0949823 0.348378 0.0788964 0.344692 0 0 0 0.00281905 l
+0.524222 0.294513 0.515742 0.300438 0 0 0 0.00281905 l
+0.524222 0.294513 0.525038 0.295428 0 0 0 0.00281905 l
+0.133383 -0.0694068 0.137592 -0.0669224 0 0 0 0.00281905 l
+0.133383 -0.0694068 0.128677 -0.0628127 0 0 0 0.00281905 l
+-0.570064 0.39051 -0.559607 0.383472 0 0 0 0.00281905 l
+-0.116534 0.868642 -0.10472 0.887291 0 0 0 0.00281905 l
+-0.116534 0.868642 -0.123125 0.87351 0 0 0 0.00281905 l
+0.697066 -0.56754 0.722292 -0.558514 0 0 0 0.00281905 l
+0.697066 -0.56754 0.687008 -0.5805 0 0 0 0.00281905 l
+0.379369 -0.282828 0.378807 -0.285628 0 0 0 0.00281905 l
+0.379369 -0.282828 0.38586 -0.271413 0 0 0 0.00281905 l
+-0.0728107 -0.187824 -0.0754869 -0.178834 0 0 0 0.00281905 l
+-0.0728107 -0.187824 -0.0587006 -0.199017 0 0 0 0.00281905 l
+-0.160899 -0.436902 -0.164083 -0.431341 0 0 0 0.00281905 l
+-0.30212 -0.867791 -0.304193 -0.87692 0 0 0 0.00281905 l
+-0.30212 -0.867791 -0.323036 -0.865246 0 0 0 0.00281905 l
+-0.0920071 -0.498506 -0.0926513 -0.513891 0 0 0 0.00281905 l
+-0.0920071 -0.498506 -0.0839072 -0.491322 0 0 0 0.00281905 l
+0.231955 -0.725177 0.240494 -0.721937 0 0 0 0.00281905 l
+0.231955 -0.725177 0.222807 -0.728631 0 0 0 0.00281905 l
+0.674367 0.656167 0.669726 0.650478 0 0 0 0.00281905 l
+-0.72131 0.620969 -0.715659 0.606144 0 0 0 0.00281905 l
+-0.72131 0.620969 -0.715108 0.62595 0 0 0 0.00281905 l
+-0.403772 -0.332374 -0.399406 -0.321599 0 0 0 0.00281905 l
+-0.403772 -0.332374 -0.388365 -0.334585 0 0 0 0.00281905 l
+-0.563257 -0.513133 -0.563535 -0.504797 0 0 0 0.00281905 l
+-0.491528 -0.139759 -0.490691 -0.126787 0 0 0 0.00281905 l
+-0.444528 -0.408589 -0.432204 -0.395143 0 0 0 0.00281905 l
+-0.444528 -0.408589 -0.437845 -0.413323 0 0 0 0.00281905 l
+-0.444528 -0.408589 -0.464992 -0.4096 0 0 0 0.00281905 l
+0.631508 -0.306909 0.634788 -0.304008 0 0 0 0.00281905 l
+0.631508 -0.306909 0.626423 -0.304997 0 0 0 0.00281905 l
+-0.126729 0.319218 -0.126637 0.315117 0 0 0 0.00281905 l
+-0.126729 0.319218 -0.132032 0.336291 0 0 0 0.00281905 l
+-0.676879 -0.404281 -0.6779 -0.41723 0 0 0 0.00281905 l
+-0.676879 -0.404281 -0.677682 -0.393258 0 0 0 0.00281905 l
+-0.676879 -0.404281 -0.644222 -0.404742 0 0 0 0.00281905 l
+-0.32059 -0.542515 -0.323072 -0.520565 0 0 0 0.00281905 l
+0.499573 -0.60715 0.494487 -0.598377 0 0 0 0.00281905 l
+0.769019 -0.292896 0.780243 -0.277186 0 0 0 0.00281905 l
+0.769019 -0.292896 0.752969 -0.301095 0 0 0 0.00281905 l
+0.256996 0.393832 0.259669 0.379751 0 0 0 0.00281905 l
+0.256996 0.393832 0.251837 0.396132 0 0 0 0.00281905 l
+-0.0391124 -0.36198 -0.0357231 -0.348234 0 0 0 0.00281905 l
+-0.0391124 -0.36198 -0.0526697 -0.370319 0 0 0 0.00281905 l
+-0.757594 -0.0995753 -0.750203 -0.104803 0 0 0 0.00281905 l
+-0.56409 0.708192 -0.552534 0.726928 0 0 0 0.00281905 l
+0.460075 -0.734536 0.460335 -0.724432 0 0 0 0.00281905 l
+-0.573186 0.223237 -0.577285 0.233712 0 0 0 0.00281905 l
+-0.573186 0.223237 -0.564791 0.213055 0 0 0 0.00281905 l
+-0.74407 0.194201 -0.747825 0.191689 0 0 0 0.00281905 l
+0.636845 -0.360033 0.632859 -0.353386 0 0 0 0.00281905 l
+-0.667667 -0.103029 -0.66911 -0.0963429 0 0 0 0.00281905 l
+-0.667667 -0.103029 -0.658754 -0.11134 0 0 0 0.00281905 l
+-0.667667 -0.103029 -0.671022 -0.104024 0 0 0 0.00281905 l
+0.814569 0.394969 0.825101 0.377348 0 0 0 0.00281905 l
+0.814569 0.394969 0.80871 0.401057 0 0 0 0.00281905 l
+0.486304 -0.273548 0.480452 -0.279308 0 0 0 0.00281905 l
+0.897424 0.367471 0.899545 0.354165 0 0 0 0.00281905 l
+0.897424 0.367471 0.902803 0.368127 0 0 0 0.00281905 l
+0.897424 0.367471 0.895049 0.370642 0 0 0 0.00281905 l
+0.902076 -0.0868506 0.897754 -0.0982184 0 0 0 0.00281905 l
+0.902076 -0.0868506 0.899006 -0.0819796 0 0 0 0.00281905 l
+0.127978 0.930869 0.12967 0.934646 0 0 0 0.00281905 l
+0.127978 0.930869 0.115106 0.93647 0 0 0 0.00281905 l
+-0.0513802 0.153568 -0.0497604 0.14437 0 0 0 0.00281905 l
+-0.0513802 0.153568 -0.0520973 0.153967 0 0 0 0.00281905 l
+-0.662675 0.0858618 -0.652512 0.0724993 0 0 0 0.00281905 l
+-0.662675 0.0858618 -0.660292 0.0918183 0 0 0 0.00281905 l
+-0.662675 0.0858618 -0.675417 0.089733 0 0 0 0.00281905 l
+0.404587 0.220644 0.419142 0.228451 0 0 0 0.00281905 l
+0.404587 0.220644 0.394469 0.223674 0 0 0 0.00281905 l
+-0.645524 -0.718283 -0.63888 -0.718126 0 0 0 0.00281905 l
+-0.645524 -0.718283 -0.649426 -0.718211 0 0 0 0.00281905 l
+-0.26136 -0.715457 -0.256112 -0.705305 0 0 0 0.00281905 l
+-0.26136 -0.715457 -0.272551 -0.714139 0 0 0 0.00281905 l
+0.397213 -0.687802 0.411046 -0.705462 0 0 0 0.00281905 l
+0.397213 -0.687802 0.398744 -0.674047 0 0 0 0.00281905 l
+0.397213 -0.687802 0.37792 -0.679004 0 0 0 0.00281905 l
+-0.719223 0.195549 -0.717905 0.202244 0 0 0 0.00281905 l
+-0.719223 0.195549 -0.70419 0.188485 0 0 0 0.00281905 l
+0.598241 0.482617 0.604392 0.472019 0 0 0 0.00281905 l
+0.598241 0.482617 0.595681 0.486023 0 0 0 0.00281905 l
+-0.463259 0.522595 -0.453386 0.535503 0 0 0 0.00281905 l
+-0.463259 0.522595 -0.446904 0.510684 0 0 0 0.00281905 l
+0.885006 0.299053 0.879312 0.313061 0 0 0 0.00281905 l
+-0.456625 0.443075 -0.45535 0.436524 0 0 0 0.00281905 l
+0.287347 -0.490159 0.293338 -0.504579 0 0 0 0.00281905 l
+0.287347 -0.490159 0.294641 -0.486899 0 0 0 0.00281905 l
+0.287347 -0.490159 0.28292 -0.490126 0 0 0 0.00281905 l
+0.58943 0.748446 0.592698 0.738297 0 0 0 0.00281905 l
+0.58943 0.748446 0.579712 0.753556 0 0 0 0.00281905 l
+0.831295 -0.369322 0.845802 -0.374842 0 0 0 0.00281905 l
+0.831295 -0.369322 0.826166 -0.372423 0 0 0 0.00281905 l
+0.608459 -0.774204 0.618108 -0.769053 0 0 0 0.00281905 l
+0.608459 -0.774204 0.605977 -0.768461 0 0 0 0.00281905 l
+0.608459 -0.774204 0.599659 -0.776516 0 0 0 0.00281905 l
+0.431271 -0.306552 0.43207 -0.301807 0 0 0 0.00281905 l
+-0.401354 -0.868161 -0.405356 -0.873188 0 0 0 0.00281905 l
+0.386292 0.431838 0.392899 0.428666 0 0 0 0.00281905 l
+0.674131 0.181231 0.666081 0.191083 0 0 0 0.00281905 l
+0.674131 0.181231 0.682151 0.176683 0 0 0 0.00281905 l
+0.674131 0.181231 0.664886 0.175773 0 0 0 0.00281905 l
+0.303633 0.7054 0.286838 0.718016 0 0 0 0.00281905 l
+0.303633 0.7054 0.30739 0.705442 0 0 0 0.00281905 l
+0.482886 -0.8145 0.490211 -0.812176 0 0 0 0.00281905 l
+0.482886 -0.8145 0.478424 -0.80953 0 0 0 0.00281905 l
+-0.283111 -0.418102 -0.282486 -0.423494 0 0 0 0.00281905 l
+-0.283111 -0.418102 -0.27534 -0.413175 0 0 0 0.00281905 l
+-0.283111 -0.418102 -0.289494 -0.420576 0 0 0 0.00281905 l
+-0.577883 -0.617961 -0.564224 -0.621774 0 0 0 0.00281905 l
+-0.577883 -0.617961 -0.581146 -0.610277 0 0 0 0.00281905 l
+-0.632117 0.129658 -0.622426 0.127501 0 0 0 0.00281905 l
+-0.632117 0.129658 -0.643641 0.12767 0 0 0 0.00281905 l
+0.647748 -0.0480882 0.658796 -0.0585182 0 0 0 0.00281905 l
+0.647748 -0.0480882 0.660929 -0.0380969 0 0 0 0.00281905 l
+0.647748 -0.0480882 0.641367 -0.0483088 0 0 0 0.00281905 l
+-0.60068 -0.343051 -0.605813 -0.340133 0 0 0 0.00281905 l
+0.295567 -0.597501 0.308744 -0.607633 0 0 0 0.00281905 l
+0.295567 -0.597501 0.306761 -0.587732 0 0 0 0.00281905 l
+0.295567 -0.597501 0.287032 -0.600744 0 0 0 0.00281905 l
+0.302097 -0.790754 0.308855 -0.79448 0 0 0 0.00281905 l
+0.302097 -0.790754 0.297746 -0.789076 0 0 0 0.00281905 l
+-0.305185 -0.257339 -0.311762 -0.251364 0 0 0 0.00281905 l
+-0.305185 -0.257339 -0.295501 -0.257967 0 0 0 0.00281905 l
+-0.305185 -0.257339 -0.312223 -0.263176 0 0 0 0.00281905 l
+0.318145 -0.172307 0.321376 -0.186399 0 0 0 0.00281905 l
+0.318145 -0.172307 0.300194 -0.182789 0 0 0 0.00281905 l
+0.672315 0.283038 0.672813 0.286904 0 0 0 0.00281905 l
+0.0662828 0.241346 0.0744193 0.238931 0 0 0 0.00281905 l
+0.0662828 0.241346 0.0609691 0.244968 0 0 0 0.00281905 l
+0.321377 0.796803 0.332547 0.806151 0 0 0 0.00281905 l
+0.321377 0.796803 0.316026 0.795371 0 0 0 0.00281905 l
+0.224107 0.249591 0.209964 0.270986 0 0 0 0.00281905 l
+0.224107 0.249591 0.23008 0.252358 0 0 0 0.00281905 l
+-0.303117 0.362094 -0.29496 0.343348 0 0 0 0.00281905 l
+-0.303117 0.362094 -0.296303 0.367325 0 0 0 0.00281905 l
+0.71174 0.0107665 0.720538 0.00547182 0 0 0 0.00281905 l
+0.71174 0.0107665 0.712419 0.0137765 0 0 0 0.00281905 l
+0.71174 0.0107665 0.696773 -0.00134317 0 0 0 0.00281905 l
+-0.0195168 -0.562029 -0.0192953 -0.556493 0 0 0 0.00281905 l
+-0.0195168 -0.562029 -0.0226209 -0.563191 0 0 0 0.00281905 l
+0.653338 0.0835046 0.669215 0.0807122 0 0 0 0.00281905 l
+0.653338 0.0835046 0.654161 0.0683734 0 0 0 0.00281905 l
+-0.186841 -0.749415 -0.177976 -0.729517 0 0 0 0.00281905 l
+-0.186841 -0.749415 -0.186073 -0.755861 0 0 0 0.00281905 l
+-0.207798 0.0764103 -0.207693 0.0786816 0 0 0 0.00281905 l
+-0.207798 0.0764103 -0.214708 0.0692997 0 0 0 0.00281905 l
+-0.438709 -0.119845 -0.438738 -0.112103 0 0 0 0.00281905 l
+-0.438709 -0.119845 -0.454936 -0.127128 0 0 0 0.00281905 l
+0.367285 -0.419998 0.362262 -0.410449 0 0 0 0.00281905 l
+-0.557956 0.799333 -0.544116 0.795363 0 0 0 0.00281905 l
+-0.557956 0.799333 -0.573225 0.798797 0 0 0 0.00281905 l
+-0.264827 0.870312 -0.276084 0.849664 0 0 0 0.00281905 l
+-0.264827 0.870312 -0.271482 0.879961 0 0 0 0.00281905 l
+0.523677 0.325968 0.538833 0.321194 0 0 0 0.00281905 l
+0.523677 0.325968 0.518688 0.313002 0 0 0 0.00281905 l
+0.523677 0.325968 0.530775 0.335462 0 0 0 0.00281905 l
+0.523677 0.325968 0.50989 0.330449 0 0 0 0.00281905 l
+0.731073 0.249853 0.739902 0.240474 0 0 0 0.00281905 l
+-0.0779103 0.708051 -0.0816758 0.693981 0 0 0 0.00281905 l
+-0.0779103 0.708051 -0.0714956 0.714867 0 0 0 0.00281905 l
+0.942383 0.301691 0.951333 0.293476 0 0 0 0.00281905 l
+0.942383 0.301691 0.947116 0.309452 0 0 0 0.00281905 l
+0.877534 -0.229596 0.895225 -0.218053 0 0 0 0.00281905 l
+-0.453276 0.228675 -0.454811 0.21712 0 0 0 0.00281905 l
+-0.453276 0.228675 -0.454904 0.232475 0 0 0 0.00281905 l
+-0.493652 -0.22274 -0.487075 -0.208759 0 0 0 0.00281905 l
+-0.493652 -0.22274 -0.478205 -0.227729 0 0 0 0.00281905 l
+-0.493652 -0.22274 -0.504623 -0.227988 0 0 0 0.00281905 l
+-0.717712 -0.30646 -0.718877 -0.300972 0 0 0 0.00281905 l
+0.303442 -0.139304 0.29566 -0.143389 0 0 0 0.00281905 l
+0.303442 -0.139304 0.304676 -0.135559 0 0 0 0.00281905 l
+-0.191584 0.379903 -0.189287 0.381563 0 0 0 0.00281905 l
+-0.191584 0.379903 -0.196299 0.376307 0 0 0 0.00281905 l
+0.399741 -0.536612 0.398519 -0.517217 0 0 0 0.00281905 l
+0.399741 -0.536612 0.405923 -0.549714 0 0 0 0.00281905 l
+0.399741 -0.536612 0.38145 -0.536894 0 0 0 0.00281905 l
+-0.0436304 0.0340249 -0.0383389 0.0423419 0 0 0 0.00281905 l
+-0.0436304 0.0340249 -0.0412447 0.026252 0 0 0 0.00281905 l
+-0.0436304 0.0340249 -0.0534172 0.0432871 0 0 0 0.00281905 l
+-0.185794 -0.00925174 -0.195541 0.00593465 0 0 0 0.00281905 l
+-0.185794 -0.00925174 -0.17065 -0.0122453 0 0 0 0.00281905 l
+-0.185794 -0.00925174 -0.192509 -0.0216451 0 0 0 0.00281905 l
+-0.138398 0.588028 -0.128345 0.604697 0 0 0 0.00281905 l
+-0.138398 0.588028 -0.151023 0.601076 0 0 0 0.00281905 l
+-0.350996 0.642759 -0.335392 0.638029 0 0 0 0.00281905 l
+-0.350996 0.642759 -0.352482 0.62545 0 0 0 0.00281905 l
+-0.350996 0.642759 -0.354134 0.649266 0 0 0 0.00281905 l
+0.472804 -0.767584 0.463393 -0.771715 0 0 0 0.00281905 l
+0.472804 -0.767584 0.474232 -0.764566 0 0 0 0.00281905 l
+0.460012 0.593099 0.460466 0.588842 0 0 0 0.00281905 l
+0.460012 0.593099 0.454214 0.606857 0 0 0 0.00281905 l
+0.460012 0.593099 0.471711 0.598913 0 0 0 0.00281905 l
+-0.256641 -0.138508 -0.249328 -0.151979 0 0 0 0.00281905 l
+-0.256641 -0.138508 -0.248304 -0.126027 0 0 0 0.00281905 l
+-0.256641 -0.138508 -0.263504 -0.132154 0 0 0 0.00281905 l
+-0.211865 0.147343 -0.210432 0.160644 0 0 0 0.00281905 l
+-0.211865 0.147343 -0.219317 0.139526 0 0 0 0.00281905 l
+0.118823 -0.524215 0.119924 -0.515741 0 0 0 0.00281905 l
+0.118823 -0.524215 0.125492 -0.532709 0 0 0 0.00281905 l
+0.118823 -0.524215 0.107857 -0.531274 0 0 0 0.00281905 l
+-0.174727 0.0604758 -0.17249 0.0762203 0 0 0 0.00281905 l
+-0.174727 0.0604758 -0.187308 0.0520719 0 0 0 0.00281905 l
+0.0267661 0.489648 0.0238336 0.480065 0 0 0 0.00281905 l
+-0.549737 -0.182691 -0.538273 -0.187557 0 0 0 0.00281905 l
+-0.549737 -0.182691 -0.55556 -0.198653 0 0 0 0.00281905 l
+-0.638889 0.420557 -0.634485 0.430165 0 0 0 0.00281905 l
+-0.638889 0.420557 -0.641166 0.414921 0 0 0 0.00281905 l
+-0.961954 -0.0711963 -0.948799 -0.0760186 0 0 0 0.00281905 l
+-0.961954 -0.0711963 -0.971278 -0.0589315 0 0 0 0.00281905 l
+-0.624878 0.609407 -0.635834 0.600135 0 0 0 0.00281905 l
+-0.624878 0.609407 -0.621358 0.613082 0 0 0 0.00281905 l
+-0.479225 -0.514594 -0.484935 -0.495707 0 0 0 0.00281905 l
+-0.479225 -0.514594 -0.481176 -0.518128 0 0 0 0.00281905 l
+0.040773 -0.0167496 0.033004 -0.00871693 0 0 0 0.00281905 l
+-0.213792 -0.0177131 -0.215549 -0.00875762 0 0 0 0.00281905 l
+-0.213792 -0.0177131 -0.216569 -0.0206235 0 0 0 0.00281905 l
+-0.78696 -0.203352 -0.791309 -0.189634 0 0 0 0.00281905 l
+-0.78696 -0.203352 -0.776064 -0.200375 0 0 0 0.00281905 l
+-0.78696 -0.203352 -0.797881 -0.206795 0 0 0 0.00281905 l
+0.936474 -0.15145 0.931906 -0.132025 0 0 0 0.00281905 l
+0.936474 -0.15145 0.933112 -0.160806 0 0 0 0.00281905 l
+0.414858 0.0119261 0.42681 0.0172097 0 0 0 0.00281905 l
+0.414858 0.0119261 0.408885 0.0119266 0 0 0 0.00281905 l
+-0.638583 0.465598 -0.62441 0.460472 0 0 0 0.00281905 l
+-0.638583 0.465598 -0.639116 0.451397 0 0 0 0.00281905 l
+-0.638583 0.465598 -0.652911 0.469762 0 0 0 0.00281905 l
+0.586557 0.16771 0.600608 0.168744 0 0 0 0.00281905 l
+0.586557 0.16771 0.578102 0.164425 0 0 0 0.00281905 l
+-0.617783 -0.519125 -0.606868 -0.52957 0 0 0 0.00281905 l
+-0.617783 -0.519125 -0.624586 -0.516549 0 0 0 0.00281905 l
+-0.617783 -0.519125 -0.614966 -0.516162 0 0 0 0.00281905 l
+0.226722 -0.308196 0.225058 -0.299026 0 0 0 0.00281905 l
+0.226722 -0.308196 0.23886 -0.305276 0 0 0 0.00281905 l
+0.226722 -0.308196 0.221328 -0.314392 0 0 0 0.00281905 l
+-0.242976 -0.80338 -0.258168 -0.807946 0 0 0 0.00281905 l
+-0.37702 0.138379 -0.377459 0.133404 0 0 0 0.00281905 l
+-0.37702 0.138379 -0.372484 0.140811 0 0 0 0.00281905 l
+-0.37702 0.138379 -0.390638 0.13884 0 0 0 0.00281905 l
+-0.347436 0.284804 -0.35061 0.273894 0 0 0 0.00281905 l
+-0.347436 0.284804 -0.355602 0.285015 0 0 0 0.00281905 l
+0.602278 0.52919 0.617599 0.525632 0 0 0 0.00281905 l
+0.602278 0.52919 0.594617 0.535582 0 0 0 0.00281905 l
+0.674716 -0.594216 0.681319 -0.589522 0 0 0 0.00281905 l
+-0.118986 -0.782435 -0.121946 -0.793189 0 0 0 0.00281905 l
+-0.118986 -0.782435 -0.136718 -0.770993 0 0 0 0.00281905 l
+0.0575837 -0.369061 0.0664777 -0.385546 0 0 0 0.00281905 l
+0.0575837 -0.369061 0.0672503 -0.352912 0 0 0 0.00281905 l
+0.0575837 -0.369061 0.0484154 -0.367749 0 0 0 0.00281905 l
+0.587043 0.337787 0.605067 0.329911 0 0 0 0.00281905 l
+0.587043 0.337787 0.583453 0.345888 0 0 0 0.00281905 l
+0.587043 0.337787 0.583939 0.329436 0 0 0 0.00281905 l
+-0.516198 0.779151 -0.501274 0.771769 0 0 0 0.00281905 l
+-0.516198 0.779151 -0.50464 0.79113 0 0 0 0.00281905 l
+-0.516198 0.779151 -0.518697 0.777387 0 0 0 0.00281905 l
+0.0142014 -0.568721 0.00183302 -0.554468 0 0 0 0.00281905 l
+0.0142014 -0.568721 0.0291117 -0.570709 0 0 0 0.00281905 l
+-0.202719 -0.703829 -0.191776 -0.708298 0 0 0 0.00281905 l
+0.673576 -0.0102288 0.682803 -0.028462 0 0 0 0.00281905 l
+0.673576 -0.0102288 0.660968 -0.00533011 0 0 0 0.00281905 l
+0.895225 -0.218053 0.899947 -0.243244 0 0 0 0.00281905 l
+0.895225 -0.218053 0.877534 -0.229596 0 0 0 0.00281905 l
+-0.754446 0.516698 -0.748832 0.519166 0 0 0 0.00281905 l
+-0.754446 0.516698 -0.754689 0.513381 0 0 0 0.00281905 l
+0.845329 -0.41322 0.839619 -0.428109 0 0 0 0.00281905 l
+0.845329 -0.41322 0.864499 -0.40857 0 0 0 0.00281905 l
+0.845329 -0.41322 0.835719 -0.412359 0 0 0 0.00281905 l
+0.704265 -0.449806 0.703625 -0.455725 0 0 0 0.00281905 l
+0.704265 -0.449806 0.709487 -0.444744 0 0 0 0.00281905 l
+-0.314982 0.922324 -0.322426 0.913333 0 0 0 0.00281905 l
+-0.314982 0.922324 -0.305799 0.925253 0 0 0 0.00281905 l
+-0.314982 0.922324 -0.322975 0.928799 0 0 0 0.00281905 l
+0.928193 -0.023734 0.932883 -0.0293105 0 0 0 0.00281905 l
+-0.569313 0.319482 -0.56345 0.337304 0 0 0 0.00281905 l
+-0.569313 0.319482 -0.558049 0.31138 0 0 0 0.00281905 l
+0.439904 0.0649067 0.4437 0.063868 0 0 0 0.00281905 l
+0.439904 0.0649067 0.434952 0.0605132 0 0 0 0.00281905 l
+0.439904 0.0649067 0.43693 0.0690557 0 0 0 0.00281905 l
+0.0423469 0.305498 0.0423077 0.307247 0 0 0 0.00281905 l
+0.0423469 0.305498 0.0451443 0.294238 0 0 0 0.00281905 l
+0.802363 0.432831 0.822256 0.444326 0 0 0 0.00281905 l
+0.802363 0.432831 0.785613 0.429127 0 0 0 0.00281905 l
+-0.046732 -0.51134 -0.0442657 -0.510682 0 0 0 0.00281905 l
+0.0542529 0.998141 0.0344408 0.990338 0 0 0 0.00281905 l
+-0.249009 -0.294645 -0.25749 -0.283666 0 0 0 0.00281905 l
+-0.504274 0.137483 -0.488199 0.12868 0 0 0 0.00281905 l
+-0.504274 0.137483 -0.516558 0.137046 0 0 0 0.00281905 l
+-0.180647 0.402719 -0.168937 0.395541 0 0 0 0.00281905 l
+-0.180647 0.402719 -0.18994 0.400256 0 0 0 0.00281905 l
+-0.159931 -0.520859 -0.160028 -0.515332 0 0 0 0.00281905 l
+-0.159931 -0.520859 -0.164553 -0.5233 0 0 0 0.00281905 l
+0.538773 0.109002 0.550901 0.113589 0 0 0 0.00281905 l
+0.538773 0.109002 0.534043 0.102583 0 0 0 0.00281905 l
+0.784185 -0.319614 0.795263 -0.330564 0 0 0 0.00281905 l
+0.751109 0.623912 0.76109 0.621136 0 0 0 0.00281905 l
+0.751109 0.623912 0.745217 0.620205 0 0 0 0.00281905 l
+-0.969187 0.0641001 -0.952389 0.0570659 0 0 0 0.00281905 l
+-0.969187 0.0641001 -0.972589 0.0717203 0 0 0 0.00281905 l
+0.411686 0.893445 0.412386 0.887802 0 0 0 0.00281905 l
+0.785 -0.261975 0.799161 -0.262697 0 0 0 0.00281905 l
+0.785 -0.261975 0.780243 -0.277186 0 0 0 0.00281905 l
+0.785 -0.261975 0.7771 -0.255417 0 0 0 0.00281905 l
+0.17922 0.553693 0.172611 0.541617 0 0 0 0.00281905 l
+-0.42633 0.520648 -0.415057 0.513862 0 0 0 0.00281905 l
+-0.42633 0.520648 -0.438136 0.531604 0 0 0 0.00281905 l
+-0.0872682 0.891965 -0.0882687 0.900209 0 0 0 0.00281905 l
+-0.0872682 0.891965 -0.0746222 0.889889 0 0 0 0.00281905 l
+-0.0872682 0.891965 -0.10472 0.887291 0 0 0 0.00281905 l
+0.250948 0.256017 0.256068 0.245263 0 0 0 0.00281905 l
+0.250948 0.256017 0.23008 0.252358 0 0 0 0.00281905 l
+0.250948 0.256017 0.25223 0.259482 0 0 0 0.00281905 l
+0.0778287 -0.765498 0.0811246 -0.761723 0 0 0 0.00281905 l
+0.0778287 -0.765498 0.0721154 -0.766253 0 0 0 0.00281905 l
+0.377683 0.556547 0.397009 0.571335 0 0 0 0.00281905 l
+-0.74723 -0.205892 -0.752358 -0.194502 0 0 0 0.00281905 l
+-0.74723 -0.205892 -0.746692 -0.205664 0 0 0 0.00281905 l
+-0.74723 -0.205892 -0.753655 -0.215878 0 0 0 0.00281905 l
+-0.625956 0.114994 -0.622426 0.127501 0 0 0 0.00281905 l
+-0.625956 0.114994 -0.616032 0.108037 0 0 0 0.00281905 l
+-0.671474 -0.257572 -0.672335 -0.264245 0 0 0 0.00281905 l
+-0.671474 -0.257572 -0.679056 -0.249337 0 0 0 0.00281905 l
+0.420444 0.880747 0.436344 0.889986 0 0 0 0.00281905 l
+0.420444 0.880747 0.417339 0.890331 0 0 0 0.00281905 l
+0.420444 0.880747 0.418283 0.879289 0 0 0 0.00281905 l
+0.360494 0.683981 0.367063 0.671708 0 0 0 0.00281905 l
+0.360494 0.683981 0.354162 0.691544 0 0 0 0.00281905 l
+-0.0194127 0.495305 -0.0100742 0.498498 0 0 0 0.00281905 l
+-0.0194127 0.495305 -0.0291717 0.506193 0 0 0 0.00281905 l
+-0.499013 -0.778098 -0.488131 -0.77713 0 0 0 0.00281905 l
+-0.499013 -0.778098 -0.492222 -0.794062 0 0 0 0.00281905 l
+-0.499013 -0.778098 -0.513339 -0.786419 0 0 0 0.00281905 l
+-0.215222 0.844214 -0.210598 0.860998 0 0 0 0.00281905 l
+-0.215222 0.844214 -0.223671 0.844436 0 0 0 0.00281905 l
+0.163448 -0.982041 0.160262 -0.976401 0 0 0 0.00281905 l
+-0.181315 0.752692 -0.19007 0.749104 0 0 0 0.00281905 l
+-0.516433 0.609629 -0.519691 0.62278 0 0 0 0.00281905 l
+-0.516433 0.609629 -0.513361 0.610013 0 0 0 0.00281905 l
+-0.584726 -0.263865 -0.602143 -0.261087 0 0 0 0.00281905 l
+0.617002 -0.372713 0.62448 -0.358885 0 0 0 0.00281905 l
+0.617002 -0.372713 0.599145 -0.376025 0 0 0 0.00281905 l
+0.439386 0.0171061 0.433343 0.0293802 0 0 0 0.00281905 l
+0.439386 0.0171061 0.449501 0.0224063 0 0 0 0.00281905 l
+0.439386 0.0171061 0.42681 0.0172097 0 0 0 0.00281905 l
+-0.12539 0.84493 -0.121686 0.854627 0 0 0 0.00281905 l
+-0.12539 0.84493 -0.132155 0.836678 0 0 0 0.00281905 l
+0.430781 0.815749 0.432988 0.815561 0 0 0 0.00281905 l
+0.430781 0.815749 0.429826 0.813689 0 0 0 0.00281905 l
+-0.28957 -0.634711 -0.28835 -0.634423 0 0 0 0.00281905 l
+-0.28957 -0.634711 -0.294257 -0.643241 0 0 0 0.00281905 l
+0.436344 0.889986 0.448512 0.872929 0 0 0 0.00281905 l
+0.436344 0.889986 0.420444 0.880747 0 0 0 0.00281905 l
+-0.550086 -0.450519 -0.547357 -0.456984 0 0 0 0.00281905 l
+-0.550086 -0.450519 -0.555229 -0.442267 0 0 0 0.00281905 l
+-0.925727 0.0975071 -0.92735 0.0899559 0 0 0 0.00281905 l
+0.00534676 0.85889 0.00507685 0.850444 0 0 0 0.00281905 l
+0.00534676 0.85889 0.0135843 0.861926 0 0 0 0.00281905 l
+0.215019 -0.775333 0.225389 -0.785862 0 0 0 0.00281905 l
+0.215019 -0.775333 0.206869 -0.78484 0 0 0 0.00281905 l
+-0.0678524 -0.95579 -0.0598951 -0.939492 0 0 0 0.00281905 l
+0.450259 -0.853663 0.456529 -0.861739 0 0 0 0.00281905 l
+0.450259 -0.853663 0.445981 -0.845682 0 0 0 0.00281905 l
+0.243925 0.728833 0.242412 0.737554 0 0 0 0.00281905 l
+0.243925 0.728833 0.251334 0.73339 0 0 0 0.00281905 l
+0.243925 0.728833 0.226267 0.727965 0 0 0 0.00281905 l
+0.62183 0.257514 0.617011 0.280696 0 0 0 0.00281905 l
+0.62183 0.257514 0.6158 0.253786 0 0 0 0.00281905 l
+0.374876 0.781573 0.358801 0.783147 0 0 0 0.00281905 l
+0.374876 0.781573 0.37556 0.784279 0 0 0 0.00281905 l
+0.195074 -0.441352 0.202087 -0.440659 0 0 0 0.00281905 l
+0.195074 -0.441352 0.186391 -0.443552 0 0 0 0.00281905 l
+0.847223 -0.222129 0.831115 -0.229786 0 0 0 0.00281905 l
+-0.166524 -0.590449 -0.179368 -0.578001 0 0 0 0.00281905 l
+0.743399 -0.237981 0.756201 -0.231063 0 0 0 0.00281905 l
+0.743399 -0.237981 0.73303 -0.235769 0 0 0 0.00281905 l
+0.633263 0.676793 0.641966 0.670411 0 0 0 0.00281905 l
+0.633263 0.676793 0.624336 0.680053 0 0 0 0.00281905 l
+0.842953 -0.0767061 0.844208 -0.0674382 0 0 0 0.00281905 l
+0.842953 -0.0767061 0.844266 -0.0844103 0 0 0 0.00281905 l
+0.244565 -0.683838 0.255973 -0.682443 0 0 0 0.00281905 l
+0.244565 -0.683838 0.227024 -0.673796 0 0 0 0.00281905 l
+0.251407 -0.561303 0.255642 -0.569986 0 0 0 0.00281905 l
+0.251407 -0.561303 0.245675 -0.565972 0 0 0 0.00281905 l
+-0.738618 -0.0501986 -0.743718 -0.0579772 0 0 0 0.00281905 l
+0.714341 0.373613 0.725933 0.368377 0 0 0 0.00281905 l
+0.714341 0.373613 0.709864 0.364895 0 0 0 0.00281905 l
+0.714341 0.373613 0.710458 0.379504 0 0 0 0.00281905 l
+-0.299676 0.636399 -0.289573 0.621302 0 0 0 0.00281905 l
+-0.299676 0.636399 -0.297829 0.637914 0 0 0 0.00281905 l
+-0.299676 0.636399 -0.314054 0.640657 0 0 0 0.00281905 l
+-0.56582 0.631636 -0.564297 0.641201 0 0 0 0.00281905 l
+-0.56582 0.631636 -0.562737 0.628839 0 0 0 0.00281905 l
+-0.56582 0.631636 -0.571028 0.625922 0 0 0 0.00281905 l
+-0.543527 -0.810187 -0.53066 -0.818327 0 0 0 0.00281905 l
+-0.543527 -0.810187 -0.551107 -0.805855 0 0 0 0.00281905 l
+0.4577 0.778656 0.466878 0.77483 0 0 0 0.00281905 l
+-0.174751 -0.228894 -0.177367 -0.232214 0 0 0 0.00281905 l
+-0.223265 -0.306723 -0.215101 -0.321994 0 0 0 0.00281905 l
+-0.223265 -0.306723 -0.231458 -0.3115 0 0 0 0.00281905 l
+-0.151604 -0.812524 -0.150786 -0.805208 0 0 0 0.00281905 l
+-0.151604 -0.812524 -0.144677 -0.813505 0 0 0 0.00281905 l
+0.241869 -0.387625 0.241582 -0.402305 0 0 0 0.00281905 l
+0.241869 -0.387625 0.249746 -0.380614 0 0 0 0.00281905 l
+0.167618 0.0176222 0.180986 0.0161231 0 0 0 0.00281905 l
+0.167618 0.0176222 0.163718 0.0233704 0 0 0 0.00281905 l
+-0.423494 0.330223 -0.416046 0.319593 0 0 0 0.00281905 l
+-0.423494 0.330223 -0.418306 0.347183 0 0 0 0.00281905 l
+-0.423494 0.330223 -0.434929 0.325732 0 0 0 0.00281905 l
+-0.388365 -0.334585 -0.403772 -0.332374 0 0 0 0.00281905 l
+-0.615468 0.0660999 -0.634662 0.0649219 0 0 0 0.00281905 l
+0.0465905 -0.397044 0.0475204 -0.380985 0 0 0 0.00281905 l
+0.0986654 0.836064 0.105597 0.825622 0 0 0 0.00281905 l
+0.0986654 0.836064 0.0967379 0.843532 0 0 0 0.00281905 l
+0.0986654 0.836064 0.084802 0.835411 0 0 0 0.00281905 l
+-0.580256 0.531829 -0.573486 0.531042 0 0 0 0.00281905 l
+-0.580256 0.531829 -0.595584 0.540501 0 0 0 0.00281905 l
+-0.57727 -0.541351 -0.57318 -0.527562 0 0 0 0.00281905 l
+-0.57727 -0.541351 -0.563969 -0.54973 0 0 0 0.00281905 l
+-0.817167 -0.128315 -0.80846 -0.137194 0 0 0 0.00281905 l
+-0.817167 -0.128315 -0.823907 -0.122007 0 0 0 0.00281905 l
+-0.0149834 -0.722587 -0.0107231 -0.718546 0 0 0 0.00281905 l
+0.542822 -0.550505 0.55339 -0.553772 0 0 0 0.00281905 l
+0.542822 -0.550505 0.532279 -0.537445 0 0 0 0.00281905 l
+-0.43552 0.483817 -0.436385 0.500343 0 0 0 0.00281905 l
+-0.43552 0.483817 -0.43363 0.481924 0 0 0 0.00281905 l
+-0.312194 0.870612 -0.305265 0.875124 0 0 0 0.00281905 l
+-0.312194 0.870612 -0.333609 0.874333 0 0 0 0.00281905 l
+-0.463205 0.602987 -0.477554 0.611506 0 0 0 0.00281905 l
+-0.768256 -0.362282 -0.772194 -0.347793 0 0 0 0.00281905 l
+0.558629 0.61645 0.558828 0.616573 0 0 0 0.00281905 l
+0.402084 -0.0455968 0.400747 -0.033372 0 0 0 0.00281905 l
+-0.948207 0.0760728 -0.947806 0.0802568 0 0 0 0.00281905 l
+-0.948207 0.0760728 -0.939513 0.0720851 0 0 0 0.00281905 l
+0.420483 0.843894 0.423059 0.845086 0 0 0 0.00281905 l
+0.8813 -0.35806 0.890066 -0.361856 0 0 0 0.00281905 l
+0.0981172 -0.61339 0.10203 -0.630979 0 0 0 0.00281905 l
+0.0981172 -0.61339 0.0868846 -0.609052 0 0 0 0.00281905 l
+0.160481 0.247179 0.170905 0.244406 0 0 0 0.00281905 l
+0.160481 0.247179 0.153815 0.242217 0 0 0 0.00281905 l
+-0.663343 0.232292 -0.655397 0.23101 0 0 0 0.00281905 l
+-0.663343 0.232292 -0.661617 0.222625 0 0 0 0.00281905 l
+-0.663343 0.232292 -0.67587 0.234855 0 0 0 0.00281905 l
+-0.175535 0.186114 -0.17991 0.178676 0 0 0 0.00281905 l
+-0.212782 0.286397 -0.193514 0.286711 0 0 0 0.00281905 l
+-0.524959 -0.702304 -0.516147 -0.710064 0 0 0 0.00281905 l
+-0.524959 -0.702304 -0.538745 -0.703241 0 0 0 0.00281905 l
+0.863235 0.354437 0.876485 0.356104 0 0 0 0.00281905 l
+-0.240901 -0.385646 -0.244465 -0.374376 0 0 0 0.00281905 l
+-0.240901 -0.385646 -0.246747 -0.401638 0 0 0 0.00281905 l
+0.428101 0.0498465 0.434952 0.0605132 0 0 0 0.00281905 l
+0.428101 0.0498465 0.421202 0.0555981 0 0 0 0.00281905 l
+-0.103724 -0.914929 -0.106834 -0.924701 0 0 0 0.00281905 l
+-0.103724 -0.914929 -0.117226 -0.915239 0 0 0 0.00281905 l
+-0.562868 -0.146255 -0.563199 -0.143348 0 0 0 0.00281905 l
+-0.562868 -0.146255 -0.574096 -0.158554 0 0 0 0.00281905 l
+0.162638 0.648375 0.15019 0.64532 0 0 0 0.00281905 l
+-0.715108 0.62595 -0.716756 0.631178 0 0 0 0.00281905 l
+-0.715108 0.62595 -0.72131 0.620969 0 0 0 0.00281905 l
+-0.488312 -0.808276 -0.482099 -0.798337 0 0 0 0.00281905 l
+-0.488312 -0.808276 -0.478492 -0.814989 0 0 0 0.00281905 l
+-0.381979 0.731105 -0.370791 0.734116 0 0 0 0.00281905 l
+-0.381979 0.731105 -0.397928 0.721963 0 0 0 0.00281905 l
+-0.669518 -0.0444978 -0.677442 -0.0428734 0 0 0 0.00281905 l
+-0.166782 0.141561 -0.168457 0.133617 0 0 0 0.00281905 l
+-0.166782 0.141561 -0.156137 0.148232 0 0 0 0.00281905 l
+-0.166782 0.141561 -0.172039 0.149231 0 0 0 0.00281905 l
+0.291693 -0.272141 0.292119 -0.272692 0 0 0 0.00281905 l
+0.291693 -0.272141 0.285125 -0.275222 0 0 0 0.00281905 l
+0.191317 -0.268373 0.20098 -0.276787 0 0 0 0.00281905 l
+0.191317 -0.268373 0.180118 -0.256613 0 0 0 0.00281905 l
+0.191317 -0.268373 0.178043 -0.278777 0 0 0 0.00281905 l
+-0.203861 -0.222435 -0.205614 -0.214678 0 0 0 0.00281905 l
+-0.203861 -0.222435 -0.208554 -0.238499 0 0 0 0.00281905 l
+-0.789726 -0.426538 -0.783027 -0.420782 0 0 0 0.00281905 l
+0.519092 -0.08444 0.527264 -0.0945232 0 0 0 0.00281905 l
+0.519092 -0.08444 0.509356 -0.0980577 0 0 0 0.00281905 l
+0.519092 -0.08444 0.511616 -0.0734819 0 0 0 0.00281905 l
+0.599104 -0.00747451 0.593092 -0.0148311 0 0 0 0.00281905 l
+-0.0587006 -0.199017 -0.0498239 -0.208133 0 0 0 0.00281905 l
+-0.0587006 -0.199017 -0.0728107 -0.187824 0 0 0 0.00281905 l
+0.737944 -0.138871 0.74081 -0.122235 0 0 0 0.00281905 l
+0.737944 -0.138871 0.744215 -0.148421 0 0 0 0.00281905 l
+0.107937 -0.992914 0.108423 -0.982607 0 0 0 0.00281905 l
+0.107937 -0.992914 0.0967169 -0.99261 0 0 0 0.00281905 l
+-0.062805 0.414003 -0.0563198 0.40555 0 0 0 0.00281905 l
+-0.062805 0.414003 -0.0541708 0.419667 0 0 0 0.00281905 l
+-0.062805 0.414003 -0.0720977 0.409534 0 0 0 0.00281905 l
+-0.062805 0.414003 -0.0675933 0.419112 0 0 0 0.00281905 l
+-0.159019 0.181149 -0.154413 0.196856 0 0 0 0.00281905 l
+-0.159019 0.181149 -0.168752 0.176348 0 0 0 0.00281905 l
+-0.0552108 -0.921283 -0.0476685 -0.931465 0 0 0 0.00281905 l
+-0.0552108 -0.921283 -0.0514841 -0.916103 0 0 0 0.00281905 l
+-0.0655355 0.246514 -0.0648853 0.255454 0 0 0 0.00281905 l
+-0.0655355 0.246514 -0.0636804 0.234933 0 0 0 0.00281905 l
+-0.497804 0.0319589 -0.480578 0.02679 0 0 0 0.00281905 l
+-0.497804 0.0319589 -0.509096 0.0327524 0 0 0 0.00281905 l
+0.857665 0.379156 0.864085 0.397894 0 0 0 0.00281905 l
+0.857665 0.379156 0.846915 0.383533 0 0 0 0.00281905 l
+0.761549 0.37395 0.77071 0.363158 0 0 0 0.00281905 l
+0.761549 0.37395 0.775387 0.380766 0 0 0 0.00281905 l
+0.761549 0.37395 0.748759 0.385939 0 0 0 0.00281905 l
+-0.0670468 0.496376 -0.0570988 0.487806 0 0 0 0.00281905 l
+-0.0670468 0.496376 -0.0540208 0.503602 0 0 0 0.00281905 l
+-0.0670468 0.496376 -0.0806514 0.493114 0 0 0 0.00281905 l
+-0.584958 0.102186 -0.582705 0.0914337 0 0 0 0.00281905 l
+-0.584958 0.102186 -0.589359 0.101348 0 0 0 0.00281905 l
+-0.076085 -0.276345 -0.0671279 -0.296162 0 0 0 0.00281905 l
+-0.076085 -0.276345 -0.0856975 -0.276819 0 0 0 0.00281905 l
+-0.296225 -0.616802 -0.290801 -0.618981 0 0 0 0.00281905 l
+-0.296225 -0.616802 -0.296925 -0.621286 0 0 0 0.00281905 l
+0.311985 -0.689507 0.328003 -0.704211 0 0 0 0.00281905 l
+0.311985 -0.689507 0.326144 -0.682206 0 0 0 0.00281905 l
+0.311985 -0.689507 0.309897 -0.691342 0 0 0 0.00281905 l
+-0.15774 -0.221402 -0.155523 -0.212985 0 0 0 0.00281905 l
+-0.15774 -0.221402 -0.151409 -0.228228 0 0 0 0.00281905 l
+0.187485 -0.565075 0.205715 -0.555007 0 0 0 0.00281905 l
+0.187485 -0.565075 0.177555 -0.566859 0 0 0 0.00281905 l
+-0.0722805 -0.156947 -0.0734321 -0.161026 0 0 0 0.00281905 l
+-0.367698 -0.499098 -0.350425 -0.492611 0 0 0 0.00281905 l
+-0.367698 -0.499098 -0.379646 -0.495271 0 0 0 0.00281905 l
+0.711514 0.656938 0.712108 0.666206 0 0 0 0.00281905 l
+0.711514 0.656938 0.719565 0.656266 0 0 0 0.00281905 l
+0.711514 0.656938 0.708712 0.656746 0 0 0 0.00281905 l
+-0.803693 0.554978 -0.817754 0.559246 0 0 0 0.00281905 l
+0.461841 0.370342 0.468742 0.363173 0 0 0 0.00281905 l
+0.461841 0.370342 0.449126 0.360789 0 0 0 0.00281905 l
+-0.566998 0.66675 -0.566473 0.664268 0 0 0 0.00281905 l
+-0.566998 0.66675 -0.582155 0.668321 0 0 0 0.00281905 l
+0.726358 0.226537 0.728188 0.232755 0 0 0 0.00281905 l
+0.728005 -0.0604436 0.723069 -0.0595435 0 0 0 0.00281905 l
+0.604392 0.472019 0.616921 0.471377 0 0 0 0.00281905 l
+0.604392 0.472019 0.598241 0.482617 0 0 0 0.00281905 l
+0.604392 0.472019 0.593964 0.468026 0 0 0 0.00281905 l
+-0.0194356 -0.44439 -0.0166209 -0.430136 0 0 0 0.00281905 l
+-0.0194356 -0.44439 -0.0230444 -0.44461 0 0 0 0.00281905 l
+-0.161513 -0.100653 -0.150765 -0.0946922 0 0 0 0.00281905 l
+0.453306 0.406275 0.440848 0.417584 0 0 0 0.00281905 l
+0.453306 0.406275 0.437661 0.40033 0 0 0 0.00281905 l
+-0.0891242 0.465045 -0.0895336 0.469141 0 0 0 0.00281905 l
+0.83887 0.278724 0.830794 0.277003 0 0 0 0.00281905 l
+0.625773 -0.208136 0.622471 -0.198466 0 0 0 0.00281905 l
+0.625773 -0.208136 0.62152 -0.210253 0 0 0 0.00281905 l
+0.779243 -0.173526 0.780185 -0.161666 0 0 0 0.00281905 l
+0.779243 -0.173526 0.778383 -0.174234 0 0 0 0.00281905 l
+-0.63148 -0.595981 -0.625565 -0.600683 0 0 0 0.00281905 l
+-0.63148 -0.595981 -0.634614 -0.598403 0 0 0 0.00281905 l
+-0.754689 0.513381 -0.754446 0.516698 0 0 0 0.00281905 l
+-0.754689 0.513381 -0.760542 0.50161 0 0 0 0.00281905 l
+-0.662069 0.182657 -0.667736 0.1809 0 0 0 0.00281905 l
+-0.889129 0.188042 -0.887455 0.192491 0 0 0 0.00281905 l
+-0.775745 -0.0644735 -0.779455 -0.0515826 0 0 0 0.00281905 l
+-0.775745 -0.0644735 -0.775189 -0.0704009 0 0 0 0.00281905 l
+0.624423 -0.0661264 0.623076 -0.0513411 0 0 0 0.00281905 l
+0.624423 -0.0661264 0.629366 -0.0795694 0 0 0 0.00281905 l
+0.624423 -0.0661264 0.613329 -0.0671899 0 0 0 0.00281905 l
+0.105633 0.104423 0.0993346 0.115471 0 0 0 0.00281905 l
+0.105633 0.104423 0.0958719 0.0968936 0 0 0 0.00281905 l
+-0.0441432 0.780852 -0.0334288 0.78246 0 0 0 0.00281905 l
+-0.0441432 0.780852 -0.0499802 0.779065 0 0 0 0.00281905 l
+0.240788 -0.754287 0.253907 -0.760727 0 0 0 0.00281905 l
+0.240788 -0.754287 0.237639 -0.75135 0 0 0 0.00281905 l
+-0.740271 -0.339693 -0.746498 -0.337325 0 0 0 0.00281905 l
+0.181347 0.10885 0.181837 0.111848 0 0 0 0.00281905 l
+-0.571891 -0.00366643 -0.5644 0.00387959 0 0 0 0.00281905 l
+-0.571891 -0.00366643 -0.571728 -0.0169238 0 0 0 0.00281905 l
+-0.657431 0.0461772 -0.651872 0.0437504 0 0 0 0.00281905 l
+-0.657431 0.0461772 -0.653729 0.0532402 0 0 0 0.00281905 l
+-0.657431 0.0461772 -0.671378 0.0382945 0 0 0 0.00281905 l
+-0.498813 0.116143 -0.495373 0.103805 0 0 0 0.00281905 l
+-0.498813 0.116143 -0.488199 0.12868 0 0 0 0.00281905 l
+-0.671022 -0.104024 -0.667667 -0.103029 0 0 0 0.00281905 l
+-0.671022 -0.104024 -0.675101 -0.106499 0 0 0 0.00281905 l
+0.545729 -0.378057 0.553961 -0.37671 0 0 0 0.00281905 l
+0.545729 -0.378057 0.541081 -0.372723 0 0 0 0.00281905 l
+0.690714 0.469409 0.698247 0.453898 0 0 0 0.00281905 l
+0.690714 0.469409 0.674133 0.473402 0 0 0 0.00281905 l
+-0.286652 -0.813124 -0.269505 -0.813911 0 0 0 0.00281905 l
+-0.709172 0.239374 -0.700949 0.225961 0 0 0 0.00281905 l
+-0.709172 0.239374 -0.724351 0.23411 0 0 0 0.00281905 l
+-0.709172 0.239374 -0.705853 0.246135 0 0 0 0.00281905 l
+0.917937 -0.0994198 0.930097 -0.0911542 0 0 0 0.00281905 l
+0.917937 -0.0994198 0.924565 -0.108377 0 0 0 0.00281905 l
+-0.708738 -0.386085 -0.698387 -0.377688 0 0 0 0.00281905 l
+-0.708738 -0.386085 -0.726036 -0.378856 0 0 0 0.00281905 l
+-0.624444 0.0912946 -0.622471 0.101655 0 0 0 0.00281905 l
+0.514249 -0.468975 0.512947 -0.476369 0 0 0 0.00281905 l
+0.514249 -0.468975 0.518363 -0.463744 0 0 0 0.00281905 l
+0.504243 -0.246813 0.498362 -0.236065 0 0 0 0.00281905 l
+-0.37358 -0.581713 -0.362016 -0.577581 0 0 0 0.00281905 l
+-0.37358 -0.581713 -0.376371 -0.585005 0 0 0 0.00281905 l
+-0.159142 0.506826 -0.176139 0.52653 0 0 0 0.00281905 l
+0.32809 -0.341895 0.330017 -0.338959 0 0 0 0.00281905 l
+-0.59182 -0.230628 -0.590307 -0.232581 0 0 0 0.00281905 l
+-0.59182 -0.230628 -0.609664 -0.221576 0 0 0 0.00281905 l
+0.475199 -0.349387 0.4886 -0.340108 0 0 0 0.00281905 l
+0.475199 -0.349387 0.46915 -0.339966 0 0 0 0.00281905 l
+-0.718877 -0.300972 -0.723254 -0.287022 0 0 0 0.00281905 l
+-0.718877 -0.300972 -0.710506 -0.295983 0 0 0 0.00281905 l
+-0.718877 -0.300972 -0.717712 -0.30646 0 0 0 0.00281905 l
+-0.512541 -0.0635361 -0.523972 -0.0527644 0 0 0 0.00281905 l
+0.75903 -0.469819 0.752599 -0.460121 0 0 0 0.00281905 l
+0.75903 -0.469819 0.766483 -0.463035 0 0 0 0.00281905 l
+-0.871007 0.233637 -0.865592 0.219871 0 0 0 0.00281905 l
+-0.871007 0.233637 -0.86542 0.237303 0 0 0 0.00281905 l
+-0.871007 0.233637 -0.888231 0.233895 0 0 0 0.00281905 l
+-0.752266 0.366741 -0.758946 0.383348 0 0 0 0.00281905 l
+-0.752266 0.366741 -0.762209 0.355263 0 0 0 0.00281905 l
+-0.360887 -0.228718 -0.365357 -0.243224 0 0 0 0.00281905 l
+-0.360887 -0.228718 -0.354364 -0.222368 0 0 0 0.00281905 l
+-0.526954 -0.813868 -0.53066 -0.818327 0 0 0 0.00281905 l
+0.0176731 0.123742 0.0113524 0.11654 0 0 0 0.00281905 l
+-0.975718 0.218857 -0.972613 0.22711 0 0 0 0.00281905 l
+-0.975718 0.218857 -0.957745 0.204277 0 0 0 0.00281905 l
+0.756378 0.533796 0.761372 0.522257 0 0 0 0.00281905 l
+0.756378 0.533796 0.754331 0.537284 0 0 0 0.00281905 l
+0.826492 -0.056076 0.835375 -0.0676224 0 0 0 0.00281905 l
+0.826492 -0.056076 0.813004 -0.0601676 0 0 0 0.00281905 l
+0.139254 -0.30464 0.117763 -0.304226 0 0 0 0.00281905 l
+-0.307804 0.0905935 -0.30873 0.0987135 0 0 0 0.00281905 l
+-0.307804 0.0905935 -0.295214 0.0835888 0 0 0 0.00281905 l
+-0.837893 -0.314557 -0.834802 -0.306252 0 0 0 0.00281905 l
+-0.837893 -0.314557 -0.841928 -0.316044 0 0 0 0.00281905 l
+-0.940393 -0.288881 -0.929986 -0.299649 0 0 0 0.00281905 l
+-0.940393 -0.288881 -0.948423 -0.284737 0 0 0 0.00281905 l
+-0.940393 -0.288881 -0.935131 -0.282211 0 0 0 0.00281905 l
+-0.217134 0.511329 -0.21432 0.496846 0 0 0 0.00281905 l
+-0.217134 0.511329 -0.214992 0.520323 0 0 0 0.00281905 l
+-0.217134 0.511329 -0.232741 0.508809 0 0 0 0.00281905 l
+-0.0965469 0.637028 -0.085543 0.631439 0 0 0 0.00281905 l
+-0.0965469 0.637028 -0.0998139 0.626165 0 0 0 0.00281905 l
+-0.0965469 0.637028 -0.104129 0.642005 0 0 0 0.00281905 l
+0.285563 -0.477153 0.292308 -0.472521 0 0 0 0.00281905 l
+0.285563 -0.477153 0.289964 -0.482375 0 0 0 0.00281905 l
+-0.507644 -0.162991 -0.506752 -0.169045 0 0 0 0.00281905 l
+0.179464 -0.808184 0.186936 -0.813768 0 0 0 0.00281905 l
+0.179464 -0.808184 0.162478 -0.81296 0 0 0 0.00281905 l
+0.586324 -0.338908 0.596603 -0.345163 0 0 0 0.00281905 l
+0.586324 -0.338908 0.573869 -0.348667 0 0 0 0.00281905 l
+0.586324 -0.338908 0.587435 -0.334624 0 0 0 0.00281905 l
+0.843335 0.0504197 0.846472 0.0338629 0 0 0 0.00281905 l
+0.843335 0.0504197 0.845524 0.0508683 0 0 0 0.00281905 l
+0.0538495 -0.0930439 0.05447 -0.0862266 0 0 0 0.00281905 l
+0.0538495 -0.0930439 0.0649928 -0.107606 0 0 0 0.00281905 l
+0.0745035 -0.581547 0.0747528 -0.581497 0 0 0 0.00281905 l
+0.0745035 -0.581547 0.0615664 -0.576272 0 0 0 0.00281905 l
+0.0529211 0.512235 0.0604677 0.516892 0 0 0 0.00281905 l
+0.0529211 0.512235 0.0479191 0.503421 0 0 0 0.00281905 l
+0.0077785 -0.487754 0.0174979 -0.503064 0 0 0 0.00281905 l
+0.0077785 -0.487754 0.011818 -0.479346 0 0 0 0.00281905 l
+0.0774614 0.218943 0.0746854 0.220278 0 0 0 0.00281905 l
+0.331819 0.773096 0.316674 0.776034 0 0 0 0.00281905 l
+0.0397164 -0.93324 0.0478441 -0.940275 0 0 0 0.00281905 l
+0.506051 0.18663 0.495671 0.172731 0 0 0 0.00281905 l
+0.532279 -0.537445 0.542822 -0.550505 0 0 0 0.00281905 l
+-0.307494 0.532003 -0.293744 0.534802 0 0 0 0.00281905 l
+-0.396063 0.453229 -0.393998 0.438416 0 0 0 0.00281905 l
+-0.396063 0.453229 -0.382533 0.460775 0 0 0 0.00281905 l
+-0.396063 0.453229 -0.411649 0.46193 0 0 0 0.00281905 l
+0.396662 0.721446 0.398457 0.717968 0 0 0 0.00281905 l
+0.396662 0.721446 0.392649 0.727112 0 0 0 0.00281905 l
+0.622274 0.311939 0.628794 0.324449 0 0 0 0.00281905 l
+0.622274 0.311939 0.635856 0.306672 0 0 0 0.00281905 l
+-0.554853 0.269423 -0.558446 0.256713 0 0 0 0.00281905 l
+-0.554853 0.269423 -0.560916 0.282578 0 0 0 0.00281905 l
+-0.838816 0.327991 -0.830142 0.318809 0 0 0 0.00281905 l
+-0.838816 0.327991 -0.846658 0.331692 0 0 0 0.00281905 l
+0.542846 -0.0981971 0.550701 -0.0967541 0 0 0 0.00281905 l
+0.542846 -0.0981971 0.536093 -0.0975822 0 0 0 0.00281905 l
+-0.789285 0.199571 -0.781055 0.208836 0 0 0 0.00281905 l
+-0.789285 0.199571 -0.790782 0.186761 0 0 0 0.00281905 l
+0.983031 -0.173375 0.980309 -0.161384 0 0 0 0.00281905 l
+0.983031 -0.173375 0.975726 -0.180076 0 0 0 0.00281905 l
+0.87319 0.0267613 0.862767 0.0324139 0 0 0 0.00281905 l
+0.298008 -0.151425 0.298184 -0.160836 0 0 0 0.00281905 l
+0.298008 -0.151425 0.29566 -0.143389 0 0 0 0.00281905 l
+0.298008 -0.151425 0.302843 -0.150034 0 0 0 0.00281905 l
+0.373136 0.292543 0.37313 0.300869 0 0 0 0.00281905 l
+0.373136 0.292543 0.378233 0.288489 0 0 0 0.00281905 l
+-0.856608 0.429681 -0.856821 0.437404 0 0 0 0.00281905 l
+-0.856608 0.429681 -0.847641 0.416984 0 0 0 0.00281905 l
+-0.856608 0.429681 -0.863008 0.432623 0 0 0 0.00281905 l
+-0.630126 -0.203224 -0.63171 -0.209739 0 0 0 0.00281905 l
+-0.630126 -0.203224 -0.621653 -0.194644 0 0 0 0.00281905 l
+-0.248304 -0.126027 -0.256641 -0.138508 0 0 0 0.00281905 l
+-0.248304 -0.126027 -0.239697 -0.117029 0 0 0 0.00281905 l
+-0.562737 0.628839 -0.548872 0.620259 0 0 0 0.00281905 l
+-0.562737 0.628839 -0.56582 0.631636 0 0 0 0.00281905 l
+-0.11943 -0.227097 -0.111204 -0.235757 0 0 0 0.00281905 l
+-0.11943 -0.227097 -0.129336 -0.223367 0 0 0 0.00281905 l
+-0.263631 -0.774421 -0.275825 -0.773407 0 0 0 0.00281905 l
+-0.774113 0.594583 -0.774951 0.58919 0 0 0 0.00281905 l
+-0.774113 0.594583 -0.776513 0.601194 0 0 0 0.00281905 l
+0.0142219 0.647383 0.016473 0.640136 0 0 0 0.00281905 l
+0.0142219 0.647383 0.0137035 0.652096 0 0 0 0.00281905 l
+0.457203 0.535205 0.465141 0.538864 0 0 0 0.00281905 l
+-0.417486 -0.724715 -0.396639 -0.724701 0 0 0 0.00281905 l
+-0.469832 0.125438 -0.468261 0.119814 0 0 0 0.00281905 l
+-0.469832 0.125438 -0.4756 0.131618 0 0 0 0.00281905 l
+-0.626239 -0.0329287 -0.617601 -0.0288869 0 0 0 0.00281905 l
+-0.626239 -0.0329287 -0.632438 -0.0318521 0 0 0 0.00281905 l
+0.53736 0.811539 0.532655 0.825652 0 0 0 0.00281905 l
+-0.578719 0.587806 -0.585223 0.596996 0 0 0 0.00281905 l
+-0.578719 0.587806 -0.593318 0.580741 0 0 0 0.00281905 l
+0.167802 0.802793 0.166973 0.811501 0 0 0 0.00281905 l
+0.167802 0.802793 0.164503 0.790452 0 0 0 0.00281905 l
+0.0301897 -0.081611 0.0343803 -0.0842026 0 0 0 0.00281905 l
+0.0301897 -0.081611 0.0181818 -0.0910752 0 0 0 0.00281905 l
+-0.291506 -0.526159 -0.288169 -0.523394 0 0 0 0.00281905 l
+-0.291506 -0.526159 -0.303071 -0.525554 0 0 0 0.00281905 l
+0.0619061 -0.204734 0.0705764 -0.192373 0 0 0 0.00281905 l
+0.0619061 -0.204734 0.0578319 -0.204478 0 0 0 0.00281905 l
+-0.300275 -0.67061 -0.294095 -0.665844 0 0 0 0.00281905 l
+-0.300275 -0.67061 -0.306925 -0.672334 0 0 0 0.00281905 l
+-0.0989686 -0.375028 -0.0925954 -0.366585 0 0 0 0.00281905 l
+0.16983 -0.161432 0.176916 -0.170433 0 0 0 0.00281905 l
+0.16983 -0.161432 0.15884 -0.1539 0 0 0 0.00281905 l
+-0.857543 -0.433766 -0.857238 -0.430194 0 0 0 0.00281905 l
+-0.144673 0.816523 -0.140829 0.820803 0 0 0 0.00281905 l
+-0.967208 0.152214 -0.956778 0.160253 0 0 0 0.00281905 l
+-0.967208 0.152214 -0.976945 0.149804 0 0 0 0.00281905 l
+-0.509979 -0.677291 -0.505335 -0.676398 0 0 0 0.00281905 l
+-0.671378 0.0382945 -0.673343 0.0154916 0 0 0 0.00281905 l
+-0.671378 0.0382945 -0.657431 0.0461772 0 0 0 0.00281905 l
+-0.393523 0.011131 -0.389306 0.00564745 0 0 0 0.00281905 l
+0.208899 -0.173192 0.201712 -0.190242 0 0 0 0.00281905 l
+0.208899 -0.173192 0.214993 -0.16831 0 0 0 0.00281905 l
+-0.420794 -0.24615 -0.416782 -0.255665 0 0 0 0.00281905 l
+-0.420794 -0.24615 -0.425682 -0.246788 0 0 0 0.00281905 l
+0.0728576 0.319594 0.069758 0.313959 0 0 0 0.00281905 l
+0.0728576 0.319594 0.0832575 0.326865 0 0 0 0.00281905 l
+-0.215574 -0.096557 -0.221011 -0.0920298 0 0 0 0.00281905 l
+0.105597 0.825622 0.0986654 0.836064 0 0 0 0.00281905 l
+0.105597 0.825622 0.0944291 0.816401 0 0 0 0.00281905 l
+0.223619 -0.0441659 0.21095 -0.0577675 0 0 0 0.00281905 l
+0.223619 -0.0441659 0.230377 -0.0417726 0 0 0 0.00281905 l
+0.164226 -0.0540648 0.177645 -0.0501687 0 0 0 0.00281905 l
+0.164226 -0.0540648 0.150977 -0.0569331 0 0 0 0.00281905 l
+0.307862 0.770267 0.316674 0.776034 0 0 0 0.00281905 l
+0.307862 0.770267 0.303308 0.771061 0 0 0 0.00281905 l
+-0.362912 0.563992 -0.372858 0.566488 0 0 0 0.00281905 l
+0.34283 0.0639632 0.357941 0.0744603 0 0 0 0.00281905 l
+0.34283 0.0639632 0.341219 0.0640053 0 0 0 0.00281905 l
+0.617287 -0.424168 0.629643 -0.439224 0 0 0 0.00281905 l
+-0.384989 0.757887 -0.386243 0.750239 0 0 0 0.00281905 l
+-0.384989 0.757887 -0.382249 0.767112 0 0 0 0.00281905 l
+0.23661 0.806993 0.237876 0.827168 0 0 0 0.00281905 l
+0.23661 0.806993 0.248154 0.809292 0 0 0 0.00281905 l
+0.23661 0.806993 0.23109 0.804567 0 0 0 0.00281905 l
+-0.114746 0.940634 -0.107824 0.948275 0 0 0 0.00281905 l
+-0.343362 0.899906 -0.334868 0.883263 0 0 0 0.00281905 l
+-0.255371 0.540381 -0.25405 0.522235 0 0 0 0.00281905 l
+-0.255371 0.540381 -0.245 0.550204 0 0 0 0.00281905 l
+-0.255371 0.540381 -0.260016 0.543852 0 0 0 0.00281905 l
+-0.671516 -0.479482 -0.674672 -0.49058 0 0 0 0.00281905 l
+-0.671516 -0.479482 -0.671443 -0.475682 0 0 0 0.00281905 l
+-0.671516 -0.479482 -0.684468 -0.480826 0 0 0 0.00281905 l
+-0.188007 0.135616 -0.168457 0.133617 0 0 0 0.00281905 l
+-0.25576 0.602377 -0.24861 0.608091 0 0 0 0.00281905 l
+-0.25576 0.602377 -0.256243 0.601545 0 0 0 0.00281905 l
+0.459458 -0.425375 0.455288 -0.436016 0 0 0 0.00281905 l
+0.459458 -0.425375 0.450157 -0.425527 0 0 0 0.00281905 l
+-0.635237 -0.457554 -0.631451 -0.461741 0 0 0 0.00281905 l
+-0.635237 -0.457554 -0.64247 -0.456003 0 0 0 0.00281905 l
+-0.974762 0.0230526 -0.969097 0.028464 0 0 0 0.00281905 l
+-0.974762 0.0230526 -0.985191 0.0126579 0 0 0 0.00281905 l
+0.417965 0.387219 0.4234 0.377135 0 0 0 0.00281905 l
+0.417965 0.387219 0.405862 0.376434 0 0 0 0.00281905 l
+0.293013 -0.306595 0.29348 -0.294104 0 0 0 0.00281905 l
+0.293013 -0.306595 0.298178 -0.30823 0 0 0 0.00281905 l
+0.0494498 -0.14821 0.0516108 -0.135691 0 0 0 0.00281905 l
+0.0494498 -0.14821 0.041199 -0.153382 0 0 0 0.00281905 l
+0.310185 -0.474497 0.315585 -0.475105 0 0 0 0.00281905 l
+0.310185 -0.474497 0.292308 -0.472521 0 0 0 0.00281905 l
+-0.800721 0.451438 -0.805306 0.440006 0 0 0 0.00281905 l
+-0.800721 0.451438 -0.787024 0.452823 0 0 0 0.00281905 l
+0.0344999 0.278472 0.0502007 0.287193 0 0 0 0.00281905 l
+0.0344999 0.278472 0.0261246 0.277342 0 0 0 0.00281905 l
+0.0715936 0.188876 0.0858474 0.182462 0 0 0 0.00281905 l
+0.0715936 0.188876 0.0608748 0.188779 0 0 0 0.00281905 l
+-0.84155 -0.0570568 -0.850723 -0.0751691 0 0 0 0.00281905 l
+-0.740878 -0.263081 -0.736078 -0.253197 0 0 0 0.00281905 l
+0.101019 0.667972 0.108244 0.662783 0 0 0 0.00281905 l
+0.101019 0.667972 0.0955106 0.659802 0 0 0 0.00281905 l
+-0.781998 0.234768 -0.7835 0.223876 0 0 0 0.00281905 l
+-0.0681322 -0.117907 -0.0615237 -0.107651 0 0 0 0.00281905 l
+-0.0681322 -0.117907 -0.0598151 -0.133768 0 0 0 0.00281905 l
+-0.0681322 -0.117907 -0.0748145 -0.122022 0 0 0 0.00281905 l
+-0.150862 -0.832692 -0.144677 -0.813505 0 0 0 0.00281905 l
+-0.497582 0.844561 -0.497415 0.848694 0 0 0 0.00281905 l
+-0.497582 0.844561 -0.488356 0.832801 0 0 0 0.00281905 l
+0.980622 0.0250043 0.982355 0.022313 0 0 0 0.00281905 l
+0.980622 0.0250043 0.976819 0.0281726 0 0 0 0.00281905 l
+0.560222 0.433442 0.568657 0.445315 0 0 0 0.00281905 l
+0.560222 0.433442 0.548013 0.428781 0 0 0 0.00281905 l
+0.0544229 -0.665024 0.0445895 -0.677521 0 0 0 0.00281905 l
+0.0544229 -0.665024 0.0605841 -0.660208 0 0 0 0.00281905 l
+0.58768 0.767835 0.579482 0.769433 0 0 0 0.00281905 l
+0.58768 0.767835 0.589985 0.771528 0 0 0 0.00281905 l
+0.296763 -0.161112 0.298184 -0.160836 0 0 0 0.00281905 l
+0.296763 -0.161112 0.28555 -0.158284 0 0 0 0.00281905 l
+-0.151434 -0.396547 -0.138074 -0.390706 0 0 0 0.00281905 l
+-0.151434 -0.396547 -0.148247 -0.406799 0 0 0 0.00281905 l
+-0.151434 -0.396547 -0.15467 -0.384005 0 0 0 0.00281905 l
+0.226655 -0.640393 0.235084 -0.630485 0 0 0 0.00281905 l
+0.127751 0.547963 0.140396 0.533394 0 0 0 0.00281905 l
+0.127751 0.547963 0.132468 0.559406 0 0 0 0.00281905 l
+0.127751 0.547963 0.115071 0.558496 0 0 0 0.00281905 l
+-0.480145 -0.639647 -0.482362 -0.645869 0 0 0 0.00281905 l
+-0.480145 -0.639647 -0.467281 -0.637469 0 0 0 0.00281905 l
+-0.480145 -0.639647 -0.485941 -0.636158 0 0 0 0.00281905 l
+-0.665286 -0.173693 -0.653991 -0.177995 0 0 0 0.00281905 l
+-0.665286 -0.173693 -0.672545 -0.18034 0 0 0 0.00281905 l
+-0.665286 -0.173693 -0.671621 -0.166178 0 0 0 0.00281905 l
+0.328769 -0.725765 0.326425 -0.741584 0 0 0 0.00281905 l
+0.328769 -0.725765 0.327576 -0.720089 0 0 0 0.00281905 l
+0.0120132 0.587417 0.0300137 0.593982 0 0 0 0.00281905 l
+0.0120132 0.587417 -0.007003 0.583346 0 0 0 0.00281905 l
+0.314813 0.303022 0.315509 0.294034 0 0 0 0.00281905 l
+0.314813 0.303022 0.312524 0.308382 0 0 0 0.00281905 l
+-0.638719 -0.234543 -0.634403 -0.23306 0 0 0 0.00281905 l
+-0.253716 -0.599412 -0.254132 -0.595057 0 0 0 0.00281905 l
+0.487068 -0.306228 0.491634 -0.301631 0 0 0 0.00281905 l
+0.487068 -0.306228 0.474383 -0.305495 0 0 0 0.00281905 l
+0.421517 -0.194016 0.416306 -0.179198 0 0 0 0.00281905 l
+0.421517 -0.194016 0.426711 -0.192921 0 0 0 0.00281905 l
+0.421517 -0.194016 0.41099 -0.206663 0 0 0 0.00281905 l
+0.264056 0.475727 0.255432 0.472909 0 0 0 0.00281905 l
+-0.0611782 0.746094 -0.0511121 0.745043 0 0 0 0.00281905 l
+-0.0611782 0.746094 -0.0581448 0.735065 0 0 0 0.00281905 l
+-0.0611782 0.746094 -0.0615094 0.746148 0 0 0 0.00281905 l
+-0.264415 0.337388 -0.269692 0.321634 0 0 0 0.00281905 l
+-0.264415 0.337388 -0.256666 0.351629 0 0 0 0.00281905 l
+0.921857 0.0631322 0.915004 0.0847772 0 0 0 0.00281905 l
+0.921857 0.0631322 0.938527 0.0517995 0 0 0 0.00281905 l
+0.921857 0.0631322 0.902306 0.0522079 0 0 0 0.00281905 l
+-0.902096 0.0544831 -0.886005 0.0466323 0 0 0 0.00281905 l
+-0.902096 0.0544831 -0.905055 0.0581861 0 0 0 0.00281905 l
+-0.674243 -0.428712 -0.677852 -0.447071 0 0 0 0.00281905 l
+-0.674243 -0.428712 -0.678759 -0.418793 0 0 0 0.00281905 l
+0.266673 0.847575 0.272028 0.86479 0 0 0 0.00281905 l
+0.266673 0.847575 0.275896 0.842921 0 0 0 0.00281905 l
+0.266673 0.847575 0.260539 0.839922 0 0 0 0.00281905 l
+-0.38014 -0.846584 -0.38198 -0.864002 0 0 0 0.00281905 l
+-0.38014 -0.846584 -0.391268 -0.845879 0 0 0 0.00281905 l
+-0.00405571 -0.582543 -0.0223632 -0.577535 0 0 0 0.00281905 l
+-0.303122 0.115551 -0.30873 0.0987135 0 0 0 0.00281905 l
+-0.303122 0.115551 -0.309314 0.123802 0 0 0 0.00281905 l
+-0.651511 -0.565413 -0.634637 -0.560724 0 0 0 0.00281905 l
+-0.651511 -0.565413 -0.661313 -0.575778 0 0 0 0.00281905 l
+-0.651511 -0.565413 -0.656856 -0.561098 0 0 0 0.00281905 l
+-0.410713 0.890251 -0.397071 0.879742 0 0 0 0.00281905 l
+-0.410713 0.890251 -0.410544 0.891817 0 0 0 0.00281905 l
+0.614052 0.75225 0.620507 0.748928 0 0 0 0.00281905 l
+0.614052 0.75225 0.600489 0.763056 0 0 0 0.00281905 l
+-0.134641 0.855131 -0.121686 0.854627 0 0 0 0.00281905 l
+-0.134641 0.855131 -0.138862 0.860333 0 0 0 0.00281905 l
+0.322648 0.40715 0.320829 0.3979 0 0 0 0.00281905 l
+0.322648 0.40715 0.331876 0.408811 0 0 0 0.00281905 l
+-0.247738 0.347234 -0.250031 0.347192 0 0 0 0.00281905 l
+-0.792319 0.501497 -0.786227 0.488405 0 0 0 0.00281905 l
+-0.792319 0.501497 -0.784068 0.508757 0 0 0 0.00281905 l
+-0.792319 0.501497 -0.814852 0.497071 0 0 0 0.00281905 l
+0.810892 -0.0688945 0.813004 -0.0601676 0 0 0 0.00281905 l
+0.810892 -0.0688945 0.816164 -0.0717095 0 0 0 0.00281905 l
+0.810892 -0.0688945 0.801899 -0.0759943 0 0 0 0.00281905 l
+0.293983 0.0575007 0.289356 0.0748388 0 0 0 0.00281905 l
+0.293983 0.0575007 0.296858 0.0573792 0 0 0 0.00281905 l
+0.655195 0.622067 0.659766 0.613087 0 0 0 0.00281905 l
+0.655195 0.622067 0.661525 0.626703 0 0 0 0.00281905 l
+0.655195 0.622067 0.651279 0.630921 0 0 0 0.00281905 l
+0.155878 0.83676 0.169456 0.83357 0 0 0 0.00281905 l
+0.155878 0.83676 0.151858 0.829035 0 0 0 0.00281905 l
+0.155878 0.83676 0.143079 0.845248 0 0 0 0.00281905 l
+-0.56749 0.190688 -0.55651 0.208507 0 0 0 0.00281905 l
+0.0667513 -0.19042 0.0668636 -0.188052 0 0 0 0.00281905 l
+0.0667513 -0.19042 0.0705764 -0.192373 0 0 0 0.00281905 l
+0.0608748 0.188779 0.0715936 0.188876 0 0 0 0.00281905 l
+0.0608748 0.188779 0.0590578 0.185736 0 0 0 0.00281905 l
+-0.662136 -0.30796 -0.652156 -0.30233 0 0 0 0.00281905 l
+-0.662136 -0.30796 -0.668449 -0.29223 0 0 0 0.00281905 l
+-0.662136 -0.30796 -0.672776 -0.311725 0 0 0 0.00281905 l
+0.958362 0.146693 0.959309 0.144072 0 0 0 0.00281905 l
+0.715416 0.172852 0.721324 0.171566 0 0 0 0.00281905 l
+0.715416 0.172852 0.714397 0.164196 0 0 0 0.00281905 l
+0.715416 0.172852 0.708082 0.181733 0 0 0 0.00281905 l
+0.172734 0.583271 0.16686 0.592074 0 0 0 0.00281905 l
+0.0500875 -0.702661 0.0652994 -0.701298 0 0 0 0.00281905 l
+0.0500875 -0.702661 0.0313305 -0.697146 0 0 0 0.00281905 l
+-0.0915908 -0.879075 -0.0810374 -0.872727 0 0 0 0.00281905 l
+-0.0915908 -0.879075 -0.101343 -0.879654 0 0 0 0.00281905 l
+0.826166 -0.372423 0.811854 -0.354739 0 0 0 0.00281905 l
+0.826166 -0.372423 0.831295 -0.369322 0 0 0 0.00281905 l
+-0.304261 0.581993 -0.304795 0.602119 0 0 0 0.00281905 l
+-0.304261 0.581993 -0.294769 0.579498 0 0 0 0.00281905 l
+-0.304261 0.581993 -0.314278 0.561054 0 0 0 0.00281905 l
+-0.437923 -0.651829 -0.442604 -0.661115 0 0 0 0.00281905 l
+-0.437923 -0.651829 -0.436571 -0.641834 0 0 0 0.00281905 l
+-0.130161 -0.190945 -0.129811 -0.192656 0 0 0 0.00281905 l
+-0.130161 -0.190945 -0.135457 -0.190825 0 0 0 0.00281905 l
+0.00567514 -0.221812 0.00156488 -0.22872 0 0 0 0.00281905 l
+0.00567514 -0.221812 0.0132464 -0.218145 0 0 0 0.00281905 l
+0.815291 -0.307738 0.822822 -0.295258 0 0 0 0.00281905 l
+0.815291 -0.307738 0.812214 -0.313528 0 0 0 0.00281905 l
+0.899795 -0.0647737 0.8987 -0.0726415 0 0 0 0.00281905 l
+0.899795 -0.0647737 0.904067 -0.0631729 0 0 0 0.00281905 l
+-0.2488 0.225416 -0.236085 0.238986 0 0 0 0.00281905 l
+-0.2488 0.225416 -0.245803 0.22115 0 0 0 0.00281905 l
+-0.2488 0.225416 -0.250337 0.226757 0 0 0 0.00281905 l
+0.92552 -0.368163 0.91469 -0.359928 0 0 0 0.00281905 l
+0.92552 -0.368163 0.914172 -0.37388 0 0 0 0.00281905 l
+-0.462931 0.10329 -0.450982 0.106655 0 0 0 0.00281905 l
+-0.462931 0.10329 -0.468261 0.119814 0 0 0 0.00281905 l
+0.0926123 -0.74928 0.0805016 -0.739182 0 0 0 0.00281905 l
+0.0926123 -0.74928 0.0811246 -0.761723 0 0 0 0.00281905 l
+0.0988206 -0.708685 0.101861 -0.721985 0 0 0 0.00281905 l
+0.0988206 -0.708685 0.0970512 -0.691353 0 0 0 0.00281905 l
+0.0163499 -0.536184 0.00825097 -0.534565 0 0 0 0.00281905 l
+0.0163499 -0.536184 0.020818 -0.531706 0 0 0 0.00281905 l
+-0.254482 -0.414234 -0.240365 -0.4214 0 0 0 0.00281905 l
+-0.254482 -0.414234 -0.246747 -0.401638 0 0 0 0.00281905 l
+0.0345962 0.701747 0.0407204 0.690664 0 0 0 0.00281905 l
+0.0345962 0.701747 0.0279319 0.710826 0 0 0 0.00281905 l
+-0.249336 0.654303 -0.256455 0.651864 0 0 0 0.00281905 l
+0.179239 -0.760919 0.19883 -0.7587 0 0 0 0.00281905 l
+0.179239 -0.760919 0.160339 -0.756281 0 0 0 0.00281905 l
+0.119349 0.0468448 0.110461 0.0574462 0 0 0 0.00281905 l
+-0.118116 0.00390034 -0.116723 -0.0085806 0 0 0 0.00281905 l
+-0.118116 0.00390034 -0.129088 0.00746886 0 0 0 0.00281905 l
+0.752232 0.208245 0.756068 0.198626 0 0 0 0.00281905 l
+0.752232 0.208245 0.748569 0.210114 0 0 0 0.00281905 l
+0.565281 0.6854 0.566307 0.681343 0 0 0 0.00281905 l
+-0.285823 0.541146 -0.287031 0.53537 0 0 0 0.00281905 l
+-0.285823 0.541146 -0.264194 0.547573 0 0 0 0.00281905 l
+0.307061 -0.641291 0.316132 -0.638902 0 0 0 0.00281905 l
+0.307061 -0.641291 0.304267 -0.633212 0 0 0 0.00281905 l
+0.484096 -0.498597 0.487641 -0.50238 0 0 0 0.00281905 l
+0.484096 -0.498597 0.478416 -0.492517 0 0 0 0.00281905 l
+-0.550448 -0.137919 -0.552623 -0.138977 0 0 0 0.00281905 l
+0.278626 0.44116 0.283473 0.425608 0 0 0 0.00281905 l
+0.278626 0.44116 0.28927 0.44877 0 0 0 0.00281905 l
+0.278626 0.44116 0.272775 0.442278 0 0 0 0.00281905 l
+-0.233103 0.174737 -0.22947 0.160401 0 0 0 0.00281905 l
+-0.233103 0.174737 -0.237929 0.189347 0 0 0 0.00281905 l
+0.465194 0.0679942 0.471425 0.0670765 0 0 0 0.00281905 l
+0.465194 0.0679942 0.451803 0.0831259 0 0 0 0.00281905 l
+0.465194 0.0679942 0.450227 0.0584916 0 0 0 0.00281905 l
+-0.0668379 0.376319 -0.0638413 0.392135 0 0 0 0.00281905 l
+0.697976 -0.359357 0.714095 -0.368501 0 0 0 0.00281905 l
+0.697976 -0.359357 0.688782 -0.366273 0 0 0 0.00281905 l
+0.748569 0.210114 0.752232 0.208245 0 0 0 0.00281905 l
+-0.323957 0.726314 -0.323674 0.711424 0 0 0 0.00281905 l
+-0.323957 0.726314 -0.323949 0.734022 0 0 0 0.00281905 l
+-0.457981 0.0271486 -0.459085 0.0310881 0 0 0 0.00281905 l
+0.0068649 0.923351 0.00834311 0.92391 0 0 0 0.00281905 l
+0.0068649 0.923351 -0.00657777 0.940991 0 0 0 0.00281905 l
+0.54534 -0.482509 0.558095 -0.485132 0 0 0 0.00281905 l
+0.256176 0.817641 0.267907 0.819675 0 0 0 0.00281905 l
+0.256176 0.817641 0.248154 0.809292 0 0 0 0.00281905 l
+0.356206 0.783891 0.358801 0.783147 0 0 0 0.00281905 l
+0.356206 0.783891 0.341279 0.789628 0 0 0 0.00281905 l
+0.548106 -0.328914 0.552856 -0.326254 0 0 0 0.00281905 l
+0.548106 -0.328914 0.535681 -0.331069 0 0 0 0.00281905 l
+0.459317 0.545806 0.459201 0.554054 0 0 0 0.00281905 l
+0.459317 0.545806 0.466408 0.541015 0 0 0 0.00281905 l
+-0.478105 -0.794422 -0.482099 -0.798337 0 0 0 0.00281905 l
+-0.370043 0.135253 -0.372484 0.140811 0 0 0 0.00281905 l
+-0.370043 0.135253 -0.367697 0.13038 0 0 0 0.00281905 l
+0.169908 0.59707 0.160475 0.609493 0 0 0 0.00281905 l
+0.169908 0.59707 0.173683 0.598534 0 0 0 0.00281905 l
+0.169908 0.59707 0.16686 0.592074 0 0 0 0.00281905 l
+-0.511681 0.761759 -0.501274 0.771769 0 0 0 0.00281905 l
+-0.427777 -0.658417 -0.424513 -0.656724 0 0 0 0.00281905 l
+-0.225697 -0.487049 -0.213114 -0.472536 0 0 0 0.00281905 l
+-0.225697 -0.487049 -0.236652 -0.478185 0 0 0 0.00281905 l
+0.0413802 -0.299833 0.052618 -0.296495 0 0 0 0.00281905 l
+0.0413802 -0.299833 0.0383813 -0.304405 0 0 0 0.00281905 l
+-0.120728 -0.908797 -0.117226 -0.915239 0 0 0 0.00281905 l
+-0.120728 -0.908797 -0.120349 -0.906132 0 0 0 0.00281905 l
+0.401489 0.876218 0.412386 0.887802 0 0 0 0.00281905 l
+0.401489 0.876218 0.403211 0.873554 0 0 0 0.00281905 l
+0.827815 0.197654 0.824082 0.211977 0 0 0 0.00281905 l
+0.827815 0.197654 0.831534 0.197148 0 0 0 0.00281905 l
+0.827815 0.197654 0.817785 0.191548 0 0 0 0.00281905 l
+-0.385445 0.31581 -0.390298 0.303187 0 0 0 0.00281905 l
+0.121815 -0.972676 0.121146 -0.966807 0 0 0 0.00281905 l
+0.121815 -0.972676 0.125228 -0.975849 0 0 0 0.00281905 l
+0.121815 -0.972676 0.108423 -0.982607 0 0 0 0.00281905 l
+-0.794968 -0.146362 -0.777386 -0.143678 0 0 0 0.00281905 l
+-0.794968 -0.146362 -0.80846 -0.137194 0 0 0 0.00281905 l
+0.25967 -0.908048 0.265406 -0.891342 0 0 0 0.00281905 l
+0.25967 -0.908048 0.268362 -0.910512 0 0 0 0.00281905 l
+0.25967 -0.908048 0.248766 -0.919427 0 0 0 0.00281905 l
+-0.24324 -0.480261 -0.244068 -0.47413 0 0 0 0.00281905 l
+-0.24324 -0.480261 -0.236652 -0.478185 0 0 0 0.00281905 l
+-0.24324 -0.480261 -0.251535 -0.488557 0 0 0 0.00281905 l
+-0.56345 0.337304 -0.569313 0.319482 0 0 0 0.00281905 l
+-0.56345 0.337304 -0.546055 0.33691 0 0 0 0.00281905 l
+-0.56345 0.337304 -0.564564 0.339642 0 0 0 0.00281905 l
+0.258514 0.687966 0.269082 0.672881 0 0 0 0.00281905 l
+0.258514 0.687966 0.243997 0.688842 0 0 0 0.00281905 l
+-0.77532 0.328484 -0.787762 0.314705 0 0 0 0.00281905 l
+-0.896639 -0.340494 -0.888128 -0.340012 0 0 0 0.00281905 l
+-0.896639 -0.340494 -0.914743 -0.331412 0 0 0 0.00281905 l
+0.0839629 -0.227123 0.0878522 -0.219345 0 0 0 0.00281905 l
+0.0839629 -0.227123 0.0875798 -0.229611 0 0 0 0.00281905 l
+0.0839629 -0.227123 0.0795316 -0.225621 0 0 0 0.00281905 l
+0.273374 -0.686645 0.291984 -0.688813 0 0 0 0.00281905 l
+0.273374 -0.686645 0.270334 -0.694823 0 0 0 0.00281905 l
+-0.86275 -0.0147814 -0.861741 0.00365199 0 0 0 0.00281905 l
+-0.59918 0.798177 -0.587661 0.797405 0 0 0 0.00281905 l
+-0.59918 0.798177 -0.598433 0.78984 0 0 0 0.00281905 l
+0.383165 -0.187575 0.380626 -0.182453 0 0 0 0.00281905 l
+0.383165 -0.187575 0.380761 -0.204267 0 0 0 0.00281905 l
+0.383165 -0.187575 0.398249 -0.187374 0 0 0 0.00281905 l
+-0.10658 0.727076 -0.102238 0.716016 0 0 0 0.00281905 l
+-0.10658 0.727076 -0.0922459 0.743857 0 0 0 0.00281905 l
+-0.911537 0.168458 -0.906518 0.161012 0 0 0 0.00281905 l
+-0.911537 0.168458 -0.9208 0.16953 0 0 0 0.00281905 l
+0.791465 -0.575392 0.80417 -0.561251 0 0 0 0.00281905 l
+0.791465 -0.575392 0.794579 -0.593387 0 0 0 0.00281905 l
+-0.935411 -0.211838 -0.944361 -0.202361 0 0 0 0.00281905 l
+-0.113357 0.270107 -0.106947 0.278187 0 0 0 0.00281905 l
+-0.113357 0.270107 -0.128344 0.268412 0 0 0 0.00281905 l
+0.113393 0.494714 0.11054 0.501889 0 0 0 0.00281905 l
+0.113393 0.494714 0.131485 0.498057 0 0 0 0.00281905 l
+0.113393 0.494714 0.10289 0.489194 0 0 0 0.00281905 l
+0.104082 0.422344 0.113645 0.423784 0 0 0 0.00281905 l
+0.104082 0.422344 0.0872514 0.418275 0 0 0 0.00281905 l
+0.74456 0.266009 0.744644 0.262738 0 0 0 0.00281905 l
+0.74456 0.266009 0.725783 0.268143 0 0 0 0.00281905 l
+-0.0761912 0.0642849 -0.0760536 0.0594207 0 0 0 0.00281905 l
+0.676223 0.159156 0.673614 0.144956 0 0 0 0.00281905 l
+0.676223 0.159156 0.682151 0.176683 0 0 0 0.00281905 l
+-0.234984 -0.234214 -0.227558 -0.238459 0 0 0 0.00281905 l
+-0.234984 -0.234214 -0.24227 -0.228311 0 0 0 0.00281905 l
+0.245775 0.281393 0.249118 0.295657 0 0 0 0.00281905 l
+0.245775 0.281393 0.265064 0.272314 0 0 0 0.00281905 l
+0.62589 -0.34901 0.632859 -0.353386 0 0 0 0.00281905 l
+0.62589 -0.34901 0.62448 -0.358885 0 0 0 0.00281905 l
+-0.713042 0.637909 -0.70566 0.634924 0 0 0 0.00281905 l
+-0.713042 0.637909 -0.716756 0.631178 0 0 0 0.00281905 l
+-0.713042 0.637909 -0.715564 0.642132 0 0 0 0.00281905 l
+-0.363046 -0.531368 -0.35107 -0.530781 0 0 0 0.00281905 l
+-0.363046 -0.531368 -0.369838 -0.530501 0 0 0 0.00281905 l
+-0.55411 0.0444683 -0.562835 0.0353538 0 0 0 0.00281905 l
+-0.55411 0.0444683 -0.566458 0.0483661 0 0 0 0.00281905 l
+0.224951 -0.529741 0.242724 -0.516675 0 0 0 0.00281905 l
+-0.874931 -0.360026 -0.869859 -0.361154 0 0 0 0.00281905 l
+-0.874931 -0.360026 -0.87753 -0.359045 0 0 0 0.00281905 l
+0.74458 0.449007 0.740074 0.447286 0 0 0 0.00281905 l
+-0.579142 0.614841 -0.585223 0.596996 0 0 0 0.00281905 l
+-0.579142 0.614841 -0.571028 0.625922 0 0 0 0.00281905 l
+-0.0154171 -0.212508 -0.0087273 -0.219641 0 0 0 0.00281905 l
+-0.0154171 -0.212508 -0.0074707 -0.204966 0 0 0 0.00281905 l
+-0.0154171 -0.212508 -0.0256082 -0.206207 0 0 0 0.00281905 l
+-0.334868 0.883263 -0.333609 0.874333 0 0 0 0.00281905 l
+-0.334868 0.883263 -0.343362 0.899906 0 0 0 0.00281905 l
+-0.130561 0.375195 -0.135829 0.363844 0 0 0 0.00281905 l
+-0.389374 0.0490065 -0.381254 0.0491927 0 0 0 0.00281905 l
+-0.389374 0.0490065 -0.397254 0.0477514 0 0 0 0.00281905 l
+-0.0386577 -0.29579 -0.0518368 -0.312598 0 0 0 0.00281905 l
+-0.0386577 -0.29579 -0.0406821 -0.291902 0 0 0 0.00281905 l
+-0.85772 0.0551769 -0.857469 0.0582739 0 0 0 0.00281905 l
+-0.85772 0.0551769 -0.846486 0.0536178 0 0 0 0.00281905 l
+0.399478 -0.781768 0.413123 -0.793556 0 0 0 0.00281905 l
+0.399478 -0.781768 0.378596 -0.791261 0 0 0 0.00281905 l
+-0.0327066 0.440303 -0.0410162 0.425466 0 0 0 0.00281905 l
+-0.0327066 0.440303 -0.0306977 0.445289 0 0 0 0.00281905 l
+-0.46828 -0.808865 -0.454125 -0.817719 0 0 0 0.00281905 l
+-0.46828 -0.808865 -0.478492 -0.814989 0 0 0 0.00281905 l
+0.632179 -0.703072 0.640003 -0.707862 0 0 0 0.00281905 l
+0.632179 -0.703072 0.619001 -0.719551 0 0 0 0.00281905 l
+0.455966 0.685542 0.454346 0.668484 0 0 0 0.00281905 l
+0.455966 0.685542 0.456284 0.685642 0 0 0 0.00281905 l
+-0.199549 -0.140703 -0.188611 -0.139473 0 0 0 0.00281905 l
+-0.199549 -0.140703 -0.216883 -0.14132 0 0 0 0.00281905 l
+0.0113582 0.305589 0.0111923 0.303376 0 0 0 0.00281905 l
+0.0113582 0.305589 0.0149366 0.3113 0 0 0 0.00281905 l
+0.0113582 0.305589 0.00720694 0.306965 0 0 0 0.00281905 l
+0.107272 0.158221 0.107035 0.159896 0 0 0 0.00281905 l
+0.672751 0.688111 0.679186 0.698116 0 0 0 0.00281905 l
+0.672751 0.688111 0.664553 0.696554 0 0 0 0.00281905 l
+-0.413606 0.104885 -0.422354 0.123887 0 0 0 0.00281905 l
+-0.413606 0.104885 -0.418941 0.0978936 0 0 0 0.00281905 l
+0.117998 -0.158719 0.118378 -0.167354 0 0 0 0.00281905 l
+0.117998 -0.158719 0.11191 -0.153831 0 0 0 0.00281905 l
+-0.630762 -0.0227757 -0.632438 -0.0318521 0 0 0 0.00281905 l
+-0.630762 -0.0227757 -0.641579 -0.0114108 0 0 0 0.00281905 l
+0.339987 -0.163737 0.357808 -0.156312 0 0 0 0.00281905 l
+0.339987 -0.163737 0.336643 -0.152878 0 0 0 0.00281905 l
+-0.322111 0.415716 -0.318567 0.422037 0 0 0 0.00281905 l
+-0.322111 0.415716 -0.312852 0.40084 0 0 0 0.00281905 l
+-0.322111 0.415716 -0.329793 0.422705 0 0 0 0.00281905 l
+-0.245709 0.407393 -0.246058 0.393407 0 0 0 0.00281905 l
+-0.547057 0.0947999 -0.555041 0.10615 0 0 0 0.00281905 l
+-0.547057 0.0947999 -0.530149 0.0859213 0 0 0 0.00281905 l
+-0.547057 0.0947999 -0.55741 0.0834508 0 0 0 0.00281905 l
+0.611676 -0.127802 0.60267 -0.11274 0 0 0 0.00281905 l
+0.611676 -0.127802 0.620521 -0.119128 0 0 0 0.00281905 l
+0.611676 -0.127802 0.593057 -0.131867 0 0 0 0.00281905 l
+0.453608 -0.0478701 0.462674 -0.0533953 0 0 0 0.00281905 l
+0.453608 -0.0478701 0.455364 -0.0454441 0 0 0 0.00281905 l
+-0.36281 0.877691 -0.364752 0.878425 0 0 0 0.00281905 l
+-0.128793 -0.568145 -0.128569 -0.561551 0 0 0 0.00281905 l
+-0.128793 -0.568145 -0.125784 -0.581691 0 0 0 0.00281905 l
+0.374583 0.125258 0.383568 0.125205 0 0 0 0.00281905 l
+0.374583 0.125258 0.368478 0.133971 0 0 0 0.00281905 l
+0.605241 0.226937 0.602566 0.218646 0 0 0 0.00281905 l
+0.605241 0.226937 0.613095 0.231129 0 0 0 0.00281905 l
+0.605241 0.226937 0.590383 0.234249 0 0 0 0.00281905 l
+0.189529 0.124661 0.181854 0.128919 0 0 0 0.00281905 l
+0.491959 -0.835332 0.495731 -0.830107 0 0 0 0.00281905 l
+0.491959 -0.835332 0.490402 -0.835166 0 0 0 0.00281905 l
+0.592725 0.402111 0.588809 0.403292 0 0 0 0.00281905 l
+-0.476887 -0.840469 -0.478403 -0.83599 0 0 0 0.00281905 l
+-0.476887 -0.840469 -0.48358 -0.843971 0 0 0 0.00281905 l
+-0.430592 0.749362 -0.41801 0.734096 0 0 0 0.00281905 l
+-0.430592 0.749362 -0.437791 0.753493 0 0 0 0.00281905 l
+0.834886 0.545956 0.81851 0.538493 0 0 0 0.00281905 l
+0.162414 -0.657951 0.158524 -0.663338 0 0 0 0.00281905 l
+-0.367936 -0.632141 -0.355032 -0.636769 0 0 0 0.00281905 l
+0.626363 -0.106223 0.620521 -0.119128 0 0 0 0.00281905 l
+0.626363 -0.106223 0.635447 -0.0942709 0 0 0 0.00281905 l
+-0.230286 -0.127473 -0.229091 -0.135995 0 0 0 0.00281905 l
+-0.230286 -0.127473 -0.227939 -0.12033 0 0 0 0.00281905 l
+-0.413238 0.346095 -0.418306 0.347183 0 0 0 0.00281905 l
+-0.634662 0.0649219 -0.615468 0.0660999 0 0 0 0.00281905 l
+-0.634662 0.0649219 -0.652512 0.0724993 0 0 0 0.00281905 l
+0.510146 -0.715846 0.52552 -0.713851 0 0 0 0.00281905 l
+0.510146 -0.715846 0.50791 -0.722794 0 0 0 0.00281905 l
+-0.454811 0.21712 -0.453276 0.228675 0 0 0 0.00281905 l
+-0.454811 0.21712 -0.444975 0.208972 0 0 0 0.00281905 l
+-0.514227 -0.445139 -0.512512 -0.445704 0 0 0 0.00281905 l
+-0.514227 -0.445139 -0.5315 -0.450997 0 0 0 0.00281905 l
+-0.64946 -0.124069 -0.651853 -0.141402 0 0 0 0.00281905 l
+-0.64946 -0.124069 -0.63689 -0.119688 0 0 0 0.00281905 l
+-0.64946 -0.124069 -0.658754 -0.11134 0 0 0 0.00281905 l
+-0.748145 -0.344089 -0.746498 -0.337325 0 0 0 0.00281905 l
+0.871446 -0.174197 0.879196 -0.174847 0 0 0 0.00281905 l
+0.871446 -0.174197 0.864387 -0.173663 0 0 0 0.00281905 l
+0.0901949 -0.107542 0.105928 -0.0944507 0 0 0 0.00281905 l
+0.0901949 -0.107542 0.0981672 -0.119211 0 0 0 0.00281905 l
+0.832684 0.14044 0.837457 0.128422 0 0 0 0.00281905 l
+0.832684 0.14044 0.816722 0.139001 0 0 0 0.00281905 l
+-0.10296 0.0215788 -0.0886712 0.0317118 0 0 0 0.00281905 l
+-0.10296 0.0215788 -0.121469 0.0228443 0 0 0 0.00281905 l
+0.102991 -0.318478 0.0970203 -0.30283 0 0 0 0.00281905 l
+0.102991 -0.318478 0.0948657 -0.320846 0 0 0 0.00281905 l
+0.304676 -0.135559 0.317976 -0.132037 0 0 0 0.00281905 l
+0.304676 -0.135559 0.303442 -0.139304 0 0 0 0.00281905 l
+-0.534309 0.288488 -0.530891 0.290838 0 0 0 0.00281905 l
+-0.534309 0.288488 -0.544439 0.287166 0 0 0 0.00281905 l
+0.79577 0.411668 0.785613 0.429127 0 0 0 0.00281905 l
+0.79577 0.411668 0.796442 0.409934 0 0 0 0.00281905 l
+0.754741 -0.187928 0.738535 -0.194993 0 0 0 0.00281905 l
+0.754741 -0.187928 0.755563 -0.184813 0 0 0 0.00281905 l
+-0.365632 0.548029 -0.363512 0.54092 0 0 0 0.00281905 l
+-0.365632 0.548029 -0.378824 0.553336 0 0 0 0.00281905 l
+0.65767 0.33952 0.671599 0.338901 0 0 0 0.00281905 l
+0.65767 0.33952 0.639856 0.339225 0 0 0 0.00281905 l
+0.0854947 -0.423539 0.0880505 -0.423995 0 0 0 0.00281905 l
+0.0854947 -0.423539 0.0773097 -0.42781 0 0 0 0.00281905 l
+-0.0981035 0.223023 -0.100373 0.208031 0 0 0 0.00281905 l
+-0.0981035 0.223023 -0.0921426 0.228197 0 0 0 0.00281905 l
+0.00496532 0.274849 0.0114489 0.255154 0 0 0 0.00281905 l
+0.00496532 0.274849 -0.0100627 0.285587 0 0 0 0.00281905 l
+0.470066 -0.188296 0.453209 -0.204185 0 0 0 0.00281905 l
+0.361701 -0.801001 0.356169 -0.783406 0 0 0 0.00281905 l
+0.361701 -0.801001 0.368315 -0.800676 0 0 0 0.00281905 l
+-0.352864 -0.249765 -0.355476 -0.245154 0 0 0 0.00281905 l
+0.791044 0.0203049 0.78679 0.034011 0 0 0 0.00281905 l
+-0.0393383 0.215306 -0.0429263 0.224521 0 0 0 0.00281905 l
+-0.0393383 0.215306 -0.0298518 0.211894 0 0 0 0.00281905 l
+-0.0393383 0.215306 -0.0454669 0.210598 0 0 0 0.00281905 l
+0.467921 -0.103727 0.474669 -0.099354 0 0 0 0.00281905 l
+0.467921 -0.103727 0.460064 -0.0965293 0 0 0 0.00281905 l
+-0.986874 -0.0868779 -0.97999 -0.0934113 0 0 0 0.00281905 l
+-0.986874 -0.0868779 -0.993612 -0.0938908 0 0 0 0.00281905 l
+-0.209961 0.715761 -0.207325 0.711782 0 0 0 0.00281905 l
+0.881914 -0.143757 0.881755 -0.148765 0 0 0 0.00281905 l
+0.881914 -0.143757 0.900011 -0.141537 0 0 0 0.00281905 l
+0.881914 -0.143757 0.88042 -0.138735 0 0 0 0.00281905 l
+-0.477649 -0.328556 -0.466269 -0.319024 0 0 0 0.00281905 l
+-0.477649 -0.328556 -0.480187 -0.337708 0 0 0 0.00281905 l
+0.246323 -0.284371 0.253448 -0.27984 0 0 0 0.00281905 l
+0.246323 -0.284371 0.233736 -0.289843 0 0 0 0.00281905 l
+0.986945 0.150489 0.991167 0.127118 0 0 0 0.00281905 l
+0.986945 0.150489 0.978848 0.178185 0 0 0 0.00281905 l
+-0.640183 0.726733 -0.645992 0.713161 0 0 0 0.00281905 l
+-0.640183 0.726733 -0.647852 0.733913 0 0 0 0.00281905 l
+-0.168953 0.215061 -0.157788 0.217132 0 0 0 0.00281905 l
+0.855307 -0.32581 0.860603 -0.325271 0 0 0 0.00281905 l
+0.855307 -0.32581 0.847489 -0.338987 0 0 0 0.00281905 l
+0.855307 -0.32581 0.850886 -0.320343 0 0 0 0.00281905 l
+-0.491721 -0.290644 -0.490357 -0.286128 0 0 0 0.00281905 l
+-0.10316 -0.330355 -0.0912344 -0.320339 0 0 0 0.00281905 l
+-0.10316 -0.330355 -0.10444 -0.329942 0 0 0 0.00281905 l
+-0.233592 -0.901184 -0.237655 -0.912798 0 0 0 0.00281905 l
+-0.233592 -0.901184 -0.233742 -0.891145 0 0 0 0.00281905 l
+-0.379646 -0.495271 -0.367698 -0.499098 0 0 0 0.00281905 l
+-0.379646 -0.495271 -0.388951 -0.509615 0 0 0 0.00281905 l
+-0.379646 -0.495271 -0.382768 -0.489438 0 0 0 0.00281905 l
+0.298403 0.900142 0.305174 0.913624 0 0 0 0.00281905 l
+-0.575185 0.45215 -0.576291 0.435622 0 0 0 0.00281905 l
+-0.575185 0.45215 -0.563431 0.456629 0 0 0 0.00281905 l
+-0.575185 0.45215 -0.591356 0.450798 0 0 0 0.00281905 l
+-0.248847 -0.656316 -0.237224 -0.663572 0 0 0 0.00281905 l
+-0.248847 -0.656316 -0.260306 -0.641201 0 0 0 0.00281905 l
+0.500648 -0.70138 0.499236 -0.693166 0 0 0 0.00281905 l
+0.500648 -0.70138 0.495979 -0.715204 0 0 0 0.00281905 l
+0.34055 0.118659 0.347842 0.120427 0 0 0 0.00281905 l
+0.34055 0.118659 0.331127 0.131862 0 0 0 0.00281905 l
+0.700327 0.587275 0.706749 0.585894 0 0 0 0.00281905 l
+0.700327 0.587275 0.696891 0.575034 0 0 0 0.00281905 l
+0.700327 0.587275 0.696569 0.593977 0 0 0 0.00281905 l
+-0.590665 0.276922 -0.586125 0.284563 0 0 0 0.00281905 l
+-0.590665 0.276922 -0.603329 0.274645 0 0 0 0.00281905 l
+0.268757 0.492305 0.282951 0.503955 0 0 0 0.00281905 l
+0.268757 0.492305 0.256363 0.497871 0 0 0 0.00281905 l
+-0.947983 -0.0873574 -0.936466 -0.106454 0 0 0 0.00281905 l
+-0.947983 -0.0873574 -0.948799 -0.0760186 0 0 0 0.00281905 l
+-0.0629643 0.332049 -0.0519356 0.32514 0 0 0 0.00281905 l
+-0.0629643 0.332049 -0.0714618 0.337184 0 0 0 0.00281905 l
+-0.284254 -0.619588 -0.27923 -0.630758 0 0 0 0.00281905 l
+-0.284254 -0.619588 -0.27926 -0.615004 0 0 0 0.00281905 l
+-0.284254 -0.619588 -0.290801 -0.618981 0 0 0 0.00281905 l
+-0.16075 -0.0598025 -0.143157 -0.0504802 0 0 0 0.00281905 l
+-0.16075 -0.0598025 -0.170001 -0.0653636 0 0 0 0.00281905 l
+-0.50619 -0.50291 -0.484935 -0.495707 0 0 0 0.00281905 l
+-0.50619 -0.50291 -0.514934 -0.501016 0 0 0 0.00281905 l
+0.400551 -0.0810123 0.401602 -0.0848418 0 0 0 0.00281905 l
+0.400551 -0.0810123 0.395912 -0.0766517 0 0 0 0.00281905 l
+0.033741 0.0175564 0.0323125 0.0216024 0 0 0 0.00281905 l
+0.725653 -0.263959 0.732757 -0.27178 0 0 0 0.00281905 l
+0.725653 -0.263959 0.710744 -0.274289 0 0 0 0.00281905 l
+0.658796 -0.0585182 0.667703 -0.0710971 0 0 0 0.00281905 l
+0.658796 -0.0585182 0.647748 -0.0480882 0 0 0 0.00281905 l
+0.658796 -0.0585182 0.644609 -0.0682438 0 0 0 0.00281905 l
+-0.188053 -0.599009 -0.198903 -0.597679 0 0 0 0.00281905 l
+-0.177367 -0.232214 -0.181904 -0.247208 0 0 0 0.00281905 l
+-0.177367 -0.232214 -0.174751 -0.228894 0 0 0 0.00281905 l
+-0.254132 -0.595057 -0.254477 -0.582653 0 0 0 0.00281905 l
+-0.254132 -0.595057 -0.253716 -0.599412 0 0 0 0.00281905 l
+0.424302 0.172199 0.428465 0.191523 0 0 0 0.00281905 l
+0.424302 0.172199 0.434828 0.160905 0 0 0 0.00281905 l
+0.424302 0.172199 0.412112 0.179162 0 0 0 0.00281905 l
+-0.190599 0.935061 -0.192892 0.935904 0 0 0 0.00281905 l
+-0.520343 0.418629 -0.509504 0.412853 0 0 0 0.00281905 l
+-0.520343 0.418629 -0.535567 0.41255 0 0 0 0.00281905 l
+-0.384444 0.839319 -0.391437 0.845703 0 0 0 0.00281905 l
+0.682591 -0.49324 0.694835 -0.479655 0 0 0 0.00281905 l
+0.107425 0.732874 0.110915 0.724717 0 0 0 0.00281905 l
+0.107425 0.732874 0.11017 0.737881 0 0 0 0.00281905 l
+0.107425 0.732874 0.0951225 0.733274 0 0 0 0.00281905 l
+0.0129909 -0.917216 0.0100471 -0.913308 0 0 0 0.00281905 l
+-0.223867 0.480294 -0.223461 0.478037 0 0 0 0.00281905 l
+-0.223867 0.480294 -0.229369 0.49219 0 0 0 0.00281905 l
+0.175755 -0.734076 0.172141 -0.727241 0 0 0 0.00281905 l
+0.175755 -0.734076 0.174112 -0.736465 0 0 0 0.00281905 l
+-0.0513189 0.0285547 -0.0476284 0.025398 0 0 0 0.00281905 l
+-0.0513189 0.0285547 -0.0580605 0.0194769 0 0 0 0.00281905 l
+0.43184 -0.176354 0.439982 -0.172934 0 0 0 0.00281905 l
+0.43184 -0.176354 0.416306 -0.179198 0 0 0 0.00281905 l
+0.725093 -0.047359 0.739169 -0.0447414 0 0 0 0.00281905 l
+0.725093 -0.047359 0.723069 -0.0595435 0 0 0 0.00281905 l
+0.725093 -0.047359 0.711151 -0.045666 0 0 0 0.00281905 l
+0.629366 -0.0795694 0.635447 -0.0942709 0 0 0 0.00281905 l
+0.629366 -0.0795694 0.624423 -0.0661264 0 0 0 0.00281905 l
+0.629366 -0.0795694 0.612565 -0.0862837 0 0 0 0.00281905 l
+-0.0255413 -0.157513 -0.0390996 -0.165077 0 0 0 0.00281905 l
+-0.325909 0.342977 -0.323431 0.34428 0 0 0 0.00281905 l
+-0.325909 0.342977 -0.325285 0.338269 0 0 0 0.00281905 l
+-0.0644906 -0.441927 -0.0740086 -0.437677 0 0 0 0.00281905 l
+-0.574672 -0.818349 -0.567876 -0.793593 0 0 0 0.00281905 l
+0.463116 -0.0856317 0.460064 -0.0965293 0 0 0 0.00281905 l
+0.463116 -0.0856317 0.462986 -0.078583 0 0 0 0.00281905 l
+0.00687329 -0.957147 0.00606472 -0.974154 0 0 0 0.00281905 l
+0.551717 0.712925 0.542171 0.714958 0 0 0 0.00281905 l
+-0.00882128 0.872963 -0.00540737 0.878479 0 0 0 0.00281905 l
+-0.00882128 0.872963 -0.0136998 0.864473 0 0 0 0.00281905 l
+-0.246058 0.393407 -0.245709 0.407393 0 0 0 0.00281905 l
+-0.246058 0.393407 -0.237583 0.392216 0 0 0 0.00281905 l
+-0.246058 0.393407 -0.24988 0.380791 0 0 0 0.00281905 l
+0.454287 0.750669 0.437309 0.747712 0 0 0 0.00281905 l
+0.225419 0.825442 0.237876 0.827168 0 0 0 0.00281905 l
+0.965689 0.0101854 0.978191 0.00579893 0 0 0 0.00281905 l
+0.965689 0.0101854 0.959013 0.00679028 0 0 0 0.00281905 l
+0.293751 -0.841402 0.307385 -0.827747 0 0 0 0.00281905 l
+0.293751 -0.841402 0.28883 -0.840054 0 0 0 0.00281905 l
+0.394768 -0.274789 0.400666 -0.275342 0 0 0 0.00281905 l
+0.394768 -0.274789 0.38586 -0.271413 0 0 0 0.00281905 l
+0.712591 -0.406759 0.718738 -0.388735 0 0 0 0.00281905 l
+0.712591 -0.406759 0.715525 -0.409416 0 0 0 0.00281905 l
+-0.0451477 -0.699731 -0.0271955 -0.699382 0 0 0 0.00281905 l
+-0.0451477 -0.699731 -0.0558546 -0.711844 0 0 0 0.00281905 l
+0.0502007 0.287193 0.0344999 0.278472 0 0 0 0.00281905 l
+0.0502007 0.287193 0.0571581 0.292384 0 0 0 0.00281905 l
+0.0502007 0.287193 0.0451443 0.294238 0 0 0 0.00281905 l
+-0.304021 -0.184733 -0.298834 -0.182428 0 0 0 0.00281905 l
+-0.864638 -0.49896 -0.849515 -0.508807 0 0 0 0.00281905 l
+-0.864638 -0.49896 -0.85085 -0.479579 0 0 0 0.00281905 l
+0.56387 -0.5582 0.564377 -0.553354 0 0 0 0.00281905 l
+0.56387 -0.5582 0.559422 -0.555839 0 0 0 0.00281905 l
+0.396719 -0.378362 0.407429 -0.378927 0 0 0 0.00281905 l
+0.396719 -0.378362 0.390928 -0.3771 0 0 0 0.00281905 l
+0.0879119 0.0484809 0.0827801 0.05847 0 0 0 0.00281905 l
+0.0879119 0.0484809 0.0998299 0.0455969 0 0 0 0.00281905 l
+0.0879119 0.0484809 0.0761971 0.0401935 0 0 0 0.00281905 l
+-0.0592845 0.186598 -0.0523878 0.175596 0 0 0 0.00281905 l
+-0.0592845 0.186598 -0.0673331 0.191848 0 0 0 0.00281905 l
+0.0160789 0.198676 0.0324047 0.19896 0 0 0 0.00281905 l
+0.0160789 0.198676 0.01002 0.206782 0 0 0 0.00281905 l
+0.0160789 0.198676 0.0153318 0.197463 0 0 0 0.00281905 l
+-0.218732 -0.934028 -0.223605 -0.933207 0 0 0 0.00281905 l
+-0.147642 -0.0374651 -0.134892 -0.0247255 0 0 0 0.00281905 l
+-0.147642 -0.0374651 -0.143157 -0.0504802 0 0 0 0.00281905 l
+-0.273266 -0.227016 -0.256803 -0.219258 0 0 0 0.00281905 l
+-0.273266 -0.227016 -0.288285 -0.227703 0 0 0 0.00281905 l
+0.533279 -0.390751 0.535252 -0.380814 0 0 0 0.00281905 l
+0.533279 -0.390751 0.523326 -0.387152 0 0 0 0.00281905 l
+-0.541549 0.64569 -0.544495 0.652729 0 0 0 0.00281905 l
+-0.295214 0.0835888 -0.279879 0.0818276 0 0 0 0.00281905 l
+-0.295214 0.0835888 -0.307804 0.0905935 0 0 0 0.00281905 l
+-0.360235 0.357744 -0.360712 0.358066 0 0 0 0.00281905 l
+-0.360235 0.357744 -0.355529 0.35918 0 0 0 0.00281905 l
+-0.343959 0.0238525 -0.359981 0.0187121 0 0 0 0.00281905 l
+-0.124845 -0.483509 -0.11775 -0.480488 0 0 0 0.00281905 l
+-0.71721 0.345414 -0.700504 0.348021 0 0 0 0.00281905 l
+-0.71721 0.345414 -0.714133 0.336421 0 0 0 0.00281905 l
+-0.71721 0.345414 -0.730169 0.353128 0 0 0 0.00281905 l
+0.500963 0.763243 0.510198 0.758131 0 0 0 0.00281905 l
+0.500963 0.763243 0.487315 0.755318 0 0 0 0.00281905 l
+-0.00292038 0.77745 -0.00589301 0.785368 0 0 0 0.00281905 l
+0.914172 -0.37388 0.92552 -0.368163 0 0 0 0.00281905 l
+0.914172 -0.37388 0.920339 -0.380327 0 0 0 0.00281905 l
+0.914172 -0.37388 0.90764 -0.372444 0 0 0 0.00281905 l
+0.434828 0.160905 0.424302 0.172199 0 0 0 0.00281905 l
+0.434828 0.160905 0.439543 0.156688 0 0 0 0.00281905 l
+0.298899 0.0387407 0.296858 0.0573792 0 0 0 0.00281905 l
+0.298899 0.0387407 0.295793 0.0293948 0 0 0 0.00281905 l
+0.656864 0.36066 0.670885 0.366732 0 0 0 0.00281905 l
+0.656864 0.36066 0.642694 0.357919 0 0 0 0.00281905 l
+0.89353 -0.165311 0.90114 -0.168939 0 0 0 0.00281905 l
+0.89353 -0.165311 0.883458 -0.164857 0 0 0 0.00281905 l
+0.261222 -0.693823 0.255973 -0.682443 0 0 0 0.00281905 l
+0.261222 -0.693823 0.261532 -0.695079 0 0 0 0.00281905 l
+0.530834 -0.671606 0.531189 -0.68349 0 0 0 0.00281905 l
+0.530834 -0.671606 0.532209 -0.652247 0 0 0 0.00281905 l
+0.530834 -0.671606 0.513061 -0.66987 0 0 0 0.00281905 l
+-0.312765 -0.175179 -0.319487 -0.160023 0 0 0 0.00281905 l
+-0.312765 -0.175179 -0.304515 -0.174461 0 0 0 0.00281905 l
+-0.312765 -0.175179 -0.318006 -0.187835 0 0 0 0.00281905 l
+0.748759 0.385939 0.761549 0.37395 0 0 0 0.00281905 l
+0.748759 0.385939 0.737303 0.380624 0 0 0 0.00281905 l
+0.748759 0.385939 0.754044 0.390038 0 0 0 0.00281905 l
+0.582244 0.438478 0.582928 0.442041 0 0 0 0.00281905 l
+0.582244 0.438478 0.575804 0.426993 0 0 0 0.00281905 l
+0.78403 0.146757 0.788023 0.145556 0 0 0 0.00281905 l
+0.78403 0.146757 0.768058 0.141918 0 0 0 0.00281905 l
+-0.729275 0.0833788 -0.721289 0.0773936 0 0 0 0.00281905 l
+0.588372 0.104899 0.602365 0.0965569 0 0 0 0.00281905 l
+0.588372 0.104899 0.584309 0.089887 0 0 0 0.00281905 l
+0.588372 0.104899 0.591035 0.111227 0 0 0 0.00281905 l
+0.588372 0.104899 0.574651 0.104898 0 0 0 0.00281905 l
+0.693256 0.609025 0.696569 0.593977 0 0 0 0.00281905 l
+0.693256 0.609025 0.677766 0.609084 0 0 0 0.00281905 l
+0.801828 0.303314 0.807991 0.312194 0 0 0 0.00281905 l
+0.801828 0.303314 0.810568 0.299089 0 0 0 0.00281905 l
+0.801828 0.303314 0.792462 0.290358 0 0 0 0.00281905 l
+0.0179357 0.899116 0.00834311 0.92391 0 0 0 0.00281905 l
+0.0179357 0.899116 0.0310535 0.900366 0 0 0 0.00281905 l
+-0.800987 0.350457 -0.797912 0.353186 0 0 0 0.00281905 l
+-0.800987 0.350457 -0.800605 0.341635 0 0 0 0.00281905 l
+0.631603 0.763807 0.637078 0.764563 0 0 0 0.00281905 l
+0.631603 0.763807 0.627785 0.749832 0 0 0 0.00281905 l
+0.631603 0.763807 0.621142 0.767257 0 0 0 0.00281905 l
+0.276906 -0.62408 0.272076 -0.637286 0 0 0 0.00281905 l
+0.276906 -0.62408 0.286494 -0.623691 0 0 0 0.00281905 l
+0.276906 -0.62408 0.25921 -0.615296 0 0 0 0.00281905 l
+0.716267 0.549514 0.723098 0.566388 0 0 0 0.00281905 l
+0.716267 0.549514 0.725238 0.540268 0 0 0 0.00281905 l
+0.716267 0.549514 0.704437 0.534094 0 0 0 0.00281905 l
+-0.0018897 -0.0400022 -0.0189583 -0.0261561 0 0 0 0.00281905 l
+0.846472 0.0338629 0.851114 0.0335093 0 0 0 0.00281905 l
+0.846472 0.0338629 0.843335 0.0504197 0 0 0 0.00281905 l
+0.846472 0.0338629 0.838387 0.0335367 0 0 0 0.00281905 l
+0.496382 -0.0258005 0.506362 -0.0295732 0 0 0 0.00281905 l
+0.496382 -0.0258005 0.499631 -0.0203278 0 0 0 0.00281905 l
+-0.245941 -0.159855 -0.249328 -0.151979 0 0 0 0.00281905 l
+-0.245941 -0.159855 -0.235758 -0.15684 0 0 0 0.00281905 l
+-0.232741 0.508809 -0.217134 0.511329 0 0 0 0.00281905 l
+-0.232741 0.508809 -0.247128 0.512753 0 0 0 0.00281905 l
+0.814299 0.576747 0.811635 0.57243 0 0 0 0.00281905 l
+-0.424986 -0.527468 -0.422659 -0.538825 0 0 0 0.00281905 l
+0.159651 -0.111034 0.153758 -0.116353 0 0 0 0.00281905 l
+0.509363 -0.429853 0.511902 -0.43237 0 0 0 0.00281905 l
+0.509363 -0.429853 0.495719 -0.433143 0 0 0 0.00281905 l
+0.109438 0.601087 0.0982021 0.622165 0 0 0 0.00281905 l
+0.169357 0.925219 0.173187 0.928945 0 0 0 0.00281905 l
+0.169357 0.925219 0.164523 0.921324 0 0 0 0.00281905 l
+0.955876 0.237263 0.95727 0.226526 0 0 0 0.00281905 l
+-0.0355175 -0.536145 -0.0355415 -0.528705 0 0 0 0.00281905 l
+-0.0355175 -0.536145 -0.0235383 -0.535621 0 0 0 0.00281905 l
+-0.0355175 -0.536145 -0.0368405 -0.53993 0 0 0 0.00281905 l
+0.260465 -0.952124 0.254885 -0.94739 0 0 0 0.00281905 l
+-0.893486 0.403122 -0.893552 0.407985 0 0 0 0.00281905 l
+-0.909386 -0.0866346 -0.907437 -0.0701222 0 0 0 0.00281905 l
+-0.909386 -0.0866346 -0.913475 -0.0886517 0 0 0 0.00281905 l
+0.875383 0.0989741 0.872086 0.105794 0 0 0 0.00281905 l
+0.875383 0.0989741 0.893483 0.0929721 0 0 0 0.00281905 l
+0.875383 0.0989741 0.872109 0.0907807 0 0 0 0.00281905 l
+0.739164 0.615745 0.745217 0.620205 0 0 0 0.00281905 l
+0.739164 0.615745 0.73072 0.611074 0 0 0 0.00281905 l
+0.223491 0.955471 0.203703 0.977787 0 0 0 0.00281905 l
+0.223491 0.955471 0.228604 0.958146 0 0 0 0.00281905 l
+0.223491 0.955471 0.216719 0.940047 0 0 0 0.00281905 l
+0.796831 0.317673 0.807991 0.312194 0 0 0 0.00281905 l
+0.272856 -0.798442 0.273 -0.806206 0 0 0 0.00281905 l
+0.272856 -0.798442 0.275646 -0.796359 0 0 0 0.00281905 l
+0.39891 0.663963 0.408213 0.676786 0 0 0 0.00281905 l
+0.569759 0.287961 0.563705 0.298463 0 0 0 0.00281905 l
+0.569759 0.287961 0.586561 0.287877 0 0 0 0.00281905 l
+-0.0595936 0.780041 -0.0499802 0.779065 0 0 0 0.00281905 l
+-0.0595936 0.780041 -0.068691 0.787664 0 0 0 0.00281905 l
+-0.558546 0.399118 -0.548876 0.390544 0 0 0 0.00281905 l
+0.243781 -0.447138 0.240197 -0.443214 0 0 0 0.00281905 l
+0.293338 -0.504579 0.306559 -0.504239 0 0 0 0.00281905 l
+0.293338 -0.504579 0.288273 -0.515839 0 0 0 0.00281905 l
+0.293338 -0.504579 0.287347 -0.490159 0 0 0 0.00281905 l
+0.137217 0.33264 0.145425 0.31892 0 0 0 0.00281905 l
+0.137217 0.33264 0.151382 0.336017 0 0 0 0.00281905 l
+0.137217 0.33264 0.128881 0.336814 0 0 0 0.00281905 l
+0.249263 -0.0928167 0.265029 -0.099268 0 0 0 0.00281905 l
+0.249263 -0.0928167 0.249012 -0.0854829 0 0 0 0.00281905 l
+0.807522 -0.207394 0.797051 -0.186499 0 0 0 0.00281905 l
+0.807522 -0.207394 0.810455 -0.213929 0 0 0 0.00281905 l
+-0.227558 -0.238459 -0.209381 -0.242097 0 0 0 0.00281905 l
+-0.227558 -0.238459 -0.234984 -0.234214 0 0 0 0.00281905 l
+0.819606 -0.33773 0.812091 -0.349678 0 0 0 0.00281905 l
+0.819606 -0.33773 0.821324 -0.32456 0 0 0 0.00281905 l
+0.819606 -0.33773 0.836518 -0.340642 0 0 0 0.00281905 l
+0.29691 0.76423 0.298209 0.773204 0 0 0 0.00281905 l
+0.29691 0.76423 0.29728 0.764129 0 0 0 0.00281905 l
+-0.00771786 -0.611379 0.0150254 -0.606744 0 0 0 0.00281905 l
+-0.00771786 -0.611379 -0.0207099 -0.624262 0 0 0 0.00281905 l
+-0.171041 -0.895712 -0.168078 -0.891159 0 0 0 0.00281905 l
+-0.171041 -0.895712 -0.178179 -0.904615 0 0 0 0.00281905 l
+0.177317 -0.423114 0.167167 -0.411072 0 0 0 0.00281905 l
+0.177317 -0.423114 0.181076 -0.43013 0 0 0 0.00281905 l
+-0.653576 0.374083 -0.64613 0.374128 0 0 0 0.00281905 l
+-0.653576 0.374083 -0.66817 0.384922 0 0 0 0.00281905 l
+0.141393 0.905413 0.141194 0.901489 0 0 0 0.00281905 l
+0.141393 0.905413 0.148935 0.908336 0 0 0 0.00281905 l
+0.215932 0.475674 0.215908 0.458661 0 0 0 0.00281905 l
+0.215932 0.475674 0.218598 0.477351 0 0 0 0.00281905 l
+-0.526661 0.333 -0.52491 0.316803 0 0 0 0.00281905 l
+-0.0384719 -0.824974 -0.0363477 -0.814841 0 0 0 0.00281905 l
+-0.0384719 -0.824974 -0.0444955 -0.828437 0 0 0 0.00281905 l
+-0.943287 -0.0224447 -0.940218 -0.0221952 0 0 0 0.00281905 l
+-0.943287 -0.0224447 -0.949518 -0.029842 0 0 0 0.00281905 l
+0.326144 -0.682206 0.335699 -0.671492 0 0 0 0.00281905 l
+0.326144 -0.682206 0.311985 -0.689507 0 0 0 0.00281905 l
+0.983043 -0.154139 0.980731 -0.148243 0 0 0 0.00281905 l
+0.983043 -0.154139 0.981781 -0.155444 0 0 0 0.00281905 l
+0.444061 -0.65849 0.444562 -0.652983 0 0 0 0.00281905 l
+0.444061 -0.65849 0.43571 -0.669646 0 0 0 0.00281905 l
+-0.0759408 0.000703685 -0.0803243 0.00181404 0 0 0 0.00281905 l
+0.687533 -0.540981 0.691927 -0.52702 0 0 0 0.00281905 l
+0.687533 -0.540981 0.691265 -0.542416 0 0 0 0.00281905 l
+0.687533 -0.540981 0.668486 -0.556291 0 0 0 0.00281905 l
+0.0507665 0.706029 0.0498665 0.716211 0 0 0 0.00281905 l
+0.0507665 0.706029 0.0493959 0.699749 0 0 0 0.00281905 l
+-0.719813 -0.136555 -0.71874 -0.137247 0 0 0 0.00281905 l
+-0.719813 -0.136555 -0.718933 -0.132526 0 0 0 0.00281905 l
+0.0860354 0.408903 0.0872514 0.418275 0 0 0 0.00281905 l
+0.0860354 0.408903 0.0975184 0.399122 0 0 0 0.00281905 l
+0.268922 0.303004 0.273033 0.317818 0 0 0 0.00281905 l
+0.268922 0.303004 0.265522 0.301819 0 0 0 0.00281905 l
+0.119458 0.891119 0.108754 0.893897 0 0 0 0.00281905 l
+0.38771 0.0490325 0.389025 0.0481102 0 0 0 0.00281905 l
+0.468713 -0.469332 0.468978 -0.485117 0 0 0 0.00281905 l
+0.468713 -0.469332 0.458926 -0.471826 0 0 0 0.00281905 l
+-0.0770816 -0.0583641 -0.0725879 -0.0436994 0 0 0 0.00281905 l
+-0.0770816 -0.0583641 -0.0712478 -0.0671511 0 0 0 0.00281905 l
+-0.103686 0.169704 -0.104171 0.178698 0 0 0 0.00281905 l
+-0.103686 0.169704 -0.111598 0.173029 0 0 0 0.00281905 l
+0.0209686 -0.671304 0.0169379 -0.675838 0 0 0 0.00281905 l
+0.0209686 -0.671304 0.0194388 -0.668179 0 0 0 0.00281905 l
+0.490402 -0.835166 0.491959 -0.835332 0 0 0 0.00281905 l
+-0.206498 -0.978179 -0.187192 -0.968067 0 0 0 0.00281905 l
+0.77699 -0.377769 0.776361 -0.373834 0 0 0 0.00281905 l
+-0.514843 -0.0302298 -0.515578 -0.0129698 0 0 0 0.00281905 l
+-0.514843 -0.0302298 -0.509276 -0.0330108 0 0 0 0.00281905 l
+-0.514843 -0.0302298 -0.521767 -0.0299253 0 0 0 0.00281905 l
+-0.355631 -0.870232 -0.35577 -0.873098 0 0 0 0.00281905 l
+-0.355631 -0.870232 -0.349231 -0.855393 0 0 0 0.00281905 l
+-0.355631 -0.870232 -0.366981 -0.867016 0 0 0 0.00281905 l
+-0.837752 -0.161693 -0.818944 -0.163808 0 0 0 0.00281905 l
+-0.837752 -0.161693 -0.840519 -0.162066 0 0 0 0.00281905 l
+0.693523 0.175183 0.708082 0.181733 0 0 0 0.00281905 l
+0.693523 0.175183 0.682151 0.176683 0 0 0 0.00281905 l
+-0.179255 0.322144 -0.166842 0.314475 0 0 0 0.00281905 l
+-0.179255 0.322144 -0.172942 0.329416 0 0 0 0.00281905 l
+0.347272 -0.372483 0.346466 -0.38217 0 0 0 0.00281905 l
+0.347272 -0.372483 0.354671 -0.366082 0 0 0 0.00281905 l
+0.347272 -0.372483 0.332672 -0.372989 0 0 0 0.00281905 l
+0.141916 -0.345739 0.153545 -0.334367 0 0 0 0.00281905 l
+0.141916 -0.345739 0.14889 -0.354705 0 0 0 0.00281905 l
+0.141916 -0.345739 0.131629 -0.335896 0 0 0 0.00281905 l
+-0.256893 0.298169 -0.25233 0.288453 0 0 0 0.00281905 l
+-0.515154 0.45609 -0.50986 0.456723 0 0 0 0.00281905 l
+-0.515154 0.45609 -0.520864 0.45846 0 0 0 0.00281905 l
+-0.459085 0.0310881 -0.443423 0.0367178 0 0 0 0.00281905 l
+-0.459085 0.0310881 -0.457981 0.0271486 0 0 0 0.00281905 l
+-0.459085 0.0310881 -0.472835 0.0365135 0 0 0 0.00281905 l
+0.226128 0.00806809 0.230637 -0.00840827 0 0 0 0.00281905 l
+0.226128 0.00806809 0.225665 0.0102632 0 0 0 0.00281905 l
+-0.798348 -0.20823 -0.797881 -0.206795 0 0 0 0.00281905 l
+-0.175147 -0.83167 -0.184714 -0.815567 0 0 0 0.00281905 l
+-0.35865 -0.0668503 -0.356974 -0.0507432 0 0 0 0.00281905 l
+-0.35865 -0.0668503 -0.347333 -0.0661738 0 0 0 0.00281905 l
+0.546186 -0.0681896 0.542691 -0.053891 0 0 0 0.00281905 l
+-0.00589439 -0.837937 -0.0154638 -0.82834 0 0 0 0.00281905 l
+-0.00589439 -0.837937 -0.0169125 -0.844514 0 0 0 0.00281905 l
+0.443296 -0.210007 0.441034 -0.210783 0 0 0 0.00281905 l
+0.687278 0.2497 0.688548 0.244295 0 0 0 0.00281905 l
+0.687278 0.2497 0.670672 0.252784 0 0 0 0.00281905 l
+0.704229 -0.016223 0.696638 -0.00812394 0 0 0 0.00281905 l
+-0.150786 -0.805208 -0.137801 -0.799296 0 0 0 0.00281905 l
+-0.150786 -0.805208 -0.151604 -0.812524 0 0 0 0.00281905 l
+-0.595312 0.548189 -0.595584 0.540501 0 0 0 0.00281905 l
+-0.595312 0.548189 -0.604974 0.554154 0 0 0 0.00281905 l
+-0.613143 -0.000416248 -0.611013 -0.0121431 0 0 0 0.00281905 l
+-0.613143 -0.000416248 -0.62697 -0.00054444 0 0 0 0.00281905 l
+0.565664 -0.553334 0.564377 -0.553354 0 0 0 0.00281905 l
+-0.577564 -0.727528 -0.579277 -0.711791 0 0 0 0.00281905 l
+-0.577564 -0.727528 -0.566645 -0.727059 0 0 0 0.00281905 l
+-0.577564 -0.727528 -0.582217 -0.736283 0 0 0 0.00281905 l
+0.474669 -0.099354 0.483255 -0.0982571 0 0 0 0.00281905 l
+0.474669 -0.099354 0.467921 -0.103727 0 0 0 0.00281905 l
+0.692742 0.432786 0.695944 0.414457 0 0 0 0.00281905 l
+0.692742 0.432786 0.683102 0.445595 0 0 0 0.00281905 l
+-0.146203 0.654434 -0.141452 0.671772 0 0 0 0.00281905 l
+-0.146203 0.654434 -0.139998 0.647854 0 0 0 0.00281905 l
+-0.146203 0.654434 -0.14996 0.650551 0 0 0 0.00281905 l
+-0.314819 -0.379943 -0.307416 -0.377931 0 0 0 0.00281905 l
+-0.314819 -0.379943 -0.323343 -0.380418 0 0 0 0.00281905 l
+0.0276884 -0.68313 0.0389374 -0.686031 0 0 0 0.00281905 l
+0.0276884 -0.68313 0.015095 -0.680902 0 0 0 0.00281905 l
+0.0535099 0.968753 0.0550421 0.963334 0 0 0 0.00281905 l
+0.291978 0.942759 0.28719 0.944167 0 0 0 0.00281905 l
+0.260778 -0.308209 0.253373 -0.30039 0 0 0 0.00281905 l
+0.260778 -0.308209 0.257553 -0.314425 0 0 0 0.00281905 l
+-0.533031 -0.717465 -0.538745 -0.703241 0 0 0 0.00281905 l
+-0.0638413 0.392135 -0.0484316 0.387525 0 0 0 0.00281905 l
+-0.0638413 0.392135 -0.0668379 0.376319 0 0 0 0.00281905 l
+-0.0638413 0.392135 -0.0689616 0.395774 0 0 0 0.00281905 l
+0.654959 0.182825 0.664886 0.175773 0 0 0 0.00281905 l
+0.654959 0.182825 0.648307 0.178832 0 0 0 0.00281905 l
+-0.358621 -0.851975 -0.354072 -0.850903 0 0 0 0.00281905 l
+0.437674 -0.607186 0.444944 -0.612455 0 0 0 0.00281905 l
+-0.583614 0.630635 -0.575832 0.639813 0 0 0 0.00281905 l
+-0.583614 0.630635 -0.59591 0.620012 0 0 0 0.00281905 l
+0.571978 0.663119 0.577515 0.669629 0 0 0 0.00281905 l
+0.11276 0.636198 0.110494 0.649964 0 0 0 0.00281905 l
+0.307258 0.00531227 0.30998 0.00326442 0 0 0 0.00281905 l
+0.307258 0.00531227 0.304682 0.0049123 0 0 0 0.00281905 l
+-0.0234151 0.942981 -0.00657777 0.940991 0 0 0 0.00281905 l
+-0.0234151 0.942981 -0.0360401 0.95645 0 0 0 0.00281905 l
+-0.530217 -0.568193 -0.514618 -0.557571 0 0 0 0.00281905 l
+-0.530217 -0.568193 -0.538924 -0.564821 0 0 0 0.00281905 l
+-0.867904 -0.305847 -0.866708 -0.286972 0 0 0 0.00281905 l
+-0.894323 0.117195 -0.885444 0.102265 0 0 0 0.00281905 l
+-0.894323 0.117195 -0.905777 0.118332 0 0 0 0.00281905 l
+0.654281 0.3051 0.652656 0.300091 0 0 0 0.00281905 l
+0.654281 0.3051 0.655731 0.307494 0 0 0 0.00281905 l
+-0.108743 -0.0859735 -0.100826 -0.0681722 0 0 0 0.00281905 l
+-0.108743 -0.0859735 -0.0982648 -0.0988496 0 0 0 0.00281905 l
+-0.108743 -0.0859735 -0.122906 -0.10077 0 0 0 0.00281905 l
+-0.554198 -0.0564833 -0.561486 -0.0741459 0 0 0 0.00281905 l
+-0.554198 -0.0564833 -0.548778 -0.0491475 0 0 0 0.00281905 l
+0.737446 -0.595536 0.737894 -0.589556 0 0 0 0.00281905 l
+0.737446 -0.595536 0.749658 -0.598866 0 0 0 0.00281905 l
+-0.279606 0.0906622 -0.281667 0.102973 0 0 0 0.00281905 l
+-0.279606 0.0906622 -0.279879 0.0818276 0 0 0 0.00281905 l
+-0.446199 0.844963 -0.44041 0.859266 0 0 0 0.00281905 l
+-0.446199 0.844963 -0.465504 0.857236 0 0 0 0.00281905 l
+0.542777 0.0454417 0.533971 0.0612763 0 0 0 0.00281905 l
+0.542777 0.0454417 0.545467 0.0352446 0 0 0 0.00281905 l
+-0.0344007 0.973191 -0.0360401 0.95645 0 0 0 0.00281905 l
+-0.0344007 0.973191 -0.0300682 0.991597 0 0 0 0.00281905 l
+0.798083 -0.111485 0.791927 -0.0975185 0 0 0 0.00281905 l
+0.798083 -0.111485 0.809168 -0.108243 0 0 0 0.00281905 l
+0.798083 -0.111485 0.794321 -0.117049 0 0 0 0.00281905 l
+0.069758 0.313959 0.0728576 0.319594 0 0 0 0.00281905 l
+0.069758 0.313959 0.0670361 0.313223 0 0 0 0.00281905 l
+-0.765885 0.461176 -0.764051 0.463369 0 0 0 0.00281905 l
+-0.765885 0.461176 -0.768565 0.464627 0 0 0 0.00281905 l
+-0.394173 0.524626 -0.395353 0.51913 0 0 0 0.00281905 l
+-0.394173 0.524626 -0.386923 0.531928 0 0 0 0.00281905 l
+0.927389 -0.319183 0.929268 -0.308711 0 0 0 0.00281905 l
+0.927389 -0.319183 0.941254 -0.324092 0 0 0 0.00281905 l
+-0.74445 0.541903 -0.730443 0.537811 0 0 0 0.00281905 l
+-0.74445 0.541903 -0.745795 0.53071 0 0 0 0.00281905 l
+0.532923 -0.139301 0.529609 -0.147317 0 0 0 0.00281905 l
+0.532923 -0.139301 0.5399 -0.135484 0 0 0 0.00281905 l
+0.532923 -0.139301 0.521828 -0.132636 0 0 0 0.00281905 l
+-0.198886 -0.811867 -0.208438 -0.827146 0 0 0 0.00281905 l
+-0.198886 -0.811867 -0.184714 -0.815567 0 0 0 0.00281905 l
+-0.198886 -0.811867 -0.198065 -0.802898 0 0 0 0.00281905 l
+-0.198886 -0.811867 -0.211231 -0.808719 0 0 0 0.00281905 l
+-0.535415 -0.824434 -0.526145 -0.8385 0 0 0 0.00281905 l
+-0.535415 -0.824434 -0.53066 -0.818327 0 0 0 0.00281905 l
+-0.642762 -0.613321 -0.634614 -0.598403 0 0 0 0.00281905 l
+-0.642762 -0.613321 -0.634014 -0.620446 0 0 0 0.00281905 l
+-0.642762 -0.613321 -0.656992 -0.619102 0 0 0 0.00281905 l
+-0.231573 0.257244 -0.233851 0.271721 0 0 0 0.00281905 l
+-0.231573 0.257244 -0.236085 0.238986 0 0 0 0.00281905 l
+-0.297159 0.602232 -0.29672 0.612221 0 0 0 0.00281905 l
+-0.297159 0.602232 -0.304795 0.602119 0 0 0 0.00281905 l
+0.370553 0.761681 0.38624 0.772718 0 0 0 0.00281905 l
+0.370553 0.761681 0.349328 0.760589 0 0 0 0.00281905 l
+0.490857 0.54815 0.494642 0.539123 0 0 0 0.00281905 l
+0.377868 0.658179 0.38101 0.670285 0 0 0 0.00281905 l
+0.377868 0.658179 0.375036 0.650233 0 0 0 0.00281905 l
+-0.544495 0.652729 -0.536132 0.653475 0 0 0 0.00281905 l
+-0.544495 0.652729 -0.541549 0.64569 0 0 0 0.00281905 l
+-0.544495 0.652729 -0.550582 0.651462 0 0 0 0.00281905 l
+0.478424 -0.80953 0.482886 -0.8145 0 0 0 0.00281905 l
+0.478424 -0.80953 0.465745 -0.809853 0 0 0 0.00281905 l
+-0.140421 0.151237 -0.134417 0.134286 0 0 0 0.00281905 l
+-0.140421 0.151237 -0.143347 0.160469 0 0 0 0.00281905 l
+-0.228836 -0.287647 -0.233367 -0.276709 0 0 0 0.00281905 l
+0.13811 -0.24488 0.139648 -0.240502 0 0 0 0.00281905 l
+0.13811 -0.24488 0.134511 -0.262417 0 0 0 0.00281905 l
+0.256964 0.414008 0.257379 0.427235 0 0 0 0.00281905 l
+0.256964 0.414008 0.270193 0.406056 0 0 0 0.00281905 l
+0.256964 0.414008 0.24714 0.401271 0 0 0 0.00281905 l
+-0.859048 0.154908 -0.851468 0.173907 0 0 0 0.00281905 l
+-0.859048 0.154908 -0.847293 0.146122 0 0 0 0.00281905 l
+-0.859048 0.154908 -0.862695 0.144242 0 0 0 0.00281905 l
+0.0363339 0.730477 0.0383029 0.728525 0 0 0 0.00281905 l
+0.0363339 0.730477 0.0253106 0.739951 0 0 0 0.00281905 l
+-0.143347 0.160469 -0.140421 0.151237 0 0 0 0.00281905 l
+-0.143347 0.160469 -0.139834 0.171303 0 0 0 0.00281905 l
+-0.143347 0.160469 -0.147938 0.158703 0 0 0 0.00281905 l
+0.527305 0.443712 0.534148 0.436348 0 0 0 0.00281905 l
+0.527305 0.443712 0.531514 0.446818 0 0 0 0.00281905 l
+0.527305 0.443712 0.517393 0.454175 0 0 0 0.00281905 l
+-0.148361 0.425375 -0.140204 0.428698 0 0 0 0.00281905 l
+-0.148361 0.425375 -0.157835 0.423078 0 0 0 0.00281905 l
+-0.340426 -0.173472 -0.33107 -0.185575 0 0 0 0.00281905 l
+-0.340426 -0.173472 -0.336929 -0.162724 0 0 0 0.00281905 l
+-0.25405 0.522235 -0.247128 0.512753 0 0 0 0.00281905 l
+-0.25405 0.522235 -0.255371 0.540381 0 0 0 0.00281905 l
+-0.25405 0.522235 -0.266237 0.515397 0 0 0 0.00281905 l
+-0.646701 0.365267 -0.64613 0.374128 0 0 0 0.00281905 l
+-0.646701 0.365267 -0.625335 0.367173 0 0 0 0.00281905 l
+-0.189472 0.36352 -0.179725 0.361433 0 0 0 0.00281905 l
+-0.189472 0.36352 -0.191713 0.365204 0 0 0 0.00281905 l
+-0.295849 0.029227 -0.295773 0.0305051 0 0 0 0.00281905 l
+-0.295849 0.029227 -0.293584 0.0196004 0 0 0 0.00281905 l
+-0.658286 -0.148888 -0.661308 -0.161431 0 0 0 0.00281905 l
+-0.658286 -0.148888 -0.651433 -0.148657 0 0 0 0.00281905 l
+-0.658286 -0.148888 -0.670146 -0.142618 0 0 0 0.00281905 l
+-0.209435 0.097832 -0.191288 0.0943496 0 0 0 0.00281905 l
+-0.209435 0.097832 -0.225564 0.0998431 0 0 0 0.00281905 l
+-0.391268 -0.845879 -0.385558 -0.832888 0 0 0 0.00281905 l
+-0.391268 -0.845879 -0.38014 -0.846584 0 0 0 0.00281905 l
+-0.264194 0.547573 -0.260016 0.543852 0 0 0 0.00281905 l
+-0.264194 0.547573 -0.259983 0.556263 0 0 0 0.00281905 l
+-0.264194 0.547573 -0.285823 0.541146 0 0 0 0.00281905 l
+-0.511312 0.103497 -0.5104 0.0955515 0 0 0 0.00281905 l
+-0.322426 0.913333 -0.314982 0.922324 0 0 0 0.00281905 l
+-0.649426 -0.718211 -0.645524 -0.718283 0 0 0 0.00281905 l
+-0.649426 -0.718211 -0.656915 -0.725085 0 0 0 0.00281905 l
+0.263049 0.0552656 0.256342 0.0400094 0 0 0 0.00281905 l
+0.955776 -0.269906 0.954443 -0.292795 0 0 0 0.00281905 l
+-0.90215 -0.265555 -0.886435 -0.270097 0 0 0 0.00281905 l
+-0.90215 -0.265555 -0.907259 -0.248572 0 0 0 0.00281905 l
+0.756068 0.198626 0.764849 0.207012 0 0 0 0.00281905 l
+0.756068 0.198626 0.752232 0.208245 0 0 0 0.00281905 l
+-0.257268 -0.0410096 -0.238827 -0.0455218 0 0 0 0.00281905 l
+-0.257268 -0.0410096 -0.266263 -0.0579224 0 0 0 0.00281905 l
+0.196638 -0.693142 0.200784 -0.67561 0 0 0 0.00281905 l
+0.196638 -0.693142 0.20298 -0.694144 0 0 0 0.00281905 l
+0.196638 -0.693142 0.187962 -0.696126 0 0 0 0.00281905 l
+0.61364 0.601569 0.617278 0.611755 0 0 0 0.00281905 l
+-0.0932397 0.680809 -0.0852581 0.683158 0 0 0 0.00281905 l
+-0.0932397 0.680809 -0.0990284 0.687836 0 0 0 0.00281905 l
+0.189133 -0.644477 0.198149 -0.652933 0 0 0 0.00281905 l
+0.189133 -0.644477 0.181269 -0.639778 0 0 0 0.00281905 l
+0.203703 0.977787 0.223491 0.955471 0 0 0 0.00281905 l
+0.203703 0.977787 0.189989 0.968226 0 0 0 0.00281905 l
+0.403358 -0.580276 0.411817 -0.566864 0 0 0 0.00281905 l
+0.403358 -0.580276 0.396847 -0.582953 0 0 0 0.00281905 l
+-0.207109 0.195611 -0.196846 0.205775 0 0 0 0.00281905 l
+-0.207109 0.195611 -0.20441 0.191311 0 0 0 0.00281905 l
+-0.207109 0.195611 -0.222725 0.190309 0 0 0 0.00281905 l
+-0.295306 0.704521 -0.293769 0.712577 0 0 0 0.00281905 l
+-0.295306 0.704521 -0.292166 0.698567 0 0 0 0.00281905 l
+-0.0985346 -0.288372 -0.0856975 -0.276819 0 0 0 0.00281905 l
+-0.0985346 -0.288372 -0.108028 -0.296534 0 0 0 0.00281905 l
+-0.249368 -0.685586 -0.242914 -0.678739 0 0 0 0.00281905 l
+-0.249368 -0.685586 -0.260987 -0.69546 0 0 0 0.00281905 l
+-0.249368 -0.685586 -0.262012 -0.679304 0 0 0 0.00281905 l
+-0.386243 0.750239 -0.384989 0.757887 0 0 0 0.00281905 l
+-0.386243 0.750239 -0.380806 0.747748 0 0 0 0.00281905 l
+-0.386243 0.750239 -0.389394 0.751163 0 0 0 0.00281905 l
+0.469155 -0.250665 0.469928 -0.260851 0 0 0 0.00281905 l
+0.469155 -0.250665 0.47756 -0.243834 0 0 0 0.00281905 l
+0.793747 -0.0424008 0.780563 -0.0384472 0 0 0 0.00281905 l
+0.362421 -0.293309 0.368044 -0.286922 0 0 0 0.00281905 l
+0.362421 -0.293309 0.357924 -0.295427 0 0 0 0.00281905 l
+-0.137867 -0.797582 -0.121946 -0.793189 0 0 0 0.00281905 l
+-0.137867 -0.797582 -0.137801 -0.799296 0 0 0 0.00281905 l
+-0.868072 0.271042 -0.856665 0.259754 0 0 0 0.00281905 l
+-0.868072 0.271042 -0.87751 0.276645 0 0 0 0.00281905 l
+0.16352 -0.545326 0.159696 -0.55807 0 0 0 0.00281905 l
+0.16352 -0.545326 0.163507 -0.544853 0 0 0 0.00281905 l
+0.722292 -0.558514 0.697066 -0.56754 0 0 0 0.00281905 l
+-0.155791 -0.981737 -0.156711 -0.963087 0 0 0 0.00281905 l
+-0.155791 -0.981737 -0.172394 -0.981374 0 0 0 0.00281905 l
+0.381545 0.0280405 0.383687 0.0318404 0 0 0 0.00281905 l
+0.381545 0.0280405 0.383175 0.0244977 0 0 0 0.00281905 l
+-0.833461 -0.227966 -0.830781 -0.20861 0 0 0 0.00281905 l
+-0.833461 -0.227966 -0.827983 -0.231856 0 0 0 0.00281905 l
+-0.833461 -0.227966 -0.841464 -0.225414 0 0 0 0.00281905 l
+0.125492 -0.532709 0.118823 -0.524215 0 0 0 0.00281905 l
+0.125492 -0.532709 0.124297 -0.534294 0 0 0 0.00281905 l
+0.479305 0.608127 0.470226 0.620232 0 0 0 0.00281905 l
+0.479305 0.608127 0.471711 0.598913 0 0 0 0.00281905 l
+-0.442668 -0.00407661 -0.441122 -0.0113368 0 0 0 0.00281905 l
+-0.442668 -0.00407661 -0.430034 -0.00183504 0 0 0 0.00281905 l
+-0.442668 -0.00407661 -0.446012 0.00224228 0 0 0 0.00281905 l
+0.278334 0.197929 0.277643 0.207278 0 0 0 0.00281905 l
+0.278334 0.197929 0.276596 0.194344 0 0 0 0.00281905 l
+-0.125068 -0.619755 -0.122443 -0.616117 0 0 0 0.00281905 l
+0.570666 -0.0995152 0.579899 -0.111787 0 0 0 0.00281905 l
+0.570666 -0.0995152 0.561292 -0.0996268 0 0 0 0.00281905 l
+-0.672491 0.403605 -0.669969 0.41117 0 0 0 0.00281905 l
+-0.672491 0.403605 -0.681529 0.400717 0 0 0 0.00281905 l
+-0.570767 0.148407 -0.585019 0.144556 0 0 0 0.00281905 l
+0.0132179 0.78833 0.0106326 0.798224 0 0 0 0.00281905 l
+0.0132179 0.78833 -0.00249991 0.786333 0 0 0 0.00281905 l
+-0.0454669 0.210598 -0.0393383 0.215306 0 0 0 0.00281905 l
+0.606682 0.249112 0.6158 0.253786 0 0 0 0.00281905 l
+0.202087 -0.440659 0.206386 -0.452701 0 0 0 0.00281905 l
+0.202087 -0.440659 0.195074 -0.441352 0 0 0 0.00281905 l
+-0.0106857 0.23434 -0.0166495 0.220013 0 0 0 0.00281905 l
+-0.0106857 0.23434 -0.00902992 0.239005 0 0 0 0.00281905 l
+-0.00574395 0.085142 -0.00653477 0.0789303 0 0 0 0.00281905 l
+-0.00574395 0.085142 -0.0106223 0.105602 0 0 0 0.00281905 l
+-0.235758 -0.15684 -0.235673 -0.162976 0 0 0 0.00281905 l
+-0.235758 -0.15684 -0.245941 -0.159855 0 0 0 0.00281905 l
+0.249381 0.888045 0.251627 0.897977 0 0 0 0.00281905 l
+0.657276 0.0673793 0.66338 0.0550395 0 0 0 0.00281905 l
+0.657276 0.0673793 0.654161 0.0683734 0 0 0 0.00281905 l
+0.164349 0.40281 0.180656 0.405058 0 0 0 0.00281905 l
+0.164349 0.40281 0.161331 0.39989 0 0 0 0.00281905 l
+-0.622459 -0.471024 -0.60994 -0.467014 0 0 0 0.00281905 l
+-0.622459 -0.471024 -0.631451 -0.461741 0 0 0 0.00281905 l
+-0.628293 0.319531 -0.613174 0.32571 0 0 0 0.00281905 l
+-0.628293 0.319531 -0.649814 0.325234 0 0 0 0.00281905 l
+0.625074 0.499046 0.614957 0.491171 0 0 0 0.00281905 l
+0.742707 0.555103 0.753058 0.53811 0 0 0 0.00281905 l
+0.742707 0.555103 0.736284 0.56782 0 0 0 0.00281905 l
+0.330017 -0.338959 0.320242 -0.325628 0 0 0 0.00281905 l
+0.330017 -0.338959 0.337422 -0.341587 0 0 0 0.00281905 l
+0.330017 -0.338959 0.32809 -0.341895 0 0 0 0.00281905 l
+0.371717 0.0118229 0.385055 0.0182855 0 0 0 0.00281905 l
+0.371717 0.0118229 0.367208 0.0239527 0 0 0 0.00281905 l
+0.371717 0.0118229 0.356768 0.00409432 0 0 0 0.00281905 l
+-0.903453 0.401688 -0.911831 0.382237 0 0 0 0.00281905 l
+-0.903453 0.401688 -0.90268 0.405578 0 0 0 0.00281905 l
+0.520171 0.0260144 0.516038 0.0295501 0 0 0 0.00281905 l
+0.218929 0.678131 0.205685 0.673082 0 0 0 0.00281905 l
+0.835375 -0.0676224 0.844208 -0.0674382 0 0 0 0.00281905 l
+0.835375 -0.0676224 0.826492 -0.056076 0 0 0 0.00281905 l
+-0.445413 -0.881537 -0.448612 -0.869804 0 0 0 0.00281905 l
+-0.445413 -0.881537 -0.431131 -0.882019 0 0 0 0.00281905 l
+-0.445413 -0.881537 -0.451013 -0.891583 0 0 0 0.00281905 l
+0.399508 -0.825068 0.41144 -0.812832 0 0 0 0.00281905 l
+0.399508 -0.825068 0.38867 -0.814051 0 0 0 0.00281905 l
+0.399508 -0.825068 0.398782 -0.827548 0 0 0 0.00281905 l
+0.138132 -0.0428178 0.150977 -0.0569331 0 0 0 0.00281905 l
+0.138132 -0.0428178 0.139308 -0.0362019 0 0 0 0.00281905 l
+0.138132 -0.0428178 0.12617 -0.0426661 0 0 0 0.00281905 l
+0.114897 0.9489 0.108456 0.941648 0 0 0 0.00281905 l
+-0.765512 -0.17332 -0.758077 -0.177188 0 0 0 0.00281905 l
+-0.765512 -0.17332 -0.770776 -0.166589 0 0 0 0.00281905 l
+0.0726546 0.767055 0.07953 0.777347 0 0 0 0.00281905 l
+0.0726546 0.767055 0.0740701 0.762218 0 0 0 0.00281905 l
+-0.470645 0.473308 -0.476791 0.475314 0 0 0 0.00281905 l
+0.846629 -0.148259 0.832199 -0.134654 0 0 0 0.00281905 l
+-0.694682 -0.0967871 -0.683125 -0.104678 0 0 0 0.00281905 l
+-0.694682 -0.0967871 -0.706291 -0.1071 0 0 0 0.00281905 l
+0.000430739 0.726857 0.00173541 0.735806 0 0 0 0.00281905 l
+0.000430739 0.726857 -0.016909 0.725782 0 0 0 0.00281905 l
+0.262242 -0.11541 0.265029 -0.099268 0 0 0 0.00281905 l
+0.262242 -0.11541 0.276701 -0.129331 0 0 0 0.00281905 l
+0.262242 -0.11541 0.253615 -0.115832 0 0 0 0.00281905 l
+-0.111249 -0.640397 -0.11269 -0.651261 0 0 0 0.00281905 l
+-0.111249 -0.640397 -0.100736 -0.627055 0 0 0 0.00281905 l
+-0.390298 0.303187 -0.385445 0.31581 0 0 0 0.00281905 l
+-0.390298 0.303187 -0.410859 0.310004 0 0 0 0.00281905 l
+-0.390298 0.303187 -0.395402 0.29444 0 0 0 0.00281905 l
+0.486442 -0.207048 0.499928 -0.22264 0 0 0 0.00281905 l
+0.0970203 -0.30283 0.102991 -0.318478 0 0 0 0.00281905 l
+0.0970203 -0.30283 0.109779 -0.293058 0 0 0 0.00281905 l
+-0.912271 0.332264 -0.904586 0.342888 0 0 0 0.00281905 l
+-0.912271 0.332264 -0.912446 0.321063 0 0 0 0.00281905 l
+-0.912271 0.332264 -0.923433 0.337801 0 0 0 0.00281905 l
+-0.822478 0.171334 -0.815881 0.18919 0 0 0 0.00281905 l
+-0.822478 0.171334 -0.821844 0.160754 0 0 0 0.00281905 l
+0.809356 -0.352088 0.812091 -0.349678 0 0 0 0.00281905 l
+0.809356 -0.352088 0.811854 -0.354739 0 0 0 0.00281905 l
+0.809356 -0.352088 0.794886 -0.342719 0 0 0 0.00281905 l
+-0.616718 -0.554948 -0.617563 -0.563437 0 0 0 0.00281905 l
+-0.616718 -0.554948 -0.617316 -0.541915 0 0 0 0.00281905 l
+-0.616718 -0.554948 -0.611521 -0.553951 0 0 0 0.00281905 l
+-0.213432 -0.576936 -0.202493 -0.580639 0 0 0 0.00281905 l
+-0.213432 -0.576936 -0.224412 -0.58172 0 0 0 0.00281905 l
+-0.233554 0.427082 -0.233299 0.431621 0 0 0 0.00281905 l
+-0.233554 0.427082 -0.221782 0.417106 0 0 0 0.00281905 l
+-0.159651 0.553139 -0.15911 0.56188 0 0 0 0.00281905 l
+-0.159651 0.553139 -0.159515 0.537419 0 0 0 0.00281905 l
+-0.159651 0.553139 -0.162468 0.553256 0 0 0 0.00281905 l
+-0.814929 -0.0600103 -0.806212 -0.052957 0 0 0 0.00281905 l
+-0.814929 -0.0600103 -0.826418 -0.07227 0 0 0 0.00281905 l
+-0.00454499 0.358401 0.00513286 0.351256 0 0 0 0.00281905 l
+-0.00454499 0.358401 -0.0099758 0.355066 0 0 0 0.00281905 l
+0.125318 0.189865 0.132745 0.173064 0 0 0 0.00281905 l
+0.125318 0.189865 0.123596 0.198058 0 0 0 0.00281905 l
+0.125318 0.189865 0.137696 0.194178 0 0 0 0.00281905 l
+0.00643805 -0.203806 0.00633459 -0.202663 0 0 0 0.00281905 l
+0.0970512 -0.691353 0.0988206 -0.708685 0 0 0 0.00281905 l
+0.0970512 -0.691353 0.0913035 -0.68681 0 0 0 0.00281905 l
+-0.0505844 -0.146945 -0.0593838 -0.1635 0 0 0 0.00281905 l
+-0.0505844 -0.146945 -0.0598151 -0.133768 0 0 0 0.00281905 l
+-0.402202 -0.472281 -0.386746 -0.484763 0 0 0 0.00281905 l
+-0.402202 -0.472281 -0.402748 -0.471189 0 0 0 0.00281905 l
+0.645407 0.298348 0.652656 0.300091 0 0 0 0.00281905 l
+0.645407 0.298348 0.635856 0.306672 0 0 0 0.00281905 l
+0.28292 -0.490126 0.287347 -0.490159 0 0 0 0.00281905 l
+0.199764 -0.15863 0.208647 -0.153415 0 0 0 0.00281905 l
+0.199764 -0.15863 0.188555 -0.165142 0 0 0 0.00281905 l
+0.199764 -0.15863 0.191437 -0.152231 0 0 0 0.00281905 l
+-0.21947 0.64598 -0.209153 0.630903 0 0 0 0.00281905 l
+-0.176436 -0.530245 -0.17384 -0.517685 0 0 0 0.00281905 l
+-0.176436 -0.530245 -0.193769 -0.526706 0 0 0 0.00281905 l
+-0.634637 -0.560724 -0.617563 -0.563437 0 0 0 0.00281905 l
+-0.634637 -0.560724 -0.651511 -0.565413 0 0 0 0.00281905 l
+-0.634637 -0.560724 -0.63603 -0.556591 0 0 0 0.00281905 l
+-0.38448 0.0977041 -0.368318 0.0954764 0 0 0 0.00281905 l
+-0.38448 0.0977041 -0.391931 0.0930126 0 0 0 0.00281905 l
+0.341279 0.789628 0.353419 0.803155 0 0 0 0.00281905 l
+0.341279 0.789628 0.356206 0.783891 0 0 0 0.00281905 l
+0.341279 0.789628 0.332547 0.806151 0 0 0 0.00281905 l
+-0.923433 0.337801 -0.912271 0.332264 0 0 0 0.00281905 l
+-0.923433 0.337801 -0.933061 0.336021 0 0 0 0.00281905 l
+0.620521 -0.119128 0.626363 -0.106223 0 0 0 0.00281905 l
+0.620521 -0.119128 0.611676 -0.127802 0 0 0 0.00281905 l
+0.72659 -0.166994 0.743223 -0.165684 0 0 0 0.00281905 l
+0.72659 -0.166994 0.71342 -0.17814 0 0 0 0.00281905 l
+-0.728405 -0.112601 -0.72219 -0.0990526 0 0 0 0.00281905 l
+0.1016 -0.453225 0.108018 -0.453934 0 0 0 0.00281905 l
+0.1016 -0.453225 0.0940376 -0.460759 0 0 0 0.00281905 l
+0.1016 -0.453225 0.0924559 -0.446942 0 0 0 0.00281905 l
+0.773631 0.397263 0.764135 0.40848 0 0 0 0.00281905 l
+0.773631 0.397263 0.794609 0.399406 0 0 0 0.00281905 l
+0.773631 0.397263 0.773545 0.396092 0 0 0 0.00281905 l
+-0.767365 0.16449 -0.767132 0.168813 0 0 0 0.00281905 l
+-0.767365 0.16449 -0.754855 0.165196 0 0 0 0.00281905 l
+0.0287414 -0.306426 0.0326577 -0.320622 0 0 0 0.00281905 l
+0.0287414 -0.306426 0.0383813 -0.304405 0 0 0 0.00281905 l
+0.0287414 -0.306426 0.0228254 -0.297953 0 0 0 0.00281905 l
+-0.634014 -0.620446 -0.63308 -0.624807 0 0 0 0.00281905 l
+-0.634014 -0.620446 -0.642762 -0.613321 0 0 0 0.00281905 l
+0.09671 0.011621 0.117014 0.0166601 0 0 0 0.00281905 l
+-0.14996 -0.210912 -0.145989 -0.21513 0 0 0 0.00281905 l
+-0.14996 -0.210912 -0.155523 -0.212985 0 0 0 0.00281905 l
+0.300092 0.572821 0.313903 0.575043 0 0 0 0.00281905 l
+0.300092 0.572821 0.288773 0.579193 0 0 0 0.00281905 l
+0.590782 -0.638661 0.590357 -0.645292 0 0 0 0.00281905 l
+0.590782 -0.638661 0.583115 -0.628053 0 0 0 0.00281905 l
+-0.906686 -0.0679642 -0.907437 -0.0701222 0 0 0 0.00281905 l
+-0.906686 -0.0679642 -0.909984 -0.0676924 0 0 0 0.00281905 l
+-0.156386 0.297729 -0.155367 0.281579 0 0 0 0.00281905 l
+-0.156386 0.297729 -0.15453 0.309752 0 0 0 0.00281905 l
+0.461008 0.197742 0.468857 0.206916 0 0 0 0.00281905 l
+-0.0544496 0.00872464 -0.0580605 0.0194769 0 0 0 0.00281905 l
+-0.0544496 0.00872464 -0.0472505 0.00292533 0 0 0 0.00281905 l
+-0.0544496 0.00872464 -0.0651223 0.00827818 0 0 0 0.00281905 l
+-0.35861 -0.0937448 -0.353358 -0.0965898 0 0 0 0.00281905 l
+0.121901 -0.690156 0.11971 -0.70118 0 0 0 0.00281905 l
+0.121901 -0.690156 0.117454 -0.68132 0 0 0 0.00281905 l
+-0.528849 0.150669 -0.515815 0.146819 0 0 0 0.00281905 l
+-0.528849 0.150669 -0.538837 0.162791 0 0 0 0.00281905 l
+0.777285 0.227256 0.788804 0.217445 0 0 0 0.00281905 l
+0.777285 0.227256 0.764849 0.207012 0 0 0 0.00281905 l
+-0.231127 -0.943403 -0.222037 -0.956741 0 0 0 0.00281905 l
+-0.231127 -0.943403 -0.223605 -0.933207 0 0 0 0.00281905 l
+-0.231127 -0.943403 -0.239437 -0.933285 0 0 0 0.00281905 l
+-0.606583 0.491628 -0.603683 0.491128 0 0 0 0.00281905 l
+-0.606583 0.491628 -0.621642 0.482879 0 0 0 0.00281905 l
+-0.768899 -0.575023 -0.761757 -0.580824 0 0 0 0.00281905 l
+-0.768899 -0.575023 -0.782615 -0.566311 0 0 0 0.00281905 l
+-0.245392 -0.930029 -0.244503 -0.925519 0 0 0 0.00281905 l
+-0.245392 -0.930029 -0.239437 -0.933285 0 0 0 0.00281905 l
+0.145092 -0.40749 0.150608 -0.409452 0 0 0 0.00281905 l
+0.145092 -0.40749 0.144499 -0.4158 0 0 0 0.00281905 l
+0.145092 -0.40749 0.132668 -0.406724 0 0 0 0.00281905 l
+-0.319903 0.43632 -0.317893 0.449859 0 0 0 0.00281905 l
+-0.319903 0.43632 -0.331569 0.429098 0 0 0 0.00281905 l
+-0.872045 0.0364239 -0.87529 0.0475248 0 0 0 0.00281905 l
+-0.872045 0.0364239 -0.870706 0.0225344 0 0 0 0.00281905 l
+-0.872045 0.0364239 -0.88222 0.0308066 0 0 0 0.00281905 l
+-0.0504062 0.0642808 -0.0491823 0.0782104 0 0 0 0.00281905 l
+-0.0504062 0.0642808 -0.0356111 0.0664645 0 0 0 0.00281905 l
+-0.0504062 0.0642808 -0.0586317 0.0550902 0 0 0 0.00281905 l
+-0.369098 -0.52461 -0.366808 -0.517668 0 0 0 0.00281905 l
+-0.369098 -0.52461 -0.373027 -0.528885 0 0 0 0.00281905 l
+-0.0222405 -0.340454 -0.00825396 -0.349622 0 0 0 0.00281905 l
+-0.0222405 -0.340454 -0.0131691 -0.330904 0 0 0 0.00281905 l
+-0.0222405 -0.340454 -0.0357231 -0.348234 0 0 0 0.00281905 l
+0.349328 0.760589 0.370553 0.761681 0 0 0 0.00281905 l
+-0.239671 0.443197 -0.239069 0.449006 0 0 0 0.00281905 l
+-0.239671 0.443197 -0.234565 0.439562 0 0 0 0.00281905 l
+-0.239671 0.443197 -0.2561 0.441504 0 0 0 0.00281905 l
+-0.796864 0.327548 -0.787762 0.314705 0 0 0 0.00281905 l
+-0.796864 0.327548 -0.801703 0.33383 0 0 0 0.00281905 l
+-0.101224 0.65704 -0.0973701 0.646066 0 0 0 0.00281905 l
+-0.101224 0.65704 -0.0968438 0.659498 0 0 0 0.00281905 l
+-0.101224 0.65704 -0.118055 0.661446 0 0 0 0.00281905 l
+-0.214072 0.392279 -0.213913 0.391491 0 0 0 0.00281905 l
+-0.240704 -0.247335 -0.247852 -0.240696 0 0 0 0.00281905 l
+0.718553 -0.526429 0.733334 -0.531461 0 0 0 0.00281905 l
+0.718553 -0.526429 0.710059 -0.533088 0 0 0 0.00281905 l
+0.368586 0.645902 0.375036 0.650233 0 0 0 0.00281905 l
+0.368586 0.645902 0.36624 0.645527 0 0 0 0.00281905 l
+-0.730667 -0.547146 -0.724206 -0.543572 0 0 0 0.00281905 l
+-0.730667 -0.547146 -0.732572 -0.548888 0 0 0 0.00281905 l
+0.616196 0.19513 0.615484 0.182329 0 0 0 0.00281905 l
+0.616196 0.19513 0.614082 0.202625 0 0 0 0.00281905 l
+0.489197 -0.485058 0.50235 -0.490125 0 0 0 0.00281905 l
+0.489197 -0.485058 0.478416 -0.492517 0 0 0 0.00281905 l
+-0.0841351 -0.643348 -0.0671254 -0.643726 0 0 0 0.00281905 l
+0.0325596 0.861852 0.0543819 0.868287 0 0 0 0.00281905 l
+0.0325596 0.861852 0.0135843 0.861926 0 0 0 0.00281905 l
+0.544219 0.279621 0.548264 0.285955 0 0 0 0.00281905 l
+0.354474 -0.921469 0.35625 -0.922687 0 0 0 0.00281905 l
+-0.760875 0.419338 -0.762815 0.399585 0 0 0 0.00281905 l
+-0.760875 0.419338 -0.753437 0.426596 0 0 0 0.00281905 l
+-0.511125 -0.279054 -0.512238 -0.273175 0 0 0 0.00281905 l
+0.320242 -0.325628 0.330017 -0.338959 0 0 0 0.00281905 l
+0.320242 -0.325628 0.316593 -0.305555 0 0 0 0.00281905 l
+-0.408734 -0.027352 -0.403883 -0.0247595 0 0 0 0.00281905 l
+0.503612 0.00190704 0.512347 0.0116944 0 0 0 0.00281905 l
+0.503612 0.00190704 0.497379 -0.00989928 0 0 0 0.00281905 l
+0.503612 0.00190704 0.499758 0.00485662 0 0 0 0.00281905 l
+0.0991834 0.118971 0.104848 0.12868 0 0 0 0.00281905 l
+0.0991834 0.118971 0.0993346 0.115471 0 0 0 0.00281905 l
+0.611803 -0.595518 0.612416 -0.589655 0 0 0 0.00281905 l
+0.611803 -0.595518 0.602739 -0.606155 0 0 0 0.00281905 l
+0.191848 -0.247718 0.180685 -0.248905 0 0 0 0.00281905 l
+-0.367017 0.072606 -0.345461 0.0687381 0 0 0 0.00281905 l
+-0.367017 0.072606 -0.38382 0.0844554 0 0 0 0.00281905 l
+0.601617 0.299257 0.586561 0.287877 0 0 0 0.00281905 l
+0.601617 0.299257 0.589562 0.31039 0 0 0 0.00281905 l
+-0.216038 0.771047 -0.197985 0.759121 0 0 0 0.00281905 l
+-0.243749 0.908572 -0.240903 0.921702 0 0 0 0.00281905 l
+-0.243749 0.908572 -0.235964 0.901786 0 0 0 0.00281905 l
+-0.243749 0.908572 -0.256745 0.90736 0 0 0 0.00281905 l
+-0.121495 0.203791 -0.107838 0.197453 0 0 0 0.00281905 l
+-0.121495 0.203791 -0.133133 0.203282 0 0 0 0.00281905 l
+-0.479498 -0.443917 -0.470956 -0.442362 0 0 0 0.00281905 l
+-0.479498 -0.443917 -0.483284 -0.446923 0 0 0 0.00281905 l
+0.73541 0.354395 0.738796 0.35516 0 0 0 0.00281905 l
+0.73541 0.354395 0.737068 0.349777 0 0 0 0.00281905 l
+0.494642 0.539123 0.502619 0.534129 0 0 0 0.00281905 l
+0.494642 0.539123 0.490857 0.54815 0 0 0 0.00281905 l
+0.411076 -0.864195 0.413101 -0.888875 0 0 0 0.00281905 l
+0.411076 -0.864195 0.409956 -0.851674 0 0 0 0.00281905 l
+0.411076 -0.864195 0.421186 -0.860267 0 0 0 0.00281905 l
+-0.549732 0.598092 -0.546757 0.595024 0 0 0 0.00281905 l
+-0.549732 0.598092 -0.552383 0.599322 0 0 0 0.00281905 l
+0.693114 -0.323452 0.692024 -0.331256 0 0 0 0.00281905 l
+0.693114 -0.323452 0.695342 -0.322766 0 0 0 0.00281905 l
+-0.8481 0.487001 -0.836822 0.481311 0 0 0 0.00281905 l
+-0.8481 0.487001 -0.85945 0.480734 0 0 0 0.00281905 l
+-0.61753 0.57557 -0.622844 0.563884 0 0 0 0.00281905 l
+-0.61753 0.57557 -0.625953 0.589286 0 0 0 0.00281905 l
+0.288666 0.824768 0.293432 0.826569 0 0 0 0.00281905 l
+0.288666 0.824768 0.283818 0.823762 0 0 0 0.00281905 l
+-0.854573 0.327657 -0.846658 0.331692 0 0 0 0.00281905 l
+-0.854573 0.327657 -0.860921 0.323759 0 0 0 0.00281905 l
+-0.966718 -0.247739 -0.96644 -0.249276 0 0 0 0.00281905 l
+0.360225 -0.434812 0.359862 -0.44813 0 0 0 0.00281905 l
+0.360225 -0.434812 0.357045 -0.434138 0 0 0 0.00281905 l
+0.024056 0.45116 0.0317882 0.450422 0 0 0 0.00281905 l
+-0.47511 -0.734888 -0.471945 -0.715232 0 0 0 0.00281905 l
+-0.47511 -0.734888 -0.473713 -0.740404 0 0 0 0.00281905 l
+-0.203258 -0.547108 -0.203704 -0.551123 0 0 0 0.00281905 l
+-0.203258 -0.547108 -0.215406 -0.536747 0 0 0 0.00281905 l
+-0.548998 -0.624274 -0.535316 -0.637018 0 0 0 0.00281905 l
+-0.548998 -0.624274 -0.556272 -0.616707 0 0 0 0.00281905 l
+-0.605993 0.600186 -0.587102 0.597113 0 0 0 0.00281905 l
+-0.605993 0.600186 -0.621358 0.613082 0 0 0 0.00281905 l
+0.302259 -0.399627 0.32107 -0.407555 0 0 0 0.00281905 l
+0.302259 -0.399627 0.296479 -0.405795 0 0 0 0.00281905 l
+0.353001 0.456139 0.342298 0.453467 0 0 0 0.00281905 l
+0.275404 -0.0801483 0.280944 -0.0852214 0 0 0 0.00281905 l
+-0.388642 -0.911226 -0.386672 -0.912975 0 0 0 0.00281905 l
+-0.388642 -0.911226 -0.389546 -0.908246 0 0 0 0.00281905 l
+0.798274 0.14474 0.813251 0.151959 0 0 0 0.00281905 l
+0.798274 0.14474 0.790301 0.144134 0 0 0 0.00281905 l
+0.0963817 -0.914892 0.106356 -0.917457 0 0 0 0.00281905 l
+0.0963817 -0.914892 0.0905404 -0.916858 0 0 0 0.00281905 l
+0.315509 0.294034 0.314813 0.303022 0 0 0 0.00281905 l
+0.315509 0.294034 0.334064 0.297101 0 0 0 0.00281905 l
+0.315509 0.294034 0.298254 0.290105 0 0 0 0.00281905 l
+0.295793 0.0293948 0.311135 0.0208179 0 0 0 0.00281905 l
+0.295793 0.0293948 0.298899 0.0387407 0 0 0 0.00281905 l
+0.295793 0.0293948 0.285134 0.0199736 0 0 0 0.00281905 l
+0.0639925 -0.76375 0.0721154 -0.766253 0 0 0 0.00281905 l
+0.430612 -0.2572 0.428923 -0.241124 0 0 0 0.00281905 l
+0.430612 -0.2572 0.436014 -0.261119 0 0 0 0.00281905 l
+-0.926619 -0.307435 -0.929986 -0.299649 0 0 0 0.00281905 l
+-0.926619 -0.307435 -0.925903 -0.313 0 0 0 0.00281905 l
+0.366863 0.719541 0.353574 0.725216 0 0 0 0.00281905 l
+0.11054 0.501889 0.113393 0.494714 0 0 0 0.00281905 l
+0.11054 0.501889 0.0966354 0.508299 0 0 0 0.00281905 l
+0.230377 -0.0417726 0.232538 -0.0355874 0 0 0 0.00281905 l
+0.230377 -0.0417726 0.223619 -0.0441659 0 0 0 0.00281905 l
+-0.145288 0.624826 -0.145546 0.615631 0 0 0 0.00281905 l
+-0.145288 0.624826 -0.144684 0.640067 0 0 0 0.00281905 l
+0.353408 0.370553 0.358437 0.354667 0 0 0 0.00281905 l
+0.353408 0.370553 0.353625 0.375267 0 0 0 0.00281905 l
+0.353408 0.370553 0.365757 0.371255 0 0 0 0.00281905 l
+0.353408 0.370553 0.34712 0.367882 0 0 0 0.00281905 l
+0.0916289 -0.67984 0.0977012 -0.681626 0 0 0 0.00281905 l
+0.0916289 -0.67984 0.0913035 -0.68681 0 0 0 0.00281905 l
+-0.105869 0.242085 -0.0921426 0.228197 0 0 0 0.00281905 l
+-0.0316137 0.192832 -0.0298518 0.211894 0 0 0 0.00281905 l
+-0.0316137 0.192832 -0.0387187 0.18083 0 0 0 0.00281905 l
+-0.603329 0.274645 -0.590665 0.276922 0 0 0 0.00281905 l
+-0.603329 0.274645 -0.606561 0.27321 0 0 0 0.00281905 l
+-0.375844 0.357342 -0.367107 0.362705 0 0 0 0.00281905 l
+-0.85997 -0.411649 -0.860894 -0.4124 0 0 0 0.00281905 l
+-0.244247 0.0569093 -0.254928 0.0524395 0 0 0 0.00281905 l
+-0.244247 0.0569093 -0.239432 0.0670741 0 0 0 0.00281905 l
+-0.0926513 -0.513891 -0.0920071 -0.498506 0 0 0 0.00281905 l
+-0.0926513 -0.513891 -0.0848311 -0.52823 0 0 0 0.00281905 l
+-0.0926513 -0.513891 -0.100216 -0.514579 0 0 0 0.00281905 l
+0.504857 -0.372731 0.509445 -0.393472 0 0 0 0.00281905 l
+0.504857 -0.372731 0.508496 -0.366462 0 0 0 0.00281905 l
+0.108456 0.941648 0.114897 0.9489 0 0 0 0.00281905 l
+0.108456 0.941648 0.115106 0.93647 0 0 0 0.00281905 l
+0.108456 0.941648 0.102944 0.936192 0 0 0 0.00281905 l
+-0.24596 -0.174915 -0.23844 -0.173115 0 0 0 0.00281905 l
+-0.24596 -0.174915 -0.246898 -0.172155 0 0 0 0.00281905 l
+0.633748 0.481594 0.643548 0.486488 0 0 0 0.00281905 l
+0.633748 0.481594 0.643208 0.47215 0 0 0 0.00281905 l
+0.633748 0.481594 0.622827 0.478655 0 0 0 0.00281905 l
+-0.692327 0.0676913 -0.694 0.0567076 0 0 0 0.00281905 l
+-0.692327 0.0676913 -0.692833 0.073828 0 0 0 0.00281905 l
+0.483255 -0.0982571 0.485224 -0.112322 0 0 0 0.00281905 l
+0.483255 -0.0982571 0.474669 -0.099354 0 0 0 0.00281905 l
+-0.711124 -0.494633 -0.700245 -0.49365 0 0 0 0.00281905 l
+-0.843971 -0.146253 -0.844616 -0.137616 0 0 0 0.00281905 l
+-0.843971 -0.146253 -0.842727 -0.150288 0 0 0 0.00281905 l
+-0.240494 0.791917 -0.224104 0.805232 0 0 0 0.00281905 l
+-0.240494 0.791917 -0.242876 0.77663 0 0 0 0.00281905 l
+-0.240494 0.791917 -0.246513 0.800796 0 0 0 0.00281905 l
+0.141791 -0.124999 0.138926 -0.115009 0 0 0 0.00281905 l
+0.141791 -0.124999 0.144566 -0.128166 0 0 0 0.00281905 l
+-0.132752 -0.0207942 -0.119486 -0.00896643 0 0 0 0.00281905 l
+-0.132752 -0.0207942 -0.134892 -0.0247255 0 0 0 0.00281905 l
+-0.616901 -0.357797 -0.605813 -0.340133 0 0 0 0.00281905 l
+-0.616901 -0.357797 -0.629221 -0.366649 0 0 0 0.00281905 l
+0.412018 -0.61421 0.401577 -0.603261 0 0 0 0.00281905 l
+0.412018 -0.61421 0.405828 -0.619173 0 0 0 0.00281905 l
+-0.233742 -0.891145 -0.222823 -0.891878 0 0 0 0.00281905 l
+-0.233742 -0.891145 -0.233592 -0.901184 0 0 0 0.00281905 l
+-0.233742 -0.891145 -0.242304 -0.892012 0 0 0 0.00281905 l
+-0.240807 0.741568 -0.237927 0.744182 0 0 0 0.00281905 l
+-0.240807 0.741568 -0.251135 0.745971 0 0 0 0.00281905 l
+0.843985 0.0829162 0.853307 0.0821561 0 0 0 0.00281905 l
+0.843985 0.0829162 0.833632 0.0782513 0 0 0 0.00281905 l
+0.843985 0.0829162 0.84792 0.0914489 0 0 0 0.00281905 l
+0.759219 0.150893 0.767893 0.161121 0 0 0 0.00281905 l
+0.759219 0.150893 0.768058 0.141918 0 0 0 0.00281905 l
+0.207472 -0.798889 0.207182 -0.801335 0 0 0 0.00281905 l
+0.207472 -0.798889 0.206869 -0.78484 0 0 0 0.00281905 l
+0.902641 0.160446 0.907363 0.161138 0 0 0 0.00281905 l
+0.902641 0.160446 0.889945 0.160207 0 0 0 0.00281905 l
+0.563705 0.298463 0.569759 0.287961 0 0 0 0.00281905 l
+0.563705 0.298463 0.570423 0.31569 0 0 0 0.00281905 l
+-0.5975 -0.128083 -0.591313 -0.138944 0 0 0 0.00281905 l
+0.654639 -0.619385 0.658427 -0.619827 0 0 0 0.00281905 l
+0.654639 -0.619385 0.650559 -0.626329 0 0 0 0.00281905 l
+-0.592669 0.306467 -0.592858 0.292285 0 0 0 0.00281905 l
+-0.592669 0.306467 -0.604729 0.306591 0 0 0 0.00281905 l
+-0.324037 -0.935332 -0.315088 -0.944697 0 0 0 0.00281905 l
+0.650099 -0.741363 0.64706 -0.729154 0 0 0 0.00281905 l
+0.650099 -0.741363 0.651538 -0.741891 0 0 0 0.00281905 l
+0.650099 -0.741363 0.636645 -0.754293 0 0 0 0.00281905 l
+-0.965907 0.0985085 -0.959271 0.110163 0 0 0 0.00281905 l
+-0.965907 0.0985085 -0.975134 0.108805 0 0 0 0.00281905 l
+-0.345461 0.0687381 -0.367017 0.072606 0 0 0 0.00281905 l
+-0.419906 -0.805386 -0.420041 -0.795592 0 0 0 0.00281905 l
+-0.433485 -0.688395 -0.430726 -0.689184 0 0 0 0.00281905 l
+-0.479893 -0.48795 -0.481029 -0.492327 0 0 0 0.00281905 l
+-0.479893 -0.48795 -0.469206 -0.484257 0 0 0 0.00281905 l
+-0.479893 -0.48795 -0.484935 -0.482005 0 0 0 0.00281905 l
+0.731488 0.494844 0.744234 0.483391 0 0 0 0.00281905 l
+0.731488 0.494844 0.724341 0.48561 0 0 0 0.00281905 l
+-0.0906788 -0.666264 -0.0894777 -0.669489 0 0 0 0.00281905 l
+0.139373 0.694295 0.146575 0.708966 0 0 0 0.00281905 l
+0.139373 0.694295 0.134017 0.679757 0 0 0 0.00281905 l
+0.559005 -0.018311 0.571655 -0.0268387 0 0 0 0.00281905 l
+0.559005 -0.018311 0.569777 -0.00821252 0 0 0 0.00281905 l
+0.559005 -0.018311 0.550486 -0.0135731 0 0 0 0.00281905 l
+0.821239 0.245769 0.818154 0.26173 0 0 0 0.00281905 l
+0.821239 0.245769 0.826091 0.233118 0 0 0 0.00281905 l
+0.821239 0.245769 0.802763 0.237718 0 0 0 0.00281905 l
+-0.0400169 -0.0520873 -0.0386715 -0.0431681 0 0 0 0.00281905 l
+0.677766 0.609084 0.693256 0.609025 0 0 0 0.00281905 l
+0.677766 0.609084 0.676846 0.589782 0 0 0 0.00281905 l
+0.677766 0.609084 0.664467 0.608874 0 0 0 0.00281905 l
+-0.007003 0.583346 0.0120132 0.587417 0 0 0 0.00281905 l
+-0.007003 0.583346 -0.0129073 0.581111 0 0 0 0.00281905 l
+-0.0591777 -0.377011 -0.0526697 -0.370319 0 0 0 0.00281905 l
+-0.0591777 -0.377011 -0.0421471 -0.393905 0 0 0 0.00281905 l
+-0.0591777 -0.377011 -0.0773543 -0.383147 0 0 0 0.00281905 l
+0.173187 0.928945 0.195166 0.932298 0 0 0 0.00281905 l
+0.173187 0.928945 0.169357 0.925219 0 0 0 0.00281905 l
+-0.580122 -0.352681 -0.575306 -0.334004 0 0 0 0.00281905 l
+-0.580122 -0.352681 -0.576346 -0.353756 0 0 0 0.00281905 l
+0.572109 0.0426269 0.574973 0.0444442 0 0 0 0.00281905 l
+0.572109 0.0426269 0.566024 0.0512999 0 0 0 0.00281905 l
+0.844208 -0.0674382 0.850741 -0.057681 0 0 0 0.00281905 l
+0.844208 -0.0674382 0.842953 -0.0767061 0 0 0 0.00281905 l
+0.844208 -0.0674382 0.835375 -0.0676224 0 0 0 0.00281905 l
+0.291771 0.320509 0.281665 0.322103 0 0 0 0.00281905 l
+0.291771 0.320509 0.293155 0.323911 0 0 0 0.00281905 l
+-0.45135 0.355661 -0.438617 0.34292 0 0 0 0.00281905 l
+-0.71913 -0.0477793 -0.71196 -0.0641645 0 0 0 0.00281905 l
+0.81683 0.130372 0.816722 0.139001 0 0 0 0.00281905 l
+0.131394 0.868509 0.120056 0.86288 0 0 0 0.00281905 l
+-0.259983 0.556263 -0.256351 0.56344 0 0 0 0.00281905 l
+-0.259983 0.556263 -0.264194 0.547573 0 0 0 0.00281905 l
+0.253982 0.552197 0.263962 0.562144 0 0 0 0.00281905 l
+0.253982 0.552197 0.262169 0.546691 0 0 0 0.00281905 l
+0.253982 0.552197 0.239824 0.555415 0 0 0 0.00281905 l
+0.208334 -0.468334 0.206386 -0.452701 0 0 0 0.00281905 l
+0.208334 -0.468334 0.205493 -0.469187 0 0 0 0.00281905 l
+-0.530504 -0.384398 -0.52954 -0.374254 0 0 0 0.00281905 l
+-0.530504 -0.384398 -0.527648 -0.390076 0 0 0 0.00281905 l
+0.26101 0.921674 0.255989 0.912561 0 0 0 0.00281905 l
+0.540906 0.736714 0.553208 0.740577 0 0 0 0.00281905 l
+0.540906 0.736714 0.539924 0.735844 0 0 0 0.00281905 l
+-0.765014 0.208729 -0.760521 0.214677 0 0 0 0.00281905 l
+-0.765014 0.208729 -0.766045 0.193964 0 0 0 0.00281905 l
+-0.765014 0.208729 -0.781055 0.208836 0 0 0 0.00281905 l
+0.434441 0.645359 0.421707 0.655813 0 0 0 0.00281905 l
+0.434441 0.645359 0.442389 0.641109 0 0 0 0.00281905 l
+0.434441 0.645359 0.420206 0.638806 0 0 0 0.00281905 l
+-0.329312 -0.411843 -0.323512 -0.421395 0 0 0 0.00281905 l
+-0.329312 -0.411843 -0.332053 -0.395948 0 0 0 0.00281905 l
+-0.484895 0.127886 -0.476803 0.131814 0 0 0 0.00281905 l
+-0.484895 0.127886 -0.488199 0.12868 0 0 0 0.00281905 l
+-0.546055 0.33691 -0.56345 0.337304 0 0 0 0.00281905 l
+-0.558049 0.31138 -0.553575 0.296911 0 0 0 0.00281905 l
+-0.558049 0.31138 -0.569313 0.319482 0 0 0 0.00281905 l
+-0.148804 0.952742 -0.154907 0.972644 0 0 0 0.00281905 l
+-0.148804 0.952742 -0.154851 0.944207 0 0 0 0.00281905 l
+0.544997 0.363752 0.546702 0.356133 0 0 0 0.00281905 l
+0.544997 0.363752 0.542652 0.384133 0 0 0 0.00281905 l
+0.249012 -0.0854829 0.253132 -0.0840502 0 0 0 0.00281905 l
+0.249012 -0.0854829 0.249263 -0.0928167 0 0 0 0.00281905 l
+0.593092 -0.0148311 0.593292 -0.0253304 0 0 0 0.00281905 l
+0.593092 -0.0148311 0.599104 -0.00747451 0 0 0 0.00281905 l
+0.593092 -0.0148311 0.577884 -0.00951244 0 0 0 0.00281905 l
+0.249118 0.295657 0.245775 0.281393 0 0 0 0.00281905 l
+0.249118 0.295657 0.265522 0.301819 0 0 0 0.00281905 l
+0.249118 0.295657 0.230098 0.29353 0 0 0 0.00281905 l
+0.0450904 -0.852311 0.0445223 -0.846144 0 0 0 0.00281905 l
+0.0450904 -0.852311 0.0625908 -0.855393 0 0 0 0.00281905 l
+0.0450904 -0.852311 0.0272587 -0.854068 0 0 0 0.00281905 l
+-0.362016 -0.577581 -0.358505 -0.567961 0 0 0 0.00281905 l
+-0.362016 -0.577581 -0.37358 -0.581713 0 0 0 0.00281905 l
+-0.632505 0.0165645 -0.62697 -0.00054444 0 0 0 0.00281905 l
+-0.755193 -0.158293 -0.756704 -0.152382 0 0 0 0.00281905 l
+-0.755193 -0.158293 -0.740724 -0.158466 0 0 0 0.00281905 l
+-0.755193 -0.158293 -0.757621 -0.159618 0 0 0 0.00281905 l
+-0.335392 0.638029 -0.314054 0.640657 0 0 0 0.00281905 l
+-0.335392 0.638029 -0.350996 0.642759 0 0 0 0.00281905 l
+-0.700306 -0.230823 -0.709207 -0.221777 0 0 0 0.00281905 l
+-0.700306 -0.230823 -0.69185 -0.235383 0 0 0 0.00281905 l
+-0.700306 -0.230823 -0.703517 -0.234983 0 0 0 0.00281905 l
+-0.1673 -0.27514 -0.165775 -0.285933 0 0 0 0.00281905 l
+-0.1673 -0.27514 -0.173523 -0.267918 0 0 0 0.00281905 l
+-0.243288 0.151006 -0.239258 0.161149 0 0 0 0.00281905 l
+-0.243288 0.151006 -0.240152 0.147453 0 0 0 0.00281905 l
+0.924565 -0.108377 0.922466 -0.117191 0 0 0 0.00281905 l
+0.924565 -0.108377 0.917937 -0.0994198 0 0 0 0.00281905 l
+-0.948558 -0.213544 -0.94685 -0.202549 0 0 0 0.00281905 l
+-0.948558 -0.213544 -0.951986 -0.214041 0 0 0 0.00281905 l
+-0.0511313 -0.260431 -0.0528756 -0.252589 0 0 0 0.00281905 l
+-0.0511313 -0.260431 -0.0336384 -0.257983 0 0 0 0.00281905 l
+-0.0511313 -0.260431 -0.0534324 -0.261401 0 0 0 0.00281905 l
+0.160668 0.0698119 0.159007 0.0549418 0 0 0 0.00281905 l
+0.160668 0.0698119 0.164432 0.0811077 0 0 0 0.00281905 l
+-0.764441 -0.64019 -0.776374 -0.618354 0 0 0 0.00281905 l
+-0.41313 0.550104 -0.419592 0.542858 0 0 0 0.00281905 l
+0.150608 -0.409452 0.161083 -0.405013 0 0 0 0.00281905 l
+0.150608 -0.409452 0.145092 -0.40749 0 0 0 0.00281905 l
+-0.429097 0.157103 -0.433652 0.146444 0 0 0 0.00281905 l
+-0.429097 0.157103 -0.433666 0.166619 0 0 0 0.00281905 l
+-0.0969485 0.33264 -0.0865326 0.331707 0 0 0 0.00281905 l
+-0.00540737 0.878479 -0.0134509 0.884671 0 0 0 0.00281905 l
+-0.00540737 0.878479 -0.00882128 0.872963 0 0 0 0.00281905 l
+-0.451204 -0.648302 -0.448604 -0.658091 0 0 0 0.00281905 l
+-0.451204 -0.648302 -0.458992 -0.649726 0 0 0 0.00281905 l
+-0.471794 -0.0107573 -0.46796 -0.0124811 0 0 0 0.00281905 l
+-0.595028 -0.481125 -0.593727 -0.48901 0 0 0 0.00281905 l
+-0.595028 -0.481125 -0.599347 -0.478608 0 0 0 0.00281905 l
+-0.300992 -0.0724428 -0.300672 -0.0799068 0 0 0 0.00281905 l
+-0.300992 -0.0724428 -0.310977 -0.0733723 0 0 0 0.00281905 l
+0.903061 0.257045 0.917296 0.264257 0 0 0 0.00281905 l
+0.903061 0.257045 0.889835 0.248453 0 0 0 0.00281905 l
+0.0149366 0.3113 0.017707 0.31117 0 0 0 0.00281905 l
+0.0149366 0.3113 0.0113582 0.305589 0 0 0 0.00281905 l
+0.839071 0.107838 0.840439 0.111089 0 0 0 0.00281905 l
+-0.606281 -0.745466 -0.599385 -0.730138 0 0 0 0.00281905 l
+0.500853 0.735994 0.509779 0.746576 0 0 0 0.00281905 l
+0.500853 0.735994 0.498865 0.729762 0 0 0 0.00281905 l
+-0.719105 -0.515868 -0.717009 -0.532539 0 0 0 0.00281905 l
+-0.719105 -0.515868 -0.733753 -0.51974 0 0 0 0.00281905 l
+0.93636 -0.0630087 0.939122 -0.073207 0 0 0 0.00281905 l
+0.93636 -0.0630087 0.936504 -0.0513468 0 0 0 0.00281905 l
+-0.510249 -0.641163 -0.497769 -0.634975 0 0 0 0.00281905 l
+-0.510249 -0.641163 -0.524123 -0.641862 0 0 0 0.00281905 l
+-0.112317 -0.137708 -0.112119 -0.119998 0 0 0 0.00281905 l
+-0.112317 -0.137708 -0.0987334 -0.147024 0 0 0 0.00281905 l
+-0.836822 0.481311 -0.829384 0.462973 0 0 0 0.00281905 l
+-0.836822 0.481311 -0.830542 0.502784 0 0 0 0.00281905 l
+-0.836822 0.481311 -0.8481 0.487001 0 0 0 0.00281905 l
+0.454545 0.805971 0.469686 0.822955 0 0 0 0.00281905 l
+0.454545 0.805971 0.451388 0.801407 0 0 0 0.00281905 l
+0.221721 -0.0242625 0.232747 -0.0302739 0 0 0 0.00281905 l
+0.221721 -0.0242625 0.230637 -0.00840827 0 0 0 0.00281905 l
+0.221721 -0.0242625 0.218065 -0.0268488 0 0 0 0.00281905 l
+0.716983 -0.618206 0.706113 -0.614325 0 0 0 0.00281905 l
+0.716983 -0.618206 0.731909 -0.621841 0 0 0 0.00281905 l
+0.449204 0.663069 0.454346 0.668484 0 0 0 0.00281905 l
+0.449204 0.663069 0.437985 0.673761 0 0 0 0.00281905 l
+-0.422474 -0.772689 -0.425537 -0.784618 0 0 0 0.00281905 l
+-0.422474 -0.772689 -0.432589 -0.759699 0 0 0 0.00281905 l
+-0.770776 -0.166589 -0.757621 -0.159618 0 0 0 0.00281905 l
+-0.770776 -0.166589 -0.765512 -0.17332 0 0 0 0.00281905 l
+-0.770776 -0.166589 -0.785914 -0.181396 0 0 0 0.00281905 l
+0.991131 0.116443 0.991167 0.127118 0 0 0 0.00281905 l
+0.991131 0.116443 0.979803 0.113648 0 0 0 0.00281905 l
+-0.94595 -0.182985 -0.944427 -0.183279 0 0 0 0.00281905 l
+-0.907521 0.288084 -0.901597 0.307318 0 0 0 0.00281905 l
+-0.907521 0.288084 -0.905592 0.287089 0 0 0 0.00281905 l
+-0.907521 0.288084 -0.916704 0.269573 0 0 0 0.00281905 l
+-0.55569 0.576532 -0.546757 0.595024 0 0 0 0.00281905 l
+-0.55569 0.576532 -0.56109 0.56863 0 0 0 0.00281905 l
+0.0281375 -0.437151 0.0297063 -0.430098 0 0 0 0.00281905 l
+0.0281375 -0.437151 0.0342286 -0.446214 0 0 0 0.00281905 l
+0.0281375 -0.437151 0.0169789 -0.434153 0 0 0 0.00281905 l
+0.473415 -0.0581657 0.485347 -0.0579699 0 0 0 0.00281905 l
+0.473415 -0.0581657 0.462674 -0.0533953 0 0 0 0.00281905 l
+0.193578 0.605487 0.20415 0.606996 0 0 0 0.00281905 l
+0.193578 0.605487 0.190532 0.603587 0 0 0 0.00281905 l
+0.691265 -0.542416 0.687533 -0.540981 0 0 0 0.00281905 l
+0.288529 0.728534 0.286838 0.718016 0 0 0 0.00281905 l
+-0.121686 0.854627 -0.116348 0.851228 0 0 0 0.00281905 l
+-0.121686 0.854627 -0.12539 0.84493 0 0 0 0.00281905 l
+-0.121686 0.854627 -0.134641 0.855131 0 0 0 0.00281905 l
+0.238853 0.758101 0.24066 0.76921 0 0 0 0.00281905 l
+0.238853 0.758101 0.22846 0.751789 0 0 0 0.00281905 l
+0.694562 -0.434884 0.700614 -0.429468 0 0 0 0.00281905 l
+0.694562 -0.434884 0.681718 -0.444874 0 0 0 0.00281905 l
+-0.390618 -0.667773 -0.383187 -0.663101 0 0 0 0.00281905 l
+-0.390618 -0.667773 -0.40063 -0.663096 0 0 0 0.00281905 l
+-0.696755 -0.646714 -0.697241 -0.637901 0 0 0 0.00281905 l
+-0.696755 -0.646714 -0.69285 -0.652463 0 0 0 0.00281905 l
+-0.0276785 -0.974424 -0.0143689 -0.975676 0 0 0 0.00281905 l
+-0.0276785 -0.974424 -0.0343855 -0.96771 0 0 0 0.00281905 l
+0.635641 0.212347 0.658198 0.207619 0 0 0 0.00281905 l
+0.581534 0.186327 0.573908 0.199861 0 0 0 0.00281905 l
+0.581534 0.186327 0.573743 0.176833 0 0 0 0.00281905 l
+-0.860771 -0.0720439 -0.862557 -0.0639363 0 0 0 0.00281905 l
+-0.860771 -0.0720439 -0.857619 -0.0790086 0 0 0 0.00281905 l
+0.368044 -0.286922 0.378807 -0.285628 0 0 0 0.00281905 l
+0.368044 -0.286922 0.362421 -0.293309 0 0 0 0.00281905 l
+-0.488131 -0.77713 -0.487309 -0.757779 0 0 0 0.00281905 l
+-0.488131 -0.77713 -0.499013 -0.778098 0 0 0 0.00281905 l
+-0.516558 0.137046 -0.515815 0.146819 0 0 0 0.00281905 l
+-0.516558 0.137046 -0.504274 0.137483 0 0 0 0.00281905 l
+-0.18426 0.0388021 -0.185058 0.0458942 0 0 0 0.00281905 l
+-0.18426 0.0388021 -0.171585 0.0379873 0 0 0 0.00281905 l
+0.193307 0.249766 0.182396 0.261844 0 0 0 0.00281905 l
+0.253131 -0.271794 0.263411 -0.274071 0 0 0 0.00281905 l
+0.253131 -0.271794 0.253448 -0.27984 0 0 0 0.00281905 l
+0.253131 -0.271794 0.258111 -0.263949 0 0 0 0.00281905 l
+-0.0165989 -0.00781046 -0.000892871 -0.014212 0 0 0 0.00281905 l
+-0.0165989 -0.00781046 -0.027122 -0.000579469 0 0 0 0.00281905 l
+-0.0165989 -0.00781046 -0.0178294 -0.0103801 0 0 0 0.00281905 l
+0.325924 0.247661 0.345347 0.251955 0 0 0 0.00281905 l
+0.115162 0.687891 0.102012 0.702991 0 0 0 0.00281905 l
+0.115162 0.687891 0.123578 0.67919 0 0 0 0.00281905 l
+-0.239069 0.449006 -0.239671 0.443197 0 0 0 0.00281905 l
+-0.239069 0.449006 -0.244319 0.458575 0 0 0 0.00281905 l
+-0.239069 0.449006 -0.233425 0.453717 0 0 0 0.00281905 l
+0.711571 0.627407 0.718854 0.629992 0 0 0 0.00281905 l
+0.711571 0.627407 0.703983 0.637882 0 0 0 0.00281905 l
+-0.195935 -0.16256 -0.185318 -0.15818 0 0 0 0.00281905 l
+-0.195935 -0.16256 -0.207633 -0.158163 0 0 0 0.00281905 l
+0.649469 -0.532547 0.662617 -0.550955 0 0 0 0.00281905 l
+0.649469 -0.532547 0.645867 -0.515698 0 0 0 0.00281905 l
+0.649469 -0.532547 0.661199 -0.526288 0 0 0 0.00281905 l
+0.649469 -0.532547 0.639028 -0.533705 0 0 0 0.00281905 l
+-0.529485 -0.0976464 -0.523005 -0.111177 0 0 0 0.00281905 l
+0.209144 0.84699 0.214454 0.839349 0 0 0 0.00281905 l
+0.229261 0.100429 0.23851 0.0905993 0 0 0 0.00281905 l
+0.229261 0.100429 0.229957 0.10223 0 0 0 0.00281905 l
+-0.290866 0.400554 -0.29563 0.387552 0 0 0 0.00281905 l
+0.143944 -0.0799475 0.140306 -0.0757422 0 0 0 0.00281905 l
+0.178791 0.122922 0.181837 0.111848 0 0 0 0.00281905 l
+0.178791 0.122922 0.168401 0.123693 0 0 0 0.00281905 l
+0.178791 0.122922 0.181854 0.128919 0 0 0 0.00281905 l
+-0.510155 0.605464 -0.513361 0.610013 0 0 0 0.00281905 l
+-0.510155 0.605464 -0.513686 0.59774 0 0 0 0.00281905 l
+-0.216356 0.898297 -0.217455 0.902435 0 0 0 0.00281905 l
+-0.235964 0.901786 -0.232116 0.887858 0 0 0 0.00281905 l
+-0.235964 0.901786 -0.224068 0.90594 0 0 0 0.00281905 l
+-0.235964 0.901786 -0.243749 0.908572 0 0 0 0.00281905 l
+-0.120147 0.750978 -0.116141 0.75592 0 0 0 0.00281905 l
+0.157154 -0.716511 0.159504 -0.722235 0 0 0 0.00281905 l
+0.157154 -0.716511 0.139271 -0.711176 0 0 0 0.00281905 l
+-0.817255 0.0275186 -0.822655 0.0375448 0 0 0 0.00281905 l
+-0.817255 0.0275186 -0.817779 0.0254674 0 0 0 0.00281905 l
+0.0104353 0.98587 0.0344408 0.990338 0 0 0 0.00281905 l
+0.0104353 0.98587 -0.00246756 0.970526 0 0 0 0.00281905 l
+-0.308751 -0.306904 -0.310971 -0.314509 0 0 0 0.00281905 l
+0.48796 0.33334 0.482188 0.349874 0 0 0 0.00281905 l
+0.48796 0.33334 0.479696 0.319038 0 0 0 0.00281905 l
+0.365072 -0.675384 0.37792 -0.679004 0 0 0 0.00281905 l
+0.365072 -0.675384 0.359743 -0.693365 0 0 0 0.00281905 l
+-0.886005 0.0466323 -0.87529 0.0475248 0 0 0 0.00281905 l
+-0.886005 0.0466323 -0.902096 0.0544831 0 0 0 0.00281905 l
+-0.842705 0.306046 -0.833396 0.29143 0 0 0 0.00281905 l
+-0.842705 0.306046 -0.83085 0.314394 0 0 0 0.00281905 l
+-0.842705 0.306046 -0.851938 0.303416 0 0 0 0.00281905 l
+-0.82046 0.260705 -0.818235 0.262678 0 0 0 0.00281905 l
+0.775272 -0.174678 0.776248 -0.184908 0 0 0 0.00281905 l
+0.775272 -0.174678 0.778383 -0.174234 0 0 0 0.00281905 l
+0.775272 -0.174678 0.769006 -0.175617 0 0 0 0.00281905 l
+0.0175271 0.111767 0.0229649 0.0996016 0 0 0 0.00281905 l
+0.0175271 0.111767 0.0291488 0.113412 0 0 0 0.00281905 l
+0.0175271 0.111767 0.0119631 0.109488 0 0 0 0.00281905 l
+-0.579603 -0.473129 -0.577132 -0.483894 0 0 0 0.00281905 l
+-0.579603 -0.473129 -0.578543 -0.467186 0 0 0 0.00281905 l
+0.684986 0.518294 0.684993 0.512614 0 0 0 0.00281905 l
+0.684986 0.518294 0.694848 0.535382 0 0 0 0.00281905 l
+0.393776 0.769831 0.410191 0.764462 0 0 0 0.00281905 l
+0.393776 0.769831 0.38624 0.772718 0 0 0 0.00281905 l
+0.393776 0.769831 0.391784 0.766422 0 0 0 0.00281905 l
+0.499236 -0.693166 0.500648 -0.70138 0 0 0 0.00281905 l
+0.499236 -0.693166 0.491724 -0.688434 0 0 0 0.00281905 l
+0.00320947 0.680519 0.00167698 0.690373 0 0 0 0.00281905 l
+0.00320947 0.680519 0.0136158 0.672032 0 0 0 0.00281905 l
+0.00320947 0.680519 -0.00303749 0.668337 0 0 0 0.00281905 l
+0.033004 -0.00871693 0.0464922 0.0032031 0 0 0 0.00281905 l
+0.033004 -0.00871693 0.040773 -0.0167496 0 0 0 0.00281905 l
+0.130862 -0.896819 0.125004 -0.888027 0 0 0 0.00281905 l
+0.130862 -0.896819 0.144012 -0.892973 0 0 0 0.00281905 l
+0.130862 -0.896819 0.12317 -0.899219 0 0 0 0.00281905 l
+-0.751796 0.312805 -0.744326 0.307725 0 0 0 0.00281905 l
+-0.175209 -0.192221 -0.165193 -0.204005 0 0 0 0.00281905 l
+-0.175209 -0.192221 -0.187522 -0.198287 0 0 0 0.00281905 l
+-0.175209 -0.192221 -0.175667 -0.190113 0 0 0 0.00281905 l
+0.460556 0.337057 0.464241 0.346221 0 0 0 0.00281905 l
+-0.400799 -0.0418487 -0.399598 -0.0370971 0 0 0 0.00281905 l
+-0.400799 -0.0418487 -0.397155 -0.0435873 0 0 0 0.00281905 l
+-0.400799 -0.0418487 -0.418141 -0.0422675 0 0 0 0.00281905 l
+-0.517191 0.375073 -0.517601 0.394785 0 0 0 0.00281905 l
+-0.517191 0.375073 -0.503398 0.365699 0 0 0 0.00281905 l
+-0.935223 0.294584 -0.93179 0.303601 0 0 0 0.00281905 l
+-0.935223 0.294584 -0.941154 0.282361 0 0 0 0.00281905 l
+0.387689 0.837541 0.385682 0.827492 0 0 0 0.00281905 l
+0.387689 0.837541 0.388484 0.841124 0 0 0 0.00281905 l
+-0.354723 -0.564646 -0.349437 -0.567291 0 0 0 0.00281905 l
+-0.354723 -0.564646 -0.358505 -0.567961 0 0 0 0.00281905 l
+-0.949143 0.11944 -0.943956 0.135957 0 0 0 0.00281905 l
+-0.949143 0.11944 -0.949853 0.117858 0 0 0 0.00281905 l
+0.847489 -0.338987 0.855307 -0.32581 0 0 0 0.00281905 l
+0.847489 -0.338987 0.852208 -0.340956 0 0 0 0.00281905 l
+0.847489 -0.338987 0.836938 -0.337789 0 0 0 0.00281905 l
+0.077044 -0.539368 0.0871399 -0.538193 0 0 0 0.00281905 l
+0.077044 -0.539368 0.0623154 -0.532317 0 0 0 0.00281905 l
+0.00606472 -0.974154 0.00687329 -0.957147 0 0 0 0.00281905 l
+0.00606472 -0.974154 0.018374 -0.976908 0 0 0 0.00281905 l
+0.00606472 -0.974154 0.000522187 -0.974772 0 0 0 0.00281905 l
+-0.0386715 -0.0431681 -0.0400169 -0.0520873 0 0 0 0.00281905 l
+-0.0386715 -0.0431681 -0.0339329 -0.0342905 0 0 0 0.00281905 l
+-0.420041 -0.795592 -0.419906 -0.805386 0 0 0 0.00281905 l
+-0.420041 -0.795592 -0.416449 -0.793478 0 0 0 0.00281905 l
+-0.420041 -0.795592 -0.422638 -0.795734 0 0 0 0.00281905 l
+0.33906 0.307393 0.339385 0.314651 0 0 0 0.00281905 l
+0.33906 0.307393 0.335631 0.301311 0 0 0 0.00281905 l
+-0.703944 0.00866701 -0.701125 0.0135103 0 0 0 0.00281905 l
+0.843877 -0.533248 0.839425 -0.508671 0 0 0 0.00281905 l
+0.843877 -0.533248 0.824022 -0.541012 0 0 0 0.00281905 l
+-0.276084 0.849664 -0.264827 0.870312 0 0 0 0.00281905 l
+-0.276084 0.849664 -0.282038 0.845353 0 0 0 0.00281905 l
+-0.829384 0.462973 -0.836822 0.481311 0 0 0 0.00281905 l
+-0.829384 0.462973 -0.821005 0.463393 0 0 0 0.00281905 l
+0.0859229 -0.870245 0.0662144 -0.864503 0 0 0 0.00281905 l
+0.595709 0.703359 0.590118 0.695906 0 0 0 0.00281905 l
+0.595709 0.703359 0.595538 0.705009 0 0 0 0.00281905 l
+0.595709 0.703359 0.600707 0.702028 0 0 0 0.00281905 l
+0.52295 -0.487863 0.512947 -0.476369 0 0 0 0.00281905 l
+-0.483541 -0.268556 -0.483274 -0.275463 0 0 0 0.00281905 l
+0.229789 0.613911 0.239388 0.610868 0 0 0 0.00281905 l
+0.229789 0.613911 0.230374 0.600931 0 0 0 0.00281905 l
+0.229789 0.613911 0.218971 0.614714 0 0 0 0.00281905 l
+0.245764 -0.376485 0.249746 -0.380614 0 0 0 0.00281905 l
+0.245764 -0.376485 0.239759 -0.370918 0 0 0 0.00281905 l
+-0.524123 -0.641862 -0.519931 -0.65778 0 0 0 0.00281905 l
+-0.524123 -0.641862 -0.522012 -0.631433 0 0 0 0.00281905 l
+-0.524123 -0.641862 -0.510249 -0.641163 0 0 0 0.00281905 l
+-0.524123 -0.641862 -0.535316 -0.637018 0 0 0 0.00281905 l
+-0.772194 -0.347793 -0.768256 -0.362282 0 0 0 0.00281905 l
+-0.772194 -0.347793 -0.786273 -0.352667 0 0 0 0.00281905 l
+0.658532 -0.730983 0.66805 -0.728082 0 0 0 0.00281905 l
+0.658532 -0.730983 0.64706 -0.729154 0 0 0 0.00281905 l
+0.58804 -0.144247 0.591195 -0.134275 0 0 0 0.00281905 l
+0.194446 0.30009 0.206586 0.318078 0 0 0 0.00281905 l
+0.732376 0.112982 0.731846 0.124674 0 0 0 0.00281905 l
+0.732376 0.112982 0.724418 0.104039 0 0 0 0.00281905 l
+0.880405 0.428363 0.897255 0.437277 0 0 0 0.00281905 l
+0.880405 0.428363 0.882633 0.424663 0 0 0 0.00281905 l
+0.880405 0.428363 0.860934 0.435851 0 0 0 0.00281905 l
+0.239388 0.610868 0.229789 0.613911 0 0 0 0.00281905 l
+-0.0706839 -0.513423 -0.0747043 -0.523731 0 0 0 0.00281905 l
+-0.438617 0.34292 -0.45135 0.355661 0 0 0 0.00281905 l
+-0.438617 0.34292 -0.444111 0.338088 0 0 0 0.00281905 l
+0.00600318 -0.119377 -0.0141802 -0.122026 0 0 0 0.00281905 l
+0.425751 0.670064 0.421707 0.655813 0 0 0 0.00281905 l
+0.425751 0.670064 0.437985 0.673761 0 0 0 0.00281905 l
+0.425751 0.670064 0.414944 0.671736 0 0 0 0.00281905 l
+0.883553 0.234628 0.889835 0.248453 0 0 0 0.00281905 l
+0.883553 0.234628 0.891256 0.232533 0 0 0 0.00281905 l
+0.137983 0.756011 0.142679 0.765803 0 0 0 0.00281905 l
+0.137983 0.756011 0.157482 0.738069 0 0 0 0.00281905 l
+0.788237 0.0539035 0.799095 0.0488866 0 0 0 0.00281905 l
+0.788237 0.0539035 0.780967 0.0702956 0 0 0 0.00281905 l
+0.788237 0.0539035 0.777687 0.0377925 0 0 0 0.00281905 l
+0.151503 0.725332 0.158898 0.735325 0 0 0 0.00281905 l
+0.151503 0.725332 0.162961 0.7185 0 0 0 0.00281905 l
+0.151503 0.725332 0.145121 0.725514 0 0 0 0.00281905 l
+0.320829 0.3979 0.321619 0.380611 0 0 0 0.00281905 l
+0.320829 0.3979 0.322648 0.40715 0 0 0 0.00281905 l
+-0.234327 0.310245 -0.219016 0.322865 0 0 0 0.00281905 l
+-0.234327 0.310245 -0.233418 0.297107 0 0 0 0.00281905 l
+-0.599126 -0.0200293 -0.592022 -0.00802412 0 0 0 0.00281905 l
+-0.599126 -0.0200293 -0.600431 -0.0375296 0 0 0 0.00281905 l
+-0.599126 -0.0200293 -0.611013 -0.0121431 0 0 0 0.00281905 l
+-0.304256 0.133978 -0.304484 0.138749 0 0 0 0.00281905 l
+-0.304256 0.133978 -0.291983 0.129124 0 0 0 0.00281905 l
+-0.304256 0.133978 -0.309314 0.123802 0 0 0 0.00281905 l
+0.405423 -0.0637036 0.418581 -0.0533448 0 0 0 0.00281905 l
+0.405423 -0.0637036 0.395912 -0.0766517 0 0 0 0.00281905 l
+-0.181564 0.553376 -0.170797 0.565572 0 0 0 0.00281905 l
+-0.181564 0.553376 -0.188323 0.56668 0 0 0 0.00281905 l
+-0.898061 -0.153156 -0.900706 -0.142356 0 0 0 0.00281905 l
+-0.898061 -0.153156 -0.895315 -0.154381 0 0 0 0.00281905 l
+0.506627 -0.068885 0.511616 -0.0734819 0 0 0 0.00281905 l
+-0.418141 -0.0422675 -0.422156 -0.0566317 0 0 0 0.00281905 l
+-0.418141 -0.0422675 -0.400799 -0.0418487 0 0 0 0.00281905 l
+-0.418141 -0.0422675 -0.432147 -0.0382859 0 0 0 0.00281905 l
+-0.7835 0.223876 -0.781998 0.234768 0 0 0 0.00281905 l
+-0.7835 0.223876 -0.781055 0.208836 0 0 0 0.00281905 l
+-0.534944 -0.531927 -0.539605 -0.513836 0 0 0 0.00281905 l
+-0.534944 -0.531927 -0.513811 -0.542973 0 0 0 0.00281905 l
+-0.534944 -0.531927 -0.539839 -0.532737 0 0 0 0.00281905 l
+0.383687 0.0318404 0.389025 0.0481102 0 0 0 0.00281905 l
+0.383687 0.0318404 0.372788 0.0385112 0 0 0 0.00281905 l
+0.383687 0.0318404 0.381545 0.0280405 0 0 0 0.00281905 l
+-0.373027 0.421394 -0.364811 0.405046 0 0 0 0.00281905 l
+-0.373027 0.421394 -0.367884 0.430902 0 0 0 0.00281905 l
+0.415708 -0.12444 0.413871 -0.115406 0 0 0 0.00281905 l
+0.799205 0.112785 0.800094 0.101442 0 0 0 0.00281905 l
+0.799205 0.112785 0.793837 0.122679 0 0 0 0.00281905 l
+0.799205 0.112785 0.801417 0.113397 0 0 0 0.00281905 l
+-0.329793 0.422705 -0.331569 0.429098 0 0 0 0.00281905 l
+-0.329793 0.422705 -0.322111 0.415716 0 0 0 0.00281905 l
+-0.329793 0.422705 -0.33804 0.409234 0 0 0 0.00281905 l
+0.343073 0.548973 0.348923 0.551491 0 0 0 0.00281905 l
+0.343073 0.548973 0.338889 0.537533 0 0 0 0.00281905 l
+0.603563 0.547481 0.602876 0.547689 0 0 0 0.00281905 l
+0.00648479 0.340854 0.00513286 0.351256 0 0 0 0.00281905 l
+0.00648479 0.340854 0.0132111 0.33875 0 0 0 0.00281905 l
+0.977199 0.113626 0.979803 0.113648 0 0 0 0.00281905 l
+0.977199 0.113626 0.953854 0.122269 0 0 0 0.00281905 l
+-0.0147365 0.630483 -0.0074681 0.63859 0 0 0 0.00281905 l
+-0.0147365 0.630483 -0.0309986 0.638417 0 0 0 0.00281905 l
+-0.722619 -0.6836 -0.718355 -0.692688 0 0 0 0.00281905 l
+0.381735 -0.036384 0.376004 -0.0487393 0 0 0 0.00281905 l
+0.381735 -0.036384 0.400747 -0.033372 0 0 0 0.00281905 l
+-0.577367 -0.526671 -0.575461 -0.511595 0 0 0 0.00281905 l
+-0.577367 -0.526671 -0.57318 -0.527562 0 0 0 0.00281905 l
+-0.577367 -0.526671 -0.585245 -0.525197 0 0 0 0.00281905 l
+0.575804 0.426993 0.582244 0.438478 0 0 0 0.00281905 l
+0.575804 0.426993 0.579847 0.425204 0 0 0 0.00281905 l
+0.210369 -0.42076 0.222964 -0.408546 0 0 0 0.00281905 l
+-0.116015 0.30627 -0.115233 0.302014 0 0 0 0.00281905 l
+-0.116015 0.30627 -0.126637 0.315117 0 0 0 0.00281905 l
+0.654317 -0.328948 0.653593 -0.312451 0 0 0 0.00281905 l
+0.913723 0.0158251 0.912548 -0.00556433 0 0 0 0.00281905 l
+0.913723 0.0158251 0.907007 0.020923 0 0 0 0.00281905 l
+-0.238827 -0.0455218 -0.235598 -0.047461 0 0 0 0.00281905 l
+-0.238827 -0.0455218 -0.257268 -0.0410096 0 0 0 0.00281905 l
+-0.0438899 -0.91058 -0.0363511 -0.915851 0 0 0 0.00281905 l
+-0.0438899 -0.91058 -0.0514841 -0.916103 0 0 0 0.00281905 l
+-0.327894 0.0450649 -0.320944 0.0404954 0 0 0 0.00281905 l
+-0.327894 0.0450649 -0.329713 0.046071 0 0 0 0.00281905 l
+-0.972613 0.22711 -0.975718 0.218857 0 0 0 0.00281905 l
+0.899766 0.0965962 0.908931 0.0944769 0 0 0 0.00281905 l
+0.899766 0.0965962 0.894183 0.103661 0 0 0 0.00281905 l
+0.899766 0.0965962 0.893483 0.0929721 0 0 0 0.00281905 l
+-0.530149 0.0859213 -0.525805 0.0876112 0 0 0 0.00281905 l
+-0.530149 0.0859213 -0.525632 0.0763348 0 0 0 0.00281905 l
+-0.530149 0.0859213 -0.547057 0.0947999 0 0 0 0.00281905 l
+-0.700504 0.348021 -0.69775 0.36611 0 0 0 0.00281905 l
+-0.700504 0.348021 -0.71721 0.345414 0 0 0 0.00281905 l
+-0.0303317 -0.107029 -0.0287266 -0.0982455 0 0 0 0.00281905 l
+-0.0303317 -0.107029 -0.0141802 -0.122026 0 0 0 0.00281905 l
+-0.0303317 -0.107029 -0.0437732 -0.105416 0 0 0 0.00281905 l
+-0.016909 0.725782 0.000430739 0.726857 0 0 0 0.00281905 l
+-0.016909 0.725782 -0.023499 0.731846 0 0 0 0.00281905 l
+-0.016909 0.725782 -0.021102 0.720428 0 0 0 0.00281905 l
+0.614082 0.202625 0.616196 0.19513 0 0 0 0.00281905 l
+0.614082 0.202625 0.602566 0.218646 0 0 0 0.00281905 l
+0.732757 -0.27178 0.741704 -0.272312 0 0 0 0.00281905 l
+0.732757 -0.27178 0.725653 -0.263959 0 0 0 0.00281905 l
+0.314249 0.504321 0.313265 0.525326 0 0 0 0.00281905 l
+0.314249 0.504321 0.309692 0.4896 0 0 0 0.00281905 l
+-0.61335 0.158522 -0.616834 0.140074 0 0 0 0.00281905 l
+-0.61335 0.158522 -0.626341 0.174345 0 0 0 0.00281905 l
+0.0755072 -0.133152 0.068112 -0.121265 0 0 0 0.00281905 l
+0.0755072 -0.133152 0.07846 -0.145534 0 0 0 0.00281905 l
+0.798288 -0.40179 0.796461 -0.389096 0 0 0 0.00281905 l
+0.798288 -0.40179 0.789085 -0.408865 0 0 0 0.00281905 l
+0.408156 0.574388 0.419496 0.590839 0 0 0 0.00281905 l
+0.408156 0.574388 0.401705 0.577364 0 0 0 0.00281905 l
+-0.486151 0.781248 -0.481666 0.777905 0 0 0 0.00281905 l
+-0.486151 0.781248 -0.501274 0.771769 0 0 0 0.00281905 l
+-0.0865326 0.331707 -0.0750595 0.335374 0 0 0 0.00281905 l
+-0.0865326 0.331707 -0.0969485 0.33264 0 0 0 0.00281905 l
+0.180685 -0.248905 0.180554 -0.25523 0 0 0 0.00281905 l
+0.180685 -0.248905 0.191848 -0.247718 0 0 0 0.00281905 l
+0.180685 -0.248905 0.179976 -0.240723 0 0 0 0.00281905 l
+-0.891073 -0.00357615 -0.884227 -0.00884595 0 0 0 0.00281905 l
+-0.891073 -0.00357615 -0.894943 -0.00108552 0 0 0 0.00281905 l
+0.447947 -0.0728956 0.462986 -0.078583 0 0 0 0.00281905 l
+0.447947 -0.0728956 0.443728 -0.0804721 0 0 0 0.00281905 l
+0.565714 0.599313 0.576305 0.581426 0 0 0 0.00281905 l
+0.565714 0.599313 0.564068 0.612402 0 0 0 0.00281905 l
+0.565714 0.599313 0.576371 0.602917 0 0 0 0.00281905 l
+0.565714 0.599313 0.554567 0.598977 0 0 0 0.00281905 l
+-0.659829 0.136879 -0.6626 0.155326 0 0 0 0.00281905 l
+-0.659829 0.136879 -0.64963 0.124316 0 0 0 0.00281905 l
+-0.659829 0.136879 -0.67852 0.130741 0 0 0 0.00281905 l
+-0.919618 0.0185415 -0.911963 0.0127607 0 0 0 0.00281905 l
+0.317729 0.536861 0.326346 0.533894 0 0 0 0.00281905 l
+0.317729 0.536861 0.313265 0.525326 0 0 0 0.00281905 l
+-0.160281 -0.705928 -0.144465 -0.722234 0 0 0 0.00281905 l
+-0.160281 -0.705928 -0.175121 -0.704277 0 0 0 0.00281905 l
+0.226267 0.727965 0.243925 0.728833 0 0 0 0.00281905 l
+0.226267 0.727965 0.219034 0.730701 0 0 0 0.00281905 l
+-0.168691 0.969757 -0.159352 0.972004 0 0 0 0.00281905 l
+-0.168691 0.969757 -0.17541 0.976407 0 0 0 0.00281905 l
+-0.314232 0.459774 -0.294853 0.466583 0 0 0 0.00281905 l
+-0.314232 0.459774 -0.317893 0.449859 0 0 0 0.00281905 l
+-0.314232 0.459774 -0.321003 0.46477 0 0 0 0.00281905 l
+-0.617316 -0.541915 -0.606868 -0.52957 0 0 0 0.00281905 l
+-0.617316 -0.541915 -0.616718 -0.554948 0 0 0 0.00281905 l
+-0.233418 0.297107 -0.234327 0.310245 0 0 0 0.00281905 l
+-0.233418 0.297107 -0.241066 0.283955 0 0 0 0.00281905 l
+-0.185372 -0.0804114 -0.181808 -0.0866542 0 0 0 0.00281905 l
+-0.185372 -0.0804114 -0.188815 -0.0783077 0 0 0 0.00281905 l
+0.995439 0.00548529 0.978191 0.00579893 0 0 0 0.00281905 l
+0.680328 -0.128861 0.683385 -0.145998 0 0 0 0.00281905 l
+0.587435 -0.334624 0.586324 -0.338908 0 0 0 0.00281905 l
+-0.0421546 -0.740398 -0.0371457 -0.762064 0 0 0 0.00281905 l
+-0.0421546 -0.740398 -0.03441 -0.733979 0 0 0 0.00281905 l
+-0.0421546 -0.740398 -0.0484475 -0.729703 0 0 0 0.00281905 l
+-0.234754 -0.573227 -0.224412 -0.58172 0 0 0 0.00281905 l
+-0.234754 -0.573227 -0.226829 -0.567501 0 0 0 0.00281905 l
+-0.234754 -0.573227 -0.254477 -0.582653 0 0 0 0.00281905 l
+-0.0894777 -0.669489 -0.0820827 -0.671559 0 0 0 0.00281905 l
+-0.0894777 -0.669489 -0.0960864 -0.676841 0 0 0 0.00281905 l
+-0.0894777 -0.669489 -0.0906788 -0.666264 0 0 0 0.00281905 l
+-0.735849 0.289693 -0.741864 0.300878 0 0 0 0.00281905 l
+-0.735849 0.289693 -0.74049 0.280808 0 0 0 0.00281905 l
+0.557535 0.12334 0.550901 0.113589 0 0 0 0.00281905 l
+0.616806 -0.188923 0.622471 -0.198466 0 0 0 0.00281905 l
+0.616806 -0.188923 0.608427 -0.175089 0 0 0 0.00281905 l
+0.616806 -0.188923 0.626533 -0.182653 0 0 0 0.00281905 l
+0.616806 -0.188923 0.603018 -0.193661 0 0 0 0.00281905 l
+0.908885 -0.0529987 0.911779 -0.0458675 0 0 0 0.00281905 l
+0.908885 -0.0529987 0.904671 -0.0587103 0 0 0 0.00281905 l
+-0.0520973 0.153967 -0.0477335 0.162449 0 0 0 0.00281905 l
+-0.0520973 0.153967 -0.0513802 0.153568 0 0 0 0.00281905 l
+-0.0520973 0.153967 -0.0708522 0.15141 0 0 0 0.00281905 l
+-0.205672 -0.855439 -0.20154 -0.868496 0 0 0 0.00281905 l
+-0.205672 -0.855439 -0.203261 -0.838536 0 0 0 0.00281905 l
+-0.205672 -0.855439 -0.187701 -0.849803 0 0 0 0.00281905 l
+-0.265421 0.0276249 -0.254695 0.0358275 0 0 0 0.00281905 l
+-0.795576 0.0552122 -0.798803 0.0566113 0 0 0 0.00281905 l
+0.487131 -0.663094 0.499593 -0.671025 0 0 0 0.00281905 l
+0.613139 0.107505 0.625174 0.105729 0 0 0 0.00281905 l
+0.613139 0.107505 0.610185 0.108837 0 0 0 0.00281905 l
+-0.609774 -0.20354 -0.60919 -0.20581 0 0 0 0.00281905 l
+-0.609774 -0.20354 -0.611812 -0.201149 0 0 0 0.00281905 l
+0.289964 -0.482375 0.294641 -0.486899 0 0 0 0.00281905 l
+0.289964 -0.482375 0.285563 -0.477153 0 0 0 0.00281905 l
+0.744515 0.249288 0.739902 0.240474 0 0 0 0.00281905 l
+0.744515 0.249288 0.74326 0.256704 0 0 0 0.00281905 l
+0.906446 0.227343 0.910972 0.240045 0 0 0 0.00281905 l
+0.906446 0.227343 0.912829 0.215637 0 0 0 0.00281905 l
+0.906446 0.227343 0.902621 0.226426 0 0 0 0.00281905 l
+-0.0888636 -0.179631 -0.0754869 -0.178834 0 0 0 0.00281905 l
+-0.0888636 -0.179631 -0.105063 -0.176941 0 0 0 0.00281905 l
+-0.592351 -0.398914 -0.610198 -0.39078 0 0 0 0.00281905 l
+-0.103269 0.569469 -0.107926 0.585005 0 0 0 0.00281905 l
+-0.103269 0.569469 -0.0983433 0.56889 0 0 0 0.00281905 l
+-0.103269 0.569469 -0.110962 0.566268 0 0 0 0.00281905 l
+-0.539032 -0.655267 -0.540188 -0.678303 0 0 0 0.00281905 l
+-0.539032 -0.655267 -0.542537 -0.647118 0 0 0 0.00281905 l
+0.40124 0.38329 0.400865 0.377707 0 0 0 0.00281905 l
+0.531514 0.446818 0.546921 0.455187 0 0 0 0.00281905 l
+0.531514 0.446818 0.527305 0.443712 0 0 0 0.00281905 l
+-0.329215 0.762734 -0.337272 0.747757 0 0 0 0.00281905 l
+-0.329215 0.762734 -0.327142 0.765425 0 0 0 0.00281905 l
+-0.452768 -0.330229 -0.44396 -0.339364 0 0 0 0.00281905 l
+-0.452768 -0.330229 -0.462547 -0.3433 0 0 0 0.00281905 l
+-0.452768 -0.330229 -0.446718 -0.323224 0 0 0 0.00281905 l
+0.474232 -0.764566 0.472804 -0.767584 0 0 0 0.00281905 l
+-0.274911 -0.697169 -0.276917 -0.693119 0 0 0 0.00281905 l
+-0.274911 -0.697169 -0.283034 -0.707572 0 0 0 0.00281905 l
+-0.657997 0.66921 -0.656626 0.678816 0 0 0 0.00281905 l
+-0.657997 0.66921 -0.681561 0.665741 0 0 0 0.00281905 l
+-0.527648 -0.390076 -0.530504 -0.384398 0 0 0 0.00281905 l
+-0.63689 -0.119688 -0.64946 -0.124069 0 0 0 0.00281905 l
+0.504196 0.505077 0.516114 0.514975 0 0 0 0.00281905 l
+0.504196 0.505077 0.511954 0.493328 0 0 0 0.00281905 l
+-0.221838 -0.267337 -0.207961 -0.272411 0 0 0 0.00281905 l
+-0.221838 -0.267337 -0.230241 -0.270756 0 0 0 0.00281905 l
+-0.46323 0.235681 -0.454904 0.232475 0 0 0 0.00281905 l
+-0.46323 0.235681 -0.467981 0.228418 0 0 0 0.00281905 l
+-0.46323 0.235681 -0.469679 0.237555 0 0 0 0.00281905 l
+0.0544324 -0.941333 0.0619705 -0.945131 0 0 0 0.00281905 l
+0.0544324 -0.941333 0.0478441 -0.940275 0 0 0 0.00281905 l
+-0.535362 0.496492 -0.531972 0.495561 0 0 0 0.00281905 l
+-0.535362 0.496492 -0.54652 0.506373 0 0 0 0.00281905 l
+-0.671443 -0.475682 -0.671516 -0.479482 0 0 0 0.00281905 l
+-0.671443 -0.475682 -0.66216 -0.469287 0 0 0 0.00281905 l
+0.52433 0.10176 0.521323 0.0865356 0 0 0 0.00281905 l
+0.52433 0.10176 0.534043 0.102583 0 0 0 0.00281905 l
+0.52433 0.10176 0.516743 0.109334 0 0 0 0.00281905 l
+0.89125 0.185141 0.887296 0.191698 0 0 0 0.00281905 l
+-0.283313 0.605428 -0.283706 0.617742 0 0 0 0.00281905 l
+-0.283313 0.605428 -0.26188 0.604139 0 0 0 0.00281905 l
+0.488906 0.243299 0.4892 0.262729 0 0 0 0.00281905 l
+0.488906 0.243299 0.493614 0.231338 0 0 0 0.00281905 l
+0.458006 -0.218894 0.455486 -0.21582 0 0 0 0.00281905 l
+-0.18994 0.400256 -0.180647 0.402719 0 0 0 0.00281905 l
+-0.18994 0.400256 -0.192347 0.401921 0 0 0 0.00281905 l
+-0.396019 -0.0876371 -0.395111 -0.0807875 0 0 0 0.00281905 l
+-0.396019 -0.0876371 -0.386004 -0.0979852 0 0 0 0.00281905 l
+0.437038 0.511337 0.444396 0.513378 0 0 0 0.00281905 l
+0.437038 0.511337 0.418485 0.51891 0 0 0 0.00281905 l
+-0.892681 0.266595 -0.882722 0.259391 0 0 0 0.00281905 l
+-0.892681 0.266595 -0.88469 0.273331 0 0 0 0.00281905 l
+-0.424112 -0.367534 -0.420462 -0.354003 0 0 0 0.00281905 l
+-0.424112 -0.367534 -0.413072 -0.378193 0 0 0 0.00281905 l
+-0.652747 -0.756496 -0.63985 -0.746481 0 0 0 0.00281905 l
+-0.652747 -0.756496 -0.657953 -0.751981 0 0 0 0.00281905 l
+0.768058 0.141918 0.78403 0.146757 0 0 0 0.00281905 l
+0.768058 0.141918 0.759219 0.150893 0 0 0 0.00281905 l
+0.768058 0.141918 0.760149 0.135229 0 0 0 0.00281905 l
+-0.415489 -0.397931 -0.41823 -0.388103 0 0 0 0.00281905 l
+-0.427955 0.219468 -0.414869 0.238499 0 0 0 0.00281905 l
+-0.427955 0.219468 -0.430225 0.213961 0 0 0 0.00281905 l
+-0.191371 -0.774802 -0.182175 -0.788924 0 0 0 0.00281905 l
+-0.191371 -0.774802 -0.191339 -0.774652 0 0 0 0.00281905 l
+0.0829917 -0.275024 0.0971216 -0.283504 0 0 0 0.00281905 l
+0.0829917 -0.275024 0.0719817 -0.264261 0 0 0 0.00281905 l
+-0.382768 -0.489438 -0.379646 -0.495271 0 0 0 0.00281905 l
+-0.382768 -0.489438 -0.386746 -0.484763 0 0 0 0.00281905 l
+0.0654885 0.407798 0.059776 0.421073 0 0 0 0.00281905 l
+0.270602 -0.239736 0.275491 -0.249488 0 0 0 0.00281905 l
+0.270602 -0.239736 0.284203 -0.230681 0 0 0 0.00281905 l
+0.270602 -0.239736 0.268951 -0.239451 0 0 0 0.00281905 l
+-0.416046 0.319593 -0.423494 0.330223 0 0 0 0.00281905 l
+-0.416046 0.319593 -0.410859 0.310004 0 0 0 0.00281905 l
+-0.356705 0.124652 -0.367697 0.13038 0 0 0 0.00281905 l
+-0.356705 0.124652 -0.344136 0.133933 0 0 0 0.00281905 l
+0.558095 -0.485132 0.567084 -0.489137 0 0 0 0.00281905 l
+0.558095 -0.485132 0.551423 -0.495062 0 0 0 0.00281905 l
+0.558095 -0.485132 0.54534 -0.482509 0 0 0 0.00281905 l
+-0.149135 -0.85928 -0.143542 -0.871417 0 0 0 0.00281905 l
+-0.149135 -0.85928 -0.14142 -0.855694 0 0 0 0.00281905 l
+-0.149135 -0.85928 -0.161095 -0.869227 0 0 0 0.00281905 l
+0.415896 0.614854 0.422983 0.600975 0 0 0 0.00281905 l
+-0.26295 -0.349601 -0.255554 -0.3406 0 0 0 0.00281905 l
+-0.26295 -0.349601 -0.270772 -0.357836 0 0 0 0.00281905 l
+-0.425707 -0.842117 -0.411284 -0.837183 0 0 0 0.00281905 l
+-0.425707 -0.842117 -0.437203 -0.844036 0 0 0 0.00281905 l
+-0.196771 0.209016 -0.196846 0.205775 0 0 0 0.00281905 l
+-0.196771 0.209016 -0.19479 0.212309 0 0 0 0.00281905 l
+0.137896 -0.978451 0.151427 -0.98495 0 0 0 0.00281905 l
+0.137896 -0.978451 0.125228 -0.975849 0 0 0 0.00281905 l
+-0.418018 -0.0712548 -0.422004 -0.0594418 0 0 0 0.00281905 l
+-0.418018 -0.0712548 -0.418477 -0.0766387 0 0 0 0.00281905 l
+0.5399 -0.135484 0.540055 -0.135527 0 0 0 0.00281905 l
+0.5399 -0.135484 0.532923 -0.139301 0 0 0 0.00281905 l
+-0.473493 0.0653732 -0.469134 0.0676284 0 0 0 0.00281905 l
+-0.473493 0.0653732 -0.493155 0.0733156 0 0 0 0.00281905 l
+0.362776 -0.898066 0.363415 -0.890585 0 0 0 0.00281905 l
+0.363165 -0.3128 0.34618 -0.309763 0 0 0 0.00281905 l
+-0.389098 -0.600396 -0.39064 -0.597497 0 0 0 0.00281905 l
+-0.811891 -0.546468 -0.803296 -0.531398 0 0 0 0.00281905 l
+-0.811891 -0.546468 -0.807026 -0.558512 0 0 0 0.00281905 l
+-0.811891 -0.546468 -0.829424 -0.542861 0 0 0 0.00281905 l
+0.624431 0.703688 0.625529 0.716586 0 0 0 0.00281905 l
+0.624431 0.703688 0.6241 0.701227 0 0 0 0.00281905 l
+-0.557703 0.217376 -0.55651 0.208507 0 0 0 0.00281905 l
+-0.557703 0.217376 -0.564791 0.213055 0 0 0 0.00281905 l
+0.00459305 0.219447 0.01002 0.206782 0 0 0 0.00281905 l
+0.00459305 0.219447 -0.000454341 0.217395 0 0 0 0.00281905 l
+-0.55651 0.208507 -0.557703 0.217376 0 0 0 0.00281905 l
+-0.55651 0.208507 -0.56749 0.190688 0 0 0 0.00281905 l
+-0.48158 0.255778 -0.473274 0.247653 0 0 0 0.00281905 l
+0.75031 0.0151408 0.77051 0.0147366 0 0 0 0.00281905 l
+0.75031 0.0151408 0.736871 0.0210706 0 0 0 0.00281905 l
+0.53251 -0.00889918 0.540777 -0.0241911 0 0 0 0.00281905 l
+-0.217455 0.902435 -0.216356 0.898297 0 0 0 0.00281905 l
+-0.217455 0.902435 -0.216222 0.904024 0 0 0 0.00281905 l
+-0.217455 0.902435 -0.224068 0.90594 0 0 0 0.00281905 l
+0.932326 0.10026 0.923665 0.117033 0 0 0 0.00281905 l
+-0.397855 0.840111 -0.410559 0.830107 0 0 0 0.00281905 l
+-0.397855 0.840111 -0.391437 0.845703 0 0 0 0.00281905 l
+-0.397855 0.840111 -0.408976 0.847803 0 0 0 0.00281905 l
+-0.0235383 -0.535621 -0.0150999 -0.547549 0 0 0 0.00281905 l
+-0.0235383 -0.535621 -0.0355175 -0.536145 0 0 0 0.00281905 l
+0.218517 -0.129387 0.224296 -0.121657 0 0 0 0.00281905 l
+0.218517 -0.129387 0.21607 -0.130596 0 0 0 0.00281905 l
+0.114013 -0.397705 0.10916 -0.389834 0 0 0 0.00281905 l
+0.114013 -0.397705 0.109771 -0.401121 0 0 0 0.00281905 l
+-0.236188 -0.845777 -0.23903 -0.84309 0 0 0 0.00281905 l
+-0.111503 -0.453739 -0.112586 -0.469311 0 0 0 0.00281905 l
+-0.111503 -0.453739 -0.111602 -0.43838 0 0 0 0.00281905 l
+-0.455557 -0.789424 -0.457273 -0.780919 0 0 0 0.00281905 l
+-0.455557 -0.789424 -0.433789 -0.786807 0 0 0 0.00281905 l
+-0.280525 0.437008 -0.289864 0.442863 0 0 0 0.00281905 l
+0.20888 0.896361 0.208441 0.88741 0 0 0 0.00281905 l
+0.20888 0.896361 0.216988 0.90413 0 0 0 0.00281905 l
+0.182689 0.343951 0.181653 0.357679 0 0 0 0.00281905 l
+0.182689 0.343951 0.187211 0.344379 0 0 0 0.00281905 l
+-0.244319 0.458575 -0.239069 0.449006 0 0 0 0.00281905 l
+0.375214 -0.825718 0.38867 -0.814051 0 0 0 0.00281905 l
+0.375214 -0.825718 0.372391 -0.826013 0 0 0 0.00281905 l
+-0.181226 0.357034 -0.185899 0.346299 0 0 0 0.00281905 l
+-0.181226 0.357034 -0.179725 0.361433 0 0 0 0.00281905 l
+0.123596 0.198058 0.125318 0.189865 0 0 0 0.00281905 l
+0.123596 0.198058 0.11638 0.192806 0 0 0 0.00281905 l
+0.123596 0.198058 0.118551 0.203455 0 0 0 0.00281905 l
+-0.407178 -0.841708 -0.411284 -0.837183 0 0 0 0.00281905 l
+-0.437845 -0.413323 -0.422496 -0.41745 0 0 0 0.00281905 l
+-0.437845 -0.413323 -0.444528 -0.408589 0 0 0 0.00281905 l
+-0.556872 -0.537646 -0.563969 -0.54973 0 0 0 0.00281905 l
+-0.556872 -0.537646 -0.548624 -0.536184 0 0 0 0.00281905 l
+0.550701 -0.0967541 0.561292 -0.0996268 0 0 0 0.00281905 l
+0.550701 -0.0967541 0.542846 -0.0981971 0 0 0 0.00281905 l
+-0.925487 0.123232 -0.905777 0.118332 0 0 0 0.00281905 l
+-0.925487 0.123232 -0.943956 0.135957 0 0 0 0.00281905 l
+0.0929661 -0.816806 0.106574 -0.822047 0 0 0 0.00281905 l
+0.0929661 -0.816806 0.0843934 -0.818033 0 0 0 0.00281905 l
+-0.135457 -0.190825 -0.130161 -0.190945 0 0 0 0.00281905 l
+-0.135457 -0.190825 -0.150856 -0.188925 0 0 0 0.00281905 l
+0.787786 -0.0186319 0.803505 -0.0245896 0 0 0 0.00281905 l
+0.787786 -0.0186319 0.785901 -0.027345 0 0 0 0.00281905 l
+0.787786 -0.0186319 0.774844 -0.00520352 0 0 0 0.00281905 l
+-0.602122 -0.706662 -0.599565 -0.708621 0 0 0 0.00281905 l
+0.740074 0.447286 0.736852 0.451863 0 0 0 0.00281905 l
+0.740074 0.447286 0.74458 0.449007 0 0 0 0.00281905 l
+0.834154 -0.509433 0.837658 -0.506039 0 0 0 0.00281905 l
+0.834154 -0.509433 0.816037 -0.505268 0 0 0 0.00281905 l
+-0.779455 -0.0515826 -0.775745 -0.0644735 0 0 0 0.00281905 l
+-0.779455 -0.0515826 -0.797203 -0.0612036 0 0 0 0.00281905 l
+0.181837 0.111848 0.178791 0.122922 0 0 0 0.00281905 l
+0.181837 0.111848 0.181347 0.10885 0 0 0 0.00281905 l
+-0.809724 -0.0157454 -0.817462 -0.0125251 0 0 0 0.00281905 l
+0.174931 0.150551 0.176777 0.140502 0 0 0 0.00281905 l
+0.174931 0.150551 0.176102 0.152404 0 0 0 0.00281905 l
+-0.00653477 0.0789303 -0.00574395 0.085142 0 0 0 0.00281905 l
+-0.00653477 0.0789303 -0.0128417 0.0632123 0 0 0 0.00281905 l
+0.0767172 -0.996356 0.0967169 -0.99261 0 0 0 0.00281905 l
+0.000522187 -0.974772 0.00606472 -0.974154 0 0 0 0.00281905 l
+0.000522187 -0.974772 -0.00457386 -0.9805 0 0 0 0.00281905 l
+-0.609816 0.553596 -0.604974 0.554154 0 0 0 0.00281905 l
+-0.609816 0.553596 -0.622844 0.563884 0 0 0 0.00281905 l
+0.289179 -0.0560628 0.279404 -0.0458935 0 0 0 0.00281905 l
+-0.193773 -0.386603 -0.200845 -0.400624 0 0 0 0.00281905 l
+-0.499978 0.00206755 -0.512845 -0.00286025 0 0 0 0.00281905 l
+-0.373135 0.743583 -0.370791 0.734116 0 0 0 0.00281905 l
+-0.373135 0.743583 -0.380806 0.747748 0 0 0 0.00281905 l
+0.0294556 0.413847 0.0340053 0.408223 0 0 0 0.00281905 l
+0.0294556 0.413847 0.0264703 0.415852 0 0 0 0.00281905 l
+0.373278 0.597185 0.384967 0.599581 0 0 0 0.00281905 l
+0.373278 0.597185 0.36411 0.60137 0 0 0 0.00281905 l
+-0.316 0.763805 -0.315215 0.764588 0 0 0 0.00281905 l
+-0.316 0.763805 -0.327142 0.765425 0 0 0 0.00281905 l
+-0.323949 0.734022 -0.323957 0.726314 0 0 0 0.00281905 l
+-0.323949 0.734022 -0.322734 0.736335 0 0 0 0.00281905 l
+0.549905 0.182243 0.551792 0.194629 0 0 0 0.00281905 l
+0.549905 0.182243 0.562442 0.179657 0 0 0 0.00281905 l
+0.549905 0.182243 0.532867 0.184044 0 0 0 0.00281905 l
+0.158877 0.428998 0.139506 0.410658 0 0 0 0.00281905 l
+-0.188611 -0.139473 -0.18837 -0.152295 0 0 0 0.00281905 l
+-0.188611 -0.139473 -0.189503 -0.134121 0 0 0 0.00281905 l
+-0.188611 -0.139473 -0.199549 -0.140703 0 0 0 0.00281905 l
+-0.123398 -0.743846 -0.11117 -0.748369 0 0 0 0.00281905 l
+-0.123398 -0.743846 -0.135173 -0.753246 0 0 0 0.00281905 l
+0.78679 0.034011 0.791044 0.0203049 0 0 0 0.00281905 l
+0.78679 0.034011 0.777687 0.0377925 0 0 0 0.00281905 l
+-0.764051 0.463369 -0.758098 0.479709 0 0 0 0.00281905 l
+-0.764051 0.463369 -0.765885 0.461176 0 0 0 0.00281905 l
+-0.555992 -0.165243 -0.545108 -0.159155 0 0 0 0.00281905 l
+-0.555992 -0.165243 -0.574096 -0.158554 0 0 0 0.00281905 l
+-0.413674 0.0601514 -0.403272 0.061426 0 0 0 0.00281905 l
+0.398177 -0.173902 0.398249 -0.187374 0 0 0 0.00281905 l
+0.398177 -0.173902 0.406158 -0.161392 0 0 0 0.00281905 l
+0.398177 -0.173902 0.389198 -0.169432 0 0 0 0.00281905 l
+-0.169851 0.621446 -0.164363 0.631181 0 0 0 0.00281905 l
+-0.169851 0.621446 -0.162114 0.618215 0 0 0 0.00281905 l
+-0.169851 0.621446 -0.183047 0.626915 0 0 0 0.00281905 l
+-0.565216 -0.466554 -0.564954 -0.45722 0 0 0 0.00281905 l
+-0.565216 -0.466554 -0.578543 -0.467186 0 0 0 0.00281905 l
+0.255207 0.643144 0.252654 0.627491 0 0 0 0.00281905 l
+0.255207 0.643144 0.2433 0.647582 0 0 0 0.00281905 l
+-0.6626 0.155326 -0.663797 0.165933 0 0 0 0.00281905 l
+-0.6626 0.155326 -0.659829 0.136879 0 0 0 0.00281905 l
+-0.197276 0.336981 -0.185899 0.346299 0 0 0 0.00281905 l
+-0.197276 0.336981 -0.210289 0.332863 0 0 0 0.00281905 l
+-0.403822 0.425605 -0.399403 0.42314 0 0 0 0.00281905 l
+-0.403822 0.425605 -0.398796 0.434046 0 0 0 0.00281905 l
+0.567632 -0.443996 0.556863 -0.433521 0 0 0 0.00281905 l
+0.567632 -0.443996 0.580269 -0.443817 0 0 0 0.00281905 l
+0.567632 -0.443996 0.561787 -0.455474 0 0 0 0.00281905 l
+0.762144 -0.0939711 0.760142 -0.0760978 0 0 0 0.00281905 l
+0.762144 -0.0939711 0.759869 -0.0978489 0 0 0 0.00281905 l
+0.0622207 -0.428878 0.0764977 -0.426921 0 0 0 0.00281905 l
+0.0622207 -0.428878 0.0623083 -0.432772 0 0 0 0.00281905 l
+0.689759 0.339326 0.705895 0.347719 0 0 0 0.00281905 l
+0.689759 0.339326 0.671599 0.338901 0 0 0 0.00281905 l
+0.530044 -0.0379473 0.528689 -0.0291657 0 0 0 0.00281905 l
+0.530044 -0.0379473 0.520339 -0.0430718 0 0 0 0.00281905 l
+-0.0120944 -0.305289 -0.00629927 -0.299569 0 0 0 0.00281905 l
+0.348506 0.281343 0.334064 0.297101 0 0 0 0.00281905 l
+0.348506 0.281343 0.332938 0.271198 0 0 0 0.00281905 l
+0.19772 -0.963034 0.211318 -0.959537 0 0 0 0.00281905 l
+0.19772 -0.963034 0.186992 -0.966804 0 0 0 0.00281905 l
+0.417154 0.81735 0.429826 0.813689 0 0 0 0.00281905 l
+0.417154 0.81735 0.39534 0.812216 0 0 0 0.00281905 l
+-0.291014 -0.0788067 -0.300672 -0.0799068 0 0 0 0.00281905 l
+-0.566634 0.014476 -0.566709 0.00698378 0 0 0 0.00281905 l
+-0.566634 0.014476 -0.554372 0.0216403 0 0 0 0.00281905 l
+0.359743 -0.693365 0.365072 -0.675384 0 0 0 0.00281905 l
+0.359743 -0.693365 0.356869 -0.695143 0 0 0 0.00281905 l
+0.416306 -0.179198 0.412434 -0.168448 0 0 0 0.00281905 l
+0.416306 -0.179198 0.43184 -0.176354 0 0 0 0.00281905 l
+0.416306 -0.179198 0.421517 -0.194016 0 0 0 0.00281905 l
+-0.46366 0.54114 -0.474069 0.557784 0 0 0 0.00281905 l
+-0.46366 0.54114 -0.453386 0.535503 0 0 0 0.00281905 l
+-0.827296 0.286213 -0.815115 0.283269 0 0 0 0.00281905 l
+-0.827296 0.286213 -0.828208 0.27308 0 0 0 0.00281905 l
+-0.827296 0.286213 -0.831251 0.288925 0 0 0 0.00281905 l
+-0.517163 0.703015 -0.517202 0.706725 0 0 0 0.00281905 l
+-0.517163 0.703015 -0.516356 0.701618 0 0 0 0.00281905 l
+0.866411 0.479533 0.872233 0.474953 0 0 0 0.00281905 l
+0.866411 0.479533 0.87134 0.484348 0 0 0 0.00281905 l
+0.866411 0.479533 0.850005 0.479454 0 0 0 0.00281905 l
+-0.23543 0.38176 -0.220971 0.389841 0 0 0 0.00281905 l
+-0.23543 0.38176 -0.232792 0.368571 0 0 0 0.00281905 l
+-0.23543 0.38176 -0.237583 0.392216 0 0 0 0.00281905 l
+-0.516356 0.701618 -0.512401 0.694281 0 0 0 0.00281905 l
+-0.516356 0.701618 -0.517163 0.703015 0 0 0 0.00281905 l
+0.792143 -0.131356 0.794321 -0.117049 0 0 0 0.00281905 l
+0.792143 -0.131356 0.794599 -0.138796 0 0 0 0.00281905 l
+0.792143 -0.131356 0.77191 -0.132156 0 0 0 0.00281905 l
+-0.372838 0.885996 -0.364752 0.878425 0 0 0 0.00281905 l
+-0.372838 0.885996 -0.377541 0.887044 0 0 0 0.00281905 l
+-0.622844 0.563884 -0.61753 0.57557 0 0 0 0.00281905 l
+-0.622844 0.563884 -0.609816 0.553596 0 0 0 0.00281905 l
+-0.152207 0.933929 -0.154851 0.944207 0 0 0 0.00281905 l
+-0.152207 0.933929 -0.146857 0.930381 0 0 0 0.00281905 l
+-0.152207 0.933929 -0.166993 0.930697 0 0 0 0.00281905 l
+0.455364 -0.0454441 0.453608 -0.0478701 0 0 0 0.00281905 l
+-0.155523 -0.212985 -0.15774 -0.221402 0 0 0 0.00281905 l
+-0.155523 -0.212985 -0.14996 -0.210912 0 0 0 0.00281905 l
+-0.155523 -0.212985 -0.165193 -0.204005 0 0 0 0.00281905 l
+-0.730535 0.274471 -0.725539 0.271048 0 0 0 0.00281905 l
+-0.730535 0.274471 -0.74049 0.280808 0 0 0 0.00281905 l
+0.810568 0.299089 0.816093 0.300971 0 0 0 0.00281905 l
+0.810568 0.299089 0.801828 0.303314 0 0 0 0.00281905 l
+0.225558 0.307164 0.230098 0.29353 0 0 0 0.00281905 l
+0.225558 0.307164 0.217329 0.309023 0 0 0 0.00281905 l
+-0.506752 -0.169045 -0.507644 -0.162991 0 0 0 0.00281905 l
+-0.506752 -0.169045 -0.497017 -0.165525 0 0 0 0.00281905 l
+-0.483323 -0.381633 -0.466575 -0.368739 0 0 0 0.00281905 l
+-0.483323 -0.381633 -0.496174 -0.378905 0 0 0 0.00281905 l
+0.910381 0.173732 0.912752 0.161937 0 0 0 0.00281905 l
+0.910381 0.173732 0.921749 0.179337 0 0 0 0.00281905 l
+-0.501041 -0.544383 -0.502605 -0.5316 0 0 0 0.00281905 l
+-0.501041 -0.544383 -0.502659 -0.553607 0 0 0 0.00281905 l
+-0.501041 -0.544383 -0.513811 -0.542973 0 0 0 0.00281905 l
+-0.526248 0.228606 -0.51419 0.239071 0 0 0 0.00281905 l
+-0.526248 0.228606 -0.51745 0.218923 0 0 0 0.00281905 l
+0.576883 -0.128858 0.591195 -0.134275 0 0 0 0.00281905 l
+0.576883 -0.128858 0.567856 -0.120091 0 0 0 0.00281905 l
+0.576883 -0.128858 0.569264 -0.137027 0 0 0 0.00281905 l
+0.891289 -0.272927 0.888296 -0.291867 0 0 0 0.00281905 l
+-0.114881 -0.600446 -0.106852 -0.608091 0 0 0 0.00281905 l
+-0.114881 -0.600446 -0.122443 -0.616117 0 0 0 0.00281905 l
+-0.114881 -0.600446 -0.13057 -0.590787 0 0 0 0.00281905 l
+0.620675 -0.254471 0.611308 -0.240162 0 0 0 0.00281905 l
+0.620675 -0.254471 0.610587 -0.260244 0 0 0 0.00281905 l
+-0.193041 0.495938 -0.187547 0.49149 0 0 0 0.00281905 l
+-0.193041 0.495938 -0.203045 0.503336 0 0 0 0.00281905 l
+-0.97999 -0.0934113 -0.97476 -0.109543 0 0 0 0.00281905 l
+-0.97999 -0.0934113 -0.986874 -0.0868779 0 0 0 0.00281905 l
+0.474213 -0.729717 0.471592 -0.743504 0 0 0 0.00281905 l
+0.474213 -0.729717 0.47232 -0.722985 0 0 0 0.00281905 l
+-0.308068 0.190053 -0.302639 0.19958 0 0 0 0.00281905 l
+-0.308068 0.190053 -0.293801 0.179938 0 0 0 0.00281905 l
+-0.308068 0.190053 -0.313413 0.19571 0 0 0 0.00281905 l
+-0.0100627 0.285587 0.00496532 0.274849 0 0 0 0.00281905 l
+-0.0100627 0.285587 0.00447014 0.295747 0 0 0 0.00281905 l
+-0.0100627 0.285587 -0.0139928 0.269383 0 0 0 0.00281905 l
+-0.0100627 0.285587 -0.0265918 0.291939 0 0 0 0.00281905 l
+-0.133958 -0.902922 -0.126333 -0.894108 0 0 0 0.00281905 l
+0.447366 -0.828168 0.461675 -0.83643 0 0 0 0.00281905 l
+0.447366 -0.828168 0.445981 -0.845682 0 0 0 0.00281905 l
+0.447366 -0.828168 0.435802 -0.823099 0 0 0 0.00281905 l
+-0.622426 0.127501 -0.625956 0.114994 0 0 0 0.00281905 l
+-0.622426 0.127501 -0.6218 0.13006 0 0 0 0.00281905 l
+-0.622426 0.127501 -0.632117 0.129658 0 0 0 0.00281905 l
+0.308159 -0.51207 0.306559 -0.504239 0 0 0 0.00281905 l
+0.308159 -0.51207 0.311546 -0.517578 0 0 0 0.00281905 l
+-0.379645 -0.106963 -0.367449 -0.107243 0 0 0 0.00281905 l
+-0.379645 -0.106963 -0.390433 -0.118897 0 0 0 0.00281905 l
+-0.379645 -0.106963 -0.386004 -0.0979852 0 0 0 0.00281905 l
+-0.349499 0.749498 -0.359128 0.735703 0 0 0 0.00281905 l
+-0.349499 0.749498 -0.347134 0.767128 0 0 0 0.00281905 l
+-0.349499 0.749498 -0.337272 0.747757 0 0 0 0.00281905 l
+0.553963 -0.269853 0.552371 -0.278153 0 0 0 0.00281905 l
+0.553963 -0.269853 0.564353 -0.265134 0 0 0 0.00281905 l
+0.553963 -0.269853 0.544738 -0.262364 0 0 0 0.00281905 l
+-0.564954 -0.45722 -0.565216 -0.466554 0 0 0 0.00281905 l
+-0.564954 -0.45722 -0.565435 -0.452104 0 0 0 0.00281905 l
+0.271985 -0.519882 0.271976 -0.510692 0 0 0 0.00281905 l
+0.271985 -0.519882 0.276765 -0.525652 0 0 0 0.00281905 l
+0.271985 -0.519882 0.267108 -0.526615 0 0 0 0.00281905 l
+-0.88192 0.441807 -0.877736 0.441989 0 0 0 0.00281905 l
+-0.88192 0.441807 -0.879973 0.435441 0 0 0 0.00281905 l
+-0.88192 0.441807 -0.888104 0.448102 0 0 0 0.00281905 l
+-0.322734 0.736335 -0.318274 0.73475 0 0 0 0.00281905 l
+-0.322734 0.736335 -0.323949 0.734022 0 0 0 0.00281905 l
+-0.364104 -0.183242 -0.345739 -0.188253 0 0 0 0.00281905 l
+-0.364104 -0.183242 -0.368079 -0.195 0 0 0 0.00281905 l
+-0.60746 -0.383819 -0.610198 -0.39078 0 0 0 0.00281905 l
+-0.60746 -0.383819 -0.622728 -0.378936 0 0 0 0.00281905 l
+-0.405846 0.817623 -0.410559 0.830107 0 0 0 0.00281905 l
+-0.405846 0.817623 -0.420969 0.809556 0 0 0 0.00281905 l
+-0.785914 -0.181396 -0.770776 -0.166589 0 0 0 0.00281905 l
+-0.785914 -0.181396 -0.791309 -0.189634 0 0 0 0.00281905 l
+-0.347333 -0.0661738 -0.341215 -0.0772426 0 0 0 0.00281905 l
+-0.347333 -0.0661738 -0.35865 -0.0668503 0 0 0 0.00281905 l
+-0.0478067 0.599529 -0.0522235 0.585466 0 0 0 0.00281905 l
+-0.0478067 0.599529 -0.0434513 0.604003 0 0 0 0.00281905 l
+0.165821 -0.343266 0.173643 -0.34033 0 0 0 0.00281905 l
+0.71628 0.144743 0.718057 0.132256 0 0 0 0.00281905 l
+0.71628 0.144743 0.730795 0.149465 0 0 0 0.00281905 l
+0.449858 -0.318563 0.450188 -0.314985 0 0 0 0.00281905 l
+0.449858 -0.318563 0.444347 -0.328139 0 0 0 0.00281905 l
+-0.800831 -0.263721 -0.790133 -0.256539 0 0 0 0.00281905 l
+-0.800831 -0.263721 -0.809437 -0.271793 0 0 0 0.00281905 l
+-0.253215 -0.431795 -0.240365 -0.4214 0 0 0 0.00281905 l
+-0.253215 -0.431795 -0.262338 -0.439149 0 0 0 0.00281905 l
+-0.511763 -0.195182 -0.503779 -0.201759 0 0 0 0.00281905 l
+-0.511763 -0.195182 -0.524245 -0.186631 0 0 0 0.00281905 l
+0.375685 0.738945 0.364666 0.737853 0 0 0 0.00281905 l
+-0.548624 -0.536184 -0.539839 -0.532737 0 0 0 0.00281905 l
+-0.548624 -0.536184 -0.556872 -0.537646 0 0 0 0.00281905 l
+0.0336093 -0.632856 0.0360315 -0.622152 0 0 0 0.00281905 l
+0.0336093 -0.632856 0.0410285 -0.638444 0 0 0 0.00281905 l
+0.0336093 -0.632856 0.0156282 -0.634239 0 0 0 0.00281905 l
+-0.391369 -0.736215 -0.376945 -0.745333 0 0 0 0.00281905 l
+-0.391369 -0.736215 -0.396639 -0.724701 0 0 0 0.00281905 l
+-0.226435 0.356471 -0.227962 0.343461 0 0 0 0.00281905 l
+-0.226435 0.356471 -0.224217 0.362874 0 0 0 0.00281905 l
+-0.286515 -0.769556 -0.291435 -0.755148 0 0 0 0.00281905 l
+-0.286515 -0.769556 -0.275825 -0.773407 0 0 0 0.00281905 l
+0.342135 -0.715778 0.350886 -0.72482 0 0 0 0.00281905 l
+0.342135 -0.715778 0.327576 -0.720089 0 0 0 0.00281905 l
+-0.50957 -0.208461 -0.503779 -0.201759 0 0 0 0.00281905 l
+0.421186 -0.860267 0.42352 -0.850881 0 0 0 0.00281905 l
+0.421186 -0.860267 0.411076 -0.864195 0 0 0 0.00281905 l
+-0.90352 -0.304944 -0.895469 -0.300178 0 0 0 0.00281905 l
+-0.90352 -0.304944 -0.91112 -0.305925 0 0 0 0.00281905 l
+0.0822286 -0.806432 0.0857634 -0.793244 0 0 0 0.00281905 l
+0.0822286 -0.806432 0.0843934 -0.818033 0 0 0 0.00281905 l
+-0.607007 0.0294454 -0.584095 0.0362237 0 0 0 0.00281905 l
+-0.735877 -0.440541 -0.72206 -0.455203 0 0 0 0.00281905 l
+-0.735877 -0.440541 -0.734186 -0.427437 0 0 0 0.00281905 l
+-0.735877 -0.440541 -0.75095 -0.438058 0 0 0 0.00281905 l
+-0.107838 0.197453 -0.100373 0.208031 0 0 0 0.00281905 l
+-0.107838 0.197453 -0.121495 0.203791 0 0 0 0.00281905 l
+0.347948 0.105194 0.347842 0.120427 0 0 0 0.00281905 l
+0.347948 0.105194 0.36978 0.104754 0 0 0 0.00281905 l
+0.347948 0.105194 0.342083 0.0928161 0 0 0 0.00281905 l
+-0.661617 0.222625 -0.652231 0.217113 0 0 0 0.00281905 l
+-0.661617 0.222625 -0.663343 0.232292 0 0 0 0.00281905 l
+0.573572 -0.608778 0.57094 -0.597447 0 0 0 0.00281905 l
+0.573572 -0.608778 0.578338 -0.610616 0 0 0 0.00281905 l
+0.573572 -0.608778 0.561593 -0.619813 0 0 0 0.00281905 l
+0.543221 -0.415456 0.549632 -0.415546 0 0 0 0.00281905 l
+-0.647484 -0.148953 -0.651433 -0.148657 0 0 0 0.00281905 l
+-0.247128 0.512753 -0.25405 0.522235 0 0 0 0.00281905 l
+-0.247128 0.512753 -0.232741 0.508809 0 0 0 0.00281905 l
+0.129907 0.452428 0.138038 0.450211 0 0 0 0.00281905 l
+-0.57714 0.131851 -0.567021 0.118317 0 0 0 0.00281905 l
+-0.57714 0.131851 -0.585019 0.144556 0 0 0 0.00281905 l
+-0.442604 -0.661115 -0.437923 -0.651829 0 0 0 0.00281905 l
+-0.442604 -0.661115 -0.448604 -0.658091 0 0 0 0.00281905 l
+-0.762468 -0.528041 -0.760404 -0.522621 0 0 0 0.00281905 l
+-0.395239 0.703694 -0.387076 0.692185 0 0 0 0.00281905 l
+-0.395239 0.703694 -0.397928 0.721963 0 0 0 0.00281905 l
+-0.395239 0.703694 -0.410502 0.704015 0 0 0 0.00281905 l
+-0.385842 -0.0338155 -0.373701 -0.0202088 0 0 0 0.00281905 l
+-0.385842 -0.0338155 -0.399598 -0.0370971 0 0 0 0.00281905 l
+0.38586 -0.271413 0.394768 -0.274789 0 0 0 0.00281905 l
+0.38586 -0.271413 0.379369 -0.282828 0 0 0 0.00281905 l
+-0.570767 0.81405 -0.573225 0.798797 0 0 0 0.00281905 l
+-0.0476284 0.025398 -0.0412447 0.026252 0 0 0 0.00281905 l
+-0.0476284 0.025398 -0.0464503 0.0216653 0 0 0 0.00281905 l
+-0.0476284 0.025398 -0.0513189 0.0285547 0 0 0 0.00281905 l
+0.15062 -0.50557 0.151264 -0.512561 0 0 0 0.00281905 l
+0.15062 -0.50557 0.154635 -0.502535 0 0 0 0.00281905 l
+0.635447 -0.0942709 0.629366 -0.0795694 0 0 0 0.00281905 l
+0.635447 -0.0942709 0.626363 -0.106223 0 0 0 0.00281905 l
+0.261544 -0.505196 0.265166 -0.488598 0 0 0 0.00281905 l
+0.261544 -0.505196 0.271976 -0.510692 0 0 0 0.00281905 l
+0.372812 0.159692 0.376163 0.159085 0 0 0 0.00281905 l
+0.372812 0.159692 0.361284 0.159923 0 0 0 0.00281905 l
+0.314846 0.30972 0.312524 0.308382 0 0 0 0.00281905 l
+0.924533 0.355242 0.938311 0.342929 0 0 0 0.00281905 l
+0.924533 0.355242 0.914124 0.356067 0 0 0 0.00281905 l
+-0.225564 0.0998431 -0.209435 0.097832 0 0 0 0.00281905 l
+-0.225564 0.0998431 -0.229932 0.0824348 0 0 0 0.00281905 l
+0.629643 -0.439224 0.617287 -0.424168 0 0 0 0.00281905 l
+0.629643 -0.439224 0.633062 -0.439298 0 0 0 0.00281905 l
+0.629643 -0.439224 0.626054 -0.443826 0 0 0 0.00281905 l
+0.391998 -0.382187 0.390928 -0.3771 0 0 0 0.00281905 l
+-0.641166 0.414921 -0.638889 0.420557 0 0 0 0.00281905 l
+-0.641166 0.414921 -0.62818 0.410708 0 0 0 0.00281905 l
+-0.641166 0.414921 -0.645632 0.409667 0 0 0 0.00281905 l
+0.0101976 0.00126571 -0.000892871 -0.014212 0 0 0 0.00281905 l
+0.0101976 0.00126571 0.00188986 0.00745381 0 0 0 0.00281905 l
+0.144012 -0.892973 0.154088 -0.904832 0 0 0 0.00281905 l
+0.144012 -0.892973 0.152227 -0.886286 0 0 0 0.00281905 l
+0.144012 -0.892973 0.130862 -0.896819 0 0 0 0.00281905 l
+-0.417586 -0.607838 -0.416013 -0.608472 0 0 0 0.00281905 l
+-0.417586 -0.607838 -0.419004 -0.611027 0 0 0 0.00281905 l
+0.225041 -0.504888 0.242724 -0.516675 0 0 0 0.00281905 l
+0.225041 -0.504888 0.219533 -0.49787 0 0 0 0.00281905 l
+-0.726458 -0.00793686 -0.70582 -0.0128947 0 0 0 0.00281905 l
+-0.726458 -0.00793686 -0.735438 -0.0249705 0 0 0 0.00281905 l
+-0.726458 -0.00793686 -0.737182 0.00253006 0 0 0 0.00281905 l
+0.789085 -0.408865 0.798288 -0.40179 0 0 0 0.00281905 l
+0.789085 -0.408865 0.788867 -0.410458 0 0 0 0.00281905 l
+0.533701 0.153689 0.533824 0.134311 0 0 0 0.00281905 l
+0.533701 0.153689 0.529071 0.161353 0 0 0 0.00281905 l
+-0.513452 0.56729 -0.507202 0.576196 0 0 0 0.00281905 l
+-0.513452 0.56729 -0.518386 0.557415 0 0 0 0.00281905 l
+0.398457 0.717968 0.400955 0.703883 0 0 0 0.00281905 l
+0.398457 0.717968 0.396662 0.721446 0 0 0 0.00281905 l
+0.282991 0.62965 0.284461 0.630031 0 0 0 0.00281905 l
+0.282991 0.62965 0.269886 0.631533 0 0 0 0.00281905 l
+0.660314 0.0308069 0.670279 0.0303594 0 0 0 0.00281905 l
+-0.741061 -0.466023 -0.737724 -0.46699 0 0 0 0.00281905 l
+-0.741061 -0.466023 -0.746483 -0.466165 0 0 0 0.00281905 l
+0.920365 0.203823 0.929042 0.186443 0 0 0 0.00281905 l
+0.920365 0.203823 0.912829 0.215637 0 0 0 0.00281905 l
+0.110461 0.0574462 0.116452 0.0746246 0 0 0 0.00281905 l
+0.110461 0.0574462 0.119349 0.0468448 0 0 0 0.00281905 l
+0.110461 0.0574462 0.0998299 0.0455969 0 0 0 0.00281905 l
+0.439739 0.463384 0.445316 0.444545 0 0 0 0.00281905 l
+0.439739 0.463384 0.440497 0.468303 0 0 0 0.00281905 l
+0.0959863 -0.64181 0.101717 -0.636056 0 0 0 0.00281905 l
+0.0959863 -0.64181 0.0822732 -0.631216 0 0 0 0.00281905 l
+0.0959863 -0.64181 0.0823531 -0.650882 0 0 0 0.00281905 l
+0.154088 -0.904832 0.173396 -0.911077 0 0 0 0.00281905 l
+0.154088 -0.904832 0.148441 -0.918568 0 0 0 0.00281905 l
+0.154088 -0.904832 0.144012 -0.892973 0 0 0 0.00281905 l
+0.303971 0.85099 0.306646 0.83607 0 0 0 0.00281905 l
+0.303971 0.85099 0.31349 0.852219 0 0 0 0.00281905 l
+0.775387 0.380766 0.773545 0.396092 0 0 0 0.00281905 l
+0.775387 0.380766 0.777985 0.380957 0 0 0 0.00281905 l
+0.775387 0.380766 0.761549 0.37395 0 0 0 0.00281905 l
+0.437396 0.725405 0.43393 0.734046 0 0 0 0.00281905 l
+-0.65375 0.588001 -0.644626 0.594498 0 0 0 0.00281905 l
+-0.395402 0.29444 -0.401378 0.285835 0 0 0 0.00281905 l
+-0.395402 0.29444 -0.390298 0.303187 0 0 0 0.00281905 l
+0.39271 0.319559 0.392651 0.325948 0 0 0 0.00281905 l
+0.39271 0.319559 0.394003 0.309589 0 0 0 0.00281905 l
+-0.0518368 -0.312598 -0.0386577 -0.29579 0 0 0 0.00281905 l
+-0.0518368 -0.312598 -0.0671279 -0.296162 0 0 0 0.00281905 l
+0.20298 -0.694144 0.216334 -0.703435 0 0 0 0.00281905 l
+0.20298 -0.694144 0.196638 -0.693142 0 0 0 0.00281905 l
+-0.137454 0.291331 -0.136952 0.277406 0 0 0 0.00281905 l
+-0.137454 0.291331 -0.138929 0.302653 0 0 0 0.00281905 l
+-0.361898 0.719564 -0.359128 0.735703 0 0 0 0.00281905 l
+-0.361898 0.719564 -0.366247 0.717835 0 0 0 0.00281905 l
+0.176135 -0.536537 0.183501 -0.525921 0 0 0 0.00281905 l
+0.176135 -0.536537 0.169108 -0.524408 0 0 0 0.00281905 l
+0.176135 -0.536537 0.163507 -0.544853 0 0 0 0.00281905 l
+0.921923 0.151857 0.912752 0.161937 0 0 0 0.00281905 l
+0.921923 0.151857 0.936224 0.149538 0 0 0 0.00281905 l
+0.921923 0.151857 0.926581 0.138677 0 0 0 0.00281905 l
+0.921923 0.151857 0.909537 0.147106 0 0 0 0.00281905 l
+0.151267 -0.812703 0.162478 -0.81296 0 0 0 0.00281905 l
+0.151267 -0.812703 0.148354 -0.809648 0 0 0 0.00281905 l
+0.11021 -0.0159084 0.121565 -0.02562 0 0 0 0.00281905 l
+0.792462 0.584123 0.792984 0.604744 0 0 0 0.00281905 l
+0.792462 0.584123 0.798373 0.578077 0 0 0 0.00281905 l
+-0.611812 -0.201149 -0.609774 -0.20354 0 0 0 0.00281905 l
+-0.611812 -0.201149 -0.621653 -0.194644 0 0 0 0.00281905 l
+-0.021102 0.720428 -0.016909 0.725782 0 0 0 0.00281905 l
+-0.390932 0.539945 -0.378824 0.553336 0 0 0 0.00281905 l
+-0.390932 0.539945 -0.386923 0.531928 0 0 0 0.00281905 l
+-0.653991 -0.177995 -0.640268 -0.184745 0 0 0 0.00281905 l
+-0.653991 -0.177995 -0.665286 -0.173693 0 0 0 0.00281905 l
+-0.199499 -0.715209 -0.191776 -0.708298 0 0 0 0.00281905 l
+-0.199499 -0.715209 -0.197738 -0.723959 0 0 0 0.00281905 l
+0.838072 0.510561 0.83604 0.517486 0 0 0 0.00281905 l
+0.838072 0.510561 0.84399 0.482954 0 0 0 0.00281905 l
+0.838072 0.510561 0.828253 0.510489 0 0 0 0.00281905 l
+0.293032 -0.216586 0.28853 -0.218506 0 0 0 0.00281905 l
+-0.787024 0.452823 -0.783088 0.451357 0 0 0 0.00281905 l
+-0.787024 0.452823 -0.800721 0.451438 0 0 0 0.00281905 l
+0.428281 -0.207101 0.42633 -0.198818 0 0 0 0.00281905 l
+0.428281 -0.207101 0.435246 -0.206102 0 0 0 0.00281905 l
+0.14366 0.0537663 0.141457 0.0703728 0 0 0 0.00281905 l
+0.14366 0.0537663 0.159007 0.0549418 0 0 0 0.00281905 l
+0.300656 -0.424381 0.312849 -0.437373 0 0 0 0.00281905 l
+0.300656 -0.424381 0.299383 -0.413198 0 0 0 0.00281905 l
+0.300656 -0.424381 0.293966 -0.432183 0 0 0 0.00281905 l
+-0.431504 0.635732 -0.428635 0.621301 0 0 0 0.00281905 l
+-0.431504 0.635732 -0.437967 0.638082 0 0 0 0.00281905 l
+0.744644 0.262738 0.74326 0.256704 0 0 0 0.00281905 l
+0.744644 0.262738 0.74456 0.266009 0 0 0 0.00281905 l
+0.744644 0.262738 0.767002 0.262985 0 0 0 0.00281905 l
+0.189964 0.674076 0.200663 0.675451 0 0 0 0.00281905 l
+0.189964 0.674076 0.180538 0.677491 0 0 0 0.00281905 l
+-0.690279 0.194272 -0.70419 0.188485 0 0 0 0.00281905 l
+0.180554 -0.25523 0.180685 -0.248905 0 0 0 0.00281905 l
+0.180554 -0.25523 0.180118 -0.256613 0 0 0 0.00281905 l
+0.780563 -0.0384472 0.793747 -0.0424008 0 0 0 0.00281905 l
+0.780563 -0.0384472 0.767676 -0.0484075 0 0 0 0.00281905 l
+0.780563 -0.0384472 0.785901 -0.027345 0 0 0 0.00281905 l
+-0.263293 0.581746 -0.246187 0.576756 0 0 0 0.00281905 l
+-0.263293 0.581746 -0.264443 0.583477 0 0 0 0.00281905 l
+0.479696 0.319038 0.48796 0.33334 0 0 0 0.00281905 l
+0.479696 0.319038 0.484448 0.306933 0 0 0 0.00281905 l
+0.479696 0.319038 0.469671 0.308796 0 0 0 0.00281905 l
+0.202507 0.449223 0.213234 0.451835 0 0 0 0.00281905 l
+0.202507 0.449223 0.194361 0.451397 0 0 0 0.00281905 l
+0.622522 0.657171 0.617897 0.666362 0 0 0 0.00281905 l
+0.680828 -0.725162 0.66805 -0.728082 0 0 0 0.00281905 l
+0.134511 -0.262417 0.13811 -0.24488 0 0 0 0.00281905 l
+0.134511 -0.262417 0.143206 -0.264068 0 0 0 0.00281905 l
+-0.502605 -0.5316 -0.501041 -0.544383 0 0 0 0.00281905 l
+0.947818 0.125689 0.959309 0.144072 0 0 0 0.00281905 l
+0.947818 0.125689 0.953854 0.122269 0 0 0 0.00281905 l
+0.947818 0.125689 0.928129 0.124578 0 0 0 0.00281905 l
+0.395912 -0.0766517 0.405423 -0.0637036 0 0 0 0.00281905 l
+0.395912 -0.0766517 0.400551 -0.0810123 0 0 0 0.00281905 l
+0.395912 -0.0766517 0.385674 -0.0693716 0 0 0 0.00281905 l
+-0.142004 0.749257 -0.147292 0.746347 0 0 0 0.00281905 l
+-0.144684 0.640067 -0.139998 0.647854 0 0 0 0.00281905 l
+-0.144684 0.640067 -0.13137 0.635852 0 0 0 0.00281905 l
+-0.144684 0.640067 -0.145288 0.624826 0 0 0 0.00281905 l
+-0.548204 0.290605 -0.553575 0.296911 0 0 0 0.00281905 l
+-0.548204 0.290605 -0.544439 0.287166 0 0 0 0.00281905 l
+-0.548204 0.290605 -0.555616 0.286031 0 0 0 0.00281905 l
+-0.640238 0.261852 -0.640677 0.269013 0 0 0 0.00281905 l
+-0.640238 0.261852 -0.628212 0.25628 0 0 0 0.00281905 l
+-0.640238 0.261852 -0.64814 0.264719 0 0 0 0.00281905 l
+0.422661 0.106506 0.429505 0.128192 0 0 0 0.00281905 l
+0.422661 0.106506 0.411634 0.108271 0 0 0 0.00281905 l
+0.0532444 -0.431365 0.0545617 -0.436461 0 0 0 0.00281905 l
+0.0532444 -0.431365 0.0482858 -0.431582 0 0 0 0.00281905 l
+0.251334 0.73339 0.251448 0.737802 0 0 0 0.00281905 l
+0.251334 0.73339 0.26467 0.719879 0 0 0 0.00281905 l
+0.251334 0.73339 0.243925 0.728833 0 0 0 0.00281905 l
+-0.433659 0.435334 -0.43382 0.433634 0 0 0 0.00281905 l
+-0.56413 -0.432009 -0.555229 -0.442267 0 0 0 0.00281905 l
+-0.56413 -0.432009 -0.579178 -0.428842 0 0 0 0.00281905 l
+-0.441045 0.43497 -0.439242 0.433102 0 0 0 0.00281905 l
+-0.441045 0.43497 -0.45535 0.436524 0 0 0 0.00281905 l
+0.591329 0.0470849 0.590183 0.0540321 0 0 0 0.00281905 l
+0.591329 0.0470849 0.601055 0.050532 0 0 0 0.00281905 l
+0.591329 0.0470849 0.578227 0.0426273 0 0 0 0.00281905 l
+0.887345 0.218156 0.891256 0.232533 0 0 0 0.00281905 l
+0.305174 0.913624 0.298403 0.900142 0 0 0 0.00281905 l
+0.305174 0.913624 0.315353 0.919222 0 0 0 0.00281905 l
+0.305174 0.913624 0.296814 0.91948 0 0 0 0.00281905 l
+-0.0116695 -0.812113 0.000446392 -0.817143 0 0 0 0.00281905 l
+-0.0116695 -0.812113 -0.0269046 -0.818167 0 0 0 0.00281905 l
+-0.159027 -0.41948 -0.155451 -0.427624 0 0 0 0.00281905 l
+-0.159027 -0.41948 -0.148247 -0.406799 0 0 0 0.00281905 l
+-0.159027 -0.41948 -0.172982 -0.418446 0 0 0 0.00281905 l
+-0.63308 -0.624807 -0.639332 -0.637713 0 0 0 0.00281905 l
+-0.63308 -0.624807 -0.634014 -0.620446 0 0 0 0.00281905 l
+0.667598 -0.692674 0.668019 -0.688442 0 0 0 0.00281905 l
+0.667598 -0.692674 0.640003 -0.707862 0 0 0 0.00281905 l
+0.0573474 0.441591 0.068162 0.432919 0 0 0 0.00281905 l
+0.0573474 0.441591 0.0437595 0.436363 0 0 0 0.00281905 l
+0.439982 -0.172934 0.443847 -0.167558 0 0 0 0.00281905 l
+0.439982 -0.172934 0.43184 -0.176354 0 0 0 0.00281905 l
+0.267108 -0.526615 0.271985 -0.519882 0 0 0 0.00281905 l
+-0.929504 -0.364608 -0.915991 -0.36293 0 0 0 0.00281905 l
+0.769006 -0.175617 0.775272 -0.174678 0 0 0 0.00281905 l
+0.769006 -0.175617 0.761289 -0.18525 0 0 0 0.00281905 l
+-0.0949189 0.845798 -0.106124 0.85749 0 0 0 0.00281905 l
+-0.0949189 0.845798 -0.0857198 0.844553 0 0 0 0.00281905 l
+-0.170648 0.606351 -0.156945 0.61109 0 0 0 0.00281905 l
+-0.143157 -0.0504802 -0.147642 -0.0374651 0 0 0 0.00281905 l
+-0.143157 -0.0504802 -0.132357 -0.0571776 0 0 0 0.00281905 l
+-0.143157 -0.0504802 -0.16075 -0.0598025 0 0 0 0.00281905 l
+0.13531 0.167385 0.140122 0.155097 0 0 0 0.00281905 l
+0.13531 0.167385 0.132745 0.173064 0 0 0 0.00281905 l
+0.771202 -0.354058 0.784177 -0.353295 0 0 0 0.00281905 l
+0.771202 -0.354058 0.766176 -0.340296 0 0 0 0.00281905 l
+-0.833396 0.29143 -0.842705 0.306046 0 0 0 0.00281905 l
+-0.833396 0.29143 -0.831251 0.288925 0 0 0 0.00281905 l
+-0.833396 0.29143 -0.844515 0.28625 0 0 0 0.00281905 l
+0.132418 0.268952 0.136388 0.260537 0 0 0 0.00281905 l
+0.132418 0.268952 0.135032 0.279408 0 0 0 0.00281905 l
+0.132418 0.268952 0.121425 0.264699 0 0 0 0.00281905 l
+-0.222725 0.190309 -0.207109 0.195611 0 0 0 0.00281905 l
+-0.222725 0.190309 -0.229485 0.192712 0 0 0 0.00281905 l
+-0.877736 0.441989 -0.88192 0.441807 0 0 0 0.00281905 l
+-0.303071 -0.525554 -0.291506 -0.526159 0 0 0 0.00281905 l
+-0.303071 -0.525554 -0.323072 -0.520565 0 0 0 0.00281905 l
+0.445316 0.444545 0.439739 0.463384 0 0 0 0.00281905 l
+0.445316 0.444545 0.438586 0.431477 0 0 0 0.00281905 l
+-0.326575 0.845414 -0.314212 0.835639 0 0 0 0.00281905 l
+-0.326575 0.845414 -0.341747 0.842408 0 0 0 0.00281905 l
+0.850741 -0.057681 0.844208 -0.0674382 0 0 0 0.00281905 l
+0.850741 -0.057681 0.853869 -0.0499024 0 0 0 0.00281905 l
+0.850741 -0.057681 0.843417 -0.0527606 0 0 0 0.00281905 l
+-0.402087 -0.013 -0.389306 0.00564745 0 0 0 0.00281905 l
+-0.402087 -0.013 -0.403883 -0.0247595 0 0 0 0.00281905 l
+-0.402087 -0.013 -0.408294 -0.0114624 0 0 0 0.00281905 l
+0.146918 0.80329 0.147297 0.806542 0 0 0 0.00281905 l
+-0.14505 -0.329224 -0.137858 -0.336549 0 0 0 0.00281905 l
+-0.14505 -0.329224 -0.158437 -0.342701 0 0 0 0.00281905 l
+-0.14505 -0.329224 -0.141783 -0.323027 0 0 0 0.00281905 l
+-0.246187 0.576756 -0.248465 0.569556 0 0 0 0.00281905 l
+-0.246187 0.576756 -0.263293 0.581746 0 0 0 0.00281905 l
+-0.748832 0.519166 -0.745795 0.53071 0 0 0 0.00281905 l
+-0.748832 0.519166 -0.754446 0.516698 0 0 0 0.00281905 l
+-0.380502 -0.520625 -0.388951 -0.509615 0 0 0 0.00281905 l
+-0.380502 -0.520625 -0.373027 -0.528885 0 0 0 0.00281905 l
+-0.380502 -0.520625 -0.388473 -0.530037 0 0 0 0.00281905 l
+0.592054 -0.697949 0.607404 -0.69953 0 0 0 0.00281905 l
+0.592054 -0.697949 0.573535 -0.692124 0 0 0 0.00281905 l
+-0.64247 -0.456003 -0.645478 -0.444765 0 0 0 0.00281905 l
+-0.64247 -0.456003 -0.635237 -0.457554 0 0 0 0.00281905 l
+-0.64247 -0.456003 -0.654178 -0.468224 0 0 0 0.00281905 l
+0.180877 -0.371896 0.194284 -0.359864 0 0 0 0.00281905 l
+0.180877 -0.371896 0.171205 -0.381199 0 0 0 0.00281905 l
+0.284203 -0.230681 0.28853 -0.218506 0 0 0 0.00281905 l
+0.284203 -0.230681 0.270602 -0.239736 0 0 0 0.00281905 l
+-0.888712 -0.239626 -0.882339 -0.243127 0 0 0 0.00281905 l
+-0.888712 -0.239626 -0.892247 -0.250573 0 0 0 0.00281905 l
+-0.888712 -0.239626 -0.90338 -0.236517 0 0 0 0.00281905 l
+-0.88469 0.273331 -0.87751 0.276645 0 0 0 0.00281905 l
+-0.88469 0.273331 -0.892681 0.266595 0 0 0 0.00281905 l
+0.464252 -0.722301 0.47232 -0.722985 0 0 0 0.00281905 l
+0.464252 -0.722301 0.460335 -0.724432 0 0 0 0.00281905 l
+0.257553 -0.314425 0.260778 -0.308209 0 0 0 0.00281905 l
+-0.054258 0.628488 -0.0507641 0.619913 0 0 0 0.00281905 l
+-0.054258 0.628488 -0.0560596 0.635978 0 0 0 0.00281905 l
+0.194479 0.220464 0.19198 0.232645 0 0 0 0.00281905 l
+0.194479 0.220464 0.189318 0.217251 0 0 0 0.00281905 l
+-0.573191 0.3415 -0.57715 0.350369 0 0 0 0.00281905 l
+-0.573191 0.3415 -0.56698 0.343785 0 0 0 0.00281905 l
+0.321619 0.380611 0.320829 0.3979 0 0 0 0.00281905 l
+0.321619 0.380611 0.340173 0.377022 0 0 0 0.00281905 l
+0.825793 -0.277021 0.822822 -0.295258 0 0 0 0.00281905 l
+0.825793 -0.277021 0.84093 -0.273735 0 0 0 0.00281905 l
+0.267907 0.819675 0.274304 0.80929 0 0 0 0.00281905 l
+0.267907 0.819675 0.267705 0.828594 0 0 0 0.00281905 l
+0.267907 0.819675 0.256176 0.817641 0 0 0 0.00281905 l
+0.240344 -0.616847 0.244712 -0.624722 0 0 0 0.00281905 l
+0.240344 -0.616847 0.245718 -0.612089 0 0 0 0.00281905 l
+0.607281 -0.556219 0.619921 -0.544049 0 0 0 0.00281905 l
+0.607281 -0.556219 0.620859 -0.566757 0 0 0 0.00281905 l
+-0.168049 0.341518 -0.162658 0.339415 0 0 0 0.00281905 l
+-0.168049 0.341518 -0.172942 0.329416 0 0 0 0.00281905 l
+-0.168049 0.341518 -0.185899 0.346299 0 0 0 0.00281905 l
+0.0312733 0.653379 0.040934 0.653378 0 0 0 0.00281905 l
+0.0312733 0.653379 0.0190522 0.65544 0 0 0 0.00281905 l
+-0.594611 -0.102896 -0.603287 -0.0859752 0 0 0 0.00281905 l
+0.0229649 0.0996016 0.0175271 0.111767 0 0 0 0.00281905 l
+0.0229649 0.0996016 0.0188282 0.094882 0 0 0 0.00281905 l
+0.561593 -0.619813 0.547688 -0.603287 0 0 0 0.00281905 l
+0.561593 -0.619813 0.573572 -0.608778 0 0 0 0.00281905 l
+-0.836998 0.385329 -0.835773 0.398373 0 0 0 0.00281905 l
+-0.836998 0.385329 -0.835102 0.378157 0 0 0 0.00281905 l
+-0.836998 0.385329 -0.850108 0.391883 0 0 0 0.00281905 l
+-0.524966 0.0105456 -0.515388 -0.00173529 0 0 0 0.00281905 l
+-0.524966 0.0105456 -0.536708 0.00752927 0 0 0 0.00281905 l
+-0.750203 -0.104803 -0.76153 -0.114924 0 0 0 0.00281905 l
+-0.750203 -0.104803 -0.757594 -0.0995753 0 0 0 0.00281905 l
+-0.367179 0.240954 -0.373852 0.248632 0 0 0 0.00281905 l
+-0.730757 0.493131 -0.73646 0.496138 0 0 0 0.00281905 l
+-0.730757 0.493131 -0.731957 0.490751 0 0 0 0.00281905 l
+-0.59739 -0.794854 -0.621846 -0.781936 0 0 0 0.00281905 l
+-0.59739 -0.794854 -0.595482 -0.794517 0 0 0 0.00281905 l
+-0.617601 -0.0288869 -0.606491 -0.0428925 0 0 0 0.00281905 l
+-0.617601 -0.0288869 -0.626239 -0.0329287 0 0 0 0.00281905 l
+-0.332053 -0.395948 -0.329312 -0.411843 0 0 0 0.00281905 l
+-0.332053 -0.395948 -0.324124 -0.39336 0 0 0 0.00281905 l
+-0.256455 0.651864 -0.249336 0.654303 0 0 0 0.00281905 l
+-0.256455 0.651864 -0.24767 0.635012 0 0 0 0.00281905 l
+-0.256455 0.651864 -0.262465 0.647171 0 0 0 0.00281905 l
+0.59977 0.14065 0.601043 0.162637 0 0 0 0.00281905 l
+0.525164 -0.738775 0.511061 -0.724836 0 0 0 0.00281905 l
+0.525164 -0.738775 0.518565 -0.748736 0 0 0 0.00281905 l
+0.247604 0.236462 0.256068 0.245263 0 0 0 0.00281905 l
+-0.288595 0.00379277 -0.284027 -0.00818105 0 0 0 0.00281905 l
+-0.288595 0.00379277 -0.280749 0.00932734 0 0 0 0.00281905 l
+0.89326 -0.0987694 0.897754 -0.0982184 0 0 0 0.00281905 l
+0.89326 -0.0987694 0.886794 -0.0987549 0 0 0 0.00281905 l
+0.345161 -0.0875764 0.344232 -0.0756216 0 0 0 0.00281905 l
+0.345161 -0.0875764 0.355767 -0.0920342 0 0 0 0.00281905 l
+-0.769377 -0.320386 -0.768322 -0.304354 0 0 0 0.00281905 l
+-0.769377 -0.320386 -0.759482 -0.324597 0 0 0 0.00281905 l
+-0.769377 -0.320386 -0.774956 -0.328259 0 0 0 0.00281905 l
+0.148935 0.908336 0.146646 0.923977 0 0 0 0.00281905 l
+0.148935 0.908336 0.141393 0.905413 0 0 0 0.00281905 l
+0.329257 -0.248052 0.33027 -0.253005 0 0 0 0.00281905 l
+-0.19765 0.00752604 -0.213146 0.0214237 0 0 0 0.00281905 l
+-0.19765 0.00752604 -0.195541 0.00593465 0 0 0 0.00281905 l
+0.302004 -0.688305 0.304481 -0.677698 0 0 0 0.00281905 l
+0.302004 -0.688305 0.306692 -0.689056 0 0 0 0.00281905 l
+0.302004 -0.688305 0.291984 -0.688813 0 0 0 0.00281905 l
+-0.57715 0.350369 -0.568411 0.367228 0 0 0 0.00281905 l
+-0.57715 0.350369 -0.573191 0.3415 0 0 0 0.00281905 l
+-0.57715 0.350369 -0.586558 0.351725 0 0 0 0.00281905 l
+9.33519e-05 0.476591 0.0164049 0.480938 0 0 0 0.00281905 l
+9.33519e-05 0.476591 -0.0100515 0.488499 0 0 0 0.00281905 l
+-0.192245 0.853843 -0.185429 0.871619 0 0 0 0.00281905 l
+-0.192245 0.853843 -0.179799 0.83765 0 0 0 0.00281905 l
+-0.192245 0.853843 -0.210598 0.860998 0 0 0 0.00281905 l
+0.11638 0.192806 0.123596 0.198058 0 0 0 0.00281905 l
+0.11638 0.192806 0.100671 0.191628 0 0 0 0.00281905 l
+-0.814567 0.328272 -0.801703 0.33383 0 0 0 0.00281905 l
+-0.814567 0.328272 -0.818165 0.323579 0 0 0 0.00281905 l
+-0.00629927 -0.299569 -2.15015e-05 -0.296169 0 0 0 0.00281905 l
+-0.00629927 -0.299569 -0.0120944 -0.305289 0 0 0 0.00281905 l
+-0.275444 0.806504 -0.266857 0.793932 0 0 0 0.00281905 l
+-0.527257 0.180312 -0.523493 0.188651 0 0 0 0.00281905 l
+-0.527257 0.180312 -0.527181 0.176973 0 0 0 0.00281905 l
+-0.527257 0.180312 -0.536502 0.189372 0 0 0 0.00281905 l
+0.113495 -0.78913 0.109971 -0.777669 0 0 0 0.00281905 l
+0.113495 -0.78913 0.107904 -0.797495 0 0 0 0.00281905 l
+-0.315436 0.689429 -0.314897 0.705869 0 0 0 0.00281905 l
+-0.315436 0.689429 -0.30287 0.682252 0 0 0 0.00281905 l
+0.487383 0.845846 0.476705 0.826157 0 0 0 0.00281905 l
+0.487383 0.845846 0.493243 0.849443 0 0 0 0.00281905 l
+0.769971 0.296022 0.771217 0.32057 0 0 0 0.00281905 l
+0.769971 0.296022 0.771345 0.28501 0 0 0 0.00281905 l
+-0.156711 -0.963087 -0.155791 -0.981737 0 0 0 0.00281905 l
+-0.156711 -0.963087 -0.139973 -0.947226 0 0 0 0.00281905 l
+-0.568555 0.775531 -0.56261 0.757775 0 0 0 0.00281905 l
+-0.568555 0.775531 -0.573977 0.787683 0 0 0 0.00281905 l
+-0.568555 0.775531 -0.578429 0.768119 0 0 0 0.00281905 l
+-0.83843 -0.541714 -0.837275 -0.524432 0 0 0 0.00281905 l
+-0.83843 -0.541714 -0.829424 -0.542861 0 0 0 0.00281905 l
+0.325077 0.601217 0.336218 0.585053 0 0 0 0.00281905 l
+0.325077 0.601217 0.33267 0.610885 0 0 0 0.00281905 l
+0.737428 -0.502341 0.741401 -0.484237 0 0 0 0.00281905 l
+0.737428 -0.502341 0.748399 -0.50406 0 0 0 0.00281905 l
+0.145425 0.31892 0.137217 0.33264 0 0 0 0.00281905 l
+0.145425 0.31892 0.1483 0.316145 0 0 0 0.00281905 l
+0.733725 -0.332131 0.745256 -0.317816 0 0 0 0.00281905 l
+0.733725 -0.332131 0.747678 -0.338191 0 0 0 0.00281905 l
+0.733725 -0.332131 0.724323 -0.338883 0 0 0 0.00281905 l
+0.754044 0.390038 0.748759 0.385939 0 0 0 0.00281905 l
+-0.527698 0.703046 -0.527454 0.70739 0 0 0 0.00281905 l
+-0.527698 0.703046 -0.525165 0.698012 0 0 0 0.00281905 l
+-0.527698 0.703046 -0.542089 0.696216 0 0 0 0.00281905 l
+0.719565 0.656266 0.729399 0.656438 0 0 0 0.00281905 l
+0.719565 0.656266 0.711514 0.656938 0 0 0 0.00281905 l
+-0.358805 -0.104151 -0.353776 -0.0977946 0 0 0 0.00281905 l
+-0.358805 -0.104151 -0.35662 -0.118325 0 0 0 0.00281905 l
+-0.358805 -0.104151 -0.367449 -0.107243 0 0 0 0.00281905 l
+-0.972324 -0.177059 -0.965522 -0.19963 0 0 0 0.00281905 l
+-0.972324 -0.177059 -0.976962 -0.172154 0 0 0 0.00281905 l
+0.680853 -0.076788 0.68176 -0.0664626 0 0 0 0.00281905 l
+0.680853 -0.076788 0.68313 -0.0896031 0 0 0 0.00281905 l
+0.680853 -0.076788 0.667703 -0.0710971 0 0 0 0.00281905 l
+-0.240365 -0.4214 -0.226244 -0.410431 0 0 0 0.00281905 l
+-0.240365 -0.4214 -0.237351 -0.42636 0 0 0 0.00281905 l
+-0.240365 -0.4214 -0.253215 -0.431795 0 0 0 0.00281905 l
+-0.240365 -0.4214 -0.254482 -0.414234 0 0 0 0.00281905 l
+-0.172039 0.149231 -0.172089 0.15437 0 0 0 0.00281905 l
+-0.172039 0.149231 -0.166782 0.141561 0 0 0 0.00281905 l
+0.798795 -0.0878288 0.801899 -0.0759943 0 0 0 0.00281905 l
+0.798795 -0.0878288 0.789875 -0.0873253 0 0 0 0.00281905 l
+-0.129088 0.00746886 -0.121469 0.0228443 0 0 0 0.00281905 l
+-0.129088 0.00746886 -0.118116 0.00390034 0 0 0 0.00281905 l
+-0.129088 0.00746886 -0.13404 0.00993114 0 0 0 0.00281905 l
+-0.0305158 0.912857 -0.0128192 0.899165 0 0 0 0.00281905 l
+-0.00413429 -0.777294 0.0082151 -0.780968 0 0 0 0.00281905 l
+-0.00413429 -0.777294 -0.00993121 -0.773886 0 0 0 0.00281905 l
+-0.728682 0.328992 -0.723371 0.331338 0 0 0 0.00281905 l
+-0.728682 0.328992 -0.733246 0.323356 0 0 0 0.00281905 l
+-0.239081 -0.0619393 -0.239186 -0.068198 0 0 0 0.00281905 l
+-0.239081 -0.0619393 -0.230517 -0.0565945 0 0 0 0.00281905 l
+-0.293744 0.534802 -0.287031 0.53537 0 0 0 0.00281905 l
+-0.293744 0.534802 -0.307494 0.532003 0 0 0 0.00281905 l
+0.546888 0.753905 0.554963 0.741949 0 0 0 0.00281905 l
+0.546888 0.753905 0.533496 0.760751 0 0 0 0.00281905 l
+-0.318625 0.0423322 -0.320944 0.0404954 0 0 0 0.00281905 l
+-0.517202 0.706725 -0.517163 0.703015 0 0 0 0.00281905 l
+-0.517202 0.706725 -0.525497 0.710533 0 0 0 0.00281905 l
+-0.391825 -0.76384 -0.391777 -0.781627 0 0 0 0.00281905 l
+-0.391825 -0.76384 -0.385401 -0.761311 0 0 0 0.00281905 l
+0.688265 0.402207 0.701836 0.390655 0 0 0 0.00281905 l
+0.688265 0.402207 0.686687 0.408981 0 0 0 0.00281905 l
+0.688265 0.402207 0.685734 0.398952 0 0 0 0.00281905 l
+-0.798305 -0.300821 -0.805424 -0.314174 0 0 0 0.00281905 l
+-0.798305 -0.300821 -0.804495 -0.296672 0 0 0 0.00281905 l
+0.203673 -0.82905 0.198448 -0.830531 0 0 0 0.00281905 l
+0.370282 -0.171548 0.373701 -0.182546 0 0 0 0.00281905 l
+0.370282 -0.171548 0.362232 -0.168432 0 0 0 0.00281905 l
+-0.235176 -0.542238 -0.227965 -0.549005 0 0 0 0.00281905 l
+-0.0754869 -0.178834 -0.0728107 -0.187824 0 0 0 0.00281905 l
+-0.0754869 -0.178834 -0.0734321 -0.161026 0 0 0 0.00281905 l
+-0.0754869 -0.178834 -0.0888636 -0.179631 0 0 0 0.00281905 l
+0.0972237 -0.96864 0.108423 -0.982607 0 0 0 0.00281905 l
+0.0972237 -0.96864 0.106614 -0.95335 0 0 0 0.00281905 l
+-0.747446 0.188568 -0.741142 0.1823 0 0 0 0.00281905 l
+-0.747446 0.188568 -0.747825 0.191689 0 0 0 0.00281905 l
+-0.536663 -0.014828 -0.515578 -0.0129698 0 0 0 0.00281905 l
+-0.536663 -0.014828 -0.550855 -0.0319624 0 0 0 0.00281905 l
+-0.125561 -0.810106 -0.137801 -0.799296 0 0 0 0.00281905 l
+-0.138074 -0.390706 -0.132243 -0.395909 0 0 0 0.00281905 l
+-0.138074 -0.390706 -0.151434 -0.396547 0 0 0 0.00281905 l
+-0.138074 -0.390706 -0.139104 -0.387702 0 0 0 0.00281905 l
+0.707249 0.0971727 0.714044 0.0853493 0 0 0 0.00281905 l
+0.707249 0.0971727 0.703811 0.104289 0 0 0 0.00281905 l
+0.707249 0.0971727 0.696672 0.0964095 0 0 0 0.00281905 l
+-0.795524 -0.55775 -0.787553 -0.566308 0 0 0 0.00281905 l
+-0.795524 -0.55775 -0.807026 -0.558512 0 0 0 0.00281905 l
+-0.0268939 0.646548 -0.0338108 0.659116 0 0 0 0.00281905 l
+-0.0268939 0.646548 -0.0309986 0.638417 0 0 0 0.00281905 l
+-0.727197 -0.652705 -0.729552 -0.646194 0 0 0 0.00281905 l
+0.173734 -0.851037 0.193884 -0.861234 0 0 0 0.00281905 l
+0.173734 -0.851037 0.179786 -0.84089 0 0 0 0.00281905 l
+-0.249699 -0.873503 -0.254183 -0.892282 0 0 0 0.00281905 l
+-0.249699 -0.873503 -0.24481 -0.868924 0 0 0 0.00281905 l
+0.652656 0.300091 0.654281 0.3051 0 0 0 0.00281905 l
+0.652656 0.300091 0.657916 0.29594 0 0 0 0.00281905 l
+0.652656 0.300091 0.645407 0.298348 0 0 0 0.00281905 l
+0.659346 -0.308518 0.663463 -0.313731 0 0 0 0.00281905 l
+0.659346 -0.308518 0.664694 -0.306885 0 0 0 0.00281905 l
+0.659346 -0.308518 0.653593 -0.312451 0 0 0 0.00281905 l
+0.659346 -0.308518 0.656959 -0.305592 0 0 0 0.00281905 l
+-0.290468 -0.346537 -0.278715 -0.332195 0 0 0 0.00281905 l
+-0.290468 -0.346537 -0.300281 -0.334504 0 0 0 0.00281905 l
+-0.290468 -0.346537 -0.286214 -0.34936 0 0 0 0.00281905 l
+-0.290468 -0.346537 -0.300767 -0.352311 0 0 0 0.00281905 l
+0.0872514 0.418275 0.0860354 0.408903 0 0 0 0.00281905 l
+0.0872514 0.418275 0.104082 0.422344 0 0 0 0.00281905 l
+0.0872514 0.418275 0.0823872 0.420038 0 0 0 0.00281905 l
+-0.493155 0.0733156 -0.495998 0.0834818 0 0 0 0.00281905 l
+-0.493155 0.0733156 -0.473493 0.0653732 0 0 0 0.00281905 l
+0.100464 -0.570456 0.113801 -0.587613 0 0 0 0.00281905 l
+0.100464 -0.570456 0.0869546 -0.561376 0 0 0 0.00281905 l
+0.295154 -0.677226 0.293906 -0.674426 0 0 0 0.00281905 l
+0.295154 -0.677226 0.304481 -0.677698 0 0 0 0.00281905 l
+-0.487075 -0.208759 -0.493652 -0.22274 0 0 0 0.00281905 l
+-0.487075 -0.208759 -0.503779 -0.201759 0 0 0 0.00281905 l
+-0.776064 -0.200375 -0.78696 -0.203352 0 0 0 0.00281905 l
+-0.261521 -0.452681 -0.252748 -0.468563 0 0 0 0.00281905 l
+-0.261521 -0.452681 -0.274216 -0.449205 0 0 0 0.00281905 l
+-0.992017 0.0460004 -0.991884 0.0344015 0 0 0 0.00281905 l
+-0.992017 0.0460004 -0.994663 0.0557993 0 0 0 0.00281905 l
+-0.552383 0.599322 -0.55359 0.609783 0 0 0 0.00281905 l
+-0.552383 0.599322 -0.549732 0.598092 0 0 0 0.00281905 l
+0.107035 0.159896 0.107272 0.158221 0 0 0 0.00281905 l
+0.107035 0.159896 0.103421 0.166096 0 0 0 0.00281905 l
+-0.656915 -0.725085 -0.655095 -0.729278 0 0 0 0.00281905 l
+-0.656915 -0.725085 -0.649426 -0.718211 0 0 0 0.00281905 l
+-0.656915 -0.725085 -0.665407 -0.716963 0 0 0 0.00281905 l
+-0.668449 -0.29223 -0.666978 -0.27837 0 0 0 0.00281905 l
+-0.668449 -0.29223 -0.662136 -0.30796 0 0 0 0.00281905 l
+-0.668449 -0.29223 -0.681757 -0.28589 0 0 0 0.00281905 l
+0.36624 0.645527 0.361697 0.627478 0 0 0 0.00281905 l
+0.36624 0.645527 0.368586 0.645902 0 0 0 0.00281905 l
+-0.367083 -0.887482 -0.370245 -0.881833 0 0 0 0.00281905 l
+-0.367083 -0.887482 -0.36419 -0.887224 0 0 0 0.00281905 l
+-0.487309 -0.757779 -0.488131 -0.77713 0 0 0 0.00281905 l
+-0.487309 -0.757779 -0.469455 -0.756369 0 0 0 0.00281905 l
+-0.524048 0.551139 -0.518386 0.557415 0 0 0 0.00281905 l
+-0.524048 0.551139 -0.53043 0.547367 0 0 0 0.00281905 l
+0.51367 -0.505498 0.519862 -0.505883 0 0 0 0.00281905 l
+0.51367 -0.505498 0.507275 -0.516024 0 0 0 0.00281905 l
+0.622745 -0.723038 0.619001 -0.719551 0 0 0 0.00281905 l
+-0.0099758 0.355066 -0.00454499 0.358401 0 0 0 0.00281905 l
+-0.0099758 0.355066 -0.023462 0.365896 0 0 0 0.00281905 l
+-0.317296 0.494619 -0.309704 0.506116 0 0 0 0.00281905 l
+-0.317296 0.494619 -0.327972 0.497988 0 0 0 0.00281905 l
+0.816767 -0.109355 0.814984 -0.116465 0 0 0 0.00281905 l
+0.816767 -0.109355 0.821864 -0.105424 0 0 0 0.00281905 l
+0.816767 -0.109355 0.809168 -0.108243 0 0 0 0.00281905 l
+0.247246 0.0284738 0.250115 0.0297416 0 0 0 0.00281905 l
+0.247246 0.0284738 0.240705 0.0346761 0 0 0 0.00281905 l
+-0.938911 -0.0659163 -0.930461 -0.0786856 0 0 0 0.00281905 l
+-0.938911 -0.0659163 -0.948799 -0.0760186 0 0 0 0.00281905 l
+-0.938911 -0.0659163 -0.948026 -0.0576251 0 0 0 0.00281905 l
+-0.779969 -0.0900206 -0.782909 -0.080582 0 0 0 0.00281905 l
+-0.146222 -0.766371 -0.149003 -0.75632 0 0 0 0.00281905 l
+-0.146222 -0.766371 -0.14014 -0.764077 0 0 0 0.00281905 l
+-0.146222 -0.766371 -0.146624 -0.768533 0 0 0 0.00281905 l
+-0.816017 0.489713 -0.814852 0.497071 0 0 0 0.00281905 l
+0.280944 -0.0852214 0.265029 -0.099268 0 0 0 0.00281905 l
+0.280944 -0.0852214 0.275404 -0.0801483 0 0 0 0.00281905 l
+-0.393998 0.438416 -0.396063 0.453229 0 0 0 0.00281905 l
+-0.393998 0.438416 -0.398796 0.434046 0 0 0 0.00281905 l
+0.410167 -0.748167 0.41135 -0.758625 0 0 0 0.00281905 l
+0.410167 -0.748167 0.411883 -0.742422 0 0 0 0.00281905 l
+-0.309497 -0.642881 -0.294257 -0.643241 0 0 0 0.00281905 l
+0.32594 0.223701 0.335655 0.210385 0 0 0 0.00281905 l
+0.32594 0.223701 0.339295 0.231306 0 0 0 0.00281905 l
+0.0520985 0.545457 0.0471527 0.546501 0 0 0 0.00281905 l
+-0.125444 0.504397 -0.101502 0.50785 0 0 0 0.00281905 l
+-0.125444 0.504397 -0.126849 0.508265 0 0 0 0.00281905 l
+-0.205153 0.251317 -0.219244 0.2327 0 0 0 0.00281905 l
+0.188396 0.393545 0.198122 0.396891 0 0 0 0.00281905 l
+0.188396 0.393545 0.184093 0.395891 0 0 0 0.00281905 l
+-0.234911 0.885979 -0.232116 0.887858 0 0 0 0.00281905 l
+-0.494089 0.543528 -0.474069 0.557784 0 0 0 0.00281905 l
+-0.637834 0.64708 -0.63889 0.643781 0 0 0 0.00281905 l
+-0.637834 0.64708 -0.645734 0.647866 0 0 0 0.00281905 l
+-0.140702 0.892217 -0.137084 0.875066 0 0 0 0.00281905 l
+-0.140702 0.892217 -0.154582 0.887362 0 0 0 0.00281905 l
+0.025778 0.717487 0.0306926 0.717781 0 0 0 0.00281905 l
+0.025778 0.717487 0.0279319 0.710826 0 0 0 0.00281905 l
+-0.0580605 0.0194769 -0.0544496 0.00872464 0 0 0 0.00281905 l
+-0.0580605 0.0194769 -0.0513189 0.0285547 0 0 0 0.00281905 l
+-0.944361 -0.202361 -0.935411 -0.211838 0 0 0 0.00281905 l
+-0.944361 -0.202361 -0.940486 -0.19875 0 0 0 0.00281905 l
+-0.944361 -0.202361 -0.94685 -0.202549 0 0 0 0.00281905 l
+0.91032 -0.313594 0.914891 -0.305581 0 0 0 0.00281905 l
+0.91032 -0.313594 0.889826 -0.319835 0 0 0 0.00281905 l
+-0.134892 -0.0247255 -0.147642 -0.0374651 0 0 0 0.00281905 l
+-0.134892 -0.0247255 -0.132752 -0.0207942 0 0 0 0.00281905 l
+-0.134892 -0.0247255 -0.144765 -0.0193012 0 0 0 0.00281905 l
+-0.362239 0.209805 -0.358903 0.205019 0 0 0 0.00281905 l
+-0.0705677 0.881325 -0.0746222 0.889889 0 0 0 0.00281905 l
+0.677327 0.515092 0.684993 0.512614 0 0 0 0.00281905 l
+0.677327 0.515092 0.674158 0.523633 0 0 0 0.00281905 l
+-0.0848311 -0.52823 -0.0926513 -0.513891 0 0 0 0.00281905 l
+-0.0848311 -0.52823 -0.0783426 -0.53355 0 0 0 0.00281905 l
+-0.257386 0.964242 -0.225639 0.970066 0 0 0 0.00281905 l
+-0.257386 0.964242 -0.274967 0.939157 0 0 0 0.00281905 l
+-0.229932 0.0824348 -0.225564 0.0998431 0 0 0 0.00281905 l
+-0.229932 0.0824348 -0.239432 0.0670741 0 0 0 0.00281905 l
+0.42895 -0.046238 0.427405 -0.0578001 0 0 0 0.00281905 l
+0.42895 -0.046238 0.423456 -0.0335887 0 0 0 0.00281905 l
+0.546109 -0.11865 0.547045 -0.112631 0 0 0 0.00281905 l
+0.252654 0.627491 0.255207 0.643144 0 0 0 0.00281905 l
+0.252654 0.627491 0.269886 0.631533 0 0 0 0.00281905 l
+-0.323036 -0.865246 -0.32373 -0.856311 0 0 0 0.00281905 l
+-0.323036 -0.865246 -0.30212 -0.867791 0 0 0 0.00281905 l
+-0.054016 0.470261 -0.0711508 0.470514 0 0 0 0.00281905 l
+0.897754 -0.0982184 0.904713 -0.11405 0 0 0 0.00281905 l
+0.897754 -0.0982184 0.902076 -0.0868506 0 0 0 0.00281905 l
+0.897754 -0.0982184 0.89326 -0.0987694 0 0 0 0.00281905 l
+-0.153606 0.535373 -0.148329 0.531672 0 0 0 0.00281905 l
+-0.153606 0.535373 -0.159515 0.537419 0 0 0 0.00281905 l
+-0.186383 -0.567019 -0.179368 -0.578001 0 0 0 0.00281905 l
+-0.186383 -0.567019 -0.183174 -0.561218 0 0 0 0.00281905 l
+-0.186383 -0.567019 -0.201918 -0.567312 0 0 0 0.00281905 l
+-0.597354 0.250663 -0.596434 0.234755 0 0 0 0.00281905 l
+-0.597354 0.250663 -0.596973 0.250855 0 0 0 0.00281905 l
+-0.597354 0.250663 -0.610157 0.243089 0 0 0 0.00281905 l
+0.468978 -0.485117 0.468713 -0.469332 0 0 0 0.00281905 l
+0.468978 -0.485117 0.478416 -0.492517 0 0 0 0.00281905 l
+0.468978 -0.485117 0.453917 -0.504761 0 0 0 0.00281905 l
+0.626054 -0.443826 0.63303 -0.457469 0 0 0 0.00281905 l
+0.626054 -0.443826 0.629643 -0.439224 0 0 0 0.00281905 l
+0.626054 -0.443826 0.611835 -0.452193 0 0 0 0.00281905 l
+-0.45341 -0.453976 -0.459833 -0.445835 0 0 0 0.00281905 l
+-0.216883 -0.14132 -0.199549 -0.140703 0 0 0 0.00281905 l
+-0.216883 -0.14132 -0.229091 -0.135995 0 0 0 0.00281905 l
+-0.168607 -0.0811395 -0.170001 -0.0653636 0 0 0 0.00281905 l
+-0.168607 -0.0811395 -0.163575 -0.0804066 0 0 0 0.00281905 l
+-0.168607 -0.0811395 -0.181808 -0.0866542 0 0 0 0.00281905 l
+-0.429034 0.416299 -0.43382 0.433634 0 0 0 0.00281905 l
+-0.429034 0.416299 -0.420386 0.412927 0 0 0 0.00281905 l
+-0.429034 0.416299 -0.436099 0.412507 0 0 0 0.00281905 l
+0.649502 0.150461 0.648666 0.15843 0 0 0 0.00281905 l
+0.649502 0.150461 0.652438 0.145722 0 0 0 0.00281905 l
+0.649502 0.150461 0.63272 0.138527 0 0 0 0.00281905 l
+0.0662608 -0.49624 0.0728685 -0.484108 0 0 0 0.00281905 l
+-0.170001 -0.0653636 -0.16075 -0.0598025 0 0 0 0.00281905 l
+-0.170001 -0.0653636 -0.168607 -0.0811395 0 0 0 0.00281905 l
+-0.775189 -0.0704009 -0.775745 -0.0644735 0 0 0 0.00281905 l
+-0.775189 -0.0704009 -0.765284 -0.0678209 0 0 0 0.00281905 l
+-0.775189 -0.0704009 -0.782909 -0.080582 0 0 0 0.00281905 l
+-0.168078 -0.891159 -0.174424 -0.882171 0 0 0 0.00281905 l
+-0.168078 -0.891159 -0.171041 -0.895712 0 0 0 0.00281905 l
+0.338724 0.62263 0.341644 0.642019 0 0 0 0.00281905 l
+0.338724 0.62263 0.330746 0.623265 0 0 0 0.00281905 l
+-0.217841 -0.432883 -0.207803 -0.446474 0 0 0 0.00281905 l
+-0.217841 -0.432883 -0.209248 -0.422391 0 0 0 0.00281905 l
+-0.217841 -0.432883 -0.232567 -0.449248 0 0 0 0.00281905 l
+-0.388473 -0.530037 -0.380502 -0.520625 0 0 0 0.00281905 l
+-0.388473 -0.530037 -0.401211 -0.525683 0 0 0 0.00281905 l
+-0.651853 -0.141402 -0.64946 -0.124069 0 0 0 0.00281905 l
+-0.651853 -0.141402 -0.651433 -0.148657 0 0 0 0.00281905 l
+0.502152 0.423863 0.502418 0.414217 0 0 0 0.00281905 l
+0.502152 0.423863 0.508216 0.435253 0 0 0 0.00281905 l
+0.232143 0.795267 0.23109 0.804567 0 0 0 0.00281905 l
+0.452776 0.876357 0.448512 0.872929 0 0 0 0.00281905 l
+0.154214 -0.121928 0.153758 -0.116353 0 0 0 0.00281905 l
+0.154214 -0.121928 0.144566 -0.128166 0 0 0 0.00281905 l
+-0.63889 0.643781 -0.637834 0.64708 0 0 0 0.00281905 l
+-0.63889 0.643781 -0.642314 0.624527 0 0 0 0.00281905 l
+-0.575832 0.639813 -0.571486 0.645211 0 0 0 0.00281905 l
+-0.575832 0.639813 -0.583614 0.630635 0 0 0 0.00281905 l
+0.979667 -0.0775116 0.978179 -0.0889295 0 0 0 0.00281905 l
+0.979667 -0.0775116 0.991225 -0.077941 0 0 0 0.00281905 l
+0.979667 -0.0775116 0.975961 -0.0728958 0 0 0 0.00281905 l
+-0.187573 0.735514 -0.183273 0.742061 0 0 0 0.00281905 l
+-0.187573 0.735514 -0.185542 0.734215 0 0 0 0.00281905 l
+-0.187573 0.735514 -0.199306 0.739641 0 0 0 0.00281905 l
+-0.91657 0.37069 -0.911831 0.382237 0 0 0 0.00281905 l
+-0.44041 0.859266 -0.446199 0.844963 0 0 0 0.00281905 l
+-0.44041 0.859266 -0.438703 0.860624 0 0 0 0.00281905 l
+0.535252 -0.380814 0.533279 -0.390751 0 0 0 0.00281905 l
+0.535252 -0.380814 0.541081 -0.372723 0 0 0 0.00281905 l
+-0.550855 -0.0319624 -0.548778 -0.0491475 0 0 0 0.00281905 l
+-0.550855 -0.0319624 -0.536663 -0.014828 0 0 0 0.00281905 l
+-0.462198 -0.867008 -0.455958 -0.865832 0 0 0 0.00281905 l
+-0.262012 -0.679304 -0.249368 -0.685586 0 0 0 0.00281905 l
+-0.262012 -0.679304 -0.264465 -0.678891 0 0 0 0.00281905 l
+-0.41998 -0.650518 -0.424513 -0.656724 0 0 0 0.00281905 l
+-0.41998 -0.650518 -0.406829 -0.643122 0 0 0 0.00281905 l
+-0.41998 -0.650518 -0.429033 -0.645016 0 0 0 0.00281905 l
+0.688782 -0.366273 0.697976 -0.359357 0 0 0 0.00281905 l
+0.688782 -0.366273 0.669386 -0.362048 0 0 0 0.00281905 l
+-0.703036 0.439787 -0.693391 0.442563 0 0 0 0.00281905 l
+-0.703036 0.439787 -0.714001 0.451106 0 0 0 0.00281905 l
+0.923444 0.223425 0.941692 0.227407 0 0 0 0.00281905 l
+0.923444 0.223425 0.912829 0.215637 0 0 0 0.00281905 l
+-0.0458544 -0.0798258 -0.0461062 -0.075782 0 0 0 0.00281905 l
+-0.0458544 -0.0798258 -0.0482593 -0.088062 0 0 0 0.00281905 l
+-0.872738 0.405459 -0.881141 0.420081 0 0 0 0.00281905 l
+-0.872738 0.405459 -0.873724 0.39683 0 0 0 0.00281905 l
+0.194284 -0.359864 0.196037 -0.350555 0 0 0 0.00281905 l
+0.194284 -0.359864 0.211175 -0.363979 0 0 0 0.00281905 l
+0.194284 -0.359864 0.180877 -0.371896 0 0 0 0.00281905 l
+-0.0142458 0.5042 -0.0100742 0.498498 0 0 0 0.00281905 l
+0.837457 0.128422 0.832684 0.14044 0 0 0 0.00281905 l
+0.837457 0.128422 0.840439 0.111089 0 0 0 0.00281905 l
+0.253252 -0.420961 0.251835 -0.425419 0 0 0 0.00281905 l
+0.253252 -0.420961 0.266514 -0.419193 0 0 0 0.00281905 l
+0.0605841 -0.660208 0.0565057 -0.642049 0 0 0 0.00281905 l
+0.0605841 -0.660208 0.0544229 -0.665024 0 0 0 0.00281905 l
+0.223311 0.453686 0.215908 0.458661 0 0 0 0.00281905 l
+-0.038905 0.0946904 -0.0375404 0.0891898 0 0 0 0.00281905 l
+-0.0406692 -0.859425 -0.0387151 -0.858925 0 0 0 0.00281905 l
+-0.0406692 -0.859425 -0.0536879 -0.869108 0 0 0 0.00281905 l
+0.376163 0.159085 0.380019 0.179202 0 0 0 0.00281905 l
+0.376163 0.159085 0.372812 0.159692 0 0 0 0.00281905 l
+-0.606561 0.27321 -0.60704 0.268573 0 0 0 0.00281905 l
+-0.606561 0.27321 -0.606897 0.276546 0 0 0 0.00281905 l
+-0.606561 0.27321 -0.603329 0.274645 0 0 0 0.00281905 l
+0.251837 0.396132 0.256996 0.393832 0 0 0 0.00281905 l
+0.251837 0.396132 0.24714 0.401271 0 0 0 0.00281905 l
+-0.335798 0.362651 -0.341145 0.380351 0 0 0 0.00281905 l
+-0.509096 0.0327524 -0.497804 0.0319589 0 0 0 0.00281905 l
+-0.50933 0.0862189 -0.502375 0.091121 0 0 0 0.00281905 l
+-0.50933 0.0862189 -0.515668 0.0836378 0 0 0 0.00281905 l
+0.864085 0.397894 0.867339 0.39768 0 0 0 0.00281905 l
+0.864085 0.397894 0.857665 0.379156 0 0 0 0.00281905 l
+0.864085 0.397894 0.847262 0.41219 0 0 0 0.00281905 l
+-0.344462 0.211454 -0.347965 0.199637 0 0 0 0.00281905 l
+-0.344462 0.211454 -0.340959 0.214098 0 0 0 0.00281905 l
+0.23851 0.0905993 0.229261 0.100429 0 0 0 0.00281905 l
+0.450088 0.571511 0.459201 0.554054 0 0 0 0.00281905 l
+0.450088 0.571511 0.438294 0.582879 0 0 0 0.00281905 l
+-0.0871538 0.473291 -0.0895336 0.469141 0 0 0 0.00281905 l
+-0.0871538 0.473291 -0.089762 0.474465 0 0 0 0.00281905 l
+-0.24861 0.608091 -0.257138 0.614416 0 0 0 0.00281905 l
+-0.24861 0.608091 -0.25576 0.602377 0 0 0 0.00281905 l
+-0.325687 -0.670572 -0.334477 -0.68491 0 0 0 0.00281905 l
+-0.325687 -0.670572 -0.324343 -0.661009 0 0 0 0.00281905 l
+-0.325687 -0.670572 -0.306925 -0.672334 0 0 0 0.00281905 l
+-0.692573 -0.626879 -0.697747 -0.632855 0 0 0 0.00281905 l
+-0.692573 -0.626879 -0.6973 -0.624367 0 0 0 0.00281905 l
+0.325535 0.691825 0.344487 0.696933 0 0 0 0.00281905 l
+0.325535 0.691825 0.325821 0.685853 0 0 0 0.00281905 l
+0.488671 -0.24711 0.482676 -0.24214 0 0 0 0.00281905 l
+-0.461637 0.150778 -0.460791 0.137156 0 0 0 0.00281905 l
+-0.461637 0.150778 -0.47525 0.148449 0 0 0 0.00281905 l
+0.450305 -0.538557 0.458553 -0.546045 0 0 0 0.00281905 l
+-0.853043 0.211289 -0.838068 0.226193 0 0 0 0.00281905 l
+-0.853043 0.211289 -0.845435 0.199336 0 0 0 0.00281905 l
+-0.853043 0.211289 -0.857591 0.212183 0 0 0 0.00281905 l
+0.736018 -0.081899 0.749546 -0.067776 0 0 0 0.00281905 l
+0.736018 -0.081899 0.731445 -0.089025 0 0 0 0.00281905 l
+0.371997 -0.495545 0.376853 -0.505102 0 0 0 0.00281905 l
+0.371997 -0.495545 0.379474 -0.483721 0 0 0 0.00281905 l
+0.371997 -0.495545 0.365008 -0.501858 0 0 0 0.00281905 l
+-0.411772 0.587496 -0.410236 0.597317 0 0 0 0.00281905 l
+0.14672 -0.7905 0.15877 -0.782437 0 0 0 0.00281905 l
+0.14672 -0.7905 0.145373 -0.795503 0 0 0 0.00281905 l
+-0.200119 -0.305648 -0.199055 -0.312533 0 0 0 0.00281905 l
+-0.200119 -0.305648 -0.18317 -0.300343 0 0 0 0.00281905 l
+0.0375292 -0.6572 0.0355181 -0.666428 0 0 0 0.00281905 l
+-0.132155 0.836678 -0.120907 0.827427 0 0 0 0.00281905 l
+-0.132155 0.836678 -0.12539 0.84493 0 0 0 0.00281905 l
+-0.192006 0.469847 -0.182278 0.478683 0 0 0 0.00281905 l
+-0.192006 0.469847 -0.184303 0.462078 0 0 0 0.00281905 l
+0.0482192 0.772924 0.045473 0.758335 0 0 0 0.00281905 l
+0.0482192 0.772924 0.0474121 0.776291 0 0 0 0.00281905 l
+-0.0886712 0.0317118 -0.0940309 0.0453731 0 0 0 0.00281905 l
+-0.0886712 0.0317118 -0.0794213 0.0295471 0 0 0 0.00281905 l
+-0.0886712 0.0317118 -0.10296 0.0215788 0 0 0 0.00281905 l
+-0.685036 -0.0731641 -0.680974 -0.0567207 0 0 0 0.00281905 l
+-0.685036 -0.0731641 -0.697077 -0.0698009 0 0 0 0.00281905 l
+0.401051 -0.314124 0.40394 -0.313381 0 0 0 0.00281905 l
+0.401051 -0.314124 0.395619 -0.316126 0 0 0 0.00281905 l
+0.0289148 -0.822333 0.0192621 -0.802804 0 0 0 0.00281905 l
+0.0289148 -0.822333 0.0344357 -0.826531 0 0 0 0.00281905 l
+0.0289148 -0.822333 0.00823022 -0.827218 0 0 0 0.00281905 l
+-0.316533 -0.0584141 -0.311092 -0.0578662 0 0 0 0.00281905 l
+-0.316533 -0.0584141 -0.322456 -0.0570458 0 0 0 0.00281905 l
+0.229489 -0.607493 0.238127 -0.604508 0 0 0 0.00281905 l
+0.229489 -0.607493 0.224441 -0.608386 0 0 0 0.00281905 l
+-0.00387802 0.791185 -0.00249991 0.786333 0 0 0 0.00281905 l
+0.280153 0.357591 0.286172 0.379342 0 0 0 0.00281905 l
+0.256388 -0.700134 0.261532 -0.695079 0 0 0 0.00281905 l
+0.256388 -0.700134 0.264682 -0.704197 0 0 0 0.00281905 l
+0.256388 -0.700134 0.255052 -0.706085 0 0 0 0.00281905 l
+0.07846 -0.145534 0.0755072 -0.133152 0 0 0 0.00281905 l
+0.07846 -0.145534 0.087542 -0.146053 0 0 0 0.00281905 l
+0.07846 -0.145534 0.0762076 -0.147555 0 0 0 0.00281905 l
+-0.0414119 0.567753 -0.0485673 0.581213 0 0 0 0.00281905 l
+-0.0414119 0.567753 -0.0247685 0.562519 0 0 0 0.00281905 l
+-0.0414119 0.567753 -0.0424917 0.555068 0 0 0 0.00281905 l
+-0.276731 -0.358055 -0.270772 -0.357836 0 0 0 0.00281905 l
+-0.276731 -0.358055 -0.286214 -0.34936 0 0 0 0.00281905 l
+0.32107 -0.407555 0.334736 -0.422443 0 0 0 0.00281905 l
+0.32107 -0.407555 0.302259 -0.399627 0 0 0 0.00281905 l
+0.593964 0.468026 0.599551 0.454121 0 0 0 0.00281905 l
+0.593964 0.468026 0.604392 0.472019 0 0 0 0.00281905 l
+0.781036 -0.609119 0.781693 -0.59491 0 0 0 0.00281905 l
+0.690405 -0.110173 0.695985 -0.109827 0 0 0 0.00281905 l
+0.288477 0.807801 0.285576 0.798016 0 0 0 0.00281905 l
+0.288477 0.807801 0.297208 0.820841 0 0 0 0.00281905 l
+0.288477 0.807801 0.278122 0.80868 0 0 0 0.00281905 l
+0.39564 -0.328158 0.396859 -0.334295 0 0 0 0.00281905 l
+0.39564 -0.328158 0.390005 -0.325993 0 0 0 0.00281905 l
+0.113774 -0.381678 0.10916 -0.389834 0 0 0 0.00281905 l
+0.191437 -0.152231 0.199872 -0.13929 0 0 0 0.00281905 l
+0.191437 -0.152231 0.199764 -0.15863 0 0 0 0.00281905 l
+-0.613453 0.263967 -0.616222 0.272154 0 0 0 0.00281905 l
+-0.613453 0.263967 -0.60704 0.268573 0 0 0 0.00281905 l
+-0.613453 0.263967 -0.619943 0.255085 0 0 0 0.00281905 l
+0.344979 -0.873333 0.347043 -0.881234 0 0 0 0.00281905 l
+0.344979 -0.873333 0.350031 -0.860059 0 0 0 0.00281905 l
+-0.0339329 -0.0342905 -0.0310971 -0.0322101 0 0 0 0.00281905 l
+-0.0339329 -0.0342905 -0.0386715 -0.0431681 0 0 0 0.00281905 l
+0.629626 -0.186071 0.636227 -0.184951 0 0 0 0.00281905 l
+0.629626 -0.186071 0.626533 -0.182653 0 0 0 0.00281905 l
+0.290084 0.166936 0.299838 0.16681 0 0 0 0.00281905 l
+0.290084 0.166936 0.283233 0.162454 0 0 0 0.00281905 l
+0.679845 0.449759 0.683102 0.445595 0 0 0 0.00281905 l
+0.633164 -0.295608 0.63084 -0.287456 0 0 0 0.00281905 l
+0.633164 -0.295608 0.648165 -0.294344 0 0 0 0.00281905 l
+0.633164 -0.295608 0.634788 -0.304008 0 0 0 0.00281905 l
+-0.0265918 0.291939 -0.0254182 0.300329 0 0 0 0.00281905 l
+-0.0265918 0.291939 -0.0100627 0.285587 0 0 0 0.00281905 l
+-0.0265918 0.291939 -0.0411414 0.297721 0 0 0 0.00281905 l
+-0.124624 0.817791 -0.121914 0.809835 0 0 0 0.00281905 l
+-0.124624 0.817791 -0.120907 0.827427 0 0 0 0.00281905 l
+-0.124624 0.817791 -0.140829 0.820803 0 0 0 0.00281905 l
+-0.166842 0.314475 -0.15453 0.309752 0 0 0 0.00281905 l
+-0.166842 0.314475 -0.17744 0.305878 0 0 0 0.00281905 l
+-0.166842 0.314475 -0.179255 0.322144 0 0 0 0.00281905 l
+0.0103448 0.251022 0.0109269 0.251209 0 0 0 0.00281905 l
+-0.846486 0.0536178 -0.836592 0.0513411 0 0 0 0.00281905 l
+-0.846486 0.0536178 -0.84571 0.0374958 0 0 0 0.00281905 l
+-0.846486 0.0536178 -0.85772 0.0551769 0 0 0 0.00281905 l
+-0.00961435 -0.898244 -0.0124874 -0.893705 0 0 0 0.00281905 l
+-0.274216 -0.449205 -0.26684 -0.440211 0 0 0 0.00281905 l
+-0.274216 -0.449205 -0.261521 -0.452681 0 0 0 0.00281905 l
+-0.274216 -0.449205 -0.282715 -0.444933 0 0 0 0.00281905 l
+-0.157561 -0.237855 -0.151409 -0.228228 0 0 0 0.00281905 l
+0.0267073 -0.50005 0.0235847 -0.506653 0 0 0 0.00281905 l
+0.0267073 -0.50005 0.0364645 -0.486172 0 0 0 0.00281905 l
+-0.583239 0.00892794 -0.566709 0.00698378 0 0 0 0.00281905 l
+-0.583239 0.00892794 -0.592022 -0.00802412 0 0 0 0.00281905 l
+0.731806 -0.225457 0.720841 -0.206468 0 0 0 0.00281905 l
+0.731806 -0.225457 0.73303 -0.235769 0 0 0 0.00281905 l
+0.257781 -0.250963 0.258111 -0.263949 0 0 0 0.00281905 l
+0.257781 -0.250963 0.251124 -0.242378 0 0 0 0.00281905 l
+0.257781 -0.250963 0.260383 -0.248829 0 0 0 0.00281905 l
+0.693747 -0.174308 0.704142 -0.170671 0 0 0 0.00281905 l
+0.693747 -0.174308 0.691636 -0.179852 0 0 0 0.00281905 l
+0.365757 0.371255 0.377206 0.359339 0 0 0 0.00281905 l
+0.365757 0.371255 0.368217 0.384348 0 0 0 0.00281905 l
+0.365757 0.371255 0.353408 0.370553 0 0 0 0.00281905 l
+-0.866708 -0.286972 -0.867904 -0.305847 0 0 0 0.00281905 l
+-0.866708 -0.286972 -0.858749 -0.271037 0 0 0 0.00281905 l
+-0.866708 -0.286972 -0.879857 -0.285722 0 0 0 0.00281905 l
+0.0135843 0.861926 0.0325596 0.861852 0 0 0 0.00281905 l
+0.0135843 0.861926 0.00534676 0.85889 0 0 0 0.00281905 l
+-0.144765 -0.0193012 -0.14568 -0.0132317 0 0 0 0.00281905 l
+-0.144765 -0.0193012 -0.134892 -0.0247255 0 0 0 0.00281905 l
+-0.140041 -0.673035 -0.13721 -0.673133 0 0 0 0.00281905 l
+-0.140041 -0.673035 -0.145343 -0.672199 0 0 0 0.00281905 l
+-0.421132 0.621589 -0.409234 0.623312 0 0 0 0.00281905 l
+-0.421132 0.621589 -0.428635 0.621301 0 0 0 0.00281905 l
+0.554687 -0.655076 0.554137 -0.656497 0 0 0 0.00281905 l
+-0.469206 -0.484257 -0.472065 -0.466637 0 0 0 0.00281905 l
+-0.469206 -0.484257 -0.454287 -0.478457 0 0 0 0.00281905 l
+-0.469206 -0.484257 -0.479893 -0.48795 0 0 0 0.00281905 l
+0.811635 0.57243 0.814299 0.576747 0 0 0 0.00281905 l
+0.811635 0.57243 0.798373 0.578077 0 0 0 0.00281905 l
+-0.870067 0.0179736 -0.870706 0.0225344 0 0 0 0.00281905 l
+-0.870067 0.0179736 -0.85485 0.0176036 0 0 0 0.00281905 l
+-0.870067 0.0179736 -0.877473 0.0176556 0 0 0 0.00281905 l
+-0.464293 0.821904 -0.476657 0.812986 0 0 0 0.00281905 l
+-0.416776 -0.156688 -0.417557 -0.148388 0 0 0 0.00281905 l
+-0.416776 -0.156688 -0.414793 -0.160972 0 0 0 0.00281905 l
+-0.416776 -0.156688 -0.425527 -0.153564 0 0 0 0.00281905 l
+-0.885444 0.102265 -0.894323 0.117195 0 0 0 0.00281905 l
+-0.885444 0.102265 -0.872125 0.090655 0 0 0 0.00281905 l
+-0.885444 0.102265 -0.892357 0.0852273 0 0 0 0.00281905 l
+0.434952 0.0605132 0.428101 0.0498465 0 0 0 0.00281905 l
+0.434952 0.0605132 0.439904 0.0649067 0 0 0 0.00281905 l
+-0.381254 0.0491927 -0.360827 0.0526602 0 0 0 0.00281905 l
+-0.381254 0.0491927 -0.389374 0.0490065 0 0 0 0.00281905 l
+0.415424 -0.89981 0.406362 -0.911624 0 0 0 0.00281905 l
+0.415424 -0.89981 0.408072 -0.893611 0 0 0 0.00281905 l
+0.217039 0.396332 0.223221 0.386072 0 0 0 0.00281905 l
+0.217039 0.396332 0.20979 0.398424 0 0 0 0.00281905 l
+0.0981672 -0.119211 0.109799 -0.12575 0 0 0 0.00281905 l
+0.0981672 -0.119211 0.0901949 -0.107542 0 0 0 0.00281905 l
+0.731991 0.363837 0.736073 0.362641 0 0 0 0.00281905 l
+0.731991 0.363837 0.725933 0.368377 0 0 0 0.00281905 l
+-0.135829 0.363844 -0.130561 0.375195 0 0 0 0.00281905 l
+-0.135829 0.363844 -0.131094 0.354752 0 0 0 0.00281905 l
+-0.135829 0.363844 -0.144105 0.367345 0 0 0 0.00281905 l
+-0.626341 0.174345 -0.61335 0.158522 0 0 0 0.00281905 l
+-0.626341 0.174345 -0.615477 0.189529 0 0 0 0.00281905 l
+-0.626341 0.174345 -0.631199 0.173401 0 0 0 0.00281905 l
+0.379474 -0.483721 0.390793 -0.486306 0 0 0 0.00281905 l
+0.379474 -0.483721 0.371997 -0.495545 0 0 0 0.00281905 l
+-0.861741 0.00365199 -0.86275 -0.0147814 0 0 0 0.00281905 l
+-0.861741 0.00365199 -0.873877 0.0116112 0 0 0 0.00281905 l
+0.304481 -0.677698 0.302004 -0.688305 0 0 0 0.00281905 l
+0.304481 -0.677698 0.295154 -0.677226 0 0 0 0.00281905 l
+0.238127 -0.604508 0.242354 -0.589848 0 0 0 0.00281905 l
+0.238127 -0.604508 0.245718 -0.612089 0 0 0 0.00281905 l
+0.238127 -0.604508 0.229489 -0.607493 0 0 0 0.00281905 l
+0.359181 0.893379 0.368493 0.916552 0 0 0 0.00281905 l
+0.359181 0.893379 0.376107 0.885425 0 0 0 0.00281905 l
+-0.540124 0.570259 -0.539688 0.567085 0 0 0 0.00281905 l
+-0.583424 0.676087 -0.582155 0.668321 0 0 0 0.00281905 l
+-0.583424 0.676087 -0.584045 0.686991 0 0 0 0.00281905 l
+0.352261 0.191609 0.363134 0.203816 0 0 0 0.00281905 l
+0.352261 0.191609 0.346473 0.191668 0 0 0 0.00281905 l
+0.0874055 -0.541674 0.0958835 -0.551611 0 0 0 0.00281905 l
+0.0874055 -0.541674 0.0871399 -0.538193 0 0 0 0.00281905 l
+-0.470956 -0.442362 -0.459833 -0.445835 0 0 0 0.00281905 l
+-0.470956 -0.442362 -0.469842 -0.455161 0 0 0 0.00281905 l
+-0.470956 -0.442362 -0.479498 -0.443917 0 0 0 0.00281905 l
+-0.400809 0.653632 -0.396524 0.653176 0 0 0 0.00281905 l
+-0.400809 0.653632 -0.406455 0.657288 0 0 0 0.00281905 l
+0.665372 0.489621 0.659141 0.482139 0 0 0 0.00281905 l
+0.665372 0.489621 0.666919 0.491917 0 0 0 0.00281905 l
+0.469928 -0.260851 0.477722 -0.272837 0 0 0 0.00281905 l
+0.469928 -0.260851 0.469155 -0.250665 0 0 0 0.00281905 l
+0.469928 -0.260851 0.461629 -0.272027 0 0 0 0.00281905 l
+-0.0387151 -0.858925 -0.0353849 -0.848134 0 0 0 0.00281905 l
+-0.0387151 -0.858925 -0.0406692 -0.859425 0 0 0 0.00281905 l
+-0.75445 0.49453 -0.760542 0.50161 0 0 0 0.00281905 l
+0.358946 -0.176598 0.354077 -0.188918 0 0 0 0.00281905 l
+0.358946 -0.176598 0.362232 -0.168432 0 0 0 0.00281905 l
+-0.701841 0.709226 -0.68068 0.712579 0 0 0 0.00281905 l
+-0.701841 0.709226 -0.695042 0.689592 0 0 0 0.00281905 l
+0.108505 -0.550957 0.109443 -0.556131 0 0 0 0.00281905 l
+0.108505 -0.550957 0.0958835 -0.551611 0 0 0 0.00281905 l
+-0.66216 -0.469287 -0.654178 -0.468224 0 0 0 0.00281905 l
+-0.66216 -0.469287 -0.660209 -0.479733 0 0 0 0.00281905 l
+-0.66216 -0.469287 -0.671443 -0.475682 0 0 0 0.00281905 l
+-0.149317 0.276998 -0.150005 0.274124 0 0 0 0.00281905 l
+-0.149317 0.276998 -0.155367 0.281579 0 0 0 0.00281905 l
+0.109443 -0.556131 0.108505 -0.550957 0 0 0 0.00281905 l
+0.109443 -0.556131 0.122061 -0.555125 0 0 0 0.00281905 l
+-0.492376 0.596604 -0.492109 0.614196 0 0 0 0.00281905 l
+-0.492376 0.596604 -0.493539 0.592099 0 0 0 0.00281905 l
+0.398744 -0.674047 0.404907 -0.676177 0 0 0 0.00281905 l
+0.398744 -0.674047 0.397213 -0.687802 0 0 0 0.00281905 l
+-0.464992 -0.4096 -0.444528 -0.408589 0 0 0 0.00281905 l
+-0.188323 0.56668 -0.181564 0.553376 0 0 0 0.00281905 l
+-0.188323 0.56668 -0.207844 0.567401 0 0 0 0.00281905 l
+0.613597 0.0601242 0.606785 0.0468362 0 0 0 0.00281905 l
+0.613597 0.0601242 0.627468 0.0597638 0 0 0 0.00281905 l
+0.386067 -0.465405 0.393043 -0.464873 0 0 0 0.00281905 l
+0.386067 -0.465405 0.384458 -0.459086 0 0 0 0.00281905 l
+-0.251135 0.745971 -0.240807 0.741568 0 0 0 0.00281905 l
+0.218598 0.477351 0.215932 0.475674 0 0 0 0.00281905 l
+-0.0279088 0.773898 -0.0135983 0.788935 0 0 0 0.00281905 l
+-0.0279088 0.773898 -0.0334288 0.78246 0 0 0 0.00281905 l
+-0.0279088 0.773898 -0.0331129 0.769214 0 0 0 0.00281905 l
+-0.429483 -0.744338 -0.426152 -0.752659 0 0 0 0.00281905 l
+0.007158 0.405619 0.0109142 0.390083 0 0 0 0.00281905 l
+0.841886 -0.0852088 0.844266 -0.0844103 0 0 0 0.00281905 l
+-0.227077 -0.723277 -0.217218 -0.728543 0 0 0 0.00281905 l
+0.588116 0.27078 0.586561 0.287877 0 0 0 0.00281905 l
+0.588116 0.27078 0.576806 0.26792 0 0 0 0.00281905 l
+-0.448952 0.405021 -0.436099 0.412507 0 0 0 0.00281905 l
+-0.448952 0.405021 -0.463433 0.403136 0 0 0 0.00281905 l
+-0.554119 0.646277 -0.550582 0.651462 0 0 0 0.00281905 l
+-0.554119 0.646277 -0.55832 0.641174 0 0 0 0.00281905 l
+0.139506 0.410658 0.158877 0.428998 0 0 0 0.00281905 l
+0.139506 0.410658 0.150428 0.399639 0 0 0 0.00281905 l
+-0.227939 -0.12033 -0.214821 -0.118732 0 0 0 0.00281905 l
+-0.227939 -0.12033 -0.230286 -0.127473 0 0 0 0.00281905 l
+-0.227939 -0.12033 -0.239697 -0.117029 0 0 0 0.00281905 l
+0.724418 0.104039 0.732376 0.112982 0 0 0 0.00281905 l
+0.724418 0.104039 0.737389 0.094595 0 0 0 0.00281905 l
+-0.935923 0.335072 -0.936279 0.325361 0 0 0 0.00281905 l
+-0.935923 0.335072 -0.933061 0.336021 0 0 0 0.00281905 l
+-0.316689 0.16474 -0.305969 0.160879 0 0 0 0.00281905 l
+-0.316689 0.16474 -0.327393 0.159684 0 0 0 0.00281905 l
+-0.358795 0.691045 -0.360989 0.679489 0 0 0 0.00281905 l
+0.476574 0.52699 0.465762 0.527534 0 0 0 0.00281905 l
+-0.403883 -0.0247595 -0.402087 -0.013 0 0 0 0.00281905 l
+-0.403883 -0.0247595 -0.399598 -0.0370971 0 0 0 0.00281905 l
+-0.403883 -0.0247595 -0.408734 -0.027352 0 0 0 0.00281905 l
+0.296858 0.0573792 0.298899 0.0387407 0 0 0 0.00281905 l
+0.296858 0.0573792 0.293983 0.0575007 0 0 0 0.00281905 l
+-0.0411414 0.297721 -0.0413975 0.30903 0 0 0 0.00281905 l
+-0.0411414 0.297721 -0.0265918 0.291939 0 0 0 0.00281905 l
+-0.0411414 0.297721 -0.0438324 0.283814 0 0 0 0.00281905 l
+0.412073 -0.438413 0.412501 -0.426253 0 0 0 0.00281905 l
+0.412073 -0.438413 0.418042 -0.438294 0 0 0 0.00281905 l
+0.412073 -0.438413 0.41088 -0.4435 0 0 0 0.00281905 l
+0.38867 -0.814051 0.399508 -0.825068 0 0 0 0.00281905 l
+0.38867 -0.814051 0.375214 -0.825718 0 0 0 0.00281905 l
+-0.0983433 0.56889 -0.0971836 0.568136 0 0 0 0.00281905 l
+-0.0983433 0.56889 -0.103269 0.569469 0 0 0 0.00281905 l
+0.880723 -0.40095 0.877436 -0.398377 0 0 0 0.00281905 l
+-0.371242 0.627117 -0.363423 0.619505 0 0 0 0.00281905 l
+-0.371242 0.627117 -0.388216 0.638614 0 0 0 0.00281905 l
+0.824082 0.211977 0.827815 0.197654 0 0 0 0.00281905 l
+0.824082 0.211977 0.825176 0.213025 0 0 0 0.00281905 l
+0.824082 0.211977 0.809769 0.207781 0 0 0 0.00281905 l
+0.970852 -0.0230126 0.992233 -0.0336152 0 0 0 0.00281905 l
+0.970852 -0.0230126 0.965567 -0.0267364 0 0 0 0.00281905 l
+-0.275168 -0.50375 -0.263941 -0.513142 0 0 0 0.00281905 l
+-0.275168 -0.50375 -0.267807 -0.491926 0 0 0 0.00281905 l
+-0.275168 -0.50375 -0.290816 -0.504638 0 0 0 0.00281905 l
+-0.773431 -0.519341 -0.781165 -0.519909 0 0 0 0.00281905 l
+-0.773431 -0.519341 -0.76701 -0.513317 0 0 0 0.00281905 l
+0.0857634 -0.793244 0.0809075 -0.78458 0 0 0 0.00281905 l
+0.0857634 -0.793244 0.0822286 -0.806432 0 0 0 0.00281905 l
+-0.533869 0.559109 -0.536139 0.552827 0 0 0 0.00281905 l
+-0.533869 0.559109 -0.539688 0.567085 0 0 0 0.00281905 l
+-0.934105 -0.337959 -0.91995 -0.338815 0 0 0 0.00281905 l
+-0.84571 0.0374958 -0.846486 0.0536178 0 0 0 0.00281905 l
+-0.84571 0.0374958 -0.854856 0.0282175 0 0 0 0.00281905 l
+-0.258292 0.109812 -0.264621 0.127205 0 0 0 0.00281905 l
+-0.258292 0.109812 -0.248937 0.103502 0 0 0 0.00281905 l
+-0.0363477 -0.814841 -0.0350571 -0.807325 0 0 0 0.00281905 l
+-0.0363477 -0.814841 -0.0269046 -0.818167 0 0 0 0.00281905 l
+-0.0363477 -0.814841 -0.0384719 -0.824974 0 0 0 0.00281905 l
+0.38101 0.670285 0.382477 0.679764 0 0 0 0.00281905 l
+0.38101 0.670285 0.377868 0.658179 0 0 0 0.00281905 l
+0.38101 0.670285 0.367063 0.671708 0 0 0 0.00281905 l
+-0.904586 0.342888 -0.904238 0.351851 0 0 0 0.00281905 l
+-0.904586 0.342888 -0.912271 0.332264 0 0 0 0.00281905 l
+-0.135173 -0.753246 -0.123398 -0.743846 0 0 0 0.00281905 l
+-0.135173 -0.753246 -0.14014 -0.764077 0 0 0 0.00281905 l
+-0.395484 0.0887438 -0.391931 0.0930126 0 0 0 0.00281905 l
+-0.395484 0.0887438 -0.409843 0.0917576 0 0 0 0.00281905 l
+-0.248937 0.103502 -0.258292 0.109812 0 0 0 0.00281905 l
+0.414944 0.671736 0.425751 0.670064 0 0 0 0.00281905 l
+0.414944 0.671736 0.408213 0.676786 0 0 0 0.00281905 l
+-0.425682 -0.246788 -0.428002 -0.231154 0 0 0 0.00281905 l
+-0.425682 -0.246788 -0.420794 -0.24615 0 0 0 0.00281905 l
+-0.425682 -0.246788 -0.43431 -0.247648 0 0 0 0.00281905 l
+0.240197 -0.443214 0.244489 -0.441193 0 0 0 0.00281905 l
+0.240197 -0.443214 0.243781 -0.447138 0 0 0 0.00281905 l
+-0.480971 -0.858857 -0.48358 -0.843971 0 0 0 0.00281905 l
+-0.703633 -0.478704 -0.700245 -0.49365 0 0 0 0.00281905 l
+-0.703633 -0.478704 -0.700484 -0.477794 0 0 0 0.00281905 l
+-0.703633 -0.478704 -0.712821 -0.473273 0 0 0 0.00281905 l
+0.810455 -0.213929 0.807522 -0.207394 0 0 0 0.00281905 l
+0.134017 0.679757 0.135443 0.661927 0 0 0 0.00281905 l
+0.134017 0.679757 0.139373 0.694295 0 0 0 0.00281905 l
+0.134017 0.679757 0.123578 0.67919 0 0 0 0.00281905 l
+0.573556 0.413521 0.582653 0.407763 0 0 0 0.00281905 l
+0.573556 0.413521 0.575828 0.418227 0 0 0 0.00281905 l
+0.417676 -0.0281655 0.423456 -0.0335887 0 0 0 0.00281905 l
+0.417676 -0.0281655 0.413889 -0.0313196 0 0 0 0.00281905 l
+0.868956 -0.404247 0.877436 -0.398377 0 0 0 0.00281905 l
+0.868956 -0.404247 0.864759 -0.40803 0 0 0 0.00281905 l
+0.868956 -0.404247 0.867346 -0.402381 0 0 0 0.00281905 l
+-0.804575 0.112702 -0.802534 0.120231 0 0 0 0.00281905 l
+-0.892357 0.0852273 -0.885444 0.102265 0 0 0 0.00281905 l
+-0.892357 0.0852273 -0.887888 0.0810518 0 0 0 0.00281905 l
+-0.892357 0.0852273 -0.903965 0.0793392 0 0 0 0.00281905 l
+0.355863 0.168602 0.35303 0.162167 0 0 0 0.00281905 l
+-0.270828 -0.581995 -0.254477 -0.582653 0 0 0 0.00281905 l
+-0.270828 -0.581995 -0.270518 -0.586567 0 0 0 0.00281905 l
+-0.440459 -0.0670604 -0.437549 -0.0782434 0 0 0 0.00281905 l
+-0.440459 -0.0670604 -0.449571 -0.069077 0 0 0 0.00281905 l
+-0.17991 0.178676 -0.168752 0.176348 0 0 0 0.00281905 l
+-0.17991 0.178676 -0.19267 0.176945 0 0 0 0.00281905 l
+-0.17991 0.178676 -0.175535 0.186114 0 0 0 0.00281905 l
+-0.133133 0.203282 -0.121495 0.203791 0 0 0 0.00281905 l
+-0.133133 0.203282 -0.134562 0.188374 0 0 0 0.00281905 l
+0.538833 0.321194 0.545584 0.316875 0 0 0 0.00281905 l
+0.538833 0.321194 0.523677 0.325968 0 0 0 0.00281905 l
+0.297288 0.643016 0.29588 0.636024 0 0 0 0.00281905 l
+0.297288 0.643016 0.287747 0.653558 0 0 0 0.00281905 l
+-0.437854 -0.352338 -0.432701 -0.340521 0 0 0 0.00281905 l
+-0.437854 -0.352338 -0.420462 -0.354003 0 0 0 0.00281905 l
+0.749324 -0.2716 0.749478 -0.2696 0 0 0 0.00281905 l
+0.749324 -0.2716 0.741704 -0.272312 0 0 0 0.00281905 l
+0.583115 -0.628053 0.594609 -0.623847 0 0 0 0.00281905 l
+0.583115 -0.628053 0.590782 -0.638661 0 0 0 0.00281905 l
+0.583115 -0.628053 0.579447 -0.62234 0 0 0 0.00281905 l
+-0.706291 -0.1071 -0.694682 -0.0967871 0 0 0 0.00281905 l
+-0.706291 -0.1071 -0.72219 -0.0990526 0 0 0 0.00281905 l
+-0.536708 0.00752927 -0.524966 0.0105456 0 0 0 0.00281905 l
+-0.536708 0.00752927 -0.547855 0.0058834 0 0 0 0.00281905 l
+-0.150765 -0.0946922 -0.135879 -0.083559 0 0 0 0.00281905 l
+-0.150765 -0.0946922 -0.161513 -0.100653 0 0 0 0.00281905 l
+-0.226829 -0.567501 -0.221643 -0.551992 0 0 0 0.00281905 l
+-0.226829 -0.567501 -0.234754 -0.573227 0 0 0 0.00281905 l
+-0.081642 0.442934 -0.0744801 0.451434 0 0 0 0.00281905 l
+-0.081642 0.442934 -0.0892202 0.439158 0 0 0 0.00281905 l
+-0.818165 0.323579 -0.814567 0.328272 0 0 0 0.00281905 l
+-0.818165 0.323579 -0.830142 0.318809 0 0 0 0.00281905 l
+0.354671 -0.366082 0.347272 -0.372483 0 0 0 0.00281905 l
+-0.446718 -0.323224 -0.452768 -0.330229 0 0 0 0.00281905 l
+0.413846 0.306869 0.424491 0.310354 0 0 0 0.00281905 l
+0.413846 0.306869 0.407131 0.3083 0 0 0 0.00281905 l
+0.249017 -0.888063 0.265406 -0.891342 0 0 0 0.00281905 l
+-0.579178 -0.428842 -0.56413 -0.432009 0 0 0 0.00281905 l
+0.0324047 0.19896 0.0160789 0.198676 0 0 0 0.00281905 l
+0.532655 0.825652 0.521769 0.849185 0 0 0 0.00281905 l
+0.532655 0.825652 0.53736 0.811539 0 0 0 0.00281905 l
+0.532655 0.825652 0.512679 0.821944 0 0 0 0.00281905 l
+0.583939 0.329436 0.587043 0.337787 0 0 0 0.00281905 l
+0.583939 0.329436 0.570423 0.31569 0 0 0 0.00281905 l
+0.903975 0.383482 0.8962 0.387087 0 0 0 0.00281905 l
+0.300813 0.377633 0.296988 0.391246 0 0 0 0.00281905 l
+-0.190965 0.286471 -0.193514 0.286711 0 0 0 0.00281905 l
+-0.190965 0.286471 -0.184112 0.293467 0 0 0 0.00281905 l
+0.639354 -0.230528 0.650855 -0.219829 0 0 0 0.00281905 l
+0.639354 -0.230528 0.645833 -0.239702 0 0 0 0.00281905 l
+0.340425 0.829587 0.341354 0.835749 0 0 0 0.00281905 l
+0.340425 0.829587 0.331199 0.831583 0 0 0 0.00281905 l
+0.256068 0.245263 0.250948 0.256017 0 0 0 0.00281905 l
+0.256068 0.245263 0.265244 0.237757 0 0 0 0.00281905 l
+0.256068 0.245263 0.247604 0.236462 0 0 0 0.00281905 l
+-0.514077 0.276042 -0.516771 0.291747 0 0 0 0.00281905 l
+-0.514077 0.276042 -0.524107 0.275957 0 0 0 0.00281905 l
+-0.205079 -0.424163 -0.209248 -0.422391 0 0 0 0.00281905 l
+-0.205203 0.434233 -0.213637 0.423911 0 0 0 0.00281905 l
+-0.0923272 -0.865272 -0.0888367 -0.861559 0 0 0 0.00281905 l
+0.651015 0.524361 0.65127 0.539962 0 0 0 0.00281905 l
+0.651015 0.524361 0.652179 0.511229 0 0 0 0.00281905 l
+0.651015 0.524361 0.63914 0.524161 0 0 0 0.00281905 l
+-0.550561 0.501987 -0.55448 0.487851 0 0 0 0.00281905 l
+-0.550561 0.501987 -0.54652 0.506373 0 0 0 0.00281905 l
+-0.828896 -0.254682 -0.827983 -0.231856 0 0 0 0.00281905 l
+0.0181818 -0.0910752 0.0301897 -0.081611 0 0 0 0.00281905 l
+0.0913035 -0.68681 0.0970512 -0.691353 0 0 0 0.00281905 l
+0.0913035 -0.68681 0.0916289 -0.67984 0 0 0 0.00281905 l
+0.0913035 -0.68681 0.0773221 -0.699957 0 0 0 0.00281905 l
+0.768658 -0.257161 0.7771 -0.255417 0 0 0 0.00281905 l
+0.0727212 0.817437 0.0728629 0.797144 0 0 0 0.00281905 l
+0.0727212 0.817437 0.0819474 0.825141 0 0 0 0.00281905 l
+-0.280635 -0.905405 -0.274472 -0.91482 0 0 0 0.00281905 l
+-0.280635 -0.905405 -0.302516 -0.905614 0 0 0 0.00281905 l
+-0.784068 0.508757 -0.792319 0.501497 0 0 0 0.00281905 l
+0.88865 0.195106 0.901681 0.196523 0 0 0 0.00281905 l
+0.88865 0.195106 0.887296 0.191698 0 0 0 0.00281905 l
+-0.428882 -0.333464 -0.427755 -0.327327 0 0 0 0.00281905 l
+-0.428882 -0.333464 -0.432701 -0.340521 0 0 0 0.00281905 l
+-0.27865 0.658188 -0.277091 0.655073 0 0 0 0.00281905 l
+-0.0596628 0.578087 -0.0522235 0.585466 0 0 0 0.00281905 l
+-0.239024 0.00976958 -0.228518 0.00301098 0 0 0 0.00281905 l
+-0.239024 0.00976958 -0.252668 0.00167118 0 0 0 0.00281905 l
+-0.239024 0.00976958 -0.238091 0.0127339 0 0 0 0.00281905 l
+-0.841421 0.522472 -0.824177 0.526006 0 0 0 0.00281905 l
+-0.841421 0.522472 -0.832367 0.50981 0 0 0 0.00281905 l
+-0.841421 0.522472 -0.843976 0.523075 0 0 0 0.00281905 l
+0.543017 -0.784547 0.547924 -0.778083 0 0 0 0.00281905 l
+0.287419 -0.180458 0.286321 -0.173822 0 0 0 0.00281905 l
+0.287419 -0.180458 0.300194 -0.182789 0 0 0 0.00281905 l
+-0.857591 0.212183 -0.865592 0.219871 0 0 0 0.00281905 l
+-0.857591 0.212183 -0.853043 0.211289 0 0 0 0.00281905 l
+0.78566 -0.476611 0.799544 -0.490547 0 0 0 0.00281905 l
+0.78566 -0.476611 0.786555 -0.464225 0 0 0 0.00281905 l
+-0.185318 -0.15818 -0.18837 -0.152295 0 0 0 0.00281905 l
+-0.185318 -0.15818 -0.195935 -0.16256 0 0 0 0.00281905 l
+0.324558 -0.913296 0.318511 -0.922517 0 0 0 0.00281905 l
+0.324558 -0.913296 0.330474 -0.908754 0 0 0 0.00281905 l
+0.35285 0.486876 0.358898 0.481448 0 0 0 0.00281905 l
+-0.0838997 -0.909238 -0.0733442 -0.897057 0 0 0 0.00281905 l
+0.354077 -0.188918 0.351245 -0.208525 0 0 0 0.00281905 l
+0.354077 -0.188918 0.358946 -0.176598 0 0 0 0.00281905 l
+-0.0357231 -0.348234 -0.0391124 -0.36198 0 0 0 0.00281905 l
+-0.0357231 -0.348234 -0.0222405 -0.340454 0 0 0 0.00281905 l
+-0.515718 -0.274828 -0.512238 -0.273175 0 0 0 0.00281905 l
+-0.515718 -0.274828 -0.52251 -0.277104 0 0 0 0.00281905 l
+0.427854 0.309428 0.429398 0.303165 0 0 0 0.00281905 l
+0.427854 0.309428 0.424491 0.310354 0 0 0 0.00281905 l
+0.413101 -0.888875 0.411076 -0.864195 0 0 0 0.00281905 l
+0.413101 -0.888875 0.408072 -0.893611 0 0 0 0.00281905 l
+0.0779731 0.955177 0.0786691 0.930816 0 0 0 0.00281905 l
+0.0779731 0.955177 0.0825767 0.958029 0 0 0 0.00281905 l
+0.0779731 0.955177 0.0550421 0.963334 0 0 0 0.00281905 l
+0.816093 0.300971 0.820688 0.303284 0 0 0 0.00281905 l
+0.816093 0.300971 0.810568 0.299089 0 0 0 0.00281905 l
+-0.470651 -0.218245 -0.478205 -0.227729 0 0 0 0.00281905 l
+-0.873877 0.0116112 -0.861741 0.00365199 0 0 0 0.00281905 l
+-0.873877 0.0116112 -0.877473 0.0176556 0 0 0 0.00281905 l
+0.6559 -0.184946 0.66809 -0.172299 0 0 0 0.00281905 l
+0.6559 -0.184946 0.649814 -0.178015 0 0 0 0.00281905 l
+0.6559 -0.184946 0.652912 -0.190286 0 0 0 0.00281905 l
+0.864499 -0.40857 0.873976 -0.414721 0 0 0 0.00281905 l
+0.864499 -0.40857 0.845329 -0.41322 0 0 0 0.00281905 l
+0.864499 -0.40857 0.864759 -0.40803 0 0 0 0.00281905 l
+-0.673744 0.295588 -0.675665 0.314913 0 0 0 0.00281905 l
+-0.673744 0.295588 -0.675439 0.293342 0 0 0 0.00281905 l
+-0.371631 0.0273986 -0.369777 0.0274005 0 0 0 0.00281905 l
+0.401705 0.577364 0.408156 0.574388 0 0 0 0.00281905 l
+0.401705 0.577364 0.397009 0.571335 0 0 0 0.00281905 l
+-0.205135 -0.116367 -0.214821 -0.118732 0 0 0 0.00281905 l
+-0.658915 0.254328 -0.651977 0.25292 0 0 0 0.00281905 l
+-0.658915 0.254328 -0.66926 0.27026 0 0 0 0.00281905 l
+0.448906 -0.118412 0.442514 -0.118683 0 0 0 0.00281905 l
+0.448906 -0.118412 0.452118 -0.116129 0 0 0 0.00281905 l
+0.332672 -0.372989 0.330368 -0.355955 0 0 0 0.00281905 l
+0.332672 -0.372989 0.347272 -0.372483 0 0 0 0.00281905 l
+-0.509447 0.483794 -0.509571 0.476904 0 0 0 0.00281905 l
+-0.509447 0.483794 -0.494059 0.489766 0 0 0 0.00281905 l
+-0.509447 0.483794 -0.512335 0.485376 0 0 0 0.00281905 l
+-0.263176 -0.824586 -0.268315 -0.823231 0 0 0 0.00281905 l
+-0.364941 0.53428 -0.364555 0.526779 0 0 0 0.00281905 l
+-0.364941 0.53428 -0.363512 0.54092 0 0 0 0.00281905 l
+0.0126096 0.76101 0.0257341 0.764167 0 0 0 0.00281905 l
+0.0126096 0.76101 0.000549871 0.748572 0 0 0 0.00281905 l
+0.0955106 0.659802 0.101019 0.667972 0 0 0 0.00281905 l
+0.0955106 0.659802 0.0831658 0.65422 0 0 0 0.00281905 l
+0.55099 0.42097 0.548013 0.428781 0 0 0 0.00281905 l
+-0.889898 -0.296865 -0.884183 -0.290607 0 0 0 0.00281905 l
+-0.889898 -0.296865 -0.895469 -0.300178 0 0 0 0.00281905 l
+0.316372 -0.0358121 0.309872 -0.0504843 0 0 0 0.00281905 l
+0.316372 -0.0358121 0.329007 -0.0358915 0 0 0 0.00281905 l
+0.316372 -0.0358121 0.303046 -0.0269853 0 0 0 0.00281905 l
+0.890747 -0.414611 0.882583 -0.42218 0 0 0 0.00281905 l
+0.0804247 0.242859 0.0995328 0.230874 0 0 0 0.00281905 l
+0.0804247 0.242859 0.0742174 0.251437 0 0 0 0.00281905 l
+0.0804247 0.242859 0.0744193 0.238931 0 0 0 0.00281905 l
+0.180538 0.677491 0.189964 0.674076 0 0 0 0.00281905 l
+0.180538 0.677491 0.172204 0.684997 0 0 0 0.00281905 l
+0.438294 0.582879 0.43425 0.601834 0 0 0 0.00281905 l
+0.438294 0.582879 0.450088 0.571511 0 0 0 0.00281905 l
+-0.611013 -0.0121431 -0.613143 -0.000416248 0 0 0 0.00281905 l
+-0.611013 -0.0121431 -0.599126 -0.0200293 0 0 0 0.00281905 l
+0.325664 -0.556123 0.333501 -0.543507 0 0 0 0.00281905 l
+0.325664 -0.556123 0.317542 -0.551965 0 0 0 0.00281905 l
+-0.148975 -0.142673 -0.140896 -0.11995 0 0 0 0.00281905 l
+-0.148975 -0.142673 -0.152845 -0.15105 0 0 0 0.00281905 l
+-0.568411 0.367228 -0.57715 0.350369 0 0 0 0.00281905 l
+-0.568411 0.367228 -0.55943 0.371135 0 0 0 0.00281905 l
+-0.568411 0.367228 -0.580683 0.372237 0 0 0 0.00281905 l
+-0.571217 0.547752 -0.560062 0.536728 0 0 0 0.00281905 l
+-0.571217 0.547752 -0.580113 0.558721 0 0 0 0.00281905 l
+0.0402859 0.0554464 0.0448701 0.0370715 0 0 0 0.00281905 l
+0.0402859 0.0554464 0.0239222 0.0617035 0 0 0 0.00281905 l
+-0.942273 -0.137762 -0.942832 -0.150165 0 0 0 0.00281905 l
+-0.942273 -0.137762 -0.937839 -0.131783 0 0 0 0.00281905 l
+-0.0633404 -0.340589 -0.0653536 -0.353986 0 0 0 0.00281905 l
+-0.0633404 -0.340589 -0.070794 -0.328827 0 0 0 0.00281905 l
+-0.662431 0.714714 -0.659869 0.705292 0 0 0 0.00281905 l
+-0.662431 0.714714 -0.68068 0.712579 0 0 0 0.00281905 l
+0.206638 0.420826 0.209933 0.420344 0 0 0 0.00281905 l
+0.206638 0.420826 0.199909 0.419481 0 0 0 0.00281905 l
+-0.406518 0.51009 -0.408679 0.51629 0 0 0 0.00281905 l
+-0.406518 0.51009 -0.40049 0.510975 0 0 0 0.00281905 l
+-0.406518 0.51009 -0.405152 0.505631 0 0 0 0.00281905 l
+0.355674 -0.149235 0.357444 -0.149104 0 0 0 0.00281905 l
+0.200784 -0.67561 0.196638 -0.693142 0 0 0 0.00281905 l
+0.200784 -0.67561 0.206697 -0.664915 0 0 0 0.00281905 l
+-0.777386 -0.143678 -0.779251 -0.133185 0 0 0 0.00281905 l
+-0.777386 -0.143678 -0.794968 -0.146362 0 0 0 0.00281905 l
+-0.658252 -0.351221 -0.65288 -0.35266 0 0 0 0.00281905 l
+-0.658252 -0.351221 -0.673674 -0.363505 0 0 0 0.00281905 l
+-0.0298518 0.211894 -0.0316137 0.192832 0 0 0 0.00281905 l
+-0.0298518 0.211894 -0.0161561 0.213599 0 0 0 0.00281905 l
+-0.0298518 0.211894 -0.0393383 0.215306 0 0 0 0.00281905 l
+0.133307 0.368436 0.115589 0.379409 0 0 0 0.00281905 l
+0.133307 0.368436 0.129685 0.361057 0 0 0 0.00281905 l
+-0.742278 0.0647263 -0.739033 0.058379 0 0 0 0.00281905 l
+-0.742278 0.0647263 -0.748059 0.0627779 0 0 0 0.00281905 l
+0.12259 0.722196 0.111753 0.721165 0 0 0 0.00281905 l
+0.377206 0.359339 0.390569 0.35999 0 0 0 0.00281905 l
+0.377206 0.359339 0.365757 0.371255 0 0 0 0.00281905 l
+0.495596 0.821524 0.498734 0.820436 0 0 0 0.00281905 l
+0.495596 0.821524 0.481343 0.816252 0 0 0 0.00281905 l
+0.739902 0.240474 0.744515 0.249288 0 0 0 0.00281905 l
+0.739902 0.240474 0.731073 0.249853 0 0 0 0.00281905 l
+0.739902 0.240474 0.728188 0.232755 0 0 0 0.00281905 l
+-0.622728 -0.378936 -0.60746 -0.383819 0 0 0 0.00281905 l
+-0.622728 -0.378936 -0.629221 -0.366649 0 0 0 0.00281905 l
+0.944823 -0.164494 0.948348 -0.176564 0 0 0 0.00281905 l
+0.944823 -0.164494 0.933112 -0.160806 0 0 0 0.00281905 l
+0.333196 -0.893782 0.330474 -0.908754 0 0 0 0.00281905 l
+0.333196 -0.893782 0.335273 -0.886784 0 0 0 0.00281905 l
+-0.857228 -0.330649 -0.853355 -0.327329 0 0 0 0.00281905 l
+-0.857228 -0.330649 -0.859706 -0.328201 0 0 0 0.00281905 l
+0.244489 -0.441193 0.24186 -0.425128 0 0 0 0.00281905 l
+0.244489 -0.441193 0.240197 -0.443214 0 0 0 0.00281905 l
+0.781183 -0.554729 0.796357 -0.554484 0 0 0 0.00281905 l
+0.781183 -0.554729 0.771576 -0.562159 0 0 0 0.00281905 l
+-0.236983 0.434649 -0.234565 0.439562 0 0 0 0.00281905 l
+-0.236983 0.434649 -0.233299 0.431621 0 0 0 0.00281905 l
+-0.236983 0.434649 -0.239618 0.434297 0 0 0 0.00281905 l
+-0.430225 0.213961 -0.416736 0.210163 0 0 0 0.00281905 l
+-0.430225 0.213961 -0.433085 0.201711 0 0 0 0.00281905 l
+-0.430225 0.213961 -0.427955 0.219468 0 0 0 0.00281905 l
+-0.0106223 0.105602 -0.00574395 0.085142 0 0 0 0.00281905 l
+-0.0106223 0.105602 -0.0230276 0.112986 0 0 0 0.00281905 l
+-0.284276 -0.130931 -0.269215 -0.145084 0 0 0 0.00281905 l
+-0.284276 -0.130931 -0.294523 -0.127114 0 0 0 0.00281905 l
+-0.305969 0.160879 -0.293801 0.179938 0 0 0 0.00281905 l
+-0.305969 0.160879 -0.304484 0.138749 0 0 0 0.00281905 l
+-0.305969 0.160879 -0.316689 0.16474 0 0 0 0.00281905 l
+0.711148 -0.192842 0.722765 -0.185184 0 0 0 0.00281905 l
+0.711148 -0.192842 0.71164 -0.198825 0 0 0 0.00281905 l
+0.280733 -0.335456 0.288929 -0.336095 0 0 0 0.00281905 l
+0.280733 -0.335456 0.277841 -0.341603 0 0 0 0.00281905 l
+0.280733 -0.335456 0.273853 -0.333131 0 0 0 0.00281905 l
+0.223842 0.18376 0.212972 0.164517 0 0 0 0.00281905 l
+0.223842 0.18376 0.221504 0.187709 0 0 0 0.00281905 l
+0.288098 0.562986 0.282609 0.558838 0 0 0 0.00281905 l
+0.162655 -0.405756 0.167167 -0.411072 0 0 0 0.00281905 l
+0.162655 -0.405756 0.161083 -0.405013 0 0 0 0.00281905 l
+-0.310971 -0.314509 -0.308751 -0.306904 0 0 0 0.00281905 l
+-0.310971 -0.314509 -0.308776 -0.324811 0 0 0 0.00281905 l
+0.536093 -0.0975822 0.542846 -0.0981971 0 0 0 0.00281905 l
+0.536093 -0.0975822 0.527264 -0.0945232 0 0 0 0.00281905 l
+-0.454125 -0.817719 -0.46828 -0.808865 0 0 0 0.00281905 l
+-0.454125 -0.817719 -0.444569 -0.818909 0 0 0 0.00281905 l
+-0.454125 -0.817719 -0.457782 -0.82472 0 0 0 0.00281905 l
+0.380745 -0.159776 0.389198 -0.169432 0 0 0 0.00281905 l
+0.380745 -0.159776 0.39193 -0.152982 0 0 0 0.00281905 l
+-0.201918 -0.567312 -0.203704 -0.551123 0 0 0 0.00281905 l
+-0.201918 -0.567312 -0.186383 -0.567019 0 0 0 0.00281905 l
+-0.201918 -0.567312 -0.202493 -0.580639 0 0 0 0.00281905 l
+-0.483284 -0.446923 -0.479498 -0.443917 0 0 0 0.00281905 l
+0.458926 -0.471826 0.468713 -0.469332 0 0 0 0.00281905 l
+0.458926 -0.471826 0.448406 -0.466242 0 0 0 0.00281905 l
+-0.312169 -0.148035 -0.309121 -0.14802 0 0 0 0.00281905 l
+-0.312169 -0.148035 -0.319487 -0.160023 0 0 0 0.00281905 l
+-0.829424 -0.542861 -0.811891 -0.546468 0 0 0 0.00281905 l
+-0.829424 -0.542861 -0.83843 -0.541714 0 0 0 0.00281905 l
+-0.884227 -0.00884595 -0.881043 -0.0119759 0 0 0 0.00281905 l
+-0.884227 -0.00884595 -0.891073 -0.00357615 0 0 0 0.00281905 l
+0.555481 0.166558 0.562442 0.179657 0 0 0 0.00281905 l
+0.555481 0.166558 0.541785 0.165981 0 0 0 0.00281905 l
+0.173683 0.598534 0.183955 0.610026 0 0 0 0.00281905 l
+0.173683 0.598534 0.169908 0.59707 0 0 0 0.00281905 l
+0.540054 0.29944 0.548264 0.285955 0 0 0 0.00281905 l
+0.540054 0.29944 0.525038 0.295428 0 0 0 0.00281905 l
+-0.146857 0.930381 -0.151414 0.926282 0 0 0 0.00281905 l
+-0.146857 0.930381 -0.152207 0.933929 0 0 0 0.00281905 l
+0.319327 0.0353932 0.326571 0.0222512 0 0 0 0.00281905 l
+0.319327 0.0353932 0.332582 0.0426953 0 0 0 0.00281905 l
+0.711151 -0.045666 0.725093 -0.047359 0 0 0 0.00281905 l
+-0.465214 -0.200721 -0.454281 -0.212226 0 0 0 0.00281905 l
+-0.465214 -0.200721 -0.46137 -0.183794 0 0 0 0.00281905 l
+0.002285 0.618907 0.00238574 0.622497 0 0 0 0.00281905 l
+0.0681678 0.334997 0.0697739 0.34719 0 0 0 0.00281905 l
+0.0681678 0.334997 0.059482 0.332173 0 0 0 0.00281905 l
+-0.680662 -0.589476 -0.678578 -0.589335 0 0 0 0.00281905 l
+-0.155611 0.7722 -0.153893 0.764626 0 0 0 0.00281905 l
+-0.155611 0.7722 -0.171376 0.777961 0 0 0 0.00281905 l
+-0.592309 0.782161 -0.605271 0.773787 0 0 0 0.00281905 l
+-0.592309 0.782161 -0.598433 0.78984 0 0 0 0.00281905 l
+0.234619 0.0197603 0.235979 0.0300127 0 0 0 0.00281905 l
+0.234619 0.0197603 0.225665 0.0102632 0 0 0 0.00281905 l
+0.38624 0.772718 0.387118 0.785956 0 0 0 0.00281905 l
+0.38624 0.772718 0.393776 0.769831 0 0 0 0.00281905 l
+0.38624 0.772718 0.370553 0.761681 0 0 0 0.00281905 l
+-0.183966 -0.92969 -0.178867 -0.907092 0 0 0 0.00281905 l
+-0.356936 0.489893 -0.335999 0.483683 0 0 0 0.00281905 l
+-0.356936 0.489893 -0.371659 0.499413 0 0 0 0.00281905 l
+-0.0695536 -0.689133 -0.0638563 -0.680541 0 0 0 0.00281905 l
+-0.0695536 -0.689133 -0.0763677 -0.681176 0 0 0 0.00281905 l
+-0.35662 -0.118325 -0.358805 -0.104151 0 0 0 0.00281905 l
+-0.35662 -0.118325 -0.350309 -0.13245 0 0 0 0.00281905 l
+0.176014 -0.0790242 0.188143 -0.0920435 0 0 0 0.00281905 l
+0.176014 -0.0790242 0.170843 -0.0841323 0 0 0 0.00281905 l
+-0.373027 -0.528885 -0.369838 -0.530501 0 0 0 0.00281905 l
+-0.373027 -0.528885 -0.380502 -0.520625 0 0 0 0.00281905 l
+-0.373027 -0.528885 -0.369098 -0.52461 0 0 0 0.00281905 l
+-0.538273 -0.187557 -0.534629 -0.178345 0 0 0 0.00281905 l
+-0.538273 -0.187557 -0.549737 -0.182691 0 0 0 0.00281905 l
+0.150428 0.399639 0.161331 0.39989 0 0 0 0.00281905 l
+0.150428 0.399639 0.139506 0.410658 0 0 0 0.00281905 l
+-0.686954 -0.238867 -0.680305 -0.234959 0 0 0 0.00281905 l
+-0.686954 -0.238867 -0.69185 -0.235383 0 0 0 0.00281905 l
+0.199684 -0.309589 0.195911 -0.320588 0 0 0 0.00281905 l
+0.199684 -0.309589 0.183864 -0.298683 0 0 0 0.00281905 l
+0.127092 -0.225204 0.136857 -0.22625 0 0 0 0.00281905 l
+0.127092 -0.225204 0.115457 -0.225291 0 0 0 0.00281905 l
+-0.401378 0.285835 -0.395402 0.29444 0 0 0 0.00281905 l
+-0.401378 0.285835 -0.40092 0.279217 0 0 0 0.00281905 l
+-0.401378 0.285835 -0.404415 0.286519 0 0 0 0.00281905 l
+-0.229596 -0.18988 -0.229432 -0.176083 0 0 0 0.00281905 l
+-0.229596 -0.18988 -0.230188 -0.20267 0 0 0 0.00281905 l
+-0.325779 0.265193 -0.314879 0.251368 0 0 0 0.00281905 l
+-0.325779 0.265193 -0.322074 0.272767 0 0 0 0.00281905 l
+-0.208472 -0.619402 -0.193575 -0.627186 0 0 0 0.00281905 l
+-0.208472 -0.619402 -0.211846 -0.616792 0 0 0 0.00281905 l
+0.726658 -0.0106861 0.732669 -0.0278845 0 0 0 0.00281905 l
+0.726658 -0.0106861 0.726658 -0.00353304 0 0 0 0.00281905 l
+0.726658 -0.0106861 0.732715 -0.00948405 0 0 0 0.00281905 l
+-0.787762 0.314705 -0.77532 0.328484 0 0 0 0.00281905 l
+-0.787762 0.314705 -0.796864 0.327548 0 0 0 0.00281905 l
+-0.787762 0.314705 -0.786604 0.312412 0 0 0 0.00281905 l
+-0.116396 0.989493 -0.11197 0.977427 0 0 0 0.00281905 l
+-0.475281 0.73422 -0.464725 0.754014 0 0 0 0.00281905 l
+-0.475281 0.73422 -0.461259 0.730063 0 0 0 0.00281905 l
+0.913889 -0.292964 0.914891 -0.305581 0 0 0 0.00281905 l
+0.913889 -0.292964 0.921171 -0.289583 0 0 0 0.00281905 l
+-0.0165022 -0.872368 -0.0129921 -0.885685 0 0 0 0.00281905 l
+-0.0165022 -0.872368 -0.0166758 -0.856668 0 0 0 0.00281905 l
+0.083954 0.437223 0.0823872 0.420038 0 0 0 0.00281905 l
+0.083954 0.437223 0.068162 0.432919 0 0 0 0.00281905 l
+0.452465 0.22766 0.46001 0.243729 0 0 0 0.00281905 l
+0.452465 0.22766 0.447924 0.218862 0 0 0 0.00281905 l
+0.387968 0.79142 0.387118 0.785956 0 0 0 0.00281905 l
+0.387968 0.79142 0.38508 0.793964 0 0 0 0.00281905 l
+0.138675 -0.611083 0.147938 -0.605466 0 0 0 0.00281905 l
+0.138675 -0.611083 0.136678 -0.618677 0 0 0 0.00281905 l
+-0.275134 -0.744407 -0.281677 -0.74759 0 0 0 0.00281905 l
+-0.16383 0.728902 -0.167364 0.735449 0 0 0 0.00281905 l
+-0.16383 0.728902 -0.157312 0.722883 0 0 0 0.00281905 l
+0.29877 -0.306927 0.298178 -0.30823 0 0 0 0.00281905 l
+0.873976 -0.414721 0.879112 -0.412237 0 0 0 0.00281905 l
+0.873976 -0.414721 0.864499 -0.40857 0 0 0 0.00281905 l
+0.234598 0.380948 0.233982 0.360308 0 0 0 0.00281905 l
+0.234598 0.380948 0.233576 0.392689 0 0 0 0.00281905 l
+0.289356 0.0748388 0.305613 0.0735602 0 0 0 0.00281905 l
+0.289356 0.0748388 0.293983 0.0575007 0 0 0 0.00281905 l
+-0.282425 -0.936414 -0.284736 -0.932627 0 0 0 0.00281905 l
+-0.282425 -0.936414 -0.266255 -0.953115 0 0 0 0.00281905 l
+-0.599347 -0.478608 -0.595028 -0.481125 0 0 0 0.00281905 l
+-0.599347 -0.478608 -0.597708 -0.476284 0 0 0 0.00281905 l
+0.0535707 -0.531069 0.0623154 -0.532317 0 0 0 0.00281905 l
+0.530515 0.679786 0.5287 0.670301 0 0 0 0.00281905 l
+0.530515 0.679786 0.530487 0.703647 0 0 0 0.00281905 l
+-0.473713 -0.740404 -0.469455 -0.756369 0 0 0 0.00281905 l
+-0.473713 -0.740404 -0.47511 -0.734888 0 0 0 0.00281905 l
+0.0418622 0.237817 0.0511689 0.227821 0 0 0 0.00281905 l
+0.0418622 0.237817 0.0260782 0.252738 0 0 0 0.00281905 l
+0.726658 -0.00353304 0.726658 -0.0106861 0 0 0 0.00281905 l
+0.726658 -0.00353304 0.720538 0.00547182 0 0 0 0.00281905 l
+-0.294171 0.321321 -0.302069 0.32797 0 0 0 0.00281905 l
+-0.0756769 -0.538044 -0.0630525 -0.536465 0 0 0 0.00281905 l
+-0.0756769 -0.538044 -0.0783426 -0.53355 0 0 0 0.00281905 l
+-0.835377 -0.281141 -0.840233 -0.302678 0 0 0 0.00281905 l
+-0.835377 -0.281141 -0.844062 -0.276128 0 0 0 0.00281905 l
+-0.48651 0.671979 -0.487535 0.657567 0 0 0 0.00281905 l
+-0.48651 0.671979 -0.480281 0.674573 0 0 0 0.00281905 l
+0.27023 -0.452597 0.268725 -0.438228 0 0 0 0.00281905 l
+0.160475 0.609493 0.169908 0.59707 0 0 0 0.00281905 l
+0.160475 0.609493 0.148894 0.618869 0 0 0 0.00281905 l
+0.744215 -0.148421 0.745363 -0.16276 0 0 0 0.00281905 l
+0.744215 -0.148421 0.755606 -0.140581 0 0 0 0.00281905 l
+0.744215 -0.148421 0.737944 -0.138871 0 0 0 0.00281905 l
+-0.474916 0.410385 -0.462454 0.419633 0 0 0 0.00281905 l
+-0.474916 0.410385 -0.463433 0.403136 0 0 0 0.00281905 l
+-0.474916 0.410385 -0.478655 0.419513 0 0 0 0.00281905 l
+0.44212 -0.26106 0.448658 -0.245409 0 0 0 0.00281905 l
+0.44212 -0.26106 0.450681 -0.268341 0 0 0 0.00281905 l
+0.44212 -0.26106 0.439783 -0.260834 0 0 0 0.00281905 l
+0.255989 0.912561 0.270471 0.907649 0 0 0 0.00281905 l
+0.255989 0.912561 0.251627 0.897977 0 0 0 0.00281905 l
+0.255989 0.912561 0.26101 0.921674 0 0 0 0.00281905 l
+0.0984581 -0.38304 0.0932169 -0.368894 0 0 0 0.00281905 l
+0.0984581 -0.38304 0.1048 -0.385723 0 0 0 0.00281905 l
+-0.102639 -0.111258 -0.0982648 -0.0988496 0 0 0 0.00281905 l
+-0.102639 -0.111258 -0.112119 -0.119998 0 0 0 0.00281905 l
+0.597771 -0.399542 0.59351 -0.378382 0 0 0 0.00281905 l
+0.190532 0.603587 0.193578 0.605487 0 0 0 0.00281905 l
+0.190532 0.603587 0.183955 0.610026 0 0 0 0.00281905 l
+-0.369838 -0.530501 -0.363046 -0.531368 0 0 0 0.00281905 l
+-0.369838 -0.530501 -0.373027 -0.528885 0 0 0 0.00281905 l
+-0.3333 -0.300746 -0.335551 -0.289702 0 0 0 0.00281905 l
+-0.3333 -0.300746 -0.336802 -0.317362 0 0 0 0.00281905 l
+-0.179799 0.83765 -0.192245 0.853843 0 0 0 0.00281905 l
+-0.179799 0.83765 -0.178422 0.834705 0 0 0 0.00281905 l
+-0.179799 0.83765 -0.197607 0.828013 0 0 0 0.00281905 l
+0.794321 -0.117049 0.792143 -0.131356 0 0 0 0.00281905 l
+0.794321 -0.117049 0.798083 -0.111485 0 0 0 0.00281905 l
+0.791534 0.136547 0.790301 0.144134 0 0 0 0.00281905 l
+0.791534 0.136547 0.789172 0.135122 0 0 0 0.00281905 l
+0.654161 0.0683734 0.653338 0.0835046 0 0 0 0.00281905 l
+0.654161 0.0683734 0.657276 0.0673793 0 0 0 0.00281905 l
+0.654161 0.0683734 0.641278 0.0609624 0 0 0 0.00281905 l
+-0.721566 -0.535093 -0.724206 -0.543572 0 0 0 0.00281905 l
+-0.721566 -0.535093 -0.717009 -0.532539 0 0 0 0.00281905 l
+0.176777 0.140502 0.181854 0.128919 0 0 0 0.00281905 l
+0.176777 0.140502 0.174931 0.150551 0 0 0 0.00281905 l
+0.068162 0.432919 0.083954 0.437223 0 0 0 0.00281905 l
+0.068162 0.432919 0.059776 0.421073 0 0 0 0.00281905 l
+0.068162 0.432919 0.0573474 0.441591 0 0 0 0.00281905 l
+-0.310734 -0.944469 -0.304081 -0.952198 0 0 0 0.00281905 l
+-0.310734 -0.944469 -0.315088 -0.944697 0 0 0 0.00281905 l
+0.713911 -0.646336 0.721115 -0.646881 0 0 0 0.00281905 l
+0.316132 -0.638902 0.307061 -0.641291 0 0 0 0.00281905 l
+0.316132 -0.638902 0.314845 -0.635999 0 0 0 0.00281905 l
+0.459135 -0.126023 0.452118 -0.116129 0 0 0 0.00281905 l
+0.459135 -0.126023 0.460559 -0.13698 0 0 0 0.00281905 l
+-0.354072 -0.850903 -0.349231 -0.855393 0 0 0 0.00281905 l
+-0.354072 -0.850903 -0.358621 -0.851975 0 0 0 0.00281905 l
+-0.0438041 -0.957622 -0.0343855 -0.96771 0 0 0 0.00281905 l
+-0.0438041 -0.957622 -0.0459058 -0.958106 0 0 0 0.00281905 l
+0.365112 0.48062 0.365324 0.483602 0 0 0 0.00281905 l
+0.365112 0.48062 0.383358 0.469749 0 0 0 0.00281905 l
+0.365112 0.48062 0.358898 0.481448 0 0 0 0.00281905 l
+0.0719817 -0.264261 0.0829917 -0.275024 0 0 0 0.00281905 l
+0.0719817 -0.264261 0.0603967 -0.267275 0 0 0 0.00281905 l
+0.262251 -0.842054 0.258928 -0.857938 0 0 0 0.00281905 l
+0.262251 -0.842054 0.256423 -0.833626 0 0 0 0.00281905 l
+-0.0671279 -0.296162 -0.076085 -0.276345 0 0 0 0.00281905 l
+-0.0671279 -0.296162 -0.0518368 -0.312598 0 0 0 0.00281905 l
+0.408066 0.0937854 0.411634 0.108271 0 0 0 0.00281905 l
+0.408066 0.0937854 0.403989 0.0916956 0 0 0 0.00281905 l
+0.551792 0.194629 0.552909 0.20062 0 0 0 0.00281905 l
+0.551792 0.194629 0.549905 0.182243 0 0 0 0.00281905 l
+0.69908 -0.305671 0.70289 -0.291814 0 0 0 0.00281905 l
+0.69908 -0.305671 0.696371 -0.316729 0 0 0 0.00281905 l
+0.69908 -0.305671 0.69116 -0.305378 0 0 0 0.00281905 l
+0.0862134 0.140535 0.0881119 0.132518 0 0 0 0.00281905 l
+0.0862134 0.140535 0.0811118 0.138269 0 0 0 0.00281905 l
+0.140396 0.533394 0.127751 0.547963 0 0 0 0.00281905 l
+0.140396 0.533394 0.134447 0.525127 0 0 0 0.00281905 l
+-0.197607 0.828013 -0.179799 0.83765 0 0 0 0.00281905 l
+-0.197607 0.828013 -0.205557 0.820863 0 0 0 0.00281905 l
+0.057302 -0.203303 0.0578319 -0.204478 0 0 0 0.00281905 l
+0.057302 -0.203303 0.0424135 -0.197435 0 0 0 0.00281905 l
+0.0607803 0.876963 0.0594682 0.87758 0 0 0 0.00281905 l
+0.357795 0.433505 0.342469 0.44431 0 0 0 0.00281905 l
+0.363134 0.203816 0.364509 0.210525 0 0 0 0.00281905 l
+0.363134 0.203816 0.369379 0.189056 0 0 0 0.00281905 l
+0.363134 0.203816 0.352261 0.191609 0 0 0 0.00281905 l
+-0.557523 -0.283606 -0.539033 -0.284288 0 0 0 0.00281905 l
+-0.557523 -0.283606 -0.571152 -0.293083 0 0 0 0.00281905 l
+-0.327799 -0.780081 -0.318288 -0.798664 0 0 0 0.00281905 l
+-0.327799 -0.780081 -0.309123 -0.76356 0 0 0 0.00281905 l
+-0.156137 0.148232 -0.147938 0.158703 0 0 0 0.00281905 l
+-0.156137 0.148232 -0.166782 0.141561 0 0 0 0.00281905 l
+-0.454936 -0.127128 -0.438709 -0.119845 0 0 0 0.00281905 l
+-0.454936 -0.127128 -0.449746 -0.137896 0 0 0 0.00281905 l
+0.0409017 -0.320211 0.040672 -0.340377 0 0 0 0.00281905 l
+0.0409017 -0.320211 0.0326577 -0.320622 0 0 0 0.00281905 l
+-0.25233 0.288453 -0.241066 0.283955 0 0 0 0.00281905 l
+-0.25233 0.288453 -0.256893 0.298169 0 0 0 0.00281905 l
+-0.118973 0.609435 -0.107879 0.597322 0 0 0 0.00281905 l
+-0.118973 0.609435 -0.12631 0.608985 0 0 0 0.00281905 l
+-0.367107 0.362705 -0.367419 0.374032 0 0 0 0.00281905 l
+-0.367107 0.362705 -0.360712 0.358066 0 0 0 0.00281905 l
+-0.367107 0.362705 -0.375844 0.357342 0 0 0 0.00281905 l
+0.547688 -0.603287 0.561593 -0.619813 0 0 0 0.00281905 l
+0.547688 -0.603287 0.547444 -0.592761 0 0 0 0.00281905 l
+0.547688 -0.603287 0.533996 -0.622429 0 0 0 0.00281905 l
+0.602739 -0.606155 0.611803 -0.595518 0 0 0 0.00281905 l
+0.602739 -0.606155 0.595823 -0.615662 0 0 0 0.00281905 l
+-0.818235 0.262678 -0.811576 0.257864 0 0 0 0.00281905 l
+-0.818235 0.262678 -0.828208 0.27308 0 0 0 0.00281905 l
+-0.818235 0.262678 -0.82046 0.260705 0 0 0 0.00281905 l
+0.18512 0.732618 0.17334 0.730685 0 0 0 0.00281905 l
+0.747678 -0.338191 0.745713 -0.348265 0 0 0 0.00281905 l
+0.747678 -0.338191 0.757346 -0.3361 0 0 0 0.00281905 l
+0.747678 -0.338191 0.733725 -0.332131 0 0 0 0.00281905 l
+0.608427 -0.175089 0.616806 -0.188923 0 0 0 0.00281905 l
+0.608427 -0.175089 0.615717 -0.163799 0 0 0 0.00281905 l
+-0.402748 -0.471189 -0.417644 -0.452815 0 0 0 0.00281905 l
+-0.402748 -0.471189 -0.402202 -0.472281 0 0 0 0.00281905 l
+0.0323967 0.316593 0.0311067 0.333075 0 0 0 0.00281905 l
+0.0323967 0.316593 0.0423077 0.307247 0 0 0 0.00281905 l
+0.0323967 0.316593 0.017707 0.31117 0 0 0 0.00281905 l
+0.695342 -0.322766 0.696371 -0.316729 0 0 0 0.00281905 l
+0.695342 -0.322766 0.693114 -0.323452 0 0 0 0.00281905 l
+-0.33804 0.409234 -0.329793 0.422705 0 0 0 0.00281905 l
+-0.33804 0.409234 -0.353341 0.412346 0 0 0 0.00281905 l
+0.685734 0.398952 0.688265 0.402207 0 0 0 0.00281905 l
+0.00987967 -0.520014 0.0174979 -0.503064 0 0 0 0.00281905 l
+0.00987967 -0.520014 0.00825097 -0.534565 0 0 0 0.00281905 l
+0.506458 -0.139527 0.50893 -0.13706 0 0 0 0.00281905 l
+-0.787993 -0.261667 -0.790133 -0.256539 0 0 0 0.00281905 l
+0.72696 0.0193843 0.724444 0.0253599 0 0 0 0.00281905 l
+0.72696 0.0193843 0.736871 0.0210706 0 0 0 0.00281905 l
+-0.0990284 0.687836 -0.0932397 0.680809 0 0 0 0.00281905 l
+0.528491 0.646506 0.524114 0.638491 0 0 0 0.00281905 l
+0.408072 -0.893611 0.413101 -0.888875 0 0 0 0.00281905 l
+0.408072 -0.893611 0.415424 -0.89981 0 0 0 0.00281905 l
+0.408072 -0.893611 0.405161 -0.891598 0 0 0 0.00281905 l
+0.198149 -0.652933 0.208526 -0.659575 0 0 0 0.00281905 l
+0.198149 -0.652933 0.189133 -0.644477 0 0 0 0.00281905 l
+0.824022 -0.541012 0.843877 -0.533248 0 0 0 0.00281905 l
+-0.373469 0.27991 -0.355602 0.285015 0 0 0 0.00281905 l
+-0.40498 -0.546262 -0.408887 -0.535474 0 0 0 0.00281905 l
+-0.40498 -0.546262 -0.396734 -0.553012 0 0 0 0.00281905 l
+0.424031 0.683449 0.412389 0.685282 0 0 0 0.00281905 l
+-0.682858 0.293927 -0.675439 0.293342 0 0 0 0.00281905 l
+-0.13529 -0.76517 -0.136718 -0.770993 0 0 0 0.00281905 l
+-0.13529 -0.76517 -0.14014 -0.764077 0 0 0 0.00281905 l
+0.917445 -0.256943 0.919859 -0.24223 0 0 0 0.00281905 l
+-0.695532 0.629578 -0.692255 0.637237 0 0 0 0.00281905 l
+-0.695532 0.629578 -0.68958 0.623633 0 0 0 0.00281905 l
+-0.695532 0.629578 -0.70566 0.634924 0 0 0 0.00281905 l
+-0.33289 -0.741811 -0.310403 -0.743714 0 0 0 0.00281905 l
+-0.33289 -0.741811 -0.351745 -0.730957 0 0 0 0.00281905 l
+0.744607 0.134864 0.755244 0.134949 0 0 0 0.00281905 l
+0.744607 0.134864 0.739514 0.138004 0 0 0 0.00281905 l
+-0.245788 -0.472229 -0.244068 -0.47413 0 0 0 0.00281905 l
+-0.245788 -0.472229 -0.252748 -0.468563 0 0 0 0.00281905 l
+0.356869 -0.695143 0.359743 -0.693365 0 0 0 0.00281905 l
+0.356869 -0.695143 0.364127 -0.704402 0 0 0 0.00281905 l
+0.448658 -0.245409 0.44212 -0.26106 0 0 0 0.00281905 l
+0.521323 0.0865356 0.533554 0.0691592 0 0 0 0.00281905 l
+0.521323 0.0865356 0.52433 0.10176 0 0 0 0.00281905 l
+-0.165193 -0.204005 -0.175209 -0.192221 0 0 0 0.00281905 l
+-0.165193 -0.204005 -0.153992 -0.198208 0 0 0 0.00281905 l
+-0.165193 -0.204005 -0.155523 -0.212985 0 0 0 0.00281905 l
+-0.472082 0.014812 -0.475921 0.0140014 0 0 0 0.00281905 l
+-0.0794952 -0.738284 -0.0690446 -0.734171 0 0 0 0.00281905 l
+-0.0794952 -0.738284 -0.077214 -0.745015 0 0 0 0.00281905 l
+-0.0794952 -0.738284 -0.0970644 -0.739787 0 0 0 0.00281905 l
+-0.230335 0.237322 -0.219244 0.2327 0 0 0 0.00281905 l
+-0.230335 0.237322 -0.236085 0.238986 0 0 0 0.00281905 l
+0.148441 -0.918568 0.154088 -0.904832 0 0 0 0.00281905 l
+0.148441 -0.918568 0.135028 -0.913721 0 0 0 0.00281905 l
+-0.0689616 0.395774 -0.0638413 0.392135 0 0 0 0.00281905 l
+-0.0689616 0.395774 -0.0816311 0.400133 0 0 0 0.00281905 l
+0.587345 0.601078 0.594736 0.600998 0 0 0 0.00281905 l
+0.587345 0.601078 0.576371 0.602917 0 0 0 0.00281905 l
+0.764574 -0.557277 0.766365 -0.543123 0 0 0 0.00281905 l
+0.764574 -0.557277 0.771576 -0.562159 0 0 0 0.00281905 l
+-0.783105 0.0946519 -0.79091 0.0824744 0 0 0 0.00281905 l
+-0.681529 0.400717 -0.680053 0.393509 0 0 0 0.00281905 l
+-0.681529 0.400717 -0.672491 0.403605 0 0 0 0.00281905 l
+-0.115625 -0.305908 -0.108028 -0.296534 0 0 0 0.00281905 l
+-0.325285 0.338269 -0.325909 0.342977 0 0 0 0.00281905 l
+-0.325285 0.338269 -0.34242 0.332796 0 0 0 0.00281905 l
+-0.606708 -0.187357 -0.590825 -0.187286 0 0 0 0.00281905 l
+-0.606708 -0.187357 -0.614974 -0.184413 0 0 0 0.00281905 l
+-0.197342 -0.242671 -0.181904 -0.247208 0 0 0 0.00281905 l
+-0.197342 -0.242671 -0.208554 -0.238499 0 0 0 0.00281905 l
+-0.207062 -0.279514 -0.207961 -0.272411 0 0 0 0.00281905 l
+-0.207062 -0.279514 -0.204401 -0.283186 0 0 0 0.00281905 l
+0.0656404 0.674602 0.0658642 0.662871 0 0 0 0.00281905 l
+0.0656404 0.674602 0.0582546 0.674468 0 0 0 0.00281905 l
+-0.538638 -0.287643 -0.539033 -0.284288 0 0 0 0.00281905 l
+-0.540642 0.5492 -0.536139 0.552827 0 0 0 0.00281905 l
+-0.311762 -0.251364 -0.305185 -0.257339 0 0 0 0.00281905 l
+-0.311762 -0.251364 -0.321632 -0.239038 0 0 0 0.00281905 l
+-0.137084 0.875066 -0.140702 0.892217 0 0 0 0.00281905 l
+-0.137084 0.875066 -0.123125 0.87351 0 0 0 0.00281905 l
+-0.137084 0.875066 -0.138862 0.860333 0 0 0 0.00281905 l
+0.567084 -0.489137 0.569441 -0.476936 0 0 0 0.00281905 l
+0.567084 -0.489137 0.570585 -0.500126 0 0 0 0.00281905 l
+0.567084 -0.489137 0.558095 -0.485132 0 0 0 0.00281905 l
+0.613926 0.33196 0.622638 0.345301 0 0 0 0.00281905 l
+0.613926 0.33196 0.628794 0.324449 0 0 0 0.00281905 l
+0.613926 0.33196 0.6088 0.326778 0 0 0 0.00281905 l
+0.0754052 0.135926 0.0681839 0.148208 0 0 0 0.00281905 l
+0.0754052 0.135926 0.0811118 0.138269 0 0 0 0.00281905 l
+0.0754052 0.135926 0.0582615 0.131091 0 0 0 0.00281905 l
+-0.190485 0.885841 -0.185429 0.871619 0 0 0 0.00281905 l
+-0.190485 0.885841 -0.191317 0.887829 0 0 0 0.00281905 l
+0.253132 -0.0840502 0.256347 -0.0677364 0 0 0 0.00281905 l
+0.253132 -0.0840502 0.249012 -0.0854829 0 0 0 0.00281905 l
+0.579974 0.0374239 0.580282 0.0317056 0 0 0 0.00281905 l
+0.579974 0.0374239 0.578227 0.0426273 0 0 0 0.00281905 l
+-0.216387 -0.344215 -0.201991 -0.334177 0 0 0 0.00281905 l
+-0.216387 -0.344215 -0.2266 -0.351837 0 0 0 0.00281905 l
+0.0761971 0.0401935 0.0879119 0.0484809 0 0 0 0.00281905 l
+0.0761971 0.0401935 0.069611 0.0294489 0 0 0 0.00281905 l
+0.867832 -0.0208838 0.86534 -0.030318 0 0 0 0.00281905 l
+0.867832 -0.0208838 0.867316 -0.0203235 0 0 0 0.00281905 l
+0.0407204 0.690664 0.0493959 0.699749 0 0 0 0.00281905 l
+0.0407204 0.690664 0.0345962 0.701747 0 0 0 0.00281905 l
+0.374242 0.338368 0.381794 0.342803 0 0 0 0.00281905 l
+0.374242 0.338368 0.383683 0.328034 0 0 0 0.00281905 l
+0.374242 0.338368 0.359205 0.340136 0 0 0 0.00281905 l
+0.0891672 0.707587 0.102008 0.706537 0 0 0 0.00281905 l
+0.0891672 0.707587 0.0865911 0.701048 0 0 0 0.00281905 l
+0.0891672 0.707587 0.0829608 0.715401 0 0 0 0.00281905 l
+-0.514618 -0.557571 -0.507454 -0.574217 0 0 0 0.00281905 l
+-0.514618 -0.557571 -0.502659 -0.553607 0 0 0 0.00281905 l
+-0.514618 -0.557571 -0.530217 -0.568193 0 0 0 0.00281905 l
+0.678419 -0.469666 0.694835 -0.479655 0 0 0 0.00281905 l
+0.678419 -0.469666 0.675198 -0.463127 0 0 0 0.00281905 l
+0.212972 0.164517 0.223842 0.18376 0 0 0 0.00281905 l
+0.313325 -0.895207 0.307161 -0.911254 0 0 0 0.00281905 l
+0.313325 -0.895207 0.301657 -0.884231 0 0 0 0.00281905 l
+0.313325 -0.895207 0.314536 -0.894312 0 0 0 0.00281905 l
+0.74593 -0.665095 0.751082 -0.649217 0 0 0 0.00281905 l
+0.74593 -0.665095 0.738918 -0.664508 0 0 0 0.00281905 l
+-0.232072 0.136271 -0.224241 0.12919 0 0 0 0.00281905 l
+-0.232072 0.136271 -0.242661 0.138996 0 0 0 0.00281905 l
+0.0951225 0.733274 0.0983228 0.746278 0 0 0 0.00281905 l
+0.0951225 0.733274 0.107425 0.732874 0 0 0 0.00281905 l
+0.363011 0.0600105 0.357941 0.0744603 0 0 0 0.00281905 l
+0.363011 0.0600105 0.366755 0.0550387 0 0 0 0.00281905 l
+-0.0383389 0.0423419 -0.0436304 0.0340249 0 0 0 0.00281905 l
+0.440848 0.417584 0.453306 0.406275 0 0 0 0.00281905 l
+0.440848 0.417584 0.447568 0.429806 0 0 0 0.00281905 l
+0.219363 -0.600191 0.224697 -0.6049 0 0 0 0.00281905 l
+0.219363 -0.600191 0.201598 -0.588095 0 0 0 0.00281905 l
+-0.309985 -0.746704 -0.309123 -0.76356 0 0 0 0.00281905 l
+-0.309985 -0.746704 -0.310403 -0.743714 0 0 0 0.00281905 l
+0.33991 -0.226179 0.344723 -0.218604 0 0 0 0.00281905 l
+0.33991 -0.226179 0.349471 -0.237616 0 0 0 0.00281905 l
+0.255973 -0.682443 0.261222 -0.693823 0 0 0 0.00281905 l
+0.255973 -0.682443 0.266552 -0.671087 0 0 0 0.00281905 l
+0.255973 -0.682443 0.244565 -0.683838 0 0 0 0.00281905 l
+-0.511532 -0.260289 -0.512238 -0.273175 0 0 0 0.00281905 l
+-0.511532 -0.260289 -0.516419 -0.258015 0 0 0 0.00281905 l
+0.801265 0.356477 0.816603 0.356582 0 0 0 0.00281905 l
+-0.0901915 0.505453 -0.0766167 0.511444 0 0 0 0.00281905 l
+-0.0901915 0.505453 -0.101502 0.50785 0 0 0 0.00281905 l
+0.812243 0.371146 0.818313 0.374084 0 0 0 0.00281905 l
+0.812243 0.371146 0.814381 0.366699 0 0 0 0.00281905 l
+0.522067 -0.651999 0.532209 -0.652247 0 0 0 0.00281905 l
+0.522067 -0.651999 0.516224 -0.646126 0 0 0 0.00281905 l
+0.229957 0.10223 0.217569 0.115464 0 0 0 0.00281905 l
+0.229957 0.10223 0.229261 0.100429 0 0 0 0.00281905 l
+-0.114437 0.820214 -0.120907 0.827427 0 0 0 0.00281905 l
+-0.114437 0.820214 -0.096476 0.822132 0 0 0 0.00281905 l
+-0.914069 -0.35129 -0.915991 -0.36293 0 0 0 0.00281905 l
+-0.914069 -0.35129 -0.91995 -0.338815 0 0 0 0.00281905 l
+0.255052 -0.706085 0.256388 -0.700134 0 0 0 0.00281905 l
+0.255052 -0.706085 0.254677 -0.708516 0 0 0 0.00281905 l
+0.536327 -0.228528 0.533341 -0.211796 0 0 0 0.00281905 l
+0.536327 -0.228528 0.529409 -0.233409 0 0 0 0.00281905 l
+0.397841 0.0114409 0.393669 0.000324163 0 0 0 0.00281905 l
+0.397841 0.0114409 0.403434 0.0139576 0 0 0 0.00281905 l
+0.397841 0.0114409 0.390331 0.0193567 0 0 0 0.00281905 l
+0.417959 0.0667413 0.421202 0.0555981 0 0 0 0.00281905 l
+0.417959 0.0667413 0.425206 0.0767722 0 0 0 0.00281905 l
+0.666031 0.475121 0.674133 0.473402 0 0 0 0.00281905 l
+0.666031 0.475121 0.664129 0.478442 0 0 0 0.00281905 l
+0.57094 -0.597447 0.584545 -0.590198 0 0 0 0.00281905 l
+0.57094 -0.597447 0.573572 -0.608778 0 0 0 0.00281905 l
+-0.199851 -0.65383 -0.184919 -0.656242 0 0 0 0.00281905 l
+-0.199851 -0.65383 -0.202566 -0.661997 0 0 0 0.00281905 l
+-0.199851 -0.65383 -0.208573 -0.647957 0 0 0 0.00281905 l
+-0.116915 -0.840728 -0.103943 -0.850149 0 0 0 0.00281905 l
+-0.116915 -0.840728 -0.125886 -0.836091 0 0 0 0.00281905 l
+-0.539605 -0.513836 -0.534944 -0.531927 0 0 0 0.00281905 l
+-0.392769 0.124391 -0.390638 0.13884 0 0 0 0.00281905 l
+0.520137 0.4579 0.525091 0.464665 0 0 0 0.00281905 l
+0.520137 0.4579 0.517393 0.454175 0 0 0 0.00281905 l
+-0.354134 0.649266 -0.343115 0.656944 0 0 0 0.00281905 l
+-0.354134 0.649266 -0.350996 0.642759 0 0 0 0.00281905 l
+-0.673463 0.552609 -0.668451 0.535473 0 0 0 0.00281905 l
+-0.673463 0.552609 -0.684793 0.567328 0 0 0 0.00281905 l
+0.087134 -0.0525296 0.0989089 -0.050982 0 0 0 0.00281905 l
+0.087134 -0.0525296 0.0761579 -0.03983 0 0 0 0.00281905 l
+0.748399 -0.50406 0.754584 -0.511191 0 0 0 0.00281905 l
+0.748399 -0.50406 0.737428 -0.502341 0 0 0 0.00281905 l
+0.429398 0.303165 0.427854 0.309428 0 0 0 0.00281905 l
+0.429398 0.303165 0.435434 0.299367 0 0 0 0.00281905 l
+0.281261 -0.921097 0.27902 -0.908251 0 0 0 0.00281905 l
+0.773545 0.396092 0.775387 0.380766 0 0 0 0.00281905 l
+0.773545 0.396092 0.773631 0.397263 0 0 0 0.00281905 l
+0.34369 -0.626307 0.357066 -0.601062 0 0 0 0.00281905 l
+0.34369 -0.626307 0.351796 -0.639906 0 0 0 0.00281905 l
+0.34369 -0.626307 0.326777 -0.625929 0 0 0 0.00281905 l
+0.242724 -0.516675 0.224951 -0.529741 0 0 0 0.00281905 l
+0.242724 -0.516675 0.225041 -0.504888 0 0 0 0.00281905 l
+-0.0354421 0.245718 -0.0429263 0.224521 0 0 0 0.00281905 l
+-0.719672 0.315816 -0.704245 0.319587 0 0 0 0.00281905 l
+-0.719672 0.315816 -0.72288 0.318033 0 0 0 0.00281905 l
+0.24066 0.76921 0.238853 0.758101 0 0 0 0.00281905 l
+0.520544 -0.758228 0.518565 -0.748736 0 0 0 0.00281905 l
+0.520544 -0.758228 0.499145 -0.770283 0 0 0 0.00281905 l
+-0.144163 -0.00918508 -0.14568 -0.0132317 0 0 0 0.00281905 l
+-0.403671 -0.216343 -0.397883 -0.219108 0 0 0 0.00281905 l
+-0.403671 -0.216343 -0.406675 -0.217436 0 0 0 0.00281905 l
+-0.351061 0.350871 -0.34242 0.332796 0 0 0 0.00281905 l
+-0.351061 0.350871 -0.355529 0.35918 0 0 0 0.00281905 l
+0.268725 -0.438228 0.27023 -0.452597 0 0 0 0.00281905 l
+0.268725 -0.438228 0.272432 -0.434303 0 0 0 0.00281905 l
+0.156412 -0.492967 0.156211 -0.475113 0 0 0 0.00281905 l
+0.156412 -0.492967 0.154635 -0.502535 0 0 0 0.00281905 l
+-0.0581448 0.735065 -0.0611782 0.746094 0 0 0 0.00281905 l
+-0.0581448 0.735065 -0.0719021 0.7269 0 0 0 0.00281905 l
+-0.183174 -0.561218 -0.17127 -0.560295 0 0 0 0.00281905 l
+-0.183174 -0.561218 -0.186383 -0.567019 0 0 0 0.00281905 l
+-0.876741 -0.182791 -0.862027 -0.192096 0 0 0 0.00281905 l
+-0.876741 -0.182791 -0.890614 -0.186672 0 0 0 0.00281905 l
+0.534007 -0.329236 0.535681 -0.331069 0 0 0 0.00281905 l
+0.534007 -0.329236 0.524454 -0.321198 0 0 0 0.00281905 l
+-0.408193 0.0708045 -0.403272 0.061426 0 0 0 0.00281905 l
+-0.408193 0.0708045 -0.412373 0.0777009 0 0 0 0.00281905 l
+-0.369777 0.0274005 -0.364941 0.0176626 0 0 0 0.00281905 l
+-0.369777 0.0274005 -0.371631 0.0273986 0 0 0 0.00281905 l
+0.456049 0.29366 0.459429 0.277492 0 0 0 0.00281905 l
+0.456049 0.29366 0.465921 0.30776 0 0 0 0.00281905 l
+0.456049 0.29366 0.435434 0.299367 0 0 0 0.00281905 l
+-0.887908 0.366458 -0.904238 0.351851 0 0 0 0.00281905 l
+-0.643641 0.12767 -0.643065 0.137531 0 0 0 0.00281905 l
+-0.643641 0.12767 -0.632117 0.129658 0 0 0 0.00281905 l
+-0.643641 0.12767 -0.64963 0.124316 0 0 0 0.00281905 l
+-0.729193 -0.584785 -0.728368 -0.586829 0 0 0 0.00281905 l
+-0.729193 -0.584785 -0.739787 -0.574122 0 0 0 0.00281905 l
+0.326809 -0.793271 0.338071 -0.810925 0 0 0 0.00281905 l
+0.326809 -0.793271 0.317346 -0.795688 0 0 0 0.00281905 l
+-0.525175 0.524571 -0.505484 0.520282 0 0 0 0.00281905 l
+-0.525175 0.524571 -0.530984 0.524263 0 0 0 0.00281905 l
+-0.806224 0.399479 -0.794909 0.400649 0 0 0 0.00281905 l
+-0.806224 0.399479 -0.814413 0.395606 0 0 0 0.00281905 l
+0.417339 0.890331 0.420444 0.880747 0 0 0 0.00281905 l
+0.417339 0.890331 0.412386 0.887802 0 0 0 0.00281905 l
+-0.277091 0.655073 -0.274777 0.656034 0 0 0 0.00281905 l
+-0.277091 0.655073 -0.27865 0.658188 0 0 0 0.00281905 l
+0.102012 0.702991 0.102008 0.706537 0 0 0 0.00281905 l
+0.102012 0.702991 0.115162 0.687891 0 0 0 0.00281905 l
+-0.700949 0.225961 -0.709172 0.239374 0 0 0 0.00281905 l
+-0.700949 0.225961 -0.700869 0.222902 0 0 0 0.00281905 l
+0.959582 -0.119594 0.977248 -0.138146 0 0 0 0.00281905 l
+-0.201912 0.744344 -0.199306 0.739641 0 0 0 0.00281905 l
+-0.201912 0.744344 -0.222582 0.750373 0 0 0 0.00281905 l
+0.566024 0.0512999 0.572109 0.0426269 0 0 0 0.00281905 l
+0.566024 0.0512999 0.569638 0.0568218 0 0 0 0.00281905 l
+-0.938061 -0.234869 -0.933208 -0.241256 0 0 0 0.00281905 l
+0.352171 -0.0347774 0.35632 -0.0457503 0 0 0 0.00281905 l
+0.695778 0.299324 0.688901 0.311103 0 0 0 0.00281905 l
+0.695778 0.299324 0.690502 0.294355 0 0 0 0.00281905 l
+-0.281536 -0.693696 -0.276917 -0.693119 0 0 0 0.00281905 l
+-0.281536 -0.693696 -0.282547 -0.690462 0 0 0 0.00281905 l
+0.157073 0.372592 0.161363 0.367915 0 0 0 0.00281905 l
+0.353574 0.725216 0.364666 0.737853 0 0 0 0.00281905 l
+0.353574 0.725216 0.366863 0.719541 0 0 0 0.00281905 l
+0.353574 0.725216 0.339541 0.739961 0 0 0 0.00281905 l
+0.353574 0.725216 0.348435 0.715339 0 0 0 0.00281905 l
+0.745713 -0.348265 0.747603 -0.356855 0 0 0 0.00281905 l
+0.745713 -0.348265 0.747678 -0.338191 0 0 0 0.00281905 l
+0.42633 -0.198818 0.426711 -0.192921 0 0 0 0.00281905 l
+0.42633 -0.198818 0.428281 -0.207101 0 0 0 0.00281905 l
+0.495731 -0.830107 0.50386 -0.839542 0 0 0 0.00281905 l
+0.495731 -0.830107 0.490662 -0.824891 0 0 0 0.00281905 l
+0.495731 -0.830107 0.491959 -0.835332 0 0 0 0.00281905 l
+0.183864 -0.298683 0.179458 -0.286659 0 0 0 0.00281905 l
+0.183864 -0.298683 0.199684 -0.309589 0 0 0 0.00281905 l
+0.183864 -0.298683 0.167196 -0.308028 0 0 0 0.00281905 l
+0.0786691 0.930816 0.0779731 0.955177 0 0 0 0.00281905 l
+0.0786691 0.930816 0.0992787 0.930574 0 0 0 0.00281905 l
+0.0786691 0.930816 0.0766732 0.92613 0 0 0 0.00281905 l
+-0.188815 -0.0783077 -0.185372 -0.0804114 0 0 0 0.00281905 l
+-0.188815 -0.0783077 -0.196043 -0.0869308 0 0 0 0.00281905 l
+0.353419 0.803155 0.341279 0.789628 0 0 0 0.00281905 l
+0.353419 0.803155 0.355585 0.806148 0 0 0 0.00281905 l
+-0.217218 -0.728543 -0.223604 -0.741251 0 0 0 0.00281905 l
+-0.217218 -0.728543 -0.197738 -0.723959 0 0 0 0.00281905 l
+-0.217218 -0.728543 -0.227077 -0.723277 0 0 0 0.00281905 l
+0.347633 -0.289008 0.349531 -0.276715 0 0 0 0.00281905 l
+0.347633 -0.289008 0.357924 -0.295427 0 0 0 0.00281905 l
+0.347633 -0.289008 0.334302 -0.296414 0 0 0 0.00281905 l
+-0.0124874 -0.893705 -0.0129921 -0.885685 0 0 0 0.00281905 l
+-0.0124874 -0.893705 -0.0042643 -0.889499 0 0 0 0.00281905 l
+-0.0124874 -0.893705 -0.00961435 -0.898244 0 0 0 0.00281905 l
+0.300194 -0.182789 0.318145 -0.172307 0 0 0 0.00281905 l
+0.300194 -0.182789 0.287419 -0.180458 0 0 0 0.00281905 l
+-0.53593 -0.439548 -0.531858 -0.428544 0 0 0 0.00281905 l
+-0.53593 -0.439548 -0.5315 -0.450997 0 0 0 0.00281905 l
+0.687508 -0.669762 0.668019 -0.688442 0 0 0 0.00281905 l
+0.687508 -0.669762 0.680504 -0.660518 0 0 0 0.00281905 l
+-0.653032 0.410949 -0.652298 0.419798 0 0 0 0.00281905 l
+-0.653032 0.410949 -0.652297 0.407991 0 0 0 0.00281905 l
+0.936224 0.149538 0.937739 0.165372 0 0 0 0.00281905 l
+0.936224 0.149538 0.921923 0.151857 0 0 0 0.00281905 l
+-0.697663 0.317113 -0.704245 0.319587 0 0 0 0.00281905 l
+-0.794358 -0.604897 -0.781186 -0.597679 0 0 0 0.00281905 l
+0.592781 -0.434856 0.585116 -0.429371 0 0 0 0.00281905 l
+-0.126286 -0.269057 -0.132413 -0.256717 0 0 0 0.00281905 l
+-0.126286 -0.269057 -0.13404 -0.271463 0 0 0 0.00281905 l
+-0.193443 -0.477016 -0.174954 -0.471335 0 0 0 0.00281905 l
+-0.193443 -0.477016 -0.197982 -0.476263 0 0 0 0.00281905 l
+-0.108568 -0.981433 -0.105854 -0.986752 0 0 0 0.00281905 l
+-0.108568 -0.981433 -0.121834 -0.986263 0 0 0 0.00281905 l
+-0.288169 -0.523394 -0.297051 -0.511417 0 0 0 0.00281905 l
+-0.288169 -0.523394 -0.291506 -0.526159 0 0 0 0.00281905 l
+-0.713311 0.118105 -0.701231 0.13214 0 0 0 0.00281905 l
+-0.713311 0.118105 -0.726461 0.133977 0 0 0 0.00281905 l
+0.493614 0.231338 0.50193 0.232878 0 0 0 0.00281905 l
+0.493614 0.231338 0.488906 0.243299 0 0 0 0.00281905 l
+-0.696059 -0.0329919 -0.70582 -0.0128947 0 0 0 0.00281905 l
+-0.696059 -0.0329919 -0.677442 -0.0428734 0 0 0 0.00281905 l
+0.885249 0.256848 0.889835 0.248453 0 0 0 0.00281905 l
+-0.502375 0.091121 -0.495998 0.0834818 0 0 0 0.00281905 l
+-0.502375 0.091121 -0.495373 0.103805 0 0 0 0.00281905 l
+-0.502375 0.091121 -0.5104 0.0955515 0 0 0 0.00281905 l
+-0.502375 0.091121 -0.50933 0.0862189 0 0 0 0.00281905 l
+0.53529 -0.704376 0.56271 -0.710118 0 0 0 0.00281905 l
+0.53529 -0.704376 0.523183 -0.701531 0 0 0 0.00281905 l
+0.756041 -0.577051 0.771576 -0.562159 0 0 0 0.00281905 l
+-0.689688 0.0858672 -0.681668 0.0819501 0 0 0 0.00281905 l
+-0.689688 0.0858672 -0.692833 0.073828 0 0 0 0.00281905 l
+-0.0895336 0.469141 -0.0871538 0.473291 0 0 0 0.00281905 l
+-0.0895336 0.469141 -0.0891242 0.465045 0 0 0 0.00281905 l
+-0.712549 0.524929 -0.693321 0.522506 0 0 0 0.00281905 l
+-0.712549 0.524929 -0.716445 0.512732 0 0 0 0.00281905 l
+-0.712549 0.524929 -0.723944 0.52891 0 0 0 0.00281905 l
+0.52552 -0.713851 0.523183 -0.701531 0 0 0 0.00281905 l
+0.52552 -0.713851 0.510146 -0.715846 0 0 0 0.00281905 l
+0.456529 -0.861739 0.469294 -0.8652 0 0 0 0.00281905 l
+0.456529 -0.861739 0.450259 -0.853663 0 0 0 0.00281905 l
+-0.613293 0.639202 -0.616926 0.648088 0 0 0 0.00281905 l
+-0.228253 0.73746 -0.223731 0.736607 0 0 0 0.00281905 l
+-0.228253 0.73746 -0.237927 0.744182 0 0 0 0.00281905 l
+0.601775 -0.324231 0.599021 -0.341164 0 0 0 0.00281905 l
+0.601775 -0.324231 0.604886 -0.315332 0 0 0 0.00281905 l
+-0.121978 0.0684982 -0.124159 0.0552155 0 0 0 0.00281905 l
+-0.121978 0.0684982 -0.118636 0.0756895 0 0 0 0.00281905 l
+0.839619 -0.428109 0.845329 -0.41322 0 0 0 0.00281905 l
+-0.450436 -0.489632 -0.45635 -0.501777 0 0 0 0.00281905 l
+-0.450436 -0.489632 -0.454287 -0.478457 0 0 0 0.00281905 l
+-0.0496149 0.991074 -0.0586321 0.970977 0 0 0 0.00281905 l
+-0.0496149 0.991074 -0.0469107 0.993439 0 0 0 0.00281905 l
+-0.0401609 0.0814154 -0.0375404 0.0891898 0 0 0 0.00281905 l
+-0.0401609 0.0814154 -0.0491823 0.0782104 0 0 0 0.00281905 l
+0.445653 -0.414497 0.449887 -0.399375 0 0 0 0.00281905 l
+0.445653 -0.414497 0.450157 -0.425527 0 0 0 0.00281905 l
+0.445653 -0.414497 0.426686 -0.424006 0 0 0 0.00281905 l
+-0.592807 -0.593134 -0.581146 -0.610277 0 0 0 0.00281905 l
+-0.592807 -0.593134 -0.602783 -0.583116 0 0 0 0.00281905 l
+-0.00925185 -0.1349 -0.0141802 -0.122026 0 0 0 0.00281905 l
+0.109971 -0.777669 0.113495 -0.78913 0 0 0 0.00281905 l
+0.109971 -0.777669 0.109723 -0.771143 0 0 0 0.00281905 l
+0.173064 0.770195 0.178708 0.78354 0 0 0 0.00281905 l
+0.2013 0.544452 0.197862 0.565314 0 0 0 0.00281905 l
+0.2013 0.544452 0.207519 0.546127 0 0 0 0.00281905 l
+0.146805 0.561243 0.142353 0.578087 0 0 0 0.00281905 l
+0.146805 0.561243 0.149325 0.560292 0 0 0 0.00281905 l
+0.146805 0.561243 0.132468 0.559406 0 0 0 0.00281905 l
+0.529409 -0.233409 0.534467 -0.238326 0 0 0 0.00281905 l
+0.529409 -0.233409 0.536327 -0.228528 0 0 0 0.00281905 l
+0.701334 -0.418616 0.708548 -0.42369 0 0 0 0.00281905 l
+-0.0074681 0.63859 0.00361648 0.625054 0 0 0 0.00281905 l
+-0.0074681 0.63859 -0.0147365 0.630483 0 0 0 0.00281905 l
+-0.482362 -0.645869 -0.480145 -0.639647 0 0 0 0.00281905 l
+-0.482362 -0.645869 -0.48665 -0.650737 0 0 0 0.00281905 l
+-0.128629 0.0992151 -0.119806 0.115945 0 0 0 0.00281905 l
+-0.128629 0.0992151 -0.121355 0.0899399 0 0 0 0.00281905 l
+-0.128629 0.0992151 -0.13119 0.0967668 0 0 0 0.00281905 l
+0.337493 0.896279 0.325626 0.911869 0 0 0 0.00281905 l
+0.337493 0.896279 0.325593 0.891458 0 0 0 0.00281905 l
+-0.277234 0.470805 -0.294853 0.466583 0 0 0 0.00281905 l
+0.532383 0.784706 0.532283 0.791445 0 0 0 0.00281905 l
+0.532383 0.784706 0.538697 0.780587 0 0 0 0.00281905 l
+-0.452665 -0.618624 -0.449711 -0.622759 0 0 0 0.00281905 l
+-0.452665 -0.618624 -0.466835 -0.615004 0 0 0 0.00281905 l
+-0.387661 -0.247529 -0.374112 -0.251253 0 0 0 0.00281905 l
+-0.245803 0.22115 -0.2488 0.225416 0 0 0 0.00281905 l
+0.29741 0.413448 0.309397 0.432814 0 0 0 0.00281905 l
+0.29741 0.413448 0.284737 0.417406 0 0 0 0.00281905 l
+0.465832 -0.552469 0.458553 -0.546045 0 0 0 0.00281905 l
+0.921171 -0.289583 0.928868 -0.291137 0 0 0 0.00281905 l
+0.921171 -0.289583 0.913889 -0.292964 0 0 0 0.00281905 l
+0.0132111 0.33875 0.0259219 0.333931 0 0 0 0.00281905 l
+0.0132111 0.33875 0.011891 0.335676 0 0 0 0.00281905 l
+0.0132111 0.33875 0.00648479 0.340854 0 0 0 0.00281905 l
+0.50948 0.209617 0.507029 0.228012 0 0 0 0.00281905 l
+0.50948 0.209617 0.5181 0.21034 0 0 0 0.00281905 l
+0.313042 -0.0558716 0.310962 -0.0655643 0 0 0 0.00281905 l
+0.313042 -0.0558716 0.309872 -0.0504843 0 0 0 0.00281905 l
+-0.816289 0.123641 -0.802534 0.120231 0 0 0 0.00281905 l
+0.596494 0.613743 0.609127 0.613332 0 0 0 0.00281905 l
+0.596494 0.613743 0.594736 0.600998 0 0 0 0.00281905 l
+0.596494 0.613743 0.596814 0.630852 0 0 0 0.00281905 l
+0.299674 -0.728258 0.312048 -0.729895 0 0 0 0.00281905 l
+0.299674 -0.728258 0.29665 -0.741865 0 0 0 0.00281905 l
+-0.76161 0.608224 -0.755903 0.601222 0 0 0 0.00281905 l
+-0.76161 0.608224 -0.776896 0.604854 0 0 0 0.00281905 l
+0.687894 0.210836 0.666081 0.191083 0 0 0 0.00281905 l
+-0.15789 0.236997 -0.150817 0.236269 0 0 0 0.00281905 l
+-0.15789 0.236997 -0.157788 0.217132 0 0 0 0.00281905 l
+-0.15789 0.236997 -0.168417 0.250935 0 0 0 0.00281905 l
+-0.353776 -0.0977946 -0.358805 -0.104151 0 0 0 0.00281905 l
+-0.353776 -0.0977946 -0.353358 -0.0965898 0 0 0 0.00281905 l
+-0.0719021 0.7269 -0.0691141 0.7222 0 0 0 0.00281905 l
+-0.0719021 0.7269 -0.0581448 0.735065 0 0 0 0.00281905 l
+-0.0719021 0.7269 -0.0759238 0.726536 0 0 0 0.00281905 l
+0.378493 0.867154 0.376107 0.885425 0 0 0 0.00281905 l
+0.378493 0.867154 0.387205 0.85976 0 0 0 0.00281905 l
+0.380019 0.179202 0.376163 0.159085 0 0 0 0.00281905 l
+0.380019 0.179202 0.391326 0.180805 0 0 0 0.00281905 l
+0.380019 0.179202 0.371831 0.182955 0 0 0 0.00281905 l
+0.917296 0.264257 0.925247 0.260813 0 0 0 0.00281905 l
+0.917296 0.264257 0.903061 0.257045 0 0 0 0.00281905 l
+-0.73227 0.032923 -0.744458 0.0251737 0 0 0 0.00281905 l
+-0.371889 0.192947 -0.359988 0.177658 0 0 0 0.00281905 l
+-0.371889 0.192947 -0.366742 0.199662 0 0 0 0.00281905 l
+-0.371889 0.192947 -0.393938 0.189907 0 0 0 0.00281905 l
+-0.430815 -0.141795 -0.432712 -0.143497 0 0 0 0.00281905 l
+-0.461883 -0.023583 -0.46796 -0.0124811 0 0 0 0.00281905 l
+-0.461883 -0.023583 -0.464658 -0.0316159 0 0 0 0.00281905 l
+0.17954 -0.62451 0.179947 -0.605546 0 0 0 0.00281905 l
+0.17954 -0.62451 0.19215 -0.624236 0 0 0 0.00281905 l
+0.17954 -0.62451 0.181269 -0.639778 0 0 0 0.00281905 l
+0.754584 -0.511191 0.767458 -0.512872 0 0 0 0.00281905 l
+0.754584 -0.511191 0.748399 -0.50406 0 0 0 0.00281905 l
+-0.246747 -0.401638 -0.240901 -0.385646 0 0 0 0.00281905 l
+-0.246747 -0.401638 -0.254482 -0.414234 0 0 0 0.00281905 l
+-0.327142 0.765425 -0.316 0.763805 0 0 0 0.00281905 l
+-0.327142 0.765425 -0.329215 0.762734 0 0 0 0.00281905 l
+0.936278 -0.197406 0.939095 -0.192835 0 0 0 0.00281905 l
+0.936278 -0.197406 0.933875 -0.1981 0 0 0 0.00281905 l
+-0.236536 0.854296 -0.228468 0.85644 0 0 0 0.00281905 l
+-0.236536 0.854296 -0.25111 0.839151 0 0 0 0.00281905 l
+-0.760096 -0.409658 -0.742815 -0.42219 0 0 0 0.00281905 l
+-0.760096 -0.409658 -0.769035 -0.395903 0 0 0 0.00281905 l
+-0.614974 -0.184413 -0.612655 -0.173906 0 0 0 0.00281905 l
+-0.614974 -0.184413 -0.606708 -0.187357 0 0 0 0.00281905 l
+-0.614974 -0.184413 -0.621653 -0.194644 0 0 0 0.00281905 l
+0.478707 0.0443429 0.479873 0.0318322 0 0 0 0.00281905 l
+0.478707 0.0443429 0.485734 0.0600073 0 0 0 0.00281905 l
+-0.938674 0.0913576 -0.92735 0.0899559 0 0 0 0.00281905 l
+-0.938674 0.0913576 -0.947806 0.0802568 0 0 0 0.00281905 l
+-0.267796 0.930518 -0.266493 0.922072 0 0 0 0.00281905 l
+-0.267796 0.930518 -0.274463 0.925292 0 0 0 0.00281905 l
+0.00353118 0.370945 0.00813491 0.361179 0 0 0 0.00281905 l
+0.00353118 0.370945 0.0109142 0.390083 0 0 0 0.00281905 l
+-0.619346 0.540109 -0.629935 0.526809 0 0 0 0.00281905 l
+-0.619346 0.540109 -0.608119 0.53974 0 0 0 0.00281905 l
+0.441034 -0.210783 0.443296 -0.210007 0 0 0 0.00281905 l
+0.441034 -0.210783 0.435246 -0.206102 0 0 0 0.00281905 l
+-0.224104 0.805232 -0.240494 0.791917 0 0 0 0.00281905 l
+-0.224104 0.805232 -0.213698 0.813302 0 0 0 0.00281905 l
+-0.870039 -0.0646064 -0.862557 -0.0639363 0 0 0 0.00281905 l
+-0.750297 -0.0192961 -0.735438 -0.0249705 0 0 0 0.00281905 l
+-0.750297 -0.0192961 -0.759123 -0.017064 0 0 0 0.00281905 l
+-0.695042 0.689592 -0.701841 0.709226 0 0 0 0.00281905 l
+-0.695042 0.689592 -0.70907 0.689131 0 0 0 0.00281905 l
+0.481343 0.816252 0.48529 0.795926 0 0 0 0.00281905 l
+0.481343 0.816252 0.476705 0.826157 0 0 0 0.00281905 l
+0.481343 0.816252 0.495596 0.821524 0 0 0 0.00281905 l
+0.84222 0.361448 0.840575 0.33986 0 0 0 0.00281905 l
+0.0450341 0.957966 0.0550421 0.963334 0 0 0 0.00281905 l
+0.633062 -0.439298 0.629643 -0.439224 0 0 0 0.00281905 l
+0.645833 -0.239702 0.639354 -0.230528 0 0 0 0.00281905 l
+-0.274973 0.710267 -0.267285 0.709923 0 0 0 0.00281905 l
+-0.274973 0.710267 -0.278163 0.701217 0 0 0 0.00281905 l
+0.0113524 0.11654 0.0176731 0.123742 0 0 0 0.00281905 l
+0.0113524 0.11654 0.0119631 0.109488 0 0 0 0.00281905 l
+-0.700484 -0.477794 -0.691406 -0.464207 0 0 0 0.00281905 l
+-0.700484 -0.477794 -0.684468 -0.480826 0 0 0 0.00281905 l
+-0.700484 -0.477794 -0.703633 -0.478704 0 0 0 0.00281905 l
+-0.136598 0.273804 -0.136952 0.277406 0 0 0 0.00281905 l
+-0.136598 0.273804 -0.128344 0.268412 0 0 0 0.00281905 l
+-0.136598 0.273804 -0.144314 0.267707 0 0 0 0.00281905 l
+-0.0415744 0.868008 -0.0400301 0.881261 0 0 0 0.00281905 l
+-0.0415744 0.868008 -0.0435758 0.860141 0 0 0 0.00281905 l
+0.384967 0.599581 0.390285 0.620006 0 0 0 0.00281905 l
+0.384967 0.599581 0.373278 0.597185 0 0 0 0.00281905 l
+0.0660422 0.482599 0.057367 0.489707 0 0 0 0.00281905 l
+0.129559 -0.732384 0.128656 -0.714534 0 0 0 0.00281905 l
+0.129559 -0.732384 0.142533 -0.73343 0 0 0 0.00281905 l
+0.135384 0.769731 0.142679 0.765803 0 0 0 0.00281905 l
+0.195166 0.932298 0.173187 0.928945 0 0 0 0.00281905 l
+0.4437 0.063868 0.450227 0.0584916 0 0 0 0.00281905 l
+0.4437 0.063868 0.439904 0.0649067 0 0 0 0.00281905 l
+-0.349437 -0.567291 -0.33694 -0.578202 0 0 0 0.00281905 l
+-0.349437 -0.567291 -0.354723 -0.564646 0 0 0 0.00281905 l
+-0.346703 -0.717132 -0.346709 -0.709464 0 0 0 0.00281905 l
+-0.346703 -0.717132 -0.351745 -0.730957 0 0 0 0.00281905 l
+0.0625908 -0.855393 0.0622822 -0.862919 0 0 0 0.00281905 l
+0.0625908 -0.855393 0.0450904 -0.852311 0 0 0 0.00281905 l
+0.19453 -0.945007 0.188663 -0.932984 0 0 0 0.00281905 l
+0.19453 -0.945007 0.184615 -0.95468 0 0 0 0.00281905 l
+-0.366247 0.717835 -0.361898 0.719564 0 0 0 0.00281905 l
+-0.707001 -0.208169 -0.709207 -0.221777 0 0 0 0.00281905 l
+-0.0714618 0.337184 -0.0629643 0.332049 0 0 0 0.00281905 l
+-0.0714618 0.337184 -0.0750595 0.335374 0 0 0 0.00281905 l
+-0.783027 -0.420782 -0.778698 -0.429777 0 0 0 0.00281905 l
+-0.783027 -0.420782 -0.79332 -0.413256 0 0 0 0.00281905 l
+-0.783027 -0.420782 -0.789726 -0.426538 0 0 0 0.00281905 l
+-0.813494 0.00301869 -0.808412 0.0171506 0 0 0 0.00281905 l
+-0.813494 0.00301869 -0.792629 0.000729275 0 0 0 0.00281905 l
+-0.813494 0.00301869 -0.817462 -0.0125251 0 0 0 0.00281905 l
+-0.813494 0.00301869 -0.826251 0.00630673 0 0 0 0.00281905 l
+0.304374 -0.242745 0.315179 -0.232908 0 0 0 0.00281905 l
+0.304374 -0.242745 0.298892 -0.242969 0 0 0 0.00281905 l
+-0.173387 0.732782 -0.167364 0.735449 0 0 0 0.00281905 l
+-0.173387 0.732782 -0.179947 0.734331 0 0 0 0.00281905 l
+0.950897 -0.201268 0.950602 -0.191227 0 0 0 0.00281905 l
+0.950897 -0.201268 0.957907 -0.202052 0 0 0 0.00281905 l
+0.556494 0.107947 0.57286 0.114411 0 0 0 0.00281905 l
+0.556494 0.107947 0.550901 0.113589 0 0 0 0.00281905 l
+0.720558 0.627243 0.728455 0.617817 0 0 0 0.00281905 l
+0.720558 0.627243 0.718854 0.629992 0 0 0 0.00281905 l
+-0.971278 -0.0589315 -0.961954 -0.0711963 0 0 0 0.00281905 l
+0.0435332 0.780722 0.0474121 0.776291 0 0 0 0.00281905 l
+0.417974 -0.551933 0.412754 -0.544489 0 0 0 0.00281905 l
+0.417974 -0.551933 0.419586 -0.55775 0 0 0 0.00281905 l
+-0.619875 0.198513 -0.613496 0.198479 0 0 0 0.00281905 l
+-0.619875 0.198513 -0.632648 0.206142 0 0 0 0.00281905 l
+0.797723 0.182441 0.800196 0.185397 0 0 0 0.00281905 l
+-0.129876 -0.237316 -0.129336 -0.223367 0 0 0 0.00281905 l
+-0.129876 -0.237316 -0.134062 -0.242775 0 0 0 0.00281905 l
+0.737971 0.0827268 0.737389 0.094595 0 0 0 0.00281905 l
+0.737971 0.0827268 0.740399 0.0813869 0 0 0 0.00281905 l
+0.737971 0.0827268 0.737552 0.0822945 0 0 0 0.00281905 l
+-0.413072 -0.378193 -0.41823 -0.388103 0 0 0 0.00281905 l
+-0.413072 -0.378193 -0.402621 -0.373107 0 0 0 0.00281905 l
+-0.413072 -0.378193 -0.424112 -0.367534 0 0 0 0.00281905 l
+0.165088 0.391175 0.169662 0.378507 0 0 0 0.00281905 l
+0.165088 0.391175 0.161331 0.39989 0 0 0 0.00281905 l
+0.871261 -0.26879 0.87853 -0.255731 0 0 0 0.00281905 l
+0.871261 -0.26879 0.863974 -0.278111 0 0 0 0.00281905 l
+0.367208 0.0239527 0.371717 0.0118229 0 0 0 0.00281905 l
+-0.157383 0.442484 -0.152452 0.45461 0 0 0 0.00281905 l
+-0.157383 0.442484 -0.149714 0.441138 0 0 0 0.00281905 l
+-0.157383 0.442484 -0.165485 0.443469 0 0 0 0.00281905 l
+0.188511 0.779259 0.201328 0.77483 0 0 0 0.00281905 l
+0.188511 0.779259 0.178708 0.78354 0 0 0 0.00281905 l
+-0.000836784 -0.388774 0.00122309 -0.380146 0 0 0 0.00281905 l
+-0.0558546 -0.711844 -0.0541525 -0.720993 0 0 0 0.00281905 l
+-0.0558546 -0.711844 -0.0451477 -0.699731 0 0 0 0.00281905 l
+-0.824154 -0.0750363 -0.824154 -0.0786788 0 0 0 0.00281905 l
+-0.824154 -0.0750363 -0.826418 -0.07227 0 0 0 0.00281905 l
+-0.885207 0.00988652 -0.877473 0.0176556 0 0 0 0.00281905 l
+-0.885207 0.00988652 -0.893278 0.00840169 0 0 0 0.00281905 l
+-0.214821 -0.118732 -0.205135 -0.116367 0 0 0 0.00281905 l
+-0.214821 -0.118732 -0.227939 -0.12033 0 0 0 0.00281905 l
+0.685739 0.110695 0.695318 0.117938 0 0 0 0.00281905 l
+-0.807618 -0.48242 -0.814561 -0.499468 0 0 0 0.00281905 l
+-0.244432 -0.331038 -0.254988 -0.316389 0 0 0 0.00281905 l
+-0.244432 -0.331038 -0.255554 -0.3406 0 0 0 0.00281905 l
+-0.294031 -0.576719 -0.299807 -0.556487 0 0 0 0.00281905 l
+-0.294031 -0.576719 -0.316056 -0.583319 0 0 0 0.00281905 l
+-0.0223632 -0.577535 -0.00405571 -0.582543 0 0 0 0.00281905 l
+-0.0223632 -0.577535 -0.0226209 -0.563191 0 0 0 0.00281905 l
+-0.0223632 -0.577535 -0.034261 -0.573736 0 0 0 0.00281905 l
+-0.393636 -0.492652 -0.400099 -0.492662 0 0 0 0.00281905 l
+-0.393636 -0.492652 -0.386746 -0.484763 0 0 0 0.00281905 l
+-0.365357 -0.243224 -0.360887 -0.228718 0 0 0 0.00281905 l
+-0.365357 -0.243224 -0.355476 -0.245154 0 0 0 0.00281905 l
+-0.365357 -0.243224 -0.374112 -0.251253 0 0 0 0.00281905 l
+0.192976 0.64745 0.204658 0.635365 0 0 0 0.00281905 l
+0.131622 -0.622737 0.136678 -0.618677 0 0 0 0.00281905 l
+0.0429009 -0.594552 0.0551983 -0.581011 0 0 0 0.00281905 l
+-0.143978 -0.924545 -0.140512 -0.939848 0 0 0 0.00281905 l
+0.0744193 0.238931 0.0761444 0.232648 0 0 0 0.00281905 l
+0.0744193 0.238931 0.0804247 0.242859 0 0 0 0.00281905 l
+0.0744193 0.238931 0.0662828 0.241346 0 0 0 0.00281905 l
+-0.389394 0.751163 -0.386243 0.750239 0 0 0 0.00281905 l
+-0.389394 0.751163 -0.408832 0.753133 0 0 0 0.00281905 l
+0.449126 0.360789 0.461841 0.370342 0 0 0 0.00281905 l
+0.449126 0.360789 0.443819 0.36135 0 0 0 0.00281905 l
+0.0460058 -0.976684 0.0504919 -0.984968 0 0 0 0.00281905 l
+0.0460058 -0.976684 0.029335 -0.976844 0 0 0 0.00281905 l
+0.441324 -0.743464 0.449493 -0.760352 0 0 0 0.00281905 l
+0.441324 -0.743464 0.438042 -0.743799 0 0 0 0.00281905 l
+0.638441 0.403514 0.65565 0.388985 0 0 0 0.00281905 l
+0.638441 0.403514 0.649749 0.42228 0 0 0 0.00281905 l
+0.638441 0.403514 0.629432 0.399291 0 0 0 0.00281905 l
+-0.425582 0.721772 -0.41818 0.733769 0 0 0 0.00281905 l
+-0.425582 0.721772 -0.427558 0.718549 0 0 0 0.00281905 l
+0.904671 -0.0587103 0.908885 -0.0529987 0 0 0 0.00281905 l
+0.904671 -0.0587103 0.907422 -0.0602081 0 0 0 0.00281905 l
+0.904671 -0.0587103 0.899988 -0.0551984 0 0 0 0.00281905 l
+0.183501 -0.525921 0.201368 -0.522197 0 0 0 0.00281905 l
+0.183501 -0.525921 0.176135 -0.536537 0 0 0 0.00281905 l
+0.939441 0.186441 0.948608 0.202007 0 0 0 0.00281905 l
+0.939441 0.186441 0.929042 0.186443 0 0 0 0.00281905 l
+-0.204529 0.633706 -0.194774 0.638666 0 0 0 0.00281905 l
+-0.204529 0.633706 -0.209153 0.630903 0 0 0 0.00281905 l
+-0.279303 -0.260478 -0.268815 -0.269799 0 0 0 0.00281905 l
+-0.279303 -0.260478 -0.286422 -0.255832 0 0 0 0.00281905 l
+0.285576 0.798016 0.288477 0.807801 0 0 0 0.00281905 l
+0.285576 0.798016 0.286502 0.779093 0 0 0 0.00281905 l
+-0.81519 0.0800164 -0.81286 0.0877904 0 0 0 0.00281905 l
+0.831534 0.197148 0.835077 0.191053 0 0 0 0.00281905 l
+0.831534 0.197148 0.827815 0.197654 0 0 0 0.00281905 l
+0.0829608 0.715401 0.0891672 0.707587 0 0 0 0.00281905 l
+-0.446563 0.586575 -0.448507 0.577561 0 0 0 0.00281905 l
+-0.446563 0.586575 -0.435295 0.599677 0 0 0 0.00281905 l
+0.135443 0.661927 0.134017 0.679757 0 0 0 0.00281905 l
+0.135443 0.661927 0.146919 0.649459 0 0 0 0.00281905 l
+0.135443 0.661927 0.118572 0.658442 0 0 0 0.00281905 l
+-0.838153 -0.465883 -0.836076 -0.44529 0 0 0 0.00281905 l
+-0.838153 -0.465883 -0.85085 -0.479579 0 0 0 0.00281905 l
+-0.838153 -0.465883 -0.856304 -0.460442 0 0 0 0.00281905 l
+0.0367689 -0.469022 0.0428803 -0.458017 0 0 0 0.00281905 l
+0.0367689 -0.469022 0.0350647 -0.47592 0 0 0 0.00281905 l
+0.038272 0.512227 0.0349781 0.517791 0 0 0 0.00281905 l
+0.038272 0.512227 0.0479191 0.503421 0 0 0 0.00281905 l
+0.666459 -0.260524 0.669991 -0.280551 0 0 0 0.00281905 l
+0.666459 -0.260524 0.673222 -0.256476 0 0 0 0.00281905 l
+0.348499 -0.656885 0.350253 -0.649658 0 0 0 0.00281905 l
+0.348499 -0.656885 0.335699 -0.671492 0 0 0 0.00281905 l
+0.207588 0.714479 0.219034 0.730701 0 0 0 0.00281905 l
+0.207588 0.714479 0.197806 0.713923 0 0 0 0.00281905 l
+-0.501274 0.771769 -0.488316 0.755369 0 0 0 0.00281905 l
+-0.501274 0.771769 -0.486151 0.781248 0 0 0 0.00281905 l
+-0.501274 0.771769 -0.511681 0.761759 0 0 0 0.00281905 l
+-0.501274 0.771769 -0.516198 0.779151 0 0 0 0.00281905 l
+-0.707779 -0.187535 -0.71334 -0.17131 0 0 0 0.00281905 l
+-0.0497604 0.14437 -0.0443842 0.133992 0 0 0 0.00281905 l
+-0.0497604 0.14437 -0.0513802 0.153568 0 0 0 0.00281905 l
+0.55339 -0.553772 0.559422 -0.555839 0 0 0 0.00281905 l
+0.55339 -0.553772 0.542822 -0.550505 0 0 0 0.00281905 l
+-0.0760536 0.0594207 -0.0761912 0.0642849 0 0 0 0.00281905 l
+-0.0760536 0.0594207 -0.0708782 0.0501204 0 0 0 0.00281905 l
+-0.0760536 0.0594207 -0.0808913 0.0555962 0 0 0 0.00281905 l
+0.393096 -0.911752 0.406362 -0.911624 0 0 0 0.00281905 l
+0.393096 -0.911752 0.378889 -0.921906 0 0 0 0.00281905 l
+0.572913 -0.0752311 0.580087 -0.0767557 0 0 0 0.00281905 l
+0.572913 -0.0752311 0.569116 -0.0669796 0 0 0 0.00281905 l
+0.599659 -0.776516 0.608459 -0.774204 0 0 0 0.00281905 l
+0.599659 -0.776516 0.589069 -0.785539 0 0 0 0.00281905 l
+-0.147292 0.746347 -0.142004 0.749257 0 0 0 0.00281905 l
+-0.147292 0.746347 -0.1561 0.746205 0 0 0 0.00281905 l
+-0.137801 -0.799296 -0.125561 -0.810106 0 0 0 0.00281905 l
+-0.137801 -0.799296 -0.137867 -0.797582 0 0 0 0.00281905 l
+-0.137801 -0.799296 -0.150786 -0.805208 0 0 0 0.00281905 l
+0.0403637 0.114267 0.0605843 0.107692 0 0 0 0.00281905 l
+0.0403637 0.114267 0.0369058 0.120098 0 0 0 0.00281905 l
+-0.621169 -0.501327 -0.613744 -0.513108 0 0 0 0.00281905 l
+-0.422712 0.291837 -0.410389 0.283303 0 0 0 0.00281905 l
+0.289137 0.655615 0.287747 0.653558 0 0 0 0.00281905 l
+-0.879973 0.435441 -0.881141 0.420081 0 0 0 0.00281905 l
+-0.879973 0.435441 -0.863008 0.432623 0 0 0 0.00281905 l
+-0.879973 0.435441 -0.88192 0.441807 0 0 0 0.00281905 l
+-0.386746 -0.484763 -0.402202 -0.472281 0 0 0 0.00281905 l
+-0.386746 -0.484763 -0.382768 -0.489438 0 0 0 0.00281905 l
+-0.386746 -0.484763 -0.393636 -0.492652 0 0 0 0.00281905 l
+0.309459 -0.495425 0.306559 -0.504239 0 0 0 0.00281905 l
+0.511616 -0.0734819 0.519092 -0.08444 0 0 0 0.00281905 l
+0.511616 -0.0734819 0.506627 -0.068885 0 0 0 0.00281905 l
+0.140723 -0.814096 0.148354 -0.809648 0 0 0 0.00281905 l
+0.140723 -0.814096 0.126259 -0.808334 0 0 0 0.00281905 l
+-0.716356 -0.591955 -0.718363 -0.585222 0 0 0 0.00281905 l
+-0.716356 -0.591955 -0.717098 -0.596795 0 0 0 0.00281905 l
+0.649749 0.42228 0.669142 0.437545 0 0 0 0.00281905 l
+0.649749 0.42228 0.638441 0.403514 0 0 0 0.00281905 l
+-0.555383 -0.398187 -0.561806 -0.382839 0 0 0 0.00281905 l
+-0.555383 -0.398187 -0.54565 -0.398647 0 0 0 0.00281905 l
+-0.555383 -0.398187 -0.563939 -0.404791 0 0 0 0.00281905 l
+-0.203269 -0.67548 -0.206515 -0.673358 0 0 0 0.00281905 l
+-0.385558 -0.832888 -0.376545 -0.830115 0 0 0 0.00281905 l
+-0.385558 -0.832888 -0.391268 -0.845879 0 0 0 0.00281905 l
+-0.385558 -0.832888 -0.392134 -0.826142 0 0 0 0.00281905 l
+-0.670845 -0.275805 -0.672335 -0.264245 0 0 0 0.00281905 l
+-0.670845 -0.275805 -0.666978 -0.27837 0 0 0 0.00281905 l
+0.0173259 0.179161 0.0306661 0.172097 0 0 0 0.00281905 l
+0.0173259 0.179161 0.00123777 0.178034 0 0 0 0.00281905 l
+0.411861 0.53074 0.418485 0.51891 0 0 0 0.00281905 l
+0.411861 0.53074 0.415086 0.534528 0 0 0 0.00281905 l
+-0.940486 -0.19875 -0.929391 -0.193952 0 0 0 0.00281905 l
+-0.940486 -0.19875 -0.946997 -0.194642 0 0 0 0.00281905 l
+-0.940486 -0.19875 -0.944361 -0.202361 0 0 0 0.00281905 l
+-0.450982 0.106655 -0.445308 0.099341 0 0 0 0.00281905 l
+-0.450982 0.106655 -0.462931 0.10329 0 0 0 0.00281905 l
+-0.416782 -0.255665 -0.420794 -0.24615 0 0 0 0.00281905 l
+-0.416782 -0.255665 -0.416061 -0.257141 0 0 0 0.00281905 l
+0.961438 0.0363541 0.954928 0.0216045 0 0 0 0.00281905 l
+0.364127 -0.704402 0.364991 -0.71375 0 0 0 0.00281905 l
+0.364127 -0.704402 0.356869 -0.695143 0 0 0 0.00281905 l
+-0.790782 0.186761 -0.789285 0.199571 0 0 0 0.00281905 l
+-0.790782 0.186761 -0.78862 0.186264 0 0 0 0.00281905 l
+0.775951 -0.510103 0.779152 -0.509239 0 0 0 0.00281905 l
+0.775951 -0.510103 0.767458 -0.512872 0 0 0 0.00281905 l
+0.334693 -0.454143 0.352631 -0.454052 0 0 0 0.00281905 l
+0.334693 -0.454143 0.333915 -0.457303 0 0 0 0.00281905 l
+-0.718363 -0.585222 -0.716356 -0.591955 0 0 0 0.00281905 l
+-0.718363 -0.585222 -0.728368 -0.586829 0 0 0 0.00281905 l
+0.333501 -0.543507 0.325664 -0.556123 0 0 0 0.00281905 l
+0.151264 -0.512561 0.165484 -0.514362 0 0 0 0.00281905 l
+0.151264 -0.512561 0.15062 -0.50557 0 0 0 0.00281905 l
+0.0604304 0.518232 0.0604677 0.516892 0 0 0 0.00281905 l
+0.0604304 0.518232 0.0642648 0.522771 0 0 0 0.00281905 l
+0.350031 -0.860059 0.344979 -0.873333 0 0 0 0.00281905 l
+0.350031 -0.860059 0.356198 -0.857124 0 0 0 0.00281905 l
+0.350031 -0.860059 0.335338 -0.857753 0 0 0 0.00281905 l
+0.783857 -0.0684448 0.77692 -0.0577995 0 0 0 0.00281905 l
+0.783857 -0.0684448 0.79204 -0.074379 0 0 0 0.00281905 l
+0.783857 -0.0684448 0.771424 -0.0744495 0 0 0 0.00281905 l
+0.412112 0.179162 0.408421 0.190148 0 0 0 0.00281905 l
+0.412112 0.179162 0.424302 0.172199 0 0 0 0.00281905 l
+0.383358 0.469749 0.403751 0.462313 0 0 0 0.00281905 l
+0.383358 0.469749 0.365112 0.48062 0 0 0 0.00281905 l
+0.174381 0.912756 0.179863 0.91385 0 0 0 0.00281905 l
+0.174381 0.912756 0.164523 0.921324 0 0 0 0.00281905 l
+-0.234539 0.335661 -0.227962 0.343461 0 0 0 0.00281905 l
+-0.234539 0.335661 -0.235995 0.330701 0 0 0 0.00281905 l
+-0.45635 -0.501777 -0.450436 -0.489632 0 0 0 0.00281905 l
+0.00361648 0.625054 -0.0074681 0.63859 0 0 0 0.00281905 l
+0.00361648 0.625054 0.013018 0.625936 0 0 0 0.00281905 l
+0.00361648 0.625054 0.00238574 0.622497 0 0 0 0.00281905 l
+-0.741864 0.300878 -0.735849 0.289693 0 0 0 0.00281905 l
+-0.741864 0.300878 -0.744326 0.307725 0 0 0 0.00281905 l
+-0.139834 0.171303 -0.143347 0.160469 0 0 0 0.00281905 l
+-0.139834 0.171303 -0.134847 0.173405 0 0 0 0.00281905 l
+-0.0791461 0.692805 -0.0816758 0.693981 0 0 0 0.00281905 l
+0.0445895 -0.677521 0.0544229 -0.665024 0 0 0 0.00281905 l
+0.0445895 -0.677521 0.0355181 -0.666428 0 0 0 0.00281905 l
+0.0445895 -0.677521 0.0389374 -0.686031 0 0 0 0.00281905 l
+-0.193514 0.286711 -0.212782 0.286397 0 0 0 0.00281905 l
+-0.193514 0.286711 -0.190965 0.286471 0 0 0 0.00281905 l
+-0.171585 0.0379873 -0.17402 0.0217113 0 0 0 0.00281905 l
+-0.171585 0.0379873 -0.18426 0.0388021 0 0 0 0.00281905 l
+0.637972 0.363392 0.642694 0.357919 0 0 0 0.00281905 l
+-0.484009 0.696163 -0.481691 0.680988 0 0 0 0.00281905 l
+-0.484009 0.696163 -0.481141 0.714145 0 0 0 0.00281905 l
+-0.484009 0.696163 -0.497717 0.690533 0 0 0 0.00281905 l
+-0.866332 -0.38475 -0.882509 -0.391047 0 0 0 0.00281905 l
+-0.866332 -0.38475 -0.867518 -0.380522 0 0 0 0.00281905 l
+-0.149449 0.0790038 -0.163432 0.0955439 0 0 0 0.00281905 l
+-0.149449 0.0790038 -0.142645 0.0789173 0 0 0 0.00281905 l
+0.681718 -0.444874 0.675198 -0.463127 0 0 0 0.00281905 l
+0.681718 -0.444874 0.694562 -0.434884 0 0 0 0.00281905 l
+0.10117 -0.0686018 0.0989089 -0.050982 0 0 0 0.00281905 l
+0.10117 -0.0686018 0.118378 -0.0687233 0 0 0 0.00281905 l
+-0.831145 0.505183 -0.830542 0.502784 0 0 0 0.00281905 l
+-0.831145 0.505183 -0.832367 0.50981 0 0 0 0.00281905 l
+0.80871 0.401057 0.814569 0.394969 0 0 0 0.00281905 l
+0.80871 0.401057 0.794609 0.399406 0 0 0 0.00281905 l
+0.456237 0.718632 0.447756 0.701132 0 0 0 0.00281905 l
+0.456237 0.718632 0.46857 0.720025 0 0 0 0.00281905 l
+0.452094 -0.675875 0.467739 -0.684046 0 0 0 0.00281905 l
+0.452094 -0.675875 0.43571 -0.669646 0 0 0 0.00281905 l
+0.0642648 0.522771 0.0739938 0.528442 0 0 0 0.00281905 l
+0.0642648 0.522771 0.0604304 0.518232 0 0 0 0.00281905 l
+0.266729 -0.343796 0.277841 -0.341603 0 0 0 0.00281905 l
+0.266729 -0.343796 0.261604 -0.345791 0 0 0 0.00281905 l
+-0.860921 0.323759 -0.854573 0.327657 0 0 0 0.00281905 l
+0.520858 0.397139 0.510031 0.396041 0 0 0 0.00281905 l
+0.520858 0.397139 0.524778 0.402079 0 0 0 0.00281905 l
+0.21607 -0.130596 0.218517 -0.129387 0 0 0 0.00281905 l
+0.21607 -0.130596 0.204457 -0.125821 0 0 0 0.00281905 l
+0.576692 -0.0350918 0.571655 -0.0268387 0 0 0 0.00281905 l
+0.576692 -0.0350918 0.567886 -0.036734 0 0 0 0.00281905 l
+-0.749831 -0.385706 -0.746552 -0.389846 0 0 0 0.00281905 l
+0.776248 -0.184908 0.775272 -0.174678 0 0 0 0.00281905 l
+0.954928 0.0216045 0.961438 0.0363541 0 0 0 0.00281905 l
+0.954928 0.0216045 0.959013 0.00679028 0 0 0 0.00281905 l
+-0.697241 -0.637901 -0.696755 -0.646714 0 0 0 0.00281905 l
+-0.697241 -0.637901 -0.697747 -0.632855 0 0 0 0.00281905 l
+-0.411649 0.46193 -0.418003 0.481581 0 0 0 0.00281905 l
+-0.411649 0.46193 -0.396063 0.453229 0 0 0 0.00281905 l
+-0.411649 0.46193 -0.419935 0.456869 0 0 0 0.00281905 l
+0.550901 0.113589 0.557535 0.12334 0 0 0 0.00281905 l
+0.550901 0.113589 0.539256 0.126665 0 0 0 0.00281905 l
+0.550901 0.113589 0.556494 0.107947 0 0 0 0.00281905 l
+0.550901 0.113589 0.538773 0.109002 0 0 0 0.00281905 l
+-0.80975 -0.23372 -0.827983 -0.231856 0 0 0 0.00281905 l
+0.391784 0.766422 0.393776 0.769831 0 0 0 0.00281905 l
+0.686413 0.13244 0.673614 0.144956 0 0 0 0.00281905 l
+0.686413 0.13244 0.692175 0.124878 0 0 0 0.00281905 l
+0.686413 0.13244 0.671778 0.126821 0 0 0 0.00281905 l
+-0.517104 0.59941 -0.513686 0.59774 0 0 0 0.00281905 l
+0.471958 -0.0237207 0.4758 -0.0203505 0 0 0 0.00281905 l
+-0.183273 0.742061 -0.187573 0.735514 0 0 0 0.00281905 l
+-0.183273 0.742061 -0.19007 0.749104 0 0 0 0.00281905 l
+-0.158204 -0.153139 -0.157168 -0.167997 0 0 0 0.00281905 l
+-0.158204 -0.153139 -0.152845 -0.15105 0 0 0 0.00281905 l
+0.860603 -0.325271 0.869555 -0.323532 0 0 0 0.00281905 l
+0.860603 -0.325271 0.855307 -0.32581 0 0 0 0.00281905 l
+0.770751 0.0195839 0.77051 0.0147366 0 0 0 0.00281905 l
+0.770751 0.0195839 0.777687 0.0377925 0 0 0 0.00281905 l
+0.254885 -0.94739 0.247063 -0.931912 0 0 0 0.00281905 l
+0.254885 -0.94739 0.260465 -0.952124 0 0 0 0.00281905 l
+0.254885 -0.94739 0.252127 -0.948533 0 0 0 0.00281905 l
+0.0977012 -0.681626 0.117454 -0.68132 0 0 0 0.00281905 l
+0.0977012 -0.681626 0.0916289 -0.67984 0 0 0 0.00281905 l
+0.0634763 0.869524 0.0572939 0.872737 0 0 0 0.00281905 l
+0.334302 -0.296414 0.347633 -0.289008 0 0 0 0.00281905 l
+0.334302 -0.296414 0.34618 -0.309763 0 0 0 0.00281905 l
+0.21898 0.881048 0.222116 0.882692 0 0 0 0.00281905 l
+-0.415057 0.513862 -0.408679 0.51629 0 0 0 0.00281905 l
+-0.415057 0.513862 -0.42633 0.520648 0 0 0 0.00281905 l
+0.849907 -0.47285 0.852606 -0.464844 0 0 0 0.00281905 l
+0.849907 -0.47285 0.828789 -0.470456 0 0 0 0.00281905 l
+-0.0507641 0.619913 -0.0434513 0.604003 0 0 0 0.00281905 l
+-0.0507641 0.619913 -0.054258 0.628488 0 0 0 0.00281905 l
+-2.15015e-05 -0.296169 -0.00440754 -0.283809 0 0 0 0.00281905 l
+-2.15015e-05 -0.296169 -0.00629927 -0.299569 0 0 0 0.00281905 l
+0.66805 -0.728082 0.680828 -0.725162 0 0 0 0.00281905 l
+0.66805 -0.728082 0.658532 -0.730983 0 0 0 0.00281905 l
+-0.609176 0.516777 -0.614596 0.515187 0 0 0 0.00281905 l
+0.21889 0.598869 0.230374 0.600931 0 0 0 0.00281905 l
+0.160046 -0.616527 0.14729 -0.617873 0 0 0 0.00281905 l
+0.801417 0.113397 0.799205 0.112785 0 0 0 0.00281905 l
+-0.253011 -0.381429 -0.244465 -0.374376 0 0 0 0.00281905 l
+-0.253011 -0.381429 -0.263865 -0.370285 0 0 0 0.00281905 l
+-0.48173 0.380035 -0.47902 0.375 0 0 0 0.00281905 l
+-0.48173 0.380035 -0.489709 0.38149 0 0 0 0.00281905 l
+0.594736 0.600998 0.595664 0.589088 0 0 0 0.00281905 l
+0.594736 0.600998 0.596494 0.613743 0 0 0 0.00281905 l
+0.594736 0.600998 0.587345 0.601078 0 0 0 0.00281905 l
+0.222116 0.882692 0.223979 0.894369 0 0 0 0.00281905 l
+0.222116 0.882692 0.227774 0.876363 0 0 0 0.00281905 l
+0.222116 0.882692 0.21898 0.881048 0 0 0 0.00281905 l
+-0.597864 -0.449041 -0.595229 -0.440003 0 0 0 0.00281905 l
+-0.597864 -0.449041 -0.609004 -0.463303 0 0 0 0.00281905 l
+-0.303431 0.0386019 -0.295773 0.0305051 0 0 0 0.00281905 l
+-0.303431 0.0386019 -0.314762 0.0296076 0 0 0 0.00281905 l
+0.664694 -0.306885 0.659346 -0.308518 0 0 0 0.00281905 l
+-0.223461 0.478037 -0.208068 0.475776 0 0 0 0.00281905 l
+-0.223461 0.478037 -0.222739 0.466137 0 0 0 0.00281905 l
+-0.223461 0.478037 -0.223867 0.480294 0 0 0 0.00281905 l
+0.850005 0.479454 0.866411 0.479533 0 0 0 0.00281905 l
+0.850005 0.479454 0.850917 0.463601 0 0 0 0.00281905 l
+0.850005 0.479454 0.84399 0.482954 0 0 0 0.00281905 l
+-0.942832 -0.150165 -0.942273 -0.137762 0 0 0 0.00281905 l
+-0.942832 -0.150165 -0.929746 -0.151657 0 0 0 0.00281905 l
+0.679107 0.372247 0.681641 0.369879 0 0 0 0.00281905 l
+0.679107 0.372247 0.674654 0.372148 0 0 0 0.00281905 l
+-0.318274 0.73475 -0.308558 0.736182 0 0 0 0.00281905 l
+-0.318274 0.73475 -0.322734 0.736335 0 0 0 0.00281905 l
+0.6792 -0.220858 0.695096 -0.213498 0 0 0 0.00281905 l
+0.6792 -0.220858 0.666347 -0.207084 0 0 0 0.00281905 l
+0.729565 -0.651262 0.724206 -0.664359 0 0 0 0.00281905 l
+0.729565 -0.651262 0.721115 -0.646881 0 0 0 0.00281905 l
+-0.0964474 -0.478425 -0.0839072 -0.491322 0 0 0 0.00281905 l
+-0.0964474 -0.478425 -0.112586 -0.469311 0 0 0 0.00281905 l
+-0.75252 0.0444008 -0.749671 0.0527303 0 0 0 0.00281905 l
+-0.75252 0.0444008 -0.75783 0.0358052 0 0 0 0.00281905 l
+-0.0714956 0.714867 -0.0691141 0.7222 0 0 0 0.00281905 l
+-0.0714956 0.714867 -0.0779103 0.708051 0 0 0 0.00281905 l
+0.0445223 -0.846144 0.0592192 -0.832596 0 0 0 0.00281905 l
+0.0445223 -0.846144 0.0450904 -0.852311 0 0 0 0.00281905 l
+0.0445223 -0.846144 0.0344357 -0.826531 0 0 0 0.00281905 l
+0.570423 0.31569 0.583939 0.329436 0 0 0 0.00281905 l
+0.570423 0.31569 0.563705 0.298463 0 0 0 0.00281905 l
+0.570423 0.31569 0.557663 0.32752 0 0 0 0.00281905 l
+0.0298122 0.669986 0.0443173 0.665247 0 0 0 0.00281905 l
+0.0298122 0.669986 0.0240807 0.671092 0 0 0 0.00281905 l
+-0.507482 -0.105652 -0.50939 -0.117221 0 0 0 0.00281905 l
+-0.507482 -0.105652 -0.49381 -0.0940095 0 0 0 0.00281905 l
+-0.895315 -0.154381 -0.898325 -0.158439 0 0 0 0.00281905 l
+-0.895315 -0.154381 -0.898061 -0.153156 0 0 0 0.00281905 l
+0.121146 -0.966807 0.141578 -0.951739 0 0 0 0.00281905 l
+0.121146 -0.966807 0.121815 -0.972676 0 0 0 0.00281905 l
+-0.969097 0.028464 -0.965191 0.019838 0 0 0 0.00281905 l
+-0.969097 0.028464 -0.96363 0.0336893 0 0 0 0.00281905 l
+-0.969097 0.028464 -0.974762 0.0230526 0 0 0 0.00281905 l
+0.351796 -0.639906 0.350253 -0.649658 0 0 0 0.00281905 l
+0.351796 -0.639906 0.34369 -0.626307 0 0 0 0.00281905 l
+-0.230517 -0.0565945 -0.235598 -0.047461 0 0 0 0.00281905 l
+-0.230517 -0.0565945 -0.225151 -0.0607045 0 0 0 0.00281905 l
+-0.230517 -0.0565945 -0.239081 -0.0619393 0 0 0 0.00281905 l
+0.755358 0.485475 0.753179 0.495628 0 0 0 0.00281905 l
+0.755358 0.485475 0.744234 0.483391 0 0 0 0.00281905 l
+-0.843976 0.523075 -0.841421 0.522472 0 0 0 0.00281905 l
+-0.843976 0.523075 -0.845333 0.527936 0 0 0 0.00281905 l
+0.145128 -0.0334862 0.139308 -0.0362019 0 0 0 0.00281905 l
+0.815392 -0.496865 0.816037 -0.505268 0 0 0 0.00281905 l
+0.815392 -0.496865 0.799544 -0.490547 0 0 0 0.00281905 l
+-0.410502 0.704015 -0.395239 0.703694 0 0 0 0.00281905 l
+-0.410502 0.704015 -0.410159 0.688191 0 0 0 0.00281905 l
+0.400747 -0.033372 0.395549 -0.0177963 0 0 0 0.00281905 l
+0.400747 -0.033372 0.40822 -0.0346204 0 0 0 0.00281905 l
+0.400747 -0.033372 0.402084 -0.0455968 0 0 0 0.00281905 l
+0.400747 -0.033372 0.381735 -0.036384 0 0 0 0.00281905 l
+-0.478931 -0.0751444 -0.46484 -0.0794619 0 0 0 0.00281905 l
+-0.478931 -0.0751444 -0.480967 -0.0807854 0 0 0 0.00281905 l
+-0.767072 0.551853 -0.777821 0.563847 0 0 0 0.00281905 l
+-0.00902992 0.239005 -0.0106857 0.23434 0 0 0 0.00281905 l
+0.586849 0.656822 0.595718 0.667314 0 0 0 0.00281905 l
+0.586849 0.656822 0.577515 0.669629 0 0 0 0.00281905 l
+-0.302369 0.425803 -0.289864 0.442863 0 0 0 0.00281905 l
+-0.302369 0.425803 -0.318567 0.422037 0 0 0 0.00281905 l
+0.951333 0.293476 0.938897 0.278609 0 0 0 0.00281905 l
+0.951333 0.293476 0.942383 0.301691 0 0 0 0.00281905 l
+0.593399 0.630913 0.596814 0.630852 0 0 0 0.00281905 l
+0.341219 0.0640053 0.34283 0.0639632 0 0 0 0.00281905 l
+-0.621358 0.613082 -0.605993 0.600186 0 0 0 0.00281905 l
+-0.621358 0.613082 -0.624878 0.609407 0 0 0 0.00281905 l
+0.0747528 -0.581497 0.0834857 -0.590893 0 0 0 0.00281905 l
+0.0747528 -0.581497 0.0745035 -0.581547 0 0 0 0.00281905 l
+-0.584224 -0.183402 -0.580876 -0.184609 0 0 0 0.00281905 l
+-0.584224 -0.183402 -0.590825 -0.187286 0 0 0 0.00281905 l
+0.851409 -0.275331 0.863974 -0.278111 0 0 0 0.00281905 l
+0.851409 -0.275331 0.84093 -0.273735 0 0 0 0.00281905 l
+-0.0482593 -0.088062 -0.0458544 -0.0798258 0 0 0 0.00281905 l
+-0.0482593 -0.088062 -0.0495994 -0.0916137 0 0 0 0.00281905 l
+-0.422156 -0.0566317 -0.422004 -0.0594418 0 0 0 0.00281905 l
+-0.422156 -0.0566317 -0.418141 -0.0422675 0 0 0 0.00281905 l
+0.45813 -0.605 0.461054 -0.587427 0 0 0 0.00281905 l
+0.45813 -0.605 0.473387 -0.607185 0 0 0 0.00281905 l
+0.45813 -0.605 0.444944 -0.612455 0 0 0 0.00281905 l
+0.011891 0.335676 0.0132111 0.33875 0 0 0 0.00281905 l
+0.011891 0.335676 0.0119278 0.330984 0 0 0 0.00281905 l
+-0.282715 -0.444933 -0.287602 -0.429367 0 0 0 0.00281905 l
+-0.282715 -0.444933 -0.274216 -0.449205 0 0 0 0.00281905 l
+-0.282715 -0.444933 -0.291071 -0.453024 0 0 0 0.00281905 l
+0.787619 -0.221794 0.772144 -0.235277 0 0 0 0.00281905 l
+-0.363682 -0.919595 -0.362956 -0.903842 0 0 0 0.00281905 l
+-0.363682 -0.919595 -0.354315 -0.928944 0 0 0 0.00281905 l
+0.5287 0.670301 0.530515 0.679786 0 0 0 0.00281905 l
+0.5287 0.670301 0.520466 0.671158 0 0 0 0.00281905 l
+0.084802 0.835411 0.0986654 0.836064 0 0 0 0.00281905 l
+0.084802 0.835411 0.0835817 0.834695 0 0 0 0.00281905 l
+-0.0690447 0.67493 -0.072485 0.681238 0 0 0 0.00281905 l
+-0.0690447 0.67493 -0.0543427 0.668241 0 0 0 0.00281905 l
+-0.0690447 0.67493 -0.0741716 0.671743 0 0 0 0.00281905 l
+-0.625691 0.497352 -0.614596 0.515187 0 0 0 0.00281905 l
+-0.625691 0.497352 -0.635575 0.487345 0 0 0 0.00281905 l
+0.302843 -0.150034 0.298008 -0.151425 0 0 0 0.00281905 l
+0.447756 0.701132 0.456237 0.718632 0 0 0 0.00281905 l
+0.447756 0.701132 0.434014 0.702679 0 0 0 0.00281905 l
+-0.313413 0.19571 -0.308068 0.190053 0 0 0 0.00281905 l
+-0.313413 0.19571 -0.322386 0.197223 0 0 0 0.00281905 l
+-0.697551 0.653721 -0.692255 0.637237 0 0 0 0.00281905 l
+-0.697551 0.653721 -0.681561 0.665741 0 0 0 0.00281905 l
+0.10902 0.433741 0.113645 0.423784 0 0 0 0.00281905 l
+0.10902 0.433741 0.103112 0.447991 0 0 0 0.00281905 l
+0.743666 0.57619 0.734283 0.590491 0 0 0 0.00281905 l
+0.743666 0.57619 0.736284 0.56782 0 0 0 0.00281905 l
+-0.406908 -0.100988 -0.40367 -0.110635 0 0 0 0.00281905 l
+0.225058 -0.299026 0.233736 -0.289843 0 0 0 0.00281905 l
+0.225058 -0.299026 0.226722 -0.308196 0 0 0 0.00281905 l
+0.225058 -0.299026 0.217154 -0.288137 0 0 0 0.00281905 l
+-0.565435 -0.452104 -0.564954 -0.45722 0 0 0 0.00281905 l
+-0.565435 -0.452104 -0.555229 -0.442267 0 0 0 0.00281905 l
+0.00622981 -0.263785 0.0209484 -0.265892 0 0 0 0.00281905 l
+0.00622981 -0.263785 -0.00257454 -0.266219 0 0 0 0.00281905 l
+0.146919 0.649459 0.15019 0.64532 0 0 0 0.00281905 l
+0.146919 0.649459 0.135443 0.661927 0 0 0 0.00281905 l
+-0.239186 -0.068198 -0.239081 -0.0619393 0 0 0 0.00281905 l
+-0.116723 -0.0085806 -0.118116 0.00390034 0 0 0 0.00281905 l
+-0.116723 -0.0085806 -0.103904 -0.0118689 0 0 0 0.00281905 l
+-0.116723 -0.0085806 -0.119486 -0.00896643 0 0 0 0.00281905 l
+0.484448 0.306933 0.479696 0.319038 0 0 0 0.00281905 l
+0.484448 0.306933 0.487859 0.307611 0 0 0 0.00281905 l
+0.484448 0.306933 0.483999 0.299126 0 0 0 0.00281905 l
+-0.198903 -0.597679 -0.200865 -0.589863 0 0 0 0.00281905 l
+-0.198903 -0.597679 -0.188053 -0.599009 0 0 0 0.00281905 l
+0.899947 -0.243244 0.895225 -0.218053 0 0 0 0.00281905 l
+0.899947 -0.243244 0.919859 -0.24223 0 0 0 0.00281905 l
+-0.737244 -0.219545 -0.727426 -0.228087 0 0 0 0.00281905 l
+0.295553 0.121061 0.29942 0.111802 0 0 0 0.00281905 l
+0.295553 0.121061 0.292883 0.12219 0 0 0 0.00281905 l
+0.799095 0.0488866 0.801541 0.0500827 0 0 0 0.00281905 l
+0.799095 0.0488866 0.788237 0.0539035 0 0 0 0.00281905 l
+0.114121 -0.204832 0.120412 -0.201425 0 0 0 0.00281905 l
+-0.784377 -0.333521 -0.774956 -0.328259 0 0 0 0.00281905 l
+-0.784377 -0.333521 -0.791297 -0.349648 0 0 0 0.00281905 l
+-0.784377 -0.333521 -0.79226 -0.328192 0 0 0 0.00281905 l
+-0.862027 -0.192096 -0.861399 -0.191507 0 0 0 0.00281905 l
+-0.862027 -0.192096 -0.876741 -0.182791 0 0 0 0.00281905 l
+-0.0287266 -0.0982455 -0.0303317 -0.107029 0 0 0 0.00281905 l
+-0.0287266 -0.0982455 -0.02841 -0.0909643 0 0 0 0.00281905 l
+-0.752681 0.101229 -0.762908 0.0832709 0 0 0 0.00281905 l
+-0.752681 0.101229 -0.74129 0.10342 0 0 0 0.00281905 l
+-0.752681 0.101229 -0.753698 0.11143 0 0 0 0.00281905 l
+0.848908 0.107126 0.853608 0.119333 0 0 0 0.00281905 l
+0.848908 0.107126 0.862012 0.103055 0 0 0 0.00281905 l
+0.848908 0.107126 0.84792 0.0914489 0 0 0 0.00281905 l
+0.848908 0.107126 0.840439 0.111089 0 0 0 0.00281905 l
+0.139271 -0.711176 0.157154 -0.716511 0 0 0 0.00281905 l
+0.139271 -0.711176 0.140905 -0.696421 0 0 0 0.00281905 l
+0.139271 -0.711176 0.132638 -0.71147 0 0 0 0.00281905 l
+-0.450532 0.30139 -0.451442 0.303744 0 0 0 0.00281905 l
+-0.56289 -0.758974 -0.554379 -0.741309 0 0 0 0.00281905 l
+-0.56289 -0.758974 -0.565709 -0.76565 0 0 0 0.00281905 l
+-0.142645 0.0789173 -0.141746 0.0601798 0 0 0 0.00281905 l
+-0.142645 0.0789173 -0.149449 0.0790038 0 0 0 0.00281905 l
+0.26467 0.719879 0.251334 0.73339 0 0 0 0.00281905 l
+0.26467 0.719879 0.264493 0.713747 0 0 0 0.00281905 l
+-0.430739 0.460578 -0.426112 0.459472 0 0 0 0.00281905 l
+-0.653705 0.750969 -0.647852 0.733913 0 0 0 0.00281905 l
+-0.101912 -0.197872 -0.105063 -0.176941 0 0 0 0.00281905 l
+-0.101912 -0.197872 -0.104369 -0.205854 0 0 0 0.00281905 l
+-0.468261 0.119814 -0.463232 0.123319 0 0 0 0.00281905 l
+-0.468261 0.119814 -0.462931 0.10329 0 0 0 0.00281905 l
+-0.468261 0.119814 -0.469832 0.125438 0 0 0 0.00281905 l
+-0.00719245 0.547822 -0.0241475 0.550379 0 0 0 0.00281905 l
+-0.312802 -0.893684 -0.304193 -0.87692 0 0 0 0.00281905 l
+-0.312802 -0.893684 -0.302516 -0.905614 0 0 0 0.00281905 l
+0.798278 0.0781186 0.811676 0.0858651 0 0 0 0.00281905 l
+0.798278 0.0781186 0.7918 0.0742006 0 0 0 0.00281905 l
+-0.121834 -0.986263 -0.108568 -0.981433 0 0 0 0.00281905 l
+-0.121834 -0.986263 -0.129745 -0.974393 0 0 0 0.00281905 l
+0.41077 0.44138 0.411143 0.439133 0 0 0 0.00281905 l
+-0.544439 0.287166 -0.534309 0.288488 0 0 0 0.00281905 l
+-0.544439 0.287166 -0.548204 0.290605 0 0 0 0.00281905 l
+0.151419 0.937909 0.160706 0.958272 0 0 0 0.00281905 l
+0.151419 0.937909 0.149476 0.93484 0 0 0 0.00281905 l
+-0.141452 0.671772 -0.146203 0.654434 0 0 0 0.00281905 l
+0.447165 0.249694 0.443774 0.260506 0 0 0 0.00281905 l
+0.447165 0.249694 0.455927 0.246693 0 0 0 0.00281905 l
+-0.467981 0.228418 -0.467719 0.217923 0 0 0 0.00281905 l
+-0.467981 0.228418 -0.46323 0.235681 0 0 0 0.00281905 l
+-0.40371 0.383043 -0.390089 0.37438 0 0 0 0.00281905 l
+-0.40371 0.383043 -0.415126 0.382355 0 0 0 0.00281905 l
+-0.237351 -0.42636 -0.240365 -0.4214 0 0 0 0.00281905 l
+0.204457 -0.125821 0.210368 -0.109028 0 0 0 0.00281905 l
+0.204457 -0.125821 0.21607 -0.130596 0 0 0 0.00281905 l
+0.204457 -0.125821 0.199872 -0.13929 0 0 0 0.00281905 l
+0.326571 0.0222512 0.341686 0.0127917 0 0 0 0.00281905 l
+0.326571 0.0222512 0.319327 0.0353932 0 0 0 0.00281905 l
+0.326571 0.0222512 0.311135 0.0208179 0 0 0 0.00281905 l
+0.0831824 -0.824587 0.0814796 -0.839098 0 0 0 0.00281905 l
+0.0831824 -0.824587 0.0843934 -0.818033 0 0 0 0.00281905 l
+-0.194774 0.638666 -0.188857 0.633777 0 0 0 0.00281905 l
+-0.194774 0.638666 -0.204529 0.633706 0 0 0 0.00281905 l
+-0.521767 -0.0299253 -0.514843 -0.0302298 0 0 0 0.00281905 l
+-0.521767 -0.0299253 -0.521148 -0.0434508 0 0 0 0.00281905 l
+0.101318 0.331449 0.114991 0.321222 0 0 0 0.00281905 l
+0.101318 0.331449 0.0984295 0.334889 0 0 0 0.00281905 l
+0.20979 0.398424 0.217039 0.396332 0 0 0 0.00281905 l
+0.20979 0.398424 0.198372 0.396263 0 0 0 0.00281905 l
+-0.417619 -0.697159 -0.404718 -0.692682 0 0 0 0.00281905 l
+-0.417619 -0.697159 -0.430726 -0.689184 0 0 0 0.00281905 l
+-0.314278 0.561054 -0.304261 0.581993 0 0 0 0.00281905 l
+-0.139104 -0.387702 -0.138074 -0.390706 0 0 0 0.00281905 l
+0.243901 -0.642405 0.23657 -0.652371 0 0 0 0.00281905 l
+0.243901 -0.642405 0.235084 -0.630485 0 0 0 0.00281905 l
+0.702572 0.113352 0.703811 0.104289 0 0 0 0.00281905 l
+0.702572 0.113352 0.704755 0.121388 0 0 0 0.00281905 l
+0.702572 0.113352 0.695318 0.117938 0 0 0 0.00281905 l
+0.550505 -0.140489 0.553445 -0.141611 0 0 0 0.00281905 l
+0.550505 -0.140489 0.540055 -0.135527 0 0 0 0.00281905 l
+-0.538924 -0.564821 -0.530217 -0.568193 0 0 0 0.00281905 l
+-0.538924 -0.564821 -0.542721 -0.576151 0 0 0 0.00281905 l
+0.193884 -0.861234 0.195562 -0.859029 0 0 0 0.00281905 l
+0.193884 -0.861234 0.173734 -0.851037 0 0 0 0.00281905 l
+-0.245785 -0.627513 -0.232439 -0.63291 0 0 0 0.00281905 l
+-0.233851 0.271721 -0.231573 0.257244 0 0 0 0.00281905 l
+-0.233851 0.271721 -0.241008 0.27807 0 0 0 0.00281905 l
+0.0377893 0.841139 0.0494847 0.840127 0 0 0 0.00281905 l
+0.0377893 0.841139 0.0377139 0.832649 0 0 0 0.00281905 l
+0.385682 0.827492 0.387689 0.837541 0 0 0 0.00281905 l
+0.385682 0.827492 0.385491 0.815361 0 0 0 0.00281905 l
+0.385682 0.827492 0.374748 0.828994 0 0 0 0.00281905 l
+0.529654 0.753657 0.513731 0.753167 0 0 0 0.00281905 l
+0.529654 0.753657 0.530753 0.755734 0 0 0 0.00281905 l
+0.196303 -0.212149 0.19566 -0.230072 0 0 0 0.00281905 l
+0.196303 -0.212149 0.196177 -0.205125 0 0 0 0.00281905 l
+-0.212365 -0.787524 -0.203619 -0.79095 0 0 0 0.00281905 l
+-0.212365 -0.787524 -0.214146 -0.78334 0 0 0 0.00281905 l
+-0.144677 -0.813505 -0.150862 -0.832692 0 0 0 0.00281905 l
+-0.144677 -0.813505 -0.151604 -0.812524 0 0 0 0.00281905 l
+0.450227 0.0584916 0.465194 0.0679942 0 0 0 0.00281905 l
+0.450227 0.0584916 0.4437 0.063868 0 0 0 0.00281905 l
+0.343835 -0.77322 0.355891 -0.769312 0 0 0 0.00281905 l
+-0.587661 0.797405 -0.576103 0.793548 0 0 0 0.00281905 l
+-0.587661 0.797405 -0.59918 0.798177 0 0 0 0.00281905 l
+-0.523933 0.441905 -0.512125 0.446648 0 0 0 0.00281905 l
+-0.523933 0.441905 -0.523328 0.440596 0 0 0 0.00281905 l
+-0.0316595 -0.195496 -0.0256082 -0.206207 0 0 0 0.00281905 l
+-0.0316595 -0.195496 -0.0433082 -0.199543 0 0 0 0.00281905 l
+0.877436 -0.398377 0.880723 -0.40095 0 0 0 0.00281905 l
+0.877436 -0.398377 0.868956 -0.404247 0 0 0 0.00281905 l
+0.0670361 0.313223 0.069758 0.313959 0 0 0 0.00281905 l
+0.0670361 0.313223 0.0598332 0.316798 0 0 0 0.00281905 l
+-0.28819 0.888932 -0.295968 0.906392 0 0 0 0.00281905 l
+-0.28819 0.888932 -0.271482 0.879961 0 0 0 0.00281905 l
+-0.28819 0.888932 -0.305265 0.875124 0 0 0 0.00281905 l
+-0.815881 0.18919 -0.822478 0.171334 0 0 0 0.00281905 l
+-0.815881 0.18919 -0.813272 0.210077 0 0 0 0.00281905 l
+0.0367698 0.12497 0.0446075 0.132718 0 0 0 0.00281905 l
+0.0367698 0.12497 0.0369058 0.120098 0 0 0 0.00281905 l
+-0.55448 0.487851 -0.550561 0.501987 0 0 0 0.00281905 l
+0.166973 0.811501 0.167802 0.802793 0 0 0 0.00281905 l
+0.166973 0.811501 0.147297 0.806542 0 0 0 0.00281905 l
+-0.25786 -0.16767 -0.246898 -0.172155 0 0 0 0.00281905 l
+-0.25786 -0.16767 -0.263914 -0.169389 0 0 0 0.00281905 l
+0.000446392 -0.817143 0.00823022 -0.827218 0 0 0 0.00281905 l
+0.000446392 -0.817143 -0.0116695 -0.812113 0 0 0 0.00281905 l
+-0.420201 -0.279309 -0.418711 -0.285416 0 0 0 0.00281905 l
+-0.420201 -0.279309 -0.419727 -0.264939 0 0 0 0.00281905 l
+-0.874449 -0.347159 -0.874466 -0.347796 0 0 0 0.00281905 l
+-0.874449 -0.347159 -0.888128 -0.340012 0 0 0 0.00281905 l
+0.446909 -0.584374 0.438339 -0.569736 0 0 0 0.00281905 l
+0.446909 -0.584374 0.449588 -0.586252 0 0 0 0.00281905 l
+-0.664714 0.525696 -0.668451 0.535473 0 0 0 0.00281905 l
+-0.664714 0.525696 -0.652152 0.508881 0 0 0 0.00281905 l
+0.620507 0.748928 0.627785 0.749832 0 0 0 0.00281905 l
+0.620507 0.748928 0.614052 0.75225 0 0 0 0.00281905 l
+-0.311092 -0.0578662 -0.313403 -0.044924 0 0 0 0.00281905 l
+-0.311092 -0.0578662 -0.310977 -0.0733723 0 0 0 0.00281905 l
+-0.311092 -0.0578662 -0.316533 -0.0584141 0 0 0 0.00281905 l
+0.0264703 0.415852 0.0294556 0.413847 0 0 0 0.00281905 l
+0.752873 -0.0158843 0.75759 -0.00719115 0 0 0 0.00281905 l
+0.752873 -0.0158843 0.74845 -0.0198284 0 0 0 0.00281905 l
+-0.381436 -0.142291 -0.38004 -0.142378 0 0 0 0.00281905 l
+-0.381436 -0.142291 -0.387994 -0.151597 0 0 0 0.00281905 l
+0.29588 0.636024 0.297288 0.643016 0 0 0 0.00281905 l
+0.29588 0.636024 0.304278 0.635915 0 0 0 0.00281905 l
+0.29588 0.636024 0.284461 0.630031 0 0 0 0.00281905 l
+-0.428002 -0.231154 -0.431104 -0.213447 0 0 0 0.00281905 l
+-0.428002 -0.231154 -0.425682 -0.246788 0 0 0 0.00281905 l
+-0.49451 -0.59806 -0.493124 -0.609856 0 0 0 0.00281905 l
+-0.49451 -0.59806 -0.490438 -0.58716 0 0 0 0.00281905 l
+-0.126849 0.508265 -0.125444 0.504397 0 0 0 0.00281905 l
+0.231858 -0.420454 0.24186 -0.425128 0 0 0 0.00281905 l
+0.231858 -0.420454 0.222964 -0.408546 0 0 0 0.00281905 l
+0.383175 0.0244977 0.385055 0.0182855 0 0 0 0.00281905 l
+0.383175 0.0244977 0.381545 0.0280405 0 0 0 0.00281905 l
+-0.224764 -0.826819 -0.223244 -0.826366 0 0 0 0.00281905 l
+-0.224764 -0.826819 -0.230167 -0.823515 0 0 0 0.00281905 l
+0.0414452 0.0816184 0.0268152 0.0687403 0 0 0 0.00281905 l
+0.460559 -0.13698 0.459135 -0.126023 0 0 0 0.00281905 l
+0.460559 -0.13698 0.475469 -0.132497 0 0 0 0.00281905 l
+-0.790316 -0.00037791 -0.790245 -0.00726669 0 0 0 0.00281905 l
+-0.790316 -0.00037791 -0.792629 0.000729275 0 0 0 0.00281905 l
+-0.415853 0.636459 -0.409234 0.623312 0 0 0 0.00281905 l
+0.726389 0.612936 0.726247 0.610468 0 0 0 0.00281905 l
+0.726389 0.612936 0.728455 0.617817 0 0 0 0.00281905 l
+-0.314749 -0.713841 -0.311918 -0.712942 0 0 0 0.00281905 l
+-0.314749 -0.713841 -0.317264 -0.715457 0 0 0 0.00281905 l
+-0.5644 0.00387959 -0.571891 -0.00366643 0 0 0 0.00281905 l
+-0.5644 0.00387959 -0.547855 0.0058834 0 0 0 0.00281905 l
+-0.5644 0.00387959 -0.566709 0.00698378 0 0 0 0.00281905 l
+-0.232116 0.887858 -0.235964 0.901786 0 0 0 0.00281905 l
+-0.232116 0.887858 -0.234911 0.885979 0 0 0 0.00281905 l
+-0.154869 -0.171139 -0.136095 -0.16405 0 0 0 0.00281905 l
+-0.154869 -0.171139 -0.157328 -0.171435 0 0 0 0.00281905 l
+0.234986 0.851129 0.225906 0.843946 0 0 0 0.00281905 l
+-0.750934 -0.597682 -0.761757 -0.580824 0 0 0 0.00281905 l
+-0.750934 -0.597682 -0.753516 -0.602405 0 0 0 0.00281905 l
+0.694669 0.0801293 0.710869 0.0822651 0 0 0 0.00281905 l
+0.694669 0.0801293 0.68259 0.0768876 0 0 0 0.00281905 l
+-0.661095 0.288527 -0.669259 0.285991 0 0 0 0.00281905 l
+0.0245737 -0.542746 0.0225929 -0.537784 0 0 0 0.00281905 l
+-0.118721 -0.655345 -0.117615 -0.664964 0 0 0 0.00281905 l
+-0.118721 -0.655345 -0.11269 -0.651261 0 0 0 0.00281905 l
+-0.118721 -0.655345 -0.128671 -0.643142 0 0 0 0.00281905 l
+0.307182 -0.752621 0.306613 -0.757377 0 0 0 0.00281905 l
+0.307182 -0.752621 0.29665 -0.741865 0 0 0 0.00281905 l
+0.632859 -0.353386 0.636845 -0.360033 0 0 0 0.00281905 l
+0.632859 -0.353386 0.62589 -0.34901 0 0 0 0.00281905 l
+0.198352 -0.493075 0.205965 -0.501941 0 0 0 0.00281905 l
+0.652438 0.145722 0.662696 0.144497 0 0 0 0.00281905 l
+0.652438 0.145722 0.649502 0.150461 0 0 0 0.00281905 l
+0.0221515 -0.188089 0.0338978 -0.194606 0 0 0 0.00281905 l
+0.0221515 -0.188089 0.0101882 -0.177811 0 0 0 0.00281905 l
+-0.020388 0.0119641 -0.0213929 0.0238491 0 0 0 0.00281905 l
+-0.020388 0.0119641 -0.027122 -0.000579469 0 0 0 0.00281905 l
+-0.613174 0.32571 -0.604729 0.306591 0 0 0 0.00281905 l
+-0.613174 0.32571 -0.618712 0.336219 0 0 0 0.00281905 l
+-0.613174 0.32571 -0.628293 0.319531 0 0 0 0.00281905 l
+0.105282 0.309599 0.113223 0.314989 0 0 0 0.00281905 l
+0.105282 0.309599 0.0923415 0.308757 0 0 0 0.00281905 l
+0.467739 -0.684046 0.482189 -0.691722 0 0 0 0.00281905 l
+0.467739 -0.684046 0.452094 -0.675875 0 0 0 0.00281905 l
+-0.534083 0.484642 -0.531972 0.495561 0 0 0 0.00281905 l
+-0.534083 0.484642 -0.539093 0.479564 0 0 0 0.00281905 l
+-0.689062 -0.280872 -0.688497 -0.269883 0 0 0 0.00281905 l
+-0.689062 -0.280872 -0.681757 -0.28589 0 0 0 0.00281905 l
+0.324524 0.628217 0.330746 0.623265 0 0 0 0.00281905 l
+0.324524 0.628217 0.321754 0.631699 0 0 0 0.00281905 l
+-0.689781 -0.517476 -0.700245 -0.49365 0 0 0 0.00281905 l
+-0.472065 -0.466637 -0.469842 -0.455161 0 0 0 0.00281905 l
+-0.472065 -0.466637 -0.469206 -0.484257 0 0 0 0.00281905 l
+0.0773221 -0.699957 0.0913035 -0.68681 0 0 0 0.00281905 l
+0.0773221 -0.699957 0.0652994 -0.701298 0 0 0 0.00281905 l
+-0.550987 -0.202089 -0.55041 -0.218037 0 0 0 0.00281905 l
+-0.550987 -0.202089 -0.555066 -0.201816 0 0 0 0.00281905 l
+-0.548876 0.390544 -0.558546 0.399118 0 0 0 0.00281905 l
+-0.548876 0.390544 -0.543145 0.397263 0 0 0 0.00281905 l
+-0.548876 0.390544 -0.559607 0.383472 0 0 0 0.00281905 l
+-0.229091 -0.135995 -0.230286 -0.127473 0 0 0 0.00281905 l
+-0.229091 -0.135995 -0.216883 -0.14132 0 0 0 0.00281905 l
+0.306692 -0.689056 0.309897 -0.691342 0 0 0 0.00281905 l
+0.306692 -0.689056 0.302004 -0.688305 0 0 0 0.00281905 l
+-0.614797 -0.60887 -0.607822 -0.605823 0 0 0 0.00281905 l
+-0.614797 -0.60887 -0.61382 -0.610664 0 0 0 0.00281905 l
+-0.786604 0.312412 -0.78091 0.301576 0 0 0 0.00281905 l
+-0.786604 0.312412 -0.801219 0.302154 0 0 0 0.00281905 l
+-0.786604 0.312412 -0.787762 0.314705 0 0 0 0.00281905 l
+0.0352411 -0.41986 0.0297063 -0.430098 0 0 0 0.00281905 l
+0.0352411 -0.41986 0.0287167 -0.412798 0 0 0 0.00281905 l
+-0.527454 0.70739 -0.527698 0.703046 0 0 0 0.00281905 l
+-0.527454 0.70739 -0.525497 0.710533 0 0 0 0.00281905 l
+0.821864 -0.105424 0.83546 -0.101297 0 0 0 0.00281905 l
+0.821864 -0.105424 0.816767 -0.109355 0 0 0 0.00281905 l
+-0.697747 -0.632855 -0.692573 -0.626879 0 0 0 0.00281905 l
+-0.697747 -0.632855 -0.697241 -0.637901 0 0 0 0.00281905 l
+-0.949518 -0.029842 -0.950454 -0.0405042 0 0 0 0.00281905 l
+-0.949518 -0.029842 -0.943287 -0.0224447 0 0 0 0.00281905 l
+-0.949518 -0.029842 -0.952215 -0.027516 0 0 0 0.00281905 l
+0.0192621 -0.802804 0.0207839 -0.782327 0 0 0 0.00281905 l
+0.0192621 -0.802804 0.0289148 -0.822333 0 0 0 0.00281905 l
+0.335338 -0.857753 0.337385 -0.83835 0 0 0 0.00281905 l
+0.335338 -0.857753 0.350031 -0.860059 0 0 0 0.00281905 l
+-0.357251 -0.453361 -0.349775 -0.455934 0 0 0 0.00281905 l
+0.653593 -0.312451 0.654317 -0.328948 0 0 0 0.00281905 l
+0.653593 -0.312451 0.659346 -0.308518 0 0 0 0.00281905 l
+0.173396 -0.911077 0.174375 -0.896239 0 0 0 0.00281905 l
+0.173396 -0.911077 0.154088 -0.904832 0 0 0 0.00281905 l
+-0.370429 0.571241 -0.372858 0.566488 0 0 0 0.00281905 l
+0.204418 0.832115 0.214454 0.839349 0 0 0 0.00281905 l
+0.204418 0.832115 0.189765 0.832063 0 0 0 0.00281905 l
+0.47232 -0.722985 0.474213 -0.729717 0 0 0 0.00281905 l
+0.47232 -0.722985 0.464252 -0.722301 0 0 0 0.00281905 l
+-0.555616 0.286031 -0.548204 0.290605 0 0 0 0.00281905 l
+-0.555616 0.286031 -0.560916 0.282578 0 0 0 0.00281905 l
+-0.468484 -0.549982 -0.466397 -0.538827 0 0 0 0.00281905 l
+-0.468484 -0.549982 -0.467018 -0.557025 0 0 0 0.00281905 l
+0.410191 0.764462 0.413568 0.752051 0 0 0 0.00281905 l
+0.410191 0.764462 0.414591 0.783417 0 0 0 0.00281905 l
+0.410191 0.764462 0.393776 0.769831 0 0 0 0.00281905 l
+0.780572 -0.529739 0.781743 -0.532412 0 0 0 0.00281905 l
+0.780572 -0.529739 0.767743 -0.516798 0 0 0 0.00281905 l
+-0.172077 0.47877 -0.182278 0.478683 0 0 0 0.00281905 l
+-0.272605 0.31303 -0.269692 0.321634 0 0 0 0.00281905 l
+-0.712821 -0.473273 -0.710684 -0.461057 0 0 0 0.00281905 l
+-0.712821 -0.473273 -0.703633 -0.478704 0 0 0 0.00281905 l
+-0.0912344 -0.320339 -0.10316 -0.330355 0 0 0 0.00281905 l
+-0.0912344 -0.320339 -0.102103 -0.307197 0 0 0 0.00281905 l
+-0.415226 -0.143689 -0.417557 -0.148388 0 0 0 0.00281905 l
+0.861334 -0.0157504 0.867316 -0.0203235 0 0 0 0.00281905 l
+0.861334 -0.0157504 0.85635 -0.0139479 0 0 0 0.00281905 l
+0.861334 -0.0157504 0.864351 -0.0133905 0 0 0 0.00281905 l
+0.381433 -0.436474 0.391432 -0.424896 0 0 0 0.00281905 l
+0.381433 -0.436474 0.367429 -0.446403 0 0 0 0.00281905 l
+-0.11671 -0.956021 -0.121182 -0.971737 0 0 0 0.00281905 l
+-0.11671 -0.956021 -0.106219 -0.948816 0 0 0 0.00281905 l
+-0.11671 -0.956021 -0.135957 -0.945604 0 0 0 0.00281905 l
+0.018374 -0.976908 0.0188294 -0.973239 0 0 0 0.00281905 l
+0.018374 -0.976908 0.0204966 -0.978261 0 0 0 0.00281905 l
+0.018374 -0.976908 0.00606472 -0.974154 0 0 0 0.00281905 l
+0.0752201 -0.921786 0.0663631 -0.903446 0 0 0 0.00281905 l
+0.0752201 -0.921786 0.0867214 -0.927503 0 0 0 0.00281905 l
+0.135229 -0.546584 0.124297 -0.534294 0 0 0 0.00281905 l
+0.135229 -0.546584 0.122061 -0.555125 0 0 0 0.00281905 l
+0.75759 -0.00719115 0.774844 -0.00520352 0 0 0 0.00281905 l
+0.75759 -0.00719115 0.752873 -0.0158843 0 0 0 0.00281905 l
+0.0410285 -0.638444 0.0565057 -0.642049 0 0 0 0.00281905 l
+0.0410285 -0.638444 0.0336093 -0.632856 0 0 0 0.00281905 l
+0.330746 0.623265 0.338724 0.62263 0 0 0 0.00281905 l
+0.330746 0.623265 0.33267 0.610885 0 0 0 0.00281905 l
+0.330746 0.623265 0.324524 0.628217 0 0 0 0.00281905 l
+0.779152 -0.509239 0.775951 -0.510103 0 0 0 0.00281905 l
+-0.734186 -0.427437 -0.735877 -0.440541 0 0 0 0.00281905 l
+-0.734186 -0.427437 -0.724544 -0.423067 0 0 0 0.00281905 l
+-0.734186 -0.427437 -0.742815 -0.42219 0 0 0 0.00281905 l
+-0.754327 0.33521 -0.738605 0.320925 0 0 0 0.00281905 l
+0.893483 0.0929721 0.899766 0.0965962 0 0 0 0.00281905 l
+0.893483 0.0929721 0.875383 0.0989741 0 0 0 0.00281905 l
+0.507029 0.228012 0.50948 0.209617 0 0 0 0.00281905 l
+0.507029 0.228012 0.518657 0.232429 0 0 0 0.00281905 l
+0.507029 0.228012 0.50193 0.232878 0 0 0 0.00281905 l
+-0.72219 -0.0990526 -0.706291 -0.1071 0 0 0 0.00281905 l
+-0.72219 -0.0990526 -0.728405 -0.112601 0 0 0 0.00281905 l
+-0.72219 -0.0990526 -0.731631 -0.0867363 0 0 0 0.00281905 l
+0.136857 -0.22625 0.145019 -0.227688 0 0 0 0.00281905 l
+0.136857 -0.22625 0.135331 -0.237195 0 0 0 0.00281905 l
+0.136857 -0.22625 0.127092 -0.225204 0 0 0 0.00281905 l
+-0.22559 0.545963 -0.212971 0.56137 0 0 0 0.00281905 l
+-0.22559 0.545963 -0.23291 0.545206 0 0 0 0.00281905 l
+-0.12631 0.608985 -0.118973 0.609435 0 0 0 0.00281905 l
+-0.12631 0.608985 -0.128345 0.604697 0 0 0 0.00281905 l
+0.683385 -0.145998 0.680328 -0.128861 0 0 0 0.00281905 l
+0.683385 -0.145998 0.702178 -0.139947 0 0 0 0.00281905 l
+0.683385 -0.145998 0.667325 -0.149863 0 0 0 0.00281905 l
+-0.923842 0.323723 -0.912446 0.321063 0 0 0 0.00281905 l
+-0.463132 -0.690768 -0.462837 -0.702149 0 0 0 0.00281905 l
+-0.463132 -0.690768 -0.482092 -0.680818 0 0 0 0.00281905 l
+0.628479 -0.164132 0.615717 -0.163799 0 0 0 0.00281905 l
+-0.410324 -0.299672 -0.407674 -0.300619 0 0 0 0.00281905 l
+-0.410324 -0.299672 -0.413061 -0.295541 0 0 0 0.00281905 l
+0.867346 -0.402381 0.868956 -0.404247 0 0 0 0.00281905 l
+-0.579759 0.504113 -0.569358 0.506199 0 0 0 0.00281905 l
+-0.779988 0.363388 -0.776007 0.356523 0 0 0 0.00281905 l
+-0.779988 0.363388 -0.770889 0.368695 0 0 0 0.00281905 l
+0.656959 -0.305592 0.648165 -0.294344 0 0 0 0.00281905 l
+0.656959 -0.305592 0.659346 -0.308518 0 0 0 0.00281905 l
+-0.905592 0.287089 -0.907521 0.288084 0 0 0 0.00281905 l
+-0.547855 0.0058834 -0.536708 0.00752927 0 0 0 0.00281905 l
+-0.547855 0.0058834 -0.5644 0.00387959 0 0 0 0.00281905 l
+0.0590578 0.185736 0.0608748 0.188779 0 0 0 0.00281905 l
+0.0590578 0.185736 0.0598513 0.185305 0 0 0 0.00281905 l
+-0.473274 0.247653 -0.468892 0.254386 0 0 0 0.00281905 l
+-0.473274 0.247653 -0.469971 0.244123 0 0 0 0.00281905 l
+-0.473274 0.247653 -0.48158 0.255778 0 0 0 0.00281905 l
+0.853817 -0.497713 0.839425 -0.508671 0 0 0 0.00281905 l
+-0.362215 -0.153335 -0.362233 -0.162009 0 0 0 0.00281905 l
+-0.362215 -0.153335 -0.34493 -0.1493 0 0 0 0.00281905 l
+-0.405152 0.505631 -0.406518 0.51009 0 0 0 0.00281905 l
+-0.652297 0.407991 -0.655543 0.399722 0 0 0 0.00281905 l
+-0.652297 0.407991 -0.645632 0.409667 0 0 0 0.00281905 l
+-0.652297 0.407991 -0.653032 0.410949 0 0 0 0.00281905 l
+-0.00246756 0.970526 0.0104353 0.98587 0 0 0 0.00281905 l
+-0.00246756 0.970526 -0.0178889 0.985 0 0 0 0.00281905 l
+-0.729942 -0.567026 -0.732572 -0.548888 0 0 0 0.00281905 l
+-0.729942 -0.567026 -0.739787 -0.574122 0 0 0 0.00281905 l
+0.142775 0.727129 0.145121 0.725514 0 0 0 0.00281905 l
+-0.378448 0.913009 -0.377541 0.887044 0 0 0 0.00281905 l
+-0.207844 0.567401 -0.207374 0.576815 0 0 0 0.00281905 l
+-0.207844 0.567401 -0.188323 0.56668 0 0 0 0.00281905 l
+-0.207844 0.567401 -0.211322 0.564725 0 0 0 0.00281905 l
+0.358801 0.783147 0.374876 0.781573 0 0 0 0.00281905 l
+0.358801 0.783147 0.356206 0.783891 0 0 0 0.00281905 l
+0.809168 -0.108243 0.816767 -0.109355 0 0 0 0.00281905 l
+0.809168 -0.108243 0.798083 -0.111485 0 0 0 0.00281905 l
+0.299733 0.236217 0.301517 0.219778 0 0 0 0.00281905 l
+0.299733 0.236217 0.289469 0.235821 0 0 0 0.00281905 l
+-0.38346 -0.215206 -0.385279 -0.206878 0 0 0 0.00281905 l
+-0.38346 -0.215206 -0.373365 -0.214269 0 0 0 0.00281905 l
+-0.38346 -0.215206 -0.397883 -0.219108 0 0 0 0.00281905 l
+-0.0790234 0.843557 -0.0679275 0.8526 0 0 0 0.00281905 l
+-0.0790234 0.843557 -0.0857198 0.844553 0 0 0 0.00281905 l
+0.291984 -0.688813 0.302004 -0.688305 0 0 0 0.00281905 l
+0.291984 -0.688813 0.273374 -0.686645 0 0 0 0.00281905 l
+0.0677427 -0.348692 0.0607029 -0.328613 0 0 0 0.00281905 l
+0.0677427 -0.348692 0.0672503 -0.352912 0 0 0 0.00281905 l
+-0.334477 -0.68491 -0.33118 -0.696436 0 0 0 0.00281905 l
+-0.334477 -0.68491 -0.325687 -0.670572 0 0 0 0.00281905 l
+0.0809231 -0.0138637 0.0894244 -0.0234995 0 0 0 0.00281905 l
+0.0809231 -0.0138637 0.0674823 -0.00762229 0 0 0 0.00281905 l
+0.250663 -0.925477 0.248766 -0.919427 0 0 0 0.00281905 l
+0.250663 -0.925477 0.247063 -0.931912 0 0 0 0.00281905 l
+-0.44388 0.507345 -0.436385 0.500343 0 0 0 0.00281905 l
+-0.44388 0.507345 -0.446904 0.510684 0 0 0 0.00281905 l
+0.437093 -0.726236 0.432968 -0.716918 0 0 0 0.00281905 l
+0.437093 -0.726236 0.443349 -0.7284 0 0 0 0.00281905 l
+0.437093 -0.726236 0.420814 -0.730466 0 0 0 0.00281905 l
+-0.642314 0.624527 -0.63889 0.643781 0 0 0 0.00281905 l
+-0.642314 0.624527 -0.634342 0.620484 0 0 0 0.00281905 l
+-0.642314 0.624527 -0.647668 0.611357 0 0 0 0.00281905 l
+0.406847 0.0152008 0.408885 0.0119266 0 0 0 0.00281905 l
+0.406847 0.0152008 0.403434 0.0139576 0 0 0 0.00281905 l
+-0.734401 -0.17399 -0.740724 -0.158466 0 0 0 0.00281905 l
+-0.734401 -0.17399 -0.727751 -0.184077 0 0 0 0.00281905 l
+-0.0373656 -0.429175 -0.0166209 -0.430136 0 0 0 0.00281905 l
+0.519438 -0.458422 0.518363 -0.463744 0 0 0 0.00281905 l
+0.519438 -0.458422 0.517008 -0.443446 0 0 0 0.00281905 l
+0.565697 0.262735 0.576806 0.26792 0 0 0 0.00281905 l
+0.284461 0.630031 0.29588 0.636024 0 0 0 0.00281905 l
+0.284461 0.630031 0.282991 0.62965 0 0 0 0.00281905 l
+-0.642496 -0.521418 -0.624586 -0.516549 0 0 0 0.00281905 l
+0.159245 -0.322939 0.167196 -0.308028 0 0 0 0.00281905 l
+0.159245 -0.322939 0.172476 -0.328893 0 0 0 0.00281905 l
+0.159245 -0.322939 0.152326 -0.326305 0 0 0 0.00281905 l
+0.250854 0.480826 0.255432 0.472909 0 0 0 0.00281905 l
+0.250854 0.480826 0.250462 0.482529 0 0 0 0.00281905 l
+-0.349468 -0.447815 -0.349775 -0.455934 0 0 0 0.00281905 l
+0.534408 0.127824 0.533824 0.134311 0 0 0 0.00281905 l
+0.534408 0.127824 0.539256 0.126665 0 0 0 0.00281905 l
+-0.220971 0.389841 -0.213913 0.391491 0 0 0 0.00281905 l
+-0.220971 0.389841 -0.23543 0.38176 0 0 0 0.00281905 l
+0.992014 -0.115504 0.991026 -0.119659 0 0 0 0.00281905 l
+0.864427 -0.293363 0.864022 -0.301261 0 0 0 0.00281905 l
+0.864427 -0.293363 0.865791 -0.281962 0 0 0 0.00281905 l
+0.864427 -0.293363 0.875642 -0.290297 0 0 0 0.00281905 l
+-0.723295 0.17495 -0.710342 0.17499 0 0 0 0.00281905 l
+-0.723295 0.17495 -0.738376 0.16698 0 0 0 0.00281905 l
+-0.43249 -0.705028 -0.430726 -0.689184 0 0 0 0.00281905 l
+-0.797721 0.159704 -0.794919 0.146842 0 0 0 0.00281905 l
+-0.797721 0.159704 -0.821844 0.160754 0 0 0 0.00281905 l
+0.694848 0.535382 0.704437 0.534094 0 0 0 0.00281905 l
+0.694848 0.535382 0.684986 0.518294 0 0 0 0.00281905 l
+0.694848 0.535382 0.688649 0.539186 0 0 0 0.00281905 l
+0.0571581 0.292384 0.0502007 0.287193 0 0 0 0.00281905 l
+0.629067 0.572402 0.638397 0.541501 0 0 0 0.00281905 l
+0.666319 -0.104294 0.676012 -0.0919279 0 0 0 0.00281905 l
+-0.30873 0.0987135 -0.307804 0.0905935 0 0 0 0.00281905 l
+-0.30873 0.0987135 -0.303122 0.115551 0 0 0 0.00281905 l
+0.315655 0.928119 0.315353 0.919222 0 0 0 0.00281905 l
+0.315655 0.928119 0.328302 0.940271 0 0 0 0.00281905 l
+0.0764977 -0.426921 0.0773097 -0.42781 0 0 0 0.00281905 l
+0.0764977 -0.426921 0.0622207 -0.428878 0 0 0 0.00281905 l
+0.216515 -0.849599 0.208862 -0.865358 0 0 0 0.00281905 l
+0.283247 0.240802 0.274699 0.251315 0 0 0 0.00281905 l
+0.283247 0.240802 0.289469 0.235821 0 0 0 0.00281905 l
+0.814358 -0.425224 0.809348 -0.423396 0 0 0 0.00281905 l
+0.91469 -0.359928 0.92552 -0.368163 0 0 0 0.00281905 l
+0.91469 -0.359928 0.919033 -0.351044 0 0 0 0.00281905 l
+-0.640963 -0.207745 -0.63171 -0.209739 0 0 0 0.00281905 l
+-0.640963 -0.207745 -0.642313 -0.195259 0 0 0 0.00281905 l
+0.254938 -0.802915 0.273 -0.806206 0 0 0 0.00281905 l
+-0.648194 -0.354452 -0.646171 -0.36826 0 0 0 0.00281905 l
+-0.648194 -0.354452 -0.65288 -0.35266 0 0 0 0.00281905 l
+0.667703 -0.0710971 0.658796 -0.0585182 0 0 0 0.00281905 l
+0.667703 -0.0710971 0.680853 -0.076788 0 0 0 0.00281905 l
+-0.13404 0.00993114 -0.129088 0.00746886 0 0 0 0.00281905 l
+-0.13404 0.00993114 -0.147944 0.0157465 0 0 0 0.00281905 l
+-0.286646 -0.934078 -0.304081 -0.952198 0 0 0 0.00281905 l
+-0.286646 -0.934078 -0.284736 -0.932627 0 0 0 0.00281905 l
+-0.78091 0.301576 -0.786604 0.312412 0 0 0 0.00281905 l
+-0.78091 0.301576 -0.779921 0.289873 0 0 0 0.00281905 l
+-0.209381 -0.242097 -0.227558 -0.238459 0 0 0 0.00281905 l
+-0.209381 -0.242097 -0.208554 -0.238499 0 0 0 0.00281905 l
+-0.577285 0.233712 -0.573186 0.223237 0 0 0 0.00281905 l
+-0.577285 0.233712 -0.581937 0.230588 0 0 0 0.00281905 l
+0.51739 0.499235 0.511954 0.493328 0 0 0 0.00281905 l
+0.702178 -0.139947 0.713076 -0.12764 0 0 0 0.00281905 l
+0.702178 -0.139947 0.683385 -0.145998 0 0 0 0.00281905 l
+0.767458 -0.512872 0.775951 -0.510103 0 0 0 0.00281905 l
+0.767458 -0.512872 0.767743 -0.516798 0 0 0 0.00281905 l
+0.767458 -0.512872 0.754584 -0.511191 0 0 0 0.00281905 l
+0.451803 0.0831259 0.45799 0.0925421 0 0 0 0.00281905 l
+0.451803 0.0831259 0.465194 0.0679942 0 0 0 0.00281905 l
+0.854465 0.0627964 0.853307 0.0821561 0 0 0 0.00281905 l
+0.854465 0.0627964 0.86591 0.0603281 0 0 0 0.00281905 l
+0.854465 0.0627964 0.845524 0.0508683 0 0 0 0.00281905 l
+0.0776234 0.623132 0.0779409 0.627487 0 0 0 0.00281905 l
+0.0776234 0.623132 0.0659407 0.614678 0 0 0 0.00281905 l
+0.164503 0.790452 0.167802 0.802793 0 0 0 0.00281905 l
+0.164503 0.790452 0.178708 0.78354 0 0 0 0.00281905 l
+0.164503 0.790452 0.160395 0.787931 0 0 0 0.00281905 l
+0.81851 0.538493 0.83604 0.517486 0 0 0 0.00281905 l
+0.81851 0.538493 0.834886 0.545956 0 0 0 0.00281905 l
+0.312997 0.85912 0.31349 0.852219 0 0 0 0.00281905 l
+0.312997 0.85912 0.330056 0.867083 0 0 0 0.00281905 l
+0.312997 0.85912 0.310029 0.860656 0 0 0 0.00281905 l
+0.703983 0.637882 0.701928 0.645464 0 0 0 0.00281905 l
+0.703983 0.637882 0.711571 0.627407 0 0 0 0.00281905 l
+0.703983 0.637882 0.689006 0.633814 0 0 0 0.00281905 l
+0.506362 -0.0295732 0.520339 -0.0430718 0 0 0 0.00281905 l
+0.506362 -0.0295732 0.496382 -0.0258005 0 0 0 0.00281905 l
+-0.0277273 0.374333 -0.0382336 0.38314 0 0 0 0.00281905 l
+-0.0277273 0.374333 -0.0242019 0.369427 0 0 0 0.00281905 l
+0.263411 -0.274071 0.253131 -0.271794 0 0 0 0.00281905 l
+-0.705853 0.246135 -0.707755 0.259011 0 0 0 0.00281905 l
+-0.705853 0.246135 -0.709172 0.239374 0 0 0 0.00281905 l
+0.881755 -0.148765 0.881914 -0.143757 0 0 0 0.00281905 l
+0.881755 -0.148765 0.883458 -0.164857 0 0 0 0.00281905 l
+0.726686 -0.483091 0.726093 -0.473646 0 0 0 0.00281905 l
+0.309692 0.4896 0.314249 0.504321 0 0 0 0.00281905 l
+0.309692 0.4896 0.328711 0.491134 0 0 0 0.00281905 l
+0.619001 -0.719551 0.632179 -0.703072 0 0 0 0.00281905 l
+0.619001 -0.719551 0.622745 -0.723038 0 0 0 0.00281905 l
+0.619001 -0.719551 0.595041 -0.730904 0 0 0 0.00281905 l
+0.619001 -0.719551 0.607206 -0.705842 0 0 0 0.00281905 l
+0.434014 0.702679 0.447756 0.701132 0 0 0 0.00281905 l
+0.434014 0.702679 0.421521 0.709131 0 0 0 0.00281905 l
+0.429505 0.128192 0.422661 0.106506 0 0 0 0.00281905 l
+0.429505 0.128192 0.446644 0.129097 0 0 0 0.00281905 l
+0.429505 0.128192 0.425089 0.135096 0 0 0 0.00281905 l
+0.133892 0.296707 0.125309 0.308363 0 0 0 0.00281905 l
+0.133892 0.296707 0.12724 0.289268 0 0 0 0.00281905 l
+-0.779921 0.289873 -0.78091 0.301576 0 0 0 0.00281905 l
+-0.779921 0.289873 -0.76811 0.294511 0 0 0 0.00281905 l
+-0.19559 0.952831 -0.192892 0.935904 0 0 0 0.00281905 l
+-0.19559 0.952831 -0.186783 0.962533 0 0 0 0.00281905 l
+-0.985191 0.0126579 -0.994334 0.028406 0 0 0 0.00281905 l
+-0.985191 0.0126579 -0.974762 0.0230526 0 0 0 0.00281905 l
+-0.985191 0.0126579 -0.991399 0.00388385 0 0 0 0.00281905 l
+0.879704 0.0487943 0.879374 0.0548496 0 0 0 0.00281905 l
+0.216278 0.0357388 0.217524 0.0312718 0 0 0 0.00281905 l
+-0.153066 -0.00884505 -0.14568 -0.0132317 0 0 0 0.00281905 l
+-0.153066 -0.00884505 -0.160779 -0.019322 0 0 0 0.00281905 l
+-0.906424 -0.244679 -0.90338 -0.236517 0 0 0 0.00281905 l
+-0.906424 -0.244679 -0.907259 -0.248572 0 0 0 0.00281905 l
+-0.919607 -0.188173 -0.913074 -0.196854 0 0 0 0.00281905 l
+-0.919607 -0.188173 -0.909054 -0.181294 0 0 0 0.00281905 l
+-0.919607 -0.188173 -0.929391 -0.193952 0 0 0 0.00281905 l
+-0.492694 0.645639 -0.49281 0.648633 0 0 0 0.00281905 l
+-0.492694 0.645639 -0.472664 0.641365 0 0 0 0.00281905 l
+0.029335 -0.976844 0.0280003 -0.993834 0 0 0 0.00281905 l
+0.029335 -0.976844 0.0306859 -0.964871 0 0 0 0.00281905 l
+0.029335 -0.976844 0.0460058 -0.976684 0 0 0 0.00281905 l
+0.029335 -0.976844 0.0204966 -0.978261 0 0 0 0.00281905 l
+0.160262 -0.976401 0.163448 -0.982041 0 0 0 0.00281905 l
+0.160262 -0.976401 0.166248 -0.962485 0 0 0 0.00281905 l
+0.160262 -0.976401 0.151427 -0.98495 0 0 0 0.00281905 l
+0.292026 -0.674881 0.293906 -0.674426 0 0 0 0.00281905 l
+0.853869 -0.0499024 0.870428 -0.0593267 0 0 0 0.00281905 l
+0.853869 -0.0499024 0.850741 -0.057681 0 0 0 0.00281905 l
+-0.0693729 0.480832 -0.0711508 0.470514 0 0 0 0.00281905 l
+-0.0693729 0.480832 -0.0570988 0.487806 0 0 0 0.00281905 l
+-0.427558 0.718549 -0.425582 0.721772 0 0 0 0.00281905 l
+-0.427558 0.718549 -0.433315 0.713688 0 0 0 0.00281905 l
+0.393669 0.000324163 0.397841 0.0114409 0 0 0 0.00281905 l
+0.393669 0.000324163 0.398113 -0.00919072 0 0 0 0.00281905 l
+-0.641579 -0.0114108 -0.64726 -0.00504405 0 0 0 0.00281905 l
+-0.641579 -0.0114108 -0.630762 -0.0227757 0 0 0 0.00281905 l
+-0.6218 0.13006 -0.622426 0.127501 0 0 0 0.00281905 l
+-0.6218 0.13006 -0.61788 0.136657 0 0 0 0.00281905 l
+0.425736 0.228143 0.419142 0.228451 0 0 0 0.00281905 l
+-0.149111 0.981705 -0.126505 0.974443 0 0 0 0.00281905 l
+-0.149111 0.981705 -0.154907 0.972644 0 0 0 0.00281905 l
+-0.360712 0.358066 -0.360235 0.357744 0 0 0 0.00281905 l
+-0.360712 0.358066 -0.367107 0.362705 0 0 0 0.00281905 l
+0.883853 0.14962 0.889945 0.160207 0 0 0 0.00281905 l
+0.883853 0.14962 0.886771 0.133937 0 0 0 0.00281905 l
+0.883853 0.14962 0.880251 0.15024 0 0 0 0.00281905 l
+0.744234 0.483391 0.742542 0.464396 0 0 0 0.00281905 l
+0.744234 0.483391 0.755358 0.485475 0 0 0 0.00281905 l
+0.744234 0.483391 0.731488 0.494844 0 0 0 0.00281905 l
+-0.781476 0.38705 -0.768309 0.388209 0 0 0 0.00281905 l
+-0.781476 0.38705 -0.789243 0.37904 0 0 0 0.00281905 l
+0.233736 -0.289843 0.246323 -0.284371 0 0 0 0.00281905 l
+0.233736 -0.289843 0.225058 -0.299026 0 0 0 0.00281905 l
+-0.409105 -0.262447 -0.407034 -0.266 0 0 0 0.00281905 l
+-0.409105 -0.262447 -0.416061 -0.257141 0 0 0 0.00281905 l
+0.524148 -0.398422 0.523326 -0.387152 0 0 0 0.00281905 l
+0.151427 -0.98495 0.137896 -0.978451 0 0 0 0.00281905 l
+0.151427 -0.98495 0.160262 -0.976401 0 0 0 0.00281905 l
+0.940152 -0.294071 0.954443 -0.292795 0 0 0 0.00281905 l
+0.940152 -0.294071 0.942127 -0.306879 0 0 0 0.00281905 l
+0.940152 -0.294071 0.928868 -0.291137 0 0 0 0.00281905 l
+0.349471 -0.237616 0.350173 -0.242906 0 0 0 0.00281905 l
+0.349471 -0.237616 0.33991 -0.226179 0 0 0 0.00281905 l
+-0.669259 0.285991 -0.661095 0.288527 0 0 0 0.00281905 l
+-0.669259 0.285991 -0.675439 0.293342 0 0 0 0.00281905 l
+-0.669259 0.285991 -0.674189 0.281518 0 0 0 0.00281905 l
+0.757193 0.121594 0.755244 0.134949 0 0 0 0.00281905 l
+0.645934 0.682447 0.64137 0.692715 0 0 0 0.00281905 l
+-0.433315 0.713688 -0.432055 0.693501 0 0 0 0.00281905 l
+-0.433315 0.713688 -0.427558 0.718549 0 0 0 0.00281905 l
+-0.433315 0.713688 -0.442927 0.712748 0 0 0 0.00281905 l
+-0.905055 0.0581861 -0.912412 0.0687866 0 0 0 0.00281905 l
+-0.905055 0.0581861 -0.902096 0.0544831 0 0 0 0.00281905 l
+-0.905055 0.0581861 -0.910548 0.0550818 0 0 0 0.00281905 l
+0.581748 0.807222 0.589985 0.771528 0 0 0 0.00281905 l
+-0.0551462 -0.588721 -0.0498468 -0.566282 0 0 0 0.00281905 l
+-0.0551462 -0.588721 -0.0607823 -0.589126 0 0 0 0.00281905 l
+-0.857469 0.0582739 -0.85772 0.0551769 0 0 0 0.00281905 l
+-0.857469 0.0582739 -0.853626 0.0627171 0 0 0 0.00281905 l
+-0.485941 -0.636158 -0.480145 -0.639647 0 0 0 0.00281905 l
+-0.485941 -0.636158 -0.497769 -0.634975 0 0 0 0.00281905 l
+-0.24227 -0.228311 -0.246014 -0.212158 0 0 0 0.00281905 l
+-0.24227 -0.228311 -0.234984 -0.234214 0 0 0 0.00281905 l
+-0.24227 -0.228311 -0.247852 -0.240696 0 0 0 0.00281905 l
+-0.323072 -0.520565 -0.323848 -0.506562 0 0 0 0.00281905 l
+-0.323072 -0.520565 -0.303071 -0.525554 0 0 0 0.00281905 l
+-0.323072 -0.520565 -0.32059 -0.542515 0 0 0 0.00281905 l
+-0.512335 0.485376 -0.509447 0.483794 0 0 0 0.00281905 l
+0.586561 0.287877 0.601617 0.299257 0 0 0 0.00281905 l
+0.586561 0.287877 0.588116 0.27078 0 0 0 0.00281905 l
+0.586561 0.287877 0.569759 0.287961 0 0 0 0.00281905 l
+-0.71649 -0.143018 -0.71874 -0.137247 0 0 0 0.00281905 l
+-0.71649 -0.143018 -0.699276 -0.144943 0 0 0 0.00281905 l
+0.186992 -0.966804 0.192607 -0.979646 0 0 0 0.00281905 l
+0.186992 -0.966804 0.184615 -0.95468 0 0 0 0.00281905 l
+0.186992 -0.966804 0.19772 -0.963034 0 0 0 0.00281905 l
+0.186992 -0.966804 0.179122 -0.969073 0 0 0 0.00281905 l
+0.161363 0.367915 0.169662 0.378507 0 0 0 0.00281905 l
+0.161363 0.367915 0.157073 0.372592 0 0 0 0.00281905 l
+-0.351745 -0.730957 -0.346703 -0.717132 0 0 0 0.00281905 l
+-0.351745 -0.730957 -0.33289 -0.741811 0 0 0 0.00281905 l
+-0.351745 -0.730957 -0.367327 -0.731021 0 0 0 0.00281905 l
+-0.206515 -0.673358 -0.202566 -0.661997 0 0 0 0.00281905 l
+-0.206515 -0.673358 -0.203269 -0.67548 0 0 0 0.00281905 l
+-0.206515 -0.673358 -0.207612 -0.674514 0 0 0 0.00281905 l
+-0.709037 0.0394558 -0.703997 0.0548335 0 0 0 0.00281905 l
+-0.709037 0.0394558 -0.716227 0.0237814 0 0 0 0.00281905 l
+0.524778 0.402079 0.5297 0.401636 0 0 0 0.00281905 l
+0.524778 0.402079 0.520858 0.397139 0 0 0 0.00281905 l
+-0.546357 -0.736556 -0.528827 -0.740871 0 0 0 0.00281905 l
+-0.546357 -0.736556 -0.554946 -0.738092 0 0 0 0.00281905 l
+0.0681839 0.148208 0.0754052 0.135926 0 0 0 0.00281905 l
+-0.26226 0.166617 -0.260758 0.179268 0 0 0 0.00281905 l
+-0.26226 0.166617 -0.239258 0.161149 0 0 0 0.00281905 l
+-0.965191 0.019838 -0.954453 0.0228362 0 0 0 0.00281905 l
+-0.965191 0.019838 -0.969097 0.028464 0 0 0 0.00281905 l
+-0.616032 0.108037 -0.602414 0.106747 0 0 0 0.00281905 l
+-0.616032 0.108037 -0.625956 0.114994 0 0 0 0.00281905 l
+-0.616032 0.108037 -0.622471 0.101655 0 0 0 0.00281905 l
+-0.548778 -0.0491475 -0.550855 -0.0319624 0 0 0 0.00281905 l
+-0.548778 -0.0491475 -0.554198 -0.0564833 0 0 0 0.00281905 l
+0.792297 -0.34196 0.795263 -0.330564 0 0 0 0.00281905 l
+0.792297 -0.34196 0.794886 -0.342719 0 0 0 0.00281905 l
+0.792297 -0.34196 0.784177 -0.353295 0 0 0 0.00281905 l
+0.216764 -0.0842968 0.211181 -0.0737283 0 0 0 0.00281905 l
+0.216764 -0.0842968 0.212597 -0.0909193 0 0 0 0.00281905 l
+-0.0598951 -0.939492 -0.0678524 -0.95579 0 0 0 0.00281905 l
+-0.0598951 -0.939492 -0.0476685 -0.931465 0 0 0 0.00281905 l
+-0.824154 -0.0786788 -0.824154 -0.0750363 0 0 0 0.00281905 l
+-0.824154 -0.0786788 -0.841879 -0.0869091 0 0 0 0.00281905 l
+-0.242661 0.138996 -0.242647 0.140572 0 0 0 0.00281905 l
+-0.242661 0.138996 -0.232072 0.136271 0 0 0 0.00281905 l
+0.561787 -0.455474 0.567632 -0.443996 0 0 0 0.00281905 l
+0.561787 -0.455474 0.55597 -0.469859 0 0 0 0.00281905 l
+-0.873853 0.30412 -0.881631 0.303183 0 0 0 0.00281905 l
+-0.355602 0.285015 -0.356382 0.304641 0 0 0 0.00281905 l
+-0.355602 0.285015 -0.347436 0.284804 0 0 0 0.00281905 l
+-0.355602 0.285015 -0.373469 0.27991 0 0 0 0.00281905 l
+-0.0469107 0.993439 -0.0300682 0.991597 0 0 0 0.00281905 l
+-0.0469107 0.993439 -0.0496149 0.991074 0 0 0 0.00281905 l
+-0.542089 0.696216 -0.527698 0.703046 0 0 0 0.00281905 l
+-0.111163 -0.941424 -0.106834 -0.924701 0 0 0 0.00281905 l
+-0.111163 -0.941424 -0.106219 -0.948816 0 0 0 0.00281905 l
+0.106575 0.0811952 0.116452 0.0746246 0 0 0 0.00281905 l
+0.106575 0.0811952 0.0958719 0.0968936 0 0 0 0.00281905 l
+0.153758 -0.116353 0.154214 -0.121928 0 0 0 0.00281905 l
+0.153758 -0.116353 0.159651 -0.111034 0 0 0 0.00281905 l
+0.936504 -0.0513468 0.93636 -0.0630087 0 0 0 0.00281905 l
+0.936504 -0.0513468 0.946869 -0.0360685 0 0 0 0.00281905 l
+-0.0309634 0.343431 -0.0462363 0.351448 0 0 0 0.00281905 l
+0.690551 0.54905 0.688649 0.539186 0 0 0 0.00281905 l
+0.0762076 -0.147555 0.07846 -0.145534 0 0 0 0.00281905 l
+0.556353 0.396786 0.564381 0.393704 0 0 0 0.00281905 l
+0.0603967 -0.267275 0.0606098 -0.281203 0 0 0 0.00281905 l
+0.0603967 -0.267275 0.0719817 -0.264261 0 0 0 0.00281905 l
+0.552258 0.225627 0.563188 0.232913 0 0 0 0.00281905 l
+0.552258 0.225627 0.541181 0.216227 0 0 0 0.00281905 l
+-0.110527 -0.0353621 -0.100481 -0.0527413 0 0 0 0.00281905 l
+-0.448612 -0.869804 -0.445413 -0.881537 0 0 0 0.00281905 l
+-0.448612 -0.869804 -0.455958 -0.865832 0 0 0 0.00281905 l
+0.413889 -0.0313196 0.417676 -0.0281655 0 0 0 0.00281905 l
+0.413889 -0.0313196 0.40822 -0.0346204 0 0 0 0.00281905 l
+0.22267 0.897683 0.223979 0.894369 0 0 0 0.00281905 l
+0.22267 0.897683 0.216988 0.90413 0 0 0 0.00281905 l
+-0.450668 -0.21041 -0.454281 -0.212226 0 0 0 0.00281905 l
+0.68313 -0.0896031 0.680853 -0.076788 0 0 0 0.00281905 l
+0.68313 -0.0896031 0.689488 -0.0872034 0 0 0 0.00281905 l
+0.68313 -0.0896031 0.676012 -0.0919279 0 0 0 0.00281905 l
+-0.355529 0.35918 -0.351061 0.350871 0 0 0 0.00281905 l
+-0.355529 0.35918 -0.360235 0.357744 0 0 0 0.00281905 l
+-0.370791 0.734116 -0.373135 0.743583 0 0 0 0.00281905 l
+-0.370791 0.734116 -0.359128 0.735703 0 0 0 0.00281905 l
+-0.370791 0.734116 -0.381979 0.731105 0 0 0 0.00281905 l
+-0.109764 -0.574647 -0.125784 -0.581691 0 0 0 0.00281905 l
+-0.660209 -0.479733 -0.66216 -0.469287 0 0 0 0.00281905 l
+0.113204 -0.417105 0.111447 -0.402976 0 0 0 0.00281905 l
+0.113204 -0.417105 0.114175 -0.417613 0 0 0 0.00281905 l
+0.113204 -0.417105 0.104636 -0.420277 0 0 0 0.00281905 l
+-0.128908 -0.154424 -0.136095 -0.16405 0 0 0 0.00281905 l
+0.0827801 0.05847 0.0879119 0.0484809 0 0 0 0.00281905 l
+-0.0424917 0.555068 -0.0414119 0.567753 0 0 0 0.00281905 l
+-0.0424917 0.555068 -0.0593924 0.558626 0 0 0 0.00281905 l
+0.465921 0.30776 0.456049 0.29366 0 0 0 0.00281905 l
+0.465921 0.30776 0.469671 0.308796 0 0 0 0.00281905 l
+0.465921 0.30776 0.455596 0.318523 0 0 0 0.00281905 l
+0.0572939 0.872737 0.0634763 0.869524 0 0 0 0.00281905 l
+0.0572939 0.872737 0.0594682 0.87758 0 0 0 0.00281905 l
+0.0572939 0.872737 0.0543819 0.868287 0 0 0 0.00281905 l
+-0.314212 0.835639 -0.326575 0.845414 0 0 0 0.00281905 l
+-0.314212 0.835639 -0.314606 0.834501 0 0 0 0.00281905 l
+0.567886 -0.036734 0.576692 -0.0350918 0 0 0 0.00281905 l
+0.567886 -0.036734 0.559613 -0.0427211 0 0 0 0.00281905 l
+-0.132032 0.336291 -0.126729 0.319218 0 0 0 0.00281905 l
+-0.132032 0.336291 -0.131094 0.354752 0 0 0 0.00281905 l
+-0.132032 0.336291 -0.119543 0.339315 0 0 0 0.00281905 l
+0.376107 0.885425 0.378493 0.867154 0 0 0 0.00281905 l
+0.376107 0.885425 0.379431 0.887936 0 0 0 0.00281905 l
+0.376107 0.885425 0.359181 0.893379 0 0 0 0.00281905 l
+0.636319 -0.458628 0.639392 -0.476488 0 0 0 0.00281905 l
+0.636319 -0.458628 0.642361 -0.456546 0 0 0 0.00281905 l
+0.636319 -0.458628 0.63303 -0.457469 0 0 0 0.00281905 l
+0.806309 0.173724 0.80382 0.184186 0 0 0 0.00281905 l
+0.806309 0.173724 0.794087 0.166225 0 0 0 0.00281905 l
+0.103112 0.447991 0.10902 0.433741 0 0 0 0.00281905 l
+0.103112 0.447991 0.094738 0.45669 0 0 0 0.00281905 l
+-0.262267 -0.0163516 -0.252668 0.00167118 0 0 0 0.00281905 l
+-0.262267 -0.0163516 -0.277271 -0.0106778 0 0 0 0.00281905 l
+0.181854 0.128919 0.176777 0.140502 0 0 0 0.00281905 l
+0.181854 0.128919 0.189529 0.124661 0 0 0 0.00281905 l
+0.181854 0.128919 0.178791 0.122922 0 0 0 0.00281905 l
+0.265406 -0.891342 0.25967 -0.908048 0 0 0 0.00281905 l
+0.265406 -0.891342 0.271195 -0.882071 0 0 0 0.00281905 l
+0.265406 -0.891342 0.249017 -0.888063 0 0 0 0.00281905 l
+-0.297019 0.471217 -0.294853 0.466583 0 0 0 0.00281905 l
+-0.454281 -0.212226 -0.453983 -0.220396 0 0 0 0.00281905 l
+-0.454281 -0.212226 -0.465214 -0.200721 0 0 0 0.00281905 l
+-0.454281 -0.212226 -0.450668 -0.21041 0 0 0 0.00281905 l
+0.221653 0.87243 0.227774 0.876363 0 0 0 0.00281905 l
+0.0822732 -0.631216 0.0959863 -0.64181 0 0 0 0.00281905 l
+0.0822732 -0.631216 0.0669338 -0.638431 0 0 0 0.00281905 l
+-0.67619 0.342936 -0.676341 0.367073 0 0 0 0.00281905 l
+-0.67619 0.342936 -0.668018 0.343876 0 0 0 0.00281905 l
+-0.613496 0.198479 -0.615477 0.189529 0 0 0 0.00281905 l
+-0.613496 0.198479 -0.619875 0.198513 0 0 0 0.00281905 l
+-0.220655 0.572396 -0.211322 0.564725 0 0 0 0.00281905 l
+-0.220655 0.572396 -0.224606 0.583983 0 0 0 0.00281905 l
+0.167167 -0.411072 0.180694 -0.397662 0 0 0 0.00281905 l
+0.167167 -0.411072 0.177317 -0.423114 0 0 0 0.00281905 l
+0.167167 -0.411072 0.162655 -0.405756 0 0 0 0.00281905 l
+-0.363577 0.786062 -0.365028 0.803093 0 0 0 0.00281905 l
+-0.363577 0.786062 -0.37574 0.775321 0 0 0 0.00281905 l
+0.177645 -0.0501687 0.187478 -0.0425438 0 0 0 0.00281905 l
+0.177645 -0.0501687 0.175451 -0.0377231 0 0 0 0.00281905 l
+0.177645 -0.0501687 0.164226 -0.0540648 0 0 0 0.00281905 l
+0.29348 -0.294104 0.300079 -0.282404 0 0 0 0.00281905 l
+0.29348 -0.294104 0.293013 -0.306595 0 0 0 0.00281905 l
+0.363415 -0.890585 0.362776 -0.898066 0 0 0 0.00281905 l
+0.363415 -0.890585 0.34495 -0.892724 0 0 0 0.00281905 l
+-0.230188 -0.20267 -0.229596 -0.18988 0 0 0 0.00281905 l
+-0.230188 -0.20267 -0.229752 -0.20308 0 0 0 0.00281905 l
+-0.230188 -0.20267 -0.246014 -0.212158 0 0 0 0.00281905 l
+-0.530984 0.524263 -0.536441 0.512308 0 0 0 0.00281905 l
+-0.530984 0.524263 -0.525175 0.524571 0 0 0 0.00281905 l
+-0.530984 0.524263 -0.533087 0.526448 0 0 0 0.00281905 l
+-0.869808 -0.152129 -0.869612 -0.14352 0 0 0 0.00281905 l
+-0.869808 -0.152129 -0.859227 -0.165621 0 0 0 0.00281905 l
+-0.869808 -0.152129 -0.879772 -0.164604 0 0 0 0.00281905 l
+-0.116141 0.75592 -0.110668 0.758072 0 0 0 0.00281905 l
+-0.116141 0.75592 -0.120147 0.750978 0 0 0 0.00281905 l
+-0.295773 0.0305051 -0.295849 0.029227 0 0 0 0.00281905 l
+-0.295773 0.0305051 -0.303431 0.0386019 0 0 0 0.00281905 l
+-0.24988 0.380791 -0.25286 0.374782 0 0 0 0.00281905 l
+-0.24988 0.380791 -0.246058 0.393407 0 0 0 0.00281905 l
+0.411883 -0.742422 0.420814 -0.730466 0 0 0 0.00281905 l
+0.411883 -0.742422 0.410167 -0.748167 0 0 0 0.00281905 l
+-0.291435 -0.755148 -0.286515 -0.769556 0 0 0 0.00281905 l
+-0.291435 -0.755148 -0.281677 -0.74759 0 0 0 0.00281905 l
+-0.291435 -0.755148 -0.309123 -0.76356 0 0 0 0.00281905 l
+0.411634 0.108271 0.422661 0.106506 0 0 0 0.00281905 l
+0.411634 0.108271 0.408066 0.0937854 0 0 0 0.00281905 l
+0.541785 0.165981 0.555481 0.166558 0 0 0 0.00281905 l
+0.541785 0.165981 0.529071 0.161353 0 0 0 0.00281905 l
+0.123972 -0.107649 0.138926 -0.115009 0 0 0 0.00281905 l
+0.123972 -0.107649 0.114419 -0.114658 0 0 0 0.00281905 l
+-0.023499 0.731846 -0.016909 0.725782 0 0 0 0.00281905 l
+-0.023499 0.731846 -0.0421232 0.735412 0 0 0 0.00281905 l
+0.222807 -0.728631 0.221392 -0.721223 0 0 0 0.00281905 l
+0.222807 -0.728631 0.231955 -0.725177 0 0 0 0.00281905 l
+0.950602 -0.191227 0.948348 -0.176564 0 0 0 0.00281905 l
+0.950602 -0.191227 0.950897 -0.201268 0 0 0 0.00281905 l
+0.950602 -0.191227 0.939095 -0.192835 0 0 0 0.00281905 l
+0.139044 -0.665521 0.135405 -0.675883 0 0 0 0.00281905 l
+0.139044 -0.665521 0.141777 -0.653059 0 0 0 0.00281905 l
+0.139044 -0.665521 0.132509 -0.663352 0 0 0 0.00281905 l
+-0.0514841 -0.916103 -0.0664764 -0.909016 0 0 0 0.00281905 l
+-0.0514841 -0.916103 -0.0438899 -0.91058 0 0 0 0.00281905 l
+-0.0514841 -0.916103 -0.0552108 -0.921283 0 0 0 0.00281905 l
+-0.177255 0.247748 -0.168417 0.250935 0 0 0 0.00281905 l
+0.708548 -0.42369 0.707844 -0.427902 0 0 0 0.00281905 l
+0.708548 -0.42369 0.715525 -0.409416 0 0 0 0.00281905 l
+0.708548 -0.42369 0.701334 -0.418616 0 0 0 0.00281905 l
+0.889835 0.248453 0.903061 0.257045 0 0 0 0.00281905 l
+0.889835 0.248453 0.883553 0.234628 0 0 0 0.00281905 l
+0.889835 0.248453 0.885249 0.256848 0 0 0 0.00281905 l
+-0.0967097 0.798948 -0.0851098 0.81183 0 0 0 0.00281905 l
+-0.0967097 0.798948 -0.0853175 0.789978 0 0 0 0.00281905 l
+-0.0967097 0.798948 -0.100648 0.796427 0 0 0 0.00281905 l
+0.884434 0.0693095 0.882629 0.0689667 0 0 0 0.00281905 l
+-0.02841 -0.0909643 -0.0146425 -0.0909829 0 0 0 0.00281905 l
+-0.02841 -0.0909643 -0.0287266 -0.0982455 0 0 0 0.00281905 l
+-0.593712 0.0924504 -0.589359 0.101348 0 0 0 0.00281905 l
+-0.593712 0.0924504 -0.594504 0.0886444 0 0 0 0.00281905 l
+0.821282 0.032771 0.838387 0.0335367 0 0 0 0.00281905 l
+0.821282 0.032771 0.820714 0.0301043 0 0 0 0.00281905 l
+-0.0653536 -0.353986 -0.0633404 -0.340589 0 0 0 0.00281905 l
+-0.0653536 -0.353986 -0.0619107 -0.364736 0 0 0 0.00281905 l
+-0.0653536 -0.353986 -0.0747692 -0.361898 0 0 0 0.00281905 l
+-0.590623 0.165897 -0.585019 0.144556 0 0 0 0.00281905 l
+-0.651977 0.25292 -0.651856 0.248869 0 0 0 0.00281905 l
+-0.651977 0.25292 -0.64814 0.264719 0 0 0 0.00281905 l
+-0.651977 0.25292 -0.658915 0.254328 0 0 0 0.00281905 l
+0.121425 0.264699 0.132418 0.268952 0 0 0 0.00281905 l
+0.121425 0.264699 0.109761 0.273437 0 0 0 0.00281905 l
+-0.430378 -0.29263 -0.418711 -0.285416 0 0 0 0.00281905 l
+-0.914743 -0.331412 -0.912569 -0.313717 0 0 0 0.00281905 l
+-0.914743 -0.331412 -0.896639 -0.340494 0 0 0 0.00281905 l
+-0.914743 -0.331412 -0.920398 -0.330468 0 0 0 0.00281905 l
+0.0082151 -0.780968 0.0207839 -0.782327 0 0 0 0.00281905 l
+0.0082151 -0.780968 -0.00413429 -0.777294 0 0 0 0.00281905 l
+-0.377459 0.133404 -0.37702 0.138379 0 0 0 0.00281905 l
+-0.00257454 -0.266219 -0.00440754 -0.283809 0 0 0 0.00281905 l
+-0.00257454 -0.266219 0.00622981 -0.263785 0 0 0 0.00281905 l
+-0.00257454 -0.266219 -0.0139088 -0.259357 0 0 0 0.00281905 l
+0.117454 -0.68132 0.135405 -0.675883 0 0 0 0.00281905 l
+0.117454 -0.68132 0.121901 -0.690156 0 0 0 0.00281905 l
+0.117454 -0.68132 0.0977012 -0.681626 0 0 0 0.00281905 l
+-0.490691 -0.126787 -0.491528 -0.139759 0 0 0 0.00281905 l
+-0.490691 -0.126787 -0.50939 -0.117221 0 0 0 0.00281905 l
+-0.260306 -0.641201 -0.248847 -0.656316 0 0 0 0.00281905 l
+-0.260306 -0.641201 -0.27923 -0.630758 0 0 0 0.00281905 l
+0.37313 0.300869 0.394003 0.309589 0 0 0 0.00281905 l
+0.37313 0.300869 0.373136 0.292543 0 0 0 0.00281905 l
+-0.270772 -0.357836 -0.263865 -0.370285 0 0 0 0.00281905 l
+-0.270772 -0.357836 -0.26295 -0.349601 0 0 0 0.00281905 l
+-0.270772 -0.357836 -0.276731 -0.358055 0 0 0 0.00281905 l
+-0.629935 0.526809 -0.619346 0.540109 0 0 0 0.00281905 l
+-0.629935 0.526809 -0.614596 0.515187 0 0 0 0.00281905 l
+-0.629935 0.526809 -0.641361 0.541519 0 0 0 0.00281905 l
+0.669726 0.650478 0.674367 0.656167 0 0 0 0.00281905 l
+0.669726 0.650478 0.671624 0.645106 0 0 0 0.00281905 l
+0.669726 0.650478 0.661283 0.653904 0 0 0 0.00281905 l
+-0.0338108 0.659116 -0.0268939 0.646548 0 0 0 0.00281905 l
+-0.0338108 0.659116 -0.0387106 0.658106 0 0 0 0.00281905 l
+0.334736 -0.422443 0.347775 -0.416992 0 0 0 0.00281905 l
+0.334736 -0.422443 0.32107 -0.407555 0 0 0 0.00281905 l
+-0.936279 0.325361 -0.935428 0.304699 0 0 0 0.00281905 l
+-0.936279 0.325361 -0.935923 0.335072 0 0 0 0.00281905 l
+-0.171737 0.715379 -0.175785 0.704028 0 0 0 0.00281905 l
+-0.171737 0.715379 -0.173261 0.719661 0 0 0 0.00281905 l
+-0.171737 0.715379 -0.160385 0.714365 0 0 0 0.00281905 l
+-0.171737 0.715379 -0.183539 0.713358 0 0 0 0.00281905 l
+0.222437 0.913039 0.216988 0.90413 0 0 0 0.00281905 l
+0.222437 0.913039 0.215491 0.916948 0 0 0 0.00281905 l
+-0.173724 0.699641 -0.180525 0.687648 0 0 0 0.00281905 l
+-0.173724 0.699641 -0.175785 0.704028 0 0 0 0.00281905 l
+0.704142 -0.170671 0.71342 -0.17814 0 0 0 0.00281905 l
+0.704142 -0.170671 0.693747 -0.174308 0 0 0 0.00281905 l
+0.100478 -0.42071 0.104636 -0.420277 0 0 0 0.00281905 l
+0.100478 -0.42071 0.100056 -0.422701 0 0 0 0.00281905 l
+0.100478 -0.42071 0.0983791 -0.418494 0 0 0 0.00281905 l
+0.0671764 0.841412 0.0728983 0.84125 0 0 0 0.00281905 l
+0.0671764 0.841412 0.059071 0.838298 0 0 0 0.00281905 l
+0.130399 0.513418 0.131485 0.498057 0 0 0 0.00281905 l
+0.130399 0.513418 0.140982 0.517044 0 0 0 0.00281905 l
+0.139648 -0.240502 0.13811 -0.24488 0 0 0 0.00281905 l
+0.139648 -0.240502 0.135331 -0.237195 0 0 0 0.00281905 l
+-0.10444 -0.329942 -0.10316 -0.330355 0 0 0 0.00281905 l
+-0.10444 -0.329942 -0.118857 -0.330398 0 0 0 0.00281905 l
+0.529254 0.552157 0.537052 0.538093 0 0 0 0.00281905 l
+0.285386 0.885165 0.27486 0.876553 0 0 0 0.00281905 l
+-0.496035 0.726816 -0.495282 0.733581 0 0 0 0.00281905 l
+-0.496035 0.726816 -0.481141 0.714145 0 0 0 0.00281905 l
+0.262377 0.755358 0.26709 0.758891 0 0 0 0.00281905 l
+-0.00657777 0.940991 0.0068649 0.923351 0 0 0 0.00281905 l
+-0.00657777 0.940991 -0.0234151 0.942981 0 0 0 0.00281905 l
+-0.0128417 0.0632123 -0.00653477 0.0789303 0 0 0 0.00281905 l
+-0.0128417 0.0632123 -0.0122085 0.054965 0 0 0 0.00281905 l
+0.0982704 -0.933021 0.102106 -0.935774 0 0 0 0.00281905 l
+0.0982704 -0.933021 0.091493 -0.929001 0 0 0 0.00281905 l
+-0.714436 -0.614022 -0.708656 -0.617941 0 0 0 0.00281905 l
+-0.714436 -0.614022 -0.723302 -0.60957 0 0 0 0.00281905 l
+-0.467809 0.265553 -0.468892 0.254386 0 0 0 0.00281905 l
+-0.467809 0.265553 -0.473127 0.272209 0 0 0 0.00281905 l
+0.553208 0.740577 0.554963 0.741949 0 0 0 0.00281905 l
+0.553208 0.740577 0.540906 0.736714 0 0 0 0.00281905 l
+0.316593 -0.305555 0.320242 -0.325628 0 0 0 0.00281905 l
+0.316593 -0.305555 0.31663 -0.302336 0 0 0 0.00281905 l
+0.0835817 0.834695 0.0819474 0.825141 0 0 0 0.00281905 l
+0.0835817 0.834695 0.084802 0.835411 0 0 0 0.00281905 l
+0.0835817 0.834695 0.0757658 0.837646 0 0 0 0.00281905 l
+-0.269215 -0.145084 -0.263504 -0.132154 0 0 0 0.00281905 l
+-0.269215 -0.145084 -0.284276 -0.130931 0 0 0 0.00281905 l
+-0.269215 -0.145084 -0.278779 -0.158186 0 0 0 0.00281905 l
+0.162804 -0.212563 0.145019 -0.227688 0 0 0 0.00281905 l
+0.641367 -0.0483088 0.647748 -0.0480882 0 0 0 0.00281905 l
+0.641367 -0.0483088 0.626666 -0.0435007 0 0 0 0.00281905 l
+-0.198065 -0.802898 -0.203619 -0.79095 0 0 0 0.00281905 l
+-0.198065 -0.802898 -0.193221 -0.802274 0 0 0 0.00281905 l
+-0.198065 -0.802898 -0.198886 -0.811867 0 0 0 0.00281905 l
+0.628552 -0.625134 0.626885 -0.636392 0 0 0 0.00281905 l
+0.628552 -0.625134 0.640948 -0.620292 0 0 0 0.00281905 l
+-0.192892 0.935904 -0.19559 0.952831 0 0 0 0.00281905 l
+-0.192892 0.935904 -0.190599 0.935061 0 0 0 0.00281905 l
+-0.570562 -0.377246 -0.560174 -0.362305 0 0 0 0.00281905 l
+-0.570562 -0.377246 -0.561806 -0.382839 0 0 0 0.00281905 l
+-0.604729 0.306591 -0.613174 0.32571 0 0 0 0.00281905 l
+-0.604729 0.306591 -0.592669 0.306467 0 0 0 0.00281905 l
+-0.0859145 0.268973 -0.0859123 0.278073 0 0 0 0.00281905 l
+-0.0859145 0.268973 -0.0853743 0.268654 0 0 0 0.00281905 l
+0.79204 -0.074379 0.801899 -0.0759943 0 0 0 0.00281905 l
+0.79204 -0.074379 0.783857 -0.0684448 0 0 0 0.00281905 l
+0.100056 -0.422701 0.100117 -0.42634 0 0 0 0.00281905 l
+0.100056 -0.422701 0.100478 -0.42071 0 0 0 0.00281905 l
+-0.361679 -0.790909 -0.35685 -0.788066 0 0 0 0.00281905 l
+0.696569 0.593977 0.693256 0.609025 0 0 0 0.00281905 l
+0.696569 0.593977 0.700327 0.587275 0 0 0 0.00281905 l
+-0.678759 -0.418793 -0.674243 -0.428712 0 0 0 0.00281905 l
+-0.678759 -0.418793 -0.6779 -0.41723 0 0 0 0.00281905 l
+-0.290801 -0.618981 -0.284254 -0.619588 0 0 0 0.00281905 l
+-0.290801 -0.618981 -0.296225 -0.616802 0 0 0 0.00281905 l
+0.144211 -0.87457 0.152227 -0.886286 0 0 0 0.00281905 l
+-0.660567 -0.0793311 -0.66911 -0.0963429 0 0 0 0.00281905 l
+-0.660567 -0.0793311 -0.651832 -0.0742272 0 0 0 0.00281905 l
+-0.340744 0.815323 -0.342445 0.830651 0 0 0 0.00281905 l
+-0.0412447 0.026252 -0.0436304 0.0340249 0 0 0 0.00281905 l
+-0.0412447 0.026252 -0.0341029 0.0211779 0 0 0 0.00281905 l
+-0.0412447 0.026252 -0.0476284 0.025398 0 0 0 0.00281905 l
+-0.731957 0.490751 -0.730757 0.493131 0 0 0 0.00281905 l
+-0.596434 0.234755 -0.581937 0.230588 0 0 0 0.00281905 l
+-0.596434 0.234755 -0.597354 0.250663 0 0 0 0.00281905 l
+-0.672545 -0.18034 -0.665286 -0.173693 0 0 0 0.00281905 l
+-0.672545 -0.18034 -0.676817 -0.177286 0 0 0 0.00281905 l
+0.847175 0.184648 0.847103 0.181788 0 0 0 0.00281905 l
+0.847175 0.184648 0.835077 0.191053 0 0 0 0.00281905 l
+0.0296244 -0.128165 0.0297304 -0.135978 0 0 0 0.00281905 l
+-0.0360401 0.95645 -0.0344007 0.973191 0 0 0 0.00281905 l
+-0.0360401 0.95645 -0.0234151 0.942981 0 0 0 0.00281905 l
+-0.0360401 0.95645 -0.0486792 0.934977 0 0 0 0.00281905 l
+-0.0725904 -0.462424 -0.0847791 -0.448096 0 0 0 0.00281905 l
+-0.0725904 -0.462424 -0.0731623 -0.463906 0 0 0 0.00281905 l
+0.174375 -0.896239 0.173396 -0.911077 0 0 0 0.00281905 l
+0.174375 -0.896239 0.176807 -0.887129 0 0 0 0.00281905 l
+0.875642 -0.290297 0.888296 -0.291867 0 0 0 0.00281905 l
+0.875642 -0.290297 0.864427 -0.293363 0 0 0 0.00281905 l
+0.0626334 0.659331 0.0718049 0.654125 0 0 0 0.00281905 l
+0.0626334 0.659331 0.0658642 0.662871 0 0 0 0.00281905 l
+0.129685 0.361057 0.134113 0.34395 0 0 0 0.00281905 l
+0.129685 0.361057 0.133307 0.368436 0 0 0 0.00281905 l
+0.66809 -0.172299 0.6559 -0.184946 0 0 0 0.00281905 l
+0.66809 -0.172299 0.663086 -0.163838 0 0 0 0.00281905 l
+0.891256 0.232533 0.902621 0.226426 0 0 0 0.00281905 l
+0.891256 0.232533 0.887345 0.218156 0 0 0 0.00281905 l
+0.891256 0.232533 0.883553 0.234628 0 0 0 0.00281905 l
+-0.408679 0.51629 -0.406518 0.51009 0 0 0 0.00281905 l
+-0.408679 0.51629 -0.415057 0.513862 0 0 0 0.00281905 l
+0.428465 0.191523 0.424302 0.172199 0 0 0 0.00281905 l
+-0.286321 -0.0463104 -0.2754 -0.0530764 0 0 0 0.00281905 l
+-0.286321 -0.0463104 -0.300916 -0.0348707 0 0 0 0.00281905 l
+-0.504623 -0.227988 -0.493652 -0.22274 0 0 0 0.00281905 l
+-0.504623 -0.227988 -0.517944 -0.237631 0 0 0 0.00281905 l
+0.650559 -0.626329 0.654639 -0.619385 0 0 0 0.00281905 l
+0.650559 -0.626329 0.640948 -0.620292 0 0 0 0.00281905 l
+0.0170601 0.38963 0.0109142 0.390083 0 0 0 0.00281905 l
+0.258928 -0.857938 0.265131 -0.868861 0 0 0 0.00281905 l
+0.258928 -0.857938 0.262251 -0.842054 0 0 0 0.00281905 l
+0.258928 -0.857938 0.252687 -0.864036 0 0 0 0.00281905 l
+0.650855 -0.219829 0.666347 -0.207084 0 0 0 0.00281905 l
+0.650855 -0.219829 0.639354 -0.230528 0 0 0 0.00281905 l
+-0.388951 -0.509615 -0.380502 -0.520625 0 0 0 0.00281905 l
+-0.388951 -0.509615 -0.379646 -0.495271 0 0 0 0.00281905 l
+-0.398062 0.562454 -0.384272 0.568749 0 0 0 0.00281905 l
+0.183776 0.149683 0.184667 0.154832 0 0 0 0.00281905 l
+0.183776 0.149683 0.176102 0.152404 0 0 0 0.00281905 l
+0.0693927 -0.747692 0.0753081 -0.742728 0 0 0 0.00281905 l
+-0.723179 -0.221344 -0.709207 -0.221777 0 0 0 0.00281905 l
+-0.723179 -0.221344 -0.727426 -0.228087 0 0 0 0.00281905 l
+0.0136158 0.672032 0.0240807 0.671092 0 0 0 0.00281905 l
+0.0136158 0.672032 0.00320947 0.680519 0 0 0 0.00281905 l
+0.069611 0.0294489 0.0727936 0.0280003 0 0 0 0.00281905 l
+0.069611 0.0294489 0.0761971 0.0401935 0 0 0 0.00281905 l
+0.069611 0.0294489 0.0526059 0.0210699 0 0 0 0.00281905 l
+-0.272049 0.0696736 -0.273139 0.0770537 0 0 0 0.00281905 l
+-0.272049 0.0696736 -0.277084 0.0630049 0 0 0 0.00281905 l
+0.347842 0.120427 0.347948 0.105194 0 0 0 0.00281905 l
+0.347842 0.120427 0.34055 0.118659 0 0 0 0.00281905 l
+0.879916 -0.0335789 0.881237 -0.0195923 0 0 0 0.00281905 l
+0.879916 -0.0335789 0.894738 -0.0406066 0 0 0 0.00281905 l
+-0.879772 -0.164604 -0.869808 -0.152129 0 0 0 0.00281905 l
+-0.879772 -0.164604 -0.886975 -0.165767 0 0 0 0.00281905 l
+0.488957 -0.530737 0.487325 -0.519395 0 0 0 0.00281905 l
+0.488957 -0.530737 0.491561 -0.53256 0 0 0 0.00281905 l
+0.342111 -0.0174184 0.33925 -0.00113459 0 0 0 0.00281905 l
+0.342111 -0.0174184 0.355975 -0.0113779 0 0 0 0.00281905 l
+0.342111 -0.0174184 0.33481 -0.0204293 0 0 0 0.00281905 l
+0.261503 -0.0632182 0.256347 -0.0677364 0 0 0 0.00281905 l
+-0.939513 0.0720851 -0.942476 0.0641372 0 0 0 0.00281905 l
+-0.939513 0.0720851 -0.948207 0.0760728 0 0 0 0.00281905 l
+-0.0434513 0.604003 -0.0352988 0.59281 0 0 0 0.00281905 l
+-0.0434513 0.604003 -0.0507641 0.619913 0 0 0 0.00281905 l
+-0.0434513 0.604003 -0.0478067 0.599529 0 0 0 0.00281905 l
+-0.214992 0.520323 -0.206937 0.51868 0 0 0 0.00281905 l
+-0.214992 0.520323 -0.217134 0.511329 0 0 0 0.00281905 l
+-0.214992 0.520323 -0.221092 0.525353 0 0 0 0.00281905 l
+-0.746552 -0.389846 -0.729835 -0.384569 0 0 0 0.00281905 l
+-0.746552 -0.389846 -0.749831 -0.385706 0 0 0 0.00281905 l
+-0.647852 0.733913 -0.653705 0.750969 0 0 0 0.00281905 l
+-0.647852 0.733913 -0.637978 0.738232 0 0 0 0.00281905 l
+-0.647852 0.733913 -0.640183 0.726733 0 0 0 0.00281905 l
+-0.647852 0.733913 -0.659698 0.730459 0 0 0 0.00281905 l
+0.356169 -0.783406 0.361701 -0.801001 0 0 0 0.00281905 l
+0.356169 -0.783406 0.355891 -0.769312 0 0 0 0.00281905 l
+-0.785998 0.580995 -0.784184 0.584221 0 0 0 0.00281905 l
+-0.645003 -0.304041 -0.642105 -0.32284 0 0 0 0.00281905 l
+-0.645003 -0.304041 -0.652156 -0.30233 0 0 0 0.00281905 l
+-0.602099 0.432041 -0.591356 0.450798 0 0 0 0.00281905 l
+-0.602099 0.432041 -0.615821 0.426155 0 0 0 0.00281905 l
+0.1483 0.316145 0.164963 0.317763 0 0 0 0.00281905 l
+0.1483 0.316145 0.145425 0.31892 0 0 0 0.00281905 l
+0.0332703 0.550079 0.0373541 0.551675 0 0 0 0.00281905 l
+0.390994 -0.580268 0.394945 -0.568678 0 0 0 0.00281905 l
+0.390994 -0.580268 0.396847 -0.582953 0 0 0 0.00281905 l
+0.743223 -0.165684 0.72659 -0.166994 0 0 0 0.00281905 l
+0.743223 -0.165684 0.745363 -0.16276 0 0 0 0.00281905 l
+0.422708 -0.670839 0.43571 -0.669646 0 0 0 0.00281905 l
+0.422708 -0.670839 0.409505 -0.666874 0 0 0 0.00281905 l
+0.422983 0.600975 0.43425 0.601834 0 0 0 0.00281905 l
+0.422983 0.600975 0.415896 0.614854 0 0 0 0.00281905 l
+0.422983 0.600975 0.419496 0.590839 0 0 0 0.00281905 l
+0.378038 -0.131091 0.379045 -0.122598 0 0 0 0.00281905 l
+0.378038 -0.131091 0.387085 -0.1394 0 0 0 0.00281905 l
+-0.335999 0.483683 -0.335126 0.494196 0 0 0 0.00281905 l
+-0.335999 0.483683 -0.356936 0.489893 0 0 0 0.00281905 l
+0.451595 -0.621061 0.4482 -0.64025 0 0 0 0.00281905 l
+0.451595 -0.621061 0.444944 -0.612455 0 0 0 0.00281905 l
+0.471592 -0.743504 0.474213 -0.729717 0 0 0 0.00281905 l
+0.584309 0.089887 0.586955 0.0783149 0 0 0 0.00281905 l
+0.584309 0.089887 0.588372 0.104899 0 0 0 0.00281905 l
+0.584309 0.089887 0.572697 0.0827439 0 0 0 0.00281905 l
+0.74081 -0.122235 0.737944 -0.138871 0 0 0 0.00281905 l
+0.642187 0.736083 0.655062 0.742157 0 0 0 0.00281905 l
+0.642187 0.736083 0.634934 0.726133 0 0 0 0.00281905 l
+0.739514 0.138004 0.730795 0.149465 0 0 0 0.00281905 l
+0.739514 0.138004 0.744607 0.134864 0 0 0 0.00281905 l
+0.464241 0.346221 0.468742 0.363173 0 0 0 0.00281905 l
+0.464241 0.346221 0.482188 0.349874 0 0 0 0.00281905 l
+0.464241 0.346221 0.460556 0.337057 0 0 0 0.00281905 l
+0.902306 0.0522079 0.904161 0.0448206 0 0 0 0.00281905 l
+0.902306 0.0522079 0.921857 0.0631322 0 0 0 0.00281905 l
+-0.0220374 -0.843041 -0.0169125 -0.844514 0 0 0 0.00281905 l
+-0.0220374 -0.843041 -0.0353849 -0.848134 0 0 0 0.00281905 l
+0.0619705 -0.945131 0.0781011 -0.936035 0 0 0 0.00281905 l
+0.0619705 -0.945131 0.0544324 -0.941333 0 0 0 0.00281905 l
+-0.460481 -0.306983 -0.459951 -0.305005 0 0 0 0.00281905 l
+-0.460481 -0.306983 -0.470522 -0.313997 0 0 0 0.00281905 l
+0.470698 0.266176 0.4892 0.262729 0 0 0 0.00281905 l
+0.470698 0.266176 0.459429 0.277492 0 0 0 0.00281905 l
+0.000549871 0.748572 0.00173541 0.735806 0 0 0 0.00281905 l
+0.000549871 0.748572 0.0126096 0.76101 0 0 0 0.00281905 l
+0.000549871 0.748572 -0.00902538 0.743185 0 0 0 0.00281905 l
+-0.160551 -0.0239264 -0.160779 -0.019322 0 0 0 0.00281905 l
+-0.160551 -0.0239264 -0.17578 -0.0324139 0 0 0 0.00281905 l
+-0.157312 0.722883 -0.146902 0.719778 0 0 0 0.00281905 l
+-0.157312 0.722883 -0.160385 0.714365 0 0 0 0.00281905 l
+-0.157312 0.722883 -0.16383 0.728902 0 0 0 0.00281905 l
+0.84093 -0.273735 0.851409 -0.275331 0 0 0 0.00281905 l
+0.84093 -0.273735 0.825793 -0.277021 0 0 0 0.00281905 l
+0.230374 0.600931 0.229789 0.613911 0 0 0 0.00281905 l
+0.230374 0.600931 0.21889 0.598869 0 0 0 0.00281905 l
+0.34618 -0.309763 0.363165 -0.3128 0 0 0 0.00281905 l
+0.34618 -0.309763 0.334302 -0.296414 0 0 0 0.00281905 l
+-0.0166495 0.220013 -0.0106857 0.23434 0 0 0 0.00281905 l
+-0.0166495 0.220013 -0.0161561 0.213599 0 0 0 0.00281905 l
+-0.242647 0.140572 -0.240152 0.147453 0 0 0 0.00281905 l
+-0.242647 0.140572 -0.242661 0.138996 0 0 0 0.00281905 l
+-0.242647 0.140572 -0.246491 0.141934 0 0 0 0.00281905 l
+0.128881 0.336814 0.137217 0.33264 0 0 0 0.00281905 l
+0.128881 0.336814 0.134113 0.34395 0 0 0 0.00281905 l
+-0.433666 0.166619 -0.429097 0.157103 0 0 0 0.00281905 l
+-0.433666 0.166619 -0.439399 0.173834 0 0 0 0.00281905 l
+-0.322074 0.272767 -0.325779 0.265193 0 0 0 0.00281905 l
+0.626533 -0.182653 0.629626 -0.186071 0 0 0 0.00281905 l
+0.626533 -0.182653 0.616806 -0.188923 0 0 0 0.00281905 l
+-0.174424 -0.882171 -0.168078 -0.891159 0 0 0 0.00281905 l
+-0.174424 -0.882171 -0.170927 -0.865165 0 0 0 0.00281905 l
+-0.174424 -0.882171 -0.183324 -0.878002 0 0 0 0.00281905 l
+0.35069 -0.261634 0.357642 -0.270459 0 0 0 0.00281905 l
+0.35069 -0.261634 0.345285 -0.256722 0 0 0 0.00281905 l
+-0.155367 0.281579 -0.156386 0.297729 0 0 0 0.00281905 l
+-0.155367 0.281579 -0.149317 0.276998 0 0 0 0.00281905 l
+0.444944 -0.612455 0.45813 -0.605 0 0 0 0.00281905 l
+0.444944 -0.612455 0.451595 -0.621061 0 0 0 0.00281905 l
+0.444944 -0.612455 0.437674 -0.607186 0 0 0 0.00281905 l
+0.755563 -0.184813 0.761289 -0.18525 0 0 0 0.00281905 l
+0.755563 -0.184813 0.754741 -0.187928 0 0 0 0.00281905 l
+0.325626 0.911869 0.337493 0.896279 0 0 0 0.00281905 l
+0.325626 0.911869 0.329436 0.916026 0 0 0 0.00281905 l
+0.325626 0.911869 0.317619 0.916339 0 0 0 0.00281905 l
+0.293966 -0.432183 0.300656 -0.424381 0 0 0 0.00281905 l
+-0.00421419 0.823066 0.0118304 0.8226 0 0 0 0.00281905 l
+0.209933 0.420344 0.206638 0.420826 0 0 0 0.00281905 l
+-0.144314 0.267707 -0.154783 0.256784 0 0 0 0.00281905 l
+-0.144314 0.267707 -0.136598 0.273804 0 0 0 0.00281905 l
+-0.144314 0.267707 -0.150005 0.274124 0 0 0 0.00281905 l
+0.303213 0.106034 0.311801 0.103077 0 0 0 0.00281905 l
+0.303213 0.106034 0.29942 0.111802 0 0 0 0.00281905 l
+0.406519 -0.486546 0.404657 -0.479598 0 0 0 0.00281905 l
+0.406519 -0.486546 0.410406 -0.489229 0 0 0 0.00281905 l
+-0.160454 0.881369 -0.154582 0.887362 0 0 0 0.00281905 l
+0.091636 0.373105 0.0973117 0.377078 0 0 0 0.00281905 l
+0.091636 0.373105 0.0775398 0.362226 0 0 0 0.00281905 l
+0.486021 0.770694 0.498603 0.784029 0 0 0 0.00281905 l
+0.486021 0.770694 0.487315 0.755318 0 0 0 0.00281905 l
+0.486021 0.770694 0.471566 0.765735 0 0 0 0.00281905 l
+-0.457273 -0.780919 -0.455557 -0.789424 0 0 0 0.00281905 l
+-0.117445 0.177399 -0.119503 0.185983 0 0 0 0.00281905 l
+-0.117445 0.177399 -0.111598 0.173029 0 0 0 0.00281905 l
+-0.202493 -0.580639 -0.200865 -0.589863 0 0 0 0.00281905 l
+-0.202493 -0.580639 -0.201918 -0.567312 0 0 0 0.00281905 l
+-0.202493 -0.580639 -0.213432 -0.576936 0 0 0 0.00281905 l
+-0.616834 0.140074 -0.61335 0.158522 0 0 0 0.00281905 l
+-0.616834 0.140074 -0.61788 0.136657 0 0 0 0.00281905 l
+-0.447707 0.0927907 -0.445308 0.099341 0 0 0 0.00281905 l
+-0.447707 0.0927907 -0.44341 0.090064 0 0 0 0.00281905 l
+0.011421 -0.637842 0.0156282 -0.634239 0 0 0 0.00281905 l
+-0.552972 0.0312639 -0.554372 0.0216403 0 0 0 0.00281905 l
+-0.552972 0.0312639 -0.562835 0.0353538 0 0 0 0.00281905 l
+-0.540188 -0.678303 -0.539032 -0.655267 0 0 0 0.00281905 l
+-0.540188 -0.678303 -0.542071 -0.679928 0 0 0 0.00281905 l
+0.101127 0.233477 0.0995328 0.230874 0 0 0 0.00281905 l
+0.737894 -0.589556 0.737446 -0.595536 0 0 0 0.00281905 l
+0.737894 -0.589556 0.732942 -0.591039 0 0 0 0.00281905 l
+-0.0369126 0.125381 -0.0270269 0.132542 0 0 0 0.00281905 l
+-0.0369126 0.125381 -0.0443842 0.133992 0 0 0 0.00281905 l
+-0.991399 0.00388385 -0.981093 -0.00869599 0 0 0 0.00281905 l
+-0.991399 0.00388385 -0.985191 0.0126579 0 0 0 0.00281905 l
+-0.199055 -0.312533 -0.192783 -0.32799 0 0 0 0.00281905 l
+-0.199055 -0.312533 -0.200119 -0.305648 0 0 0 0.00281905 l
+-0.410544 0.891817 -0.420234 0.904953 0 0 0 0.00281905 l
+-0.410544 0.891817 -0.400065 0.897851 0 0 0 0.00281905 l
+-0.410544 0.891817 -0.410713 0.890251 0 0 0 0.00281905 l
+0.0662144 -0.864503 0.0859229 -0.870245 0 0 0 0.00281905 l
+0.0662144 -0.864503 0.0622822 -0.862919 0 0 0 0.00281905 l
+0.517393 0.454175 0.527305 0.443712 0 0 0 0.00281905 l
+0.517393 0.454175 0.520137 0.4579 0 0 0 0.00281905 l
+0.928868 -0.291137 0.931797 -0.282408 0 0 0 0.00281905 l
+0.928868 -0.291137 0.940152 -0.294071 0 0 0 0.00281905 l
+0.928868 -0.291137 0.921171 -0.289583 0 0 0 0.00281905 l
+0.184667 0.154832 0.183776 0.149683 0 0 0 0.00281905 l
+0.2433 0.647582 0.255207 0.643144 0 0 0 0.00281905 l
+0.2433 0.647582 0.229622 0.650192 0 0 0 0.00281905 l
+0.194361 0.451397 0.197503 0.470117 0 0 0 0.00281905 l
+0.194361 0.451397 0.202507 0.449223 0 0 0 0.00281905 l
+-0.372898 0.759246 -0.366505 0.758772 0 0 0 0.00281905 l
+-0.372898 0.759246 -0.376034 0.76153 0 0 0 0.00281905 l
+-0.568277 -0.50445 -0.569683 -0.500035 0 0 0 0.00281905 l
+-0.568277 -0.50445 -0.563535 -0.504797 0 0 0 0.00281905 l
+-0.568277 -0.50445 -0.575461 -0.511595 0 0 0 0.00281905 l
+0.686687 0.408981 0.688265 0.402207 0 0 0 0.00281905 l
+0.686687 0.408981 0.695944 0.414457 0 0 0 0.00281905 l
+0.387118 0.785956 0.387968 0.79142 0 0 0 0.00281905 l
+0.387118 0.785956 0.38624 0.772718 0 0 0 0.00281905 l
+0.387118 0.785956 0.37556 0.784279 0 0 0 0.00281905 l
+-0.376371 -0.585005 -0.39064 -0.597497 0 0 0 0.00281905 l
+-0.376371 -0.585005 -0.37358 -0.581713 0 0 0 0.00281905 l
+-0.467018 -0.557025 -0.468484 -0.549982 0 0 0 0.00281905 l
+0.529836 0.253319 0.528499 0.248535 0 0 0 0.00281905 l
+0.235904 0.940493 0.240585 0.944203 0 0 0 0.00281905 l
+0.235904 0.940493 0.228051 0.936698 0 0 0 0.00281905 l
+0.589985 0.771528 0.581748 0.807222 0 0 0 0.00281905 l
+0.589985 0.771528 0.600489 0.763056 0 0 0 0.00281905 l
+0.589985 0.771528 0.58768 0.767835 0 0 0 0.00281905 l
+0.172109 0.622042 0.172874 0.620734 0 0 0 0.00281905 l
+0.515742 0.300438 0.518688 0.313002 0 0 0 0.00281905 l
+0.515742 0.300438 0.524222 0.294513 0 0 0 0.00281905 l
+0.515742 0.300438 0.497283 0.292812 0 0 0 0.00281905 l
+0.111753 0.721165 0.102008 0.706537 0 0 0 0.00281905 l
+0.111753 0.721165 0.12259 0.722196 0 0 0 0.00281905 l
+0.111753 0.721165 0.110915 0.724717 0 0 0 0.00281905 l
+-0.404033 0.36083 -0.406115 0.367839 0 0 0 0.00281905 l
+-0.304484 0.138749 -0.305969 0.160879 0 0 0 0.00281905 l
+-0.304484 0.138749 -0.304256 0.133978 0 0 0 0.00281905 l
+-0.304484 0.138749 -0.315402 0.138071 0 0 0 0.00281905 l
+0.298254 0.290105 0.2969 0.273858 0 0 0 0.00281905 l
+0.298254 0.290105 0.315509 0.294034 0 0 0 0.00281905 l
+0.00180936 -0.199822 0.00633459 -0.202663 0 0 0 0.00281905 l
+0.00180936 -0.199822 -0.00418032 -0.196153 0 0 0 0.00281905 l
+-0.776007 0.356523 -0.762209 0.355263 0 0 0 0.00281905 l
+-0.776007 0.356523 -0.779988 0.363388 0 0 0 0.00281905 l
+-0.776007 0.356523 -0.786839 0.35449 0 0 0 0.00281905 l
+-0.299807 -0.556487 -0.288603 -0.556037 0 0 0 0.00281905 l
+-0.299807 -0.556487 -0.294031 -0.576719 0 0 0 0.00281905 l
+-0.0816758 0.693981 -0.0779103 0.708051 0 0 0 0.00281905 l
+-0.0816758 0.693981 -0.0791461 0.692805 0 0 0 0.00281905 l
+-0.0816758 0.693981 -0.0852581 0.683158 0 0 0 0.00281905 l
+-0.0636804 0.234933 -0.0655355 0.246514 0 0 0 0.00281905 l
+-0.0636804 0.234933 -0.0673039 0.228183 0 0 0 0.00281905 l
+0.708486 0.440453 0.698247 0.453898 0 0 0 0.00281905 l
+0.708486 0.440453 0.723864 0.425412 0 0 0 0.00281905 l
+-0.0143234 0.159135 -0.00415519 0.155145 0 0 0 0.00281905 l
+0.017211 -0.590061 0.0189354 -0.60555 0 0 0 0.00281905 l
+0.017211 -0.590061 0.0259233 -0.581877 0 0 0 0.00281905 l
+-0.743159 -0.496232 -0.752244 -0.509145 0 0 0 0.00281905 l
+-0.743159 -0.496232 -0.743536 -0.495338 0 0 0 0.00281905 l
+0.10916 -0.389834 0.113774 -0.381678 0 0 0 0.00281905 l
+0.10916 -0.389834 0.114013 -0.397705 0 0 0 0.00281905 l
+0.10916 -0.389834 0.1048 -0.385723 0 0 0 0.00281905 l
+0.091493 -0.929001 0.0982704 -0.933021 0 0 0 0.00281905 l
+0.091493 -0.929001 0.0867214 -0.927503 0 0 0 0.00281905 l
+0.437347 -0.0183985 0.437982 -0.0121583 0 0 0 0.00281905 l
+0.437347 -0.0183985 0.433109 -0.0219774 0 0 0 0.00281905 l
+-0.592858 0.292285 -0.592669 0.306467 0 0 0 0.00281905 l
+-0.592858 0.292285 -0.586125 0.284563 0 0 0 0.00281905 l
+0.392037 -0.474552 0.404657 -0.479598 0 0 0 0.00281905 l
+0.392037 -0.474552 0.390793 -0.486306 0 0 0 0.00281905 l
+0.392037 -0.474552 0.393043 -0.464873 0 0 0 0.00281905 l
+-0.297051 -0.511417 -0.288169 -0.523394 0 0 0 0.00281905 l
+-0.297051 -0.511417 -0.290816 -0.504638 0 0 0 0.00281905 l
+0.462674 -0.0533953 0.473415 -0.0581657 0 0 0 0.00281905 l
+0.462674 -0.0533953 0.459915 -0.0619874 0 0 0 0.00281905 l
+0.462674 -0.0533953 0.453608 -0.0478701 0 0 0 0.00281905 l
+0.886771 0.133937 0.883853 0.14962 0 0 0 0.00281905 l
+0.534148 0.436348 0.538414 0.437937 0 0 0 0.00281905 l
+0.534148 0.436348 0.527305 0.443712 0 0 0 0.00281905 l
+0.534148 0.436348 0.523064 0.431084 0 0 0 0.00281905 l
+-0.503398 0.365699 -0.502867 0.364867 0 0 0 0.00281905 l
+-0.503398 0.365699 -0.517191 0.375073 0 0 0 0.00281905 l
+0.861805 0.283383 0.864004 0.285944 0 0 0 0.00281905 l
+-0.384419 -0.458153 -0.367355 -0.471198 0 0 0 0.00281905 l
+-0.384419 -0.458153 -0.382611 -0.448127 0 0 0 0.00281905 l
+-0.97476 -0.109543 -0.957981 -0.113868 0 0 0 0.00281905 l
+-0.97476 -0.109543 -0.97999 -0.0934113 0 0 0 0.00281905 l
+-0.0541708 0.419667 -0.0589306 0.433507 0 0 0 0.00281905 l
+-0.0541708 0.419667 -0.0536392 0.419437 0 0 0 0.00281905 l
+-0.0541708 0.419667 -0.062805 0.414003 0 0 0 0.00281905 l
+-0.46796 -0.0124811 -0.461883 -0.023583 0 0 0 0.00281905 l
+-0.46796 -0.0124811 -0.471794 -0.0107573 0 0 0 0.00281905 l
+0.436014 -0.261119 0.439783 -0.260834 0 0 0 0.00281905 l
+0.436014 -0.261119 0.430612 -0.2572 0 0 0 0.00281905 l
+-0.901506 -0.0101113 -0.902453 -0.016711 0 0 0 0.00281905 l
+-0.901506 -0.0101113 -0.894943 -0.00108552 0 0 0 0.00281905 l
+-0.385279 -0.206878 -0.387782 -0.197817 0 0 0 0.00281905 l
+-0.385279 -0.206878 -0.38346 -0.215206 0 0 0 0.00281905 l
+0.0983228 0.746278 0.0951225 0.733274 0 0 0 0.00281905 l
+0.0983228 0.746278 0.0924507 0.749409 0 0 0 0.00281905 l
+-0.569358 0.506199 -0.552082 0.511686 0 0 0 0.00281905 l
+-0.569358 0.506199 -0.579759 0.504113 0 0 0 0.00281905 l
+-0.0189583 -0.0261561 -0.0178294 -0.0103801 0 0 0 0.00281905 l
+-0.0189583 -0.0261561 -0.0018897 -0.0400022 0 0 0 0.00281905 l
+-0.0189583 -0.0261561 -0.028021 -0.0284747 0 0 0 0.00281905 l
+-0.49381 -0.0940095 -0.480967 -0.0807854 0 0 0 0.00281905 l
+-0.49381 -0.0940095 -0.507482 -0.105652 0 0 0 0.00281905 l
+-0.571486 0.645211 -0.564297 0.641201 0 0 0 0.00281905 l
+-0.571486 0.645211 -0.575832 0.639813 0 0 0 0.00281905 l
+0.562497 0.0744476 0.572697 0.0827439 0 0 0 0.00281905 l
+-0.436571 -0.641834 -0.431347 -0.629727 0 0 0 0.00281905 l
+-0.436571 -0.641834 -0.429033 -0.645016 0 0 0 0.00281905 l
+-0.436571 -0.641834 -0.437923 -0.651829 0 0 0 0.00281905 l
+-0.235673 -0.162976 -0.235758 -0.15684 0 0 0 0.00281905 l
+-0.235673 -0.162976 -0.236174 -0.16674 0 0 0 0.00281905 l
+-0.208438 -0.827146 -0.203261 -0.838536 0 0 0 0.00281905 l
+-0.208438 -0.827146 -0.198886 -0.811867 0 0 0 0.00281905 l
+-0.208438 -0.827146 -0.223244 -0.826366 0 0 0 0.00281905 l
+-0.261824 -0.262972 -0.250225 -0.268649 0 0 0 0.00281905 l
+-0.261824 -0.262972 -0.268815 -0.269799 0 0 0 0.00281905 l
+0.049647 0.597589 0.0545468 0.61495 0 0 0 0.00281905 l
+0.049647 0.597589 0.0598583 0.593354 0 0 0 0.00281905 l
+0.753373 0.0440827 0.759127 0.0489503 0 0 0 0.00281905 l
+0.753373 0.0440827 0.75155 0.038979 0 0 0 0.00281905 l
+-0.114215 -0.414303 -0.120046 -0.407505 0 0 0 0.00281905 l
+0.462381 -0.388774 0.469099 -0.378971 0 0 0 0.00281905 l
+0.462381 -0.388774 0.449887 -0.399375 0 0 0 0.00281905 l
+-0.68068 0.712579 -0.662431 0.714714 0 0 0 0.00281905 l
+-0.68068 0.712579 -0.701841 0.709226 0 0 0 0.00281905 l
+0.509573 -0.307295 0.504816 -0.294766 0 0 0 0.00281905 l
+0.509573 -0.307295 0.517652 -0.321857 0 0 0 0.00281905 l
+0.509573 -0.307295 0.495351 -0.308538 0 0 0 0.00281905 l
+0.865456 -0.0911717 0.867832 -0.0802485 0 0 0 0.00281905 l
+0.865456 -0.0911717 0.86206 -0.0998185 0 0 0 0.00281905 l
+-0.845631 -0.0935084 -0.841879 -0.0869091 0 0 0 0.00281905 l
+-0.140512 -0.939848 -0.135957 -0.945604 0 0 0 0.00281905 l
+-0.140512 -0.939848 -0.143978 -0.924545 0 0 0 0.00281905 l
+-0.21015 -0.412246 -0.200845 -0.400624 0 0 0 0.00281905 l
+-0.21015 -0.412246 -0.214607 -0.417675 0 0 0 0.00281905 l
+0.0360315 -0.622152 0.0336093 -0.632856 0 0 0 0.00281905 l
+0.570933 -0.225316 0.581726 -0.241461 0 0 0 0.00281905 l
+0.570933 -0.225316 0.556627 -0.210148 0 0 0 0.00281905 l
+0.0373998 -0.186192 0.0467613 -0.170992 0 0 0 0.00281905 l
+0.0373998 -0.186192 0.0338978 -0.194606 0 0 0 0.00281905 l
+-0.751991 -0.228181 -0.749238 -0.240866 0 0 0 0.00281905 l
+-0.751991 -0.228181 -0.753655 -0.215878 0 0 0 0.00281905 l
+-0.751991 -0.228181 -0.770354 -0.231486 0 0 0 0.00281905 l
+0.0613402 -0.786317 0.0683795 -0.780394 0 0 0 0.00281905 l
+0.0613402 -0.786317 0.0675832 -0.795413 0 0 0 0.00281905 l
+0.00513286 0.351256 0.00813491 0.361179 0 0 0 0.00281905 l
+0.00513286 0.351256 0.00648479 0.340854 0 0 0 0.00281905 l
+0.00513286 0.351256 -0.00454499 0.358401 0 0 0 0.00281905 l
+0.60825 0.679628 0.622368 0.686318 0 0 0 0.00281905 l
+0.60825 0.679628 0.595718 0.667314 0 0 0 0.00281905 l
+-0.122906 -0.10077 -0.108743 -0.0859735 0 0 0 0.00281905 l
+-0.122906 -0.10077 -0.125462 -0.100999 0 0 0 0.00281905 l
+0.000914739 0.0510042 -0.0122085 0.054965 0 0 0 0.00281905 l
+0.0622822 -0.862919 0.0625908 -0.855393 0 0 0 0.00281905 l
+0.0622822 -0.862919 0.0662144 -0.864503 0 0 0 0.00281905 l
+-0.839647 -0.0248634 -0.834117 -0.00832675 0 0 0 0.00281905 l
+0.640746 0.500613 0.643548 0.486488 0 0 0 0.00281905 l
+0.640746 0.500613 0.652179 0.511229 0 0 0 0.00281905 l
+0.0721154 -0.766253 0.0778287 -0.765498 0 0 0 0.00281905 l
+0.0721154 -0.766253 0.0715648 -0.773352 0 0 0 0.00281905 l
+0.0721154 -0.766253 0.0639925 -0.76375 0 0 0 0.00281905 l
+0.533554 0.0691592 0.533971 0.0612763 0 0 0 0.00281905 l
+0.533554 0.0691592 0.521323 0.0865356 0 0 0 0.00281905 l
+0.552909 0.20062 0.551792 0.194629 0 0 0 0.00281905 l
+0.552909 0.20062 0.541181 0.216227 0 0 0 0.00281905 l
+-0.276495 0.786795 -0.274028 0.787117 0 0 0 0.00281905 l
+-0.276495 0.786795 -0.279961 0.775062 0 0 0 0.00281905 l
+-0.890016 0.325201 -0.882045 0.311342 0 0 0 0.00281905 l
+-0.890016 0.325201 -0.886908 0.330936 0 0 0 0.00281905 l
+-0.890016 0.325201 -0.905136 0.320191 0 0 0 0.00281905 l
+-0.225639 0.970066 -0.257386 0.964242 0 0 0 0.00281905 l
+-0.113819 0.409876 -0.114468 0.402155 0 0 0 0.00281905 l
+-0.113819 0.409876 -0.103695 0.411657 0 0 0 0.00281905 l
+-0.113819 0.409876 -0.119307 0.410486 0 0 0 0.00281905 l
+-0.63799 -0.0589955 -0.650096 -0.0707802 0 0 0 0.00281905 l
+-0.63799 -0.0589955 -0.646021 -0.0379407 0 0 0 0.00281905 l
+-0.63799 -0.0589955 -0.629075 -0.0599193 0 0 0 0.00281905 l
+-0.380504 0.368938 -0.37454 0.374179 0 0 0 0.00281905 l
+-0.380504 0.368938 -0.390089 0.37438 0 0 0 0.00281905 l
+-0.144105 0.367345 -0.135829 0.363844 0 0 0 0.00281905 l
+-0.144105 0.367345 -0.154765 0.380145 0 0 0 0.00281905 l
+-0.0848001 0.488813 -0.0897377 0.477298 0 0 0 0.00281905 l
+-0.0848001 0.488813 -0.0806514 0.493114 0 0 0 0.00281905 l
+-0.0420746 0.854616 -0.0435758 0.860141 0 0 0 0.00281905 l
+-0.0420746 0.854616 -0.0559224 0.845203 0 0 0 0.00281905 l
+0.332563 -0.0834278 0.335355 -0.0717461 0 0 0 0.00281905 l
+0.332563 -0.0834278 0.328411 -0.0894602 0 0 0 0.00281905 l
+-0.621642 0.482879 -0.606583 0.491628 0 0 0 0.00281905 l
+-0.621642 0.482879 -0.635575 0.487345 0 0 0 0.00281905 l
+0.723864 0.425412 0.708486 0.440453 0 0 0 0.00281905 l
+-0.0926024 -0.302728 -0.102103 -0.307197 0 0 0 0.00281905 l
+0.131485 0.498057 0.130399 0.513418 0 0 0 0.00281905 l
+0.131485 0.498057 0.13932 0.486255 0 0 0 0.00281905 l
+0.131485 0.498057 0.113393 0.494714 0 0 0 0.00281905 l
+-0.718933 -0.132526 -0.713576 -0.125926 0 0 0 0.00281905 l
+-0.718933 -0.132526 -0.719813 -0.136555 0 0 0 0.00281905 l
+-0.870706 0.0225344 -0.870067 0.0179736 0 0 0 0.00281905 l
+-0.870706 0.0225344 -0.872045 0.0364239 0 0 0 0.00281905 l
+0.367429 -0.446403 0.381433 -0.436474 0 0 0 0.00281905 l
+0.367429 -0.446403 0.359862 -0.44813 0 0 0 0.00281905 l
+0.867316 -0.0203235 0.867832 -0.0208838 0 0 0 0.00281905 l
+0.867316 -0.0203235 0.861334 -0.0157504 0 0 0 0.00281905 l
+0.485347 -0.0579699 0.486502 -0.0492582 0 0 0 0.00281905 l
+0.485347 -0.0579699 0.481215 -0.0689392 0 0 0 0.00281905 l
+0.485347 -0.0579699 0.473415 -0.0581657 0 0 0 0.00281905 l
+-0.351435 0.857264 -0.341747 0.842408 0 0 0 0.00281905 l
+-0.351435 0.857264 -0.368235 0.851479 0 0 0 0.00281905 l
+-0.717098 -0.596795 -0.716356 -0.591955 0 0 0 0.00281905 l
+-0.717098 -0.596795 -0.723302 -0.60957 0 0 0 0.00281905 l
+0.530775 0.335462 0.525126 0.347219 0 0 0 0.00281905 l
+0.530775 0.335462 0.523677 0.325968 0 0 0 0.00281905 l
+-0.564791 0.213055 -0.557703 0.217376 0 0 0 0.00281905 l
+-0.564791 0.213055 -0.573186 0.223237 0 0 0 0.00281905 l
+0.802546 -0.418406 0.812903 -0.40835 0 0 0 0.00281905 l
+0.802546 -0.418406 0.803908 -0.421936 0 0 0 0.00281905 l
+0.802546 -0.418406 0.788867 -0.410458 0 0 0 0.00281905 l
+-0.502867 0.364867 -0.503398 0.365699 0 0 0 0.00281905 l
+0.273033 0.317818 0.268922 0.303004 0 0 0 0.00281905 l
+0.273033 0.317818 0.281665 0.322103 0 0 0 0.00281905 l
+0.760149 0.135229 0.768058 0.141918 0 0 0 0.00281905 l
+0.760149 0.135229 0.755244 0.134949 0 0 0 0.00281905 l
+0.709487 -0.444744 0.707844 -0.427902 0 0 0 0.00281905 l
+0.709487 -0.444744 0.713185 -0.447193 0 0 0 0.00281905 l
+0.709487 -0.444744 0.704265 -0.449806 0 0 0 0.00281905 l
+0.761372 0.522257 0.76524 0.514898 0 0 0 0.00281905 l
+0.761372 0.522257 0.756378 0.533796 0 0 0 0.00281905 l
+0.0498665 0.716211 0.0507665 0.706029 0 0 0 0.00281905 l
+0.470226 0.620232 0.484444 0.624981 0 0 0 0.00281905 l
+0.470226 0.620232 0.479305 0.608127 0 0 0 0.00281905 l
+0.470226 0.620232 0.469796 0.620896 0 0 0 0.00281905 l
+0.577884 -0.00951244 0.578823 -0.000852624 0 0 0 0.00281905 l
+0.577884 -0.00951244 0.593092 -0.0148311 0 0 0 0.00281905 l
+0.577884 -0.00951244 0.569777 -0.00821252 0 0 0 0.00281905 l
+0.299383 -0.413198 0.300656 -0.424381 0 0 0 0.00281905 l
+0.299383 -0.413198 0.296479 -0.405795 0 0 0 0.00281905 l
+-0.0413975 0.30903 -0.0411414 0.297721 0 0 0 0.00281905 l
+-0.0413975 0.30903 -0.0453286 0.311044 0 0 0 0.00281905 l
+-0.200845 -0.400624 -0.19245 -0.410395 0 0 0 0.00281905 l
+-0.200845 -0.400624 -0.193773 -0.386603 0 0 0 0.00281905 l
+-0.200845 -0.400624 -0.21015 -0.412246 0 0 0 0.00281905 l
+-0.185634 0.158499 -0.172089 0.15437 0 0 0 0.00281905 l
+-0.185634 0.158499 -0.191785 0.159807 0 0 0 0.00281905 l
+-0.229432 -0.176083 -0.229596 -0.18988 0 0 0 0.00281905 l
+-0.229432 -0.176083 -0.23844 -0.173115 0 0 0 0.00281905 l
+0.77071 0.363158 0.761549 0.37395 0 0 0 0.00281905 l
+0.77071 0.363158 0.765512 0.356163 0 0 0 0.00281905 l
+0.265064 0.272314 0.266692 0.267853 0 0 0 0.00281905 l
+0.265064 0.272314 0.245775 0.281393 0 0 0 0.00281905 l
+-0.543251 -0.610935 -0.551375 -0.603786 0 0 0 0.00281905 l
+-0.416013 -0.608472 -0.401074 -0.619475 0 0 0 0.00281905 l
+-0.416013 -0.608472 -0.417586 -0.607838 0 0 0 0.00281905 l
+-0.592869 -0.471337 -0.584484 -0.464525 0 0 0 0.00281905 l
+-0.592869 -0.471337 -0.597708 -0.476284 0 0 0 0.00281905 l
+-0.414793 -0.160972 -0.395724 -0.16523 0 0 0 0.00281905 l
+-0.414793 -0.160972 -0.416776 -0.156688 0 0 0 0.00281905 l
+0.730795 0.149465 0.739514 0.138004 0 0 0 0.00281905 l
+0.730795 0.149465 0.71628 0.144743 0 0 0 0.00281905 l
+0.0674492 -0.297405 0.0592835 -0.296391 0 0 0 0.00281905 l
+-0.200992 0.16251 -0.19267 0.176945 0 0 0 0.00281905 l
+-0.200992 0.16251 -0.191785 0.159807 0 0 0 0.00281905 l
+-0.200992 0.16251 -0.210432 0.160644 0 0 0 0.00281905 l
+-0.962639 0.185995 -0.966114 0.175631 0 0 0 0.00281905 l
+-0.962639 0.185995 -0.953943 0.191822 0 0 0 0.00281905 l
+-0.962639 0.185995 -0.979049 0.19193 0 0 0 0.00281905 l
+-0.179368 -0.578001 -0.166524 -0.590449 0 0 0 0.00281905 l
+-0.179368 -0.578001 -0.186383 -0.567019 0 0 0 0.00281905 l
+0.209813 0.748896 0.210519 0.74965 0 0 0 0.00281905 l
+0.870428 -0.0593267 0.853869 -0.0499024 0 0 0 0.00281905 l
+-0.449746 -0.137896 -0.450595 -0.153382 0 0 0 0.00281905 l
+-0.449746 -0.137896 -0.454936 -0.127128 0 0 0 0.00281905 l
+-0.124564 0.800847 -0.121914 0.809835 0 0 0 0.00281905 l
+-0.124564 0.800847 -0.133125 0.797976 0 0 0 0.00281905 l
+0.0791014 0.468467 0.0804063 0.466179 0 0 0 0.00281905 l
+-0.526187 0.0727476 -0.513024 0.0682619 0 0 0 0.00281905 l
+-0.526187 0.0727476 -0.525632 0.0763348 0 0 0 0.00281905 l
+0.153056 0.877776 0.174278 0.869106 0 0 0 0.00281905 l
+0.627747 -0.324871 0.620552 -0.308709 0 0 0 0.00281905 l
+-0.487982 0.50336 -0.481578 0.503134 0 0 0 0.00281905 l
+-0.487982 0.50336 -0.494059 0.489766 0 0 0 0.00281905 l
+-0.487982 0.50336 -0.501042 0.504486 0 0 0 0.00281905 l
+0.251448 0.737802 0.251334 0.73339 0 0 0 0.00281905 l
+-0.300444 -0.407416 -0.294489 -0.41037 0 0 0 0.00281905 l
+-0.692255 0.637237 -0.697551 0.653721 0 0 0 0.00281905 l
+-0.692255 0.637237 -0.695532 0.629578 0 0 0 0.00281905 l
+-0.0664764 -0.909016 -0.0514841 -0.916103 0 0 0 0.00281905 l
+-0.0664764 -0.909016 -0.0733442 -0.897057 0 0 0 0.00281905 l
+-0.697907 -0.574269 -0.691909 -0.567651 0 0 0 0.00281905 l
+-0.697907 -0.574269 -0.703439 -0.56992 0 0 0 0.00281905 l
+0.286838 0.718016 0.288529 0.728534 0 0 0 0.00281905 l
+0.286838 0.718016 0.303633 0.7054 0 0 0 0.00281905 l
+0.286838 0.718016 0.281511 0.700095 0 0 0 0.00281905 l
+0.286838 0.718016 0.269915 0.714823 0 0 0 0.00281905 l
+-0.230241 -0.270756 -0.221838 -0.267337 0 0 0 0.00281905 l
+-0.230241 -0.270756 -0.229227 -0.274779 0 0 0 0.00281905 l
+0.277643 0.207278 0.278334 0.197929 0 0 0 0.00281905 l
+0.277643 0.207278 0.28329 0.214294 0 0 0 0.00281905 l
+0.277643 0.207278 0.268162 0.207814 0 0 0 0.00281905 l
+-0.912569 -0.313717 -0.914743 -0.331412 0 0 0 0.00281905 l
+-0.912569 -0.313717 -0.91112 -0.305925 0 0 0 0.00281905 l
+-0.912569 -0.313717 -0.925903 -0.313 0 0 0 0.00281905 l
+-0.724544 -0.423067 -0.716477 -0.426087 0 0 0 0.00281905 l
+-0.724544 -0.423067 -0.734186 -0.427437 0 0 0 0.00281905 l
+-0.0586321 0.970977 -0.0496149 0.991074 0 0 0 0.00281905 l
+0.399564 0.642568 0.40843 0.633497 0 0 0 0.00281905 l
+0.399564 0.642568 0.387772 0.650882 0 0 0 0.00281905 l
+-0.106892 -0.79253 -0.0939756 -0.791091 0 0 0 0.00281905 l
+-0.106892 -0.79253 -0.106155 -0.796698 0 0 0 0.00281905 l
+0.587043 0.723975 0.592698 0.738297 0 0 0 0.00281905 l
+0.587043 0.723975 0.600439 0.723525 0 0 0 0.00281905 l
+0.587043 0.723975 0.57982 0.72583 0 0 0 0.00281905 l
+-0.397883 -0.219108 -0.38346 -0.215206 0 0 0 0.00281905 l
+-0.397883 -0.219108 -0.403671 -0.216343 0 0 0 0.00281905 l
+-0.56261 0.757775 -0.560918 0.746387 0 0 0 0.00281905 l
+-0.56261 0.757775 -0.568555 0.775531 0 0 0 0.00281905 l
+-0.56261 0.757775 -0.54037 0.765047 0 0 0 0.00281905 l
+-0.237929 0.189347 -0.233103 0.174737 0 0 0 0.00281905 l
+-0.237929 0.189347 -0.229485 0.192712 0 0 0 0.00281905 l
+0.219034 0.730701 0.224202 0.745603 0 0 0 0.00281905 l
+0.219034 0.730701 0.226267 0.727965 0 0 0 0.00281905 l
+0.219034 0.730701 0.207588 0.714479 0 0 0 0.00281905 l
+-0.173523 -0.267918 -0.1673 -0.27514 0 0 0 0.00281905 l
+-0.173523 -0.267918 -0.168794 -0.259154 0 0 0 0.00281905 l
+0.762023 -0.0387265 0.767676 -0.0484075 0 0 0 0.00281905 l
+-0.395724 -0.16523 -0.387994 -0.151597 0 0 0 0.00281905 l
+-0.395724 -0.16523 -0.414793 -0.160972 0 0 0 0.00281905 l
+0.167196 -0.308028 0.183864 -0.298683 0 0 0 0.00281905 l
+0.167196 -0.308028 0.159245 -0.322939 0 0 0 0.00281905 l
+0.096434 -0.521626 0.107857 -0.531274 0 0 0 0.00281905 l
+0.848 -0.010964 0.848544 -0.00604996 0 0 0 0.00281905 l
+0.848 -0.010964 0.85635 -0.0139479 0 0 0 0.00281905 l
+0.848 -0.010964 0.835501 -0.0188345 0 0 0 0.00281905 l
+-0.509571 0.476904 -0.509447 0.483794 0 0 0 0.00281905 l
+-0.509571 0.476904 -0.512883 0.461347 0 0 0 0.00281905 l
+0.35261 0.840797 0.352017 0.848214 0 0 0 0.00281905 l
+0.35261 0.840797 0.366186 0.838884 0 0 0 0.00281905 l
+0.35261 0.840797 0.341354 0.835749 0 0 0 0.00281905 l
+-0.512512 -0.445704 -0.514227 -0.445139 0 0 0 0.00281905 l
+-0.536502 0.189372 -0.537148 0.196208 0 0 0 0.00281905 l
+-0.536502 0.189372 -0.527257 0.180312 0 0 0 0.00281905 l
+0.674158 0.523633 0.677327 0.515092 0 0 0 0.00281905 l
+0.674158 0.523633 0.662978 0.518548 0 0 0 0.00281905 l
+0.357045 -0.434138 0.360225 -0.434812 0 0 0 0.00281905 l
+0.357045 -0.434138 0.351496 -0.429794 0 0 0 0.00281905 l
+0.872109 0.0907807 0.871962 0.0878966 0 0 0 0.00281905 l
+0.872109 0.0907807 0.875383 0.0989741 0 0 0 0.00281905 l
+0.161083 -0.405013 0.162655 -0.405756 0 0 0 0.00281905 l
+0.161083 -0.405013 0.150608 -0.409452 0 0 0 0.00281905 l
+0.725783 0.268143 0.74456 0.266009 0 0 0 0.00281905 l
+0.725783 0.268143 0.723266 0.272772 0 0 0 0.00281905 l
+0.0540049 0.834331 0.059071 0.838298 0 0 0 0.00281905 l
+0.0540049 0.834331 0.0494847 0.840127 0 0 0 0.00281905 l
+0.432481 -0.15578 0.427859 -0.141307 0 0 0 0.00281905 l
+0.432481 -0.15578 0.442709 -0.164076 0 0 0 0.00281905 l
+-0.602414 0.106747 -0.600449 0.108819 0 0 0 0.00281905 l
+-0.602414 0.106747 -0.616032 0.108037 0 0 0 0.00281905 l
+0.0432767 -0.231503 0.0579499 -0.235702 0 0 0 0.00281905 l
+0.0432767 -0.231503 0.0421582 -0.230135 0 0 0 0.00281905 l
+-0.222582 0.750373 -0.201912 0.744344 0 0 0 0.00281905 l
+-0.222582 0.750373 -0.223731 0.736607 0 0 0 0.00281905 l
+-0.396012 -0.796179 -0.391777 -0.781627 0 0 0 0.00281905 l
+-0.396012 -0.796179 -0.416449 -0.793478 0 0 0 0.00281905 l
+0.256363 0.497871 0.268757 0.492305 0 0 0 0.00281905 l
+0.256363 0.497871 0.252156 0.48766 0 0 0 0.00281905 l
+0.256363 0.497871 0.259507 0.502527 0 0 0 0.00281905 l
+-0.394923 0.243734 -0.385247 0.243873 0 0 0 0.00281905 l
+-0.394923 0.243734 -0.406681 0.237282 0 0 0 0.00281905 l
+-0.72206 -0.455203 -0.735877 -0.440541 0 0 0 0.00281905 l
+-0.72206 -0.455203 -0.710684 -0.461057 0 0 0 0.00281905 l
+-0.72206 -0.455203 -0.737724 -0.46699 0 0 0 0.00281905 l
+-0.350873 0.103311 -0.342582 0.102433 0 0 0 0.00281905 l
+-0.350873 0.103311 -0.368318 0.0954764 0 0 0 0.00281905 l
+0.682151 0.176683 0.693523 0.175183 0 0 0 0.00281905 l
+0.682151 0.176683 0.676223 0.159156 0 0 0 0.00281905 l
+0.682151 0.176683 0.674131 0.181231 0 0 0 0.00281905 l
+-0.515777 0.398971 -0.509504 0.412853 0 0 0 0.00281905 l
+-0.515777 0.398971 -0.517601 0.394785 0 0 0 0.00281905 l
+0.186631 0.890063 0.196083 0.889086 0 0 0 0.00281905 l
+0.186631 0.890063 0.187225 0.881743 0 0 0 0.00281905 l
+0.186631 0.890063 0.181798 0.892738 0 0 0 0.00281905 l
+0.734103 -0.00515419 0.732715 -0.00948405 0 0 0 0.00281905 l
+0.734103 -0.00515419 0.735149 -0.00368851 0 0 0 0.00281905 l
+0.378233 0.288489 0.373136 0.292543 0 0 0 0.00281905 l
+-0.74049 0.280808 -0.730535 0.274471 0 0 0 0.00281905 l
+-0.74049 0.280808 -0.751768 0.268491 0 0 0 0.00281905 l
+-0.74049 0.280808 -0.735849 0.289693 0 0 0 0.00281905 l
+0.0649928 -0.107606 0.068112 -0.121265 0 0 0 0.00281905 l
+0.0649928 -0.107606 0.0538495 -0.0930439 0 0 0 0.00281905 l
+0.512947 -0.476369 0.514249 -0.468975 0 0 0 0.00281905 l
+0.512947 -0.476369 0.52295 -0.487863 0 0 0 0.00281905 l
+0.512947 -0.476369 0.50235 -0.490125 0 0 0 0.00281905 l
+0.229622 0.650192 0.2433 0.647582 0 0 0 0.00281905 l
+0.215491 0.916948 0.219064 0.936417 0 0 0 0.00281905 l
+0.215491 0.916948 0.222437 0.913039 0 0 0 0.00281905 l
+0.428984 0.380111 0.4234 0.377135 0 0 0 0.00281905 l
+0.435036 -0.564171 0.438339 -0.569736 0 0 0 0.00281905 l
+0.435036 -0.564171 0.419586 -0.55775 0 0 0 0.00281905 l
+-0.0803243 0.00181404 -0.0798379 0.00702604 0 0 0 0.00281905 l
+-0.0803243 0.00181404 -0.0759408 0.000703685 0 0 0 0.00281905 l
+-0.0803243 0.00181404 -0.0865835 0.000396928 0 0 0 0.00281905 l
+-0.677662 0.2214 -0.67587 0.234855 0 0 0 0.00281905 l
+0.0768841 0.551869 0.0739938 0.528442 0 0 0 0.00281905 l
+0.0768841 0.551869 0.0794692 0.566218 0 0 0 0.00281905 l
+-0.191288 0.0943496 -0.196044 0.0774738 0 0 0 0.00281905 l
+-0.191288 0.0943496 -0.209435 0.097832 0 0 0 0.00281905 l
+-0.4704 0.643535 -0.454803 0.629458 0 0 0 0.00281905 l
+-0.4704 0.643535 -0.472664 0.641365 0 0 0 0.00281905 l
+0.66913 0.636835 0.661525 0.626703 0 0 0 0.00281905 l
+0.66913 0.636835 0.671624 0.645106 0 0 0 0.00281905 l
+0.66913 0.636835 0.689006 0.633814 0 0 0 0.00281905 l
+-0.912412 0.0687866 -0.905055 0.0581861 0 0 0 0.00281905 l
+-0.912412 0.0687866 -0.903965 0.0793392 0 0 0 0.00281905 l
+-0.203045 0.503336 -0.193041 0.495938 0 0 0 0.00281905 l
+-0.203045 0.503336 -0.210473 0.495437 0 0 0 0.00281905 l
+0.497283 0.292812 0.515742 0.300438 0 0 0 0.00281905 l
+0.497283 0.292812 0.483999 0.299126 0 0 0 0.00281905 l
+-0.911816 0.00590096 -0.911963 0.0127607 0 0 0 0.00281905 l
+-0.911816 0.00590096 -0.921847 0.00413317 0 0 0 0.00281905 l
+-0.0694484 0.260371 -0.0723769 0.270172 0 0 0 0.00281905 l
+-0.0694484 0.260371 -0.0648853 0.255454 0 0 0 0.00281905 l
+-0.0694484 0.260371 -0.0786134 0.261651 0 0 0 0.00281905 l
+-0.476803 0.131814 -0.4756 0.131618 0 0 0 0.00281905 l
+-0.476803 0.131814 -0.484895 0.127886 0 0 0 0.00281905 l
+0.054131 0.344527 0.059482 0.332173 0 0 0 0.00281905 l
+0.054131 0.344527 0.056529 0.353663 0 0 0 0.00281905 l
+-0.475811 0.444583 -0.488358 0.460001 0 0 0 0.00281905 l
+-0.475811 0.444583 -0.489538 0.433212 0 0 0 0.00281905 l
+0.511902 -0.43237 0.517781 -0.433832 0 0 0 0.00281905 l
+0.511902 -0.43237 0.509363 -0.429853 0 0 0 0.00281905 l
+0.211318 -0.959537 0.213599 -0.972591 0 0 0 0.00281905 l
+0.211318 -0.959537 0.228666 -0.951708 0 0 0 0.00281905 l
+0.211318 -0.959537 0.19772 -0.963034 0 0 0 0.00281905 l
+0.453733 0.427783 0.461029 0.431465 0 0 0 0.00281905 l
+0.453733 0.427783 0.447568 0.429806 0 0 0 0.00281905 l
+0.355891 -0.769312 0.368136 -0.775439 0 0 0 0.00281905 l
+0.355891 -0.769312 0.356169 -0.783406 0 0 0 0.00281905 l
+0.355891 -0.769312 0.343835 -0.77322 0 0 0 0.00281905 l
+0.0895203 0.263639 0.083658 0.27673 0 0 0 0.00281905 l
+0.0895203 0.263639 0.0765299 0.262166 0 0 0 0.00281905 l
+-0.0406821 -0.291902 -0.0386577 -0.29579 0 0 0 0.00281905 l
+-0.728379 -0.0701402 -0.731631 -0.0867363 0 0 0 0.00281905 l
+-0.728379 -0.0701402 -0.71196 -0.0641645 0 0 0 0.00281905 l
+-0.728379 -0.0701402 -0.743718 -0.0579772 0 0 0 0.00281905 l
+-0.818944 -0.163808 -0.837752 -0.161693 0 0 0 0.00281905 l
+-0.62697 -0.00054444 -0.632505 0.0165645 0 0 0 0.00281905 l
+-0.62697 -0.00054444 -0.613143 -0.000416248 0 0 0 0.00281905 l
+0.362262 -0.410449 0.367285 -0.419998 0 0 0 0.00281905 l
+0.362262 -0.410449 0.353145 -0.414197 0 0 0 0.00281905 l
+-0.611648 0.279697 -0.606897 0.276546 0 0 0 0.00281905 l
+-0.382249 0.767112 -0.376034 0.76153 0 0 0 0.00281905 l
+-0.382249 0.767112 -0.37574 0.775321 0 0 0 0.00281905 l
+-0.382249 0.767112 -0.384989 0.757887 0 0 0 0.00281905 l
+0.444562 -0.652983 0.444061 -0.65849 0 0 0 0.00281905 l
+0.444562 -0.652983 0.4482 -0.64025 0 0 0 0.00281905 l
+0.569441 -0.476936 0.567084 -0.489137 0 0 0 0.00281905 l
+0.569441 -0.476936 0.55597 -0.469859 0 0 0 0.00281905 l
+0.687327 -0.204701 0.701034 -0.1978 0 0 0 0.00281905 l
+0.687327 -0.204701 0.695096 -0.213498 0 0 0 0.00281905 l
+-0.781055 0.208836 -0.765014 0.208729 0 0 0 0.00281905 l
+-0.781055 0.208836 -0.7835 0.223876 0 0 0 0.00281905 l
+-0.781055 0.208836 -0.789285 0.199571 0 0 0 0.00281905 l
+-0.638436 -0.175104 -0.640268 -0.184745 0 0 0 0.00281905 l
+-0.638436 -0.175104 -0.631496 -0.172217 0 0 0 0.00281905 l
+0.29342 -0.248933 0.298892 -0.242969 0 0 0 0.00281905 l
+0.29342 -0.248933 0.305731 -0.258657 0 0 0 0.00281905 l
+0.29342 -0.248933 0.290608 -0.248222 0 0 0 0.00281905 l
+-0.849515 -0.508807 -0.846067 -0.525519 0 0 0 0.00281905 l
+-0.849515 -0.508807 -0.864638 -0.49896 0 0 0 0.00281905 l
+-0.575461 -0.511595 -0.577367 -0.526671 0 0 0 0.00281905 l
+-0.575461 -0.511595 -0.568277 -0.50445 0 0 0 0.00281905 l
+0.181653 0.357679 0.182689 0.343951 0 0 0 0.00281905 l
+0.181653 0.357679 0.177908 0.36511 0 0 0 0.00281905 l
+-0.418941 0.0978936 -0.409843 0.0917576 0 0 0 0.00281905 l
+-0.418941 0.0978936 -0.413606 0.104885 0 0 0 0.00281905 l
+0.176952 0.178014 0.19727 0.182705 0 0 0 0.00281905 l
+0.176952 0.178014 0.173389 0.180649 0 0 0 0.00281905 l
+0.413123 -0.793556 0.418329 -0.776123 0 0 0 0.00281905 l
+0.413123 -0.793556 0.410202 -0.8095 0 0 0 0.00281905 l
+0.413123 -0.793556 0.399478 -0.781768 0 0 0 0.00281905 l
+-0.712621 0.484928 -0.70077 0.471456 0 0 0 0.00281905 l
+0.147632 0.190437 0.154959 0.176355 0 0 0 0.00281905 l
+0.147632 0.190437 0.150715 0.192188 0 0 0 0.00281905 l
+0.147632 0.190437 0.137696 0.194178 0 0 0 0.00281905 l
+-0.350425 -0.492611 -0.341193 -0.481314 0 0 0 0.00281905 l
+-0.350425 -0.492611 -0.367698 -0.499098 0 0 0 0.00281905 l
+0.21095 -0.0577675 0.223619 -0.0441659 0 0 0 0.00281905 l
+0.21095 -0.0577675 0.20339 -0.0657824 0 0 0 0.00281905 l
+-0.503319 0.324042 -0.488687 0.308278 0 0 0 0.00281905 l
+-0.503319 0.324042 -0.507934 0.326344 0 0 0 0.00281905 l
+0.894143 0.377623 0.895049 0.370642 0 0 0 0.00281905 l
+0.894143 0.377623 0.8962 0.387087 0 0 0 0.00281905 l
+-0.0241475 0.550379 -0.0235271 0.560363 0 0 0 0.00281905 l
+-0.0241475 0.550379 -0.00719245 0.547822 0 0 0 0.00281905 l
+0.251968 -0.300188 0.253373 -0.30039 0 0 0 0.00281905 l
+0.251968 -0.300188 0.23886 -0.305276 0 0 0 0.00281905 l
+-0.23025 -0.595513 -0.224412 -0.58172 0 0 0 0.00281905 l
+-0.23025 -0.595513 -0.231363 -0.611435 0 0 0 0.00281905 l
+-0.209467 0.350006 -0.202629 0.355891 0 0 0 0.00281905 l
+-0.209467 0.350006 -0.21528 0.357488 0 0 0 0.00281905 l
+-0.200413 0.907705 -0.21109 0.920662 0 0 0 0.00281905 l
+-0.200413 0.907705 -0.197096 0.896493 0 0 0 0.00281905 l
+-0.200413 0.907705 -0.216222 0.904024 0 0 0 0.00281905 l
+0.163962 -0.00261265 0.171294 -0.00601238 0 0 0 0.00281905 l
+0.163962 -0.00261265 0.155936 -0.0129222 0 0 0 0.00281905 l
+0.163962 -0.00261265 0.161423 -0.000510583 0 0 0 0.00281905 l
+-0.85085 -0.479579 -0.838153 -0.465883 0 0 0 0.00281905 l
+-0.85085 -0.479579 -0.864638 -0.49896 0 0 0 0.00281905 l
+0.560505 -0.405696 0.568403 -0.412442 0 0 0 0.00281905 l
+0.560505 -0.405696 0.549632 -0.415546 0 0 0 0.00281905 l
+0.560505 -0.405696 0.56037 -0.405123 0 0 0 0.00281905 l
+0.0727936 0.0280003 0.069611 0.0294489 0 0 0 0.00281905 l
+-0.404163 -0.905133 -0.389546 -0.908246 0 0 0 0.00281905 l
+0.368478 0.133971 0.374583 0.125258 0 0 0 0.00281905 l
+-0.605271 0.773787 -0.592309 0.782161 0 0 0 0.00281905 l
+-0.077703 0.356281 -0.0859777 0.363155 0 0 0 0.00281905 l
+0.66384 -0.415708 0.657794 -0.433041 0 0 0 0.00281905 l
+0.66384 -0.415708 0.666732 -0.402769 0 0 0 0.00281905 l
+0.66384 -0.415708 0.676104 -0.416441 0 0 0 0.00281905 l
+-0.717009 -0.532539 -0.719105 -0.515868 0 0 0 0.00281905 l
+-0.717009 -0.532539 -0.710127 -0.535737 0 0 0 0.00281905 l
+-0.717009 -0.532539 -0.721566 -0.535093 0 0 0 0.00281905 l
+0.620552 -0.308709 0.627747 -0.324871 0 0 0 0.00281905 l
+0.620552 -0.308709 0.626423 -0.304997 0 0 0 0.00281905 l
+0.620552 -0.308709 0.604886 -0.315332 0 0 0 0.00281905 l
+-0.927781 -0.172659 -0.917632 -0.163325 0 0 0 0.00281905 l
+-0.927781 -0.172659 -0.931481 -0.166737 0 0 0 0.00281905 l
+-0.927781 -0.172659 -0.933165 -0.178705 0 0 0 0.00281905 l
+0.016473 0.640136 0.0142219 0.647383 0 0 0 0.00281905 l
+0.016473 0.640136 0.0258828 0.637795 0 0 0 0.00281905 l
+0.016473 0.640136 0.013098 0.629567 0 0 0 0.00281905 l
+0.591381 0.545042 0.602876 0.547689 0 0 0 0.00281905 l
+0.591381 0.545042 0.594617 0.535582 0 0 0 0.00281905 l
+0.591381 0.545042 0.577597 0.545435 0 0 0 0.00281905 l
+0.658642 -0.633765 0.660966 -0.628441 0 0 0 0.00281905 l
+0.24998 0.345634 0.249742 0.35797 0 0 0 0.00281905 l
+0.24998 0.345634 0.246955 0.345503 0 0 0 0.00281905 l
+-0.203619 -0.79095 -0.198065 -0.802898 0 0 0 0.00281905 l
+-0.203619 -0.79095 -0.212365 -0.787524 0 0 0 0.00281905 l
+0.668486 -0.556291 0.687533 -0.540981 0 0 0 0.00281905 l
+0.668486 -0.556291 0.661574 -0.557356 0 0 0 0.00281905 l
+-0.0733442 -0.897057 -0.0664764 -0.909016 0 0 0 0.00281905 l
+-0.0733442 -0.897057 -0.0838997 -0.909238 0 0 0 0.00281905 l
+-0.0733442 -0.897057 -0.0769398 -0.892899 0 0 0 0.00281905 l
+0.438586 0.431477 0.445316 0.444545 0 0 0 0.00281905 l
+0.438586 0.431477 0.447568 0.429806 0 0 0 0.00281905 l
+0.438586 0.431477 0.424311 0.432701 0 0 0 0.00281905 l
+-0.615477 0.189529 -0.613496 0.198479 0 0 0 0.00281905 l
+-0.615477 0.189529 -0.603936 0.184845 0 0 0 0.00281905 l
+-0.615477 0.189529 -0.626341 0.174345 0 0 0 0.00281905 l
+-0.852358 -0.200454 -0.859756 -0.192855 0 0 0 0.00281905 l
+-0.201991 -0.334177 -0.192783 -0.32799 0 0 0 0.00281905 l
+-0.201991 -0.334177 -0.215101 -0.321994 0 0 0 0.00281905 l
+-0.201991 -0.334177 -0.216387 -0.344215 0 0 0 0.00281905 l
+0.614957 0.491171 0.620287 0.481315 0 0 0 0.00281905 l
+0.614957 0.491171 0.625074 0.499046 0 0 0 0.00281905 l
+0.602365 0.0965569 0.610185 0.108837 0 0 0 0.00281905 l
+0.602365 0.0965569 0.588372 0.104899 0 0 0 0.00281905 l
+-0.422004 -0.0594418 -0.418018 -0.0712548 0 0 0 0.00281905 l
+-0.422004 -0.0594418 -0.422156 -0.0566317 0 0 0 0.00281905 l
+0.416471 0.721495 0.417419 0.721553 0 0 0 0.00281905 l
+0.416471 0.721495 0.414221 0.726052 0 0 0 0.00281905 l
+0.108018 -0.453934 0.118477 -0.440509 0 0 0 0.00281905 l
+0.108018 -0.453934 0.112057 -0.456275 0 0 0 0.00281905 l
+0.108018 -0.453934 0.1016 -0.453225 0 0 0 0.00281905 l
+-0.0410162 0.425466 -0.030818 0.409307 0 0 0 0.00281905 l
+-0.0410162 0.425466 -0.0327066 0.440303 0 0 0 0.00281905 l
+-0.0410162 0.425466 -0.0536392 0.419437 0 0 0 0.00281905 l
+0.30907 0.313922 0.312524 0.308382 0 0 0 0.00281905 l
+0.30907 0.313922 0.310457 0.316311 0 0 0 0.00281905 l
+0.788867 -0.410458 0.802546 -0.418406 0 0 0 0.00281905 l
+0.788867 -0.410458 0.789085 -0.408865 0 0 0 0.00281905 l
+-0.6199 -0.719141 -0.623555 -0.710551 0 0 0 0.00281905 l
+0.0207839 -0.782327 0.0192621 -0.802804 0 0 0 0.00281905 l
+0.0207839 -0.782327 0.0367495 -0.773698 0 0 0 0.00281905 l
+0.0207839 -0.782327 0.0082151 -0.780968 0 0 0 0.00281905 l
+-0.489286 0.468563 -0.488358 0.460001 0 0 0 0.00281905 l
+-0.489286 0.468563 -0.476791 0.475314 0 0 0 0.00281905 l
+-0.828441 -0.13827 -0.821213 -0.141602 0 0 0 0.00281905 l
+-0.828441 -0.13827 -0.836495 -0.129366 0 0 0 0.00281905 l
+0.312246 -0.538192 0.312506 -0.518838 0 0 0 0.00281905 l
+0.312246 -0.538192 0.305077 -0.550722 0 0 0 0.00281905 l
+0.122978 -0.193479 0.120412 -0.201425 0 0 0 0.00281905 l
+0.122978 -0.193479 0.121215 -0.190181 0 0 0 0.00281905 l
+0.405923 -0.549714 0.399741 -0.536612 0 0 0 0.00281905 l
+0.405923 -0.549714 0.412754 -0.544489 0 0 0 0.00281905 l
+-0.408887 -0.535474 -0.40498 -0.546262 0 0 0 0.00281905 l
+-0.408887 -0.535474 -0.401211 -0.525683 0 0 0 0.00281905 l
+-0.408887 -0.535474 -0.420875 -0.538723 0 0 0 0.00281905 l
+0.512034 0.652995 0.520466 0.671158 0 0 0 0.00281905 l
+0.512034 0.652995 0.514049 0.641165 0 0 0 0.00281905 l
+-0.232792 0.368571 -0.23543 0.38176 0 0 0 0.00281905 l
+-0.232792 0.368571 -0.22866 0.363155 0 0 0 0.00281905 l
+0.170156 0.155711 0.176102 0.152404 0 0 0 0.00281905 l
+0.170156 0.155711 0.158099 0.157696 0 0 0 0.00281905 l
+-0.245328 -0.275228 -0.250225 -0.268649 0 0 0 0.00281905 l
+-0.245328 -0.275228 -0.243824 -0.279169 0 0 0 0.00281905 l
+-0.229369 0.49219 -0.216662 0.495779 0 0 0 0.00281905 l
+-0.229369 0.49219 -0.223867 0.480294 0 0 0 0.00281905 l
+0.471566 0.765735 0.486021 0.770694 0 0 0 0.00281905 l
+0.471566 0.765735 0.466878 0.77483 0 0 0 0.00281905 l
+0.816169 -0.181239 0.818649 -0.185561 0 0 0 0.00281905 l
+0.816169 -0.181239 0.804297 -0.179079 0 0 0 0.00281905 l
+0.467481 -0.439808 0.457257 -0.437549 0 0 0 0.00281905 l
+-0.467281 -0.637469 -0.461833 -0.638415 0 0 0 0.00281905 l
+-0.467281 -0.637469 -0.480145 -0.639647 0 0 0 0.00281905 l
+-0.4756 0.131618 -0.469832 0.125438 0 0 0 0.00281905 l
+-0.4756 0.131618 -0.476803 0.131814 0 0 0 0.00281905 l
+0.406068 0.415504 0.412791 0.413565 0 0 0 0.00281905 l
+0.406068 0.415504 0.39105 0.420393 0 0 0 0.00281905 l
+-0.294489 -0.41037 -0.289494 -0.420576 0 0 0 0.00281905 l
+-0.294489 -0.41037 -0.300444 -0.407416 0 0 0 0.00281905 l
+-0.27372 -0.795005 -0.275825 -0.773407 0 0 0 0.00281905 l
+-0.27372 -0.795005 -0.260768 -0.801085 0 0 0 0.00281905 l
+-0.595858 -0.713065 -0.579277 -0.711791 0 0 0 0.00281905 l
+-0.595858 -0.713065 -0.599385 -0.730138 0 0 0 0.00281905 l
+-0.595858 -0.713065 -0.599565 -0.708621 0 0 0 0.00281905 l
+-0.749671 0.0527303 -0.748059 0.0627779 0 0 0 0.00281905 l
+-0.749671 0.0527303 -0.75252 0.0444008 0 0 0 0.00281905 l
+0.811891 -0.447673 0.826242 -0.454828 0 0 0 0.00281905 l
+0.811891 -0.447673 0.802764 -0.438565 0 0 0 0.00281905 l
+-0.139392 0.0499299 -0.126635 0.0328223 0 0 0 0.00281905 l
+-0.139392 0.0499299 -0.139771 0.0526833 0 0 0 0.00281905 l
+-0.425917 0.671917 -0.414007 0.678662 0 0 0 0.00281905 l
+-0.425917 0.671917 -0.429511 0.658783 0 0 0 0.00281905 l
+-0.425917 0.671917 -0.428066 0.672781 0 0 0 0.00281905 l
+-0.404596 -0.290831 -0.391239 -0.298605 0 0 0 0.00281905 l
+-0.404596 -0.290831 -0.413061 -0.295541 0 0 0 0.00281905 l
+0.751678 0.172211 0.758726 0.172771 0 0 0 0.00281905 l
+0.751678 0.172211 0.752506 0.168586 0 0 0 0.00281905 l
+0.166248 -0.962485 0.168231 -0.962432 0 0 0 0.00281905 l
+0.166248 -0.962485 0.160262 -0.976401 0 0 0 0.00281905 l
+0.137696 0.194178 0.147632 0.190437 0 0 0 0.00281905 l
+0.137696 0.194178 0.125318 0.189865 0 0 0 0.00281905 l
+0.0482858 -0.431582 0.0532444 -0.431365 0 0 0 0.00281905 l
+-0.523493 0.188651 -0.506963 0.184236 0 0 0 0.00281905 l
+-0.523493 0.188651 -0.527257 0.180312 0 0 0 0.00281905 l
+-0.336929 -0.162724 -0.340426 -0.173472 0 0 0 0.00281905 l
+-0.336929 -0.162724 -0.34493 -0.1493 0 0 0 0.00281905 l
+-0.0318264 -0.620569 -0.0318552 -0.602183 0 0 0 0.00281905 l
+-0.0318264 -0.620569 -0.0207099 -0.624262 0 0 0 0.00281905 l
+-0.0318264 -0.620569 -0.0361393 -0.622353 0 0 0 0.00281905 l
+-0.438703 0.860624 -0.446122 0.876254 0 0 0 0.00281905 l
+-0.438703 0.860624 -0.422024 0.850861 0 0 0 0.00281905 l
+-0.438703 0.860624 -0.44041 0.859266 0 0 0 0.00281905 l
+-0.405356 -0.873188 -0.398286 -0.878602 0 0 0 0.00281905 l
+-0.405356 -0.873188 -0.401354 -0.868161 0 0 0 0.00281905 l
+-0.405356 -0.873188 -0.421641 -0.879484 0 0 0 0.00281905 l
+0.266757 0.541485 0.265718 0.536611 0 0 0 0.00281905 l
+0.266757 0.541485 0.262169 0.546691 0 0 0 0.00281905 l
+0.153815 0.242217 0.160481 0.247179 0 0 0 0.00281905 l
+0.153815 0.242217 0.138477 0.240926 0 0 0 0.00281905 l
+0.0237127 -0.412763 0.0287167 -0.412798 0 0 0 0.00281905 l
+0.0237127 -0.412763 0.0159871 -0.408132 0 0 0 0.00281905 l
+0.466878 0.77483 0.471566 0.765735 0 0 0 0.00281905 l
+0.466878 0.77483 0.4577 0.778656 0 0 0 0.00281905 l
+0.775095 -0.150382 0.780185 -0.161666 0 0 0 0.00281905 l
+0.775095 -0.150382 0.772971 -0.142863 0 0 0 0.00281905 l
+0.680504 -0.660518 0.687508 -0.669762 0 0 0 0.00281905 l
+-0.889702 -0.219306 -0.883921 -0.213445 0 0 0 0.00281905 l
+-0.889702 -0.219306 -0.901382 -0.216828 0 0 0 0.00281905 l
+-0.311918 -0.712942 -0.314749 -0.713841 0 0 0 0.00281905 l
+-0.934335 0.0400148 -0.926015 0.0360989 0 0 0 0.00281905 l
+-0.934335 0.0400148 -0.952389 0.0570659 0 0 0 0.00281905 l
+-0.934335 0.0400148 -0.944985 0.0307441 0 0 0 0.00281905 l
+-0.22866 0.363155 -0.224217 0.362874 0 0 0 0.00281905 l
+-0.22866 0.363155 -0.232792 0.368571 0 0 0 0.00281905 l
+0.494381 0.574901 0.508869 0.565763 0 0 0 0.00281905 l
+0.494381 0.574901 0.477064 0.567031 0 0 0 0.00281905 l
+0.252687 -0.864036 0.258928 -0.857938 0 0 0 0.00281905 l
+0.252687 -0.864036 0.246912 -0.869057 0 0 0 0.00281905 l
+-0.41801 0.734096 -0.430592 0.749362 0 0 0 0.00281905 l
+-0.41801 0.734096 -0.415368 0.735076 0 0 0 0.00281905 l
+-0.41801 0.734096 -0.41818 0.733769 0 0 0 0.00281905 l
+-0.0257452 0.438031 -0.0258673 0.442291 0 0 0 0.00281905 l
+0.82949 0.231415 0.825176 0.213025 0 0 0 0.00281905 l
+0.82949 0.231415 0.837642 0.228156 0 0 0 0.00281905 l
+0.82949 0.231415 0.826091 0.233118 0 0 0 0.00281905 l
+-0.931481 -0.166737 -0.927781 -0.172659 0 0 0 0.00281905 l
+-0.931481 -0.166737 -0.933953 -0.160621 0 0 0 0.00281905 l
+-0.9208 0.16953 -0.911537 0.168458 0 0 0 0.00281905 l
+-0.9208 0.16953 -0.932398 0.186754 0 0 0 0.00281905 l
+-0.581842 -0.290666 -0.571152 -0.293083 0 0 0 0.00281905 l
+0.0489667 0.474009 0.057367 0.489707 0 0 0 0.00281905 l
+0.0489667 0.474009 0.0414407 0.475033 0 0 0 0.00281905 l
+-0.197982 -0.476263 -0.193443 -0.477016 0 0 0 0.00281905 l
+-0.197982 -0.476263 -0.203807 -0.482528 0 0 0 0.00281905 l
+-0.817779 0.0254674 -0.808412 0.0171506 0 0 0 0.00281905 l
+-0.817779 0.0254674 -0.817255 0.0275186 0 0 0 0.00281905 l
+0.688649 0.539186 0.690551 0.54905 0 0 0 0.00281905 l
+0.688649 0.539186 0.694848 0.535382 0 0 0 0.00281905 l
+0.367788 -0.2251 0.374484 -0.210449 0 0 0 0.00281905 l
+0.367788 -0.2251 0.377996 -0.232162 0 0 0 0.00281905 l
+0.724696 -0.459713 0.71683 -0.451035 0 0 0 0.00281905 l
+0.724696 -0.459713 0.716776 -0.468322 0 0 0 0.00281905 l
+0.275646 -0.796359 0.268165 -0.778566 0 0 0 0.00281905 l
+0.275646 -0.796359 0.272856 -0.798442 0 0 0 0.00281905 l
+0.765169 0.0958805 0.783686 0.0952758 0 0 0 0.00281905 l
+0.4886 -0.340108 0.475199 -0.349387 0 0 0 0.00281905 l
+-0.537148 0.196208 -0.536502 0.189372 0 0 0 0.00281905 l
+0.468372 -0.636661 0.471366 -0.64455 0 0 0 0.00281905 l
+0.468372 -0.636661 0.4482 -0.64025 0 0 0 0.00281905 l
+0.591035 0.111227 0.588372 0.104899 0 0 0 0.00281905 l
+-0.366591 -0.0177968 -0.364179 -0.0114705 0 0 0 0.00281905 l
+-0.366591 -0.0177968 -0.357323 -0.0240345 0 0 0 0.00281905 l
+-0.366591 -0.0177968 -0.373701 -0.0202088 0 0 0 0.00281905 l
+-0.85249 0.372585 -0.854265 0.380865 0 0 0 0.00281905 l
+-0.0519356 0.32514 -0.045084 0.32164 0 0 0 0.00281905 l
+-0.0519356 0.32514 -0.0629643 0.332049 0 0 0 0.00281905 l
+-0.175264 0.262946 -0.163204 0.26456 0 0 0 0.00281905 l
+0.548264 0.285955 0.540054 0.29944 0 0 0 0.00281905 l
+0.548264 0.285955 0.544219 0.279621 0 0 0 0.00281905 l
+-0.184714 -0.815567 -0.175147 -0.83167 0 0 0 0.00281905 l
+-0.184714 -0.815567 -0.198886 -0.811867 0 0 0 0.00281905 l
+0.407732 -0.297409 0.423263 -0.290453 0 0 0 0.00281905 l
+0.407732 -0.297409 0.40394 -0.313381 0 0 0 0.00281905 l
+0.605067 0.329911 0.587043 0.337787 0 0 0 0.00281905 l
+0.605067 0.329911 0.6088 0.326778 0 0 0 0.00281905 l
+0.0594682 0.87758 0.0581151 0.887564 0 0 0 0.00281905 l
+0.0594682 0.87758 0.0607803 0.876963 0 0 0 0.00281905 l
+0.0594682 0.87758 0.0572939 0.872737 0 0 0 0.00281905 l
+0.339508 -0.126727 0.34072 -0.116199 0 0 0 0.00281905 l
+0.339508 -0.126727 0.35618 -0.135943 0 0 0 0.00281905 l
+0.43761 0.470585 0.440991 0.477605 0 0 0 0.00281905 l
+0.43761 0.470585 0.440497 0.468303 0 0 0 0.00281905 l
+0.43761 0.470585 0.432853 0.475575 0 0 0 0.00281905 l
+-0.398796 0.434046 -0.393998 0.438416 0 0 0 0.00281905 l
+-0.398796 0.434046 -0.403822 0.425605 0 0 0 0.00281905 l
+-0.314879 0.251368 -0.318459 0.233084 0 0 0 0.00281905 l
+-0.314879 0.251368 -0.325779 0.265193 0 0 0 0.00281905 l
+-0.575306 -0.334004 -0.580122 -0.352681 0 0 0 0.00281905 l
+-0.575306 -0.334004 -0.56875 -0.325975 0 0 0 0.00281905 l
+-0.575306 -0.334004 -0.583502 -0.332021 0 0 0 0.00281905 l
+0.269082 0.672881 0.286418 0.673668 0 0 0 0.00281905 l
+0.269082 0.672881 0.258514 0.687966 0 0 0 0.00281905 l
+-0.376102 -0.132359 -0.378806 -0.137068 0 0 0 0.00281905 l
+0.353544 0.346141 0.353828 0.343307 0 0 0 0.00281905 l
+0.353544 0.346141 0.358437 0.354667 0 0 0 0.00281905 l
+0.551423 -0.495062 0.558095 -0.485132 0 0 0 0.00281905 l
+-0.341193 -0.481314 -0.332196 -0.486093 0 0 0 0.00281905 l
+-0.341193 -0.481314 -0.350425 -0.492611 0 0 0 0.00281905 l
+-0.341193 -0.481314 -0.353603 -0.475063 0 0 0 0.00281905 l
+0.324336 -0.119121 0.34072 -0.116199 0 0 0 0.00281905 l
+0.324336 -0.119121 0.317976 -0.132037 0 0 0 0.00281905 l
+0.324336 -0.119121 0.311589 -0.107062 0 0 0 0.00281905 l
+-0.824132 0.156096 -0.821844 0.160754 0 0 0 0.00281905 l
+0.23008 0.252358 0.250948 0.256017 0 0 0 0.00281905 l
+0.23008 0.252358 0.224107 0.249591 0 0 0 0.00281905 l
+-0.108798 0.972631 -0.0841777 0.988438 0 0 0 0.00281905 l
+-0.108798 0.972631 -0.113673 0.960324 0 0 0 0.00281905 l
+-0.108798 0.972631 -0.11197 0.977427 0 0 0 0.00281905 l
+-0.63172 0.400716 -0.62818 0.410708 0 0 0 0.00281905 l
+-0.133125 0.797976 -0.124564 0.800847 0 0 0 0.00281905 l
+-0.133125 0.797976 -0.146837 0.795197 0 0 0 0.00281905 l
+-0.406922 -0.304288 -0.399406 -0.321599 0 0 0 0.00281905 l
+-0.406922 -0.304288 -0.407674 -0.300619 0 0 0 0.00281905 l
+-0.45184 -0.0423567 -0.432147 -0.0382859 0 0 0 0.00281905 l
+-0.45184 -0.0423567 -0.464658 -0.0316159 0 0 0 0.00281905 l
+0.991129 0.0651264 0.994508 0.0537307 0 0 0 0.00281905 l
+0.991129 0.0651264 0.983838 0.0666955 0 0 0 0.00281905 l
+0.480863 -0.793543 0.485724 -0.794402 0 0 0 0.00281905 l
+0.480863 -0.793543 0.465672 -0.777935 0 0 0 0.00281905 l
+-0.661308 -0.161431 -0.658286 -0.148888 0 0 0 0.00281905 l
+-0.661308 -0.161431 -0.671621 -0.166178 0 0 0 0.00281905 l
+0.389198 -0.169432 0.398177 -0.173902 0 0 0 0.00281905 l
+0.389198 -0.169432 0.380745 -0.159776 0 0 0 0.00281905 l
+0.176807 -0.887129 0.187726 -0.886056 0 0 0 0.00281905 l
+0.176807 -0.887129 0.174375 -0.896239 0 0 0 0.00281905 l
+-0.663797 0.165933 -0.6626 0.155326 0 0 0 0.00281905 l
+-0.663797 0.165933 -0.667736 0.1809 0 0 0 0.00281905 l
+-0.0100515 0.488499 -0.0100742 0.498498 0 0 0 0.00281905 l
+-0.0100515 0.488499 9.33519e-05 0.476591 0 0 0 0.00281905 l
+0.823574 0.464183 0.82865 0.448759 0 0 0 0.00281905 l
+0.823574 0.464183 0.805232 0.474603 0 0 0 0.00281905 l
+-0.551375 -0.603786 -0.543251 -0.610935 0 0 0 0.00281905 l
+-0.551375 -0.603786 -0.556272 -0.616707 0 0 0 0.00281905 l
+-0.424513 -0.656724 -0.41998 -0.650518 0 0 0 0.00281905 l
+-0.424513 -0.656724 -0.419209 -0.669044 0 0 0 0.00281905 l
+-0.424513 -0.656724 -0.427777 -0.658417 0 0 0 0.00281905 l
+0.118477 -0.440509 0.124012 -0.424301 0 0 0 0.00281905 l
+0.118477 -0.440509 0.108018 -0.453934 0 0 0 0.00281905 l
+-0.246898 -0.172155 -0.24596 -0.174915 0 0 0 0.00281905 l
+-0.246898 -0.172155 -0.25786 -0.16767 0 0 0 0.00281905 l
+-0.158437 -0.342701 -0.14505 -0.329224 0 0 0 0.00281905 l
+-0.158437 -0.342701 -0.164051 -0.342597 0 0 0 0.00281905 l
+0.0516108 -0.135691 0.0494498 -0.14821 0 0 0 0.00281905 l
+0.0776741 -0.0366574 0.0894244 -0.0234995 0 0 0 0.00281905 l
+0.0776741 -0.0366574 0.0707834 -0.0317987 0 0 0 0.00281905 l
+0.0776741 -0.0366574 0.0761579 -0.03983 0 0 0 0.00281905 l
+-0.800159 0.355545 -0.797912 0.353186 0 0 0 0.00281905 l
+-0.926677 -0.12328 -0.936466 -0.106454 0 0 0 0.00281905 l
+-0.926677 -0.12328 -0.937839 -0.131783 0 0 0 0.00281905 l
+0.425723 0.315389 0.424491 0.310354 0 0 0 0.00281905 l
+0.442709 -0.164076 0.454717 -0.158842 0 0 0 0.00281905 l
+0.442709 -0.164076 0.443847 -0.167558 0 0 0 0.00281905 l
+0.442709 -0.164076 0.432481 -0.15578 0 0 0 0.00281905 l
+0.221392 -0.721223 0.222807 -0.728631 0 0 0 0.00281905 l
+0.221392 -0.721223 0.214702 -0.720671 0 0 0 0.00281905 l
+0.751082 -0.649217 0.756375 -0.649583 0 0 0 0.00281905 l
+0.751082 -0.649217 0.74593 -0.665095 0 0 0 0.00281905 l
+-0.446012 0.00224228 -0.444697 0.016905 0 0 0 0.00281905 l
+-0.446012 0.00224228 -0.442668 -0.00407661 0 0 0 0.00281905 l
+-0.432712 -0.143497 -0.433728 -0.155211 0 0 0 0.00281905 l
+-0.432712 -0.143497 -0.430815 -0.141795 0 0 0 0.00281905 l
+0.108754 0.893897 0.113321 0.90287 0 0 0 0.00281905 l
+0.108754 0.893897 0.119458 0.891119 0 0 0 0.00281905 l
+0.108754 0.893897 0.103457 0.893661 0 0 0 0.00281905 l
+-0.60919 -0.20581 -0.609664 -0.221576 0 0 0 0.00281905 l
+-0.60919 -0.20581 -0.598868 -0.205143 0 0 0 0.00281905 l
+-0.60919 -0.20581 -0.609774 -0.20354 0 0 0 0.00281905 l
+0.742532 0.360178 0.738796 0.35516 0 0 0 0.00281905 l
+0.742532 0.360178 0.736073 0.362641 0 0 0 0.00281905 l
+0.0228254 -0.297953 0.0179683 -0.281144 0 0 0 0.00281905 l
+0.0228254 -0.297953 0.0287414 -0.306426 0 0 0 0.00281905 l
+0.669386 -0.362048 0.688782 -0.366273 0 0 0 0.00281905 l
+0.669386 -0.362048 0.661024 -0.37872 0 0 0 0.00281905 l
+-0.492222 -0.794062 -0.499013 -0.778098 0 0 0 0.00281905 l
+-0.492222 -0.794062 -0.488352 -0.79521 0 0 0 0.00281905 l
+-0.0741716 0.671743 -0.0829132 0.657181 0 0 0 0.00281905 l
+-0.0741716 0.671743 -0.0690447 0.67493 0 0 0 0.00281905 l
+0.929268 -0.308711 0.927389 -0.319183 0 0 0 0.00281905 l
+0.929268 -0.308711 0.942127 -0.306879 0 0 0 0.00281905 l
+-0.136718 -0.770993 -0.13529 -0.76517 0 0 0 0.00281905 l
+-0.136718 -0.770993 -0.118986 -0.782435 0 0 0 0.00281905 l
+0.578102 0.164425 0.586557 0.16771 0 0 0 0.00281905 l
+0.578102 0.164425 0.572665 0.169357 0 0 0 0.00281905 l
+0.125166 0.100854 0.132412 0.0884444 0 0 0 0.00281905 l
+-0.617366 -0.664786 -0.617435 -0.671242 0 0 0 0.00281905 l
+-0.617366 -0.664786 -0.630639 -0.655819 0 0 0 0.00281905 l
+-0.254928 0.0524395 -0.254695 0.0358275 0 0 0 0.00281905 l
+-0.254928 0.0524395 -0.244247 0.0569093 0 0 0 0.00281905 l
+-0.44396 -0.339364 -0.432701 -0.340521 0 0 0 0.00281905 l
+-0.44396 -0.339364 -0.452768 -0.330229 0 0 0 0.00281905 l
+0.874866 -0.461953 0.852606 -0.464844 0 0 0 0.00281905 l
+0.509774 -0.51912 0.506083 -0.530574 0 0 0 0.00281905 l
+0.509774 -0.51912 0.507275 -0.516024 0 0 0 0.00281905 l
+0.0446075 0.132718 0.0582615 0.131091 0 0 0 0.00281905 l
+0.0446075 0.132718 0.0367698 0.12497 0 0 0 0.00281905 l
+0.0446075 0.132718 0.0388176 0.13814 0 0 0 0.00281905 l
+-0.782909 -0.080582 -0.775189 -0.0704009 0 0 0 0.00281905 l
+-0.782909 -0.080582 -0.779969 -0.0900206 0 0 0 0.00281905 l
+-0.00415519 0.155145 -0.00196712 0.167491 0 0 0 0.00281905 l
+-0.00415519 0.155145 -0.0143234 0.159135 0 0 0 0.00281905 l
+-0.0731474 0.279377 -0.0723769 0.270172 0 0 0 0.00281905 l
+-0.619943 0.255085 -0.613453 0.263967 0 0 0 0.00281905 l
+-0.619943 0.255085 -0.628212 0.25628 0 0 0 0.00281905 l
+-0.54619 -0.225688 -0.55041 -0.218037 0 0 0 0.00281905 l
+-0.54619 -0.225688 -0.555016 -0.230787 0 0 0 0.00281905 l
+0.768188 -0.132357 0.77191 -0.132156 0 0 0 0.00281905 l
+0.768188 -0.132357 0.761281 -0.128158 0 0 0 0.00281905 l
+0.625303 0.459165 0.616921 0.471377 0 0 0 0.00281905 l
+0.625303 0.459165 0.617671 0.455948 0 0 0 0.00281905 l
+-0.316057 -0.198608 -0.318006 -0.187835 0 0 0 0.00281905 l
+-0.316057 -0.198608 -0.325484 -0.202778 0 0 0 0.00281905 l
+0.545467 0.0352446 0.542777 0.0454417 0 0 0 0.00281905 l
+0.545467 0.0352446 0.549025 0.0298082 0 0 0 0.00281905 l
+0.326261 0.444142 0.332855 0.435582 0 0 0 0.00281905 l
+-0.00196712 0.167491 -0.00415519 0.155145 0 0 0 0.00281905 l
+-0.00196712 0.167491 0.00123777 0.178034 0 0 0 0.00281905 l
+0.796357 -0.554484 0.80417 -0.561251 0 0 0 0.00281905 l
+0.796357 -0.554484 0.781183 -0.554729 0 0 0 0.00281905 l
+-0.133801 -0.401873 -0.120046 -0.407505 0 0 0 0.00281905 l
+-0.133801 -0.401873 -0.132943 -0.416401 0 0 0 0.00281905 l
+-0.133801 -0.401873 -0.13438 -0.40042 0 0 0 0.00281905 l
+0.377996 -0.232162 0.389143 -0.231633 0 0 0 0.00281905 l
+0.377996 -0.232162 0.367788 -0.2251 0 0 0 0.00281905 l
+0.38508 0.793964 0.387968 0.79142 0 0 0 0.00281905 l
+0.42681 0.0172097 0.439386 0.0171061 0 0 0 0.00281905 l
+0.42681 0.0172097 0.414858 0.0119261 0 0 0 0.00281905 l
+0.0235847 -0.506653 0.0267073 -0.50005 0 0 0 0.00281905 l
+0.0235847 -0.506653 0.0174979 -0.503064 0 0 0 0.00281905 l
+-0.315402 0.138071 -0.304484 0.138749 0 0 0 0.00281905 l
+-0.315402 0.138071 -0.320403 0.137847 0 0 0 0.00281905 l
+0.667325 -0.149863 0.683385 -0.145998 0 0 0 0.00281905 l
+0.667325 -0.149863 0.67232 -0.159013 0 0 0 0.00281905 l
+0.667325 -0.149863 0.658089 -0.153546 0 0 0 0.00281905 l
+-0.187927 0.412044 -0.192347 0.401921 0 0 0 0.00281905 l
+0.122061 -0.555125 0.135229 -0.546584 0 0 0 0.00281905 l
+0.122061 -0.555125 0.109443 -0.556131 0 0 0 0.00281905 l
+-0.131094 0.354752 -0.132032 0.336291 0 0 0 0.00281905 l
+-0.131094 0.354752 -0.135829 0.363844 0 0 0 0.00281905 l
+0.498734 0.820436 0.506839 0.811955 0 0 0 0.00281905 l
+0.498734 0.820436 0.495596 0.821524 0 0 0 0.00281905 l
+0.863974 -0.278111 0.871261 -0.26879 0 0 0 0.00281905 l
+0.863974 -0.278111 0.865791 -0.281962 0 0 0 0.00281905 l
+0.863974 -0.278111 0.851409 -0.275331 0 0 0 0.00281905 l
+-0.229752 -0.20308 -0.230188 -0.20267 0 0 0 0.00281905 l
+-0.4471 -0.582873 -0.43689 -0.574383 0 0 0 0.00281905 l
+-0.4471 -0.582873 -0.460558 -0.58352 0 0 0 0.00281905 l
+0.42352 -0.850881 0.421186 -0.860267 0 0 0 0.00281905 l
+0.835077 0.191053 0.831534 0.197148 0 0 0 0.00281905 l
+0.835077 0.191053 0.847175 0.184648 0 0 0 0.00281905 l
+-0.342445 0.830651 -0.340744 0.815323 0 0 0 0.00281905 l
+-0.342445 0.830651 -0.341747 0.842408 0 0 0 0.00281905 l
+-0.36336 0.330211 -0.357973 0.326126 0 0 0 0.00281905 l
+-0.644258 0.547697 -0.641361 0.541519 0 0 0 0.00281905 l
+-0.254211 -0.0859868 -0.26311 -0.096409 0 0 0 0.00281905 l
+0.767893 0.161121 0.758726 0.172771 0 0 0 0.00281905 l
+0.767893 0.161121 0.759219 0.150893 0 0 0 0.00281905 l
+0.640516 0.097134 0.625174 0.105729 0 0 0 0.00281905 l
+0.640516 0.097134 0.633789 0.0880051 0 0 0 0.00281905 l
+0.868321 -0.31925 0.869555 -0.323532 0 0 0 0.00281905 l
+0.159696 -0.55807 0.16352 -0.545326 0 0 0 0.00281905 l
+0.159696 -0.55807 0.177555 -0.566859 0 0 0 0.00281905 l
+0.0336413 -0.0423153 0.0317402 -0.0563828 0 0 0 0.00281905 l
+0.364991 -0.71375 0.364127 -0.704402 0 0 0 0.00281905 l
+0.364991 -0.71375 0.382146 -0.72275 0 0 0 0.00281905 l
+0.364991 -0.71375 0.350886 -0.72482 0 0 0 0.00281905 l
+-0.13221 -0.862471 -0.13531 -0.857802 0 0 0 0.00281905 l
+-0.118055 0.661446 -0.101224 0.65704 0 0 0 0.00281905 l
+-0.118055 0.661446 -0.127234 0.656106 0 0 0 0.00281905 l
+0.607206 -0.705842 0.607404 -0.69953 0 0 0 0.00281905 l
+0.607206 -0.705842 0.619001 -0.719551 0 0 0 0.00281905 l
+-0.805019 0.591439 -0.796564 0.596856 0 0 0 0.00281905 l
+-0.805019 0.591439 -0.815075 0.573991 0 0 0 0.00281905 l
+0.116452 0.0746246 0.110461 0.0574462 0 0 0 0.00281905 l
+0.116452 0.0746246 0.106575 0.0811952 0 0 0 0.00281905 l
+-0.37384 0.846568 -0.366863 0.839735 0 0 0 0.00281905 l
+-0.37384 0.846568 -0.368235 0.851479 0 0 0 0.00281905 l
+-0.37384 0.846568 -0.384663 0.850313 0 0 0 0.00281905 l
+-0.221782 0.417106 -0.233554 0.427082 0 0 0 0.00281905 l
+-0.221782 0.417106 -0.213637 0.423911 0 0 0 0.00281905 l
+-0.221782 0.417106 -0.222548 0.413959 0 0 0 0.00281905 l
+-0.166993 0.930697 -0.152207 0.933929 0 0 0 0.00281905 l
+-0.286551 -0.635721 -0.27923 -0.630758 0 0 0 0.00281905 l
+-0.286551 -0.635721 -0.28835 -0.634423 0 0 0 0.00281905 l
+0.596827 0.376222 0.594298 0.389865 0 0 0 0.00281905 l
+0.596827 0.376222 0.598735 0.366225 0 0 0 0.00281905 l
+-0.260987 -0.69546 -0.249368 -0.685586 0 0 0 0.00281905 l
+-0.260987 -0.69546 -0.255663 -0.702719 0 0 0 0.00281905 l
+-0.608841 -0.272386 -0.602143 -0.261087 0 0 0 0.00281905 l
+-0.608841 -0.272386 -0.629968 -0.272836 0 0 0 0.00281905 l
+-0.611407 -0.685756 -0.617435 -0.671242 0 0 0 0.00281905 l
+0.117494 -0.823148 0.126259 -0.808334 0 0 0 0.00281905 l
+0.117494 -0.823148 0.128471 -0.829294 0 0 0 0.00281905 l
+0.117494 -0.823148 0.111144 -0.826232 0 0 0 0.00281905 l
+0.799716 -0.165844 0.804297 -0.179079 0 0 0 0.00281905 l
+0.799716 -0.165844 0.780185 -0.161666 0 0 0 0.00281905 l
+-0.493528 -0.187068 -0.497017 -0.165525 0 0 0 0.00281905 l
+-0.493528 -0.187068 -0.495271 -0.191435 0 0 0 0.00281905 l
+0.00188986 0.00745381 0.0101976 0.00126571 0 0 0 0.00281905 l
+0.378807 -0.285628 0.379369 -0.282828 0 0 0 0.00281905 l
+0.378807 -0.285628 0.368044 -0.286922 0 0 0 0.00281905 l
+0.512527 -0.365928 0.5205 -0.364902 0 0 0 0.00281905 l
+0.512527 -0.365928 0.508496 -0.366462 0 0 0 0.00281905 l
+0.0621519 -0.475619 0.0728685 -0.484108 0 0 0 0.00281905 l
+0.0621519 -0.475619 0.0542115 -0.471754 0 0 0 0.00281905 l
+0.31941 0.185827 0.318511 0.177408 0 0 0 0.00281905 l
+0.31941 0.185827 0.311709 0.191077 0 0 0 0.00281905 l
+0.964439 -0.148796 0.967438 -0.147442 0 0 0 0.00281905 l
+-0.455299 0.30308 -0.466107 0.290364 0 0 0 0.00281905 l
+-0.455299 0.30308 -0.451442 0.303744 0 0 0 0.00281905 l
+-0.455299 0.30308 -0.461762 0.313181 0 0 0 0.00281905 l
+0.852208 -0.340956 0.847489 -0.338987 0 0 0 0.00281905 l
+-0.446467 0.775199 -0.444692 0.772597 0 0 0 0.00281905 l
+-0.446467 0.775199 -0.449923 0.784659 0 0 0 0.00281905 l
+0.882633 0.424663 0.884383 0.403111 0 0 0 0.00281905 l
+0.882633 0.424663 0.880405 0.428363 0 0 0 0.00281905 l
+-0.461259 0.730063 -0.462341 0.715359 0 0 0 0.00281905 l
+-0.461259 0.730063 -0.475281 0.73422 0 0 0 0.00281905 l
+-0.862557 -0.0639363 -0.866853 -0.0413217 0 0 0 0.00281905 l
+-0.862557 -0.0639363 -0.860771 -0.0720439 0 0 0 0.00281905 l
+-0.862557 -0.0639363 -0.870039 -0.0646064 0 0 0 0.00281905 l
+-0.213114 -0.472536 -0.203807 -0.482528 0 0 0 0.00281905 l
+-0.213114 -0.472536 -0.225697 -0.487049 0 0 0 0.00281905 l
+-0.0679275 0.8526 -0.0559224 0.845203 0 0 0 0.00281905 l
+-0.0679275 0.8526 -0.0790234 0.843557 0 0 0 0.00281905 l
+0.870001 0.200194 0.883525 0.19432 0 0 0 0.00281905 l
+0.870001 0.200194 0.86453 0.184655 0 0 0 0.00281905 l
+0.870001 0.200194 0.864147 0.205444 0 0 0 0.00281905 l
+0.265032 0.45553 0.255432 0.472909 0 0 0 0.00281905 l
+0.265032 0.45553 0.269152 0.452817 0 0 0 0.00281905 l
+0.411369 0.475968 0.42261 0.485865 0 0 0 0.00281905 l
+0.411369 0.475968 0.407554 0.469572 0 0 0 0.00281905 l
+0.0102051 -0.700197 0.00751042 -0.700447 0 0 0 0.00281905 l
+0.0102051 -0.700197 0.010459 -0.699725 0 0 0 0.00281905 l
+0.669142 0.437545 0.683102 0.445595 0 0 0 0.00281905 l
+0.669142 0.437545 0.649749 0.42228 0 0 0 0.00281905 l
+0.594688 0.364191 0.598735 0.366225 0 0 0 0.00281905 l
+0.594688 0.364191 0.583369 0.371326 0 0 0 0.00281905 l
+0.33925 -0.00113459 0.342111 -0.0174184 0 0 0 0.00281905 l
+0.33925 -0.00113459 0.336725 0.0034775 0 0 0 0.00281905 l
+0.329852 0.834859 0.323835 0.84685 0 0 0 0.00281905 l
+0.329852 0.834859 0.331199 0.831583 0 0 0 0.00281905 l
+0.265768 -0.703515 0.264682 -0.704197 0 0 0 0.00281905 l
+-0.238091 0.0127339 -0.239024 0.00976958 0 0 0 0.00281905 l
+0.353625 0.375267 0.353408 0.370553 0 0 0 0.00281905 l
+-0.224241 0.12919 -0.219317 0.139526 0 0 0 0.00281905 l
+-0.224241 0.12919 -0.222462 0.123687 0 0 0 0.00281905 l
+-0.224241 0.12919 -0.232072 0.136271 0 0 0 0.00281905 l
+-0.186853 0.38126 -0.189287 0.381563 0 0 0 0.00281905 l
+-0.751952 -0.07178 -0.743718 -0.0579772 0 0 0 0.00281905 l
+-0.751952 -0.07178 -0.765284 -0.0678209 0 0 0 0.00281905 l
+0.826186 -0.142027 0.832199 -0.134654 0 0 0 0.00281905 l
+0.826186 -0.142027 0.811208 -0.132283 0 0 0 0.00281905 l
+0.965567 -0.0267364 0.963257 -0.0330784 0 0 0 0.00281905 l
+0.965567 -0.0267364 0.970852 -0.0230126 0 0 0 0.00281905 l
+0.965567 -0.0267364 0.960453 -0.025314 0 0 0 0.00281905 l
+0.128624 -0.167753 0.130396 -0.175823 0 0 0 0.00281905 l
+0.128624 -0.167753 0.118378 -0.167354 0 0 0 0.00281905 l
+-0.0361393 -0.622353 -0.0318264 -0.620569 0 0 0 0.00281905 l
+-0.0361393 -0.622353 -0.043886 -0.625989 0 0 0 0.00281905 l
+-0.1561 0.746205 -0.153893 0.764626 0 0 0 0.00281905 l
+-0.1561 0.746205 -0.147292 0.746347 0 0 0 0.00281905 l
+-0.1561 0.746205 -0.167364 0.735449 0 0 0 0.00281905 l
+-0.678767 0.602167 -0.694814 0.614002 0 0 0 0.00281905 l
+-0.678767 0.602167 -0.682015 0.596803 0 0 0 0.00281905 l
+0.199872 -0.13929 0.204457 -0.125821 0 0 0 0.00281905 l
+0.199872 -0.13929 0.191437 -0.152231 0 0 0 0.00281905 l
+-0.648726 0.709793 -0.64946 0.70493 0 0 0 0.00281905 l
+-0.648726 0.709793 -0.647439 0.713238 0 0 0 0.00281905 l
+-0.648726 0.709793 -0.649427 0.709868 0 0 0 0.00281905 l
+-0.161152 -0.263029 -0.168794 -0.259154 0 0 0 0.00281905 l
+0.975726 -0.180076 0.968601 -0.194581 0 0 0 0.00281905 l
+0.975726 -0.180076 0.983031 -0.173375 0 0 0 0.00281905 l
+0.600298 -0.798479 0.595613 -0.793738 0 0 0 0.00281905 l
+0.174312 0.278757 0.182396 0.261844 0 0 0 0.00281905 l
+0.174312 0.278757 0.164095 0.284327 0 0 0 0.00281905 l
+0.233387 -0.133339 0.224296 -0.121657 0 0 0 0.00281905 l
+-0.0678142 0.750581 -0.0615094 0.746148 0 0 0 0.00281905 l
+0.598111 0.0639224 0.603143 0.0773387 0 0 0 0.00281905 l
+0.598111 0.0639224 0.590183 0.0540321 0 0 0 0.00281905 l
+0.598111 0.0639224 0.589856 0.0697154 0 0 0 0.00281905 l
+0.586064 -0.478355 0.579438 -0.464655 0 0 0 0.00281905 l
+0.586064 -0.478355 0.594812 -0.481815 0 0 0 0.00281905 l
+0.586064 -0.478355 0.581845 -0.492748 0 0 0 0.00281905 l
+0.435246 -0.206102 0.443371 -0.198483 0 0 0 0.00281905 l
+0.435246 -0.206102 0.441034 -0.210783 0 0 0 0.00281905 l
+0.435246 -0.206102 0.428281 -0.207101 0 0 0 0.00281905 l
+0.260702 0.038137 0.256342 0.0400094 0 0 0 0.00281905 l
+0.2515 0.122243 0.246628 0.132946 0 0 0 0.00281905 l
+0.2515 0.122243 0.25505 0.119646 0 0 0 0.00281905 l
+0.745256 -0.317816 0.75613 -0.306594 0 0 0 0.00281905 l
+0.745256 -0.317816 0.733725 -0.332131 0 0 0 0.00281905 l
+0.862521 0.176256 0.86453 0.184655 0 0 0 0.00281905 l
+0.862521 0.176256 0.868657 0.168724 0 0 0 0.00281905 l
+0.862521 0.176256 0.847103 0.181788 0 0 0 0.00281905 l
+-0.655043 0.392471 -0.655543 0.399722 0 0 0 0.00281905 l
+-0.655043 0.392471 -0.66817 0.384922 0 0 0 0.00281905 l
+0.0797773 -0.354531 0.0806951 -0.366446 0 0 0 0.00281905 l
+0.0797773 -0.354531 0.0672503 -0.352912 0 0 0 0.00281905 l
+0.239759 -0.370918 0.245764 -0.376485 0 0 0 0.00281905 l
+0.238042 -0.17405 0.228827 -0.163963 0 0 0 0.00281905 l
+0.238042 -0.17405 0.251298 -0.168779 0 0 0 0.00281905 l
+0.508209 -0.21846 0.507831 -0.22673 0 0 0 0.00281905 l
+-0.439242 0.433102 -0.43382 0.433634 0 0 0 0.00281905 l
+-0.439242 0.433102 -0.441045 0.43497 0 0 0 0.00281905 l
+-0.518386 0.557415 -0.513452 0.56729 0 0 0 0.00281905 l
+-0.518386 0.557415 -0.524048 0.551139 0 0 0 0.00281905 l
+-0.0857198 0.844553 -0.0790234 0.843557 0 0 0 0.00281905 l
+-0.0857198 0.844553 -0.0949189 0.845798 0 0 0 0.00281905 l
+0.19215 -0.624236 0.203573 -0.625541 0 0 0 0.00281905 l
+0.19215 -0.624236 0.17954 -0.62451 0 0 0 0.00281905 l
+0.398782 -0.827548 0.401774 -0.848925 0 0 0 0.00281905 l
+0.398782 -0.827548 0.399508 -0.825068 0 0 0 0.00281905 l
+0.0839942 -0.464459 0.0940376 -0.460759 0 0 0 0.00281905 l
+0.888296 -0.291867 0.891289 -0.272927 0 0 0 0.00281905 l
+0.888296 -0.291867 0.880817 -0.303731 0 0 0 0.00281905 l
+0.888296 -0.291867 0.875642 -0.290297 0 0 0 0.00281905 l
+-0.729835 -0.384569 -0.729001 -0.395676 0 0 0 0.00281905 l
+-0.729835 -0.384569 -0.726036 -0.378856 0 0 0 0.00281905 l
+-0.729835 -0.384569 -0.746552 -0.389846 0 0 0 0.00281905 l
+-0.736078 -0.253197 -0.740878 -0.263081 0 0 0 0.00281905 l
+-0.736078 -0.253197 -0.727921 -0.250241 0 0 0 0.00281905 l
+-0.736078 -0.253197 -0.749238 -0.240866 0 0 0 0.00281905 l
+-0.283034 -0.707572 -0.274911 -0.697169 0 0 0 0.00281905 l
+-0.283034 -0.707572 -0.272551 -0.714139 0 0 0 0.00281905 l
+-0.725072 -0.372498 -0.726036 -0.378856 0 0 0 0.00281905 l
+0.272432 -0.434303 0.266514 -0.419193 0 0 0 0.00281905 l
+0.272432 -0.434303 0.268725 -0.438228 0 0 0 0.00281905 l
+-0.158768 -0.177634 -0.151316 -0.185469 0 0 0 0.00281905 l
+-0.158768 -0.177634 -0.157328 -0.171435 0 0 0 0.00281905 l
+0.33267 0.610885 0.330746 0.623265 0 0 0 0.00281905 l
+0.33267 0.610885 0.325077 0.601217 0 0 0 0.00281905 l
+-0.17249 0.0762203 -0.174727 0.0604758 0 0 0 0.00281905 l
+-0.17249 0.0762203 -0.163432 0.0955439 0 0 0 0.00281905 l
+0.263962 0.562144 0.272089 0.567396 0 0 0 0.00281905 l
+0.263962 0.562144 0.253982 0.552197 0 0 0 0.00281905 l
+0.820714 0.0301043 0.821282 0.032771 0 0 0 0.00281905 l
+-0.0477335 0.162449 -0.0523878 0.175596 0 0 0 0.00281905 l
+-0.0477335 0.162449 -0.0520973 0.153967 0 0 0 0.00281905 l
+0.718854 0.629992 0.728006 0.637086 0 0 0 0.00281905 l
+0.718854 0.629992 0.720558 0.627243 0 0 0 0.00281905 l
+0.718854 0.629992 0.711571 0.627407 0 0 0 0.00281905 l
+-0.366588 -0.38263 -0.372475 -0.386635 0 0 0 0.00281905 l
+-0.691406 -0.464207 -0.675656 -0.458076 0 0 0 0.00281905 l
+-0.691406 -0.464207 -0.700484 -0.477794 0 0 0 0.00281905 l
+-0.17127 -0.560295 -0.158568 -0.553845 0 0 0 0.00281905 l
+-0.17127 -0.560295 -0.183174 -0.561218 0 0 0 0.00281905 l
+-0.106248 -0.753759 -0.11117 -0.748369 0 0 0 0.00281905 l
+-0.877473 0.0176556 -0.873877 0.0116112 0 0 0 0.00281905 l
+-0.877473 0.0176556 -0.870067 0.0179736 0 0 0 0.00281905 l
+-0.877473 0.0176556 -0.885207 0.00988652 0 0 0 0.00281905 l
+0.73303 -0.235769 0.731806 -0.225457 0 0 0 0.00281905 l
+0.73303 -0.235769 0.743399 -0.237981 0 0 0 0.00281905 l
+-0.84913 -0.236143 -0.852891 -0.229667 0 0 0 0.00281905 l
+0.00813491 0.361179 0.00353118 0.370945 0 0 0 0.00281905 l
+0.00813491 0.361179 0.00513286 0.351256 0 0 0 0.00281905 l
+0.696672 0.0964095 0.707249 0.0971727 0 0 0 0.00281905 l
+0.520466 0.671158 0.512034 0.652995 0 0 0 0.00281905 l
+0.520466 0.671158 0.5287 0.670301 0 0 0 0.00281905 l
+-0.669978 -0.242851 -0.670948 -0.235338 0 0 0 0.00281905 l
+-0.669978 -0.242851 -0.656344 -0.248712 0 0 0 0.00281905 l
+-0.669978 -0.242851 -0.679056 -0.249337 0 0 0 0.00281905 l
+-0.55741 0.0834508 -0.549839 0.0794188 0 0 0 0.00281905 l
+-0.55741 0.0834508 -0.547057 0.0947999 0 0 0 0.00281905 l
+-0.55741 0.0834508 -0.568053 0.080883 0 0 0 0.00281905 l
+0.364666 0.737853 0.375685 0.738945 0 0 0 0.00281905 l
+0.364666 0.737853 0.353574 0.725216 0 0 0 0.00281905 l
+-0.656992 -0.619102 -0.6645 -0.606877 0 0 0 0.00281905 l
+-0.656992 -0.619102 -0.642762 -0.613321 0 0 0 0.00281905 l
+-0.656992 -0.619102 -0.665185 -0.626528 0 0 0 0.00281905 l
+0.214433 -0.348314 0.211175 -0.363979 0 0 0 0.00281905 l
+-0.715607 -0.548499 -0.697266 -0.559353 0 0 0 0.00281905 l
+-0.715607 -0.548499 -0.724206 -0.543572 0 0 0 0.00281905 l
+0.579909 0.534159 0.582084 0.514468 0 0 0 0.00281905 l
+0.579909 0.534159 0.577597 0.545435 0 0 0 0.00281905 l
+0.579909 0.534159 0.562304 0.531496 0 0 0 0.00281905 l
+0.193553 0.816553 0.189765 0.832063 0 0 0 0.00281905 l
+0.193553 0.816553 0.203336 0.811808 0 0 0 0.00281905 l
+-0.523328 0.440596 -0.523933 0.441905 0 0 0 0.00281905 l
+-0.156945 0.61109 -0.151023 0.601076 0 0 0 0.00281905 l
+-0.156945 0.61109 -0.145546 0.615631 0 0 0 0.00281905 l
+-0.156945 0.61109 -0.170648 0.606351 0 0 0 0.00281905 l
+-0.156945 0.61109 -0.162114 0.618215 0 0 0 0.00281905 l
+0.701249 0.243894 0.699447 0.239532 0 0 0 0.00281905 l
+-0.0922459 0.743857 -0.0833289 0.733969 0 0 0 0.00281905 l
+-0.0922459 0.743857 -0.10658 0.727076 0 0 0 0.00281905 l
+-0.263914 -0.169389 -0.25786 -0.16767 0 0 0 0.00281905 l
+-0.263914 -0.169389 -0.271373 -0.178864 0 0 0 0.00281905 l
+0.398113 -0.00919072 0.407521 -0.00899539 0 0 0 0.00281905 l
+0.398113 -0.00919072 0.395549 -0.0177963 0 0 0 0.00281905 l
+0.398113 -0.00919072 0.393669 0.000324163 0 0 0 0.00281905 l
+-0.11197 0.977427 -0.116396 0.989493 0 0 0 0.00281905 l
+-0.11197 0.977427 -0.108798 0.972631 0 0 0 0.00281905 l
+-0.11197 0.977427 -0.126505 0.974443 0 0 0 0.00281905 l
+0.391223 0.493045 0.409578 0.492415 0 0 0 0.00281905 l
+0.391223 0.493045 0.388542 0.496189 0 0 0 0.00281905 l
+0.489694 0.149198 0.505343 0.160212 0 0 0 0.00281905 l
+0.489694 0.149198 0.487863 0.142843 0 0 0 0.00281905 l
+-0.312223 -0.263176 -0.305185 -0.257339 0 0 0 0.00281905 l
+-0.312223 -0.263176 -0.319103 -0.266325 0 0 0 0.00281905 l
+0.210072 -0.0281794 0.218065 -0.0268488 0 0 0 0.00281905 l
+0.210072 -0.0281794 0.207678 -0.0377392 0 0 0 0.00281905 l
+0.274748 0.21694 0.28329 0.214294 0 0 0 0.00281905 l
+0.276765 -0.525652 0.271985 -0.519882 0 0 0 0.00281905 l
+0.276765 -0.525652 0.285435 -0.523733 0 0 0 0.00281905 l
+0.43693 0.0690557 0.439904 0.0649067 0 0 0 0.00281905 l
+-0.642105 -0.32284 -0.63071 -0.338245 0 0 0 0.00281905 l
+-0.642105 -0.32284 -0.645003 -0.304041 0 0 0 0.00281905 l
+0.187726 -0.886056 0.176807 -0.887129 0 0 0 0.00281905 l
+-0.359981 0.0187121 -0.358574 0.00853546 0 0 0 0.00281905 l
+-0.359981 0.0187121 -0.343959 0.0238525 0 0 0 0.00281905 l
+-0.359981 0.0187121 -0.364941 0.0176626 0 0 0 0.00281905 l
+0.114419 -0.114658 0.109799 -0.12575 0 0 0 0.00281905 l
+0.114419 -0.114658 0.123972 -0.107649 0 0 0 0.00281905 l
+-0.817462 -0.0125251 -0.813494 0.00301869 0 0 0 0.00281905 l
+-0.817462 -0.0125251 -0.809724 -0.0157454 0 0 0 0.00281905 l
+-0.35107 -0.530781 -0.363046 -0.531368 0 0 0 0.00281905 l
+0.206244 -0.922395 0.203748 -0.908961 0 0 0 0.00281905 l
+0.206244 -0.922395 0.188663 -0.932984 0 0 0 0.00281905 l
+0.00720694 0.306965 0.0113582 0.305589 0 0 0 0.00281905 l
+0.767676 -0.0484075 0.780563 -0.0384472 0 0 0 0.00281905 l
+0.767676 -0.0484075 0.77692 -0.0577995 0 0 0 0.00281905 l
+0.767676 -0.0484075 0.762023 -0.0387265 0 0 0 0.00281905 l
+-0.154413 0.196856 -0.157788 0.217132 0 0 0 0.00281905 l
+-0.154413 0.196856 -0.159019 0.181149 0 0 0 0.00281905 l
+0.158317 0.335432 0.159206 0.337621 0 0 0 0.00281905 l
+0.776208 0.11978 0.782655 0.121474 0 0 0 0.00281905 l
+-0.0825705 -0.405971 -0.0814608 -0.387172 0 0 0 0.00281905 l
+-0.0825705 -0.405971 -0.0725211 -0.408445 0 0 0 0.00281905 l
+-0.0825705 -0.405971 -0.101609 -0.399938 0 0 0 0.00281905 l
+-0.243828 -0.867488 -0.24481 -0.868924 0 0 0 0.00281905 l
+-0.539955 -0.35176 -0.524486 -0.348605 0 0 0 0.00281905 l
+-0.539955 -0.35176 -0.548852 -0.365921 0 0 0 0.00281905 l
+0.576806 0.26792 0.582016 0.251835 0 0 0 0.00281905 l
+0.576806 0.26792 0.588116 0.27078 0 0 0 0.00281905 l
+0.576806 0.26792 0.565697 0.262735 0 0 0 0.00281905 l
+0.00238574 0.622497 0.002285 0.618907 0 0 0 0.00281905 l
+0.00238574 0.622497 0.00361648 0.625054 0 0 0 0.00281905 l
+-0.47902 0.375 -0.48173 0.380035 0 0 0 0.00281905 l
+0.108528 0.135144 0.11545 0.131758 0 0 0 0.00281905 l
+0.108528 0.135144 0.104848 0.12868 0 0 0 0.00281905 l
+-0.700869 0.222902 -0.700949 0.225961 0 0 0 0.00281905 l
+-0.700869 0.222902 -0.699777 0.221204 0 0 0 0.00281905 l
+-0.672776 -0.311725 -0.673513 -0.320466 0 0 0 0.00281905 l
+-0.672776 -0.311725 -0.662136 -0.30796 0 0 0 0.00281905 l
+-0.184492 -0.363678 -0.168884 -0.366913 0 0 0 0.00281905 l
+-0.184492 -0.363678 -0.2007 -0.366449 0 0 0 0.00281905 l
+0.324698 0.269985 0.332938 0.271198 0 0 0 0.00281905 l
+-0.590307 -0.232581 -0.570609 -0.22955 0 0 0 0.00281905 l
+-0.590307 -0.232581 -0.59182 -0.230628 0 0 0 0.00281905 l
+-0.83085 0.314394 -0.830142 0.318809 0 0 0 0.00281905 l
+-0.83085 0.314394 -0.842705 0.306046 0 0 0 0.00281905 l
+-0.0277842 -0.945789 -0.0252594 -0.931069 0 0 0 0.00281905 l
+-0.0277842 -0.945789 -0.0176257 -0.956622 0 0 0 0.00281905 l
+0.980731 -0.148243 0.983043 -0.154139 0 0 0 0.00281905 l
+0.980731 -0.148243 0.977248 -0.138146 0 0 0 0.00281905 l
+0.980731 -0.148243 0.972557 -0.152624 0 0 0 0.00281905 l
+0.739199 -0.628432 0.740426 -0.621538 0 0 0 0.00281905 l
+-0.0306977 0.445289 -0.0258673 0.442291 0 0 0 0.00281905 l
+-0.0306977 0.445289 -0.0327066 0.440303 0 0 0 0.00281905 l
+0.533971 0.0612763 0.542777 0.0454417 0 0 0 0.00281905 l
+0.533971 0.0612763 0.533554 0.0691592 0 0 0 0.00281905 l
+0.590761 -0.457211 0.611835 -0.452193 0 0 0 0.00281905 l
+0.590761 -0.457211 0.579438 -0.464655 0 0 0 0.00281905 l
+0.085039 -0.200681 0.0942822 -0.202988 0 0 0 0.00281905 l
+0.085039 -0.200681 0.0705764 -0.192373 0 0 0 0.00281905 l
+0.0581151 0.887564 0.0594682 0.87758 0 0 0 0.00281905 l
+0.0581151 0.887564 0.0443188 0.896231 0 0 0 0.00281905 l
+-0.0828964 -0.0128834 -0.0827732 -0.00881832 0 0 0 0.00281905 l
+-0.0828964 -0.0128834 -0.0659766 -0.0201552 0 0 0 0.00281905 l
+0.666732 -0.402769 0.667181 -0.392893 0 0 0 0.00281905 l
+0.666732 -0.402769 0.66384 -0.415708 0 0 0 0.00281905 l
+0.666732 -0.402769 0.65891 -0.400816 0 0 0 0.00281905 l
+-0.904238 0.351851 -0.887908 0.366458 0 0 0 0.00281905 l
+-0.904238 0.351851 -0.904586 0.342888 0 0 0 0.00281905 l
+-0.81286 0.0877904 -0.79091 0.0824744 0 0 0 0.00281905 l
+-0.81286 0.0877904 -0.81519 0.0800164 0 0 0 0.00281905 l
+-0.81286 0.0877904 -0.83303 0.0920831 0 0 0 0.00281905 l
+-0.854856 0.0282175 -0.85485 0.0176036 0 0 0 0.00281905 l
+-0.854856 0.0282175 -0.84571 0.0374958 0 0 0 0.00281905 l
+0.246645 0.960911 0.240585 0.944203 0 0 0 0.00281905 l
+-0.559607 0.383472 -0.55943 0.371135 0 0 0 0.00281905 l
+-0.559607 0.383472 -0.548876 0.390544 0 0 0 0.00281905 l
+-0.559607 0.383472 -0.570064 0.39051 0 0 0 0.00281905 l
+0.666919 0.491917 0.665372 0.489621 0 0 0 0.00281905 l
+0.270471 0.907649 0.283415 0.912594 0 0 0 0.00281905 l
+0.270471 0.907649 0.255989 0.912561 0 0 0 0.00281905 l
+0.503224 -0.559041 0.50567 -0.550386 0 0 0 0.00281905 l
+0.503224 -0.559041 0.512163 -0.562278 0 0 0 0.00281905 l
+0.503224 -0.559041 0.496868 -0.563139 0 0 0 0.00281905 l
+-0.441122 -0.0113368 -0.434056 -0.0143752 0 0 0 0.00281905 l
+-0.441122 -0.0113368 -0.442668 -0.00407661 0 0 0 0.00281905 l
+-0.286843 0.837955 -0.287862 0.826537 0 0 0 0.00281905 l
+-0.286843 0.837955 -0.282038 0.845353 0 0 0 0.00281905 l
+-0.467719 0.217923 -0.467981 0.228418 0 0 0 0.00281905 l
+-0.467719 0.217923 -0.466617 0.209667 0 0 0 0.00281905 l
+0.580405 -0.60875 0.578338 -0.610616 0 0 0 0.00281905 l
+0.233982 0.360308 0.234598 0.380948 0 0 0 0.00281905 l
+0.233982 0.360308 0.249742 0.35797 0 0 0 0.00281905 l
+0.837658 -0.506039 0.839425 -0.508671 0 0 0 0.00281905 l
+0.837658 -0.506039 0.834154 -0.509433 0 0 0 0.00281905 l
+0.88733 -0.0790919 0.899006 -0.0819796 0 0 0 0.00281905 l
+-0.493163 0.413011 -0.496301 0.392848 0 0 0 0.00281905 l
+-0.493163 0.413011 -0.478655 0.419513 0 0 0 0.00281905 l
+-0.493163 0.413011 -0.509504 0.412853 0 0 0 0.00281905 l
+0.372788 0.0385112 0.383687 0.0318404 0 0 0 0.00281905 l
+0.372788 0.0385112 0.366755 0.0550387 0 0 0 0.00281905 l
+0.761281 -0.128158 0.768188 -0.132357 0 0 0 0.00281905 l
+0.761281 -0.128158 0.755606 -0.140581 0 0 0 0.00281905 l
+-0.373365 -0.214269 -0.359283 -0.208361 0 0 0 0.00281905 l
+-0.373365 -0.214269 -0.38346 -0.215206 0 0 0 0.00281905 l
+-0.0256082 -0.206207 -0.0316595 -0.195496 0 0 0 0.00281905 l
+-0.0256082 -0.206207 -0.0154171 -0.212508 0 0 0 0.00281905 l
+-0.621846 -0.781936 -0.59739 -0.794854 0 0 0 0.00281905 l
+-0.112586 -0.469311 -0.111503 -0.453739 0 0 0 0.00281905 l
+-0.112586 -0.469311 -0.0964474 -0.478425 0 0 0 0.00281905 l
+-0.112586 -0.469311 -0.11775 -0.480488 0 0 0 0.00281905 l
+-0.484935 -0.495707 -0.479225 -0.514594 0 0 0 0.00281905 l
+-0.484935 -0.495707 -0.481029 -0.492327 0 0 0 0.00281905 l
+-0.484935 -0.495707 -0.50619 -0.50291 0 0 0 0.00281905 l
+0.180118 -0.256613 0.191317 -0.268373 0 0 0 0.00281905 l
+0.180118 -0.256613 0.160945 -0.261869 0 0 0 0.00281905 l
+0.180118 -0.256613 0.180554 -0.25523 0 0 0 0.00281905 l
+-0.462454 0.419633 -0.474916 0.410385 0 0 0 0.00281905 l
+-0.364179 -0.0114705 -0.360587 -0.00117533 0 0 0 0.00281905 l
+-0.364179 -0.0114705 -0.366591 -0.0177968 0 0 0 0.00281905 l
+-0.70566 0.634924 -0.695532 0.629578 0 0 0 0.00281905 l
+-0.70566 0.634924 -0.713042 0.637909 0 0 0 0.00281905 l
+0.754268 -0.437199 0.753811 -0.42026 0 0 0 0.00281905 l
+0.754268 -0.437199 0.752599 -0.460121 0 0 0 0.00281905 l
+-0.494762 0.453668 -0.488358 0.460001 0 0 0 0.00281905 l
+-0.494762 0.453668 -0.509305 0.452204 0 0 0 0.00281905 l
+0.420814 -0.730466 0.437093 -0.726236 0 0 0 0.00281905 l
+0.420814 -0.730466 0.411883 -0.742422 0 0 0 0.00281905 l
+-0.548027 -0.240373 -0.551642 -0.255386 0 0 0 0.00281905 l
+-0.548027 -0.240373 -0.545413 -0.238942 0 0 0 0.00281905 l
+-0.548027 -0.240373 -0.555016 -0.230787 0 0 0 0.00281905 l
+0.151382 0.336017 0.155286 0.33951 0 0 0 0.00281905 l
+0.151382 0.336017 0.137217 0.33264 0 0 0 0.00281905 l
+0.0688759 -0.246198 0.0643814 -0.23302 0 0 0 0.00281905 l
+-0.205614 -0.214678 -0.18747 -0.213936 0 0 0 0.00281905 l
+-0.205614 -0.214678 -0.203861 -0.222435 0 0 0 0.00281905 l
+-0.0543427 0.668241 -0.0487333 0.664967 0 0 0 0.00281905 l
+-0.0543427 0.668241 -0.0690447 0.67493 0 0 0 0.00281905 l
+-0.0708522 0.15141 -0.0520973 0.153967 0 0 0 0.00281905 l
+-0.0708522 0.15141 -0.0816385 0.155719 0 0 0 0.00281905 l
+0.524454 -0.321198 0.52704 -0.315989 0 0 0 0.00281905 l
+0.524454 -0.321198 0.534007 -0.329236 0 0 0 0.00281905 l
+0.524454 -0.321198 0.517652 -0.321857 0 0 0 0.00281905 l
+0.041732 0.536666 0.0471527 0.546501 0 0 0 0.00281905 l
+-0.416061 -0.257141 -0.409105 -0.262447 0 0 0 0.00281905 l
+-0.416061 -0.257141 -0.419727 -0.264939 0 0 0 0.00281905 l
+-0.416061 -0.257141 -0.416782 -0.255665 0 0 0 0.00281905 l
+-0.0998139 0.626165 -0.0965469 0.637028 0 0 0 0.00281905 l
+-0.0998139 0.626165 -0.107672 0.629454 0 0 0 0.00281905 l
+-0.734408 0.223123 -0.724351 0.23411 0 0 0 0.00281905 l
+0.0967169 -0.99261 0.107937 -0.992914 0 0 0 0.00281905 l
+0.0967169 -0.99261 0.0767172 -0.996356 0 0 0 0.00281905 l
+0.380761 -0.204267 0.383165 -0.187575 0 0 0 0.00281905 l
+0.380761 -0.204267 0.374484 -0.210449 0 0 0 0.00281905 l
+-0.363423 0.619505 -0.352482 0.62545 0 0 0 0.00281905 l
+-0.363423 0.619505 -0.371242 0.627117 0 0 0 0.00281905 l
+0.335355 -0.0717461 0.332563 -0.0834278 0 0 0 0.00281905 l
+0.335355 -0.0717461 0.342159 -0.0682193 0 0 0 0.00281905 l
+0.335355 -0.0717461 0.329383 -0.0691895 0 0 0 0.00281905 l
+-0.077995 -0.885597 -0.0810374 -0.872727 0 0 0 0.00281905 l
+-0.077995 -0.885597 -0.0769398 -0.892899 0 0 0 0.00281905 l
+0.864756 -0.202048 0.882604 -0.19464 0 0 0 0.00281905 l
+0.77191 -0.132156 0.772971 -0.142863 0 0 0 0.00281905 l
+0.77191 -0.132156 0.771589 -0.12776 0 0 0 0.00281905 l
+0.77191 -0.132156 0.792143 -0.131356 0 0 0 0.00281905 l
+0.77191 -0.132156 0.768188 -0.132357 0 0 0 0.00281905 l
+-0.206582 0.0330684 -0.210859 0.0489857 0 0 0 0.00281905 l
+-0.206582 0.0330684 -0.213146 0.0214237 0 0 0 0.00281905 l
+0.765512 0.356163 0.77071 0.363158 0 0 0 0.00281905 l
+0.674654 0.372148 0.679107 0.372247 0 0 0 0.00281905 l
+0.674654 0.372148 0.670885 0.366732 0 0 0 0.00281905 l
+-0.89761 0.20235 -0.896469 0.203037 0 0 0 0.00281905 l
+-0.89761 0.20235 -0.922577 0.193622 0 0 0 0.00281905 l
+-0.185542 0.734215 -0.179947 0.734331 0 0 0 0.00281905 l
+-0.185542 0.734215 -0.187573 0.735514 0 0 0 0.00281905 l
+-0.404371 -0.192489 -0.395043 -0.193564 0 0 0 0.00281905 l
+-0.404371 -0.192489 -0.426563 -0.191342 0 0 0 0.00281905 l
+0.0652994 -0.701298 0.0773221 -0.699957 0 0 0 0.00281905 l
+0.0652994 -0.701298 0.0500875 -0.702661 0 0 0 0.00281905 l
+0.550486 -0.0135731 0.550691 -0.00211002 0 0 0 0.00281905 l
+0.550486 -0.0135731 0.559005 -0.018311 0 0 0 0.00281905 l
+0.550486 -0.0135731 0.544303 -0.0265087 0 0 0 0.00281905 l
+-0.15911 0.56188 -0.159651 0.553139 0 0 0 0.00281905 l
+-0.15911 0.56188 -0.170797 0.565572 0 0 0 0.00281905 l
+0.593781 -0.791036 0.595613 -0.793738 0 0 0 0.00281905 l
+0.593781 -0.791036 0.589069 -0.785539 0 0 0 0.00281905 l
+-0.912446 0.321063 -0.912271 0.332264 0 0 0 0.00281905 l
+-0.912446 0.321063 -0.905136 0.320191 0 0 0 0.00281905 l
+-0.912446 0.321063 -0.923842 0.323723 0 0 0 0.00281905 l
+0.521828 -0.132636 0.532923 -0.139301 0 0 0 0.00281905 l
+0.521828 -0.132636 0.511709 -0.125709 0 0 0 0.00281905 l
+0.141777 -0.653059 0.148044 -0.633498 0 0 0 0.00281905 l
+0.141777 -0.653059 0.139044 -0.665521 0 0 0 0.00281905 l
+0.0377139 0.832649 0.0377893 0.841139 0 0 0 0.00281905 l
+0.0377139 0.832649 0.0406878 0.832308 0 0 0 0.00281905 l
+-0.0808913 0.0555962 -0.0760536 0.0594207 0 0 0 0.00281905 l
+-0.0808913 0.0555962 -0.0940309 0.0453731 0 0 0 0.00281905 l
+0.0893844 0.282907 0.083658 0.27673 0 0 0 0.00281905 l
+0.0893844 0.282907 0.0808742 0.28687 0 0 0 0.00281905 l
+0.792462 0.290358 0.801828 0.303314 0 0 0 0.00281905 l
+0.792462 0.290358 0.771345 0.28501 0 0 0 0.00281905 l
+-0.120046 -0.407505 -0.116002 -0.398511 0 0 0 0.00281905 l
+-0.120046 -0.407505 -0.114215 -0.414303 0 0 0 0.00281905 l
+-0.120046 -0.407505 -0.133801 -0.401873 0 0 0 0.00281905 l
+0.0942822 -0.202988 0.0878522 -0.219345 0 0 0 0.00281905 l
+0.0942822 -0.202988 0.106562 -0.192028 0 0 0 0.00281905 l
+0.0942822 -0.202988 0.085039 -0.200681 0 0 0 0.00281905 l
+0.161331 0.39989 0.165088 0.391175 0 0 0 0.00281905 l
+0.161331 0.39989 0.164349 0.40281 0 0 0 0.00281905 l
+0.161331 0.39989 0.150428 0.399639 0 0 0 0.00281905 l
+0.802743 -0.371897 0.796461 -0.389096 0 0 0 0.00281905 l
+0.802743 -0.371897 0.787593 -0.368328 0 0 0 0.00281905 l
+0.123578 0.67919 0.134017 0.679757 0 0 0 0.00281905 l
+0.123578 0.67919 0.115162 0.687891 0 0 0 0.00281905 l
+0.216334 -0.703435 0.20298 -0.694144 0 0 0 0.00281905 l
+0.216334 -0.703435 0.204618 -0.71277 0 0 0 0.00281905 l
+-0.0895299 -0.942053 -0.0918797 -0.950623 0 0 0 0.00281905 l
+-0.0895299 -0.942053 -0.0988007 -0.942085 0 0 0 0.00281905 l
+-0.635575 0.487345 -0.621642 0.482879 0 0 0 0.00281905 l
+-0.635575 0.487345 -0.625691 0.497352 0 0 0 0.00281905 l
+0.699667 0.313595 0.688901 0.311103 0 0 0 0.00281905 l
+-0.600449 0.108819 -0.599656 0.115798 0 0 0 0.00281905 l
+-0.600449 0.108819 -0.589359 0.101348 0 0 0 0.00281905 l
+-0.600449 0.108819 -0.602414 0.106747 0 0 0 0.00281905 l
+-0.620771 0.220791 -0.617051 0.228609 0 0 0 0.00281905 l
+-0.620771 0.220791 -0.626166 0.214998 0 0 0 0.00281905 l
+0.00823022 -0.827218 0.0289148 -0.822333 0 0 0 0.00281905 l
+0.00823022 -0.827218 0.000446392 -0.817143 0 0 0 0.00281905 l
+-0.736818 0.351592 -0.730169 0.353128 0 0 0 0.00281905 l
+-0.0362982 -0.389045 -0.0421471 -0.393905 0 0 0 0.00281905 l
+0.310131 -0.286867 0.31663 -0.302336 0 0 0 0.00281905 l
+0.310131 -0.286867 0.300079 -0.282404 0 0 0 0.00281905 l
+-0.345626 -0.514551 -0.35997 -0.519059 0 0 0 0.00281905 l
+-0.394707 -0.656155 -0.40063 -0.663096 0 0 0 0.00281905 l
+-0.277429 0.928931 -0.274967 0.939157 0 0 0 0.00281905 l
+-0.277429 0.928931 -0.274463 0.925292 0 0 0 0.00281905 l
+-0.0429912 0.68867 -0.0408841 0.675222 0 0 0 0.00281905 l
+-0.221858 -0.0282035 -0.216569 -0.0206235 0 0 0 0.00281905 l
+-0.106124 0.85749 -0.0949189 0.845798 0 0 0 0.00281905 l
+-0.106124 0.85749 -0.114744 0.850647 0 0 0 0.00281905 l
+0.403434 0.0139576 0.406847 0.0152008 0 0 0 0.00281905 l
+0.403434 0.0139576 0.397841 0.0114409 0 0 0 0.00281905 l
+0.407407 -0.351146 0.409129 -0.360644 0 0 0 0.00281905 l
+0.407407 -0.351146 0.408295 -0.343066 0 0 0 0.00281905 l
+-0.100826 -0.0681722 -0.108743 -0.0859735 0 0 0 0.00281905 l
+-0.100826 -0.0681722 -0.100481 -0.0527413 0 0 0 0.00281905 l
+-0.354364 -0.222368 -0.359283 -0.208361 0 0 0 0.00281905 l
+-0.354364 -0.222368 -0.360887 -0.228718 0 0 0 0.00281905 l
+-0.203807 -0.482528 -0.197982 -0.476263 0 0 0 0.00281905 l
+-0.203807 -0.482528 -0.213114 -0.472536 0 0 0 0.00281905 l
+0.162478 -0.81296 0.160606 -0.801183 0 0 0 0.00281905 l
+0.162478 -0.81296 0.179464 -0.808184 0 0 0 0.00281905 l
+0.162478 -0.81296 0.151267 -0.812703 0 0 0 0.00281905 l
+-0.238927 0.696177 -0.235365 0.682143 0 0 0 0.00281905 l
+-0.238927 0.696177 -0.241742 0.700025 0 0 0 0.00281905 l
+-0.412622 -0.00813736 -0.408294 -0.0114624 0 0 0 0.00281905 l
+-0.412622 -0.00813736 -0.425079 -0.00381754 0 0 0 0.00281905 l
+0.264493 0.713747 0.26467 0.719879 0 0 0 0.00281905 l
+0.264493 0.713747 0.269915 0.714823 0 0 0 0.00281905 l
+0.264493 0.713747 0.246504 0.704912 0 0 0 0.00281905 l
+-0.571728 -0.0169238 -0.571891 -0.00366643 0 0 0 0.00281905 l
+0.925247 0.260813 0.941022 0.271461 0 0 0 0.00281905 l
+0.925247 0.260813 0.917296 0.264257 0 0 0 0.00281905 l
+0.679186 0.698116 0.675671 0.709711 0 0 0 0.00281905 l
+0.679186 0.698116 0.672751 0.688111 0 0 0 0.00281905 l
+0.656409 0.157807 0.648666 0.15843 0 0 0 0.00281905 l
+0.65891 -0.400816 0.666732 -0.402769 0 0 0 0.00281905 l
+0.65891 -0.400816 0.648447 -0.39931 0 0 0 0.00281905 l
+-0.298834 -0.182428 -0.304515 -0.174461 0 0 0 0.00281905 l
+-0.298834 -0.182428 -0.304021 -0.184733 0 0 0 0.00281905 l
+-0.231363 -0.611435 -0.23025 -0.595513 0 0 0 0.00281905 l
+-0.231363 -0.611435 -0.211846 -0.616792 0 0 0 0.00281905 l
+-0.979359 -0.0342607 -0.963998 -0.0237917 0 0 0 0.00281905 l
+-0.391777 -0.781627 -0.396012 -0.796179 0 0 0 0.00281905 l
+-0.391777 -0.781627 -0.391825 -0.76384 0 0 0 0.00281905 l
+-0.391777 -0.781627 -0.384783 -0.78149 0 0 0 0.00281905 l
+0.324338 0.15285 0.313327 0.153464 0 0 0 0.00281905 l
+0.304932 -0.57325 0.306761 -0.587732 0 0 0 0.00281905 l
+0.720841 -0.206468 0.731806 -0.225457 0 0 0 0.00281905 l
+0.720841 -0.206468 0.71164 -0.198825 0 0 0 0.00281905 l
+-0.0563198 0.40555 -0.062805 0.414003 0 0 0 0.00281905 l
+0.796442 0.409934 0.794609 0.399406 0 0 0 0.00281905 l
+0.796442 0.409934 0.79577 0.411668 0 0 0 0.00281905 l
+0.843417 -0.0527606 0.850741 -0.057681 0 0 0 0.00281905 l
+-0.0353849 -0.848134 -0.0387151 -0.858925 0 0 0 0.00281905 l
+-0.0353849 -0.848134 -0.0220374 -0.843041 0 0 0 0.00281905 l
+-0.114872 0.629771 -0.107672 0.629454 0 0 0 0.00281905 l
+-0.56698 0.343785 -0.564564 0.339642 0 0 0 0.00281905 l
+-0.56698 0.343785 -0.573191 0.3415 0 0 0 0.00281905 l
+-0.722474 -0.400092 -0.722228 -0.400106 0 0 0 0.00281905 l
+-0.722474 -0.400092 -0.729001 -0.395676 0 0 0 0.00281905 l
+0.30636 0.819854 0.306646 0.83607 0 0 0 0.00281905 l
+0.30636 0.819854 0.297208 0.820841 0 0 0 0.00281905 l
+0.581845 -0.492748 0.586064 -0.478355 0 0 0 0.00281905 l
+0.581845 -0.492748 0.59493 -0.500403 0 0 0 0.00281905 l
+0.581845 -0.492748 0.570585 -0.500126 0 0 0 0.00281905 l
+-0.67852 0.130741 -0.682052 0.149011 0 0 0 0.00281905 l
+-0.67852 0.130741 -0.659829 0.136879 0 0 0 0.00281905 l
+-0.0712478 -0.0671511 -0.0770816 -0.0583641 0 0 0 0.00281905 l
+-0.0712478 -0.0671511 -0.0763721 -0.0732998 0 0 0 0.00281905 l
+0.0981779 0.866614 0.111441 0.849678 0 0 0 0.00281905 l
+0.245413 -0.776023 0.253907 -0.760727 0 0 0 0.00281905 l
+0.245413 -0.776023 0.248309 -0.780939 0 0 0 0.00281905 l
+-0.603949 0.475288 -0.603683 0.491128 0 0 0 0.00281905 l
+0.0326995 0.0367904 0.0323125 0.0216024 0 0 0 0.00281905 l
+0.0326995 0.0367904 0.0448701 0.0370715 0 0 0 0.00281905 l
+-0.0777067 0.408927 -0.0720977 0.409534 0 0 0 0.00281905 l
+-0.0777067 0.408927 -0.0816311 0.400133 0 0 0 0.00281905 l
+-0.882836 -0.423835 -0.885769 -0.418478 0 0 0 0.00281905 l
+-0.882836 -0.423835 -0.885301 -0.428616 0 0 0 0.00281905 l
+0.18006 -0.713056 0.172141 -0.727241 0 0 0 0.00281905 l
+0.18006 -0.713056 0.192654 -0.713142 0 0 0 0.00281905 l
+-0.150817 0.236269 -0.15789 0.236997 0 0 0 0.00281905 l
+-0.341238 0.218049 -0.340959 0.214098 0 0 0 0.00281905 l
+-0.341238 0.218049 -0.343741 0.226641 0 0 0 0.00281905 l
+0.321376 -0.186399 0.318145 -0.172307 0 0 0 0.00281905 l
+-0.0464503 0.0216653 -0.0476284 0.025398 0 0 0 0.00281905 l
+0.934655 -0.224693 0.935663 -0.201174 0 0 0 0.00281905 l
+0.934655 -0.224693 0.926691 -0.231533 0 0 0 0.00281905 l
+-0.141104 0.913471 -0.149146 0.910903 0 0 0 0.00281905 l
+0.0995328 0.230874 0.0804247 0.242859 0 0 0 0.00281905 l
+0.0995328 0.230874 0.101127 0.233477 0 0 0 0.00281905 l
+0.843803 -0.191406 0.823738 -0.182048 0 0 0 0.00281905 l
+0.569777 -0.00821252 0.577884 -0.00951244 0 0 0 0.00281905 l
+0.569777 -0.00821252 0.559005 -0.018311 0 0 0 0.00281905 l
+0.143079 0.845248 0.155878 0.83676 0 0 0 0.00281905 l
+0.143079 0.845248 0.133606 0.836049 0 0 0 0.00281905 l
+-0.581446 -0.314342 -0.583892 -0.317741 0 0 0 0.00281905 l
+0.0582615 0.131091 0.0754052 0.135926 0 0 0 0.00281905 l
+0.0582615 0.131091 0.0446075 0.132718 0 0 0 0.00281905 l
+-0.280749 0.00932734 -0.293584 0.0196004 0 0 0 0.00281905 l
+-0.280749 0.00932734 -0.288595 0.00379277 0 0 0 0.00281905 l
+0.201598 -0.588095 0.202967 -0.576562 0 0 0 0.00281905 l
+0.201598 -0.588095 0.219363 -0.600191 0 0 0 0.00281905 l
+0.201598 -0.588095 0.192975 -0.585733 0 0 0 0.00281905 l
+-0.641361 0.541519 -0.629935 0.526809 0 0 0 0.00281905 l
+-0.641361 0.541519 -0.644258 0.547697 0 0 0 0.00281905 l
+0.469294 -0.8652 0.473536 -0.85081 0 0 0 0.00281905 l
+0.469294 -0.8652 0.456529 -0.861739 0 0 0 0.00281905 l
+-0.777657 0.581113 -0.777821 0.563847 0 0 0 0.00281905 l
+-0.777657 0.581113 -0.774951 0.58919 0 0 0 0.00281905 l
+-0.777657 0.581113 -0.784184 0.584221 0 0 0 0.00281905 l
+-0.199306 0.739641 -0.187573 0.735514 0 0 0 0.00281905 l
+-0.199306 0.739641 -0.201912 0.744344 0 0 0 0.00281905 l
+-0.0331869 0.148115 -0.0270269 0.132542 0 0 0 0.00281905 l
+0.0588895 0.503464 0.057367 0.489707 0 0 0 0.00281905 l
+0.0588895 0.503464 0.064028 0.50754 0 0 0 0.00281905 l
+-0.668018 0.343876 -0.67619 0.342936 0 0 0 0.00281905 l
+0.3082 0.0141989 0.311135 0.0208179 0 0 0 0.00281905 l
+0.3082 0.0141989 0.302631 0.012745 0 0 0 0.00281905 l
+0.274284 0.169888 0.283233 0.162454 0 0 0 0.00281905 l
+0.516038 0.0295501 0.520171 0.0260144 0 0 0 0.00281905 l
+0.516038 0.0295501 0.511528 0.0264356 0 0 0 0.00281905 l
+-0.0986139 0.305745 -0.0891844 0.289279 0 0 0 0.00281905 l
+-0.0986139 0.305745 -0.115233 0.302014 0 0 0 0.00281905 l
+-0.213637 0.423911 -0.205203 0.434233 0 0 0 0.00281905 l
+-0.213637 0.423911 -0.221782 0.417106 0 0 0 0.00281905 l
+-0.657953 -0.751981 -0.652747 -0.756496 0 0 0 0.00281905 l
+-0.657953 -0.751981 -0.661565 -0.733299 0 0 0 0.00281905 l
+0.960453 -0.025314 0.965567 -0.0267364 0 0 0 0.00281905 l
+0.622638 0.345301 0.639856 0.339225 0 0 0 0.00281905 l
+0.622638 0.345301 0.613926 0.33196 0 0 0 0.00281905 l
+0.622638 0.345301 0.608925 0.358462 0 0 0 0.00281905 l
+-0.436385 0.500343 -0.43552 0.483817 0 0 0 0.00281905 l
+-0.436385 0.500343 -0.44388 0.507345 0 0 0 0.00281905 l
+0.745363 -0.16276 0.744215 -0.148421 0 0 0 0.00281905 l
+0.745363 -0.16276 0.759571 -0.157329 0 0 0 0.00281905 l
+0.745363 -0.16276 0.743223 -0.165684 0 0 0 0.00281905 l
+-0.0865204 0.142866 -0.0816385 0.155719 0 0 0 0.00281905 l
+-0.0865204 0.142866 -0.105974 0.154572 0 0 0 0.00281905 l
+0.350253 -0.649658 0.351796 -0.639906 0 0 0 0.00281905 l
+0.350253 -0.649658 0.348499 -0.656885 0 0 0 0.00281905 l
+0.350253 -0.649658 0.341504 -0.646166 0 0 0 0.00281905 l
+0.455486 -0.21582 0.453209 -0.204185 0 0 0 0.00281905 l
+0.455486 -0.21582 0.458006 -0.218894 0 0 0 0.00281905 l
+0.285125 -0.275222 0.291693 -0.272141 0 0 0 0.00281905 l
+0.63272 0.138527 0.649502 0.150461 0 0 0 0.00281905 l
+-0.483274 -0.275463 -0.483541 -0.268556 0 0 0 0.00281905 l
+-0.483274 -0.275463 -0.475386 -0.272768 0 0 0 0.00281905 l
+-0.483274 -0.275463 -0.490357 -0.286128 0 0 0 0.00281905 l
+0.560795 -0.171927 0.551792 -0.181033 0 0 0 0.00281905 l
+0.560795 -0.171927 0.552533 -0.165465 0 0 0 0.00281905 l
+-0.0438324 0.283814 -0.0411414 0.297721 0 0 0 0.00281905 l
+-0.0438324 0.283814 -0.0549432 0.285889 0 0 0 0.00281905 l
+0.228827 -0.163963 0.225128 -0.157102 0 0 0 0.00281905 l
+0.228827 -0.163963 0.238042 -0.17405 0 0 0 0.00281905 l
+0.228827 -0.163963 0.214993 -0.16831 0 0 0 0.00281905 l
+-0.0892202 0.439158 -0.0890332 0.432214 0 0 0 0.00281905 l
+-0.0892202 0.439158 -0.081642 0.442934 0 0 0 0.00281905 l
+-0.7412 -0.291267 -0.746132 -0.310331 0 0 0 0.00281905 l
+-0.7412 -0.291267 -0.723254 -0.287022 0 0 0 0.00281905 l
+-0.41976 -0.485287 -0.400099 -0.492662 0 0 0 0.00281905 l
+0.818649 -0.185561 0.823738 -0.182048 0 0 0 0.00281905 l
+0.818649 -0.185561 0.816169 -0.181239 0 0 0 0.00281905 l
+-0.432701 -0.340521 -0.437854 -0.352338 0 0 0 0.00281905 l
+-0.432701 -0.340521 -0.428882 -0.333464 0 0 0 0.00281905 l
+-0.432701 -0.340521 -0.44396 -0.339364 0 0 0 0.00281905 l
+-0.426563 -0.191342 -0.404371 -0.192489 0 0 0 0.00281905 l
+-0.426563 -0.191342 -0.436441 -0.179718 0 0 0 0.00281905 l
+0.113321 0.90287 0.114246 0.910178 0 0 0 0.00281905 l
+0.113321 0.90287 0.108754 0.893897 0 0 0 0.00281905 l
+0.419496 0.590839 0.408156 0.574388 0 0 0 0.00281905 l
+0.419496 0.590839 0.422983 0.600975 0 0 0 0.00281905 l
+-0.187547 0.49149 -0.182278 0.478683 0 0 0 0.00281905 l
+-0.187547 0.49149 -0.193041 0.495938 0 0 0 0.00281905 l
+0.285754 -0.745136 0.29665 -0.741865 0 0 0 0.00281905 l
+0.285754 -0.745136 0.280147 -0.735182 0 0 0 0.00281905 l
+-0.421323 -0.67407 -0.430726 -0.689184 0 0 0 0.00281905 l
+-0.421323 -0.67407 -0.419209 -0.669044 0 0 0 0.00281905 l
+-0.66817 0.384922 -0.653576 0.374083 0 0 0 0.00281905 l
+-0.66817 0.384922 -0.676341 0.367073 0 0 0 0.00281905 l
+-0.66817 0.384922 -0.655043 0.392471 0 0 0 0.00281905 l
+-0.66817 0.384922 -0.680053 0.393509 0 0 0 0.00281905 l
+0.0975184 0.399122 0.109132 0.386105 0 0 0 0.00281905 l
+0.0975184 0.399122 0.0860354 0.408903 0 0 0 0.00281905 l
+-0.976945 0.149804 -0.967208 0.152214 0 0 0 0.00281905 l
+0.430336 -0.0133154 0.435286 -0.0109673 0 0 0 0.00281905 l
+0.505343 0.160212 0.495671 0.172731 0 0 0 0.00281905 l
+0.505343 0.160212 0.489694 0.149198 0 0 0 0.00281905 l
+-0.0970616 0.367848 -0.0859777 0.363155 0 0 0 0.00281905 l
+-0.0970616 0.367848 -0.0889522 0.379026 0 0 0 0.00281905 l
+-0.0970616 0.367848 -0.10871 0.354069 0 0 0 0.00281905 l
+0.514997 0.475471 0.525091 0.464665 0 0 0 0.00281905 l
+0.514997 0.475471 0.511954 0.493328 0 0 0 0.00281905 l
+0.514997 0.475471 0.505134 0.468774 0 0 0 0.00281905 l
+0.160339 -0.756281 0.179239 -0.760919 0 0 0 0.00281905 l
+0.160339 -0.756281 0.154218 -0.770312 0 0 0 0.00281905 l
+0.160339 -0.756281 0.156873 -0.75443 0 0 0 0.00281905 l
+0.664886 0.175773 0.674131 0.181231 0 0 0 0.00281905 l
+0.664886 0.175773 0.654959 0.182825 0 0 0 0.00281905 l
+-0.563939 -0.404791 -0.555383 -0.398187 0 0 0 0.00281905 l
+-0.317264 -0.715457 -0.33118 -0.696436 0 0 0 0.00281905 l
+-0.317264 -0.715457 -0.314749 -0.713841 0 0 0 0.00281905 l
+0.221343 -0.4528 0.206386 -0.452701 0 0 0 0.00281905 l
+-0.0731623 -0.463906 -0.0724658 -0.473547 0 0 0 0.00281905 l
+-0.0731623 -0.463906 -0.0725904 -0.462424 0 0 0 0.00281905 l
+0.692024 -0.331256 0.693114 -0.323452 0 0 0 0.00281905 l
+0.310962 -0.0655643 0.313042 -0.0558716 0 0 0 0.00281905 l
+0.310962 -0.0655643 0.319802 -0.0770073 0 0 0 0.00281905 l
+0.310962 -0.0655643 0.302011 -0.0717886 0 0 0 0.00281905 l
+-0.941997 0.26991 -0.942199 0.272833 0 0 0 0.00281905 l
+-0.941997 0.26991 -0.95111 0.262859 0 0 0 0.00281905 l
+0.466408 0.541015 0.459317 0.545806 0 0 0 0.00281905 l
+0.466408 0.541015 0.465141 0.538864 0 0 0 0.00281905 l
+-0.309123 -0.76356 -0.309985 -0.746704 0 0 0 0.00281905 l
+-0.309123 -0.76356 -0.291435 -0.755148 0 0 0 0.00281905 l
+-0.309123 -0.76356 -0.327799 -0.780081 0 0 0 0.00281905 l
+0.38274 0.118071 0.36978 0.104754 0 0 0 0.00281905 l
+0.38274 0.118071 0.383568 0.125205 0 0 0 0.00281905 l
+0.214702 -0.720671 0.221392 -0.721223 0 0 0 0.00281905 l
+0.214702 -0.720671 0.204618 -0.71277 0 0 0 0.00281905 l
+0.160818 -0.43339 0.148215 -0.432363 0 0 0 0.00281905 l
+0.445981 -0.845682 0.447366 -0.828168 0 0 0 0.00281905 l
+0.445981 -0.845682 0.450259 -0.853663 0 0 0 0.00281905 l
+0.313265 0.525326 0.314249 0.504321 0 0 0 0.00281905 l
+0.313265 0.525326 0.317729 0.536861 0 0 0 0.00281905 l
+0.313265 0.525326 0.303326 0.535783 0 0 0 0.00281905 l
+-0.120349 -0.906132 -0.120728 -0.908797 0 0 0 0.00281905 l
+-0.120349 -0.906132 -0.115396 -0.90128 0 0 0 0.00281905 l
+-0.847641 0.416984 -0.830022 0.426071 0 0 0 0.00281905 l
+-0.847641 0.416984 -0.856608 0.429681 0 0 0 0.00281905 l
+-0.485567 0.276336 -0.473127 0.272209 0 0 0 0.00281905 l
+-0.485567 0.276336 -0.489064 0.275926 0 0 0 0.00281905 l
+0.378889 -0.921906 0.393096 -0.911752 0 0 0 0.00281905 l
+0.378889 -0.921906 0.363465 -0.928574 0 0 0 0.00281905 l
+-0.577132 -0.483894 -0.562156 -0.491196 0 0 0 0.00281905 l
+-0.577132 -0.483894 -0.579603 -0.473129 0 0 0 0.00281905 l
+-0.733246 0.323356 -0.72288 0.318033 0 0 0 0.00281905 l
+-0.733246 0.323356 -0.728682 0.328992 0 0 0 0.00281905 l
+-0.733246 0.323356 -0.738605 0.320925 0 0 0 0.00281905 l
+-0.760542 0.50161 -0.75445 0.49453 0 0 0 0.00281905 l
+-0.760542 0.50161 -0.754689 0.513381 0 0 0 0.00281905 l
+-0.760542 0.50161 -0.771213 0.490798 0 0 0 0.00281905 l
+0.283415 0.912594 0.296814 0.91948 0 0 0 0.00281905 l
+0.283415 0.912594 0.270471 0.907649 0 0 0 0.00281905 l
+0.158782 0.27985 0.164095 0.284327 0 0 0 0.00281905 l
+0.158782 0.27985 0.157477 0.277165 0 0 0 0.00281905 l
+0.28927 0.44877 0.288457 0.45939 0 0 0 0.00281905 l
+0.28927 0.44877 0.278626 0.44116 0 0 0 0.00281905 l
+0.845524 0.0508683 0.843335 0.0504197 0 0 0 0.00281905 l
+0.845524 0.0508683 0.854465 0.0627964 0 0 0 0.00281905 l
+0.412389 0.685282 0.40887 0.699345 0 0 0 0.00281905 l
+0.412389 0.685282 0.424031 0.683449 0 0 0 0.00281905 l
+0.412389 0.685282 0.409591 0.679678 0 0 0 0.00281905 l
+-0.286214 -0.34936 -0.276731 -0.358055 0 0 0 0.00281905 l
+-0.286214 -0.34936 -0.290468 -0.346537 0 0 0 0.00281905 l
+-0.0891844 0.289279 -0.0986139 0.305745 0 0 0 0.00281905 l
+-0.0891844 0.289279 -0.0859123 0.278073 0 0 0 0.00281905 l
+-0.61788 0.136657 -0.608309 0.132208 0 0 0 0.00281905 l
+-0.61788 0.136657 -0.616834 0.140074 0 0 0 0.00281905 l
+-0.61788 0.136657 -0.6218 0.13006 0 0 0 0.00281905 l
+-0.120579 -0.247396 -0.121438 -0.249671 0 0 0 0.00281905 l
+-0.616138 0.659861 -0.608397 0.651242 0 0 0 0.00281905 l
+-0.616138 0.659861 -0.613033 0.662475 0 0 0 0.00281905 l
+-0.633445 0.179238 -0.631199 0.173401 0 0 0 0.00281905 l
+0.818313 0.374084 0.825101 0.377348 0 0 0 0.00281905 l
+0.818313 0.374084 0.812243 0.371146 0 0 0 0.00281905 l
+-0.0166758 -0.856668 -0.0165022 -0.872368 0 0 0 0.00281905 l
+-0.0166758 -0.856668 -0.0118951 -0.854299 0 0 0 0.00281905 l
+-0.0166758 -0.856668 -0.0212333 -0.851024 0 0 0 0.00281905 l
+0.257428 -0.296695 0.253373 -0.30039 0 0 0 0.00281905 l
+-0.446841 0.199445 -0.445922 0.200022 0 0 0 0.00281905 l
+-0.578429 0.768119 -0.568555 0.775531 0 0 0 0.00281905 l
+-0.550417 -0.47467 -0.537417 -0.469011 0 0 0 0.00281905 l
+-0.550417 -0.47467 -0.551789 -0.478057 0 0 0 0.00281905 l
+-0.519691 0.62278 -0.516433 0.609629 0 0 0 0.00281905 l
+0.121565 -0.02562 0.12617 -0.0426661 0 0 0 0.00281905 l
+0.121565 -0.02562 0.11021 -0.0159084 0 0 0 0.00281905 l
+0.301107 0.192944 0.295555 0.210707 0 0 0 0.00281905 l
+0.301107 0.192944 0.311709 0.191077 0 0 0 0.00281905 l
+-0.42977 -0.877337 -0.431849 -0.863055 0 0 0 0.00281905 l
+-0.42977 -0.877337 -0.421641 -0.879484 0 0 0 0.00281905 l
+-0.42977 -0.877337 -0.431131 -0.882019 0 0 0 0.00281905 l
+0.774394 -0.370079 0.776361 -0.373834 0 0 0 0.00281905 l
+0.0433193 -0.37552 0.0484154 -0.367749 0 0 0 0.00281905 l
+0.0433193 -0.37552 0.0454713 -0.380247 0 0 0 0.00281905 l
+0.0433193 -0.37552 0.0307062 -0.372882 0 0 0 0.00281905 l
+-0.349231 -0.855393 -0.340983 -0.860916 0 0 0 0.00281905 l
+-0.349231 -0.855393 -0.355631 -0.870232 0 0 0 0.00281905 l
+-0.349231 -0.855393 -0.354072 -0.850903 0 0 0 0.00281905 l
+-0.894618 0.154766 -0.906518 0.161012 0 0 0 0.00281905 l
+-0.120081 -0.919621 -0.121721 -0.926156 0 0 0 0.00281905 l
+-0.120081 -0.919621 -0.117226 -0.915239 0 0 0 0.00281905 l
+0.538414 0.437937 0.548013 0.428781 0 0 0 0.00281905 l
+0.538414 0.437937 0.534148 0.436348 0 0 0 0.00281905 l
+0.520495 -0.276373 0.531481 -0.29751 0 0 0 0.00281905 l
+0.0579499 -0.235702 0.0643814 -0.23302 0 0 0 0.00281905 l
+0.0579499 -0.235702 0.0432767 -0.231503 0 0 0 0.00281905 l
+0.487315 0.755318 0.486021 0.770694 0 0 0 0.00281905 l
+0.487315 0.755318 0.500963 0.763243 0 0 0 0.00281905 l
+-0.438738 -0.112103 -0.438709 -0.119845 0 0 0 0.00281905 l
+-0.438738 -0.112103 -0.437365 -0.0955664 0 0 0 0.00281905 l
+-0.396639 -0.724701 -0.391369 -0.736215 0 0 0 0.00281905 l
+-0.396639 -0.724701 -0.417486 -0.724715 0 0 0 0.00281905 l
+-0.262465 0.647171 -0.256455 0.651864 0 0 0 0.00281905 l
+-0.262465 0.647171 -0.274777 0.656034 0 0 0 0.00281905 l
+-0.495389 -0.395826 -0.496174 -0.378905 0 0 0 0.00281905 l
+-0.495389 -0.395826 -0.505746 -0.396874 0 0 0 0.00281905 l
+-0.56109 0.56863 -0.553562 0.562988 0 0 0 0.00281905 l
+-0.56109 0.56863 -0.55569 0.576532 0 0 0 0.00281905 l
+0.00183302 -0.554468 0.0142014 -0.568721 0 0 0 0.00281905 l
+0.00183302 -0.554468 0.00825097 -0.534565 0 0 0 0.00281905 l
+0.00183302 -0.554468 -0.0150999 -0.547549 0 0 0 0.00281905 l
+-0.246014 -0.212158 -0.24227 -0.228311 0 0 0 0.00281905 l
+-0.246014 -0.212158 -0.230188 -0.20267 0 0 0 0.00281905 l
+-0.246014 -0.212158 -0.256803 -0.219258 0 0 0 0.00281905 l
+0.0338978 -0.194606 0.0373998 -0.186192 0 0 0 0.00281905 l
+0.0338978 -0.194606 0.0424135 -0.197435 0 0 0 0.00281905 l
+0.0338978 -0.194606 0.0221515 -0.188089 0 0 0 0.00281905 l
+0.345347 0.251955 0.361662 0.257473 0 0 0 0.00281905 l
+0.345347 0.251955 0.348141 0.243797 0 0 0 0.00281905 l
+0.345347 0.251955 0.325924 0.247661 0 0 0 0.00281905 l
+-0.260758 0.179268 -0.26226 0.166617 0 0 0 0.00281905 l
+-0.501042 0.504486 -0.487982 0.50336 0 0 0 0.00281905 l
+-0.501042 0.504486 -0.508414 0.505237 0 0 0 0.00281905 l
+0.211175 -0.363979 0.214433 -0.348314 0 0 0 0.00281905 l
+0.211175 -0.363979 0.208135 -0.373519 0 0 0 0.00281905 l
+0.211175 -0.363979 0.194284 -0.359864 0 0 0 0.00281905 l
+-0.290863 0.570712 -0.294769 0.579498 0 0 0 0.00281905 l
+0.0259233 -0.581877 0.0291117 -0.570709 0 0 0 0.00281905 l
+0.0259233 -0.581877 0.017211 -0.590061 0 0 0 0.00281905 l
+-0.0853743 0.268654 -0.0786134 0.261651 0 0 0 0.00281905 l
+-0.0853743 0.268654 -0.0859145 0.268973 0 0 0 0.00281905 l
+-0.309744 -0.0378772 -0.320346 -0.0271773 0 0 0 0.00281905 l
+-0.309744 -0.0378772 -0.300916 -0.0348707 0 0 0 0.00281905 l
+-0.309744 -0.0378772 -0.313403 -0.044924 0 0 0 0.00281905 l
+-0.225151 -0.0607045 -0.226322 -0.0699826 0 0 0 0.00281905 l
+-0.225151 -0.0607045 -0.230517 -0.0565945 0 0 0 0.00281905 l
+-0.167437 0.664779 -0.164842 0.667286 0 0 0 0.00281905 l
+-0.426152 -0.752659 -0.429483 -0.744338 0 0 0 0.00281905 l
+-0.426152 -0.752659 -0.432589 -0.759699 0 0 0 0.00281905 l
+-0.0166209 -0.430136 -0.00781449 -0.413831 0 0 0 0.00281905 l
+-0.0166209 -0.430136 -0.00328876 -0.436844 0 0 0 0.00281905 l
+-0.0166209 -0.430136 -0.0194356 -0.44439 0 0 0 0.00281905 l
+-0.0166209 -0.430136 -0.0373656 -0.429175 0 0 0 0.00281905 l
+0.991026 -0.119659 0.992014 -0.115504 0 0 0 0.00281905 l
+0.991026 -0.119659 0.988307 -0.120358 0 0 0 0.00281905 l
+-0.373643 -0.895131 -0.375557 -0.887456 0 0 0 0.00281905 l
+-0.373643 -0.895131 -0.389546 -0.908246 0 0 0 0.00281905 l
+0.712108 0.666206 0.711514 0.656938 0 0 0 0.00281905 l
+0.712108 0.666206 0.718407 0.672556 0 0 0 0.00281905 l
+0.871776 0.14372 0.880251 0.15024 0 0 0 0.00281905 l
+-0.126635 0.0328223 -0.139392 0.0499299 0 0 0 0.00281905 l
+-0.126635 0.0328223 -0.121469 0.0228443 0 0 0 0.00281905 l
+0.831115 -0.229786 0.847223 -0.222129 0 0 0 0.00281905 l
+0.831115 -0.229786 0.816188 -0.243864 0 0 0 0.00281905 l
+-0.306925 -0.672334 -0.300275 -0.67061 0 0 0 0.00281905 l
+-0.306925 -0.672334 -0.325687 -0.670572 0 0 0 0.00281905 l
+0.423456 -0.0335887 0.42895 -0.046238 0 0 0 0.00281905 l
+0.423456 -0.0335887 0.433109 -0.0219774 0 0 0 0.00281905 l
+0.423456 -0.0335887 0.417676 -0.0281655 0 0 0 0.00281905 l
+0.807157 -0.254347 0.805731 -0.243221 0 0 0 0.00281905 l
+0.807157 -0.254347 0.799161 -0.262697 0 0 0 0.00281905 l
+0.31983 -0.586719 0.306761 -0.587732 0 0 0 0.00281905 l
+-0.475633 -0.183865 -0.470607 -0.169915 0 0 0 0.00281905 l
+-0.475633 -0.183865 -0.46137 -0.183794 0 0 0 0.00281905 l
+0.82381 0.292015 0.820688 0.303284 0 0 0 0.00281905 l
+0.82381 0.292015 0.830794 0.277003 0 0 0 0.00281905 l
+-0.500563 0.179967 -0.48711 0.166322 0 0 0 0.00281905 l
+-0.500563 0.179967 -0.506963 0.184236 0 0 0 0.00281905 l
+-0.0763677 -0.681176 -0.078388 -0.673363 0 0 0 0.00281905 l
+-0.0763677 -0.681176 -0.0695536 -0.689133 0 0 0 0.00281905 l
+0.41099 -0.206663 0.421517 -0.194016 0 0 0 0.00281905 l
+-0.139973 -0.947226 -0.135957 -0.945604 0 0 0 0.00281905 l
+-0.139973 -0.947226 -0.156711 -0.963087 0 0 0 0.00281905 l
+0.66741 -0.389189 0.667181 -0.392893 0 0 0 0.00281905 l
+0.66741 -0.389189 0.659154 -0.38286 0 0 0 0.00281905 l
+0.788023 0.145556 0.790301 0.144134 0 0 0 0.00281905 l
+0.788023 0.145556 0.78403 0.146757 0 0 0 0.00281905 l
+-0.0207099 -0.624262 -0.00771786 -0.611379 0 0 0 0.00281905 l
+-0.0207099 -0.624262 -0.0318264 -0.620569 0 0 0 0.00281905 l
+0.0150254 -0.606744 0.0177076 -0.617413 0 0 0 0.00281905 l
+0.0150254 -0.606744 0.0189354 -0.60555 0 0 0 0.00281905 l
+0.0150254 -0.606744 -0.00771786 -0.611379 0 0 0 0.00281905 l
+-0.397155 -0.0435873 -0.400799 -0.0418487 0 0 0 0.00281905 l
+-0.188668 -0.28913 -0.18317 -0.300343 0 0 0 0.00281905 l
+-0.188668 -0.28913 -0.204401 -0.283186 0 0 0 0.00281905 l
+0.0113259 0.801402 0.0274755 0.806385 0 0 0 0.00281905 l
+0.0113259 0.801402 0.0106326 0.798224 0 0 0 0.00281905 l
+-0.0484316 0.387525 -0.0382336 0.38314 0 0 0 0.00281905 l
+-0.0484316 0.387525 -0.0638413 0.392135 0 0 0 0.00281905 l
+0.260277 0.870489 0.272028 0.86479 0 0 0 0.00281905 l
+-0.296246 -0.0121887 -0.284027 -0.00818105 0 0 0 0.00281905 l
+-0.293769 0.712577 -0.295306 0.704521 0 0 0 0.00281905 l
+-0.841464 -0.225414 -0.833461 -0.227966 0 0 0 0.00281905 l
+-0.841464 -0.225414 -0.852891 -0.229667 0 0 0 0.00281905 l
+0.676055 0.48027 0.674133 0.473402 0 0 0 0.00281905 l
+0.676055 0.48027 0.690203 0.487685 0 0 0 0.00281905 l
+-0.111204 -0.235757 -0.108647 -0.235515 0 0 0 0.00281905 l
+-0.111204 -0.235757 -0.11943 -0.227097 0 0 0 0.00281905 l
+-0.26684 -0.440211 -0.262338 -0.439149 0 0 0 0.00281905 l
+-0.26684 -0.440211 -0.274216 -0.449205 0 0 0 0.00281905 l
+-0.0749651 -0.982172 -0.0898105 -0.988213 0 0 0 0.00281905 l
+-0.603287 -0.0859752 -0.594611 -0.102896 0 0 0 0.00281905 l
+-0.603287 -0.0859752 -0.614876 -0.0661967 0 0 0 0.00281905 l
+-0.603287 -0.0859752 -0.627898 -0.090737 0 0 0 0.00281905 l
+-0.344168 0.937169 -0.340081 0.924799 0 0 0 0.00281905 l
+-0.344168 0.937169 -0.354723 0.932487 0 0 0 0.00281905 l
+0.0426121 0.438404 0.0445242 0.452478 0 0 0 0.00281905 l
+0.0426121 0.438404 0.0437595 0.436363 0 0 0 0.00281905 l
+0.0426121 0.438404 0.04122 0.438206 0 0 0 0.00281905 l
+0.557663 0.32752 0.570423 0.31569 0 0 0 0.00281905 l
+0.557663 0.32752 0.553809 0.323095 0 0 0 0.00281905 l
+0.753058 0.53811 0.742707 0.555103 0 0 0 0.00281905 l
+0.753058 0.53811 0.754331 0.537284 0 0 0 0.00281905 l
+-0.561948 0.117445 -0.555041 0.10615 0 0 0 0.00281905 l
+-0.561948 0.117445 -0.567021 0.118317 0 0 0 0.00281905 l
+-0.340959 0.214098 -0.341238 0.218049 0 0 0 0.00281905 l
+-0.340959 0.214098 -0.344462 0.211454 0 0 0 0.00281905 l
+0.292119 -0.272692 0.298834 -0.274908 0 0 0 0.00281905 l
+0.292119 -0.272692 0.291693 -0.272141 0 0 0 0.00281905 l
+0.444347 -0.328139 0.449858 -0.318563 0 0 0 0.00281905 l
+0.444347 -0.328139 0.43676 -0.33439 0 0 0 0.00281905 l
+-0.0516829 0.0473933 -0.0586317 0.0550902 0 0 0 0.00281905 l
+-0.0516829 0.0473933 -0.0534172 0.0432871 0 0 0 0.00281905 l
+0.256347 -0.0677364 0.253132 -0.0840502 0 0 0 0.00281905 l
+0.256347 -0.0677364 0.261503 -0.0632182 0 0 0 0.00281905 l
+-0.949853 0.117858 -0.947799 0.116676 0 0 0 0.00281905 l
+-0.949853 0.117858 -0.959577 0.112197 0 0 0 0.00281905 l
+-0.949853 0.117858 -0.949143 0.11944 0 0 0 0.00281905 l
+-0.803296 -0.531398 -0.811891 -0.546468 0 0 0 0.00281905 l
+-0.803296 -0.531398 -0.8076 -0.529078 0 0 0 0.00281905 l
+0.117279 -0.920341 0.135028 -0.913721 0 0 0 0.00281905 l
+0.117279 -0.920341 0.106356 -0.917457 0 0 0 0.00281905 l
+-0.0433082 -0.199543 -0.0498239 -0.208133 0 0 0 0.00281905 l
+-0.0433082 -0.199543 -0.0316595 -0.195496 0 0 0 0.00281905 l
+-0.47115 -0.102792 -0.480967 -0.0807854 0 0 0 0.00281905 l
+0.850886 -0.320343 0.850786 -0.318306 0 0 0 0.00281905 l
+0.850886 -0.320343 0.855307 -0.32581 0 0 0 0.00281905 l
+-0.333743 -0.0734285 -0.322456 -0.0570458 0 0 0 0.00281905 l
+-0.333743 -0.0734285 -0.341215 -0.0772426 0 0 0 0.00281905 l
+-0.353341 0.412346 -0.349031 0.429001 0 0 0 0.00281905 l
+-0.353341 0.412346 -0.33804 0.409234 0 0 0 0.00281905 l
+-0.353341 0.412346 -0.364811 0.405046 0 0 0 0.00281905 l
+0.408885 0.0119266 0.406847 0.0152008 0 0 0 0.00281905 l
+0.408885 0.0119266 0.414858 0.0119261 0 0 0 0.00281905 l
+0.676846 0.589782 0.677766 0.609084 0 0 0 0.00281905 l
+-0.856665 0.259754 -0.868072 0.271042 0 0 0 0.00281905 l
+0.698871 -0.457361 0.703625 -0.455725 0 0 0 0.00281905 l
+-0.222037 -0.956741 -0.231127 -0.943403 0 0 0 0.00281905 l
+-0.222037 -0.956741 -0.230684 -0.960087 0 0 0 0.00281905 l
+0.471711 0.598913 0.480623 0.594851 0 0 0 0.00281905 l
+0.471711 0.598913 0.479305 0.608127 0 0 0 0.00281905 l
+0.471711 0.598913 0.460012 0.593099 0 0 0 0.00281905 l
+-0.634614 -0.598403 -0.642762 -0.613321 0 0 0 0.00281905 l
+-0.634614 -0.598403 -0.63148 -0.595981 0 0 0 0.00281905 l
+-0.634614 -0.598403 -0.637965 -0.593206 0 0 0 0.00281905 l
+-0.360989 0.679489 -0.358795 0.691045 0 0 0 0.00281905 l
+-0.360989 0.679489 -0.358543 0.676815 0 0 0 0.00281905 l
+-0.360989 0.679489 -0.374877 0.683565 0 0 0 0.00281905 l
+0.449887 -0.399375 0.445653 -0.414497 0 0 0 0.00281905 l
+0.449887 -0.399375 0.462381 -0.388774 0 0 0 0.00281905 l
+0.287191 0.394986 0.286925 0.389536 0 0 0 0.00281905 l
+0.287191 0.394986 0.27769 0.393559 0 0 0 0.00281905 l
+-0.726461 0.133977 -0.713311 0.118105 0 0 0 0.00281905 l
+-0.726461 0.133977 -0.737135 0.125423 0 0 0 0.00281905 l
+-0.835468 0.0988961 -0.83303 0.0920831 0 0 0 0.00281905 l
+-0.835468 0.0988961 -0.853908 0.0948758 0 0 0 0.00281905 l
+-0.317893 0.449859 -0.314232 0.459774 0 0 0 0.00281905 l
+-0.317893 0.449859 -0.319903 0.43632 0 0 0 0.00281905 l
+-0.317893 0.449859 -0.339107 0.451063 0 0 0 0.00281905 l
+-0.444697 0.016905 -0.446012 0.00224228 0 0 0 0.00281905 l
+-0.444697 0.016905 -0.439904 0.0280359 0 0 0 0.00281905 l
+-0.354081 0.925412 -0.354723 0.932487 0 0 0 0.00281905 l
+0.495351 -0.308538 0.493169 -0.315467 0 0 0 0.00281905 l
+0.495351 -0.308538 0.509573 -0.307295 0 0 0 0.00281905 l
+0.495351 -0.308538 0.491634 -0.301631 0 0 0 0.00281905 l
+0.57563 0.745279 0.579712 0.753556 0 0 0 0.00281905 l
+0.57563 0.745279 0.561308 0.734885 0 0 0 0.00281905 l
+-0.857489 0.10738 -0.849258 0.122367 0 0 0 0.00281905 l
+-0.857489 0.10738 -0.853908 0.0948758 0 0 0 0.00281905 l
+-0.376945 -0.745333 -0.367327 -0.731021 0 0 0 0.00281905 l
+-0.376945 -0.745333 -0.36452 -0.757353 0 0 0 0.00281905 l
+-0.376945 -0.745333 -0.383227 -0.758285 0 0 0 0.00281905 l
+-0.376945 -0.745333 -0.391369 -0.736215 0 0 0 0.00281905 l
+-0.266255 -0.953115 -0.282425 -0.936414 0 0 0 0.00281905 l
+0.411046 -0.705462 0.397213 -0.687802 0 0 0 0.00281905 l
+-0.901978 -0.0391823 -0.901392 -0.0438912 0 0 0 0.00281905 l
+-0.901978 -0.0391823 -0.902453 -0.016711 0 0 0 0.00281905 l
+0.86206 -0.0998185 0.865456 -0.0911717 0 0 0 0.00281905 l
+0.86206 -0.0998185 0.865356 -0.117963 0 0 0 0.00281905 l
+0.617671 0.455948 0.622106 0.444286 0 0 0 0.00281905 l
+0.617671 0.455948 0.625303 0.459165 0 0 0 0.00281905 l
+0.0388176 0.13814 0.0446075 0.132718 0 0 0 0.00281905 l
+-0.79226 -0.328192 -0.784377 -0.333521 0 0 0 0.00281905 l
+-0.79226 -0.328192 -0.805424 -0.314174 0 0 0 0.00281905 l
+0.266552 -0.671087 0.255973 -0.682443 0 0 0 0.00281905 l
+-0.340983 -0.860916 -0.32373 -0.856311 0 0 0 0.00281905 l
+-0.340983 -0.860916 -0.349231 -0.855393 0 0 0 0.00281905 l
+0.706113 -0.614325 0.716983 -0.618206 0 0 0 0.00281905 l
+0.706113 -0.614325 0.694226 -0.592659 0 0 0 0.00281905 l
+0.706113 -0.614325 0.70533 -0.618269 0 0 0 0.00281905 l
+-0.281838 -0.320306 -0.278715 -0.332195 0 0 0 0.00281905 l
+0.720538 0.00547182 0.726658 -0.00353304 0 0 0 0.00281905 l
+0.720538 0.00547182 0.71174 0.0107665 0 0 0 0.00281905 l
+0.178043 -0.278777 0.191317 -0.268373 0 0 0 0.00281905 l
+0.178043 -0.278777 0.179458 -0.286659 0 0 0 0.00281905 l
+-0.096476 0.822132 -0.0851098 0.81183 0 0 0 0.00281905 l
+-0.096476 0.822132 -0.114437 0.820214 0 0 0 0.00281905 l
+0.224665 -0.400439 0.241582 -0.402305 0 0 0 0.00281905 l
+0.224665 -0.400439 0.222964 -0.408546 0 0 0 0.00281905 l
+0.037721 0.818623 0.0274755 0.806385 0 0 0 0.00281905 l
+0.037721 0.818623 0.0406878 0.832308 0 0 0 0.00281905 l
+-0.230167 -0.823515 -0.224764 -0.826819 0 0 0 0.00281905 l
+-0.230167 -0.823515 -0.23903 -0.84309 0 0 0 0.00281905 l
+0.234133 -0.320769 0.231676 -0.3381 0 0 0 0.00281905 l
+0.234133 -0.320769 0.221328 -0.314392 0 0 0 0.00281905 l
+-0.129745 -0.974393 -0.121182 -0.971737 0 0 0 0.00281905 l
+-0.129745 -0.974393 -0.121834 -0.986263 0 0 0 0.00281905 l
+0.546702 0.356133 0.544997 0.363752 0 0 0 0.00281905 l
+-0.523048 -0.366127 -0.524486 -0.348605 0 0 0 0.00281905 l
+-0.523048 -0.366127 -0.52954 -0.374254 0 0 0 0.00281905 l
+-0.43382 0.433634 -0.433659 0.435334 0 0 0 0.00281905 l
+-0.43382 0.433634 -0.429034 0.416299 0 0 0 0.00281905 l
+-0.43382 0.433634 -0.439242 0.433102 0 0 0 0.00281905 l
+0.487859 0.307611 0.484448 0.306933 0 0 0 0.00281905 l
+0.547894 -0.286355 0.538235 -0.301711 0 0 0 0.00281905 l
+0.547894 -0.286355 0.552371 -0.278153 0 0 0 0.00281905 l
+-0.126637 0.315117 -0.126729 0.319218 0 0 0 0.00281905 l
+-0.126637 0.315117 -0.116015 0.30627 0 0 0 0.00281905 l
+-0.126637 0.315117 -0.138929 0.302653 0 0 0 0.00281905 l
+-0.309704 0.506116 -0.317296 0.494619 0 0 0 0.00281905 l
+-0.524245 -0.186631 -0.534629 -0.178345 0 0 0 0.00281905 l
+-0.524245 -0.186631 -0.511763 -0.195182 0 0 0 0.00281905 l
+0.459915 -0.0619874 0.462674 -0.0533953 0 0 0 0.00281905 l
+0.671624 0.645106 0.66913 0.636835 0 0 0 0.00281905 l
+0.671624 0.645106 0.669726 0.650478 0 0 0 0.00281905 l
+-0.221011 -0.0920298 -0.2181 -0.0750379 0 0 0 0.00281905 l
+-0.221011 -0.0920298 -0.215574 -0.096557 0 0 0 0.00281905 l
+0.23657 -0.652371 0.243901 -0.642405 0 0 0 0.00281905 l
+-0.759496 0.290101 -0.760269 0.269954 0 0 0 0.00281905 l
+-0.759496 0.290101 -0.76811 0.294511 0 0 0 0.00281905 l
+-0.15467 -0.384005 -0.151434 -0.396547 0 0 0 0.00281905 l
+-0.15467 -0.384005 -0.155672 -0.378808 0 0 0 0.00281905 l
+0.340305 0.139951 0.332869 0.135137 0 0 0 0.00281905 l
+0.939788 0.320068 0.947893 0.316158 0 0 0 0.00281905 l
+0.939788 0.320068 0.921102 0.319728 0 0 0 0.00281905 l
+-0.797656 0.263615 -0.811576 0.257864 0 0 0 0.00281905 l
+0.151858 0.829035 0.155878 0.83676 0 0 0 0.00281905 l
+0.77051 0.0147366 0.770751 0.0195839 0 0 0 0.00281905 l
+0.77051 0.0147366 0.75031 0.0151408 0 0 0 0.00281905 l
+-0.353358 -0.0965898 -0.35861 -0.0937448 0 0 0 0.00281905 l
+-0.353358 -0.0965898 -0.353776 -0.0977946 0 0 0 0.00281905 l
+0.0565057 -0.642049 0.0605841 -0.660208 0 0 0 0.00281905 l
+0.0565057 -0.642049 0.0669338 -0.638431 0 0 0 0.00281905 l
+0.0565057 -0.642049 0.0410285 -0.638444 0 0 0 0.00281905 l
+-0.703517 -0.234983 -0.700306 -0.230823 0 0 0 0.00281905 l
+-0.703517 -0.234983 -0.70995 -0.241291 0 0 0 0.00281905 l
+0.740601 0.284847 0.737404 0.285698 0 0 0 0.00281905 l
+0.740601 0.284847 0.74435 0.286138 0 0 0 0.00281905 l
+-0.797881 -0.206795 -0.78696 -0.203352 0 0 0 0.00281905 l
+-0.797881 -0.206795 -0.808262 -0.199351 0 0 0 0.00281905 l
+-0.797881 -0.206795 -0.798348 -0.20823 0 0 0 0.00281905 l
+0.594609 -0.623847 0.595823 -0.615662 0 0 0 0.00281905 l
+0.594609 -0.623847 0.583115 -0.628053 0 0 0 0.00281905 l
+0.0257341 0.764167 0.0126096 0.76101 0 0 0 0.00281905 l
+0.245675 -0.565972 0.251407 -0.561303 0 0 0 0.00281905 l
+0.186853 -0.202447 0.196177 -0.205125 0 0 0 0.00281905 l
+-0.406675 -0.217436 -0.403671 -0.216343 0 0 0 0.00281905 l
+-0.418246 -0.0812016 -0.418477 -0.0766387 0 0 0 0.00281905 l
+0.512163 -0.562278 0.519605 -0.56043 0 0 0 0.00281905 l
+0.512163 -0.562278 0.503224 -0.559041 0 0 0 0.00281905 l
+-0.304193 -0.87692 -0.30212 -0.867791 0 0 0 0.00281905 l
+-0.304193 -0.87692 -0.281719 -0.877927 0 0 0 0.00281905 l
+-0.304193 -0.87692 -0.312802 -0.893684 0 0 0 0.00281905 l
+-0.145989 -0.21513 -0.129336 -0.223367 0 0 0 0.00281905 l
+-0.145989 -0.21513 -0.14996 -0.210912 0 0 0 0.00281905 l
+-0.885301 -0.428616 -0.882836 -0.423835 0 0 0 0.00281905 l
+-0.885301 -0.428616 -0.884676 -0.434774 0 0 0 0.00281905 l
+-0.103943 -0.850149 -0.0939285 -0.847176 0 0 0 0.00281905 l
+-0.103943 -0.850149 -0.116915 -0.840728 0 0 0 0.00281905 l
+0.23886 -0.305276 0.251968 -0.300188 0 0 0 0.00281905 l
+0.23886 -0.305276 0.226722 -0.308196 0 0 0 0.00281905 l
+-0.777821 0.563847 -0.777657 0.581113 0 0 0 0.00281905 l
+-0.777821 0.563847 -0.767072 0.551853 0 0 0 0.00281905 l
+-0.0350571 -0.807325 -0.035769 -0.78507 0 0 0 0.00281905 l
+-0.0350571 -0.807325 -0.0363477 -0.814841 0 0 0 0.00281905 l
+-0.830022 0.426071 -0.847641 0.416984 0 0 0 0.00281905 l
+-0.830022 0.426071 -0.836143 0.434044 0 0 0 0.00281905 l
+0.788804 0.217445 0.809769 0.207781 0 0 0 0.00281905 l
+0.788804 0.217445 0.777285 0.227256 0 0 0 0.00281905 l
+0.553961 -0.37671 0.556954 -0.389991 0 0 0 0.00281905 l
+0.553961 -0.37671 0.545729 -0.378057 0 0 0 0.00281905 l
+0.592899 -0.296266 0.593958 -0.298609 0 0 0 0.00281905 l
+0.592899 -0.296266 0.588218 -0.290661 0 0 0 0.00281905 l
+-0.404415 0.286519 -0.401378 0.285835 0 0 0 0.00281905 l
+-0.404415 0.286519 -0.410389 0.283303 0 0 0 0.00281905 l
+0.309464 0.646158 0.303412 0.654062 0 0 0 0.00281905 l
+0.309464 0.646158 0.304278 0.635915 0 0 0 0.00281905 l
+0.787474 0.455728 0.79524 0.470555 0 0 0 0.00281905 l
+-0.770889 0.368695 -0.779988 0.363388 0 0 0 0.00281905 l
+-0.382611 -0.448127 -0.384419 -0.458153 0 0 0 0.00281905 l
+-0.382611 -0.448127 -0.380921 -0.447 0 0 0 0.00281905 l
+-0.808412 0.0171506 -0.813494 0.00301869 0 0 0 0.00281905 l
+-0.808412 0.0171506 -0.817779 0.0254674 0 0 0 0.00281905 l
+0.0592192 -0.832596 0.0742208 -0.836554 0 0 0 0.00281905 l
+0.0592192 -0.832596 0.0445223 -0.846144 0 0 0 0.00281905 l
+0.971689 0.224964 0.95727 0.226526 0 0 0 0.00281905 l
+0.40843 0.633497 0.420206 0.638806 0 0 0 0.00281905 l
+0.40843 0.633497 0.399564 0.642568 0 0 0 0.00281905 l
+-0.862234 0.396472 -0.8608 0.387165 0 0 0 0.00281905 l
+-0.862234 0.396472 -0.873724 0.39683 0 0 0 0.00281905 l
+-0.0615237 -0.107651 -0.0681322 -0.117907 0 0 0 0.00281905 l
+-0.0615237 -0.107651 -0.0437732 -0.105416 0 0 0 0.00281905 l
+-0.0615237 -0.107651 -0.0621551 -0.10562 0 0 0 0.00281905 l
+0.351496 -0.429794 0.347775 -0.416992 0 0 0 0.00281905 l
+0.351496 -0.429794 0.357045 -0.434138 0 0 0 0.00281905 l
+0.70289 -0.291814 0.710744 -0.274289 0 0 0 0.00281905 l
+0.70289 -0.291814 0.69908 -0.305671 0 0 0 0.00281905 l
+-0.276053 -0.376284 -0.274294 -0.388489 0 0 0 0.00281905 l
+-0.276053 -0.376284 -0.263865 -0.370285 0 0 0 0.00281905 l
+-0.883816 -0.0236089 -0.881043 -0.0119759 0 0 0 0.00281905 l
+0.617897 0.666362 0.624336 0.680053 0 0 0 0.00281905 l
+0.617897 0.666362 0.622522 0.657171 0 0 0 0.00281905 l
+-0.399403 0.42314 -0.401258 0.411192 0 0 0 0.00281905 l
+-0.399403 0.42314 -0.403822 0.425605 0 0 0 0.00281905 l
+0.708712 0.656746 0.711514 0.656938 0 0 0 0.00281905 l
+0.708712 0.656746 0.701928 0.645464 0 0 0 0.00281905 l
+-0.374647 -0.396082 -0.372475 -0.386635 0 0 0 0.00281905 l
+-0.374647 -0.396082 -0.361644 -0.410231 0 0 0 0.00281905 l
+-0.374647 -0.396082 -0.391737 -0.408452 0 0 0 0.00281905 l
+-0.121641 -0.683611 -0.116191 -0.675018 0 0 0 0.00281905 l
+-0.121641 -0.683611 -0.129235 -0.68322 0 0 0 0.00281905 l
+0.440681 -0.35128 0.428602 -0.3471 0 0 0 0.00281905 l
+0.0494847 0.840127 0.0540049 0.834331 0 0 0 0.00281905 l
+0.0494847 0.840127 0.0377893 0.841139 0 0 0 0.00281905 l
+0.165484 -0.514362 0.171809 -0.502699 0 0 0 0.00281905 l
+0.165484 -0.514362 0.169108 -0.524408 0 0 0 0.00281905 l
+0.165484 -0.514362 0.151264 -0.512561 0 0 0 0.00281905 l
+0.725238 0.540268 0.716267 0.549514 0 0 0 0.00281905 l
+0.121215 -0.190181 0.122978 -0.193479 0 0 0 0.00281905 l
+0.121215 -0.190181 0.114652 -0.18783 0 0 0 0.00281905 l
+0.0280003 -0.993834 0.029335 -0.976844 0 0 0 0.00281905 l
+0.0280003 -0.993834 0.0260746 -0.998488 0 0 0 0.00281905 l
+-0.121355 0.0899399 -0.128629 0.0992151 0 0 0 0.00281905 l
+-0.121355 0.0899399 -0.109606 0.0862939 0 0 0 0.00281905 l
+0.083658 0.27673 0.0893844 0.282907 0 0 0 0.00281905 l
+0.083658 0.27673 0.0895203 0.263639 0 0 0 0.00281905 l
+-0.56875 -0.325975 -0.553714 -0.325577 0 0 0 0.00281905 l
+-0.56875 -0.325975 -0.575306 -0.334004 0 0 0 0.00281905 l
+0.197503 0.470117 0.195913 0.483755 0 0 0 0.00281905 l
+0.197503 0.470117 0.194361 0.451397 0 0 0 0.00281905 l
+0.056529 0.353663 0.054131 0.344527 0 0 0 0.00281905 l
+0.056529 0.353663 0.0449346 0.352802 0 0 0 0.00281905 l
+0.626875 -0.0276707 0.634276 -0.0121349 0 0 0 0.00281905 l
+0.626875 -0.0276707 0.634094 -0.031309 0 0 0 0.00281905 l
+0.626875 -0.0276707 0.61523 -0.0217753 0 0 0 0.00281905 l
+0.148215 -0.432363 0.160818 -0.43339 0 0 0 0.00281905 l
+0.148215 -0.432363 0.143508 -0.416166 0 0 0 0.00281905 l
+0.107883 -0.499038 0.120706 -0.499668 0 0 0 0.00281905 l
+-0.14014 -0.764077 -0.135173 -0.753246 0 0 0 0.00281905 l
+-0.14014 -0.764077 -0.13529 -0.76517 0 0 0 0.00281905 l
+-0.14014 -0.764077 -0.146222 -0.766371 0 0 0 0.00281905 l
+0.0806951 -0.366446 0.0797773 -0.354531 0 0 0 0.00281905 l
+0.0806951 -0.366446 0.0932169 -0.368894 0 0 0 0.00281905 l
+-0.425685 -0.6212 -0.428617 -0.61074 0 0 0 0.00281905 l
+-0.425685 -0.6212 -0.426274 -0.627145 0 0 0 0.00281905 l
+0.0487097 0.636865 0.040934 0.653378 0 0 0 0.00281905 l
+0.755244 0.134949 0.760149 0.135229 0 0 0 0.00281905 l
+0.755244 0.134949 0.757193 0.121594 0 0 0 0.00281905 l
+0.755244 0.134949 0.744607 0.134864 0 0 0 0.00281905 l
+-0.809437 -0.271793 -0.800831 -0.263721 0 0 0 0.00281905 l
+-0.809437 -0.271793 -0.804077 -0.281375 0 0 0 0.00281905 l
+-0.0570988 0.487806 -0.0670468 0.496376 0 0 0 0.00281905 l
+-0.0570988 0.487806 -0.0693729 0.480832 0 0 0 0.00281905 l
+0.690749 -0.239843 0.704875 -0.253117 0 0 0 0.00281905 l
+-0.18381 0.297756 -0.184112 0.293467 0 0 0 0.00281905 l
+-0.18381 0.297756 -0.17744 0.305878 0 0 0 0.00281905 l
+0.0239222 0.0617035 0.0402859 0.0554464 0 0 0 0.00281905 l
+0.0239222 0.0617035 0.0268152 0.0687403 0 0 0 0.00281905 l
+-0.621653 -0.194644 -0.611812 -0.201149 0 0 0 0.00281905 l
+-0.621653 -0.194644 -0.614974 -0.184413 0 0 0 0.00281905 l
+-0.621653 -0.194644 -0.630126 -0.203224 0 0 0 0.00281905 l
+0.390101 0.123344 0.405075 0.139008 0 0 0 0.00281905 l
+0.390101 0.123344 0.386066 0.127808 0 0 0 0.00281905 l
+0.506343 -0.176612 0.515754 -0.178052 0 0 0 0.00281905 l
+0.506839 0.811955 0.512679 0.821944 0 0 0 0.00281905 l
+0.506839 0.811955 0.498734 0.820436 0 0 0 0.00281905 l
+0.681319 -0.589522 0.686379 -0.599059 0 0 0 0.00281905 l
+0.681319 -0.589522 0.687008 -0.5805 0 0 0 0.00281905 l
+0.681319 -0.589522 0.674716 -0.594216 0 0 0 0.00281905 l
+0.619921 -0.544049 0.614157 -0.531152 0 0 0 0.00281905 l
+0.619921 -0.544049 0.623513 -0.54772 0 0 0 0.00281905 l
+0.619921 -0.544049 0.607281 -0.556219 0 0 0 0.00281905 l
+0.406171 -0.442588 0.400765 -0.454313 0 0 0 0.00281905 l
+0.406171 -0.442588 0.41088 -0.4435 0 0 0 0.00281905 l
+0.953854 0.122269 0.977199 0.113626 0 0 0 0.00281905 l
+0.953854 0.122269 0.947818 0.125689 0 0 0 0.00281905 l
+0.953854 0.122269 0.948885 0.118758 0 0 0 0.00281905 l
+0.649814 -0.178015 0.6559 -0.184946 0 0 0 0.00281905 l
+0.649814 -0.178015 0.636227 -0.184951 0 0 0 0.00281905 l
+0.714656 -0.0710853 0.723069 -0.0595435 0 0 0 0.00281905 l
+0.714656 -0.0710853 0.709097 -0.0728468 0 0 0 0.00281905 l
+0.0454713 -0.380247 0.0475204 -0.380985 0 0 0 0.00281905 l
+0.0454713 -0.380247 0.0433193 -0.37552 0 0 0 0.00281905 l
+-0.698387 -0.377688 -0.679858 -0.377469 0 0 0 0.00281905 l
+-0.698387 -0.377688 -0.708738 -0.386085 0 0 0 0.00281905 l
+0.599145 -0.376025 0.617002 -0.372713 0 0 0 0.00281905 l
+0.599145 -0.376025 0.59351 -0.378382 0 0 0 0.00281905 l
+0.209329 -0.239912 0.19566 -0.230072 0 0 0 0.00281905 l
+-0.349031 0.429001 -0.353341 0.412346 0 0 0 0.00281905 l
+-0.282038 0.845353 -0.276084 0.849664 0 0 0 0.00281905 l
+-0.282038 0.845353 -0.275831 0.841272 0 0 0 0.00281905 l
+-0.282038 0.845353 -0.286843 0.837955 0 0 0 0.00281905 l
+-0.184303 0.462078 -0.179933 0.452799 0 0 0 0.00281905 l
+-0.184303 0.462078 -0.192006 0.469847 0 0 0 0.00281905 l
+0.430854 -0.82155 0.435802 -0.823099 0 0 0 0.00281905 l
+0.430854 -0.82155 0.41144 -0.812832 0 0 0 0.00281905 l
+-0.739033 0.058379 -0.737577 0.0494016 0 0 0 0.00281905 l
+-0.739033 0.058379 -0.742278 0.0647263 0 0 0 0.00281905 l
+-0.0131691 -0.330904 -0.0222405 -0.340454 0 0 0 0.00281905 l
+-0.540851 -0.770903 -0.544933 -0.789297 0 0 0 0.00281905 l
+-0.540851 -0.770903 -0.533195 -0.759963 0 0 0 0.00281905 l
+-0.371659 0.499413 -0.366666 0.51632 0 0 0 0.00281905 l
+-0.371659 0.499413 -0.356936 0.489893 0 0 0 0.00281905 l
+-0.371659 0.499413 -0.381654 0.482027 0 0 0 0.00281905 l
+-0.371659 0.499413 -0.3834 0.50305 0 0 0 0.00281905 l
+-0.263941 -0.513142 -0.265894 -0.525587 0 0 0 0.00281905 l
+-0.263941 -0.513142 -0.275168 -0.50375 0 0 0 0.00281905 l
+-0.030818 0.409307 -0.0410162 0.425466 0 0 0 0.00281905 l
+0.710185 -0.244217 0.704875 -0.253117 0 0 0 0.00281905 l
+0.49427 0.45577 0.496445 0.455707 0 0 0 0.00281905 l
+-0.100216 -0.514579 -0.0926513 -0.513891 0 0 0 0.00281905 l
+-0.100216 -0.514579 -0.119089 -0.5204 0 0 0 0.00281905 l
+0.268162 0.207814 0.277643 0.207278 0 0 0 0.00281905 l
+-0.884676 -0.434774 -0.885301 -0.428616 0 0 0 0.00281905 l
+0.432184 -0.109052 0.431016 -0.101707 0 0 0 0.00281905 l
+0.432184 -0.109052 0.442514 -0.118683 0 0 0 0.00281905 l
+0.432184 -0.109052 0.426473 -0.120629 0 0 0 0.00281905 l
+0.443484 0.851936 0.44287 0.861957 0 0 0 0.00281905 l
+-0.894943 -0.00108552 -0.893278 0.00840169 0 0 0 0.00281905 l
+-0.894943 -0.00108552 -0.891073 -0.00357615 0 0 0 0.00281905 l
+-0.894943 -0.00108552 -0.901506 -0.0101113 0 0 0 0.00281905 l
+-0.776896 0.604854 -0.76161 0.608224 0 0 0 0.00281905 l
+-0.776896 0.604854 -0.776513 0.601194 0 0 0 0.00281905 l
+-0.577564 0.298612 -0.581128 0.284022 0 0 0 0.00281905 l
+0.410406 -0.489229 0.406519 -0.486546 0 0 0 0.00281905 l
+0.900101 -0.384038 0.90764 -0.372444 0 0 0 0.00281905 l
+-0.673343 0.0154916 -0.671378 0.0382945 0 0 0 0.00281905 l
+-0.546757 0.595024 -0.55569 0.576532 0 0 0 0.00281905 l
+-0.546757 0.595024 -0.543793 0.59757 0 0 0 0.00281905 l
+-0.546757 0.595024 -0.549732 0.598092 0 0 0 0.00281905 l
+-0.0435758 0.860141 -0.0420746 0.854616 0 0 0 0.00281905 l
+-0.0435758 0.860141 -0.0415744 0.868008 0 0 0 0.00281905 l
+-0.348134 -0.887908 -0.35154 -0.886153 0 0 0 0.00281905 l
+0.59835 -0.643821 0.604926 -0.640913 0 0 0 0.00281905 l
+0.59835 -0.643821 0.590357 -0.645292 0 0 0 0.00281905 l
+-0.470451 0.844619 -0.465504 0.857236 0 0 0 0.00281905 l
+-0.470451 0.844619 -0.483647 0.828384 0 0 0 0.00281905 l
+-0.181904 -0.247208 -0.168794 -0.259154 0 0 0 0.00281905 l
+-0.181904 -0.247208 -0.177367 -0.232214 0 0 0 0.00281905 l
+-0.181904 -0.247208 -0.197342 -0.242671 0 0 0 0.00281905 l
+-0.882339 -0.243127 -0.870285 -0.244031 0 0 0 0.00281905 l
+-0.882339 -0.243127 -0.888712 -0.239626 0 0 0 0.00281905 l
+-0.202566 -0.661997 -0.199851 -0.65383 0 0 0 0.00281905 l
+-0.202566 -0.661997 -0.206515 -0.673358 0 0 0 0.00281905 l
+0.289925 0.521427 0.282951 0.503955 0 0 0 0.00281905 l
+0.289925 0.521427 0.303326 0.535783 0 0 0 0.00281905 l
+0.315179 -0.232908 0.310899 -0.222854 0 0 0 0.00281905 l
+0.315179 -0.232908 0.304374 -0.242745 0 0 0 0.00281905 l
+-0.911831 0.382237 -0.903453 0.401688 0 0 0 0.00281905 l
+-0.911831 0.382237 -0.91657 0.37069 0 0 0 0.00281905 l
+0.524114 0.638491 0.528491 0.646506 0 0 0 0.00281905 l
+0.524114 0.638491 0.514049 0.641165 0 0 0 0.00281905 l
+-0.0649715 0.088478 -0.0491823 0.0782104 0 0 0 0.00281905 l
+-0.446524 -0.618343 -0.449711 -0.622759 0 0 0 0.00281905 l
+0.413299 -0.415955 0.410947 -0.396509 0 0 0 0.00281905 l
+0.413299 -0.415955 0.412501 -0.426253 0 0 0 0.00281905 l
+0.413299 -0.415955 0.393648 -0.416764 0 0 0 0.00281905 l
+0.43207 -0.301807 0.439087 -0.291367 0 0 0 0.00281905 l
+0.43207 -0.301807 0.449576 -0.30718 0 0 0 0.00281905 l
+0.43207 -0.301807 0.431271 -0.306552 0 0 0 0.00281905 l
+0.43207 -0.301807 0.423263 -0.290453 0 0 0 0.00281905 l
+0.208647 -0.153415 0.214993 -0.16831 0 0 0 0.00281905 l
+0.208647 -0.153415 0.199764 -0.15863 0 0 0 0.00281905 l
+0.361662 0.257473 0.345347 0.251955 0 0 0 0.00281905 l
+0.092619 -0.319501 0.0948657 -0.320846 0 0 0 0.00281905 l
+0.244712 -0.624722 0.240344 -0.616847 0 0 0 0.00281905 l
+0.244712 -0.624722 0.235084 -0.630485 0 0 0 0.00281905 l
+-0.158568 -0.553845 -0.153619 -0.567161 0 0 0 0.00281905 l
+-0.158568 -0.553845 -0.17127 -0.560295 0 0 0 0.00281905 l
+0.299838 0.16681 0.313327 0.153464 0 0 0 0.00281905 l
+0.299838 0.16681 0.318511 0.177408 0 0 0 0.00281905 l
+0.299838 0.16681 0.290084 0.166936 0 0 0 0.00281905 l
+-0.562325 -0.349989 -0.560174 -0.362305 0 0 0 0.00281905 l
+-0.562325 -0.349989 -0.576346 -0.353756 0 0 0 0.00281905 l
+0.572972 -0.759721 0.569329 -0.776701 0 0 0 0.00281905 l
+0.499145 -0.770283 0.520544 -0.758228 0 0 0 0.00281905 l
+0.320783 -0.76126 0.328071 -0.758685 0 0 0 0.00281905 l
+0.320783 -0.76126 0.306613 -0.757377 0 0 0 0.00281905 l
+-0.0852581 0.683158 -0.072485 0.681238 0 0 0 0.00281905 l
+-0.0852581 0.683158 -0.0816758 0.693981 0 0 0 0.00281905 l
+-0.0852581 0.683158 -0.0932397 0.680809 0 0 0 0.00281905 l
+0.910972 0.240045 0.925179 0.23994 0 0 0 0.00281905 l
+0.910972 0.240045 0.906446 0.227343 0 0 0 0.00281905 l
+0.172469 -0.599028 0.179947 -0.605546 0 0 0 0.00281905 l
+-0.366505 0.758772 -0.365713 0.758606 0 0 0 0.00281905 l
+-0.366505 0.758772 -0.372898 0.759246 0 0 0 0.00281905 l
+-0.105974 0.154572 -0.0865204 0.142866 0 0 0 0.00281905 l
+-0.105974 0.154572 -0.113051 0.159741 0 0 0 0.00281905 l
+0.832199 -0.134654 0.846629 -0.148259 0 0 0 0.00281905 l
+0.832199 -0.134654 0.826186 -0.142027 0 0 0 0.00281905 l
+-0.538745 -0.703241 -0.524959 -0.702304 0 0 0 0.00281905 l
+-0.538745 -0.703241 -0.533031 -0.717465 0 0 0 0.00281905 l
+-0.538745 -0.703241 -0.558519 -0.707002 0 0 0 0.00281905 l
+0.382146 -0.72275 0.392914 -0.719115 0 0 0 0.00281905 l
+0.382146 -0.72275 0.364991 -0.71375 0 0 0 0.00281905 l
+0.382146 -0.72275 0.37511 -0.730826 0 0 0 0.00281905 l
+-0.178422 0.834705 -0.165026 0.83301 0 0 0 0.00281905 l
+-0.178422 0.834705 -0.179799 0.83765 0 0 0 0.00281905 l
+-0.174763 -0.76427 -0.171721 -0.760454 0 0 0 0.00281905 l
+-0.174763 -0.76427 -0.179275 -0.758231 0 0 0 0.00281905 l
+-0.0390996 -0.165077 -0.032921 -0.17657 0 0 0 0.00281905 l
+-0.0390996 -0.165077 -0.0255413 -0.157513 0 0 0 0.00281905 l
+0.232145 0.0366373 0.235979 0.0300127 0 0 0 0.00281905 l
+0.232145 0.0366373 0.217524 0.0312718 0 0 0 0.00281905 l
+0.408128 0.738103 0.408865 0.747206 0 0 0 0.00281905 l
+0.408128 0.738103 0.417409 0.731866 0 0 0 0.00281905 l
+0.772144 -0.235277 0.787619 -0.221794 0 0 0 0.00281905 l
+0.772144 -0.235277 0.778193 -0.241115 0 0 0 0.00281905 l
+0.772144 -0.235277 0.756201 -0.231063 0 0 0 0.00281905 l
+-0.869612 -0.14352 -0.869808 -0.152129 0 0 0 0.00281905 l
+-0.64946 0.70493 -0.649996 0.684267 0 0 0 0.00281905 l
+-0.64946 0.70493 -0.648726 0.709793 0 0 0 0.00281905 l
+-0.64946 0.70493 -0.659869 0.705292 0 0 0 0.00281905 l
+-0.0921426 0.228197 -0.105869 0.242085 0 0 0 0.00281905 l
+-0.0921426 0.228197 -0.0981035 0.223023 0 0 0 0.00281905 l
+0.76524 0.514898 0.767425 0.514169 0 0 0 0.00281905 l
+0.76524 0.514898 0.761372 0.522257 0 0 0 0.00281905 l
+0.63914 0.524161 0.651015 0.524361 0 0 0 0.00281905 l
+-0.834587 0.348122 -0.846658 0.331692 0 0 0 0.00281905 l
+-0.294095 -0.665844 -0.284258 -0.64961 0 0 0 0.00281905 l
+-0.294095 -0.665844 -0.300275 -0.67061 0 0 0 0.00281905 l
+0.780185 -0.161666 0.775095 -0.150382 0 0 0 0.00281905 l
+0.780185 -0.161666 0.799716 -0.165844 0 0 0 0.00281905 l
+0.780185 -0.161666 0.779243 -0.173526 0 0 0 0.00281905 l
+-0.693321 0.522506 -0.68901 0.504591 0 0 0 0.00281905 l
+-0.693321 0.522506 -0.712549 0.524929 0 0 0 0.00281905 l
+0.532283 0.791445 0.532383 0.784706 0 0 0 0.00281905 l
+-0.675665 0.314913 -0.673744 0.295588 0 0 0 0.00281905 l
+0.274923 0.580393 0.288773 0.579193 0 0 0 0.00281905 l
+0.274923 0.580393 0.272089 0.567396 0 0 0 0.00281905 l
+0.794579 -0.593387 0.791465 -0.575392 0 0 0 0.00281905 l
+0.794579 -0.593387 0.781693 -0.59491 0 0 0 0.00281905 l
+0.670672 0.252784 0.687278 0.2497 0 0 0 0.00281905 l
+0.670672 0.252784 0.657387 0.247274 0 0 0 0.00281905 l
+0.571925 -0.0598065 0.580161 -0.064904 0 0 0 0.00281905 l
+0.571925 -0.0598065 0.569116 -0.0669796 0 0 0 0.00281905 l
+0.571925 -0.0598065 0.554193 -0.0519775 0 0 0 0.00281905 l
+-0.0216321 0.13088 -0.0230276 0.112986 0 0 0 0.00281905 l
+-0.0216321 0.13088 -0.0270269 0.132542 0 0 0 0.00281905 l
+0.615717 -0.163799 0.615995 -0.152334 0 0 0 0.00281905 l
+0.615717 -0.163799 0.628479 -0.164132 0 0 0 0.00281905 l
+0.615717 -0.163799 0.608427 -0.175089 0 0 0 0.00281905 l
+-0.151414 0.926282 -0.146857 0.930381 0 0 0 0.00281905 l
+-0.151414 0.926282 -0.149146 0.910903 0 0 0 0.00281905 l
+-0.273139 0.0770537 -0.272049 0.0696736 0 0 0 0.00281905 l
+-0.273139 0.0770537 -0.279879 0.0818276 0 0 0 0.00281905 l
+-0.141021 0.433607 -0.140204 0.428698 0 0 0 0.00281905 l
+-0.141021 0.433607 -0.117375 0.442541 0 0 0 0.00281905 l
+-0.141021 0.433607 -0.149714 0.441138 0 0 0 0.00281905 l
+-0.276917 -0.693119 -0.274911 -0.697169 0 0 0 0.00281905 l
+-0.276917 -0.693119 -0.281536 -0.693696 0 0 0 0.00281905 l
+0.28928 -0.608556 0.28701 -0.621005 0 0 0 0.00281905 l
+0.28928 -0.608556 0.287032 -0.600744 0 0 0 0.00281905 l
+0.240585 0.944203 0.246645 0.960911 0 0 0 0.00281905 l
+0.240585 0.944203 0.235904 0.940493 0 0 0 0.00281905 l
+0.707428 0.678021 0.718407 0.672556 0 0 0 0.00281905 l
+-0.65288 -0.35266 -0.648194 -0.354452 0 0 0 0.00281905 l
+-0.65288 -0.35266 -0.658252 -0.351221 0 0 0 0.00281905 l
+-0.624586 -0.516549 -0.617783 -0.519125 0 0 0 0.00281905 l
+-0.624586 -0.516549 -0.642496 -0.521418 0 0 0 0.00281905 l
+-0.0387187 0.18083 -0.0316137 0.192832 0 0 0 0.00281905 l
+-0.0387187 0.18083 -0.0325896 0.173567 0 0 0 0.00281905 l
+-0.0387187 0.18083 -0.0523878 0.175596 0 0 0 0.00281905 l
+0.968601 -0.194581 0.975726 -0.180076 0 0 0 0.00281905 l
+0.968601 -0.194581 0.976975 -0.199873 0 0 0 0.00281905 l
+0.968601 -0.194581 0.957907 -0.202052 0 0 0 0.00281905 l
+0.0383029 0.728525 0.0306926 0.717781 0 0 0 0.00281905 l
+0.0383029 0.728525 0.0363339 0.730477 0 0 0 0.00281905 l
+0.354162 0.691544 0.360494 0.683981 0 0 0 0.00281905 l
+0.354162 0.691544 0.344487 0.696933 0 0 0 0.00281905 l
+0.612416 -0.589655 0.611803 -0.595518 0 0 0 0.00281905 l
+0.609127 0.613332 0.617278 0.611755 0 0 0 0.00281905 l
+0.609127 0.613332 0.596494 0.613743 0 0 0 0.00281905 l
+0.318511 0.177408 0.31941 0.185827 0 0 0 0.00281905 l
+0.318511 0.177408 0.299838 0.16681 0 0 0 0.00281905 l
+0.868657 0.168724 0.862521 0.176256 0 0 0 0.00281905 l
+-0.686988 -0.668569 -0.686955 -0.66353 0 0 0 0.00281905 l
+-0.686988 -0.668569 -0.697592 -0.685289 0 0 0 0.00281905 l
+0.507275 -0.516024 0.51367 -0.505498 0 0 0 0.00281905 l
+0.507275 -0.516024 0.509774 -0.51912 0 0 0 0.00281905 l
+0.421202 0.0555981 0.417959 0.0667413 0 0 0 0.00281905 l
+0.421202 0.0555981 0.428101 0.0498465 0 0 0 0.00281905 l
+0.421202 0.0555981 0.410052 0.0557325 0 0 0 0.00281905 l
+0.0679373 -0.061666 0.0754555 -0.0743963 0 0 0 0.00281905 l
+0.0679373 -0.061666 0.0603862 -0.0743883 0 0 0 0.00281905 l
+0.907007 0.020923 0.910713 0.0296029 0 0 0 0.00281905 l
+0.907007 0.020923 0.913723 0.0158251 0 0 0 0.00281905 l
+0.907007 0.020923 0.900335 0.0165146 0 0 0 0.00281905 l
+-0.569683 -0.500035 -0.568277 -0.50445 0 0 0 0.00281905 l
+-0.569683 -0.500035 -0.562156 -0.491196 0 0 0 0.00281905 l
+0.759571 -0.157329 0.745363 -0.16276 0 0 0 0.00281905 l
+0.595664 0.589088 0.594736 0.600998 0 0 0 0.00281905 l
+-0.202923 -0.183163 -0.181919 -0.178761 0 0 0 0.00281905 l
+0.170843 -0.0841323 0.176014 -0.0790242 0 0 0 0.00281905 l
+0.451388 0.801407 0.454545 0.805971 0 0 0 0.00281905 l
+-0.655397 0.23101 -0.655883 0.239541 0 0 0 0.00281905 l
+-0.655397 0.23101 -0.663343 0.232292 0 0 0 0.00281905 l
+-0.441757 0.204619 -0.433085 0.201711 0 0 0 0.00281905 l
+-0.441757 0.204619 -0.445922 0.200022 0 0 0 0.00281905 l
+-0.441757 0.204619 -0.444975 0.208972 0 0 0 0.00281905 l
+0.286418 0.673668 0.279665 0.658522 0 0 0 0.00281905 l
+0.286418 0.673668 0.269082 0.672881 0 0 0 0.00281905 l
+0.935663 -0.201174 0.934655 -0.224693 0 0 0 0.00281905 l
+0.935663 -0.201174 0.933875 -0.1981 0 0 0 0.00281905 l
+0.144499 -0.4158 0.145092 -0.40749 0 0 0 0.00281905 l
+0.144499 -0.4158 0.143508 -0.416166 0 0 0 0.00281905 l
+0.866705 0.496424 0.87134 0.484348 0 0 0 0.00281905 l
+0.24186 -0.425128 0.244489 -0.441193 0 0 0 0.00281905 l
+0.24186 -0.425128 0.251835 -0.425419 0 0 0 0.00281905 l
+0.24186 -0.425128 0.231858 -0.420454 0 0 0 0.00281905 l
+-0.211322 0.564725 -0.220655 0.572396 0 0 0 0.00281905 l
+-0.211322 0.564725 -0.207844 0.567401 0 0 0 0.00281905 l
+-0.211322 0.564725 -0.212971 0.56137 0 0 0 0.00281905 l
+0.661283 0.653904 0.669726 0.650478 0 0 0 0.00281905 l
+0.661283 0.653904 0.653521 0.656916 0 0 0 0.00281905 l
+-0.577604 0.468427 -0.583892 0.466734 0 0 0 0.00281905 l
+-0.289992 0.252677 -0.286284 0.235084 0 0 0 0.00281905 l
+-0.694036 0.492748 -0.690615 0.487211 0 0 0 0.00281905 l
+-0.694036 0.492748 -0.699508 0.497745 0 0 0 0.00281905 l
+0.241306 0.0512469 0.240705 0.0346761 0 0 0 0.00281905 l
+0.150654 -0.697445 0.162467 -0.693333 0 0 0 0.00281905 l
+0.150654 -0.697445 0.140905 -0.696421 0 0 0 0.00281905 l
+0.833632 0.0782513 0.843985 0.0829162 0 0 0 0.00281905 l
+0.12317 -0.899219 0.130862 -0.896819 0 0 0 0.00281905 l
+0.947893 0.316158 0.947116 0.309452 0 0 0 0.00281905 l
+0.947893 0.316158 0.939788 0.320068 0 0 0 0.00281905 l
+0.948885 0.118758 0.953854 0.122269 0 0 0 0.00281905 l
+0.101717 -0.636056 0.10203 -0.630979 0 0 0 0.00281905 l
+0.101717 -0.636056 0.108529 -0.648492 0 0 0 0.00281905 l
+0.101717 -0.636056 0.0959863 -0.64181 0 0 0 0.00281905 l
+-0.535567 0.41255 -0.520343 0.418629 0 0 0 0.00281905 l
+-0.535567 0.41255 -0.541793 0.416075 0 0 0 0.00281905 l
+0.011818 -0.479346 0.00516181 -0.462174 0 0 0 0.00281905 l
+0.011818 -0.479346 0.0077785 -0.487754 0 0 0 0.00281905 l
+0.0169379 -0.675838 0.0209686 -0.671304 0 0 0 0.00281905 l
+0.0169379 -0.675838 0.015095 -0.680902 0 0 0 0.00281905 l
+-0.438136 0.531604 -0.42633 0.520648 0 0 0 0.00281905 l
+-0.438136 0.531604 -0.445777 0.542124 0 0 0 0.00281905 l
+-0.224217 0.362874 -0.21528 0.357488 0 0 0 0.00281905 l
+-0.224217 0.362874 -0.226435 0.356471 0 0 0 0.00281905 l
+-0.224217 0.362874 -0.22866 0.363155 0 0 0 0.00281905 l
+-0.488687 0.308278 -0.503319 0.324042 0 0 0 0.00281905 l
+-0.0343855 -0.96771 -0.0276785 -0.974424 0 0 0 0.00281905 l
+-0.0343855 -0.96771 -0.0438041 -0.957622 0 0 0 0.00281905 l
+-0.0343855 -0.96771 -0.0397814 -0.978229 0 0 0 0.00281905 l
+0.302011 -0.0717886 0.310962 -0.0655643 0 0 0 0.00281905 l
+-0.861399 -0.191507 -0.859756 -0.192855 0 0 0 0.00281905 l
+-0.861399 -0.191507 -0.854611 -0.184633 0 0 0 0.00281905 l
+-0.861399 -0.191507 -0.862027 -0.192096 0 0 0 0.00281905 l
+-0.256666 0.351629 -0.256081 0.357732 0 0 0 0.00281905 l
+-0.256666 0.351629 -0.250031 0.347192 0 0 0 0.00281905 l
+-0.256666 0.351629 -0.264415 0.337388 0 0 0 0.00281905 l
+-0.0291717 0.506193 -0.0283905 0.517849 0 0 0 0.00281905 l
+-0.0291717 0.506193 -0.0194127 0.495305 0 0 0 0.00281905 l
+-0.0291717 0.506193 -0.0440958 0.51218 0 0 0 0.00281905 l
+0.209964 0.270986 0.224107 0.249591 0 0 0 0.00281905 l
+0.209964 0.270986 0.209517 0.27459 0 0 0 0.00281905 l
+0.670279 0.0303594 0.674519 0.0421113 0 0 0 0.00281905 l
+0.670279 0.0303594 0.660314 0.0308069 0 0 0 0.00281905 l
+-0.143035 -0.623373 -0.138697 -0.638894 0 0 0 0.00281905 l
+-0.143035 -0.623373 -0.132163 -0.610069 0 0 0 0.00281905 l
+-0.143035 -0.623373 -0.157151 -0.618997 0 0 0 0.00281905 l
+0.24156 -0.83257 0.256423 -0.833626 0 0 0 0.00281905 l
+0.24156 -0.83257 0.232531 -0.825849 0 0 0 0.00281905 l
+0.90114 -0.168939 0.89353 -0.165311 0 0 0 0.00281905 l
+-0.463635 -0.71532 -0.471945 -0.715232 0 0 0 0.00281905 l
+0.535772 -0.186596 0.551792 -0.181033 0 0 0 0.00281905 l
+0.535772 -0.186596 0.515754 -0.178052 0 0 0 0.00281905 l
+0.0309108 -0.762964 0.0367495 -0.773698 0 0 0 0.00281905 l
+0.0309108 -0.762964 0.0381628 -0.750854 0 0 0 0.00281905 l
+0.105928 -0.0944507 0.0901949 -0.107542 0 0 0 0.00281905 l
+-0.191785 0.159807 -0.185634 0.158499 0 0 0 0.00281905 l
+-0.191785 0.159807 -0.200992 0.16251 0 0 0 0.00281905 l
+-0.135389 -0.669415 -0.13721 -0.673133 0 0 0 0.00281905 l
+-0.107824 0.948275 -0.114746 0.940634 0 0 0 0.00281905 l
+-0.107824 0.948275 -0.0967306 0.944414 0 0 0 0.00281905 l
+-0.107824 0.948275 -0.114812 0.954159 0 0 0 0.00281905 l
+0.735149 -0.00368851 0.734103 -0.00515419 0 0 0 0.00281905 l
+-0.680053 0.393509 -0.66817 0.384922 0 0 0 0.00281905 l
+-0.680053 0.393509 -0.681529 0.400717 0 0 0 0.00281905 l
+-0.680053 0.393509 -0.686952 0.385728 0 0 0 0.00281905 l
+-0.75783 0.0358052 -0.753707 0.0335004 0 0 0 0.00281905 l
+-0.75783 0.0358052 -0.777844 0.0315275 0 0 0 0.00281905 l
+-0.75783 0.0358052 -0.75252 0.0444008 0 0 0 0.00281905 l
+0.261166 -0.145018 0.259045 -0.153383 0 0 0 0.00281905 l
+0.642361 -0.456546 0.636319 -0.458628 0 0 0 0.00281905 l
+0.174112 -0.736465 0.175755 -0.734076 0 0 0 0.00281905 l
+0.812903 -0.40835 0.825552 -0.415757 0 0 0 0.00281905 l
+0.812903 -0.40835 0.802546 -0.418406 0 0 0 0.00281905 l
+0.303308 0.771061 0.307862 0.770267 0 0 0 0.00281905 l
+0.303308 0.771061 0.298209 0.773204 0 0 0 0.00281905 l
+0.432853 0.475575 0.43761 0.470585 0 0 0 0.00281905 l
+0.432853 0.475575 0.42261 0.485865 0 0 0 0.00281905 l
+0.16686 0.592074 0.172734 0.583271 0 0 0 0.00281905 l
+0.16686 0.592074 0.169908 0.59707 0 0 0 0.00281905 l
+0.16686 0.592074 0.158087 0.587024 0 0 0 0.00281905 l
+0.0159871 -0.408132 0.0237127 -0.412763 0 0 0 0.00281905 l
+-0.861588 0.45668 -0.856821 0.437404 0 0 0 0.00281905 l
+-0.651856 0.248869 -0.651977 0.25292 0 0 0 0.00281905 l
+-0.651856 0.248869 -0.655883 0.239541 0 0 0 0.00281905 l
+0.00122309 -0.380146 -0.000836784 -0.388774 0 0 0 0.00281905 l
+0.00122309 -0.380146 0.00108654 -0.366223 0 0 0 0.00281905 l
+0.367502 -0.864417 0.371161 -0.852433 0 0 0 0.00281905 l
+0.367502 -0.864417 0.356198 -0.857124 0 0 0 0.00281905 l
+-0.196846 0.205775 -0.196771 0.209016 0 0 0 0.00281905 l
+-0.196846 0.205775 -0.207109 0.195611 0 0 0 0.00281905 l
+-0.132243 -0.395909 -0.13438 -0.40042 0 0 0 0.00281905 l
+-0.132243 -0.395909 -0.138074 -0.390706 0 0 0 0.00281905 l
+0.566852 0.012537 0.578823 -0.000852624 0 0 0 0.00281905 l
+0.566852 0.012537 0.57513 0.0312002 0 0 0 0.00281905 l
+0.836938 -0.337789 0.847489 -0.338987 0 0 0 0.00281905 l
+0.836938 -0.337789 0.836518 -0.340642 0 0 0 0.00281905 l
+0.141878 0.0287438 0.138076 0.0200819 0 0 0 0.00281905 l
+0.141878 0.0287438 0.157892 0.0372881 0 0 0 0.00281905 l
+-0.224068 0.90594 -0.217455 0.902435 0 0 0 0.00281905 l
+-0.224068 0.90594 -0.235964 0.901786 0 0 0 0.00281905 l
+-0.0310971 -0.0322101 -0.0339329 -0.0342905 0 0 0 0.00281905 l
+-0.0310971 -0.0322101 -0.028021 -0.0284747 0 0 0 0.00281905 l
+-0.250337 0.226757 -0.2488 0.225416 0 0 0 0.00281905 l
+0.546921 0.455187 0.544426 0.47173 0 0 0 0.00281905 l
+0.546921 0.455187 0.531514 0.446818 0 0 0 0.00281905 l
+0.82865 0.448759 0.823574 0.464183 0 0 0 0.00281905 l
+0.82865 0.448759 0.840238 0.457341 0 0 0 0.00281905 l
+0.82865 0.448759 0.822256 0.444326 0 0 0 0.00281905 l
+0.248608 0.579864 0.252656 0.591472 0 0 0 0.00281905 l
+0.248608 0.579864 0.242706 0.564914 0 0 0 0.00281905 l
+-0.603683 0.491128 -0.603949 0.475288 0 0 0 0.00281905 l
+-0.603683 0.491128 -0.606583 0.491628 0 0 0 0.00281905 l
+0.069408 0.368243 0.0775398 0.362226 0 0 0 0.00281905 l
+0.793837 0.122679 0.799205 0.112785 0 0 0 0.00281905 l
+0.793837 0.122679 0.789172 0.135122 0 0 0 0.00281905 l
+0.793837 0.122679 0.782655 0.121474 0 0 0 0.00281905 l
+0.342469 0.44431 0.357795 0.433505 0 0 0 0.00281905 l
+0.342469 0.44431 0.332855 0.435582 0 0 0 0.00281905 l
+0.342469 0.44431 0.342298 0.453467 0 0 0 0.00281905 l
+-0.35685 -0.788066 -0.348642 -0.795528 0 0 0 0.00281905 l
+-0.35685 -0.788066 -0.361679 -0.790909 0 0 0 0.00281905 l
+-0.35685 -0.788066 -0.355678 -0.786606 0 0 0 0.00281905 l
+-0.921847 0.00413317 -0.911816 0.00590096 0 0 0 0.00281905 l
+-0.921847 0.00413317 -0.930636 -0.00909486 0 0 0 0.00281905 l
+0.27974 0.327403 0.281665 0.322103 0 0 0 0.00281905 l
+0.288457 0.45939 0.30327 0.463279 0 0 0 0.00281905 l
+0.288457 0.45939 0.28927 0.44877 0 0 0 0.00281905 l
+0.0132464 -0.218145 0.0219938 -0.232118 0 0 0 0.00281905 l
+0.0132464 -0.218145 0.00567514 -0.221812 0 0 0 0.00281905 l
+0.610587 -0.260244 0.615475 -0.278579 0 0 0 0.00281905 l
+0.610587 -0.260244 0.620675 -0.254471 0 0 0 0.00281905 l
+0.276701 -0.129331 0.279965 -0.125 0 0 0 0.00281905 l
+0.276701 -0.129331 0.262242 -0.11541 0 0 0 0.00281905 l
+-0.704988 0.211542 -0.699777 0.221204 0 0 0 0.00281905 l
+-0.704988 0.211542 -0.717905 0.202244 0 0 0 0.00281905 l
+0.391432 -0.424896 0.393648 -0.416764 0 0 0 0.00281905 l
+0.391432 -0.424896 0.381433 -0.436474 0 0 0 0.00281905 l
+-0.55385 0.440143 -0.555642 0.432886 0 0 0 0.00281905 l
+0.461054 -0.587427 0.45813 -0.605 0 0 0 0.00281905 l
+0.461054 -0.587427 0.449588 -0.586252 0 0 0 0.00281905 l
+0.143508 -0.416166 0.148215 -0.432363 0 0 0 0.00281905 l
+0.143508 -0.416166 0.144499 -0.4158 0 0 0 0.00281905 l
+0.581726 -0.241461 0.570933 -0.225316 0 0 0 0.00281905 l
+0.922427 0.137022 0.928129 0.124578 0 0 0 0.00281905 l
+0.922427 0.137022 0.926581 0.138677 0 0 0 0.00281905 l
+-0.290325 0.102329 -0.281667 0.102973 0 0 0 0.00281905 l
+0.188555 -0.165142 0.199764 -0.15863 0 0 0 0.00281905 l
+0.188555 -0.165142 0.176916 -0.170433 0 0 0 0.00281905 l
+-0.0158779 -0.751366 -0.00993121 -0.773886 0 0 0 0.00281905 l
+-0.692994 0.475083 -0.690615 0.487211 0 0 0 0.00281905 l
+-0.692994 0.475083 -0.70077 0.471456 0 0 0 0.00281905 l
+0.667181 -0.392893 0.66741 -0.389189 0 0 0 0.00281905 l
+0.667181 -0.392893 0.666732 -0.402769 0 0 0 0.00281905 l
+0.107857 -0.531274 0.118823 -0.524215 0 0 0 0.00281905 l
+0.107857 -0.531274 0.096434 -0.521626 0 0 0 0.00281905 l
+0.612565 -0.0862837 0.629366 -0.0795694 0 0 0 0.00281905 l
+-0.541793 0.416075 -0.550855 0.423235 0 0 0 0.00281905 l
+-0.541793 0.416075 -0.535567 0.41255 0 0 0 0.00281905 l
+-0.541793 0.416075 -0.545165 0.412053 0 0 0 0.00281905 l
+0.602566 0.218646 0.605241 0.226937 0 0 0 0.00281905 l
+0.602566 0.218646 0.614082 0.202625 0 0 0 0.00281905 l
+0.132412 0.0884444 0.125166 0.100854 0 0 0 0.00281905 l
+0.132412 0.0884444 0.137469 0.0834567 0 0 0 0.00281905 l
+-0.507454 -0.574217 -0.490438 -0.58716 0 0 0 0.00281905 l
+-0.507454 -0.574217 -0.523121 -0.594687 0 0 0 0.00281905 l
+-0.507454 -0.574217 -0.514618 -0.557571 0 0 0 0.00281905 l
+0.437985 0.673761 0.449204 0.663069 0 0 0 0.00281905 l
+0.437985 0.673761 0.425751 0.670064 0 0 0 0.00281905 l
+-0.162468 0.553256 -0.159651 0.553139 0 0 0 0.00281905 l
+-0.109836 -0.798251 -0.106155 -0.796698 0 0 0 0.00281905 l
+-0.109836 -0.798251 -0.111745 -0.794424 0 0 0 0.00281905 l
+0.502249 0.0650232 0.495587 0.0888765 0 0 0 0.00281905 l
+0.502249 0.0650232 0.511754 0.0567113 0 0 0 0.00281905 l
+0.502249 0.0650232 0.485734 0.0600073 0 0 0 0.00281905 l
+-0.422496 -0.41745 -0.437845 -0.413323 0 0 0 0.00281905 l
+0.64137 0.692715 0.645934 0.682447 0 0 0 0.00281905 l
+0.64137 0.692715 0.658426 0.699548 0 0 0 0.00281905 l
+0.64137 0.692715 0.631204 0.700176 0 0 0 0.00281905 l
+0.640948 -0.620292 0.636358 -0.608404 0 0 0 0.00281905 l
+0.640948 -0.620292 0.650559 -0.626329 0 0 0 0.00281905 l
+0.640948 -0.620292 0.628552 -0.625134 0 0 0 0.00281905 l
+0.772971 -0.142863 0.775095 -0.150382 0 0 0 0.00281905 l
+0.772971 -0.142863 0.77191 -0.132156 0 0 0 0.00281905 l
+0.484444 0.624981 0.489531 0.625336 0 0 0 0.00281905 l
+0.484444 0.624981 0.470226 0.620232 0 0 0 0.00281905 l
+0.108529 -0.648492 0.115066 -0.640914 0 0 0 0.00281905 l
+0.108529 -0.648492 0.101717 -0.636056 0 0 0 0.00281905 l
+-0.0523878 0.175596 -0.0477335 0.162449 0 0 0 0.00281905 l
+-0.0523878 0.175596 -0.0387187 0.18083 0 0 0 0.00281905 l
+-0.0523878 0.175596 -0.0592845 0.186598 0 0 0 0.00281905 l
+0.234652 0.882828 0.227774 0.876363 0 0 0 0.00281905 l
+0.234652 0.882828 0.236441 0.890676 0 0 0 0.00281905 l
+-0.595482 -0.794517 -0.582977 -0.788475 0 0 0 0.00281905 l
+-0.595482 -0.794517 -0.59739 -0.794854 0 0 0 0.00281905 l
+-0.503052 0.583028 -0.507202 0.576196 0 0 0 0.00281905 l
+-0.503052 0.583028 -0.499086 0.586857 0 0 0 0.00281905 l
+0.833249 0.321357 0.825328 0.334405 0 0 0 0.00281905 l
+0.833249 0.321357 0.834697 0.319221 0 0 0 0.00281905 l
+0.152326 -0.326305 0.153545 -0.334367 0 0 0 0.00281905 l
+0.152326 -0.326305 0.159245 -0.322939 0 0 0 0.00281905 l
+-0.826418 -0.07227 -0.814929 -0.0600103 0 0 0 0.00281905 l
+-0.826418 -0.07227 -0.824154 -0.0750363 0 0 0 0.00281905 l
+-0.119307 0.410486 -0.113819 0.409876 0 0 0 0.00281905 l
+-0.170363 0.392419 -0.168937 0.395541 0 0 0 0.00281905 l
+0.388113 0.251337 0.413889 0.257699 0 0 0 0.00281905 l
+-0.501449 0.799788 -0.50464 0.79113 0 0 0 0.00281905 l
+0.302087 0.75823 0.301316 0.753025 0 0 0 0.00281905 l
+0.302087 0.75823 0.29728 0.764129 0 0 0 0.00281905 l
+-0.40063 -0.663096 -0.390618 -0.667773 0 0 0 0.00281905 l
+-0.40063 -0.663096 -0.394707 -0.656155 0 0 0 0.00281905 l
+-0.40063 -0.663096 -0.416139 -0.670006 0 0 0 0.00281905 l
+-0.26311 -0.096409 -0.254211 -0.0859868 0 0 0 0.00281905 l
+-0.26311 -0.096409 -0.266285 -0.104597 0 0 0 0.00281905 l
+-0.40049 0.510975 -0.395353 0.51913 0 0 0 0.00281905 l
+-0.40049 0.510975 -0.406518 0.51009 0 0 0 0.00281905 l
+0.0891225 -0.156749 0.087542 -0.146053 0 0 0 0.00281905 l
+0.0891225 -0.156749 0.0979584 -0.157264 0 0 0 0.00281905 l
+0.0891225 -0.156749 0.0792753 -0.163286 0 0 0 0.00281905 l
+-0.428635 0.621301 -0.435295 0.599677 0 0 0 0.00281905 l
+-0.428635 0.621301 -0.431504 0.635732 0 0 0 0.00281905 l
+-0.428635 0.621301 -0.421132 0.621589 0 0 0 0.00281905 l
+0.385491 0.815361 0.385682 0.827492 0 0 0 0.00281905 l
+0.385491 0.815361 0.39534 0.812216 0 0 0 0.00281905 l
+0.735806 0.63952 0.747157 0.646867 0 0 0 0.00281905 l
+0.735806 0.63952 0.728006 0.637086 0 0 0 0.00281905 l
+-0.542537 -0.647118 -0.535316 -0.637018 0 0 0 0.00281905 l
+-0.542537 -0.647118 -0.539032 -0.655267 0 0 0 0.00281905 l
+-0.462341 0.715359 -0.461259 0.730063 0 0 0 0.00281905 l
+-0.462341 0.715359 -0.442927 0.712748 0 0 0 0.00281905 l
+-0.462341 0.715359 -0.473991 0.718235 0 0 0 0.00281905 l
+-0.553714 -0.325577 -0.553755 -0.320361 0 0 0 0.00281905 l
+-0.553714 -0.325577 -0.56875 -0.325975 0 0 0 0.00281905 l
+-0.959271 0.110163 -0.965907 0.0985085 0 0 0 0.00281905 l
+-0.959271 0.110163 -0.959577 0.112197 0 0 0 0.00281905 l
+-0.0690446 -0.734171 -0.0541525 -0.720993 0 0 0 0.00281905 l
+-0.0690446 -0.734171 -0.0794952 -0.738284 0 0 0 0.00281905 l
+-0.293801 0.179938 -0.305969 0.160879 0 0 0 0.00281905 l
+-0.293801 0.179938 -0.308068 0.190053 0 0 0 0.00281905 l
+0.247063 -0.931912 0.254885 -0.94739 0 0 0 0.00281905 l
+0.247063 -0.931912 0.250663 -0.925477 0 0 0 0.00281905 l
+0.509356 -0.0980577 0.519092 -0.08444 0 0 0 0.00281905 l
+0.220044 -0.904858 0.224085 -0.917313 0 0 0 0.00281905 l
+0.220044 -0.904858 0.206273 -0.907022 0 0 0 0.00281905 l
+0.407429 -0.378927 0.41265 -0.390204 0 0 0 0.00281905 l
+0.407429 -0.378927 0.396719 -0.378362 0 0 0 0.00281905 l
+0.0291488 0.113412 0.0348004 0.108034 0 0 0 0.00281905 l
+0.0291488 0.113412 0.0175271 0.111767 0 0 0 0.00281905 l
+0.0291488 0.113412 0.0300703 0.115839 0 0 0 0.00281905 l
+0.0119631 0.109488 0.0113524 0.11654 0 0 0 0.00281905 l
+0.0119631 0.109488 0.0175271 0.111767 0 0 0 0.00281905 l
+0.641838 -0.15107 0.657388 -0.145855 0 0 0 0.00281905 l
+-0.737135 0.125423 -0.73385 0.115349 0 0 0 0.00281905 l
+-0.737135 0.125423 -0.726461 0.133977 0 0 0 0.00281905 l
+0.298184 -0.160836 0.298008 -0.151425 0 0 0 0.00281905 l
+0.298184 -0.160836 0.296763 -0.161112 0 0 0 0.00281905 l
+-0.873852 0.340371 -0.886908 0.330936 0 0 0 0.00281905 l
+0.675198 -0.463127 0.681718 -0.444874 0 0 0 0.00281905 l
+0.675198 -0.463127 0.678419 -0.469666 0 0 0 0.00281905 l
+0.813004 -0.0601676 0.826492 -0.056076 0 0 0 0.00281905 l
+0.813004 -0.0601676 0.810892 -0.0688945 0 0 0 0.00281905 l
+0.368136 -0.775439 0.372214 -0.755705 0 0 0 0.00281905 l
+0.368136 -0.775439 0.355891 -0.769312 0 0 0 0.00281905 l
+0.303326 0.535783 0.304837 0.554532 0 0 0 0.00281905 l
+0.303326 0.535783 0.313265 0.525326 0 0 0 0.00281905 l
+0.303326 0.535783 0.289925 0.521427 0 0 0 0.00281905 l
+-0.20847 -0.782232 -0.214146 -0.78334 0 0 0 0.00281905 l
+0.14729 -0.617873 0.148044 -0.633498 0 0 0 0.00281905 l
+0.14729 -0.617873 0.160046 -0.616527 0 0 0 0.00281905 l
+0.14729 -0.617873 0.136678 -0.618677 0 0 0 0.00281905 l
+0.4234 0.377135 0.417965 0.387219 0 0 0 0.00281905 l
+0.4234 0.377135 0.428984 0.380111 0 0 0 0.00281905 l
+-0.658986 -0.646237 -0.665185 -0.626528 0 0 0 0.00281905 l
+0.507178 -0.132945 0.50893 -0.13706 0 0 0 0.00281905 l
+0.507178 -0.132945 0.511709 -0.125709 0 0 0 0.00281905 l
+0.507178 -0.132945 0.495084 -0.129123 0 0 0 0.00281905 l
+-0.389957 -0.413067 -0.397138 -0.433001 0 0 0 0.00281905 l
+-0.389957 -0.413067 -0.391737 -0.408452 0 0 0 0.00281905 l
+0.340887 -0.487122 0.336109 -0.479036 0 0 0 0.00281905 l
+0.573743 0.176833 0.572665 0.169357 0 0 0 0.00281905 l
+0.573743 0.176833 0.581534 0.186327 0 0 0 0.00281905 l
+0.573743 0.176833 0.562442 0.179657 0 0 0 0.00281905 l
+-0.718187 0.285248 -0.725539 0.271048 0 0 0 0.00281905 l
+-0.718187 0.285248 -0.709962 0.288404 0 0 0 0.00281905 l
+0.40394 -0.313381 0.407732 -0.297409 0 0 0 0.00281905 l
+0.40394 -0.313381 0.416404 -0.315134 0 0 0 0.00281905 l
+0.40394 -0.313381 0.401051 -0.314124 0 0 0 0.00281905 l
+-0.235995 0.330701 -0.234539 0.335661 0 0 0 0.00281905 l
+0.196083 0.889086 0.208441 0.88741 0 0 0 0.00281905 l
+0.196083 0.889086 0.186631 0.890063 0 0 0 0.00281905 l
+-0.550582 0.651462 -0.552574 0.664521 0 0 0 0.00281905 l
+-0.550582 0.651462 -0.544495 0.652729 0 0 0 0.00281905 l
+-0.550582 0.651462 -0.554119 0.646277 0 0 0 0.00281905 l
+-0.471945 -0.715232 -0.47511 -0.734888 0 0 0 0.00281905 l
+-0.471945 -0.715232 -0.473648 -0.706399 0 0 0 0.00281905 l
+-0.471945 -0.715232 -0.463635 -0.71532 0 0 0 0.00281905 l
+0.389143 -0.231633 0.391458 -0.233928 0 0 0 0.00281905 l
+0.389143 -0.231633 0.377996 -0.232162 0 0 0 0.00281905 l
+0.353336 -0.403986 0.353145 -0.414197 0 0 0 0.00281905 l
+0.332547 0.806151 0.341279 0.789628 0 0 0 0.00281905 l
+0.332547 0.806151 0.321377 0.796803 0 0 0 0.00281905 l
+0.362232 -0.168432 0.357808 -0.156312 0 0 0 0.00281905 l
+0.362232 -0.168432 0.370282 -0.171548 0 0 0 0.00281905 l
+0.362232 -0.168432 0.358946 -0.176598 0 0 0 0.00281905 l
+-0.273936 -0.287637 -0.26811 -0.282987 0 0 0 0.00281905 l
+-0.143542 -0.871417 -0.140269 -0.8851 0 0 0 0.00281905 l
+-0.143542 -0.871417 -0.149135 -0.85928 0 0 0 0.00281905 l
+-0.64613 0.374128 -0.646701 0.365267 0 0 0 0.00281905 l
+-0.64613 0.374128 -0.653576 0.374083 0 0 0 0.00281905 l
+-0.736173 0.602223 -0.734669 0.593889 0 0 0 0.00281905 l
+-0.736173 0.602223 -0.715659 0.606144 0 0 0 0.00281905 l
+-0.0768317 -0.86137 -0.0807489 -0.869869 0 0 0 0.00281905 l
+-0.469455 -0.756369 -0.473713 -0.740404 0 0 0 0.00281905 l
+-0.469455 -0.756369 -0.487309 -0.757779 0 0 0 0.00281905 l
+-0.300767 -0.352311 -0.290468 -0.346537 0 0 0 0.00281905 l
+-0.300767 -0.352311 -0.315018 -0.360102 0 0 0 0.00281905 l
+-0.0794213 0.0295471 -0.0886712 0.0317118 0 0 0 0.00281905 l
+-0.0794213 0.0295471 -0.0768803 0.0338433 0 0 0 0.00281905 l
+0.578227 0.0426273 0.579974 0.0374239 0 0 0 0.00281905 l
+0.578227 0.0426273 0.591329 0.0470849 0 0 0 0.00281905 l
+0.578227 0.0426273 0.574973 0.0444442 0 0 0 0.00281905 l
+-0.882045 0.311342 -0.890016 0.325201 0 0 0 0.00281905 l
+-0.882045 0.311342 -0.881631 0.303183 0 0 0 0.00281905 l
+-0.0810374 -0.872727 -0.077995 -0.885597 0 0 0 0.00281905 l
+-0.0810374 -0.872727 -0.0807489 -0.869869 0 0 0 0.00281905 l
+-0.0810374 -0.872727 -0.0915908 -0.879075 0 0 0 0.00281905 l
+0.0777288 0.746287 0.0924507 0.749409 0 0 0 0.00281905 l
+0.0777288 0.746287 0.0716402 0.747798 0 0 0 0.00281905 l
+-0.70582 -0.0128947 -0.696059 -0.0329919 0 0 0 0.00281905 l
+-0.70582 -0.0128947 -0.726458 -0.00793686 0 0 0 0.00281905 l
+0.865791 -0.281962 0.864427 -0.293363 0 0 0 0.00281905 l
+0.865791 -0.281962 0.863974 -0.278111 0 0 0 0.00281905 l
+-0.525805 0.0876112 -0.515668 0.0836378 0 0 0 0.00281905 l
+-0.525805 0.0876112 -0.530149 0.0859213 0 0 0 0.00281905 l
+-0.500667 -0.735888 -0.507112 -0.738336 0 0 0 0.00281905 l
+-0.151023 0.601076 -0.138398 0.588028 0 0 0 0.00281905 l
+-0.151023 0.601076 -0.156945 0.61109 0 0 0 0.00281905 l
+-0.844515 0.28625 -0.833396 0.29143 0 0 0 0.00281905 l
+0.0504747 -0.486319 0.0542115 -0.471754 0 0 0 0.00281905 l
+0.0504747 -0.486319 0.0388771 -0.486795 0 0 0 0.00281905 l
+-0.0820827 -0.671559 -0.078388 -0.673363 0 0 0 0.00281905 l
+-0.0820827 -0.671559 -0.0894777 -0.669489 0 0 0 0.00281905 l
+-0.64448 0.602419 -0.641306 0.607614 0 0 0 0.00281905 l
+-0.64448 0.602419 -0.635834 0.600135 0 0 0 0.00281905 l
+-0.64448 0.602419 -0.644626 0.594498 0 0 0 0.00281905 l
+-0.243632 0.630976 -0.257138 0.614416 0 0 0 0.00281905 l
+-0.243632 0.630976 -0.24767 0.635012 0 0 0 0.00281905 l
+-0.121438 -0.249671 -0.120579 -0.247396 0 0 0 0.00281905 l
+-0.121438 -0.249671 -0.132623 -0.247644 0 0 0 0.00281905 l
+0.155286 0.33951 0.159206 0.337621 0 0 0 0.00281905 l
+0.155286 0.33951 0.151382 0.336017 0 0 0 0.00281905 l
+-0.119089 -0.5204 -0.100216 -0.514579 0 0 0 0.00281905 l
+-0.119089 -0.5204 -0.133424 -0.504989 0 0 0 0.00281905 l
+-0.854611 -0.184633 -0.848672 -0.188976 0 0 0 0.00281905 l
+-0.854611 -0.184633 -0.850534 -0.17631 0 0 0 0.00281905 l
+-0.854611 -0.184633 -0.861399 -0.191507 0 0 0 0.00281905 l
+0.157663 -0.143199 0.15884 -0.1539 0 0 0 0.00281905 l
+0.157663 -0.143199 0.144566 -0.128166 0 0 0 0.00281905 l
+0.120706 -0.499668 0.128444 -0.483237 0 0 0 0.00281905 l
+0.120706 -0.499668 0.119924 -0.515741 0 0 0 0.00281905 l
+0.120706 -0.499668 0.107883 -0.499038 0 0 0 0.00281905 l
+0.767743 -0.516798 0.780572 -0.529739 0 0 0 0.00281905 l
+0.767743 -0.516798 0.767458 -0.512872 0 0 0 0.00281905 l
+-0.519543 -0.751565 -0.528827 -0.740871 0 0 0 0.00281905 l
+-0.519543 -0.751565 -0.514247 -0.753812 0 0 0 0.00281905 l
+-0.519543 -0.751565 -0.533195 -0.759963 0 0 0 0.00281905 l
+0.254677 -0.708516 0.240494 -0.721937 0 0 0 0.00281905 l
+0.254677 -0.708516 0.255052 -0.706085 0 0 0 0.00281905 l
+0.237639 -0.75135 0.236629 -0.747023 0 0 0 0.00281905 l
+0.237639 -0.75135 0.240788 -0.754287 0 0 0 0.00281905 l
+0.237639 -0.75135 0.233137 -0.755956 0 0 0 0.00281905 l
+-0.058065 -0.763148 -0.0528354 -0.765145 0 0 0 0.00281905 l
+0.732715 -0.00948405 0.734103 -0.00515419 0 0 0 0.00281905 l
+0.732715 -0.00948405 0.726658 -0.0106861 0 0 0 0.00281905 l
+-0.705015 0.578656 -0.717656 0.573317 0 0 0 0.00281905 l
+-0.705015 0.578656 -0.708834 0.584134 0 0 0 0.00281905 l
+-0.760521 0.261933 -0.760269 0.269954 0 0 0 0.00281905 l
+-0.400205 0.205982 -0.393938 0.189907 0 0 0 0.00281905 l
+-0.400205 0.205982 -0.416736 0.210163 0 0 0 0.00281905 l
+0.0875798 -0.229611 0.0846135 -0.238621 0 0 0 0.00281905 l
+0.0875798 -0.229611 0.0839629 -0.227123 0 0 0 0.00281905 l
+0.0306661 0.172097 0.0301894 0.168643 0 0 0 0.00281905 l
+0.0306661 0.172097 0.0173259 0.179161 0 0 0 0.00281905 l
+0.332066 -0.213717 0.344723 -0.218604 0 0 0 0.00281905 l
+0.332066 -0.213717 0.326493 -0.210343 0 0 0 0.00281905 l
+-0.339107 0.451063 -0.317893 0.449859 0 0 0 0.00281905 l
+-0.339107 0.451063 -0.358628 0.457152 0 0 0 0.00281905 l
+-0.18317 -0.300343 -0.188668 -0.28913 0 0 0 0.00281905 l
+-0.18317 -0.300343 -0.200119 -0.305648 0 0 0 0.00281905 l
+-0.666978 -0.27837 -0.668449 -0.29223 0 0 0 0.00281905 l
+-0.666978 -0.27837 -0.656864 -0.271333 0 0 0 0.00281905 l
+-0.666978 -0.27837 -0.670845 -0.275805 0 0 0 0.00281905 l
+0.0623154 -0.532317 0.077044 -0.539368 0 0 0 0.00281905 l
+0.0623154 -0.532317 0.0535707 -0.531069 0 0 0 0.00281905 l
+0.224085 -0.917313 0.220044 -0.904858 0 0 0 0.00281905 l
+0.876485 0.356104 0.881109 0.35713 0 0 0 0.00281905 l
+0.876485 0.356104 0.863235 0.354437 0 0 0 0.00281905 l
+0.465672 -0.777935 0.480863 -0.793543 0 0 0 0.00281905 l
+0.465672 -0.777935 0.46332 -0.773569 0 0 0 0.00281905 l
+0.554567 0.598977 0.544399 0.58672 0 0 0 0.00281905 l
+0.554567 0.598977 0.565714 0.599313 0 0 0 0.00281905 l
+0.554567 0.598977 0.543998 0.604238 0 0 0 0.00281905 l
+0.187225 0.881743 0.186631 0.890063 0 0 0 0.00281905 l
+0.187225 0.881743 0.174278 0.869106 0 0 0 0.00281905 l
+-0.13721 -0.673133 -0.135389 -0.669415 0 0 0 0.00281905 l
+-0.13721 -0.673133 -0.129235 -0.68322 0 0 0 0.00281905 l
+-0.13721 -0.673133 -0.140041 -0.673035 0 0 0 0.00281905 l
+0.109723 -0.771143 0.109971 -0.777669 0 0 0 0.00281905 l
+0.109723 -0.771143 0.0984956 -0.768258 0 0 0 0.00281905 l
+0.756375 -0.649583 0.751082 -0.649217 0 0 0 0.00281905 l
+-0.665185 -0.626528 -0.658986 -0.646237 0 0 0 0.00281905 l
+-0.665185 -0.626528 -0.656992 -0.619102 0 0 0 0.00281905 l
+0.419586 -0.55775 0.417974 -0.551933 0 0 0 0.00281905 l
+0.419586 -0.55775 0.435036 -0.564171 0 0 0 0.00281905 l
+0.419586 -0.55775 0.411817 -0.566864 0 0 0 0.00281905 l
+0.28555 -0.158284 0.296763 -0.161112 0 0 0 0.00281905 l
+0.28555 -0.158284 0.286321 -0.173822 0 0 0 0.00281905 l
+-0.630639 -0.655819 -0.639332 -0.637713 0 0 0 0.00281905 l
+-0.630639 -0.655819 -0.617366 -0.664786 0 0 0 0.00281905 l
+-0.152452 0.45461 -0.150038 0.474274 0 0 0 0.00281905 l
+-0.152452 0.45461 -0.157383 0.442484 0 0 0 0.00281905 l
+-0.325877 -0.424008 -0.323512 -0.421395 0 0 0 0.00281905 l
+-0.414765 0.86798 -0.411067 0.857224 0 0 0 0.00281905 l
+-0.414765 0.86798 -0.408127 0.871623 0 0 0 0.00281905 l
+0.580269 -0.443817 0.585116 -0.429371 0 0 0 0.00281905 l
+0.580269 -0.443817 0.567632 -0.443996 0 0 0 0.00281905 l
+0.269152 0.452817 0.27265 0.44452 0 0 0 0.00281905 l
+0.269152 0.452817 0.265032 0.45553 0 0 0 0.00281905 l
+0.205715 -0.555007 0.187485 -0.565075 0 0 0 0.00281905 l
+0.205715 -0.555007 0.201439 -0.547354 0 0 0 0.00281905 l
+-0.948423 -0.284737 -0.940393 -0.288881 0 0 0 0.00281905 l
+-0.227962 0.343461 -0.226435 0.356471 0 0 0 0.00281905 l
+-0.227962 0.343461 -0.234539 0.335661 0 0 0 0.00281905 l
+0.30327 0.463279 0.323403 0.468251 0 0 0 0.00281905 l
+0.30327 0.463279 0.288457 0.45939 0 0 0 0.00281905 l
+0.208441 0.88741 0.20888 0.896361 0 0 0 0.00281905 l
+0.208441 0.88741 0.196083 0.889086 0 0 0 0.00281905 l
+0.435976 0.151947 0.439543 0.156688 0 0 0 0.00281905 l
+0.435976 0.151947 0.436423 0.1496 0 0 0 0.00281905 l
+0.0239016 0.477041 0.0238336 0.480065 0 0 0 0.00281905 l
+0.0239016 0.477041 0.0414407 0.475033 0 0 0 0.00281905 l
+-0.18939 0.759133 -0.19007 0.749104 0 0 0 0.00281905 l
+-0.18939 0.759133 -0.197985 0.759121 0 0 0 0.00281905 l
+0.224383 0.210693 0.219849 0.204669 0 0 0 0.00281905 l
+0.104636 -0.420277 0.113204 -0.417105 0 0 0 0.00281905 l
+0.104636 -0.420277 0.100478 -0.42071 0 0 0 0.00281905 l
+0.625174 0.105729 0.640516 0.097134 0 0 0 0.00281905 l
+0.625174 0.105729 0.613139 0.107505 0 0 0 0.00281905 l
+0.535091 0.401764 0.542652 0.384133 0 0 0 0.00281905 l
+0.535091 0.401764 0.5297 0.401636 0 0 0 0.00281905 l
+-0.84803 -0.331353 -0.853355 -0.327329 0 0 0 0.00281905 l
+-0.259803 -0.189353 -0.267029 -0.190615 0 0 0 0.00281905 l
+-0.23291 0.545206 -0.22559 0.545963 0 0 0 0.00281905 l
+-0.23291 0.545206 -0.245 0.550204 0 0 0 0.00281905 l
+-0.8608 0.387165 -0.862234 0.396472 0 0 0 0.00281905 l
+-0.8608 0.387165 -0.850108 0.391883 0 0 0 0.00281905 l
+-0.8608 0.387165 -0.854265 0.380865 0 0 0 0.00281905 l
+-0.8608 0.387165 -0.86572 0.37585 0 0 0 0.00281905 l
+0.158524 -0.663338 0.165113 -0.67199 0 0 0 0.00281905 l
+0.158524 -0.663338 0.162414 -0.657951 0 0 0 0.00281905 l
+-0.315018 -0.360102 -0.300767 -0.352311 0 0 0 0.00281905 l
+-0.315018 -0.360102 -0.322736 -0.361179 0 0 0 0.00281905 l
+-0.515668 0.0836378 -0.50933 0.0862189 0 0 0 0.00281905 l
+-0.515668 0.0836378 -0.525805 0.0876112 0 0 0 0.00281905 l
+-0.552082 0.511686 -0.544548 0.510971 0 0 0 0.00281905 l
+-0.552082 0.511686 -0.569358 0.506199 0 0 0 0.00281905 l
+0.365008 -0.501858 0.351643 -0.522316 0 0 0 0.00281905 l
+0.365008 -0.501858 0.371997 -0.495545 0 0 0 0.00281905 l
+-0.120663 -0.342988 -0.118857 -0.330398 0 0 0 0.00281905 l
+-0.120663 -0.342988 -0.135481 -0.339244 0 0 0 0.00281905 l
+0.222221 0.382532 0.223221 0.386072 0 0 0 0.00281905 l
+0.222221 0.382532 0.203481 0.374195 0 0 0 0.00281905 l
+0.087542 -0.146053 0.0891225 -0.156749 0 0 0 0.00281905 l
+0.087542 -0.146053 0.07846 -0.145534 0 0 0 0.00281905 l
+-0.434929 0.325732 -0.423494 0.330223 0 0 0 0.00281905 l
+-0.434929 0.325732 -0.444111 0.338088 0 0 0 0.00281905 l
+-0.434929 0.325732 -0.436562 0.322416 0 0 0 0.00281905 l
+0.148657 -0.463137 0.146779 -0.475542 0 0 0 0.00281905 l
+0.148657 -0.463137 0.149206 -0.45946 0 0 0 0.00281905 l
+0.867832 -0.0802485 0.865456 -0.0911717 0 0 0 0.00281905 l
+0.899132 0.315069 0.903665 0.305051 0 0 0 0.00281905 l
+0.899132 0.315069 0.892377 0.314377 0 0 0 0.00281905 l
+0.899132 0.315069 0.903845 0.322358 0 0 0 0.00281905 l
+0.403211 0.873554 0.413854 0.862225 0 0 0 0.00281905 l
+0.403211 0.873554 0.387205 0.85976 0 0 0 0.00281905 l
+0.403211 0.873554 0.401489 0.876218 0 0 0 0.00281905 l
+0.852606 -0.464844 0.874866 -0.461953 0 0 0 0.00281905 l
+0.852606 -0.464844 0.849907 -0.47285 0 0 0 0.00281905 l
+0.0343723 0.578406 0.0320164 0.587367 0 0 0 0.00281905 l
+0.0343723 0.578406 0.0419822 0.568788 0 0 0 0.00281905 l
+0.577597 0.545435 0.591381 0.545042 0 0 0 0.00281905 l
+0.577597 0.545435 0.579909 0.534159 0 0 0 0.00281905 l
+-0.838068 0.226193 -0.853043 0.211289 0 0 0 0.00281905 l
+-0.838068 0.226193 -0.828273 0.238411 0 0 0 0.00281905 l
+-0.178867 -0.907092 -0.183966 -0.92969 0 0 0 0.00281905 l
+-0.178867 -0.907092 -0.178179 -0.904615 0 0 0 0.00281905 l
+0.58716 0.398491 0.594298 0.389865 0 0 0 0.00281905 l
+0.58716 0.398491 0.588809 0.403292 0 0 0 0.00281905 l
+-0.625799 -0.458232 -0.631451 -0.461741 0 0 0 0.00281905 l
+0.825328 0.334405 0.833249 0.321357 0 0 0 0.00281905 l
+0.825328 0.334405 0.840575 0.33986 0 0 0 0.00281905 l
+0.825328 0.334405 0.812715 0.333723 0 0 0 0.00281905 l
+0.29566 -0.143389 0.303442 -0.139304 0 0 0 0.00281905 l
+0.29566 -0.143389 0.298008 -0.151425 0 0 0 0.00281905 l
+-0.632438 -0.0318521 -0.630762 -0.0227757 0 0 0 0.00281905 l
+-0.632438 -0.0318521 -0.626239 -0.0329287 0 0 0 0.00281905 l
+-0.632438 -0.0318521 -0.646021 -0.0379407 0 0 0 0.00281905 l
+0.760352 -0.599902 0.781693 -0.59491 0 0 0 0.00281905 l
+0.760352 -0.599902 0.749658 -0.598866 0 0 0 0.00281905 l
+-0.17065 -0.0122453 -0.160779 -0.019322 0 0 0 0.00281905 l
+-0.17065 -0.0122453 -0.185794 -0.00925174 0 0 0 0.00281905 l
+-0.406115 0.367839 -0.404033 0.36083 0 0 0 0.00281905 l
+-0.406115 0.367839 -0.413603 0.374728 0 0 0 0.00281905 l
+-0.0559224 0.845203 -0.056927 0.840451 0 0 0 0.00281905 l
+-0.0559224 0.845203 -0.0420746 0.854616 0 0 0 0.00281905 l
+-0.0559224 0.845203 -0.0679275 0.8526 0 0 0 0.00281905 l
+0.785613 0.429127 0.79577 0.411668 0 0 0 0.00281905 l
+0.785613 0.429127 0.802363 0.432831 0 0 0 0.00281905 l
+-0.368079 -0.195 -0.359283 -0.208361 0 0 0 0.00281905 l
+-0.368079 -0.195 -0.364104 -0.183242 0 0 0 0.00281905 l
+-0.387994 -0.151597 -0.379721 -0.161118 0 0 0 0.00281905 l
+-0.387994 -0.151597 -0.395724 -0.16523 0 0 0 0.00281905 l
+-0.387994 -0.151597 -0.381436 -0.142291 0 0 0 0.00281905 l
+-0.360394 -0.810255 -0.34687 -0.806146 0 0 0 0.00281905 l
+-0.292166 0.698567 -0.290278 0.690846 0 0 0 0.00281905 l
+-0.292166 0.698567 -0.278163 0.701217 0 0 0 0.00281905 l
+-0.292166 0.698567 -0.295306 0.704521 0 0 0 0.00281905 l
+-0.551107 -0.805855 -0.544933 -0.789297 0 0 0 0.00281905 l
+-0.551107 -0.805855 -0.543527 -0.810187 0 0 0 0.00281905 l
+-0.551107 -0.805855 -0.567876 -0.793593 0 0 0 0.00281905 l
+0.507831 -0.22673 0.508209 -0.21846 0 0 0 0.00281905 l
+0.507831 -0.22673 0.498362 -0.236065 0 0 0 0.00281905 l
+0.507831 -0.22673 0.499928 -0.22264 0 0 0 0.00281905 l
+-0.547357 -0.456984 -0.537417 -0.469011 0 0 0 0.00281905 l
+-0.547357 -0.456984 -0.550086 -0.450519 0 0 0 0.00281905 l
+-0.547357 -0.456984 -0.5315 -0.450997 0 0 0 0.00281905 l
+-0.35154 -0.886153 -0.35577 -0.873098 0 0 0 0.00281905 l
+-0.35154 -0.886153 -0.348134 -0.887908 0 0 0 0.00281905 l
+-0.35154 -0.886153 -0.356519 -0.893897 0 0 0 0.00281905 l
+-0.835773 0.398373 -0.814413 0.395606 0 0 0 0.00281905 l
+-0.835773 0.398373 -0.836998 0.385329 0 0 0 0.00281905 l
+-0.814561 -0.499468 -0.807618 -0.48242 0 0 0 0.00281905 l
+-0.814561 -0.499468 -0.80285 -0.521799 0 0 0 0.00281905 l
+0.19566 -0.230072 0.196303 -0.212149 0 0 0 0.00281905 l
+0.19566 -0.230072 0.209329 -0.239912 0 0 0 0.00281905 l
+0.19566 -0.230072 0.183478 -0.239425 0 0 0 0.00281905 l
+-0.860894 -0.4124 -0.879834 -0.40777 0 0 0 0.00281905 l
+-0.860894 -0.4124 -0.85997 -0.411649 0 0 0 0.00281905 l
+-0.860894 -0.4124 -0.859556 -0.413875 0 0 0 0.00281905 l
+0.0742208 -0.836554 0.0814796 -0.839098 0 0 0 0.00281905 l
+0.0742208 -0.836554 0.0592192 -0.832596 0 0 0 0.00281905 l
+0.278122 0.80868 0.288477 0.807801 0 0 0 0.00281905 l
+0.278122 0.80868 0.274304 0.80929 0 0 0 0.00281905 l
+-0.581937 0.230588 -0.577285 0.233712 0 0 0 0.00281905 l
+-0.581937 0.230588 -0.596434 0.234755 0 0 0 0.00281905 l
+0.450157 -0.425527 0.445653 -0.414497 0 0 0 0.00281905 l
+0.450157 -0.425527 0.459458 -0.425375 0 0 0 0.00281905 l
+-0.591079 -0.146692 -0.591313 -0.138944 0 0 0 0.00281905 l
+-0.796663 -0.350522 -0.791297 -0.349648 0 0 0 0.00281905 l
+-0.796663 -0.350522 -0.800148 -0.350436 0 0 0 0.00281905 l
+0.109761 0.273437 0.121425 0.264699 0 0 0 0.00281905 l
+-0.466269 -0.319024 -0.477649 -0.328556 0 0 0 0.00281905 l
+-0.466269 -0.319024 -0.470522 -0.313997 0 0 0 0.00281905 l
+0.277841 -0.341603 0.280733 -0.335456 0 0 0 0.00281905 l
+0.277841 -0.341603 0.266729 -0.343796 0 0 0 0.00281905 l
+-0.0918797 -0.950623 -0.0895299 -0.942053 0 0 0 0.00281905 l
+0.624336 0.680053 0.622368 0.686318 0 0 0 0.00281905 l
+0.624336 0.680053 0.633263 0.676793 0 0 0 0.00281905 l
+0.624336 0.680053 0.617897 0.666362 0 0 0 0.00281905 l
+-0.730765 -0.611932 -0.732255 -0.630928 0 0 0 0.00281905 l
+-0.730765 -0.611932 -0.731198 -0.603448 0 0 0 0.00281905 l
+-0.730765 -0.611932 -0.723302 -0.60957 0 0 0 0.00281905 l
+-0.730765 -0.611932 -0.747448 -0.613847 0 0 0 0.00281905 l
+-0.0759238 0.726536 -0.0719021 0.7269 0 0 0 0.00281905 l
+-0.0759238 0.726536 -0.0833289 0.733969 0 0 0 0.00281905 l
+0.590559 -0.534245 0.588412 -0.53752 0 0 0 0.00281905 l
+0.222228 0.332831 0.206586 0.318078 0 0 0 0.00281905 l
+0.166621 0.259037 0.172982 0.259448 0 0 0 0.00281905 l
+0.00740765 0.566477 0.0150127 0.566974 0 0 0 0.00281905 l
+0.00740765 0.566477 -0.00806925 0.57144 0 0 0 0.00281905 l
+-0.580113 0.558721 -0.571217 0.547752 0 0 0 0.00281905 l
+0.137592 -0.0669224 0.140306 -0.0757422 0 0 0 0.00281905 l
+0.137592 -0.0669224 0.150977 -0.0569331 0 0 0 0.00281905 l
+0.137592 -0.0669224 0.133383 -0.0694068 0 0 0 0.00281905 l
+0.483999 0.299126 0.497283 0.292812 0 0 0 0.00281905 l
+0.483999 0.299126 0.484448 0.306933 0 0 0 0.00281905 l
+-0.0541525 -0.720993 -0.0558546 -0.711844 0 0 0 0.00281905 l
+-0.0541525 -0.720993 -0.0502248 -0.721795 0 0 0 0.00281905 l
+-0.0541525 -0.720993 -0.0690446 -0.734171 0 0 0 0.00281905 l
+-0.239618 0.434297 -0.236983 0.434649 0 0 0 0.00281905 l
+-0.043886 -0.625989 -0.0361393 -0.622353 0 0 0 0.00281905 l
+0.443349 -0.7284 0.43826 -0.734125 0 0 0 0.00281905 l
+0.443349 -0.7284 0.455007 -0.717542 0 0 0 0.00281905 l
+0.443349 -0.7284 0.437093 -0.726236 0 0 0 0.00281905 l
+-0.683133 -0.595352 -0.678277 -0.592325 0 0 0 0.00281905 l
+-0.683133 -0.595352 -0.695368 -0.598554 0 0 0 0.00281905 l
+-0.803055 0.24477 -0.808958 0.220942 0 0 0 0.00281905 l
+-0.803055 0.24477 -0.814799 0.249717 0 0 0 0.00281905 l
+-0.781165 -0.519909 -0.773431 -0.519341 0 0 0 0.00281905 l
+0.298834 -0.274908 0.300079 -0.282404 0 0 0 0.00281905 l
+0.298834 -0.274908 0.302232 -0.270151 0 0 0 0.00281905 l
+0.298834 -0.274908 0.292119 -0.272692 0 0 0 0.00281905 l
+-0.608119 0.53974 -0.60283 0.540468 0 0 0 0.00281905 l
+-0.608119 0.53974 -0.619346 0.540109 0 0 0 0.00281905 l
+0.158898 0.735325 0.17334 0.730685 0 0 0 0.00281905 l
+0.158898 0.735325 0.151503 0.725332 0 0 0 0.00281905 l
+0.158898 0.735325 0.157482 0.738069 0 0 0 0.00281905 l
+-0.0783426 -0.53355 -0.0747043 -0.523731 0 0 0 0.00281905 l
+-0.0783426 -0.53355 -0.0756769 -0.538044 0 0 0 0.00281905 l
+-0.0783426 -0.53355 -0.0848311 -0.52823 0 0 0 0.00281905 l
+0.182923 -0.342138 0.184612 -0.341872 0 0 0 0.00281905 l
+0.182923 -0.342138 0.173643 -0.34033 0 0 0 0.00281905 l
+0.219064 0.936417 0.215491 0.916948 0 0 0 0.00281905 l
+0.219064 0.936417 0.228051 0.936698 0 0 0 0.00281905 l
+0.219064 0.936417 0.216719 0.940047 0 0 0 0.00281905 l
+0.506083 -0.530574 0.509774 -0.51912 0 0 0 0.00281905 l
+0.506083 -0.530574 0.499032 -0.533761 0 0 0 0.00281905 l
+0.12967 0.934646 0.132326 0.945569 0 0 0 0.00281905 l
+0.12967 0.934646 0.144009 0.935127 0 0 0 0.00281905 l
+0.12967 0.934646 0.127978 0.930869 0 0 0 0.00281905 l
+-0.758077 -0.177188 -0.765512 -0.17332 0 0 0 0.00281905 l
+0.103421 0.166096 0.102942 0.177668 0 0 0 0.00281905 l
+0.103421 0.166096 0.107035 0.159896 0 0 0 0.00281905 l
+0.572915 -0.691669 0.573535 -0.692124 0 0 0 0.00281905 l
+0.0390585 -0.265315 0.0388845 -0.274886 0 0 0 0.00281905 l
+0.0390585 -0.265315 0.0271997 -0.258809 0 0 0 0.00281905 l
+-0.372858 0.566488 -0.378824 0.553336 0 0 0 0.00281905 l
+-0.372858 0.566488 -0.362912 0.563992 0 0 0 0.00281905 l
+-0.372858 0.566488 -0.370429 0.571241 0 0 0 0.00281905 l
+-0.372858 0.566488 -0.384272 0.568749 0 0 0 0.00281905 l
+0.589562 0.31039 0.601617 0.299257 0 0 0 0.00281905 l
+-0.60283 0.540468 -0.595584 0.540501 0 0 0 0.00281905 l
+-0.60283 0.540468 -0.608119 0.53974 0 0 0 0.00281905 l
+-0.459171 0.800915 -0.476657 0.812986 0 0 0 0.00281905 l
+-0.459171 0.800915 -0.460144 0.798133 0 0 0 0.00281905 l
+0.285134 0.0199736 0.295793 0.0293948 0 0 0 0.00281905 l
+0.285134 0.0199736 0.26696 0.0175563 0 0 0 0.00281905 l
+0.0376129 -0.568085 0.0308855 -0.567843 0 0 0 0.00281905 l
+0.146646 0.923977 0.164523 0.921324 0 0 0 0.00281905 l
+0.146646 0.923977 0.148935 0.908336 0 0 0 0.00281905 l
+0.146646 0.923977 0.147178 0.934427 0 0 0 0.00281905 l
+0.915004 0.0847772 0.921857 0.0631322 0 0 0 0.00281905 l
+0.915004 0.0847772 0.908931 0.0944769 0 0 0 0.00281905 l
+0.124297 -0.534294 0.135229 -0.546584 0 0 0 0.00281905 l
+0.124297 -0.534294 0.125492 -0.532709 0 0 0 0.00281905 l
+0.368217 0.384348 0.377782 0.38659 0 0 0 0.00281905 l
+0.368217 0.384348 0.365757 0.371255 0 0 0 0.00281905 l
+-0.0342956 0.881365 -0.0134509 0.884671 0 0 0 0.00281905 l
+-0.0342956 0.881365 -0.0400301 0.881261 0 0 0 0.00281905 l
+-0.132163 -0.610069 -0.122443 -0.616117 0 0 0 0.00281905 l
+-0.132163 -0.610069 -0.143035 -0.623373 0 0 0 0.00281905 l
+-0.290816 -0.504638 -0.275168 -0.50375 0 0 0 0.00281905 l
+-0.290816 -0.504638 -0.297051 -0.511417 0 0 0 0.00281905 l
+0.286925 0.389536 0.286172 0.379342 0 0 0 0.00281905 l
+0.286925 0.389536 0.287191 0.394986 0 0 0 0.00281905 l
+0.286925 0.389536 0.296988 0.391246 0 0 0 0.00281905 l
+-0.365028 0.803093 -0.363577 0.786062 0 0 0 0.00281905 l
+-0.274509 0.376069 -0.258711 0.378563 0 0 0 0.00281905 l
+0.919033 -0.351044 0.930528 -0.352185 0 0 0 0.00281905 l
+0.919033 -0.351044 0.91469 -0.359928 0 0 0 0.00281905 l
+-0.115233 0.302014 -0.0986139 0.305745 0 0 0 0.00281905 l
+-0.115233 0.302014 -0.116015 0.30627 0 0 0 0.00281905 l
+0.0313305 -0.697146 0.0389374 -0.686031 0 0 0 0.00281905 l
+0.0313305 -0.697146 0.0500875 -0.702661 0 0 0 0.00281905 l
+0.0313305 -0.697146 0.0303802 -0.697064 0 0 0 0.00281905 l
+-0.104129 0.642005 -0.0965469 0.637028 0 0 0 0.00281905 l
+-0.104129 0.642005 -0.0973701 0.646066 0 0 0 0.00281905 l
+-0.104129 0.642005 -0.111519 0.642181 0 0 0 0.00281905 l
+-0.277888 -0.0570166 -0.2754 -0.0530764 0 0 0 0.00281905 l
+-0.433728 -0.155211 -0.432712 -0.143497 0 0 0 0.00281905 l
+-0.433728 -0.155211 -0.425527 -0.153564 0 0 0 0.00281905 l
+-0.433728 -0.155211 -0.450595 -0.153382 0 0 0 0.00281905 l
+-0.42207 0.799575 -0.420969 0.809556 0 0 0 0.00281905 l
+0.143206 -0.264068 0.160945 -0.261869 0 0 0 0.00281905 l
+0.143206 -0.264068 0.134511 -0.262417 0 0 0 0.00281905 l
+0.179786 -0.84089 0.198448 -0.830531 0 0 0 0.00281905 l
+0.179786 -0.84089 0.173734 -0.851037 0 0 0 0.00281905 l
+-0.795837 0.425402 -0.782144 0.424294 0 0 0 0.00281905 l
+-0.795837 0.425402 -0.805306 0.440006 0 0 0 0.00281905 l
+-0.24481 -0.868924 -0.249699 -0.873503 0 0 0 0.00281905 l
+-0.24481 -0.868924 -0.243828 -0.867488 0 0 0 0.00281905 l
+-0.740724 -0.158466 -0.734401 -0.17399 0 0 0 0.00281905 l
+-0.740724 -0.158466 -0.755193 -0.158293 0 0 0 0.00281905 l
+0.639856 0.339225 0.642694 0.357919 0 0 0 0.00281905 l
+0.639856 0.339225 0.65767 0.33952 0 0 0 0.00281905 l
+0.639856 0.339225 0.622638 0.345301 0 0 0 0.00281905 l
+0.603018 -0.193661 0.616806 -0.188923 0 0 0 0.00281905 l
+0.603018 -0.193661 0.595723 -0.200439 0 0 0 0.00281905 l
+0.733334 -0.531461 0.718553 -0.526429 0 0 0 0.00281905 l
+0.19883 -0.7587 0.203068 -0.740159 0 0 0 0.00281905 l
+0.19883 -0.7587 0.179239 -0.760919 0 0 0 0.00281905 l
+-0.62441 0.460472 -0.638583 0.465598 0 0 0 0.00281905 l
+-0.164363 0.631181 -0.169851 0.621446 0 0 0 0.00281905 l
+-0.414044 0.66508 -0.414007 0.678662 0 0 0 0.00281905 l
+-0.414044 0.66508 -0.407997 0.663841 0 0 0 0.00281905 l
+0.714817 -0.321722 0.721342 -0.306479 0 0 0 0.00281905 l
+0.714817 -0.321722 0.71408 -0.335987 0 0 0 0.00281905 l
+0.714817 -0.321722 0.696371 -0.316729 0 0 0 0.00281905 l
+0.773487 -0.337473 0.766176 -0.340296 0 0 0 0.00281905 l
+-0.417644 -0.452815 -0.402748 -0.471189 0 0 0 0.00281905 l
+0.836518 -0.340642 0.836938 -0.337789 0 0 0 0.00281905 l
+0.836518 -0.340642 0.819606 -0.33773 0 0 0 0.00281905 l
+0.716229 -0.336557 0.724323 -0.338883 0 0 0 0.00281905 l
+0.716229 -0.336557 0.71408 -0.335987 0 0 0 0.00281905 l
+-0.0528354 -0.765145 -0.0371457 -0.762064 0 0 0 0.00281905 l
+-0.0528354 -0.765145 -0.0604881 -0.785019 0 0 0 0.00281905 l
+-0.0528354 -0.765145 -0.058065 -0.763148 0 0 0 0.00281905 l
+-0.509504 0.412853 -0.493163 0.413011 0 0 0 0.00281905 l
+-0.509504 0.412853 -0.515777 0.398971 0 0 0 0.00281905 l
+-0.509504 0.412853 -0.520343 0.418629 0 0 0 0.00281905 l
+-0.443444 0.0722929 -0.441834 0.0846763 0 0 0 0.00281905 l
+-0.443444 0.0722929 -0.433371 0.0615073 0 0 0 0.00281905 l
+-0.237655 -0.912798 -0.233592 -0.901184 0 0 0 0.00281905 l
+-0.237655 -0.912798 -0.249537 -0.919289 0 0 0 0.00281905 l
+0.149325 0.560292 0.146805 0.561243 0 0 0 0.00281905 l
+-0.223244 -0.826366 -0.208438 -0.827146 0 0 0 0.00281905 l
+-0.223244 -0.826366 -0.224764 -0.826819 0 0 0 0.00281905 l
+0.0495605 0.412473 0.0565317 0.422664 0 0 0 0.00281905 l
+0.0495605 0.412473 0.0340053 0.408223 0 0 0 0.00281905 l
+0.691636 -0.179852 0.693747 -0.174308 0 0 0 0.00281905 l
+0.691636 -0.179852 0.687216 -0.186402 0 0 0 0.00281905 l
+-0.0127046 0.449114 -0.0153619 0.443188 0 0 0 0.00281905 l
+-0.0127046 0.449114 -0.00134603 0.455033 0 0 0 0.00281905 l
+-0.0127046 0.449114 -0.0158993 0.452591 0 0 0 0.00281905 l
+-0.294523 -0.127114 -0.284276 -0.130931 0 0 0 0.00281905 l
+0.533496 0.760751 0.546888 0.753905 0 0 0 0.00281905 l
+0.533496 0.760751 0.530753 0.755734 0 0 0 0.00281905 l
+-0.731026 0.0131338 -0.737182 0.00253006 0 0 0 0.00281905 l
+-0.731026 0.0131338 -0.731263 0.0147989 0 0 0 0.00281905 l
+-0.0791557 -0.431535 -0.0740086 -0.437677 0 0 0 0.00281905 l
+-0.681971 0.415983 -0.669969 0.41117 0 0 0 0.00281905 l
+-0.61382 -0.610664 -0.614797 -0.60887 0 0 0 0.00281905 l
+-0.940218 -0.0221952 -0.934091 -0.0236802 0 0 0 0.00281905 l
+-0.940218 -0.0221952 -0.943287 -0.0224447 0 0 0 0.00281905 l
+-0.418003 0.481581 -0.411649 0.46193 0 0 0 0.00281905 l
+-0.418003 0.481581 -0.421886 0.488646 0 0 0 0.00281905 l
+-0.418306 0.347183 -0.42033 0.364014 0 0 0 0.00281905 l
+-0.418306 0.347183 -0.413238 0.346095 0 0 0 0.00281905 l
+-0.418306 0.347183 -0.423494 0.330223 0 0 0 0.00281905 l
+-0.78591 -0.585242 -0.781186 -0.597679 0 0 0 0.00281905 l
+-0.78591 -0.585242 -0.787553 -0.566308 0 0 0 0.00281905 l
+0.225906 0.843946 0.234986 0.851129 0 0 0 0.00281905 l
+0.225906 0.843946 0.235334 0.837054 0 0 0 0.00281905 l
+0.225906 0.843946 0.214454 0.839349 0 0 0 0.00281905 l
+0.00825097 -0.534565 0.00183302 -0.554468 0 0 0 0.00281905 l
+0.00825097 -0.534565 0.00987967 -0.520014 0 0 0 0.00281905 l
+0.00825097 -0.534565 0.0163499 -0.536184 0 0 0 0.00281905 l
+0.617338 0.619792 0.621978 0.629656 0 0 0 0.00281905 l
+0.617338 0.619792 0.617278 0.611755 0 0 0 0.00281905 l
+-0.746483 -0.466165 -0.741061 -0.466023 0 0 0 0.00281905 l
+-0.746483 -0.466165 -0.758312 -0.477691 0 0 0 0.00281905 l
+-0.734606 0.56783 -0.723845 0.555401 0 0 0 0.00281905 l
+-0.836592 0.0513411 -0.823377 0.0446953 0 0 0 0.00281905 l
+-0.836592 0.0513411 -0.846486 0.0536178 0 0 0 0.00281905 l
+-0.852891 -0.229667 -0.841464 -0.225414 0 0 0 0.00281905 l
+-0.852891 -0.229667 -0.84913 -0.236143 0 0 0 0.00281905 l
+-0.852891 -0.229667 -0.860238 -0.23352 0 0 0 0.00281905 l
+0.755606 -0.140581 0.761281 -0.128158 0 0 0 0.00281905 l
+0.755606 -0.140581 0.744215 -0.148421 0 0 0 0.00281905 l
+0.253479 -0.184552 0.251298 -0.168779 0 0 0 0.00281905 l
+0.166185 0.521681 0.175437 0.527711 0 0 0 0.00281905 l
+0.353145 -0.414197 0.353336 -0.403986 0 0 0 0.00281905 l
+0.353145 -0.414197 0.362262 -0.410449 0 0 0 0.00281905 l
+0.353145 -0.414197 0.347775 -0.416992 0 0 0 0.00281905 l
+0.239824 0.555415 0.242706 0.564914 0 0 0 0.00281905 l
+0.239824 0.555415 0.253982 0.552197 0 0 0 0.00281905 l
+0.239824 0.555415 0.238759 0.547497 0 0 0 0.00281905 l
+0.239824 0.555415 0.234203 0.559019 0 0 0 0.00281905 l
+-0.53043 0.547367 -0.535292 0.538825 0 0 0 0.00281905 l
+-0.53043 0.547367 -0.536139 0.552827 0 0 0 0.00281905 l
+-0.53043 0.547367 -0.524048 0.551139 0 0 0 0.00281905 l
+-0.570894 0.685069 -0.584045 0.686991 0 0 0 0.00281905 l
+-0.528827 -0.740871 -0.519543 -0.751565 0 0 0 0.00281905 l
+-0.528827 -0.740871 -0.546357 -0.736556 0 0 0 0.00281905 l
+0.0819474 0.825141 0.0835817 0.834695 0 0 0 0.00281905 l
+0.0819474 0.825141 0.0727212 0.817437 0 0 0 0.00281905 l
+-0.507934 0.326344 -0.503319 0.324042 0 0 0 0.00281905 l
+-0.507934 0.326344 -0.515813 0.309736 0 0 0 0.00281905 l
+-0.495282 0.733581 -0.488316 0.755369 0 0 0 0.00281905 l
+-0.495282 0.733581 -0.496035 0.726816 0 0 0 0.00281905 l
+-0.495282 0.733581 -0.510452 0.736022 0 0 0 0.00281905 l
+0.111144 -0.826232 0.117494 -0.823148 0 0 0 0.00281905 l
+0.111144 -0.826232 0.106574 -0.822047 0 0 0 0.00281905 l
+-0.754147 -0.559884 -0.739787 -0.574122 0 0 0 0.00281905 l
+0.448512 0.872929 0.462376 0.859505 0 0 0 0.00281905 l
+0.448512 0.872929 0.436344 0.889986 0 0 0 0.00281905 l
+0.448512 0.872929 0.452776 0.876357 0 0 0 0.00281905 l
+0.448512 0.872929 0.44287 0.861957 0 0 0 0.00281905 l
+0.417256 0.147472 0.425833 0.145117 0 0 0 0.00281905 l
+0.417256 0.147472 0.416894 0.139221 0 0 0 0.00281905 l
+-0.959543 0.000243254 -0.957476 -0.00905659 0 0 0 0.00281905 l
+-0.959543 0.000243254 -0.951515 0.00509584 0 0 0 0.00281905 l
+-0.959543 0.000243254 -0.976324 -0.00284653 0 0 0 0.00281905 l
+0.461029 0.431465 0.453733 0.427783 0 0 0 0.00281905 l
+0.573869 -0.348667 0.586324 -0.338908 0 0 0 0.00281905 l
+0.253615 -0.115832 0.262242 -0.11541 0 0 0 0.00281905 l
+-0.583892 -0.317741 -0.583502 -0.332021 0 0 0 0.00281905 l
+-0.583892 -0.317741 -0.581446 -0.314342 0 0 0 0.00281905 l
+-0.386004 -0.0979852 -0.379645 -0.106963 0 0 0 0.00281905 l
+-0.386004 -0.0979852 -0.396019 -0.0876371 0 0 0 0.00281905 l
+-0.77334 -0.303416 -0.768322 -0.304354 0 0 0 0.00281905 l
+-0.356382 0.304641 -0.357973 0.326126 0 0 0 0.00281905 l
+-0.356382 0.304641 -0.355602 0.285015 0 0 0 0.00281905 l
+0.294839 -0.814145 0.294832 -0.818299 0 0 0 0.00281905 l
+0.294839 -0.814145 0.285307 -0.807843 0 0 0 0.00281905 l
+-0.800605 0.341635 -0.801703 0.33383 0 0 0 0.00281905 l
+-0.800605 0.341635 -0.800987 0.350457 0 0 0 0.00281905 l
+-0.0853398 0.397337 -0.0889522 0.379026 0 0 0 0.00281905 l
+-0.0853398 0.397337 -0.0816311 0.400133 0 0 0 0.00281905 l
+-0.882722 0.259391 -0.892681 0.266595 0 0 0 0.00281905 l
+0.0944291 0.816401 0.105597 0.825622 0 0 0 0.00281905 l
+-0.109815 -0.671747 -0.0960864 -0.676841 0 0 0 0.00281905 l
+-0.109815 -0.671747 -0.116191 -0.675018 0 0 0 0.00281905 l
+-0.152763 -0.297745 -0.165775 -0.285933 0 0 0 0.00281905 l
+-0.17523 0.360729 -0.179725 0.361433 0 0 0 0.00281905 l
+0.207519 0.546127 0.210666 0.524805 0 0 0 0.00281905 l
+0.207519 0.546127 0.2013 0.544452 0 0 0 0.00281905 l
+0.606935 -0.513012 0.614831 -0.495595 0 0 0 0.00281905 l
+0.606935 -0.513012 0.614157 -0.531152 0 0 0 0.00281905 l
+0.606935 -0.513012 0.59493 -0.500403 0 0 0 0.00281905 l
+0.606935 -0.513012 0.600647 -0.516872 0 0 0 0.00281905 l
+-0.579277 -0.711791 -0.577564 -0.727528 0 0 0 0.00281905 l
+-0.579277 -0.711791 -0.595858 -0.713065 0 0 0 0.00281905 l
+0.751699 0.0591822 0.759127 0.0489503 0 0 0 0.00281905 l
+0.751699 0.0591822 0.766644 0.0651518 0 0 0 0.00281905 l
+0.265522 0.301819 0.268922 0.303004 0 0 0 0.00281905 l
+0.265522 0.301819 0.249118 0.295657 0 0 0 0.00281905 l
+-0.872125 0.090655 -0.853908 0.0948758 0 0 0 0.00281905 l
+-0.872125 0.090655 -0.885444 0.102265 0 0 0 0.00281905 l
+0.328411 -0.0894602 0.332563 -0.0834278 0 0 0 0.00281905 l
+-0.866928 0.136351 -0.849258 0.122367 0 0 0 0.00281905 l
+-0.866928 0.136351 -0.862695 0.144242 0 0 0 0.00281905 l
+0.293906 -0.674426 0.295154 -0.677226 0 0 0 0.00281905 l
+0.293906 -0.674426 0.292026 -0.674881 0 0 0 0.00281905 l
+-0.493124 -0.609856 -0.49451 -0.59806 0 0 0 0.00281905 l
+0.251298 -0.168779 0.259045 -0.153383 0 0 0 0.00281905 l
+0.251298 -0.168779 0.253479 -0.184552 0 0 0 0.00281905 l
+0.251298 -0.168779 0.238042 -0.17405 0 0 0 0.00281905 l
+0.657388 -0.145855 0.65049 -0.129223 0 0 0 0.00281905 l
+0.657388 -0.145855 0.658089 -0.153546 0 0 0 0.00281905 l
+0.657388 -0.145855 0.641838 -0.15107 0 0 0 0.00281905 l
+-0.926015 0.0360989 -0.934335 0.0400148 0 0 0 0.00281905 l
+-0.83303 0.0920831 -0.835468 0.0988961 0 0 0 0.00281905 l
+-0.83303 0.0920831 -0.81286 0.0877904 0 0 0 0.00281905 l
+-0.83303 0.0920831 -0.839918 0.0786497 0 0 0 0.00281905 l
+-0.617051 0.228609 -0.610157 0.243089 0 0 0 0.00281905 l
+-0.617051 0.228609 -0.620771 0.220791 0 0 0 0.00281905 l
+-0.557202 -0.683338 -0.542071 -0.679928 0 0 0 0.00281905 l
+-0.557202 -0.683338 -0.576607 -0.684734 0 0 0 0.00281905 l
+0.301517 0.219778 0.299733 0.236217 0 0 0 0.00281905 l
+0.301517 0.219778 0.295555 0.210707 0 0 0 0.00281905 l
+-0.499086 0.586857 -0.493539 0.592099 0 0 0 0.00281905 l
+-0.499086 0.586857 -0.503052 0.583028 0 0 0 0.00281905 l
+-0.0179926 -0.369543 0.00108654 -0.366223 0 0 0 0.00281905 l
+0.185205 0.0861395 0.202217 0.0720466 0 0 0 0.00281905 l
+0.185205 0.0861395 0.164432 0.0811077 0 0 0 0.00281905 l
+-0.888104 0.448102 -0.881194 0.464055 0 0 0 0.00281905 l
+-0.888104 0.448102 -0.88192 0.441807 0 0 0 0.00281905 l
+-0.239437 -0.933285 -0.231127 -0.943403 0 0 0 0.00281905 l
+-0.239437 -0.933285 -0.245392 -0.930029 0 0 0 0.00281905 l
+-0.225822 0.00773785 -0.213146 0.0214237 0 0 0 0.00281905 l
+-0.225822 0.00773785 -0.22228 0.00478532 0 0 0 0.00281905 l
+-0.225822 0.00773785 -0.228518 0.00301098 0 0 0 0.00281905 l
+0.415086 0.534528 0.420509 0.537894 0 0 0 0.00281905 l
+0.415086 0.534528 0.411861 0.53074 0 0 0 0.00281905 l
+0.195337 -0.104477 0.210368 -0.109028 0 0 0 0.00281905 l
+0.195337 -0.104477 0.188143 -0.0920435 0 0 0 0.00281905 l
+-0.0498468 -0.566282 -0.034261 -0.573736 0 0 0 0.00281905 l
+-0.0498468 -0.566282 -0.0551462 -0.588721 0 0 0 0.00281905 l
+0.648447 -0.39931 0.65891 -0.400816 0 0 0 0.00281905 l
+0.796461 -0.389096 0.802743 -0.371897 0 0 0 0.00281905 l
+0.796461 -0.389096 0.798288 -0.40179 0 0 0 0.00281905 l
+-0.110962 0.566268 -0.103269 0.569469 0 0 0 0.00281905 l
+-0.110962 0.566268 -0.124509 0.551882 0 0 0 0.00281905 l
+-0.643202 0.195593 -0.632648 0.206142 0 0 0 0.00281905 l
+-0.148329 0.531672 -0.142378 0.541376 0 0 0 0.00281905 l
+-0.148329 0.531672 -0.153606 0.535373 0 0 0 0.00281905 l
+-0.616222 0.272154 -0.613453 0.263967 0 0 0 0.00281905 l
+-0.0729418 0.422132 -0.0675933 0.419112 0 0 0 0.00281905 l
+0.227024 -0.673796 0.244565 -0.683838 0 0 0 0.00281905 l
+0.121346 -0.858763 0.112264 -0.86867 0 0 0 0.00281905 l
+0.0474121 0.776291 0.0495935 0.778917 0 0 0 0.00281905 l
+0.0474121 0.776291 0.0482192 0.772924 0 0 0 0.00281905 l
+0.0474121 0.776291 0.0435332 0.780722 0 0 0 0.00281905 l
+-0.391989 0.606799 -0.39792 0.617356 0 0 0 0.00281905 l
+-0.391989 0.606799 -0.392881 0.598454 0 0 0 0.00281905 l
+-0.527181 0.176973 -0.538837 0.162791 0 0 0 0.00281905 l
+-0.527181 0.176973 -0.527257 0.180312 0 0 0 0.00281905 l
+-0.527181 0.176973 -0.523693 0.178483 0 0 0 0.00281905 l
+0.879312 0.313061 0.881788 0.332473 0 0 0 0.00281905 l
+0.879312 0.313061 0.892377 0.314377 0 0 0 0.00281905 l
+0.879312 0.313061 0.885006 0.299053 0 0 0 0.00281905 l
+0.879312 0.313061 0.869232 0.317212 0 0 0 0.00281905 l
+-0.434903 0.271499 -0.434804 0.263445 0 0 0 0.00281905 l
+-0.434903 0.271499 -0.444314 0.271636 0 0 0 0.00281905 l
+0.194312 0.35002 0.191791 0.34716 0 0 0 0.00281905 l
+0.126134 -0.47815 0.128444 -0.483237 0 0 0 0.00281905 l
+0.460335 -0.724432 0.460075 -0.734536 0 0 0 0.00281905 l
+0.460335 -0.724432 0.464252 -0.722301 0 0 0 0.00281905 l
+0.460335 -0.724432 0.455007 -0.717542 0 0 0 0.00281905 l
+0.502619 0.534129 0.506744 0.545489 0 0 0 0.00281905 l
+0.502619 0.534129 0.50606 0.52865 0 0 0 0.00281905 l
+0.502619 0.534129 0.494642 0.539123 0 0 0 0.00281905 l
+-0.398185 0.597353 -0.392881 0.598454 0 0 0 0.00281905 l
+-0.398185 0.597353 -0.402346 0.595882 0 0 0 0.00281905 l
+0.491561 -0.53256 0.499032 -0.533761 0 0 0 0.00281905 l
+0.491561 -0.53256 0.488957 -0.530737 0 0 0 0.00281905 l
+-0.350309 -0.13245 -0.34493 -0.1493 0 0 0 0.00281905 l
+-0.350309 -0.13245 -0.35662 -0.118325 0 0 0 0.00281905 l
+-0.350309 -0.13245 -0.343691 -0.127846 0 0 0 0.00281905 l
+0.923665 0.117033 0.932326 0.10026 0 0 0 0.00281905 l
+0.923665 0.117033 0.909269 0.118093 0 0 0 0.00281905 l
+0.923665 0.117033 0.928129 0.124578 0 0 0 0.00281905 l
+-0.286422 -0.255832 -0.279303 -0.260478 0 0 0 0.00281905 l
+-0.286422 -0.255832 -0.295501 -0.257967 0 0 0 0.00281905 l
+0.468857 0.206916 0.454167 0.216302 0 0 0 0.00281905 l
+0.468857 0.206916 0.461008 0.197742 0 0 0 0.00281905 l
+0.145373 -0.795503 0.148354 -0.809648 0 0 0 0.00281905 l
+0.145373 -0.795503 0.14672 -0.7905 0 0 0 0.00281905 l
+-0.366981 -0.867016 -0.355631 -0.870232 0 0 0 0.00281905 l
+-0.366981 -0.867016 -0.369904 -0.865052 0 0 0 0.00281905 l
+-0.494059 0.489766 -0.487982 0.50336 0 0 0 0.00281905 l
+-0.494059 0.489766 -0.509447 0.483794 0 0 0 0.00281905 l
+-0.517944 -0.237631 -0.504623 -0.227988 0 0 0 0.00281905 l
+0.0658642 0.662871 0.0656404 0.674602 0 0 0 0.00281905 l
+0.0658642 0.662871 0.0626334 0.659331 0 0 0 0.00281905 l
+-0.539093 0.479564 -0.534083 0.484642 0 0 0 0.00281905 l
+-0.271373 -0.178864 -0.267029 -0.190615 0 0 0 0.00281905 l
+-0.271373 -0.178864 -0.263914 -0.169389 0 0 0 0.00281905 l
+0.390285 0.620006 0.384967 0.599581 0 0 0 0.00281905 l
+0.127453 -0.873797 0.125004 -0.888027 0 0 0 0.00281905 l
+-0.165905 -0.322506 -0.164051 -0.342597 0 0 0 0.00281905 l
+0.462607 0.13222 0.446644 0.129097 0 0 0 0.00281905 l
+0.379045 -0.122598 0.378038 -0.131091 0 0 0 0.00281905 l
+0.379045 -0.122598 0.381103 -0.110534 0 0 0 0.00281905 l
+0.379045 -0.122598 0.370464 -0.121836 0 0 0 0.00281905 l
+-0.28202 -0.462811 -0.282015 -0.46428 0 0 0 0.00281905 l
+-0.28202 -0.462811 -0.291071 -0.453024 0 0 0 0.00281905 l
+0.115457 -0.225291 0.127092 -0.225204 0 0 0 0.00281905 l
+0.377298 -0.355154 0.38075 -0.357633 0 0 0 0.00281905 l
+0.147178 0.934427 0.146646 0.923977 0 0 0 0.00281905 l
+0.147178 0.934427 0.149476 0.93484 0 0 0 0.00281905 l
+0.147178 0.934427 0.144009 0.935127 0 0 0 0.00281905 l
+-0.0982648 -0.0988496 -0.102639 -0.111258 0 0 0 0.00281905 l
+-0.0982648 -0.0988496 -0.108743 -0.0859735 0 0 0 0.00281905 l
+-0.909984 -0.0676924 -0.906686 -0.0679642 0 0 0 0.00281905 l
+0.761289 -0.18525 0.769006 -0.175617 0 0 0 0.00281905 l
+0.761289 -0.18525 0.755563 -0.184813 0 0 0 0.00281905 l
+-0.189287 0.381563 -0.186853 0.38126 0 0 0 0.00281905 l
+-0.189287 0.381563 -0.191584 0.379903 0 0 0 0.00281905 l
+0.729399 0.656438 0.719565 0.656266 0 0 0 0.00281905 l
+0.442389 0.641109 0.434441 0.645359 0 0 0 0.00281905 l
+0.282951 0.503955 0.289925 0.521427 0 0 0 0.00281905 l
+0.282951 0.503955 0.268757 0.492305 0 0 0 0.00281905 l
+0.854839 0.310959 0.864082 0.306563 0 0 0 0.00281905 l
+-0.793235 0.471507 -0.786227 0.488405 0 0 0 0.00281905 l
+0.170944 -0.638949 0.181269 -0.639778 0 0 0 0.00281905 l
+0.949135 0.0061998 0.959013 0.00679028 0 0 0 0.00281905 l
+-0.50464 0.79113 -0.501449 0.799788 0 0 0 0.00281905 l
+-0.50464 0.79113 -0.516198 0.779151 0 0 0 0.00281905 l
+-0.10871 0.354069 -0.119543 0.339315 0 0 0 0.00281905 l
+-0.10871 0.354069 -0.0970616 0.367848 0 0 0 0.00281905 l
+-0.0230276 0.112986 -0.0216321 0.13088 0 0 0 0.00281905 l
+-0.0230276 0.112986 -0.0106223 0.105602 0 0 0 0.00281905 l
+0.0479191 0.503421 0.0529211 0.512235 0 0 0 0.00281905 l
+0.0479191 0.503421 0.038272 0.512227 0 0 0 0.00281905 l
+0.0479191 0.503421 0.0434185 0.496325 0 0 0 0.00281905 l
+-0.580876 -0.184609 -0.584224 -0.183402 0 0 0 0.00281905 l
+0.728681 -0.105425 0.723664 -0.0937109 0 0 0 0.00281905 l
+0.728681 -0.105425 0.714321 -0.117539 0 0 0 0.00281905 l
+-0.216662 0.495779 -0.21432 0.496846 0 0 0 0.00281905 l
+-0.216662 0.495779 -0.229369 0.49219 0 0 0 0.00281905 l
+0.50567 -0.550386 0.499032 -0.533761 0 0 0 0.00281905 l
+0.50567 -0.550386 0.503224 -0.559041 0 0 0 0.00281905 l
+-0.436562 0.322416 -0.434929 0.325732 0 0 0 0.00281905 l
+0.233989 -0.795961 0.248309 -0.780939 0 0 0 0.00281905 l
+0.233989 -0.795961 0.225389 -0.785862 0 0 0 0.00281905 l
+0.533996 -0.622429 0.547688 -0.603287 0 0 0 0.00281905 l
+0.533996 -0.622429 0.525325 -0.627025 0 0 0 0.00281905 l
+0.145216 -0.769514 0.154218 -0.770312 0 0 0 0.00281905 l
+0.145216 -0.769514 0.128625 -0.766533 0 0 0 0.00281905 l
+0.571451 0.344153 0.583453 0.345888 0 0 0 0.00281905 l
+-0.451013 -0.891583 -0.445413 -0.881537 0 0 0 0.00281905 l
+0.378708 -0.531241 0.38145 -0.536894 0 0 0 0.00281905 l
+0.133713 0.471947 0.13932 0.486255 0 0 0 0.00281905 l
+0.133713 0.471947 0.140216 0.453177 0 0 0 0.00281905 l
+0.822822 -0.295258 0.835603 -0.306829 0 0 0 0.00281905 l
+0.822822 -0.295258 0.825793 -0.277021 0 0 0 0.00281905 l
+0.822822 -0.295258 0.815291 -0.307738 0 0 0 0.00281905 l
+0.830459 -0.404711 0.835719 -0.412359 0 0 0 0.00281905 l
+0.350173 -0.242906 0.349471 -0.237616 0 0 0 0.00281905 l
+0.350173 -0.242906 0.345285 -0.256722 0 0 0 0.00281905 l
+0.218065 -0.0268488 0.221721 -0.0242625 0 0 0 0.00281905 l
+0.218065 -0.0268488 0.210072 -0.0281794 0 0 0 0.00281905 l
+-0.80846 -0.137194 -0.817167 -0.128315 0 0 0 0.00281905 l
+-0.80846 -0.137194 -0.794968 -0.146362 0 0 0 0.00281905 l
+-0.80846 -0.137194 -0.821213 -0.141602 0 0 0 0.00281905 l
+0.0388845 -0.274886 0.0390585 -0.265315 0 0 0 0.00281905 l
+0.100458 -0.182645 0.106562 -0.192028 0 0 0 0.00281905 l
+0.100458 -0.182645 0.0996131 -0.18204 0 0 0 0.00281905 l
+-0.884183 -0.290607 -0.879857 -0.285722 0 0 0 0.00281905 l
+-0.884183 -0.290607 -0.889898 -0.296865 0 0 0 0.00281905 l
+0.904056 0.134811 0.909537 0.147106 0 0 0 0.00281905 l
+0.725599 0.450658 0.735504 0.450538 0 0 0 0.00281905 l
+0.673222 -0.256476 0.666459 -0.260524 0 0 0 0.00281905 l
+-0.498946 -0.0245071 -0.503469 -0.0307864 0 0 0 0.00281905 l
+0.0814796 -0.839098 0.0831824 -0.824587 0 0 0 0.00281905 l
+0.0814796 -0.839098 0.0742208 -0.836554 0 0 0 0.00281905 l
+-0.398773 0.860037 -0.397578 0.862035 0 0 0 0.00281905 l
+-0.398773 0.860037 -0.411067 0.857224 0 0 0 0.00281905 l
+-0.845435 0.199336 -0.853043 0.211289 0 0 0 0.00281905 l
+0.0940376 -0.460759 0.1016 -0.453225 0 0 0 0.00281905 l
+0.0940376 -0.460759 0.0839942 -0.464459 0 0 0 0.00281905 l
+-0.432055 0.693501 -0.433315 0.713688 0 0 0 0.00281905 l
+0.0811118 0.138269 0.0862134 0.140535 0 0 0 0.00281905 l
+0.0811118 0.138269 0.0754052 0.135926 0 0 0 0.00281905 l
+-0.874466 -0.347796 -0.874449 -0.347159 0 0 0 0.00281905 l
+-0.874466 -0.347796 -0.87753 -0.359045 0 0 0 0.00281905 l
+0.638397 0.541501 0.629067 0.572402 0 0 0 0.00281905 l
+0.638397 0.541501 0.65127 0.539962 0 0 0 0.00281905 l
+-0.168752 0.176348 -0.159019 0.181149 0 0 0 0.00281905 l
+-0.168752 0.176348 -0.17991 0.178676 0 0 0 0.00281905 l
+0.709097 -0.0728468 0.714656 -0.0710853 0 0 0 0.00281905 l
+-0.279879 0.0818276 -0.279606 0.0906622 0 0 0 0.00281905 l
+-0.279879 0.0818276 -0.273139 0.0770537 0 0 0 0.00281905 l
+-0.279879 0.0818276 -0.295214 0.0835888 0 0 0 0.00281905 l
+-0.103093 0.0477133 -0.0940309 0.0453731 0 0 0 0.00281905 l
+-0.480187 -0.337708 -0.477649 -0.328556 0 0 0 0.00281905 l
+-0.480187 -0.337708 -0.48241 -0.341168 0 0 0 0.00281905 l
+-0.645992 0.713161 -0.640183 0.726733 0 0 0 0.00281905 l
+-0.645992 0.713161 -0.647439 0.713238 0 0 0 0.00281905 l
+-0.889873 -0.20859 -0.887836 -0.196856 0 0 0 0.00281905 l
+-0.889873 -0.20859 -0.883921 -0.213445 0 0 0 0.00281905 l
+-0.360587 -0.00117533 -0.358574 0.00853546 0 0 0 0.00281905 l
+-0.360587 -0.00117533 -0.364179 -0.0114705 0 0 0 0.00281905 l
+0.698812 0.359616 0.705895 0.347719 0 0 0 0.00281905 l
+0.698812 0.359616 0.709864 0.364895 0 0 0 0.00281905 l
+-0.870821 -0.0924164 -0.866412 -0.109302 0 0 0 0.00281905 l
+-0.870821 -0.0924164 -0.857619 -0.0790086 0 0 0 0.00281905 l
+-0.340081 0.924799 -0.344168 0.937169 0 0 0 0.00281905 l
+-0.340081 0.924799 -0.322975 0.928799 0 0 0 0.00281905 l
+-0.290278 0.690846 -0.292166 0.698567 0 0 0 0.00281905 l
+-0.290278 0.690846 -0.30287 0.682252 0 0 0 0.00281905 l
+0.601446 0.631762 0.596814 0.630852 0 0 0 0.00281905 l
+-0.891921 -0.138445 -0.900706 -0.142356 0 0 0 0.00281905 l
+0.65127 0.539962 0.651015 0.524361 0 0 0 0.00281905 l
+0.65127 0.539962 0.638397 0.541501 0 0 0 0.00281905 l
+-0.256792 -0.489948 -0.251535 -0.488557 0 0 0 0.00281905 l
+-0.256792 -0.489948 -0.267807 -0.491926 0 0 0 0.00281905 l
+0.461675 -0.83643 0.447366 -0.828168 0 0 0 0.00281905 l
+-0.853908 0.0948758 -0.857489 0.10738 0 0 0 0.00281905 l
+-0.853908 0.0948758 -0.835468 0.0988961 0 0 0 0.00281905 l
+-0.853908 0.0948758 -0.872125 0.090655 0 0 0 0.00281905 l
+-0.50939 -0.117221 -0.507482 -0.105652 0 0 0 0.00281905 l
+-0.50939 -0.117221 -0.490691 -0.126787 0 0 0 0.00281905 l
+-0.50939 -0.117221 -0.523005 -0.111177 0 0 0 0.00281905 l
+-0.420462 -0.354003 -0.424112 -0.367534 0 0 0 0.00281905 l
+-0.420462 -0.354003 -0.437854 -0.352338 0 0 0 0.00281905 l
+-0.456939 -0.0659617 -0.449571 -0.069077 0 0 0 0.00281905 l
+-0.456939 -0.0659617 -0.46484 -0.0794619 0 0 0 0.00281905 l
+-0.456939 -0.0659617 -0.473459 -0.0562206 0 0 0 0.00281905 l
+-0.11269 -0.651261 -0.111249 -0.640397 0 0 0 0.00281905 l
+-0.11269 -0.651261 -0.118721 -0.655345 0 0 0 0.00281905 l
+0.771589 -0.12776 0.77191 -0.132156 0 0 0 0.00281905 l
+0.623373 0.0350129 0.634755 0.0226904 0 0 0 0.00281905 l
+0.623373 0.0350129 0.606785 0.0468362 0 0 0 0.00281905 l
+0.713076 -0.12764 0.714321 -0.117539 0 0 0 0.00281905 l
+0.713076 -0.12764 0.702178 -0.139947 0 0 0 0.00281905 l
+-0.723371 0.331338 -0.714133 0.336421 0 0 0 0.00281905 l
+-0.723371 0.331338 -0.728682 0.328992 0 0 0 0.00281905 l
+0.848544 -0.00604996 0.861585 0.00371509 0 0 0 0.00281905 l
+0.848544 -0.00604996 0.848 -0.010964 0 0 0 0.00281905 l
+0.264406 0.195295 0.276596 0.194344 0 0 0 0.00281905 l
+0.264406 0.195295 0.245335 0.195889 0 0 0 0.00281905 l
+-0.39792 0.617356 -0.391989 0.606799 0 0 0 0.00281905 l
+-0.39792 0.617356 -0.40721 0.622151 0 0 0 0.00281905 l
+0.308352 0.135018 0.307095 0.148788 0 0 0 0.00281905 l
+0.308352 0.135018 0.292639 0.128123 0 0 0 0.00281905 l
+0.811854 -0.354739 0.826166 -0.372423 0 0 0 0.00281905 l
+0.811854 -0.354739 0.809356 -0.352088 0 0 0 0.00281905 l
+0.178398 0.229837 0.19198 0.232645 0 0 0 0.00281905 l
+0.178398 0.229837 0.170905 0.244406 0 0 0 0.00281905 l
+0.178398 0.229837 0.174868 0.222115 0 0 0 0.00281905 l
+0.312506 -0.518838 0.312246 -0.538192 0 0 0 0.00281905 l
+0.312506 -0.518838 0.311546 -0.517578 0 0 0 0.00281905 l
+0.416894 0.139221 0.425089 0.135096 0 0 0 0.00281905 l
+0.416894 0.139221 0.417256 0.147472 0 0 0 0.00281905 l
+0.416894 0.139221 0.412743 0.140121 0 0 0 0.00281905 l
+-0.0746222 0.889889 -0.0567037 0.898214 0 0 0 0.00281905 l
+-0.0746222 0.889889 -0.0705677 0.881325 0 0 0 0.00281905 l
+-0.0746222 0.889889 -0.0872682 0.891965 0 0 0 0.00281905 l
+0.251122 0.180045 0.245335 0.195889 0 0 0 0.00281905 l
+0.870763 0.108485 0.872086 0.105794 0 0 0 0.00281905 l
+0.870763 0.108485 0.862012 0.103055 0 0 0 0.00281905 l
+-0.254183 -0.892282 -0.249699 -0.873503 0 0 0 0.00281905 l
+-0.254183 -0.892282 -0.242304 -0.892012 0 0 0 0.00281905 l
+0.456284 0.685642 0.474353 0.683127 0 0 0 0.00281905 l
+0.456284 0.685642 0.455966 0.685542 0 0 0 0.00281905 l
+0.0530301 0.00491423 0.0526059 0.0210699 0 0 0 0.00281905 l
+0.0530301 0.00491423 0.0674823 -0.00762229 0 0 0 0.00281905 l
+0.0530301 0.00491423 0.0464922 0.0032031 0 0 0 0.00281905 l
+-0.624409 -0.159302 -0.626343 -0.139335 0 0 0 0.00281905 l
+-0.624409 -0.159302 -0.631496 -0.172217 0 0 0 0.00281905 l
+0.261532 -0.695079 0.270334 -0.694823 0 0 0 0.00281905 l
+0.261532 -0.695079 0.256388 -0.700134 0 0 0 0.00281905 l
+0.261532 -0.695079 0.261222 -0.693823 0 0 0 0.00281905 l
+-0.379721 -0.161118 -0.362233 -0.162009 0 0 0 0.00281905 l
+-0.379721 -0.161118 -0.387994 -0.151597 0 0 0 0.00281905 l
+0.128729 0.00174263 0.137925 0.00643126 0 0 0 0.00281905 l
+0.128729 0.00174263 0.121551 0.00496176 0 0 0 0.00281905 l
+-0.444111 0.338088 -0.434929 0.325732 0 0 0 0.00281905 l
+-0.444111 0.338088 -0.438617 0.34292 0 0 0 0.00281905 l
+0.0967379 0.843532 0.0986654 0.836064 0 0 0 0.00281905 l
+0.0967379 0.843532 0.111441 0.849678 0 0 0 0.00281905 l
+0.224441 -0.608386 0.220241 -0.622547 0 0 0 0.00281905 l
+0.224441 -0.608386 0.224697 -0.6049 0 0 0 0.00281905 l
+0.224441 -0.608386 0.229489 -0.607493 0 0 0 0.00281905 l
+-0.413603 0.374728 -0.415126 0.382355 0 0 0 0.00281905 l
+-0.413603 0.374728 -0.406115 0.367839 0 0 0 0.00281905 l
+-0.413603 0.374728 -0.420571 0.366819 0 0 0 0.00281905 l
+0.5761 -0.46264 0.579438 -0.464655 0 0 0 0.00281905 l
+0.381794 0.342803 0.374242 0.338368 0 0 0 0.00281905 l
+0.742542 0.464396 0.744234 0.483391 0 0 0 0.00281905 l
+0.742542 0.464396 0.736852 0.451863 0 0 0 0.00281905 l
+0.174278 0.869106 0.187225 0.881743 0 0 0 0.00281905 l
+0.174278 0.869106 0.153056 0.877776 0 0 0 0.00281905 l
+-0.488356 0.832801 -0.483647 0.828384 0 0 0 0.00281905 l
+-0.488356 0.832801 -0.497582 0.844561 0 0 0 0.00281905 l
+-0.450341 0.576168 -0.448507 0.577561 0 0 0 0.00281905 l
+0.0343803 -0.0842026 0.0466489 -0.0704684 0 0 0 0.00281905 l
+0.0343803 -0.0842026 0.0301897 -0.081611 0 0 0 0.00281905 l
+-0.765033 -0.453068 -0.75095 -0.438058 0 0 0 0.00281905 l
+-0.00185276 -0.710262 0.00131251 -0.716806 0 0 0 0.00281905 l
+-0.00185276 -0.710262 0.00751042 -0.700447 0 0 0 0.00281905 l
+-0.00185276 -0.710262 -0.0107231 -0.718546 0 0 0 0.00281905 l
+0.356564 0.517034 0.353775 0.538438 0 0 0 0.00281905 l
+0.356564 0.517034 0.368633 0.505972 0 0 0 0.00281905 l
+0.467472 0.0223417 0.479873 0.0318322 0 0 0 0.00281905 l
+0.467472 0.0223417 0.449501 0.0224063 0 0 0 0.00281905 l
+-0.136952 0.277406 -0.137454 0.291331 0 0 0 0.00281905 l
+-0.136952 0.277406 -0.136598 0.273804 0 0 0 0.00281905 l
+0.251627 0.897977 0.249381 0.888045 0 0 0 0.00281905 l
+0.251627 0.897977 0.255989 0.912561 0 0 0 0.00281905 l
+0.251627 0.897977 0.239904 0.89836 0 0 0 0.00281905 l
+0.301657 -0.884231 0.313325 -0.895207 0 0 0 0.00281905 l
+0.301657 -0.884231 0.298412 -0.889157 0 0 0 0.00281905 l
+-0.0502248 -0.721795 -0.0484475 -0.729703 0 0 0 0.00281905 l
+-0.0502248 -0.721795 -0.0541525 -0.720993 0 0 0 0.00281905 l
+-0.335143 -0.697747 -0.33118 -0.696436 0 0 0 0.00281905 l
+-0.335143 -0.697747 -0.346709 -0.709464 0 0 0 0.00281905 l
+0.399311 -0.515174 0.406614 -0.515963 0 0 0 0.00281905 l
+0.399311 -0.515174 0.398519 -0.517217 0 0 0 0.00281905 l
+0.449501 0.0224063 0.447412 0.0397224 0 0 0 0.00281905 l
+0.449501 0.0224063 0.467472 0.0223417 0 0 0 0.00281905 l
+0.449501 0.0224063 0.439386 0.0171061 0 0 0 0.00281905 l
+0.926581 0.138677 0.921923 0.151857 0 0 0 0.00281905 l
+0.926581 0.138677 0.922427 0.137022 0 0 0 0.00281905 l
+0.131629 -0.335896 0.141916 -0.345739 0 0 0 0.00281905 l
+-0.165775 -0.285933 -0.1673 -0.27514 0 0 0 0.00281905 l
+-0.165775 -0.285933 -0.152763 -0.297745 0 0 0 0.00281905 l
+0.326777 -0.625929 0.34369 -0.626307 0 0 0 0.00281905 l
+0.326777 -0.625929 0.314845 -0.635999 0 0 0 0.00281905 l
+0.0153318 0.197463 0.0160789 0.198676 0 0 0 0.00281905 l
+0.0153318 0.197463 0.0029867 0.189186 0 0 0 0.00281905 l
+0.737068 0.349777 0.73541 0.354395 0 0 0 0.00281905 l
+0.286919 -0.000591498 0.293281 -0.0148111 0 0 0 0.00281905 l
+0.348435 0.715339 0.344487 0.696933 0 0 0 0.00281905 l
+0.348435 0.715339 0.353574 0.725216 0 0 0 0.00281905 l
+0.0718049 0.654125 0.0831658 0.65422 0 0 0 0.00281905 l
+0.0718049 0.654125 0.0626334 0.659331 0 0 0 0.00281905 l
+0.367063 0.671708 0.360494 0.683981 0 0 0 0.00281905 l
+0.367063 0.671708 0.38101 0.670285 0 0 0 0.00281905 l
+0.367063 0.671708 0.363052 0.669687 0 0 0 0.00281905 l
+0.825176 0.213025 0.82949 0.231415 0 0 0 0.00281905 l
+0.825176 0.213025 0.824082 0.211977 0 0 0 0.00281905 l
+0.0958835 -0.551611 0.0874055 -0.541674 0 0 0 0.00281905 l
+0.0958835 -0.551611 0.108505 -0.550957 0 0 0 0.00281905 l
+0.0958835 -0.551611 0.0869546 -0.561376 0 0 0 0.00281905 l
+-0.888128 -0.340012 -0.874449 -0.347159 0 0 0 0.00281905 l
+-0.888128 -0.340012 -0.896639 -0.340494 0 0 0 0.00281905 l
+0.703022 0.0382721 0.695807 0.0525798 0 0 0 0.00281905 l
+0.703022 0.0382721 0.714029 0.0443691 0 0 0 0.00281905 l
+0.703022 0.0382721 0.69659 0.0276552 0 0 0 0.00281905 l
+-0.105436 -0.407656 -0.0970157 -0.422405 0 0 0 0.00281905 l
+-0.105436 -0.407656 -0.101609 -0.399938 0 0 0 0.00281905 l
+0.132326 0.945569 0.12967 0.934646 0 0 0 0.00281905 l
+-0.327603 0.390484 -0.318258 0.384071 0 0 0 0.00281905 l
+-0.327603 0.390484 -0.342521 0.390879 0 0 0 0.00281905 l
+-0.415368 0.735076 -0.408832 0.753133 0 0 0 0.00281905 l
+-0.415368 0.735076 -0.41801 0.734096 0 0 0 0.00281905 l
+0.433908 -0.703168 0.432968 -0.716918 0 0 0 0.00281905 l
+0.0869546 -0.561376 0.100464 -0.570456 0 0 0 0.00281905 l
+0.0869546 -0.561376 0.0958835 -0.551611 0 0 0 0.00281905 l
+-0.0387106 0.658106 -0.0499188 0.644873 0 0 0 0.00281905 l
+-0.0387106 0.658106 -0.0465954 0.666337 0 0 0 0.00281905 l
+-0.0387106 0.658106 -0.0338108 0.659116 0 0 0 0.00281905 l
+-0.157168 -0.167997 -0.158204 -0.153139 0 0 0 0.00281905 l
+-0.157168 -0.167997 -0.157328 -0.171435 0 0 0 0.00281905 l
+0.208862 -0.865358 0.216515 -0.849599 0 0 0 0.00281905 l
+0.208862 -0.865358 0.200998 -0.863349 0 0 0 0.00281905 l
+-0.553562 0.562988 -0.539688 0.567085 0 0 0 0.00281905 l
+-0.553562 0.562988 -0.56109 0.56863 0 0 0 0.00281905 l
+0.132745 0.173064 0.125318 0.189865 0 0 0 0.00281905 l
+0.132745 0.173064 0.13531 0.167385 0 0 0 0.00281905 l
+-0.816625 -0.0480042 -0.820198 -0.0379837 0 0 0 0.00281905 l
+-0.816625 -0.0480042 -0.806435 -0.0522655 0 0 0 0.00281905 l
+-0.410159 0.688191 -0.414007 0.678662 0 0 0 0.00281905 l
+-0.410159 0.688191 -0.410502 0.704015 0 0 0 0.00281905 l
+0.0545617 -0.436461 0.0623083 -0.432772 0 0 0 0.00281905 l
+0.0545617 -0.436461 0.0551177 -0.438607 0 0 0 0.00281905 l
+0.0545617 -0.436461 0.0532444 -0.431365 0 0 0 0.00281905 l
+0.0545617 -0.436461 0.0528841 -0.436639 0 0 0 0.00281905 l
+-0.88222 0.0308066 -0.872045 0.0364239 0 0 0 0.00281905 l
+-0.119503 0.185983 -0.117445 0.177399 0 0 0 0.00281905 l
+-0.119503 0.185983 -0.126743 0.185802 0 0 0 0.00281905 l
+0.508216 0.435253 0.523064 0.431084 0 0 0 0.00281905 l
+0.508216 0.435253 0.502152 0.423863 0 0 0 0.00281905 l
+-0.490305 0.0998989 -0.495373 0.103805 0 0 0 0.00281905 l
+-0.459282 -0.830735 -0.457782 -0.82472 0 0 0 0.00281905 l
+0.520931 0.526558 0.537052 0.538093 0 0 0 0.00281905 l
+0.520931 0.526558 0.515144 0.526468 0 0 0 0.00281905 l
+0.0642345 -0.22297 0.0788921 -0.225319 0 0 0 0.00281905 l
+0.0642345 -0.22297 0.0643814 -0.23302 0 0 0 0.00281905 l
+-0.267807 -0.491926 -0.256792 -0.489948 0 0 0 0.00281905 l
+-0.267807 -0.491926 -0.275168 -0.50375 0 0 0 0.00281905 l
+0.059482 0.332173 0.054131 0.344527 0 0 0 0.00281905 l
+0.059482 0.332173 0.0681678 0.334997 0 0 0 0.00281905 l
+-0.855926 -0.42098 -0.857238 -0.430194 0 0 0 0.00281905 l
+-0.855926 -0.42098 -0.862578 -0.417462 0 0 0 0.00281905 l
+-0.027122 -0.000579469 -0.020388 0.0119641 0 0 0 0.00281905 l
+-0.027122 -0.000579469 -0.0165989 -0.00781046 0 0 0 0.00281905 l
+0.659141 0.482139 0.665372 0.489621 0 0 0 0.00281905 l
+0.659141 0.482139 0.664129 0.478442 0 0 0 0.00281905 l
+0.659141 0.482139 0.653076 0.486697 0 0 0 0.00281905 l
+-0.737577 0.0494016 -0.739033 0.058379 0 0 0 0.00281905 l
+-0.525165 0.698012 -0.522488 0.687516 0 0 0 0.00281905 l
+-0.525165 0.698012 -0.527698 0.703046 0 0 0 0.00281905 l
+0.696638 -0.00812394 0.704229 -0.016223 0 0 0 0.00281905 l
+0.696638 -0.00812394 0.699856 -0.00523386 0 0 0 0.00281905 l
+0.805731 -0.243221 0.816188 -0.243864 0 0 0 0.00281905 l
+0.805731 -0.243221 0.807157 -0.254347 0 0 0 0.00281905 l
+-0.495399 0.210341 -0.487846 0.224646 0 0 0 0.00281905 l
+-0.495399 0.210341 -0.510952 0.214924 0 0 0 0.00281905 l
+0.208526 -0.659575 0.206697 -0.664915 0 0 0 0.00281905 l
+0.208526 -0.659575 0.198149 -0.652933 0 0 0 0.00281905 l
+0.0190522 0.65544 0.0312733 0.653379 0 0 0 0.00281905 l
+0.0190522 0.65544 0.0137035 0.652096 0 0 0 0.00281905 l
+0.882583 -0.42218 0.890747 -0.414611 0 0 0 0.00281905 l
+0.882583 -0.42218 0.879112 -0.412237 0 0 0 0.00281905 l
+0.882583 -0.42218 0.890339 -0.42827 0 0 0 0.00281905 l
+0.882583 -0.42218 0.876936 -0.425273 0 0 0 0.00281905 l
+-0.282486 -0.423494 -0.287602 -0.429367 0 0 0 0.00281905 l
+-0.282486 -0.423494 -0.283111 -0.418102 0 0 0 0.00281905 l
+-0.255554 -0.3406 -0.239855 -0.349289 0 0 0 0.00281905 l
+-0.255554 -0.3406 -0.244432 -0.331038 0 0 0 0.00281905 l
+-0.255554 -0.3406 -0.26295 -0.349601 0 0 0 0.00281905 l
+0.0467613 -0.170992 0.041199 -0.153382 0 0 0 0.00281905 l
+0.0467613 -0.170992 0.0373998 -0.186192 0 0 0 0.00281905 l
+0.64706 -0.729154 0.640003 -0.707862 0 0 0 0.00281905 l
+0.64706 -0.729154 0.658532 -0.730983 0 0 0 0.00281905 l
+0.64706 -0.729154 0.650099 -0.741363 0 0 0 0.00281905 l
+-0.64814 0.264719 -0.640238 0.261852 0 0 0 0.00281905 l
+-0.64814 0.264719 -0.651977 0.25292 0 0 0 0.00281905 l
+0.0661742 0.916341 0.0766732 0.92613 0 0 0 0.00281905 l
+0.129981 0.837835 0.133606 0.836049 0 0 0 0.00281905 l
+-0.475921 0.0140014 -0.480578 0.02679 0 0 0 0.00281905 l
+-0.475921 0.0140014 -0.472082 0.014812 0 0 0 0.00281905 l
+0.0582546 0.674468 0.0656404 0.674602 0 0 0 0.00281905 l
+0.0582546 0.674468 0.0443173 0.665247 0 0 0 0.00281905 l
+0.556627 -0.210148 0.570933 -0.225316 0 0 0 0.00281905 l
+0.556627 -0.210148 0.559568 -0.205229 0 0 0 0.00281905 l
+0.556627 -0.210148 0.533341 -0.211796 0 0 0 0.00281905 l
+-0.0087273 -0.219641 0.00156488 -0.22872 0 0 0 0.00281905 l
+-0.0087273 -0.219641 -0.0154171 -0.212508 0 0 0 0.00281905 l
+0.569329 -0.776701 0.572972 -0.759721 0 0 0 0.00281905 l
+0.569329 -0.776701 0.589069 -0.785539 0 0 0 0.00281905 l
+0.569329 -0.776701 0.547924 -0.778083 0 0 0 0.00281905 l
+-0.392214 0.173111 -0.393938 0.189907 0 0 0 0.00281905 l
+-0.392214 0.173111 -0.382679 0.166688 0 0 0 0.00281905 l
+0.304278 0.635915 0.309464 0.646158 0 0 0 0.00281905 l
+0.304278 0.635915 0.321754 0.631699 0 0 0 0.00281905 l
+0.304278 0.635915 0.29588 0.636024 0 0 0 0.00281905 l
+-0.438114 -0.276322 -0.446832 -0.265248 0 0 0 0.00281905 l
+-0.885769 -0.418478 -0.882836 -0.423835 0 0 0 0.00281905 l
+-0.885769 -0.418478 -0.884225 -0.412282 0 0 0 0.00281905 l
+-0.623555 -0.710551 -0.6199 -0.719141 0 0 0 0.00281905 l
+-0.623555 -0.710551 -0.63514 -0.698314 0 0 0 0.00281905 l
+-0.623555 -0.710551 -0.63888 -0.718126 0 0 0 0.00281905 l
+0.520598 0.138694 0.533824 0.134311 0 0 0 0.00281905 l
+0.520598 0.138694 0.513299 0.14065 0 0 0 0.00281905 l
+0.544399 0.58672 0.554567 0.598977 0 0 0 0.00281905 l
+0.544399 0.58672 0.53825 0.581333 0 0 0 0.00281905 l
+0.393043 -0.464873 0.392037 -0.474552 0 0 0 0.00281905 l
+0.393043 -0.464873 0.396938 -0.463511 0 0 0 0.00281905 l
+0.393043 -0.464873 0.386067 -0.465405 0 0 0 0.00281905 l
+-0.628212 0.25628 -0.619943 0.255085 0 0 0 0.00281905 l
+-0.628212 0.25628 -0.633058 0.24512 0 0 0 0.00281905 l
+-0.628212 0.25628 -0.640238 0.261852 0 0 0 0.00281905 l
+0.749546 -0.067776 0.760142 -0.0760978 0 0 0 0.00281905 l
+0.749546 -0.067776 0.736018 -0.081899 0 0 0 0.00281905 l
+0.738918 -0.664508 0.74593 -0.665095 0 0 0 0.00281905 l
+0.738918 -0.664508 0.724206 -0.664359 0 0 0 0.00281905 l
+0.525325 -0.627025 0.516224 -0.646126 0 0 0 0.00281905 l
+0.525325 -0.627025 0.533996 -0.622429 0 0 0 0.00281905 l
+0.525325 -0.627025 0.520869 -0.619885 0 0 0 0.00281905 l
+0.426711 -0.192921 0.42633 -0.198818 0 0 0 0.00281905 l
+0.426711 -0.192921 0.421517 -0.194016 0 0 0 0.00281905 l
+-0.893552 0.407985 -0.893486 0.403122 0 0 0 0.00281905 l
+-0.893552 0.407985 -0.881141 0.420081 0 0 0 0.00281905 l
+-0.893552 0.407985 -0.90268 0.405578 0 0 0 0.00281905 l
+-0.542071 -0.679928 -0.540188 -0.678303 0 0 0 0.00281905 l
+-0.542071 -0.679928 -0.557202 -0.683338 0 0 0 0.00281905 l
+0.567834 -0.0666336 0.569116 -0.0669796 0 0 0 0.00281905 l
+0.395549 -0.0177963 0.400747 -0.033372 0 0 0 0.00281905 l
+0.395549 -0.0177963 0.398113 -0.00919072 0 0 0 0.00281905 l
+0.0340053 0.408223 0.0495605 0.412473 0 0 0 0.00281905 l
+0.0340053 0.408223 0.0294556 0.413847 0 0 0 0.00281905 l
+0.721541 0.083414 0.734246 0.078957 0 0 0 0.00281905 l
+0.721541 0.083414 0.720031 0.0686332 0 0 0 0.00281905 l
+0.721541 0.083414 0.714044 0.0853493 0 0 0 0.00281905 l
+0.229043 -0.950286 0.228666 -0.951708 0 0 0 0.00281905 l
+-0.17384 -0.517685 -0.164553 -0.5233 0 0 0 0.00281905 l
+-0.17384 -0.517685 -0.176436 -0.530245 0 0 0 0.00281905 l
+0.191791 0.34716 0.19705 0.336669 0 0 0 0.00281905 l
+0.191791 0.34716 0.194312 0.35002 0 0 0 0.00281905 l
+0.191791 0.34716 0.187211 0.344379 0 0 0 0.00281905 l
+-0.709207 -0.221777 -0.700306 -0.230823 0 0 0 0.00281905 l
+-0.709207 -0.221777 -0.707001 -0.208169 0 0 0 0.00281905 l
+-0.709207 -0.221777 -0.723179 -0.221344 0 0 0 0.00281905 l
+-0.163432 0.0955439 -0.149449 0.0790038 0 0 0 0.00281905 l
+-0.163432 0.0955439 -0.17249 0.0762203 0 0 0 0.00281905 l
+0.541181 0.216227 0.552258 0.225627 0 0 0 0.00281905 l
+0.541181 0.216227 0.552909 0.20062 0 0 0 0.00281905 l
+-0.584045 0.686991 -0.570894 0.685069 0 0 0 0.00281905 l
+-0.584045 0.686991 -0.583424 0.676087 0 0 0 0.00281905 l
+-0.584045 0.686991 -0.595225 0.70039 0 0 0 0.00281905 l
+-0.510952 0.214924 -0.495399 0.210341 0 0 0 0.00281905 l
+-0.510952 0.214924 -0.51029 0.203439 0 0 0 0.00281905 l
+-0.510952 0.214924 -0.51745 0.218923 0 0 0 0.00281905 l
+0.747927 -0.402132 0.753811 -0.42026 0 0 0 0.00281905 l
+-0.936026 0.149292 -0.949953 0.167987 0 0 0 0.00281905 l
+-0.936026 0.149292 -0.93593 0.148362 0 0 0 0.00281905 l
+0.938897 0.278609 0.951333 0.293476 0 0 0 0.00281905 l
+0.938897 0.278609 0.941022 0.271461 0 0 0 0.00281905 l
+0.576842 0.38169 0.577711 0.378431 0 0 0 0.00281905 l
+0.576842 0.38169 0.560972 0.384013 0 0 0 0.00281905 l
+-0.785913 0.186794 -0.774617 0.17908 0 0 0 0.00281905 l
+-0.785913 0.186794 -0.78862 0.186264 0 0 0 0.00281905 l
+0.519862 -0.505883 0.51367 -0.505498 0 0 0 0.00281905 l
+-0.495998 0.0834818 -0.493155 0.0733156 0 0 0 0.00281905 l
+-0.495998 0.0834818 -0.502375 0.091121 0 0 0 0.00281905 l
+-0.622956 0.691068 -0.649996 0.684267 0 0 0 0.00281905 l
+0.0403615 -0.819917 0.0344357 -0.826531 0 0 0 0.00281905 l
+0.573535 -0.692124 0.592054 -0.697949 0 0 0 0.00281905 l
+0.573535 -0.692124 0.56271 -0.710118 0 0 0 0.00281905 l
+0.573535 -0.692124 0.572915 -0.691669 0 0 0 0.00281905 l
+-0.230684 -0.960087 -0.222037 -0.956741 0 0 0 0.00281905 l
+0.864759 -0.40803 0.868956 -0.404247 0 0 0 0.00281905 l
+0.864759 -0.40803 0.864499 -0.40857 0 0 0 0.00281905 l
+0.396669 -0.243818 0.391458 -0.233928 0 0 0 0.00281905 l
+0.512347 0.0116944 0.503612 0.00190704 0 0 0 0.00281905 l
+0.512347 0.0116944 0.51156 0.0173723 0 0 0 0.00281905 l
+-0.993612 -0.0938908 -0.986874 -0.0868779 0 0 0 0.00281905 l
+0.455712 0.0989044 0.459833 0.110293 0 0 0 0.00281905 l
+0.455712 0.0989044 0.45799 0.0925421 0 0 0 0.00281905 l
+0.695944 0.414457 0.692742 0.432786 0 0 0 0.00281905 l
+0.695944 0.414457 0.686687 0.408981 0 0 0 0.00281905 l
+-0.565713 -0.128772 -0.575823 -0.13599 0 0 0 0.00281905 l
+-0.563431 0.456629 -0.575185 0.45215 0 0 0 0.00281905 l
+-0.0484475 -0.729703 -0.0502248 -0.721795 0 0 0 0.00281905 l
+-0.0484475 -0.729703 -0.0421546 -0.740398 0 0 0 0.00281905 l
+0.0740701 0.762218 0.0716402 0.747798 0 0 0 0.00281905 l
+0.0740701 0.762218 0.0726546 0.767055 0 0 0 0.00281905 l
+-0.567021 0.118317 -0.561948 0.117445 0 0 0 0.00281905 l
+-0.567021 0.118317 -0.57714 0.131851 0 0 0 0.00281905 l
+0.788649 0.494744 0.791256 0.493034 0 0 0 0.00281905 l
+-0.602143 -0.261087 -0.584726 -0.263865 0 0 0 0.00281905 l
+-0.602143 -0.261087 -0.608841 -0.272386 0 0 0 0.00281905 l
+0.310328 0.668881 0.303412 0.654062 0 0 0 0.00281905 l
+0.397048 -0.456328 0.396938 -0.463511 0 0 0 0.00281905 l
+0.397048 -0.456328 0.400765 -0.454313 0 0 0 0.00281905 l
+0.144566 -0.128166 0.154214 -0.121928 0 0 0 0.00281905 l
+0.144566 -0.128166 0.157663 -0.143199 0 0 0 0.00281905 l
+0.144566 -0.128166 0.141791 -0.124999 0 0 0 0.00281905 l
+-0.270843 -0.670837 -0.264465 -0.678891 0 0 0 0.00281905 l
+-0.96644 -0.249276 -0.966718 -0.247739 0 0 0 0.00281905 l
+-0.96644 -0.249276 -0.960749 -0.261062 0 0 0 0.00281905 l
+0.439836 0.740547 0.437309 0.747712 0 0 0 0.00281905 l
+0.439836 0.740547 0.43393 0.734046 0 0 0 0.00281905 l
+-0.85945 0.480734 -0.8481 0.487001 0 0 0 0.00281905 l
+-0.563199 -0.143348 -0.562868 -0.146255 0 0 0 0.00281905 l
+-0.563199 -0.143348 -0.552623 -0.138977 0 0 0 0.00281905 l
+-0.563199 -0.143348 -0.575823 -0.13599 0 0 0 0.00281905 l
+-0.155922 -0.674259 -0.149574 -0.667372 0 0 0 0.00281905 l
+0.704755 0.121388 0.702572 0.113352 0 0 0 0.00281905 l
+0.704755 0.121388 0.701798 0.12952 0 0 0 0.00281905 l
+0.584138 -0.804638 0.571265 -0.817467 0 0 0 0.00281905 l
+0.584138 -0.804638 0.595613 -0.793738 0 0 0 0.00281905 l
+0.0551177 -0.438607 0.0545617 -0.436461 0 0 0 0.00281905 l
+-0.652911 0.469762 -0.638583 0.465598 0 0 0 0.00281905 l
+0.262169 0.546691 0.266757 0.541485 0 0 0 0.00281905 l
+0.262169 0.546691 0.253982 0.552197 0 0 0 0.00281905 l
+-0.200865 -0.589863 -0.202493 -0.580639 0 0 0 0.00281905 l
+-0.200865 -0.589863 -0.198903 -0.597679 0 0 0 0.00281905 l
+0.1006 0.992089 0.123875 0.989201 0 0 0 0.00281905 l
+-0.133424 -0.504989 -0.119089 -0.5204 0 0 0 0.00281905 l
+-0.133424 -0.504989 -0.151187 -0.511663 0 0 0 0.00281905 l
+0.0132054 -0.855591 0.0272587 -0.854068 0 0 0 0.00281905 l
+-0.603358 -0.335057 -0.607449 -0.320658 0 0 0 0.00281905 l
+-0.603358 -0.335057 -0.583502 -0.332021 0 0 0 0.00281905 l
+-0.603358 -0.335057 -0.605813 -0.340133 0 0 0 0.00281905 l
+-0.551789 -0.478057 -0.550417 -0.47467 0 0 0 0.00281905 l
+0.401602 -0.0848418 0.400551 -0.0810123 0 0 0 0.00281905 l
+0.401602 -0.0848418 0.409886 -0.0883579 0 0 0 0.00281905 l
+0.401602 -0.0848418 0.397883 -0.0870992 0 0 0 0.00281905 l
+0.628794 0.324449 0.622274 0.311939 0 0 0 0.00281905 l
+0.628794 0.324449 0.613926 0.33196 0 0 0 0.00281905 l
+-0.536132 0.653475 -0.544495 0.652729 0 0 0 0.00281905 l
+-0.840519 -0.162066 -0.842727 -0.150288 0 0 0 0.00281905 l
+-0.840519 -0.162066 -0.837752 -0.161693 0 0 0 0.00281905 l
+-0.840519 -0.162066 -0.851841 -0.161878 0 0 0 0.00281905 l
+0.312849 -0.437373 0.300656 -0.424381 0 0 0 0.00281905 l
+0.967438 -0.147442 0.972557 -0.152624 0 0 0 0.00281905 l
+0.967438 -0.147442 0.964439 -0.148796 0 0 0 0.00281905 l
+-0.976324 -0.00284653 -0.959543 0.000243254 0 0 0 0.00281905 l
+-0.976324 -0.00284653 -0.981093 -0.00869599 0 0 0 0.00281905 l
+0.00507685 0.850444 0.00534676 0.85889 0 0 0 0.00281905 l
+0.00507685 0.850444 0.00265448 0.845691 0 0 0 0.00281905 l
+0.00507685 0.850444 -0.00546681 0.853226 0 0 0 0.00281905 l
+0.84399 0.482954 0.838072 0.510561 0 0 0 0.00281905 l
+0.84399 0.482954 0.850005 0.479454 0 0 0 0.00281905 l
+0.847103 0.181788 0.862521 0.176256 0 0 0 0.00281905 l
+0.847103 0.181788 0.847175 0.184648 0 0 0 0.00281905 l
+-0.116002 -0.398511 -0.108488 -0.394721 0 0 0 0.00281905 l
+-0.116002 -0.398511 -0.120046 -0.407505 0 0 0 0.00281905 l
+0.370927 -0.100477 0.381103 -0.110534 0 0 0 0.00281905 l
+0.370927 -0.100477 0.357471 -0.0910324 0 0 0 0.00281905 l
+0.734283 0.590491 0.743666 0.57619 0 0 0 0.00281905 l
+0.734283 0.590491 0.729906 0.590029 0 0 0 0.00281905 l
+0.397009 0.571335 0.401705 0.577364 0 0 0 0.00281905 l
+0.397009 0.571335 0.377683 0.556547 0 0 0 0.00281905 l
+-0.932398 0.186754 -0.9208 0.16953 0 0 0 0.00281905 l
+-0.932398 0.186754 -0.922577 0.193622 0 0 0 0.00281905 l
+-0.932398 0.186754 -0.944281 0.187624 0 0 0 0.00281905 l
+-0.607822 -0.605823 -0.614658 -0.595104 0 0 0 0.00281905 l
+-0.607822 -0.605823 -0.614797 -0.60887 0 0 0 0.00281905 l
+-0.716477 -0.426087 -0.724544 -0.423067 0 0 0 0.00281905 l
+-0.64963 0.124316 -0.643641 0.12767 0 0 0 0.00281905 l
+-0.64963 0.124316 -0.659829 0.136879 0 0 0 0.00281905 l
+0.569116 -0.0669796 0.572913 -0.0752311 0 0 0 0.00281905 l
+0.569116 -0.0669796 0.571925 -0.0598065 0 0 0 0.00281905 l
+0.569116 -0.0669796 0.567834 -0.0666336 0 0 0 0.00281905 l
+-0.568053 0.080883 -0.572038 0.0902452 0 0 0 0.00281905 l
+-0.568053 0.080883 -0.55741 0.0834508 0 0 0 0.00281905 l
+0.583048 0.698489 0.590118 0.695906 0 0 0 0.00281905 l
+0.583048 0.698489 0.576784 0.707147 0 0 0 0.00281905 l
+-0.340774 0.680304 -0.339962 0.692083 0 0 0 0.00281905 l
+-0.340774 0.680304 -0.358543 0.676815 0 0 0 0.00281905 l
+-0.907437 -0.0701222 -0.906686 -0.0679642 0 0 0 0.00281905 l
+-0.907437 -0.0701222 -0.909386 -0.0866346 0 0 0 0.00281905 l
+0.590093 -0.5788 0.587729 -0.58494 0 0 0 0.00281905 l
+0.739169 0.603542 0.730075 0.607005 0 0 0 0.00281905 l
+-0.0421232 0.735412 -0.0511121 0.745043 0 0 0 0.00281905 l
+-0.0421232 0.735412 -0.023499 0.731846 0 0 0 0.00281905 l
+-0.722228 -0.400106 -0.722474 -0.400092 0 0 0 0.00281905 l
+0.163718 0.0233704 0.157892 0.0372881 0 0 0 0.00281905 l
+0.163718 0.0233704 0.167618 0.0176222 0 0 0 0.00281905 l
+0.52777 -0.210128 0.513038 -0.194487 0 0 0 0.00281905 l
+0.52777 -0.210128 0.533341 -0.211796 0 0 0 0.00281905 l
+0.0878462 0.644527 0.0860512 0.632615 0 0 0 0.00281905 l
+0.0878462 0.644527 0.0831658 0.65422 0 0 0 0.00281905 l
+0.128163 0.228462 0.129657 0.227663 0 0 0 0.00281905 l
+0.480452 -0.279308 0.486304 -0.273548 0 0 0 0.00281905 l
+0.480452 -0.279308 0.477722 -0.272837 0 0 0 0.00281905 l
+0.480452 -0.279308 0.469718 -0.287103 0 0 0 0.00281905 l
+0.560625 -0.541823 0.564377 -0.553354 0 0 0 0.00281905 l
+0.560625 -0.541823 0.568179 -0.53132 0 0 0 0.00281905 l
+0.764849 0.207012 0.768108 0.194902 0 0 0 0.00281905 l
+0.764849 0.207012 0.777285 0.227256 0 0 0 0.00281905 l
+0.764849 0.207012 0.756068 0.198626 0 0 0 0.00281905 l
+-0.563969 -0.54973 -0.556872 -0.537646 0 0 0 0.00281905 l
+-0.563969 -0.54973 -0.566678 -0.563627 0 0 0 0.00281905 l
+-0.563969 -0.54973 -0.57727 -0.541351 0 0 0 0.00281905 l
+0.181798 0.892738 0.179863 0.91385 0 0 0 0.00281905 l
+0.181798 0.892738 0.186631 0.890063 0 0 0 0.00281905 l
+0.19727 0.182705 0.176952 0.178014 0 0 0 0.00281905 l
+0.235447 -0.963628 0.249685 -0.958293 0 0 0 0.00281905 l
+0.235447 -0.963628 0.228666 -0.951708 0 0 0 0.00281905 l
+0.580282 0.0317056 0.579974 0.0374239 0 0 0 0.00281905 l
+0.580282 0.0317056 0.57513 0.0312002 0 0 0 0.00281905 l
+0.899545 0.354165 0.914124 0.356067 0 0 0 0.00281905 l
+0.899545 0.354165 0.897424 0.367471 0 0 0 0.00281905 l
+0.504802 0.386286 0.511461 0.372436 0 0 0 0.00281905 l
+0.504802 0.386286 0.510031 0.396041 0 0 0 0.00281905 l
+0.0511689 0.227821 0.0609691 0.244968 0 0 0 0.00281905 l
+0.0511689 0.227821 0.0418622 0.237817 0 0 0 0.00281905 l
+-0.637978 0.738232 -0.647852 0.733913 0 0 0 0.00281905 l
+0.643548 0.486488 0.640746 0.500613 0 0 0 0.00281905 l
+0.643548 0.486488 0.653076 0.486697 0 0 0 0.00281905 l
+0.643548 0.486488 0.633748 0.481594 0 0 0 0.00281905 l
+-0.341215 -0.0772426 -0.347333 -0.0661738 0 0 0 0.00281905 l
+-0.341215 -0.0772426 -0.333743 -0.0734285 0 0 0 0.00281905 l
+0.359205 0.340136 0.359046 0.324055 0 0 0 0.00281905 l
+0.359205 0.340136 0.359047 0.344191 0 0 0 0.00281905 l
+0.359205 0.340136 0.374242 0.338368 0 0 0 0.00281905 l
+-0.420375 0.256325 -0.41951 0.248616 0 0 0 0.00281905 l
+-0.420375 0.256325 -0.434804 0.263445 0 0 0 0.00281905 l
+0.656052 -0.484536 0.656122 -0.49276 0 0 0 0.00281905 l
+0.656052 -0.484536 0.639392 -0.476488 0 0 0 0.00281905 l
+0.640641 -0.59143 0.647199 -0.577208 0 0 0 0.00281905 l
+0.640641 -0.59143 0.636358 -0.608404 0 0 0 0.00281905 l
+-0.36738 -0.546704 -0.377168 -0.556729 0 0 0 0.00281905 l
+-0.602797 0.738519 -0.596428 0.733788 0 0 0 0.00281905 l
+-0.602797 0.738519 -0.61342 0.723451 0 0 0 0.00281905 l
+-0.602797 0.738519 -0.609381 0.748063 0 0 0 0.00281905 l
+0.412178 0.0489788 0.410052 0.0557325 0 0 0 0.00281905 l
+-0.117375 0.442541 -0.141021 0.433607 0 0 0 0.00281905 l
+0.746245 0.0989359 0.737389 0.094595 0 0 0 0.00281905 l
+0.63303 -0.457469 0.626054 -0.443826 0 0 0 0.00281905 l
+0.63303 -0.457469 0.636319 -0.458628 0 0 0 0.00281905 l
+0.63303 -0.457469 0.626818 -0.460488 0 0 0 0.00281905 l
+0.622106 0.444286 0.617671 0.455948 0 0 0 0.00281905 l
+-0.599656 0.115798 -0.600449 0.108819 0 0 0 0.00281905 l
+0.65049 -0.129223 0.657388 -0.145855 0 0 0 0.00281905 l
+0.265244 0.237757 0.274699 0.251315 0 0 0 0.00281905 l
+0.265244 0.237757 0.256068 0.245263 0 0 0 0.00281905 l
+-0.924182 0.217761 -0.925337 0.202212 0 0 0 0.00281905 l
+-0.185058 0.0458942 -0.18426 0.0388021 0 0 0 0.00281905 l
+-0.185058 0.0458942 -0.187308 0.0520719 0 0 0 0.00281905 l
+0.052618 -0.296495 0.0592835 -0.296391 0 0 0 0.00281905 l
+0.052618 -0.296495 0.0413802 -0.299833 0 0 0 0.00281905 l
+-0.439156 -0.848104 -0.431849 -0.863055 0 0 0 0.00281905 l
+-0.439156 -0.848104 -0.437203 -0.844036 0 0 0 0.00281905 l
+0.169108 -0.524408 0.165484 -0.514362 0 0 0 0.00281905 l
+0.169108 -0.524408 0.176135 -0.536537 0 0 0 0.00281905 l
+0.0419855 -0.448373 0.0428803 -0.458017 0 0 0 0.00281905 l
+0.0419855 -0.448373 0.0528841 -0.436639 0 0 0 0.00281905 l
+0.0419855 -0.448373 0.0342286 -0.446214 0 0 0 0.00281905 l
+0.60428 -0.671564 0.601651 -0.68348 0 0 0 0.00281905 l
+0.316047 -0.25641 0.33027 -0.253005 0 0 0 0.00281905 l
+0.316047 -0.25641 0.305731 -0.258657 0 0 0 0.00281905 l
+0.113133 0.790645 0.112597 0.791504 0 0 0 0.00281905 l
+0.230734 -0.189589 0.22159 -0.177689 0 0 0 0.00281905 l
+0.731846 0.124674 0.732376 0.112982 0 0 0 0.00281905 l
+0.731846 0.124674 0.722759 0.120093 0 0 0 0.00281905 l
+-0.655883 0.239541 -0.655397 0.23101 0 0 0 0.00281905 l
+-0.655883 0.239541 -0.651856 0.248869 0 0 0 0.00281905 l
+-0.0865676 -0.703775 -0.0962162 -0.693002 0 0 0 0.00281905 l
+-0.0865676 -0.703775 -0.0973074 -0.710652 0 0 0 0.00281905 l
+0.737552 0.0822945 0.737971 0.0827268 0 0 0 0.00281905 l
+0.737552 0.0822945 0.734246 0.078957 0 0 0 0.00281905 l
+0.489847 0.0982795 0.487644 0.0918372 0 0 0 0.00281905 l
+-0.478205 -0.227729 -0.470154 -0.234332 0 0 0 0.00281905 l
+-0.478205 -0.227729 -0.470651 -0.218245 0 0 0 0.00281905 l
+-0.478205 -0.227729 -0.493652 -0.22274 0 0 0 0.00281905 l
+0.0924559 -0.446942 0.1016 -0.453225 0 0 0 0.00281905 l
+-0.0915277 -0.97972 -0.0898105 -0.988213 0 0 0 0.00281905 l
+-0.0915277 -0.97972 -0.0949387 -0.976551 0 0 0 0.00281905 l
+-0.256112 -0.705305 -0.255663 -0.702719 0 0 0 0.00281905 l
+-0.256112 -0.705305 -0.26136 -0.715457 0 0 0 0.00281905 l
+-0.222462 0.123687 -0.207412 0.122926 0 0 0 0.00281905 l
+-0.222462 0.123687 -0.224241 0.12919 0 0 0 0.00281905 l
+0.991225 -0.077941 0.992805 -0.0722798 0 0 0 0.00281905 l
+0.991225 -0.077941 0.979667 -0.0775116 0 0 0 0.00281905 l
+-0.0526697 -0.370319 -0.0591777 -0.377011 0 0 0 0.00281905 l
+-0.0526697 -0.370319 -0.0391124 -0.36198 0 0 0 0.00281905 l
+-0.0526697 -0.370319 -0.0619107 -0.364736 0 0 0 0.00281905 l
+0.152708 -0.742685 0.156873 -0.75443 0 0 0 0.00281905 l
+0.152708 -0.742685 0.142533 -0.73343 0 0 0 0.00281905 l
+0.171205 -0.381199 0.180694 -0.397662 0 0 0 0.00281905 l
+0.171205 -0.381199 0.180877 -0.371896 0 0 0 0.00281905 l
+0.837068 -0.167083 0.823738 -0.182048 0 0 0 0.00281905 l
+-0.496239 -0.684635 -0.493855 -0.687542 0 0 0 0.00281905 l
+-0.496239 -0.684635 -0.505335 -0.676398 0 0 0 0.00281905 l
+-0.716227 0.0237814 -0.709037 0.0394558 0 0 0 0.00281905 l
+-0.716227 0.0237814 -0.701125 0.0135103 0 0 0 0.00281905 l
+-0.716227 0.0237814 -0.731263 0.0147989 0 0 0 0.00281905 l
+0.152227 -0.886286 0.144211 -0.87457 0 0 0 0.00281905 l
+0.152227 -0.886286 0.144012 -0.892973 0 0 0 0.00281905 l
+0.582084 0.514468 0.579909 0.534159 0 0 0 0.00281905 l
+-0.512883 0.461347 -0.50986 0.456723 0 0 0 0.00281905 l
+-0.512883 0.461347 -0.509571 0.476904 0 0 0 0.00281905 l
+-0.544933 -0.789297 -0.540851 -0.770903 0 0 0 0.00281905 l
+-0.544933 -0.789297 -0.551107 -0.805855 0 0 0 0.00281905 l
+0.0868659 0.469121 0.094738 0.45669 0 0 0 0.00281905 l
+0.0868659 0.469121 0.0804063 0.466179 0 0 0 0.00281905 l
+0.180204 -0.573157 0.192975 -0.585733 0 0 0 0.00281905 l
+0.180204 -0.573157 0.177555 -0.566859 0 0 0 0.00281905 l
+-0.105854 -0.986752 -0.0953551 -0.991005 0 0 0 0.00281905 l
+-0.105854 -0.986752 -0.108568 -0.981433 0 0 0 0.00281905 l
+-0.19007 0.749104 -0.18939 0.759133 0 0 0 0.00281905 l
+-0.19007 0.749104 -0.181315 0.752692 0 0 0 0.00281905 l
+-0.19007 0.749104 -0.183273 0.742061 0 0 0 0.00281905 l
+0.859862 -0.300573 0.864022 -0.301261 0 0 0 0.00281905 l
+-0.235365 0.682143 -0.238927 0.696177 0 0 0 0.00281905 l
+-0.235365 0.682143 -0.217782 0.690022 0 0 0 0.00281905 l
+-0.232567 -0.449248 -0.217841 -0.432883 0 0 0 0.00281905 l
+0.27902 -0.908251 0.281261 -0.921097 0 0 0 0.00281905 l
+0.27902 -0.908251 0.272916 -0.91096 0 0 0 0.00281905 l
+0.0550421 0.963334 0.0535099 0.968753 0 0 0 0.00281905 l
+0.0550421 0.963334 0.0779731 0.955177 0 0 0 0.00281905 l
+0.0550421 0.963334 0.0450341 0.957966 0 0 0 0.00281905 l
+-0.0306524 -0.25522 -0.0139088 -0.259357 0 0 0 0.00281905 l
+-0.0306524 -0.25522 -0.0336384 -0.257983 0 0 0 0.00281905 l
+-0.488358 0.460001 -0.475811 0.444583 0 0 0 0.00281905 l
+-0.488358 0.460001 -0.489286 0.468563 0 0 0 0.00281905 l
+-0.488358 0.460001 -0.494762 0.453668 0 0 0 0.00281905 l
+0.602876 0.547689 0.603563 0.547481 0 0 0 0.00281905 l
+0.602876 0.547689 0.591381 0.545042 0 0 0 0.00281905 l
+-0.171376 0.777961 -0.155611 0.7722 0 0 0 0.00281905 l
+-0.171376 0.777961 -0.17444 0.775227 0 0 0 0.00281905 l
+-0.25111 0.839151 -0.236536 0.854296 0 0 0 0.00281905 l
+-0.25111 0.839151 -0.267023 0.835398 0 0 0 0.00281905 l
+-0.0660427 -0.0381245 -0.0659766 -0.0201552 0 0 0 0.00281905 l
+-0.0660427 -0.0381245 -0.063674 -0.0383654 0 0 0 0.00281905 l
+-0.0660427 -0.0381245 -0.0724743 -0.0402904 0 0 0 0.00281905 l
+-0.266857 0.793932 -0.275444 0.806504 0 0 0 0.00281905 l
+-0.266857 0.793932 -0.259887 0.799868 0 0 0 0.00281905 l
+-0.266857 0.793932 -0.274028 0.787117 0 0 0 0.00281905 l
+0.200998 -0.863349 0.195562 -0.859029 0 0 0 0.00281905 l
+0.200998 -0.863349 0.208862 -0.865358 0 0 0 0.00281905 l
+-0.178179 -0.904615 -0.171041 -0.895712 0 0 0 0.00281905 l
+-0.178179 -0.904615 -0.178867 -0.907092 0 0 0 0.00281905 l
+-0.0726451 0.615615 -0.085543 0.631439 0 0 0 0.00281905 l
+0.513806 0.240297 0.520666 0.239799 0 0 0 0.00281905 l
+-0.0734321 -0.161026 -0.0754869 -0.178834 0 0 0 0.00281905 l
+-0.0734321 -0.161026 -0.0593838 -0.1635 0 0 0 0.00281905 l
+-0.0734321 -0.161026 -0.0722805 -0.156947 0 0 0 0.00281905 l
+0.477064 0.567031 0.494381 0.574901 0 0 0 0.00281905 l
+0.385674 -0.0693716 0.395912 -0.0766517 0 0 0 0.00281905 l
+0.385674 -0.0693716 0.375707 -0.0747375 0 0 0 0.00281905 l
+-0.717905 0.202244 -0.719223 0.195549 0 0 0 0.00281905 l
+-0.717905 0.202244 -0.704988 0.211542 0 0 0 0.00281905 l
+0.43676 -0.33439 0.444347 -0.328139 0 0 0 0.00281905 l
+0.43676 -0.33439 0.428602 -0.3471 0 0 0 0.00281905 l
+-0.427068 0.00136749 -0.430034 -0.00183504 0 0 0 0.00281905 l
+0.308744 -0.607633 0.295567 -0.597501 0 0 0 0.00281905 l
+-0.782144 0.424294 -0.783875 0.41188 0 0 0 0.00281905 l
+-0.782144 0.424294 -0.795837 0.425402 0 0 0 0.00281905 l
+0.639028 -0.533705 0.638001 -0.546558 0 0 0 0.00281905 l
+0.639028 -0.533705 0.649469 -0.532547 0 0 0 0.00281905 l
+-0.69185 -0.235383 -0.686954 -0.238867 0 0 0 0.00281905 l
+-0.69185 -0.235383 -0.68813 -0.231961 0 0 0 0.00281905 l
+-0.69185 -0.235383 -0.700306 -0.230823 0 0 0 0.00281905 l
+-0.367449 -0.107243 -0.358805 -0.104151 0 0 0 0.00281905 l
+-0.367449 -0.107243 -0.379645 -0.106963 0 0 0 0.00281905 l
+0.393648 -0.416764 0.413299 -0.415955 0 0 0 0.00281905 l
+0.393648 -0.416764 0.391432 -0.424896 0 0 0 0.00281905 l
+0.446969 -0.562288 0.458553 -0.546045 0 0 0 0.00281905 l
+0.446969 -0.562288 0.442275 -0.564644 0 0 0 0.00281905 l
+0.348322 0.241077 0.348141 0.243797 0 0 0 0.00281905 l
+0.348322 0.241077 0.339295 0.231306 0 0 0 0.00281905 l
+0.522691 -0.821089 0.506519 -0.814502 0 0 0 0.00281905 l
+-0.629075 -0.0599193 -0.614876 -0.0661967 0 0 0 0.00281905 l
+-0.629075 -0.0599193 -0.63799 -0.0589955 0 0 0 0.00281905 l
+-0.629075 -0.0599193 -0.628733 -0.0582704 0 0 0 0.00281905 l
+0.286321 -0.173822 0.287419 -0.180458 0 0 0 0.00281905 l
+0.286321 -0.173822 0.28555 -0.158284 0 0 0 0.00281905 l
+0.286321 -0.173822 0.271479 -0.174207 0 0 0 0.00281905 l
+0.162961 0.7185 0.151503 0.725332 0 0 0 0.00281905 l
+-0.068691 0.787664 -0.0595936 0.780041 0 0 0 0.00281905 l
+-0.068691 0.787664 -0.0853175 0.789978 0 0 0 0.00281905 l
+0.460466 0.588842 0.460012 0.593099 0 0 0 0.00281905 l
+-0.570609 -0.22955 -0.555016 -0.230787 0 0 0 0.00281905 l
+-0.570609 -0.22955 -0.569905 -0.238293 0 0 0 0.00281905 l
+-0.570609 -0.22955 -0.590307 -0.232581 0 0 0 0.00281905 l
+-0.864799 -0.0395843 -0.866853 -0.0413217 0 0 0 0.00281905 l
+-0.128345 0.604697 -0.138398 0.588028 0 0 0 0.00281905 l
+-0.128345 0.604697 -0.12631 0.608985 0 0 0 0.00281905 l
+-0.327972 0.497988 -0.317296 0.494619 0 0 0 0.00281905 l
+-0.327972 0.497988 -0.335126 0.494196 0 0 0 0.00281905 l
+-0.604945 -0.580979 -0.602783 -0.583116 0 0 0 0.00281905 l
+-0.832367 0.50981 -0.831145 0.505183 0 0 0 0.00281905 l
+-0.832367 0.50981 -0.841421 0.522472 0 0 0 0.00281905 l
+0.547045 -0.112631 0.546109 -0.11865 0 0 0 0.00281905 l
+0.547045 -0.112631 0.554764 -0.10916 0 0 0 0.00281905 l
+-0.790133 -0.256539 -0.787993 -0.261667 0 0 0 0.00281905 l
+-0.790133 -0.256539 -0.785787 -0.244363 0 0 0 0.00281905 l
+-0.790133 -0.256539 -0.800831 -0.263721 0 0 0 0.00281905 l
+-0.837386 0.00531087 -0.826251 0.00630673 0 0 0 0.00281905 l
+-0.837386 0.00531087 -0.834117 -0.00832675 0 0 0 0.00281905 l
+0.528499 0.248535 0.529836 0.253319 0 0 0 0.00281905 l
+0.528499 0.248535 0.520666 0.239799 0 0 0 0.00281905 l
+-0.226244 -0.410431 -0.214607 -0.417675 0 0 0 0.00281905 l
+-0.226244 -0.410431 -0.240365 -0.4214 0 0 0 0.00281905 l
+-0.363512 0.54092 -0.356289 0.546202 0 0 0 0.00281905 l
+-0.363512 0.54092 -0.364941 0.53428 0 0 0 0.00281905 l
+-0.363512 0.54092 -0.365632 0.548029 0 0 0 0.00281905 l
+0.948348 -0.176564 0.944823 -0.164494 0 0 0 0.00281905 l
+0.948348 -0.176564 0.950602 -0.191227 0 0 0 0.00281905 l
+0.0754555 -0.0743963 0.0679373 -0.061666 0 0 0 0.00281905 l
+0.579438 -0.464655 0.586064 -0.478355 0 0 0 0.00281905 l
+0.579438 -0.464655 0.590761 -0.457211 0 0 0 0.00281905 l
+0.579438 -0.464655 0.5761 -0.46264 0 0 0 0.00281905 l
+0.0861802 -0.951002 0.0781011 -0.936035 0 0 0 0.00281905 l
+0.394003 0.309589 0.39271 0.319559 0 0 0 0.00281905 l
+0.394003 0.309589 0.407131 0.3083 0 0 0 0.00281905 l
+0.394003 0.309589 0.37313 0.300869 0 0 0 0.00281905 l
+-0.128569 -0.561551 -0.128793 -0.568145 0 0 0 0.00281905 l
+-0.637126 -0.67808 -0.617435 -0.671242 0 0 0 0.00281905 l
+-0.637126 -0.67808 -0.645758 -0.685735 0 0 0 0.00281905 l
+-0.0768803 0.0338433 -0.0735665 0.0328014 0 0 0 0.00281905 l
+-0.0768803 0.0338433 -0.0794213 0.0295471 0 0 0 0.00281905 l
+-0.355476 -0.245154 -0.352864 -0.249765 0 0 0 0.00281905 l
+-0.355476 -0.245154 -0.365357 -0.243224 0 0 0 0.00281905 l
+0.0971216 -0.283504 0.109779 -0.293058 0 0 0 0.00281905 l
+0.0971216 -0.283504 0.0829917 -0.275024 0 0 0 0.00281905 l
+0.346466 -0.38217 0.347272 -0.372483 0 0 0 0.00281905 l
+-0.548852 -0.365921 -0.539955 -0.35176 0 0 0 0.00281905 l
+-0.548852 -0.365921 -0.560174 -0.362305 0 0 0 0.00281905 l
+0.206697 -0.664915 0.208526 -0.659575 0 0 0 0.00281905 l
+0.206697 -0.664915 0.200784 -0.67561 0 0 0 0.00281905 l
+0.108423 -0.982607 0.107937 -0.992914 0 0 0 0.00281905 l
+0.108423 -0.982607 0.121815 -0.972676 0 0 0 0.00281905 l
+0.108423 -0.982607 0.0972237 -0.96864 0 0 0 0.00281905 l
+0.331876 0.408811 0.322648 0.40715 0 0 0 0.00281905 l
+0.331876 0.408811 0.333046 0.40992 0 0 0 0.00281905 l
+-0.392111 0.788327 -0.391729 0.787748 0 0 0 0.00281905 l
+-0.352482 0.62545 -0.350996 0.642759 0 0 0 0.00281905 l
+-0.352482 0.62545 -0.363423 0.619505 0 0 0 0.00281905 l
+0.0615664 -0.576272 0.0745035 -0.581547 0 0 0 0.00281905 l
+0.0615664 -0.576272 0.0551983 -0.581011 0 0 0 0.00281905 l
+-0.401258 0.411192 -0.399403 0.42314 0 0 0 0.00281905 l
+-0.401258 0.411192 -0.420386 0.412927 0 0 0 0.00281905 l
+0.357941 0.0744603 0.363011 0.0600105 0 0 0 0.00281905 l
+0.357941 0.0744603 0.34283 0.0639632 0 0 0 0.00281905 l
+0.0781011 -0.936035 0.0861802 -0.951002 0 0 0 0.00281905 l
+0.0781011 -0.936035 0.0804705 -0.933762 0 0 0 0.00281905 l
+0.0781011 -0.936035 0.0619705 -0.945131 0 0 0 0.00281905 l
+-0.00651781 -0.0735509 -0.0146425 -0.0909829 0 0 0 0.00281905 l
+-0.085543 0.631439 -0.0726451 0.615615 0 0 0 0.00281905 l
+-0.085543 0.631439 -0.0965469 0.637028 0 0 0 0.00281905 l
+0.293155 0.323911 0.295053 0.326162 0 0 0 0.00281905 l
+0.293155 0.323911 0.291771 0.320509 0 0 0 0.00281905 l
+-0.281677 -0.74759 -0.275134 -0.744407 0 0 0 0.00281905 l
+-0.281677 -0.74759 -0.291435 -0.755148 0 0 0 0.00281905 l
+0.46001 0.243729 0.452465 0.22766 0 0 0 0.00281905 l
+0.46001 0.243729 0.455927 0.246693 0 0 0 0.00281905 l
+0.620287 0.481315 0.614957 0.491171 0 0 0 0.00281905 l
+0.620287 0.481315 0.622827 0.478655 0 0 0 0.00281905 l
+0.355587 -0.552695 0.376464 -0.558093 0 0 0 0.00281905 l
+-0.110668 0.758072 -0.109139 0.776304 0 0 0 0.00281905 l
+-0.110668 0.758072 -0.116141 0.75592 0 0 0 0.00281905 l
+-0.0522107 -0.1761 -0.0593838 -0.1635 0 0 0 0.00281905 l
+-0.0522107 -0.1761 -0.0494214 -0.179308 0 0 0 0.00281905 l
+-0.731333 0.499703 -0.726206 0.503545 0 0 0 0.00281905 l
+-0.731333 0.499703 -0.73646 0.496138 0 0 0 0.00281905 l
+-0.174319 -0.462372 -0.152631 -0.465707 0 0 0 0.00281905 l
+-0.174319 -0.462372 -0.174954 -0.471335 0 0 0 0.00281905 l
+-0.174319 -0.462372 -0.18276 -0.448186 0 0 0 0.00281905 l
+-0.291983 0.129124 -0.304256 0.133978 0 0 0 0.00281905 l
+0.185558 0.406808 0.199785 0.417592 0 0 0 0.00281905 l
+0.185558 0.406808 0.180656 0.405058 0 0 0 0.00281905 l
+-0.160028 -0.515332 -0.159931 -0.520859 0 0 0 0.00281905 l
+-0.160028 -0.515332 -0.151187 -0.511663 0 0 0 0.00281905 l
+0.216003 -0.490486 0.219533 -0.49787 0 0 0 0.00281905 l
+0.307161 -0.911254 0.313325 -0.895207 0 0 0 0.00281905 l
+0.307161 -0.911254 0.318511 -0.922517 0 0 0 0.00281905 l
+-0.436441 -0.179718 -0.426563 -0.191342 0 0 0 0.00281905 l
+-0.436441 -0.179718 -0.456557 -0.184366 0 0 0 0.00281905 l
+-0.167112 0.820289 -0.165882 0.822806 0 0 0 0.00281905 l
+-0.167112 0.820289 -0.171899 0.813877 0 0 0 0.00281905 l
+-0.301323 -0.838225 -0.323597 -0.850233 0 0 0 0.00281905 l
+0.040934 0.653378 0.0487097 0.636865 0 0 0 0.00281905 l
+0.040934 0.653378 0.0443173 0.665247 0 0 0 0.00281905 l
+0.040934 0.653378 0.0312733 0.653379 0 0 0 0.00281905 l
+0.28701 -0.621005 0.28928 -0.608556 0 0 0 0.00281905 l
+0.28701 -0.621005 0.286494 -0.623691 0 0 0 0.00281905 l
+0.611835 -0.452193 0.626054 -0.443826 0 0 0 0.00281905 l
+0.611835 -0.452193 0.590761 -0.457211 0 0 0 0.00281905 l
+-0.0584359 -0.684781 -0.0489195 -0.676973 0 0 0 0.00281905 l
+-0.0584359 -0.684781 -0.0638563 -0.680541 0 0 0 0.00281905 l
+0.0224802 -0.27297 0.0209484 -0.265892 0 0 0 0.00281905 l
+0.0224802 -0.27297 0.0182091 -0.276157 0 0 0 0.00281905 l
+0.0881119 0.132518 0.0862134 0.140535 0 0 0 0.00281905 l
+0.0881119 0.132518 0.104848 0.12868 0 0 0 0.00281905 l
+0.0188282 0.094882 0.0229649 0.0996016 0 0 0 0.00281905 l
+-0.327393 0.159684 -0.316689 0.16474 0 0 0 0.00281905 l
+0.91664 -0.389836 0.920339 -0.380327 0 0 0 0.00281905 l
+-0.165026 0.83301 -0.15958 0.842394 0 0 0 0.00281905 l
+-0.165026 0.83301 -0.165882 0.822806 0 0 0 0.00281905 l
+-0.165026 0.83301 -0.178422 0.834705 0 0 0 0.00281905 l
+0.0111923 0.303376 0.0102529 0.297858 0 0 0 0.00281905 l
+0.0111923 0.303376 0.0113582 0.305589 0 0 0 0.00281905 l
+0.168231 -0.962432 0.179122 -0.969073 0 0 0 0.00281905 l
+0.168231 -0.962432 0.166248 -0.962485 0 0 0 0.00281905 l
+-0.859756 -0.192855 -0.852358 -0.200454 0 0 0 0.00281905 l
+-0.859756 -0.192855 -0.861399 -0.191507 0 0 0 0.00281905 l
+0.297208 0.820841 0.288477 0.807801 0 0 0 0.00281905 l
+0.297208 0.820841 0.30636 0.819854 0 0 0 0.00281905 l
+0.297208 0.820841 0.293432 0.826569 0 0 0 0.00281905 l
+0.506304 0.702831 0.49526 0.697279 0 0 0 0.00281905 l
+0.506304 0.702831 0.506699 0.704993 0 0 0 0.00281905 l
+-0.48711 0.166322 -0.500563 0.179967 0 0 0 0.00281905 l
+0.332869 0.135137 0.340305 0.139951 0 0 0 0.00281905 l
+0.332869 0.135137 0.331127 0.131862 0 0 0 0.00281905 l
+0.544167 -0.0280602 0.544303 -0.0265087 0 0 0 0.00281905 l
+-0.365713 0.758606 -0.366505 0.758772 0 0 0 0.00281905 l
+-0.782457 0.595787 -0.776513 0.601194 0 0 0 0.00281905 l
+-0.782457 0.595787 -0.796564 0.596856 0 0 0 0.00281905 l
+0.864004 0.285944 0.864082 0.306563 0 0 0 0.00281905 l
+0.864004 0.285944 0.861805 0.283383 0 0 0 0.00281905 l
+0.474383 -0.305495 0.469718 -0.287103 0 0 0 0.00281905 l
+0.474383 -0.305495 0.487068 -0.306228 0 0 0 0.00281905 l
+0.474383 -0.305495 0.463381 -0.317907 0 0 0 0.00281905 l
+-0.656626 0.678816 -0.657997 0.66921 0 0 0 0.00281905 l
+-0.656626 0.678816 -0.649996 0.684267 0 0 0 0.00281905 l
+-0.492749 0.822441 -0.483647 0.828384 0 0 0 0.00281905 l
+-0.92735 0.0899559 -0.925727 0.0975071 0 0 0 0.00281905 l
+-0.92735 0.0899559 -0.938674 0.0913576 0 0 0 0.00281905 l
+-0.578152 -0.206225 -0.59008 -0.203235 0 0 0 0.00281905 l
+0.505757 -0.337776 0.511854 -0.325838 0 0 0 0.00281905 l
+0.605977 -0.768461 0.608459 -0.774204 0 0 0 0.00281905 l
+0.465141 0.538864 0.465762 0.527534 0 0 0 0.00281905 l
+0.465141 0.538864 0.466408 0.541015 0 0 0 0.00281905 l
+0.465141 0.538864 0.457203 0.535205 0 0 0 0.00281905 l
+0.209381 0.502582 0.210666 0.524805 0 0 0 0.00281905 l
+0.209381 0.502582 0.195913 0.483755 0 0 0 0.00281905 l
+-0.0465954 0.666337 -0.0408841 0.675222 0 0 0 0.00281905 l
+-0.0465954 0.666337 -0.0387106 0.658106 0 0 0 0.00281905 l
+-0.0465954 0.666337 -0.0487333 0.664967 0 0 0 0.00281905 l
+-0.489064 0.275926 -0.485567 0.276336 0 0 0 0.00281905 l
+-0.489064 0.275926 -0.493418 0.280258 0 0 0 0.00281905 l
+-0.149574 -0.667372 -0.165211 -0.656169 0 0 0 0.00281905 l
+-0.149574 -0.667372 -0.145343 -0.672199 0 0 0 0.00281905 l
+-0.149574 -0.667372 -0.155922 -0.674259 0 0 0 0.00281905 l
+0.549632 -0.415546 0.556863 -0.433521 0 0 0 0.00281905 l
+0.549632 -0.415546 0.560505 -0.405696 0 0 0 0.00281905 l
+0.549632 -0.415546 0.543221 -0.415456 0 0 0 0.00281905 l
+-0.0949387 -0.976551 -0.0915277 -0.97972 0 0 0 0.00281905 l
+0.342083 0.0928161 0.347948 0.105194 0 0 0 0.00281905 l
+-0.477811 -0.823551 -0.478403 -0.83599 0 0 0 0.00281905 l
+-0.477811 -0.823551 -0.478492 -0.814989 0 0 0 0.00281905 l
+0.258111 -0.263949 0.257781 -0.250963 0 0 0 0.00281905 l
+0.258111 -0.263949 0.268596 -0.262773 0 0 0 0.00281905 l
+0.258111 -0.263949 0.253131 -0.271794 0 0 0 0.00281905 l
+0.582016 0.251835 0.576806 0.26792 0 0 0 0.00281905 l
+0.582016 0.251835 0.588775 0.241775 0 0 0 0.00281905 l
+0.777985 0.380957 0.775387 0.380766 0 0 0 0.00281905 l
+0.908931 0.0944769 0.915004 0.0847772 0 0 0 0.00281905 l
+0.908931 0.0944769 0.899766 0.0965962 0 0 0 0.00281905 l
+-0.850723 -0.0751691 -0.841879 -0.0869091 0 0 0 0.00281905 l
+-0.850723 -0.0751691 -0.84155 -0.0570568 0 0 0 0.00281905 l
+-0.850723 -0.0751691 -0.857619 -0.0790086 0 0 0 0.00281905 l
+0.296814 0.91948 0.285731 0.934929 0 0 0 0.00281905 l
+0.296814 0.91948 0.305174 0.913624 0 0 0 0.00281905 l
+0.296814 0.91948 0.283415 0.912594 0 0 0 0.00281905 l
+-0.0816385 0.155719 -0.0708522 0.15141 0 0 0 0.00281905 l
+-0.0816385 0.155719 -0.0865204 0.142866 0 0 0 0.00281905 l
+0.513038 -0.194487 0.52777 -0.210128 0 0 0 0.00281905 l
+0.513038 -0.194487 0.515754 -0.178052 0 0 0 0.00281905 l
+0.0623083 -0.432772 0.0622207 -0.428878 0 0 0 0.00281905 l
+0.0623083 -0.432772 0.0545617 -0.436461 0 0 0 0.00281905 l
+0.309872 -0.0504843 0.316372 -0.0358121 0 0 0 0.00281905 l
+0.309872 -0.0504843 0.313042 -0.0558716 0 0 0 0.00281905 l
+0.313327 0.153464 0.324338 0.15285 0 0 0 0.00281905 l
+0.313327 0.153464 0.299838 0.16681 0 0 0 0.00281905 l
+0.313327 0.153464 0.307095 0.148788 0 0 0 0.00281905 l
+0.235084 -0.630485 0.243901 -0.642405 0 0 0 0.00281905 l
+0.235084 -0.630485 0.244712 -0.624722 0 0 0 0.00281905 l
+0.235084 -0.630485 0.226655 -0.640393 0 0 0 0.00281905 l
+-0.0540208 0.503602 -0.0620178 0.514304 0 0 0 0.00281905 l
+-0.0540208 0.503602 -0.0440958 0.51218 0 0 0 0.00281905 l
+-0.0540208 0.503602 -0.0670468 0.496376 0 0 0 0.00281905 l
+0.537052 0.538093 0.529254 0.552157 0 0 0 0.00281905 l
+0.537052 0.538093 0.549955 0.546996 0 0 0 0.00281905 l
+0.537052 0.538093 0.520931 0.526558 0 0 0 0.00281905 l
+0.132468 0.559406 0.127751 0.547963 0 0 0 0.00281905 l
+0.132468 0.559406 0.146805 0.561243 0 0 0 0.00281905 l
+0.0355181 -0.666428 0.0445895 -0.677521 0 0 0 0.00281905 l
+0.0355181 -0.666428 0.0375292 -0.6572 0 0 0 0.00281905 l
+0.737303 0.380624 0.748759 0.385939 0 0 0 0.00281905 l
+0.737303 0.380624 0.725933 0.368377 0 0 0 0.00281905 l
+0.737303 0.380624 0.735655 0.383164 0 0 0 0.00281905 l
+-0.593318 0.580741 -0.578719 0.587806 0 0 0 0.00281905 l
+0.53611 0.0986934 0.534043 0.102583 0 0 0 0.00281905 l
+0.102806 -0.354355 0.0932169 -0.368894 0 0 0 0.00281905 l
+0.102806 -0.354355 0.0946041 -0.340749 0 0 0 0.00281905 l
+0.102806 -0.354355 0.111608 -0.353861 0 0 0 0.00281905 l
+0.854883 0.132883 0.859485 0.121724 0 0 0 0.00281905 l
+0.938527 0.0517995 0.945454 0.0688078 0 0 0 0.00281905 l
+0.938527 0.0517995 0.921857 0.0631322 0 0 0 0.00281905 l
+-0.30287 0.682252 -0.290278 0.690846 0 0 0 0.00281905 l
+-0.30287 0.682252 -0.315436 0.689429 0 0 0 0.00281905 l
+0.23109 0.804567 0.232143 0.795267 0 0 0 0.00281905 l
+0.23109 0.804567 0.23661 0.806993 0 0 0 0.00281905 l
+-0.737116 -0.234249 -0.727426 -0.228087 0 0 0 0.00281905 l
+-0.737116 -0.234249 -0.749238 -0.240866 0 0 0 0.00281905 l
+0.615475 -0.278579 0.610587 -0.260244 0 0 0 0.00281905 l
+0.615475 -0.278579 0.63084 -0.287456 0 0 0 0.00281905 l
+-0.0833289 0.733969 -0.0759238 0.726536 0 0 0 0.00281905 l
+-0.0833289 0.733969 -0.0922459 0.743857 0 0 0 0.00281905 l
+0.941022 0.271461 0.938897 0.278609 0 0 0 0.00281905 l
+0.941022 0.271461 0.952981 0.261884 0 0 0 0.00281905 l
+0.941022 0.271461 0.925247 0.260813 0 0 0 0.00281905 l
+0.482676 -0.24214 0.488671 -0.24711 0 0 0 0.00281905 l
+0.482676 -0.24214 0.486221 -0.237789 0 0 0 0.00281905 l
+0.482676 -0.24214 0.47908 -0.243948 0 0 0 0.00281905 l
+-0.322386 0.197223 -0.313413 0.19571 0 0 0 0.00281905 l
+-0.322386 0.197223 -0.330241 0.183156 0 0 0 0.00281905 l
+0.658427 -0.619827 0.662405 -0.622525 0 0 0 0.00281905 l
+0.658427 -0.619827 0.654639 -0.619385 0 0 0 0.00281905 l
+-0.503779 -0.201759 -0.495271 -0.191435 0 0 0 0.00281905 l
+-0.503779 -0.201759 -0.487075 -0.208759 0 0 0 0.00281905 l
+-0.503779 -0.201759 -0.50957 -0.208461 0 0 0 0.00281905 l
+-0.503779 -0.201759 -0.511763 -0.195182 0 0 0 0.00281905 l
+-0.358628 0.457152 -0.339107 0.451063 0 0 0 0.00281905 l
+-0.358628 0.457152 -0.373504 0.454747 0 0 0 0.00281905 l
+-0.342686 -0.612462 -0.33452 -0.619478 0 0 0 0.00281905 l
+-0.342686 -0.612462 -0.357023 -0.606348 0 0 0 0.00281905 l
+0.716776 -0.468322 0.726093 -0.473646 0 0 0 0.00281905 l
+0.716776 -0.468322 0.724696 -0.459713 0 0 0 0.00281905 l
+0.724206 -0.664359 0.729565 -0.651262 0 0 0 0.00281905 l
+0.724206 -0.664359 0.738918 -0.664508 0 0 0 0.00281905 l
+-0.753437 0.426596 -0.760875 0.419338 0 0 0 0.00281905 l
+-0.913475 -0.0886517 -0.916373 -0.087605 0 0 0 0.00281905 l
+-0.913475 -0.0886517 -0.909386 -0.0866346 0 0 0 0.00281905 l
+0.864147 0.205444 0.854656 0.213617 0 0 0 0.00281905 l
+0.864147 0.205444 0.870001 0.200194 0 0 0 0.00281905 l
+-0.724351 0.23411 -0.709172 0.239374 0 0 0 0.00281905 l
+-0.724351 0.23411 -0.734408 0.223123 0 0 0 0.00281905 l
+-0.782615 -0.566311 -0.768899 -0.575023 0 0 0 0.00281905 l
+-0.782615 -0.566311 -0.787553 -0.566308 0 0 0 0.00281905 l
+-0.204401 -0.283186 -0.188668 -0.28913 0 0 0 0.00281905 l
+-0.204401 -0.283186 -0.207062 -0.279514 0 0 0 0.00281905 l
+0.511528 0.0264356 0.516038 0.0295501 0 0 0 0.00281905 l
+0.511528 0.0264356 0.51156 0.0173723 0 0 0 0.00281905 l
+-0.0368405 -0.53993 -0.0312536 -0.546077 0 0 0 0.00281905 l
+-0.0368405 -0.53993 -0.0355175 -0.536145 0 0 0 0.00281905 l
+0.15884 -0.1539 0.157663 -0.143199 0 0 0 0.00281905 l
+0.15884 -0.1539 0.16983 -0.161432 0 0 0 0.00281905 l
+0.0193076 0.214679 0.01002 0.206782 0 0 0 0.00281905 l
+-0.136095 -0.16405 -0.128908 -0.154424 0 0 0 0.00281905 l
+-0.136095 -0.16405 -0.154869 -0.171139 0 0 0 0.00281905 l
+-0.0602744 -0.254022 -0.0528756 -0.252589 0 0 0 0.00281905 l
+-0.0602744 -0.254022 -0.0767205 -0.256275 0 0 0 0.00281905 l
+-0.790245 -0.00726669 -0.790316 -0.00037791 0 0 0 0.00281905 l
+0.0189354 -0.60555 0.017211 -0.590061 0 0 0 0.00281905 l
+0.0189354 -0.60555 0.0150254 -0.606744 0 0 0 0.00281905 l
+0.444169 -0.479887 0.448406 -0.466242 0 0 0 0.00281905 l
+0.0388771 -0.486795 0.0504747 -0.486319 0 0 0 0.00281905 l
+0.0388771 -0.486795 0.0364645 -0.486172 0 0 0 0.00281905 l
+0.460064 -0.0965293 0.463116 -0.0856317 0 0 0 0.00281905 l
+0.460064 -0.0965293 0.467921 -0.103727 0 0 0 0.00281905 l
+-0.358505 -0.567961 -0.362016 -0.577581 0 0 0 0.00281905 l
+-0.358505 -0.567961 -0.354723 -0.564646 0 0 0 0.00281905 l
+-0.358505 -0.567961 -0.377168 -0.556729 0 0 0 0.00281905 l
+-0.2878 -0.214368 -0.288285 -0.227703 0 0 0 0.00281905 l
+-0.484935 -0.482005 -0.479893 -0.48795 0 0 0 0.00281905 l
+-0.834802 -0.306252 -0.837893 -0.314557 0 0 0 0.00281905 l
+-0.834802 -0.306252 -0.840233 -0.302678 0 0 0 0.00281905 l
+0.963257 -0.0330784 0.959507 -0.0461685 0 0 0 0.00281905 l
+0.963257 -0.0330784 0.965567 -0.0267364 0 0 0 0.00281905 l
+0.0177076 -0.617413 0.0156282 -0.634239 0 0 0 0.00281905 l
+0.0177076 -0.617413 0.0150254 -0.606744 0 0 0 0.00281905 l
+-0.473991 0.718235 -0.462341 0.715359 0 0 0 0.00281905 l
+-0.473991 0.718235 -0.481141 0.714145 0 0 0 0.00281905 l
+-0.649427 0.709868 -0.648726 0.709793 0 0 0 0.00281905 l
+-0.689079 -0.44193 -0.677852 -0.447071 0 0 0 0.00281905 l
+-0.689079 -0.44193 -0.694613 -0.440951 0 0 0 0.00281905 l
+0.128444 -0.483237 0.146779 -0.475542 0 0 0 0.00281905 l
+0.128444 -0.483237 0.120706 -0.499668 0 0 0 0.00281905 l
+0.128444 -0.483237 0.126134 -0.47815 0 0 0 0.00281905 l
+0.359161 0.621443 0.36411 0.60137 0 0 0 0.00281905 l
+0.359161 0.621443 0.361697 0.627478 0 0 0 0.00281905 l
+-0.731756 0.651007 -0.715564 0.642132 0 0 0 0.00281905 l
+0.0831658 0.65422 0.0955106 0.659802 0 0 0 0.00281905 l
+0.0831658 0.65422 0.0878462 0.644527 0 0 0 0.00281905 l
+0.0831658 0.65422 0.0718049 0.654125 0 0 0 0.00281905 l
+0.257272 -0.573043 0.242354 -0.589848 0 0 0 0.00281905 l
+0.257272 -0.573043 0.255642 -0.569986 0 0 0 0.00281905 l
+0.0672503 -0.352912 0.0575837 -0.369061 0 0 0 0.00281905 l
+0.0672503 -0.352912 0.0677427 -0.348692 0 0 0 0.00281905 l
+0.0672503 -0.352912 0.0797773 -0.354531 0 0 0 0.00281905 l
+0.912752 0.161937 0.921923 0.151857 0 0 0 0.00281905 l
+0.912752 0.161937 0.910381 0.173732 0 0 0 0.00281905 l
+0.912752 0.161937 0.907363 0.161138 0 0 0 0.00281905 l
+-0.928883 -0.152554 -0.933953 -0.160621 0 0 0 0.00281905 l
+-0.928883 -0.152554 -0.929746 -0.151657 0 0 0 0.00281905 l
+0.374484 -0.210449 0.367788 -0.2251 0 0 0 0.00281905 l
+0.374484 -0.210449 0.380761 -0.204267 0 0 0 0.00281905 l
+0.280147 -0.735182 0.285754 -0.745136 0 0 0 0.00281905 l
+0.280147 -0.735182 0.2768 -0.732061 0 0 0 0.00281905 l
+-0.554519 0.162255 -0.538837 0.162791 0 0 0 0.00281905 l
+-0.488316 0.755369 -0.495282 0.733581 0 0 0 0.00281905 l
+-0.488316 0.755369 -0.501274 0.771769 0 0 0 0.00281905 l
+-0.498274 -0.0510132 -0.502357 -0.0451854 0 0 0 0.00281905 l
+0.71279 0.39022 0.710458 0.379504 0 0 0 0.00281905 l
+0.71279 0.39022 0.701836 0.390655 0 0 0 0.00281905 l
+-0.113051 0.159741 -0.105974 0.154572 0 0 0 0.00281905 l
+-0.113051 0.159741 -0.111598 0.173029 0 0 0 0.00281905 l
+-0.0925954 -0.366585 -0.0747692 -0.361898 0 0 0 0.00281905 l
+-0.0925954 -0.366585 -0.0989686 -0.375028 0 0 0 0.00281905 l
+0.653088 0.261671 0.647396 0.256202 0 0 0 0.00281905 l
+-0.110623 0.912427 -0.100138 0.905435 0 0 0 0.00281905 l
+-0.437967 0.638082 -0.431504 0.635732 0 0 0 0.00281905 l
+-0.437967 0.638082 -0.454803 0.629458 0 0 0 0.00281905 l
+-0.653729 0.0532402 -0.651998 0.0536243 0 0 0 0.00281905 l
+-0.653729 0.0532402 -0.657431 0.0461772 0 0 0 0.00281905 l
+0.175865 0.249967 0.172982 0.259448 0 0 0 0.00281905 l
+0.175865 0.249967 0.170905 0.244406 0 0 0 0.00281905 l
+-0.0939285 -0.847176 -0.0888367 -0.861559 0 0 0 0.00281905 l
+-0.0939285 -0.847176 -0.103943 -0.850149 0 0 0 0.00281905 l
+0.349531 -0.276715 0.347633 -0.289008 0 0 0 0.00281905 l
+0.349531 -0.276715 0.357642 -0.270459 0 0 0 0.00281905 l
+-0.520297 0.29151 -0.516771 0.291747 0 0 0 0.00281905 l
+-0.520297 0.29151 -0.530891 0.290838 0 0 0 0.00281905 l
+-0.367355 -0.471198 -0.357865 -0.470833 0 0 0 0.00281905 l
+-0.367355 -0.471198 -0.384419 -0.458153 0 0 0 0.00281905 l
+-0.0444955 -0.828437 -0.0384719 -0.824974 0 0 0 0.00281905 l
+0.236629 -0.747023 0.237639 -0.75135 0 0 0 0.00281905 l
+0.115071 0.558496 0.127751 0.547963 0 0 0 0.00281905 l
+0.115071 0.558496 0.10413 0.565506 0 0 0 0.00281905 l
+-0.0671254 -0.643726 -0.0481163 -0.653014 0 0 0 0.00281905 l
+-0.0671254 -0.643726 -0.0841351 -0.643348 0 0 0 0.00281905 l
+-0.573225 0.798797 -0.570767 0.81405 0 0 0 0.00281905 l
+-0.573225 0.798797 -0.557956 0.799333 0 0 0 0.00281905 l
+-0.573225 0.798797 -0.576103 0.793548 0 0 0 0.00281905 l
+-0.213146 0.0214237 -0.206582 0.0330684 0 0 0 0.00281905 l
+-0.213146 0.0214237 -0.19765 0.00752604 0 0 0 0.00281905 l
+-0.213146 0.0214237 -0.225822 0.00773785 0 0 0 0.00281905 l
+-0.385247 0.243873 -0.383147 0.251792 0 0 0 0.00281905 l
+-0.385247 0.243873 -0.394923 0.243734 0 0 0 0.00281905 l
+0.41144 -0.812832 0.430854 -0.82155 0 0 0 0.00281905 l
+0.41144 -0.812832 0.399508 -0.825068 0 0 0 0.00281905 l
+0.41144 -0.812832 0.410202 -0.8095 0 0 0 0.00281905 l
+0.0434185 0.496325 0.0479191 0.503421 0 0 0 0.00281905 l
+-0.028021 -0.0284747 -0.0189583 -0.0261561 0 0 0 0.00281905 l
+-0.028021 -0.0284747 -0.0310971 -0.0322101 0 0 0 0.00281905 l
+-0.141746 0.0601798 -0.142645 0.0789173 0 0 0 0.00281905 l
+-0.141746 0.0601798 -0.139771 0.0526833 0 0 0 0.00281905 l
+-0.0498239 -0.208133 -0.0533977 -0.22428 0 0 0 0.00281905 l
+-0.0498239 -0.208133 -0.0433082 -0.199543 0 0 0 0.00281905 l
+-0.0498239 -0.208133 -0.0587006 -0.199017 0 0 0 0.00281905 l
+0.102106 -0.935774 0.107767 -0.936606 0 0 0 0.00281905 l
+0.102106 -0.935774 0.0982704 -0.933021 0 0 0 0.00281905 l
+0.0209484 -0.265892 0.0224802 -0.27297 0 0 0 0.00281905 l
+0.0209484 -0.265892 0.0271997 -0.258809 0 0 0 0.00281905 l
+0.0209484 -0.265892 0.00622981 -0.263785 0 0 0 0.00281905 l
+-0.179947 0.734331 -0.173387 0.732782 0 0 0 0.00281905 l
+-0.179947 0.734331 -0.185542 0.734215 0 0 0 0.00281905 l
+-0.710342 0.17499 -0.70419 0.188485 0 0 0 0.00281905 l
+-0.710342 0.17499 -0.723295 0.17495 0 0 0 0.00281905 l
+-0.0806514 0.493114 -0.0670468 0.496376 0 0 0 0.00281905 l
+-0.0806514 0.493114 -0.0848001 0.488813 0 0 0 0.00281905 l
+0.561292 -0.0996268 0.570666 -0.0995152 0 0 0 0.00281905 l
+0.561292 -0.0996268 0.554764 -0.10916 0 0 0 0.00281905 l
+0.561292 -0.0996268 0.550701 -0.0967541 0 0 0 0.00281905 l
+0.588543 -0.359538 0.596603 -0.345163 0 0 0 0.00281905 l
+0.588543 -0.359538 0.59351 -0.378382 0 0 0 0.00281905 l
+0.0598583 0.593354 0.049647 0.597589 0 0 0 0.00281905 l
+0.529071 0.161353 0.541785 0.165981 0 0 0 0.00281905 l
+0.529071 0.161353 0.533701 0.153689 0 0 0 0.00281905 l
+0.671599 0.338901 0.689759 0.339326 0 0 0 0.00281905 l
+0.671599 0.338901 0.65767 0.33952 0 0 0 0.00281905 l
+0.948608 0.202007 0.939441 0.186441 0 0 0 0.00281905 l
+-0.391437 0.845703 -0.384663 0.850313 0 0 0 0.00281905 l
+-0.391437 0.845703 -0.384444 0.839319 0 0 0 0.00281905 l
+-0.391437 0.845703 -0.397855 0.840111 0 0 0 0.00281905 l
+0.34712 0.367882 0.353408 0.370553 0 0 0 0.00281905 l
+0.34712 0.367882 0.340173 0.377022 0 0 0 0.00281905 l
+-0.330301 -0.113108 -0.343691 -0.127846 0 0 0 0.00281905 l
+0.379426 -0.33293 0.390005 -0.325993 0 0 0 0.00281905 l
+0.913129 0.325407 0.921102 0.319728 0 0 0 0.00281905 l
+0.913129 0.325407 0.903845 0.322358 0 0 0 0.00281905 l
+-0.261166 0.721451 -0.267285 0.709923 0 0 0 0.00281905 l
+0.203481 0.374195 0.222221 0.382532 0 0 0 0.00281905 l
+0.0219938 -0.232118 0.0184842 -0.249749 0 0 0 0.00281905 l
+0.0219938 -0.232118 0.0132464 -0.218145 0 0 0 0.00281905 l
+0.825552 -0.415757 0.835719 -0.412359 0 0 0 0.00281905 l
+0.825552 -0.415757 0.812903 -0.40835 0 0 0 0.00281905 l
+-0.443423 0.0367178 -0.439904 0.0280359 0 0 0 0.00281905 l
+-0.443423 0.0367178 -0.456841 0.0530636 0 0 0 0.00281905 l
+-0.443423 0.0367178 -0.459085 0.0310881 0 0 0 0.00281905 l
+-0.505335 -0.676398 -0.496239 -0.684635 0 0 0 0.00281905 l
+-0.505335 -0.676398 -0.509979 -0.677291 0 0 0 0.00281905 l
+0.593958 -0.298609 0.604886 -0.315332 0 0 0 0.00281905 l
+0.593958 -0.298609 0.592899 -0.296266 0 0 0 0.00281905 l
+0.540055 -0.135527 0.550505 -0.140489 0 0 0 0.00281905 l
+0.540055 -0.135527 0.5399 -0.135484 0 0 0 0.00281905 l
+0.283818 0.823762 0.288666 0.824768 0 0 0 0.00281905 l
+0.983838 0.0666955 0.974544 0.0834857 0 0 0 0.00281905 l
+0.983838 0.0666955 0.991129 0.0651264 0 0 0 0.00281905 l
+0.983838 0.0666955 0.981266 0.0557801 0 0 0 0.00281905 l
+0.789381 -0.458025 0.79628 -0.464702 0 0 0 0.00281905 l
+0.789381 -0.458025 0.786555 -0.464225 0 0 0 0.00281905 l
+-0.473127 0.272209 -0.466107 0.290364 0 0 0 0.00281905 l
+-0.473127 0.272209 -0.467809 0.265553 0 0 0 0.00281905 l
+-0.473127 0.272209 -0.485567 0.276336 0 0 0 0.00281905 l
+-0.323848 -0.506562 -0.323072 -0.520565 0 0 0 0.00281905 l
+-0.323848 -0.506562 -0.332196 -0.486093 0 0 0 0.00281905 l
+0.534043 0.102583 0.538773 0.109002 0 0 0 0.00281905 l
+0.534043 0.102583 0.53611 0.0986934 0 0 0 0.00281905 l
+0.534043 0.102583 0.52433 0.10176 0 0 0 0.00281905 l
+-0.386923 0.531928 -0.390932 0.539945 0 0 0 0.00281905 l
+-0.386923 0.531928 -0.394173 0.524626 0 0 0 0.00281905 l
+-0.655095 -0.729278 -0.656915 -0.725085 0 0 0 0.00281905 l
+-0.655095 -0.729278 -0.661565 -0.733299 0 0 0 0.00281905 l
+-0.466397 -0.538827 -0.468484 -0.549982 0 0 0 0.00281905 l
+-0.466397 -0.538827 -0.481176 -0.518128 0 0 0 0.00281905 l
+-0.381166 0.658859 -0.376286 0.649711 0 0 0 0.00281905 l
+-0.381166 0.658859 -0.396524 0.653176 0 0 0 0.00281905 l
+-0.650096 -0.0707802 -0.63799 -0.0589955 0 0 0 0.00281905 l
+-0.650096 -0.0707802 -0.651832 -0.0742272 0 0 0 0.00281905 l
+-0.650096 -0.0707802 -0.653746 -0.0680466 0 0 0 0.00281905 l
+0.907422 -0.0602081 0.904067 -0.0631729 0 0 0 0.00281905 l
+0.907422 -0.0602081 0.904671 -0.0587103 0 0 0 0.00281905 l
+0.0338482 0.351798 0.0449346 0.352802 0 0 0 0.00281905 l
+0.0338482 0.351798 0.0311067 0.333075 0 0 0 0.00281905 l
+0.28719 0.944167 0.291978 0.942759 0 0 0 0.00281905 l
+0.28719 0.944167 0.285731 0.934929 0 0 0 0.00281905 l
+0.723069 -0.0595435 0.725093 -0.047359 0 0 0 0.00281905 l
+0.723069 -0.0595435 0.728005 -0.0604436 0 0 0 0.00281905 l
+0.723069 -0.0595435 0.714656 -0.0710853 0 0 0 0.00281905 l
+-0.710127 -0.535737 -0.717009 -0.532539 0 0 0 0.00281905 l
+-0.757621 -0.159618 -0.755193 -0.158293 0 0 0 0.00281905 l
+-0.757621 -0.159618 -0.770776 -0.166589 0 0 0 0.00281905 l
+-0.171721 -0.760454 -0.174763 -0.76427 0 0 0 0.00281905 l
+0.86591 0.0603281 0.879374 0.0548496 0 0 0 0.00281905 l
+0.86591 0.0603281 0.854465 0.0627964 0 0 0 0.00281905 l
+0.723664 -0.0937109 0.728681 -0.105425 0 0 0 0.00281905 l
+0.723664 -0.0937109 0.731445 -0.089025 0 0 0 0.00281905 l
+-0.157835 0.423078 -0.148361 0.425375 0 0 0 0.00281905 l
+-0.157835 0.423078 -0.168033 0.430843 0 0 0 0.00281905 l
+0.284737 0.417406 0.283473 0.425608 0 0 0 0.00281905 l
+0.284737 0.417406 0.29741 0.413448 0 0 0 0.00281905 l
+0.284737 0.417406 0.270193 0.406056 0 0 0 0.00281905 l
+0.68176 -0.0664626 0.684698 -0.052942 0 0 0 0.00281905 l
+0.68176 -0.0664626 0.680853 -0.076788 0 0 0 0.00281905 l
+-0.727426 -0.228087 -0.723179 -0.221344 0 0 0 0.00281905 l
+-0.727426 -0.228087 -0.720855 -0.231609 0 0 0 0.00281905 l
+-0.727426 -0.228087 -0.737244 -0.219545 0 0 0 0.00281905 l
+-0.727426 -0.228087 -0.737116 -0.234249 0 0 0 0.00281905 l
+-0.407674 -0.300619 -0.406922 -0.304288 0 0 0 0.00281905 l
+-0.407674 -0.300619 -0.410324 -0.299672 0 0 0 0.00281905 l
+0.897807 0.0304783 0.904646 0.0320615 0 0 0 0.00281905 l
+-0.675355 -0.562256 -0.656856 -0.561098 0 0 0 0.00281905 l
+-0.675355 -0.562256 -0.691909 -0.567651 0 0 0 0.00281905 l
+0.069898 0.0992727 0.0717954 0.0924075 0 0 0 0.00281905 l
+0.069898 0.0992727 0.0605843 0.107692 0 0 0 0.00281905 l
+-0.743536 -0.495338 -0.743159 -0.496232 0 0 0 0.00281905 l
+-0.294769 0.579498 -0.290863 0.570712 0 0 0 0.00281905 l
+-0.294769 0.579498 -0.304261 0.581993 0 0 0 0.00281905 l
+-0.127922 -0.700776 -0.119843 -0.702764 0 0 0 0.00281905 l
+-0.127922 -0.700776 -0.129235 -0.68322 0 0 0 0.00281905 l
+-0.281719 -0.877927 -0.304193 -0.87692 0 0 0 0.00281905 l
+0.737389 0.094595 0.746245 0.0989359 0 0 0 0.00281905 l
+0.737389 0.094595 0.737971 0.0827268 0 0 0 0.00281905 l
+0.737389 0.094595 0.724418 0.104039 0 0 0 0.00281905 l
+0.141457 0.0703728 0.137469 0.0834567 0 0 0 0.00281905 l
+0.141457 0.0703728 0.14366 0.0537663 0 0 0 0.00281905 l
+-0.91346 -0.385921 -0.915991 -0.36293 0 0 0 0.00281905 l
+-0.683125 -0.104678 -0.675101 -0.106499 0 0 0 0.00281905 l
+-0.683125 -0.104678 -0.694682 -0.0967871 0 0 0 0.00281905 l
+-0.98766 -0.0139746 -0.981093 -0.00869599 0 0 0 0.00281905 l
+-0.297829 0.637914 -0.299676 0.636399 0 0 0 0.00281905 l
+-0.344365 -0.645289 -0.337482 -0.642391 0 0 0 0.00281905 l
+-0.344365 -0.645289 -0.349456 -0.648455 0 0 0 0.00281905 l
+-0.677852 -0.447071 -0.675656 -0.458076 0 0 0 0.00281905 l
+-0.677852 -0.447071 -0.674243 -0.428712 0 0 0 0.00281905 l
+-0.677852 -0.447071 -0.689079 -0.44193 0 0 0 0.00281905 l
+-0.379128 0.383973 -0.37329 0.383362 0 0 0 0.00281905 l
+-0.0744801 0.451434 -0.0728485 0.453888 0 0 0 0.00281905 l
+-0.0744801 0.451434 -0.081642 0.442934 0 0 0 0.00281905 l
+0.112708 0.0321531 0.117014 0.0166601 0 0 0 0.00281905 l
+0.112708 0.0321531 0.100583 0.0328563 0 0 0 0.00281905 l
+-0.794909 0.400649 -0.783875 0.41188 0 0 0 0.00281905 l
+-0.794909 0.400649 -0.806224 0.399479 0 0 0 0.00281905 l
+-0.323343 -0.380418 -0.314819 -0.379943 0 0 0 0.00281905 l
+-0.323343 -0.380418 -0.324124 -0.39336 0 0 0 0.00281905 l
+-0.323343 -0.380418 -0.334105 -0.374717 0 0 0 0.00281905 l
+-0.0973701 0.646066 -0.101224 0.65704 0 0 0 0.00281905 l
+-0.0973701 0.646066 -0.104129 0.642005 0 0 0 0.00281905 l
+0.281697 -0.815306 0.282011 -0.811365 0 0 0 0.00281905 l
+-0.0747043 -0.523731 -0.0706839 -0.513423 0 0 0 0.00281905 l
+-0.0747043 -0.523731 -0.0783426 -0.53355 0 0 0 0.00281905 l
+0.495084 -0.129123 0.507178 -0.132945 0 0 0 0.00281905 l
+0.495084 -0.129123 0.480446 -0.120821 0 0 0 0.00281905 l
+0.474909 0.685583 0.474353 0.683127 0 0 0 0.00281905 l
+-0.339971 -0.82836 -0.338669 -0.823483 0 0 0 0.00281905 l
+-0.154907 0.972644 -0.148804 0.952742 0 0 0 0.00281905 l
+-0.154907 0.972644 -0.149111 0.981705 0 0 0 0.00281905 l
+-0.154907 0.972644 -0.159352 0.972004 0 0 0 0.00281905 l
+-0.289864 0.442863 -0.280525 0.437008 0 0 0 0.00281905 l
+-0.289864 0.442863 -0.302369 0.425803 0 0 0 0.00281905 l
+-0.271482 0.879961 -0.264827 0.870312 0 0 0 0.00281905 l
+-0.271482 0.879961 -0.28819 0.888932 0 0 0 0.00281905 l
+0.592698 0.738297 0.58943 0.748446 0 0 0 0.00281905 l
+0.592698 0.738297 0.587043 0.723975 0 0 0 0.00281905 l
+-0.422659 -0.538825 -0.424986 -0.527468 0 0 0 0.00281905 l
+-0.422659 -0.538825 -0.420875 -0.538723 0 0 0 0.00281905 l
+-0.422659 -0.538825 -0.425568 -0.540517 0 0 0 0.00281905 l
+-0.266263 -0.0579224 -0.257268 -0.0410096 0 0 0 0.00281905 l
+-0.266263 -0.0579224 -0.266062 -0.0599483 0 0 0 0.00281905 l
+-0.266263 -0.0579224 -0.2754 -0.0530764 0 0 0 0.00281905 l
+-0.0258673 0.442291 -0.0153619 0.443188 0 0 0 0.00281905 l
+-0.0258673 0.442291 -0.0257452 0.438031 0 0 0 0.00281905 l
+-0.0258673 0.442291 -0.0306977 0.445289 0 0 0 0.00281905 l
+-0.701231 0.13214 -0.713311 0.118105 0 0 0 0.00281905 l
+-0.701231 0.13214 -0.709961 0.148032 0 0 0 0.00281905 l
+-0.168794 -0.259154 -0.181904 -0.247208 0 0 0 0.00281905 l
+-0.168794 -0.259154 -0.161152 -0.263029 0 0 0 0.00281905 l
+-0.168794 -0.259154 -0.173523 -0.267918 0 0 0 0.00281905 l
+0.551792 -0.181033 0.560795 -0.171927 0 0 0 0.00281905 l
+0.551792 -0.181033 0.535772 -0.186596 0 0 0 0.00281905 l
+0.28853 -0.218506 0.284203 -0.230681 0 0 0 0.00281905 l
+0.28853 -0.218506 0.293032 -0.216586 0 0 0 0.00281905 l
+0.164095 0.284327 0.174312 0.278757 0 0 0 0.00281905 l
+0.164095 0.284327 0.158782 0.27985 0 0 0 0.00281905 l
+0.724431 0.672511 0.718407 0.672556 0 0 0 0.00281905 l
+0.22159 -0.177689 0.230734 -0.189589 0 0 0 0.00281905 l
+0.22159 -0.177689 0.214993 -0.16831 0 0 0 0.00281905 l
+-0.163575 -0.0804066 -0.148472 -0.0721595 0 0 0 0.00281905 l
+-0.163575 -0.0804066 -0.168607 -0.0811395 0 0 0 0.00281905 l
+-0.699276 -0.144943 -0.71649 -0.143018 0 0 0 0.00281905 l
+0.406158 -0.161392 0.412434 -0.168448 0 0 0 0.00281905 l
+0.406158 -0.161392 0.398177 -0.173902 0 0 0 0.00281905 l
+0.453563 0.516157 0.465762 0.527534 0 0 0 0.00281905 l
+0.453563 0.516157 0.444396 0.513378 0 0 0 0.00281905 l
+0.332855 0.435582 0.342469 0.44431 0 0 0 0.00281905 l
+0.332855 0.435582 0.326261 0.444142 0 0 0 0.00281905 l
+0.332855 0.435582 0.328125 0.4328 0 0 0 0.00281905 l
+0.235456 -0.86862 0.246912 -0.869057 0 0 0 0.00281905 l
+-0.605734 -0.470135 -0.597708 -0.476284 0 0 0 0.00281905 l
+-0.605734 -0.470135 -0.60994 -0.467014 0 0 0 0.00281905 l
+-0.445922 0.200022 -0.441757 0.204619 0 0 0 0.00281905 l
+-0.445922 0.200022 -0.446841 0.199445 0 0 0 0.00281905 l
+-0.957745 0.204277 -0.953943 0.191822 0 0 0 0.00281905 l
+-0.957745 0.204277 -0.948622 0.211428 0 0 0 0.00281905 l
+-0.957745 0.204277 -0.975718 0.218857 0 0 0 0.00281905 l
+0.664467 0.608874 0.677766 0.609084 0 0 0 0.00281905 l
+0.664467 0.608874 0.659766 0.613087 0 0 0 0.00281905 l
+-0.164553 -0.5233 -0.159931 -0.520859 0 0 0 0.00281905 l
+-0.164553 -0.5233 -0.17384 -0.517685 0 0 0 0.00281905 l
+-0.569905 -0.238293 -0.570609 -0.22955 0 0 0 0.00281905 l
+-0.643065 0.137531 -0.643641 0.12767 0 0 0 0.00281905 l
+-0.643065 0.137531 -0.641192 0.142027 0 0 0 0.00281905 l
+0.532065 0.407789 0.532601 0.412757 0 0 0 0.00281905 l
+0.532065 0.407789 0.5297 0.401636 0 0 0 0.00281905 l
+0.0728629 0.797144 0.0727212 0.817437 0 0 0 0.00281905 l
+0.0728629 0.797144 0.0722856 0.784959 0 0 0 0.00281905 l
+0.0728629 0.797144 0.0604241 0.792402 0 0 0 0.00281905 l
+0.425206 0.0767722 0.417959 0.0667413 0 0 0 0.00281905 l
+-0.386672 -0.912975 -0.388642 -0.911226 0 0 0 0.00281905 l
+-0.0748145 -0.122022 -0.0681322 -0.117907 0 0 0 0.00281905 l
+-0.0748145 -0.122022 -0.0853062 -0.132816 0 0 0 0.00281905 l
+-0.625565 -0.600683 -0.63148 -0.595981 0 0 0 0.00281905 l
+-0.625565 -0.600683 -0.614658 -0.595104 0 0 0 0.00281905 l
+-0.367697 0.13038 -0.370043 0.135253 0 0 0 0.00281905 l
+-0.367697 0.13038 -0.356705 0.124652 0 0 0 0.00281905 l
+-0.367697 0.13038 -0.369552 0.125253 0 0 0 0.00281905 l
+-0.126333 -0.894108 -0.115396 -0.90128 0 0 0 0.00281905 l
+-0.126333 -0.894108 -0.140269 -0.8851 0 0 0 0.00281905 l
+-0.126333 -0.894108 -0.118871 -0.886589 0 0 0 0.00281905 l
+-0.126333 -0.894108 -0.133958 -0.902922 0 0 0 0.00281905 l
+0.728455 0.617817 0.720558 0.627243 0 0 0 0.00281905 l
+0.728455 0.617817 0.726389 0.612936 0 0 0 0.00281905 l
+0.452118 -0.116129 0.459135 -0.126023 0 0 0 0.00281905 l
+0.452118 -0.116129 0.448906 -0.118412 0 0 0 0.00281905 l
+-0.197738 -0.723959 -0.177976 -0.729517 0 0 0 0.00281905 l
+-0.197738 -0.723959 -0.199499 -0.715209 0 0 0 0.00281905 l
+-0.197738 -0.723959 -0.217218 -0.728543 0 0 0 0.00281905 l
+0.556863 -0.433521 0.567632 -0.443996 0 0 0 0.00281905 l
+0.556863 -0.433521 0.549632 -0.415546 0 0 0 0.00281905 l
+0.556863 -0.433521 0.547155 -0.442173 0 0 0 0.00281905 l
+-0.469134 0.0676284 -0.456841 0.0530636 0 0 0 0.00281905 l
+-0.469134 0.0676284 -0.473493 0.0653732 0 0 0 0.00281905 l
+0.644423 0.608301 0.659766 0.613087 0 0 0 0.00281905 l
+-0.387076 0.692185 -0.395239 0.703694 0 0 0 0.00281905 l
+-0.387076 0.692185 -0.374877 0.683565 0 0 0 0.00281905 l
+0.00834311 0.92391 0.0179357 0.899116 0 0 0 0.00281905 l
+0.00834311 0.92391 0.0068649 0.923351 0 0 0 0.00281905 l
+-0.256929 0.372516 -0.256081 0.357732 0 0 0 0.00281905 l
+-0.256929 0.372516 -0.258711 0.378563 0 0 0 0.00281905 l
+-0.256929 0.372516 -0.25286 0.374782 0 0 0 0.00281905 l
+0.669215 0.0807122 0.68259 0.0768876 0 0 0 0.00281905 l
+0.669215 0.0807122 0.653338 0.0835046 0 0 0 0.00281905 l
+0.752599 -0.460121 0.754268 -0.437199 0 0 0 0.00281905 l
+0.752599 -0.460121 0.75903 -0.469819 0 0 0 0.00281905 l
+0.752599 -0.460121 0.746468 -0.465922 0 0 0 0.00281905 l
+0.641067 0.23596 0.657387 0.247274 0 0 0 0.00281905 l
+0.641067 0.23596 0.659074 0.224573 0 0 0 0.00281905 l
+0.753179 0.495628 0.764545 0.50187 0 0 0 0.00281905 l
+0.753179 0.495628 0.755358 0.485475 0 0 0 0.00281905 l
+0.753179 0.495628 0.750135 0.502492 0 0 0 0.00281905 l
+-0.268815 -0.269799 -0.261824 -0.262972 0 0 0 0.00281905 l
+-0.268815 -0.269799 -0.279303 -0.260478 0 0 0 0.00281905 l
+0.447568 0.429806 0.453733 0.427783 0 0 0 0.00281905 l
+0.447568 0.429806 0.440848 0.417584 0 0 0 0.00281905 l
+0.447568 0.429806 0.438586 0.431477 0 0 0 0.00281905 l
+0.233137 -0.755956 0.237639 -0.75135 0 0 0 0.00281905 l
+-0.435547 0.54589 -0.419592 0.542858 0 0 0 0.00281905 l
+-0.435547 0.54589 -0.445777 0.542124 0 0 0 0.00281905 l
+-0.435547 0.54589 -0.433849 0.550762 0 0 0 0.00281905 l
+0.867339 0.39768 0.873613 0.399164 0 0 0 0.00281905 l
+0.867339 0.39768 0.864085 0.397894 0 0 0 0.00281905 l
+0.423059 0.845086 0.42646 0.83955 0 0 0 0.00281905 l
+0.423059 0.845086 0.413854 0.862225 0 0 0 0.00281905 l
+0.423059 0.845086 0.420483 0.843894 0 0 0 0.00281905 l
+-0.446904 0.510684 -0.44388 0.507345 0 0 0 0.00281905 l
+-0.446904 0.510684 -0.463259 0.522595 0 0 0 0.00281905 l
+0.497834 -0.52737 0.499032 -0.533761 0 0 0 0.00281905 l
+-0.421177 0.848329 -0.417835 0.846606 0 0 0 0.00281905 l
+-0.421177 0.848329 -0.422024 0.850861 0 0 0 0.00281905 l
+0.179976 -0.240723 0.183478 -0.239425 0 0 0 0.00281905 l
+0.179976 -0.240723 0.180685 -0.248905 0 0 0 0.00281905 l
+0.527264 -0.0945232 0.519092 -0.08444 0 0 0 0.00281905 l
+0.527264 -0.0945232 0.536093 -0.0975822 0 0 0 0.00281905 l
+0.109962 -0.884259 0.112264 -0.86867 0 0 0 0.00281905 l
+0.109962 -0.884259 0.120389 -0.888028 0 0 0 0.00281905 l
+0.0545468 0.61495 0.0659407 0.614678 0 0 0 0.00281905 l
+0.0545468 0.61495 0.049647 0.597589 0 0 0 0.00281905 l
+-0.0760159 0.540889 -0.0702927 0.538948 0 0 0 0.00281905 l
+-0.0760159 0.540889 -0.0781541 0.536559 0 0 0 0.00281905 l
+0.153545 -0.334367 0.152326 -0.326305 0 0 0 0.00281905 l
+0.153545 -0.334367 0.141916 -0.345739 0 0 0 0.00281905 l
+-0.515388 -0.00173529 -0.512845 -0.00286025 0 0 0 0.00281905 l
+-0.515388 -0.00173529 -0.524966 0.0105456 0 0 0 0.00281905 l
+0.333046 0.40992 0.331876 0.408811 0 0 0 0.00281905 l
+0.920339 -0.380327 0.91664 -0.389836 0 0 0 0.00281905 l
+0.920339 -0.380327 0.914172 -0.37388 0 0 0 0.00281905 l
+0.279665 0.658522 0.286418 0.673668 0 0 0 0.00281905 l
+0.279665 0.658522 0.287747 0.653558 0 0 0 0.00281905 l
+-0.916644 -0.234605 -0.90338 -0.236517 0 0 0 0.00281905 l
+-0.19267 0.176945 -0.17991 0.178676 0 0 0 0.00281905 l
+-0.19267 0.176945 -0.200992 0.16251 0 0 0 0.00281905 l
+-0.0723769 0.270172 -0.0694484 0.260371 0 0 0 0.00281905 l
+-0.0723769 0.270172 -0.0731474 0.279377 0 0 0 0.00281905 l
+-0.148472 -0.0721595 -0.135879 -0.083559 0 0 0 0.00281905 l
+-0.148472 -0.0721595 -0.163575 -0.0804066 0 0 0 0.00281905 l
+-0.901382 -0.216828 -0.90338 -0.236517 0 0 0 0.00281905 l
+-0.901382 -0.216828 -0.889702 -0.219306 0 0 0 0.00281905 l
+-0.191317 0.887829 -0.190485 0.885841 0 0 0 0.00281905 l
+-0.191317 0.887829 -0.197096 0.896493 0 0 0 0.00281905 l
+0.595419 -0.543231 0.6041 -0.538053 0 0 0 0.00281905 l
+0.595419 -0.543231 0.588412 -0.53752 0 0 0 0.00281905 l
+0.890066 -0.361856 0.90764 -0.372444 0 0 0 0.00281905 l
+0.890066 -0.361856 0.8813 -0.35806 0 0 0 0.00281905 l
+-0.362233 -0.162009 -0.362215 -0.153335 0 0 0 0.00281905 l
+-0.362233 -0.162009 -0.379721 -0.161118 0 0 0 0.00281905 l
+-0.349473 0.270782 -0.35061 0.273894 0 0 0 0.00281905 l
+-0.728368 -0.586829 -0.718363 -0.585222 0 0 0 0.00281905 l
+-0.728368 -0.586829 -0.729193 -0.584785 0 0 0 0.00281905 l
+0.429826 0.813689 0.417154 0.81735 0 0 0 0.00281905 l
+0.429826 0.813689 0.430781 0.815749 0 0 0 0.00281905 l
+0.120389 -0.888028 0.125004 -0.888027 0 0 0 0.00281905 l
+0.120389 -0.888028 0.109962 -0.884259 0 0 0 0.00281905 l
+-0.367419 0.374032 -0.367107 0.362705 0 0 0 0.00281905 l
+-0.367419 0.374032 -0.37454 0.374179 0 0 0 0.00281905 l
+-0.282015 -0.46428 -0.28202 -0.462811 0 0 0 0.00281905 l
+0.10413 0.565506 0.115071 0.558496 0 0 0 0.00281905 l
+-0.0429263 0.224521 -0.0354421 0.245718 0 0 0 0.00281905 l
+-0.0429263 0.224521 -0.0393383 0.215306 0 0 0 0.00281905 l
+0.461629 -0.272027 0.469928 -0.260851 0 0 0 0.00281905 l
+0.461629 -0.272027 0.450681 -0.268341 0 0 0 0.00281905 l
+-0.254661 0.323686 -0.269692 0.321634 0 0 0 0.00281905 l
+-0.233367 -0.276709 -0.228836 -0.287647 0 0 0 0.00281905 l
+-0.233367 -0.276709 -0.229227 -0.274779 0 0 0 0.00281905 l
+-0.233367 -0.276709 -0.243824 -0.279169 0 0 0 0.00281905 l
+-0.256351 0.56344 -0.248465 0.569556 0 0 0 0.00281905 l
+-0.256351 0.56344 -0.259983 0.556263 0 0 0 0.00281905 l
+-0.574096 -0.158554 -0.562868 -0.146255 0 0 0 0.00281905 l
+-0.574096 -0.158554 -0.555992 -0.165243 0 0 0 0.00281905 l
+-0.00328876 -0.436844 -0.00427752 -0.447583 0 0 0 0.00281905 l
+-0.00328876 -0.436844 -0.0166209 -0.430136 0 0 0 0.00281905 l
+0.152219 0.149709 0.157982 0.143075 0 0 0 0.00281905 l
+0.152219 0.149709 0.140122 0.155097 0 0 0 0.00281905 l
+0.152219 0.149709 0.158099 0.157696 0 0 0 0.00281905 l
+0.287032 -0.600744 0.295567 -0.597501 0 0 0 0.00281905 l
+0.287032 -0.600744 0.28928 -0.608556 0 0 0 0.00281905 l
+-0.0417472 -0.883062 -0.0532179 -0.886292 0 0 0 0.00281905 l
+-0.222548 0.413959 -0.221782 0.417106 0 0 0 0.00281905 l
+0.0908494 0.890395 0.0849622 0.907348 0 0 0 0.00281905 l
+0.0908494 0.890395 0.103457 0.893661 0 0 0 0.00281905 l
+-0.487846 0.224646 -0.495399 0.210341 0 0 0 0.00281905 l
+-0.487846 0.224646 -0.478139 0.235726 0 0 0 0.00281905 l
+0.985674 0.0352875 0.994508 0.0537307 0 0 0 0.00281905 l
+0.985674 0.0352875 0.981623 0.0303927 0 0 0 0.00281905 l
+0.0924507 0.749409 0.0916609 0.760925 0 0 0 0.00281905 l
+0.0924507 0.749409 0.0983228 0.746278 0 0 0 0.00281905 l
+0.0924507 0.749409 0.0777288 0.746287 0 0 0 0.00281905 l
+0.421521 0.709131 0.417419 0.721553 0 0 0 0.00281905 l
+0.421521 0.709131 0.434014 0.702679 0 0 0 0.00281905 l
+0.421521 0.709131 0.40887 0.699345 0 0 0 0.00281905 l
+0.412743 0.140121 0.416894 0.139221 0 0 0 0.00281905 l
+0.412743 0.140121 0.405075 0.139008 0 0 0 0.00281905 l
+-0.497717 0.690533 -0.484009 0.696163 0 0 0 0.00281905 l
+-0.497717 0.690533 -0.512401 0.694281 0 0 0 0.00281905 l
+-0.677442 -0.0428734 -0.669518 -0.0444978 0 0 0 0.00281905 l
+-0.677442 -0.0428734 -0.680974 -0.0567207 0 0 0 0.00281905 l
+-0.677442 -0.0428734 -0.696059 -0.0329919 0 0 0 0.00281905 l
+-0.497017 -0.165525 -0.493528 -0.187068 0 0 0 0.00281905 l
+-0.497017 -0.165525 -0.506752 -0.169045 0 0 0 0.00281905 l
+0.173389 0.180649 0.161886 0.194542 0 0 0 0.00281905 l
+0.173389 0.180649 0.176952 0.178014 0 0 0 0.00281905 l
+-0.356974 -0.0507432 -0.35865 -0.0668503 0 0 0 0.00281905 l
+-0.356974 -0.0507432 -0.364598 -0.0445639 0 0 0 0.00281905 l
+-0.714001 0.451106 -0.703036 0.439787 0 0 0 0.00281905 l
+-0.714001 0.451106 -0.706684 0.456713 0 0 0 0.00281905 l
+-0.714001 0.451106 -0.730473 0.453691 0 0 0 0.00281905 l
+-0.758946 0.383348 -0.752266 0.366741 0 0 0 0.00281905 l
+-0.758946 0.383348 -0.768309 0.388209 0 0 0 0.00281905 l
+-0.00100853 -0.358107 0.00108654 -0.366223 0 0 0 0.00281905 l
+-0.00100853 -0.358107 -0.00825396 -0.349622 0 0 0 0.00281905 l
+-0.738376 0.16698 -0.737176 0.161142 0 0 0 0.00281905 l
+-0.738376 0.16698 -0.741142 0.1823 0 0 0 0.00281905 l
+-0.738376 0.16698 -0.723295 0.17495 0 0 0 0.00281905 l
+-0.738376 0.16698 -0.754855 0.165196 0 0 0 0.00281905 l
+-0.262338 -0.439149 -0.253215 -0.431795 0 0 0 0.00281905 l
+-0.262338 -0.439149 -0.26684 -0.440211 0 0 0 0.00281905 l
+-0.399406 -0.321599 -0.406922 -0.304288 0 0 0 0.00281905 l
+-0.399406 -0.321599 -0.403772 -0.332374 0 0 0 0.00281905 l
+-0.362956 -0.903842 -0.356519 -0.893897 0 0 0 0.00281905 l
+-0.362956 -0.903842 -0.363682 -0.919595 0 0 0 0.00281905 l
+0.607404 -0.69953 0.601651 -0.68348 0 0 0 0.00281905 l
+0.607404 -0.69953 0.607206 -0.705842 0 0 0 0.00281905 l
+0.607404 -0.69953 0.592054 -0.697949 0 0 0 0.00281905 l
+-0.468177 0.664858 -0.480281 0.674573 0 0 0 0.00281905 l
+-0.787553 -0.566308 -0.782615 -0.566311 0 0 0 0.00281905 l
+-0.787553 -0.566308 -0.78591 -0.585242 0 0 0 0.00281905 l
+-0.787553 -0.566308 -0.795524 -0.55775 0 0 0 0.00281905 l
+0.384458 -0.459086 0.386067 -0.465405 0 0 0 0.00281905 l
+0.423263 -0.290453 0.422844 -0.286039 0 0 0 0.00281905 l
+0.423263 -0.290453 0.43207 -0.301807 0 0 0 0.00281905 l
+0.423263 -0.290453 0.407732 -0.297409 0 0 0 0.00281905 l
+-0.236652 -0.478185 -0.225697 -0.487049 0 0 0 0.00281905 l
+-0.236652 -0.478185 -0.24324 -0.480261 0 0 0 0.00281905 l
+-0.582155 0.668321 -0.583424 0.676087 0 0 0 0.00281905 l
+-0.582155 0.668321 -0.590882 0.65319 0 0 0 0.00281905 l
+-0.582155 0.668321 -0.566998 0.66675 0 0 0 0.00281905 l
+-0.727751 -0.184077 -0.732872 -0.199186 0 0 0 0.00281905 l
+-0.727751 -0.184077 -0.71334 -0.17131 0 0 0 0.00281905 l
+-0.727751 -0.184077 -0.734401 -0.17399 0 0 0 0.00281905 l
+0.113009 -0.950783 0.113151 -0.947652 0 0 0 0.00281905 l
+0.113009 -0.950783 0.106614 -0.95335 0 0 0 0.00281905 l
+0.519605 -0.56043 0.517946 -0.568989 0 0 0 0.00281905 l
+0.519605 -0.56043 0.512163 -0.562278 0 0 0 0.00281905 l
+0.0268152 0.0687403 0.0414452 0.0816184 0 0 0 0.00281905 l
+0.0268152 0.0687403 0.0239222 0.0617035 0 0 0 0.00281905 l
+-0.211231 -0.808719 -0.198886 -0.811867 0 0 0 0.00281905 l
+0.794599 -0.138796 0.792143 -0.131356 0 0 0 0.00281905 l
+-0.196043 -0.0869308 -0.188815 -0.0783077 0 0 0 0.00281905 l
+0.577711 0.378431 0.583369 0.371326 0 0 0 0.00281905 l
+0.577711 0.378431 0.576842 0.38169 0 0 0 0.00281905 l
+-0.802534 0.120231 -0.788413 0.138742 0 0 0 0.00281905 l
+-0.802534 0.120231 -0.804575 0.112702 0 0 0 0.00281905 l
+-0.802534 0.120231 -0.816289 0.123641 0 0 0 0.00281905 l
+-0.159868 0.891499 -0.16459 0.910971 0 0 0 0.00281905 l
+-0.159868 0.891499 -0.154582 0.887362 0 0 0 0.00281905 l
+0.922466 -0.117191 0.924565 -0.108377 0 0 0 0.00281905 l
+0.922466 -0.117191 0.919393 -0.129885 0 0 0 0.00281905 l
+-0.703997 0.0548335 -0.709037 0.0394558 0 0 0 0.00281905 l
+-0.703997 0.0548335 -0.694 0.0567076 0 0 0 0.00281905 l
+0.532209 -0.652247 0.549349 -0.658081 0 0 0 0.00281905 l
+0.532209 -0.652247 0.530834 -0.671606 0 0 0 0.00281905 l
+0.532209 -0.652247 0.522067 -0.651999 0 0 0 0.00281905 l
+-0.0950944 -0.436901 -0.0970157 -0.422405 0 0 0 0.00281905 l
+-0.0950944 -0.436901 -0.0880438 -0.443854 0 0 0 0.00281905 l
+-0.0950944 -0.436901 -0.111602 -0.43838 0 0 0 0.00281905 l
+0.134113 0.34395 0.129685 0.361057 0 0 0 0.00281905 l
+0.134113 0.34395 0.128881 0.336814 0 0 0 0.00281905 l
+-0.70419 0.188485 -0.710342 0.17499 0 0 0 0.00281905 l
+-0.70419 0.188485 -0.690279 0.194272 0 0 0 0.00281905 l
+-0.70419 0.188485 -0.719223 0.195549 0 0 0 0.00281905 l
+0.221944 0.195347 0.245335 0.195889 0 0 0 0.00281905 l
+0.221944 0.195347 0.221504 0.187709 0 0 0 0.00281905 l
+0.221944 0.195347 0.219849 0.204669 0 0 0 0.00281905 l
+-0.769035 -0.395903 -0.760096 -0.409658 0 0 0 0.00281905 l
+-0.769035 -0.395903 -0.78233 -0.385587 0 0 0 0.00281905 l
+-0.215549 -0.00875762 -0.213792 -0.0177131 0 0 0 0.00281905 l
+-0.215549 -0.00875762 -0.22228 0.00478532 0 0 0 0.00281905 l
+-0.37329 0.383362 -0.374543 0.392668 0 0 0 0.00281905 l
+-0.37329 0.383362 -0.37454 0.374179 0 0 0 0.00281905 l
+-0.37329 0.383362 -0.379128 0.383973 0 0 0 0.00281905 l
+0.409105 0.273777 0.411891 0.273496 0 0 0 0.00281905 l
+0.428923 -0.241124 0.430612 -0.2572 0 0 0 0.00281905 l
+-0.670948 -0.235338 -0.675506 -0.22828 0 0 0 0.00281905 l
+-0.670948 -0.235338 -0.669978 -0.242851 0 0 0 0.00281905 l
+-0.0101216 0.685435 0.00167698 0.690373 0 0 0 0.00281905 l
+0.432988 0.815561 0.430781 0.815749 0 0 0 0.00281905 l
+-0.90338 -0.236517 -0.901382 -0.216828 0 0 0 0.00281905 l
+-0.90338 -0.236517 -0.888712 -0.239626 0 0 0 0.00281905 l
+-0.90338 -0.236517 -0.906424 -0.244679 0 0 0 0.00281905 l
+-0.90338 -0.236517 -0.916644 -0.234605 0 0 0 0.00281905 l
+0.0766732 0.92613 0.0849622 0.907348 0 0 0 0.00281905 l
+0.0766732 0.92613 0.0786691 0.930816 0 0 0 0.00281905 l
+0.0766732 0.92613 0.0661742 0.916341 0 0 0 0.00281905 l
+-0.179933 0.452799 -0.165485 0.443469 0 0 0 0.00281905 l
+-0.179933 0.452799 -0.184303 0.462078 0 0 0 0.00281905 l
+-0.0536392 0.419437 -0.0410162 0.425466 0 0 0 0.00281905 l
+-0.0536392 0.419437 -0.0541708 0.419667 0 0 0 0.00281905 l
+0.253907 -0.760727 0.245413 -0.776023 0 0 0 0.00281905 l
+0.253907 -0.760727 0.258461 -0.756421 0 0 0 0.00281905 l
+0.253907 -0.760727 0.240788 -0.754287 0 0 0 0.00281905 l
+0.559568 -0.205229 0.556627 -0.210148 0 0 0 0.00281905 l
+0.480623 0.594851 0.491381 0.601615 0 0 0 0.00281905 l
+0.480623 0.594851 0.471711 0.598913 0 0 0 0.00281905 l
+-0.197985 0.759121 -0.18939 0.759133 0 0 0 0.00281905 l
+-0.197985 0.759121 -0.216038 0.771047 0 0 0 0.00281905 l
+0.391326 0.180805 0.408421 0.190148 0 0 0 0.00281905 l
+0.391326 0.180805 0.380019 0.179202 0 0 0 0.00281905 l
+0.732828 -0.302186 0.721342 -0.306479 0 0 0 0.00281905 l
+0.243997 0.688842 0.246504 0.704912 0 0 0 0.00281905 l
+0.243997 0.688842 0.258514 0.687966 0 0 0 0.00281905 l
+0.243997 0.688842 0.23212 0.694975 0 0 0 0.00281905 l
+0.258461 -0.756421 0.253907 -0.760727 0 0 0 0.00281905 l
+-0.418711 -0.285416 -0.420201 -0.279309 0 0 0 0.00281905 l
+-0.418711 -0.285416 -0.413061 -0.295541 0 0 0 0.00281905 l
+-0.418711 -0.285416 -0.430378 -0.29263 0 0 0 0.00281905 l
+-0.54565 -0.398647 -0.555383 -0.398187 0 0 0 0.00281905 l
+0.903665 0.305051 0.899132 0.315069 0 0 0 0.00281905 l
+-0.90268 0.405578 -0.893552 0.407985 0 0 0 0.00281905 l
+-0.90268 0.405578 -0.903453 0.401688 0 0 0 0.00281905 l
+-0.626343 -0.139335 -0.624409 -0.159302 0 0 0 0.00281905 l
+0.752969 -0.301095 0.769019 -0.292896 0 0 0 0.00281905 l
+0.752969 -0.301095 0.75613 -0.306594 0 0 0 0.00281905 l
+-0.475176 0.335801 -0.461762 0.313181 0 0 0 0.00281905 l
+-0.475176 0.335801 -0.482106 0.339872 0 0 0 0.00281905 l
+-0.701956 -0.321023 -0.688805 -0.321425 0 0 0 0.00281905 l
+-0.701956 -0.321023 -0.715794 -0.330412 0 0 0 0.00281905 l
+0.554764 -0.10916 0.561292 -0.0996268 0 0 0 0.00281905 l
+0.554764 -0.10916 0.547045 -0.112631 0 0 0 0.00281905 l
+-0.0135983 0.788935 -0.0279088 0.773898 0 0 0 0.00281905 l
+-0.0135983 0.788935 -0.00589301 0.785368 0 0 0 0.00281905 l
+0.579712 0.753556 0.58943 0.748446 0 0 0 0.00281905 l
+0.579712 0.753556 0.57563 0.745279 0 0 0 0.00281905 l
+0.579712 0.753556 0.567557 0.760158 0 0 0 0.00281905 l
+0.272916 -0.91096 0.27902 -0.908251 0 0 0 0.00281905 l
+0.272916 -0.91096 0.268362 -0.910512 0 0 0 0.00281905 l
+-0.244503 -0.925519 -0.245392 -0.930029 0 0 0 0.00281905 l
+-0.244503 -0.925519 -0.247887 -0.922799 0 0 0 0.00281905 l
+-0.411284 -0.837183 -0.407277 -0.825366 0 0 0 0.00281905 l
+-0.411284 -0.837183 -0.407178 -0.841708 0 0 0 0.00281905 l
+-0.411284 -0.837183 -0.425707 -0.842117 0 0 0 0.00281905 l
+-0.119486 -0.00896643 -0.116723 -0.0085806 0 0 0 0.00281905 l
+-0.119486 -0.00896643 -0.132752 -0.0207942 0 0 0 0.00281905 l
+0.017707 0.31117 0.0323967 0.316593 0 0 0 0.00281905 l
+0.017707 0.31117 0.0149366 0.3113 0 0 0 0.00281905 l
+-0.0970157 -0.422405 -0.0950944 -0.436901 0 0 0 0.00281905 l
+-0.0970157 -0.422405 -0.105436 -0.407656 0 0 0 0.00281905 l
+-0.941154 0.282361 -0.942199 0.272833 0 0 0 0.00281905 l
+-0.941154 0.282361 -0.935223 0.294584 0 0 0 0.00281905 l
+0.648666 0.15843 0.656409 0.157807 0 0 0 0.00281905 l
+0.648666 0.15843 0.649502 0.150461 0 0 0 0.00281905 l
+-0.266285 -0.104597 -0.260789 -0.105218 0 0 0 0.00281905 l
+-0.266285 -0.104597 -0.265806 -0.108363 0 0 0 0.00281905 l
+-0.266285 -0.104597 -0.26311 -0.096409 0 0 0 0.00281905 l
+-0.708656 -0.617941 -0.6973 -0.624367 0 0 0 0.00281905 l
+-0.708656 -0.617941 -0.71292 -0.628767 0 0 0 0.00281905 l
+-0.708656 -0.617941 -0.714436 -0.614022 0 0 0 0.00281905 l
+0.794609 0.399406 0.796442 0.409934 0 0 0 0.00281905 l
+0.794609 0.399406 0.80871 0.401057 0 0 0 0.00281905 l
+0.794609 0.399406 0.773631 0.397263 0 0 0 0.00281905 l
+-0.366808 -0.517668 -0.35997 -0.519059 0 0 0 0.00281905 l
+-0.366808 -0.517668 -0.369098 -0.52461 0 0 0 0.00281905 l
+0.175316 -0.187113 0.176916 -0.170433 0 0 0 0.00281905 l
+0.474353 0.683127 0.493003 0.679399 0 0 0 0.00281905 l
+0.474353 0.683127 0.456284 0.685642 0 0 0 0.00281905 l
+0.474353 0.683127 0.474909 0.685583 0 0 0 0.00281905 l
+-0.224412 -0.58172 -0.23025 -0.595513 0 0 0 0.00281905 l
+-0.224412 -0.58172 -0.213432 -0.576936 0 0 0 0.00281905 l
+-0.224412 -0.58172 -0.234754 -0.573227 0 0 0 0.00281905 l
+-0.636371 0.272648 -0.632388 0.286165 0 0 0 0.00281905 l
+-0.636371 0.272648 -0.640677 0.269013 0 0 0 0.00281905 l
+-0.644626 0.594498 -0.64448 0.602419 0 0 0 0.00281905 l
+-0.644626 0.594498 -0.65375 0.588001 0 0 0 0.00281905 l
+0.696891 0.575034 0.700327 0.587275 0 0 0 0.00281905 l
+0.696891 0.575034 0.70167 0.566035 0 0 0 0.00281905 l
+0.0342533 -0.480061 0.0364645 -0.486172 0 0 0 0.00281905 l
+0.0342533 -0.480061 0.0350647 -0.47592 0 0 0 0.00281905 l
+0.436464 0.611864 0.454214 0.606857 0 0 0 0.00281905 l
+0.436464 0.611864 0.43425 0.601834 0 0 0 0.00281905 l
+0.436464 0.611864 0.433054 0.614152 0 0 0 0.00281905 l
+-0.682015 0.596803 -0.678767 0.602167 0 0 0 0.00281905 l
+-0.815115 0.283269 -0.827296 0.286213 0 0 0 0.00281905 l
+-0.631451 -0.461741 -0.622459 -0.471024 0 0 0 0.00281905 l
+-0.631451 -0.461741 -0.625799 -0.458232 0 0 0 0.00281905 l
+-0.631451 -0.461741 -0.635237 -0.457554 0 0 0 0.00281905 l
+0.276596 0.194344 0.264406 0.195295 0 0 0 0.00281905 l
+0.276596 0.194344 0.278334 0.197929 0 0 0 0.00281905 l
+0.0301894 0.168643 0.0306661 0.172097 0 0 0 0.00281905 l
+0.665123 0.19205 0.658198 0.207619 0 0 0 0.00281905 l
+0.665123 0.19205 0.666081 0.191083 0 0 0 0.00281905 l
+-0.525497 0.710533 -0.517202 0.706725 0 0 0 0.00281905 l
+-0.525497 0.710533 -0.527454 0.70739 0 0 0 0.00281905 l
+-0.565561 -0.633652 -0.562795 -0.631207 0 0 0 0.00281905 l
+-0.581146 -0.610277 -0.592807 -0.593134 0 0 0 0.00281905 l
+-0.581146 -0.610277 -0.577883 -0.617961 0 0 0 0.00281905 l
+-0.910548 0.0550818 -0.905055 0.0581861 0 0 0 0.00281905 l
+0.721115 -0.646881 0.721461 -0.639918 0 0 0 0.00281905 l
+0.721115 -0.646881 0.729565 -0.651262 0 0 0 0.00281905 l
+0.721115 -0.646881 0.713911 -0.646336 0 0 0 0.00281905 l
+0.0811246 -0.761723 0.0926123 -0.74928 0 0 0 0.00281905 l
+0.0811246 -0.761723 0.0984956 -0.768258 0 0 0 0.00281905 l
+0.0811246 -0.761723 0.0778287 -0.765498 0 0 0 0.00281905 l
+-0.545108 -0.159155 -0.531938 -0.163738 0 0 0 0.00281905 l
+-0.545108 -0.159155 -0.555992 -0.165243 0 0 0 0.00281905 l
+-0.783088 0.451357 -0.773749 0.466639 0 0 0 0.00281905 l
+-0.783088 0.451357 -0.787024 0.452823 0 0 0 0.00281905 l
+-0.383147 0.251792 -0.373852 0.248632 0 0 0 0.00281905 l
+-0.383147 0.251792 -0.385247 0.243873 0 0 0 0.00281905 l
+-0.444314 0.271636 -0.434903 0.271499 0 0 0 0.00281905 l
+-0.387782 -0.197817 -0.385279 -0.206878 0 0 0 0.00281905 l
+-0.387782 -0.197817 -0.387703 -0.194354 0 0 0 0.00281905 l
+-0.701125 0.0135103 -0.716227 0.0237814 0 0 0 0.00281905 l
+-0.701125 0.0135103 -0.703944 0.00866701 0 0 0 0.00281905 l
+-0.86572 0.37585 -0.8608 0.387165 0 0 0 0.00281905 l
+-0.193221 -0.802274 -0.198065 -0.802898 0 0 0 0.00281905 l
+0.792984 0.604744 0.792462 0.584123 0 0 0 0.00281905 l
+0.792984 0.604744 0.77521 0.608905 0 0 0 0.00281905 l
+0.375707 -0.0747375 0.375711 -0.0797612 0 0 0 0.00281905 l
+0.375707 -0.0747375 0.385674 -0.0693716 0 0 0 0.00281905 l
+0.425089 0.135096 0.429505 0.128192 0 0 0 0.00281905 l
+0.425089 0.135096 0.416894 0.139221 0 0 0 0.00281905 l
+0.575828 0.418227 0.579847 0.425204 0 0 0 0.00281905 l
+0.575828 0.418227 0.573556 0.413521 0 0 0 0.00281905 l
+-0.948026 -0.0576251 -0.950454 -0.0405042 0 0 0 0.00281905 l
+-0.948026 -0.0576251 -0.938911 -0.0659163 0 0 0 0.00281905 l
+0.285307 -0.807843 0.294839 -0.814145 0 0 0 0.00281905 l
+0.285307 -0.807843 0.282011 -0.811365 0 0 0 0.00281905 l
+0.546767 0.565425 0.549955 0.546996 0 0 0 0.00281905 l
+0.546767 0.565425 0.53825 0.581333 0 0 0 0.00281905 l
+-0.228468 0.85644 -0.223671 0.844436 0 0 0 0.00281905 l
+-0.228468 0.85644 -0.236536 0.854296 0 0 0 0.00281905 l
+-0.564224 -0.621774 -0.561845 -0.630275 0 0 0 0.00281905 l
+-0.564224 -0.621774 -0.556272 -0.616707 0 0 0 0.00281905 l
+-0.564224 -0.621774 -0.577883 -0.617961 0 0 0 0.00281905 l
+0.269575 -0.0440042 0.279404 -0.0458935 0 0 0 0.00281905 l
+0.269575 -0.0440042 0.26828 -0.0431997 0 0 0 0.00281905 l
+0.233576 0.392689 0.238565 0.393327 0 0 0 0.00281905 l
+0.233576 0.392689 0.234598 0.380948 0 0 0 0.00281905 l
+0.233576 0.392689 0.223221 0.386072 0 0 0 0.00281905 l
+-0.270518 -0.586567 -0.270828 -0.581995 0 0 0 0.00281905 l
+-0.132943 -0.416401 -0.130469 -0.424963 0 0 0 0.00281905 l
+-0.132943 -0.416401 -0.133801 -0.401873 0 0 0 0.00281905 l
+0.981266 0.0557801 0.983838 0.0666955 0 0 0 0.00281905 l
+-0.87751 0.276645 -0.878127 0.292665 0 0 0 0.00281905 l
+-0.87751 0.276645 -0.868072 0.271042 0 0 0 0.00281905 l
+-0.87751 0.276645 -0.88469 0.273331 0 0 0 0.00281905 l
+0.391677 0.377247 0.397497 0.376167 0 0 0 0.00281905 l
+0.391677 0.377247 0.377782 0.38659 0 0 0 0.00281905 l
+0.18318 0.69858 0.184813 0.706819 0 0 0 0.00281905 l
+0.18318 0.69858 0.172204 0.684997 0 0 0 0.00281905 l
+-0.813228 -0.438529 -0.80508 -0.418363 0 0 0 0.00281905 l
+-0.813228 -0.438529 -0.827483 -0.43727 0 0 0 0.00281905 l
+-0.545413 -0.238942 -0.548027 -0.240373 0 0 0 0.00281905 l
+-0.0853175 0.789978 -0.068691 0.787664 0 0 0 0.00281905 l
+-0.0853175 0.789978 -0.0961382 0.780995 0 0 0 0.00281905 l
+-0.0853175 0.789978 -0.0967097 0.798948 0 0 0 0.00281905 l
+-0.45147 -0.624343 -0.461833 -0.638415 0 0 0 0.00281905 l
+-0.45147 -0.624343 -0.449711 -0.622759 0 0 0 0.00281905 l
+-0.544659 0.671935 -0.535068 0.679154 0 0 0 0.00281905 l
+-0.544659 0.671935 -0.551997 0.66562 0 0 0 0.00281905 l
+0.259045 -0.153383 0.261166 -0.145018 0 0 0 0.00281905 l
+0.259045 -0.153383 0.251298 -0.168779 0 0 0 0.00281905 l
+-0.418477 -0.0766387 -0.418018 -0.0712548 0 0 0 0.00281905 l
+-0.418477 -0.0766387 -0.418246 -0.0812016 0 0 0 0.00281905 l
+-0.418477 -0.0766387 -0.437549 -0.0782434 0 0 0 0.00281905 l
+-0.0355415 -0.528705 -0.0345044 -0.510134 0 0 0 0.00281905 l
+-0.0355415 -0.528705 -0.0355175 -0.536145 0 0 0 0.00281905 l
+0.0603862 -0.0743883 0.05447 -0.0862266 0 0 0 0.00281905 l
+0.0603862 -0.0743883 0.0679373 -0.061666 0 0 0 0.00281905 l
+0.0603862 -0.0743883 0.0466489 -0.0704684 0 0 0 0.00281905 l
+-0.834117 -0.00832675 -0.839647 -0.0248634 0 0 0 0.00281905 l
+-0.834117 -0.00832675 -0.837386 0.00531087 0 0 0 0.00281905 l
+-0.114744 0.850647 -0.106124 0.85749 0 0 0 0.00281905 l
+-0.114744 0.850647 -0.116348 0.851228 0 0 0 0.00281905 l
+0.257408 0.598408 0.252656 0.591472 0 0 0 0.00281905 l
+0.0746854 0.220278 0.0761444 0.232648 0 0 0 0.00281905 l
+0.0746854 0.220278 0.0774614 0.218943 0 0 0 0.00281905 l
+-0.33452 -0.619478 -0.337482 -0.642391 0 0 0 0.00281905 l
+-0.33452 -0.619478 -0.342686 -0.612462 0 0 0 0.00281905 l
+-0.290157 0.761985 -0.289121 0.746069 0 0 0 0.00281905 l
+-0.290157 0.761985 -0.279961 0.775062 0 0 0 0.00281905 l
+-0.717235 -0.345942 -0.715794 -0.330412 0 0 0 0.00281905 l
+-0.717235 -0.345942 -0.704795 -0.347772 0 0 0 0.00281905 l
+0.376464 -0.558093 0.39227 -0.562777 0 0 0 0.00281905 l
+0.376464 -0.558093 0.355587 -0.552695 0 0 0 0.00281905 l
+0.700614 -0.429468 0.707844 -0.427902 0 0 0 0.00281905 l
+0.700614 -0.429468 0.694562 -0.434884 0 0 0 0.00281905 l
+-0.00546681 0.853226 0.00507685 0.850444 0 0 0 0.00281905 l
+-0.00546681 0.853226 -0.0136998 0.864473 0 0 0 0.00281905 l
+-0.537417 -0.469011 -0.523163 -0.48391 0 0 0 0.00281905 l
+-0.537417 -0.469011 -0.547357 -0.456984 0 0 0 0.00281905 l
+-0.537417 -0.469011 -0.550417 -0.47467 0 0 0 0.00281905 l
+0.639392 -0.476488 0.656052 -0.484536 0 0 0 0.00281905 l
+0.639392 -0.476488 0.636319 -0.458628 0 0 0 0.00281905 l
+0.0282344 -0.528635 0.020818 -0.531706 0 0 0 0.00281905 l
+-0.0968438 0.659498 -0.0829132 0.657181 0 0 0 0.00281905 l
+-0.0968438 0.659498 -0.101224 0.65704 0 0 0 0.00281905 l
+-0.523972 -0.0527644 -0.512541 -0.0635361 0 0 0 0.00281905 l
+-0.523972 -0.0527644 -0.523826 -0.0454869 0 0 0 0.00281905 l
+0.816722 0.139001 0.81683 0.130372 0 0 0 0.00281905 l
+0.816722 0.139001 0.832684 0.14044 0 0 0 0.00281905 l
+0.816722 0.139001 0.813251 0.151959 0 0 0 0.00281905 l
+-0.179275 -0.758231 -0.174763 -0.76427 0 0 0 0.00281905 l
+-0.179275 -0.758231 -0.186073 -0.755861 0 0 0 0.00281905 l
+0.759747 0.640892 0.755031 0.642621 0 0 0 0.00281905 l
+-0.0895533 -0.268737 -0.0767205 -0.256275 0 0 0 0.00281905 l
+-0.0895533 -0.268737 -0.0856975 -0.276819 0 0 0 0.00281905 l
+-0.215572 -0.88459 -0.211695 -0.872174 0 0 0 0.00281905 l
+-0.215572 -0.88459 -0.222823 -0.891878 0 0 0 0.00281905 l
+0.80382 0.184186 0.806309 0.173724 0 0 0 0.00281905 l
+0.80382 0.184186 0.817785 0.191548 0 0 0 0.00281905 l
+0.80382 0.184186 0.800196 0.185397 0 0 0 0.00281905 l
+0.566307 0.681343 0.577515 0.669629 0 0 0 0.00281905 l
+0.566307 0.681343 0.565281 0.6854 0 0 0 0.00281905 l
+-0.9335 -0.314844 -0.925903 -0.313 0 0 0 0.00281905 l
+-0.0888367 -0.861559 -0.0939285 -0.847176 0 0 0 0.00281905 l
+-0.0888367 -0.861559 -0.0807489 -0.869869 0 0 0 0.00281905 l
+-0.0888367 -0.861559 -0.0923272 -0.865272 0 0 0 0.00281905 l
+0.506744 0.545489 0.508869 0.565763 0 0 0 0.00281905 l
+0.506744 0.545489 0.502619 0.534129 0 0 0 0.00281905 l
+0.411143 0.439133 0.397097 0.430242 0 0 0 0.00281905 l
+0.411143 0.439133 0.41212 0.438413 0 0 0 0.00281905 l
+0.411143 0.439133 0.41077 0.44138 0 0 0 0.00281905 l
+0.517946 -0.568989 0.519605 -0.56043 0 0 0 0.00281905 l
+-0.36452 -0.757353 -0.363737 -0.770325 0 0 0 0.00281905 l
+-0.36452 -0.757353 -0.376945 -0.745333 0 0 0 0.00281905 l
+-0.665407 -0.716963 -0.656915 -0.725085 0 0 0 0.00281905 l
+-0.665407 -0.716963 -0.690606 -0.712632 0 0 0 0.00281905 l
+-0.0235271 0.560363 -0.0241475 0.550379 0 0 0 0.00281905 l
+-0.0235271 0.560363 -0.0247685 0.562519 0 0 0 0.00281905 l
+0.249742 0.35797 0.24998 0.345634 0 0 0 0.00281905 l
+0.249742 0.35797 0.233982 0.360308 0 0 0 0.00281905 l
+0.181269 -0.639778 0.17954 -0.62451 0 0 0 0.00281905 l
+0.181269 -0.639778 0.189133 -0.644477 0 0 0 0.00281905 l
+0.181269 -0.639778 0.170944 -0.638949 0 0 0 0.00281905 l
+0.725933 0.368377 0.737303 0.380624 0 0 0 0.00281905 l
+0.725933 0.368377 0.731991 0.363837 0 0 0 0.00281905 l
+0.725933 0.368377 0.714341 0.373613 0 0 0 0.00281905 l
+0.0114489 0.255154 0.00496532 0.274849 0 0 0 0.00281905 l
+0.0114489 0.255154 0.0260782 0.252738 0 0 0 0.00281905 l
+0.0114489 0.255154 0.0109269 0.251209 0 0 0 0.00281905 l
+0.244067 -0.481931 0.256226 -0.472325 0 0 0 0.00281905 l
+0.329007 -0.0358915 0.324221 -0.0250199 0 0 0 0.00281905 l
+0.329007 -0.0358915 0.316372 -0.0358121 0 0 0 0.00281905 l
+-0.55788 -0.218605 -0.55041 -0.218037 0 0 0 0.00281905 l
+-0.14142 -0.855694 -0.13531 -0.857802 0 0 0 0.00281905 l
+-0.14142 -0.855694 -0.149135 -0.85928 0 0 0 0.00281905 l
+0.137867 0.98501 0.142111 0.970473 0 0 0 0.00281905 l
+0.137867 0.98501 0.123875 0.989201 0 0 0 0.00281905 l
+0.665178 0.296022 0.672813 0.286904 0 0 0 0.00281905 l
+0.665178 0.296022 0.657916 0.29594 0 0 0 0.00281905 l
+0.957907 -0.202052 0.968601 -0.194581 0 0 0 0.00281905 l
+0.957907 -0.202052 0.950897 -0.201268 0 0 0 0.00281905 l
+0.01002 0.206782 0.0160789 0.198676 0 0 0 0.00281905 l
+0.01002 0.206782 0.00459305 0.219447 0 0 0 0.00281905 l
+0.01002 0.206782 0.0193076 0.214679 0 0 0 0.00281905 l
+-0.518106 -0.424839 -0.531858 -0.428544 0 0 0 0.00281905 l
+-0.896469 0.203037 -0.887455 0.192491 0 0 0 0.00281905 l
+-0.896469 0.203037 -0.89761 0.20235 0 0 0 0.00281905 l
+0.197163 -0.816542 0.207182 -0.801335 0 0 0 0.00281905 l
+0.197163 -0.816542 0.198448 -0.830531 0 0 0 0.00281905 l
+0.197163 -0.816542 0.186936 -0.813768 0 0 0 0.00281905 l
+-0.951986 -0.214041 -0.948558 -0.213544 0 0 0 0.00281905 l
+-0.756704 -0.152382 -0.755193 -0.158293 0 0 0 0.00281905 l
+0.496445 0.455707 0.500749 0.470675 0 0 0 0.00281905 l
+0.496445 0.455707 0.49427 0.45577 0 0 0 0.00281905 l
+0.670805 -0.2851 0.669991 -0.280551 0 0 0 0.00281905 l
+0.670805 -0.2851 0.663176 -0.289408 0 0 0 0.00281905 l
+-0.909054 -0.181294 -0.890614 -0.186672 0 0 0 0.00281905 l
+-0.909054 -0.181294 -0.919607 -0.188173 0 0 0 0.00281905 l
+0.317976 -0.132037 0.324336 -0.119121 0 0 0 0.00281905 l
+0.317976 -0.132037 0.304676 -0.135559 0 0 0 0.00281905 l
+-0.374461 0.153265 -0.372484 0.140811 0 0 0 0.00281905 l
+-0.374461 0.153265 -0.382679 0.166688 0 0 0 0.00281905 l
+-0.433085 0.201711 -0.430225 0.213961 0 0 0 0.00281905 l
+-0.433085 0.201711 -0.441757 0.204619 0 0 0 0.00281905 l
+-0.0495994 -0.0916137 -0.0437732 -0.105416 0 0 0 0.00281905 l
+-0.0495994 -0.0916137 -0.0482593 -0.088062 0 0 0 0.00281905 l
+0.882553 -0.125459 0.88454 -0.11695 0 0 0 0.00281905 l
+0.882553 -0.125459 0.88042 -0.138735 0 0 0 0.00281905 l
+0.882553 -0.125459 0.865205 -0.125953 0 0 0 0.00281905 l
+-0.518697 0.777387 -0.516198 0.779151 0 0 0 0.00281905 l
+-0.518697 0.777387 -0.538686 0.770699 0 0 0 0.00281905 l
+-0.128344 0.268412 -0.113357 0.270107 0 0 0 0.00281905 l
+-0.128344 0.268412 -0.128394 0.250055 0 0 0 0.00281905 l
+-0.128344 0.268412 -0.136598 0.273804 0 0 0 0.00281905 l
+-0.337482 -0.642391 -0.33452 -0.619478 0 0 0 0.00281905 l
+-0.337482 -0.642391 -0.344365 -0.645289 0 0 0 0.00281905 l
+-0.00993121 -0.773886 -0.0158779 -0.751366 0 0 0 0.00281905 l
+-0.00993121 -0.773886 -0.00413429 -0.777294 0 0 0 0.00281905 l
+-0.165485 0.443469 -0.157383 0.442484 0 0 0 0.00281905 l
+-0.165485 0.443469 -0.179933 0.452799 0 0 0 0.00281905 l
+0.782655 0.121474 0.793837 0.122679 0 0 0 0.00281905 l
+0.782655 0.121474 0.776208 0.11978 0 0 0 0.00281905 l
+-0.723254 -0.287022 -0.718877 -0.300972 0 0 0 0.00281905 l
+-0.723254 -0.287022 -0.7412 -0.291267 0 0 0 0.00281905 l
+0.473686 0.370448 0.476154 0.395363 0 0 0 0.00281905 l
+0.473686 0.370448 0.468742 0.363173 0 0 0 0.00281905 l
+-0.358903 0.205019 -0.347965 0.199637 0 0 0 0.00281905 l
+-0.358903 0.205019 -0.366742 0.199662 0 0 0 0.00281905 l
+-0.358903 0.205019 -0.362239 0.209805 0 0 0 0.00281905 l
+0.0992787 0.930574 0.102944 0.936192 0 0 0 0.00281905 l
+0.0992787 0.930574 0.0786691 0.930816 0 0 0 0.00281905 l
+-0.321632 -0.239038 -0.311762 -0.251364 0 0 0 0.00281905 l
+-0.321632 -0.239038 -0.316845 -0.233723 0 0 0 0.00281905 l
+-0.410559 0.830107 -0.397855 0.840111 0 0 0 0.00281905 l
+-0.410559 0.830107 -0.405846 0.817623 0 0 0 0.00281905 l
+-0.372161 -0.430604 -0.380513 -0.441779 0 0 0 0.00281905 l
+0.0757658 0.837646 0.0835817 0.834695 0 0 0 0.00281905 l
+0.0757658 0.837646 0.0728983 0.84125 0 0 0 0.00281905 l
+0.298892 -0.242969 0.304374 -0.242745 0 0 0 0.00281905 l
+0.298892 -0.242969 0.29342 -0.248933 0 0 0 0.00281905 l
+-0.496301 0.392848 -0.493163 0.413011 0 0 0 0.00281905 l
+-0.496301 0.392848 -0.489709 0.38149 0 0 0 0.00281905 l
+0.414221 0.726052 0.417409 0.731866 0 0 0 0.00281905 l
+0.414221 0.726052 0.416471 0.721495 0 0 0 0.00281905 l
+0.8987 -0.0726415 0.899006 -0.0819796 0 0 0 0.00281905 l
+0.8987 -0.0726415 0.899795 -0.0647737 0 0 0 0.00281905 l
+0.12617 -0.0426661 0.121565 -0.02562 0 0 0 0.00281905 l
+0.12617 -0.0426661 0.138132 -0.0428178 0 0 0 0.00281905 l
+0.352631 -0.454052 0.359862 -0.44813 0 0 0 0.00281905 l
+0.352631 -0.454052 0.334693 -0.454143 0 0 0 0.00281905 l
+-0.65101 0.0908986 -0.660292 0.0918183 0 0 0 0.00281905 l
+-0.935131 -0.282211 -0.940393 -0.288881 0 0 0 0.00281905 l
+0.56271 -0.710118 0.573535 -0.692124 0 0 0 0.00281905 l
+0.56271 -0.710118 0.560694 -0.726401 0 0 0 0.00281905 l
+0.56271 -0.710118 0.53529 -0.704376 0 0 0 0.00281905 l
+0.0794692 0.566218 0.0768841 0.551869 0 0 0 0.00281905 l
+-0.720855 -0.231609 -0.727426 -0.228087 0 0 0 0.00281905 l
+-0.538837 0.162791 -0.527181 0.176973 0 0 0 0.00281905 l
+-0.538837 0.162791 -0.528849 0.150669 0 0 0 0.00281905 l
+-0.538837 0.162791 -0.554519 0.162255 0 0 0 0.00281905 l
+-0.0459058 -0.958106 -0.0438041 -0.957622 0 0 0 0.00281905 l
+0.057367 0.489707 0.0588895 0.503464 0 0 0 0.00281905 l
+0.057367 0.489707 0.0660422 0.482599 0 0 0 0.00281905 l
+0.057367 0.489707 0.0489667 0.474009 0 0 0 0.00281905 l
+0.326493 -0.210343 0.332066 -0.213717 0 0 0 0.00281905 l
+-0.29672 0.612221 -0.297159 0.602232 0 0 0 0.00281905 l
+-0.29672 0.612221 -0.289573 0.621302 0 0 0 0.00281905 l
+-0.29672 0.612221 -0.309393 0.616341 0 0 0 0.00281905 l
+0.408213 0.676786 0.414944 0.671736 0 0 0 0.00281905 l
+0.408213 0.676786 0.39891 0.663963 0 0 0 0.00281905 l
+0.408213 0.676786 0.409591 0.679678 0 0 0 0.00281905 l
+0.55597 -0.469859 0.561787 -0.455474 0 0 0 0.00281905 l
+0.55597 -0.469859 0.569441 -0.476936 0 0 0 0.00281905 l
+0.156211 -0.475113 0.156412 -0.492967 0 0 0 0.00281905 l
+0.156211 -0.475113 0.155029 -0.474446 0 0 0 0.00281905 l
+-0.111519 0.642181 -0.104129 0.642005 0 0 0 0.00281905 l
+0.480446 -0.120821 0.495084 -0.129123 0 0 0 0.00281905 l
+0.480446 -0.120821 0.475469 -0.132497 0 0 0 0.00281905 l
+0.480446 -0.120821 0.485224 -0.112322 0 0 0 0.00281905 l
+-0.0421471 -0.393905 -0.0362982 -0.389045 0 0 0 0.00281905 l
+-0.0421471 -0.393905 -0.0591777 -0.377011 0 0 0 0.00281905 l
+0.0317402 -0.0563828 0.0336413 -0.0423153 0 0 0 0.00281905 l
+0.0317402 -0.0563828 0.0466489 -0.0704684 0 0 0 0.00281905 l
+0.518657 0.232429 0.520666 0.239799 0 0 0 0.00281905 l
+0.518657 0.232429 0.507029 0.228012 0 0 0 0.00281905 l
+0.49526 0.697279 0.493003 0.679399 0 0 0 0.00281905 l
+0.49526 0.697279 0.506304 0.702831 0 0 0 0.00281905 l
+0.647199 -0.577208 0.640641 -0.59143 0 0 0 0.00281905 l
+-0.310977 -0.0733723 -0.311092 -0.0578662 0 0 0 0.00281905 l
+-0.310977 -0.0733723 -0.300992 -0.0724428 0 0 0 0.00281905 l
+0.69659 0.0276552 0.712491 0.0240388 0 0 0 0.00281905 l
+0.69659 0.0276552 0.703022 0.0382721 0 0 0 0.00281905 l
+0.499928 -0.22264 0.486442 -0.207048 0 0 0 0.00281905 l
+0.499928 -0.22264 0.507831 -0.22673 0 0 0 0.00281905 l
+-0.906177 -0.285938 -0.895469 -0.300178 0 0 0 0.00281905 l
+0.919393 -0.129885 0.922466 -0.117191 0 0 0 0.00281905 l
+0.919393 -0.129885 0.931906 -0.132025 0 0 0 0.00281905 l
+0.919393 -0.129885 0.908405 -0.126191 0 0 0 0.00281905 l
+-0.0619107 -0.364736 -0.0653536 -0.353986 0 0 0 0.00281905 l
+-0.0619107 -0.364736 -0.0526697 -0.370319 0 0 0 0.00281905 l
+-0.319103 -0.266325 -0.316011 -0.278523 0 0 0 0.00281905 l
+-0.319103 -0.266325 -0.312223 -0.263176 0 0 0 0.00281905 l
+0.36978 0.104754 0.38274 0.118071 0 0 0 0.00281905 l
+0.36978 0.104754 0.367551 0.0950161 0 0 0 0.00281905 l
+0.36978 0.104754 0.347948 0.105194 0 0 0 0.00281905 l
+0.174868 0.222115 0.178398 0.229837 0 0 0 0.00281905 l
+0.588809 0.403292 0.592725 0.402111 0 0 0 0.00281905 l
+0.588809 0.403292 0.58716 0.398491 0 0 0 0.00281905 l
+0.588809 0.403292 0.582653 0.407763 0 0 0 0.00281905 l
+-0.609381 0.748063 -0.602797 0.738519 0 0 0 0.00281905 l
+0.387772 0.650882 0.399564 0.642568 0 0 0 0.00281905 l
+0.387772 0.650882 0.379374 0.646196 0 0 0 0.00281905 l
+-0.555016 -0.230787 -0.54619 -0.225688 0 0 0 0.00281905 l
+-0.555016 -0.230787 -0.548027 -0.240373 0 0 0 0.00281905 l
+-0.555016 -0.230787 -0.570609 -0.22955 0 0 0 0.00281905 l
+-0.15958 0.842394 -0.165026 0.83301 0 0 0 0.00281905 l
+-0.15958 0.842394 -0.159742 0.84315 0 0 0 0.00281905 l
+0.109771 -0.401121 0.114013 -0.397705 0 0 0 0.00281905 l
+0.109771 -0.401121 0.111447 -0.402976 0 0 0 0.00281905 l
+-0.260676 0.504567 -0.266237 0.515397 0 0 0 0.00281905 l
+-0.380513 -0.441779 -0.380921 -0.447 0 0 0 0.00281905 l
+-0.380513 -0.441779 -0.372161 -0.430604 0 0 0 0.00281905 l
+-0.380513 -0.441779 -0.397138 -0.433001 0 0 0 0.00281905 l
+-0.207457 -0.420021 -0.209248 -0.422391 0 0 0 0.00281905 l
+0.240705 0.0346761 0.241306 0.0512469 0 0 0 0.00281905 l
+0.240705 0.0346761 0.247246 0.0284738 0 0 0 0.00281905 l
+0.240705 0.0346761 0.235979 0.0300127 0 0 0 0.00281905 l
+-0.66926 0.27026 -0.674189 0.281518 0 0 0 0.00281905 l
+-0.66926 0.27026 -0.658915 0.254328 0 0 0 0.00281905 l
+-0.364941 0.0176626 -0.369777 0.0274005 0 0 0 0.00281905 l
+-0.364941 0.0176626 -0.359981 0.0187121 0 0 0 0.00281905 l
+0.487863 0.142843 0.489694 0.149198 0 0 0 0.00281905 l
+0.487863 0.142843 0.484474 0.135577 0 0 0 0.00281905 l
+0.978179 -0.0889295 0.979667 -0.0775116 0 0 0 0.00281905 l
+-0.887836 -0.196856 -0.889873 -0.20859 0 0 0 0.00281905 l
+-0.887836 -0.196856 -0.890614 -0.186672 0 0 0 0.00281905 l
+-0.699508 0.497745 -0.68901 0.504591 0 0 0 0.00281905 l
+-0.699508 0.497745 -0.694036 0.492748 0 0 0 0.00281905 l
+-0.165882 0.822806 -0.165026 0.83301 0 0 0 0.00281905 l
+-0.165882 0.822806 -0.167112 0.820289 0 0 0 0.00281905 l
+-0.468892 0.254386 -0.467809 0.265553 0 0 0 0.00281905 l
+-0.468892 0.254386 -0.473274 0.247653 0 0 0 0.00281905 l
+-0.850108 0.391883 -0.836998 0.385329 0 0 0 0.00281905 l
+-0.850108 0.391883 -0.8608 0.387165 0 0 0 0.00281905 l
+-0.512958 -0.49666 -0.523163 -0.48391 0 0 0 0.00281905 l
+-0.512958 -0.49666 -0.514934 -0.501016 0 0 0 0.00281905 l
+-0.37454 0.374179 -0.37329 0.383362 0 0 0 0.00281905 l
+-0.37454 0.374179 -0.367419 0.374032 0 0 0 0.00281905 l
+-0.37454 0.374179 -0.380504 0.368938 0 0 0 0.00281905 l
+-0.582217 -0.736283 -0.577599 -0.738863 0 0 0 0.00281905 l
+-0.582217 -0.736283 -0.577564 -0.727528 0 0 0 0.00281905 l
+-0.419592 0.542858 -0.41313 0.550104 0 0 0 0.00281905 l
+-0.419592 0.542858 -0.435547 0.54589 0 0 0 0.00281905 l
+-0.35577 -0.873098 -0.355631 -0.870232 0 0 0 0.00281905 l
+-0.35577 -0.873098 -0.35154 -0.886153 0 0 0 0.00281905 l
+0.57982 0.72583 0.587043 0.723975 0 0 0 0.00281905 l
+0.57982 0.72583 0.576784 0.707147 0 0 0 0.00281905 l
+-0.207612 -0.674514 -0.206515 -0.673358 0 0 0 0.00281905 l
+0.29728 0.764129 0.302087 0.75823 0 0 0 0.00281905 l
+0.29728 0.764129 0.29691 0.76423 0 0 0 0.00281905 l
+0.730075 0.607005 0.73072 0.611074 0 0 0 0.00281905 l
+0.730075 0.607005 0.739169 0.603542 0 0 0 0.00281905 l
+0.730075 0.607005 0.727936 0.602873 0 0 0 0.00281905 l
+-0.342582 0.102433 -0.337262 0.101963 0 0 0 0.00281905 l
+-0.342582 0.102433 -0.350873 0.103311 0 0 0 0.00281905 l
+0.593292 -0.0253304 0.593092 -0.0148311 0 0 0 0.00281905 l
+0.593292 -0.0253304 0.602303 -0.0232589 0 0 0 0.00281905 l
+0.0669338 -0.638431 0.0822732 -0.631216 0 0 0 0.00281905 l
+0.0669338 -0.638431 0.0565057 -0.642049 0 0 0 0.00281905 l
+0.437309 0.747712 0.454287 0.750669 0 0 0 0.00281905 l
+0.437309 0.747712 0.439836 0.740547 0 0 0 0.00281905 l
+-0.146837 0.795197 -0.133125 0.797976 0 0 0 0.00281905 l
+-0.146837 0.795197 -0.151423 0.799081 0 0 0 0.00281905 l
+0.176916 -0.170433 0.175316 -0.187113 0 0 0 0.00281905 l
+0.176916 -0.170433 0.188555 -0.165142 0 0 0 0.00281905 l
+0.176916 -0.170433 0.16983 -0.161432 0 0 0 0.00281905 l
+-0.785787 -0.244363 -0.779532 -0.24478 0 0 0 0.00281905 l
+-0.785787 -0.244363 -0.790133 -0.256539 0 0 0 0.00281905 l
+0.747157 0.646867 0.755031 0.642621 0 0 0 0.00281905 l
+0.747157 0.646867 0.735806 0.63952 0 0 0 0.00281905 l
+-0.336972 0.70248 -0.339962 0.692083 0 0 0 0.00281905 l
+-0.336972 0.70248 -0.323674 0.711424 0 0 0 0.00281905 l
+0.0522422 -0.891731 0.0480267 -0.883697 0 0 0 0.00281905 l
+0.0522422 -0.891731 0.0663631 -0.903446 0 0 0 0.00281905 l
+-0.251535 -0.488557 -0.24324 -0.480261 0 0 0 0.00281905 l
+-0.251535 -0.488557 -0.256792 -0.489948 0 0 0 0.00281905 l
+0.462986 -0.078583 0.475326 -0.0775939 0 0 0 0.00281905 l
+0.462986 -0.078583 0.463116 -0.0856317 0 0 0 0.00281905 l
+0.462986 -0.078583 0.447947 -0.0728956 0 0 0 0.00281905 l
+0.0769371 0.465112 0.0804063 0.466179 0 0 0 0.00281905 l
+0.865356 -0.117963 0.86206 -0.0998185 0 0 0 0.00281905 l
+0.865356 -0.117963 0.865915 -0.118293 0 0 0 0.00281905 l
+-0.23844 -0.173115 -0.236174 -0.16674 0 0 0 0.00281905 l
+-0.23844 -0.173115 -0.229432 -0.176083 0 0 0 0.00281905 l
+-0.23844 -0.173115 -0.24596 -0.174915 0 0 0 0.00281905 l
+0.110227 -0.171234 0.118378 -0.167354 0 0 0 0.00281905 l
+0.110227 -0.171234 0.095381 -0.173341 0 0 0 0.00281905 l
+0.107904 -0.797495 0.113495 -0.78913 0 0 0 0.00281905 l
+-0.783875 0.41188 -0.782144 0.424294 0 0 0 0.00281905 l
+-0.783875 0.41188 -0.776819 0.405374 0 0 0 0.00281905 l
+-0.783875 0.41188 -0.794909 0.400649 0 0 0 0.00281905 l
+-0.366863 0.839735 -0.368838 0.827375 0 0 0 0.00281905 l
+-0.366863 0.839735 -0.37384 0.846568 0 0 0 0.00281905 l
+-0.652156 -0.30233 -0.662136 -0.30796 0 0 0 0.00281905 l
+-0.652156 -0.30233 -0.645003 -0.304041 0 0 0 0.00281905 l
+-0.652156 -0.30233 -0.65278 -0.299836 0 0 0 0.00281905 l
+0.643208 0.47215 0.633748 0.481594 0 0 0 0.00281905 l
+0.661574 -0.557356 0.662617 -0.550955 0 0 0 0.00281905 l
+0.661574 -0.557356 0.668486 -0.556291 0 0 0 0.00281905 l
+0.140905 -0.696421 0.150654 -0.697445 0 0 0 0.00281905 l
+0.140905 -0.696421 0.139271 -0.711176 0 0 0 0.00281905 l
+0.544426 0.47173 0.546921 0.455187 0 0 0 0.00281905 l
+0.544426 0.47173 0.537669 0.485628 0 0 0 0.00281905 l
+0.566385 -0.288781 0.552371 -0.278153 0 0 0 0.00281905 l
+-0.65278 -0.299836 -0.641822 -0.287853 0 0 0 0.00281905 l
+-0.65278 -0.299836 -0.652156 -0.30233 0 0 0 0.00281905 l
+-0.456841 0.0530636 -0.443423 0.0367178 0 0 0 0.00281905 l
+-0.456841 0.0530636 -0.469134 0.0676284 0 0 0 0.00281905 l
+-0.306303 -0.334627 -0.308776 -0.324811 0 0 0 0.00281905 l
+-0.306303 -0.334627 -0.300281 -0.334504 0 0 0 0.00281905 l
+0.387085 -0.1394 0.39193 -0.152982 0 0 0 0.00281905 l
+0.387085 -0.1394 0.378038 -0.131091 0 0 0 0.00281905 l
+-0.725539 0.271048 -0.718187 0.285248 0 0 0 0.00281905 l
+-0.725539 0.271048 -0.707755 0.259011 0 0 0 0.00281905 l
+-0.725539 0.271048 -0.730535 0.274471 0 0 0 0.00281905 l
+-0.11775 -0.480488 -0.112586 -0.469311 0 0 0 0.00281905 l
+-0.11775 -0.480488 -0.124845 -0.483509 0 0 0 0.00281905 l
+0.173643 -0.34033 0.172476 -0.328893 0 0 0 0.00281905 l
+0.173643 -0.34033 0.182923 -0.342138 0 0 0 0.00281905 l
+0.173643 -0.34033 0.165821 -0.343266 0 0 0 0.00281905 l
+0.651528 0.121983 0.655366 0.115633 0 0 0 0.00281905 l
+-0.121182 -0.971737 -0.11671 -0.956021 0 0 0 0.00281905 l
+-0.121182 -0.971737 -0.129745 -0.974393 0 0 0 0.00281905 l
+0.164963 0.317763 0.1483 0.316145 0 0 0 0.00281905 l
+-0.531972 0.495561 -0.534083 0.484642 0 0 0 0.00281905 l
+-0.531972 0.495561 -0.535362 0.496492 0 0 0 0.00281905 l
+-0.222823 -0.891878 -0.215572 -0.88459 0 0 0 0.00281905 l
+-0.222823 -0.891878 -0.233742 -0.891145 0 0 0 0.00281905 l
+0.0804705 -0.933762 0.0867214 -0.927503 0 0 0 0.00281905 l
+0.0804705 -0.933762 0.0781011 -0.936035 0 0 0 0.00281905 l
+-0.596428 0.733788 -0.589766 0.715339 0 0 0 0.00281905 l
+-0.596428 0.733788 -0.602797 0.738519 0 0 0 0.00281905 l
+0.0174979 -0.503064 0.0235847 -0.506653 0 0 0 0.00281905 l
+0.0174979 -0.503064 0.00987967 -0.520014 0 0 0 0.00281905 l
+0.0174979 -0.503064 0.0077785 -0.487754 0 0 0 0.00281905 l
+-0.248465 0.569556 -0.246187 0.576756 0 0 0 0.00281905 l
+-0.248465 0.569556 -0.256351 0.56344 0 0 0 0.00281905 l
+-0.851468 0.173907 -0.859048 0.154908 0 0 0 0.00281905 l
+-0.768322 -0.304354 -0.769377 -0.320386 0 0 0 0.00281905 l
+-0.768322 -0.304354 -0.77334 -0.303416 0 0 0 0.00281905 l
+0.413889 0.257699 0.411891 0.273496 0 0 0 0.00281905 l
+0.413889 0.257699 0.42179 0.250787 0 0 0 0.00281905 l
+0.413889 0.257699 0.388113 0.251337 0 0 0 0.00281905 l
+-0.0953551 -0.991005 -0.0898105 -0.988213 0 0 0 0.00281905 l
+-0.0953551 -0.991005 -0.105854 -0.986752 0 0 0 0.00281905 l
+0.769588 0.266076 0.771345 0.28501 0 0 0 0.00281905 l
+0.769588 0.266076 0.767002 0.262985 0 0 0 0.00281905 l
+0.939122 -0.073207 0.938478 -0.0799388 0 0 0 0.00281905 l
+0.939122 -0.073207 0.93636 -0.0630087 0 0 0 0.00281905 l
+0.687008 -0.5805 0.697066 -0.56754 0 0 0 0.00281905 l
+0.687008 -0.5805 0.681319 -0.589522 0 0 0 0.00281905 l
+0.252156 0.48766 0.256363 0.497871 0 0 0 0.00281905 l
+0.252156 0.48766 0.250462 0.482529 0 0 0 0.00281905 l
+0.158099 0.157696 0.170156 0.155711 0 0 0 0.00281905 l
+0.158099 0.157696 0.152219 0.149709 0 0 0 0.00281905 l
+0.547155 -0.442173 0.556863 -0.433521 0 0 0 0.00281905 l
+0.547155 -0.442173 0.527861 -0.440745 0 0 0 0.00281905 l
+-0.709962 0.288404 -0.718187 0.285248 0 0 0 0.00281905 l
+0.740426 -0.621538 0.739199 -0.628432 0 0 0 0.00281905 l
+0.740426 -0.621538 0.749658 -0.598866 0 0 0 0.00281905 l
+0.740426 -0.621538 0.731909 -0.621841 0 0 0 0.00281905 l
+0.118551 0.203455 0.127032 0.209825 0 0 0 0.00281905 l
+0.118551 0.203455 0.123596 0.198058 0 0 0 0.00281905 l
+0.118551 0.203455 0.115363 0.211869 0 0 0 0.00281905 l
+0.747487 0.0868053 0.747824 0.0865688 0 0 0 0.00281905 l
+0.747487 0.0868053 0.740399 0.0813869 0 0 0 0.00281905 l
+-0.380806 0.747748 -0.373135 0.743583 0 0 0 0.00281905 l
+-0.380806 0.747748 -0.386243 0.750239 0 0 0 0.00281905 l
+-0.0485673 0.581213 -0.0414119 0.567753 0 0 0 0.00281905 l
+-0.0485673 0.581213 -0.0522235 0.585466 0 0 0 0.00281905 l
+0.661525 0.626703 0.66913 0.636835 0 0 0 0.00281905 l
+0.661525 0.626703 0.655195 0.622067 0 0 0 0.00281905 l
+-0.116191 -0.675018 -0.121641 -0.683611 0 0 0 0.00281905 l
+-0.116191 -0.675018 -0.117615 -0.664964 0 0 0 0.00281905 l
+-0.116191 -0.675018 -0.109815 -0.671747 0 0 0 0.00281905 l
+-0.380304 0.788404 -0.37574 0.775321 0 0 0 0.00281905 l
+-0.380304 0.788404 -0.391729 0.787748 0 0 0 0.00281905 l
+0.558828 0.616573 0.564068 0.612402 0 0 0 0.00281905 l
+0.558828 0.616573 0.558629 0.61645 0 0 0 0.00281905 l
+0.796804 -0.494622 0.799544 -0.490547 0 0 0 0.00281905 l
+0.0598513 0.185305 0.0590578 0.185736 0 0 0 0.00281905 l
+-0.425527 -0.153564 -0.416776 -0.156688 0 0 0 0.00281905 l
+-0.425527 -0.153564 -0.433728 -0.155211 0 0 0 0.00281905 l
+0.403989 0.0916956 0.408066 0.0937854 0 0 0 0.00281905 l
+0.32953 -0.883061 0.335273 -0.886784 0 0 0 0.00281905 l
+-0.387703 -0.194354 -0.387782 -0.197817 0 0 0 0.00281905 l
+-0.387703 -0.194354 -0.395043 -0.193564 0 0 0 0.00281905 l
+0.812091 -0.349678 0.819606 -0.33773 0 0 0 0.00281905 l
+0.812091 -0.349678 0.809356 -0.352088 0 0 0 0.00281905 l
+0.869555 -0.323532 0.868321 -0.31925 0 0 0 0.00281905 l
+0.869555 -0.323532 0.860603 -0.325271 0 0 0 0.00281905 l
+-0.856821 0.437404 -0.861588 0.45668 0 0 0 0.00281905 l
+-0.856821 0.437404 -0.856608 0.429681 0 0 0 0.00281905 l
+0.203748 -0.908961 0.206244 -0.922395 0 0 0 0.00281905 l
+0.203748 -0.908961 0.206273 -0.907022 0 0 0 0.00281905 l
+0.746468 -0.465922 0.752599 -0.460121 0 0 0 0.00281905 l
+0.746468 -0.465922 0.734915 -0.477128 0 0 0 0.00281905 l
+0.450681 -0.268341 0.461629 -0.272027 0 0 0 0.00281905 l
+0.450681 -0.268341 0.44212 -0.26106 0 0 0 0.00281905 l
+0.563188 0.232913 0.552258 0.225627 0 0 0 0.00281905 l
+-0.130469 -0.424963 -0.132943 -0.416401 0 0 0 0.00281905 l
+-0.00303749 0.668337 0.00320947 0.680519 0 0 0 0.00281905 l
+-0.692833 0.073828 -0.692327 0.0676913 0 0 0 0.00281905 l
+-0.692833 0.073828 -0.689688 0.0858672 0 0 0 0.00281905 l
+-0.692833 0.073828 -0.710602 0.0811489 0 0 0 0.00281905 l
+0.360117 -0.143042 0.357444 -0.149104 0 0 0 0.00281905 l
+0.360117 -0.143042 0.360847 -0.140489 0 0 0 0.00281905 l
+0.360117 -0.143042 0.362778 -0.143711 0 0 0 0.00281905 l
+0.48701 -0.514374 0.487641 -0.50238 0 0 0 0.00281905 l
+0.48701 -0.514374 0.487325 -0.519395 0 0 0 0.00281905 l
+0.881788 0.332473 0.884472 0.354285 0 0 0 0.00281905 l
+0.881788 0.332473 0.879312 0.313061 0 0 0 0.00281905 l
+0.476154 0.395363 0.473686 0.370448 0 0 0 0.00281905 l
+-0.390638 0.13884 -0.394787 0.149718 0 0 0 0.00281905 l
+-0.390638 0.13884 -0.37702 0.138379 0 0 0 0.00281905 l
+-0.390638 0.13884 -0.392769 0.124391 0 0 0 0.00281905 l
+-0.737176 0.161142 -0.738376 0.16698 0 0 0 0.00281905 l
+-0.138981 0.188299 -0.134562 0.188374 0 0 0 0.00281905 l
+0.412386 0.887802 0.411686 0.893445 0 0 0 0.00281905 l
+0.412386 0.887802 0.417339 0.890331 0 0 0 0.00281905 l
+0.412386 0.887802 0.401489 0.876218 0 0 0 0.00281905 l
+0.709864 0.364895 0.714341 0.373613 0 0 0 0.00281905 l
+0.709864 0.364895 0.698812 0.359616 0 0 0 0.00281905 l
+0.759108 -0.211572 0.756201 -0.231063 0 0 0 0.00281905 l
+0.784177 -0.353295 0.787593 -0.368328 0 0 0 0.00281905 l
+0.784177 -0.353295 0.792297 -0.34196 0 0 0 0.00281905 l
+0.784177 -0.353295 0.771202 -0.354058 0 0 0 0.00281905 l
+-0.364752 0.878425 -0.36281 0.877691 0 0 0 0.00281905 l
+-0.364752 0.878425 -0.372838 0.885996 0 0 0 0.00281905 l
+0.818154 0.26173 0.821239 0.245769 0 0 0 0.00281905 l
+0.818154 0.26173 0.830794 0.277003 0 0 0 0.00281905 l
+0.224066 0.772022 0.226524 0.762432 0 0 0 0.00281905 l
+-0.185387 -0.333471 -0.192783 -0.32799 0 0 0 0.00281905 l
+0.305346 -0.0992044 0.311589 -0.107062 0 0 0 0.00281905 l
+-0.675439 0.293342 -0.669259 0.285991 0 0 0 0.00281905 l
+-0.675439 0.293342 -0.682858 0.293927 0 0 0 0.00281905 l
+-0.675439 0.293342 -0.673744 0.295588 0 0 0 0.00281905 l
+0.400504 0.293362 0.415311 0.28007 0 0 0 0.00281905 l
+0.400504 0.293362 0.407131 0.3083 0 0 0 0.00281905 l
+-0.669969 0.41117 -0.672491 0.403605 0 0 0 0.00281905 l
+-0.669969 0.41117 -0.681971 0.415983 0 0 0 0.00281905 l
+-0.314897 0.705869 -0.315436 0.689429 0 0 0 0.00281905 l
+-0.314897 0.705869 -0.323674 0.711424 0 0 0 0.00281905 l
+0.201328 0.77483 0.209881 0.78857 0 0 0 0.00281905 l
+0.201328 0.77483 0.208282 0.764144 0 0 0 0.00281905 l
+0.201328 0.77483 0.188511 0.779259 0 0 0 0.00281905 l
+0.75155 0.038979 0.753373 0.0440827 0 0 0 0.00281905 l
+-0.870285 -0.244031 -0.860238 -0.23352 0 0 0 0.00281905 l
+-0.870285 -0.244031 -0.882339 -0.243127 0 0 0 0.00281905 l
+0.629432 0.399291 0.638441 0.403514 0 0 0 0.00281905 l
+0.629432 0.399291 0.627808 0.401031 0 0 0 0.00281905 l
+-0.555642 0.432886 -0.55385 0.440143 0 0 0 0.00281905 l
+-0.555642 0.432886 -0.550855 0.423235 0 0 0 0.00281905 l
+-0.555642 0.432886 -0.561719 0.432825 0 0 0 0.00281905 l
+-0.172322 -0.645625 -0.175458 -0.657824 0 0 0 0.00281905 l
+-0.836076 -0.44529 -0.838153 -0.465883 0 0 0 0.00281905 l
+-0.836076 -0.44529 -0.827483 -0.43727 0 0 0 0.00281905 l
+-0.577599 -0.738863 -0.582217 -0.736283 0 0 0 0.00281905 l
+-0.460144 0.798133 -0.449923 0.784659 0 0 0 0.00281905 l
+-0.460144 0.798133 -0.459171 0.800915 0 0 0 0.00281905 l
+0.931797 -0.282408 0.928868 -0.291137 0 0 0 0.00281905 l
+-0.673513 -0.320466 -0.672776 -0.311725 0 0 0 0.00281905 l
+-0.673513 -0.320466 -0.680496 -0.323855 0 0 0 0.00281905 l
+-0.659869 0.705292 -0.64946 0.70493 0 0 0 0.00281905 l
+-0.659869 0.705292 -0.662431 0.714714 0 0 0 0.00281905 l
+-0.000892871 -0.014212 0.0101976 0.00126571 0 0 0 0.00281905 l
+-0.000892871 -0.014212 0.00610386 -0.019118 0 0 0 0.00281905 l
+-0.000892871 -0.014212 -0.0165989 -0.00781046 0 0 0 0.00281905 l
+-0.646021 -0.0379407 -0.63799 -0.0589955 0 0 0 0.00281905 l
+-0.646021 -0.0379407 -0.632438 -0.0318521 0 0 0 0.00281905 l
+-0.296303 0.367325 -0.29563 0.387552 0 0 0 0.00281905 l
+-0.296303 0.367325 -0.303117 0.362094 0 0 0 0.00281905 l
+-0.554372 0.0216403 -0.552972 0.0312639 0 0 0 0.00281905 l
+-0.554372 0.0216403 -0.566634 0.014476 0 0 0 0.00281905 l
+0.531189 -0.68349 0.530834 -0.671606 0 0 0 0.00281905 l
+0.531189 -0.68349 0.517696 -0.6902 0 0 0 0.00281905 l
+0.100117 -0.42634 0.100056 -0.422701 0 0 0 0.00281905 l
+-0.681757 -0.28589 -0.668449 -0.29223 0 0 0 0.00281905 l
+-0.681757 -0.28589 -0.689062 -0.280872 0 0 0 0.00281905 l
+0.187211 0.344379 0.191791 0.34716 0 0 0 0.00281905 l
+0.187211 0.344379 0.182689 0.343951 0 0 0 0.00281905 l
+-0.0100742 0.498498 -0.0142458 0.5042 0 0 0 0.00281905 l
+-0.0100742 0.498498 -0.0100515 0.488499 0 0 0 0.00281905 l
+-0.0100742 0.498498 -0.0194127 0.495305 0 0 0 0.00281905 l
+-0.417557 -0.148388 -0.416776 -0.156688 0 0 0 0.00281905 l
+-0.417557 -0.148388 -0.415226 -0.143689 0 0 0 0.00281905 l
+-0.710602 0.0811489 -0.692833 0.073828 0 0 0 0.00281905 l
+-0.710602 0.0811489 -0.721289 0.0773936 0 0 0 0.00281905 l
+-0.223604 -0.741251 -0.217218 -0.728543 0 0 0 0.00281905 l
+-0.223604 -0.741251 -0.231297 -0.744985 0 0 0 0.00281905 l
+-0.451442 0.303744 -0.450532 0.30139 0 0 0 0.00281905 l
+-0.451442 0.303744 -0.455299 0.30308 0 0 0 0.00281905 l
+-0.388716 -0.552766 -0.380007 -0.554957 0 0 0 0.00281905 l
+-0.388716 -0.552766 -0.396734 -0.553012 0 0 0 0.00281905 l
+-0.0859777 0.363155 -0.077703 0.356281 0 0 0 0.00281905 l
+-0.0859777 0.363155 -0.0970616 0.367848 0 0 0 0.00281905 l
+-0.138697 -0.638894 -0.143035 -0.623373 0 0 0 0.00281905 l
+-0.138697 -0.638894 -0.128671 -0.643142 0 0 0 0.00281905 l
+-0.0889522 0.379026 -0.0853398 0.397337 0 0 0 0.00281905 l
+-0.0889522 0.379026 -0.0970616 0.367848 0 0 0 0.00281905 l
+0.73072 0.611074 0.730075 0.607005 0 0 0 0.00281905 l
+0.73072 0.611074 0.739164 0.615745 0 0 0 0.00281905 l
+0.73072 0.611074 0.726247 0.610468 0 0 0 0.00281905 l
+-0.808262 -0.199351 -0.797881 -0.206795 0 0 0 0.00281905 l
+-0.808262 -0.199351 -0.820564 -0.194413 0 0 0 0.00281905 l
+-0.0614377 0.121701 -0.0554581 0.123654 0 0 0 0.00281905 l
+-0.0614377 0.121701 -0.0672167 0.115005 0 0 0 0.00281905 l
+0.5205 -0.364902 0.512527 -0.365928 0 0 0 0.00281905 l
+0.109799 -0.12575 0.114419 -0.114658 0 0 0 0.00281905 l
+0.109799 -0.12575 0.0981672 -0.119211 0 0 0 0.00281905 l
+-0.214607 -0.417675 -0.209248 -0.422391 0 0 0 0.00281905 l
+-0.214607 -0.417675 -0.21015 -0.412246 0 0 0 0.00281905 l
+-0.214607 -0.417675 -0.226244 -0.410431 0 0 0 0.00281905 l
+-0.210432 0.160644 -0.200992 0.16251 0 0 0 0.00281905 l
+-0.210432 0.160644 -0.211865 0.147343 0 0 0 0.00281905 l
+-0.552574 0.664521 -0.550582 0.651462 0 0 0 0.00281905 l
+-0.552574 0.664521 -0.551997 0.66562 0 0 0 0.00281905 l
+-0.552574 0.664521 -0.566473 0.664268 0 0 0 0.00281905 l
+-0.0522235 0.585466 -0.0478067 0.599529 0 0 0 0.00281905 l
+-0.0522235 0.585466 -0.0485673 0.581213 0 0 0 0.00281905 l
+-0.0522235 0.585466 -0.0596628 0.578087 0 0 0 0.00281905 l
+-0.200123 -0.358181 -0.2007 -0.366449 0 0 0 0.00281905 l
+-0.489538 0.433212 -0.478655 0.419513 0 0 0 0.00281905 l
+-0.489538 0.433212 -0.475811 0.444583 0 0 0 0.00281905 l
+0.260315 0.51037 0.259507 0.502527 0 0 0 0.00281905 l
+0.812214 -0.313528 0.821324 -0.32456 0 0 0 0.00281905 l
+0.812214 -0.313528 0.815291 -0.307738 0 0 0 0.00281905 l
+-0.480967 -0.0807854 -0.47115 -0.102792 0 0 0 0.00281905 l
+-0.480967 -0.0807854 -0.478931 -0.0751444 0 0 0 0.00281905 l
+-0.480967 -0.0807854 -0.49381 -0.0940095 0 0 0 0.00281905 l
+0.693253 0.277258 0.690502 0.294355 0 0 0 0.00281905 l
+-0.391931 0.0930126 -0.38382 0.0844554 0 0 0 0.00281905 l
+-0.391931 0.0930126 -0.39409 0.102093 0 0 0 0.00281905 l
+-0.391931 0.0930126 -0.38448 0.0977041 0 0 0 0.00281905 l
+-0.391931 0.0930126 -0.395484 0.0887438 0 0 0 0.00281905 l
+0.0466489 -0.0704684 0.0317402 -0.0563828 0 0 0 0.00281905 l
+0.0466489 -0.0704684 0.0603862 -0.0743883 0 0 0 0.00281905 l
+0.0466489 -0.0704684 0.0343803 -0.0842026 0 0 0 0.00281905 l
+0.34072 -0.116199 0.339508 -0.126727 0 0 0 0.00281905 l
+0.34072 -0.116199 0.324336 -0.119121 0 0 0 0.00281905 l
+-0.172089 0.15437 -0.172039 0.149231 0 0 0 0.00281905 l
+-0.172089 0.15437 -0.185634 0.158499 0 0 0 0.00281905 l
+-0.335032 -0.337 -0.336308 -0.32636 0 0 0 0.00281905 l
+-0.335032 -0.337 -0.340089 -0.35063 0 0 0 0.00281905 l
+0.0674823 -0.00762229 0.0809231 -0.0138637 0 0 0 0.00281905 l
+0.0674823 -0.00762229 0.0530301 0.00491423 0 0 0 0.00281905 l
+0.281665 0.322103 0.27974 0.327403 0 0 0 0.00281905 l
+0.281665 0.322103 0.291771 0.320509 0 0 0 0.00281905 l
+0.281665 0.322103 0.273033 0.317818 0 0 0 0.00281905 l
+0.290608 -0.248222 0.29342 -0.248933 0 0 0 0.00281905 l
+0.290608 -0.248222 0.275491 -0.249488 0 0 0 0.00281905 l
+0.87134 0.484348 0.866705 0.496424 0 0 0 0.00281905 l
+0.87134 0.484348 0.866411 0.479533 0 0 0 0.00281905 l
+-0.922577 0.193622 -0.89761 0.20235 0 0 0 0.00281905 l
+-0.922577 0.193622 -0.925337 0.202212 0 0 0 0.00281905 l
+-0.922577 0.193622 -0.932398 0.186754 0 0 0 0.00281905 l
+-0.419727 -0.264939 -0.420201 -0.279309 0 0 0 0.00281905 l
+-0.419727 -0.264939 -0.416061 -0.257141 0 0 0 0.00281905 l
+0.68259 0.0768876 0.694669 0.0801293 0 0 0 0.00281905 l
+0.68259 0.0768876 0.669215 0.0807122 0 0 0 0.00281905 l
+-0.478655 0.419513 -0.474916 0.410385 0 0 0 0.00281905 l
+-0.478655 0.419513 -0.489538 0.433212 0 0 0 0.00281905 l
+-0.478655 0.419513 -0.493163 0.413011 0 0 0 0.00281905 l
+-0.0659766 -0.0201552 -0.0660427 -0.0381245 0 0 0 0.00281905 l
+-0.0659766 -0.0201552 -0.0828964 -0.0128834 0 0 0 0.00281905 l
+-0.22947 0.160401 -0.233103 0.174737 0 0 0 0.00281905 l
+-0.22947 0.160401 -0.239258 0.161149 0 0 0 0.00281905 l
+0.661199 -0.526288 0.669319 -0.516625 0 0 0 0.00281905 l
+0.661199 -0.526288 0.649469 -0.532547 0 0 0 0.00281905 l
+-0.496174 -0.378905 -0.500613 -0.360754 0 0 0 0.00281905 l
+-0.496174 -0.378905 -0.483323 -0.381633 0 0 0 0.00281905 l
+-0.496174 -0.378905 -0.495389 -0.395826 0 0 0 0.00281905 l
+0.358437 0.354667 0.353408 0.370553 0 0 0 0.00281905 l
+0.358437 0.354667 0.353544 0.346141 0 0 0 0.00281905 l
+0.492813 0.714618 0.498865 0.729762 0 0 0 0.00281905 l
+0.492813 0.714618 0.506699 0.704993 0 0 0 0.00281905 l
+-0.792629 0.000729275 -0.790316 -0.00037791 0 0 0 0.00281905 l
+-0.792629 0.000729275 -0.813494 0.00301869 0 0 0 0.00281905 l
+0.803505 -0.0245896 0.805744 -0.0258535 0 0 0 0.00281905 l
+0.803505 -0.0245896 0.787786 -0.0186319 0 0 0 0.00281905 l
+0.324221 -0.0250199 0.33481 -0.0204293 0 0 0 0.00281905 l
+0.324221 -0.0250199 0.329007 -0.0358915 0 0 0 0.00281905 l
+-0.512845 -0.00286025 -0.515578 -0.0129698 0 0 0 0.00281905 l
+-0.512845 -0.00286025 -0.499978 0.00206755 0 0 0 0.00281905 l
+-0.512845 -0.00286025 -0.515388 -0.00173529 0 0 0 0.00281905 l
+0.469099 -0.378971 0.462381 -0.388774 0 0 0 0.00281905 l
+-0.239697 -0.117029 -0.227939 -0.12033 0 0 0 0.00281905 l
+-0.239697 -0.117029 -0.248304 -0.126027 0 0 0 0.00281905 l
+-0.239697 -0.117029 -0.244587 -0.109925 0 0 0 0.00281905 l
+-0.425568 -0.540517 -0.422659 -0.538825 0 0 0 0.00281905 l
+0.10203 -0.630979 0.0981172 -0.61339 0 0 0 0.00281905 l
+0.10203 -0.630979 0.101717 -0.636056 0 0 0 0.00281905 l
+-0.0762153 -0.619688 -0.0704537 -0.606966 0 0 0 0.00281905 l
+-0.269505 -0.813911 -0.268315 -0.823231 0 0 0 0.00281905 l
+-0.269505 -0.813911 -0.258168 -0.807946 0 0 0 0.00281905 l
+-0.269505 -0.813911 -0.286652 -0.813124 0 0 0 0.00281905 l
+-0.54652 0.506373 -0.535362 0.496492 0 0 0 0.00281905 l
+-0.54652 0.506373 -0.544548 0.510971 0 0 0 0.00281905 l
+-0.54652 0.506373 -0.550561 0.501987 0 0 0 0.00281905 l
+0.805232 0.474603 0.800641 0.49229 0 0 0 0.00281905 l
+0.805232 0.474603 0.823574 0.464183 0 0 0 0.00281905 l
+0.805232 0.474603 0.79524 0.470555 0 0 0 0.00281905 l
+0.50193 0.232878 0.507029 0.228012 0 0 0 0.00281905 l
+0.50193 0.232878 0.493614 0.231338 0 0 0 0.00281905 l
+-0.2181 -0.0750379 -0.221011 -0.0920298 0 0 0 0.00281905 l
+-0.2181 -0.0750379 -0.226322 -0.0699826 0 0 0 0.00281905 l
+0.157477 0.277165 0.14625 0.283896 0 0 0 0.00281905 l
+0.157477 0.277165 0.158782 0.27985 0 0 0 0.00281905 l
+0.589069 -0.785539 0.599659 -0.776516 0 0 0 0.00281905 l
+0.589069 -0.785539 0.593781 -0.791036 0 0 0 0.00281905 l
+0.589069 -0.785539 0.569329 -0.776701 0 0 0 0.00281905 l
+-0.0781541 0.536559 -0.097076 0.536034 0 0 0 0.00281905 l
+-0.0781541 0.536559 -0.0760159 0.540889 0 0 0 0.00281905 l
+-0.681668 0.0819501 -0.675417 0.089733 0 0 0 0.00281905 l
+-0.681668 0.0819501 -0.689688 0.0858672 0 0 0 0.00281905 l
+-0.397071 0.879742 -0.377541 0.887044 0 0 0 0.00281905 l
+-0.397071 0.879742 -0.410713 0.890251 0 0 0 0.00281905 l
+-0.397071 0.879742 -0.408127 0.871623 0 0 0 0.00281905 l
+0.517696 -0.6902 0.523183 -0.701531 0 0 0 0.00281905 l
+0.517696 -0.6902 0.531189 -0.68349 0 0 0 0.00281905 l
+0.826091 0.233118 0.821239 0.245769 0 0 0 0.00281905 l
+0.826091 0.233118 0.82949 0.231415 0 0 0 0.00281905 l
+-0.690615 0.487211 -0.692994 0.475083 0 0 0 0.00281905 l
+-0.690615 0.487211 -0.694036 0.492748 0 0 0 0.00281905 l
+-0.933165 -0.178705 -0.927781 -0.172659 0 0 0 0.00281905 l
+-0.933165 -0.178705 -0.944427 -0.183279 0 0 0 0.00281905 l
+-0.729001 -0.395676 -0.729835 -0.384569 0 0 0 0.00281905 l
+-0.729001 -0.395676 -0.722474 -0.400092 0 0 0 0.00281905 l
+0.0272587 -0.854068 0.0450904 -0.852311 0 0 0 0.00281905 l
+0.0272587 -0.854068 0.0132054 -0.855591 0 0 0 0.00281905 l
+-0.304498 -0.9172 -0.302516 -0.905614 0 0 0 0.00281905 l
+-0.69285 -0.652463 -0.686955 -0.66353 0 0 0 0.00281905 l
+-0.69285 -0.652463 -0.696755 -0.646714 0 0 0 0.00281905 l
+0.311589 -0.107062 0.324336 -0.119121 0 0 0 0.00281905 l
+0.311589 -0.107062 0.295544 -0.116926 0 0 0 0.00281905 l
+0.311589 -0.107062 0.305346 -0.0992044 0 0 0 0.00281905 l
+0.521769 0.849185 0.532655 0.825652 0 0 0 0.00281905 l
+-0.916373 -0.087605 -0.913475 -0.0886517 0 0 0 0.00281905 l
+-0.916373 -0.087605 -0.930461 -0.0786856 0 0 0 0.00281905 l
+-0.0964766 0.769996 -0.0961382 0.780995 0 0 0 0.00281905 l
+0.245718 -0.612089 0.238127 -0.604508 0 0 0 0.00281905 l
+0.245718 -0.612089 0.25921 -0.615296 0 0 0 0.00281905 l
+0.245718 -0.612089 0.240344 -0.616847 0 0 0 0.00281905 l
+0.542691 -0.053891 0.546186 -0.0681896 0 0 0 0.00281905 l
+0.542691 -0.053891 0.554193 -0.0519775 0 0 0 0.00281905 l
+0.351313 0.220088 0.364509 0.210525 0 0 0 0.00281905 l
+0.351313 0.220088 0.339295 0.231306 0 0 0 0.00281905 l
+-0.0898105 -0.988213 -0.0749651 -0.982172 0 0 0 0.00281905 l
+-0.0898105 -0.988213 -0.0915277 -0.97972 0 0 0 0.00281905 l
+-0.0898105 -0.988213 -0.0953551 -0.991005 0 0 0 0.00281905 l
+0.0815989 0.698005 0.0865911 0.701048 0 0 0 0.00281905 l
+-0.369552 0.125253 -0.367697 0.13038 0 0 0 0.00281905 l
+-0.264443 0.583477 -0.256243 0.601545 0 0 0 0.00281905 l
+-0.264443 0.583477 -0.263293 0.581746 0 0 0 0.00281905 l
+-0.649996 0.684267 -0.64946 0.70493 0 0 0 0.00281905 l
+-0.649996 0.684267 -0.622956 0.691068 0 0 0 0.00281905 l
+-0.649996 0.684267 -0.656626 0.678816 0 0 0 0.00281905 l
+0.552856 -0.326254 0.548106 -0.328914 0 0 0 0.00281905 l
+0.282011 -0.811365 0.281697 -0.815306 0 0 0 0.00281905 l
+0.282011 -0.811365 0.285307 -0.807843 0 0 0 0.00281905 l
+0.282011 -0.811365 0.273 -0.806206 0 0 0 0.00281905 l
+0.183955 0.610026 0.190532 0.603587 0 0 0 0.00281905 l
+0.183955 0.610026 0.173683 0.598534 0 0 0 0.00281905 l
+0.183955 0.610026 0.172874 0.620734 0 0 0 0.00281905 l
+-0.586125 0.284563 -0.581128 0.284022 0 0 0 0.00281905 l
+-0.586125 0.284563 -0.590665 0.276922 0 0 0 0.00281905 l
+-0.586125 0.284563 -0.592858 0.292285 0 0 0 0.00281905 l
+0.514049 0.641165 0.512034 0.652995 0 0 0 0.00281905 l
+0.514049 0.641165 0.524114 0.638491 0 0 0 0.00281905 l
+0.178708 0.78354 0.188511 0.779259 0 0 0 0.00281905 l
+0.178708 0.78354 0.173064 0.770195 0 0 0 0.00281905 l
+0.178708 0.78354 0.164503 0.790452 0 0 0 0.00281905 l
+-0.304795 0.602119 -0.304261 0.581993 0 0 0 0.00281905 l
+-0.304795 0.602119 -0.297159 0.602232 0 0 0 0.00281905 l
+0.660968 -0.00533011 0.673576 -0.0102288 0 0 0 0.00281905 l
+-0.0226209 -0.563191 -0.0223632 -0.577535 0 0 0 0.00281905 l
+-0.0226209 -0.563191 -0.0195168 -0.562029 0 0 0 0.00281905 l
+0.599021 -0.341164 0.601775 -0.324231 0 0 0 0.00281905 l
+0.599021 -0.341164 0.596603 -0.345163 0 0 0 0.00281905 l
+-0.378745 -0.142461 -0.378806 -0.137068 0 0 0 0.00281905 l
+-0.378745 -0.142461 -0.38004 -0.142378 0 0 0 0.00281905 l
+-0.22228 0.00478532 -0.215549 -0.00875762 0 0 0 0.00281905 l
+-0.22228 0.00478532 -0.225822 0.00773785 0 0 0 0.00281905 l
+-0.774885 0.491976 -0.771213 0.490798 0 0 0 0.00281905 l
+-0.774885 0.491976 -0.786227 0.488405 0 0 0 0.00281905 l
+-0.410236 0.597317 -0.402346 0.595882 0 0 0 0.00281905 l
+-0.410236 0.597317 -0.411772 0.587496 0 0 0 0.00281905 l
+0.941938 -0.331138 0.930528 -0.352185 0 0 0 0.00281905 l
+0.941938 -0.331138 0.941254 -0.324092 0 0 0 0.00281905 l
+0.406362 -0.911624 0.415424 -0.89981 0 0 0 0.00281905 l
+0.406362 -0.911624 0.393096 -0.911752 0 0 0 0.00281905 l
+-0.320944 0.0404954 -0.314762 0.0296076 0 0 0 0.00281905 l
+-0.320944 0.0404954 -0.327894 0.0450649 0 0 0 0.00281905 l
+-0.320944 0.0404954 -0.318625 0.0423322 0 0 0 0.00281905 l
+-0.107992 0.481642 -0.102301 0.482668 0 0 0 0.00281905 l
+-0.0511121 0.745043 -0.0421232 0.735412 0 0 0 0.00281905 l
+-0.0511121 0.745043 -0.0611782 0.746094 0 0 0 0.00281905 l
+0.134575 -0.396414 0.132668 -0.406724 0 0 0 0.00281905 l
+0.330056 0.867083 0.322922 0.881884 0 0 0 0.00281905 l
+0.330056 0.867083 0.341819 0.872936 0 0 0 0.00281905 l
+0.330056 0.867083 0.312997 0.85912 0 0 0 0.00281905 l
+0.07953 0.777347 0.0811614 0.783952 0 0 0 0.00281905 l
+0.07953 0.777347 0.0845045 0.775598 0 0 0 0.00281905 l
+0.07953 0.777347 0.0726546 0.767055 0 0 0 0.00281905 l
+-0.683268 -0.214773 -0.679716 -0.211342 0 0 0 0.00281905 l
+-0.683268 -0.214773 -0.681808 -0.21889 0 0 0 0.00281905 l
+-0.683268 -0.214773 -0.686453 -0.210814 0 0 0 0.00281905 l
+-0.609004 -0.463303 -0.597864 -0.449041 0 0 0 0.00281905 l
+-0.609004 -0.463303 -0.60994 -0.467014 0 0 0 0.00281905 l
+0.486502 -0.0492582 0.485347 -0.0579699 0 0 0 0.00281905 l
+0.10719 0.930574 0.102944 0.936192 0 0 0 0.00281905 l
+0.84792 0.0914489 0.848908 0.107126 0 0 0 0.00281905 l
+0.84792 0.0914489 0.843985 0.0829162 0 0 0 0.00281905 l
+-0.134062 -0.242775 -0.129876 -0.237316 0 0 0 0.00281905 l
+-0.134062 -0.242775 -0.132623 -0.247644 0 0 0 0.00281905 l
+-0.221092 0.525353 -0.214992 0.520323 0 0 0 0.00281905 l
+-0.000454341 0.217395 -0.0161561 0.213599 0 0 0 0.00281905 l
+-0.000454341 0.217395 0.00459305 0.219447 0 0 0 0.00281905 l
+-0.0341029 0.0211779 -0.0213929 0.0238491 0 0 0 0.00281905 l
+-0.0341029 0.0211779 -0.0412447 0.026252 0 0 0 0.00281905 l
+-0.242914 -0.678739 -0.237224 -0.663572 0 0 0 0.00281905 l
+-0.242914 -0.678739 -0.234757 -0.684903 0 0 0 0.00281905 l
+-0.242914 -0.678739 -0.249368 -0.685586 0 0 0 0.00281905 l
+0.83546 -0.101297 0.821864 -0.105424 0 0 0 0.00281905 l
+0.316674 0.776034 0.31639 0.787669 0 0 0 0.00281905 l
+0.316674 0.776034 0.331819 0.773096 0 0 0 0.00281905 l
+0.316674 0.776034 0.307862 0.770267 0 0 0 0.00281905 l
+0.428405 0.53851 0.426317 0.537675 0 0 0 0.00281905 l
+-0.889152 0.0764076 -0.887888 0.0810518 0 0 0 0.00281905 l
+0.512679 0.821944 0.506839 0.811955 0 0 0 0.00281905 l
+0.512679 0.821944 0.532655 0.825652 0 0 0 0.00281905 l
+-0.310009 -0.796644 -0.318288 -0.798664 0 0 0 0.00281905 l
+-0.0839072 -0.491322 -0.0964474 -0.478425 0 0 0 0.00281905 l
+-0.0839072 -0.491322 -0.0920071 -0.498506 0 0 0 0.00281905 l
+0.741704 -0.272312 0.732757 -0.27178 0 0 0 0.00281905 l
+0.741704 -0.272312 0.749324 -0.2716 0 0 0 0.00281905 l
+-0.170797 0.565572 -0.170295 0.582996 0 0 0 0.00281905 l
+-0.170797 0.565572 -0.15911 0.56188 0 0 0 0.00281905 l
+-0.170797 0.565572 -0.181564 0.553376 0 0 0 0.00281905 l
+-0.629707 0.293885 -0.627689 0.292287 0 0 0 0.00281905 l
+-0.86542 0.237303 -0.871007 0.233637 0 0 0 0.00281905 l
+0.941254 -0.324092 0.941938 -0.331138 0 0 0 0.00281905 l
+0.941254 -0.324092 0.927389 -0.319183 0 0 0 0.00281905 l
+-0.196887 0.116031 -0.207412 0.122926 0 0 0 0.00281905 l
+0.202217 0.0720466 0.219042 0.0766828 0 0 0 0.00281905 l
+0.202217 0.0720466 0.185205 0.0861395 0 0 0 0.00281905 l
+-0.804077 -0.281375 -0.804495 -0.296672 0 0 0 0.00281905 l
+-0.804077 -0.281375 -0.794669 -0.280692 0 0 0 0.00281905 l
+-0.804077 -0.281375 -0.809437 -0.271793 0 0 0 0.00281905 l
+0.221328 -0.314392 0.234133 -0.320769 0 0 0 0.00281905 l
+0.221328 -0.314392 0.226722 -0.308196 0 0 0 0.00281905 l
+-0.881631 0.303183 -0.878127 0.292665 0 0 0 0.00281905 l
+-0.881631 0.303183 -0.882045 0.311342 0 0 0 0.00281905 l
+-0.881631 0.303183 -0.873853 0.30412 0 0 0 0.00281905 l
+0.20339 -0.0657824 0.211181 -0.0737283 0 0 0 0.00281905 l
+0.20339 -0.0657824 0.21095 -0.0577675 0 0 0 0.00281905 l
+0.547597 -0.246631 0.544738 -0.262364 0 0 0 0.00281905 l
+0.547597 -0.246631 0.537528 -0.244047 0 0 0 0.00281905 l
+-0.104874 0.417639 -0.103695 0.411657 0 0 0 0.00281905 l
+-0.104874 0.417639 -0.0890332 0.432214 0 0 0 0.00281905 l
+0.703625 -0.455725 0.704265 -0.449806 0 0 0 0.00281905 l
+0.703625 -0.455725 0.698871 -0.457361 0 0 0 0.00281905 l
+0.0996131 -0.18204 0.100458 -0.182645 0 0 0 0.00281905 l
+0.0996131 -0.18204 0.09684 -0.179297 0 0 0 0.00281905 l
+-0.363737 -0.770325 -0.36452 -0.757353 0 0 0 0.00281905 l
+-0.363737 -0.770325 -0.355678 -0.786606 0 0 0 0.00281905 l
+-0.0213929 0.0238491 -0.020388 0.0119641 0 0 0 0.00281905 l
+-0.0213929 0.0238491 -0.0341029 0.0211779 0 0 0 0.00281905 l
+-0.744458 0.0251737 -0.731263 0.0147989 0 0 0 0.00281905 l
+-0.744458 0.0251737 -0.751853 0.012317 0 0 0 0.00281905 l
+-0.744458 0.0251737 -0.73227 0.032923 0 0 0 0.00281905 l
+-0.744458 0.0251737 -0.753707 0.0335004 0 0 0 0.00281905 l
+-0.667736 0.1809 -0.662069 0.182657 0 0 0 0.00281905 l
+-0.667736 0.1809 -0.663797 0.165933 0 0 0 0.00281905 l
+0.205493 -0.469187 0.208334 -0.468334 0 0 0 0.00281905 l
+0.634094 -0.031309 0.626666 -0.0435007 0 0 0 0.00281905 l
+0.634094 -0.031309 0.626875 -0.0276707 0 0 0 0.00281905 l
+-0.710684 -0.461057 -0.712821 -0.473273 0 0 0 0.00281905 l
+-0.710684 -0.461057 -0.72206 -0.455203 0 0 0 0.00281905 l
+-0.400099 -0.492662 -0.393636 -0.492652 0 0 0 0.00281905 l
+-0.400099 -0.492662 -0.41976 -0.485287 0 0 0 0.00281905 l
+-0.330332 0.662231 -0.343115 0.656944 0 0 0 0.00281905 l
+-0.59591 0.620012 -0.583614 0.630635 0 0 0 0.00281905 l
+0.0277569 0.602656 0.0300137 0.593982 0 0 0 0.00281905 l
+0.266514 -0.419193 0.272432 -0.434303 0 0 0 0.00281905 l
+0.266514 -0.419193 0.267335 -0.409868 0 0 0 0.00281905 l
+0.266514 -0.419193 0.253252 -0.420961 0 0 0 0.00281905 l
+0.826242 -0.454828 0.828789 -0.470456 0 0 0 0.00281905 l
+0.826242 -0.454828 0.840286 -0.447401 0 0 0 0.00281905 l
+0.826242 -0.454828 0.811891 -0.447673 0 0 0 0.00281905 l
+0.518254 -0.112899 0.511709 -0.125709 0 0 0 0.00281905 l
+0.120418 0.01615 0.121551 0.00496176 0 0 0 0.00281905 l
+0.120418 0.01615 0.131622 0.019342 0 0 0 0.00281905 l
+0.120418 0.01615 0.117014 0.0166601 0 0 0 0.00281905 l
+0.314845 -0.635999 0.326777 -0.625929 0 0 0 0.00281905 l
+0.314845 -0.635999 0.316132 -0.638902 0 0 0 0.00281905 l
+-0.697507 -0.126742 -0.6823 -0.136453 0 0 0 0.00281905 l
+-0.697507 -0.126742 -0.713576 -0.125926 0 0 0 0.00281905 l
+0.336109 -0.479036 0.340887 -0.487122 0 0 0 0.00281905 l
+0.336109 -0.479036 0.333915 -0.457303 0 0 0 0.00281905 l
+0.336109 -0.479036 0.332764 -0.480226 0 0 0 0.00281905 l
+0.864082 0.306563 0.864004 0.285944 0 0 0 0.00281905 l
+0.864082 0.306563 0.869232 0.317212 0 0 0 0.00281905 l
+0.864082 0.306563 0.854839 0.310959 0 0 0 0.00281905 l
+0.77692 -0.0577995 0.783857 -0.0684448 0 0 0 0.00281905 l
+0.77692 -0.0577995 0.767676 -0.0484075 0 0 0 0.00281905 l
+0.560634 -0.807125 0.560643 -0.797171 0 0 0 0.00281905 l
+0.560634 -0.807125 0.571265 -0.817467 0 0 0 0.00281905 l
+0.0344408 0.990338 0.0542529 0.998141 0 0 0 0.00281905 l
+0.0344408 0.990338 0.0104353 0.98587 0 0 0 0.00281905 l
+0.0109142 0.390083 0.00353118 0.370945 0 0 0 0.00281905 l
+0.0109142 0.390083 0.007158 0.405619 0 0 0 0.00281905 l
+0.0109142 0.390083 0.0170601 0.38963 0 0 0 0.00281905 l
+0.526648 -0.437091 0.527861 -0.440745 0 0 0 0.00281905 l
+0.526648 -0.437091 0.517781 -0.433832 0 0 0 0.00281905 l
+-0.0967306 0.944414 -0.0964042 0.943083 0 0 0 0.00281905 l
+-0.0967306 0.944414 -0.107824 0.948275 0 0 0 0.00281905 l
+-0.202238 -0.63654 -0.208573 -0.647957 0 0 0 0.00281905 l
+-0.202238 -0.63654 -0.193575 -0.627186 0 0 0 0.00281905 l
+0.811676 0.0858651 0.800094 0.101442 0 0 0 0.00281905 l
+0.811676 0.0858651 0.798278 0.0781186 0 0 0 0.00281905 l
+0.865205 -0.125953 0.865915 -0.118293 0 0 0 0.00281905 l
+0.865205 -0.125953 0.882553 -0.125459 0 0 0 0.00281905 l
+0.865205 -0.125953 0.861131 -0.134606 0 0 0 0.00281905 l
+0.456982 -0.169034 0.454717 -0.158842 0 0 0 0.00281905 l
+0.11971 -0.70118 0.121901 -0.690156 0 0 0 0.00281905 l
+0.11971 -0.70118 0.122985 -0.703958 0 0 0 0.00281905 l
+0.704437 0.534094 0.716267 0.549514 0 0 0 0.00281905 l
+0.704437 0.534094 0.694848 0.535382 0 0 0 0.00281905 l
+0.498865 0.729762 0.492813 0.714618 0 0 0 0.00281905 l
+0.498865 0.729762 0.500853 0.735994 0 0 0 0.00281905 l
+0.068112 -0.121265 0.0755072 -0.133152 0 0 0 0.00281905 l
+0.068112 -0.121265 0.0649928 -0.107606 0 0 0 0.00281905 l
+-0.937839 -0.131783 -0.926677 -0.12328 0 0 0 0.00281905 l
+-0.937839 -0.131783 -0.942273 -0.137762 0 0 0 0.00281905 l
+0.65565 0.388985 0.638441 0.403514 0 0 0 0.00281905 l
+-0.135879 -0.083559 -0.125462 -0.100999 0 0 0 0.00281905 l
+-0.135879 -0.083559 -0.150765 -0.0946922 0 0 0 0.00281905 l
+-0.135879 -0.083559 -0.148472 -0.0721595 0 0 0 0.00281905 l
+-0.966114 0.175631 -0.962639 0.185995 0 0 0 0.00281905 l
+-0.966114 0.175631 -0.961788 0.16872 0 0 0 0.00281905 l
+0.10289 0.489194 0.113393 0.494714 0 0 0 0.00281905 l
+0.180656 0.405058 0.185558 0.406808 0 0 0 0.00281905 l
+0.180656 0.405058 0.184093 0.395891 0 0 0 0.00281905 l
+0.180656 0.405058 0.164349 0.40281 0 0 0 0.00281905 l
+0.347775 -0.416992 0.351496 -0.429794 0 0 0 0.00281905 l
+0.347775 -0.416992 0.353145 -0.414197 0 0 0 0.00281905 l
+0.347775 -0.416992 0.334736 -0.422443 0 0 0 0.00281905 l
+-0.515578 -0.0129698 -0.512845 -0.00286025 0 0 0 0.00281905 l
+-0.515578 -0.0129698 -0.514843 -0.0302298 0 0 0 0.00281905 l
+-0.515578 -0.0129698 -0.536663 -0.014828 0 0 0 0.00281905 l
+0.825101 0.377348 0.814569 0.394969 0 0 0 0.00281905 l
+0.825101 0.377348 0.818313 0.374084 0 0 0 0.00281905 l
+0.47756 -0.243834 0.47908 -0.243948 0 0 0 0.00281905 l
+0.47756 -0.243834 0.469155 -0.250665 0 0 0 0.00281905 l
+0.375865 0.516177 0.368633 0.505972 0 0 0 0.00281905 l
+-0.109606 0.0862939 -0.118636 0.0756895 0 0 0 0.00281905 l
+-0.109606 0.0862939 -0.121355 0.0899399 0 0 0 0.00281905 l
+0.497186 0.0200434 0.51156 0.0173723 0 0 0 0.00281905 l
+-0.881194 0.464055 -0.888104 0.448102 0 0 0 0.00281905 l
+0.310899 -0.222854 0.315179 -0.232908 0 0 0 0.00281905 l
+0.6041 -0.538053 0.614157 -0.531152 0 0 0 0.00281905 l
+0.6041 -0.538053 0.595419 -0.543231 0 0 0 0.00281905 l
+0.0369058 0.120098 0.0403637 0.114267 0 0 0 0.00281905 l
+0.0369058 0.120098 0.0367698 0.12497 0 0 0 0.00281905 l
+0.0369058 0.120098 0.0300703 0.115839 0 0 0 0.00281905 l
+0.206869 -0.78484 0.207472 -0.798889 0 0 0 0.00281905 l
+0.206869 -0.78484 0.215019 -0.775333 0 0 0 0.00281905 l
+0.206869 -0.78484 0.194135 -0.790698 0 0 0 0.00281905 l
+0.530183 0.614006 0.543998 0.604238 0 0 0 0.00281905 l
+0.530183 0.614006 0.513915 0.607394 0 0 0 0.00281905 l
+0.517008 -0.443446 0.519438 -0.458422 0 0 0 0.00281905 l
+0.517008 -0.443446 0.517781 -0.433832 0 0 0 0.00281905 l
+0.807991 0.312194 0.812346 0.313288 0 0 0 0.00281905 l
+0.807991 0.312194 0.801828 0.303314 0 0 0 0.00281905 l
+0.807991 0.312194 0.796831 0.317673 0 0 0 0.00281905 l
+-0.762209 0.355263 -0.752266 0.366741 0 0 0 0.00281905 l
+-0.762209 0.355263 -0.776007 0.356523 0 0 0 0.00281905 l
+-0.697592 -0.685289 -0.686988 -0.668569 0 0 0 0.00281905 l
+-0.697592 -0.685289 -0.718355 -0.692688 0 0 0 0.00281905 l
+-0.274777 0.656034 -0.262465 0.647171 0 0 0 0.00281905 l
+-0.274777 0.656034 -0.277091 0.655073 0 0 0 0.00281905 l
+-0.514247 -0.753812 -0.507112 -0.738336 0 0 0 0.00281905 l
+-0.514247 -0.753812 -0.517019 -0.76902 0 0 0 0.00281905 l
+-0.514247 -0.753812 -0.519543 -0.751565 0 0 0 0.00281905 l
+0.0100471 -0.913308 0.0291673 -0.900703 0 0 0 0.00281905 l
+0.0100471 -0.913308 0.0129909 -0.917216 0 0 0 0.00281905 l
+0.0100471 -0.913308 0.00219534 -0.910376 0 0 0 0.00281905 l
+-0.645758 -0.685735 -0.637126 -0.67808 0 0 0 0.00281905 l
+-0.645758 -0.685735 -0.63514 -0.698314 0 0 0 0.00281905 l
+-0.284736 -0.932627 -0.274472 -0.91482 0 0 0 0.00281905 l
+-0.284736 -0.932627 -0.282425 -0.936414 0 0 0 0.00281905 l
+-0.284736 -0.932627 -0.286646 -0.934078 0 0 0 0.00281905 l
+-0.343691 -0.127846 -0.330301 -0.113108 0 0 0 0.00281905 l
+-0.343691 -0.127846 -0.350309 -0.13245 0 0 0 0.00281905 l
+-0.651998 0.0536243 -0.652512 0.0724993 0 0 0 0.00281905 l
+-0.651998 0.0536243 -0.653729 0.0532402 0 0 0 0.00281905 l
+0.602303 -0.0232589 0.61523 -0.0217753 0 0 0 0.00281905 l
+0.602303 -0.0232589 0.593292 -0.0253304 0 0 0 0.00281905 l
+-0.407277 -0.825366 -0.392134 -0.826142 0 0 0 0.00281905 l
+-0.407277 -0.825366 -0.411284 -0.837183 0 0 0 0.00281905 l
+0.149206 -0.45946 0.148657 -0.463137 0 0 0 0.00281905 l
+-0.814413 0.395606 -0.806224 0.399479 0 0 0 0.00281905 l
+-0.814413 0.395606 -0.835773 0.398373 0 0 0 0.00281905 l
+-0.752358 -0.194502 -0.74723 -0.205892 0 0 0 0.00281905 l
+0.36411 0.60137 0.359161 0.621443 0 0 0 0.00281905 l
+0.36411 0.60137 0.373278 0.597185 0 0 0 0.00281905 l
+-0.555041 0.10615 -0.547057 0.0947999 0 0 0 0.00281905 l
+-0.555041 0.10615 -0.561948 0.117445 0 0 0 0.00281905 l
+0.0808742 0.28687 0.0893844 0.282907 0 0 0 0.00281905 l
+-0.315088 -0.944697 -0.310734 -0.944469 0 0 0 0.00281905 l
+-0.315088 -0.944697 -0.324037 -0.935332 0 0 0 0.00281905 l
+-0.0961382 0.780995 -0.0853175 0.789978 0 0 0 0.00281905 l
+-0.0961382 0.780995 -0.0964766 0.769996 0 0 0 0.00281905 l
+-0.0961382 0.780995 -0.109139 0.776304 0 0 0 0.00281905 l
+0.575914 0.573916 0.576305 0.581426 0 0 0 0.00281905 l
+0.6088 0.326778 0.613926 0.33196 0 0 0 0.00281905 l
+0.6088 0.326778 0.605067 0.329911 0 0 0 0.00281905 l
+0.122985 -0.703958 0.128656 -0.714534 0 0 0 0.00281905 l
+0.122985 -0.703958 0.11971 -0.70118 0 0 0 0.00281905 l
+0.397682 0.0240576 0.390331 0.0193567 0 0 0 0.00281905 l
+-0.697077 -0.0698009 -0.685036 -0.0731641 0 0 0 0.00281905 l
+-0.697077 -0.0698009 -0.71196 -0.0641645 0 0 0 0.00281905 l
+0.342298 0.453467 0.353001 0.456139 0 0 0 0.00281905 l
+0.342298 0.453467 0.342469 0.44431 0 0 0 0.00281905 l
+0.257379 0.427235 0.256964 0.414008 0 0 0 0.00281905 l
+0.257379 0.427235 0.253043 0.440504 0 0 0 0.00281905 l
+-0.828273 0.238411 -0.814799 0.249717 0 0 0 0.00281905 l
+-0.828273 0.238411 -0.838068 0.226193 0 0 0 0.00281905 l
+-0.840833 -0.130077 -0.836495 -0.129366 0 0 0 0.00281905 l
+-0.840833 -0.130077 -0.844616 -0.137616 0 0 0 0.00281905 l
+-0.473459 -0.0562206 -0.456939 -0.0659617 0 0 0 0.00281905 l
+-0.269692 0.321634 -0.272605 0.31303 0 0 0 0.00281905 l
+-0.269692 0.321634 -0.264415 0.337388 0 0 0 0.00281905 l
+-0.269692 0.321634 -0.254661 0.323686 0 0 0 0.00281905 l
+0.226524 0.762432 0.224066 0.772022 0 0 0 0.00281905 l
+0.226524 0.762432 0.22846 0.751789 0 0 0 0.00281905 l
+0.941692 0.227407 0.95727 0.226526 0 0 0 0.00281905 l
+0.941692 0.227407 0.923444 0.223425 0 0 0 0.00281905 l
+-0.539688 0.567085 -0.540124 0.570259 0 0 0 0.00281905 l
+-0.539688 0.567085 -0.533869 0.559109 0 0 0 0.00281905 l
+-0.539688 0.567085 -0.553562 0.562988 0 0 0 0.00281905 l
+-0.353627 -0.664887 -0.349456 -0.648455 0 0 0 0.00281905 l
+-0.353627 -0.664887 -0.369281 -0.672753 0 0 0 0.00281905 l
+0.358898 0.481448 0.365112 0.48062 0 0 0 0.00281905 l
+0.358898 0.481448 0.35285 0.486876 0 0 0 0.00281905 l
+-0.703439 -0.56992 -0.697907 -0.574269 0 0 0 0.00281905 l
+-0.453386 0.535503 -0.463259 0.522595 0 0 0 0.00281905 l
+-0.453386 0.535503 -0.445777 0.542124 0 0 0 0.00281905 l
+-0.453386 0.535503 -0.46366 0.54114 0 0 0 0.00281905 l
+0.0753081 -0.742728 0.0805016 -0.739182 0 0 0 0.00281905 l
+0.0753081 -0.742728 0.0693927 -0.747692 0 0 0 0.00281905 l
+0.600439 0.723525 0.587043 0.723975 0 0 0 0.00281905 l
+-0.129811 -0.192656 -0.130161 -0.190945 0 0 0 0.00281905 l
+-0.482099 -0.798337 -0.488312 -0.808276 0 0 0 0.00281905 l
+-0.482099 -0.798337 -0.478105 -0.794422 0 0 0 0.00281905 l
+-0.482099 -0.798337 -0.488352 -0.79521 0 0 0 0.00281905 l
+-0.512125 0.446648 -0.509305 0.452204 0 0 0 0.00281905 l
+-0.512125 0.446648 -0.523933 0.441905 0 0 0 0.00281905 l
+0.113151 -0.947652 0.113009 -0.950783 0 0 0 0.00281905 l
+0.113151 -0.947652 0.107767 -0.936606 0 0 0 0.00281905 l
+-0.154851 0.944207 -0.152207 0.933929 0 0 0 0.00281905 l
+-0.154851 0.944207 -0.148804 0.952742 0 0 0 0.00281905 l
+0.192975 -0.585733 0.201598 -0.588095 0 0 0 0.00281905 l
+0.192975 -0.585733 0.180204 -0.573157 0 0 0 0.00281905 l
+-0.323431 0.34428 -0.325909 0.342977 0 0 0 0.00281905 l
+0.723098 0.566388 0.716267 0.549514 0 0 0 0.00281905 l
+0.723098 0.566388 0.736284 0.56782 0 0 0 0.00281905 l
+0.0948657 -0.320846 0.0946041 -0.340749 0 0 0 0.00281905 l
+0.0948657 -0.320846 0.102991 -0.318478 0 0 0 0.00281905 l
+0.0948657 -0.320846 0.092619 -0.319501 0 0 0 0.00281905 l
+0.185566 0.498014 0.185919 0.490962 0 0 0 0.00281905 l
+-0.936466 -0.106454 -0.926677 -0.12328 0 0 0 0.00281905 l
+-0.936466 -0.106454 -0.947983 -0.0873574 0 0 0 0.00281905 l
+-0.936466 -0.106454 -0.957981 -0.113868 0 0 0 0.00281905 l
+-0.391239 -0.298605 -0.404596 -0.290831 0 0 0 0.00281905 l
+0.541081 -0.372723 0.545729 -0.378057 0 0 0 0.00281905 l
+0.541081 -0.372723 0.535252 -0.380814 0 0 0 0.00281905 l
+0.301316 0.753025 0.302087 0.75823 0 0 0 0.00281905 l
+0.301316 0.753025 0.301388 0.745362 0 0 0 0.00281905 l
+0.0788964 0.344692 0.0949823 0.348378 0 0 0 0.00281905 l
+0.0788964 0.344692 0.0816094 0.338024 0 0 0 0.00281905 l
+0.0788964 0.344692 0.0697739 0.34719 0 0 0 0.00281905 l
+0.353775 0.538438 0.356564 0.517034 0 0 0 0.00281905 l
+0.353775 0.538438 0.348923 0.551491 0 0 0 0.00281905 l
+-0.573486 0.531042 -0.560062 0.536728 0 0 0 0.00281905 l
+-0.573486 0.531042 -0.580256 0.531829 0 0 0 0.00281905 l
+-0.693391 0.442563 -0.703036 0.439787 0 0 0 0.00281905 l
+0.517166 0.12847 0.512863 0.135356 0 0 0 0.00281905 l
+0.426473 -0.120629 0.432184 -0.109052 0 0 0 0.00281905 l
+0.426473 -0.120629 0.419064 -0.112711 0 0 0 0.00281905 l
+-0.440788 -0.24178 -0.43431 -0.247648 0 0 0 0.00281905 l
+-0.440788 -0.24178 -0.449978 -0.253718 0 0 0 0.00281905 l
+-0.709961 0.148032 -0.701231 0.13214 0 0 0 0.00281905 l
+-0.241742 0.700025 -0.237986 0.707789 0 0 0 0.00281905 l
+-0.241742 0.700025 -0.238927 0.696177 0 0 0 0.00281905 l
+-0.241742 0.700025 -0.252554 0.693479 0 0 0 0.00281905 l
+0.481329 -0.598714 0.486157 -0.585138 0 0 0 0.00281905 l
+0.481329 -0.598714 0.494487 -0.598377 0 0 0 0.00281905 l
+0.481329 -0.598714 0.473387 -0.607185 0 0 0 0.00281905 l
+0.120056 0.86288 0.111441 0.849678 0 0 0 0.00281905 l
+0.120056 0.86288 0.131394 0.868509 0 0 0 0.00281905 l
+0.446644 0.129097 0.462607 0.13222 0 0 0 0.00281905 l
+0.446644 0.129097 0.429505 0.128192 0 0 0 0.00281905 l
+-0.120907 0.827427 -0.114437 0.820214 0 0 0 0.00281905 l
+-0.120907 0.827427 -0.124624 0.817791 0 0 0 0.00281905 l
+-0.120907 0.827427 -0.132155 0.836678 0 0 0 0.00281905 l
+-0.252668 0.00167118 -0.262267 -0.0163516 0 0 0 0.00281905 l
+-0.252668 0.00167118 -0.239024 0.00976958 0 0 0 0.00281905 l
+-0.55041 -0.218037 -0.54619 -0.225688 0 0 0 0.00281905 l
+-0.55041 -0.218037 -0.550987 -0.202089 0 0 0 0.00281905 l
+-0.55041 -0.218037 -0.55788 -0.218605 0 0 0 0.00281905 l
+-0.366666 0.51632 -0.364555 0.526779 0 0 0 0.00281905 l
+-0.366666 0.51632 -0.371659 0.499413 0 0 0 0.00281905 l
+0.153521 0.00169971 0.161423 -0.000510583 0 0 0 0.00281905 l
+0.153521 0.00169971 0.137925 0.00643126 0 0 0 0.00281905 l
+0.676012 -0.0919279 0.68313 -0.0896031 0 0 0 0.00281905 l
+0.676012 -0.0919279 0.666319 -0.104294 0 0 0 0.00281905 l
+-0.305265 0.875124 -0.28819 0.888932 0 0 0 0.00281905 l
+-0.305265 0.875124 -0.312194 0.870612 0 0 0 0.00281905 l
+0.509779 0.746576 0.513731 0.753167 0 0 0 0.00281905 l
+0.509779 0.746576 0.500853 0.735994 0 0 0 0.00281905 l
+0.392651 0.325948 0.39271 0.319559 0 0 0 0.00281905 l
+0.392651 0.325948 0.383683 0.328034 0 0 0 0.00281905 l
+0.341644 0.642019 0.338724 0.62263 0 0 0 0.00281905 l
+-0.288285 -0.227703 -0.2878 -0.214368 0 0 0 0.00281905 l
+-0.288285 -0.227703 -0.273266 -0.227016 0 0 0 0.00281905 l
+-0.934091 -0.0236802 -0.929677 -0.0391187 0 0 0 0.00281905 l
+-0.934091 -0.0236802 -0.940218 -0.0221952 0 0 0 0.00281905 l
+-0.934091 -0.0236802 -0.932611 -0.0225353 0 0 0 0.00281905 l
+0.0291117 -0.570709 0.0259233 -0.581877 0 0 0 0.00281905 l
+0.0291117 -0.570709 0.0308855 -0.567843 0 0 0 0.00281905 l
+0.0291117 -0.570709 0.0142014 -0.568721 0 0 0 0.00281905 l
+-0.164327 0.803985 -0.151423 0.799081 0 0 0 0.00281905 l
+-0.164327 0.803985 -0.171899 0.813877 0 0 0 0.00281905 l
+-0.613744 -0.513108 -0.621169 -0.501327 0 0 0 0.00281905 l
+-0.613744 -0.513108 -0.614966 -0.516162 0 0 0 0.00281905 l
+-0.591356 0.450798 -0.591159 0.45566 0 0 0 0.00281905 l
+-0.591356 0.450798 -0.575185 0.45215 0 0 0 0.00281905 l
+-0.591356 0.450798 -0.602099 0.432041 0 0 0 0.00281905 l
+0.188663 -0.932984 0.19453 -0.945007 0 0 0 0.00281905 l
+0.188663 -0.932984 0.206244 -0.922395 0 0 0 0.00281905 l
+0.335699 -0.671492 0.348499 -0.656885 0 0 0 0.00281905 l
+0.335699 -0.671492 0.326144 -0.682206 0 0 0 0.00281905 l
+0.38075 -0.357633 0.393478 -0.364069 0 0 0 0.00281905 l
+0.38075 -0.357633 0.377298 -0.355154 0 0 0 0.00281905 l
+0.768108 0.194902 0.764849 0.207012 0 0 0 0.00281905 l
+-0.902453 -0.016711 -0.901506 -0.0101113 0 0 0 0.00281905 l
+-0.902453 -0.016711 -0.901978 -0.0391823 0 0 0 0.00281905 l
+0.206586 0.318078 0.222228 0.332831 0 0 0 0.00281905 l
+0.206586 0.318078 0.217329 0.309023 0 0 0 0.00281905 l
+0.206586 0.318078 0.194446 0.30009 0 0 0 0.00281905 l
+0.206586 0.318078 0.190112 0.329727 0 0 0 0.00281905 l
+-0.806435 -0.0522655 -0.806212 -0.052957 0 0 0 0.00281905 l
+-0.806435 -0.0522655 -0.816625 -0.0480042 0 0 0 0.00281905 l
+0.298178 -0.30823 0.293013 -0.306595 0 0 0 0.00281905 l
+0.298178 -0.30823 0.29877 -0.306927 0 0 0 0.00281905 l
+0.512863 0.135356 0.513299 0.14065 0 0 0 0.00281905 l
+0.512863 0.135356 0.517166 0.12847 0 0 0 0.00281905 l
+0.512863 0.135356 0.495937 0.132743 0 0 0 0.00281905 l
+0.891547 -0.184704 0.888053 -0.183183 0 0 0 0.00281905 l
+-0.140204 0.428698 -0.141021 0.433607 0 0 0 0.00281905 l
+-0.140204 0.428698 -0.148361 0.425375 0 0 0 0.00281905 l
+0.41088 -0.4435 0.412073 -0.438413 0 0 0 0.00281905 l
+0.41088 -0.4435 0.406171 -0.442588 0 0 0 0.00281905 l
+0.368633 0.505972 0.375865 0.516177 0 0 0 0.00281905 l
+0.368633 0.505972 0.379537 0.50121 0 0 0 0.00281905 l
+0.368633 0.505972 0.356564 0.517034 0 0 0 0.00281905 l
+0.728188 0.232755 0.739902 0.240474 0 0 0 0.00281905 l
+0.728188 0.232755 0.726358 0.226537 0 0 0 0.00281905 l
+-0.191713 0.365204 -0.196299 0.376307 0 0 0 0.00281905 l
+-0.191713 0.365204 -0.189472 0.36352 0 0 0 0.00281905 l
+-0.191713 0.365204 -0.202629 0.355891 0 0 0 0.00281905 l
+0.726247 0.610468 0.726389 0.612936 0 0 0 0.00281905 l
+0.726247 0.610468 0.73072 0.611074 0 0 0 0.00281905 l
+-0.73385 0.115349 -0.734224 0.107655 0 0 0 0.00281905 l
+-0.73385 0.115349 -0.737135 0.125423 0 0 0 0.00281905 l
+0.177555 -0.566859 0.187485 -0.565075 0 0 0 0.00281905 l
+0.177555 -0.566859 0.180204 -0.573157 0 0 0 0.00281905 l
+0.177555 -0.566859 0.159696 -0.55807 0 0 0 0.00281905 l
+0.4892 0.262729 0.488906 0.243299 0 0 0 0.00281905 l
+0.4892 0.262729 0.496982 0.270407 0 0 0 0.00281905 l
+0.4892 0.262729 0.470698 0.266176 0 0 0 0.00281905 l
+-0.208068 0.475776 -0.223461 0.478037 0 0 0 0.00281905 l
+-0.0144263 -0.674143 -0.00993317 -0.657905 0 0 0 0.00281905 l
+-0.0144263 -0.674143 -0.0194248 -0.675801 0 0 0 0.00281905 l
+-0.34687 -0.806146 -0.338669 -0.823483 0 0 0 0.00281905 l
+-0.34687 -0.806146 -0.348642 -0.795528 0 0 0 0.00281905 l
+-0.34687 -0.806146 -0.360394 -0.810255 0 0 0 0.00281905 l
+0.448656 -0.513246 0.453917 -0.504761 0 0 0 0.00281905 l
+0.655366 0.115633 0.671778 0.126821 0 0 0 0.00281905 l
+0.655366 0.115633 0.651528 0.121983 0 0 0 0.00281905 l
+0.230637 -0.00840827 0.226128 0.00806809 0 0 0 0.00281905 l
+0.230637 -0.00840827 0.221721 -0.0242625 0 0 0 0.00281905 l
+0.272028 0.86479 0.266673 0.847575 0 0 0 0.00281905 l
+0.272028 0.86479 0.281094 0.866988 0 0 0 0.00281905 l
+0.272028 0.86479 0.260277 0.870489 0 0 0 0.00281905 l
+-0.621874 0.340038 -0.618712 0.336219 0 0 0 0.00281905 l
+0.242354 -0.589848 0.257272 -0.573043 0 0 0 0.00281905 l
+0.242354 -0.589848 0.238127 -0.604508 0 0 0 0.00281905 l
+0.39227 -0.562777 0.394945 -0.568678 0 0 0 0.00281905 l
+0.39227 -0.562777 0.376464 -0.558093 0 0 0 0.00281905 l
+-0.566473 0.664268 -0.552574 0.664521 0 0 0 0.00281905 l
+-0.566473 0.664268 -0.566998 0.66675 0 0 0 0.00281905 l
+0.0865911 0.701048 0.0938819 0.690609 0 0 0 0.00281905 l
+0.0865911 0.701048 0.0891672 0.707587 0 0 0 0.00281905 l
+0.0865911 0.701048 0.0815989 0.698005 0 0 0 0.00281905 l
+-0.138292 -0.269213 -0.13404 -0.271463 0 0 0 0.00281905 l
+-0.243398 -0.73145 -0.240216 -0.743999 0 0 0 0.00281905 l
+-0.850442 -0.373911 -0.84791 -0.380746 0 0 0 0.00281905 l
+-0.850442 -0.373911 -0.867518 -0.380522 0 0 0 0.00281905 l
+-0.195629 -0.0436842 -0.193718 -0.0314281 0 0 0 0.00281905 l
+-0.195629 -0.0436842 -0.192241 -0.0477515 0 0 0 0.00281905 l
+-0.777844 0.0315275 -0.75783 0.0358052 0 0 0 0.00281905 l
+0.272076 -0.637286 0.276906 -0.62408 0 0 0 0.00281905 l
+0.272076 -0.637286 0.278515 -0.642057 0 0 0 0.00281905 l
+-0.929391 -0.193952 -0.919607 -0.188173 0 0 0 0.00281905 l
+-0.929391 -0.193952 -0.940486 -0.19875 0 0 0 0.00281905 l
+-0.502357 -0.0451854 -0.509276 -0.0330108 0 0 0 0.00281905 l
+-0.502357 -0.0451854 -0.498274 -0.0510132 0 0 0 0.00281905 l
+0.115363 0.211869 0.118551 0.203455 0 0 0 0.00281905 l
+-0.671621 -0.166178 -0.665286 -0.173693 0 0 0 0.00281905 l
+-0.671621 -0.166178 -0.661308 -0.161431 0 0 0 0.00281905 l
+0.271195 -0.882071 0.27181 -0.880524 0 0 0 0.00281905 l
+0.271195 -0.882071 0.265406 -0.891342 0 0 0 0.00281905 l
+-0.239855 -0.349289 -0.239349 -0.350002 0 0 0 0.00281905 l
+-0.239855 -0.349289 -0.255554 -0.3406 0 0 0 0.00281905 l
+-0.648974 -0.370565 -0.646171 -0.36826 0 0 0 0.00281905 l
+-0.821213 -0.141602 -0.80846 -0.137194 0 0 0 0.00281905 l
+-0.821213 -0.141602 -0.828441 -0.13827 0 0 0 0.00281905 l
+0.515144 0.526468 0.520931 0.526558 0 0 0 0.00281905 l
+0.515144 0.526468 0.516114 0.514975 0 0 0 0.00281905 l
+0.515144 0.526468 0.50606 0.52865 0 0 0 0.00281905 l
+-0.305799 0.925253 -0.299896 0.917187 0 0 0 0.00281905 l
+-0.305799 0.925253 -0.314982 0.922324 0 0 0 0.00281905 l
+0.296479 -0.405795 0.299383 -0.413198 0 0 0 0.00281905 l
+0.296479 -0.405795 0.302259 -0.399627 0 0 0 0.00281905 l
+0.296479 -0.405795 0.291319 -0.405491 0 0 0 0.00281905 l
+-0.814799 0.249717 -0.811576 0.257864 0 0 0 0.00281905 l
+-0.814799 0.249717 -0.803055 0.24477 0 0 0 0.00281905 l
+-0.814799 0.249717 -0.828273 0.238411 0 0 0 0.00281905 l
+-0.00285242 -0.184346 -0.00418032 -0.196153 0 0 0 0.00281905 l
+-0.00285242 -0.184346 0.0101882 -0.177811 0 0 0 0.00281905 l
+-0.00285242 -0.184346 -0.0091847 -0.184857 0 0 0 0.00281905 l
+0.673614 0.144956 0.676223 0.159156 0 0 0 0.00281905 l
+0.673614 0.144956 0.686413 0.13244 0 0 0 0.00281905 l
+0.673614 0.144956 0.662696 0.144497 0 0 0 0.00281905 l
+-0.364598 -0.0445639 -0.363994 -0.0365987 0 0 0 0.00281905 l
+-0.364598 -0.0445639 -0.356974 -0.0507432 0 0 0 0.00281905 l
+-0.40721 0.622151 -0.39792 0.617356 0 0 0 0.00281905 l
+-0.40721 0.622151 -0.409234 0.623312 0 0 0 0.00281905 l
+0.368315 -0.800676 0.378596 -0.791261 0 0 0 0.00281905 l
+0.368315 -0.800676 0.361701 -0.801001 0 0 0 0.00281905 l
+0.118572 0.658442 0.110494 0.649964 0 0 0 0.00281905 l
+0.118572 0.658442 0.135443 0.661927 0 0 0 0.00281905 l
+0.118572 0.658442 0.108244 0.662783 0 0 0 0.00281905 l
+0.0240807 0.671092 0.0298122 0.669986 0 0 0 0.00281905 l
+0.0240807 0.671092 0.0136158 0.672032 0 0 0 0.00281905 l
+0.377782 0.38659 0.391677 0.377247 0 0 0 0.00281905 l
+0.377782 0.38659 0.368217 0.384348 0 0 0 0.00281905 l
+-0.599385 -0.730138 -0.595858 -0.713065 0 0 0 0.00281905 l
+-0.599385 -0.730138 -0.606281 -0.745466 0 0 0 0.00281905 l
+0.0412184 0.550722 0.0471527 0.546501 0 0 0 0.00281905 l
+0.0412184 0.550722 0.0373541 0.551675 0 0 0 0.00281905 l
+-0.801703 0.33383 -0.800605 0.341635 0 0 0 0.00281905 l
+-0.801703 0.33383 -0.796864 0.327548 0 0 0 0.00281905 l
+-0.801703 0.33383 -0.814567 0.328272 0 0 0 0.00281905 l
+-0.80508 -0.418363 -0.79332 -0.413256 0 0 0 0.00281905 l
+-0.80508 -0.418363 -0.813228 -0.438529 0 0 0 0.00281905 l
+-0.21432 0.496846 -0.217134 0.511329 0 0 0 0.00281905 l
+-0.21432 0.496846 -0.210473 0.495437 0 0 0 0.00281905 l
+-0.21432 0.496846 -0.216662 0.495779 0 0 0 0.00281905 l
+0.564068 0.612402 0.565714 0.599313 0 0 0 0.00281905 l
+0.564068 0.612402 0.558828 0.616573 0 0 0 0.00281905 l
+0.564068 0.612402 0.570821 0.617444 0 0 0 0.00281905 l
+0.040672 -0.340377 0.0409017 -0.320211 0 0 0 0.00281905 l
+0.485724 -0.794402 0.498697 -0.798856 0 0 0 0.00281905 l
+0.485724 -0.794402 0.480863 -0.793543 0 0 0 0.00281905 l
+-0.376286 0.649711 -0.381166 0.658859 0 0 0 0.00281905 l
+-0.376286 0.649711 -0.388216 0.638614 0 0 0 0.00281905 l
+-0.854265 0.380865 -0.85249 0.372585 0 0 0 0.00281905 l
+-0.854265 0.380865 -0.8608 0.387165 0 0 0 0.00281905 l
+0.259811 -0.377593 0.265619 -0.35874 0 0 0 0.00281905 l
+0.259811 -0.377593 0.267659 -0.390353 0 0 0 0.00281905 l
+0.259811 -0.377593 0.25494 -0.381484 0 0 0 0.00281905 l
+0.738796 0.35516 0.742532 0.360178 0 0 0 0.00281905 l
+0.738796 0.35516 0.73541 0.354395 0 0 0 0.00281905 l
+-0.79332 -0.413256 -0.783027 -0.420782 0 0 0 0.00281905 l
+-0.79332 -0.413256 -0.80508 -0.418363 0 0 0 0.00281905 l
+0.534126 -0.238873 0.537528 -0.244047 0 0 0 0.00281905 l
+0.534126 -0.238873 0.534467 -0.238326 0 0 0 0.00281905 l
+0.495671 0.172731 0.505343 0.160212 0 0 0 0.00281905 l
+0.495671 0.172731 0.506051 0.18663 0 0 0 0.00281905 l
+0.0894244 -0.0234995 0.0776741 -0.0366574 0 0 0 0.00281905 l
+0.0894244 -0.0234995 0.0809231 -0.0138637 0 0 0 0.00281905 l
+0.39193 -0.152982 0.387085 -0.1394 0 0 0 0.00281905 l
+0.39193 -0.152982 0.380745 -0.159776 0 0 0 0.00281905 l
+-0.706684 0.456713 -0.70077 0.471456 0 0 0 0.00281905 l
+-0.706684 0.456713 -0.714001 0.451106 0 0 0 0.00281905 l
+0.771909 0.600385 0.77521 0.608905 0 0 0 0.00281905 l
+0.582928 0.442041 0.582244 0.438478 0 0 0 0.00281905 l
+0.582928 0.442041 0.568657 0.445315 0 0 0 0.00281905 l
+-0.493855 -0.687542 -0.482092 -0.680818 0 0 0 0.00281905 l
+-0.493855 -0.687542 -0.49688 -0.692125 0 0 0 0.00281905 l
+-0.493855 -0.687542 -0.496239 -0.684635 0 0 0 0.00281905 l
+-0.385401 -0.761311 -0.391825 -0.76384 0 0 0 0.00281905 l
+-0.385401 -0.761311 -0.383227 -0.758285 0 0 0 0.00281905 l
+0.359046 0.324055 0.359205 0.340136 0 0 0 0.00281905 l
+0.0311067 0.333075 0.0323967 0.316593 0 0 0 0.00281905 l
+0.0311067 0.333075 0.0338482 0.351798 0 0 0 0.00281905 l
+0.0311067 0.333075 0.0259219 0.333931 0 0 0 0.00281905 l
+0.325821 0.685853 0.325535 0.691825 0 0 0 0.00281905 l
+0.493003 0.679399 0.49526 0.697279 0 0 0 0.00281905 l
+0.493003 0.679399 0.484047 0.663137 0 0 0 0.00281905 l
+0.493003 0.679399 0.474353 0.683127 0 0 0 0.00281905 l
+-0.51001 -0.344541 -0.517117 -0.336142 0 0 0 0.00281905 l
+-0.51001 -0.344541 -0.4977 -0.349606 0 0 0 0.00281905 l
+0.486842 -0.237993 0.498362 -0.236065 0 0 0 0.00281905 l
+0.486842 -0.237993 0.486221 -0.237789 0 0 0 0.00281905 l
+-0.768565 0.464627 -0.765885 0.461176 0 0 0 0.00281905 l
+-0.768565 0.464627 -0.773749 0.466639 0 0 0 0.00281905 l
+0.308855 -0.79448 0.317346 -0.795688 0 0 0 0.00281905 l
+0.308855 -0.79448 0.302097 -0.790754 0 0 0 0.00281905 l
+0.251124 -0.242378 0.237721 -0.227045 0 0 0 0.00281905 l
+0.251124 -0.242378 0.257781 -0.250963 0 0 0 0.00281905 l
+0.251124 -0.242378 0.242422 -0.251177 0 0 0 0.00281905 l
+-0.295501 -0.257967 -0.286422 -0.255832 0 0 0 0.00281905 l
+-0.295501 -0.257967 -0.305185 -0.257339 0 0 0 0.00281905 l
+0.409886 -0.0883579 0.401602 -0.0848418 0 0 0 0.00281905 l
+0.889826 -0.319835 0.880817 -0.303731 0 0 0 0.00281905 l
+0.889826 -0.319835 0.91032 -0.313594 0 0 0 0.00281905 l
+-0.0141802 -0.122026 0.00600318 -0.119377 0 0 0 0.00281905 l
+-0.0141802 -0.122026 -0.00925185 -0.1349 0 0 0 0.00281905 l
+-0.0141802 -0.122026 -0.0303317 -0.107029 0 0 0 0.00281905 l
+-0.422638 -0.795734 -0.420041 -0.795592 0 0 0 0.00281905 l
+-0.402346 0.595882 -0.398185 0.597353 0 0 0 0.00281905 l
+-0.402346 0.595882 -0.410236 0.597317 0 0 0 0.00281905 l
+0.394469 0.223674 0.404587 0.220644 0 0 0 0.00281905 l
+-0.73646 0.496138 -0.731333 0.499703 0 0 0 0.00281905 l
+-0.73646 0.496138 -0.730757 0.493131 0 0 0 0.00281905 l
+0.595823 -0.615662 0.594609 -0.623847 0 0 0 0.00281905 l
+0.595823 -0.615662 0.602739 -0.606155 0 0 0 0.00281905 l
+0.0258828 0.637795 0.016473 0.640136 0 0 0 0.00281905 l
+-0.26811 -0.282987 -0.265311 -0.284971 0 0 0 0.00281905 l
+-0.26811 -0.282987 -0.273936 -0.287637 0 0 0 0.00281905 l
+-0.231704 -0.633897 -0.224238 -0.643785 0 0 0 0.00281905 l
+-0.231704 -0.633897 -0.232439 -0.63291 0 0 0 0.00281905 l
+0.29942 0.111802 0.295553 0.121061 0 0 0 0.00281905 l
+0.29942 0.111802 0.303213 0.106034 0 0 0 0.00281905 l
+0.26696 0.0175563 0.285134 0.0199736 0 0 0 0.00281905 l
+0.26696 0.0175563 0.261716 0.00869818 0 0 0 0.00281905 l
+-0.579896 -0.0517447 -0.574233 -0.0393411 0 0 0 0.00281905 l
+-0.579896 -0.0517447 -0.58079 -0.0602753 0 0 0 0.00281905 l
+-0.579896 -0.0517447 -0.597058 -0.0400136 0 0 0 0.00281905 l
+0.223979 0.894369 0.222116 0.882692 0 0 0 0.00281905 l
+0.223979 0.894369 0.22267 0.897683 0 0 0 0.00281905 l
+0.479699 0.0626173 0.485734 0.0600073 0 0 0 0.00281905 l
+0.479699 0.0626173 0.471425 0.0670765 0 0 0 0.00281905 l
+0.045473 0.758335 0.0482192 0.772924 0 0 0 0.00281905 l
+-0.224238 -0.643785 -0.209681 -0.648163 0 0 0 0.00281905 l
+-0.224238 -0.643785 -0.225848 -0.656221 0 0 0 0.00281905 l
+-0.224238 -0.643785 -0.231704 -0.633897 0 0 0 0.00281905 l
+-0.553755 -0.320361 -0.553714 -0.325577 0 0 0 0.00281905 l
+-0.70907 0.689131 -0.695042 0.689592 0 0 0 0.00281905 l
+-0.499593 -0.652595 -0.48665 -0.650737 0 0 0 0.00281905 l
+-0.0247685 0.562519 -0.00806925 0.57144 0 0 0 0.00281905 l
+-0.0247685 0.562519 -0.0235271 0.560363 0 0 0 0.00281905 l
+-0.0247685 0.562519 -0.0414119 0.567753 0 0 0 0.00281905 l
+-0.509276 -0.0330108 -0.502357 -0.0451854 0 0 0 0.00281905 l
+-0.509276 -0.0330108 -0.503469 -0.0307864 0 0 0 0.00281905 l
+-0.509276 -0.0330108 -0.514843 -0.0302298 0 0 0 0.00281905 l
+0.409552 -0.626324 0.409556 -0.638414 0 0 0 0.00281905 l
+0.409552 -0.626324 0.405828 -0.619173 0 0 0 0.00281905 l
+-0.2671 -0.110215 -0.265806 -0.108363 0 0 0 0.00281905 l
+-0.151782 0.338207 -0.150818 0.323989 0 0 0 0.00281905 l
+-0.151782 0.338207 -0.162658 0.339415 0 0 0 0.00281905 l
+-0.52251 -0.277104 -0.515718 -0.274828 0 0 0 0.00281905 l
+-0.349775 -0.455934 -0.349468 -0.447815 0 0 0 0.00281905 l
+-0.349775 -0.455934 -0.357865 -0.470833 0 0 0 0.00281905 l
+-0.349775 -0.455934 -0.357251 -0.453361 0 0 0 0.00281905 l
+-0.59008 -0.203235 -0.578152 -0.206225 0 0 0 0.00281905 l
+-0.59008 -0.203235 -0.598868 -0.205143 0 0 0 0.00281905 l
+0.658089 -0.153546 0.657388 -0.145855 0 0 0 0.00281905 l
+0.658089 -0.153546 0.667325 -0.149863 0 0 0 0.00281905 l
+0.441068 0.483447 0.451038 0.487041 0 0 0 0.00281905 l
+0.441068 0.483447 0.440991 0.477605 0 0 0 0.00281905 l
+0.26709 0.758891 0.273243 0.768981 0 0 0 0.00281905 l
+0.26709 0.758891 0.262377 0.755358 0 0 0 0.00281905 l
+-0.266062 -0.0599483 -0.266263 -0.0579224 0 0 0 0.00281905 l
+-0.446832 -0.265248 -0.449978 -0.253718 0 0 0 0.00281905 l
+-0.446832 -0.265248 -0.438114 -0.276322 0 0 0 0.00281905 l
+-0.23976 0.937734 -0.240903 0.921702 0 0 0 0.00281905 l
+-0.907259 -0.248572 -0.90215 -0.265555 0 0 0 0.00281905 l
+-0.907259 -0.248572 -0.906424 -0.244679 0 0 0 0.00281905 l
+-0.907259 -0.248572 -0.923414 -0.25199 0 0 0 0.00281905 l
+0.821324 -0.32456 0.819606 -0.33773 0 0 0 0.00281905 l
+0.821324 -0.32456 0.812214 -0.313528 0 0 0 0.00281905 l
+-0.45535 0.436524 -0.456625 0.443075 0 0 0 0.00281905 l
+-0.45535 0.436524 -0.441045 0.43497 0 0 0 0.00281905 l
+-0.155672 -0.378808 -0.15467 -0.384005 0 0 0 0.00281905 l
+-0.155672 -0.378808 -0.168884 -0.366913 0 0 0 0.00281905 l
+-0.432589 -0.759699 -0.422474 -0.772689 0 0 0 0.00281905 l
+-0.432589 -0.759699 -0.426152 -0.752659 0 0 0 0.00281905 l
+-0.432589 -0.759699 -0.443257 -0.761427 0 0 0 0.00281905 l
+0.328302 0.940271 0.315655 0.928119 0 0 0 0.00281905 l
+-0.17444 0.775227 -0.171376 0.777961 0 0 0 0.00281905 l
+-0.70077 0.471456 -0.706684 0.456713 0 0 0 0.00281905 l
+-0.70077 0.471456 -0.712621 0.484928 0 0 0 0.00281905 l
+-0.70077 0.471456 -0.692994 0.475083 0 0 0 0.00281905 l
+-0.85485 0.0176036 -0.854856 0.0282175 0 0 0 0.00281905 l
+-0.85485 0.0176036 -0.870067 0.0179736 0 0 0 0.00281905 l
+-0.531938 -0.163738 -0.534629 -0.178345 0 0 0 0.00281905 l
+-0.531938 -0.163738 -0.545108 -0.159155 0 0 0 0.00281905 l
+-0.149003 -0.75632 -0.146222 -0.766371 0 0 0 0.00281905 l
+-0.111598 0.173029 -0.103686 0.169704 0 0 0 0.00281905 l
+-0.111598 0.173029 -0.113051 0.159741 0 0 0 0.00281905 l
+-0.111598 0.173029 -0.117445 0.177399 0 0 0 0.00281905 l
+0.383683 0.328034 0.392651 0.325948 0 0 0 0.00281905 l
+0.383683 0.328034 0.374242 0.338368 0 0 0 0.00281905 l
+-0.680305 -0.234959 -0.675506 -0.22828 0 0 0 0.00281905 l
+-0.680305 -0.234959 -0.679656 -0.235486 0 0 0 0.00281905 l
+-0.680305 -0.234959 -0.686954 -0.238867 0 0 0 0.00281905 l
+0.273853 -0.333131 0.280733 -0.335456 0 0 0 0.00281905 l
+0.128625 -0.766533 0.145216 -0.769514 0 0 0 0.00281905 l
+0.655062 0.742157 0.647717 0.754484 0 0 0 0.00281905 l
+0.655062 0.742157 0.664011 0.744323 0 0 0 0.00281905 l
+0.655062 0.742157 0.642187 0.736083 0 0 0 0.00281905 l
+-0.455958 -0.865832 -0.448612 -0.869804 0 0 0 0.00281905 l
+-0.455958 -0.865832 -0.462198 -0.867008 0 0 0 0.00281905 l
+0.385055 0.0182855 0.383175 0.0244977 0 0 0 0.00281905 l
+0.385055 0.0182855 0.390331 0.0193567 0 0 0 0.00281905 l
+0.385055 0.0182855 0.371717 0.0118229 0 0 0 0.00281905 l
+0.46423 0.853307 0.462376 0.859505 0 0 0 0.00281905 l
+0.710059 -0.533088 0.718553 -0.526429 0 0 0 0.00281905 l
+0.710059 -0.533088 0.696806 -0.525368 0 0 0 0.00281905 l
+0.572697 0.0827439 0.584309 0.089887 0 0 0 0.00281905 l
+0.572697 0.0827439 0.562497 0.0744476 0 0 0 0.00281905 l
+-0.415126 0.382355 -0.40371 0.383043 0 0 0 0.00281905 l
+-0.415126 0.382355 -0.413603 0.374728 0 0 0 0.00281905 l
+-0.415126 0.382355 -0.416122 0.383675 0 0 0 0.00281905 l
+-0.330241 0.183156 -0.322386 0.197223 0 0 0 0.00281905 l
+0.511854 -0.325838 0.505757 -0.337776 0 0 0 0.00281905 l
+0.511854 -0.325838 0.517652 -0.321857 0 0 0 0.00281905 l
+-0.463232 0.123319 -0.460791 0.137156 0 0 0 0.00281905 l
+-0.463232 0.123319 -0.468261 0.119814 0 0 0 0.00281905 l
+0.840286 -0.447401 0.826242 -0.454828 0 0 0 0.00281905 l
+-0.382533 0.460775 -0.373504 0.454747 0 0 0 0.00281905 l
+-0.382533 0.460775 -0.396063 0.453229 0 0 0 0.00281905 l
+0.379431 0.887936 0.376107 0.885425 0 0 0 0.00281905 l
+0.579847 0.425204 0.575828 0.418227 0 0 0 0.00281905 l
+0.579847 0.425204 0.575804 0.426993 0 0 0 0.00281905 l
+-0.264621 0.127205 -0.258292 0.109812 0 0 0 0.00281905 l
+-0.264621 0.127205 -0.267296 0.133195 0 0 0 0.00281905 l
+-0.0638563 -0.680541 -0.0584359 -0.684781 0 0 0 0.00281905 l
+-0.0638563 -0.680541 -0.0695536 -0.689133 0 0 0 0.00281905 l
+0.391458 -0.233928 0.395049 -0.230109 0 0 0 0.00281905 l
+0.391458 -0.233928 0.396669 -0.243818 0 0 0 0.00281905 l
+0.391458 -0.233928 0.389143 -0.231633 0 0 0 0.00281905 l
+0.381103 -0.110534 0.393787 -0.115482 0 0 0 0.00281905 l
+0.381103 -0.110534 0.379045 -0.122598 0 0 0 0.00281905 l
+0.381103 -0.110534 0.370927 -0.100477 0 0 0 0.00281905 l
+-0.991884 0.0344015 -0.992017 0.0460004 0 0 0 0.00281905 l
+-0.991884 0.0344015 -0.994334 0.028406 0 0 0 0.00281905 l
+-0.0398061 -0.672967 -0.0381145 -0.676058 0 0 0 0.00281905 l
+-0.0398061 -0.672967 -0.0410281 -0.671147 0 0 0 0.00281905 l
+0.396847 -0.582953 0.401577 -0.603261 0 0 0 0.00281905 l
+0.396847 -0.582953 0.403358 -0.580276 0 0 0 0.00281905 l
+0.396847 -0.582953 0.390994 -0.580268 0 0 0 0.00281905 l
+0.662405 -0.622525 0.675963 -0.622857 0 0 0 0.00281905 l
+0.662405 -0.622525 0.660966 -0.628441 0 0 0 0.00281905 l
+0.662405 -0.622525 0.658427 -0.619827 0 0 0 0.00281905 l
+-0.949953 0.167987 -0.936026 0.149292 0 0 0 0.00281905 l
+-0.949953 0.167987 -0.956778 0.160253 0 0 0 0.00281905 l
+0.0118304 0.8226 0.0173174 0.826207 0 0 0 0.00281905 l
+0.0118304 0.8226 -0.00421419 0.823066 0 0 0 0.00281905 l
+0.732669 -0.0278845 0.739169 -0.0447414 0 0 0 0.00281905 l
+0.732669 -0.0278845 0.74845 -0.0198284 0 0 0 0.00281905 l
+0.732669 -0.0278845 0.726658 -0.0106861 0 0 0 0.00281905 l
+-0.294257 -0.643241 -0.284258 -0.64961 0 0 0 0.00281905 l
+-0.294257 -0.643241 -0.309497 -0.642881 0 0 0 0.00281905 l
+-0.294257 -0.643241 -0.28957 -0.634711 0 0 0 0.00281905 l
+0.292673 -0.339847 0.294643 -0.355377 0 0 0 0.00281905 l
+0.292673 -0.339847 0.288929 -0.336095 0 0 0 0.00281905 l
+-0.154783 0.256784 -0.144314 0.267707 0 0 0 0.00281905 l
+-0.154783 0.256784 -0.161064 0.260104 0 0 0 0.00281905 l
+-0.107879 0.597322 -0.107926 0.585005 0 0 0 0.00281905 l
+-0.107879 0.597322 -0.118973 0.609435 0 0 0 0.00281905 l
+0.491634 -0.301631 0.495351 -0.308538 0 0 0 0.00281905 l
+0.491634 -0.301631 0.487068 -0.306228 0 0 0 0.00281905 l
+0.766644 0.0651518 0.764849 0.076174 0 0 0 0.00281905 l
+0.766644 0.0651518 0.751699 0.0591822 0 0 0 0.00281905 l
+0.246628 0.132946 0.2515 0.122243 0 0 0 0.00281905 l
+0.246628 0.132946 0.230371 0.121257 0 0 0 0.00281905 l
+-0.846067 -0.525519 -0.849515 -0.508807 0 0 0 0.00281905 l
+-0.846067 -0.525519 -0.837275 -0.524432 0 0 0 0.00281905 l
+-0.630034 -0.220034 -0.63171 -0.209739 0 0 0 0.00281905 l
+-0.630034 -0.220034 -0.634403 -0.23306 0 0 0 0.00281905 l
+0.396938 -0.463511 0.397048 -0.456328 0 0 0 0.00281905 l
+0.396938 -0.463511 0.393043 -0.464873 0 0 0 0.00281905 l
+0.724085 -0.63314 0.731909 -0.621841 0 0 0 0.00281905 l
+0.724085 -0.63314 0.721461 -0.639918 0 0 0 0.00281905 l
+0.595538 0.705009 0.595709 0.703359 0 0 0 0.00281905 l
+-0.670146 -0.142618 -0.658286 -0.148888 0 0 0 0.00281905 l
+-0.670146 -0.142618 -0.6823 -0.136453 0 0 0 0.00281905 l
+-0.466835 -0.615004 -0.452665 -0.618624 0 0 0 0.00281905 l
+0.0182091 -0.276157 0.0179683 -0.281144 0 0 0 0.00281905 l
+0.0182091 -0.276157 0.0224802 -0.27297 0 0 0 0.00281905 l
+-0.574233 -0.0393411 -0.579896 -0.0517447 0 0 0 0.00281905 l
+-0.424717 -0.628032 -0.426274 -0.627145 0 0 0 0.00281905 l
+-0.771213 0.490798 -0.760542 0.50161 0 0 0 0.00281905 l
+-0.771213 0.490798 -0.768904 0.487576 0 0 0 0.00281905 l
+-0.771213 0.490798 -0.774885 0.491976 0 0 0 0.00281905 l
+0.778383 -0.174234 0.775272 -0.174678 0 0 0 0.00281905 l
+0.778383 -0.174234 0.779243 -0.173526 0 0 0 0.00281905 l
+-0.565756 -0.721479 -0.555181 -0.720769 0 0 0 0.00281905 l
+-0.565756 -0.721479 -0.566645 -0.727059 0 0 0 0.00281905 l
+0.213234 0.451835 0.215908 0.458661 0 0 0 0.00281905 l
+0.213234 0.451835 0.202507 0.449223 0 0 0 0.00281905 l
+0.124725 0.391256 0.115589 0.379409 0 0 0 0.00281905 l
+-0.20441 0.191311 -0.207109 0.195611 0 0 0 0.00281905 l
+0.242422 -0.251177 0.251124 -0.242378 0 0 0 0.00281905 l
+-0.0270269 0.132542 -0.0331869 0.148115 0 0 0 0.00281905 l
+-0.0270269 0.132542 -0.0216321 0.13088 0 0 0 0.00281905 l
+-0.0270269 0.132542 -0.0369126 0.125381 0 0 0 0.00281905 l
+0.62152 -0.210253 0.625773 -0.208136 0 0 0 0.00281905 l
+0.62152 -0.210253 0.611341 -0.219099 0 0 0 0.00281905 l
+0.60267 -0.11274 0.611676 -0.127802 0 0 0 0.00281905 l
+-0.397254 0.0477514 -0.403272 0.061426 0 0 0 0.00281905 l
+-0.397254 0.0477514 -0.389374 0.0490065 0 0 0 0.00281905 l
+-0.202629 0.355891 -0.191713 0.365204 0 0 0 0.00281905 l
+-0.202629 0.355891 -0.209467 0.350006 0 0 0 0.00281905 l
+0.25223 0.259482 0.266692 0.267853 0 0 0 0.00281905 l
+0.25223 0.259482 0.250948 0.256017 0 0 0 0.00281905 l
+-0.895469 -0.300178 -0.906177 -0.285938 0 0 0 0.00281905 l
+-0.895469 -0.300178 -0.889898 -0.296865 0 0 0 0.00281905 l
+-0.895469 -0.300178 -0.90352 -0.304944 0 0 0 0.00281905 l
+0.596814 0.630852 0.601446 0.631762 0 0 0 0.00281905 l
+0.596814 0.630852 0.596494 0.613743 0 0 0 0.00281905 l
+0.596814 0.630852 0.593399 0.630913 0 0 0 0.00281905 l
+0.314992 0.200065 0.311709 0.191077 0 0 0 0.00281905 l
+-0.651872 0.0437504 -0.657431 0.0461772 0 0 0 0.00281905 l
+-0.341145 0.380351 -0.335798 0.362651 0 0 0 0.00281905 l
+-0.341145 0.380351 -0.342521 0.390879 0 0 0 0.00281905 l
+0.636358 -0.608404 0.640641 -0.59143 0 0 0 0.00281905 l
+0.636358 -0.608404 0.640948 -0.620292 0 0 0 0.00281905 l
+-0.155542 -0.495157 -0.151187 -0.511663 0 0 0 0.00281905 l
+-0.586249 0.401812 -0.585403 0.414708 0 0 0 0.00281905 l
+-0.295968 0.906392 -0.28819 0.888932 0 0 0 0.00281905 l
+-0.295968 0.906392 -0.299896 0.917187 0 0 0 0.00281905 l
+-0.295968 0.906392 -0.303486 0.903826 0 0 0 0.00281905 l
+0.11191 -0.153831 0.122429 -0.142188 0 0 0 0.00281905 l
+0.11191 -0.153831 0.117998 -0.158719 0 0 0 0.00281905 l
+0.11191 -0.153831 0.0979584 -0.157264 0 0 0 0.00281905 l
+0.298707 0.261805 0.2969 0.273858 0 0 0 0.00281905 l
+-0.287862 0.826537 -0.286843 0.837955 0 0 0 0.00281905 l
+0.731909 -0.621841 0.740426 -0.621538 0 0 0 0.00281905 l
+0.731909 -0.621841 0.724085 -0.63314 0 0 0 0.00281905 l
+0.731909 -0.621841 0.716983 -0.618206 0 0 0 0.00281905 l
+0.88042 -0.138735 0.882553 -0.125459 0 0 0 0.00281905 l
+0.88042 -0.138735 0.881914 -0.143757 0 0 0 0.00281905 l
+-0.259887 0.799868 -0.258113 0.811522 0 0 0 0.00281905 l
+-0.259887 0.799868 -0.246513 0.800796 0 0 0 0.00281905 l
+-0.259887 0.799868 -0.266857 0.793932 0 0 0 0.00281905 l
+0.232538 -0.0355874 0.232747 -0.0302739 0 0 0 0.00281905 l
+0.232538 -0.0355874 0.246584 -0.0435224 0 0 0 0.00281905 l
+0.232538 -0.0355874 0.230377 -0.0417726 0 0 0 0.00281905 l
+0.684698 -0.052942 0.68176 -0.0664626 0 0 0 0.00281905 l
+-0.247852 -0.240696 -0.24227 -0.228311 0 0 0 0.00281905 l
+-0.247852 -0.240696 -0.240704 -0.247335 0 0 0 0.00281905 l
+0.059776 0.421073 0.0654885 0.407798 0 0 0 0.00281905 l
+0.059776 0.421073 0.068162 0.432919 0 0 0 0.00281905 l
+0.059776 0.421073 0.0565317 0.422664 0 0 0 0.00281905 l
+0.736284 0.56782 0.742707 0.555103 0 0 0 0.00281905 l
+0.736284 0.56782 0.743666 0.57619 0 0 0 0.00281905 l
+0.736284 0.56782 0.723098 0.566388 0 0 0 0.00281905 l
+-0.668873 0.0660646 -0.652512 0.0724993 0 0 0 0.00281905 l
+0.47908 -0.243948 0.47756 -0.243834 0 0 0 0.00281905 l
+0.47908 -0.243948 0.482676 -0.24214 0 0 0 0.00281905 l
+0.215666 0.756402 0.208282 0.764144 0 0 0 0.00281905 l
+0.215666 0.756402 0.217569 0.753216 0 0 0 0.00281905 l
+0.222964 -0.408546 0.231858 -0.420454 0 0 0 0.00281905 l
+0.222964 -0.408546 0.224665 -0.400439 0 0 0 0.00281905 l
+0.222964 -0.408546 0.210369 -0.42076 0 0 0 0.00281905 l
+0.400666 -0.275342 0.401122 -0.275663 0 0 0 0.00281905 l
+0.400666 -0.275342 0.394768 -0.274789 0 0 0 0.00281905 l
+-0.0320103 0.269374 -0.0311799 0.268493 0 0 0 0.00281905 l
+0.959417 -0.0520961 0.975961 -0.0728958 0 0 0 0.00281905 l
+0.959417 -0.0520961 0.959507 -0.0461685 0 0 0 0.00281905 l
+-0.0725879 -0.0436994 -0.0770816 -0.0583641 0 0 0 0.00281905 l
+-0.0725879 -0.0436994 -0.0724743 -0.0402904 0 0 0 0.00281905 l
+-0.713576 -0.125926 -0.697507 -0.126742 0 0 0 0.00281905 l
+-0.713576 -0.125926 -0.718933 -0.132526 0 0 0 0.00281905 l
+-0.475386 -0.272768 -0.46566 -0.263249 0 0 0 0.00281905 l
+-0.475386 -0.272768 -0.483274 -0.275463 0 0 0 0.00281905 l
+-0.339962 0.692083 -0.336972 0.70248 0 0 0 0.00281905 l
+-0.339962 0.692083 -0.340774 0.680304 0 0 0 0.00281905 l
+-0.167902 -0.342769 -0.164051 -0.342597 0 0 0 0.00281905 l
+0.154218 -0.770312 0.15877 -0.782437 0 0 0 0.00281905 l
+0.154218 -0.770312 0.160339 -0.756281 0 0 0 0.00281905 l
+0.154218 -0.770312 0.145216 -0.769514 0 0 0 0.00281905 l
+0.417419 0.721553 0.421521 0.709131 0 0 0 0.00281905 l
+0.417419 0.721553 0.416471 0.721495 0 0 0 0.00281905 l
+0.138038 0.450211 0.129907 0.452428 0 0 0 0.00281905 l
+0.138038 0.450211 0.140216 0.453177 0 0 0 0.00281905 l
+-0.320346 -0.0271773 -0.321556 -0.0194461 0 0 0 0.00281905 l
+-0.320346 -0.0271773 -0.309744 -0.0378772 0 0 0 0.00281905 l
+0.977248 -0.138146 0.980731 -0.148243 0 0 0 0.00281905 l
+0.977248 -0.138146 0.988307 -0.120358 0 0 0 0.00281905 l
+0.977248 -0.138146 0.959582 -0.119594 0 0 0 0.00281905 l
+-0.741142 0.1823 -0.738376 0.16698 0 0 0 0.00281905 l
+-0.741142 0.1823 -0.747446 0.188568 0 0 0 0.00281905 l
+-0.187522 -0.198287 -0.18747 -0.213936 0 0 0 0.00281905 l
+-0.187522 -0.198287 -0.175209 -0.192221 0 0 0 0.00281905 l
+0.599551 0.454121 0.593964 0.468026 0 0 0 0.00281905 l
+0.535681 -0.331069 0.533305 -0.347253 0 0 0 0.00281905 l
+0.535681 -0.331069 0.548106 -0.328914 0 0 0 0.00281905 l
+0.535681 -0.331069 0.534007 -0.329236 0 0 0 0.00281905 l
+0.515754 -0.178052 0.535772 -0.186596 0 0 0 0.00281905 l
+0.515754 -0.178052 0.513038 -0.194487 0 0 0 0.00281905 l
+0.515754 -0.178052 0.506343 -0.176612 0 0 0 0.00281905 l
+-0.62117 0.404008 -0.614253 0.415439 0 0 0 0.00281905 l
+-0.62117 0.404008 -0.62818 0.410708 0 0 0 0.00281905 l
+0.408412 -0.334929 0.408295 -0.343066 0 0 0 0.00281905 l
+0.408412 -0.334929 0.396859 -0.334295 0 0 0 0.00281905 l
+0.482188 0.349874 0.48796 0.33334 0 0 0 0.00281905 l
+0.482188 0.349874 0.464241 0.346221 0 0 0 0.00281905 l
+0.328071 -0.758685 0.326425 -0.741584 0 0 0 0.00281905 l
+0.328071 -0.758685 0.320783 -0.76126 0 0 0 0.00281905 l
+0.106614 -0.95335 0.0972237 -0.96864 0 0 0 0.00281905 l
+0.106614 -0.95335 0.113009 -0.950783 0 0 0 0.00281905 l
+-0.513811 -0.542973 -0.501041 -0.544383 0 0 0 0.00281905 l
+-0.513811 -0.542973 -0.534944 -0.531927 0 0 0 0.00281905 l
+-0.957981 -0.113868 -0.936466 -0.106454 0 0 0 0.00281905 l
+-0.957981 -0.113868 -0.97476 -0.109543 0 0 0 0.00281905 l
+-0.0752377 0.460833 -0.0711508 0.470514 0 0 0 0.00281905 l
+-0.0752377 0.460833 -0.0728485 0.453888 0 0 0 0.00281905 l
+0.661024 -0.37872 0.669386 -0.362048 0 0 0 0.00281905 l
+0.661024 -0.37872 0.659154 -0.38286 0 0 0 0.00281905 l
+-0.731198 -0.603448 -0.730765 -0.611932 0 0 0 0.00281905 l
+0.39105 0.420393 0.406068 0.415504 0 0 0 0.00281905 l
+0.39105 0.420393 0.392899 0.428666 0 0 0 0.00281905 l
+0.0464922 0.0032031 0.0530301 0.00491423 0 0 0 0.00281905 l
+0.0464922 0.0032031 0.033004 -0.00871693 0 0 0 0.00281905 l
+0.026887 -0.700259 0.0303802 -0.697064 0 0 0 0.00281905 l
+0.026887 -0.700259 0.0168384 -0.703194 0 0 0 0.00281905 l
+-0.210859 0.0489857 -0.214708 0.0692997 0 0 0 0.00281905 l
+-0.210859 0.0489857 -0.206582 0.0330684 0 0 0 0.00281905 l
+-0.210859 0.0489857 -0.228754 0.0406535 0 0 0 0.00281905 l
+0.0437595 0.436363 0.0573474 0.441591 0 0 0 0.00281905 l
+0.0437595 0.436363 0.0426121 0.438404 0 0 0 0.00281905 l
+-0.38198 -0.864002 -0.38014 -0.846584 0 0 0 0.00281905 l
+-0.38198 -0.864002 -0.375783 -0.865586 0 0 0 0.00281905 l
+0.179458 -0.286659 0.183864 -0.298683 0 0 0 0.00281905 l
+0.179458 -0.286659 0.178043 -0.278777 0 0 0 0.00281905 l
+0.224697 -0.6049 0.224441 -0.608386 0 0 0 0.00281905 l
+0.224697 -0.6049 0.219363 -0.600191 0 0 0 0.00281905 l
+-0.104171 0.178698 -0.103686 0.169704 0 0 0 0.00281905 l
+0.594298 0.389865 0.596827 0.376222 0 0 0 0.00281905 l
+0.594298 0.389865 0.58716 0.398491 0 0 0 0.00281905 l
+-0.492109 0.614196 -0.484983 0.613739 0 0 0 0.00281905 l
+-0.492109 0.614196 -0.492376 0.596604 0 0 0 0.00281905 l
+-0.365246 -0.0364193 -0.363994 -0.0365987 0 0 0 0.00281905 l
+-0.679858 -0.377469 -0.678831 -0.390101 0 0 0 0.00281905 l
+-0.679858 -0.377469 -0.673674 -0.363505 0 0 0 0.00281905 l
+-0.679858 -0.377469 -0.698387 -0.377688 0 0 0 0.00281905 l
+0.0287167 -0.412798 0.0352411 -0.41986 0 0 0 0.00281905 l
+0.0287167 -0.412798 0.0237127 -0.412763 0 0 0 0.00281905 l
+0.5297 0.401636 0.532065 0.407789 0 0 0 0.00281905 l
+0.5297 0.401636 0.535091 0.401764 0 0 0 0.00281905 l
+0.5297 0.401636 0.524778 0.402079 0 0 0 0.00281905 l
+0.00610386 -0.019118 -0.000892871 -0.014212 0 0 0 0.00281905 l
+-0.216432 -0.775313 -0.210575 -0.761346 0 0 0 0.00281905 l
+-0.216432 -0.775313 -0.214146 -0.78334 0 0 0 0.00281905 l
+-0.216432 -0.775313 -0.223879 -0.778092 0 0 0 0.00281905 l
+0.653076 0.486697 0.659141 0.482139 0 0 0 0.00281905 l
+0.653076 0.486697 0.643548 0.486488 0 0 0 0.00281905 l
+-0.219016 0.322865 -0.234327 0.310245 0 0 0 0.00281905 l
+-0.219016 0.322865 -0.210289 0.332863 0 0 0 0.00281905 l
+0.141747 -0.839473 0.128471 -0.829294 0 0 0 0.00281905 l
+0.781743 -0.532412 0.77145 -0.544199 0 0 0 0.00281905 l
+0.781743 -0.532412 0.780572 -0.529739 0 0 0 0.00281905 l
+0.648307 0.178832 0.654959 0.182825 0 0 0 0.00281905 l
+0.648307 0.178832 0.642127 0.187353 0 0 0 0.00281905 l
+0.412501 -0.426253 0.413299 -0.415955 0 0 0 0.00281905 l
+0.412501 -0.426253 0.426686 -0.424006 0 0 0 0.00281905 l
+0.412501 -0.426253 0.412073 -0.438413 0 0 0 0.00281905 l
+0.00672245 -0.733663 0.0114837 -0.727832 0 0 0 0.00281905 l
+0.727936 0.602873 0.730075 0.607005 0 0 0 0.00281905 l
+0.727936 0.602873 0.729906 0.590029 0 0 0 0.00281905 l
+0.160706 0.958272 0.151419 0.937909 0 0 0 0.00281905 l
+0.160706 0.958272 0.142111 0.970473 0 0 0 0.00281905 l
+-0.481029 -0.492327 -0.479893 -0.48795 0 0 0 0.00281905 l
+-0.481029 -0.492327 -0.484935 -0.495707 0 0 0 0.00281905 l
+0.408936 0.551292 0.418817 0.54438 0 0 0 0.00281905 l
+0.710869 0.0822651 0.714044 0.0853493 0 0 0 0.00281905 l
+0.710869 0.0822651 0.694669 0.0801293 0 0 0 0.00281905 l
+-0.0763721 -0.0732998 -0.0712478 -0.0671511 0 0 0 0.00281905 l
+-0.0890332 0.432214 -0.0892202 0.439158 0 0 0 0.00281905 l
+-0.0890332 0.432214 -0.104874 0.417639 0 0 0 0.00281905 l
+0.420206 0.638806 0.42919 0.624869 0 0 0 0.00281905 l
+0.420206 0.638806 0.434441 0.645359 0 0 0 0.00281905 l
+0.420206 0.638806 0.40843 0.633497 0 0 0 0.00281905 l
+0.420609 0.494587 0.42261 0.485865 0 0 0 0.00281905 l
+0.420609 0.494587 0.409578 0.492415 0 0 0 0.00281905 l
+0.683102 0.445595 0.698247 0.453898 0 0 0 0.00281905 l
+0.683102 0.445595 0.692742 0.432786 0 0 0 0.00281905 l
+0.683102 0.445595 0.669142 0.437545 0 0 0 0.00281905 l
+0.683102 0.445595 0.679845 0.449759 0 0 0 0.00281905 l
+0.518363 -0.463744 0.519438 -0.458422 0 0 0 0.00281905 l
+0.518363 -0.463744 0.514249 -0.468975 0 0 0 0.00281905 l
+0.508869 0.565763 0.506744 0.545489 0 0 0 0.00281905 l
+0.508869 0.565763 0.494381 0.574901 0 0 0 0.00281905 l
+-0.149146 0.910903 -0.151414 0.926282 0 0 0 0.00281905 l
+-0.149146 0.910903 -0.141104 0.913471 0 0 0 0.00281905 l
+-0.149146 0.910903 -0.16459 0.910971 0 0 0 0.00281905 l
+0.207182 -0.801335 0.207472 -0.798889 0 0 0 0.00281905 l
+0.207182 -0.801335 0.197163 -0.816542 0 0 0 0.00281905 l
+-0.566458 0.0483661 -0.55411 0.0444683 0 0 0 0.00281905 l
+-0.697266 -0.559353 -0.691909 -0.567651 0 0 0 0.00281905 l
+-0.697266 -0.559353 -0.715607 -0.548499 0 0 0 0.00281905 l
+-0.168033 0.430843 -0.157835 0.423078 0 0 0 0.00281905 l
+-0.0188177 -0.678552 -0.0278282 -0.68546 0 0 0 0.00281905 l
+-0.0188177 -0.678552 -0.0194248 -0.675801 0 0 0 0.00281905 l
+-0.272551 -0.714139 -0.26136 -0.715457 0 0 0 0.00281905 l
+-0.272551 -0.714139 -0.283034 -0.707572 0 0 0 0.00281905 l
+0.645867 -0.515698 0.649469 -0.532547 0 0 0 0.00281905 l
+0.275491 -0.249488 0.290608 -0.248222 0 0 0 0.00281905 l
+0.275491 -0.249488 0.270602 -0.239736 0 0 0 0.00281905 l
+0.0109269 0.251209 0.0114489 0.255154 0 0 0 0.00281905 l
+0.0109269 0.251209 0.0103448 0.251022 0 0 0 0.00281905 l
+-0.296361 -0.378287 -0.307416 -0.377931 0 0 0 0.00281905 l
+-0.554379 -0.741309 -0.56289 -0.758974 0 0 0 0.00281905 l
+-0.554379 -0.741309 -0.554946 -0.738092 0 0 0 0.00281905 l
+-0.208554 -0.238499 -0.203861 -0.222435 0 0 0 0.00281905 l
+-0.208554 -0.238499 -0.197342 -0.242671 0 0 0 0.00281905 l
+-0.208554 -0.238499 -0.209381 -0.242097 0 0 0 0.00281905 l
+0.33481 -0.0204293 0.342111 -0.0174184 0 0 0 0.00281905 l
+0.33481 -0.0204293 0.324221 -0.0250199 0 0 0 0.00281905 l
+-0.408832 0.753133 -0.415368 0.735076 0 0 0 0.00281905 l
+-0.408832 0.753133 -0.389394 0.751163 0 0 0 0.00281905 l
+-0.408832 0.753133 -0.412015 0.760059 0 0 0 0.00281905 l
+0.888053 -0.183183 0.891547 -0.184704 0 0 0 0.00281905 l
+0.888053 -0.183183 0.882604 -0.19464 0 0 0 0.00281905 l
+0.888053 -0.183183 0.879196 -0.174847 0 0 0 0.00281905 l
+-0.513024 0.0682619 -0.526187 0.0727476 0 0 0 0.00281905 l
+-0.212971 0.56137 -0.22559 0.545963 0 0 0 0.00281905 l
+-0.212971 0.56137 -0.211322 0.564725 0 0 0 0.00281905 l
+-0.18837 -0.152295 -0.188611 -0.139473 0 0 0 0.00281905 l
+-0.18837 -0.152295 -0.185318 -0.15818 0 0 0 0.00281905 l
+-0.587102 0.597113 -0.585223 0.596996 0 0 0 0.00281905 l
+-0.587102 0.597113 -0.605993 0.600186 0 0 0 0.00281905 l
+-0.0724743 -0.0402904 -0.0660427 -0.0381245 0 0 0 0.00281905 l
+-0.0724743 -0.0402904 -0.0725879 -0.0436994 0 0 0 0.00281905 l
+-0.507202 0.576196 -0.503052 0.583028 0 0 0 0.00281905 l
+-0.507202 0.576196 -0.513452 0.56729 0 0 0 0.00281905 l
+-0.507202 0.576196 -0.514045 0.58385 0 0 0 0.00281905 l
+0.0543819 0.868287 0.0572939 0.872737 0 0 0 0.00281905 l
+0.0543819 0.868287 0.0325596 0.861852 0 0 0 0.00281905 l
+0.107177 0.340292 0.0984295 0.334889 0 0 0 0.00281905 l
+0.064028 0.50754 0.0604677 0.516892 0 0 0 0.00281905 l
+0.064028 0.50754 0.0588895 0.503464 0 0 0 0.00281905 l
+-0.286404 0.211189 -0.287869 0.229922 0 0 0 0.00281905 l
+-0.286404 0.211189 -0.274738 0.214206 0 0 0 0.00281905 l
+-0.286404 0.211189 -0.298174 0.21014 0 0 0 0.00281905 l
+0.246584 -0.0435224 0.232538 -0.0355874 0 0 0 0.00281905 l
+0.696371 -0.316729 0.69908 -0.305671 0 0 0 0.00281905 l
+0.696371 -0.316729 0.714817 -0.321722 0 0 0 0.00281905 l
+0.696371 -0.316729 0.695342 -0.322766 0 0 0 0.00281905 l
+0.285731 0.934929 0.296814 0.91948 0 0 0 0.00281905 l
+0.285731 0.934929 0.28719 0.944167 0 0 0 0.00281905 l
+-0.324399 0.608362 -0.309393 0.616341 0 0 0 0.00281905 l
+-0.0178889 0.985 -0.00246756 0.970526 0 0 0 0.00281905 l
+-0.0178889 0.985 -0.0300682 0.991597 0 0 0 0.00281905 l
+-0.125886 -0.836091 -0.116915 -0.840728 0 0 0 0.00281905 l
+-0.521897 -0.258983 -0.516419 -0.258015 0 0 0 0.00281905 l
+-0.521897 -0.258983 -0.537074 -0.266389 0 0 0 0.00281905 l
+-0.731631 -0.0867363 -0.728379 -0.0701402 0 0 0 0.00281905 l
+-0.731631 -0.0867363 -0.72219 -0.0990526 0 0 0 0.00281905 l
+0.50386 -0.839542 0.5171 -0.841132 0 0 0 0.00281905 l
+0.50386 -0.839542 0.495731 -0.830107 0 0 0 0.00281905 l
+0.396502 0.514992 0.388542 0.496189 0 0 0 0.00281905 l
+-0.192509 -0.0216451 -0.193718 -0.0314281 0 0 0 0.00281905 l
+-0.192509 -0.0216451 -0.185794 -0.00925174 0 0 0 0.00281905 l
+0.862767 0.0324139 0.87319 0.0267613 0 0 0 0.00281905 l
+0.862767 0.0324139 0.851114 0.0335093 0 0 0 0.00281905 l
+0.921749 0.179337 0.929042 0.186443 0 0 0 0.00281905 l
+0.921749 0.179337 0.910381 0.173732 0 0 0 0.00281905 l
+-0.524107 0.275957 -0.514077 0.276042 0 0 0 0.00281905 l
+-0.524107 0.275957 -0.537166 0.268566 0 0 0 0.00281905 l
+-0.560174 -0.362305 -0.562325 -0.349989 0 0 0 0.00281905 l
+-0.560174 -0.362305 -0.548852 -0.365921 0 0 0 0.00281905 l
+-0.560174 -0.362305 -0.570562 -0.377246 0 0 0 0.00281905 l
+-0.617563 -0.563437 -0.616718 -0.554948 0 0 0 0.00281905 l
+-0.617563 -0.563437 -0.634637 -0.560724 0 0 0 0.00281905 l
+0.158087 0.587024 0.16686 0.592074 0 0 0 0.00281905 l
+0.158087 0.587024 0.142353 0.578087 0 0 0 0.00281905 l
+0.600608 0.168744 0.602944 0.168561 0 0 0 0.00281905 l
+0.600608 0.168744 0.601043 0.162637 0 0 0 0.00281905 l
+0.600608 0.168744 0.586557 0.16771 0 0 0 0.00281905 l
+0.150715 0.192188 0.161886 0.194542 0 0 0 0.00281905 l
+0.150715 0.192188 0.147632 0.190437 0 0 0 0.00281905 l
+0.928129 0.124578 0.947818 0.125689 0 0 0 0.00281905 l
+0.928129 0.124578 0.922427 0.137022 0 0 0 0.00281905 l
+0.928129 0.124578 0.923665 0.117033 0 0 0 0.00281905 l
+0.502418 0.414217 0.502152 0.423863 0 0 0 0.00281905 l
+0.0306926 0.717781 0.0383029 0.728525 0 0 0 0.00281905 l
+0.0306926 0.717781 0.025778 0.717487 0 0 0 0.00281905 l
+0.723266 0.272772 0.725049 0.28301 0 0 0 0.00281905 l
+0.723266 0.272772 0.725783 0.268143 0 0 0 0.00281905 l
+0.510031 0.396041 0.520858 0.397139 0 0 0 0.00281905 l
+0.510031 0.396041 0.504802 0.386286 0 0 0 0.00281905 l
+0.339295 0.231306 0.351313 0.220088 0 0 0 0.00281905 l
+0.339295 0.231306 0.348322 0.241077 0 0 0 0.00281905 l
+0.339295 0.231306 0.32594 0.223701 0 0 0 0.00281905 l
+-0.274463 0.925292 -0.267796 0.930518 0 0 0 0.00281905 l
+-0.274463 0.925292 -0.277429 0.928931 0 0 0 0.00281905 l
+0.344487 0.696933 0.348435 0.715339 0 0 0 0.00281905 l
+0.344487 0.696933 0.354162 0.691544 0 0 0 0.00281905 l
+0.344487 0.696933 0.325535 0.691825 0 0 0 0.00281905 l
+0.109779 -0.293058 0.117763 -0.304226 0 0 0 0.00281905 l
+0.109779 -0.293058 0.0970203 -0.30283 0 0 0 0.00281905 l
+0.109779 -0.293058 0.0971216 -0.283504 0 0 0 0.00281905 l
+0.234958 0.533418 0.235547 0.54036 0 0 0 0.00281905 l
+0.234958 0.533418 0.242945 0.534337 0 0 0 0.00281905 l
+0.234958 0.533418 0.222767 0.521116 0 0 0 0.00281905 l
+-0.032921 -0.17657 -0.0390996 -0.165077 0 0 0 0.00281905 l
+-0.032921 -0.17657 -0.0494214 -0.179308 0 0 0 0.00281905 l
+0.120412 -0.201425 0.122978 -0.193479 0 0 0 0.00281905 l
+0.120412 -0.201425 0.114121 -0.204832 0 0 0 0.00281905 l
+0.0832575 0.326865 0.0816094 0.338024 0 0 0 0.00281905 l
+0.0832575 0.326865 0.0728576 0.319594 0 0 0 0.00281905 l
+0.634276 -0.0121349 0.641023 -0.0101347 0 0 0 0.00281905 l
+0.634276 -0.0121349 0.626875 -0.0276707 0 0 0 0.00281905 l
+-0.893278 0.00840169 -0.899626 0.0235354 0 0 0 0.00281905 l
+-0.893278 0.00840169 -0.885207 0.00988652 0 0 0 0.00281905 l
+-0.893278 0.00840169 -0.894943 -0.00108552 0 0 0 0.00281905 l
+0.439087 -0.291367 0.43207 -0.301807 0 0 0 0.00281905 l
+0.529609 -0.147317 0.532923 -0.139301 0 0 0 0.00281905 l
+0.529609 -0.147317 0.525241 -0.15037 0 0 0 0.00281905 l
+-0.150038 0.474274 -0.152452 0.45461 0 0 0 0.00281905 l
+-0.152845 -0.15105 -0.148975 -0.142673 0 0 0 0.00281905 l
+-0.152845 -0.15105 -0.158204 -0.153139 0 0 0 0.00281905 l
+-0.247887 -0.922799 -0.244503 -0.925519 0 0 0 0.00281905 l
+-0.247887 -0.922799 -0.249537 -0.919289 0 0 0 0.00281905 l
+-0.433789 -0.786807 -0.432935 -0.781156 0 0 0 0.00281905 l
+-0.433789 -0.786807 -0.455557 -0.789424 0 0 0 0.00281905 l
+-0.954453 0.0228362 -0.944985 0.0307441 0 0 0 0.00281905 l
+-0.954453 0.0228362 -0.965191 0.019838 0 0 0 0.00281905 l
+-0.153893 0.764626 -0.155611 0.7722 0 0 0 0.00281905 l
+-0.153893 0.764626 -0.135291 0.7704 0 0 0 0.00281905 l
+-0.153893 0.764626 -0.1561 0.746205 0 0 0 0.00281905 l
+-0.480965 -0.594683 -0.490438 -0.58716 0 0 0 0.00281905 l
+-0.480965 -0.594683 -0.466824 -0.583267 0 0 0 0.00281905 l
+0.113223 0.314989 0.114991 0.321222 0 0 0 0.00281905 l
+0.113223 0.314989 0.125309 0.308363 0 0 0 0.00281905 l
+0.113223 0.314989 0.105282 0.309599 0 0 0 0.00281905 l
+0.681641 0.369879 0.679107 0.372247 0 0 0 0.00281905 l
+0.140306 -0.0757422 0.137592 -0.0669224 0 0 0 0.00281905 l
+0.140306 -0.0757422 0.143944 -0.0799475 0 0 0 0.00281905 l
+0.0722856 0.784959 0.0728629 0.797144 0 0 0 0.00281905 l
+0.0722856 0.784959 0.0811614 0.783952 0 0 0 0.00281905 l
+-0.34242 0.332796 -0.325285 0.338269 0 0 0 0.00281905 l
+-0.34242 0.332796 -0.351061 0.350871 0 0 0 0.00281905 l
+-0.34242 0.332796 -0.357973 0.326126 0 0 0 0.00281905 l
+0.19198 0.232645 0.194479 0.220464 0 0 0 0.00281905 l
+0.19198 0.232645 0.178398 0.229837 0 0 0 0.00281905 l
+0.129635 -0.239677 0.135331 -0.237195 0 0 0 0.00281905 l
+-0.535316 -0.637018 -0.548998 -0.624274 0 0 0 0.00281905 l
+-0.535316 -0.637018 -0.524123 -0.641862 0 0 0 0.00281905 l
+-0.535316 -0.637018 -0.542537 -0.647118 0 0 0 0.00281905 l
+-0.791297 -0.349648 -0.784377 -0.333521 0 0 0 0.00281905 l
+-0.791297 -0.349648 -0.786273 -0.352667 0 0 0 0.00281905 l
+-0.791297 -0.349648 -0.796663 -0.350522 0 0 0 0.00281905 l
+-0.62818 0.410708 -0.62117 0.404008 0 0 0 0.00281905 l
+-0.62818 0.410708 -0.63172 0.400716 0 0 0 0.00281905 l
+-0.62818 0.410708 -0.641166 0.414921 0 0 0 0.00281905 l
+0.189765 0.832063 0.204418 0.832115 0 0 0 0.00281905 l
+0.189765 0.832063 0.193553 0.816553 0 0 0 0.00281905 l
+0.189765 0.832063 0.172151 0.837416 0 0 0 0.00281905 l
+0.568179 -0.53132 0.588412 -0.53752 0 0 0 0.00281905 l
+0.568179 -0.53132 0.560625 -0.541823 0 0 0 0.00281905 l
+-0.399598 -0.0370971 -0.403883 -0.0247595 0 0 0 0.00281905 l
+-0.399598 -0.0370971 -0.385842 -0.0338155 0 0 0 0.00281905 l
+-0.399598 -0.0370971 -0.400799 -0.0418487 0 0 0 0.00281905 l
+-0.481578 0.503134 -0.487982 0.50336 0 0 0 0.00281905 l
+0.279965 -0.125 0.295544 -0.116926 0 0 0 0.00281905 l
+0.279965 -0.125 0.276701 -0.129331 0 0 0 0.00281905 l
+-0.207325 0.711782 -0.183539 0.713358 0 0 0 0.00281905 l
+-0.207325 0.711782 -0.209961 0.715761 0 0 0 0.00281905 l
+0.147938 -0.605466 0.146315 -0.585289 0 0 0 0.00281905 l
+0.147938 -0.605466 0.138675 -0.611083 0 0 0 0.00281905 l
+-0.185429 0.871619 -0.192245 0.853843 0 0 0 0.00281905 l
+-0.185429 0.871619 -0.190485 0.885841 0 0 0 0.00281905 l
+0.215908 0.458661 0.223311 0.453686 0 0 0 0.00281905 l
+0.215908 0.458661 0.215932 0.475674 0 0 0 0.00281905 l
+0.215908 0.458661 0.213234 0.451835 0 0 0 0.00281905 l
+0.15019 0.64532 0.162638 0.648375 0 0 0 0.00281905 l
+0.15019 0.64532 0.146919 0.649459 0 0 0 0.00281905 l
+-0.00825396 -0.349622 -0.00100853 -0.358107 0 0 0 0.00281905 l
+-0.00825396 -0.349622 -0.0222405 -0.340454 0 0 0 0.00281905 l
+0.976819 0.0281726 0.981623 0.0303927 0 0 0 0.00281905 l
+0.976819 0.0281726 0.980622 0.0250043 0 0 0 0.00281905 l
+-0.0708782 0.0501204 -0.0760536 0.0594207 0 0 0 0.00281905 l
+-0.0708782 0.0501204 -0.0586317 0.0550902 0 0 0 0.00281905 l
+0.67232 -0.159013 0.667325 -0.149863 0 0 0 0.00281905 l
+0.67232 -0.159013 0.663086 -0.163838 0 0 0 0.00281905 l
+-0.421641 -0.879484 -0.405356 -0.873188 0 0 0 0.00281905 l
+-0.421641 -0.879484 -0.42977 -0.877337 0 0 0 0.00281905 l
+-0.0720977 0.409534 -0.062805 0.414003 0 0 0 0.00281905 l
+-0.0720977 0.409534 -0.0777067 0.408927 0 0 0 0.00281905 l
+-0.471891 -0.0322007 -0.464658 -0.0316159 0 0 0 0.00281905 l
+-0.401074 -0.619475 -0.416013 -0.608472 0 0 0 0.00281905 l
+0.486157 -0.585138 0.481329 -0.598714 0 0 0 0.00281905 l
+-0.44341 0.090064 -0.441834 0.0846763 0 0 0 0.00281905 l
+-0.44341 0.090064 -0.447707 0.0927907 0 0 0 0.00281905 l
+-0.537074 -0.266389 -0.521897 -0.258983 0 0 0 0.00281905 l
+-0.537074 -0.266389 -0.539033 -0.284288 0 0 0 0.00281905 l
+-0.537074 -0.266389 -0.551642 -0.255386 0 0 0 0.00281905 l
+-0.0607823 -0.589126 -0.0551462 -0.588721 0 0 0 0.00281905 l
+-0.0607823 -0.589126 -0.0704537 -0.606966 0 0 0 0.00281905 l
+-0.192783 -0.32799 -0.199055 -0.312533 0 0 0 0.00281905 l
+-0.192783 -0.32799 -0.185387 -0.333471 0 0 0 0.00281905 l
+-0.192783 -0.32799 -0.201991 -0.334177 0 0 0 0.00281905 l
+0.161423 -0.000510583 0.163962 -0.00261265 0 0 0 0.00281905 l
+0.161423 -0.000510583 0.153521 0.00169971 0 0 0 0.00281905 l
+-0.605813 -0.340133 -0.616901 -0.357797 0 0 0 0.00281905 l
+-0.605813 -0.340133 -0.60068 -0.343051 0 0 0 0.00281905 l
+-0.605813 -0.340133 -0.603358 -0.335057 0 0 0 0.00281905 l
+-0.981093 -0.00869599 -0.991399 0.00388385 0 0 0 0.00281905 l
+-0.981093 -0.00869599 -0.976324 -0.00284653 0 0 0 0.00281905 l
+-0.981093 -0.00869599 -0.98766 -0.0139746 0 0 0 0.00281905 l
+-0.119843 -0.702764 -0.127922 -0.700776 0 0 0 0.00281905 l
+-0.690216 0.277887 -0.674189 0.281518 0 0 0 0.00281905 l
+0.484806 0.478211 0.500749 0.470675 0 0 0 0.00281905 l
+0.418817 0.54438 0.420509 0.537894 0 0 0 0.00281905 l
+0.418817 0.54438 0.408936 0.551292 0 0 0 0.00281905 l
+-0.410859 0.310004 -0.390298 0.303187 0 0 0 0.00281905 l
+-0.410859 0.310004 -0.416046 0.319593 0 0 0 0.00281905 l
+0.42919 0.624869 0.433054 0.614152 0 0 0 0.00281905 l
+0.42919 0.624869 0.420206 0.638806 0 0 0 0.00281905 l
+-0.5104 0.0955515 -0.502375 0.091121 0 0 0 0.00281905 l
+-0.5104 0.0955515 -0.511312 0.103497 0 0 0 0.00281905 l
+-0.431131 -0.882019 -0.42977 -0.877337 0 0 0 0.00281905 l
+-0.431131 -0.882019 -0.445413 -0.881537 0 0 0 0.00281905 l
+0.418485 0.51891 0.437038 0.511337 0 0 0 0.00281905 l
+0.418485 0.51891 0.411861 0.53074 0 0 0 0.00281905 l
+0.136388 0.260537 0.132418 0.268952 0 0 0 0.00281905 l
+-0.71334 -0.17131 -0.705349 -0.169847 0 0 0 0.00281905 l
+-0.71334 -0.17131 -0.707779 -0.187535 0 0 0 0.00281905 l
+-0.71334 -0.17131 -0.727751 -0.184077 0 0 0 0.00281905 l
+0.865915 -0.118293 0.865205 -0.125953 0 0 0 0.00281905 l
+0.865915 -0.118293 0.865356 -0.117963 0 0 0 0.00281905 l
+0.895049 0.370642 0.894143 0.377623 0 0 0 0.00281905 l
+0.895049 0.370642 0.897424 0.367471 0 0 0 0.00281905 l
+0.895049 0.370642 0.88256 0.368883 0 0 0 0.00281905 l
+-0.353603 -0.475063 -0.341193 -0.481314 0 0 0 0.00281905 l
+-0.353603 -0.475063 -0.357865 -0.470833 0 0 0 0.00281905 l
+-0.564297 0.641201 -0.55832 0.641174 0 0 0 0.00281905 l
+-0.564297 0.641201 -0.56582 0.631636 0 0 0 0.00281905 l
+-0.564297 0.641201 -0.571486 0.645211 0 0 0 0.00281905 l
+0.390569 0.35999 0.377206 0.359339 0 0 0 0.00281905 l
+0.273 -0.806206 0.272856 -0.798442 0 0 0 0.00281905 l
+0.273 -0.806206 0.282011 -0.811365 0 0 0 0.00281905 l
+0.273 -0.806206 0.254938 -0.802915 0 0 0 0.00281905 l
+-0.497769 -0.634975 -0.485941 -0.636158 0 0 0 0.00281905 l
+-0.497769 -0.634975 -0.510249 -0.641163 0 0 0 0.00281905 l
+-0.382679 0.166688 -0.374461 0.153265 0 0 0 0.00281905 l
+-0.382679 0.166688 -0.392214 0.173111 0 0 0 0.00281905 l
+-0.358574 0.00853546 -0.360587 -0.00117533 0 0 0 0.00281905 l
+-0.358574 0.00853546 -0.359981 0.0187121 0 0 0 0.00281905 l
+0.355596 0.816879 0.355585 0.806148 0 0 0 0.00281905 l
+-0.637965 -0.593206 -0.634614 -0.598403 0 0 0 0.00281905 l
+0.274304 0.80929 0.267907 0.819675 0 0 0 0.00281905 l
+0.274304 0.80929 0.278122 0.80868 0 0 0 0.00281905 l
+0.0846135 -0.238621 0.0875798 -0.229611 0 0 0 0.00281905 l
+-0.774617 0.17908 -0.767132 0.168813 0 0 0 0.00281905 l
+-0.774617 0.17908 -0.785913 0.186794 0 0 0 0.00281905 l
+0.154959 0.176355 0.147632 0.190437 0 0 0 0.00281905 l
+-0.00134603 0.455033 -0.0127046 0.449114 0 0 0 0.00281905 l
+-0.747825 0.191689 -0.74407 0.194201 0 0 0 0.00281905 l
+-0.747825 0.191689 -0.747446 0.188568 0 0 0 0.00281905 l
+-0.425537 -0.784618 -0.422474 -0.772689 0 0 0 0.00281905 l
+-0.425537 -0.784618 -0.416487 -0.787284 0 0 0 0.00281905 l
+-0.425537 -0.784618 -0.432935 -0.781156 0 0 0 0.00281905 l
+0.0475204 -0.380985 0.0465905 -0.397044 0 0 0 0.00281905 l
+0.0475204 -0.380985 0.0454713 -0.380247 0 0 0 0.00281905 l
+0.38145 -0.536894 0.399741 -0.536612 0 0 0 0.00281905 l
+0.38145 -0.536894 0.378708 -0.531241 0 0 0 0.00281905 l
+-0.168457 0.133617 -0.166782 0.141561 0 0 0 0.00281905 l
+-0.168457 0.133617 -0.188007 0.135616 0 0 0 0.00281905 l
+0.00173541 0.735806 0.000430739 0.726857 0 0 0 0.00281905 l
+0.00173541 0.735806 0.000549871 0.748572 0 0 0 0.00281905 l
+0.401774 -0.848925 0.398782 -0.827548 0 0 0 0.00281905 l
+0.401774 -0.848925 0.409956 -0.851674 0 0 0 0.00281905 l
+0.400765 -0.454313 0.406171 -0.442588 0 0 0 0.00281905 l
+0.400765 -0.454313 0.397048 -0.456328 0 0 0 0.00281905 l
+0.238759 0.547497 0.239824 0.555415 0 0 0 0.00281905 l
+0.238759 0.547497 0.235547 0.54036 0 0 0 0.00281905 l
+-0.434145 0.0266292 -0.439904 0.0280359 0 0 0 0.00281905 l
+0.407554 0.469572 0.411369 0.475968 0 0 0 0.00281905 l
+0.407554 0.469572 0.403751 0.462313 0 0 0 0.00281905 l
+0.714321 -0.117539 0.713076 -0.12764 0 0 0 0.00281905 l
+0.714321 -0.117539 0.728681 -0.105425 0 0 0 0.00281905 l
+0.714321 -0.117539 0.695985 -0.109827 0 0 0 0.00281905 l
+-0.200835 -0.754636 -0.186073 -0.755861 0 0 0 0.00281905 l
+-0.200835 -0.754636 -0.210575 -0.761346 0 0 0 0.00281905 l
+0.0973117 0.377078 0.109132 0.386105 0 0 0 0.00281905 l
+0.0973117 0.377078 0.091636 0.373105 0 0 0 0.00281905 l
+-0.0766167 0.511444 -0.0620178 0.514304 0 0 0 0.00281905 l
+-0.0766167 0.511444 -0.0901915 0.505453 0 0 0 0.00281905 l
+0.471366 -0.64455 0.468372 -0.636661 0 0 0 0.00281905 l
+0.242945 0.534337 0.24087 0.520442 0 0 0 0.00281905 l
+0.242945 0.534337 0.234958 0.533418 0 0 0 0.00281905 l
+0.24714 0.401271 0.256964 0.414008 0 0 0 0.00281905 l
+0.24714 0.401271 0.251837 0.396132 0 0 0 0.00281905 l
+0.24714 0.401271 0.238565 0.393327 0 0 0 0.00281905 l
+0.25505 0.119646 0.255564 0.113117 0 0 0 0.00281905 l
+0.25505 0.119646 0.263132 0.124343 0 0 0 0.00281905 l
+0.25505 0.119646 0.2515 0.122243 0 0 0 0.00281905 l
+0.295555 0.210707 0.301107 0.192944 0 0 0 0.00281905 l
+0.295555 0.210707 0.301517 0.219778 0 0 0 0.00281905 l
+0.295555 0.210707 0.28329 0.214294 0 0 0 0.00281905 l
+-0.228518 0.00301098 -0.225822 0.00773785 0 0 0 0.00281905 l
+-0.228518 0.00301098 -0.239024 0.00976958 0 0 0 0.00281905 l
+-0.46137 -0.183794 -0.456557 -0.184366 0 0 0 0.00281905 l
+-0.46137 -0.183794 -0.465214 -0.200721 0 0 0 0.00281905 l
+-0.46137 -0.183794 -0.475633 -0.183865 0 0 0 0.00281905 l
+-0.737182 0.00253006 -0.731026 0.0131338 0 0 0 0.00281905 l
+-0.737182 0.00253006 -0.726458 -0.00793686 0 0 0 0.00281905 l
+-0.219244 0.2327 -0.205153 0.251317 0 0 0 0.00281905 l
+-0.219244 0.2327 -0.230335 0.237322 0 0 0 0.00281905 l
+0.197862 0.565314 0.2013 0.544452 0 0 0 0.00281905 l
+-0.172942 0.329416 -0.168049 0.341518 0 0 0 0.00281905 l
+-0.172942 0.329416 -0.179255 0.322144 0 0 0 0.00281905 l
+-0.660292 0.0918183 -0.65101 0.0908986 0 0 0 0.00281905 l
+-0.660292 0.0918183 -0.662675 0.0858618 0 0 0 0.00281905 l
+-0.678578 -0.589335 -0.678277 -0.592325 0 0 0 0.00281905 l
+-0.678578 -0.589335 -0.662789 -0.581957 0 0 0 0.00281905 l
+-0.678578 -0.589335 -0.680662 -0.589476 0 0 0 0.00281905 l
+-0.257138 0.614416 -0.243632 0.630976 0 0 0 0.00281905 l
+-0.257138 0.614416 -0.24861 0.608091 0 0 0 0.00281905 l
+-0.0816311 0.400133 -0.0689616 0.395774 0 0 0 0.00281905 l
+-0.0816311 0.400133 -0.0777067 0.408927 0 0 0 0.00281905 l
+-0.0816311 0.400133 -0.0853398 0.397337 0 0 0 0.00281905 l
+0.359047 0.344191 0.359205 0.340136 0 0 0 0.00281905 l
+0.359047 0.344191 0.353828 0.343307 0 0 0 0.00281905 l
+0.531481 -0.29751 0.520495 -0.276373 0 0 0 0.00281905 l
+0.531481 -0.29751 0.538235 -0.301711 0 0 0 0.00281905 l
+-0.409234 0.623312 -0.415853 0.636459 0 0 0 0.00281905 l
+-0.409234 0.623312 -0.40721 0.622151 0 0 0 0.00281905 l
+-0.409234 0.623312 -0.421132 0.621589 0 0 0 0.00281905 l
+-0.742815 -0.42219 -0.734186 -0.427437 0 0 0 0.00281905 l
+-0.742815 -0.42219 -0.760096 -0.409658 0 0 0 0.00281905 l
+0.485224 -0.112322 0.483255 -0.0982571 0 0 0 0.00281905 l
+0.485224 -0.112322 0.480446 -0.120821 0 0 0 0.00281905 l
+-0.561845 -0.630275 -0.564224 -0.621774 0 0 0 0.00281905 l
+-0.561845 -0.630275 -0.562795 -0.631207 0 0 0 0.00281905 l
+0.448406 -0.466242 0.458926 -0.471826 0 0 0 0.00281905 l
+0.448406 -0.466242 0.444169 -0.479887 0 0 0 0.00281905 l
+0.448406 -0.466242 0.439044 -0.465089 0 0 0 0.00281905 l
+-0.734224 0.107655 -0.73385 0.115349 0 0 0 0.00281905 l
+-0.734224 0.107655 -0.741436 0.107645 0 0 0 0.00281905 l
+0.0253106 0.739951 0.0363339 0.730477 0 0 0 0.00281905 l
+0.418329 -0.776123 0.413123 -0.793556 0 0 0 0.00281905 l
+0.418329 -0.776123 0.41135 -0.758625 0 0 0 0.00281905 l
+0.921102 0.319728 0.939788 0.320068 0 0 0 0.00281905 l
+0.921102 0.319728 0.913129 0.325407 0 0 0 0.00281905 l
+0.930528 -0.352185 0.941938 -0.331138 0 0 0 0.00281905 l
+0.930528 -0.352185 0.919033 -0.351044 0 0 0 0.00281905 l
+0.261604 -0.345791 0.265619 -0.35874 0 0 0 0.00281905 l
+0.261604 -0.345791 0.266729 -0.343796 0 0 0 0.00281905 l
+0.261604 -0.345791 0.249877 -0.335489 0 0 0 0.00281905 l
+-0.899626 0.0235354 -0.893278 0.00840169 0 0 0 0.00281905 l
+-0.899626 0.0235354 -0.911963 0.0127607 0 0 0 0.00281905 l
+0.147297 0.806542 0.166973 0.811501 0 0 0 0.00281905 l
+0.147297 0.806542 0.146918 0.80329 0 0 0 0.00281905 l
+-0.356289 0.546202 -0.363512 0.54092 0 0 0 0.00281905 l
+-0.309314 0.123802 -0.304256 0.133978 0 0 0 0.00281905 l
+-0.309314 0.123802 -0.303122 0.115551 0 0 0 0.00281905 l
+0.414591 0.783417 0.423628 0.781456 0 0 0 0.00281905 l
+0.414591 0.783417 0.410191 0.764462 0 0 0 0.00281905 l
+0.933112 -0.160806 0.944823 -0.164494 0 0 0 0.00281905 l
+0.933112 -0.160806 0.936474 -0.15145 0 0 0 0.00281905 l
+-0.677682 -0.393258 -0.676879 -0.404281 0 0 0 0.00281905 l
+-0.677682 -0.393258 -0.678831 -0.390101 0 0 0 0.00281905 l
+0.952981 0.261884 0.941022 0.271461 0 0 0 0.00281905 l
+-0.822444 -0.376625 -0.81965 -0.39331 0 0 0 0.00281905 l
+0.929042 0.186443 0.920365 0.203823 0 0 0 0.00281905 l
+0.929042 0.186443 0.939441 0.186441 0 0 0 0.00281905 l
+0.929042 0.186443 0.921749 0.179337 0 0 0 0.00281905 l
+-0.560918 0.746387 -0.552534 0.726928 0 0 0 0.00281905 l
+-0.560918 0.746387 -0.56261 0.757775 0 0 0 0.00281905 l
+-0.560918 0.746387 -0.570906 0.746253 0 0 0 0.00281905 l
+0.242706 0.564914 0.248608 0.579864 0 0 0 0.00281905 l
+0.242706 0.564914 0.239824 0.555415 0 0 0 0.00281905 l
+-0.560916 0.282578 -0.554853 0.269423 0 0 0 0.00281905 l
+-0.560916 0.282578 -0.555616 0.286031 0 0 0 0.00281905 l
+-0.560916 0.282578 -0.581128 0.284022 0 0 0 0.00281905 l
+0.537669 0.485628 0.544426 0.47173 0 0 0 0.00281905 l
+0.537669 0.485628 0.551623 0.501886 0 0 0 0.00281905 l
+0.803908 -0.421936 0.809348 -0.423396 0 0 0 0.00281905 l
+0.803908 -0.421936 0.802546 -0.418406 0 0 0 0.00281905 l
+-0.469679 0.237555 -0.469971 0.244123 0 0 0 0.00281905 l
+-0.469679 0.237555 -0.46323 0.235681 0 0 0 0.00281905 l
+-0.469679 0.237555 -0.478139 0.235726 0 0 0 0.00281905 l
+-0.233425 0.453717 -0.222739 0.466137 0 0 0 0.00281905 l
+-0.233425 0.453717 -0.239069 0.449006 0 0 0 0.00281905 l
+-0.449711 -0.622759 -0.446524 -0.618343 0 0 0 0.00281905 l
+-0.449711 -0.622759 -0.452665 -0.618624 0 0 0 0.00281905 l
+-0.449711 -0.622759 -0.45147 -0.624343 0 0 0 0.00281905 l
+-0.210575 -0.761346 -0.216432 -0.775313 0 0 0 0.00281905 l
+-0.210575 -0.761346 -0.200835 -0.754636 0 0 0 0.00281905 l
+-0.0598151 -0.133768 -0.0681322 -0.117907 0 0 0 0.00281905 l
+-0.0598151 -0.133768 -0.0426622 -0.131553 0 0 0 0.00281905 l
+-0.0598151 -0.133768 -0.0505844 -0.146945 0 0 0 0.00281905 l
+-0.953449 -0.264674 -0.948049 -0.251778 0 0 0 0.00281905 l
+-0.953449 -0.264674 -0.950324 -0.266479 0 0 0 0.00281905 l
+-0.953449 -0.264674 -0.960749 -0.261062 0 0 0 0.00281905 l
+-0.0675933 0.419112 -0.062805 0.414003 0 0 0 0.00281905 l
+-0.0675933 0.419112 -0.0729418 0.422132 0 0 0 0.00281905 l
+-0.933208 -0.241256 -0.938061 -0.234869 0 0 0 0.00281905 l
+-0.933208 -0.241256 -0.939689 -0.244745 0 0 0 0.00281905 l
+-0.42033 0.364014 -0.418306 0.347183 0 0 0 0.00281905 l
+-0.42033 0.364014 -0.420571 0.366819 0 0 0 0.00281905 l
+-0.42033 0.364014 -0.429868 0.361135 0 0 0 0.00281905 l
+-0.377168 -0.556729 -0.36738 -0.546704 0 0 0 0.00281905 l
+-0.377168 -0.556729 -0.358505 -0.567961 0 0 0 0.00281905 l
+-0.377168 -0.556729 -0.380007 -0.554957 0 0 0 0.00281905 l
+0.813251 0.151959 0.816722 0.139001 0 0 0 0.00281905 l
+0.813251 0.151959 0.821163 0.155555 0 0 0 0.00281905 l
+0.813251 0.151959 0.798274 0.14474 0 0 0 0.00281905 l
+0.714095 -0.368501 0.729012 -0.374956 0 0 0 0.00281905 l
+0.714095 -0.368501 0.697976 -0.359357 0 0 0 0.00281905 l
+0.714095 -0.368501 0.707581 -0.377794 0 0 0 0.00281905 l
+0.559422 -0.555839 0.55339 -0.553772 0 0 0 0.00281905 l
+0.559422 -0.555839 0.56387 -0.5582 0 0 0 0.00281905 l
+-0.552623 -0.138977 -0.550448 -0.137919 0 0 0 0.00281905 l
+-0.552623 -0.138977 -0.563199 -0.143348 0 0 0 0.00281905 l
+0.463381 -0.317907 0.474383 -0.305495 0 0 0 0.00281905 l
+0.463381 -0.317907 0.463098 -0.32421 0 0 0 0.00281905 l
+0.463381 -0.317907 0.450188 -0.314985 0 0 0 0.00281905 l
+0.76173 0.423666 0.764135 0.40848 0 0 0 0.00281905 l
+0.76173 0.423666 0.747392 0.416905 0 0 0 0.00281905 l
+-0.315215 0.764588 -0.305835 0.791328 0 0 0 0.00281905 l
+-0.315215 0.764588 -0.316 0.763805 0 0 0 0.00281905 l
+0.210519 0.74965 0.217569 0.753216 0 0 0 0.00281905 l
+0.210519 0.74965 0.209813 0.748896 0 0 0 0.00281905 l
+0.0179683 -0.281144 0.0228254 -0.297953 0 0 0 0.00281905 l
+0.0179683 -0.281144 0.0182091 -0.276157 0 0 0 0.00281905 l
+0.853608 0.119333 0.848908 0.107126 0 0 0 0.00281905 l
+0.853608 0.119333 0.859485 0.121724 0 0 0 0.00281905 l
+0.181076 -0.43013 0.186391 -0.443552 0 0 0 0.00281905 l
+0.181076 -0.43013 0.177317 -0.423114 0 0 0 0.00281905 l
+0.720031 0.0686332 0.721541 0.083414 0 0 0 0.00281905 l
+-0.609664 -0.221576 -0.59182 -0.230628 0 0 0 0.00281905 l
+-0.609664 -0.221576 -0.60919 -0.20581 0 0 0 0.00281905 l
+0.301388 0.745362 0.301316 0.753025 0 0 0 0.00281905 l
+-0.801219 0.302154 -0.786604 0.312412 0 0 0 0.00281905 l
+0.449493 -0.760352 0.441324 -0.743464 0 0 0 0.00281905 l
+0.449493 -0.760352 0.463393 -0.771715 0 0 0 0.00281905 l
+-0.46484 -0.0794619 -0.456939 -0.0659617 0 0 0 0.00281905 l
+-0.46484 -0.0794619 -0.478931 -0.0751444 0 0 0 0.00281905 l
+-0.71874 -0.137247 -0.71649 -0.143018 0 0 0 0.00281905 l
+-0.71874 -0.137247 -0.719813 -0.136555 0 0 0 0.00281905 l
+-0.250031 0.347192 -0.247738 0.347234 0 0 0 0.00281905 l
+-0.250031 0.347192 -0.256666 0.351629 0 0 0 0.00281905 l
+-0.308558 0.736182 -0.318274 0.73475 0 0 0 0.00281905 l
+-0.543793 0.59757 -0.546757 0.595024 0 0 0 0.00281905 l
+0.523064 0.431084 0.534148 0.436348 0 0 0 0.00281905 l
+0.523064 0.431084 0.508216 0.435253 0 0 0 0.00281905 l
+0.309897 -0.691342 0.303693 -0.699058 0 0 0 0.00281905 l
+0.309897 -0.691342 0.311985 -0.689507 0 0 0 0.00281905 l
+0.309897 -0.691342 0.306692 -0.689056 0 0 0 0.00281905 l
+0.341354 0.835749 0.340425 0.829587 0 0 0 0.00281905 l
+0.341354 0.835749 0.35261 0.840797 0 0 0 0.00281905 l
+0.914891 -0.305581 0.913889 -0.292964 0 0 0 0.00281905 l
+0.914891 -0.305581 0.91032 -0.313594 0 0 0 0.00281905 l
+-0.316011 -0.278523 -0.319103 -0.266325 0 0 0 0.00281905 l
+0.180694 -0.397662 0.167167 -0.411072 0 0 0 0.00281905 l
+0.180694 -0.397662 0.171205 -0.381199 0 0 0 0.00281905 l
+0.180694 -0.397662 0.190046 -0.39205 0 0 0 0.00281905 l
+-0.134847 0.173405 -0.126743 0.185802 0 0 0 0.00281905 l
+-0.134847 0.173405 -0.139834 0.171303 0 0 0 0.00281905 l
+0.0982021 0.622165 0.109438 0.601087 0 0 0 0.00281905 l
+0.0982021 0.622165 0.0860512 0.632615 0 0 0 0.00281905 l
+0.595613 -0.793738 0.600298 -0.798479 0 0 0 0.00281905 l
+0.595613 -0.793738 0.584138 -0.804638 0 0 0 0.00281905 l
+0.595613 -0.793738 0.593781 -0.791036 0 0 0 0.00281905 l
+0.239904 0.89836 0.251627 0.897977 0 0 0 0.00281905 l
+0.239904 0.89836 0.236441 0.890676 0 0 0 0.00281905 l
+-0.0740086 -0.437677 -0.0644906 -0.441927 0 0 0 0.00281905 l
+-0.0740086 -0.437677 -0.0847791 -0.448096 0 0 0 0.00281905 l
+-0.0740086 -0.437677 -0.0791557 -0.431535 0 0 0 0.00281905 l
+-0.258113 0.811522 -0.259887 0.799868 0 0 0 0.00281905 l
+0.202954 0.801479 0.209803 0.808755 0 0 0 0.00281905 l
+0.202954 0.801479 0.209881 0.78857 0 0 0 0.00281905 l
+0.994508 0.0537307 0.991129 0.0651264 0 0 0 0.00281905 l
+0.994508 0.0537307 0.985674 0.0352875 0 0 0 0.00281905 l
+0.443728 -0.0804721 0.447947 -0.0728956 0 0 0 0.00281905 l
+0.443728 -0.0804721 0.435948 -0.0773629 0 0 0 0.00281905 l
+0.553809 0.323095 0.557663 0.32752 0 0 0 0.00281905 l
+0.553809 0.323095 0.545584 0.316875 0 0 0 0.00281905 l
+0.0323125 0.0216024 0.033741 0.0175564 0 0 0 0.00281905 l
+0.0323125 0.0216024 0.0326995 0.0367904 0 0 0 0.00281905 l
+0.0323125 0.0216024 0.022773 0.0198949 0 0 0 0.00281905 l
+-0.458992 -0.649726 -0.451204 -0.648302 0 0 0 0.00281905 l
+-0.458992 -0.649726 -0.464691 -0.643728 0 0 0 0.00281905 l
+0.435286 -0.0109673 0.437982 -0.0121583 0 0 0 0.00281905 l
+0.435286 -0.0109673 0.430336 -0.0133154 0 0 0 0.00281905 l
+0.435286 -0.0109673 0.436672 -0.00819742 0 0 0 0.00281905 l
+-0.0400301 0.881261 -0.0342956 0.881365 0 0 0 0.00281905 l
+-0.0400301 0.881261 -0.0415744 0.868008 0 0 0 0.00281905 l
+0.269915 0.714823 0.286838 0.718016 0 0 0 0.00281905 l
+0.269915 0.714823 0.264493 0.713747 0 0 0 0.00281905 l
+-0.0476685 -0.931465 -0.0552108 -0.921283 0 0 0 0.00281905 l
+-0.0476685 -0.931465 -0.0598951 -0.939492 0 0 0 0.00281905 l
+0.210368 -0.109028 0.212597 -0.0909193 0 0 0 0.00281905 l
+0.210368 -0.109028 0.204457 -0.125821 0 0 0 0.00281905 l
+0.210368 -0.109028 0.195337 -0.104477 0 0 0 0.00281905 l
+-0.866853 -0.0413217 -0.862557 -0.0639363 0 0 0 0.00281905 l
+-0.866853 -0.0413217 -0.864799 -0.0395843 0 0 0 0.00281905 l
+0.328003 -0.704211 0.327576 -0.720089 0 0 0 0.00281905 l
+0.328003 -0.704211 0.311985 -0.689507 0 0 0 0.00281905 l
+-0.566678 -0.563627 -0.563969 -0.54973 0 0 0 0.00281905 l
+-0.0533977 -0.22428 -0.0498239 -0.208133 0 0 0 0.00281905 l
+0.339385 0.314651 0.33906 0.307393 0 0 0 0.00281905 l
+-0.183047 0.626915 -0.169851 0.621446 0 0 0 0.00281905 l
+-0.183047 0.626915 -0.188857 0.633777 0 0 0 0.00281905 l
+0.255432 0.472909 0.265032 0.45553 0 0 0 0.00281905 l
+0.255432 0.472909 0.264056 0.475727 0 0 0 0.00281905 l
+0.255432 0.472909 0.250854 0.480826 0 0 0 0.00281905 l
+-0.61342 0.723451 -0.602797 0.738519 0 0 0 0.00281905 l
+0.172982 0.259448 0.175865 0.249967 0 0 0 0.00281905 l
+0.172982 0.259448 0.182396 0.261844 0 0 0 0.00281905 l
+0.172982 0.259448 0.166621 0.259037 0 0 0 0.00281905 l
+-0.248444 0.140185 -0.246491 0.141934 0 0 0 0.00281905 l
+-0.248444 0.140185 -0.267296 0.133195 0 0 0 0.00281905 l
+-0.470522 -0.313997 -0.460481 -0.306983 0 0 0 0.00281905 l
+-0.470522 -0.313997 -0.466269 -0.319024 0 0 0 0.00281905 l
+-0.611532 -0.390778 -0.610198 -0.39078 0 0 0 0.00281905 l
+-0.229485 0.192712 -0.222725 0.190309 0 0 0 0.00281905 l
+-0.229485 0.192712 -0.222333 0.202339 0 0 0 0.00281905 l
+-0.229485 0.192712 -0.237929 0.189347 0 0 0 0.00281905 l
+-0.96363 0.0336893 -0.969097 0.028464 0 0 0 0.00281905 l
+-0.345739 -0.188253 -0.331394 -0.187139 0 0 0 0.00281905 l
+-0.345739 -0.188253 -0.364104 -0.183242 0 0 0 0.00281905 l
+0.848391 0.203599 0.854656 0.213617 0 0 0 0.00281905 l
+0.321841 -0.835669 0.337385 -0.83835 0 0 0 0.00281905 l
+0.321841 -0.835669 0.319296 -0.821459 0 0 0 0.00281905 l
+-0.826413 0.376953 -0.835102 0.378157 0 0 0 0.00281905 l
+0.095381 -0.173341 0.110227 -0.171234 0 0 0 0.00281905 l
+0.095381 -0.173341 0.09684 -0.179297 0 0 0 0.00281905 l
+-0.404718 -0.692682 -0.417619 -0.697159 0 0 0 0.00281905 l
+0.306761 -0.587732 0.304932 -0.57325 0 0 0 0.00281905 l
+0.306761 -0.587732 0.31983 -0.586719 0 0 0 0.00281905 l
+0.306761 -0.587732 0.295567 -0.597501 0 0 0 0.00281905 l
+0.0993346 0.115471 0.105633 0.104423 0 0 0 0.00281905 l
+0.0993346 0.115471 0.0991834 0.118971 0 0 0 0.00281905 l
+0.0993346 0.115471 0.0969116 0.115949 0 0 0 0.00281905 l
+-0.784037 -0.376999 -0.78233 -0.385587 0 0 0 0.00281905 l
+-0.333609 0.874333 -0.334868 0.883263 0 0 0 0.00281905 l
+-0.333609 0.874333 -0.312194 0.870612 0 0 0 0.00281905 l
+0.789172 0.135122 0.793837 0.122679 0 0 0 0.00281905 l
+0.789172 0.135122 0.791534 0.136547 0 0 0 0.00281905 l
+0.883525 0.19432 0.887296 0.191698 0 0 0 0.00281905 l
+0.883525 0.19432 0.870001 0.200194 0 0 0 0.00281905 l
+0.572665 0.169357 0.573743 0.176833 0 0 0 0.00281905 l
+0.572665 0.169357 0.578102 0.164425 0 0 0 0.00281905 l
+-0.459833 -0.445835 -0.45341 -0.453976 0 0 0 0.00281905 l
+-0.459833 -0.445835 -0.455109 -0.440081 0 0 0 0.00281905 l
+-0.459833 -0.445835 -0.470956 -0.442362 0 0 0 0.00281905 l
+0.395049 -0.230109 0.391458 -0.233928 0 0 0 0.00281905 l
+-0.420969 0.809556 -0.42207 0.799575 0 0 0 0.00281905 l
+-0.420969 0.809556 -0.405846 0.817623 0 0 0 0.00281905 l
+-0.30425 -0.442405 -0.291071 -0.453024 0 0 0 0.00281905 l
+-0.13531 -0.857802 -0.13221 -0.862471 0 0 0 0.00281905 l
+-0.13531 -0.857802 -0.14142 -0.855694 0 0 0 0.00281905 l
+0.307385 -0.827747 0.293751 -0.841402 0 0 0 0.00281905 l
+0.307385 -0.827747 0.319296 -0.821459 0 0 0 0.00281905 l
+0.307385 -0.827747 0.294832 -0.818299 0 0 0 0.00281905 l
+-0.151409 -0.228228 -0.157561 -0.237855 0 0 0 0.00281905 l
+-0.151409 -0.228228 -0.15774 -0.221402 0 0 0 0.00281905 l
+0.50235 -0.490125 0.512947 -0.476369 0 0 0 0.00281905 l
+0.50235 -0.490125 0.489197 -0.485058 0 0 0 0.00281905 l
+0.119924 -0.515741 0.120706 -0.499668 0 0 0 0.00281905 l
+0.119924 -0.515741 0.118823 -0.524215 0 0 0 0.00281905 l
+0.900011 -0.141537 0.908405 -0.126191 0 0 0 0.00281905 l
+0.900011 -0.141537 0.881914 -0.143757 0 0 0 0.00281905 l
+-0.609486 -0.166932 -0.612655 -0.173906 0 0 0 0.00281905 l
+-0.490357 -0.286128 -0.483274 -0.275463 0 0 0 0.00281905 l
+-0.490357 -0.286128 -0.491721 -0.290644 0 0 0 0.00281905 l
+0.731445 -0.089025 0.736018 -0.081899 0 0 0 0.00281905 l
+0.731445 -0.089025 0.723664 -0.0937109 0 0 0 0.00281905 l
+-0.488199 0.12868 -0.484895 0.127886 0 0 0 0.00281905 l
+-0.488199 0.12868 -0.498813 0.116143 0 0 0 0.00281905 l
+-0.488199 0.12868 -0.504274 0.137483 0 0 0 0.00281905 l
+-0.135291 0.7704 -0.131039 0.778038 0 0 0 0.00281905 l
+-0.135291 0.7704 -0.153893 0.764626 0 0 0 0.00281905 l
+-0.935646 0.343461 -0.933061 0.336021 0 0 0 0.00281905 l
+-0.539839 -0.532737 -0.534944 -0.531927 0 0 0 0.00281905 l
+-0.539839 -0.532737 -0.548624 -0.536184 0 0 0 0.00281905 l
+0.371161 -0.852433 0.367502 -0.864417 0 0 0 0.00281905 l
+0.590357 -0.645292 0.590782 -0.638661 0 0 0 0.00281905 l
+0.590357 -0.645292 0.59835 -0.643821 0 0 0 0.00281905 l
+-0.216569 -0.0206235 -0.213792 -0.0177131 0 0 0 0.00281905 l
+-0.216569 -0.0206235 -0.221858 -0.0282035 0 0 0 0.00281905 l
+0.766176 -0.340296 0.771202 -0.354058 0 0 0 0.00281905 l
+0.766176 -0.340296 0.773487 -0.337473 0 0 0 0.00281905 l
+0.766176 -0.340296 0.757346 -0.3361 0 0 0 0.00281905 l
+0.338889 0.537533 0.343073 0.548973 0 0 0 0.00281905 l
+0.338889 0.537533 0.328364 0.535185 0 0 0 0.00281905 l
+0.20415 0.606996 0.218971 0.614714 0 0 0 0.00281905 l
+0.20415 0.606996 0.193578 0.605487 0 0 0 0.00281905 l
+0.43393 0.734046 0.437396 0.725405 0 0 0 0.00281905 l
+0.43393 0.734046 0.439836 0.740547 0 0 0 0.00281905 l
+0.43393 0.734046 0.417409 0.731866 0 0 0 0.00281905 l
+0.617599 0.525632 0.602278 0.52919 0 0 0 0.00281905 l
+0.328364 0.535185 0.338889 0.537533 0 0 0 0.00281905 l
+0.328364 0.535185 0.326346 0.533894 0 0 0 0.00281905 l
+-0.00781449 -0.413831 -0.0166209 -0.430136 0 0 0 0.00281905 l
+-0.440082 0.379458 -0.429868 0.361135 0 0 0 0.00281905 l
+-0.581128 0.284022 -0.577564 0.298612 0 0 0 0.00281905 l
+-0.581128 0.284022 -0.560916 0.282578 0 0 0 0.00281905 l
+-0.581128 0.284022 -0.586125 0.284563 0 0 0 0.00281905 l
+-0.255663 -0.702719 -0.256112 -0.705305 0 0 0 0.00281905 l
+-0.255663 -0.702719 -0.260987 -0.69546 0 0 0 0.00281905 l
+0.52704 -0.315989 0.538235 -0.301711 0 0 0 0.00281905 l
+0.52704 -0.315989 0.524454 -0.321198 0 0 0 0.00281905 l
+-0.302069 0.32797 -0.29496 0.343348 0 0 0 0.00281905 l
+-0.302069 0.32797 -0.294171 0.321321 0 0 0 0.00281905 l
+-0.900706 -0.142356 -0.891921 -0.138445 0 0 0 0.00281905 l
+-0.900706 -0.142356 -0.898061 -0.153156 0 0 0 0.00281905 l
+0.86534 -0.030318 0.867832 -0.0208838 0 0 0 0.00281905 l
+-0.913074 -0.196854 -0.919607 -0.188173 0 0 0 0.00281905 l
+-0.101404 -0.734262 -0.0970644 -0.739787 0 0 0 0.00281905 l
+0.884472 0.354285 0.881788 0.332473 0 0 0 0.00281905 l
+0.884472 0.354285 0.881109 0.35713 0 0 0 0.00281905 l
+0.802763 0.237718 0.821239 0.245769 0 0 0 0.00281905 l
+0.859485 0.121724 0.854883 0.132883 0 0 0 0.00281905 l
+0.859485 0.121724 0.853608 0.119333 0 0 0 0.00281905 l
+0.712491 0.0240388 0.712419 0.0137765 0 0 0 0.00281905 l
+0.712491 0.0240388 0.724444 0.0253599 0 0 0 0.00281905 l
+0.712491 0.0240388 0.69659 0.0276552 0 0 0 0.00281905 l
+-0.437203 -0.844036 -0.425707 -0.842117 0 0 0 0.00281905 l
+-0.437203 -0.844036 -0.445927 -0.838244 0 0 0 0.00281905 l
+-0.437203 -0.844036 -0.439156 -0.848104 0 0 0 0.00281905 l
+-0.681808 -0.21889 -0.675337 -0.218086 0 0 0 0.00281905 l
+-0.681808 -0.21889 -0.683268 -0.214773 0 0 0 0.00281905 l
+0.0419822 0.568788 0.0423745 0.568368 0 0 0 0.00281905 l
+0.0419822 0.568788 0.0343723 0.578406 0 0 0 0.00281905 l
+-0.386684 0.0793454 -0.38382 0.0844554 0 0 0 0.00281905 l
+0.619518 0.248199 0.613095 0.231129 0 0 0 0.00281905 l
+0.619518 0.248199 0.6158 0.253786 0 0 0 0.00281905 l
+0.482189 -0.691722 0.491724 -0.688434 0 0 0 0.00281905 l
+0.482189 -0.691722 0.467739 -0.684046 0 0 0 0.00281905 l
+0.525091 0.464665 0.514997 0.475471 0 0 0 0.00281905 l
+0.525091 0.464665 0.520137 0.4579 0 0 0 0.00281905 l
+-0.890614 -0.186672 -0.887836 -0.196856 0 0 0 0.00281905 l
+-0.890614 -0.186672 -0.876741 -0.182791 0 0 0 0.00281905 l
+-0.890614 -0.186672 -0.909054 -0.181294 0 0 0 0.00281905 l
+0.248766 -0.919427 0.250663 -0.925477 0 0 0 0.00281905 l
+0.248766 -0.919427 0.25967 -0.908048 0 0 0 0.00281905 l
+0.0705764 -0.192373 0.0762325 -0.185691 0 0 0 0.00281905 l
+0.0705764 -0.192373 0.085039 -0.200681 0 0 0 0.00281905 l
+0.0705764 -0.192373 0.0619061 -0.204734 0 0 0 0.00281905 l
+0.0705764 -0.192373 0.0667513 -0.19042 0 0 0 0.00281905 l
+-0.0621551 -0.10562 -0.0615237 -0.107651 0 0 0 0.00281905 l
+0.617278 0.611755 0.617338 0.619792 0 0 0 0.00281905 l
+0.617278 0.611755 0.61364 0.601569 0 0 0 0.00281905 l
+0.617278 0.611755 0.609127 0.613332 0 0 0 0.00281905 l
+-0.760404 -0.522621 -0.762468 -0.528041 0 0 0 0.00281905 l
+-0.760404 -0.522621 -0.764021 -0.518381 0 0 0 0.00281905 l
+-0.578711 0.42757 -0.585403 0.414708 0 0 0 0.00281905 l
+-0.578711 0.42757 -0.576291 0.435622 0 0 0 0.00281905 l
+-0.944985 0.0307441 -0.934335 0.0400148 0 0 0 0.00281905 l
+-0.944985 0.0307441 -0.954453 0.0228362 0 0 0 0.00281905 l
+0.35618 -0.135943 0.360847 -0.140489 0 0 0 0.00281905 l
+0.35618 -0.135943 0.339508 -0.126727 0 0 0 0.00281905 l
+-0.266237 0.515397 -0.25405 0.522235 0 0 0 0.00281905 l
+-0.266237 0.515397 -0.260676 0.504567 0 0 0 0.00281905 l
+-0.878195 -0.218833 -0.880928 -0.214931 0 0 0 0.00281905 l
+0.675671 0.709711 0.67952 0.728164 0 0 0 0.00281905 l
+0.675671 0.709711 0.679186 0.698116 0 0 0 0.00281905 l
+0.137469 0.0834567 0.141457 0.0703728 0 0 0 0.00281905 l
+0.137469 0.0834567 0.132412 0.0884444 0 0 0 0.00281905 l
+-0.413378 -0.517312 -0.411791 -0.522669 0 0 0 0.00281905 l
+0.144009 0.935127 0.147178 0.934427 0 0 0 0.00281905 l
+0.144009 0.935127 0.12967 0.934646 0 0 0 0.00281905 l
+-0.360827 0.0526602 -0.381254 0.0491927 0 0 0 0.00281905 l
+-0.376034 0.76153 -0.382249 0.767112 0 0 0 0.00281905 l
+-0.376034 0.76153 -0.372898 0.759246 0 0 0 0.00281905 l
+0.404657 -0.479598 0.406519 -0.486546 0 0 0 0.00281905 l
+0.404657 -0.479598 0.392037 -0.474552 0 0 0 0.00281905 l
+-0.0896443 0.579323 -0.0848113 0.596496 0 0 0 0.00281905 l
+-0.0896443 0.579323 -0.0971836 0.568136 0 0 0 0.00281905 l
+-0.0177342 -0.924899 -0.00612641 -0.912337 0 0 0 0.00281905 l
+-0.0177342 -0.924899 -0.0252594 -0.931069 0 0 0 0.00281905 l
+0.00516181 -0.462174 0.011818 -0.479346 0 0 0 0.00281905 l
+0.00516181 -0.462174 -0.00427752 -0.447583 0 0 0 0.00281905 l
+0.00516181 -0.462174 -0.0147226 -0.467203 0 0 0 0.00281905 l
+-0.817754 0.559246 -0.803693 0.554978 0 0 0 0.00281905 l
+-0.817754 0.559246 -0.815075 0.573991 0 0 0 0.00281905 l
+0.232747 -0.0302739 0.232538 -0.0355874 0 0 0 0.00281905 l
+0.232747 -0.0302739 0.221721 -0.0242625 0 0 0 0.00281905 l
+-0.460791 0.137156 -0.461637 0.150778 0 0 0 0.00281905 l
+-0.460791 0.137156 -0.444614 0.130374 0 0 0 0.00281905 l
+-0.460791 0.137156 -0.463232 0.123319 0 0 0 0.00281905 l
+-0.0735665 0.0328014 -0.0768803 0.0338433 0 0 0 0.00281905 l
+0.625529 0.716586 0.624431 0.703688 0 0 0 0.00281905 l
+0.625529 0.716586 0.634934 0.726133 0 0 0 0.00281905 l
+0.760142 -0.0760978 0.762144 -0.0939711 0 0 0 0.00281905 l
+0.760142 -0.0760978 0.771424 -0.0744495 0 0 0 0.00281905 l
+0.760142 -0.0760978 0.749546 -0.067776 0 0 0 0.00281905 l
+0.0697739 0.34719 0.0775398 0.362226 0 0 0 0.00281905 l
+0.0697739 0.34719 0.0788964 0.344692 0 0 0 0.00281905 l
+0.0697739 0.34719 0.0681678 0.334997 0 0 0 0.00281905 l
+-0.617945 -0.242948 -0.634403 -0.23306 0 0 0 0.00281905 l
+-0.78233 -0.385587 -0.784037 -0.376999 0 0 0 0.00281905 l
+-0.78233 -0.385587 -0.769035 -0.395903 0 0 0 0.00281905 l
+0.938478 -0.0799388 0.939122 -0.073207 0 0 0 0.00281905 l
+0.938478 -0.0799388 0.930097 -0.0911542 0 0 0 0.00281905 l
+0.938478 -0.0799388 0.930726 -0.0765441 0 0 0 0.00281905 l
+0.125228 -0.975849 0.137896 -0.978451 0 0 0 0.00281905 l
+0.125228 -0.975849 0.121815 -0.972676 0 0 0 0.00281905 l
+-0.25749 -0.283666 -0.249009 -0.294645 0 0 0 0.00281905 l
+-0.25749 -0.283666 -0.249852 -0.27934 0 0 0 0.00281905 l
+-0.25749 -0.283666 -0.265311 -0.284971 0 0 0 0.00281905 l
+-0.237927 0.744182 -0.228253 0.73746 0 0 0 0.00281905 l
+-0.237927 0.744182 -0.240807 0.741568 0 0 0 0.00281905 l
+0.124012 -0.424301 0.118477 -0.440509 0 0 0 0.00281905 l
+0.124012 -0.424301 0.132668 -0.406724 0 0 0 0.00281905 l
+0.124012 -0.424301 0.114175 -0.417613 0 0 0 0.00281905 l
+0.435802 -0.823099 0.447366 -0.828168 0 0 0 0.00281905 l
+0.435802 -0.823099 0.430854 -0.82155 0 0 0 0.00281905 l
+-0.652298 0.419798 -0.663896 0.434713 0 0 0 0.00281905 l
+-0.652298 0.419798 -0.653032 0.410949 0 0 0 0.00281905 l
+0.339355 -0.351328 0.337422 -0.341587 0 0 0 0.00281905 l
+0.339355 -0.351328 0.330368 -0.355955 0 0 0 0.00281905 l
+0.209881 0.78857 0.201328 0.77483 0 0 0 0.00281905 l
+0.209881 0.78857 0.202954 0.801479 0 0 0 0.00281905 l
+0.289469 0.235821 0.299733 0.236217 0 0 0 0.00281905 l
+0.289469 0.235821 0.283247 0.240802 0 0 0 0.00281905 l
+0.0984956 -0.768258 0.109723 -0.771143 0 0 0 0.00281905 l
+0.0984956 -0.768258 0.0811246 -0.761723 0 0 0 0.00281905 l
+-0.137858 -0.336549 -0.135481 -0.339244 0 0 0 0.00281905 l
+-0.137858 -0.336549 -0.14505 -0.329224 0 0 0 0.00281905 l
+-0.578543 -0.467186 -0.579603 -0.473129 0 0 0 0.00281905 l
+-0.578543 -0.467186 -0.565216 -0.466554 0 0 0 0.00281905 l
+-0.578543 -0.467186 -0.584484 -0.464525 0 0 0 0.00281905 l
+0.6241 0.701227 0.631204 0.700176 0 0 0 0.00281905 l
+0.6241 0.701227 0.62031 0.695076 0 0 0 0.00281905 l
+0.6241 0.701227 0.624431 0.703688 0 0 0 0.00281905 l
+-0.464725 0.754014 -0.475281 0.73422 0 0 0 0.00281905 l
+-0.464725 0.754014 -0.463411 0.755185 0 0 0 0.00281905 l
+-0.603936 0.184845 -0.615477 0.189529 0 0 0 0.00281905 l
+0.544738 -0.262364 0.547597 -0.246631 0 0 0 0.00281905 l
+0.544738 -0.262364 0.553963 -0.269853 0 0 0 0.00281905 l
+-0.364555 0.526779 -0.366666 0.51632 0 0 0 0.00281905 l
+-0.364555 0.526779 -0.364941 0.53428 0 0 0 0.00281905 l
+0.35632 -0.0457503 0.352171 -0.0347774 0 0 0 0.00281905 l
+0.35632 -0.0457503 0.376004 -0.0487393 0 0 0 0.00281905 l
+0.267705 0.828594 0.267907 0.819675 0 0 0 0.00281905 l
+0.267705 0.828594 0.260539 0.839922 0 0 0 0.00281905 l
+-0.52491 0.316803 -0.526661 0.333 0 0 0 0.00281905 l
+-0.52491 0.316803 -0.515813 0.309736 0 0 0 0.00281905 l
+0.899006 -0.0819796 0.8987 -0.0726415 0 0 0 0.00281905 l
+0.899006 -0.0819796 0.902076 -0.0868506 0 0 0 0.00281905 l
+0.899006 -0.0819796 0.88733 -0.0790919 0 0 0 0.00281905 l
+-0.857619 -0.0790086 -0.870821 -0.0924164 0 0 0 0.00281905 l
+-0.857619 -0.0790086 -0.850723 -0.0751691 0 0 0 0.00281905 l
+-0.857619 -0.0790086 -0.860771 -0.0720439 0 0 0 0.00281905 l
+0.182396 0.261844 0.193307 0.249766 0 0 0 0.00281905 l
+0.182396 0.261844 0.174312 0.278757 0 0 0 0.00281905 l
+0.182396 0.261844 0.172982 0.259448 0 0 0 0.00281905 l
+-0.862695 0.144242 -0.859048 0.154908 0 0 0 0.00281905 l
+-0.862695 0.144242 -0.866928 0.136351 0 0 0 0.00281905 l
+0.31663 -0.302336 0.316593 -0.305555 0 0 0 0.00281905 l
+0.31663 -0.302336 0.310131 -0.286867 0 0 0 0.00281905 l
+-0.0437732 -0.105416 -0.0303317 -0.107029 0 0 0 0.00281905 l
+-0.0437732 -0.105416 -0.0495994 -0.0916137 0 0 0 0.00281905 l
+-0.0437732 -0.105416 -0.0615237 -0.107651 0 0 0 0.00281905 l
+0.869232 0.317212 0.879312 0.313061 0 0 0 0.00281905 l
+0.869232 0.317212 0.864082 0.306563 0 0 0 0.00281905 l
+-0.223671 0.844436 -0.233504 0.825716 0 0 0 0.00281905 l
+-0.223671 0.844436 -0.228468 0.85644 0 0 0 0.00281905 l
+-0.223671 0.844436 -0.215222 0.844214 0 0 0 0.00281905 l
+0.248309 -0.780939 0.268165 -0.778566 0 0 0 0.00281905 l
+0.248309 -0.780939 0.233989 -0.795961 0 0 0 0.00281905 l
+0.248309 -0.780939 0.245413 -0.776023 0 0 0 0.00281905 l
+-0.0798379 0.00702604 -0.074392 0.00717552 0 0 0 0.00281905 l
+-0.0798379 0.00702604 -0.0803243 0.00181404 0 0 0 0.00281905 l
+0.0263655 -0.724008 0.0114837 -0.727832 0 0 0 0.00281905 l
+-0.336658 0.117928 -0.337262 0.101963 0 0 0 0.00281905 l
+-0.336658 0.117928 -0.344136 0.133933 0 0 0 0.00281905 l
+0.42646 0.83955 0.423059 0.845086 0 0 0 0.00281905 l
+-0.0536879 -0.869108 -0.0406692 -0.859425 0 0 0 0.00281905 l
+-0.0536879 -0.869108 -0.0532179 -0.886292 0 0 0 0.00281905 l
+-0.470154 -0.234332 -0.457493 -0.248828 0 0 0 0.00281905 l
+-0.470154 -0.234332 -0.457775 -0.227992 0 0 0 0.00281905 l
+-0.470154 -0.234332 -0.478205 -0.227729 0 0 0 0.00281905 l
+-0.695368 -0.598554 -0.683133 -0.595352 0 0 0 0.00281905 l
+0.0949823 0.513135 0.0966354 0.508299 0 0 0 0.00281905 l
+0.0949823 0.513135 0.0795931 0.514672 0 0 0 0.00281905 l
+0.015095 -0.680902 0.0276884 -0.68313 0 0 0 0.00281905 l
+0.015095 -0.680902 0.0169379 -0.675838 0 0 0 0.00281905 l
+0.491724 -0.688434 0.499236 -0.693166 0 0 0 0.00281905 l
+0.491724 -0.688434 0.482189 -0.691722 0 0 0 0.00281905 l
+-0.383227 -0.758285 -0.376945 -0.745333 0 0 0 0.00281905 l
+-0.383227 -0.758285 -0.385401 -0.761311 0 0 0 0.00281905 l
+0.316026 0.795371 0.321377 0.796803 0 0 0 0.00281905 l
+0.316026 0.795371 0.31639 0.787669 0 0 0 0.00281905 l
+-0.707089 0.5613 -0.684793 0.567328 0 0 0 0.00281905 l
+-0.707089 0.5613 -0.717656 0.573317 0 0 0 0.00281905 l
+-0.707089 0.5613 -0.723845 0.555401 0 0 0 0.00281905 l
+0.309397 0.432814 0.328125 0.4328 0 0 0 0.00281905 l
+0.309397 0.432814 0.29741 0.413448 0 0 0 0.00281905 l
+0.479758 -0.325487 0.463098 -0.32421 0 0 0 0.00281905 l
+-0.43567 0.0848271 -0.441834 0.0846763 0 0 0 0.00281905 l
+0.729012 -0.374956 0.731735 -0.359658 0 0 0 0.00281905 l
+0.729012 -0.374956 0.714095 -0.368501 0 0 0 0.00281905 l
+0.794087 0.166225 0.806309 0.173724 0 0 0 0.00281905 l
+0.013098 0.629567 0.013018 0.625936 0 0 0 0.00281905 l
+0.013098 0.629567 0.016473 0.640136 0 0 0 0.00281905 l
+-0.265711 0.771821 -0.279961 0.775062 0 0 0 0.00281905 l
+-0.141942 -0.687422 -0.129235 -0.68322 0 0 0 0.00281905 l
+-0.141942 -0.687422 -0.144356 -0.687791 0 0 0 0.00281905 l
+-0.374877 0.683565 -0.360989 0.679489 0 0 0 0.00281905 l
+-0.374877 0.683565 -0.387076 0.692185 0 0 0 0.00281905 l
+0.174232 -0.458266 0.186391 -0.443552 0 0 0 0.00281905 l
+-0.543145 0.397263 -0.545165 0.412053 0 0 0 0.00281905 l
+-0.543145 0.397263 -0.548876 0.390544 0 0 0 0.00281905 l
+-0.114812 0.954159 -0.113673 0.960324 0 0 0 0.00281905 l
+-0.114812 0.954159 -0.107824 0.948275 0 0 0 0.00281905 l
+0.113645 0.423784 0.10902 0.433741 0 0 0 0.00281905 l
+0.113645 0.423784 0.104082 0.422344 0 0 0 0.00281905 l
+0.392649 0.727112 0.396662 0.721446 0 0 0 0.00281905 l
+0.623513 -0.54772 0.638001 -0.546558 0 0 0 0.00281905 l
+0.623513 -0.54772 0.619921 -0.544049 0 0 0 0.00281905 l
+-0.195541 0.00593465 -0.185794 -0.00925174 0 0 0 0.00281905 l
+-0.195541 0.00593465 -0.19765 0.00752604 0 0 0 0.00281905 l
+0.0233897 0.51926 0.024476 0.51887 0 0 0 0.00281905 l
+0.436423 0.1496 0.434481 0.143755 0 0 0 0.00281905 l
+0.436423 0.1496 0.435976 0.151947 0 0 0 0.00281905 l
+0.198122 0.396891 0.198372 0.396263 0 0 0 0.00281905 l
+0.198122 0.396891 0.188396 0.393545 0 0 0 0.00281905 l
+0.612343 -0.633265 0.626885 -0.636392 0 0 0 0.00281905 l
+0.612343 -0.633265 0.604926 -0.640913 0 0 0 0.00281905 l
+-0.466617 0.209667 -0.467719 0.217923 0 0 0 0.00281905 l
+-0.466617 0.209667 -0.470723 0.204716 0 0 0 0.00281905 l
+-0.119806 0.115945 -0.128629 0.0992151 0 0 0 0.00281905 l
+-0.161508 -0.348034 -0.164051 -0.342597 0 0 0 0.00281905 l
+-0.161508 -0.348034 -0.166582 -0.353338 0 0 0 0.00281905 l
+0.313903 0.575043 0.300092 0.572821 0 0 0 0.00281905 l
+-0.634342 0.620484 -0.642314 0.624527 0 0 0 0.00281905 l
+0.357642 -0.270459 0.35069 -0.261634 0 0 0 0.00281905 l
+0.357642 -0.270459 0.349531 -0.276715 0 0 0 0.00281905 l
+-0.608271 -0.303339 -0.607449 -0.320658 0 0 0 0.00281905 l
+-0.608271 -0.303339 -0.61972 -0.293387 0 0 0 0.00281905 l
+-0.448604 -0.658091 -0.442604 -0.661115 0 0 0 0.00281905 l
+-0.448604 -0.658091 -0.451204 -0.648302 0 0 0 0.00281905 l
+-0.373852 0.248632 -0.367179 0.240954 0 0 0 0.00281905 l
+-0.373852 0.248632 -0.383147 0.251792 0 0 0 0.00281905 l
+-0.597058 -0.0400136 -0.579896 -0.0517447 0 0 0 0.00281905 l
+-0.597058 -0.0400136 -0.600431 -0.0375296 0 0 0 0.00281905 l
+0.708082 0.181733 0.715416 0.172852 0 0 0 0.00281905 l
+0.708082 0.181733 0.693523 0.175183 0 0 0 0.00281905 l
+-0.815075 0.573991 -0.805019 0.591439 0 0 0 0.00281905 l
+-0.815075 0.573991 -0.817754 0.559246 0 0 0 0.00281905 l
+-0.346709 -0.709464 -0.346703 -0.717132 0 0 0 0.00281905 l
+-0.346709 -0.709464 -0.335143 -0.697747 0 0 0 0.00281905 l
+-0.346709 -0.709464 -0.351045 -0.708971 0 0 0 0.00281905 l
+-0.652231 0.217113 -0.661617 0.222625 0 0 0 0.00281905 l
+-0.51029 0.203439 -0.510952 0.214924 0 0 0 0.00281905 l
+-0.335551 -0.289702 -0.3333 -0.300746 0 0 0 0.00281905 l
+-0.335551 -0.289702 -0.34786 -0.2869 0 0 0 0.00281905 l
+0.657387 0.247274 0.670672 0.252784 0 0 0 0.00281905 l
+0.657387 0.247274 0.641067 0.23596 0 0 0 0.00281905 l
+0.657387 0.247274 0.647396 0.256202 0 0 0 0.00281905 l
+-0.39409 0.102093 -0.391931 0.0930126 0 0 0 0.00281905 l
+-0.406455 0.657288 -0.407997 0.663841 0 0 0 0.00281905 l
+-0.406455 0.657288 -0.400809 0.653632 0 0 0 0.00281905 l
+0.266692 0.267853 0.25223 0.259482 0 0 0 0.00281905 l
+0.266692 0.267853 0.265064 0.272314 0 0 0 0.00281905 l
+-0.466575 -0.368739 -0.483323 -0.381633 0 0 0 0.00281905 l
+0.228051 0.936698 0.235904 0.940493 0 0 0 0.00281905 l
+0.228051 0.936698 0.219064 0.936417 0 0 0 0.00281905 l
+0.880817 -0.303731 0.888296 -0.291867 0 0 0 0.00281905 l
+0.880817 -0.303731 0.889826 -0.319835 0 0 0 0.00281905 l
+0.0871399 -0.538193 0.0874055 -0.541674 0 0 0 0.00281905 l
+0.0871399 -0.538193 0.077044 -0.539368 0 0 0 0.00281905 l
+-0.346622 -0.33147 -0.336308 -0.32636 0 0 0 0.00281905 l
+-0.303606 0.232468 -0.301908 0.232097 0 0 0 0.00281905 l
+-0.303606 0.232468 -0.318459 0.233084 0 0 0 0.00281905 l
+0.600707 0.702028 0.595709 0.703359 0 0 0 0.00281905 l
+0.0495935 0.778917 0.059072 0.790593 0 0 0 0.00281905 l
+0.0495935 0.778917 0.0474121 0.776291 0 0 0 0.00281905 l
+0.67952 0.728164 0.675671 0.709711 0 0 0 0.00281905 l
+-0.383187 -0.663101 -0.369281 -0.672753 0 0 0 0.00281905 l
+-0.383187 -0.663101 -0.390618 -0.667773 0 0 0 0.00281905 l
+0.764135 0.40848 0.773631 0.397263 0 0 0 0.00281905 l
+0.764135 0.40848 0.76173 0.423666 0 0 0 0.00281905 l
+-0.851841 -0.161878 -0.840519 -0.162066 0 0 0 0.00281905 l
+-0.851841 -0.161878 -0.852209 -0.163375 0 0 0 0.00281905 l
+-0.0773543 -0.383147 -0.0591777 -0.377011 0 0 0 0.00281905 l
+-0.0773543 -0.383147 -0.0814608 -0.387172 0 0 0 0.00281905 l
+0.396859 -0.334295 0.39564 -0.328158 0 0 0 0.00281905 l
+0.396859 -0.334295 0.408412 -0.334929 0 0 0 0.00281905 l
+0.823738 -0.182048 0.843803 -0.191406 0 0 0 0.00281905 l
+0.823738 -0.182048 0.837068 -0.167083 0 0 0 0.00281905 l
+0.823738 -0.182048 0.818649 -0.185561 0 0 0 0.00281905 l
+-0.0129073 0.581111 -0.007003 0.583346 0 0 0 0.00281905 l
+-0.0129073 0.581111 -0.00806925 0.57144 0 0 0 0.00281905 l
+0.608925 0.358462 0.622638 0.345301 0 0 0 0.00281905 l
+0.608925 0.358462 0.598735 0.366225 0 0 0 0.00281905 l
+0.42179 0.250787 0.419142 0.228451 0 0 0 0.00281905 l
+0.42179 0.250787 0.413889 0.257699 0 0 0 0.00281905 l
+0.809769 0.207781 0.824082 0.211977 0 0 0 0.00281905 l
+0.809769 0.207781 0.788804 0.217445 0 0 0 0.00281905 l
+0.698247 0.453898 0.708486 0.440453 0 0 0 0.00281905 l
+0.698247 0.453898 0.690714 0.469409 0 0 0 0.00281905 l
+0.698247 0.453898 0.683102 0.445595 0 0 0 0.00281905 l
+-0.425079 -0.00381754 -0.412622 -0.00813736 0 0 0 0.00281905 l
+-0.425079 -0.00381754 -0.430034 -0.00183504 0 0 0 0.00281905 l
+-0.366742 0.199662 -0.358903 0.205019 0 0 0 0.00281905 l
+-0.366742 0.199662 -0.371889 0.192947 0 0 0 0.00281905 l
+-0.106852 -0.608091 -0.114881 -0.600446 0 0 0 0.00281905 l
+0.303412 0.654062 0.310328 0.668881 0 0 0 0.00281905 l
+0.303412 0.654062 0.309464 0.646158 0 0 0 0.00281905 l
+0.245335 0.195889 0.264406 0.195295 0 0 0 0.00281905 l
+0.245335 0.195889 0.251122 0.180045 0 0 0 0.00281905 l
+0.245335 0.195889 0.221944 0.195347 0 0 0 0.00281905 l
+0.455927 0.246693 0.46001 0.243729 0 0 0 0.00281905 l
+0.455927 0.246693 0.447165 0.249694 0 0 0 0.00281905 l
+-0.576103 0.793548 -0.573225 0.798797 0 0 0 0.00281905 l
+-0.576103 0.793548 -0.573977 0.787683 0 0 0 0.00281905 l
+-0.576103 0.793548 -0.587661 0.797405 0 0 0 0.00281905 l
+-0.644222 -0.404742 -0.676879 -0.404281 0 0 0 0.00281905 l
+-0.135957 -0.945604 -0.11671 -0.956021 0 0 0 0.00281905 l
+-0.135957 -0.945604 -0.140512 -0.939848 0 0 0 0.00281905 l
+-0.135957 -0.945604 -0.139973 -0.947226 0 0 0 0.00281905 l
+0.00219534 -0.910376 0.00425097 -0.900307 0 0 0 0.00281905 l
+0.00219534 -0.910376 0.0100471 -0.913308 0 0 0 0.00281905 l
+0.00219534 -0.910376 -0.00612641 -0.912337 0 0 0 0.00281905 l
+-0.159742 0.84315 -0.15958 0.842394 0 0 0 0.00281905 l
+-0.2561 0.441504 -0.239671 0.443197 0 0 0 0.00281905 l
+-0.2561 0.441504 -0.259875 0.449412 0 0 0 0.00281905 l
+0.931906 -0.132025 0.936474 -0.15145 0 0 0 0.00281905 l
+0.931906 -0.132025 0.919393 -0.129885 0 0 0 0.00281905 l
+0.442514 -0.118683 0.432184 -0.109052 0 0 0 0.00281905 l
+0.442514 -0.118683 0.448906 -0.118412 0 0 0 0.00281905 l
+0.208135 -0.373519 0.211175 -0.363979 0 0 0 0.00281905 l
+0.184093 0.395891 0.188396 0.393545 0 0 0 0.00281905 l
+0.184093 0.395891 0.180656 0.405058 0 0 0 0.00281905 l
+-0.784184 0.584221 -0.777657 0.581113 0 0 0 0.00281905 l
+-0.784184 0.584221 -0.785998 0.580995 0 0 0 0.00281905 l
+-0.380007 -0.554957 -0.377168 -0.556729 0 0 0 0.00281905 l
+-0.380007 -0.554957 -0.388716 -0.552766 0 0 0 0.00281905 l
+-0.266493 0.922072 -0.267796 0.930518 0 0 0 0.00281905 l
+-0.266493 0.922072 -0.259653 0.91724 0 0 0 0.00281905 l
+0.146779 -0.475542 0.148657 -0.463137 0 0 0 0.00281905 l
+0.146779 -0.475542 0.155029 -0.474446 0 0 0 0.00281905 l
+0.146779 -0.475542 0.128444 -0.483237 0 0 0 0.00281905 l
+-0.523826 -0.0454869 -0.523972 -0.0527644 0 0 0 0.00281905 l
+-0.523826 -0.0454869 -0.521148 -0.0434508 0 0 0 0.00281905 l
+0.231676 -0.3381 0.234133 -0.320769 0 0 0 0.00281905 l
+0.231676 -0.3381 0.249877 -0.335489 0 0 0 0.00281905 l
+0.876144 -0.0122709 0.881237 -0.0195923 0 0 0 0.00281905 l
+0.876144 -0.0122709 0.864351 -0.0133905 0 0 0 0.00281905 l
+-0.334105 -0.374717 -0.322736 -0.361179 0 0 0 0.00281905 l
+-0.334105 -0.374717 -0.323343 -0.380418 0 0 0 0.00281905 l
+0.339541 0.739961 0.353574 0.725216 0 0 0 0.00281905 l
+-0.274967 0.939157 -0.257386 0.964242 0 0 0 0.00281905 l
+-0.274967 0.939157 -0.277429 0.928931 0 0 0 0.00281905 l
+0.0989089 -0.050982 0.10117 -0.0686018 0 0 0 0.00281905 l
+0.0989089 -0.050982 0.087134 -0.0525296 0 0 0 0.00281905 l
+-0.112119 -0.119998 -0.112317 -0.137708 0 0 0 0.00281905 l
+-0.112119 -0.119998 -0.102639 -0.111258 0 0 0 0.00281905 l
+0.36732 -0.735841 0.37511 -0.730826 0 0 0 0.00281905 l
+0.36732 -0.735841 0.35872 -0.745973 0 0 0 0.00281905 l
+0.567557 0.760158 0.579712 0.753556 0 0 0 0.00281905 l
+0.567557 0.760158 0.564501 0.76548 0 0 0 0.00281905 l
+0.63084 -0.287456 0.633164 -0.295608 0 0 0 0.00281905 l
+0.63084 -0.287456 0.615475 -0.278579 0 0 0 0.00281905 l
+-0.853355 -0.327329 -0.841928 -0.316044 0 0 0 0.00281905 l
+-0.853355 -0.327329 -0.84803 -0.331353 0 0 0 0.00281905 l
+-0.853355 -0.327329 -0.857228 -0.330649 0 0 0 0.00281905 l
+-0.179744 -0.127444 -0.189503 -0.134121 0 0 0 0.00281905 l
+0.453917 -0.504761 0.468978 -0.485117 0 0 0 0.00281905 l
+0.453917 -0.504761 0.448656 -0.513246 0 0 0 0.00281905 l
+0.0643814 -0.23302 0.0688759 -0.246198 0 0 0 0.00281905 l
+0.0643814 -0.23302 0.0642345 -0.22297 0 0 0 0.00281905 l
+0.0643814 -0.23302 0.0579499 -0.235702 0 0 0 0.00281905 l
+0.219042 0.0766828 0.202217 0.0720466 0 0 0 0.00281905 l
+0.498603 0.784029 0.486021 0.770694 0 0 0 0.00281905 l
+0.498603 0.784029 0.48529 0.795926 0 0 0 0.00281905 l
+-0.0593924 0.558626 -0.0424917 0.555068 0 0 0 0.00281905 l
+-0.151316 -0.185469 -0.150856 -0.188925 0 0 0 0.00281905 l
+-0.151316 -0.185469 -0.158768 -0.177634 0 0 0 0.00281905 l
+0.53825 0.581333 0.546767 0.565425 0 0 0 0.00281905 l
+0.53825 0.581333 0.544399 0.58672 0 0 0 0.00281905 l
+0.53825 0.581333 0.521226 0.582454 0 0 0 0.00281905 l
+-0.6645 -0.606877 -0.656992 -0.619102 0 0 0 0.00281905 l
+-0.6645 -0.606877 -0.678277 -0.592325 0 0 0 0.00281905 l
+-0.431347 -0.629727 -0.436571 -0.641834 0 0 0 0.00281905 l
+-0.431347 -0.629727 -0.426274 -0.627145 0 0 0 0.00281905 l
+0.344723 -0.218604 0.351245 -0.208525 0 0 0 0.00281905 l
+0.344723 -0.218604 0.33991 -0.226179 0 0 0 0.00281905 l
+0.344723 -0.218604 0.332066 -0.213717 0 0 0 0.00281905 l
+-0.886975 -0.165767 -0.879772 -0.164604 0 0 0 0.00281905 l
+-0.886975 -0.165767 -0.898325 -0.158439 0 0 0 0.00281905 l
+-0.882509 -0.391047 -0.866332 -0.38475 0 0 0 0.00281905 l
+-0.882509 -0.391047 -0.879834 -0.40777 0 0 0 0.00281905 l
+0.515762 0.0177656 0.51156 0.0173723 0 0 0 0.00281905 l
+0.621142 0.767257 0.631603 0.763807 0 0 0 0.00281905 l
+0.408295 -0.343066 0.408412 -0.334929 0 0 0 0.00281905 l
+0.408295 -0.343066 0.407407 -0.351146 0 0 0 0.00281905 l
+-0.17744 0.305878 -0.166842 0.314475 0 0 0 0.00281905 l
+-0.17744 0.305878 -0.18381 0.297756 0 0 0 0.00281905 l
+-0.63071 -0.338245 -0.642105 -0.32284 0 0 0 0.00281905 l
+0.142111 0.970473 0.137867 0.98501 0 0 0 0.00281905 l
+0.142111 0.970473 0.160706 0.958272 0 0 0 0.00281905 l
+0.04122 0.438206 0.0426121 0.438404 0 0 0 0.00281905 l
+-0.758098 0.479709 -0.764051 0.463369 0 0 0 0.00281905 l
+-0.758098 0.479709 -0.768904 0.487576 0 0 0 0.00281905 l
+-0.192241 -0.0477515 -0.195629 -0.0436842 0 0 0 0.00281905 l
+0.786329 0.566404 0.798373 0.578077 0 0 0 0.00281905 l
+0.786329 0.566404 0.77587 0.554475 0 0 0 0.00281905 l
+-0.396734 -0.553012 -0.388716 -0.552766 0 0 0 0.00281905 l
+-0.396734 -0.553012 -0.40498 -0.546262 0 0 0 0.00281905 l
+0.45799 0.0925421 0.451803 0.0831259 0 0 0 0.00281905 l
+0.45799 0.0925421 0.455712 0.0989044 0 0 0 0.00281905 l
+0.516743 0.109334 0.52433 0.10176 0 0 0 0.00281905 l
+-0.745795 0.53071 -0.748832 0.519166 0 0 0 0.00281905 l
+-0.745795 0.53071 -0.74445 0.541903 0 0 0 0.00281905 l
+-0.27534 -0.413175 -0.283111 -0.418102 0 0 0 0.00281905 l
+0.123875 0.989201 0.137867 0.98501 0 0 0 0.00281905 l
+0.123875 0.989201 0.1006 0.992089 0 0 0 0.00281905 l
+-0.551642 -0.255386 -0.548027 -0.240373 0 0 0 0.00281905 l
+-0.551642 -0.255386 -0.537074 -0.266389 0 0 0 0.00281905 l
+0.516224 -0.646126 0.525325 -0.627025 0 0 0 0.00281905 l
+0.516224 -0.646126 0.522067 -0.651999 0 0 0 0.00281905 l
+0.516224 -0.646126 0.501581 -0.643777 0 0 0 0.00281905 l
+-0.606868 -0.52957 -0.599054 -0.538011 0 0 0 0.00281905 l
+-0.606868 -0.52957 -0.617316 -0.541915 0 0 0 0.00281905 l
+-0.606868 -0.52957 -0.617783 -0.519125 0 0 0 0.00281905 l
+0.570585 -0.500126 0.581845 -0.492748 0 0 0 0.00281905 l
+0.570585 -0.500126 0.567084 -0.489137 0 0 0 0.00281905 l
+0.564381 0.393704 0.560972 0.384013 0 0 0 0.00281905 l
+0.564381 0.393704 0.556353 0.396786 0 0 0 0.00281905 l
+0.839425 -0.508671 0.853817 -0.497713 0 0 0 0.00281905 l
+0.839425 -0.508671 0.843877 -0.533248 0 0 0 0.00281905 l
+0.839425 -0.508671 0.837658 -0.506039 0 0 0 0.00281905 l
+-0.304081 -0.952198 -0.286646 -0.934078 0 0 0 0.00281905 l
+-0.304081 -0.952198 -0.310734 -0.944469 0 0 0 0.00281905 l
+-0.673674 -0.363505 -0.679858 -0.377469 0 0 0 0.00281905 l
+-0.673674 -0.363505 -0.658252 -0.351221 0 0 0 0.00281905 l
+-0.673674 -0.363505 -0.689056 -0.349931 0 0 0 0.00281905 l
+0.804297 -0.179079 0.799716 -0.165844 0 0 0 0.00281905 l
+0.804297 -0.179079 0.816169 -0.181239 0 0 0 0.00281905 l
+0.804297 -0.179079 0.797051 -0.186499 0 0 0 0.00281905 l
+0.0878522 -0.219345 0.0942822 -0.202988 0 0 0 0.00281905 l
+0.0878522 -0.219345 0.0839629 -0.227123 0 0 0 0.00281905 l
+0.455596 0.318523 0.465921 0.30776 0 0 0 0.00281905 l
+0.5595 -0.395497 0.56037 -0.405123 0 0 0 0.00281905 l
+0.5595 -0.395497 0.556954 -0.389991 0 0 0 0.00281905 l
+0.22846 0.751789 0.238853 0.758101 0 0 0 0.00281905 l
+0.22846 0.751789 0.224202 0.745603 0 0 0 0.00281905 l
+0.22846 0.751789 0.226524 0.762432 0 0 0 0.00281905 l
+0.225665 0.0102632 0.234619 0.0197603 0 0 0 0.00281905 l
+0.225665 0.0102632 0.226128 0.00806809 0 0 0 0.00281905 l
+0.0707834 -0.0317987 0.0776741 -0.0366574 0 0 0 0.00281905 l
+0.159007 0.0549418 0.160668 0.0698119 0 0 0 0.00281905 l
+0.159007 0.0549418 0.164655 0.0450256 0 0 0 0.00281905 l
+0.159007 0.0549418 0.14366 0.0537663 0 0 0 0.00281905 l
+0.249877 -0.335489 0.261604 -0.345791 0 0 0 0.00281905 l
+0.249877 -0.335489 0.231676 -0.3381 0 0 0 0.00281905 l
+-0.056927 0.840451 -0.0559224 0.845203 0 0 0 0.00281905 l
+-0.056927 0.840451 -0.0638899 0.835924 0 0 0 0.00281905 l
+0.627468 0.0597638 0.641278 0.0609624 0 0 0 0.00281905 l
+0.627468 0.0597638 0.613597 0.0601242 0 0 0 0.00281905 l
+0.33027 -0.253005 0.329257 -0.248052 0 0 0 0.00281905 l
+0.33027 -0.253005 0.330889 -0.254308 0 0 0 0.00281905 l
+0.33027 -0.253005 0.316047 -0.25641 0 0 0 0.00281905 l
+-0.320416 -0.226373 -0.316845 -0.233723 0 0 0 0.00281905 l
+-0.215406 -0.536747 -0.203258 -0.547108 0 0 0 0.00281905 l
+-0.215406 -0.536747 -0.222689 -0.516962 0 0 0 0.00281905 l
+0.17654 0.0395066 0.164655 0.0450256 0 0 0 0.00281905 l
+-0.241066 0.283955 -0.233418 0.297107 0 0 0 0.00281905 l
+-0.241066 0.283955 -0.241008 0.27807 0 0 0 0.00281905 l
+-0.241066 0.283955 -0.25233 0.288453 0 0 0 0.00281905 l
+-0.979049 0.19193 -0.962639 0.185995 0 0 0 0.00281905 l
+-0.805306 0.440006 -0.800721 0.451438 0 0 0 0.00281905 l
+-0.805306 0.440006 -0.795837 0.425402 0 0 0 0.00281905 l
+-0.154885 -0.570194 -0.153619 -0.567161 0 0 0 0.00281905 l
+-0.631496 -0.172217 -0.624409 -0.159302 0 0 0 0.00281905 l
+-0.631496 -0.172217 -0.638436 -0.175104 0 0 0 0.00281905 l
+-0.0638176 -0.470179 -0.0563765 -0.458916 0 0 0 0.00281905 l
+-0.0638176 -0.470179 -0.0724658 -0.473547 0 0 0 0.00281905 l
+-0.48665 -0.650737 -0.481536 -0.657829 0 0 0 0.00281905 l
+-0.48665 -0.650737 -0.482362 -0.645869 0 0 0 0.00281905 l
+-0.48665 -0.650737 -0.499593 -0.652595 0 0 0 0.00281905 l
+0.513915 0.607394 0.530183 0.614006 0 0 0 0.00281905 l
+0.539924 0.735844 0.542171 0.714958 0 0 0 0.00281905 l
+0.539924 0.735844 0.540906 0.736714 0 0 0 0.00281905 l
+-0.716445 0.512732 -0.712549 0.524929 0 0 0 0.00281905 l
+-0.716445 0.512732 -0.715119 0.509589 0 0 0 0.00281905 l
+-0.13137 0.635852 -0.144684 0.640067 0 0 0 0.00281905 l
+-0.317704 -0.00147212 -0.321556 -0.0194461 0 0 0 0.00281905 l
+-0.242304 -0.892012 -0.233742 -0.891145 0 0 0 0.00281905 l
+-0.242304 -0.892012 -0.254183 -0.892282 0 0 0 0.00281905 l
+0.419142 0.228451 0.42179 0.250787 0 0 0 0.00281905 l
+0.419142 0.228451 0.425736 0.228143 0 0 0 0.00281905 l
+0.419142 0.228451 0.404587 0.220644 0 0 0 0.00281905 l
+0.0916609 0.760925 0.0924507 0.749409 0 0 0 0.00281905 l
+0.418581 -0.0533448 0.427405 -0.0578001 0 0 0 0.00281905 l
+0.418581 -0.0533448 0.405423 -0.0637036 0 0 0 0.00281905 l
+-0.395043 -0.193564 -0.387703 -0.194354 0 0 0 0.00281905 l
+-0.395043 -0.193564 -0.404371 -0.192489 0 0 0 0.00281905 l
+-0.723845 0.555401 -0.730443 0.537811 0 0 0 0.00281905 l
+-0.723845 0.555401 -0.707089 0.5613 0 0 0 0.00281905 l
+-0.723845 0.555401 -0.734606 0.56783 0 0 0 0.00281905 l
+-0.640268 -0.184745 -0.642313 -0.195259 0 0 0 0.00281905 l
+-0.640268 -0.184745 -0.638436 -0.175104 0 0 0 0.00281905 l
+-0.640268 -0.184745 -0.653991 -0.177995 0 0 0 0.00281905 l
+0.776361 -0.373834 0.787593 -0.368328 0 0 0 0.00281905 l
+0.776361 -0.373834 0.77699 -0.377769 0 0 0 0.00281905 l
+0.776361 -0.373834 0.774394 -0.370079 0 0 0 0.00281905 l
+0.177908 0.36511 0.169662 0.378507 0 0 0 0.00281905 l
+0.177908 0.36511 0.181653 0.357679 0 0 0 0.00281905 l
+0.675963 -0.622857 0.662405 -0.622525 0 0 0 0.00281905 l
+0.658085 -0.679366 0.668019 -0.688442 0 0 0 0.00281905 l
+0.286494 -0.623691 0.28701 -0.621005 0 0 0 0.00281905 l
+0.286494 -0.623691 0.276906 -0.62408 0 0 0 0.00281905 l
+0.108244 0.662783 0.118572 0.658442 0 0 0 0.00281905 l
+0.108244 0.662783 0.101019 0.667972 0 0 0 0.00281905 l
+-0.146902 0.719778 -0.157312 0.722883 0 0 0 0.00281905 l
+0.908405 -0.126191 0.904713 -0.11405 0 0 0 0.00281905 l
+0.908405 -0.126191 0.919393 -0.129885 0 0 0 0.00281905 l
+0.908405 -0.126191 0.900011 -0.141537 0 0 0 0.00281905 l
+-0.102495 0.54985 -0.0898826 0.559066 0 0 0 0.00281905 l
+-0.102495 0.54985 -0.097076 0.536034 0 0 0 0.00281905 l
+-0.751768 0.268491 -0.74049 0.280808 0 0 0 0.00281905 l
+-0.751768 0.268491 -0.760269 0.269954 0 0 0 0.00281905 l
+-0.675337 -0.218086 -0.675506 -0.22828 0 0 0 0.00281905 l
+-0.675337 -0.218086 -0.681808 -0.21889 0 0 0 0.00281905 l
+-0.186783 0.962533 -0.17541 0.976407 0 0 0 0.00281905 l
+-0.186783 0.962533 -0.19559 0.952831 0 0 0 0.00281905 l
+0.209517 0.27459 0.209964 0.270986 0 0 0 0.00281905 l
+0.822256 0.444326 0.82865 0.448759 0 0 0 0.00281905 l
+0.822256 0.444326 0.802363 0.432831 0 0 0 0.00281905 l
+-0.473648 -0.706399 -0.471945 -0.715232 0 0 0 0.00281905 l
+-0.473648 -0.706399 -0.462837 -0.702149 0 0 0 0.00281905 l
+-0.493418 0.280258 -0.489064 0.275926 0 0 0 0.00281905 l
+0.975961 -0.0728958 0.959417 -0.0520961 0 0 0 0.00281905 l
+0.975961 -0.0728958 0.979667 -0.0775116 0 0 0 0.00281905 l
+0.979803 0.113648 0.991131 0.116443 0 0 0 0.00281905 l
+0.979803 0.113648 0.977199 0.113626 0 0 0 0.00281905 l
+0.533341 -0.211796 0.556627 -0.210148 0 0 0 0.00281905 l
+0.533341 -0.211796 0.536327 -0.228528 0 0 0 0.00281905 l
+0.533341 -0.211796 0.52777 -0.210128 0 0 0 0.00281905 l
+0.527861 -0.440745 0.526648 -0.437091 0 0 0 0.00281905 l
+0.527861 -0.440745 0.547155 -0.442173 0 0 0 0.00281905 l
+-0.0153619 0.443188 -0.0127046 0.449114 0 0 0 0.00281905 l
+-0.0153619 0.443188 -0.0032994 0.435016 0 0 0 0.00281905 l
+-0.0153619 0.443188 -0.0258673 0.442291 0 0 0 0.00281905 l
+-0.881141 0.420081 -0.872738 0.405459 0 0 0 0.00281905 l
+-0.881141 0.420081 -0.879973 0.435441 0 0 0 0.00281905 l
+-0.881141 0.420081 -0.893552 0.407985 0 0 0 0.00281905 l
+0.348923 0.551491 0.353775 0.538438 0 0 0 0.00281905 l
+0.348923 0.551491 0.343073 0.548973 0 0 0 0.00281905 l
+0.595723 -0.200439 0.603018 -0.193661 0 0 0 0.00281905 l
+0.595723 -0.200439 0.583185 -0.200937 0 0 0 0.00281905 l
+0.115066 -0.640914 0.108529 -0.648492 0 0 0 0.00281905 l
+-0.0192953 -0.556493 -0.0195168 -0.562029 0 0 0 0.00281905 l
+-0.0192953 -0.556493 -0.0150999 -0.547549 0 0 0 0.00281905 l
+-0.918777 -0.0196165 -0.932611 -0.0225353 0 0 0 0.00281905 l
+0.0443173 0.665247 0.040934 0.653378 0 0 0 0.00281905 l
+0.0443173 0.665247 0.0582546 0.674468 0 0 0 0.00281905 l
+0.0443173 0.665247 0.0298122 0.669986 0 0 0 0.00281905 l
+0.360501 0.666707 0.351299 0.668055 0 0 0 0.00281905 l
+0.360501 0.666707 0.363052 0.669687 0 0 0 0.00281905 l
+0.135032 0.279408 0.132418 0.268952 0 0 0 0.00281905 l
+0.135032 0.279408 0.14625 0.283896 0 0 0 0.00281905 l
+0.135032 0.279408 0.12724 0.289268 0 0 0 0.00281905 l
+-0.2007 -0.366449 -0.200123 -0.358181 0 0 0 0.00281905 l
+-0.2007 -0.366449 -0.184492 -0.363678 0 0 0 0.00281905 l
+0.27181 -0.880524 0.265131 -0.868861 0 0 0 0.00281905 l
+0.27181 -0.880524 0.271195 -0.882071 0 0 0 0.00281905 l
+0.785901 -0.027345 0.787786 -0.0186319 0 0 0 0.00281905 l
+0.785901 -0.027345 0.780563 -0.0384472 0 0 0 0.00281905 l
+-0.450595 -0.153382 -0.433728 -0.155211 0 0 0 0.00281905 l
+-0.450595 -0.153382 -0.449746 -0.137896 0 0 0 0.00281905 l
+-0.699777 0.221204 -0.704988 0.211542 0 0 0 0.00281905 l
+-0.699777 0.221204 -0.700869 0.222902 0 0 0 0.00281905 l
+-0.684468 -0.480826 -0.671516 -0.479482 0 0 0 0.00281905 l
+-0.684468 -0.480826 -0.700484 -0.477794 0 0 0 0.00281905 l
+-0.66911 -0.0963429 -0.660567 -0.0793311 0 0 0 0.00281905 l
+-0.66911 -0.0963429 -0.667667 -0.103029 0 0 0 0.00281905 l
+0.374748 0.828994 0.385682 0.827492 0 0 0 0.00281905 l
+0.374748 0.828994 0.366186 0.838884 0 0 0 0.00281905 l
+0.148894 0.618869 0.160475 0.609493 0 0 0 0.00281905 l
+-0.0440958 0.51218 -0.0291717 0.506193 0 0 0 0.00281905 l
+-0.0440958 0.51218 -0.0540208 0.503602 0 0 0 0.00281905 l
+0.559613 -0.0427211 0.567886 -0.036734 0 0 0 0.00281905 l
+0.559613 -0.0427211 0.553637 -0.0462289 0 0 0 0.00281905 l
+-0.576291 0.435622 -0.575185 0.45215 0 0 0 0.00281905 l
+-0.576291 0.435622 -0.561719 0.432825 0 0 0 0.00281905 l
+-0.576291 0.435622 -0.578711 0.42757 0 0 0 0.00281905 l
+-0.287031 0.53537 -0.285823 0.541146 0 0 0 0.00281905 l
+-0.287031 0.53537 -0.293744 0.534802 0 0 0 0.00281905 l
+0.206386 -0.452701 0.202087 -0.440659 0 0 0 0.00281905 l
+0.206386 -0.452701 0.221343 -0.4528 0 0 0 0.00281905 l
+0.206386 -0.452701 0.208334 -0.468334 0 0 0 0.00281905 l
+-0.342521 0.390879 -0.327603 0.390484 0 0 0 0.00281905 l
+-0.342521 0.390879 -0.341145 0.380351 0 0 0 0.00281905 l
+0.386987 0.918334 0.368493 0.916552 0 0 0 0.00281905 l
+-0.228754 0.0406535 -0.210859 0.0489857 0 0 0 0.00281905 l
+0.926691 -0.231533 0.934655 -0.224693 0 0 0 0.00281905 l
+0.926691 -0.231533 0.919859 -0.24223 0 0 0 0.00281905 l
+0.552533 -0.165465 0.560795 -0.171927 0 0 0 0.00281905 l
+0.796931 0.495703 0.800641 0.49229 0 0 0 0.00281905 l
+0.796931 0.495703 0.791256 0.493034 0 0 0 0.00281905 l
+-0.70995 -0.241291 -0.703517 -0.234983 0 0 0 0.00281905 l
+0.454346 0.668484 0.455966 0.685542 0 0 0 0.00281905 l
+0.454346 0.668484 0.449204 0.663069 0 0 0 0.00281905 l
+0.12724 0.289268 0.135032 0.279408 0 0 0 0.00281905 l
+0.12724 0.289268 0.133892 0.296707 0 0 0 0.00281905 l
+-0.553575 0.296911 -0.558049 0.31138 0 0 0 0.00281905 l
+-0.553575 0.296911 -0.548204 0.290605 0 0 0 0.00281905 l
+-0.779251 -0.133185 -0.777386 -0.143678 0 0 0 0.00281905 l
+-0.779251 -0.133185 -0.764542 -0.116205 0 0 0 0.00281905 l
+-0.686952 0.385728 -0.680053 0.393509 0 0 0 0.00281905 l
+0.109904 -0.735568 0.101861 -0.721985 0 0 0 0.00281905 l
+0.375711 -0.0797612 0.375707 -0.0747375 0 0 0 0.00281905 l
+0.771424 -0.0744495 0.783857 -0.0684448 0 0 0 0.00281905 l
+0.771424 -0.0744495 0.760142 -0.0760978 0 0 0 0.00281905 l
+0.873613 0.399164 0.884383 0.403111 0 0 0 0.00281905 l
+0.873613 0.399164 0.867339 0.39768 0 0 0 0.00281905 l
+0.0307062 -0.372882 0.0433193 -0.37552 0 0 0 0.00281905 l
+0.217524 0.0312718 0.232145 0.0366373 0 0 0 0.00281905 l
+0.217524 0.0312718 0.216278 0.0357388 0 0 0 0.00281905 l
+0.221504 0.187709 0.221944 0.195347 0 0 0 0.00281905 l
+0.221504 0.187709 0.223842 0.18376 0 0 0 0.00281905 l
+0.133606 0.836049 0.143079 0.845248 0 0 0 0.00281905 l
+0.133606 0.836049 0.129981 0.837835 0 0 0 0.00281905 l
+0.919859 -0.24223 0.917445 -0.256943 0 0 0 0.00281905 l
+0.919859 -0.24223 0.926691 -0.231533 0 0 0 0.00281905 l
+0.919859 -0.24223 0.899947 -0.243244 0 0 0 0.00281905 l
+0.601055 0.050532 0.606785 0.0468362 0 0 0 0.00281905 l
+0.601055 0.050532 0.591329 0.0470849 0 0 0 0.00281905 l
+-0.0252594 -0.931069 -0.0277842 -0.945789 0 0 0 0.00281905 l
+-0.0252594 -0.931069 -0.0363511 -0.915851 0 0 0 0.00281905 l
+-0.0252594 -0.931069 -0.0177342 -0.924899 0 0 0 0.00281905 l
+-0.627898 -0.090737 -0.603287 -0.0859752 0 0 0 0.00281905 l
+-0.781186 -0.597679 -0.776374 -0.618354 0 0 0 0.00281905 l
+-0.781186 -0.597679 -0.78591 -0.585242 0 0 0 0.00281905 l
+-0.781186 -0.597679 -0.775376 -0.595248 0 0 0 0.00281905 l
+-0.781186 -0.597679 -0.794358 -0.604897 0 0 0 0.00281905 l
+-0.708834 0.584134 -0.705015 0.578656 0 0 0 0.00281905 l
+-0.708834 0.584134 -0.714406 0.588104 0 0 0 0.00281905 l
+0.176102 0.152404 0.170156 0.155711 0 0 0 0.00281905 l
+0.176102 0.152404 0.183776 0.149683 0 0 0 0.00281905 l
+0.176102 0.152404 0.174931 0.150551 0 0 0 0.00281905 l
+-0.305835 0.791328 -0.315215 0.764588 0 0 0 0.00281905 l
+-0.203261 -0.838536 -0.208438 -0.827146 0 0 0 0.00281905 l
+-0.203261 -0.838536 -0.205672 -0.855439 0 0 0 0.00281905 l
+0.13932 0.486255 0.133713 0.471947 0 0 0 0.00281905 l
+0.13932 0.486255 0.131485 0.498057 0 0 0 0.00281905 l
+0.0663631 -0.903446 0.0752201 -0.921786 0 0 0 0.00281905 l
+0.0663631 -0.903446 0.0522422 -0.891731 0 0 0 0.00281905 l
+0.319296 -0.821459 0.330579 -0.823376 0 0 0 0.00281905 l
+0.319296 -0.821459 0.321841 -0.835669 0 0 0 0.00281905 l
+0.319296 -0.821459 0.307385 -0.827747 0 0 0 0.00281905 l
+-0.338669 -0.823483 -0.34687 -0.806146 0 0 0 0.00281905 l
+-0.338669 -0.823483 -0.339971 -0.82836 0 0 0 0.00281905 l
+-0.100648 0.796427 -0.0967097 0.798948 0 0 0 0.00281905 l
+-0.367327 -0.731021 -0.371432 -0.717158 0 0 0 0.00281905 l
+-0.367327 -0.731021 -0.351745 -0.730957 0 0 0 0.00281905 l
+-0.367327 -0.731021 -0.376945 -0.745333 0 0 0 0.00281905 l
+-0.584095 0.0362237 -0.562835 0.0353538 0 0 0 0.00281905 l
+-0.584095 0.0362237 -0.607007 0.0294454 0 0 0 0.00281905 l
+-0.645734 0.647866 -0.637834 0.64708 0 0 0 0.00281905 l
+-0.645734 0.647866 -0.653977 0.642566 0 0 0 0.00281905 l
+-0.0747692 -0.361898 -0.0653536 -0.353986 0 0 0 0.00281905 l
+-0.0747692 -0.361898 -0.0925954 -0.366585 0 0 0 0.00281905 l
+-0.121469 0.0228443 -0.10296 0.0215788 0 0 0 0.00281905 l
+-0.121469 0.0228443 -0.129088 0.00746886 0 0 0 0.00281905 l
+-0.121469 0.0228443 -0.126635 0.0328223 0 0 0 0.00281905 l
+0.725049 0.28301 0.737404 0.285698 0 0 0 0.00281905 l
+0.725049 0.28301 0.723266 0.272772 0 0 0 0.00281905 l
+0.902803 0.368127 0.897424 0.367471 0 0 0 0.00281905 l
+0.165113 -0.67199 0.170373 -0.685805 0 0 0 0.00281905 l
+0.165113 -0.67199 0.158524 -0.663338 0 0 0 0.00281905 l
+0.305453 0.326939 0.310457 0.316311 0 0 0 0.00281905 l
+0.305453 0.326939 0.304707 0.334533 0 0 0 0.00281905 l
+0.305453 0.326939 0.298652 0.322982 0 0 0 0.00281905 l
+0.227774 0.876363 0.234652 0.882828 0 0 0 0.00281905 l
+0.227774 0.876363 0.222116 0.882692 0 0 0 0.00281905 l
+0.227774 0.876363 0.221653 0.87243 0 0 0 0.00281905 l
+-0.0827732 -0.00881832 -0.0828964 -0.0128834 0 0 0 0.00281905 l
+-0.0827732 -0.00881832 -0.0865835 0.000396928 0 0 0 0.00281905 l
+0.627808 0.401031 0.629432 0.399291 0 0 0 0.00281905 l
+0.41265 -0.390204 0.407429 -0.378927 0 0 0 0.00281905 l
+0.41265 -0.390204 0.410947 -0.396509 0 0 0 0.00281905 l
+0.234858 0.500228 0.24087 0.520442 0 0 0 0.00281905 l
+-0.0271955 -0.699382 -0.0278282 -0.68546 0 0 0 0.00281905 l
+-0.0271955 -0.699382 -0.0451477 -0.699731 0 0 0 0.00281905 l
+0.533305 -0.347253 0.535681 -0.331069 0 0 0 0.00281905 l
+0.50791 -0.722794 0.510146 -0.715846 0 0 0 0.00281905 l
+0.50791 -0.722794 0.511061 -0.724836 0 0 0 0.00281905 l
+0.50791 -0.722794 0.495979 -0.715204 0 0 0 0.00281905 l
+-0.170295 0.582996 -0.170797 0.565572 0 0 0 0.00281905 l
+0.641278 0.0609624 0.654161 0.0683734 0 0 0 0.00281905 l
+0.641278 0.0609624 0.627468 0.0597638 0 0 0 0.00281905 l
+0.858906 0.244625 0.861892 0.226938 0 0 0 0.00281905 l
+-0.0882687 0.900209 -0.0781155 0.912825 0 0 0 0.00281905 l
+-0.0882687 0.900209 -0.0872682 0.891965 0 0 0 0.00281905 l
+-0.0882687 0.900209 -0.100138 0.905435 0 0 0 0.00281905 l
+0.634755 0.0226904 0.623373 0.0350129 0 0 0 0.00281905 l
+-0.00249991 0.786333 -0.00387802 0.791185 0 0 0 0.00281905 l
+-0.00249991 0.786333 0.0132179 0.78833 0 0 0 0.00281905 l
+-0.00249991 0.786333 -0.00589301 0.785368 0 0 0 0.00281905 l
+-0.244068 -0.47413 -0.24324 -0.480261 0 0 0 0.00281905 l
+-0.244068 -0.47413 -0.245788 -0.472229 0 0 0 0.00281905 l
+-0.0125155 0.0459056 -0.0122085 0.054965 0 0 0 0.00281905 l
+-0.794669 -0.280692 -0.804077 -0.281375 0 0 0 0.00281905 l
+-0.626166 0.214998 -0.620771 0.220791 0 0 0 0.00281905 l
+-0.626166 0.214998 -0.632648 0.206142 0 0 0 0.00281905 l
+-0.164842 0.667286 -0.159636 0.689064 0 0 0 0.00281905 l
+-0.164842 0.667286 -0.167437 0.664779 0 0 0 0.00281905 l
+-0.00589301 0.785368 -0.00292038 0.77745 0 0 0 0.00281905 l
+-0.00589301 0.785368 -0.00249991 0.786333 0 0 0 0.00281905 l
+-0.00589301 0.785368 -0.0135983 0.788935 0 0 0 0.00281905 l
+0.187478 -0.0425438 0.207678 -0.0377392 0 0 0 0.00281905 l
+0.187478 -0.0425438 0.177645 -0.0501687 0 0 0 0.00281905 l
+0.321754 0.631699 0.324524 0.628217 0 0 0 0.00281905 l
+0.321754 0.631699 0.304278 0.635915 0 0 0 0.00281905 l
+-0.249532 -0.0990797 -0.244587 -0.109925 0 0 0 0.00281905 l
+-0.249532 -0.0990797 -0.260789 -0.105218 0 0 0 0.00281905 l
+0.25328 -0.0169596 0.262516 -0.0152054 0 0 0 0.00281905 l
+0.593057 -0.131867 0.611676 -0.127802 0 0 0 0.00281905 l
+0.593057 -0.131867 0.591195 -0.134275 0 0 0 0.00281905 l
+-0.0278282 -0.68546 -0.0188177 -0.678552 0 0 0 0.00281905 l
+-0.0278282 -0.68546 -0.0271955 -0.699382 0 0 0 0.00281905 l
+-0.0278282 -0.68546 -0.0381145 -0.676058 0 0 0 0.00281905 l
+-0.355032 -0.636769 -0.349456 -0.648455 0 0 0 0.00281905 l
+-0.355032 -0.636769 -0.367936 -0.632141 0 0 0 0.00281905 l
+0.0761579 -0.03983 0.087134 -0.0525296 0 0 0 0.00281905 l
+0.0761579 -0.03983 0.0776741 -0.0366574 0 0 0 0.00281905 l
+0.352017 0.848214 0.35261 0.840797 0 0 0 0.00281905 l
+0.196037 -0.350555 0.195188 -0.346543 0 0 0 0.00281905 l
+0.196037 -0.350555 0.194284 -0.359864 0 0 0 0.00281905 l
+-0.343741 0.226641 -0.341238 0.218049 0 0 0 0.00281905 l
+-0.844062 -0.276128 -0.835377 -0.281141 0 0 0 0.00281905 l
+-0.844062 -0.276128 -0.858749 -0.271037 0 0 0 0.00281905 l
+0.642127 0.187353 0.648307 0.178832 0 0 0 0.00281905 l
+-0.226322 -0.0699826 -0.225151 -0.0607045 0 0 0 0.00281905 l
+-0.226322 -0.0699826 -0.2181 -0.0750379 0 0 0 0.00281905 l
+0.336725 0.0034775 0.341686 0.0127917 0 0 0 0.00281905 l
+0.336725 0.0034775 0.33925 -0.00113459 0 0 0 0.00281905 l
+0.185919 0.490962 0.185566 0.498014 0 0 0 0.00281905 l
+0.185919 0.490962 0.195913 0.483755 0 0 0 0.00281905 l
+0.554193 -0.0519775 0.571925 -0.0598065 0 0 0 0.00281905 l
+0.554193 -0.0519775 0.553637 -0.0462289 0 0 0 0.00281905 l
+0.554193 -0.0519775 0.542691 -0.053891 0 0 0 0.00281905 l
+0.688901 0.311103 0.695778 0.299324 0 0 0 0.00281905 l
+0.688901 0.311103 0.688691 0.317485 0 0 0 0.00281905 l
+0.688901 0.311103 0.699667 0.313595 0 0 0 0.00281905 l
+0.747 0.315246 0.771217 0.32057 0 0 0 0.00281905 l
+-0.595225 0.70039 -0.589766 0.715339 0 0 0 0.00281905 l
+-0.595225 0.70039 -0.584045 0.686991 0 0 0 0.00281905 l
+0.714397 0.164196 0.715416 0.172852 0 0 0 0.00281905 l
+0.496982 0.270407 0.4892 0.262729 0 0 0 0.00281905 l
+0.704875 -0.253117 0.710744 -0.274289 0 0 0 0.00281905 l
+0.704875 -0.253117 0.710185 -0.244217 0 0 0 0.00281905 l
+0.704875 -0.253117 0.690749 -0.239843 0 0 0 0.00281905 l
+0.270193 0.406056 0.27769 0.393559 0 0 0 0.00281905 l
+0.270193 0.406056 0.284737 0.417406 0 0 0 0.00281905 l
+0.270193 0.406056 0.256964 0.414008 0 0 0 0.00281905 l
+-0.57318 -0.527562 -0.57727 -0.541351 0 0 0 0.00281905 l
+-0.57318 -0.527562 -0.577367 -0.526671 0 0 0 0.00281905 l
+-0.688497 -0.269883 -0.689062 -0.280872 0 0 0 0.00281905 l
+-0.481176 -0.518128 -0.466397 -0.538827 0 0 0 0.00281905 l
+-0.481176 -0.518128 -0.479225 -0.514594 0 0 0 0.00281905 l
+0.395619 -0.316126 0.401051 -0.314124 0 0 0 0.00281905 l
+0.395619 -0.316126 0.390005 -0.325993 0 0 0 0.00281905 l
+-0.368838 0.827375 -0.366863 0.839735 0 0 0 0.00281905 l
+0.160945 -0.261869 0.180118 -0.256613 0 0 0 0.00281905 l
+0.160945 -0.261869 0.143206 -0.264068 0 0 0 0.00281905 l
+-0.124159 0.0552155 -0.121978 0.0684982 0 0 0 0.00281905 l
+-0.124159 0.0552155 -0.139771 0.0526833 0 0 0 0.00281905 l
+0.444396 0.513378 0.453563 0.516157 0 0 0 0.00281905 l
+0.444396 0.513378 0.437038 0.511337 0 0 0 0.00281905 l
+-0.0638899 0.835924 -0.0687606 0.820359 0 0 0 0.00281905 l
+-0.0638899 0.835924 -0.056927 0.840451 0 0 0 0.00281905 l
+-0.430034 -0.00183504 -0.425079 -0.00381754 0 0 0 0.00281905 l
+-0.430034 -0.00183504 -0.427068 0.00136749 0 0 0 0.00281905 l
+-0.430034 -0.00183504 -0.442668 -0.00407661 0 0 0 0.00281905 l
+-0.132357 -0.0571776 -0.143157 -0.0504802 0 0 0 0.00281905 l
+0.71724 0.468448 0.724341 0.48561 0 0 0 0.00281905 l
+0.747392 0.416905 0.76173 0.423666 0 0 0 0.00281905 l
+0.0796351 0.16744 0.0931468 0.173973 0 0 0 0.00281905 l
+-0.0851098 0.81183 -0.0967097 0.798948 0 0 0 0.00281905 l
+-0.0851098 0.81183 -0.096476 0.822132 0 0 0 0.00281905 l
+0.771345 0.28501 0.769588 0.266076 0 0 0 0.00281905 l
+0.771345 0.28501 0.769971 0.296022 0 0 0 0.00281905 l
+0.771345 0.28501 0.792462 0.290358 0 0 0 0.00281905 l
+-0.0331129 0.769214 -0.0279088 0.773898 0 0 0 0.00281905 l
+-0.517019 -0.76902 -0.514247 -0.753812 0 0 0 0.00281905 l
+-0.517019 -0.76902 -0.513339 -0.786419 0 0 0 0.00281905 l
+0.449576 -0.30718 0.450188 -0.314985 0 0 0 0.00281905 l
+0.449576 -0.30718 0.43207 -0.301807 0 0 0 0.00281905 l
+0.707844 -0.427902 0.709487 -0.444744 0 0 0 0.00281905 l
+0.707844 -0.427902 0.708548 -0.42369 0 0 0 0.00281905 l
+0.707844 -0.427902 0.700614 -0.429468 0 0 0 0.00281905 l
+0.432968 -0.716918 0.433908 -0.703168 0 0 0 0.00281905 l
+0.432968 -0.716918 0.437093 -0.726236 0 0 0 0.00281905 l
+0.271976 -0.510692 0.273323 -0.503917 0 0 0 0.00281905 l
+0.271976 -0.510692 0.271985 -0.519882 0 0 0 0.00281905 l
+0.271976 -0.510692 0.261544 -0.505196 0 0 0 0.00281905 l
+0.840238 0.457341 0.850917 0.463601 0 0 0 0.00281905 l
+0.840238 0.457341 0.82865 0.448759 0 0 0 0.00281905 l
+-0.182278 0.478683 -0.187547 0.49149 0 0 0 0.00281905 l
+-0.182278 0.478683 -0.172077 0.47877 0 0 0 0.00281905 l
+-0.182278 0.478683 -0.192006 0.469847 0 0 0 0.00281905 l
+-0.836143 0.434044 -0.830022 0.426071 0 0 0 0.00281905 l
+-0.0841777 0.988438 -0.108798 0.972631 0 0 0 0.00281905 l
+0.403751 0.462313 0.407554 0.469572 0 0 0 0.00281905 l
+0.403751 0.462313 0.383358 0.469749 0 0 0 0.00281905 l
+0.210666 0.524805 0.207519 0.546127 0 0 0 0.00281905 l
+0.210666 0.524805 0.222767 0.521116 0 0 0 0.00281905 l
+0.210666 0.524805 0.209381 0.502582 0 0 0 0.00281905 l
+0.210666 0.524805 0.19411 0.521814 0 0 0 0.00281905 l
+-0.207788 0.798662 -0.191212 0.792702 0 0 0 0.00281905 l
+-0.207788 0.798662 -0.213698 0.813302 0 0 0 0.00281905 l
+-0.356519 -0.893897 -0.362956 -0.903842 0 0 0 0.00281905 l
+-0.356519 -0.893897 -0.35154 -0.886153 0 0 0 0.00281905 l
+-0.356519 -0.893897 -0.36419 -0.887224 0 0 0 0.00281905 l
+-0.0150999 -0.547549 -0.0235383 -0.535621 0 0 0 0.00281905 l
+-0.0150999 -0.547549 0.00183302 -0.554468 0 0 0 0.00281905 l
+-0.0150999 -0.547549 -0.0192953 -0.556493 0 0 0 0.00281905 l
+-0.393938 0.189907 -0.392214 0.173111 0 0 0 0.00281905 l
+-0.393938 0.189907 -0.400205 0.205982 0 0 0 0.00281905 l
+-0.393938 0.189907 -0.371889 0.192947 0 0 0 0.00281905 l
+0.216988 0.90413 0.222437 0.913039 0 0 0 0.00281905 l
+0.216988 0.90413 0.22267 0.897683 0 0 0 0.00281905 l
+0.216988 0.90413 0.20888 0.896361 0 0 0 0.00281905 l
+-0.196299 0.376307 -0.191713 0.365204 0 0 0 0.00281905 l
+-0.196299 0.376307 -0.191584 0.379903 0 0 0 0.00281905 l
+-0.5687 -0.0935616 -0.561486 -0.0741459 0 0 0 0.00281905 l
+-0.246513 0.800796 -0.240494 0.791917 0 0 0 0.00281905 l
+-0.246513 0.800796 -0.259887 0.799868 0 0 0 0.00281905 l
+-0.879834 -0.40777 -0.860894 -0.4124 0 0 0 0.00281905 l
+-0.879834 -0.40777 -0.882509 -0.391047 0 0 0 0.00281905 l
+-0.879834 -0.40777 -0.884225 -0.412282 0 0 0 0.00281905 l
+-0.748059 0.0627779 -0.742278 0.0647263 0 0 0 0.00281905 l
+-0.748059 0.0627779 -0.749671 0.0527303 0 0 0 0.00281905 l
+-0.807026 -0.558512 -0.811891 -0.546468 0 0 0 0.00281905 l
+-0.807026 -0.558512 -0.795524 -0.55775 0 0 0 0.00281905 l
+-0.0988007 -0.942085 -0.0895299 -0.942053 0 0 0 0.00281905 l
+-0.0988007 -0.942085 -0.106219 -0.948816 0 0 0 0.00281905 l
+-0.227965 -0.549005 -0.221643 -0.551992 0 0 0 0.00281905 l
+-0.227965 -0.549005 -0.235176 -0.542238 0 0 0 0.00281905 l
+-0.495271 -0.191435 -0.503779 -0.201759 0 0 0 0.00281905 l
+-0.495271 -0.191435 -0.493528 -0.187068 0 0 0 0.00281905 l
+-0.741436 0.107645 -0.734224 0.107655 0 0 0 0.00281905 l
+-0.741436 0.107645 -0.74129 0.10342 0 0 0 0.00281905 l
+0.0612338 0.0669765 0.0627133 0.0860404 0 0 0 0.00281905 l
+-0.223731 0.736607 -0.222582 0.750373 0 0 0 0.00281905 l
+-0.223731 0.736607 -0.228253 0.73746 0 0 0 0.00281905 l
+0.601043 0.162637 0.59977 0.14065 0 0 0 0.00281905 l
+0.601043 0.162637 0.600608 0.168744 0 0 0 0.00281905 l
+-0.372475 -0.386635 -0.374647 -0.396082 0 0 0 0.00281905 l
+-0.372475 -0.386635 -0.366588 -0.38263 0 0 0 0.00281905 l
+-0.32373 -0.856311 -0.323597 -0.850233 0 0 0 0.00281905 l
+-0.32373 -0.856311 -0.323036 -0.865246 0 0 0 0.00281905 l
+-0.32373 -0.856311 -0.340983 -0.860916 0 0 0 0.00281905 l
+0.595718 0.667314 0.586849 0.656822 0 0 0 0.00281905 l
+0.595718 0.667314 0.60825 0.679628 0 0 0 0.00281905 l
+-0.61972 -0.293387 -0.608271 -0.303339 0 0 0 0.00281905 l
+0.745217 0.620205 0.751109 0.623912 0 0 0 0.00281905 l
+0.745217 0.620205 0.739164 0.615745 0 0 0 0.00281905 l
+0.70533 -0.618269 0.706113 -0.614325 0 0 0 0.00281905 l
+-0.0970644 -0.739787 -0.0794952 -0.738284 0 0 0 0.00281905 l
+-0.0970644 -0.739787 -0.11117 -0.748369 0 0 0 0.00281905 l
+-0.0970644 -0.739787 -0.101404 -0.734262 0 0 0 0.00281905 l
+-0.322975 0.928799 -0.314982 0.922324 0 0 0 0.00281905 l
+-0.322975 0.928799 -0.340081 0.924799 0 0 0 0.00281905 l
+-0.045084 0.32164 -0.0453286 0.311044 0 0 0 0.00281905 l
+-0.045084 0.32164 -0.0519356 0.32514 0 0 0 0.00281905 l
+-0.422354 0.123887 -0.413606 0.104885 0 0 0 0.00281905 l
+0.240494 -0.721937 0.254677 -0.708516 0 0 0 0.00281905 l
+0.240494 -0.721937 0.252287 -0.732238 0 0 0 0.00281905 l
+0.240494 -0.721937 0.231955 -0.725177 0 0 0 0.00281905 l
+0.128471 -0.829294 0.141747 -0.839473 0 0 0 0.00281905 l
+0.128471 -0.829294 0.117494 -0.823148 0 0 0 0.00281905 l
+0.310029 0.860656 0.312997 0.85912 0 0 0 0.00281905 l
+0.43571 -0.669646 0.452094 -0.675875 0 0 0 0.00281905 l
+0.43571 -0.669646 0.422708 -0.670839 0 0 0 0.00281905 l
+0.43571 -0.669646 0.444061 -0.65849 0 0 0 0.00281905 l
+-0.565709 -0.76565 -0.56289 -0.758974 0 0 0 0.00281905 l
+-0.739787 -0.574122 -0.754147 -0.559884 0 0 0 0.00281905 l
+-0.739787 -0.574122 -0.729942 -0.567026 0 0 0 0.00281905 l
+-0.739787 -0.574122 -0.729193 -0.584785 0 0 0 0.00281905 l
+-0.160385 0.714365 -0.157729 0.705475 0 0 0 0.00281905 l
+-0.160385 0.714365 -0.157312 0.722883 0 0 0 0.00281905 l
+-0.160385 0.714365 -0.171737 0.715379 0 0 0 0.00281905 l
+0.50989 0.330449 0.523677 0.325968 0 0 0 0.00281905 l
+0.690203 0.487685 0.700394 0.48656 0 0 0 0.00281905 l
+0.690203 0.487685 0.676055 0.48027 0 0 0 0.00281905 l
+-0.522488 0.687516 -0.525165 0.698012 0 0 0 0.00281905 l
+-0.522488 0.687516 -0.535068 0.679154 0 0 0 0.00281905 l
+-0.551997 0.66562 -0.544659 0.671935 0 0 0 0.00281905 l
+-0.551997 0.66562 -0.552574 0.664521 0 0 0 0.00281905 l
+-0.358543 0.676815 -0.340774 0.680304 0 0 0 0.00281905 l
+-0.358543 0.676815 -0.360989 0.679489 0 0 0 0.00281905 l
+-0.0269046 -0.818167 -0.0116695 -0.812113 0 0 0 0.00281905 l
+-0.0269046 -0.818167 -0.0154638 -0.82834 0 0 0 0.00281905 l
+-0.0269046 -0.818167 -0.0363477 -0.814841 0 0 0 0.00281905 l
+0.751091 -0.370794 0.747603 -0.356855 0 0 0 0.00281905 l
+0.412791 0.413565 0.406068 0.415504 0 0 0 0.00281905 l
+0.0100262 0.649847 0.0137035 0.652096 0 0 0 0.00281905 l
+-0.887455 0.192491 -0.896469 0.203037 0 0 0 0.00281905 l
+-0.887455 0.192491 -0.889129 0.188042 0 0 0 0.00281905 l
+0.517781 -0.433832 0.526648 -0.437091 0 0 0 0.00281905 l
+0.517781 -0.433832 0.517008 -0.443446 0 0 0 0.00281905 l
+0.517781 -0.433832 0.511902 -0.43237 0 0 0 0.00281905 l
+0.611624 -0.0480491 0.623076 -0.0513411 0 0 0 0.00281905 l
+-0.403272 0.061426 -0.408193 0.0708045 0 0 0 0.00281905 l
+-0.403272 0.061426 -0.397254 0.0477514 0 0 0 0.00281905 l
+-0.403272 0.061426 -0.413674 0.0601514 0 0 0 0.00281905 l
+0.490662 -0.824891 0.495731 -0.830107 0 0 0 0.00281905 l
+0.490662 -0.824891 0.490211 -0.812176 0 0 0 0.00281905 l
+-0.442927 0.712748 -0.433315 0.713688 0 0 0 0.00281905 l
+-0.442927 0.712748 -0.462341 0.715359 0 0 0 0.00281905 l
+-0.69775 0.36611 -0.700504 0.348021 0 0 0 0.00281905 l
+-0.69775 0.36611 -0.676341 0.367073 0 0 0 0.00281905 l
+-0.274294 -0.388489 -0.276053 -0.376284 0 0 0 0.00281905 l
+-0.523163 -0.48391 -0.512958 -0.49666 0 0 0 0.00281905 l
+-0.523163 -0.48391 -0.537417 -0.469011 0 0 0 0.00281905 l
+0.199785 0.417592 0.199909 0.419481 0 0 0 0.00281905 l
+0.199785 0.417592 0.185558 0.406808 0 0 0 0.00281905 l
+0.326425 -0.741584 0.328071 -0.758685 0 0 0 0.00281905 l
+0.326425 -0.741584 0.328769 -0.725765 0 0 0 0.00281905 l
+-0.675101 -0.106499 -0.671022 -0.104024 0 0 0 0.00281905 l
+-0.675101 -0.106499 -0.683125 -0.104678 0 0 0 0.00281905 l
+0.899988 -0.0551984 0.894738 -0.0406066 0 0 0 0.00281905 l
+0.899988 -0.0551984 0.904671 -0.0587103 0 0 0 0.00281905 l
+-0.100373 0.208031 -0.107838 0.197453 0 0 0 0.00281905 l
+-0.100373 0.208031 -0.0981035 0.223023 0 0 0 0.00281905 l
+-0.100373 0.208031 -0.0863585 0.206015 0 0 0 0.00281905 l
+0.938311 0.342929 0.924533 0.355242 0 0 0 0.00281905 l
+-0.591159 0.45566 -0.583892 0.466734 0 0 0 0.00281905 l
+-0.591159 0.45566 -0.591356 0.450798 0 0 0 0.00281905 l
+0.833738 0.0117781 0.838387 0.0335367 0 0 0 0.00281905 l
+0.190046 -0.39205 0.180694 -0.397662 0 0 0 0.00281905 l
+0.342159 -0.0682193 0.344232 -0.0756216 0 0 0 0.00281905 l
+0.342159 -0.0682193 0.335355 -0.0717461 0 0 0 0.00281905 l
+-0.11117 -0.748369 -0.0970644 -0.739787 0 0 0 0.00281905 l
+-0.11117 -0.748369 -0.106248 -0.753759 0 0 0 0.00281905 l
+-0.11117 -0.748369 -0.123398 -0.743846 0 0 0 0.00281905 l
+-0.113673 0.960324 -0.108798 0.972631 0 0 0 0.00281905 l
+-0.113673 0.960324 -0.114812 0.954159 0 0 0 0.00281905 l
+0.311801 0.103077 0.316353 0.106837 0 0 0 0.00281905 l
+0.311801 0.103077 0.303213 0.106034 0 0 0 0.00281905 l
+-0.423156 -0.581974 -0.43689 -0.574383 0 0 0 0.00281905 l
+-0.52954 -0.374254 -0.530504 -0.384398 0 0 0 0.00281905 l
+-0.52954 -0.374254 -0.523048 -0.366127 0 0 0 0.00281905 l
+0.259507 0.502527 0.260315 0.51037 0 0 0 0.00281905 l
+0.259507 0.502527 0.256363 0.497871 0 0 0 0.00281905 l
+-0.237583 0.392216 -0.23543 0.38176 0 0 0 0.00281905 l
+-0.237583 0.392216 -0.246058 0.393407 0 0 0 0.00281905 l
+-0.398286 -0.878602 -0.405356 -0.873188 0 0 0 0.00281905 l
+0.360847 -0.140489 0.360117 -0.143042 0 0 0 0.00281905 l
+0.360847 -0.140489 0.35618 -0.135943 0 0 0 0.00281905 l
+0.587729 -0.58494 0.590093 -0.5788 0 0 0 0.00281905 l
+0.587729 -0.58494 0.584545 -0.590198 0 0 0 0.00281905 l
+0.334964 -0.258363 0.326858 -0.267852 0 0 0 0.00281905 l
+0.334964 -0.258363 0.345285 -0.256722 0 0 0 0.00281905 l
+0.334964 -0.258363 0.330889 -0.254308 0 0 0 0.00281905 l
+0.861131 -0.134606 0.865205 -0.125953 0 0 0 0.00281905 l
+-0.349456 -0.648455 -0.353627 -0.664887 0 0 0 0.00281905 l
+-0.349456 -0.648455 -0.344365 -0.645289 0 0 0 0.00281905 l
+-0.349456 -0.648455 -0.355032 -0.636769 0 0 0 0.00281905 l
+-0.222689 -0.516962 -0.215406 -0.536747 0 0 0 0.00281905 l
+-0.222689 -0.516962 -0.20408 -0.50884 0 0 0 0.00281905 l
+-0.237224 -0.663572 -0.242914 -0.678739 0 0 0 0.00281905 l
+-0.237224 -0.663572 -0.225848 -0.656221 0 0 0 0.00281905 l
+-0.237224 -0.663572 -0.248847 -0.656316 0 0 0 0.00281905 l
+0.209803 0.808755 0.202954 0.801479 0 0 0 0.00281905 l
+0.209803 0.808755 0.203336 0.811808 0 0 0 0.00281905 l
+0.473536 -0.85081 0.469294 -0.8652 0 0 0 0.00281905 l
+-0.576346 -0.353756 -0.562325 -0.349989 0 0 0 0.00281905 l
+-0.576346 -0.353756 -0.580122 -0.352681 0 0 0 0.00281905 l
+0.0607029 -0.328613 0.0677427 -0.348692 0 0 0 0.00281905 l
+0.334064 0.297101 0.348506 0.281343 0 0 0 0.00281905 l
+0.334064 0.297101 0.335631 0.301311 0 0 0 0.00281905 l
+0.334064 0.297101 0.315509 0.294034 0 0 0 0.00281905 l
+-0.746132 -0.310331 -0.7412 -0.291267 0 0 0 0.00281905 l
+-0.746132 -0.310331 -0.759482 -0.324597 0 0 0 0.00281905 l
+-0.905136 0.320191 -0.901597 0.307318 0 0 0 0.00281905 l
+-0.905136 0.320191 -0.890016 0.325201 0 0 0 0.00281905 l
+-0.905136 0.320191 -0.912446 0.321063 0 0 0 0.00281905 l
+-0.684793 0.567328 -0.673463 0.552609 0 0 0 0.00281905 l
+-0.684793 0.567328 -0.707089 0.5613 0 0 0 0.00281905 l
+-0.426274 -0.627145 -0.425685 -0.6212 0 0 0 0.00281905 l
+-0.426274 -0.627145 -0.424717 -0.628032 0 0 0 0.00281905 l
+-0.426274 -0.627145 -0.431347 -0.629727 0 0 0 0.00281905 l
+-0.457493 -0.248828 -0.449978 -0.253718 0 0 0 0.00281905 l
+-0.457493 -0.248828 -0.464087 -0.261615 0 0 0 0.00281905 l
+-0.457493 -0.248828 -0.470154 -0.234332 0 0 0 0.00281905 l
+-0.115396 -0.90128 -0.126333 -0.894108 0 0 0 0.00281905 l
+-0.115396 -0.90128 -0.120349 -0.906132 0 0 0 0.00281905 l
+0.80417 -0.561251 0.791465 -0.575392 0 0 0 0.00281905 l
+0.80417 -0.561251 0.796357 -0.554484 0 0 0 0.00281905 l
+-0.207374 0.576815 -0.203619 0.600583 0 0 0 0.00281905 l
+-0.207374 0.576815 -0.207844 0.567401 0 0 0 0.00281905 l
+0.614157 -0.531152 0.606935 -0.513012 0 0 0 0.00281905 l
+0.614157 -0.531152 0.619921 -0.544049 0 0 0 0.00281905 l
+0.614157 -0.531152 0.6041 -0.538053 0 0 0 0.00281905 l
+0.659766 0.613087 0.655195 0.622067 0 0 0 0.00281905 l
+0.659766 0.613087 0.664467 0.608874 0 0 0 0.00281905 l
+0.659766 0.613087 0.644423 0.608301 0 0 0 0.00281905 l
+-0.0147226 -0.467203 0.00516181 -0.462174 0 0 0 0.00281905 l
+-0.256745 0.90736 -0.259653 0.91724 0 0 0 0.00281905 l
+-0.256745 0.90736 -0.243749 0.908572 0 0 0 0.00281905 l
+-0.354315 -0.928944 -0.363682 -0.919595 0 0 0 0.00281905 l
+0.553445 -0.141611 0.569264 -0.137027 0 0 0 0.00281905 l
+0.553445 -0.141611 0.550505 -0.140489 0 0 0 0.00281905 l
+-0.975134 0.108805 -0.975742 0.123695 0 0 0 0.00281905 l
+-0.975134 0.108805 -0.965907 0.0985085 0 0 0 0.00281905 l
+0.357808 -0.156312 0.362232 -0.168432 0 0 0 0.00281905 l
+0.357808 -0.156312 0.357444 -0.149104 0 0 0 0.00281905 l
+0.357808 -0.156312 0.339987 -0.163737 0 0 0 0.00281905 l
+0.790301 0.144134 0.798274 0.14474 0 0 0 0.00281905 l
+0.790301 0.144134 0.791534 0.136547 0 0 0 0.00281905 l
+0.790301 0.144134 0.788023 0.145556 0 0 0 0.00281905 l
+0.203573 -0.625541 0.220241 -0.622547 0 0 0 0.00281905 l
+0.203573 -0.625541 0.19215 -0.624236 0 0 0 0.00281905 l
+-0.867518 -0.380522 -0.869859 -0.361154 0 0 0 0.00281905 l
+-0.867518 -0.380522 -0.850442 -0.373911 0 0 0 0.00281905 l
+-0.867518 -0.380522 -0.866332 -0.38475 0 0 0 0.00281905 l
+0.590183 0.0540321 0.598111 0.0639224 0 0 0 0.00281905 l
+0.590183 0.0540321 0.591329 0.0470849 0 0 0 0.00281905 l
+0.57513 0.0312002 0.566852 0.012537 0 0 0 0.00281905 l
+0.57513 0.0312002 0.580282 0.0317056 0 0 0 0.00281905 l
+-0.625335 0.367173 -0.646701 0.365267 0 0 0 0.00281905 l
+-0.915991 -0.36293 -0.91346 -0.385921 0 0 0 0.00281905 l
+-0.915991 -0.36293 -0.914069 -0.35129 0 0 0 0.00281905 l
+-0.915991 -0.36293 -0.929504 -0.364608 0 0 0 0.00281905 l
+-0.0091847 -0.184857 -0.00805386 -0.170471 0 0 0 0.00281905 l
+-0.0091847 -0.184857 -0.00285242 -0.184346 0 0 0 0.00281905 l
+0.294643 -0.355377 0.292673 -0.339847 0 0 0 0.00281905 l
+0.294643 -0.355377 0.29333 -0.359338 0 0 0 0.00281905 l
+-0.571028 0.625922 -0.579142 0.614841 0 0 0 0.00281905 l
+-0.571028 0.625922 -0.56582 0.631636 0 0 0 0.00281905 l
+-0.716756 0.631178 -0.715108 0.62595 0 0 0 0.00281905 l
+-0.716756 0.631178 -0.713042 0.637909 0 0 0 0.00281905 l
+-0.839918 0.0786497 -0.83303 0.0920831 0 0 0 0.00281905 l
+0.835719 -0.412359 0.830459 -0.404711 0 0 0 0.00281905 l
+0.835719 -0.412359 0.845329 -0.41322 0 0 0 0.00281905 l
+0.835719 -0.412359 0.825552 -0.415757 0 0 0 0.00281905 l
+-0.121946 -0.793189 -0.118986 -0.782435 0 0 0 0.00281905 l
+-0.121946 -0.793189 -0.111745 -0.794424 0 0 0 0.00281905 l
+-0.121946 -0.793189 -0.137867 -0.797582 0 0 0 0.00281905 l
+0.172141 -0.727241 0.18006 -0.713056 0 0 0 0.00281905 l
+0.172141 -0.727241 0.175755 -0.734076 0 0 0 0.00281905 l
+0.172141 -0.727241 0.159504 -0.722235 0 0 0 0.00281905 l
+-0.368318 0.0954764 -0.350873 0.103311 0 0 0 0.00281905 l
+-0.368318 0.0954764 -0.38448 0.0977041 0 0 0 0.00281905 l
+-0.229227 -0.274779 -0.230241 -0.270756 0 0 0 0.00281905 l
+-0.229227 -0.274779 -0.233367 -0.276709 0 0 0 0.00281905 l
+0.0606098 -0.281203 0.0603967 -0.267275 0 0 0 0.00281905 l
+0.0606098 -0.281203 0.0592835 -0.296391 0 0 0 0.00281905 l
+0.348141 0.243797 0.348322 0.241077 0 0 0 0.00281905 l
+0.348141 0.243797 0.345347 0.251955 0 0 0 0.00281905 l
+-0.126505 0.974443 -0.11197 0.977427 0 0 0 0.00281905 l
+-0.126505 0.974443 -0.149111 0.981705 0 0 0 0.00281905 l
+0.164655 0.0450256 0.159007 0.0549418 0 0 0 0.00281905 l
+0.164655 0.0450256 0.17654 0.0395066 0 0 0 0.00281905 l
+0.164655 0.0450256 0.157892 0.0372881 0 0 0 0.00281905 l
+-0.561806 -0.382839 -0.555383 -0.398187 0 0 0 0.00281905 l
+-0.561806 -0.382839 -0.570562 -0.377246 0 0 0 0.00281905 l
+-0.731263 0.0147989 -0.716227 0.0237814 0 0 0 0.00281905 l
+-0.731263 0.0147989 -0.744458 0.0251737 0 0 0 0.00281905 l
+-0.731263 0.0147989 -0.731026 0.0131338 0 0 0 0.00281905 l
+0.980309 -0.161384 0.983031 -0.173375 0 0 0 0.00281905 l
+0.980309 -0.161384 0.981781 -0.155444 0 0 0 0.00281905 l
+0.331127 0.131862 0.34055 0.118659 0 0 0 0.00281905 l
+0.331127 0.131862 0.320178 0.119231 0 0 0 0.00281905 l
+0.331127 0.131862 0.332869 0.135137 0 0 0 0.00281905 l
+0.0775398 0.362226 0.091636 0.373105 0 0 0 0.00281905 l
+0.0775398 0.362226 0.0697739 0.34719 0 0 0 0.00281905 l
+0.0775398 0.362226 0.069408 0.368243 0 0 0 0.00281905 l
+0.256342 0.0400094 0.263049 0.0552656 0 0 0 0.00281905 l
+0.256342 0.0400094 0.260702 0.038137 0 0 0 0.00281905 l
+0.256342 0.0400094 0.249946 0.0349665 0 0 0 0.00281905 l
+0.79524 0.470555 0.805232 0.474603 0 0 0 0.00281905 l
+0.79524 0.470555 0.787474 0.455728 0 0 0 0.00281905 l
+-0.268315 -0.823231 -0.269505 -0.813911 0 0 0 0.00281905 l
+-0.268315 -0.823231 -0.263176 -0.824586 0 0 0 0.00281905 l
+-0.0848113 0.596496 -0.0896443 0.579323 0 0 0 0.00281905 l
+0.0406878 0.832308 0.037721 0.818623 0 0 0 0.00281905 l
+0.0406878 0.832308 0.0377139 0.832649 0 0 0 0.00281905 l
+-0.730473 0.453691 -0.714001 0.451106 0 0 0 0.00281905 l
+-0.730473 0.453691 -0.72461 0.465363 0 0 0 0.00281905 l
+0.00108654 -0.366223 -0.00100853 -0.358107 0 0 0 0.00281905 l
+0.00108654 -0.366223 0.00122309 -0.380146 0 0 0 0.00281905 l
+0.00108654 -0.366223 -0.0179926 -0.369543 0 0 0 0.00281905 l
+-0.441834 0.0846763 -0.443444 0.0722929 0 0 0 0.00281905 l
+-0.441834 0.0846763 -0.44341 0.090064 0 0 0 0.00281905 l
+-0.441834 0.0846763 -0.43567 0.0848271 0 0 0 0.00281905 l
+0.307095 0.148788 0.308352 0.135018 0 0 0 0.00281905 l
+0.307095 0.148788 0.313327 0.153464 0 0 0 0.00281905 l
+-0.857238 -0.430194 -0.855926 -0.42098 0 0 0 0.00281905 l
+-0.857238 -0.430194 -0.857543 -0.433766 0 0 0 0.00281905 l
+0.216719 0.940047 0.223491 0.955471 0 0 0 0.00281905 l
+0.216719 0.940047 0.219064 0.936417 0 0 0 0.00281905 l
+-0.505484 0.520282 -0.508414 0.505237 0 0 0 0.00281905 l
+-0.505484 0.520282 -0.525175 0.524571 0 0 0 0.00281905 l
+0.164432 0.0811077 0.160668 0.0698119 0 0 0 0.00281905 l
+0.164432 0.0811077 0.185205 0.0861395 0 0 0 0.00281905 l
+-0.632388 0.286165 -0.627689 0.292287 0 0 0 0.00281905 l
+-0.632388 0.286165 -0.636371 0.272648 0 0 0 0.00281905 l
+-0.549839 0.0794188 -0.55741 0.0834508 0 0 0 0.00281905 l
+-0.0382336 0.38314 -0.0277273 0.374333 0 0 0 0.00281905 l
+-0.0382336 0.38314 -0.0440233 0.369389 0 0 0 0.00281905 l
+-0.0382336 0.38314 -0.0484316 0.387525 0 0 0 0.00281905 l
+0.731735 -0.359658 0.729012 -0.374956 0 0 0 0.00281905 l
+0.731735 -0.359658 0.747603 -0.356855 0 0 0 0.00281905 l
+-0.34493 -0.1493 -0.336929 -0.162724 0 0 0 0.00281905 l
+-0.34493 -0.1493 -0.350309 -0.13245 0 0 0 0.00281905 l
+-0.34493 -0.1493 -0.362215 -0.153335 0 0 0 0.00281905 l
+0.265166 -0.488598 0.256226 -0.472325 0 0 0 0.00281905 l
+0.265166 -0.488598 0.261544 -0.505196 0 0 0 0.00281905 l
+-0.730443 0.537811 -0.723845 0.555401 0 0 0 0.00281905 l
+-0.730443 0.537811 -0.723944 0.52891 0 0 0 0.00281905 l
+-0.730443 0.537811 -0.74445 0.541903 0 0 0 0.00281905 l
+0.370464 -0.121836 0.379045 -0.122598 0 0 0 0.00281905 l
+0.330474 -0.908754 0.333196 -0.893782 0 0 0 0.00281905 l
+0.330474 -0.908754 0.324558 -0.913296 0 0 0 0.00281905 l
+-0.6823 -0.136453 -0.670146 -0.142618 0 0 0 0.00281905 l
+-0.6823 -0.136453 -0.697507 -0.126742 0 0 0 0.00281905 l
+-0.582977 -0.788475 -0.567876 -0.793593 0 0 0 0.00281905 l
+-0.582977 -0.788475 -0.595482 -0.794517 0 0 0 0.00281905 l
+0.747603 -0.356855 0.751091 -0.370794 0 0 0 0.00281905 l
+0.747603 -0.356855 0.745713 -0.348265 0 0 0 0.00281905 l
+0.747603 -0.356855 0.731735 -0.359658 0 0 0 0.00281905 l
+0.937739 0.165372 0.936224 0.149538 0 0 0 0.00281905 l
+-0.318006 -0.187835 -0.316057 -0.198608 0 0 0 0.00281905 l
+-0.318006 -0.187835 -0.312765 -0.175179 0 0 0 0.00281905 l
+-0.318006 -0.187835 -0.33107 -0.185575 0 0 0 0.00281905 l
+0.606785 0.0468362 0.613597 0.0601242 0 0 0 0.00281905 l
+0.606785 0.0468362 0.623373 0.0350129 0 0 0 0.00281905 l
+0.606785 0.0468362 0.601055 0.050532 0 0 0 0.00281905 l
+0.583453 0.345888 0.587043 0.337787 0 0 0 0.00281905 l
+0.583453 0.345888 0.571451 0.344153 0 0 0 0.00281905 l
+-0.0487333 0.664967 -0.0543427 0.668241 0 0 0 0.00281905 l
+-0.0487333 0.664967 -0.0465954 0.666337 0 0 0 0.00281905 l
+-0.519931 -0.65778 -0.524123 -0.641862 0 0 0 0.00281905 l
+-0.892247 -0.250573 -0.888712 -0.239626 0 0 0 0.00281905 l
+0.242412 0.737554 0.243925 0.728833 0 0 0 0.00281905 l
+0.74435 0.286138 0.740601 0.284847 0 0 0 0.00281905 l
+-0.0230444 -0.44461 -0.0194356 -0.44439 0 0 0 0.00281905 l
+-0.455688 -0.29497 -0.453774 -0.294599 0 0 0 0.00281905 l
+-0.455688 -0.29497 -0.462461 -0.301226 0 0 0 0.00281905 l
+0.27486 0.876553 0.281094 0.866988 0 0 0 0.00281905 l
+0.27486 0.876553 0.285386 0.885165 0 0 0 0.00281905 l
+-0.0781155 0.912825 -0.0882687 0.900209 0 0 0 0.00281905 l
+-0.841879 -0.0869091 -0.824154 -0.0786788 0 0 0 0.00281905 l
+-0.841879 -0.0869091 -0.850723 -0.0751691 0 0 0 0.00281905 l
+-0.841879 -0.0869091 -0.845631 -0.0935084 0 0 0 0.00281905 l
+0.417057 0.748669 0.413568 0.752051 0 0 0 0.00281905 l
+0.338071 -0.810925 0.338135 -0.818073 0 0 0 0.00281905 l
+0.338071 -0.810925 0.326809 -0.793271 0 0 0 0.00281905 l
+-0.118636 0.0756895 -0.109606 0.0862939 0 0 0 0.00281905 l
+-0.118636 0.0756895 -0.121978 0.0684982 0 0 0 0.00281905 l
+-0.443086 -0.814079 -0.444569 -0.818909 0 0 0 0.00281905 l
+-0.0408031 -0.470899 -0.0563765 -0.458916 0 0 0 0.00281905 l
+-0.116348 0.851228 -0.114744 0.850647 0 0 0 0.00281905 l
+-0.116348 0.851228 -0.121686 0.854627 0 0 0 0.00281905 l
+0.0966354 0.508299 0.11054 0.501889 0 0 0 0.00281905 l
+0.0966354 0.508299 0.0949823 0.513135 0 0 0 0.00281905 l
+-0.762815 0.399585 -0.760875 0.419338 0 0 0 0.00281905 l
+-0.762815 0.399585 -0.739144 0.403283 0 0 0 0.00281905 l
+-0.762815 0.399585 -0.768309 0.388209 0 0 0 0.00281905 l
+-0.762815 0.399585 -0.776819 0.405374 0 0 0 0.00281905 l
+-0.214708 0.0692997 -0.210859 0.0489857 0 0 0 0.00281905 l
+-0.214708 0.0692997 -0.207798 0.0764103 0 0 0 0.00281905 l
+-0.960749 -0.261062 -0.953449 -0.264674 0 0 0 0.00281905 l
+-0.960749 -0.261062 -0.96644 -0.249276 0 0 0 0.00281905 l
+0.29665 -0.741865 0.299674 -0.728258 0 0 0 0.00281905 l
+0.29665 -0.741865 0.307182 -0.752621 0 0 0 0.00281905 l
+0.29665 -0.741865 0.285754 -0.745136 0 0 0 0.00281905 l
+0.439783 -0.260834 0.44212 -0.26106 0 0 0 0.00281905 l
+0.439783 -0.260834 0.436014 -0.261119 0 0 0 0.00281905 l
+0.332165 -0.0525579 0.329383 -0.0691895 0 0 0 0.00281905 l
+-0.36419 -0.887224 -0.356519 -0.893897 0 0 0 0.00281905 l
+-0.36419 -0.887224 -0.367083 -0.887482 0 0 0 0.00281905 l
+0.0164049 0.480938 0.0238336 0.480065 0 0 0 0.00281905 l
+0.0164049 0.480938 9.33519e-05 0.476591 0 0 0 0.00281905 l
+-0.735438 -0.0249705 -0.726458 -0.00793686 0 0 0 0.00281905 l
+-0.735438 -0.0249705 -0.750297 -0.0192961 0 0 0 0.00281905 l
+0.132638 -0.71147 0.139271 -0.711176 0 0 0 0.00281905 l
+0.132638 -0.71147 0.128656 -0.714534 0 0 0 0.00281905 l
+-0.0604881 -0.785019 -0.0528354 -0.765145 0 0 0 0.00281905 l
+-0.0604881 -0.785019 -0.0575648 -0.791976 0 0 0 0.00281905 l
+-0.300672 -0.0799068 -0.300992 -0.0724428 0 0 0 0.00281905 l
+-0.300672 -0.0799068 -0.291014 -0.0788067 0 0 0 0.00281905 l
+-0.063674 -0.0383654 -0.0660427 -0.0381245 0 0 0 0.00281905 l
+-0.461833 -0.638415 -0.45147 -0.624343 0 0 0 0.00281905 l
+-0.461833 -0.638415 -0.464691 -0.643728 0 0 0 0.00281905 l
+-0.461833 -0.638415 -0.467281 -0.637469 0 0 0 0.00281905 l
+0.114991 0.321222 0.113223 0.314989 0 0 0 0.00281905 l
+0.114991 0.321222 0.101318 0.331449 0 0 0 0.00281905 l
+-0.476571 -0.342684 -0.462547 -0.3433 0 0 0 0.00281905 l
+-0.476571 -0.342684 -0.48241 -0.341168 0 0 0 0.00281905 l
+-0.159515 0.537419 -0.159651 0.553139 0 0 0 0.00281905 l
+-0.159515 0.537419 -0.153606 0.535373 0 0 0 0.00281905 l
+-0.159515 0.537419 -0.176139 0.52653 0 0 0 0.00281905 l
+0.847262 0.41219 0.864085 0.397894 0 0 0 0.00281905 l
+0.766483 -0.463035 0.786555 -0.464225 0 0 0 0.00281905 l
+0.766483 -0.463035 0.75903 -0.469819 0 0 0 0.00281905 l
+-0.634485 0.430165 -0.639116 0.451397 0 0 0 0.00281905 l
+-0.634485 0.430165 -0.638889 0.420557 0 0 0 0.00281905 l
+-0.117836 0.77589 -0.109139 0.776304 0 0 0 0.00281905 l
+-0.117836 0.77589 -0.131039 0.778038 0 0 0 0.00281905 l
+0.718738 -0.388735 0.712591 -0.406759 0 0 0 0.00281905 l
+0.718738 -0.388735 0.707581 -0.377794 0 0 0 0.00281905 l
+0.217329 0.309023 0.225558 0.307164 0 0 0 0.00281905 l
+0.217329 0.309023 0.206586 0.318078 0 0 0 0.00281905 l
+0.186391 -0.443552 0.174232 -0.458266 0 0 0 0.00281905 l
+0.186391 -0.443552 0.181076 -0.43013 0 0 0 0.00281905 l
+0.186391 -0.443552 0.195074 -0.441352 0 0 0 0.00281905 l
+0.128656 -0.714534 0.129559 -0.732384 0 0 0 0.00281905 l
+0.128656 -0.714534 0.132638 -0.71147 0 0 0 0.00281905 l
+0.128656 -0.714534 0.122985 -0.703958 0 0 0 0.00281905 l
+-0.357023 -0.606348 -0.342686 -0.612462 0 0 0 0.00281905 l
+0.409505 -0.666874 0.422708 -0.670839 0 0 0 0.00281905 l
+0.409505 -0.666874 0.404907 -0.676177 0 0 0 0.00281905 l
+0.749478 -0.2696 0.749324 -0.2716 0 0 0 0.00281905 l
+-0.614253 0.415439 -0.62117 0.404008 0 0 0 0.00281905 l
+-0.614253 0.415439 -0.615821 0.426155 0 0 0 0.00281905 l
+-0.480578 0.02679 -0.475921 0.0140014 0 0 0 0.00281905 l
+-0.480578 0.02679 -0.497804 0.0319589 0 0 0 0.00281905 l
+-0.480578 0.02679 -0.479277 0.0306757 0 0 0 0.00281905 l
+0.828789 -0.470456 0.849907 -0.47285 0 0 0 0.00281905 l
+0.828789 -0.470456 0.826242 -0.454828 0 0 0 0.00281905 l
+-0.880928 -0.214931 -0.87579 -0.21098 0 0 0 0.00281905 l
+-0.880928 -0.214931 -0.878195 -0.218833 0 0 0 0.00281905 l
+-0.880928 -0.214931 -0.883921 -0.213445 0 0 0 0.00281905 l
+-0.456557 -0.184366 -0.436441 -0.179718 0 0 0 0.00281905 l
+-0.456557 -0.184366 -0.46137 -0.183794 0 0 0 0.00281905 l
+-0.263865 -0.370285 -0.270772 -0.357836 0 0 0 0.00281905 l
+-0.263865 -0.370285 -0.253011 -0.381429 0 0 0 0.00281905 l
+-0.263865 -0.370285 -0.276053 -0.376284 0 0 0 0.00281905 l
+0.909269 0.118093 0.923665 0.117033 0 0 0 0.00281905 l
+0.909269 0.118093 0.900254 0.109507 0 0 0 0.00281905 l
+0.304145 -0.765061 0.306613 -0.757377 0 0 0 0.00281905 l
+-0.686453 -0.210814 -0.683268 -0.214773 0 0 0 0.00281905 l
+-0.395111 -0.0807875 -0.395138 -0.0793576 0 0 0 0.00281905 l
+-0.395111 -0.0807875 -0.396019 -0.0876371 0 0 0 0.00281905 l
+-0.395111 -0.0807875 -0.398191 -0.0802133 0 0 0 0.00281905 l
+0.463098 -0.32421 0.46915 -0.339966 0 0 0 0.00281905 l
+0.463098 -0.32421 0.463381 -0.317907 0 0 0 0.00281905 l
+0.463098 -0.32421 0.479758 -0.325487 0 0 0 0.00281905 l
+-0.946997 -0.194642 -0.944427 -0.183279 0 0 0 0.00281905 l
+-0.946997 -0.194642 -0.940486 -0.19875 0 0 0 0.00281905 l
+0.542652 0.384133 0.544997 0.363752 0 0 0 0.00281905 l
+0.542652 0.384133 0.560972 0.384013 0 0 0 0.00281905 l
+0.542652 0.384133 0.535091 0.401764 0 0 0 0.00281905 l
+-0.246491 0.141934 -0.242647 0.140572 0 0 0 0.00281905 l
+-0.246491 0.141934 -0.248444 0.140185 0 0 0 0.00281905 l
+0.366755 0.0550387 0.372788 0.0385112 0 0 0 0.00281905 l
+0.366755 0.0550387 0.363011 0.0600105 0 0 0 0.00281905 l
+-0.698736 -0.436966 -0.694613 -0.440951 0 0 0 0.00281905 l
+0.20098 -0.276787 0.217154 -0.288137 0 0 0 0.00281905 l
+0.20098 -0.276787 0.191317 -0.268373 0 0 0 0.00281905 l
+-0.502659 -0.553607 -0.501041 -0.544383 0 0 0 0.00281905 l
+-0.502659 -0.553607 -0.514618 -0.557571 0 0 0 0.00281905 l
+-0.930461 -0.0786856 -0.938911 -0.0659163 0 0 0 0.00281905 l
+-0.930461 -0.0786856 -0.916373 -0.087605 0 0 0 0.00281905 l
+0.495587 0.0888765 0.502249 0.0650232 0 0 0 0.00281905 l
+0.495587 0.0888765 0.49654 0.091652 0 0 0 0.00281905 l
+0.495587 0.0888765 0.487644 0.0918372 0 0 0 0.00281905 l
+-0.192347 0.401921 -0.18994 0.400256 0 0 0 0.00281905 l
+-0.192347 0.401921 -0.187927 0.412044 0 0 0 0.00281905 l
+0.476705 0.826157 0.487383 0.845846 0 0 0 0.00281905 l
+0.476705 0.826157 0.481343 0.816252 0 0 0 0.00281905 l
+0.476705 0.826157 0.469686 0.822955 0 0 0 0.00281905 l
+0.200663 0.675451 0.205685 0.673082 0 0 0 0.00281905 l
+0.200663 0.675451 0.189964 0.674076 0 0 0 0.00281905 l
+-0.0139088 -0.259357 -0.00257454 -0.266219 0 0 0 0.00281905 l
+-0.0139088 -0.259357 -0.0306524 -0.25522 0 0 0 0.00281905 l
+-0.0345044 -0.510134 -0.0355415 -0.528705 0 0 0 0.00281905 l
+-0.0345044 -0.510134 -0.0442657 -0.510682 0 0 0 0.00281905 l
+-0.249328 -0.151979 -0.256641 -0.138508 0 0 0 0.00281905 l
+-0.249328 -0.151979 -0.245941 -0.159855 0 0 0 0.00281905 l
+-0.512401 0.694281 -0.516356 0.701618 0 0 0 0.00281905 l
+-0.512401 0.694281 -0.497717 0.690533 0 0 0 0.00281905 l
+0.00751042 -0.700447 0.0102051 -0.700197 0 0 0 0.00281905 l
+0.00751042 -0.700447 -0.00185276 -0.710262 0 0 0 0.00281905 l
+0.311781 0.339964 0.327238 0.332559 0 0 0 0.00281905 l
+0.311781 0.339964 0.304707 0.334533 0 0 0 0.00281905 l
+0.696806 -0.525368 0.710059 -0.533088 0 0 0 0.00281905 l
+0.696806 -0.525368 0.691927 -0.52702 0 0 0 0.00281905 l
+-0.0176257 -0.956622 -0.0143689 -0.975676 0 0 0 0.00281905 l
+-0.0176257 -0.956622 -0.0277842 -0.945789 0 0 0 0.00281905 l
+-0.0859123 0.278073 -0.0891844 0.289279 0 0 0 0.00281905 l
+-0.0859123 0.278073 -0.0859145 0.268973 0 0 0 0.00281905 l
+0.737404 0.285698 0.740601 0.284847 0 0 0 0.00281905 l
+0.737404 0.285698 0.725049 0.28301 0 0 0 0.00281905 l
+-0.408976 0.847803 -0.411067 0.857224 0 0 0 0.00281905 l
+-0.408976 0.847803 -0.397855 0.840111 0 0 0 0.00281905 l
+-0.408976 0.847803 -0.417835 0.846606 0 0 0 0.00281905 l
+-0.753707 0.0335004 -0.744458 0.0251737 0 0 0 0.00281905 l
+-0.753707 0.0335004 -0.75783 0.0358052 0 0 0 0.00281905 l
+0.220241 -0.622547 0.224441 -0.608386 0 0 0 0.00281905 l
+0.220241 -0.622547 0.203573 -0.625541 0 0 0 0.00281905 l
+-0.187701 -0.849803 -0.184869 -0.848152 0 0 0 0.00281905 l
+-0.187701 -0.849803 -0.205672 -0.855439 0 0 0 0.00281905 l
+0.417409 0.731866 0.43393 0.734046 0 0 0 0.00281905 l
+0.417409 0.731866 0.414221 0.726052 0 0 0 0.00281905 l
+0.417409 0.731866 0.408128 0.738103 0 0 0 0.00281905 l
+0.422017 -0.591783 0.424658 -0.577795 0 0 0 0.00281905 l
+-0.142378 0.541376 -0.148329 0.531672 0 0 0 0.00281905 l
+-0.142378 0.541376 -0.124509 0.551882 0 0 0 0.00281905 l
+0.705895 0.347719 0.698812 0.359616 0 0 0 0.00281905 l
+0.705895 0.347719 0.689759 0.339326 0 0 0 0.00281905 l
+0.315353 0.919222 0.315655 0.928119 0 0 0 0.00281905 l
+0.315353 0.919222 0.317619 0.916339 0 0 0 0.00281905 l
+0.315353 0.919222 0.305174 0.913624 0 0 0 0.00281905 l
+-0.768904 0.487576 -0.758098 0.479709 0 0 0 0.00281905 l
+-0.768904 0.487576 -0.771213 0.490798 0 0 0 0.00281905 l
+0.780967 0.0702956 0.788237 0.0539035 0 0 0 0.00281905 l
+0.780967 0.0702956 0.7918 0.0742006 0 0 0 0.00281905 l
+0.780967 0.0702956 0.771035 0.0765737 0 0 0 0.00281905 l
+-0.544548 0.510971 -0.54652 0.506373 0 0 0 0.00281905 l
+-0.544548 0.510971 -0.536441 0.512308 0 0 0 0.00281905 l
+-0.544548 0.510971 -0.552082 0.511686 0 0 0 0.00281905 l
+0.600489 0.763056 0.589985 0.771528 0 0 0 0.00281905 l
+0.600489 0.763056 0.614052 0.75225 0 0 0 0.00281905 l
+0.117763 -0.304226 0.109779 -0.293058 0 0 0 0.00281905 l
+0.117763 -0.304226 0.139254 -0.30464 0 0 0 0.00281905 l
+0.259669 0.379751 0.256996 0.393832 0 0 0 0.00281905 l
+0.939095 -0.192835 0.950602 -0.191227 0 0 0 0.00281905 l
+0.939095 -0.192835 0.936278 -0.197406 0 0 0 0.00281905 l
+0.939095 -0.192835 0.936804 -0.188756 0 0 0 0.00281905 l
+-0.0312536 -0.546077 -0.0368405 -0.53993 0 0 0 0.00281905 l
+0.146575 0.708966 0.139373 0.694295 0 0 0 0.00281905 l
+0.146575 0.708966 0.145121 0.725514 0 0 0 0.00281905 l
+0.312524 0.308382 0.314846 0.30972 0 0 0 0.00281905 l
+0.312524 0.308382 0.314813 0.303022 0 0 0 0.00281905 l
+0.312524 0.308382 0.30907 0.313922 0 0 0 0.00281905 l
+-0.753516 -0.602405 -0.747448 -0.613847 0 0 0 0.00281905 l
+-0.753516 -0.602405 -0.750934 -0.597682 0 0 0 0.00281905 l
+0.269886 0.631533 0.282991 0.62965 0 0 0 0.00281905 l
+0.269886 0.631533 0.252654 0.627491 0 0 0 0.00281905 l
+-0.19479 0.212309 -0.196771 0.209016 0 0 0 0.00281905 l
+0.0872768 0.776322 0.112597 0.791504 0 0 0 0.00281905 l
+0.0872768 0.776322 0.0845045 0.775598 0 0 0 0.00281905 l
+-0.55832 0.641174 -0.554119 0.646277 0 0 0 0.00281905 l
+-0.55832 0.641174 -0.564297 0.641201 0 0 0 0.00281905 l
+-0.715564 0.642132 -0.713042 0.637909 0 0 0 0.00281905 l
+-0.715564 0.642132 -0.731756 0.651007 0 0 0 0.00281905 l
+-0.239258 0.161149 -0.22947 0.160401 0 0 0 0.00281905 l
+-0.239258 0.161149 -0.243288 0.151006 0 0 0 0.00281905 l
+-0.239258 0.161149 -0.26226 0.166617 0 0 0 0.00281905 l
+0.0762325 -0.185691 0.0705764 -0.192373 0 0 0 0.00281905 l
+-0.715794 -0.330412 -0.717235 -0.345942 0 0 0 0.00281905 l
+-0.715794 -0.330412 -0.701956 -0.321023 0 0 0 0.00281905 l
+0.959507 -0.0461685 0.959417 -0.0520961 0 0 0 0.00281905 l
+0.959507 -0.0461685 0.963257 -0.0330784 0 0 0 0.00281905 l
+0.959507 -0.0461685 0.946869 -0.0360685 0 0 0 0.00281905 l
+0.4482 -0.64025 0.444562 -0.652983 0 0 0 0.00281905 l
+0.4482 -0.64025 0.451595 -0.621061 0 0 0 0.00281905 l
+0.4482 -0.64025 0.468372 -0.636661 0 0 0 0.00281905 l
+-0.766045 0.193964 -0.765014 0.208729 0 0 0 0.00281905 l
+-0.842727 -0.150288 -0.840519 -0.162066 0 0 0 0.00281905 l
+-0.842727 -0.150288 -0.843971 -0.146253 0 0 0 0.00281905 l
+0.692175 0.124878 0.695318 0.117938 0 0 0 0.00281905 l
+0.692175 0.124878 0.686413 0.13244 0 0 0 0.00281905 l
+-0.0691141 0.7222 -0.0714956 0.714867 0 0 0 0.00281905 l
+-0.0691141 0.7222 -0.0719021 0.7269 0 0 0 0.00281905 l
+-0.800148 -0.350436 -0.796663 -0.350522 0 0 0 0.00281905 l
+-0.800148 -0.350436 -0.816974 -0.340654 0 0 0 0.00281905 l
+-0.145343 -0.672199 -0.140041 -0.673035 0 0 0 0.00281905 l
+-0.145343 -0.672199 -0.149574 -0.667372 0 0 0 0.00281905 l
+0.335077 0.582657 0.336218 0.585053 0 0 0 0.00281905 l
+0.109132 0.386105 0.0975184 0.399122 0 0 0 0.00281905 l
+0.109132 0.386105 0.115589 0.379409 0 0 0 0.00281905 l
+0.109132 0.386105 0.0973117 0.377078 0 0 0 0.00281905 l
+0.0542115 -0.471754 0.0621519 -0.475619 0 0 0 0.00281905 l
+0.0542115 -0.471754 0.0504747 -0.486319 0 0 0 0.00281905 l
+-0.505746 -0.396874 -0.495389 -0.395826 0 0 0 0.00281905 l
+-0.901392 -0.0438912 -0.901978 -0.0391823 0 0 0 0.00281905 l
+-0.373701 -0.0202088 -0.366591 -0.0177968 0 0 0 0.00281905 l
+-0.373701 -0.0202088 -0.385842 -0.0338155 0 0 0 0.00281905 l
+0.579899 -0.111787 0.570666 -0.0995152 0 0 0 0.00281905 l
+0.579899 -0.111787 0.567856 -0.120091 0 0 0 0.00281905 l
+0.222767 0.521116 0.234958 0.533418 0 0 0 0.00281905 l
+0.222767 0.521116 0.210666 0.524805 0 0 0 0.00281905 l
+0.595681 0.486023 0.598241 0.482617 0 0 0 0.00281905 l
+0.750135 0.502492 0.753179 0.495628 0 0 0 0.00281905 l
+-0.510452 0.736022 -0.495282 0.733581 0 0 0 0.00281905 l
+-0.307416 -0.377931 -0.296361 -0.378287 0 0 0 0.00281905 l
+-0.307416 -0.377931 -0.314819 -0.379943 0 0 0 0.00281905 l
+-0.072485 0.681238 -0.0690447 0.67493 0 0 0 0.00281905 l
+-0.072485 0.681238 -0.0852581 0.683158 0 0 0 0.00281905 l
+0.548013 0.428781 0.55099 0.42097 0 0 0 0.00281905 l
+0.548013 0.428781 0.538414 0.437937 0 0 0 0.00281905 l
+0.548013 0.428781 0.560222 0.433442 0 0 0 0.00281905 l
+0.551585 0.546655 0.562304 0.531496 0 0 0 0.00281905 l
+0.551585 0.546655 0.549955 0.546996 0 0 0 0.00281905 l
+0.887296 0.191698 0.88865 0.195106 0 0 0 0.00281905 l
+0.887296 0.191698 0.89125 0.185141 0 0 0 0.00281905 l
+0.887296 0.191698 0.883525 0.19432 0 0 0 0.00281905 l
+0.62448 -0.358885 0.62589 -0.34901 0 0 0 0.00281905 l
+0.62448 -0.358885 0.617002 -0.372713 0 0 0 0.00281905 l
+-0.289573 0.621302 -0.283706 0.617742 0 0 0 0.00281905 l
+-0.289573 0.621302 -0.299676 0.636399 0 0 0 0.00281905 l
+-0.289573 0.621302 -0.29672 0.612221 0 0 0 0.00281905 l
+-0.830542 0.502784 -0.814852 0.497071 0 0 0 0.00281905 l
+-0.830542 0.502784 -0.836822 0.481311 0 0 0 0.00281905 l
+-0.830542 0.502784 -0.831145 0.505183 0 0 0 0.00281905 l
+0.828253 0.510489 0.838072 0.510561 0 0 0 0.00281905 l
+-0.753655 -0.215878 -0.751991 -0.228181 0 0 0 0.00281905 l
+-0.753655 -0.215878 -0.74723 -0.205892 0 0 0 0.00281905 l
+-0.171899 0.813877 -0.164327 0.803985 0 0 0 0.00281905 l
+-0.171899 0.813877 -0.167112 0.820289 0 0 0 0.00281905 l
+-0.610157 0.243089 -0.617051 0.228609 0 0 0 0.00281905 l
+-0.610157 0.243089 -0.597354 0.250663 0 0 0 0.00281905 l
+-0.368235 0.851479 -0.351435 0.857264 0 0 0 0.00281905 l
+-0.368235 0.851479 -0.37384 0.846568 0 0 0 0.00281905 l
+-0.694 0.0567076 -0.692327 0.0676913 0 0 0 0.00281905 l
+-0.694 0.0567076 -0.703997 0.0548335 0 0 0 0.00281905 l
+0.371831 0.182955 0.380019 0.179202 0 0 0 0.00281905 l
+0.371831 0.182955 0.369379 0.189056 0 0 0 0.00281905 l
+-0.432147 -0.0382859 -0.418141 -0.0422675 0 0 0 0.00281905 l
+-0.432147 -0.0382859 -0.45184 -0.0423567 0 0 0 0.00281905 l
+-0.663896 0.434713 -0.652298 0.419798 0 0 0 0.00281905 l
+0.134447 0.525127 0.140982 0.517044 0 0 0 0.00281905 l
+0.134447 0.525127 0.140396 0.533394 0 0 0 0.00281905 l
+0.573908 0.199861 0.581534 0.186327 0 0 0 0.00281905 l
+0.213599 -0.972591 0.211318 -0.959537 0 0 0 0.00281905 l
+0.552371 -0.278153 0.566385 -0.288781 0 0 0 0.00281905 l
+0.552371 -0.278153 0.553963 -0.269853 0 0 0 0.00281905 l
+0.552371 -0.278153 0.547894 -0.286355 0 0 0 0.00281905 l
+0.816603 0.356582 0.814381 0.366699 0 0 0 0.00281905 l
+0.816603 0.356582 0.801265 0.356477 0 0 0 0.00281905 l
+0.930097 -0.0911542 0.938478 -0.0799388 0 0 0 0.00281905 l
+0.930097 -0.0911542 0.917937 -0.0994198 0 0 0 0.00281905 l
+0.125004 -0.888027 0.127453 -0.873797 0 0 0 0.00281905 l
+0.125004 -0.888027 0.130862 -0.896819 0 0 0 0.00281905 l
+0.125004 -0.888027 0.120389 -0.888028 0 0 0 0.00281905 l
+0.449938 0.211761 0.454167 0.216302 0 0 0 0.00281905 l
+-0.828208 0.27308 -0.818235 0.262678 0 0 0 0.00281905 l
+-0.828208 0.27308 -0.827296 0.286213 0 0 0 0.00281905 l
+0.0204966 -0.978261 0.029335 -0.976844 0 0 0 0.00281905 l
+0.0204966 -0.978261 0.018374 -0.976908 0 0 0 0.00281905 l
+0.726093 -0.473646 0.734915 -0.477128 0 0 0 0.00281905 l
+0.726093 -0.473646 0.726686 -0.483091 0 0 0 0.00281905 l
+0.726093 -0.473646 0.716776 -0.468322 0 0 0 0.00281905 l
+0.0984295 0.334889 0.0949823 0.348378 0 0 0 0.00281905 l
+0.0984295 0.334889 0.107177 0.340292 0 0 0 0.00281905 l
+0.0984295 0.334889 0.101318 0.331449 0 0 0 0.00281905 l
+-0.469842 -0.455161 -0.472065 -0.466637 0 0 0 0.00281905 l
+-0.469842 -0.455161 -0.470956 -0.442362 0 0 0 0.00281905 l
+-0.101502 0.50785 -0.0901915 0.505453 0 0 0 0.00281905 l
+-0.101502 0.50785 -0.0987245 0.51536 0 0 0 0.00281905 l
+-0.101502 0.50785 -0.125444 0.504397 0 0 0 0.00281905 l
+-0.187317 0.90413 -0.189934 0.898548 0 0 0 0.00281905 l
+-0.700245 -0.49365 -0.689781 -0.517476 0 0 0 0.00281905 l
+-0.700245 -0.49365 -0.703633 -0.478704 0 0 0 0.00281905 l
+-0.700245 -0.49365 -0.711124 -0.494633 0 0 0 0.00281905 l
+-0.753698 0.11143 -0.752681 0.101229 0 0 0 0.00281905 l
+0.114652 -0.18783 0.121215 -0.190181 0 0 0 0.00281905 l
+0.114652 -0.18783 0.106562 -0.192028 0 0 0 0.00281905 l
+-0.100138 0.905435 -0.0882687 0.900209 0 0 0 0.00281905 l
+-0.100138 0.905435 -0.110623 0.912427 0 0 0 0.00281905 l
+-0.576607 -0.684734 -0.557202 -0.683338 0 0 0 0.00281905 l
+-0.645632 0.409667 -0.641166 0.414921 0 0 0 0.00281905 l
+-0.645632 0.409667 -0.652297 0.407991 0 0 0 0.00281905 l
+0.409956 -0.851674 0.411076 -0.864195 0 0 0 0.00281905 l
+0.409956 -0.851674 0.401774 -0.848925 0 0 0 0.00281905 l
+-0.50986 0.456723 -0.512883 0.461347 0 0 0 0.00281905 l
+-0.50986 0.456723 -0.509305 0.452204 0 0 0 0.00281905 l
+-0.50986 0.456723 -0.515154 0.45609 0 0 0 0.00281905 l
+-0.301908 0.232097 -0.287869 0.229922 0 0 0 0.00281905 l
+-0.301908 0.232097 -0.303606 0.232468 0 0 0 0.00281905 l
+0.669319 -0.516625 0.661199 -0.526288 0 0 0 0.00281905 l
+0.437661 0.40033 0.453306 0.406275 0 0 0 0.00281905 l
+0.408421 0.190148 0.412112 0.179162 0 0 0 0.00281905 l
+0.408421 0.190148 0.391326 0.180805 0 0 0 0.00281905 l
+-0.139998 0.647854 -0.146203 0.654434 0 0 0 0.00281905 l
+-0.139998 0.647854 -0.127234 0.656106 0 0 0 0.00281905 l
+-0.139998 0.647854 -0.144684 0.640067 0 0 0 0.00281905 l
+-0.363994 -0.0365987 -0.357323 -0.0240345 0 0 0 0.00281905 l
+-0.363994 -0.0365987 -0.364598 -0.0445639 0 0 0 0.00281905 l
+-0.363994 -0.0365987 -0.365246 -0.0364193 0 0 0 0.00281905 l
+-0.254988 -0.316389 -0.244432 -0.331038 0 0 0 0.00281905 l
+-0.723302 -0.60957 -0.717098 -0.596795 0 0 0 0.00281905 l
+-0.723302 -0.60957 -0.714436 -0.614022 0 0 0 0.00281905 l
+-0.723302 -0.60957 -0.730765 -0.611932 0 0 0 0.00281905 l
+0.840439 0.111089 0.848908 0.107126 0 0 0 0.00281905 l
+0.840439 0.111089 0.837457 0.128422 0 0 0 0.00281905 l
+0.840439 0.111089 0.839071 0.107838 0 0 0 0.00281905 l
+-0.656856 -0.561098 -0.651511 -0.565413 0 0 0 0.00281905 l
+-0.656856 -0.561098 -0.675355 -0.562256 0 0 0 0.00281905 l
+0.821163 0.155555 0.813251 0.151959 0 0 0 0.00281905 l
+-0.302516 -0.905614 -0.280635 -0.905405 0 0 0 0.00281905 l
+-0.302516 -0.905614 -0.304498 -0.9172 0 0 0 0.00281905 l
+-0.302516 -0.905614 -0.312802 -0.893684 0 0 0 0.00281905 l
+0.897255 0.437277 0.880405 0.428363 0 0 0 0.00281905 l
+0.357924 -0.295427 0.362421 -0.293309 0 0 0 0.00281905 l
+0.357924 -0.295427 0.347633 -0.289008 0 0 0 0.00281905 l
+-0.859227 -0.165621 -0.869808 -0.152129 0 0 0 0.00281905 l
+-0.859227 -0.165621 -0.852209 -0.163375 0 0 0 0.00281905 l
+0.734246 0.078957 0.737552 0.0822945 0 0 0 0.00281905 l
+0.734246 0.078957 0.721541 0.083414 0 0 0 0.00281905 l
+0.271479 -0.174207 0.286321 -0.173822 0 0 0 0.00281905 l
+0.255642 -0.569986 0.251407 -0.561303 0 0 0 0.00281905 l
+0.255642 -0.569986 0.257272 -0.573043 0 0 0 0.00281905 l
+0.418283 0.879289 0.420444 0.880747 0 0 0 0.00281905 l
+0.431016 -0.101707 0.432184 -0.109052 0 0 0 0.00281905 l
+0.431016 -0.101707 0.427798 -0.0985427 0 0 0 0.00281905 l
+0.548126 0.788447 0.55632 0.780585 0 0 0 0.00281905 l
+0.548126 0.788447 0.538697 0.780587 0 0 0 0.00281905 l
+-0.417835 0.846606 -0.408976 0.847803 0 0 0 0.00281905 l
+-0.417835 0.846606 -0.421177 0.848329 0 0 0 0.00281905 l
+-0.373504 0.454747 -0.358628 0.457152 0 0 0 0.00281905 l
+-0.373504 0.454747 -0.382533 0.460775 0 0 0 0.00281905 l
+-0.668451 0.535473 -0.664714 0.525696 0 0 0 0.00281905 l
+-0.668451 0.535473 -0.673463 0.552609 0 0 0 0.00281905 l
+-0.531858 -0.428544 -0.518106 -0.424839 0 0 0 0.00281905 l
+-0.531858 -0.428544 -0.53593 -0.439548 0 0 0 0.00281905 l
+-0.274028 0.787117 -0.266857 0.793932 0 0 0 0.00281905 l
+-0.274028 0.787117 -0.276495 0.786795 0 0 0 0.00281905 l
+-0.309121 -0.14802 -0.312169 -0.148035 0 0 0 0.00281905 l
+-0.566645 -0.727059 -0.565756 -0.721479 0 0 0 0.00281905 l
+-0.566645 -0.727059 -0.554946 -0.738092 0 0 0 0.00281905 l
+-0.566645 -0.727059 -0.577564 -0.727528 0 0 0 0.00281905 l
+-0.595229 -0.440003 -0.597864 -0.449041 0 0 0 0.00281905 l
+-0.595229 -0.440003 -0.600389 -0.428305 0 0 0 0.00281905 l
+0.333915 -0.457303 0.336109 -0.479036 0 0 0 0.00281905 l
+0.333915 -0.457303 0.334693 -0.454143 0 0 0 0.00281905 l
+-0.437365 -0.0955664 -0.438738 -0.112103 0 0 0 0.00281905 l
+-0.437365 -0.0955664 -0.437549 -0.0782434 0 0 0 0.00281905 l
+0.554963 0.741949 0.561308 0.734885 0 0 0 0.00281905 l
+0.554963 0.741949 0.546888 0.753905 0 0 0 0.00281905 l
+0.554963 0.741949 0.553208 0.740577 0 0 0 0.00281905 l
+-0.869687 0.216142 -0.865592 0.219871 0 0 0 0.00281905 l
+-0.0499188 0.644873 -0.0387106 0.658106 0 0 0 0.00281905 l
+-0.0499188 0.644873 -0.0560596 0.635978 0 0 0 0.00281905 l
+0.902621 0.226426 0.906446 0.227343 0 0 0 0.00281905 l
+0.902621 0.226426 0.891256 0.232533 0 0 0 0.00281905 l
+-0.47525 0.148449 -0.461637 0.150778 0 0 0 0.00281905 l
+0.0880505 -0.423995 0.0983791 -0.418494 0 0 0 0.00281905 l
+0.0880505 -0.423995 0.0854947 -0.423539 0 0 0 0.00281905 l
+-0.916211 0.265401 -0.916704 0.269573 0 0 0 0.00281905 l
+0.516114 0.514975 0.515144 0.526468 0 0 0 0.00281905 l
+0.516114 0.514975 0.504196 0.505077 0 0 0 0.00281905 l
+0.462376 0.859505 0.46423 0.853307 0 0 0 0.00281905 l
+0.462376 0.859505 0.448512 0.872929 0 0 0 0.00281905 l
+-0.523693 0.178483 -0.527181 0.176973 0 0 0 0.00281905 l
+0.724444 0.0253599 0.72696 0.0193843 0 0 0 0.00281905 l
+0.724444 0.0253599 0.712491 0.0240388 0 0 0 0.00281905 l
+0.394945 -0.568678 0.390994 -0.580268 0 0 0 0.00281905 l
+0.394945 -0.568678 0.39227 -0.562777 0 0 0 0.00281905 l
+-0.487535 0.657567 -0.48651 0.671979 0 0 0 0.00281905 l
+-0.487535 0.657567 -0.49281 0.648633 0 0 0 0.00281905 l
+-0.239349 -0.350002 -0.2266 -0.351837 0 0 0 0.00281905 l
+-0.239349 -0.350002 -0.239855 -0.349289 0 0 0 0.00281905 l
+0.579447 -0.62234 0.578338 -0.610616 0 0 0 0.00281905 l
+0.579447 -0.62234 0.583115 -0.628053 0 0 0 0.00281905 l
+0.131622 0.019342 0.138076 0.0200819 0 0 0 0.00281905 l
+0.131622 0.019342 0.120418 0.01615 0 0 0 0.00281905 l
+-0.0311799 0.268493 -0.0139928 0.269383 0 0 0 0.00281905 l
+-0.0311799 0.268493 -0.0320103 0.269374 0 0 0 0.00281905 l
+0.341686 0.0127917 0.336725 0.0034775 0 0 0 0.00281905 l
+0.341686 0.0127917 0.326571 0.0222512 0 0 0 0.00281905 l
+-0.614966 -0.516162 -0.613744 -0.513108 0 0 0 0.00281905 l
+-0.614966 -0.516162 -0.617783 -0.519125 0 0 0 0.00281905 l
+0.588775 0.241775 0.590383 0.234249 0 0 0 0.00281905 l
+0.588775 0.241775 0.582016 0.251835 0 0 0 0.00281905 l
+0.549025 0.0298082 0.545467 0.0352446 0 0 0 0.00281905 l
+0.0493959 0.699749 0.0507665 0.706029 0 0 0 0.00281905 l
+0.0493959 0.699749 0.0407204 0.690664 0 0 0 0.00281905 l
+0.112597 0.791504 0.113133 0.790645 0 0 0 0.00281905 l
+0.112597 0.791504 0.0872768 0.776322 0 0 0 0.00281905 l
+0.0421582 -0.230135 0.0432767 -0.231503 0 0 0 0.00281905 l
+0.252127 -0.948533 0.249685 -0.958293 0 0 0 0.00281905 l
+0.252127 -0.948533 0.254885 -0.94739 0 0 0 0.00281905 l
+0.380626 -0.182453 0.383165 -0.187575 0 0 0 0.00281905 l
+0.380626 -0.182453 0.373701 -0.182546 0 0 0 0.00281905 l
+-0.392134 -0.826142 -0.385558 -0.832888 0 0 0 0.00281905 l
+-0.392134 -0.826142 -0.407277 -0.825366 0 0 0 0.00281905 l
+0.573998 0.767552 0.579482 0.769433 0 0 0 0.00281905 l
+0.573998 0.767552 0.564501 0.76548 0 0 0 0.00281905 l
+-0.243824 -0.279169 -0.245328 -0.275228 0 0 0 0.00281905 l
+-0.243824 -0.279169 -0.233367 -0.276709 0 0 0 0.00281905 l
+-0.243824 -0.279169 -0.249852 -0.27934 0 0 0 0.00281905 l
+0.911779 -0.0458675 0.908885 -0.0529987 0 0 0 0.00281905 l
+-0.277271 -0.0106778 -0.262267 -0.0163516 0 0 0 0.00281905 l
+-0.277271 -0.0106778 -0.284027 -0.00818105 0 0 0 0.00281905 l
+-0.375557 -0.887456 -0.373643 -0.895131 0 0 0 0.00281905 l
+-0.375557 -0.887456 -0.370245 -0.881833 0 0 0 0.00281905 l
+-0.18276 -0.448186 -0.174319 -0.462372 0 0 0 0.00281905 l
+0.508496 -0.366462 0.512527 -0.365928 0 0 0 0.00281905 l
+0.508496 -0.366462 0.504857 -0.372731 0 0 0 0.00281905 l
+0.604886 -0.315332 0.593958 -0.298609 0 0 0 0.00281905 l
+0.604886 -0.315332 0.620552 -0.308709 0 0 0 0.00281905 l
+0.604886 -0.315332 0.601775 -0.324231 0 0 0 0.00281905 l
+-0.157151 -0.618997 -0.143035 -0.623373 0 0 0 0.00281905 l
+0.712419 0.0137765 0.712491 0.0240388 0 0 0 0.00281905 l
+0.712419 0.0137765 0.71174 0.0107665 0 0 0 0.00281905 l
+-0.433652 0.146444 -0.429097 0.157103 0 0 0 0.00281905 l
+-0.433652 0.146444 -0.444614 0.130374 0 0 0 0.00281905 l
+0.175451 -0.0377231 0.177645 -0.0501687 0 0 0 0.00281905 l
+0.348834 0.34252 0.353828 0.343307 0 0 0 0.00281905 l
+0.348834 0.34252 0.338865 0.346673 0 0 0 0.00281905 l
+-0.444614 0.130374 -0.433652 0.146444 0 0 0 0.00281905 l
+-0.444614 0.130374 -0.460791 0.137156 0 0 0 0.00281905 l
+-0.0408841 0.675222 -0.0429912 0.68867 0 0 0 0.00281905 l
+-0.0408841 0.675222 -0.0465954 0.666337 0 0 0 0.00281905 l
+-0.332122 0.137755 -0.328946 0.135076 0 0 0 0.00281905 l
+-0.332122 0.137755 -0.344136 0.133933 0 0 0 0.00281905 l
+0.37792 -0.679004 0.397213 -0.687802 0 0 0 0.00281905 l
+0.37792 -0.679004 0.365072 -0.675384 0 0 0 0.00281905 l
+0.125309 0.308363 0.133892 0.296707 0 0 0 0.00281905 l
+0.125309 0.308363 0.113223 0.314989 0 0 0 0.00281905 l
+0.190112 0.329727 0.206586 0.318078 0 0 0 0.00281905 l
+0.190112 0.329727 0.19705 0.336669 0 0 0 0.00281905 l
+-0.5315 -0.450997 -0.53593 -0.439548 0 0 0 0.00281905 l
+-0.5315 -0.450997 -0.514227 -0.445139 0 0 0 0.00281905 l
+-0.5315 -0.450997 -0.547357 -0.456984 0 0 0 0.00281905 l
+-0.244587 -0.109925 -0.249532 -0.0990797 0 0 0 0.00281905 l
+-0.244587 -0.109925 -0.239697 -0.117029 0 0 0 0.00281905 l
+-0.859706 -0.328201 -0.857228 -0.330649 0 0 0 0.00281905 l
+-0.181919 -0.178761 -0.175667 -0.190113 0 0 0 0.00281905 l
+-0.181919 -0.178761 -0.202923 -0.183163 0 0 0 0.00281905 l
+-0.500613 -0.360754 -0.496174 -0.378905 0 0 0 0.00281905 l
+-0.500613 -0.360754 -0.4977 -0.349606 0 0 0 0.00281905 l
+-0.125784 -0.581691 -0.128793 -0.568145 0 0 0 0.00281905 l
+-0.125784 -0.581691 -0.109764 -0.574647 0 0 0 0.00281905 l
+-0.125784 -0.581691 -0.130867 -0.584762 0 0 0 0.00281905 l
+-0.49688 -0.692125 -0.493855 -0.687542 0 0 0 0.00281905 l
+-0.135481 -0.339244 -0.120663 -0.342988 0 0 0 0.00281905 l
+-0.135481 -0.339244 -0.137858 -0.336549 0 0 0 0.00281905 l
+-0.41823 -0.388103 -0.415489 -0.397931 0 0 0 0.00281905 l
+-0.41823 -0.388103 -0.413072 -0.378193 0 0 0 0.00281905 l
+-0.41823 -0.388103 -0.427536 -0.392938 0 0 0 0.00281905 l
+0.839951 -0.025237 0.835501 -0.0188345 0 0 0 0.00281905 l
+-0.515815 0.146819 -0.516558 0.137046 0 0 0 0.00281905 l
+-0.515815 0.146819 -0.528849 0.150669 0 0 0 0.00281905 l
+-0.325484 -0.202778 -0.316057 -0.198608 0 0 0 0.00281905 l
+0.449588 -0.586252 0.461054 -0.587427 0 0 0 0.00281905 l
+0.449588 -0.586252 0.446909 -0.584374 0 0 0 0.00281905 l
+0.0946041 -0.340749 0.102806 -0.354355 0 0 0 0.00281905 l
+0.0946041 -0.340749 0.0948657 -0.320846 0 0 0 0.00281905 l
+-0.0532179 -0.886292 -0.0536879 -0.869108 0 0 0 0.00281905 l
+-0.0532179 -0.886292 -0.0417472 -0.883062 0 0 0 0.00281905 l
+-0.281667 0.102973 -0.279606 0.0906622 0 0 0 0.00281905 l
+-0.281667 0.102973 -0.290325 0.102329 0 0 0 0.00281905 l
+-0.737724 -0.46699 -0.72206 -0.455203 0 0 0 0.00281905 l
+-0.737724 -0.46699 -0.741061 -0.466023 0 0 0 0.00281905 l
+-0.150818 0.323989 -0.151782 0.338207 0 0 0 0.00281905 l
+0.336218 0.585053 0.325077 0.601217 0 0 0 0.00281905 l
+0.336218 0.585053 0.335077 0.582657 0 0 0 0.00281905 l
+0.195188 -0.346543 0.196037 -0.350555 0 0 0 0.00281905 l
+0.195188 -0.346543 0.184612 -0.341872 0 0 0 0.00281905 l
+0.564501 0.76548 0.55632 0.780585 0 0 0 0.00281905 l
+0.564501 0.76548 0.573998 0.767552 0 0 0 0.00281905 l
+0.564501 0.76548 0.567557 0.760158 0 0 0 0.00281905 l
+-0.405122 0.274907 -0.40092 0.279217 0 0 0 0.00281905 l
+0.238565 0.393327 0.24714 0.401271 0 0 0 0.00281905 l
+0.238565 0.393327 0.233576 0.392689 0 0 0 0.00281905 l
+0.0664777 -0.385546 0.0575837 -0.369061 0 0 0 0.00281905 l
+-0.566709 0.00698378 -0.566634 0.014476 0 0 0 0.00281905 l
+-0.566709 0.00698378 -0.5644 0.00387959 0 0 0 0.00281905 l
+-0.566709 0.00698378 -0.583239 0.00892794 0 0 0 0.00281905 l
+-0.63985 -0.746481 -0.652747 -0.756496 0 0 0 0.00281905 l
+-0.157328 -0.171435 -0.158768 -0.177634 0 0 0 0.00281905 l
+-0.157328 -0.171435 -0.157168 -0.167997 0 0 0 0.00281905 l
+-0.157328 -0.171435 -0.154869 -0.171139 0 0 0 0.00281905 l
+-0.0724658 -0.473547 -0.0731623 -0.463906 0 0 0 0.00281905 l
+-0.0724658 -0.473547 -0.0638176 -0.470179 0 0 0 0.00281905 l
+-0.127234 0.656106 -0.118055 0.661446 0 0 0 0.00281905 l
+-0.127234 0.656106 -0.139998 0.647854 0 0 0 0.00281905 l
+0.490211 -0.812176 0.498697 -0.798856 0 0 0 0.00281905 l
+0.490211 -0.812176 0.506519 -0.814502 0 0 0 0.00281905 l
+0.490211 -0.812176 0.490662 -0.824891 0 0 0 0.00281905 l
+0.490211 -0.812176 0.482886 -0.8145 0 0 0 0.00281905 l
+0.740399 0.0813869 0.737971 0.0827268 0 0 0 0.00281905 l
+0.740399 0.0813869 0.747487 0.0868053 0 0 0 0.00281905 l
+-0.0861925 -0.210421 -0.0934927 -0.223776 0 0 0 0.00281905 l
+-0.0861925 -0.210421 -0.104369 -0.205854 0 0 0 0.00281905 l
+0.330368 -0.355955 0.332672 -0.372989 0 0 0 0.00281905 l
+0.330368 -0.355955 0.339355 -0.351328 0 0 0 0.00281905 l
+0.539256 0.126665 0.550901 0.113589 0 0 0 0.00281905 l
+0.539256 0.126665 0.534408 0.127824 0 0 0 0.00281905 l
+0.275896 0.842921 0.266673 0.847575 0 0 0 0.00281905 l
+0.454167 0.216302 0.468857 0.206916 0 0 0 0.00281905 l
+0.454167 0.216302 0.449938 0.211761 0 0 0 0.00281905 l
+0.454167 0.216302 0.447924 0.218862 0 0 0 0.00281905 l
+-0.484983 0.613739 -0.477554 0.611506 0 0 0 0.00281905 l
+-0.484983 0.613739 -0.492109 0.614196 0 0 0 0.00281905 l
+0.298412 -0.889157 0.301657 -0.884231 0 0 0 0.00281905 l
+0.399481 -0.394353 0.410947 -0.396509 0 0 0 0.00281905 l
+-0.776513 0.601194 -0.774113 0.594583 0 0 0 0.00281905 l
+-0.776513 0.601194 -0.776896 0.604854 0 0 0 0.00281905 l
+-0.776513 0.601194 -0.782457 0.595787 0 0 0 0.00281905 l
+0.640003 -0.707862 0.667598 -0.692674 0 0 0 0.00281905 l
+0.640003 -0.707862 0.64706 -0.729154 0 0 0 0.00281905 l
+0.640003 -0.707862 0.632179 -0.703072 0 0 0 0.00281905 l
+0.05447 -0.0862266 0.0538495 -0.0930439 0 0 0 0.00281905 l
+0.05447 -0.0862266 0.0603862 -0.0743883 0 0 0 0.00281905 l
+-0.836495 -0.129366 -0.828441 -0.13827 0 0 0 0.00281905 l
+-0.836495 -0.129366 -0.840833 -0.130077 0 0 0 0.00281905 l
+0.420509 0.537894 0.418817 0.54438 0 0 0 0.00281905 l
+0.420509 0.537894 0.426317 0.537675 0 0 0 0.00281905 l
+0.420509 0.537894 0.415086 0.534528 0 0 0 0.00281905 l
+0.0825767 0.958029 0.0779731 0.955177 0 0 0 0.00281905 l
+-0.184869 -0.848152 -0.187701 -0.849803 0 0 0 0.00281905 l
+-0.210473 0.495437 -0.203045 0.503336 0 0 0 0.00281905 l
+-0.210473 0.495437 -0.21432 0.496846 0 0 0 0.00281905 l
+0.936804 -0.188756 0.939095 -0.192835 0 0 0 0.00281905 l
+0.936804 -0.188756 0.920207 -0.185771 0 0 0 0.00281905 l
+-0.0589306 0.433507 -0.0551557 0.444567 0 0 0 0.00281905 l
+-0.0589306 0.433507 -0.0541708 0.419667 0 0 0 0.00281905 l
+-0.299896 0.917187 -0.295968 0.906392 0 0 0 0.00281905 l
+-0.299896 0.917187 -0.305799 0.925253 0 0 0 0.00281905 l
+-0.186073 -0.755861 -0.186841 -0.749415 0 0 0 0.00281905 l
+-0.186073 -0.755861 -0.179275 -0.758231 0 0 0 0.00281905 l
+-0.186073 -0.755861 -0.190784 -0.766683 0 0 0 0.00281905 l
+-0.186073 -0.755861 -0.200835 -0.754636 0 0 0 0.00281905 l
+0.553637 -0.0462289 0.554193 -0.0519775 0 0 0 0.00281905 l
+0.553637 -0.0462289 0.559613 -0.0427211 0 0 0 0.00281905 l
+0.165369 -0.0195056 0.155936 -0.0129222 0 0 0 0.00281905 l
+-0.844616 -0.137616 -0.843971 -0.146253 0 0 0 0.00281905 l
+-0.844616 -0.137616 -0.840833 -0.130077 0 0 0 0.00281905 l
+-0.207693 0.0786816 -0.196044 0.0774738 0 0 0 0.00281905 l
+-0.207693 0.0786816 -0.207798 0.0764103 0 0 0 0.00281905 l
+0.248154 0.809292 0.256176 0.817641 0 0 0 0.00281905 l
+0.248154 0.809292 0.23661 0.806993 0 0 0 0.00281905 l
+-0.245 0.550204 -0.23291 0.545206 0 0 0 0.00281905 l
+-0.245 0.550204 -0.255371 0.540381 0 0 0 0.00281905 l
+0.590118 0.695906 0.595709 0.703359 0 0 0 0.00281905 l
+0.590118 0.695906 0.583048 0.698489 0 0 0 0.00281905 l
+-0.608397 0.651242 -0.590882 0.65319 0 0 0 0.00281905 l
+-0.608397 0.651242 -0.616138 0.659861 0 0 0 0.00281905 l
+-0.608397 0.651242 -0.616926 0.648088 0 0 0 0.00281905 l
+0.8962 0.387087 0.884383 0.403111 0 0 0 0.00281905 l
+0.8962 0.387087 0.903975 0.383482 0 0 0 0.00281905 l
+0.8962 0.387087 0.894143 0.377623 0 0 0 0.00281905 l
+-0.794919 0.146842 -0.797721 0.159704 0 0 0 0.00281905 l
+-0.794919 0.146842 -0.788413 0.138742 0 0 0 0.00281905 l
+0.0188294 -0.973239 0.018374 -0.976908 0 0 0 0.00281905 l
+-0.460558 -0.58352 -0.4471 -0.582873 0 0 0 0.00281905 l
+-0.460558 -0.58352 -0.466824 -0.583267 0 0 0 0.00281905 l
+-0.508414 0.505237 -0.505484 0.520282 0 0 0 0.00281905 l
+-0.508414 0.505237 -0.501042 0.504486 0 0 0 0.00281905 l
+-0.903965 0.0793392 -0.892357 0.0852273 0 0 0 0.00281905 l
+-0.903965 0.0793392 -0.912412 0.0687866 0 0 0 0.00281905 l
+-0.0620178 0.514304 -0.0679505 0.532613 0 0 0 0.00281905 l
+-0.0620178 0.514304 -0.0540208 0.503602 0 0 0 0.00281905 l
+-0.0620178 0.514304 -0.0766167 0.511444 0 0 0 0.00281905 l
+0.613095 0.231129 0.619518 0.248199 0 0 0 0.00281905 l
+0.613095 0.231129 0.605241 0.226937 0 0 0 0.00281905 l
+-0.637349 -0.257038 -0.629968 -0.272836 0 0 0 0.00281905 l
+-0.575823 -0.13599 -0.565713 -0.128772 0 0 0 0.00281905 l
+-0.575823 -0.13599 -0.563199 -0.143348 0 0 0 0.00281905 l
+-0.575823 -0.13599 -0.591313 -0.138944 0 0 0 0.00281905 l
+-0.235598 -0.047461 -0.230517 -0.0565945 0 0 0 0.00281905 l
+-0.235598 -0.047461 -0.238827 -0.0455218 0 0 0 0.00281905 l
+0.111608 -0.353861 0.118286 -0.357166 0 0 0 0.00281905 l
+0.111608 -0.353861 0.102806 -0.354355 0 0 0 0.00281905 l
+-0.402621 -0.373107 -0.399967 -0.385864 0 0 0 0.00281905 l
+-0.402621 -0.373107 -0.413072 -0.378193 0 0 0 0.00281905 l
+0.814984 -0.116465 0.816767 -0.109355 0 0 0 0.00281905 l
+0.814984 -0.116465 0.811208 -0.132283 0 0 0 0.00281905 l
+0.540777 -0.0241911 0.53251 -0.00889918 0 0 0 0.00281905 l
+0.540777 -0.0241911 0.544303 -0.0265087 0 0 0 0.00281905 l
+0.540777 -0.0241911 0.528689 -0.0291657 0 0 0 0.00281905 l
+0.0238336 0.480065 0.0267661 0.489648 0 0 0 0.00281905 l
+0.0238336 0.480065 0.0239016 0.477041 0 0 0 0.00281905 l
+0.0238336 0.480065 0.0164049 0.480938 0 0 0 0.00281905 l
+0.496868 -0.563139 0.503224 -0.559041 0 0 0 0.00281905 l
+0.145019 -0.227688 0.162804 -0.212563 0 0 0 0.00281905 l
+0.145019 -0.227688 0.136857 -0.22625 0 0 0 0.00281905 l
+0.4758 -0.0203505 0.49338 -0.0123837 0 0 0 0.00281905 l
+0.4758 -0.0203505 0.471958 -0.0237207 0 0 0 0.00281905 l
+0.311709 0.191077 0.314992 0.200065 0 0 0 0.00281905 l
+0.311709 0.191077 0.31941 0.185827 0 0 0 0.00281905 l
+0.311709 0.191077 0.301107 0.192944 0 0 0 0.00281905 l
+-0.089762 0.474465 -0.0897377 0.477298 0 0 0 0.00281905 l
+-0.089762 0.474465 -0.0871538 0.473291 0 0 0 0.00281905 l
+-0.776819 0.405374 -0.762815 0.399585 0 0 0 0.00281905 l
+-0.776819 0.405374 -0.783875 0.41188 0 0 0 0.00281905 l
+-0.384272 0.568749 -0.372858 0.566488 0 0 0 0.00281905 l
+-0.384272 0.568749 -0.398062 0.562454 0 0 0 0.00281905 l
+0.800094 0.101442 0.811676 0.0858651 0 0 0 0.00281905 l
+0.800094 0.101442 0.799205 0.112785 0 0 0 0.00281905 l
+0.800094 0.101442 0.783686 0.0952758 0 0 0 0.00281905 l
+0.473387 -0.607185 0.481329 -0.598714 0 0 0 0.00281905 l
+0.473387 -0.607185 0.45813 -0.605 0 0 0 0.00281905 l
+0.674133 0.473402 0.676055 0.48027 0 0 0 0.00281905 l
+0.674133 0.473402 0.690714 0.469409 0 0 0 0.00281905 l
+0.674133 0.473402 0.666031 0.475121 0 0 0 0.00281905 l
+-0.888231 0.233895 -0.871007 0.233637 0 0 0 0.00281905 l
+-0.54037 0.765047 -0.538686 0.770699 0 0 0 0.00281905 l
+-0.54037 0.765047 -0.56261 0.757775 0 0 0 0.00281905 l
+0.235547 0.54036 0.234958 0.533418 0 0 0 0.00281905 l
+0.235547 0.54036 0.238759 0.547497 0 0 0 0.00281905 l
+-0.944281 0.187624 -0.932398 0.186754 0 0 0 0.00281905 l
+-0.944281 0.187624 -0.953943 0.191822 0 0 0 0.00281905 l
+-0.0987334 -0.147024 -0.0853062 -0.132816 0 0 0 0.00281905 l
+-0.0987334 -0.147024 -0.112317 -0.137708 0 0 0 0.00281905 l
+0.767425 0.514169 0.764545 0.50187 0 0 0 0.00281905 l
+0.767425 0.514169 0.76524 0.514898 0 0 0 0.00281905 l
+0.714044 0.0853493 0.707249 0.0971727 0 0 0 0.00281905 l
+0.714044 0.0853493 0.721541 0.083414 0 0 0 0.00281905 l
+0.714044 0.0853493 0.710869 0.0822651 0 0 0 0.00281905 l
+0.820688 0.303284 0.82381 0.292015 0 0 0 0.00281905 l
+0.820688 0.303284 0.816093 0.300971 0 0 0 0.00281905 l
+0.506519 -0.814502 0.522691 -0.821089 0 0 0 0.00281905 l
+0.506519 -0.814502 0.490211 -0.812176 0 0 0 0.00281905 l
+0.982355 0.022313 0.978191 0.00579893 0 0 0 0.00281905 l
+0.982355 0.022313 0.980622 0.0250043 0 0 0 0.00281905 l
+0.0627133 0.0860404 0.0612338 0.0669765 0 0 0 0.00281905 l
+0.0627133 0.0860404 0.0717954 0.0924075 0 0 0 0.00281905 l
+-0.524339 0.246836 -0.51419 0.239071 0 0 0 0.00281905 l
+0.298652 0.322982 0.295053 0.326162 0 0 0 0.00281905 l
+0.298652 0.322982 0.305453 0.326939 0 0 0 0.00281905 l
+-0.108183 0.708251 -0.102238 0.716016 0 0 0 0.00281905 l
+-0.0534172 0.0432871 -0.0436304 0.0340249 0 0 0 0.00281905 l
+-0.0534172 0.0432871 -0.0516829 0.0473933 0 0 0 0.00281905 l
+0.162467 -0.693333 0.170373 -0.685805 0 0 0 0.00281905 l
+0.162467 -0.693333 0.150654 -0.697445 0 0 0 0.00281905 l
+-0.275825 -0.773407 -0.263631 -0.774421 0 0 0 0.00281905 l
+-0.275825 -0.773407 -0.27372 -0.795005 0 0 0 0.00281905 l
+-0.275825 -0.773407 -0.286515 -0.769556 0 0 0 0.00281905 l
+0.909537 0.147106 0.904056 0.134811 0 0 0 0.00281905 l
+0.909537 0.147106 0.921923 0.151857 0 0 0 0.00281905 l
+-0.381654 0.482027 -0.371659 0.499413 0 0 0 0.00281905 l
+-0.704795 -0.347772 -0.689056 -0.349931 0 0 0 0.00281905 l
+-0.704795 -0.347772 -0.717235 -0.345942 0 0 0 0.00281905 l
+-0.597708 -0.476284 -0.605734 -0.470135 0 0 0 0.00281905 l
+-0.597708 -0.476284 -0.592869 -0.471337 0 0 0 0.00281905 l
+-0.597708 -0.476284 -0.599347 -0.478608 0 0 0 0.00281905 l
+0.268165 -0.778566 0.275646 -0.796359 0 0 0 0.00281905 l
+0.268165 -0.778566 0.248309 -0.780939 0 0 0 0.00281905 l
+-0.00806925 0.57144 0.00740765 0.566477 0 0 0 0.00281905 l
+-0.00806925 0.57144 -0.0129073 0.581111 0 0 0 0.00281905 l
+-0.00806925 0.57144 -0.0247685 0.562519 0 0 0 0.00281905 l
+0.00633459 -0.202663 0.00643805 -0.203806 0 0 0 0.00281905 l
+0.00633459 -0.202663 0.00180936 -0.199822 0 0 0 0.00281905 l
+-0.0143689 -0.975676 -0.0176257 -0.956622 0 0 0 0.00281905 l
+-0.0143689 -0.975676 -0.00457386 -0.9805 0 0 0 0.00281905 l
+-0.0143689 -0.975676 -0.0276785 -0.974424 0 0 0 0.00281905 l
+-0.407997 0.663841 -0.406455 0.657288 0 0 0 0.00281905 l
+-0.407997 0.663841 -0.414044 0.66508 0 0 0 0.00281905 l
+-0.0363511 -0.915851 -0.0252594 -0.931069 0 0 0 0.00281905 l
+-0.0363511 -0.915851 -0.0438899 -0.91058 0 0 0 0.00281905 l
+-0.189503 -0.134121 -0.188611 -0.139473 0 0 0 0.00281905 l
+-0.189503 -0.134121 -0.179744 -0.127444 0 0 0 0.00281905 l
+-0.58079 -0.0602753 -0.579896 -0.0517447 0 0 0 0.00281905 l
+0.0551983 -0.581011 0.0429009 -0.594552 0 0 0 0.00281905 l
+0.0551983 -0.581011 0.0615664 -0.576272 0 0 0 0.00281905 l
+-0.738605 0.320925 -0.739602 0.314042 0 0 0 0.00281905 l
+-0.738605 0.320925 -0.754327 0.33521 0 0 0 0.00281905 l
+-0.738605 0.320925 -0.733246 0.323356 0 0 0 0.00281905 l
+0.024476 0.51887 0.0256832 0.512626 0 0 0 0.00281905 l
+0.024476 0.51887 0.0233897 0.51926 0 0 0 0.00281905 l
+-0.835102 0.378157 -0.836998 0.385329 0 0 0 0.00281905 l
+-0.835102 0.378157 -0.826413 0.376953 0 0 0 0.00281905 l
+-0.524486 -0.348605 -0.523048 -0.366127 0 0 0 0.00281905 l
+-0.524486 -0.348605 -0.517117 -0.336142 0 0 0 0.00281905 l
+-0.524486 -0.348605 -0.539955 -0.35176 0 0 0 0.00281905 l
+-0.0491823 0.0782104 -0.0504062 0.0642808 0 0 0 0.00281905 l
+-0.0491823 0.0782104 -0.0401609 0.0814154 0 0 0 0.00281905 l
+-0.0491823 0.0782104 -0.0649715 0.088478 0 0 0 0.00281905 l
+-0.63171 -0.209739 -0.630034 -0.220034 0 0 0 0.00281905 l
+-0.63171 -0.209739 -0.630126 -0.203224 0 0 0 0.00281905 l
+-0.63171 -0.209739 -0.640963 -0.207745 0 0 0 0.00281905 l
+0.1048 -0.385723 0.10916 -0.389834 0 0 0 0.00281905 l
+0.1048 -0.385723 0.0984581 -0.38304 0 0 0 0.00281905 l
+-0.950454 -0.0405042 -0.948026 -0.0576251 0 0 0 0.00281905 l
+-0.950454 -0.0405042 -0.949518 -0.029842 0 0 0 0.00281905 l
+0.383568 0.125205 0.38274 0.118071 0 0 0 0.00281905 l
+0.383568 0.125205 0.386066 0.127808 0 0 0 0.00281905 l
+0.383568 0.125205 0.374583 0.125258 0 0 0 0.00281905 l
+-0.789243 0.37904 -0.781476 0.38705 0 0 0 0.00281905 l
+-0.789243 0.37904 -0.796417 0.377074 0 0 0 0.00281905 l
+-0.0194248 -0.675801 -0.0144263 -0.674143 0 0 0 0.00281905 l
+-0.0194248 -0.675801 -0.0188177 -0.678552 0 0 0 0.00281905 l
+0.265619 -0.35874 0.259811 -0.377593 0 0 0 0.00281905 l
+0.265619 -0.35874 0.261604 -0.345791 0 0 0 0.00281905 l
+-0.707755 0.259011 -0.705853 0.246135 0 0 0 0.00281905 l
+-0.707755 0.259011 -0.725539 0.271048 0 0 0 0.00281905 l
+-0.0807489 -0.869869 -0.0810374 -0.872727 0 0 0 0.00281905 l
+-0.0807489 -0.869869 -0.0768317 -0.86137 0 0 0 0.00281905 l
+-0.0807489 -0.869869 -0.0888367 -0.861559 0 0 0 0.00281905 l
+0.647717 0.754484 0.655062 0.742157 0 0 0 0.00281905 l
+0.647717 0.754484 0.637078 0.764563 0 0 0 0.00281905 l
+0.273448 0.77534 0.273243 0.768981 0 0 0 0.00281905 l
+0.273448 0.77534 0.286502 0.779093 0 0 0 0.00281905 l
+-0.448507 0.577561 -0.446563 0.586575 0 0 0 0.00281905 l
+-0.448507 0.577561 -0.450341 0.576168 0 0 0 0.00281905 l
+-0.265311 -0.284971 -0.25749 -0.283666 0 0 0 0.00281905 l
+-0.265311 -0.284971 -0.26811 -0.282987 0 0 0 0.00281905 l
+0.797051 -0.186499 0.807522 -0.207394 0 0 0 0.00281905 l
+0.797051 -0.186499 0.804297 -0.179079 0 0 0 0.00281905 l
+-0.0462363 0.351448 -0.0440233 0.369389 0 0 0 0.00281905 l
+-0.0462363 0.351448 -0.0309634 0.343431 0 0 0 0.00281905 l
+0.249946 0.0349665 0.250115 0.0297416 0 0 0 0.00281905 l
+0.249946 0.0349665 0.256342 0.0400094 0 0 0 0.00281905 l
+-0.144465 -0.722234 -0.160281 -0.705928 0 0 0 0.00281905 l
+0.122429 -0.142188 0.11191 -0.153831 0 0 0 0.00281905 l
+-0.0898826 0.559066 -0.102495 0.54985 0 0 0 0.00281905 l
+-0.0898826 0.559066 -0.0971836 0.568136 0 0 0 0.00281905 l
+0.838387 0.0335367 0.833738 0.0117781 0 0 0 0.00281905 l
+0.838387 0.0335367 0.846472 0.0338629 0 0 0 0.00281905 l
+0.838387 0.0335367 0.821282 0.032771 0 0 0 0.00281905 l
+-0.948622 0.211428 -0.939512 0.214265 0 0 0 0.00281905 l
+-0.948622 0.211428 -0.957745 0.204277 0 0 0 0.00281905 l
+0.351299 0.668055 0.360501 0.666707 0 0 0 0.00281905 l
+0.889945 0.160207 0.902641 0.160446 0 0 0 0.00281905 l
+0.889945 0.160207 0.883853 0.14962 0 0 0 0.00281905 l
+-0.649814 0.325234 -0.628293 0.319531 0 0 0 0.00281905 l
+0.09684 -0.179297 0.095381 -0.173341 0 0 0 0.00281905 l
+0.09684 -0.179297 0.0996131 -0.18204 0 0 0 0.00281905 l
+0.972557 -0.152624 0.967438 -0.147442 0 0 0 0.00281905 l
+0.972557 -0.152624 0.980731 -0.148243 0 0 0 0.00281905 l
+-0.126743 0.185802 -0.119503 0.185983 0 0 0 0.00281905 l
+-0.126743 0.185802 -0.134847 0.173405 0 0 0 0.00281905 l
+-0.126743 0.185802 -0.134562 0.188374 0 0 0 0.00281905 l
+0.409591 0.679678 0.412389 0.685282 0 0 0 0.00281905 l
+0.409591 0.679678 0.408213 0.676786 0 0 0 0.00281905 l
+-0.128394 0.250055 -0.128344 0.268412 0 0 0 0.00281905 l
+0.504816 -0.294766 0.509573 -0.307295 0 0 0 0.00281905 l
+-0.267029 -0.190615 -0.27116 -0.203529 0 0 0 0.00281905 l
+-0.267029 -0.190615 -0.271373 -0.178864 0 0 0 0.00281905 l
+-0.267029 -0.190615 -0.259803 -0.189353 0 0 0 0.00281905 l
+-0.28835 -0.634423 -0.286551 -0.635721 0 0 0 0.00281905 l
+-0.28835 -0.634423 -0.28957 -0.634711 0 0 0 0.00281905 l
+0.304837 0.554532 0.303326 0.535783 0 0 0 0.00281905 l
+0.304837 0.554532 0.288716 0.55399 0 0 0 0.00281905 l
+0.196177 -0.205125 0.196303 -0.212149 0 0 0 0.00281905 l
+0.196177 -0.205125 0.201712 -0.190242 0 0 0 0.00281905 l
+0.196177 -0.205125 0.186853 -0.202447 0 0 0 0.00281905 l
+-0.852209 -0.163375 -0.845401 -0.173382 0 0 0 0.00281905 l
+-0.852209 -0.163375 -0.859227 -0.165621 0 0 0 0.00281905 l
+-0.852209 -0.163375 -0.851841 -0.161878 0 0 0 0.00281905 l
+-0.108028 -0.296534 -0.102103 -0.307197 0 0 0 0.00281905 l
+-0.108028 -0.296534 -0.0985346 -0.288372 0 0 0 0.00281905 l
+-0.108028 -0.296534 -0.115625 -0.305908 0 0 0 0.00281905 l
+0.106356 -0.917457 0.117279 -0.920341 0 0 0 0.00281905 l
+0.106356 -0.917457 0.0963817 -0.914892 0 0 0 0.00281905 l
+-0.371432 -0.717158 -0.367327 -0.731021 0 0 0 0.00281905 l
+-0.287602 -0.429367 -0.282486 -0.423494 0 0 0 0.00281905 l
+-0.287602 -0.429367 -0.282715 -0.444933 0 0 0 0.00281905 l
+0.853307 0.0821561 0.854465 0.0627964 0 0 0 0.00281905 l
+0.853307 0.0821561 0.843985 0.0829162 0 0 0 0.00281905 l
+0.511954 0.493328 0.514997 0.475471 0 0 0 0.00281905 l
+0.511954 0.493328 0.51739 0.499235 0 0 0 0.00281905 l
+0.511954 0.493328 0.504196 0.505077 0 0 0 0.00281905 l
+-0.33118 -0.696436 -0.334477 -0.68491 0 0 0 0.00281905 l
+-0.33118 -0.696436 -0.317264 -0.715457 0 0 0 0.00281905 l
+-0.33118 -0.696436 -0.335143 -0.697747 0 0 0 0.00281905 l
+0.288273 -0.515839 0.293338 -0.504579 0 0 0 0.00281905 l
+0.288273 -0.515839 0.285435 -0.523733 0 0 0 0.00281905 l
+0.586955 0.0783149 0.584309 0.089887 0 0 0 0.00281905 l
+0.586955 0.0783149 0.585351 0.0759399 0 0 0 0.00281905 l
+-0.316845 -0.233723 -0.320416 -0.226373 0 0 0 0.00281905 l
+-0.316845 -0.233723 -0.321632 -0.239038 0 0 0 0.00281905 l
+-0.397138 -0.433001 -0.389957 -0.413067 0 0 0 0.00281905 l
+-0.397138 -0.433001 -0.380513 -0.441779 0 0 0 0.00281905 l
+-0.398191 -0.0802133 -0.395111 -0.0807875 0 0 0 0.00281905 l
+-0.13119 0.0967668 -0.128629 0.0992151 0 0 0 0.00281905 l
+0.0396419 -0.892074 0.0480267 -0.883697 0 0 0 0.00281905 l
+0.0396419 -0.892074 0.0358706 -0.890694 0 0 0 0.00281905 l
+0.518688 0.313002 0.523677 0.325968 0 0 0 0.00281905 l
+0.518688 0.313002 0.515742 0.300438 0 0 0 0.00281905 l
+0.00664457 0.837468 0.0173174 0.826207 0 0 0 0.00281905 l
+0.00664457 0.837468 0.00265448 0.845691 0 0 0 0.00281905 l
+0.130396 -0.175823 0.128624 -0.167753 0 0 0 0.00281905 l
+0.0443188 0.896231 0.0581151 0.887564 0 0 0 0.00281905 l
+0.0443188 0.896231 0.0310535 0.900366 0 0 0 0.00281905 l
+-0.100736 -0.627055 -0.111249 -0.640397 0 0 0 0.00281905 l
+0.590383 0.234249 0.588775 0.241775 0 0 0 0.00281905 l
+0.590383 0.234249 0.605241 0.226937 0 0 0 0.00281905 l
+0.37511 -0.730826 0.382146 -0.72275 0 0 0 0.00281905 l
+0.37511 -0.730826 0.36732 -0.735841 0 0 0 0.00281905 l
+0.991167 0.127118 0.986945 0.150489 0 0 0 0.00281905 l
+0.991167 0.127118 0.991131 0.116443 0 0 0 0.00281905 l
+0.438042 -0.743799 0.43826 -0.734125 0 0 0 0.00281905 l
+0.438042 -0.743799 0.441324 -0.743464 0 0 0 0.00281905 l
+-0.0368719 0.808149 -0.0334288 0.78246 0 0 0 0.00281905 l
+0.404907 -0.676177 0.409505 -0.666874 0 0 0 0.00281905 l
+0.404907 -0.676177 0.398744 -0.674047 0 0 0 0.00281905 l
+-0.464087 -0.261615 -0.457493 -0.248828 0 0 0 0.00281905 l
+-0.464087 -0.261615 -0.46566 -0.263249 0 0 0 0.00281905 l
+-0.827983 -0.231856 -0.828896 -0.254682 0 0 0 0.00281905 l
+-0.827983 -0.231856 -0.80975 -0.23372 0 0 0 0.00281905 l
+-0.827983 -0.231856 -0.833461 -0.227966 0 0 0 0.00281905 l
+-0.514045 0.58385 -0.513686 0.59774 0 0 0 0.00281905 l
+-0.514045 0.58385 -0.507202 0.576196 0 0 0 0.00281905 l
+0.907363 0.161138 0.912752 0.161937 0 0 0 0.00281905 l
+0.907363 0.161138 0.902641 0.160446 0 0 0 0.00281905 l
+0.250462 0.482529 0.252156 0.48766 0 0 0 0.00281905 l
+0.250462 0.482529 0.250854 0.480826 0 0 0 0.00281905 l
+0.695985 -0.109827 0.714321 -0.117539 0 0 0 0.00281905 l
+0.695985 -0.109827 0.690405 -0.110173 0 0 0 0.00281905 l
+0.626818 -0.460488 0.63303 -0.457469 0 0 0 0.00281905 l
+-0.732872 -0.199186 -0.727751 -0.184077 0 0 0 0.00281905 l
+-0.732872 -0.199186 -0.733913 -0.201048 0 0 0 0.00281905 l
+0.31639 0.787669 0.316674 0.776034 0 0 0 0.00281905 l
+0.31639 0.787669 0.316026 0.795371 0 0 0 0.00281905 l
+-0.743718 -0.0579772 -0.728379 -0.0701402 0 0 0 0.00281905 l
+-0.743718 -0.0579772 -0.751952 -0.07178 0 0 0 0.00281905 l
+-0.743718 -0.0579772 -0.738618 -0.0501986 0 0 0 0.00281905 l
+-0.396524 0.653176 -0.381166 0.658859 0 0 0 0.00281905 l
+-0.396524 0.653176 -0.400809 0.653632 0 0 0 0.00281905 l
+0.315585 -0.475105 0.332764 -0.480226 0 0 0 0.00281905 l
+0.315585 -0.475105 0.310185 -0.474497 0 0 0 0.00281905 l
+0.544303 -0.0265087 0.544167 -0.0280602 0 0 0 0.00281905 l
+0.544303 -0.0265087 0.550486 -0.0135731 0 0 0 0.00281905 l
+0.544303 -0.0265087 0.540777 -0.0241911 0 0 0 0.00281905 l
+0.0528841 -0.436639 0.0419855 -0.448373 0 0 0 0.00281905 l
+0.0528841 -0.436639 0.0545617 -0.436461 0 0 0 0.00281905 l
+-0.191212 0.792702 -0.207788 0.798662 0 0 0 0.00281905 l
+-0.60994 -0.467014 -0.605734 -0.470135 0 0 0 0.00281905 l
+-0.60994 -0.467014 -0.609004 -0.463303 0 0 0 0.00281905 l
+-0.60994 -0.467014 -0.622459 -0.471024 0 0 0 0.00281905 l
+0.634788 -0.304008 0.633164 -0.295608 0 0 0 0.00281905 l
+0.634788 -0.304008 0.631508 -0.306909 0 0 0 0.00281905 l
+0.0471527 0.546501 0.0520985 0.545457 0 0 0 0.00281905 l
+0.0471527 0.546501 0.041732 0.536666 0 0 0 0.00281905 l
+0.0471527 0.546501 0.0412184 0.550722 0 0 0 0.00281905 l
+0.0303802 -0.697064 0.0313305 -0.697146 0 0 0 0.00281905 l
+0.0303802 -0.697064 0.026887 -0.700259 0 0 0 0.00281905 l
+-0.175785 0.704028 -0.171737 0.715379 0 0 0 0.00281905 l
+-0.175785 0.704028 -0.173724 0.699641 0 0 0 0.00281905 l
+-0.592022 -0.00802412 -0.599126 -0.0200293 0 0 0 0.00281905 l
+-0.592022 -0.00802412 -0.583239 0.00892794 0 0 0 0.00281905 l
+0.224202 0.745603 0.22846 0.751789 0 0 0 0.00281905 l
+0.224202 0.745603 0.219034 0.730701 0 0 0 0.00281905 l
+0.224202 0.745603 0.217569 0.753216 0 0 0 0.00281905 l
+0.35303 0.162167 0.361284 0.159923 0 0 0 0.00281905 l
+0.35303 0.162167 0.355863 0.168602 0 0 0 0.00281905 l
+-0.580683 0.372237 -0.568411 0.367228 0 0 0 0.00281905 l
+-0.580683 0.372237 -0.589373 0.381651 0 0 0 0.00281905 l
+-0.823907 -0.122007 -0.817167 -0.128315 0 0 0 0.00281905 l
+0.583185 -0.200937 0.595723 -0.200439 0 0 0 0.00281905 l
+-0.347134 0.767128 -0.349499 0.749498 0 0 0 0.00281905 l
+-0.278715 -0.332195 -0.281838 -0.320306 0 0 0 0.00281905 l
+-0.278715 -0.332195 -0.290468 -0.346537 0 0 0 0.00281905 l
+-0.439904 0.0280359 -0.443423 0.0367178 0 0 0 0.00281905 l
+-0.439904 0.0280359 -0.434145 0.0266292 0 0 0 0.00281905 l
+-0.439904 0.0280359 -0.444697 0.016905 0 0 0 0.00281905 l
+0.560694 -0.726401 0.56271 -0.710118 0 0 0 0.00281905 l
+0.262403 0.138648 0.278502 0.137061 0 0 0 0.00281905 l
+0.262403 0.138648 0.263132 0.124343 0 0 0 0.00281905 l
+0.414033 -0.323006 0.416404 -0.315134 0 0 0 0.00281905 l
+-0.615821 0.426155 -0.614253 0.415439 0 0 0 0.00281905 l
+-0.615821 0.426155 -0.602099 0.432041 0 0 0 0.00281905 l
+0.884383 0.403111 0.8962 0.387087 0 0 0 0.00281905 l
+0.884383 0.403111 0.882633 0.424663 0 0 0 0.00281905 l
+0.884383 0.403111 0.873613 0.399164 0 0 0 0.00281905 l
+0.622827 0.478655 0.616921 0.471377 0 0 0 0.00281905 l
+0.622827 0.478655 0.633748 0.481594 0 0 0 0.00281905 l
+0.622827 0.478655 0.620287 0.481315 0 0 0 0.00281905 l
+-0.242876 0.77663 -0.240494 0.791917 0 0 0 0.00281905 l
+0.113801 -0.587613 0.100464 -0.570456 0 0 0 0.00281905 l
+0.00265448 0.845691 0.00507685 0.850444 0 0 0 0.00281905 l
+0.00265448 0.845691 0.00664457 0.837468 0 0 0 0.00281905 l
+-0.0786134 0.261651 -0.0694484 0.260371 0 0 0 0.00281905 l
+-0.0786134 0.261651 -0.0853743 0.268654 0 0 0 0.00281905 l
+-0.629221 -0.366649 -0.622728 -0.378936 0 0 0 0.00281905 l
+-0.629221 -0.366649 -0.616901 -0.357797 0 0 0 0.00281905 l
+-0.629221 -0.366649 -0.646171 -0.36826 0 0 0 0.00281905 l
+0.644609 -0.0682438 0.658796 -0.0585182 0 0 0 0.00281905 l
+0.469671 0.308796 0.479696 0.319038 0 0 0 0.00281905 l
+0.469671 0.308796 0.465921 0.30776 0 0 0 0.00281905 l
+-0.223879 -0.778092 -0.216432 -0.775313 0 0 0 0.00281905 l
+0.77521 0.608905 0.792984 0.604744 0 0 0 0.00281905 l
+0.77521 0.608905 0.771909 0.600385 0 0 0 0.00281905 l
+0.77521 0.608905 0.76109 0.621136 0 0 0 0.00281905 l
+0.49338 -0.0123837 0.499631 -0.0203278 0 0 0 0.00281905 l
+0.49338 -0.0123837 0.497379 -0.00989928 0 0 0 0.00281905 l
+0.49338 -0.0123837 0.4758 -0.0203505 0 0 0 0.00281905 l
+-0.516147 -0.710064 -0.524959 -0.702304 0 0 0 0.00281905 l
+0.100583 0.0328563 0.0998299 0.0455969 0 0 0 0.00281905 l
+0.100583 0.0328563 0.112708 0.0321531 0 0 0 0.00281905 l
+0.811208 -0.132283 0.814984 -0.116465 0 0 0 0.00281905 l
+0.811208 -0.132283 0.826186 -0.142027 0 0 0 0.00281905 l
+-0.0673039 0.228183 -0.0636804 0.234933 0 0 0 0.00281905 l
+-0.662496 -0.0211437 -0.64961 -0.00776285 0 0 0 0.00281905 l
+-0.582705 0.0914337 -0.584958 0.102186 0 0 0 0.00281905 l
+-0.582705 0.0914337 -0.572038 0.0902452 0 0 0 0.00281905 l
+-0.443257 -0.761427 -0.432589 -0.759699 0 0 0 0.00281905 l
+0.278515 -0.642057 0.285095 -0.650682 0 0 0 0.00281905 l
+0.278515 -0.642057 0.272076 -0.637286 0 0 0 0.00281905 l
+0.523326 -0.387152 0.533279 -0.390751 0 0 0 0.00281905 l
+0.523326 -0.387152 0.524148 -0.398422 0 0 0 0.00281905 l
+0.523326 -0.387152 0.509445 -0.393472 0 0 0 0.00281905 l
+-0.0964042 0.943083 -0.0967306 0.944414 0 0 0 0.00281905 l
+0.438339 -0.569736 0.442275 -0.564644 0 0 0 0.00281905 l
+0.438339 -0.569736 0.446909 -0.584374 0 0 0 0.00281905 l
+0.438339 -0.569736 0.424658 -0.577795 0 0 0 0.00281905 l
+0.438339 -0.569736 0.435036 -0.564171 0 0 0 0.00281905 l
+0.138076 0.0200819 0.141878 0.0287438 0 0 0 0.00281905 l
+0.138076 0.0200819 0.131622 0.019342 0 0 0 0.00281905 l
+-0.401168 -0.524437 -0.401211 -0.525683 0 0 0 0.00281905 l
+-0.401168 -0.524437 -0.411791 -0.522669 0 0 0 0.00281905 l
+-0.461762 0.313181 -0.475176 0.335801 0 0 0 0.00281905 l
+-0.461762 0.313181 -0.455299 0.30308 0 0 0 0.00281905 l
+0.954443 -0.292795 0.955776 -0.269906 0 0 0 0.00281905 l
+0.954443 -0.292795 0.940152 -0.294071 0 0 0 0.00281905 l
+-0.959577 0.112197 -0.949853 0.117858 0 0 0 0.00281905 l
+-0.959577 0.112197 -0.959271 0.110163 0 0 0 0.00281905 l
+0.851114 0.0335093 0.862767 0.0324139 0 0 0 0.00281905 l
+0.851114 0.0335093 0.852882 0.0231235 0 0 0 0.00281905 l
+0.851114 0.0335093 0.846472 0.0338629 0 0 0 0.00281905 l
+0.237876 0.827168 0.237709 0.833634 0 0 0 0.00281905 l
+0.237876 0.827168 0.23661 0.806993 0 0 0 0.00281905 l
+0.237876 0.827168 0.225419 0.825442 0 0 0 0.00281905 l
+-0.153619 -0.567161 -0.158568 -0.553845 0 0 0 0.00281905 l
+-0.153619 -0.567161 -0.154885 -0.570194 0 0 0 0.00281905 l
+-0.336308 -0.32636 -0.335032 -0.337 0 0 0 0.00281905 l
+-0.336308 -0.32636 -0.336802 -0.317362 0 0 0 0.00281905 l
+-0.336308 -0.32636 -0.346622 -0.33147 0 0 0 0.00281905 l
+0.293289 0.327953 0.295053 0.326162 0 0 0 0.00281905 l
+-0.688653 -0.169606 -0.676817 -0.177286 0 0 0 0.00281905 l
+-0.688653 -0.169606 -0.705349 -0.169847 0 0 0 0.00281905 l
+0.568403 -0.412442 0.560505 -0.405696 0 0 0 0.00281905 l
+0.19411 0.521814 0.210666 0.524805 0 0 0 0.00281905 l
+0.19411 0.521814 0.175437 0.527711 0 0 0 0.00281905 l
+0.0383813 -0.304405 0.0413802 -0.299833 0 0 0 0.00281905 l
+0.0383813 -0.304405 0.0287414 -0.306426 0 0 0 0.00281905 l
+-0.583096 0.24908 -0.596973 0.250855 0 0 0 0.00281905 l
+0.425596 0.15255 0.425833 0.145117 0 0 0 0.00281905 l
+0.251835 -0.425419 0.253252 -0.420961 0 0 0 0.00281905 l
+0.251835 -0.425419 0.24186 -0.425128 0 0 0 0.00281905 l
+0.484047 0.663137 0.493003 0.679399 0 0 0 0.00281905 l
+0.426686 -0.424006 0.445653 -0.414497 0 0 0 0.00281905 l
+0.426686 -0.424006 0.412501 -0.426253 0 0 0 0.00281905 l
+0.0792753 -0.163286 0.0891225 -0.156749 0 0 0 0.00281905 l
+-0.513339 -0.786419 -0.517019 -0.76902 0 0 0 0.00281905 l
+-0.513339 -0.786419 -0.499013 -0.778098 0 0 0 0.00281905 l
+-0.933953 -0.160621 -0.928883 -0.152554 0 0 0 0.00281905 l
+-0.933953 -0.160621 -0.931481 -0.166737 0 0 0 0.00281905 l
+-0.351045 -0.708971 -0.346709 -0.709464 0 0 0 0.00281905 l
+0.862012 0.103055 0.870763 0.108485 0 0 0 0.00281905 l
+0.862012 0.103055 0.848908 0.107126 0 0 0 0.00281905 l
+0.059071 0.838298 0.0671764 0.841412 0 0 0 0.00281905 l
+0.059071 0.838298 0.0540049 0.834331 0 0 0 0.00281905 l
+-0.164051 -0.342597 -0.165905 -0.322506 0 0 0 0.00281905 l
+-0.164051 -0.342597 -0.158437 -0.342701 0 0 0 0.00281905 l
+-0.164051 -0.342597 -0.161508 -0.348034 0 0 0 0.00281905 l
+-0.164051 -0.342597 -0.167902 -0.342769 0 0 0 0.00281905 l
+0.311135 0.0208179 0.3082 0.0141989 0 0 0 0.00281905 l
+0.311135 0.0208179 0.326571 0.0222512 0 0 0 0.00281905 l
+0.311135 0.0208179 0.295793 0.0293948 0 0 0 0.00281905 l
+-0.633058 0.24512 -0.628212 0.25628 0 0 0 0.00281905 l
+-0.0032994 0.435016 -0.0153619 0.443188 0 0 0 0.00281905 l
+-0.563535 -0.504797 -0.563257 -0.513133 0 0 0 0.00281905 l
+-0.563535 -0.504797 -0.568277 -0.50445 0 0 0 0.00281905 l
+-0.357865 -0.470833 -0.349775 -0.455934 0 0 0 0.00281905 l
+-0.357865 -0.470833 -0.353603 -0.475063 0 0 0 0.00281905 l
+-0.357865 -0.470833 -0.367355 -0.471198 0 0 0 0.00281905 l
+0.594617 0.535582 0.591381 0.545042 0 0 0 0.00281905 l
+0.594617 0.535582 0.602278 0.52919 0 0 0 0.00281905 l
+-0.213913 0.391491 -0.220971 0.389841 0 0 0 0.00281905 l
+-0.213913 0.391491 -0.214072 0.392279 0 0 0 0.00281905 l
+0.509445 -0.393472 0.504857 -0.372731 0 0 0 0.00281905 l
+0.509445 -0.393472 0.523326 -0.387152 0 0 0 0.00281905 l
+0.137925 0.00643126 0.153521 0.00169971 0 0 0 0.00281905 l
+0.137925 0.00643126 0.128729 0.00174263 0 0 0 0.00281905 l
+0.411817 -0.566864 0.419586 -0.55775 0 0 0 0.00281905 l
+0.411817 -0.566864 0.403358 -0.580276 0 0 0 0.00281905 l
+0.295544 -0.116926 0.311589 -0.107062 0 0 0 0.00281905 l
+0.295544 -0.116926 0.279965 -0.125 0 0 0 0.00281905 l
+0.303693 -0.699058 0.309897 -0.691342 0 0 0 0.00281905 l
+-0.948049 -0.251778 -0.939689 -0.244745 0 0 0 0.00281905 l
+-0.948049 -0.251778 -0.953449 -0.264674 0 0 0 0.00281905 l
+-0.207961 -0.272411 -0.207062 -0.279514 0 0 0 0.00281905 l
+-0.207961 -0.272411 -0.221838 -0.267337 0 0 0 0.00281905 l
+-0.302639 0.19958 -0.298174 0.21014 0 0 0 0.00281905 l
+-0.302639 0.19958 -0.308068 0.190053 0 0 0 0.00281905 l
+0.267659 -0.390353 0.259811 -0.377593 0 0 0 0.00281905 l
+0.85635 -0.0139479 0.861334 -0.0157504 0 0 0 0.00281905 l
+0.85635 -0.0139479 0.848 -0.010964 0 0 0 0.00281905 l
+0.367551 0.0950161 0.36978 0.104754 0 0 0 0.00281905 l
+-0.523121 -0.594687 -0.507454 -0.574217 0 0 0 0.00281905 l
+-0.0283905 0.517849 -0.0291717 0.506193 0 0 0 0.00281905 l
+0.475326 -0.0775939 0.481215 -0.0689392 0 0 0 0.00281905 l
+0.475326 -0.0775939 0.462986 -0.078583 0 0 0 0.00281905 l
+0.0834857 -0.590893 0.0868846 -0.609052 0 0 0 0.00281905 l
+0.0834857 -0.590893 0.0747528 -0.581497 0 0 0 0.00281905 l
+0.992805 -0.0722798 0.991225 -0.077941 0 0 0 0.00281905 l
+-0.76701 -0.513317 -0.764021 -0.518381 0 0 0 0.00281905 l
+-0.76701 -0.513317 -0.773431 -0.519341 0 0 0 0.00281905 l
+0.484474 0.135577 0.495937 0.132743 0 0 0 0.00281905 l
+0.484474 0.135577 0.487863 0.142843 0 0 0 0.00281905 l
+-0.767132 0.168813 -0.767365 0.16449 0 0 0 0.00281905 l
+-0.767132 0.168813 -0.774617 0.17908 0 0 0 0.00281905 l
+-0.837275 -0.524432 -0.83843 -0.541714 0 0 0 0.00281905 l
+-0.837275 -0.524432 -0.846067 -0.525519 0 0 0 0.00281905 l
+-0.723944 0.52891 -0.712549 0.524929 0 0 0 0.00281905 l
+-0.723944 0.52891 -0.730443 0.537811 0 0 0 0.00281905 l
+0.265029 -0.099268 0.280944 -0.0852214 0 0 0 0.00281905 l
+0.265029 -0.099268 0.262242 -0.11541 0 0 0 0.00281905 l
+0.265029 -0.099268 0.249263 -0.0928167 0 0 0 0.00281905 l
+-0.431104 -0.213447 -0.428002 -0.231154 0 0 0 0.00281905 l
+-0.239432 0.0670741 -0.229932 0.0824348 0 0 0 0.00281905 l
+-0.239432 0.0670741 -0.244247 0.0569093 0 0 0 0.00281905 l
+-0.493539 0.592099 -0.492376 0.596604 0 0 0 0.00281905 l
+-0.493539 0.592099 -0.499086 0.586857 0 0 0 0.00281905 l
+-0.600701 0.264152 -0.596973 0.250855 0 0 0 0.00281905 l
+-0.600701 0.264152 -0.60704 0.268573 0 0 0 0.00281905 l
+-0.661565 -0.733299 -0.657953 -0.751981 0 0 0 0.00281905 l
+-0.661565 -0.733299 -0.655095 -0.729278 0 0 0 0.00281905 l
+0.294641 -0.486899 0.289964 -0.482375 0 0 0 0.00281905 l
+0.294641 -0.486899 0.287347 -0.490159 0 0 0 0.00281905 l
+-0.726206 0.503545 -0.715119 0.509589 0 0 0 0.00281905 l
+-0.726206 0.503545 -0.731333 0.499703 0 0 0 0.00281905 l
+0.41212 0.438413 0.424311 0.432701 0 0 0 0.00281905 l
+0.41212 0.438413 0.411143 0.439133 0 0 0 0.00281905 l
+0.465745 -0.809853 0.478424 -0.80953 0 0 0 0.00281905 l
+0.465745 -0.809853 0.465762 -0.814646 0 0 0 0.00281905 l
+-0.377541 0.887044 -0.378448 0.913009 0 0 0 0.00281905 l
+-0.377541 0.887044 -0.372838 0.885996 0 0 0 0.00281905 l
+-0.377541 0.887044 -0.397071 0.879742 0 0 0 0.00281905 l
+0.325593 0.891458 0.322922 0.881884 0 0 0 0.00281905 l
+0.325593 0.891458 0.337493 0.896279 0 0 0 0.00281905 l
+-0.267023 0.835398 -0.25111 0.839151 0 0 0 0.00281905 l
+-0.267023 0.835398 -0.275831 0.841272 0 0 0 0.00281905 l
+0.942127 -0.306879 0.940152 -0.294071 0 0 0 0.00281905 l
+0.942127 -0.306879 0.929268 -0.308711 0 0 0 0.00281905 l
+-0.367884 0.430902 -0.373027 0.421394 0 0 0 0.00281905 l
+0.335273 -0.886784 0.34495 -0.892724 0 0 0 0.00281905 l
+0.335273 -0.886784 0.333196 -0.893782 0 0 0 0.00281905 l
+0.335273 -0.886784 0.32953 -0.883061 0 0 0 0.00281905 l
+0.255564 0.113117 0.265404 0.0947701 0 0 0 0.00281905 l
+0.255564 0.113117 0.25505 0.119646 0 0 0 0.00281905 l
+0.753811 -0.42026 0.754268 -0.437199 0 0 0 0.00281905 l
+0.753811 -0.42026 0.747927 -0.402132 0 0 0 0.00281905 l
+0.574651 0.104898 0.57286 0.114411 0 0 0 0.00281905 l
+0.574651 0.104898 0.588372 0.104899 0 0 0 0.00281905 l
+0.0399745 -0.877483 0.0480267 -0.883697 0 0 0 0.00281905 l
+-0.369904 -0.865052 -0.366981 -0.867016 0 0 0 0.00281905 l
+-0.369904 -0.865052 -0.375783 -0.865586 0 0 0 0.00281905 l
+-0.739602 0.314042 -0.738605 0.320925 0 0 0 0.00281905 l
+-0.739602 0.314042 -0.744326 0.307725 0 0 0 0.00281905 l
+0.69116 -0.305378 0.69908 -0.305671 0 0 0 0.00281905 l
+-0.414869 0.238499 -0.406681 0.237282 0 0 0 0.00281905 l
+-0.414869 0.238499 -0.427955 0.219468 0 0 0 0.00281905 l
+-0.414869 0.238499 -0.41951 0.248616 0 0 0 0.00281905 l
+0.0804063 0.466179 0.0791014 0.468467 0 0 0 0.00281905 l
+0.0804063 0.466179 0.0868659 0.469121 0 0 0 0.00281905 l
+0.0804063 0.466179 0.0769371 0.465112 0 0 0 0.00281905 l
+-0.167364 0.735449 -0.16383 0.728902 0 0 0 0.00281905 l
+-0.167364 0.735449 -0.1561 0.746205 0 0 0 0.00281905 l
+-0.167364 0.735449 -0.173387 0.732782 0 0 0 0.00281905 l
+0.591195 -0.134275 0.58804 -0.144247 0 0 0 0.00281905 l
+0.591195 -0.134275 0.593057 -0.131867 0 0 0 0.00281905 l
+0.591195 -0.134275 0.576883 -0.128858 0 0 0 0.00281905 l
+-0.182175 -0.788924 -0.191371 -0.774802 0 0 0 0.00281905 l
+-0.60704 0.268573 -0.606561 0.27321 0 0 0 0.00281905 l
+-0.60704 0.268573 -0.600701 0.264152 0 0 0 0.00281905 l
+-0.60704 0.268573 -0.613453 0.263967 0 0 0 0.00281905 l
+-0.585403 0.414708 -0.578711 0.42757 0 0 0 0.00281905 l
+-0.585403 0.414708 -0.586249 0.401812 0 0 0 0.00281905 l
+-0.391737 -0.408452 -0.374647 -0.396082 0 0 0 0.00281905 l
+-0.391737 -0.408452 -0.389957 -0.413067 0 0 0 0.00281905 l
+0.249685 -0.958293 0.252127 -0.948533 0 0 0 0.00281905 l
+0.249685 -0.958293 0.235447 -0.963628 0 0 0 0.00281905 l
+0.208282 0.764144 0.215666 0.756402 0 0 0 0.00281905 l
+0.208282 0.764144 0.201328 0.77483 0 0 0 0.00281905 l
+0.208282 0.764144 0.193461 0.755388 0 0 0 0.00281905 l
+-0.944427 -0.183279 -0.933165 -0.178705 0 0 0 0.00281905 l
+-0.944427 -0.183279 -0.946997 -0.194642 0 0 0 0.00281905 l
+-0.944427 -0.183279 -0.94595 -0.182985 0 0 0 0.00281905 l
+0.771217 0.32057 0.769971 0.296022 0 0 0 0.00281905 l
+0.771217 0.32057 0.747 0.315246 0 0 0 0.00281905 l
+-0.659698 0.730459 -0.647852 0.733913 0 0 0 0.00281905 l
+0.791927 -0.0975185 0.798083 -0.111485 0 0 0 0.00281905 l
+0.791927 -0.0975185 0.789875 -0.0873253 0 0 0 0.00281905 l
+-0.848672 -0.188976 -0.854611 -0.184633 0 0 0 0.00281905 l
+0.451038 0.487041 0.441068 0.483447 0 0 0 0.00281905 l
+-0.420875 -0.538723 -0.408887 -0.535474 0 0 0 0.00281905 l
+-0.420875 -0.538723 -0.422659 -0.538825 0 0 0 0.00281905 l
+0.121551 0.00496176 0.120418 0.01615 0 0 0 0.00281905 l
+0.121551 0.00496176 0.128729 0.00174263 0 0 0 0.00281905 l
+0.184612 -0.341872 0.195188 -0.346543 0 0 0 0.00281905 l
+0.184612 -0.341872 0.182923 -0.342138 0 0 0 0.00281905 l
+-0.887888 0.0810518 -0.889152 0.0764076 0 0 0 0.00281905 l
+-0.887888 0.0810518 -0.892357 0.0852273 0 0 0 0.00281905 l
+0.369379 0.189056 0.363134 0.203816 0 0 0 0.00281905 l
+0.369379 0.189056 0.371831 0.182955 0 0 0 0.00281905 l
+0.666081 0.191083 0.687894 0.210836 0 0 0 0.00281905 l
+0.666081 0.191083 0.674131 0.181231 0 0 0 0.00281905 l
+0.666081 0.191083 0.665123 0.19205 0 0 0 0.00281905 l
+0.513061 -0.66987 0.530834 -0.671606 0 0 0 0.00281905 l
+0.513061 -0.66987 0.499593 -0.671025 0 0 0 0.00281905 l
+-0.359988 0.177658 -0.371889 0.192947 0 0 0 0.00281905 l
+-0.950324 -0.266479 -0.953449 -0.264674 0 0 0 0.00281905 l
+0.0428803 -0.458017 0.0419855 -0.448373 0 0 0 0.00281905 l
+0.0428803 -0.458017 0.0367689 -0.469022 0 0 0 0.00281905 l
+0.326346 0.533894 0.328364 0.535185 0 0 0 0.00281905 l
+0.326346 0.533894 0.317729 0.536861 0 0 0 0.00281905 l
+0.455288 -0.436016 0.459458 -0.425375 0 0 0 0.00281905 l
+0.455288 -0.436016 0.457257 -0.437549 0 0 0 0.00281905 l
+0.816164 -0.0717095 0.810892 -0.0688945 0 0 0 0.00281905 l
+-0.556272 -0.616707 -0.551375 -0.603786 0 0 0 0.00281905 l
+-0.556272 -0.616707 -0.548998 -0.624274 0 0 0 0.00281905 l
+-0.556272 -0.616707 -0.564224 -0.621774 0 0 0 0.00281905 l
+-0.191946 -0.516594 -0.193769 -0.526706 0 0 0 0.00281905 l
+-0.191946 -0.516594 -0.20408 -0.50884 0 0 0 0.00281905 l
+-0.652745 0.503677 -0.652152 0.508881 0 0 0 0.00281905 l
+0.357066 -0.601062 0.34369 -0.626307 0 0 0 0.00281905 l
+0.357066 -0.601062 0.361707 -0.590308 0 0 0 0.00281905 l
+0.317055 -0.800416 0.317346 -0.795688 0 0 0 0.00281905 l
+0.739169 -0.0447414 0.732669 -0.0278845 0 0 0 0.00281905 l
+0.739169 -0.0447414 0.725093 -0.047359 0 0 0 0.00281905 l
+0.781693 -0.59491 0.781036 -0.609119 0 0 0 0.00281905 l
+0.781693 -0.59491 0.794579 -0.593387 0 0 0 0.00281905 l
+0.781693 -0.59491 0.760352 -0.599902 0 0 0 0.00281905 l
+0.142533 -0.73343 0.152708 -0.742685 0 0 0 0.00281905 l
+0.142533 -0.73343 0.129559 -0.732384 0 0 0 0.00281905 l
+0.641966 0.670411 0.65422 0.661116 0 0 0 0.00281905 l
+0.641966 0.670411 0.633263 0.676793 0 0 0 0.00281905 l
+-0.483647 0.828384 -0.470451 0.844619 0 0 0 0.00281905 l
+-0.483647 0.828384 -0.476657 0.812986 0 0 0 0.00281905 l
+-0.483647 0.828384 -0.492749 0.822441 0 0 0 0.00281905 l
+-0.483647 0.828384 -0.488356 0.832801 0 0 0 0.00281905 l
+0.0885387 -0.487058 0.0728685 -0.484108 0 0 0 0.00281905 l
+0.0788921 -0.225319 0.0795316 -0.225621 0 0 0 0.00281905 l
+0.0788921 -0.225319 0.0642345 -0.22297 0 0 0 0.00281905 l
+0.930726 -0.0765441 0.938478 -0.0799388 0 0 0 0.00281905 l
+-0.0334288 0.78246 -0.0368719 0.808149 0 0 0 0.00281905 l
+-0.0334288 0.78246 -0.0279088 0.773898 0 0 0 0.00281905 l
+-0.0334288 0.78246 -0.0441432 0.780852 0 0 0 0.00281905 l
+0.76109 0.621136 0.77521 0.608905 0 0 0 0.00281905 l
+0.76109 0.621136 0.751109 0.623912 0 0 0 0.00281905 l
+0.469718 -0.287103 0.474383 -0.305495 0 0 0 0.00281905 l
+0.469718 -0.287103 0.480452 -0.279308 0 0 0 0.00281905 l
+-0.309393 0.616341 -0.29672 0.612221 0 0 0 0.00281905 l
+-0.309393 0.616341 -0.324399 0.608362 0 0 0 0.00281905 l
+0.41135 -0.758625 0.418329 -0.776123 0 0 0 0.00281905 l
+0.41135 -0.758625 0.410167 -0.748167 0 0 0 0.00281905 l
+0.57286 0.114411 0.574651 0.104898 0 0 0 0.00281905 l
+0.57286 0.114411 0.556494 0.107947 0 0 0 0.00281905 l
+-0.558446 0.256713 -0.555345 0.244095 0 0 0 0.00281905 l
+-0.558446 0.256713 -0.554853 0.269423 0 0 0 0.00281905 l
+0.322922 0.881884 0.325593 0.891458 0 0 0 0.00281905 l
+0.322922 0.881884 0.330056 0.867083 0 0 0 0.00281905 l
+0.2969 0.273858 0.298707 0.261805 0 0 0 0.00281905 l
+0.2969 0.273858 0.298254 0.290105 0 0 0 0.00281905 l
+-0.152631 -0.465707 -0.174319 -0.462372 0 0 0 0.00281905 l
+0.506699 0.704993 0.492813 0.714618 0 0 0 0.00281905 l
+0.506699 0.704993 0.506304 0.702831 0 0 0 0.00281905 l
+0.622368 0.686318 0.624336 0.680053 0 0 0 0.00281905 l
+0.622368 0.686318 0.62031 0.695076 0 0 0 0.00281905 l
+0.622368 0.686318 0.60825 0.679628 0 0 0 0.00281905 l
+0.0795316 -0.225621 0.0839629 -0.227123 0 0 0 0.00281905 l
+0.0795316 -0.225621 0.0788921 -0.225319 0 0 0 0.00281905 l
+-0.651433 -0.148657 -0.651853 -0.141402 0 0 0 0.00281905 l
+-0.651433 -0.148657 -0.647484 -0.148953 0 0 0 0.00281905 l
+-0.651433 -0.148657 -0.658286 -0.148888 0 0 0 0.00281905 l
+-0.0549432 0.285889 -0.0438324 0.283814 0 0 0 0.00281905 l
+0.615995 -0.152334 0.615717 -0.163799 0 0 0 0.00281905 l
+-0.100481 -0.0527413 -0.110527 -0.0353621 0 0 0 0.00281905 l
+-0.100481 -0.0527413 -0.100826 -0.0681722 0 0 0 0.00281905 l
+-0.190784 -0.766683 -0.191339 -0.774652 0 0 0 0.00281905 l
+-0.190784 -0.766683 -0.186073 -0.755861 0 0 0 0.00281905 l
+0.0423745 0.568368 0.0373541 0.551675 0 0 0 0.00281905 l
+0.0423745 0.568368 0.0419822 0.568788 0 0 0 0.00281905 l
+-0.530891 0.290838 -0.520297 0.29151 0 0 0 0.00281905 l
+-0.530891 0.290838 -0.534309 0.288488 0 0 0 0.00281905 l
+0.341504 -0.646166 0.350253 -0.649658 0 0 0 0.00281905 l
+0.674519 0.0421113 0.670279 0.0303594 0 0 0 0.00281905 l
+0.674519 0.0421113 0.660006 0.0471852 0 0 0 0.00281905 l
+-0.822655 0.0375448 -0.817255 0.0275186 0 0 0 0.00281905 l
+-0.822655 0.0375448 -0.823377 0.0446953 0 0 0 0.00281905 l
+0.0306859 -0.964871 0.029335 -0.976844 0 0 0 0.00281905 l
+0.495937 0.132743 0.512863 0.135356 0 0 0 0.00281905 l
+0.495937 0.132743 0.496534 0.129648 0 0 0 0.00281905 l
+0.495937 0.132743 0.484474 0.135577 0 0 0 0.00281905 l
+0.510198 0.758131 0.513731 0.753167 0 0 0 0.00281905 l
+0.510198 0.758131 0.500963 0.763243 0 0 0 0.00281905 l
+0.393787 -0.115482 0.413871 -0.115406 0 0 0 0.00281905 l
+0.393787 -0.115482 0.381103 -0.110534 0 0 0 0.00281905 l
+0.102944 0.936192 0.10719 0.930574 0 0 0 0.00281905 l
+0.102944 0.936192 0.108456 0.941648 0 0 0 0.00281905 l
+0.102944 0.936192 0.0992787 0.930574 0 0 0 0.00281905 l
+-0.24767 0.635012 -0.256455 0.651864 0 0 0 0.00281905 l
+-0.24767 0.635012 -0.243632 0.630976 0 0 0 0.00281905 l
+0.163507 -0.544853 0.176135 -0.536537 0 0 0 0.00281905 l
+0.163507 -0.544853 0.16352 -0.545326 0 0 0 0.00281905 l
+-0.939689 -0.244745 -0.933208 -0.241256 0 0 0 0.00281905 l
+-0.939689 -0.244745 -0.933975 -0.249746 0 0 0 0.00281905 l
+-0.939689 -0.244745 -0.948049 -0.251778 0 0 0 0.00281905 l
+-0.744326 0.307725 -0.739602 0.314042 0 0 0 0.00281905 l
+-0.744326 0.307725 -0.741864 0.300878 0 0 0 0.00281905 l
+-0.744326 0.307725 -0.751796 0.312805 0 0 0 0.00281905 l
+0.355975 -0.0113779 0.356768 0.00409432 0 0 0 0.00281905 l
+0.355975 -0.0113779 0.342111 -0.0174184 0 0 0 0.00281905 l
+0.71342 -0.17814 0.72659 -0.166994 0 0 0 0.00281905 l
+0.71342 -0.17814 0.722765 -0.185184 0 0 0 0.00281905 l
+0.71342 -0.17814 0.704142 -0.170671 0 0 0 0.00281905 l
+-0.125462 -0.100999 -0.135879 -0.083559 0 0 0 0.00281905 l
+-0.125462 -0.100999 -0.122906 -0.10077 0 0 0 0.00281905 l
+-0.994334 0.028406 -0.985191 0.0126579 0 0 0 0.00281905 l
+-0.994334 0.028406 -0.991884 0.0344015 0 0 0 0.00281905 l
+-0.0102136 0.887686 -0.0128192 0.899165 0 0 0 0.00281905 l
+-0.0102136 0.887686 -0.0134509 0.884671 0 0 0 0.00281905 l
+0.390331 0.0193567 0.397682 0.0240576 0 0 0 0.00281905 l
+0.390331 0.0193567 0.397841 0.0114409 0 0 0 0.00281905 l
+0.390331 0.0193567 0.385055 0.0182855 0 0 0 0.00281905 l
+-0.679656 -0.235486 -0.680305 -0.234959 0 0 0 0.00281905 l
+0.662696 0.144497 0.673614 0.144956 0 0 0 0.00281905 l
+0.662696 0.144497 0.652438 0.145722 0 0 0 0.00281905 l
+0.409556 -0.638414 0.409552 -0.626324 0 0 0 0.00281905 l
+0.513731 0.753167 0.509779 0.746576 0 0 0 0.00281905 l
+0.513731 0.753167 0.529654 0.753657 0 0 0 0.00281905 l
+0.513731 0.753167 0.510198 0.758131 0 0 0 0.00281905 l
+0.816188 -0.243864 0.829221 -0.255279 0 0 0 0.00281905 l
+0.816188 -0.243864 0.831115 -0.229786 0 0 0 0.00281905 l
+0.816188 -0.243864 0.805731 -0.243221 0 0 0 0.00281905 l
+-0.294853 0.466583 -0.277234 0.470805 0 0 0 0.00281905 l
+-0.294853 0.466583 -0.314232 0.459774 0 0 0 0.00281905 l
+-0.294853 0.466583 -0.297019 0.471217 0 0 0 0.00281905 l
+0.662978 0.518548 0.652179 0.511229 0 0 0 0.00281905 l
+0.662978 0.518548 0.674158 0.523633 0 0 0 0.00281905 l
+0.256226 -0.472325 0.265166 -0.488598 0 0 0 0.00281905 l
+0.256226 -0.472325 0.244067 -0.481931 0 0 0 0.00281905 l
+0.589856 0.0697154 0.598111 0.0639224 0 0 0 0.00281905 l
+0.589856 0.0697154 0.585351 0.0759399 0 0 0 0.00281905 l
+-0.0767205 -0.256275 -0.0602744 -0.254022 0 0 0 0.00281905 l
+-0.0767205 -0.256275 -0.0895533 -0.268737 0 0 0 0.00281905 l
+-0.727921 -0.250241 -0.736078 -0.253197 0 0 0 0.00281905 l
+-0.264465 -0.678891 -0.262012 -0.679304 0 0 0 0.00281905 l
+-0.264465 -0.678891 -0.270843 -0.670837 0 0 0 0.00281905 l
+-0.459951 -0.305005 -0.462461 -0.301226 0 0 0 0.00281905 l
+-0.459951 -0.305005 -0.460481 -0.306983 0 0 0 0.00281905 l
+-0.147944 0.0157465 -0.13404 0.00993114 0 0 0 0.00281905 l
+-0.097076 0.536034 -0.0781541 0.536559 0 0 0 0.00281905 l
+-0.097076 0.536034 -0.102495 0.54985 0 0 0 0.00281905 l
+-0.478492 -0.814989 -0.477811 -0.823551 0 0 0 0.00281905 l
+-0.478492 -0.814989 -0.46828 -0.808865 0 0 0 0.00281905 l
+-0.478492 -0.814989 -0.488312 -0.808276 0 0 0 0.00281905 l
+-0.590825 -0.187286 -0.584224 -0.183402 0 0 0 0.00281905 l
+-0.590825 -0.187286 -0.606708 -0.187357 0 0 0 0.00281905 l
+0.27769 0.393559 0.270193 0.406056 0 0 0 0.00281905 l
+0.27769 0.393559 0.287191 0.394986 0 0 0 0.00281905 l
+0.570821 0.617444 0.564068 0.612402 0 0 0 0.00281905 l
+-0.925337 0.202212 -0.924182 0.217761 0 0 0 0.00281905 l
+-0.925337 0.202212 -0.922577 0.193622 0 0 0 0.00281905 l
+-0.0534324 -0.261401 -0.0511313 -0.260431 0 0 0 0.00281905 l
+0.83604 0.517486 0.838072 0.510561 0 0 0 0.00281905 l
+0.83604 0.517486 0.81851 0.538493 0 0 0 0.00281905 l
+-0.764841 0.216826 -0.760521 0.214677 0 0 0 0.00281905 l
+0.453209 -0.204185 0.470066 -0.188296 0 0 0 0.00281905 l
+0.453209 -0.204185 0.455486 -0.21582 0 0 0 0.00281905 l
+0.453209 -0.204185 0.443371 -0.198483 0 0 0 0.00281905 l
+0.246912 -0.869057 0.252687 -0.864036 0 0 0 0.00281905 l
+0.246912 -0.869057 0.235456 -0.86862 0 0 0 0.00281905 l
+-0.437549 -0.0782434 -0.437365 -0.0955664 0 0 0 0.00281905 l
+-0.437549 -0.0782434 -0.440459 -0.0670604 0 0 0 0.00281905 l
+-0.437549 -0.0782434 -0.418477 -0.0766387 0 0 0 0.00281905 l
+-0.444692 0.772597 -0.437791 0.753493 0 0 0 0.00281905 l
+-0.444692 0.772597 -0.446467 0.775199 0 0 0 0.00281905 l
+-0.959125 0.271435 -0.95111 0.262859 0 0 0 0.00281905 l
+-0.14568 -0.0132317 -0.144163 -0.00918508 0 0 0 0.00281905 l
+-0.14568 -0.0132317 -0.144765 -0.0193012 0 0 0 0.00281905 l
+-0.14568 -0.0132317 -0.153066 -0.00884505 0 0 0 0.00281905 l
+-0.159636 0.689064 -0.157729 0.705475 0 0 0 0.00281905 l
+-0.159636 0.689064 -0.164842 0.667286 0 0 0 0.00281905 l
+-0.0573185 0.301684 -0.0453286 0.311044 0 0 0 0.00281905 l
+0.320178 0.119231 0.331127 0.131862 0 0 0 0.00281905 l
+0.320178 0.119231 0.313471 0.11415 0 0 0 0.00281905 l
+-0.137459 0.397523 -0.153488 0.393147 0 0 0 0.00281905 l
+0.336643 -0.152878 0.339987 -0.163737 0 0 0 0.00281905 l
+0.596603 -0.345163 0.588543 -0.359538 0 0 0 0.00281905 l
+0.596603 -0.345163 0.599021 -0.341164 0 0 0 0.00281905 l
+0.596603 -0.345163 0.586324 -0.338908 0 0 0 0.00281905 l
+-0.162114 0.618215 -0.156945 0.61109 0 0 0 0.00281905 l
+-0.162114 0.618215 -0.169851 0.621446 0 0 0 0.00281905 l
+0.0291673 -0.900703 0.0358706 -0.890694 0 0 0 0.00281905 l
+0.0291673 -0.900703 0.0100471 -0.913308 0 0 0 0.00281905 l
+0.0101882 -0.177811 0.0221515 -0.188089 0 0 0 0.00281905 l
+0.0101882 -0.177811 -0.00285242 -0.184346 0 0 0 0.00281905 l
+-0.555181 -0.720769 -0.558519 -0.707002 0 0 0 0.00281905 l
+-0.555181 -0.720769 -0.565756 -0.721479 0 0 0 0.00281905 l
+0.95727 0.226526 0.955876 0.237263 0 0 0 0.00281905 l
+0.95727 0.226526 0.971689 0.224964 0 0 0 0.00281905 l
+0.95727 0.226526 0.941692 0.227407 0 0 0 0.00281905 l
+0.43826 -0.734125 0.443349 -0.7284 0 0 0 0.00281905 l
+0.43826 -0.734125 0.438042 -0.743799 0 0 0 0.00281905 l
+0.613329 -0.0671899 0.624423 -0.0661264 0 0 0 0.00281905 l
+0.613329 -0.0671899 0.611699 -0.0631246 0 0 0 0.00281905 l
+0.118286 -0.357166 0.111608 -0.353861 0 0 0 0.00281905 l
+-0.841928 -0.316044 -0.837893 -0.314557 0 0 0 0.00281905 l
+-0.841928 -0.316044 -0.853355 -0.327329 0 0 0 0.00281905 l
+-0.585245 -0.525197 -0.577367 -0.526671 0 0 0 0.00281905 l
+-0.585245 -0.525197 -0.599054 -0.538011 0 0 0 0.00281905 l
+0.010459 -0.699725 0.0168384 -0.703194 0 0 0 0.00281905 l
+0.010459 -0.699725 0.0102051 -0.700197 0 0 0 0.00281905 l
+0.493243 0.849443 0.487383 0.845846 0 0 0 0.00281905 l
+-0.234565 0.439562 -0.236983 0.434649 0 0 0 0.00281905 l
+-0.234565 0.439562 -0.239671 0.443197 0 0 0 0.00281905 l
+-0.335126 0.494196 -0.335999 0.483683 0 0 0 0.00281905 l
+-0.335126 0.494196 -0.327972 0.497988 0 0 0 0.00281905 l
+0.317346 -0.795688 0.326809 -0.793271 0 0 0 0.00281905 l
+0.317346 -0.795688 0.317055 -0.800416 0 0 0 0.00281905 l
+0.317346 -0.795688 0.308855 -0.79448 0 0 0 0.00281905 l
+-0.0169125 -0.844514 -0.00589439 -0.837937 0 0 0 0.00281905 l
+-0.0169125 -0.844514 -0.0212333 -0.851024 0 0 0 0.00281905 l
+-0.0169125 -0.844514 -0.0220374 -0.843041 0 0 0 0.00281905 l
+-0.19245 -0.410395 -0.192541 -0.415924 0 0 0 0.00281905 l
+-0.19245 -0.410395 -0.200845 -0.400624 0 0 0 0.00281905 l
+-0.694814 0.614002 -0.68958 0.623633 0 0 0 0.00281905 l
+-0.694814 0.614002 -0.678767 0.602167 0 0 0 0.00281905 l
+-0.209248 -0.422391 -0.217841 -0.432883 0 0 0 0.00281905 l
+-0.209248 -0.422391 -0.205079 -0.424163 0 0 0 0.00281905 l
+-0.209248 -0.422391 -0.207457 -0.420021 0 0 0 0.00281905 l
+-0.209248 -0.422391 -0.214607 -0.417675 0 0 0 0.00281905 l
+0.588412 -0.53752 0.595419 -0.543231 0 0 0 0.00281905 l
+0.588412 -0.53752 0.590559 -0.534245 0 0 0 0.00281905 l
+0.588412 -0.53752 0.568179 -0.53132 0 0 0 0.00281905 l
+-0.647668 0.611357 -0.641306 0.607614 0 0 0 0.00281905 l
+-0.647668 0.611357 -0.642314 0.624527 0 0 0 0.00281905 l
+-0.560062 0.536728 -0.571217 0.547752 0 0 0 0.00281905 l
+-0.560062 0.536728 -0.573486 0.531042 0 0 0 0.00281905 l
+0.854656 0.213617 0.861892 0.226938 0 0 0 0.00281905 l
+0.854656 0.213617 0.864147 0.205444 0 0 0 0.00281905 l
+0.854656 0.213617 0.848391 0.203599 0 0 0 0.00281905 l
+-0.589359 0.101348 -0.584958 0.102186 0 0 0 0.00281905 l
+-0.589359 0.101348 -0.600449 0.108819 0 0 0 0.00281905 l
+-0.589359 0.101348 -0.593712 0.0924504 0 0 0 0.00281905 l
+-0.482106 0.339872 -0.475176 0.335801 0 0 0 0.00281905 l
+0.194135 -0.790698 0.206869 -0.78484 0 0 0 0.00281905 l
+-0.487453 -0.661976 -0.482092 -0.680818 0 0 0 0.00281905 l
+-0.487453 -0.661976 -0.481536 -0.657829 0 0 0 0.00281905 l
+-0.473766 -0.661053 -0.481536 -0.657829 0 0 0 0.00281905 l
+-0.416487 -0.787284 -0.416449 -0.793478 0 0 0 0.00281905 l
+-0.416487 -0.787284 -0.425537 -0.784618 0 0 0 0.00281905 l
+-0.554946 -0.738092 -0.546357 -0.736556 0 0 0 0.00281905 l
+-0.554946 -0.738092 -0.554379 -0.741309 0 0 0 0.00281905 l
+-0.554946 -0.738092 -0.566645 -0.727059 0 0 0 0.00281905 l
+-0.572038 0.0902452 -0.568053 0.080883 0 0 0 0.00281905 l
+-0.572038 0.0902452 -0.582705 0.0914337 0 0 0 0.00281905 l
+-0.994663 0.0557993 -0.992017 0.0460004 0 0 0 0.00281905 l
+0.622471 -0.198466 0.625773 -0.208136 0 0 0 0.00281905 l
+0.622471 -0.198466 0.616806 -0.188923 0 0 0 0.00281905 l
+-0.749238 -0.240866 -0.736078 -0.253197 0 0 0 0.00281905 l
+-0.749238 -0.240866 -0.751991 -0.228181 0 0 0 0.00281905 l
+-0.749238 -0.240866 -0.737116 -0.234249 0 0 0 0.00281905 l
+0.442275 -0.564644 0.438339 -0.569736 0 0 0 0.00281905 l
+0.442275 -0.564644 0.446969 -0.562288 0 0 0 0.00281905 l
+-0.71292 -0.628767 -0.708656 -0.617941 0 0 0 0.00281905 l
+0.443847 -0.167558 0.442709 -0.164076 0 0 0 0.00281905 l
+0.443847 -0.167558 0.439982 -0.172934 0 0 0 0.00281905 l
+0.361707 -0.590308 0.357066 -0.601062 0 0 0 0.00281905 l
+0.699447 0.239532 0.688548 0.244295 0 0 0 0.00281905 l
+0.699447 0.239532 0.701249 0.243894 0 0 0 0.00281905 l
+-0.660053 -0.502898 -0.674672 -0.49058 0 0 0 0.00281905 l
+0.0300703 0.115839 0.0369058 0.120098 0 0 0 0.00281905 l
+0.0300703 0.115839 0.0291488 0.113412 0 0 0 0.00281905 l
+0.11545 0.131758 0.108528 0.135144 0 0 0 0.00281905 l
+-0.0122085 0.054965 -0.0128417 0.0632123 0 0 0 0.00281905 l
+-0.0122085 0.054965 0.000914739 0.0510042 0 0 0 0.00281905 l
+-0.0122085 0.054965 -0.0125155 0.0459056 0 0 0 0.00281905 l
+-0.761757 -0.580824 -0.750934 -0.597682 0 0 0 0.00281905 l
+-0.761757 -0.580824 -0.768899 -0.575023 0 0 0 0.00281905 l
+0.440991 0.477605 0.441068 0.483447 0 0 0 0.00281905 l
+0.440991 0.477605 0.43761 0.470585 0 0 0 0.00281905 l
+-0.679716 -0.211342 -0.683268 -0.214773 0 0 0 0.00281905 l
+0.0300137 0.593982 0.0320164 0.587367 0 0 0 0.00281905 l
+0.0300137 0.593982 0.0277569 0.602656 0 0 0 0.00281905 l
+0.0300137 0.593982 0.0120132 0.587417 0 0 0 0.00281905 l
+-0.91995 -0.338815 -0.914069 -0.35129 0 0 0 0.00281905 l
+-0.91995 -0.338815 -0.920398 -0.330468 0 0 0 0.00281905 l
+-0.91995 -0.338815 -0.934105 -0.337959 0 0 0 0.00281905 l
+0.457257 -0.437549 0.467481 -0.439808 0 0 0 0.00281905 l
+0.457257 -0.437549 0.455288 -0.436016 0 0 0 0.00281905 l
+-0.917632 -0.163325 -0.927781 -0.172659 0 0 0 0.00281905 l
+0.701798 0.12952 0.704755 0.121388 0 0 0 0.00281905 l
+0.0297063 -0.430098 0.0281375 -0.437151 0 0 0 0.00281905 l
+0.0297063 -0.430098 0.0352411 -0.41986 0 0 0 0.00281905 l
+0.569264 -0.137027 0.576883 -0.128858 0 0 0 0.00281905 l
+0.569264 -0.137027 0.553445 -0.141611 0 0 0 0.00281905 l
+-0.603225 -0.554774 -0.611521 -0.553951 0 0 0 0.00281905 l
+-0.420571 0.366819 -0.42033 0.364014 0 0 0 0.00281905 l
+-0.420571 0.366819 -0.413603 0.374728 0 0 0 0.00281905 l
+0.318511 -0.922517 0.324558 -0.913296 0 0 0 0.00281905 l
+0.318511 -0.922517 0.307161 -0.911254 0 0 0 0.00281905 l
+0.764849 0.076174 0.771035 0.0765737 0 0 0 0.00281905 l
+0.764849 0.076174 0.766644 0.0651518 0 0 0 0.00281905 l
+0.932883 -0.0293105 0.946869 -0.0360685 0 0 0 0.00281905 l
+0.932883 -0.0293105 0.928193 -0.023734 0 0 0 0.00281905 l
+0.293432 0.826569 0.297208 0.820841 0 0 0 0.00281905 l
+0.293432 0.826569 0.288666 0.824768 0 0 0 0.00281905 l
+0.111447 -0.402976 0.113204 -0.417105 0 0 0 0.00281905 l
+0.111447 -0.402976 0.109771 -0.401121 0 0 0 0.00281905 l
+-0.935428 0.304699 -0.936279 0.325361 0 0 0 0.00281905 l
+-0.935428 0.304699 -0.93179 0.303601 0 0 0 0.00281905 l
+-0.340089 -0.35063 -0.335032 -0.337 0 0 0 0.00281905 l
+-0.340089 -0.35063 -0.322736 -0.361179 0 0 0 0.00281905 l
+-0.340089 -0.35063 -0.359808 -0.357118 0 0 0 0.00281905 l
+0.0592835 -0.296391 0.0606098 -0.281203 0 0 0 0.00281905 l
+0.0592835 -0.296391 0.0674492 -0.297405 0 0 0 0.00281905 l
+0.0592835 -0.296391 0.052618 -0.296495 0 0 0 0.00281905 l
+-0.906518 0.161012 -0.894618 0.154766 0 0 0 0.00281905 l
+-0.906518 0.161012 -0.911211 0.15122 0 0 0 0.00281905 l
+-0.906518 0.161012 -0.911537 0.168458 0 0 0 0.00281905 l
+0.310457 0.316311 0.305453 0.326939 0 0 0 0.00281905 l
+0.310457 0.316311 0.30907 0.313922 0 0 0 0.00281905 l
+0.0795931 0.514672 0.0739938 0.528442 0 0 0 0.00281905 l
+0.0795931 0.514672 0.0949823 0.513135 0 0 0 0.00281905 l
+-0.260789 -0.105218 -0.249532 -0.0990797 0 0 0 0.00281905 l
+-0.260789 -0.105218 -0.266285 -0.104597 0 0 0 0.00281905 l
+-0.374112 -0.251253 -0.369819 -0.26197 0 0 0 0.00281905 l
+-0.374112 -0.251253 -0.365357 -0.243224 0 0 0 0.00281905 l
+-0.374112 -0.251253 -0.387661 -0.247529 0 0 0 0.00281905 l
+-0.93593 0.148362 -0.943956 0.135957 0 0 0 0.00281905 l
+-0.93593 0.148362 -0.936026 0.149292 0 0 0 0.00281905 l
+-0.20154 -0.868496 -0.183324 -0.878002 0 0 0 0.00281905 l
+-0.20154 -0.868496 -0.205672 -0.855439 0 0 0 0.00281905 l
+-0.20154 -0.868496 -0.211695 -0.872174 0 0 0 0.00281905 l
+0.617011 0.280696 0.62183 0.257514 0 0 0 0.00281905 l
+0.412754 -0.544489 0.417974 -0.551933 0 0 0 0.00281905 l
+0.412754 -0.544489 0.405923 -0.549714 0 0 0 0.00281905 l
+0.00156488 -0.22872 0.00567514 -0.221812 0 0 0 0.00281905 l
+0.00156488 -0.22872 -0.0087273 -0.219641 0 0 0 0.00281905 l
+0.331199 0.831583 0.340425 0.829587 0 0 0 0.00281905 l
+0.331199 0.831583 0.329852 0.834859 0 0 0 0.00281905 l
+0.550691 -0.00211002 0.550486 -0.0135731 0 0 0 0.00281905 l
+0.663463 -0.313731 0.659346 -0.308518 0 0 0 0.00281905 l
+-0.555229 -0.442267 -0.56413 -0.432009 0 0 0 0.00281905 l
+-0.555229 -0.442267 -0.550086 -0.450519 0 0 0 0.00281905 l
+-0.555229 -0.442267 -0.565435 -0.452104 0 0 0 0.00281905 l
+0.204658 0.635365 0.192976 0.64745 0 0 0 0.00281905 l
+0.204658 0.635365 0.213089 0.635254 0 0 0 0.00281905 l
+0.204658 0.635365 0.197223 0.628567 0 0 0 0.00281905 l
+-0.2754 -0.0530764 -0.266263 -0.0579224 0 0 0 0.00281905 l
+-0.2754 -0.0530764 -0.286321 -0.0463104 0 0 0 0.00281905 l
+-0.2754 -0.0530764 -0.277888 -0.0570166 0 0 0 0.00281905 l
+-0.380921 -0.447 -0.380513 -0.441779 0 0 0 0.00281905 l
+-0.380921 -0.447 -0.382611 -0.448127 0 0 0 0.00281905 l
+0.0931468 0.173973 0.0858474 0.182462 0 0 0 0.00281905 l
+0.0931468 0.173973 0.102942 0.177668 0 0 0 0.00281905 l
+0.0931468 0.173973 0.0796351 0.16744 0 0 0 0.00281905 l
+0.0029867 0.189186 0.00123777 0.178034 0 0 0 0.00281905 l
+0.0029867 0.189186 0.0153318 0.197463 0 0 0 0.00281905 l
+-0.67587 0.234855 -0.663343 0.232292 0 0 0 0.00281905 l
+-0.67587 0.234855 -0.677662 0.2214 0 0 0 0.00281905 l
+0.433054 0.614152 0.42919 0.624869 0 0 0 0.00281905 l
+0.433054 0.614152 0.436464 0.611864 0 0 0 0.00281905 l
+0.253043 0.440504 0.257379 0.427235 0 0 0 0.00281905 l
+-0.427536 -0.392938 -0.41823 -0.388103 0 0 0 0.00281905 l
+-0.427536 -0.392938 -0.432204 -0.395143 0 0 0 0.00281905 l
+-0.490438 -0.58716 -0.480965 -0.594683 0 0 0 0.00281905 l
+-0.490438 -0.58716 -0.49451 -0.59806 0 0 0 0.00281905 l
+-0.490438 -0.58716 -0.507454 -0.574217 0 0 0 0.00281905 l
+-0.721289 0.0773936 -0.710602 0.0811489 0 0 0 0.00281905 l
+-0.721289 0.0773936 -0.729275 0.0833788 0 0 0 0.00281905 l
+-0.428617 -0.61074 -0.419004 -0.611027 0 0 0 0.00281905 l
+-0.428617 -0.61074 -0.425685 -0.6212 0 0 0 0.00281905 l
+-0.428617 -0.61074 -0.431284 -0.605059 0 0 0 0.00281905 l
+0.160395 0.787931 0.164503 0.790452 0 0 0 0.00281905 l
+0.883458 -0.164857 0.881755 -0.148765 0 0 0 0.00281905 l
+0.883458 -0.164857 0.89353 -0.165311 0 0 0 0.00281905 l
+0.883458 -0.164857 0.879196 -0.174847 0 0 0 0.00281905 l
+-0.101343 -0.879654 -0.0915908 -0.879075 0 0 0 0.00281905 l
+-0.101343 -0.879654 -0.103631 -0.885076 0 0 0 0.00281905 l
+0.7771 -0.255417 0.778193 -0.241115 0 0 0 0.00281905 l
+0.7771 -0.255417 0.785 -0.261975 0 0 0 0.00281905 l
+0.7771 -0.255417 0.768658 -0.257161 0 0 0 0.00281905 l
+0.0348004 0.108034 0.0291488 0.113412 0 0 0 0.00281905 l
+-0.641822 -0.287853 -0.629968 -0.272836 0 0 0 0.00281905 l
+-0.641822 -0.287853 -0.65278 -0.299836 0 0 0 0.00281905 l
+0.799544 -0.490547 0.815392 -0.496865 0 0 0 0.00281905 l
+0.799544 -0.490547 0.78566 -0.476611 0 0 0 0.00281905 l
+0.799544 -0.490547 0.796804 -0.494622 0 0 0 0.00281905 l
+-0.314762 0.0296076 -0.303431 0.0386019 0 0 0 0.00281905 l
+-0.314762 0.0296076 -0.320944 0.0404954 0 0 0 0.00281905 l
+-0.965522 -0.19963 -0.972324 -0.177059 0 0 0 0.00281905 l
+-0.965522 -0.19963 -0.94685 -0.202549 0 0 0 0.00281905 l
+0.424658 -0.577795 0.438339 -0.569736 0 0 0 0.00281905 l
+0.424658 -0.577795 0.422017 -0.591783 0 0 0 0.00281905 l
+0.637078 0.764563 0.647717 0.754484 0 0 0 0.00281905 l
+0.637078 0.764563 0.631603 0.763807 0 0 0 0.00281905 l
+-0.0560596 0.635978 -0.054258 0.628488 0 0 0 0.00281905 l
+-0.0560596 0.635978 -0.0499188 0.644873 0 0 0 0.00281905 l
+-0.0630525 -0.536465 -0.0756769 -0.538044 0 0 0 0.00281905 l
+-0.947799 0.116676 -0.949853 0.117858 0 0 0 0.00281905 l
+-0.109139 0.776304 -0.0961382 0.780995 0 0 0 0.00281905 l
+-0.109139 0.776304 -0.110668 0.758072 0 0 0 0.00281905 l
+-0.109139 0.776304 -0.117836 0.77589 0 0 0 0.00281905 l
+-0.241008 0.27807 -0.241066 0.283955 0 0 0 0.00281905 l
+-0.241008 0.27807 -0.233851 0.271721 0 0 0 0.00281905 l
+-0.241008 0.27807 -0.256029 0.270828 0 0 0 0.00281905 l
+-0.0494214 -0.179308 -0.032921 -0.17657 0 0 0 0.00281905 l
+-0.0494214 -0.179308 -0.0522107 -0.1761 0 0 0 0.00281905 l
+0.70167 0.566035 0.696891 0.575034 0 0 0 0.00281905 l
+-0.207412 0.122926 -0.196887 0.116031 0 0 0 0.00281905 l
+-0.207412 0.122926 -0.222462 0.123687 0 0 0 0.00281905 l
+-0.107926 0.585005 -0.107879 0.597322 0 0 0 0.00281905 l
+-0.107926 0.585005 -0.103269 0.569469 0 0 0 0.00281905 l
+-0.564564 0.339642 -0.56698 0.343785 0 0 0 0.00281905 l
+-0.564564 0.339642 -0.56345 0.337304 0 0 0 0.00281905 l
+0.978191 0.00579893 0.982355 0.022313 0 0 0 0.00281905 l
+0.978191 0.00579893 0.995439 0.00548529 0 0 0 0.00281905 l
+0.978191 0.00579893 0.965689 0.0101854 0 0 0 0.00281905 l
+-0.768309 0.388209 -0.762815 0.399585 0 0 0 0.00281905 l
+-0.768309 0.388209 -0.758946 0.383348 0 0 0 0.00281905 l
+-0.768309 0.388209 -0.781476 0.38705 0 0 0 0.00281905 l
+0.471425 0.0670765 0.479699 0.0626173 0 0 0 0.00281905 l
+0.471425 0.0670765 0.465194 0.0679942 0 0 0 0.00281905 l
+-0.535068 0.679154 -0.522488 0.687516 0 0 0 0.00281905 l
+-0.535068 0.679154 -0.544659 0.671935 0 0 0 0.00281905 l
+-0.675506 -0.22828 -0.675337 -0.218086 0 0 0 0.00281905 l
+-0.675506 -0.22828 -0.670948 -0.235338 0 0 0 0.00281905 l
+-0.675506 -0.22828 -0.680305 -0.234959 0 0 0 0.00281905 l
+-0.901597 0.307318 -0.905136 0.320191 0 0 0 0.00281905 l
+-0.901597 0.307318 -0.907521 0.288084 0 0 0 0.00281905 l
+-0.629968 -0.272836 -0.637349 -0.257038 0 0 0 0.00281905 l
+-0.629968 -0.272836 -0.608841 -0.272386 0 0 0 0.00281905 l
+-0.629968 -0.272836 -0.641822 -0.287853 0 0 0 0.00281905 l
+0.407521 -0.00899539 0.398113 -0.00919072 0 0 0 0.00281905 l
+0.272775 0.442278 0.27265 0.44452 0 0 0 0.00281905 l
+0.272775 0.442278 0.278626 0.44116 0 0 0 0.00281905 l
+-0.256803 -0.219258 -0.246014 -0.212158 0 0 0 0.00281905 l
+-0.256803 -0.219258 -0.273266 -0.227016 0 0 0 0.00281905 l
+-0.534629 -0.178345 -0.531938 -0.163738 0 0 0 0.00281905 l
+-0.534629 -0.178345 -0.524245 -0.186631 0 0 0 0.00281905 l
+-0.534629 -0.178345 -0.538273 -0.187557 0 0 0 0.00281905 l
+0.651538 -0.741891 0.650099 -0.741363 0 0 0 0.00281905 l
+-0.689056 -0.349931 -0.673674 -0.363505 0 0 0 0.00281905 l
+-0.689056 -0.349931 -0.704795 -0.347772 0 0 0 0.00281905 l
+0.262516 -0.0152054 0.261716 0.00869818 0 0 0 0.00281905 l
+0.262516 -0.0152054 0.25328 -0.0169596 0 0 0 0.00281905 l
+0.154635 -0.502535 0.156412 -0.492967 0 0 0 0.00281905 l
+0.154635 -0.502535 0.15062 -0.50557 0 0 0 0.00281905 l
+0.389025 0.0481102 0.383687 0.0318404 0 0 0 0.00281905 l
+0.389025 0.0481102 0.38771 0.0490325 0 0 0 0.00281905 l
+-0.654178 -0.468224 -0.64247 -0.456003 0 0 0 0.00281905 l
+-0.654178 -0.468224 -0.66216 -0.469287 0 0 0 0.00281905 l
+-0.64726 -0.00504405 -0.641579 -0.0114108 0 0 0 0.00281905 l
+-0.64726 -0.00504405 -0.64961 -0.00776285 0 0 0 0.00281905 l
+-0.646171 -0.36826 -0.648194 -0.354452 0 0 0 0.00281905 l
+-0.646171 -0.36826 -0.629221 -0.366649 0 0 0 0.00281905 l
+-0.646171 -0.36826 -0.648974 -0.370565 0 0 0 0.00281905 l
+0.459201 0.554054 0.450088 0.571511 0 0 0 0.00281905 l
+0.459201 0.554054 0.459317 0.545806 0 0 0 0.00281905 l
+-0.33107 -0.185575 -0.318006 -0.187835 0 0 0 0.00281905 l
+-0.33107 -0.185575 -0.340426 -0.173472 0 0 0 0.00281905 l
+-0.33107 -0.185575 -0.331394 -0.187139 0 0 0 0.00281905 l
+0.217569 0.115464 0.230371 0.121257 0 0 0 0.00281905 l
+0.217569 0.115464 0.229957 0.10223 0 0 0 0.00281905 l
+0.626423 -0.304997 0.631508 -0.306909 0 0 0 0.00281905 l
+0.626423 -0.304997 0.620552 -0.308709 0 0 0 0.00281905 l
+-0.583502 -0.332021 -0.583892 -0.317741 0 0 0 0.00281905 l
+-0.583502 -0.332021 -0.575306 -0.334004 0 0 0 0.00281905 l
+-0.583502 -0.332021 -0.603358 -0.335057 0 0 0 0.00281905 l
+-0.260016 0.543852 -0.255371 0.540381 0 0 0 0.00281905 l
+-0.260016 0.543852 -0.264194 0.547573 0 0 0 0.00281905 l
+-0.953943 0.191822 -0.957745 0.204277 0 0 0 0.00281905 l
+-0.953943 0.191822 -0.944281 0.187624 0 0 0 0.00281905 l
+-0.953943 0.191822 -0.962639 0.185995 0 0 0 0.00281905 l
+0.0156282 -0.634239 0.0177076 -0.617413 0 0 0 0.00281905 l
+0.0156282 -0.634239 0.0336093 -0.632856 0 0 0 0.00281905 l
+0.0156282 -0.634239 0.011421 -0.637842 0 0 0 0.00281905 l
+0.458553 -0.546045 0.465832 -0.552469 0 0 0 0.00281905 l
+0.458553 -0.546045 0.446969 -0.562288 0 0 0 0.00281905 l
+0.458553 -0.546045 0.450305 -0.538557 0 0 0 0.00281905 l
+0.115589 0.379409 0.124725 0.391256 0 0 0 0.00281905 l
+0.115589 0.379409 0.133307 0.368436 0 0 0 0.00281905 l
+0.115589 0.379409 0.109132 0.386105 0 0 0 0.00281905 l
+-0.168937 0.395541 -0.180647 0.402719 0 0 0 0.00281905 l
+-0.168937 0.395541 -0.153488 0.393147 0 0 0 0.00281905 l
+-0.168937 0.395541 -0.170363 0.392419 0 0 0 0.00281905 l
+0.575323 -0.0253196 0.571655 -0.0268387 0 0 0 0.00281905 l
+0.243199 -0.217891 0.250614 -0.217843 0 0 0 0.00281905 l
+0.243199 -0.217891 0.237721 -0.227045 0 0 0 0.00281905 l
+-0.283706 0.617742 -0.283313 0.605428 0 0 0 0.00281905 l
+-0.283706 0.617742 -0.289573 0.621302 0 0 0 0.00281905 l
+0.135405 -0.675883 0.139044 -0.665521 0 0 0 0.00281905 l
+0.135405 -0.675883 0.117454 -0.68132 0 0 0 0.00281905 l
+-0.0242019 0.369427 -0.023462 0.365896 0 0 0 0.00281905 l
+-0.0242019 0.369427 -0.0277273 0.374333 0 0 0 0.00281905 l
+-0.134417 0.134286 -0.140421 0.151237 0 0 0 0.00281905 l
+-0.150856 -0.188925 -0.153992 -0.198208 0 0 0 0.00281905 l
+-0.150856 -0.188925 -0.151316 -0.185469 0 0 0 0.00281905 l
+-0.150856 -0.188925 -0.135457 -0.190825 0 0 0 0.00281905 l
+-0.395353 0.51913 -0.394173 0.524626 0 0 0 0.00281905 l
+-0.395353 0.51913 -0.40049 0.510975 0 0 0 0.00281905 l
+0.110494 0.649964 0.118572 0.658442 0 0 0 0.00281905 l
+0.110494 0.649964 0.11276 0.636198 0 0 0 0.00281905 l
+-0.318567 0.422037 -0.322111 0.415716 0 0 0 0.00281905 l
+-0.318567 0.422037 -0.302369 0.425803 0 0 0 0.00281905 l
+-0.0973074 -0.710652 -0.0865676 -0.703775 0 0 0 0.00281905 l
+0.578338 -0.610616 0.579447 -0.62234 0 0 0 0.00281905 l
+0.578338 -0.610616 0.573572 -0.608778 0 0 0 0.00281905 l
+0.578338 -0.610616 0.580405 -0.60875 0 0 0 0.00281905 l
+0.0449346 0.352802 0.056529 0.353663 0 0 0 0.00281905 l
+0.0449346 0.352802 0.0338482 0.351798 0 0 0 0.00281905 l
+-0.277084 0.0630049 -0.272049 0.0696736 0 0 0 0.00281905 l
+-0.694613 -0.440951 -0.689079 -0.44193 0 0 0 0.00281905 l
+-0.694613 -0.440951 -0.698736 -0.436966 0 0 0 0.00281905 l
+-0.48358 -0.843971 -0.480971 -0.858857 0 0 0 0.00281905 l
+-0.48358 -0.843971 -0.476887 -0.840469 0 0 0 0.00281905 l
+-0.933061 0.336021 -0.935646 0.343461 0 0 0 0.00281905 l
+-0.933061 0.336021 -0.923433 0.337801 0 0 0 0.00281905 l
+-0.933061 0.336021 -0.935923 0.335072 0 0 0 0.00281905 l
+0.576784 0.707147 0.57982 0.72583 0 0 0 0.00281905 l
+0.576784 0.707147 0.583048 0.698489 0 0 0 0.00281905 l
+-0.289494 -0.420576 -0.283111 -0.418102 0 0 0 0.00281905 l
+-0.289494 -0.420576 -0.294489 -0.41037 0 0 0 0.00281905 l
+-0.520864 0.45846 -0.515154 0.45609 0 0 0 0.00281905 l
+0.532867 0.184044 0.549905 0.182243 0 0 0 0.00281905 l
+-0.674672 -0.49058 -0.671516 -0.479482 0 0 0 0.00281905 l
+-0.674672 -0.49058 -0.660053 -0.502898 0 0 0 0.00281905 l
+0.642694 0.357919 0.639856 0.339225 0 0 0 0.00281905 l
+0.642694 0.357919 0.656864 0.36066 0 0 0 0.00281905 l
+0.642694 0.357919 0.637972 0.363392 0 0 0 0.00281905 l
+0.639094 -0.75934 0.636645 -0.754293 0 0 0 0.00281905 l
+-0.0880438 -0.443854 -0.0847791 -0.448096 0 0 0 0.00281905 l
+-0.0880438 -0.443854 -0.0950944 -0.436901 0 0 0 0.00281905 l
+0.135331 -0.237195 0.136857 -0.22625 0 0 0 0.00281905 l
+0.135331 -0.237195 0.139648 -0.240502 0 0 0 0.00281905 l
+0.135331 -0.237195 0.129635 -0.239677 0 0 0 0.00281905 l
+-0.231297 -0.744985 -0.223604 -0.741251 0 0 0 0.00281905 l
+-0.231297 -0.744985 -0.240216 -0.743999 0 0 0 0.00281905 l
+0.520339 -0.0430718 0.530044 -0.0379473 0 0 0 0.00281905 l
+0.520339 -0.0430718 0.506362 -0.0295732 0 0 0 0.00281905 l
+-0.863008 0.432623 -0.856608 0.429681 0 0 0 0.00281905 l
+-0.863008 0.432623 -0.879973 0.435441 0 0 0 0.00281905 l
+-0.43431 -0.247648 -0.425682 -0.246788 0 0 0 0.00281905 l
+-0.43431 -0.247648 -0.440788 -0.24178 0 0 0 0.00281905 l
+0.267335 -0.409868 0.280996 -0.412842 0 0 0 0.00281905 l
+0.267335 -0.409868 0.266514 -0.419193 0 0 0 0.00281905 l
+-0.81965 -0.39331 -0.822444 -0.376625 0 0 0 0.00281905 l
+-0.81965 -0.39331 -0.839881 -0.402361 0 0 0 0.00281905 l
+0.128677 -0.0628127 0.133383 -0.0694068 0 0 0 0.00281905 l
+0.128677 -0.0628127 0.118378 -0.0687233 0 0 0 0.00281905 l
+0.88454 -0.11695 0.882553 -0.125459 0 0 0 0.00281905 l
+-0.478403 -0.83599 -0.476887 -0.840469 0 0 0 0.00281905 l
+-0.478403 -0.83599 -0.477811 -0.823551 0 0 0 0.00281905 l
+0.303046 -0.0269853 0.316372 -0.0358121 0 0 0 0.00281905 l
+0.303046 -0.0269853 0.289252 -0.0410934 0 0 0 0.00281905 l
+0.303046 -0.0269853 0.293281 -0.0148111 0 0 0 0.00281905 l
+0.29124 -0.377995 0.29333 -0.359338 0 0 0 0.00281905 l
+0.268596 -0.262773 0.258111 -0.263949 0 0 0 0.00281905 l
+0.439044 -0.465089 0.432164 -0.451936 0 0 0 0.00281905 l
+0.439044 -0.465089 0.448406 -0.466242 0 0 0 0.00281905 l
+0.576305 0.581426 0.575914 0.573916 0 0 0 0.00281905 l
+0.576305 0.581426 0.565714 0.599313 0 0 0 0.00281905 l
+-0.107672 0.629454 -0.0998139 0.626165 0 0 0 0.00281905 l
+-0.107672 0.629454 -0.114872 0.629771 0 0 0 0.00281905 l
+-0.37574 0.775321 -0.363577 0.786062 0 0 0 0.00281905 l
+-0.37574 0.775321 -0.380304 0.788404 0 0 0 0.00281905 l
+-0.37574 0.775321 -0.382249 0.767112 0 0 0 0.00281905 l
+-0.129336 -0.223367 -0.11943 -0.227097 0 0 0 0.00281905 l
+-0.129336 -0.223367 -0.129876 -0.237316 0 0 0 0.00281905 l
+-0.129336 -0.223367 -0.123731 -0.216357 0 0 0 0.00281905 l
+-0.129336 -0.223367 -0.145989 -0.21513 0 0 0 0.00281905 l
+0.872233 0.474953 0.866411 0.479533 0 0 0 0.00281905 l
+-0.25286 0.374782 -0.24988 0.380791 0 0 0 0.00281905 l
+-0.25286 0.374782 -0.256929 0.372516 0 0 0 0.00281905 l
+0.156873 -0.75443 0.152708 -0.742685 0 0 0 0.00281905 l
+0.156873 -0.75443 0.160339 -0.756281 0 0 0 0.00281905 l
+-0.308776 -0.324811 -0.310971 -0.314509 0 0 0 0.00281905 l
+-0.308776 -0.324811 -0.306303 -0.334627 0 0 0 0.00281905 l
+0.447924 0.218862 0.454167 0.216302 0 0 0 0.00281905 l
+0.447924 0.218862 0.452465 0.22766 0 0 0 0.00281905 l
+0.219849 0.204669 0.221944 0.195347 0 0 0 0.00281905 l
+0.219849 0.204669 0.224383 0.210693 0 0 0 0.00281905 l
+-0.314606 0.834501 -0.314212 0.835639 0 0 0 0.00281905 l
+0.169662 0.378507 0.177908 0.36511 0 0 0 0.00281905 l
+0.169662 0.378507 0.165088 0.391175 0 0 0 0.00281905 l
+0.169662 0.378507 0.161363 0.367915 0 0 0 0.00281905 l
+-0.755903 0.601222 -0.753497 0.588773 0 0 0 0.00281905 l
+-0.755903 0.601222 -0.76161 0.608224 0 0 0 0.00281905 l
+0.0739938 0.528442 0.0768841 0.551869 0 0 0 0.00281905 l
+0.0739938 0.528442 0.0795931 0.514672 0 0 0 0.00281905 l
+0.0739938 0.528442 0.0642648 0.522771 0 0 0 0.00281905 l
+0.469796 0.620896 0.470226 0.620232 0 0 0 0.00281905 l
+-0.106155 -0.796698 -0.106892 -0.79253 0 0 0 0.00281905 l
+-0.106155 -0.796698 -0.109836 -0.798251 0 0 0 0.00281905 l
+-0.0528756 -0.252589 -0.0511313 -0.260431 0 0 0 0.00281905 l
+-0.0528756 -0.252589 -0.0602744 -0.254022 0 0 0 0.00281905 l
+0.28329 0.214294 0.295555 0.210707 0 0 0 0.00281905 l
+0.28329 0.214294 0.277643 0.207278 0 0 0 0.00281905 l
+0.28329 0.214294 0.274748 0.21694 0 0 0 0.00281905 l
+0.376004 -0.0487393 0.381735 -0.036384 0 0 0 0.00281905 l
+0.376004 -0.0487393 0.35632 -0.0457503 0 0 0 0.00281905 l
+-0.733913 -0.201048 -0.732872 -0.199186 0 0 0 0.00281905 l
+-0.733913 -0.201048 -0.746692 -0.205664 0 0 0 0.00281905 l
+-0.354723 0.932487 -0.344168 0.937169 0 0 0 0.00281905 l
+-0.354723 0.932487 -0.354081 0.925412 0 0 0 0.00281905 l
+-0.173261 0.719661 -0.171737 0.715379 0 0 0 0.00281905 l
+0.357444 -0.149104 0.357808 -0.156312 0 0 0 0.00281905 l
+0.357444 -0.149104 0.360117 -0.143042 0 0 0 0.00281905 l
+0.357444 -0.149104 0.355674 -0.149235 0 0 0 0.00281905 l
+-0.762908 0.0832709 -0.752681 0.101229 0 0 0 0.00281905 l
+-0.762908 0.0832709 -0.778927 0.0803473 0 0 0 0.00281905 l
+0.904646 0.0320615 0.904161 0.0448206 0 0 0 0.00281905 l
+0.904646 0.0320615 0.910713 0.0296029 0 0 0 0.00281905 l
+0.904646 0.0320615 0.897807 0.0304783 0 0 0 0.00281905 l
+0.346473 0.191668 0.352261 0.191609 0 0 0 0.00281905 l
+0.436672 -0.00819742 0.435286 -0.0109673 0 0 0 0.00281905 l
+0.0367495 -0.773698 0.0309108 -0.762964 0 0 0 0.00281905 l
+0.0367495 -0.773698 0.0207839 -0.782327 0 0 0 0.00281905 l
+-0.480281 0.674573 -0.481691 0.680988 0 0 0 0.00281905 l
+-0.480281 0.674573 -0.468177 0.664858 0 0 0 0.00281905 l
+-0.480281 0.674573 -0.48651 0.671979 0 0 0 0.00281905 l
+0.364509 0.210525 0.363134 0.203816 0 0 0 0.00281905 l
+0.364509 0.210525 0.351313 0.220088 0 0 0 0.00281905 l
+0.659154 -0.38286 0.66741 -0.389189 0 0 0 0.00281905 l
+0.659154 -0.38286 0.661024 -0.37872 0 0 0 0.00281905 l
+0.687216 -0.186402 0.691636 -0.179852 0 0 0 0.00281905 l
+-0.849258 0.122367 -0.857489 0.10738 0 0 0 0.00281905 l
+-0.849258 0.122367 -0.866928 0.136351 0 0 0 0.00281905 l
+-0.627689 0.292287 -0.632388 0.286165 0 0 0 0.00281905 l
+-0.627689 0.292287 -0.629707 0.293885 0 0 0 0.00281905 l
+0.846915 0.383533 0.857665 0.379156 0 0 0 0.00281905 l
+0.0728685 -0.484108 0.0885387 -0.487058 0 0 0 0.00281905 l
+0.0728685 -0.484108 0.0662608 -0.49624 0 0 0 0.00281905 l
+0.0728685 -0.484108 0.0621519 -0.475619 0 0 0 0.00281905 l
+0.213089 0.635254 0.218971 0.614714 0 0 0 0.00281905 l
+0.213089 0.635254 0.204658 0.635365 0 0 0 0.00281905 l
+0.655731 0.307494 0.654281 0.3051 0 0 0 0.00281905 l
+0.487325 -0.519395 0.48701 -0.514374 0 0 0 0.00281905 l
+0.487325 -0.519395 0.488957 -0.530737 0 0 0 0.00281905 l
+0.286502 0.779093 0.285576 0.798016 0 0 0 0.00281905 l
+0.286502 0.779093 0.298209 0.773204 0 0 0 0.00281905 l
+0.286502 0.779093 0.273448 0.77534 0 0 0 0.00281905 l
+-0.943956 0.135957 -0.93593 0.148362 0 0 0 0.00281905 l
+-0.943956 0.135957 -0.925487 0.123232 0 0 0 0.00281905 l
+-0.943956 0.135957 -0.949143 0.11944 0 0 0 0.00281905 l
+-0.606491 -0.0428925 -0.617601 -0.0288869 0 0 0 0.00281905 l
+-0.606491 -0.0428925 -0.600431 -0.0375296 0 0 0 0.00281905 l
+0.0169789 -0.434153 0.0281375 -0.437151 0 0 0 0.00281905 l
+0.706749 0.585894 0.700327 0.587275 0 0 0 0.00281905 l
+0.353828 0.343307 0.353544 0.346141 0 0 0 0.00281905 l
+0.353828 0.343307 0.359047 0.344191 0 0 0 0.00281905 l
+0.353828 0.343307 0.348834 0.34252 0 0 0 0.00281905 l
+0.316353 0.106837 0.313471 0.11415 0 0 0 0.00281905 l
+0.316353 0.106837 0.311801 0.103077 0 0 0 0.00281905 l
+-0.82867 -0.198986 -0.830781 -0.20861 0 0 0 0.00281905 l
+-0.82867 -0.198986 -0.820564 -0.194413 0 0 0 0.00281905 l
+0.603143 0.0773387 0.615357 0.0775967 0 0 0 0.00281905 l
+0.603143 0.0773387 0.598111 0.0639224 0 0 0 0.00281905 l
+0.306613 -0.757377 0.307182 -0.752621 0 0 0 0.00281905 l
+0.306613 -0.757377 0.320783 -0.76126 0 0 0 0.00281905 l
+0.306613 -0.757377 0.304145 -0.765061 0 0 0 0.00281905 l
+-0.268831 -0.540096 -0.269775 -0.532888 0 0 0 0.00281905 l
+-0.381141 0.397538 -0.374543 0.392668 0 0 0 0.00281905 l
+0.207678 -0.0377392 0.210072 -0.0281794 0 0 0 0.00281905 l
+0.207678 -0.0377392 0.187478 -0.0425438 0 0 0 0.00281905 l
+-0.845401 -0.173382 -0.852209 -0.163375 0 0 0 0.00281905 l
+-0.845401 -0.173382 -0.850534 -0.17631 0 0 0 0.00281905 l
+-0.108647 -0.235515 -0.0934927 -0.223776 0 0 0 0.00281905 l
+-0.108647 -0.235515 -0.111204 -0.235757 0 0 0 0.00281905 l
+-0.0118951 -0.854299 -0.0166758 -0.856668 0 0 0 0.00281905 l
+-0.0593838 -0.1635 -0.0505844 -0.146945 0 0 0 0.00281905 l
+-0.0593838 -0.1635 -0.0522107 -0.1761 0 0 0 0.00281905 l
+-0.0593838 -0.1635 -0.0734321 -0.161026 0 0 0 0.00281905 l
+0.864351 -0.0133905 0.876144 -0.0122709 0 0 0 0.00281905 l
+0.864351 -0.0133905 0.861334 -0.0157504 0 0 0 0.00281905 l
+-0.858749 -0.271037 -0.844062 -0.276128 0 0 0 0.00281905 l
+-0.858749 -0.271037 -0.866708 -0.286972 0 0 0 0.00281905 l
+0.392914 -0.719115 0.382146 -0.72275 0 0 0 0.00281905 l
+0.179947 -0.605546 0.17954 -0.62451 0 0 0 0.00281905 l
+0.179947 -0.605546 0.172469 -0.599028 0 0 0 0.00281905 l
+0.876936 -0.425273 0.882583 -0.42218 0 0 0 0.00281905 l
+0.454214 0.606857 0.460012 0.593099 0 0 0 0.00281905 l
+0.454214 0.606857 0.436464 0.611864 0 0 0 0.00281905 l
+-0.303486 0.903826 -0.295968 0.906392 0 0 0 0.00281905 l
+0.694835 -0.479655 0.682591 -0.49324 0 0 0 0.00281905 l
+0.694835 -0.479655 0.678419 -0.469666 0 0 0 0.00281905 l
+-0.813272 0.210077 -0.808958 0.220942 0 0 0 0.00281905 l
+-0.813272 0.210077 -0.815881 0.18919 0 0 0 0.00281905 l
+-0.0586317 0.0550902 -0.0516829 0.0473933 0 0 0 0.00281905 l
+-0.0586317 0.0550902 -0.0504062 0.0642808 0 0 0 0.00281905 l
+-0.0586317 0.0550902 -0.0708782 0.0501204 0 0 0 0.00281905 l
+-0.672335 -0.264245 -0.671474 -0.257572 0 0 0 0.00281905 l
+-0.672335 -0.264245 -0.670845 -0.275805 0 0 0 0.00281905 l
+-0.0567037 0.898214 -0.0746222 0.889889 0 0 0 0.00281905 l
+0.0983791 -0.418494 0.100478 -0.42071 0 0 0 0.00281905 l
+0.0983791 -0.418494 0.0880505 -0.423995 0 0 0 0.00281905 l
+0.757346 -0.3361 0.766176 -0.340296 0 0 0 0.00281905 l
+0.757346 -0.3361 0.747678 -0.338191 0 0 0 0.00281905 l
+-0.419209 -0.669044 -0.424513 -0.656724 0 0 0 0.00281905 l
+-0.419209 -0.669044 -0.416139 -0.670006 0 0 0 0.00281905 l
+-0.419209 -0.669044 -0.421323 -0.67407 0 0 0 0.00281905 l
+0.0350647 -0.47592 0.0367689 -0.469022 0 0 0 0.00281905 l
+0.0350647 -0.47592 0.0342533 -0.480061 0 0 0 0.00281905 l
+0.598735 0.366225 0.596827 0.376222 0 0 0 0.00281905 l
+0.598735 0.366225 0.608925 0.358462 0 0 0 0.00281905 l
+0.598735 0.366225 0.594688 0.364191 0 0 0 0.00281905 l
+0.172874 0.620734 0.183955 0.610026 0 0 0 0.00281905 l
+0.172874 0.620734 0.172109 0.622042 0 0 0 0.00281905 l
+0.738535 -0.194993 0.754741 -0.187928 0 0 0 0.00281905 l
+0.614831 -0.495595 0.606935 -0.513012 0 0 0 0.00281905 l
+0.252287 -0.732238 0.240494 -0.721937 0 0 0 0.00281905 l
+0.217569 0.753216 0.224202 0.745603 0 0 0 0.00281905 l
+0.217569 0.753216 0.210519 0.74965 0 0 0 0.00281905 l
+0.217569 0.753216 0.215666 0.756402 0 0 0 0.00281905 l
+0.0424135 -0.197435 0.057302 -0.203303 0 0 0 0.00281905 l
+0.0424135 -0.197435 0.0338978 -0.194606 0 0 0 0.00281905 l
+-0.94685 -0.202549 -0.948558 -0.213544 0 0 0 0.00281905 l
+-0.94685 -0.202549 -0.944361 -0.202361 0 0 0 0.00281905 l
+-0.94685 -0.202549 -0.965522 -0.19963 0 0 0 0.00281905 l
+0.880251 0.15024 0.883853 0.14962 0 0 0 0.00281905 l
+0.880251 0.15024 0.871776 0.14372 0 0 0 0.00281905 l
+0.498362 -0.236065 0.507831 -0.22673 0 0 0 0.00281905 l
+0.498362 -0.236065 0.504243 -0.246813 0 0 0 0.00281905 l
+0.498362 -0.236065 0.486842 -0.237993 0 0 0 0.00281905 l
+-0.00805386 -0.170471 0.000946614 -0.165513 0 0 0 0.00281905 l
+-0.00805386 -0.170471 -0.0091847 -0.184857 0 0 0 0.00281905 l
+0.112264 -0.86867 0.109962 -0.884259 0 0 0 0.00281905 l
+0.112264 -0.86867 0.121346 -0.858763 0 0 0 0.00281905 l
+0.433343 0.0293802 0.439386 0.0171061 0 0 0 0.00281905 l
+-0.14996 0.650551 -0.146203 0.654434 0 0 0 0.00281905 l
+-0.102681 -0.953888 -0.106219 -0.948816 0 0 0 0.00281905 l
+-0.105063 -0.176941 -0.0888636 -0.179631 0 0 0 0.00281905 l
+-0.105063 -0.176941 -0.101912 -0.197872 0 0 0 0.00281905 l
+0.273243 0.768981 0.273448 0.77534 0 0 0 0.00281905 l
+0.273243 0.768981 0.26709 0.758891 0 0 0 0.00281905 l
+0.00167698 0.690373 0.00627197 0.706029 0 0 0 0.00281905 l
+0.00167698 0.690373 0.00320947 0.680519 0 0 0 0.00281905 l
+0.00167698 0.690373 -0.0101216 0.685435 0 0 0 0.00281905 l
+0.0998299 0.0455969 0.100583 0.0328563 0 0 0 0.00281905 l
+0.0998299 0.0455969 0.110461 0.0574462 0 0 0 0.00281905 l
+0.0998299 0.0455969 0.0879119 0.0484809 0 0 0 0.00281905 l
+0.566212 0.490944 0.570182 0.49395 0 0 0 0.00281905 l
+0.566212 0.490944 0.551623 0.501886 0 0 0 0.00281905 l
+-0.476657 0.812986 -0.459171 0.800915 0 0 0 0.00281905 l
+-0.476657 0.812986 -0.483647 0.828384 0 0 0 0.00281905 l
+-0.476657 0.812986 -0.464293 0.821904 0 0 0 0.00281905 l
+0.379374 0.646196 0.387772 0.650882 0 0 0 0.00281905 l
+0.379374 0.646196 0.375036 0.650233 0 0 0 0.00281905 l
+-0.328594 0.0880137 -0.337262 0.101963 0 0 0 0.00281905 l
+0.0849622 0.907348 0.0908494 0.890395 0 0 0 0.00281905 l
+0.0849622 0.907348 0.0766732 0.92613 0 0 0 0.00281905 l
+0.0867214 -0.927503 0.0905404 -0.916858 0 0 0 0.00281905 l
+0.0867214 -0.927503 0.091493 -0.929001 0 0 0 0.00281905 l
+0.0867214 -0.927503 0.0752201 -0.921786 0 0 0 0.00281905 l
+0.0867214 -0.927503 0.0804705 -0.933762 0 0 0 0.00281905 l
+0.61523 -0.0217753 0.626875 -0.0276707 0 0 0 0.00281905 l
+0.61523 -0.0217753 0.602303 -0.0232589 0 0 0 0.00281905 l
+-0.27926 -0.615004 -0.284254 -0.619588 0 0 0 0.00281905 l
+0.469686 0.822955 0.476705 0.826157 0 0 0 0.00281905 l
+0.469686 0.822955 0.454545 0.805971 0 0 0 0.00281905 l
+0.0809075 -0.78458 0.0857634 -0.793244 0 0 0 0.00281905 l
+0.0809075 -0.78458 0.0683795 -0.780394 0 0 0 0.00281905 l
+-0.647439 0.713238 -0.645992 0.713161 0 0 0 0.00281905 l
+-0.647439 0.713238 -0.648726 0.709793 0 0 0 0.00281905 l
+-0.209956 0.683666 -0.217782 0.690022 0 0 0 0.00281905 l
+0.427859 -0.141307 0.432481 -0.15578 0 0 0 0.00281905 l
+-0.72288 0.318033 -0.719672 0.315816 0 0 0 0.00281905 l
+-0.72288 0.318033 -0.733246 0.323356 0 0 0 0.00281905 l
+-0.759482 -0.324597 -0.746132 -0.310331 0 0 0 0.00281905 l
+-0.759482 -0.324597 -0.746498 -0.337325 0 0 0 0.00281905 l
+-0.759482 -0.324597 -0.769377 -0.320386 0 0 0 0.00281905 l
+-0.724206 -0.543572 -0.721566 -0.535093 0 0 0 0.00281905 l
+-0.724206 -0.543572 -0.715607 -0.548499 0 0 0 0.00281905 l
+-0.724206 -0.543572 -0.730667 -0.547146 0 0 0 0.00281905 l
+-0.591313 -0.138944 -0.575823 -0.13599 0 0 0 0.00281905 l
+-0.591313 -0.138944 -0.591079 -0.146692 0 0 0 0.00281905 l
+-0.591313 -0.138944 -0.5975 -0.128083 0 0 0 0.00281905 l
+-0.00440754 -0.283809 -2.15015e-05 -0.296169 0 0 0 0.00281905 l
+-0.00440754 -0.283809 -0.00257454 -0.266219 0 0 0 0.00281905 l
+-0.662789 -0.581957 -0.661313 -0.575778 0 0 0 0.00281905 l
+-0.662789 -0.581957 -0.678578 -0.589335 0 0 0 0.00281905 l
+-0.754855 0.165196 -0.738376 0.16698 0 0 0 0.00281905 l
+-0.754855 0.165196 -0.767365 0.16449 0 0 0 0.00281905 l
+0.0717954 0.0924075 0.069898 0.0992727 0 0 0 0.00281905 l
+0.0717954 0.0924075 0.0627133 0.0860404 0 0 0 0.00281905 l
+0.397097 0.430242 0.411143 0.439133 0 0 0 0.00281905 l
+0.397097 0.430242 0.392899 0.428666 0 0 0 0.00281905 l
+0.306646 0.83607 0.30636 0.819854 0 0 0 0.00281905 l
+0.306646 0.83607 0.303971 0.85099 0 0 0 0.00281905 l
+0.197223 0.628567 0.195921 0.628426 0 0 0 0.00281905 l
+0.197223 0.628567 0.204658 0.635365 0 0 0 0.00281905 l
+0.660966 -0.628441 0.658642 -0.633765 0 0 0 0.00281905 l
+0.660966 -0.628441 0.662405 -0.622525 0 0 0 0.00281905 l
+-0.616926 0.648088 -0.608397 0.651242 0 0 0 0.00281905 l
+-0.616926 0.648088 -0.613293 0.639202 0 0 0 0.00281905 l
+-0.522012 -0.631433 -0.524123 -0.641862 0 0 0 0.00281905 l
+0.168401 0.123693 0.178791 0.122922 0 0 0 0.00281905 l
+-0.203619 0.600583 -0.207374 0.576815 0 0 0 0.00281905 l
+0.777687 0.0377925 0.788237 0.0539035 0 0 0 0.00281905 l
+0.777687 0.0377925 0.78679 0.034011 0 0 0 0.00281905 l
+0.777687 0.0377925 0.770751 0.0195839 0 0 0 0.00281905 l
+0.700394 0.48656 0.690203 0.487685 0 0 0 0.00281905 l
+0.30739 0.705442 0.305646 0.700255 0 0 0 0.00281905 l
+0.30739 0.705442 0.303633 0.7054 0 0 0 0.00281905 l
+0.561308 0.734885 0.57563 0.745279 0 0 0 0.00281905 l
+0.561308 0.734885 0.554963 0.741949 0 0 0 0.00281905 l
+0.329436 0.916026 0.337558 0.922349 0 0 0 0.00281905 l
+0.329436 0.916026 0.325626 0.911869 0 0 0 0.00281905 l
+-0.555345 0.244095 -0.558446 0.256713 0 0 0 0.00281905 l
+-0.64961 -0.00776285 -0.64726 -0.00504405 0 0 0 0.00281905 l
+-0.64961 -0.00776285 -0.662496 -0.0211437 0 0 0 0.00281905 l
+-0.141783 -0.323027 -0.14505 -0.329224 0 0 0 0.00281905 l
+-0.123731 -0.216357 -0.129336 -0.223367 0 0 0 0.00281905 l
+-0.344136 0.133933 -0.336658 0.117928 0 0 0 0.00281905 l
+-0.344136 0.133933 -0.332122 0.137755 0 0 0 0.00281905 l
+-0.344136 0.133933 -0.356705 0.124652 0 0 0 0.00281905 l
+0.491381 0.601615 0.480623 0.594851 0 0 0 0.00281905 l
+0.435948 -0.0773629 0.443728 -0.0804721 0 0 0 0.00281905 l
+0.164523 0.921324 0.174381 0.912756 0 0 0 0.00281905 l
+0.164523 0.921324 0.169357 0.925219 0 0 0 0.00281905 l
+0.164523 0.921324 0.146646 0.923977 0 0 0 0.00281905 l
+0.172611 0.541617 0.175437 0.527711 0 0 0 0.00281905 l
+0.172611 0.541617 0.17922 0.553693 0 0 0 0.00281905 l
+-0.631199 0.173401 -0.626341 0.174345 0 0 0 0.00281905 l
+-0.631199 0.173401 -0.633445 0.179238 0 0 0 0.00281905 l
+0.511061 -0.724836 0.525164 -0.738775 0 0 0 0.00281905 l
+0.511061 -0.724836 0.50791 -0.722794 0 0 0 0.00281905 l
+-0.830781 -0.20861 -0.82867 -0.198986 0 0 0 0.00281905 l
+-0.830781 -0.20861 -0.819507 -0.212469 0 0 0 0.00281905 l
+-0.830781 -0.20861 -0.833461 -0.227966 0 0 0 0.00281905 l
+0.754331 0.537284 0.756378 0.533796 0 0 0 0.00281905 l
+0.754331 0.537284 0.753058 0.53811 0 0 0 0.00281905 l
+-0.786227 0.488405 -0.793235 0.471507 0 0 0 0.00281905 l
+-0.786227 0.488405 -0.792319 0.501497 0 0 0 0.00281905 l
+-0.786227 0.488405 -0.774885 0.491976 0 0 0 0.00281905 l
+0.280996 -0.412842 0.291319 -0.405491 0 0 0 0.00281905 l
+0.280996 -0.412842 0.267335 -0.409868 0 0 0 0.00281905 l
+0.695096 -0.213498 0.6792 -0.220858 0 0 0 0.00281905 l
+0.695096 -0.213498 0.687327 -0.204701 0 0 0 0.00281905 l
+-0.28512 0.744758 -0.289121 0.746069 0 0 0 0.00281905 l
+-0.263504 -0.132154 -0.256641 -0.138508 0 0 0 0.00281905 l
+-0.263504 -0.132154 -0.269215 -0.145084 0 0 0 0.00281905 l
+-0.274472 -0.91482 -0.284736 -0.932627 0 0 0 0.00281905 l
+-0.274472 -0.91482 -0.280635 -0.905405 0 0 0 0.00281905 l
+-0.0381145 -0.676058 -0.0278282 -0.68546 0 0 0 0.00281905 l
+-0.0381145 -0.676058 -0.0398061 -0.672967 0 0 0 0.00281905 l
+0.513299 0.14065 0.520598 0.138694 0 0 0 0.00281905 l
+0.513299 0.14065 0.512863 0.135356 0 0 0 0.00281905 l
+-0.203704 -0.551123 -0.203258 -0.547108 0 0 0 0.00281905 l
+-0.203704 -0.551123 -0.201918 -0.567312 0 0 0 0.00281905 l
+-0.691909 -0.567651 -0.697907 -0.574269 0 0 0 0.00281905 l
+-0.691909 -0.567651 -0.697266 -0.559353 0 0 0 0.00281905 l
+-0.691909 -0.567651 -0.675355 -0.562256 0 0 0 0.00281905 l
+0.252656 0.591472 0.248608 0.579864 0 0 0 0.00281905 l
+0.252656 0.591472 0.257408 0.598408 0 0 0 0.00281905 l
+-0.976962 -0.172154 -0.972324 -0.177059 0 0 0 0.00281905 l
+0.49654 0.091652 0.495587 0.0888765 0 0 0 0.00281905 l
+0.951404 0.0753673 0.957023 0.085221 0 0 0 0.00281905 l
+0.951404 0.0753673 0.945454 0.0688078 0 0 0 0.00281905 l
+-0.470607 -0.169915 -0.475633 -0.183865 0 0 0 0.00281905 l
+0.265131 -0.868861 0.27181 -0.880524 0 0 0 0.00281905 l
+0.265131 -0.868861 0.258928 -0.857938 0 0 0 0.00281905 l
+-0.651832 -0.0742272 -0.650096 -0.0707802 0 0 0 0.00281905 l
+-0.651832 -0.0742272 -0.660567 -0.0793311 0 0 0 0.00281905 l
+0.19705 0.336669 0.191791 0.34716 0 0 0 0.00281905 l
+0.19705 0.336669 0.190112 0.329727 0 0 0 0.00281905 l
+-0.0352988 0.59281 -0.0434513 0.604003 0 0 0 0.00281905 l
+-0.521148 -0.0434508 -0.521767 -0.0299253 0 0 0 0.00281905 l
+-0.521148 -0.0434508 -0.523826 -0.0454869 0 0 0 0.00281905 l
+-0.595584 0.540501 -0.595312 0.548189 0 0 0 0.00281905 l
+-0.595584 0.540501 -0.580256 0.531829 0 0 0 0.00281905 l
+-0.595584 0.540501 -0.60283 0.540468 0 0 0 0.00281905 l
+-0.961788 0.16872 -0.956778 0.160253 0 0 0 0.00281905 l
+-0.961788 0.16872 -0.966114 0.175631 0 0 0 0.00281905 l
+-0.732255 -0.630928 -0.729552 -0.646194 0 0 0 0.00281905 l
+-0.732255 -0.630928 -0.730765 -0.611932 0 0 0 0.00281905 l
+-0.614596 0.515187 -0.625691 0.497352 0 0 0 0.00281905 l
+-0.614596 0.515187 -0.609176 0.516777 0 0 0 0.00281905 l
+-0.614596 0.515187 -0.629935 0.526809 0 0 0 0.00281905 l
+-0.0325896 0.173567 -0.0387187 0.18083 0 0 0 0.00281905 l
+-0.0146425 -0.0909829 -0.00651781 -0.0735509 0 0 0 0.00281905 l
+-0.0146425 -0.0909829 -0.02841 -0.0909643 0 0 0 0.00281905 l
+0.103457 0.893661 0.108754 0.893897 0 0 0 0.00281905 l
+0.103457 0.893661 0.0908494 0.890395 0 0 0 0.00281905 l
+0.829159 -0.0187002 0.825855 -0.0338598 0 0 0 0.00281905 l
+0.829159 -0.0187002 0.835501 -0.0188345 0 0 0 0.00281905 l
+-0.187308 0.0520719 -0.174727 0.0604758 0 0 0 0.00281905 l
+-0.187308 0.0520719 -0.185058 0.0458942 0 0 0 0.00281905 l
+0.118378 -0.167354 0.117998 -0.158719 0 0 0 0.00281905 l
+0.118378 -0.167354 0.128624 -0.167753 0 0 0 0.00281905 l
+0.118378 -0.167354 0.110227 -0.171234 0 0 0 0.00281905 l
+-0.222333 0.202339 -0.229485 0.192712 0 0 0 0.00281905 l
+-0.614876 -0.0661967 -0.603287 -0.0859752 0 0 0 0.00281905 l
+-0.614876 -0.0661967 -0.629075 -0.0599193 0 0 0 0.00281905 l
+-0.714406 0.588104 -0.715659 0.606144 0 0 0 0.00281905 l
+-0.714406 0.588104 -0.708834 0.584134 0 0 0 0.00281905 l
+0.101861 -0.721985 0.109904 -0.735568 0 0 0 0.00281905 l
+0.101861 -0.721985 0.0988206 -0.708685 0 0 0 0.00281905 l
+-0.705349 -0.169847 -0.688653 -0.169606 0 0 0 0.00281905 l
+-0.705349 -0.169847 -0.71334 -0.17131 0 0 0 0.00281905 l
+0.569638 0.0568218 0.566024 0.0512999 0 0 0 0.00281905 l
+0.427798 -0.0985427 0.431016 -0.101707 0 0 0 0.00281905 l
+-0.232439 -0.63291 -0.231704 -0.633897 0 0 0 0.00281905 l
+-0.232439 -0.63291 -0.245785 -0.627513 0 0 0 0.00281905 l
+0.6158 0.253786 0.62183 0.257514 0 0 0 0.00281905 l
+0.6158 0.253786 0.619518 0.248199 0 0 0 0.00281905 l
+0.6158 0.253786 0.606682 0.249112 0 0 0 0.00281905 l
+0.155936 -0.0129222 0.163962 -0.00261265 0 0 0 0.00281905 l
+0.155936 -0.0129222 0.165369 -0.0195056 0 0 0 0.00281905 l
+0.658198 0.207619 0.665123 0.19205 0 0 0 0.00281905 l
+0.658198 0.207619 0.659074 0.224573 0 0 0 0.00281905 l
+0.658198 0.207619 0.635641 0.212347 0 0 0 0.00281905 l
+0.356198 -0.857124 0.367502 -0.864417 0 0 0 0.00281905 l
+0.356198 -0.857124 0.350031 -0.860059 0 0 0 0.00281905 l
+-0.225848 -0.656221 -0.224238 -0.643785 0 0 0 0.00281905 l
+-0.225848 -0.656221 -0.237224 -0.663572 0 0 0 0.00281905 l
+0.533824 0.134311 0.533701 0.153689 0 0 0 0.00281905 l
+0.533824 0.134311 0.534408 0.127824 0 0 0 0.00281905 l
+0.533824 0.134311 0.520598 0.138694 0 0 0 0.00281905 l
+-0.118871 -0.886589 -0.103631 -0.885076 0 0 0 0.00281905 l
+-0.118871 -0.886589 -0.126333 -0.894108 0 0 0 0.00281905 l
+0.925179 0.23994 0.910972 0.240045 0 0 0 0.00281905 l
+0.600647 -0.516872 0.606935 -0.513012 0 0 0 0.00281905 l
+0.0137035 0.652096 0.0142219 0.647383 0 0 0 0.00281905 l
+0.0137035 0.652096 0.0190522 0.65544 0 0 0 0.00281905 l
+0.0137035 0.652096 0.0100262 0.649847 0 0 0 0.00281905 l
+0.0373541 0.551675 0.0423745 0.568368 0 0 0 0.00281905 l
+0.0373541 0.551675 0.0412184 0.550722 0 0 0 0.00281905 l
+0.0373541 0.551675 0.0332703 0.550079 0 0 0 0.00281905 l
+0.0765299 0.262166 0.0742174 0.251437 0 0 0 0.00281905 l
+0.0765299 0.262166 0.0895203 0.263639 0 0 0 0.00281905 l
+-0.585019 0.144556 -0.590623 0.165897 0 0 0 0.00281905 l
+-0.585019 0.144556 -0.570767 0.148407 0 0 0 0.00281905 l
+-0.585019 0.144556 -0.57714 0.131851 0 0 0 0.00281905 l
+-0.76811 0.294511 -0.759496 0.290101 0 0 0 0.00281905 l
+-0.76811 0.294511 -0.779921 0.289873 0 0 0 0.00281905 l
+-0.378806 -0.137068 -0.378745 -0.142461 0 0 0 0.00281905 l
+-0.378806 -0.137068 -0.376102 -0.132359 0 0 0 0.00281905 l
+0.223221 0.386072 0.217039 0.396332 0 0 0 0.00281905 l
+0.223221 0.386072 0.233576 0.392689 0 0 0 0.00281905 l
+0.223221 0.386072 0.222221 0.382532 0 0 0 0.00281905 l
+-0.583892 0.466734 -0.577604 0.468427 0 0 0 0.00281905 l
+-0.583892 0.466734 -0.591159 0.45566 0 0 0 0.00281905 l
+-0.18747 -0.213936 -0.187522 -0.198287 0 0 0 0.00281905 l
+-0.18747 -0.213936 -0.205614 -0.214678 0 0 0 0.00281905 l
+0.477722 -0.272837 0.469928 -0.260851 0 0 0 0.00281905 l
+0.477722 -0.272837 0.480452 -0.279308 0 0 0 0.00281905 l
+-0.537166 0.268566 -0.524107 0.275957 0 0 0 0.00281905 l
+-0.489254 -0.354504 -0.48241 -0.341168 0 0 0 0.00281905 l
+-0.489254 -0.354504 -0.4977 -0.349606 0 0 0 0.00281905 l
+-0.0847791 -0.448096 -0.0725904 -0.462424 0 0 0 0.00281905 l
+-0.0847791 -0.448096 -0.0740086 -0.437677 0 0 0 0.00281905 l
+-0.0847791 -0.448096 -0.0880438 -0.443854 0 0 0 0.00281905 l
+-0.236085 0.238986 -0.231573 0.257244 0 0 0 0.00281905 l
+-0.236085 0.238986 -0.230335 0.237322 0 0 0 0.00281905 l
+-0.236085 0.238986 -0.2488 0.225416 0 0 0 0.00281905 l
+-0.947806 0.0802568 -0.948207 0.0760728 0 0 0 0.00281905 l
+-0.947806 0.0802568 -0.938674 0.0913576 0 0 0 0.00281905 l
+0.397497 0.376167 0.400865 0.377707 0 0 0 0.00281905 l
+0.397497 0.376167 0.391677 0.377247 0 0 0 0.00281905 l
+0.439147 -0.0267711 0.433109 -0.0219774 0 0 0 0.00281905 l
+-0.155451 -0.427624 -0.159027 -0.41948 0 0 0 0.00281905 l
+-0.155451 -0.427624 -0.164083 -0.431341 0 0 0 0.00281905 l
+0.214454 0.839349 0.209144 0.84699 0 0 0 0.00281905 l
+0.214454 0.839349 0.225906 0.843946 0 0 0 0.00281905 l
+0.214454 0.839349 0.204418 0.832115 0 0 0 0.00281905 l
+0.278502 0.137061 0.292639 0.128123 0 0 0 0.00281905 l
+0.278502 0.137061 0.262403 0.138648 0 0 0 0.00281905 l
+-0.0154638 -0.82834 -0.00589439 -0.837937 0 0 0 0.00281905 l
+-0.0154638 -0.82834 -0.0269046 -0.818167 0 0 0 0.00281905 l
+-0.287869 0.229922 -0.286284 0.235084 0 0 0 0.00281905 l
+-0.287869 0.229922 -0.286404 0.211189 0 0 0 0.00281905 l
+-0.287869 0.229922 -0.301908 0.232097 0 0 0 0.00281905 l
+-0.157788 0.217132 -0.154413 0.196856 0 0 0 0.00281905 l
+-0.157788 0.217132 -0.15789 0.236997 0 0 0 0.00281905 l
+-0.157788 0.217132 -0.168953 0.215061 0 0 0 0.00281905 l
+-0.269775 -0.532888 -0.268831 -0.540096 0 0 0 0.00281905 l
+-0.269775 -0.532888 -0.265894 -0.525587 0 0 0 0.00281905 l
+-0.316056 -0.583319 -0.294031 -0.576719 0 0 0 0.00281905 l
+-0.316056 -0.583319 -0.33694 -0.578202 0 0 0 0.00281905 l
+0.71683 -0.451035 0.727589 -0.443636 0 0 0 0.00281905 l
+0.71683 -0.451035 0.724696 -0.459713 0 0 0 0.00281905 l
+0.71683 -0.451035 0.713185 -0.447193 0 0 0 0.00281905 l
+0.405603 0.699613 0.40887 0.699345 0 0 0 0.00281905 l
+0.405603 0.699613 0.400955 0.703883 0 0 0 0.00281905 l
+-0.641192 0.142027 -0.643065 0.137531 0 0 0 0.00281905 l
+-0.0309986 0.638417 -0.0147365 0.630483 0 0 0 0.00281905 l
+-0.0309986 0.638417 -0.0268939 0.646548 0 0 0 0.00281905 l
+0.337422 -0.341587 0.339355 -0.351328 0 0 0 0.00281905 l
+0.337422 -0.341587 0.330017 -0.338959 0 0 0 0.00281905 l
+-0.675417 0.089733 -0.662675 0.0858618 0 0 0 0.00281905 l
+-0.675417 0.089733 -0.681668 0.0819501 0 0 0 0.00281905 l
+-0.214146 -0.78334 -0.216432 -0.775313 0 0 0 0.00281905 l
+-0.214146 -0.78334 -0.20847 -0.782232 0 0 0 0.00281905 l
+-0.214146 -0.78334 -0.212365 -0.787524 0 0 0 0.00281905 l
+-0.103695 0.411657 -0.104874 0.417639 0 0 0 0.00281905 l
+-0.103695 0.411657 -0.113819 0.409876 0 0 0 0.00281905 l
+0.50893 -0.13706 0.507178 -0.132945 0 0 0 0.00281905 l
+0.50893 -0.13706 0.506458 -0.139527 0 0 0 0.00281905 l
+0.549955 0.546996 0.546767 0.565425 0 0 0 0.00281905 l
+0.549955 0.546996 0.551585 0.546655 0 0 0 0.00281905 l
+0.549955 0.546996 0.537052 0.538093 0 0 0 0.00281905 l
+-0.140896 -0.11995 -0.148975 -0.142673 0 0 0 0.00281905 l
+0.0604241 0.792402 0.0728629 0.797144 0 0 0 0.00281905 l
+0.0604241 0.792402 0.059072 0.790593 0 0 0 0.00281905 l
+0.287747 0.653558 0.297288 0.643016 0 0 0 0.00281905 l
+0.287747 0.653558 0.279665 0.658522 0 0 0 0.00281905 l
+0.287747 0.653558 0.289137 0.655615 0 0 0 0.00281905 l
+-0.814852 0.497071 -0.792319 0.501497 0 0 0 0.00281905 l
+-0.814852 0.497071 -0.816017 0.489713 0 0 0 0.00281905 l
+-0.814852 0.497071 -0.830542 0.502784 0 0 0 0.00281905 l
+0.390005 -0.325993 0.39564 -0.328158 0 0 0 0.00281905 l
+0.390005 -0.325993 0.395619 -0.316126 0 0 0 0.00281905 l
+0.390005 -0.325993 0.379426 -0.33293 0 0 0 0.00281905 l
+-0.63514 -0.698314 -0.623555 -0.710551 0 0 0 0.00281905 l
+-0.63514 -0.698314 -0.645758 -0.685735 0 0 0 0.00281905 l
+0.660006 0.0471852 0.674519 0.0421113 0 0 0 0.00281905 l
+0.660006 0.0471852 0.66338 0.0550395 0 0 0 0.00281905 l
+-0.811576 0.257864 -0.818235 0.262678 0 0 0 0.00281905 l
+-0.811576 0.257864 -0.797656 0.263615 0 0 0 0.00281905 l
+-0.811576 0.257864 -0.814799 0.249717 0 0 0 0.00281905 l
+0.412434 -0.168448 0.416306 -0.179198 0 0 0 0.00281905 l
+0.412434 -0.168448 0.406158 -0.161392 0 0 0 0.00281905 l
+-0.820198 -0.0379837 -0.816625 -0.0480042 0 0 0 0.00281905 l
+0.838247 0.236831 0.837642 0.228156 0 0 0 0.00281905 l
+-0.652152 0.508881 -0.652745 0.503677 0 0 0 0.00281905 l
+-0.652152 0.508881 -0.664714 0.525696 0 0 0 0.00281905 l
+-0.0563765 -0.458916 -0.0408031 -0.470899 0 0 0 0.00281905 l
+-0.0563765 -0.458916 -0.0638176 -0.470179 0 0 0 0.00281905 l
+-0.510603 0.299714 -0.515813 0.309736 0 0 0 0.00281905 l
+-0.510603 0.299714 -0.516771 0.291747 0 0 0 0.00281905 l
+0.30998 0.00326442 0.307258 0.00531227 0 0 0 0.00281905 l
+-0.145546 0.615631 -0.145288 0.624826 0 0 0 0.00281905 l
+-0.145546 0.615631 -0.156945 0.61109 0 0 0 0.00281905 l
+-0.429511 0.658783 -0.425917 0.671917 0 0 0 0.00281905 l
+-0.147938 0.158703 -0.143347 0.160469 0 0 0 0.00281905 l
+-0.147938 0.158703 -0.156137 0.148232 0 0 0 0.00281905 l
+-0.916704 0.269573 -0.916211 0.265401 0 0 0 0.00281905 l
+-0.916704 0.269573 -0.907521 0.288084 0 0 0 0.00281905 l
+-0.154765 0.380145 -0.153488 0.393147 0 0 0 0.00281905 l
+-0.154765 0.380145 -0.144105 0.367345 0 0 0 0.00281905 l
+0.548279 -0.308336 0.538235 -0.301711 0 0 0 0.00281905 l
+0.5171 -0.841132 0.50386 -0.839542 0 0 0 0.00281905 l
+0.75613 -0.306594 0.745256 -0.317816 0 0 0 0.00281905 l
+0.75613 -0.306594 0.752969 -0.301095 0 0 0 0.00281905 l
+-0.249537 -0.919289 -0.237655 -0.912798 0 0 0 0.00281905 l
+-0.249537 -0.919289 -0.247887 -0.922799 0 0 0 0.00281905 l
+0.933875 -0.1981 0.936278 -0.197406 0 0 0 0.00281905 l
+0.933875 -0.1981 0.935663 -0.201174 0 0 0 0.00281905 l
+-0.323674 0.711424 -0.323957 0.726314 0 0 0 0.00281905 l
+-0.323674 0.711424 -0.314897 0.705869 0 0 0 0.00281905 l
+-0.323674 0.711424 -0.336972 0.70248 0 0 0 0.00281905 l
+-0.153488 0.393147 -0.154765 0.380145 0 0 0 0.00281905 l
+-0.153488 0.393147 -0.137459 0.397523 0 0 0 0.00281905 l
+-0.153488 0.393147 -0.168937 0.395541 0 0 0 0.00281905 l
+0.372391 -0.826013 0.375214 -0.825718 0 0 0 0.00281905 l
+-0.102103 -0.307197 -0.0912344 -0.320339 0 0 0 0.00281905 l
+-0.102103 -0.307197 -0.108028 -0.296534 0 0 0 0.00281905 l
+-0.102103 -0.307197 -0.0926024 -0.302728 0 0 0 0.00281905 l
+-0.774956 -0.328259 -0.769377 -0.320386 0 0 0 0.00281905 l
+-0.774956 -0.328259 -0.784377 -0.333521 0 0 0 0.00281905 l
+-0.933975 -0.249746 -0.923414 -0.25199 0 0 0 0.00281905 l
+-0.933975 -0.249746 -0.939689 -0.244745 0 0 0 0.00281905 l
+-0.481666 0.777905 -0.486151 0.781248 0 0 0 0.00281905 l
+-0.310403 -0.743714 -0.309985 -0.746704 0 0 0 0.00281905 l
+-0.310403 -0.743714 -0.33289 -0.741811 0 0 0 0.00281905 l
+0.568657 0.445315 0.582928 0.442041 0 0 0 0.00281905 l
+0.568657 0.445315 0.560222 0.433442 0 0 0 0.00281905 l
+0.197806 0.713923 0.207588 0.714479 0 0 0 0.00281905 l
+0.197806 0.713923 0.184813 0.706819 0 0 0 0.00281905 l
+0.861892 0.226938 0.858906 0.244625 0 0 0 0.00281905 l
+0.861892 0.226938 0.854656 0.213617 0 0 0 0.00281905 l
+0.424311 0.432701 0.438586 0.431477 0 0 0 0.00281905 l
+0.424311 0.432701 0.41212 0.438413 0 0 0 0.00281905 l
+-0.751593 -0.436417 -0.75095 -0.438058 0 0 0 0.00281905 l
+0.0526059 0.0210699 0.0530301 0.00491423 0 0 0 0.00281905 l
+0.0526059 0.0210699 0.0448701 0.0370715 0 0 0 0.00281905 l
+0.0526059 0.0210699 0.069611 0.0294489 0 0 0 0.00281905 l
+-0.690606 -0.712632 -0.665407 -0.716963 0 0 0 0.00281905 l
+-0.00427752 -0.447583 0.00516181 -0.462174 0 0 0 0.00281905 l
+-0.00427752 -0.447583 -0.00328876 -0.436844 0 0 0 0.00281905 l
+0.390928 -0.3771 0.393478 -0.364069 0 0 0 0.00281905 l
+0.390928 -0.3771 0.396719 -0.378362 0 0 0 0.00281905 l
+0.390928 -0.3771 0.391998 -0.382187 0 0 0 0.00281905 l
+0.560643 -0.797171 0.560634 -0.807125 0 0 0 0.00281905 l
+0.273323 -0.503917 0.271976 -0.510692 0 0 0 0.00281905 l
+-0.449978 -0.253718 -0.446832 -0.265248 0 0 0 0.00281905 l
+-0.449978 -0.253718 -0.440788 -0.24178 0 0 0 0.00281905 l
+-0.449978 -0.253718 -0.457493 -0.248828 0 0 0 0.00281905 l
+-0.298174 0.21014 -0.302639 0.19958 0 0 0 0.00281905 l
+-0.298174 0.21014 -0.286404 0.211189 0 0 0 0.00281905 l
+0.424491 0.310354 0.425723 0.315389 0 0 0 0.00281905 l
+0.424491 0.310354 0.427854 0.309428 0 0 0 0.00281905 l
+0.424491 0.310354 0.413846 0.306869 0 0 0 0.00281905 l
+0.0923415 0.308757 0.105282 0.309599 0 0 0 0.00281905 l
+0.25494 -0.381484 0.259811 -0.377593 0 0 0 0.00281905 l
+0.25494 -0.381484 0.249746 -0.380614 0 0 0 0.00281905 l
+-0.726036 -0.378856 -0.725072 -0.372498 0 0 0 0.00281905 l
+-0.726036 -0.378856 -0.708738 -0.386085 0 0 0 0.00281905 l
+-0.726036 -0.378856 -0.729835 -0.384569 0 0 0 0.00281905 l
+0.335655 0.210385 0.32594 0.223701 0 0 0 0.00281905 l
+0.288929 -0.336095 0.292673 -0.339847 0 0 0 0.00281905 l
+0.288929 -0.336095 0.280733 -0.335456 0 0 0 0.00281905 l
+0.00131251 -0.716806 0.0114837 -0.727832 0 0 0 0.00281905 l
+0.00131251 -0.716806 -0.00185276 -0.710262 0 0 0 0.00281905 l
+-0.884225 -0.412282 -0.879834 -0.40777 0 0 0 0.00281905 l
+-0.884225 -0.412282 -0.885769 -0.418478 0 0 0 0.00281905 l
+-0.259875 0.449412 -0.2561 0.441504 0 0 0 0.00281905 l
+0.666347 -0.207084 0.6792 -0.220858 0 0 0 0.00281905 l
+0.666347 -0.207084 0.650855 -0.219829 0 0 0 0.00281905 l
+0.872086 0.105794 0.875383 0.0989741 0 0 0 0.00281905 l
+0.872086 0.105794 0.870763 0.108485 0 0 0 0.00281905 l
+-0.10472 0.887291 -0.116534 0.868642 0 0 0 0.00281905 l
+-0.10472 0.887291 -0.0872682 0.891965 0 0 0 0.00281905 l
+-0.590882 0.65319 -0.582155 0.668321 0 0 0 0.00281905 l
+-0.590882 0.65319 -0.608397 0.651242 0 0 0 0.00281905 l
+0.894192 -0.437321 0.890339 -0.42827 0 0 0 0.00281905 l
+-0.613033 0.662475 -0.616138 0.659861 0 0 0 0.00281905 l
+0.534467 -0.238326 0.529409 -0.233409 0 0 0 0.00281905 l
+0.534467 -0.238326 0.534126 -0.238873 0 0 0 0.00281905 l
+-0.213698 0.813302 -0.207788 0.798662 0 0 0 0.00281905 l
+-0.213698 0.813302 -0.205557 0.820863 0 0 0 0.00281905 l
+-0.213698 0.813302 -0.224104 0.805232 0 0 0 0.00281905 l
+-0.525632 0.0763348 -0.530149 0.0859213 0 0 0 0.00281905 l
+-0.525632 0.0763348 -0.526187 0.0727476 0 0 0 0.00281905 l
+0.620859 -0.566757 0.607281 -0.556219 0 0 0 0.00281905 l
+-0.240152 0.147453 -0.242647 0.140572 0 0 0 0.00281905 l
+-0.240152 0.147453 -0.243288 0.151006 0 0 0 0.00281905 l
+-0.93179 0.303601 -0.935223 0.294584 0 0 0 0.00281905 l
+-0.93179 0.303601 -0.935428 0.304699 0 0 0 0.00281905 l
+0.439543 0.156688 0.435976 0.151947 0 0 0 0.00281905 l
+0.439543 0.156688 0.434828 0.160905 0 0 0 0.00281905 l
+-0.865592 0.219871 -0.857591 0.212183 0 0 0 0.00281905 l
+-0.865592 0.219871 -0.871007 0.233637 0 0 0 0.00281905 l
+-0.865592 0.219871 -0.869687 0.216142 0 0 0 0.00281905 l
+0.879374 0.0548496 0.879704 0.0487943 0 0 0 0.00281905 l
+0.879374 0.0548496 0.882629 0.0689667 0 0 0 0.00281905 l
+0.879374 0.0548496 0.86591 0.0603281 0 0 0 0.00281905 l
+0.0938819 0.690609 0.0865911 0.701048 0 0 0 0.00281905 l
+0.904713 -0.11405 0.908405 -0.126191 0 0 0 0.00281905 l
+0.904713 -0.11405 0.897754 -0.0982184 0 0 0 0.00281905 l
+-0.121721 -0.926156 -0.120081 -0.919621 0 0 0 0.00281905 l
+-0.676341 0.367073 -0.66817 0.384922 0 0 0 0.00281905 l
+-0.676341 0.367073 -0.67619 0.342936 0 0 0 0.00281905 l
+-0.676341 0.367073 -0.69775 0.36611 0 0 0 0.00281905 l
+0.42261 0.485865 0.420609 0.494587 0 0 0 0.00281905 l
+0.42261 0.485865 0.432853 0.475575 0 0 0 0.00281905 l
+0.42261 0.485865 0.411369 0.475968 0 0 0 0.00281905 l
+-0.148247 -0.406799 -0.151434 -0.396547 0 0 0 0.00281905 l
+-0.148247 -0.406799 -0.159027 -0.41948 0 0 0 0.00281905 l
+0.710458 0.379504 0.71279 0.39022 0 0 0 0.00281905 l
+0.710458 0.379504 0.714341 0.373613 0 0 0 0.00281905 l
+0.530487 0.703647 0.530515 0.679786 0 0 0 0.00281905 l
+0.530487 0.703647 0.542171 0.714958 0 0 0 0.00281905 l
+0.499593 -0.671025 0.513061 -0.66987 0 0 0 0.00281905 l
+0.499593 -0.671025 0.487131 -0.663094 0 0 0 0.00281905 l
+0.00627197 0.706029 0.00167698 0.690373 0 0 0 0.00281905 l
+0.00627197 0.706029 0.0279319 0.710826 0 0 0 0.00281905 l
+0.237709 0.833634 0.237876 0.827168 0 0 0 0.00281905 l
+0.237709 0.833634 0.235334 0.837054 0 0 0 0.00281905 l
+-0.805424 -0.314174 -0.798305 -0.300821 0 0 0 0.00281905 l
+-0.805424 -0.314174 -0.79226 -0.328192 0 0 0 0.00281905 l
+0.801541 0.0500827 0.799095 0.0488866 0 0 0 0.00281905 l
+0.542171 0.714958 0.539924 0.735844 0 0 0 0.00281905 l
+0.542171 0.714958 0.551717 0.712925 0 0 0 0.00281905 l
+0.542171 0.714958 0.530487 0.703647 0 0 0 0.00281905 l
+0.132509 -0.663352 0.139044 -0.665521 0 0 0 0.00281905 l
+0.162275 0.203506 0.161886 0.194542 0 0 0 0.00281905 l
+0.413854 0.862225 0.423059 0.845086 0 0 0 0.00281905 l
+0.413854 0.862225 0.403211 0.873554 0 0 0 0.00281905 l
+0.094738 0.45669 0.0868659 0.469121 0 0 0 0.00281905 l
+0.094738 0.45669 0.103112 0.447991 0 0 0 0.00281905 l
+0.268362 -0.910512 0.272916 -0.91096 0 0 0 0.00281905 l
+0.268362 -0.910512 0.25967 -0.908048 0 0 0 0.00281905 l
+-0.160779 -0.019322 -0.160551 -0.0239264 0 0 0 0.00281905 l
+-0.160779 -0.019322 -0.153066 -0.00884505 0 0 0 0.00281905 l
+-0.160779 -0.019322 -0.17065 -0.0122453 0 0 0 0.00281905 l
+0.459429 0.277492 0.456049 0.29366 0 0 0 0.00281905 l
+0.459429 0.277492 0.470698 0.266176 0 0 0 0.00281905 l
+0.459429 0.277492 0.440782 0.271251 0 0 0 0.00281905 l
+-0.0725211 -0.408445 -0.0825705 -0.405971 0 0 0 0.00281905 l
+-0.331394 -0.187139 -0.345739 -0.188253 0 0 0 0.00281905 l
+-0.331394 -0.187139 -0.33107 -0.185575 0 0 0 0.00281905 l
+0.0279319 0.710826 0.0345962 0.701747 0 0 0 0.00281905 l
+0.0279319 0.710826 0.025778 0.717487 0 0 0 0.00281905 l
+0.0279319 0.710826 0.00627197 0.706029 0 0 0 0.00281905 l
+-0.642313 -0.195259 -0.640268 -0.184745 0 0 0 0.00281905 l
+-0.642313 -0.195259 -0.640963 -0.207745 0 0 0 0.00281905 l
+0.626666 -0.0435007 0.634094 -0.031309 0 0 0 0.00281905 l
+0.626666 -0.0435007 0.641367 -0.0483088 0 0 0 0.00281905 l
+0.626666 -0.0435007 0.623076 -0.0513411 0 0 0 0.00281905 l
+-0.341747 0.842408 -0.342445 0.830651 0 0 0 0.00281905 l
+-0.341747 0.842408 -0.351435 0.857264 0 0 0 0.00281905 l
+-0.341747 0.842408 -0.326575 0.845414 0 0 0 0.00281905 l
+0.634934 0.726133 0.642187 0.736083 0 0 0 0.00281905 l
+0.634934 0.726133 0.625529 0.716586 0 0 0 0.00281905 l
+-0.0042643 -0.889499 0.00425097 -0.900307 0 0 0 0.00281905 l
+-0.0042643 -0.889499 -0.0124874 -0.893705 0 0 0 0.00281905 l
+0.249746 -0.380614 0.25494 -0.381484 0 0 0 0.00281905 l
+0.249746 -0.380614 0.241869 -0.387625 0 0 0 0.00281905 l
+0.249746 -0.380614 0.245764 -0.376485 0 0 0 0.00281905 l
+-0.481536 -0.657829 -0.473766 -0.661053 0 0 0 0.00281905 l
+-0.481536 -0.657829 -0.48665 -0.650737 0 0 0 0.00281905 l
+-0.481536 -0.657829 -0.487453 -0.661976 0 0 0 0.00281905 l
+0.901681 0.196523 0.908273 0.211592 0 0 0 0.00281905 l
+0.901681 0.196523 0.88865 0.195106 0 0 0 0.00281905 l
+0.959309 0.144072 0.947818 0.125689 0 0 0 0.00281905 l
+0.959309 0.144072 0.958362 0.146693 0 0 0 0.00281905 l
+0.684993 0.512614 0.684986 0.518294 0 0 0 0.00281905 l
+0.684993 0.512614 0.677327 0.515092 0 0 0 0.00281905 l
+-0.942476 0.0641372 -0.939513 0.0720851 0 0 0 0.00281905 l
+-0.942476 0.0641372 -0.952389 0.0570659 0 0 0 0.00281905 l
+0.0106326 0.798224 0.0132179 0.78833 0 0 0 0.00281905 l
+0.0106326 0.798224 0.0113259 0.801402 0 0 0 0.00281905 l
+0.297746 -0.789076 0.302097 -0.790754 0 0 0 0.00281905 l
+0.401577 -0.603261 0.412018 -0.61421 0 0 0 0.00281905 l
+0.401577 -0.603261 0.396847 -0.582953 0 0 0 0.00281905 l
+0.0860512 0.632615 0.0878462 0.644527 0 0 0 0.00281905 l
+0.0860512 0.632615 0.0982021 0.622165 0 0 0 0.00281905 l
+0.0860512 0.632615 0.0779409 0.627487 0 0 0 0.00281905 l
+0.335631 0.301311 0.33906 0.307393 0 0 0 0.00281905 l
+0.335631 0.301311 0.334064 0.297101 0 0 0 0.00281905 l
+0.184615 -0.95468 0.186992 -0.966804 0 0 0 0.00281905 l
+0.184615 -0.95468 0.19453 -0.945007 0 0 0 0.00281905 l
+-0.401211 -0.525683 -0.408887 -0.535474 0 0 0 0.00281905 l
+-0.401211 -0.525683 -0.401168 -0.524437 0 0 0 0.00281905 l
+-0.401211 -0.525683 -0.388473 -0.530037 0 0 0 0.00281905 l
+-0.254695 0.0358275 -0.254928 0.0524395 0 0 0 0.00281905 l
+-0.254695 0.0358275 -0.265421 0.0276249 0 0 0 0.00281905 l
+0.135028 -0.913721 0.148441 -0.918568 0 0 0 0.00281905 l
+0.135028 -0.913721 0.117279 -0.920341 0 0 0 0.00281905 l
+0.0979584 -0.157264 0.11191 -0.153831 0 0 0 0.00281905 l
+0.0979584 -0.157264 0.0891225 -0.156749 0 0 0 0.00281905 l
+-0.932611 -0.0225353 -0.930636 -0.00909486 0 0 0 0.00281905 l
+-0.932611 -0.0225353 -0.918777 -0.0196165 0 0 0 0.00281905 l
+-0.932611 -0.0225353 -0.934091 -0.0236802 0 0 0 0.00281905 l
+0.179863 0.91385 0.181798 0.892738 0 0 0 0.00281905 l
+0.179863 0.91385 0.174381 0.912756 0 0 0 0.00281905 l
+0.825855 -0.0338598 0.829159 -0.0187002 0 0 0 0.00281905 l
+0.825855 -0.0338598 0.807097 -0.0293921 0 0 0 0.00281905 l
+-0.437791 0.753493 -0.444692 0.772597 0 0 0 0.00281905 l
+-0.437791 0.753493 -0.430592 0.749362 0 0 0 0.00281905 l
+-0.35061 0.273894 -0.347436 0.284804 0 0 0 0.00281905 l
+-0.35061 0.273894 -0.349473 0.270782 0 0 0 0.00281905 l
+0.14625 0.283896 0.157477 0.277165 0 0 0 0.00281905 l
+0.14625 0.283896 0.135032 0.279408 0 0 0 0.00281905 l
+0.727589 -0.443636 0.71683 -0.451035 0 0 0 0.00281905 l
+-0.210289 0.332863 -0.197276 0.336981 0 0 0 0.00281905 l
+-0.210289 0.332863 -0.219016 0.322865 0 0 0 0.00281905 l
+0.235334 0.837054 0.237709 0.833634 0 0 0 0.00281905 l
+0.235334 0.837054 0.225906 0.843946 0 0 0 0.00281905 l
+0.0478441 -0.940275 0.0544324 -0.941333 0 0 0 0.00281905 l
+0.0478441 -0.940275 0.0397164 -0.93324 0 0 0 0.00281905 l
+0.584545 -0.590198 0.587729 -0.58494 0 0 0 0.00281905 l
+0.584545 -0.590198 0.57094 -0.597447 0 0 0 0.00281905 l
+-0.846658 0.331692 -0.834587 0.348122 0 0 0 0.00281905 l
+-0.846658 0.331692 -0.838816 0.327991 0 0 0 0.00281905 l
+-0.846658 0.331692 -0.854573 0.327657 0 0 0 0.00281905 l
+-0.122443 -0.616117 -0.114881 -0.600446 0 0 0 0.00281905 l
+-0.122443 -0.616117 -0.132163 -0.610069 0 0 0 0.00281905 l
+-0.122443 -0.616117 -0.125068 -0.619755 0 0 0 0.00281905 l
+-0.2266 -0.351837 -0.216387 -0.344215 0 0 0 0.00281905 l
+-0.2266 -0.351837 -0.239349 -0.350002 0 0 0 0.00281905 l
+-0.102238 0.716016 -0.10658 0.727076 0 0 0 0.00281905 l
+-0.102238 0.716016 -0.108183 0.708251 0 0 0 0.00281905 l
+-0.0856975 -0.276819 -0.0985346 -0.288372 0 0 0 0.00281905 l
+-0.0856975 -0.276819 -0.076085 -0.276345 0 0 0 0.00281905 l
+-0.0856975 -0.276819 -0.0895533 -0.268737 0 0 0 0.00281905 l
+-0.455109 -0.440081 -0.459833 -0.445835 0 0 0 0.00281905 l
+-0.598868 -0.205143 -0.59008 -0.203235 0 0 0 0.00281905 l
+-0.598868 -0.205143 -0.60919 -0.20581 0 0 0 0.00281905 l
+-0.911963 0.0127607 -0.899626 0.0235354 0 0 0 0.00281905 l
+-0.911963 0.0127607 -0.911816 0.00590096 0 0 0 0.00281905 l
+-0.911963 0.0127607 -0.919618 0.0185415 0 0 0 0.00281905 l
+-0.923414 -0.25199 -0.924426 -0.264798 0 0 0 0.00281905 l
+-0.923414 -0.25199 -0.907259 -0.248572 0 0 0 0.00281905 l
+-0.923414 -0.25199 -0.933975 -0.249746 0 0 0 0.00281905 l
+-0.256081 0.357732 -0.256929 0.372516 0 0 0 0.00281905 l
+-0.256081 0.357732 -0.256666 0.351629 0 0 0 0.00281905 l
+0.0349781 0.517791 0.038272 0.512227 0 0 0 0.00281905 l
+0.0349781 0.517791 0.0319384 0.515609 0 0 0 0.00281905 l
+0.809348 -0.423396 0.814358 -0.425224 0 0 0 0.00281905 l
+0.809348 -0.423396 0.802764 -0.438565 0 0 0 0.00281905 l
+0.809348 -0.423396 0.803908 -0.421936 0 0 0 0.00281905 l
+0.0317882 0.450422 0.0445242 0.452478 0 0 0 0.00281905 l
+0.0317882 0.450422 0.024056 0.45116 0 0 0 0.00281905 l
+-0.13404 -0.271463 -0.126286 -0.269057 0 0 0 0.00281905 l
+-0.13404 -0.271463 -0.138292 -0.269213 0 0 0 0.00281905 l
+0.203336 0.811808 0.209803 0.808755 0 0 0 0.00281905 l
+0.203336 0.811808 0.193553 0.816553 0 0 0 0.00281905 l
+0.388484 0.841124 0.387205 0.85976 0 0 0 0.00281905 l
+0.388484 0.841124 0.387689 0.837541 0 0 0 0.00281905 l
+0.0823872 0.420038 0.083954 0.437223 0 0 0 0.00281905 l
+0.0823872 0.420038 0.0872514 0.418275 0 0 0 0.00281905 l
+-0.562835 0.0353538 -0.55411 0.0444683 0 0 0 0.00281905 l
+-0.562835 0.0353538 -0.552972 0.0312639 0 0 0 0.00281905 l
+-0.562835 0.0353538 -0.584095 0.0362237 0 0 0 0.00281905 l
+0.894738 -0.0406066 0.899988 -0.0551984 0 0 0 0.00281905 l
+0.894738 -0.0406066 0.879916 -0.0335789 0 0 0 0.00281905 l
+0.656122 -0.49276 0.656052 -0.484536 0 0 0 0.00281905 l
+0.260383 -0.248829 0.268951 -0.239451 0 0 0 0.00281905 l
+0.260383 -0.248829 0.257781 -0.250963 0 0 0 0.00281905 l
+-0.550855 0.423235 -0.541793 0.416075 0 0 0 0.00281905 l
+-0.550855 0.423235 -0.555642 0.432886 0 0 0 0.00281905 l
+0.615484 0.182329 0.609722 0.166727 0 0 0 0.00281905 l
+0.615484 0.182329 0.616196 0.19513 0 0 0 0.00281905 l
+-0.680974 -0.0567207 -0.685036 -0.0731641 0 0 0 0.00281905 l
+-0.680974 -0.0567207 -0.677442 -0.0428734 0 0 0 0.00281905 l
+0.157482 0.738069 0.137983 0.756011 0 0 0 0.00281905 l
+0.157482 0.738069 0.158898 0.735325 0 0 0 0.00281905 l
+-0.862578 -0.417462 -0.859556 -0.413875 0 0 0 0.00281905 l
+-0.862578 -0.417462 -0.855926 -0.42098 0 0 0 0.00281905 l
+0.329383 -0.0691895 0.332165 -0.0525579 0 0 0 0.00281905 l
+0.329383 -0.0691895 0.335355 -0.0717461 0 0 0 0.00281905 l
+0.329383 -0.0691895 0.319802 -0.0770073 0 0 0 0.00281905 l
+0.379537 0.50121 0.388542 0.496189 0 0 0 0.00281905 l
+0.379537 0.50121 0.368633 0.505972 0 0 0 0.00281905 l
+-0.513686 0.59774 -0.510155 0.605464 0 0 0 0.00281905 l
+-0.513686 0.59774 -0.514045 0.58385 0 0 0 0.00281905 l
+-0.513686 0.59774 -0.517104 0.59941 0 0 0 0.00281905 l
+-0.411791 -0.522669 -0.413378 -0.517312 0 0 0 0.00281905 l
+-0.411791 -0.522669 -0.401168 -0.524437 0 0 0 0.00281905 l
+-0.154582 0.887362 -0.160454 0.881369 0 0 0 0.00281905 l
+-0.154582 0.887362 -0.140702 0.892217 0 0 0 0.00281905 l
+-0.154582 0.887362 -0.159868 0.891499 0 0 0 0.00281905 l
+0.636227 -0.184951 0.649814 -0.178015 0 0 0 0.00281905 l
+0.636227 -0.184951 0.629626 -0.186071 0 0 0 0.00281905 l
+0.747824 0.0865688 0.747487 0.0868053 0 0 0 0.00281905 l
+-0.183324 -0.878002 -0.174424 -0.882171 0 0 0 0.00281905 l
+-0.183324 -0.878002 -0.20154 -0.868496 0 0 0 0.00281905 l
+0.362778 -0.143711 0.360117 -0.143042 0 0 0 0.00281905 l
+-0.975742 0.123695 -0.975134 0.108805 0 0 0 0.00281905 l
+-0.481691 0.680988 -0.484009 0.696163 0 0 0 0.00281905 l
+-0.481691 0.680988 -0.480281 0.674573 0 0 0 0.00281905 l
+0.159673 -0.360021 0.14889 -0.354705 0 0 0 0.00281905 l
+0.780243 -0.277186 0.769019 -0.292896 0 0 0 0.00281905 l
+0.780243 -0.277186 0.785 -0.261975 0 0 0 0.00281905 l
+0.478416 -0.492517 0.489197 -0.485058 0 0 0 0.00281905 l
+0.478416 -0.492517 0.484096 -0.498597 0 0 0 0.00281905 l
+0.478416 -0.492517 0.468978 -0.485117 0 0 0 0.00281905 l
+-0.0426622 -0.131553 -0.0598151 -0.133768 0 0 0 0.00281905 l
+0.450188 -0.314985 0.449576 -0.30718 0 0 0 0.00281905 l
+0.450188 -0.314985 0.463381 -0.317907 0 0 0 0.00281905 l
+0.450188 -0.314985 0.449858 -0.318563 0 0 0 0.00281905 l
+0.860934 0.435851 0.880405 0.428363 0 0 0 0.00281905 l
+0.578823 -0.000852624 0.566852 0.012537 0 0 0 0.00281905 l
+0.578823 -0.000852624 0.577884 -0.00951244 0 0 0 0.00281905 l
+0.505134 0.468774 0.514997 0.475471 0 0 0 0.00281905 l
+0.505134 0.468774 0.500749 0.470675 0 0 0 0.00281905 l
+-0.114468 0.402155 -0.113819 0.409876 0 0 0 0.00281905 l
+-0.72461 0.465363 -0.730473 0.453691 0 0 0 0.00281905 l
+-0.0397814 -0.978229 -0.0343855 -0.96771 0 0 0 0.00281905 l
+-0.0397814 -0.978229 -0.0330348 -0.986124 0 0 0 0.00281905 l
+0.260539 0.839922 0.267705 0.828594 0 0 0 0.00281905 l
+0.260539 0.839922 0.266673 0.847575 0 0 0 0.00281905 l
+0.338865 0.346673 0.348834 0.34252 0 0 0 0.00281905 l
+0.338865 0.346673 0.327238 0.332559 0 0 0 0.00281905 l
+0.422844 -0.286039 0.423263 -0.290453 0 0 0 0.00281905 l
+-0.0829132 0.657181 -0.0741716 0.671743 0 0 0 0.00281905 l
+-0.0829132 0.657181 -0.0968438 0.659498 0 0 0 0.00281905 l
+-0.40367 -0.110635 -0.390433 -0.118897 0 0 0 0.00281905 l
+-0.40367 -0.110635 -0.406908 -0.100988 0 0 0 0.00281905 l
+0.799161 -0.262697 0.807157 -0.254347 0 0 0 0.00281905 l
+0.799161 -0.262697 0.785 -0.261975 0 0 0 0.00281905 l
+0.48529 0.795926 0.481343 0.816252 0 0 0 0.00281905 l
+0.48529 0.795926 0.498603 0.784029 0 0 0 0.00281905 l
+0.583369 0.371326 0.594688 0.364191 0 0 0 0.00281905 l
+0.583369 0.371326 0.577711 0.378431 0 0 0 0.00281905 l
+-0.808958 0.220942 -0.803055 0.24477 0 0 0 0.00281905 l
+-0.808958 0.220942 -0.813272 0.210077 0 0 0 0.00281905 l
+0.0843934 -0.818033 0.0831824 -0.824587 0 0 0 0.00281905 l
+0.0843934 -0.818033 0.0822286 -0.806432 0 0 0 0.00281905 l
+0.0843934 -0.818033 0.0929661 -0.816806 0 0 0 0.00281905 l
+0.148044 -0.633498 0.141777 -0.653059 0 0 0 0.00281905 l
+0.148044 -0.633498 0.14729 -0.617873 0 0 0 0.00281905 l
+-0.878127 0.292665 -0.87751 0.276645 0 0 0 0.00281905 l
+-0.878127 0.292665 -0.867436 0.292915 0 0 0 0.00281905 l
+-0.878127 0.292665 -0.881631 0.303183 0 0 0 0.00281905 l
+-0.324124 -0.39336 -0.323343 -0.380418 0 0 0 0.00281905 l
+-0.324124 -0.39336 -0.332053 -0.395948 0 0 0 0.00281905 l
+-0.873724 0.39683 -0.872738 0.405459 0 0 0 0.00281905 l
+-0.873724 0.39683 -0.862234 0.396472 0 0 0 0.00281905 l
+-0.321003 0.46477 -0.314232 0.459774 0 0 0 0.00281905 l
+-0.035769 -0.78507 -0.0350571 -0.807325 0 0 0 0.00281905 l
+0.724993 -0.420938 0.715525 -0.409416 0 0 0 0.00281905 l
+0.850786 -0.318306 0.850886 -0.320343 0 0 0 0.00281905 l
+0.475469 -0.132497 0.480446 -0.120821 0 0 0 0.00281905 l
+0.475469 -0.132497 0.460559 -0.13698 0 0 0 0.00281905 l
+0.807097 -0.0293921 0.805744 -0.0258535 0 0 0 0.00281905 l
+0.807097 -0.0293921 0.825855 -0.0338598 0 0 0 0.00281905 l
+0.312048 -0.729895 0.299674 -0.728258 0 0 0 0.00281905 l
+-0.217782 0.690022 -0.209956 0.683666 0 0 0 0.00281905 l
+-0.217782 0.690022 -0.235365 0.682143 0 0 0 0.00281905 l
+-0.140269 -0.8851 -0.143542 -0.871417 0 0 0 0.00281905 l
+-0.140269 -0.8851 -0.126333 -0.894108 0 0 0 0.00281905 l
+0.0715648 -0.773352 0.0721154 -0.766253 0 0 0 0.00281905 l
+0.0715648 -0.773352 0.0683795 -0.780394 0 0 0 0.00281905 l
+0.205685 0.673082 0.218929 0.678131 0 0 0 0.00281905 l
+0.205685 0.673082 0.200663 0.675451 0 0 0 0.00281905 l
+0.696773 -0.00134317 0.699856 -0.00523386 0 0 0 0.00281905 l
+0.696773 -0.00134317 0.71174 0.0107665 0 0 0 0.00281905 l
+-0.291071 -0.453024 -0.28202 -0.462811 0 0 0 0.00281905 l
+-0.291071 -0.453024 -0.282715 -0.444933 0 0 0 0.00281905 l
+-0.291071 -0.453024 -0.30425 -0.442405 0 0 0 0.00281905 l
+-0.407034 -0.266 -0.409105 -0.262447 0 0 0 0.00281905 l
+0.139308 -0.0362019 0.138132 -0.0428178 0 0 0 0.00281905 l
+0.139308 -0.0362019 0.145128 -0.0334862 0 0 0 0.00281905 l
+-0.618712 0.336219 -0.613174 0.32571 0 0 0 0.00281905 l
+-0.618712 0.336219 -0.621874 0.340038 0 0 0 0.00281905 l
+-0.734669 0.593889 -0.736173 0.602223 0 0 0 0.00281905 l
+-0.734669 0.593889 -0.753497 0.588773 0 0 0 0.00281905 l
+-0.732572 -0.548888 -0.729942 -0.567026 0 0 0 0.00281905 l
+-0.732572 -0.548888 -0.730667 -0.547146 0 0 0 0.00281905 l
+-0.163204 0.26456 -0.161064 0.260104 0 0 0 0.00281905 l
+-0.163204 0.26456 -0.175264 0.262946 0 0 0 0.00281905 l
+0.211181 -0.0737283 0.216764 -0.0842968 0 0 0 0.00281905 l
+0.211181 -0.0737283 0.20339 -0.0657824 0 0 0 0.00281905 l
+0.840575 0.33986 0.84222 0.361448 0 0 0 0.00281905 l
+0.840575 0.33986 0.825328 0.334405 0 0 0 0.00281905 l
+0.140122 0.155097 0.13531 0.167385 0 0 0 0.00281905 l
+0.140122 0.155097 0.152219 0.149709 0 0 0 0.00281905 l
+-0.545165 0.412053 -0.543145 0.397263 0 0 0 0.00281905 l
+-0.545165 0.412053 -0.541793 0.416075 0 0 0 0.00281905 l
+0.0604677 0.516892 0.064028 0.50754 0 0 0 0.00281905 l
+0.0604677 0.516892 0.0604304 0.518232 0 0 0 0.00281905 l
+0.0604677 0.516892 0.0529211 0.512235 0 0 0 0.00281905 l
+-0.168417 0.250935 -0.15789 0.236997 0 0 0 0.00281905 l
+-0.168417 0.250935 -0.161064 0.260104 0 0 0 0.00281905 l
+-0.168417 0.250935 -0.177255 0.247748 0 0 0 0.00281905 l
+0.741401 -0.484237 0.737428 -0.502341 0 0 0 0.00281905 l
+0.741401 -0.484237 0.734915 -0.477128 0 0 0 0.00281905 l
+-0.27116 -0.203529 -0.267029 -0.190615 0 0 0 0.00281905 l
+-0.658754 -0.11134 -0.667667 -0.103029 0 0 0 0.00281905 l
+-0.658754 -0.11134 -0.64946 -0.124069 0 0 0 0.00281905 l
+0.56037 -0.405123 0.5595 -0.395497 0 0 0 0.00281905 l
+0.56037 -0.405123 0.560505 -0.405696 0 0 0 0.00281905 l
+0.611699 -0.0631246 0.613329 -0.0671899 0 0 0 0.00281905 l
+0.957023 0.085221 0.974544 0.0834857 0 0 0 0.00281905 l
+0.957023 0.085221 0.951404 0.0753673 0 0 0 0.00281905 l
+0.228604 0.958146 0.223491 0.955471 0 0 0 0.00281905 l
+0.755031 0.642621 0.759747 0.640892 0 0 0 0.00281905 l
+0.755031 0.642621 0.747157 0.646867 0 0 0 0.00281905 l
+-0.463411 0.755185 -0.464725 0.754014 0 0 0 0.00281905 l
+0.672813 0.286904 0.672315 0.283038 0 0 0 0.00281905 l
+0.672813 0.286904 0.690502 0.294355 0 0 0 0.00281905 l
+0.672813 0.286904 0.665178 0.296022 0 0 0 0.00281905 l
+0.285435 -0.523733 0.288273 -0.515839 0 0 0 0.00281905 l
+0.285435 -0.523733 0.293725 -0.529172 0 0 0 0.00281905 l
+0.285435 -0.523733 0.276765 -0.525652 0 0 0 0.00281905 l
+0.365324 0.483602 0.365112 0.48062 0 0 0 0.00281905 l
+-0.118857 -0.330398 -0.10444 -0.329942 0 0 0 0.00281905 l
+-0.118857 -0.330398 -0.120663 -0.342988 0 0 0 0.00281905 l
+0.988307 -0.120358 0.977248 -0.138146 0 0 0 0.00281905 l
+0.988307 -0.120358 0.991026 -0.119659 0 0 0 0.00281905 l
+0.988307 -0.120358 0.986419 -0.118484 0 0 0 0.00281905 l
+0.864022 -0.301261 0.864427 -0.293363 0 0 0 0.00281905 l
+0.864022 -0.301261 0.859862 -0.300573 0 0 0 0.00281905 l
+-0.193718 -0.0314281 -0.192509 -0.0216451 0 0 0 0.00281905 l
+-0.193718 -0.0314281 -0.195629 -0.0436842 0 0 0 0.00281905 l
+-0.16459 0.910971 -0.159868 0.891499 0 0 0 0.00281905 l
+-0.16459 0.910971 -0.149146 0.910903 0 0 0 0.00281905 l
+-0.879857 -0.285722 -0.886435 -0.270097 0 0 0 0.00281905 l
+-0.879857 -0.285722 -0.866708 -0.286972 0 0 0 0.00281905 l
+-0.879857 -0.285722 -0.884183 -0.290607 0 0 0 0.00281905 l
+-0.517117 -0.336142 -0.51001 -0.344541 0 0 0 0.00281905 l
+-0.517117 -0.336142 -0.524486 -0.348605 0 0 0 0.00281905 l
+0.652912 -0.190286 0.6559 -0.184946 0 0 0 0.00281905 l
+-0.0139928 0.269383 -0.0100627 0.285587 0 0 0 0.00281905 l
+-0.0139928 0.269383 -0.0311799 0.268493 0 0 0 0.00281905 l
+-0.0897377 0.477298 -0.0848001 0.488813 0 0 0 0.00281905 l
+-0.0897377 0.477298 -0.089762 0.474465 0 0 0 0.00281905 l
+-0.0897377 0.477298 -0.102301 0.482668 0 0 0 0.00281905 l
+-0.429868 0.361135 -0.440082 0.379458 0 0 0 0.00281905 l
+-0.429868 0.361135 -0.42033 0.364014 0 0 0 0.00281905 l
+0.253373 -0.30039 0.260778 -0.308209 0 0 0 0.00281905 l
+0.253373 -0.30039 0.251968 -0.300188 0 0 0 0.00281905 l
+0.253373 -0.30039 0.257428 -0.296695 0 0 0 0.00281905 l
+-0.759123 -0.017064 -0.750297 -0.0192961 0 0 0 0.00281905 l
+0.203068 -0.740159 0.19883 -0.7587 0 0 0 0.00281905 l
+0.410202 -0.8095 0.413123 -0.793556 0 0 0 0.00281905 l
+0.410202 -0.8095 0.41144 -0.812832 0 0 0 0.00281905 l
+0.0274755 0.806385 0.037721 0.818623 0 0 0 0.00281905 l
+0.0274755 0.806385 0.0113259 0.801402 0 0 0 0.00281905 l
+0.602944 0.168561 0.609722 0.166727 0 0 0 0.00281905 l
+0.602944 0.168561 0.600608 0.168744 0 0 0 0.00281905 l
+0.800196 0.185397 0.80382 0.184186 0 0 0 0.00281905 l
+0.800196 0.185397 0.797723 0.182441 0 0 0 0.00281905 l
+-0.282547 -0.690462 -0.281536 -0.693696 0 0 0 0.00281905 l
+-0.956778 0.160253 -0.949953 0.167987 0 0 0 0.00281905 l
+-0.956778 0.160253 -0.961788 0.16872 0 0 0 0.00281905 l
+-0.956778 0.160253 -0.967208 0.152214 0 0 0 0.00281905 l
+0.74845 -0.0198284 0.752873 -0.0158843 0 0 0 0.00281905 l
+0.74845 -0.0198284 0.732669 -0.0278845 0 0 0 0.00281905 l
+-0.753497 0.588773 -0.734669 0.593889 0 0 0 0.00281905 l
+-0.753497 0.588773 -0.755903 0.601222 0 0 0 0.00281905 l
+0.0969116 0.115949 0.0993346 0.115471 0 0 0 0.00281905 l
+0.382477 0.679764 0.38101 0.670285 0 0 0 0.00281905 l
+0.481215 -0.0689392 0.485347 -0.0579699 0 0 0 0.00281905 l
+0.481215 -0.0689392 0.475326 -0.0775939 0 0 0 0.00281905 l
+-0.432204 -0.395143 -0.427536 -0.392938 0 0 0 0.00281905 l
+-0.432204 -0.395143 -0.444528 -0.408589 0 0 0 0.00281905 l
+0.671448 -0.0334163 0.682803 -0.028462 0 0 0 0.00281905 l
+0.671448 -0.0334163 0.660929 -0.0380969 0 0 0 0.00281905 l
+-0.76153 -0.114924 -0.750203 -0.104803 0 0 0 0.00281905 l
+-0.76153 -0.114924 -0.764542 -0.116205 0 0 0 0.00281905 l
+0.0845045 0.775598 0.0872768 0.776322 0 0 0 0.00281905 l
+0.0845045 0.775598 0.07953 0.777347 0 0 0 0.00281905 l
+-0.0371457 -0.762064 -0.0421546 -0.740398 0 0 0 0.00281905 l
+-0.0371457 -0.762064 -0.0528354 -0.765145 0 0 0 0.00281905 l
+0.657794 -0.433041 0.66384 -0.415708 0 0 0 0.00281905 l
+0.657794 -0.433041 0.654945 -0.435469 0 0 0 0.00281905 l
+0.749658 -0.598866 0.740426 -0.621538 0 0 0 0.00281905 l
+0.749658 -0.598866 0.760352 -0.599902 0 0 0 0.00281905 l
+0.749658 -0.598866 0.737446 -0.595536 0 0 0 0.00281905 l
+0.306559 -0.504239 0.309459 -0.495425 0 0 0 0.00281905 l
+0.306559 -0.504239 0.308159 -0.51207 0 0 0 0.00281905 l
+0.306559 -0.504239 0.293338 -0.504579 0 0 0 0.00281905 l
+-0.34786 -0.2869 -0.335551 -0.289702 0 0 0 0.00281905 l
+-0.414007 0.678662 -0.410159 0.688191 0 0 0 0.00281905 l
+-0.414007 0.678662 -0.414044 0.66508 0 0 0 0.00281905 l
+-0.414007 0.678662 -0.425917 0.671917 0 0 0 0.00281905 l
+0.146315 -0.585289 0.147938 -0.605466 0 0 0 0.00281905 l
+-0.101609 -0.399938 -0.0825705 -0.405971 0 0 0 0.00281905 l
+-0.101609 -0.399938 -0.105436 -0.407656 0 0 0 0.00281905 l
+-0.101609 -0.399938 -0.108488 -0.394721 0 0 0 0.00281905 l
+0.392899 0.428666 0.39105 0.420393 0 0 0 0.00281905 l
+0.392899 0.428666 0.397097 0.430242 0 0 0 0.00281905 l
+0.392899 0.428666 0.386292 0.431838 0 0 0 0.00281905 l
+-0.853626 0.0627171 -0.857469 0.0582739 0 0 0 0.00281905 l
+0.0320164 0.587367 0.0343723 0.578406 0 0 0 0.00281905 l
+0.0320164 0.587367 0.0300137 0.593982 0 0 0 0.00281905 l
+-0.883921 -0.213445 -0.880928 -0.214931 0 0 0 0.00281905 l
+-0.883921 -0.213445 -0.889702 -0.219306 0 0 0 0.00281905 l
+-0.883921 -0.213445 -0.889873 -0.20859 0 0 0 0.00281905 l
+0.0932169 -0.368894 0.102806 -0.354355 0 0 0 0.00281905 l
+0.0932169 -0.368894 0.0984581 -0.38304 0 0 0 0.00281905 l
+0.0932169 -0.368894 0.0806951 -0.366446 0 0 0 0.00281905 l
+-0.13438 -0.40042 -0.132243 -0.395909 0 0 0 0.00281905 l
+-0.13438 -0.40042 -0.133801 -0.401873 0 0 0 0.00281905 l
+-0.419935 0.456869 -0.411649 0.46193 0 0 0 0.00281905 l
+-0.419935 0.456869 -0.426112 0.459472 0 0 0 0.00281905 l
+-0.739144 0.403283 -0.762815 0.399585 0 0 0 0.00281905 l
+-0.244465 -0.374376 -0.240901 -0.385646 0 0 0 0.00281905 l
+-0.244465 -0.374376 -0.253011 -0.381429 0 0 0 0.00281905 l
+0.71164 -0.198825 0.711148 -0.192842 0 0 0 0.00281905 l
+0.71164 -0.198825 0.720841 -0.206468 0 0 0 0.00281905 l
+0.71164 -0.198825 0.701034 -0.1978 0 0 0 0.00281905 l
+0.132668 -0.406724 0.134575 -0.396414 0 0 0 0.00281905 l
+0.132668 -0.406724 0.145092 -0.40749 0 0 0 0.00281905 l
+0.132668 -0.406724 0.124012 -0.424301 0 0 0 0.00281905 l
+0.399399 -0.194367 0.398249 -0.187374 0 0 0 0.00281905 l
+0.443774 0.260506 0.447165 0.249694 0 0 0 0.00281905 l
+0.443774 0.260506 0.440782 0.271251 0 0 0 0.00281905 l
+0.771035 0.0765737 0.780967 0.0702956 0 0 0 0.00281905 l
+0.771035 0.0765737 0.764849 0.076174 0 0 0 0.00281905 l
+-0.593727 -0.48901 -0.595028 -0.481125 0 0 0 0.00281905 l
+0.801899 -0.0759943 0.798795 -0.0878288 0 0 0 0.00281905 l
+0.801899 -0.0759943 0.810892 -0.0688945 0 0 0 0.00281905 l
+0.801899 -0.0759943 0.79204 -0.074379 0 0 0 0.00281905 l
+-0.773749 0.466639 -0.783088 0.451357 0 0 0 0.00281905 l
+-0.773749 0.466639 -0.768565 0.464627 0 0 0 0.00281905 l
+-0.445308 0.099341 -0.447707 0.0927907 0 0 0 0.00281905 l
+-0.445308 0.099341 -0.450982 0.106655 0 0 0 0.00281905 l
+0.528689 -0.0291657 0.530044 -0.0379473 0 0 0 0.00281905 l
+0.528689 -0.0291657 0.540777 -0.0241911 0 0 0 0.00281905 l
+-0.823377 0.0446953 -0.822655 0.0375448 0 0 0 0.00281905 l
+-0.823377 0.0446953 -0.836592 0.0513411 0 0 0 0.00281905 l
+0.654945 -0.435469 0.644107 -0.419988 0 0 0 0.00281905 l
+0.654945 -0.435469 0.657794 -0.433041 0 0 0 0.00281905 l
+0.283233 0.162454 0.290084 0.166936 0 0 0 0.00281905 l
+0.283233 0.162454 0.274284 0.169888 0 0 0 0.00281905 l
+0.327576 -0.720089 0.328769 -0.725765 0 0 0 0.00281905 l
+0.327576 -0.720089 0.328003 -0.704211 0 0 0 0.00281905 l
+0.327576 -0.720089 0.342135 -0.715778 0 0 0 0.00281905 l
+-0.886435 -0.270097 -0.879857 -0.285722 0 0 0 0.00281905 l
+-0.886435 -0.270097 -0.90215 -0.265555 0 0 0 0.00281905 l
+0.447412 0.0397224 0.449501 0.0224063 0 0 0 0.00281905 l
+-0.237986 0.707789 -0.241742 0.700025 0 0 0 0.00281905 l
+-0.68901 0.504591 -0.693321 0.522506 0 0 0 0.00281905 l
+-0.68901 0.504591 -0.699508 0.497745 0 0 0 0.00281905 l
+-0.359128 0.735703 -0.361898 0.719564 0 0 0 0.00281905 l
+-0.359128 0.735703 -0.349499 0.749498 0 0 0 0.00281905 l
+-0.359128 0.735703 -0.370791 0.734116 0 0 0 0.00281905 l
+0.282609 0.558838 0.288716 0.55399 0 0 0 0.00281905 l
+0.282609 0.558838 0.288098 0.562986 0 0 0 0.00281905 l
+0.282609 0.558838 0.276287 0.566636 0 0 0 0.00281905 l
+-0.420386 0.412927 -0.401258 0.411192 0 0 0 0.00281905 l
+-0.420386 0.412927 -0.429034 0.416299 0 0 0 0.00281905 l
+0.0609691 0.244968 0.0662828 0.241346 0 0 0 0.00281905 l
+0.0609691 0.244968 0.0511689 0.227821 0 0 0 0.00281905 l
+-0.267285 0.709923 -0.261166 0.721451 0 0 0 0.00281905 l
+-0.267285 0.709923 -0.252554 0.693479 0 0 0 0.00281905 l
+-0.267285 0.709923 -0.274973 0.710267 0 0 0 0.00281905 l
+0.311546 -0.517578 0.312506 -0.518838 0 0 0 0.00281905 l
+0.311546 -0.517578 0.308159 -0.51207 0 0 0 0.00281905 l
+-0.562795 -0.631207 -0.561845 -0.630275 0 0 0 0.00281905 l
+-0.562795 -0.631207 -0.565561 -0.633652 0 0 0 0.00281905 l
+-0.319487 -0.160023 -0.312765 -0.175179 0 0 0 0.00281905 l
+-0.319487 -0.160023 -0.312169 -0.148035 0 0 0 0.00281905 l
+-0.321556 -0.0194461 -0.320346 -0.0271773 0 0 0 0.00281905 l
+-0.321556 -0.0194461 -0.317704 -0.00147212 0 0 0 0.00281905 l
+-0.533087 0.526448 -0.535292 0.538825 0 0 0 0.00281905 l
+-0.533087 0.526448 -0.530984 0.524263 0 0 0 0.00281905 l
+-0.533087 0.526448 -0.540706 0.524958 0 0 0 0.00281905 l
+-0.775376 -0.595248 -0.781186 -0.597679 0 0 0 0.00281905 l
+-0.337272 0.747757 -0.329215 0.762734 0 0 0 0.00281905 l
+-0.337272 0.747757 -0.349499 0.749498 0 0 0 0.00281905 l
+-0.444975 0.208972 -0.441757 0.204619 0 0 0 0.00281905 l
+-0.444975 0.208972 -0.454811 0.21712 0 0 0 0.00281905 l
+0.560972 0.384013 0.564381 0.393704 0 0 0 0.00281905 l
+0.560972 0.384013 0.576842 0.38169 0 0 0 0.00281905 l
+0.560972 0.384013 0.542652 0.384133 0 0 0 0.00281905 l
+-0.191339 -0.774652 -0.190784 -0.766683 0 0 0 0.00281905 l
+-0.191339 -0.774652 -0.191371 -0.774802 0 0 0 0.00281905 l
+-0.103631 -0.885076 -0.118871 -0.886589 0 0 0 0.00281905 l
+-0.103631 -0.885076 -0.101343 -0.879654 0 0 0 0.00281905 l
+0.0598332 0.316798 0.0670361 0.313223 0 0 0 0.00281905 l
+0.405161 -0.891598 0.408072 -0.893611 0 0 0 0.00281905 l
+0.759127 0.0489503 0.751699 0.0591822 0 0 0 0.00281905 l
+0.759127 0.0489503 0.753373 0.0440827 0 0 0 0.00281905 l
+-0.594504 0.0886444 -0.593712 0.0924504 0 0 0 0.00281905 l
+-0.84791 -0.380746 -0.850442 -0.373911 0 0 0 0.00281905 l
+-0.84791 -0.380746 -0.845006 -0.381534 0 0 0 0.00281905 l
+0.0605843 0.107692 0.069898 0.0992727 0 0 0 0.00281905 l
+0.0605843 0.107692 0.0403637 0.114267 0 0 0 0.00281905 l
+0.556954 -0.389991 0.553961 -0.37671 0 0 0 0.00281905 l
+0.556954 -0.389991 0.5595 -0.395497 0 0 0 0.00281905 l
+0.77587 0.554475 0.786329 0.566404 0 0 0 0.00281905 l
+0.77587 0.554475 0.778454 0.551683 0 0 0 0.00281905 l
+0.28883 -0.840054 0.293751 -0.841402 0 0 0 0.00281905 l
+0.759869 -0.0978489 0.762144 -0.0939711 0 0 0 0.00281905 l
+-0.210598 0.860998 -0.192245 0.853843 0 0 0 0.00281905 l
+-0.210598 0.860998 -0.215222 0.844214 0 0 0 0.00281905 l
+0.0308855 -0.567843 0.0376129 -0.568085 0 0 0 0.00281905 l
+0.0308855 -0.567843 0.0291117 -0.570709 0 0 0 0.00281905 l
+-0.454803 0.629458 -0.4704 0.643535 0 0 0 0.00281905 l
+-0.454803 0.629458 -0.437967 0.638082 0 0 0 0.00281905 l
+0.728812 0.175593 0.721324 0.171566 0 0 0 0.00281905 l
+0.293725 -0.529172 0.285435 -0.523733 0 0 0 0.00281905 l
+0.604926 -0.640913 0.612343 -0.633265 0 0 0 0.00281905 l
+0.604926 -0.640913 0.59835 -0.643821 0 0 0 0.00281905 l
+-0.0704537 -0.606966 -0.0607823 -0.589126 0 0 0 0.00281905 l
+-0.0704537 -0.606966 -0.0762153 -0.619688 0 0 0 0.00281905 l
+-0.448888 -0.829842 -0.445927 -0.838244 0 0 0 0.00281905 l
+-0.448888 -0.829842 -0.444528 -0.829001 0 0 0 0.00281905 l
+0.814381 0.366699 0.816603 0.356582 0 0 0 0.00281905 l
+0.814381 0.366699 0.812243 0.371146 0 0 0 0.00281905 l
+-0.397928 0.721963 -0.395239 0.703694 0 0 0 0.00281905 l
+-0.397928 0.721963 -0.381979 0.731105 0 0 0 0.00281905 l
+0.408865 0.747206 0.408128 0.738103 0 0 0 0.00281905 l
+0.408865 0.747206 0.413568 0.752051 0 0 0 0.00281905 l
+0.225128 -0.157102 0.228827 -0.163963 0 0 0 0.00281905 l
+-0.641306 0.607614 -0.64448 0.602419 0 0 0 0.00281905 l
+-0.641306 0.607614 -0.647668 0.611357 0 0 0 0.00281905 l
+-0.746498 -0.337325 -0.740271 -0.339693 0 0 0 0.00281905 l
+-0.746498 -0.337325 -0.748145 -0.344089 0 0 0 0.00281905 l
+-0.746498 -0.337325 -0.759482 -0.324597 0 0 0 0.00281905 l
+0.986419 -0.118484 0.988307 -0.120358 0 0 0 0.00281905 l
+-0.111602 -0.43838 -0.111503 -0.453739 0 0 0 0.00281905 l
+-0.111602 -0.43838 -0.0950944 -0.436901 0 0 0 0.00281905 l
+0.428602 -0.3471 0.440681 -0.35128 0 0 0 0.00281905 l
+0.428602 -0.3471 0.43676 -0.33439 0 0 0 0.00281905 l
+0.328125 0.4328 0.332855 0.435582 0 0 0 0.00281905 l
+0.328125 0.4328 0.309397 0.432814 0 0 0 0.00281905 l
+0.835603 -0.306829 0.822822 -0.295258 0 0 0 0.00281905 l
+-0.399047 -0.580146 -0.39064 -0.597497 0 0 0 0.00281905 l
+0.142353 0.578087 0.146805 0.561243 0 0 0 0.00281905 l
+0.142353 0.578087 0.158087 0.587024 0 0 0 0.00281905 l
+-0.265894 -0.525587 -0.263941 -0.513142 0 0 0 0.00281905 l
+-0.265894 -0.525587 -0.269775 -0.532888 0 0 0 0.00281905 l
+0.433109 -0.0219774 0.439147 -0.0267711 0 0 0 0.00281905 l
+0.433109 -0.0219774 0.423456 -0.0335887 0 0 0 0.00281905 l
+0.433109 -0.0219774 0.437347 -0.0183985 0 0 0 0.00281905 l
+0.736073 0.362641 0.742532 0.360178 0 0 0 0.00281905 l
+0.736073 0.362641 0.731991 0.363837 0 0 0 0.00281905 l
+-0.535292 0.538825 -0.53043 0.547367 0 0 0 0.00281905 l
+-0.535292 0.538825 -0.533087 0.526448 0 0 0 0.00281905 l
+0.022773 0.0198949 0.0323125 0.0216024 0 0 0 0.00281905 l
+-0.15453 0.309752 -0.156386 0.297729 0 0 0 0.00281905 l
+-0.15453 0.309752 -0.166842 0.314475 0 0 0 0.00281905 l
+0.496534 0.129648 0.495937 0.132743 0 0 0 0.00281905 l
+0.657916 0.29594 0.665178 0.296022 0 0 0 0.00281905 l
+0.657916 0.29594 0.652656 0.300091 0 0 0 0.00281905 l
+-0.804495 -0.296672 -0.804077 -0.281375 0 0 0 0.00281905 l
+-0.804495 -0.296672 -0.798305 -0.300821 0 0 0 0.00281905 l
+0.172204 0.684997 0.18318 0.69858 0 0 0 0.00281905 l
+0.172204 0.684997 0.180538 0.677491 0 0 0 0.00281905 l
+-0.077214 -0.745015 -0.0794952 -0.738284 0 0 0 0.00281905 l
+-0.476791 0.475314 -0.470645 0.473308 0 0 0 0.00281905 l
+-0.476791 0.475314 -0.489286 0.468563 0 0 0 0.00281905 l
+-0.376545 -0.830115 -0.385558 -0.832888 0 0 0 0.00281905 l
+0.686379 -0.599059 0.681319 -0.589522 0 0 0 0.00281905 l
+0.686379 -0.599059 0.694226 -0.592659 0 0 0 0.00281905 l
+-0.821005 0.463393 -0.829384 0.462973 0 0 0 0.00281905 l
+-0.0440233 0.369389 -0.0462363 0.351448 0 0 0 0.00281905 l
+-0.0440233 0.369389 -0.0382336 0.38314 0 0 0 0.00281905 l
+-0.166582 -0.353338 -0.168884 -0.366913 0 0 0 0.00281905 l
+-0.166582 -0.353338 -0.161508 -0.348034 0 0 0 0.00281905 l
+0.0261246 0.277342 0.0344999 0.278472 0 0 0 0.00281905 l
+-0.134562 0.188374 -0.133133 0.203282 0 0 0 0.00281905 l
+-0.134562 0.188374 -0.126743 0.185802 0 0 0 0.00281905 l
+-0.134562 0.188374 -0.138981 0.188299 0 0 0 0.00281905 l
+0.616921 0.471377 0.622827 0.478655 0 0 0 0.00281905 l
+0.616921 0.471377 0.625303 0.459165 0 0 0 0.00281905 l
+0.616921 0.471377 0.604392 0.472019 0 0 0 0.00281905 l
+-0.533195 -0.759963 -0.519543 -0.751565 0 0 0 0.00281905 l
+-0.533195 -0.759963 -0.540851 -0.770903 0 0 0 0.00281905 l
+0.117014 0.0166601 0.112708 0.0321531 0 0 0 0.00281905 l
+0.117014 0.0166601 0.120418 0.01615 0 0 0 0.00281905 l
+0.117014 0.0166601 0.09671 0.011621 0 0 0 0.00281905 l
+0.0675832 -0.795413 0.0613402 -0.786317 0 0 0 0.00281905 l
+-0.233504 0.825716 -0.223671 0.844436 0 0 0 0.00281905 l
+0.663176 -0.289408 0.670805 -0.2851 0 0 0 0.00281905 l
+0.663176 -0.289408 0.648165 -0.294344 0 0 0 0.00281905 l
+0.580087 -0.0767557 0.572913 -0.0752311 0 0 0 0.00281905 l
+0.794886 -0.342719 0.809356 -0.352088 0 0 0 0.00281905 l
+0.794886 -0.342719 0.792297 -0.34196 0 0 0 0.00281905 l
+-0.399967 -0.385864 -0.402621 -0.373107 0 0 0 0.00281905 l
+-0.620394 -0.31908 -0.607449 -0.320658 0 0 0 0.00281905 l
+0.351643 -0.522316 0.365008 -0.501858 0 0 0 0.00281905 l
+0.688548 0.244295 0.687278 0.2497 0 0 0 0.00281905 l
+0.688548 0.244295 0.699447 0.239532 0 0 0 0.00281905 l
+-0.454287 -0.478457 -0.450436 -0.489632 0 0 0 0.00281905 l
+-0.454287 -0.478457 -0.469206 -0.484257 0 0 0 0.00281905 l
+-0.369819 -0.26197 -0.374112 -0.251253 0 0 0 0.00281905 l
+-0.432935 -0.781156 -0.425537 -0.784618 0 0 0 0.00281905 l
+-0.432935 -0.781156 -0.433789 -0.786807 0 0 0 0.00281905 l
+-0.03441 -0.733979 -0.0421546 -0.740398 0 0 0 0.00281905 l
+0.102942 0.177668 0.103421 0.166096 0 0 0 0.00281905 l
+0.102942 0.177668 0.100671 0.191628 0 0 0 0.00281905 l
+0.102942 0.177668 0.0931468 0.173973 0 0 0 0.00281905 l
+0.292639 0.128123 0.308352 0.135018 0 0 0 0.00281905 l
+0.292639 0.128123 0.292883 0.12219 0 0 0 0.00281905 l
+0.292639 0.128123 0.278502 0.137061 0 0 0 0.00281905 l
+0.707581 -0.377794 0.718738 -0.388735 0 0 0 0.00281905 l
+0.707581 -0.377794 0.714095 -0.368501 0 0 0 0.00281905 l
+0.0823531 -0.650882 0.0959863 -0.64181 0 0 0 0.00281905 l
+-0.183539 0.713358 -0.171737 0.715379 0 0 0 0.00281905 l
+-0.183539 0.713358 -0.207325 0.711782 0 0 0 0.00281905 l
+0.904067 -0.0631729 0.907422 -0.0602081 0 0 0 0.00281905 l
+0.904067 -0.0631729 0.899795 -0.0647737 0 0 0 0.00281905 l
+0.141194 0.901489 0.141393 0.905413 0 0 0 0.00281905 l
+0.397883 -0.0870992 0.401602 -0.0848418 0 0 0 0.00281905 l
+0.150977 -0.0569331 0.164226 -0.0540648 0 0 0 0.00281905 l
+0.150977 -0.0569331 0.138132 -0.0428178 0 0 0 0.00281905 l
+0.150977 -0.0569331 0.137592 -0.0669224 0 0 0 0.00281905 l
+-0.0668578 0.458783 -0.0551557 0.444567 0 0 0 0.00281905 l
+-0.0668578 0.458783 -0.0728485 0.453888 0 0 0 0.00281905 l
+0.912829 0.215637 0.920365 0.203823 0 0 0 0.00281905 l
+0.912829 0.215637 0.906446 0.227343 0 0 0 0.00281905 l
+0.912829 0.215637 0.923444 0.223425 0 0 0 0.00281905 l
+0.912829 0.215637 0.908273 0.211592 0 0 0 0.00281905 l
+0.405075 0.139008 0.390101 0.123344 0 0 0 0.00281905 l
+0.405075 0.139008 0.412743 0.140121 0 0 0 0.00281905 l
+0.71408 -0.335987 0.714817 -0.321722 0 0 0 0.00281905 l
+0.71408 -0.335987 0.716229 -0.336557 0 0 0 0.00281905 l
+-0.600431 -0.0375296 -0.599126 -0.0200293 0 0 0 0.00281905 l
+-0.600431 -0.0375296 -0.597058 -0.0400136 0 0 0 0.00281905 l
+-0.600431 -0.0375296 -0.606491 -0.0428925 0 0 0 0.00281905 l
+-0.751853 0.012317 -0.744458 0.0251737 0 0 0 0.00281905 l
+-0.78862 0.186264 -0.790782 0.186761 0 0 0 0.00281905 l
+-0.78862 0.186264 -0.785913 0.186794 0 0 0 0.00281905 l
+0.735504 0.450538 0.725599 0.450658 0 0 0 0.00281905 l
+0.735504 0.450538 0.736852 0.451863 0 0 0 0.00281905 l
+-0.434804 0.263445 -0.434903 0.271499 0 0 0 0.00281905 l
+-0.434804 0.263445 -0.420375 0.256325 0 0 0 0.00281905 l
+0.570182 0.49395 0.566212 0.490944 0 0 0 0.00281905 l
+-0.0940309 0.0453731 -0.0886712 0.0317118 0 0 0 0.00281905 l
+-0.0940309 0.0453731 -0.0808913 0.0555962 0 0 0 0.00281905 l
+-0.0940309 0.0453731 -0.103093 0.0477133 0 0 0 0.00281905 l
+0.25921 -0.615296 0.276906 -0.62408 0 0 0 0.00281905 l
+0.25921 -0.615296 0.245718 -0.612089 0 0 0 0.00281905 l
+-0.0728485 0.453888 -0.0668578 0.458783 0 0 0 0.00281905 l
+-0.0728485 0.453888 -0.0752377 0.460833 0 0 0 0.00281905 l
+-0.0728485 0.453888 -0.0744801 0.451434 0 0 0 0.00281905 l
+0.340173 0.377022 0.34712 0.367882 0 0 0 0.00281905 l
+0.340173 0.377022 0.321619 0.380611 0 0 0 0.00281905 l
+-0.192541 -0.415924 -0.19245 -0.410395 0 0 0 0.00281905 l
+-0.192541 -0.415924 -0.172982 -0.418446 0 0 0 0.00281905 l
+0.418042 -0.438294 0.432164 -0.451936 0 0 0 0.00281905 l
+0.418042 -0.438294 0.412073 -0.438413 0 0 0 0.00281905 l
+-0.406829 -0.643122 -0.41998 -0.650518 0 0 0 0.00281905 l
+0.304267 -0.633212 0.307061 -0.641291 0 0 0 0.00281905 l
+-0.463433 0.403136 -0.448952 0.405021 0 0 0 0.00281905 l
+-0.463433 0.403136 -0.474916 0.410385 0 0 0 0.00281905 l
+-0.819507 -0.212469 -0.830781 -0.20861 0 0 0 0.00281905 l
+-0.384663 0.850313 -0.37384 0.846568 0 0 0 0.00281905 l
+-0.384663 0.850313 -0.391437 0.845703 0 0 0 0.00281905 l
+0.250614 -0.217843 0.243199 -0.217891 0 0 0 0.00281905 l
+-0.752244 -0.509145 -0.743159 -0.496232 0 0 0 0.00281905 l
+-0.752244 -0.509145 -0.733753 -0.51974 0 0 0 0.00281905 l
+-0.752244 -0.509145 -0.75439 -0.513988 0 0 0 0.00281905 l
+-0.55943 0.371135 -0.559607 0.383472 0 0 0 0.00281905 l
+-0.55943 0.371135 -0.568411 0.367228 0 0 0 0.00281905 l
+0.317619 0.916339 0.325626 0.911869 0 0 0 0.00281905 l
+0.317619 0.916339 0.315353 0.919222 0 0 0 0.00281905 l
+-0.164083 -0.431341 -0.155451 -0.427624 0 0 0 0.00281905 l
+-0.164083 -0.431341 -0.160899 -0.436902 0 0 0 0.00281905 l
+0.305613 0.0735602 0.289356 0.0748388 0 0 0 0.00281905 l
+0.443371 -0.198483 0.453209 -0.204185 0 0 0 0.00281905 l
+0.443371 -0.198483 0.435246 -0.206102 0 0 0 0.00281905 l
+0.041199 -0.153382 0.0467613 -0.170992 0 0 0 0.00281905 l
+0.041199 -0.153382 0.0297304 -0.135978 0 0 0 0.00281905 l
+0.041199 -0.153382 0.0494498 -0.14821 0 0 0 0.00281905 l
+0.186936 -0.813768 0.197163 -0.816542 0 0 0 0.00281905 l
+0.186936 -0.813768 0.179464 -0.808184 0 0 0 0.00281905 l
+-0.536441 0.512308 -0.530984 0.524263 0 0 0 0.00281905 l
+-0.536441 0.512308 -0.544548 0.510971 0 0 0 0.00281905 l
+-0.162658 0.339415 -0.151782 0.338207 0 0 0 0.00281905 l
+-0.162658 0.339415 -0.168049 0.341518 0 0 0 0.00281905 l
+-0.0853062 -0.132816 -0.0987334 -0.147024 0 0 0 0.00281905 l
+-0.0853062 -0.132816 -0.0748145 -0.122022 0 0 0 0.00281905 l
+-0.824177 0.526006 -0.841421 0.522472 0 0 0 0.00281905 l
+-0.412015 0.760059 -0.405921 0.771293 0 0 0 0.00281905 l
+-0.412015 0.760059 -0.408832 0.753133 0 0 0 0.00281905 l
+0.295053 0.326162 0.298652 0.322982 0 0 0 0.00281905 l
+0.295053 0.326162 0.293155 0.323911 0 0 0 0.00281905 l
+0.295053 0.326162 0.293289 0.327953 0 0 0 0.00281905 l
+0.701928 0.645464 0.703983 0.637882 0 0 0 0.00281905 l
+0.701928 0.645464 0.708712 0.656746 0 0 0 0.00281905 l
+-0.144356 -0.687791 -0.141942 -0.687422 0 0 0 0.00281905 l
+-0.730169 0.353128 -0.71721 0.345414 0 0 0 0.00281905 l
+-0.730169 0.353128 -0.736818 0.351592 0 0 0 0.00281905 l
+-0.481141 0.714145 -0.484009 0.696163 0 0 0 0.00281905 l
+-0.481141 0.714145 -0.473991 0.718235 0 0 0 0.00281905 l
+-0.481141 0.714145 -0.496035 0.726816 0 0 0 0.00281905 l
+0.29333 -0.359338 0.29124 -0.377995 0 0 0 0.00281905 l
+0.29333 -0.359338 0.294643 -0.355377 0 0 0 0.00281905 l
+-0.347965 0.199637 -0.344462 0.211454 0 0 0 0.00281905 l
+-0.347965 0.199637 -0.358903 0.205019 0 0 0 0.00281905 l
+0.890339 -0.42827 0.894192 -0.437321 0 0 0 0.00281905 l
+0.890339 -0.42827 0.882583 -0.42218 0 0 0 0.00281905 l
+-0.0443842 0.133992 -0.0497604 0.14437 0 0 0 0.00281905 l
+-0.0443842 0.133992 -0.0369126 0.125381 0 0 0 0.00281905 l
+-0.0443842 0.133992 -0.0554581 0.123654 0 0 0 0.00281905 l
+-0.119543 0.339315 -0.10871 0.354069 0 0 0 0.00281905 l
+-0.119543 0.339315 -0.132032 0.336291 0 0 0 0.00281905 l
+0.55632 0.780585 0.564501 0.76548 0 0 0 0.00281905 l
+0.55632 0.780585 0.548126 0.788447 0 0 0 0.00281905 l
+0.992233 -0.0336152 0.970852 -0.0230126 0 0 0 0.00281905 l
+-0.6779 -0.41723 -0.676879 -0.404281 0 0 0 0.00281905 l
+-0.6779 -0.41723 -0.678759 -0.418793 0 0 0 0.00281905 l
+-0.571152 -0.293083 -0.557523 -0.283606 0 0 0 0.00281905 l
+-0.571152 -0.293083 -0.581842 -0.290666 0 0 0 0.00281905 l
+0.602612 -0.473166 0.594812 -0.481815 0 0 0 0.00281905 l
+0.623076 -0.0513411 0.624423 -0.0661264 0 0 0 0.00281905 l
+0.623076 -0.0513411 0.626666 -0.0435007 0 0 0 0.00281905 l
+0.623076 -0.0513411 0.611624 -0.0480491 0 0 0 0.00281905 l
+-0.209681 -0.648163 -0.208573 -0.647957 0 0 0 0.00281905 l
+-0.209681 -0.648163 -0.224238 -0.643785 0 0 0 0.00281905 l
+0.638001 -0.546558 0.639028 -0.533705 0 0 0 0.00281905 l
+0.638001 -0.546558 0.623513 -0.54772 0 0 0 0.00281905 l
+-0.91112 -0.305925 -0.90352 -0.304944 0 0 0 0.00281905 l
+-0.91112 -0.305925 -0.912569 -0.313717 0 0 0 0.00281905 l
+-0.259653 0.91724 -0.256745 0.90736 0 0 0 0.00281905 l
+-0.259653 0.91724 -0.266493 0.922072 0 0 0 0.00281905 l
+-0.434056 -0.0143752 -0.441122 -0.0113368 0 0 0 0.00281905 l
+0.879112 -0.412237 0.882583 -0.42218 0 0 0 0.00281905 l
+0.879112 -0.412237 0.873976 -0.414721 0 0 0 0.00281905 l
+-0.600389 -0.428305 -0.595229 -0.440003 0 0 0 0.00281905 l
+-0.688805 -0.321425 -0.680496 -0.323855 0 0 0 0.00281905 l
+-0.688805 -0.321425 -0.701956 -0.321023 0 0 0 0.00281905 l
+-0.150005 0.274124 -0.149317 0.276998 0 0 0 0.00281905 l
+-0.150005 0.274124 -0.144314 0.267707 0 0 0 0.00281905 l
+-0.149714 0.441138 -0.141021 0.433607 0 0 0 0.00281905 l
+-0.149714 0.441138 -0.157383 0.442484 0 0 0 0.00281905 l
+0.332582 0.0426953 0.319327 0.0353932 0 0 0 0.00281905 l
+-0.250225 -0.268649 -0.245328 -0.275228 0 0 0 0.00281905 l
+-0.250225 -0.268649 -0.261824 -0.262972 0 0 0 0.00281905 l
+0.118378 -0.0687233 0.128677 -0.0628127 0 0 0 0.00281905 l
+0.118378 -0.0687233 0.10117 -0.0686018 0 0 0 0.00281905 l
+0.176019 0.747925 0.193461 0.755388 0 0 0 0.00281905 l
+0.176019 0.747925 0.17334 0.730685 0 0 0 0.00281905 l
+-0.622471 0.101655 -0.624444 0.0912946 0 0 0 0.00281905 l
+-0.622471 0.101655 -0.616032 0.108037 0 0 0 0.00281905 l
+-0.172982 -0.418446 -0.159027 -0.41948 0 0 0 0.00281905 l
+-0.172982 -0.418446 -0.192541 -0.415924 0 0 0 0.00281905 l
+-0.469971 0.244123 -0.469679 0.237555 0 0 0 0.00281905 l
+-0.469971 0.244123 -0.473274 0.247653 0 0 0 0.00281905 l
+0.292308 -0.472521 0.310185 -0.474497 0 0 0 0.00281905 l
+0.292308 -0.472521 0.285563 -0.477153 0 0 0 0.00281905 l
+0.805744 -0.0258535 0.807097 -0.0293921 0 0 0 0.00281905 l
+0.805744 -0.0258535 0.803505 -0.0245896 0 0 0 0.00281905 l
+0.520869 -0.619885 0.525325 -0.627025 0 0 0 0.00281905 l
+0.27265 0.44452 0.269152 0.452817 0 0 0 0.00281905 l
+0.27265 0.44452 0.272775 0.442278 0 0 0 0.00281905 l
+-0.193575 -0.627186 -0.208472 -0.619402 0 0 0 0.00281905 l
+-0.193575 -0.627186 -0.202238 -0.63654 0 0 0 0.00281905 l
+0.256423 -0.833626 0.262251 -0.842054 0 0 0 0.00281905 l
+0.256423 -0.833626 0.24156 -0.83257 0 0 0 0.00281905 l
+-0.449923 0.784659 -0.446467 0.775199 0 0 0 0.00281905 l
+-0.449923 0.784659 -0.460144 0.798133 0 0 0 0.00281905 l
+0.664011 0.744323 0.655062 0.742157 0 0 0 0.00281905 l
+-0.774951 0.58919 -0.777657 0.581113 0 0 0 0.00281905 l
+-0.774951 0.58919 -0.774113 0.594583 0 0 0 0.00281905 l
+-0.516419 -0.258015 -0.511532 -0.260289 0 0 0 0.00281905 l
+-0.516419 -0.258015 -0.521897 -0.258983 0 0 0 0.00281905 l
+-0.00457386 -0.9805 -0.0143689 -0.975676 0 0 0 0.00281905 l
+-0.00457386 -0.9805 0.000522187 -0.974772 0 0 0 0.00281905 l
+-0.260768 -0.801085 -0.258168 -0.807946 0 0 0 0.00281905 l
+-0.260768 -0.801085 -0.27372 -0.795005 0 0 0 0.00281905 l
+-0.51745 0.218923 -0.510952 0.214924 0 0 0 0.00281905 l
+-0.51745 0.218923 -0.526248 0.228606 0 0 0 0.00281905 l
+0.0381628 -0.750854 0.0309108 -0.762964 0 0 0 0.00281905 l
+-0.676817 -0.177286 -0.672545 -0.18034 0 0 0 0.00281905 l
+-0.676817 -0.177286 -0.688653 -0.169606 0 0 0 0.00281905 l
+-0.106834 -0.924701 -0.103724 -0.914929 0 0 0 0.00281905 l
+-0.106834 -0.924701 -0.111163 -0.941424 0 0 0 0.00281905 l
+-0.608309 0.132208 -0.61788 0.136657 0 0 0 0.00281905 l
+0.562442 0.179657 0.573743 0.176833 0 0 0 0.00281905 l
+0.562442 0.179657 0.555481 0.166558 0 0 0 0.00281905 l
+0.562442 0.179657 0.549905 0.182243 0 0 0 0.00281905 l
+-0.653977 0.642566 -0.645734 0.647866 0 0 0 0.00281905 l
+-0.106947 0.278187 -0.113357 0.270107 0 0 0 0.00281905 l
+0.11017 0.737881 0.107425 0.732874 0 0 0 0.00281905 l
+0.682803 -0.028462 0.673576 -0.0102288 0 0 0 0.00281905 l
+0.682803 -0.028462 0.671448 -0.0334163 0 0 0 0.00281905 l
+0.059072 0.790593 0.0495935 0.778917 0 0 0 0.00281905 l
+0.059072 0.790593 0.0604241 0.792402 0 0 0 0.00281905 l
+-0.175667 -0.190113 -0.181919 -0.178761 0 0 0 0.00281905 l
+-0.175667 -0.190113 -0.175209 -0.192221 0 0 0 0.00281905 l
+0.580161 -0.064904 0.592433 -0.0532781 0 0 0 0.00281905 l
+0.580161 -0.064904 0.571925 -0.0598065 0 0 0 0.00281905 l
+0.328711 0.491134 0.309692 0.4896 0 0 0 0.00281905 l
+0.497379 -0.00989928 0.503612 0.00190704 0 0 0 0.00281905 l
+0.497379 -0.00989928 0.49338 -0.0123837 0 0 0 0.00281905 l
+0.900254 0.109507 0.909269 0.118093 0 0 0 0.00281905 l
+0.900254 0.109507 0.894183 0.103661 0 0 0 0.00281905 l
+0.668019 -0.688442 0.687508 -0.669762 0 0 0 0.00281905 l
+0.668019 -0.688442 0.667598 -0.692674 0 0 0 0.00281905 l
+0.668019 -0.688442 0.658085 -0.679366 0 0 0 0.00281905 l
+0.415311 0.28007 0.411891 0.273496 0 0 0 0.00281905 l
+0.415311 0.28007 0.400504 0.293362 0 0 0 0.00281905 l
+0.304707 0.334533 0.305453 0.326939 0 0 0 0.00281905 l
+0.304707 0.334533 0.311781 0.339964 0 0 0 0.00281905 l
+-0.00993317 -0.657905 -0.0144263 -0.674143 0 0 0 0.00281905 l
+-0.00993317 -0.657905 -0.0248214 -0.654944 0 0 0 0.00281905 l
+0.574973 0.0444442 0.578227 0.0426273 0 0 0 0.00281905 l
+0.574973 0.0444442 0.572109 0.0426269 0 0 0 0.00281905 l
+0.90764 -0.372444 0.914172 -0.37388 0 0 0 0.00281905 l
+0.90764 -0.372444 0.900101 -0.384038 0 0 0 0.00281905 l
+0.90764 -0.372444 0.890066 -0.361856 0 0 0 0.00281905 l
+-0.293584 0.0196004 -0.280749 0.00932734 0 0 0 0.00281905 l
+-0.293584 0.0196004 -0.295849 0.029227 0 0 0 0.00281905 l
+0.332764 -0.480226 0.336109 -0.479036 0 0 0 0.00281905 l
+0.332764 -0.480226 0.315585 -0.475105 0 0 0 0.00281905 l
+-0.951515 0.00509584 -0.959543 0.000243254 0 0 0 0.00281905 l
+-0.197096 0.896493 -0.200413 0.907705 0 0 0 0.00281905 l
+-0.197096 0.896493 -0.189934 0.898548 0 0 0 0.00281905 l
+-0.197096 0.896493 -0.191317 0.887829 0 0 0 0.00281905 l
+-0.395138 -0.0793576 -0.395111 -0.0807875 0 0 0 0.00281905 l
+0.830794 0.277003 0.82381 0.292015 0 0 0 0.00281905 l
+0.830794 0.277003 0.83887 0.278724 0 0 0 0.00281905 l
+0.830794 0.277003 0.818154 0.26173 0 0 0 0.00281905 l
+0.468742 0.363173 0.473686 0.370448 0 0 0 0.00281905 l
+0.468742 0.363173 0.464241 0.346221 0 0 0 0.00281905 l
+0.468742 0.363173 0.461841 0.370342 0 0 0 0.00281905 l
+0.0169159 -0.142595 0.0297304 -0.135978 0 0 0 0.00281905 l
+0.595041 -0.730904 0.619001 -0.719551 0 0 0 0.00281905 l
+0.595041 -0.730904 0.587995 -0.730842 0 0 0 0.00281905 l
+-0.930636 -0.00909486 -0.932611 -0.0225353 0 0 0 0.00281905 l
+-0.930636 -0.00909486 -0.921847 0.00413317 0 0 0 0.00281905 l
+0.454717 -0.158842 0.456982 -0.169034 0 0 0 0.00281905 l
+0.454717 -0.158842 0.442709 -0.164076 0 0 0 0.00281905 l
+-0.786273 -0.352667 -0.772194 -0.347793 0 0 0 0.00281905 l
+-0.786273 -0.352667 -0.791297 -0.349648 0 0 0 0.00281905 l
+-0.929677 -0.0391187 -0.934091 -0.0236802 0 0 0 0.00281905 l
+0.241582 -0.402305 0.241869 -0.387625 0 0 0 0.00281905 l
+0.241582 -0.402305 0.224665 -0.400439 0 0 0 0.00281905 l
+-0.258168 -0.807946 -0.260768 -0.801085 0 0 0 0.00281905 l
+-0.258168 -0.807946 -0.242976 -0.80338 0 0 0 0.00281905 l
+-0.258168 -0.807946 -0.269505 -0.813911 0 0 0 0.00281905 l
+0.0668636 -0.188052 0.0667513 -0.19042 0 0 0 0.00281905 l
+0.305077 -0.550722 0.312246 -0.538192 0 0 0 0.00281905 l
+0.305077 -0.550722 0.317542 -0.551965 0 0 0 0.00281905 l
+0.378596 -0.791261 0.399478 -0.781768 0 0 0 0.00281905 l
+0.378596 -0.791261 0.368315 -0.800676 0 0 0 0.00281905 l
+-0.760521 0.214677 -0.765014 0.208729 0 0 0 0.00281905 l
+-0.760521 0.214677 -0.764841 0.216826 0 0 0 0.00281905 l
+-0.157729 0.705475 -0.159636 0.689064 0 0 0 0.00281905 l
+-0.157729 0.705475 -0.160385 0.714365 0 0 0 0.00281905 l
+0.549349 -0.658081 0.554137 -0.656497 0 0 0 0.00281905 l
+0.549349 -0.658081 0.532209 -0.652247 0 0 0 0.00281905 l
+-0.555066 -0.201816 -0.550987 -0.202089 0 0 0 0.00281905 l
+-0.555066 -0.201816 -0.55556 -0.198653 0 0 0 0.00281905 l
+-0.165211 -0.656169 -0.149574 -0.667372 0 0 0 0.00281905 l
+-0.165211 -0.656169 -0.175458 -0.657824 0 0 0 0.00281905 l
+0.651279 0.630921 0.655195 0.622067 0 0 0 0.00281905 l
+-0.0673331 0.191848 -0.0592845 0.186598 0 0 0 0.00281905 l
+0.567813 -0.823155 0.571265 -0.817467 0 0 0 0.00281905 l
+-0.821844 0.160754 -0.822478 0.171334 0 0 0 0.00281905 l
+-0.821844 0.160754 -0.797721 0.159704 0 0 0 0.00281905 l
+-0.821844 0.160754 -0.824132 0.156096 0 0 0 0.00281905 l
+-0.845006 -0.381534 -0.839881 -0.402361 0 0 0 0.00281905 l
+-0.845006 -0.381534 -0.84791 -0.380746 0 0 0 0.00281905 l
+0.611341 -0.219099 0.62152 -0.210253 0 0 0 0.00281905 l
+0.611341 -0.219099 0.615764 -0.224644 0 0 0 0.00281905 l
+0.611341 -0.219099 0.599835 -0.217792 0 0 0 0.00281905 l
+-0.952215 -0.027516 -0.949518 -0.029842 0 0 0 0.00281905 l
+-0.952215 -0.027516 -0.963998 -0.0237917 0 0 0 0.00281905 l
+-0.43363 0.481924 -0.421886 0.488646 0 0 0 0.00281905 l
+-0.43363 0.481924 -0.43552 0.483817 0 0 0 0.00281905 l
+-0.87529 0.0475248 -0.872045 0.0364239 0 0 0 0.00281905 l
+-0.87529 0.0475248 -0.886005 0.0466323 0 0 0 0.00281905 l
+0.567856 -0.120091 0.576883 -0.128858 0 0 0 0.00281905 l
+0.567856 -0.120091 0.579899 -0.111787 0 0 0 0.00281905 l
+-0.44234 -0.563801 -0.43427 -0.567725 0 0 0 0.00281905 l
+0.413568 0.752051 0.410191 0.764462 0 0 0 0.00281905 l
+0.413568 0.752051 0.417057 0.748669 0 0 0 0.00281905 l
+0.413568 0.752051 0.408865 0.747206 0 0 0 0.00281905 l
+0.50606 0.52865 0.515144 0.526468 0 0 0 0.00281905 l
+0.50606 0.52865 0.502619 0.534129 0 0 0 0.00281905 l
+0.410052 0.0557325 0.421202 0.0555981 0 0 0 0.00281905 l
+0.410052 0.0557325 0.412178 0.0489788 0 0 0 0.00281905 l
+-0.776374 -0.618354 -0.781186 -0.597679 0 0 0 0.00281905 l
+-0.776374 -0.618354 -0.764441 -0.64019 0 0 0 0.00281905 l
+0.564377 -0.553354 0.560625 -0.541823 0 0 0 0.00281905 l
+0.564377 -0.553354 0.565664 -0.553334 0 0 0 0.00281905 l
+0.564377 -0.553354 0.56387 -0.5582 0 0 0 0.00281905 l
+0.230371 0.121257 0.246628 0.132946 0 0 0 0.00281905 l
+0.230371 0.121257 0.217569 0.115464 0 0 0 0.00281905 l
+-0.806212 -0.052957 -0.797203 -0.0612036 0 0 0 0.00281905 l
+-0.806212 -0.052957 -0.814929 -0.0600103 0 0 0 0.00281905 l
+-0.806212 -0.052957 -0.806435 -0.0522655 0 0 0 0.00281905 l
+0.270334 -0.694823 0.273374 -0.686645 0 0 0 0.00281905 l
+0.270334 -0.694823 0.261532 -0.695079 0 0 0 0.00281905 l
+0.106562 -0.192028 0.114652 -0.18783 0 0 0 0.00281905 l
+0.106562 -0.192028 0.0942822 -0.202988 0 0 0 0.00281905 l
+0.106562 -0.192028 0.100458 -0.182645 0 0 0 0.00281905 l
+-0.866412 -0.109302 -0.870821 -0.0924164 0 0 0 0.00281905 l
+-0.866412 -0.109302 -0.877035 -0.121115 0 0 0 0.00281905 l
+-0.329713 0.046071 -0.327894 0.0450649 0 0 0 0.00281905 l
+-0.911211 0.15122 -0.906518 0.161012 0 0 0 0.00281905 l
+-0.0489195 -0.676973 -0.0584359 -0.684781 0 0 0 0.00281905 l
+-0.0489195 -0.676973 -0.0410281 -0.671147 0 0 0 0.00281905 l
+0.264682 -0.704197 0.265768 -0.703515 0 0 0 0.00281905 l
+0.264682 -0.704197 0.256388 -0.700134 0 0 0 0.00281905 l
+0.376853 -0.505102 0.371997 -0.495545 0 0 0 0.00281905 l
+-0.196044 0.0774738 -0.191288 0.0943496 0 0 0 0.00281905 l
+-0.196044 0.0774738 -0.207693 0.0786816 0 0 0 0.00281905 l
+0.314536 -0.894312 0.313325 -0.895207 0 0 0 0.00281905 l
+-0.680496 -0.323855 -0.676882 -0.336371 0 0 0 0.00281905 l
+-0.680496 -0.323855 -0.673513 -0.320466 0 0 0 0.00281905 l
+-0.680496 -0.323855 -0.688805 -0.321425 0 0 0 0.00281905 l
+0.400955 0.703883 0.398457 0.717968 0 0 0 0.00281905 l
+0.400955 0.703883 0.405603 0.699613 0 0 0 0.00281905 l
+-0.078388 -0.673363 -0.0763677 -0.681176 0 0 0 0.00281905 l
+-0.078388 -0.673363 -0.0820827 -0.671559 0 0 0 0.00281905 l
+-0.46566 -0.263249 -0.464087 -0.261615 0 0 0 0.00281905 l
+-0.46566 -0.263249 -0.475386 -0.272768 0 0 0 0.00281905 l
+0.511461 0.372436 0.504802 0.386286 0 0 0 0.00281905 l
+0.0905404 -0.916858 0.0963817 -0.914892 0 0 0 0.00281905 l
+0.0905404 -0.916858 0.0867214 -0.927503 0 0 0 0.00281905 l
+0.703811 0.104289 0.702572 0.113352 0 0 0 0.00281905 l
+0.703811 0.104289 0.707249 0.0971727 0 0 0 0.00281905 l
+-0.428066 0.672781 -0.425917 0.671917 0 0 0 0.00281905 l
+-0.422024 0.850861 -0.438703 0.860624 0 0 0 0.00281905 l
+-0.422024 0.850861 -0.421177 0.848329 0 0 0 0.00281905 l
+-0.233299 0.431621 -0.233554 0.427082 0 0 0 0.00281905 l
+-0.233299 0.431621 -0.236983 0.434649 0 0 0 0.00281905 l
+0.845802 -0.374842 0.831295 -0.369322 0 0 0 0.00281905 l
+0.530753 0.755734 0.533496 0.760751 0 0 0 0.00281905 l
+0.530753 0.755734 0.529654 0.753657 0 0 0 0.00281905 l
+-0.21109 0.920662 -0.200413 0.907705 0 0 0 0.00281905 l
+-0.161095 -0.869227 -0.149135 -0.85928 0 0 0 0.00281905 l
+-0.161095 -0.869227 -0.170927 -0.865165 0 0 0 0.00281905 l
+-0.439399 0.173834 -0.424907 0.185375 0 0 0 0.00281905 l
+-0.439399 0.173834 -0.433666 0.166619 0 0 0 0.00281905 l
+0.201368 -0.522197 0.205965 -0.501941 0 0 0 0.00281905 l
+0.201368 -0.522197 0.183501 -0.525921 0 0 0 0.00281905 l
+-0.406681 0.237282 -0.394923 0.243734 0 0 0 0.00281905 l
+-0.406681 0.237282 -0.414869 0.238499 0 0 0 0.00281905 l
+0.690502 0.294355 0.693253 0.277258 0 0 0 0.00281905 l
+0.690502 0.294355 0.695778 0.299324 0 0 0 0.00281905 l
+0.690502 0.294355 0.672813 0.286904 0 0 0 0.00281905 l
+0.0811614 0.783952 0.07953 0.777347 0 0 0 0.00281905 l
+0.0811614 0.783952 0.0722856 0.784959 0 0 0 0.00281905 l
+0.0194388 -0.668179 0.0209686 -0.671304 0 0 0 0.00281905 l
+0.413871 -0.115406 0.415708 -0.12444 0 0 0 0.00281905 l
+0.413871 -0.115406 0.419064 -0.112711 0 0 0 0.00281905 l
+0.413871 -0.115406 0.393787 -0.115482 0 0 0 0.00281905 l
+-0.466824 -0.583267 -0.460558 -0.58352 0 0 0 0.00281905 l
+-0.466824 -0.583267 -0.480965 -0.594683 0 0 0 0.00281905 l
+-0.474069 0.557784 -0.46366 0.54114 0 0 0 0.00281905 l
+-0.474069 0.557784 -0.494089 0.543528 0 0 0 0.00281905 l
+-0.606897 0.276546 -0.606561 0.27321 0 0 0 0.00281905 l
+-0.606897 0.276546 -0.611648 0.279697 0 0 0 0.00281905 l
+0.652179 0.511229 0.662978 0.518548 0 0 0 0.00281905 l
+0.652179 0.511229 0.651015 0.524361 0 0 0 0.00281905 l
+0.652179 0.511229 0.640746 0.500613 0 0 0 0.00281905 l
+0.538235 -0.301711 0.547894 -0.286355 0 0 0 0.00281905 l
+0.538235 -0.301711 0.548279 -0.308336 0 0 0 0.00281905 l
+0.538235 -0.301711 0.52704 -0.315989 0 0 0 0.00281905 l
+0.538235 -0.301711 0.531481 -0.29751 0 0 0 0.00281905 l
+-0.0248214 -0.654944 -0.00993317 -0.657905 0 0 0 0.00281905 l
+-0.0248214 -0.654944 -0.0292952 -0.647671 0 0 0 0.00281905 l
+0.486221 -0.237789 0.485768 -0.231253 0 0 0 0.00281905 l
+0.486221 -0.237789 0.486842 -0.237993 0 0 0 0.00281905 l
+0.486221 -0.237789 0.482676 -0.24214 0 0 0 0.00281905 l
+0.485768 -0.231253 0.486221 -0.237789 0 0 0 0.00281905 l
+0.406614 -0.515963 0.399311 -0.515174 0 0 0 0.00281905 l
+0.729906 0.590029 0.727936 0.602873 0 0 0 0.00281905 l
+0.729906 0.590029 0.734283 0.590491 0 0 0 0.00281905 l
+0.304682 0.0049123 0.302631 0.012745 0 0 0 0.00281905 l
+0.304682 0.0049123 0.307258 0.00531227 0 0 0 0.00281905 l
+0.206273 -0.907022 0.220044 -0.904858 0 0 0 0.00281905 l
+0.206273 -0.907022 0.203748 -0.908961 0 0 0 0.00281905 l
+0.407131 0.3083 0.413846 0.306869 0 0 0 0.00281905 l
+0.407131 0.3083 0.400504 0.293362 0 0 0 0.00281905 l
+0.407131 0.3083 0.394003 0.309589 0 0 0 0.00281905 l
+-0.390089 0.37438 -0.380504 0.368938 0 0 0 0.00281905 l
+-0.390089 0.37438 -0.40371 0.383043 0 0 0 0.00281905 l
+0.611308 -0.240162 0.620675 -0.254471 0 0 0 0.00281905 l
+0.611308 -0.240162 0.615764 -0.224644 0 0 0 0.00281905 l
+0.46857 0.720025 0.456237 0.718632 0 0 0 0.00281905 l
+0.689006 0.633814 0.703983 0.637882 0 0 0 0.00281905 l
+0.689006 0.633814 0.66913 0.636835 0 0 0 0.00281905 l
+-0.645478 -0.444765 -0.64247 -0.456003 0 0 0 0.00281905 l
+-0.189934 0.898548 -0.187317 0.90413 0 0 0 0.00281905 l
+-0.189934 0.898548 -0.197096 0.896493 0 0 0 0.00281905 l
+-0.714133 0.336421 -0.71721 0.345414 0 0 0 0.00281905 l
+-0.714133 0.336421 -0.723371 0.331338 0 0 0 0.00281905 l
+-0.185899 0.346299 -0.181226 0.357034 0 0 0 0.00281905 l
+-0.185899 0.346299 -0.168049 0.341518 0 0 0 0.00281905 l
+-0.185899 0.346299 -0.197276 0.336981 0 0 0 0.00281905 l
+-0.614658 -0.595104 -0.607822 -0.605823 0 0 0 0.00281905 l
+-0.614658 -0.595104 -0.602783 -0.583116 0 0 0 0.00281905 l
+-0.614658 -0.595104 -0.625565 -0.600683 0 0 0 0.00281905 l
+-0.278779 -0.158186 -0.269215 -0.145084 0 0 0 0.00281905 l
+0.664129 0.478442 0.666031 0.475121 0 0 0 0.00281905 l
+0.664129 0.478442 0.659141 0.482139 0 0 0 0.00281905 l
+0.272089 0.567396 0.274923 0.580393 0 0 0 0.00281905 l
+0.272089 0.567396 0.276287 0.566636 0 0 0 0.00281905 l
+0.272089 0.567396 0.263962 0.562144 0 0 0 0.00281905 l
+0.00425097 -0.900307 -0.0042643 -0.889499 0 0 0 0.00281905 l
+0.00425097 -0.900307 0.00219534 -0.910376 0 0 0 0.00281905 l
+0.100671 0.191628 0.102942 0.177668 0 0 0 0.00281905 l
+0.100671 0.191628 0.11638 0.192806 0 0 0 0.00281905 l
+-0.925903 -0.313 -0.926619 -0.307435 0 0 0 0.00281905 l
+-0.925903 -0.313 -0.912569 -0.313717 0 0 0 0.00281905 l
+-0.925903 -0.313 -0.9335 -0.314844 0 0 0 0.00281905 l
+0.013018 0.625936 0.013098 0.629567 0 0 0 0.00281905 l
+0.013018 0.625936 0.00361648 0.625054 0 0 0 0.00281905 l
+0.228666 -0.951708 0.235447 -0.963628 0 0 0 0.00281905 l
+0.228666 -0.951708 0.211318 -0.959537 0 0 0 0.00281905 l
+0.228666 -0.951708 0.229043 -0.950286 0 0 0 0.00281905 l
+0.0297304 -0.135978 0.0296244 -0.128165 0 0 0 0.00281905 l
+0.0297304 -0.135978 0.041199 -0.153382 0 0 0 0.00281905 l
+0.0297304 -0.135978 0.0169159 -0.142595 0 0 0 0.00281905 l
+0.386066 0.127808 0.390101 0.123344 0 0 0 0.00281905 l
+0.386066 0.127808 0.383568 0.125205 0 0 0 0.00281905 l
+0.756201 -0.231063 0.759108 -0.211572 0 0 0 0.00281905 l
+0.756201 -0.231063 0.772144 -0.235277 0 0 0 0.00281905 l
+0.756201 -0.231063 0.743399 -0.237981 0 0 0 0.00281905 l
+-0.410389 0.283303 -0.404415 0.286519 0 0 0 0.00281905 l
+-0.410389 0.283303 -0.422712 0.291837 0 0 0 0.00281905 l
+-0.180525 0.687648 -0.173724 0.699641 0 0 0 0.00281905 l
+-0.514934 -0.501016 -0.50619 -0.50291 0 0 0 0.00281905 l
+-0.514934 -0.501016 -0.512958 -0.49666 0 0 0 0.00281905 l
+0.0868846 -0.609052 0.0834857 -0.590893 0 0 0 0.00281905 l
+0.0868846 -0.609052 0.0981172 -0.61339 0 0 0 0.00281905 l
+-0.207803 -0.446474 -0.217841 -0.432883 0 0 0 0.00281905 l
+0.138477 0.240926 0.129657 0.227663 0 0 0 0.00281905 l
+0.138477 0.240926 0.153815 0.242217 0 0 0 0.00281905 l
+-0.0987245 0.51536 -0.101502 0.50785 0 0 0 0.00281905 l
+0.812346 0.313288 0.812715 0.333723 0 0 0 0.00281905 l
+0.812346 0.313288 0.807991 0.312194 0 0 0 0.00281905 l
+0.829221 -0.255279 0.816188 -0.243864 0 0 0 0.00281905 l
+0.21521 -0.201049 0.201712 -0.190242 0 0 0 0.00281905 l
+0.520666 0.239799 0.518657 0.232429 0 0 0 0.00281905 l
+0.520666 0.239799 0.528499 0.248535 0 0 0 0.00281905 l
+0.520666 0.239799 0.513806 0.240297 0 0 0 0.00281905 l
+0.246955 0.345503 0.24998 0.345634 0 0 0 0.00281905 l
+-0.216222 0.904024 -0.200413 0.907705 0 0 0 0.00281905 l
+-0.216222 0.904024 -0.217455 0.902435 0 0 0 0.00281905 l
+0.35625 -0.922687 0.363465 -0.928574 0 0 0 0.00281905 l
+0.35625 -0.922687 0.354474 -0.921469 0 0 0 0.00281905 l
+0.499631 -0.0203278 0.49338 -0.0123837 0 0 0 0.00281905 l
+0.499631 -0.0203278 0.496382 -0.0258005 0 0 0 0.00281905 l
+-0.416736 0.210163 -0.400205 0.205982 0 0 0 0.00281905 l
+-0.416736 0.210163 -0.416655 0.201279 0 0 0 0.00281905 l
+-0.416736 0.210163 -0.430225 0.213961 0 0 0 0.00281905 l
+0.459833 0.110293 0.455712 0.0989044 0 0 0 0.00281905 l
+-0.788413 0.138742 -0.802534 0.120231 0 0 0 0.00281905 l
+-0.788413 0.138742 -0.794919 0.146842 0 0 0 0.00281905 l
+0.736871 0.0210706 0.75031 0.0151408 0 0 0 0.00281905 l
+0.736871 0.0210706 0.72696 0.0193843 0 0 0 0.00281905 l
+0.778454 0.551683 0.77587 0.554475 0 0 0 0.00281905 l
+-0.506963 0.184236 -0.500563 0.179967 0 0 0 0.00281905 l
+-0.506963 0.184236 -0.523493 0.188651 0 0 0 0.00281905 l
+-0.729552 -0.646194 -0.732255 -0.630928 0 0 0 0.00281905 l
+-0.729552 -0.646194 -0.727197 -0.652705 0 0 0 0.00281905 l
+0.363465 -0.928574 0.378889 -0.921906 0 0 0 0.00281905 l
+0.363465 -0.928574 0.35625 -0.922687 0 0 0 0.00281905 l
+0.195562 -0.859029 0.200998 -0.863349 0 0 0 0.00281905 l
+0.195562 -0.859029 0.193884 -0.861234 0 0 0 0.00281905 l
+0.914124 0.356067 0.924533 0.355242 0 0 0 0.00281905 l
+0.914124 0.356067 0.899545 0.354165 0 0 0 0.00281905 l
+-0.413164 0.171756 -0.424907 0.185375 0 0 0 0.00281905 l
+-0.231458 -0.3115 -0.223265 -0.306723 0 0 0 0.00281905 l
+-0.95111 0.262859 -0.941997 0.26991 0 0 0 0.00281905 l
+-0.95111 0.262859 -0.959125 0.271435 0 0 0 0.00281905 l
+-0.840233 -0.302678 -0.835377 -0.281141 0 0 0 0.00281905 l
+-0.840233 -0.302678 -0.834802 -0.306252 0 0 0 0.00281905 l
+-0.391729 0.787748 -0.380304 0.788404 0 0 0 0.00281905 l
+-0.391729 0.787748 -0.392111 0.788327 0 0 0 0.00281905 l
+0.0761444 0.232648 0.0746854 0.220278 0 0 0 0.00281905 l
+0.0761444 0.232648 0.0744193 0.238931 0 0 0 0.00281905 l
+0.40822 -0.0346204 0.413889 -0.0313196 0 0 0 0.00281905 l
+0.40822 -0.0346204 0.400747 -0.033372 0 0 0 0.00281905 l
+0.837642 0.228156 0.838247 0.236831 0 0 0 0.00281905 l
+0.837642 0.228156 0.82949 0.231415 0 0 0 0.00281905 l
+-0.104369 -0.205854 -0.0861925 -0.210421 0 0 0 0.00281905 l
+-0.104369 -0.205854 -0.101912 -0.197872 0 0 0 0.00281905 l
+-0.63603 -0.556591 -0.634637 -0.560724 0 0 0 0.00281905 l
+-0.948799 -0.0760186 -0.938911 -0.0659163 0 0 0 0.00281905 l
+-0.948799 -0.0760186 -0.947983 -0.0873574 0 0 0 0.00281905 l
+-0.948799 -0.0760186 -0.961954 -0.0711963 0 0 0 0.00281905 l
+-0.211695 -0.872174 -0.215572 -0.88459 0 0 0 0.00281905 l
+-0.211695 -0.872174 -0.20154 -0.868496 0 0 0 0.00281905 l
+-0.796564 0.596856 -0.782457 0.595787 0 0 0 0.00281905 l
+-0.796564 0.596856 -0.805019 0.591439 0 0 0 0.00281905 l
+-0.55359 0.609783 -0.548872 0.620259 0 0 0 0.00281905 l
+-0.55359 0.609783 -0.552383 0.599322 0 0 0 0.00281905 l
+-0.215101 -0.321994 -0.201991 -0.334177 0 0 0 0.00281905 l
+-0.215101 -0.321994 -0.223265 -0.306723 0 0 0 0.00281905 l
+0.217154 -0.288137 0.225058 -0.299026 0 0 0 0.00281905 l
+0.217154 -0.288137 0.20098 -0.276787 0 0 0 0.00281905 l
+0.626885 -0.636392 0.628552 -0.625134 0 0 0 0.00281905 l
+0.626885 -0.636392 0.636954 -0.648631 0 0 0 0.00281905 l
+0.626885 -0.636392 0.612343 -0.633265 0 0 0 0.00281905 l
+0.766365 -0.543123 0.77145 -0.544199 0 0 0 0.00281905 l
+0.766365 -0.543123 0.764574 -0.557277 0 0 0 0.00281905 l
+0.701836 0.390655 0.71279 0.39022 0 0 0 0.00281905 l
+0.701836 0.390655 0.688265 0.402207 0 0 0 0.00281905 l
+-0.234757 -0.684903 -0.242914 -0.678739 0 0 0 0.00281905 l
+-0.337262 0.101963 -0.336658 0.117928 0 0 0 0.00281905 l
+-0.337262 0.101963 -0.328594 0.0880137 0 0 0 0.00281905 l
+-0.337262 0.101963 -0.342582 0.102433 0 0 0 0.00281905 l
+-0.21528 0.357488 -0.224217 0.362874 0 0 0 0.00281905 l
+-0.21528 0.357488 -0.209467 0.350006 0 0 0 0.00281905 l
+-0.538686 0.770699 -0.518697 0.777387 0 0 0 0.00281905 l
+-0.538686 0.770699 -0.54037 0.765047 0 0 0 0.00281905 l
+0.764545 0.50187 0.767425 0.514169 0 0 0 0.00281905 l
+0.764545 0.50187 0.753179 0.495628 0 0 0 0.00281905 l
+-0.445927 -0.838244 -0.437203 -0.844036 0 0 0 0.00281905 l
+-0.445927 -0.838244 -0.448888 -0.829842 0 0 0 0.00281905 l
+0.691927 -0.52702 0.696806 -0.525368 0 0 0 0.00281905 l
+0.691927 -0.52702 0.687533 -0.540981 0 0 0 0.00281905 l
+-0.411067 0.857224 -0.408976 0.847803 0 0 0 0.00281905 l
+-0.411067 0.857224 -0.398773 0.860037 0 0 0 0.00281905 l
+-0.411067 0.857224 -0.414765 0.86798 0 0 0 0.00281905 l
+0.187962 -0.696126 0.196638 -0.693142 0 0 0 0.00281905 l
+-0.887786 -0.365061 -0.87753 -0.359045 0 0 0 0.00281905 l
+-0.786839 0.35449 -0.776007 0.356523 0 0 0 0.00281905 l
+-0.786839 0.35449 -0.797912 0.353186 0 0 0 0.00281905 l
+0.129657 0.227663 0.127032 0.209825 0 0 0 0.00281905 l
+0.129657 0.227663 0.138477 0.240926 0 0 0 0.00281905 l
+0.129657 0.227663 0.128163 0.228462 0 0 0 0.00281905 l
+-0.446122 0.876254 -0.438703 0.860624 0 0 0 0.00281905 l
+-0.464691 -0.643728 -0.461833 -0.638415 0 0 0 0.00281905 l
+-0.464691 -0.643728 -0.458992 -0.649726 0 0 0 0.00281905 l
+0.390793 -0.486306 0.392037 -0.474552 0 0 0 0.00281905 l
+0.390793 -0.486306 0.379474 -0.483721 0 0 0 0.00281905 l
+0.758726 0.172771 0.767893 0.161121 0 0 0 0.00281905 l
+0.758726 0.172771 0.751678 0.172211 0 0 0 0.00281905 l
+0.140982 0.517044 0.134447 0.525127 0 0 0 0.00281905 l
+0.140982 0.517044 0.130399 0.513418 0 0 0 0.00281905 l
+-0.355678 -0.786606 -0.363737 -0.770325 0 0 0 0.00281905 l
+-0.355678 -0.786606 -0.35685 -0.788066 0 0 0 0.00281905 l
+0.293281 -0.0148111 0.286919 -0.000591498 0 0 0 0.00281905 l
+0.293281 -0.0148111 0.303046 -0.0269853 0 0 0 0.00281905 l
+-0.929986 -0.299649 -0.926619 -0.307435 0 0 0 0.00281905 l
+-0.929986 -0.299649 -0.940393 -0.288881 0 0 0 0.00281905 l
+0.802764 -0.438565 0.809348 -0.423396 0 0 0 0.00281905 l
+0.802764 -0.438565 0.811891 -0.447673 0 0 0 0.00281905 l
+-0.526145 -0.8385 -0.535415 -0.824434 0 0 0 0.00281905 l
+-0.0934927 -0.223776 -0.0861925 -0.210421 0 0 0 0.00281905 l
+-0.0934927 -0.223776 -0.108647 -0.235515 0 0 0 0.00281905 l
+-0.610198 -0.39078 -0.60746 -0.383819 0 0 0 0.00281905 l
+-0.610198 -0.39078 -0.592351 -0.398914 0 0 0 0.00281905 l
+-0.610198 -0.39078 -0.611532 -0.390778 0 0 0 0.00281905 l
+0.724341 0.48561 0.71724 0.468448 0 0 0 0.00281905 l
+0.724341 0.48561 0.731488 0.494844 0 0 0 0.00281905 l
+0.189318 0.217251 0.194479 0.220464 0 0 0 0.00281905 l
+-0.177976 -0.729517 -0.186841 -0.749415 0 0 0 0.00281905 l
+-0.177976 -0.729517 -0.197738 -0.723959 0 0 0 0.00281905 l
+-0.374543 0.392668 -0.37329 0.383362 0 0 0 0.00281905 l
+-0.374543 0.392668 -0.364811 0.405046 0 0 0 0.00281905 l
+-0.374543 0.392668 -0.381141 0.397538 0 0 0 0.00281905 l
+0.783686 0.0952758 0.800094 0.101442 0 0 0 0.00281905 l
+0.783686 0.0952758 0.765169 0.0958805 0 0 0 0.00281905 l
+0.0958719 0.0968936 0.106575 0.0811952 0 0 0 0.00281905 l
+0.0958719 0.0968936 0.105633 0.104423 0 0 0 0.00281905 l
+-0.482092 -0.680818 -0.463132 -0.690768 0 0 0 0.00281905 l
+-0.482092 -0.680818 -0.493855 -0.687542 0 0 0 0.00281905 l
+-0.482092 -0.680818 -0.487453 -0.661976 0 0 0 0.00281905 l
+0.434481 0.143755 0.436423 0.1496 0 0 0 0.00281905 l
+0.434481 0.143755 0.425833 0.145117 0 0 0 0.00281905 l
+-0.0499802 0.779065 -0.0441432 0.780852 0 0 0 0.00281905 l
+-0.0499802 0.779065 -0.0595936 0.780041 0 0 0 0.00281905 l
+0.263132 0.124343 0.262403 0.138648 0 0 0 0.00281905 l
+0.263132 0.124343 0.25505 0.119646 0 0 0 0.00281905 l
+0.127032 0.209825 0.129657 0.227663 0 0 0 0.00281905 l
+0.127032 0.209825 0.118551 0.203455 0 0 0 0.00281905 l
+-0.0865835 0.000396928 -0.0827732 -0.00881832 0 0 0 0.00281905 l
+-0.0865835 0.000396928 -0.0803243 0.00181404 0 0 0 0.00281905 l
+0.140216 0.453177 0.133713 0.471947 0 0 0 0.00281905 l
+0.140216 0.453177 0.138038 0.450211 0 0 0 0.00281905 l
+0.192654 -0.713142 0.204618 -0.71277 0 0 0 0.00281905 l
+0.192654 -0.713142 0.18006 -0.713056 0 0 0 0.00281905 l
+-0.274738 0.214206 -0.286404 0.211189 0 0 0 0.00281905 l
+-0.79091 0.0824744 -0.778927 0.0803473 0 0 0 0.00281905 l
+-0.79091 0.0824744 -0.798803 0.0566113 0 0 0 0.00281905 l
+-0.79091 0.0824744 -0.783105 0.0946519 0 0 0 0.00281905 l
+-0.79091 0.0824744 -0.81286 0.0877904 0 0 0 0.00281905 l
+-0.0814608 -0.387172 -0.0825705 -0.405971 0 0 0 0.00281905 l
+-0.0814608 -0.387172 -0.0773543 -0.383147 0 0 0 0.00281905 l
+-0.209153 0.630903 -0.204529 0.633706 0 0 0 0.00281905 l
+-0.209153 0.630903 -0.21947 0.64598 0 0 0 0.00281905 l
+0.300079 -0.282404 0.298834 -0.274908 0 0 0 0.00281905 l
+0.300079 -0.282404 0.310131 -0.286867 0 0 0 0.00281905 l
+0.300079 -0.282404 0.29348 -0.294104 0 0 0 0.00281905 l
+0.494487 -0.598377 0.499573 -0.60715 0 0 0 0.00281905 l
+0.494487 -0.598377 0.481329 -0.598714 0 0 0 0.00281905 l
+-0.454904 0.232475 -0.451385 0.246788 0 0 0 0.00281905 l
+-0.454904 0.232475 -0.453276 0.228675 0 0 0 0.00281905 l
+-0.454904 0.232475 -0.46323 0.235681 0 0 0 0.00281905 l
+-0.80285 -0.521799 -0.814561 -0.499468 0 0 0 0.00281905 l
+-0.80285 -0.521799 -0.8076 -0.529078 0 0 0 0.00281905 l
+-0.023462 0.365896 -0.0099758 0.355066 0 0 0 0.00281905 l
+-0.023462 0.365896 -0.0242019 0.369427 0 0 0 0.00281905 l
+-0.424907 0.185375 -0.413164 0.171756 0 0 0 0.00281905 l
+-0.424907 0.185375 -0.416655 0.201279 0 0 0 0.00281905 l
+-0.424907 0.185375 -0.439399 0.173834 0 0 0 0.00281905 l
+-0.332196 -0.486093 -0.314565 -0.486341 0 0 0 0.00281905 l
+-0.332196 -0.486093 -0.323848 -0.506562 0 0 0 0.00281905 l
+-0.332196 -0.486093 -0.341193 -0.481314 0 0 0 0.00281905 l
+-0.0410281 -0.671147 -0.0481163 -0.653014 0 0 0 0.00281905 l
+-0.0410281 -0.671147 -0.0398061 -0.672967 0 0 0 0.00281905 l
+-0.0410281 -0.671147 -0.0489195 -0.676973 0 0 0 0.00281905 l
+-0.733753 -0.51974 -0.719105 -0.515868 0 0 0 0.00281905 l
+-0.733753 -0.51974 -0.752244 -0.509145 0 0 0 0.00281905 l
+0.427405 -0.0578001 0.42895 -0.046238 0 0 0 0.00281905 l
+0.427405 -0.0578001 0.418581 -0.0533448 0 0 0 0.00281905 l
+0.465762 -0.814646 0.465745 -0.809853 0 0 0 0.00281905 l
+0.564353 -0.265134 0.553963 -0.269853 0 0 0 0.00281905 l
+-0.254477 -0.582653 -0.254132 -0.595057 0 0 0 0.00281905 l
+-0.254477 -0.582653 -0.234754 -0.573227 0 0 0 0.00281905 l
+-0.254477 -0.582653 -0.270828 -0.581995 0 0 0 0.00281905 l
+-0.587831 0.346798 -0.586558 0.351725 0 0 0 0.00281905 l
+-0.322736 -0.361179 -0.315018 -0.360102 0 0 0 0.00281905 l
+-0.322736 -0.361179 -0.334105 -0.374717 0 0 0 0.00281905 l
+-0.322736 -0.361179 -0.340089 -0.35063 0 0 0 0.00281905 l
+0.610185 0.108837 0.613139 0.107505 0 0 0 0.00281905 l
+0.610185 0.108837 0.602365 0.0965569 0 0 0 0.00281905 l
+0.405828 -0.619173 0.412018 -0.61421 0 0 0 0.00281905 l
+0.405828 -0.619173 0.409552 -0.626324 0 0 0 0.00281905 l
+-0.153992 -0.198208 -0.150856 -0.188925 0 0 0 0.00281905 l
+-0.153992 -0.198208 -0.165193 -0.204005 0 0 0 0.00281905 l
+0.159206 0.337621 0.158317 0.335432 0 0 0 0.00281905 l
+0.159206 0.337621 0.155286 0.33951 0 0 0 0.00281905 l
+-0.179725 0.361433 -0.17523 0.360729 0 0 0 0.00281905 l
+-0.179725 0.361433 -0.181226 0.357034 0 0 0 0.00281905 l
+-0.179725 0.361433 -0.189472 0.36352 0 0 0 0.00281905 l
+-0.640677 0.269013 -0.640238 0.261852 0 0 0 0.00281905 l
+-0.640677 0.269013 -0.636371 0.272648 0 0 0 0.00281905 l
+-0.35997 -0.519059 -0.345626 -0.514551 0 0 0 0.00281905 l
+-0.35997 -0.519059 -0.366808 -0.517668 0 0 0 0.00281905 l
+-0.132623 -0.247644 -0.121438 -0.249671 0 0 0 0.00281905 l
+-0.132623 -0.247644 -0.132413 -0.256717 0 0 0 0.00281905 l
+-0.132623 -0.247644 -0.134062 -0.242775 0 0 0 0.00281905 l
+0.0259219 0.333931 0.0311067 0.333075 0 0 0 0.00281905 l
+0.0259219 0.333931 0.0132111 0.33875 0 0 0 0.00281905 l
+0.23212 0.694975 0.243997 0.688842 0 0 0 0.00281905 l
+-0.679056 -0.249337 -0.669978 -0.242851 0 0 0 0.00281905 l
+-0.679056 -0.249337 -0.671474 -0.257572 0 0 0 0.00281905 l
+0.0728983 0.84125 0.0757658 0.837646 0 0 0 0.00281905 l
+0.0728983 0.84125 0.0671764 0.841412 0 0 0 0.00281905 l
+-0.607449 -0.320658 -0.603358 -0.335057 0 0 0 0.00281905 l
+-0.607449 -0.320658 -0.608271 -0.303339 0 0 0 0.00281905 l
+-0.607449 -0.320658 -0.620394 -0.31908 0 0 0 0.00281905 l
+0.46332 -0.773569 0.463393 -0.771715 0 0 0 0.00281905 l
+0.46332 -0.773569 0.465672 -0.777935 0 0 0 0.00281905 l
+0.157982 0.143075 0.152219 0.149709 0 0 0 0.00281905 l
+0.0779409 0.627487 0.0776234 0.623132 0 0 0 0.00281905 l
+0.0779409 0.627487 0.0860512 0.632615 0 0 0 0.00281905 l
+0.409129 -0.360644 0.407407 -0.351146 0 0 0 0.00281905 l
+0.409129 -0.360644 0.393478 -0.364069 0 0 0 0.00281905 l
+0.330579 -0.823376 0.338135 -0.818073 0 0 0 0.00281905 l
+0.330579 -0.823376 0.319296 -0.821459 0 0 0 0.00281905 l
+0.525126 0.347219 0.530775 0.335462 0 0 0 0.00281905 l
+0.525126 0.347219 0.517552 0.349638 0 0 0 0.00281905 l
+0.246504 0.704912 0.264493 0.713747 0 0 0 0.00281905 l
+0.246504 0.704912 0.243997 0.688842 0 0 0 0.00281905 l
+-0.758312 -0.477691 -0.746483 -0.466165 0 0 0 0.00281905 l
+-0.3834 0.50305 -0.371659 0.499413 0 0 0 0.00281905 l
+-0.942199 0.272833 -0.941154 0.282361 0 0 0 0.00281905 l
+-0.942199 0.272833 -0.941997 0.26991 0 0 0 0.00281905 l
+0.279404 -0.0458935 0.289252 -0.0410934 0 0 0 0.00281905 l
+0.279404 -0.0458935 0.289179 -0.0560628 0 0 0 0.00281905 l
+0.279404 -0.0458935 0.269575 -0.0440042 0 0 0 0.00281905 l
+0.44287 0.861957 0.443484 0.851936 0 0 0 0.00281905 l
+0.44287 0.861957 0.448512 0.872929 0 0 0 0.00281905 l
+-0.567876 -0.793593 -0.551107 -0.805855 0 0 0 0.00281905 l
+-0.567876 -0.793593 -0.574672 -0.818349 0 0 0 0.00281905 l
+-0.567876 -0.793593 -0.582977 -0.788475 0 0 0 0.00281905 l
+0.0260746 -0.998488 0.0280003 -0.993834 0 0 0 0.00281905 l
+-0.138929 0.302653 -0.137454 0.291331 0 0 0 0.00281905 l
+-0.138929 0.302653 -0.126637 0.315117 0 0 0 0.00281905 l
+-0.336802 -0.317362 -0.336308 -0.32636 0 0 0 0.00281905 l
+-0.336802 -0.317362 -0.3333 -0.300746 0 0 0 0.00281905 l
+0.547924 -0.778083 0.569329 -0.776701 0 0 0 0.00281905 l
+0.547924 -0.778083 0.543017 -0.784547 0 0 0 0.00281905 l
+-0.55556 -0.198653 -0.549737 -0.182691 0 0 0 0.00281905 l
+-0.55556 -0.198653 -0.555066 -0.201816 0 0 0 0.00281905 l
+-0.462837 -0.702149 -0.463132 -0.690768 0 0 0 0.00281905 l
+-0.462837 -0.702149 -0.473648 -0.706399 0 0 0 0.00281905 l
+-0.497415 0.848694 -0.497582 0.844561 0 0 0 0.00281905 l
+-0.497415 0.848694 -0.503707 0.850237 0 0 0 0.00281905 l
+0.463393 -0.771715 0.46332 -0.773569 0 0 0 0.00281905 l
+0.463393 -0.771715 0.472804 -0.767584 0 0 0 0.00281905 l
+0.463393 -0.771715 0.449493 -0.760352 0 0 0 0.00281905 l
+-0.63888 -0.718126 -0.623555 -0.710551 0 0 0 0.00281905 l
+-0.63888 -0.718126 -0.645524 -0.718283 0 0 0 0.00281905 l
+-0.778698 -0.429777 -0.783027 -0.420782 0 0 0 0.00281905 l
+-0.856304 -0.460442 -0.838153 -0.465883 0 0 0 0.00281905 l
+0.192607 -0.979646 0.186992 -0.966804 0 0 0 0.00281905 l
+0.633455 -0.755312 0.636645 -0.754293 0 0 0 0.00281905 l
+0.633455 -0.755312 0.613215 -0.758791 0 0 0 0.00281905 l
+0.159504 -0.722235 0.172141 -0.727241 0 0 0 0.00281905 l
+0.159504 -0.722235 0.157154 -0.716511 0 0 0 0.00281905 l
+0.669991 -0.280551 0.670805 -0.2851 0 0 0 0.00281905 l
+0.669991 -0.280551 0.666459 -0.260524 0 0 0 0.00281905 l
+-0.43427 -0.567725 -0.43689 -0.574383 0 0 0 0.00281905 l
+-0.43427 -0.567725 -0.44234 -0.563801 0 0 0 0.00281905 l
+0.359862 -0.44813 0.360225 -0.434812 0 0 0 0.00281905 l
+0.359862 -0.44813 0.367429 -0.446403 0 0 0 0.00281905 l
+0.359862 -0.44813 0.352631 -0.454052 0 0 0 0.00281905 l
+-0.375783 -0.865586 -0.369904 -0.865052 0 0 0 0.00281905 l
+-0.375783 -0.865586 -0.38198 -0.864002 0 0 0 0.00281905 l
+-0.53066 -0.818327 -0.543527 -0.810187 0 0 0 0.00281905 l
+-0.53066 -0.818327 -0.526954 -0.813868 0 0 0 0.00281905 l
+-0.53066 -0.818327 -0.535415 -0.824434 0 0 0 0.00281905 l
+0.40887 0.699345 0.412389 0.685282 0 0 0 0.00281905 l
+0.40887 0.699345 0.421521 0.709131 0 0 0 0.00281905 l
+0.40887 0.699345 0.405603 0.699613 0 0 0 0.00281905 l
+-0.598433 0.78984 -0.59918 0.798177 0 0 0 0.00281905 l
+-0.598433 0.78984 -0.592309 0.782161 0 0 0 0.00281905 l
+0.701034 -0.1978 0.71164 -0.198825 0 0 0 0.00281905 l
+0.701034 -0.1978 0.687327 -0.204701 0 0 0 0.00281905 l
+0.786555 -0.464225 0.78566 -0.476611 0 0 0 0.00281905 l
+0.786555 -0.464225 0.789381 -0.458025 0 0 0 0.00281905 l
+0.786555 -0.464225 0.766483 -0.463035 0 0 0 0.00281905 l
+0.235979 0.0300127 0.234619 0.0197603 0 0 0 0.00281905 l
+0.235979 0.0300127 0.240705 0.0346761 0 0 0 0.00281905 l
+0.235979 0.0300127 0.232145 0.0366373 0 0 0 0.00281905 l
+-0.416122 0.383675 -0.415126 0.382355 0 0 0 0.00281905 l
+0.670885 0.366732 0.674654 0.372148 0 0 0 0.00281905 l
+0.670885 0.366732 0.656864 0.36066 0 0 0 0.00281905 l
+0.579482 0.769433 0.58768 0.767835 0 0 0 0.00281905 l
+0.579482 0.769433 0.573998 0.767552 0 0 0 0.00281905 l
+-0.0554581 0.123654 -0.0443842 0.133992 0 0 0 0.00281905 l
+-0.0554581 0.123654 -0.0614377 0.121701 0 0 0 0.00281905 l
+0.2768 -0.732061 0.280147 -0.735182 0 0 0 0.00281905 l
+-0.323597 -0.850233 -0.32373 -0.856311 0 0 0 0.00281905 l
+-0.323597 -0.850233 -0.301323 -0.838225 0 0 0 0.00281905 l
+-0.929746 -0.151657 -0.928883 -0.152554 0 0 0 0.00281905 l
+-0.929746 -0.151657 -0.942832 -0.150165 0 0 0 0.00281905 l
+-0.205557 0.820863 -0.197607 0.828013 0 0 0 0.00281905 l
+-0.205557 0.820863 -0.213698 0.813302 0 0 0 0.00281905 l
+0.416404 -0.315134 0.414033 -0.323006 0 0 0 0.00281905 l
+0.416404 -0.315134 0.40394 -0.313381 0 0 0 0.00281905 l
+0.0260782 0.252738 0.0418622 0.237817 0 0 0 0.00281905 l
+0.0260782 0.252738 0.0114489 0.255154 0 0 0 0.00281905 l
+0.592433 -0.0532781 0.580161 -0.064904 0 0 0 0.00281905 l
+0.0310535 0.900366 0.0443188 0.896231 0 0 0 0.00281905 l
+0.0310535 0.900366 0.0179357 0.899116 0 0 0 0.00281905 l
+-0.466107 0.290364 -0.473127 0.272209 0 0 0 0.00281905 l
+-0.466107 0.290364 -0.455299 0.30308 0 0 0 0.00281905 l
+-0.176139 0.52653 -0.159142 0.506826 0 0 0 0.00281905 l
+-0.176139 0.52653 -0.159515 0.537419 0 0 0 0.00281905 l
+-0.240216 -0.743999 -0.243398 -0.73145 0 0 0 0.00281905 l
+-0.240216 -0.743999 -0.231297 -0.744985 0 0 0 0.00281905 l
+0.425833 0.145117 0.425596 0.15255 0 0 0 0.00281905 l
+0.425833 0.145117 0.434481 0.143755 0 0 0 0.00281905 l
+0.425833 0.145117 0.417256 0.147472 0 0 0 0.00281905 l
+-0.416139 -0.670006 -0.40063 -0.663096 0 0 0 0.00281905 l
+-0.416139 -0.670006 -0.419209 -0.669044 0 0 0 0.00281905 l
+0.861585 0.00371509 0.848544 -0.00604996 0 0 0 0.00281905 l
+-0.465504 0.857236 -0.446199 0.844963 0 0 0 0.00281905 l
+-0.465504 0.857236 -0.470451 0.844619 0 0 0 0.00281905 l
+-0.830142 0.318809 -0.83085 0.314394 0 0 0 0.00281905 l
+-0.830142 0.318809 -0.818165 0.323579 0 0 0 0.00281905 l
+-0.830142 0.318809 -0.838816 0.327991 0 0 0 0.00281905 l
+-0.29496 0.343348 -0.302069 0.32797 0 0 0 0.00281905 l
+-0.29496 0.343348 -0.303117 0.362094 0 0 0 0.00281905 l
+-0.0857093 -0.791865 -0.0939756 -0.791091 0 0 0 0.00281905 l
+0.735655 0.383164 0.737303 0.380624 0 0 0 0.00281905 l
+0.904161 0.0448206 0.902306 0.0522079 0 0 0 0.00281905 l
+0.904161 0.0448206 0.904646 0.0320615 0 0 0 0.00281905 l
+-0.314565 -0.486341 -0.332196 -0.486093 0 0 0 0.00281905 l
+-0.29563 0.387552 -0.290866 0.400554 0 0 0 0.00281905 l
+-0.29563 0.387552 -0.296303 0.367325 0 0 0 0.00281905 l
+-0.29563 0.387552 -0.312852 0.40084 0 0 0 0.00281905 l
+0.361284 0.159923 0.372812 0.159692 0 0 0 0.00281905 l
+0.361284 0.159923 0.35303 0.162167 0 0 0 0.00281905 l
+-0.405921 0.771293 -0.412015 0.760059 0 0 0 0.00281905 l
+0.774844 -0.00520352 0.787786 -0.0186319 0 0 0 0.00281905 l
+0.774844 -0.00520352 0.75759 -0.00719115 0 0 0 0.00281905 l
+0.337385 -0.83835 0.335338 -0.857753 0 0 0 0.00281905 l
+0.337385 -0.83835 0.321841 -0.835669 0 0 0 0.00281905 l
+0.618108 -0.769053 0.608459 -0.774204 0 0 0 0.00281905 l
+0.618108 -0.769053 0.613215 -0.758791 0 0 0 0.00281905 l
+-0.370245 -0.881833 -0.367083 -0.887482 0 0 0 0.00281905 l
+-0.370245 -0.881833 -0.375557 -0.887456 0 0 0 0.00281905 l
+0.631204 0.700176 0.64137 0.692715 0 0 0 0.00281905 l
+0.631204 0.700176 0.6241 0.701227 0 0 0 0.00281905 l
+-0.384783 -0.78149 -0.391777 -0.781627 0 0 0 0.00281905 l
+0.721324 0.171566 0.728812 0.175593 0 0 0 0.00281905 l
+0.721324 0.171566 0.715416 0.172852 0 0 0 0.00281905 l
+0.39534 0.812216 0.417154 0.81735 0 0 0 0.00281905 l
+0.39534 0.812216 0.385491 0.815361 0 0 0 0.00281905 l
+-0.479277 0.0306757 -0.472835 0.0365135 0 0 0 0.00281905 l
+-0.479277 0.0306757 -0.480578 0.02679 0 0 0 0.00281905 l
+0.136678 -0.618677 0.138675 -0.611083 0 0 0 0.00281905 l
+0.136678 -0.618677 0.14729 -0.617873 0 0 0 0.00281905 l
+0.136678 -0.618677 0.131622 -0.622737 0 0 0 0.00281905 l
+0.499032 -0.533761 0.50567 -0.550386 0 0 0 0.00281905 l
+0.499032 -0.533761 0.497834 -0.52737 0 0 0 0.00281905 l
+0.499032 -0.533761 0.506083 -0.530574 0 0 0 0.00281905 l
+0.499032 -0.533761 0.491561 -0.53256 0 0 0 0.00281905 l
+-0.676882 -0.336371 -0.680496 -0.323855 0 0 0 0.00281905 l
+-0.8076 -0.529078 -0.803296 -0.531398 0 0 0 0.00281905 l
+-0.8076 -0.529078 -0.80285 -0.521799 0 0 0 0.00281905 l
+-0.678277 -0.592325 -0.6645 -0.606877 0 0 0 0.00281905 l
+-0.678277 -0.592325 -0.678578 -0.589335 0 0 0 0.00281905 l
+-0.678277 -0.592325 -0.683133 -0.595352 0 0 0 0.00281905 l
+0.511709 -0.125709 0.521828 -0.132636 0 0 0 0.00281905 l
+0.511709 -0.125709 0.518254 -0.112899 0 0 0 0.00281905 l
+0.511709 -0.125709 0.507178 -0.132945 0 0 0 0.00281905 l
+0.671778 0.126821 0.686413 0.13244 0 0 0 0.00281905 l
+0.671778 0.126821 0.655366 0.115633 0 0 0 0.00281905 l
+0.46915 -0.339966 0.463098 -0.32421 0 0 0 0.00281905 l
+0.46915 -0.339966 0.475199 -0.349387 0 0 0 0.00281905 l
+-0.674189 0.281518 -0.66926 0.27026 0 0 0 0.00281905 l
+-0.674189 0.281518 -0.669259 0.285991 0 0 0 0.00281905 l
+-0.674189 0.281518 -0.690216 0.277887 0 0 0 0.00281905 l
+-0.249852 -0.27934 -0.243824 -0.279169 0 0 0 0.00281905 l
+-0.249852 -0.27934 -0.25749 -0.283666 0 0 0 0.00281905 l
+0.576371 0.602917 0.587345 0.601078 0 0 0 0.00281905 l
+0.576371 0.602917 0.565714 0.599313 0 0 0 0.00281905 l
+0.86453 0.184655 0.870001 0.200194 0 0 0 0.00281905 l
+0.86453 0.184655 0.862521 0.176256 0 0 0 0.00281905 l
+-0.449571 -0.069077 -0.440459 -0.0670604 0 0 0 0.00281905 l
+-0.449571 -0.069077 -0.456939 -0.0659617 0 0 0 0.00281905 l
+0.543998 0.604238 0.554567 0.598977 0 0 0 0.00281905 l
+0.543998 0.604238 0.530183 0.614006 0 0 0 0.00281905 l
+0.341819 0.872936 0.330056 0.867083 0 0 0 0.00281905 l
+0.976975 -0.199873 0.968601 -0.194581 0 0 0 0.00281905 l
+0.323403 0.468251 0.30327 0.463279 0 0 0 0.00281905 l
+-0.675656 -0.458076 -0.677852 -0.447071 0 0 0 0.00281905 l
+-0.675656 -0.458076 -0.691406 -0.464207 0 0 0 0.00281905 l
+-0.409843 0.0917576 -0.395484 0.0887438 0 0 0 0.00281905 l
+-0.409843 0.0917576 -0.412373 0.0777009 0 0 0 0.00281905 l
+-0.409843 0.0917576 -0.418941 0.0978936 0 0 0 0.00281905 l
+0.734915 -0.477128 0.746468 -0.465922 0 0 0 0.00281905 l
+0.734915 -0.477128 0.741401 -0.484237 0 0 0 0.00281905 l
+0.734915 -0.477128 0.726093 -0.473646 0 0 0 0.00281905 l
+0.145121 0.725514 0.151503 0.725332 0 0 0 0.00281905 l
+0.145121 0.725514 0.146575 0.708966 0 0 0 0.00281905 l
+0.145121 0.725514 0.142775 0.727129 0 0 0 0.00281905 l
+-0.436099 0.412507 -0.429034 0.416299 0 0 0 0.00281905 l
+-0.436099 0.412507 -0.448952 0.405021 0 0 0 0.00281905 l
+-0.717656 0.573317 -0.705015 0.578656 0 0 0 0.00281905 l
+-0.717656 0.573317 -0.707089 0.5613 0 0 0 0.00281905 l
+0.400865 0.377707 0.40124 0.38329 0 0 0 0.00281905 l
+0.400865 0.377707 0.405862 0.376434 0 0 0 0.00281905 l
+0.400865 0.377707 0.397497 0.376167 0 0 0 0.00281905 l
+-0.174954 -0.471335 -0.174319 -0.462372 0 0 0 0.00281905 l
+-0.174954 -0.471335 -0.193443 -0.477016 0 0 0 0.00281905 l
+-0.0750595 0.335374 -0.0714618 0.337184 0 0 0 0.00281905 l
+-0.0750595 0.335374 -0.0865326 0.331707 0 0 0 0.00281905 l
+-0.41818 0.733769 -0.41801 0.734096 0 0 0 0.00281905 l
+-0.41818 0.733769 -0.425582 0.721772 0 0 0 0.00281905 l
+-0.159352 0.972004 -0.154907 0.972644 0 0 0 0.00281905 l
+-0.159352 0.972004 -0.168691 0.969757 0 0 0 0.00281905 l
+-0.318459 0.233084 -0.314879 0.251368 0 0 0 0.00281905 l
+-0.318459 0.233084 -0.303606 0.232468 0 0 0 0.00281905 l
+-0.286284 0.235084 -0.270134 0.245492 0 0 0 0.00281905 l
+-0.286284 0.235084 -0.287869 0.229922 0 0 0 0.00281905 l
+-0.286284 0.235084 -0.289992 0.252677 0 0 0 0.00281905 l
+-0.00902538 0.743185 0.000549871 0.748572 0 0 0 0.00281905 l
+-0.188857 0.633777 -0.183047 0.626915 0 0 0 0.00281905 l
+-0.188857 0.633777 -0.194774 0.638666 0 0 0 0.00281905 l
+-0.0442657 -0.510682 -0.0345044 -0.510134 0 0 0 0.00281905 l
+-0.0442657 -0.510682 -0.046732 -0.51134 0 0 0 0.00281905 l
+0.205965 -0.501941 0.201368 -0.522197 0 0 0 0.00281905 l
+0.205965 -0.501941 0.219533 -0.49787 0 0 0 0.00281905 l
+0.205965 -0.501941 0.198352 -0.493075 0 0 0 0.00281905 l
+0.15877 -0.782437 0.154218 -0.770312 0 0 0 0.00281905 l
+0.15877 -0.782437 0.14672 -0.7905 0 0 0 0.00281905 l
+-0.512238 -0.273175 -0.511125 -0.279054 0 0 0 0.00281905 l
+-0.512238 -0.273175 -0.511532 -0.260289 0 0 0 0.00281905 l
+-0.512238 -0.273175 -0.515718 -0.274828 0 0 0 0.00281905 l
+0.265718 0.536611 0.266757 0.541485 0 0 0 0.00281905 l
+0.17334 0.730685 0.176019 0.747925 0 0 0 0.00281905 l
+0.17334 0.730685 0.18512 0.732618 0 0 0 0.00281905 l
+0.17334 0.730685 0.158898 0.735325 0 0 0 0.00281905 l
+-0.957476 -0.00905659 -0.959543 0.000243254 0 0 0 0.00281905 l
+-0.957476 -0.00905659 -0.963998 -0.0237917 0 0 0 0.00281905 l
+0.214993 -0.16831 0.22159 -0.177689 0 0 0 0.00281905 l
+0.214993 -0.16831 0.228827 -0.163963 0 0 0 0.00281905 l
+0.214993 -0.16831 0.208647 -0.153415 0 0 0 0.00281905 l
+0.214993 -0.16831 0.208899 -0.173192 0 0 0 0.00281905 l
+-0.296925 -0.621286 -0.296225 -0.616802 0 0 0 0.00281905 l
+0.405862 0.376434 0.417965 0.387219 0 0 0 0.00281905 l
+0.405862 0.376434 0.400865 0.377707 0 0 0 0.00281905 l
+-0.746692 -0.205664 -0.733913 -0.201048 0 0 0 0.00281905 l
+-0.746692 -0.205664 -0.74723 -0.205892 0 0 0 0.00281905 l
+0.288773 0.579193 0.300092 0.572821 0 0 0 0.00281905 l
+0.288773 0.579193 0.274923 0.580393 0 0 0 0.00281905 l
+-0.0129921 -0.885685 -0.0165022 -0.872368 0 0 0 0.00281905 l
+-0.0129921 -0.885685 -0.0124874 -0.893705 0 0 0 0.00281905 l
+-0.682052 0.149011 -0.67852 0.130741 0 0 0 0.00281905 l
+0.161886 0.194542 0.162275 0.203506 0 0 0 0.00281905 l
+0.161886 0.194542 0.173389 0.180649 0 0 0 0.00281905 l
+0.161886 0.194542 0.150715 0.192188 0 0 0 0.00281905 l
+-0.17541 0.976407 -0.168691 0.969757 0 0 0 0.00281905 l
+-0.17541 0.976407 -0.186783 0.962533 0 0 0 0.00281905 l
+0.613215 -0.758791 0.633455 -0.755312 0 0 0 0.00281905 l
+0.613215 -0.758791 0.618108 -0.769053 0 0 0 0.00281905 l
+0.511754 0.0567113 0.502249 0.0650232 0 0 0 0.00281905 l
+-0.41951 0.248616 -0.420375 0.256325 0 0 0 0.00281905 l
+-0.41951 0.248616 -0.414869 0.238499 0 0 0 0.00281905 l
+-0.652512 0.0724993 -0.634662 0.0649219 0 0 0 0.00281905 l
+-0.652512 0.0724993 -0.651998 0.0536243 0 0 0 0.00281905 l
+-0.652512 0.0724993 -0.662675 0.0858618 0 0 0 0.00281905 l
+-0.652512 0.0724993 -0.668873 0.0660646 0 0 0 0.00281905 l
+0.276287 0.566636 0.282609 0.558838 0 0 0 0.00281905 l
+0.276287 0.566636 0.272089 0.567396 0 0 0 0.00281905 l
+0.920207 -0.185771 0.936804 -0.188756 0 0 0 0.00281905 l
+0.195921 0.628426 0.197223 0.628567 0 0 0 0.00281905 l
+-0.323512 -0.421395 -0.329312 -0.411843 0 0 0 0.00281905 l
+-0.323512 -0.421395 -0.325877 -0.424008 0 0 0 0.00281905 l
+-0.0486792 0.934977 -0.0360401 0.95645 0 0 0 0.00281905 l
+0.812715 0.333723 0.812346 0.313288 0 0 0 0.00281905 l
+0.812715 0.333723 0.825328 0.334405 0 0 0 0.00281905 l
+0.498697 -0.798856 0.490211 -0.812176 0 0 0 0.00281905 l
+0.498697 -0.798856 0.485724 -0.794402 0 0 0 0.00281905 l
+-0.444569 -0.818909 -0.444528 -0.829001 0 0 0 0.00281905 l
+-0.444569 -0.818909 -0.443086 -0.814079 0 0 0 0.00281905 l
+-0.444569 -0.818909 -0.454125 -0.817719 0 0 0 0.00281905 l
+-0.523005 -0.111177 -0.50939 -0.117221 0 0 0 0.00281905 l
+-0.523005 -0.111177 -0.529485 -0.0976464 0 0 0 0.00281905 l
+-0.140829 0.820803 -0.124624 0.817791 0 0 0 0.00281905 l
+-0.140829 0.820803 -0.144673 0.816523 0 0 0 0.00281905 l
+-0.172394 -0.981374 -0.155791 -0.981737 0 0 0 0.00281905 l
+-0.172394 -0.981374 -0.182237 -0.976054 0 0 0 0.00281905 l
+0.372214 -0.755705 0.368136 -0.775439 0 0 0 0.00281905 l
+0.372214 -0.755705 0.35872 -0.745973 0 0 0 0.00281905 l
+-0.617435 -0.671242 -0.617366 -0.664786 0 0 0 0.00281905 l
+-0.617435 -0.671242 -0.611407 -0.685756 0 0 0 0.00281905 l
+-0.617435 -0.671242 -0.637126 -0.67808 0 0 0 0.00281905 l
+0.388542 0.496189 0.396502 0.514992 0 0 0 0.00281905 l
+0.388542 0.496189 0.391223 0.493045 0 0 0 0.00281905 l
+0.388542 0.496189 0.379537 0.50121 0 0 0 0.00281905 l
+-0.602783 -0.583116 -0.592807 -0.593134 0 0 0 0.00281905 l
+-0.602783 -0.583116 -0.614658 -0.595104 0 0 0 0.00281905 l
+-0.602783 -0.583116 -0.604945 -0.580979 0 0 0 0.00281905 l
+-0.211846 -0.616792 -0.208472 -0.619402 0 0 0 0.00281905 l
+-0.211846 -0.616792 -0.231363 -0.611435 0 0 0 0.00281905 l
+-0.0212333 -0.851024 -0.0169125 -0.844514 0 0 0 0.00281905 l
+-0.0212333 -0.851024 -0.0166758 -0.856668 0 0 0 0.00281905 l
+0.0716402 0.747798 0.0740701 0.762218 0 0 0 0.00281905 l
+0.0716402 0.747798 0.0777288 0.746287 0 0 0 0.00281905 l
+-0.175121 -0.704277 -0.160281 -0.705928 0 0 0 0.00281905 l
+-0.175121 -0.704277 -0.186377 -0.697726 0 0 0 0.00281905 l
+-0.860238 -0.23352 -0.852891 -0.229667 0 0 0 0.00281905 l
+-0.860238 -0.23352 -0.870285 -0.244031 0 0 0 0.00281905 l
+-0.23903 -0.84309 -0.230167 -0.823515 0 0 0 0.00281905 l
+-0.23903 -0.84309 -0.236188 -0.845777 0 0 0 0.00281905 l
+-0.0178294 -0.0103801 -0.0189583 -0.0261561 0 0 0 0.00281905 l
+-0.0178294 -0.0103801 -0.0165989 -0.00781046 0 0 0 0.00281905 l
+0.294832 -0.818299 0.294839 -0.814145 0 0 0 0.00281905 l
+0.294832 -0.818299 0.307385 -0.827747 0 0 0 0.00281905 l
+0.355767 -0.0920342 0.357471 -0.0910324 0 0 0 0.00281905 l
+0.355767 -0.0920342 0.345161 -0.0875764 0 0 0 0.00281905 l
+-0.939512 0.214265 -0.948622 0.211428 0 0 0 0.00281905 l
+0.180986 0.0161231 0.167618 0.0176222 0 0 0 0.00281905 l
+-0.747448 -0.613847 -0.730765 -0.611932 0 0 0 0.00281905 l
+-0.747448 -0.613847 -0.753516 -0.602405 0 0 0 0.00281905 l
+-0.318258 0.384071 -0.312852 0.40084 0 0 0 0.00281905 l
+-0.318258 0.384071 -0.327603 0.390484 0 0 0 0.00281905 l
+0.538697 0.780587 0.548126 0.788447 0 0 0 0.00281905 l
+0.538697 0.780587 0.532383 0.784706 0 0 0 0.00281905 l
+0.148354 -0.809648 0.145373 -0.795503 0 0 0 0.00281905 l
+0.148354 -0.809648 0.151267 -0.812703 0 0 0 0.00281905 l
+0.148354 -0.809648 0.140723 -0.814096 0 0 0 0.00281905 l
+-0.952389 0.0570659 -0.934335 0.0400148 0 0 0 0.00281905 l
+-0.952389 0.0570659 -0.942476 0.0641372 0 0 0 0.00281905 l
+-0.952389 0.0570659 -0.969187 0.0641001 0 0 0 0.00281905 l
+0.35872 -0.745973 0.372214 -0.755705 0 0 0 0.00281905 l
+0.35872 -0.745973 0.36732 -0.735841 0 0 0 0.00281905 l
+-0.175458 -0.657824 -0.172322 -0.645625 0 0 0 0.00281905 l
+-0.175458 -0.657824 -0.165211 -0.656169 0 0 0 0.00281905 l
+-0.175458 -0.657824 -0.184919 -0.656242 0 0 0 0.00281905 l
+0.298209 0.773204 0.303308 0.771061 0 0 0 0.00281905 l
+0.298209 0.773204 0.29691 0.76423 0 0 0 0.00281905 l
+0.298209 0.773204 0.286502 0.779093 0 0 0 0.00281905 l
+0.31349 0.852219 0.312997 0.85912 0 0 0 0.00281905 l
+0.31349 0.852219 0.323835 0.84685 0 0 0 0.00281905 l
+0.31349 0.852219 0.303971 0.85099 0 0 0 0.00281905 l
+0.0445242 0.452478 0.0426121 0.438404 0 0 0 0.00281905 l
+0.0445242 0.452478 0.0317882 0.450422 0 0 0 0.00281905 l
+-0.300281 -0.334504 -0.290468 -0.346537 0 0 0 0.00281905 l
+-0.300281 -0.334504 -0.306303 -0.334627 0 0 0 0.00281905 l
+0.852882 0.0231235 0.851114 0.0335093 0 0 0 0.00281905 l
+0.258052 0.0768818 0.265404 0.0947701 0 0 0 0.00281905 l
+0.834697 0.319221 0.833249 0.321357 0 0 0 0.00281905 l
+0.350886 -0.72482 0.364991 -0.71375 0 0 0 0.00281905 l
+0.350886 -0.72482 0.342135 -0.715778 0 0 0 0.00281905 l
+0.411891 0.273496 0.413889 0.257699 0 0 0 0.00281905 l
+0.411891 0.273496 0.415311 0.28007 0 0 0 0.00281905 l
+0.411891 0.273496 0.409105 0.273777 0 0 0 0.00281905 l
+-0.513361 0.610013 -0.510155 0.605464 0 0 0 0.00281905 l
+-0.513361 0.610013 -0.516433 0.609629 0 0 0 0.00281905 l
+-0.0481163 -0.653014 -0.0410281 -0.671147 0 0 0 0.00281905 l
+-0.0481163 -0.653014 -0.0671254 -0.643726 0 0 0 0.00281905 l
+-0.710506 -0.295983 -0.718877 -0.300972 0 0 0 0.00281905 l
+-0.453983 -0.220396 -0.457775 -0.227992 0 0 0 0.00281905 l
+-0.453983 -0.220396 -0.454281 -0.212226 0 0 0 0.00281905 l
+0.393478 -0.364069 0.409129 -0.360644 0 0 0 0.00281905 l
+0.393478 -0.364069 0.390928 -0.3771 0 0 0 0.00281905 l
+0.393478 -0.364069 0.38075 -0.357633 0 0 0 0.00281905 l
+-0.419004 -0.611027 -0.417586 -0.607838 0 0 0 0.00281905 l
+-0.419004 -0.611027 -0.428617 -0.61074 0 0 0 0.00281905 l
+-0.886908 0.330936 -0.873852 0.340371 0 0 0 0.00281905 l
+-0.886908 0.330936 -0.890016 0.325201 0 0 0 0.00281905 l
+-0.312852 0.40084 -0.29563 0.387552 0 0 0 0.00281905 l
+-0.312852 0.40084 -0.318258 0.384071 0 0 0 0.00281905 l
+-0.312852 0.40084 -0.322111 0.415716 0 0 0 0.00281905 l
+0.51156 0.0173723 0.511528 0.0264356 0 0 0 0.00281905 l
+0.51156 0.0173723 0.515762 0.0177656 0 0 0 0.00281905 l
+0.51156 0.0173723 0.512347 0.0116944 0 0 0 0.00281905 l
+0.51156 0.0173723 0.497186 0.0200434 0 0 0 0.00281905 l
+-0.240903 0.921702 -0.23976 0.937734 0 0 0 0.00281905 l
+-0.240903 0.921702 -0.243749 0.908572 0 0 0 0.00281905 l
+0.201712 -0.190242 0.21521 -0.201049 0 0 0 0.00281905 l
+0.201712 -0.190242 0.208899 -0.173192 0 0 0 0.00281905 l
+0.201712 -0.190242 0.196177 -0.205125 0 0 0 0.00281905 l
+0.694226 -0.592659 0.706113 -0.614325 0 0 0 0.00281905 l
+0.694226 -0.592659 0.686379 -0.599059 0 0 0 0.00281905 l
+-0.0960864 -0.676841 -0.0962162 -0.693002 0 0 0 0.00281905 l
+-0.0960864 -0.676841 -0.0894777 -0.669489 0 0 0 0.00281905 l
+-0.0960864 -0.676841 -0.109815 -0.671747 0 0 0 0.00281905 l
+0.170373 -0.685805 0.165113 -0.67199 0 0 0 0.00281905 l
+0.170373 -0.685805 0.162467 -0.693333 0 0 0 0.00281905 l
+-0.488352 -0.79521 -0.482099 -0.798337 0 0 0 0.00281905 l
+-0.488352 -0.79521 -0.492222 -0.794062 0 0 0 0.00281905 l
+0.114175 -0.417613 0.124012 -0.424301 0 0 0 0.00281905 l
+0.114175 -0.417613 0.113204 -0.417105 0 0 0 0.00281905 l
+-0.123125 0.87351 -0.116534 0.868642 0 0 0 0.00281905 l
+-0.123125 0.87351 -0.137084 0.875066 0 0 0 0.00281905 l
+0.525241 -0.15037 0.529609 -0.147317 0 0 0 0.00281905 l
+-0.49281 0.648633 -0.492694 0.645639 0 0 0 0.00281905 l
+-0.49281 0.648633 -0.487535 0.657567 0 0 0 0.00281905 l
+0.219533 -0.49787 0.216003 -0.490486 0 0 0 0.00281905 l
+0.219533 -0.49787 0.225041 -0.504888 0 0 0 0.00281905 l
+0.219533 -0.49787 0.205965 -0.501941 0 0 0 0.00281905 l
+-0.796417 0.377074 -0.789243 0.37904 0 0 0 0.00281905 l
+-0.536139 0.552827 -0.533869 0.559109 0 0 0 0.00281905 l
+-0.536139 0.552827 -0.53043 0.547367 0 0 0 0.00281905 l
+-0.536139 0.552827 -0.540642 0.5492 0 0 0 0.00281905 l
+0.778193 -0.241115 0.7771 -0.255417 0 0 0 0.00281905 l
+0.778193 -0.241115 0.772144 -0.235277 0 0 0 0.00281905 l
+-0.369939 0.598466 -0.377706 0.59345 0 0 0 0.00281905 l
+-0.0300682 0.991597 -0.0178889 0.985 0 0 0 0.00281905 l
+-0.0300682 0.991597 -0.0344007 0.973191 0 0 0 0.00281905 l
+-0.0300682 0.991597 -0.0469107 0.993439 0 0 0 0.00281905 l
+-0.604974 0.554154 -0.595312 0.548189 0 0 0 0.00281905 l
+-0.604974 0.554154 -0.609816 0.553596 0 0 0 0.00281905 l
+-0.920398 -0.330468 -0.914743 -0.331412 0 0 0 0.00281905 l
+-0.920398 -0.330468 -0.91995 -0.338815 0 0 0 0.00281905 l
+0.525038 0.295428 0.540054 0.29944 0 0 0 0.00281905 l
+0.525038 0.295428 0.524222 0.294513 0 0 0 0.00281905 l
+-0.770354 -0.231486 -0.779532 -0.24478 0 0 0 0.00281905 l
+-0.770354 -0.231486 -0.751991 -0.228181 0 0 0 0.00281905 l
+0.437982 -0.0121583 0.437347 -0.0183985 0 0 0 0.00281905 l
+0.437982 -0.0121583 0.453036 -0.00807106 0 0 0 0.00281905 l
+0.437982 -0.0121583 0.435286 -0.0109673 0 0 0 0.00281905 l
+-0.170927 -0.865165 -0.161095 -0.869227 0 0 0 0.00281905 l
+-0.170927 -0.865165 -0.174424 -0.882171 0 0 0 0.00281905 l
+0.74326 0.256704 0.744515 0.249288 0 0 0 0.00281905 l
+0.74326 0.256704 0.744644 0.262738 0 0 0 0.00281905 l
+0.426317 0.537675 0.428405 0.53851 0 0 0 0.00281905 l
+0.426317 0.537675 0.420509 0.537894 0 0 0 0.00281905 l
+-0.4977 -0.349606 -0.489254 -0.354504 0 0 0 0.00281905 l
+-0.4977 -0.349606 -0.500613 -0.360754 0 0 0 0.00281905 l
+-0.4977 -0.349606 -0.51001 -0.344541 0 0 0 0.00281905 l
+-0.426112 0.459472 -0.419935 0.456869 0 0 0 0.00281905 l
+-0.426112 0.459472 -0.430739 0.460578 0 0 0 0.00281905 l
+-0.552534 0.726928 -0.560918 0.746387 0 0 0 0.00281905 l
+-0.552534 0.726928 -0.56409 0.708192 0 0 0 0.00281905 l
+0.286172 0.379342 0.280153 0.357591 0 0 0 0.00281905 l
+0.286172 0.379342 0.286925 0.389536 0 0 0 0.00281905 l
+-0.584484 -0.464525 -0.578543 -0.467186 0 0 0 0.00281905 l
+-0.584484 -0.464525 -0.592869 -0.471337 0 0 0 0.00281905 l
+0.487644 0.0918372 0.495587 0.0888765 0 0 0 0.00281905 l
+0.487644 0.0918372 0.489847 0.0982795 0 0 0 0.00281905 l
+0.0342286 -0.446214 0.0419855 -0.448373 0 0 0 0.00281905 l
+0.0342286 -0.446214 0.0281375 -0.437151 0 0 0 0.00281905 l
+-0.632648 0.206142 -0.619875 0.198513 0 0 0 0.00281905 l
+-0.632648 0.206142 -0.626166 0.214998 0 0 0 0.00281905 l
+-0.632648 0.206142 -0.643202 0.195593 0 0 0 0.00281905 l
+0.487641 -0.50238 0.48701 -0.514374 0 0 0 0.00281905 l
+0.487641 -0.50238 0.484096 -0.498597 0 0 0 0.00281905 l
+0.795263 -0.330564 0.800526 -0.329972 0 0 0 0.00281905 l
+0.795263 -0.330564 0.792297 -0.34196 0 0 0 0.00281905 l
+0.795263 -0.330564 0.784185 -0.319614 0 0 0 0.00281905 l
+0.864387 -0.173663 0.871446 -0.174197 0 0 0 0.00281905 l
+0.26828 -0.0431997 0.269575 -0.0440042 0 0 0 0.00281905 l
+-0.869859 -0.361154 -0.867518 -0.380522 0 0 0 0.00281905 l
+-0.869859 -0.361154 -0.874931 -0.360026 0 0 0 0.00281905 l
+-0.850534 -0.17631 -0.845401 -0.173382 0 0 0 0.00281905 l
+-0.850534 -0.17631 -0.854611 -0.184633 0 0 0 0.00281905 l
+-0.129235 -0.68322 -0.121641 -0.683611 0 0 0 0.00281905 l
+-0.129235 -0.68322 -0.127922 -0.700776 0 0 0 0.00281905 l
+-0.129235 -0.68322 -0.13721 -0.673133 0 0 0 0.00281905 l
+-0.129235 -0.68322 -0.141942 -0.687422 0 0 0 0.00281905 l
+-0.432749 0.893366 -0.420234 0.904953 0 0 0 0.00281905 l
+0.732942 -0.591039 0.737894 -0.589556 0 0 0 0.00281905 l
+0.00447014 0.295747 0.0102529 0.297858 0 0 0 0.00281905 l
+0.00447014 0.295747 -0.0100627 0.285587 0 0 0 0.00281905 l
+-0.586558 0.351725 -0.57715 0.350369 0 0 0 0.00281905 l
+-0.586558 0.351725 -0.587831 0.346798 0 0 0 0.00281905 l
+-0.586558 0.351725 -0.594434 0.353836 0 0 0 0.00281905 l
+0.816037 -0.505268 0.815392 -0.496865 0 0 0 0.00281905 l
+0.816037 -0.505268 0.834154 -0.509433 0 0 0 0.00281905 l
+-0.300916 -0.0348707 -0.286321 -0.0463104 0 0 0 0.00281905 l
+-0.300916 -0.0348707 -0.309744 -0.0378772 0 0 0 0.00281905 l
+0.175437 0.527711 0.172611 0.541617 0 0 0 0.00281905 l
+0.175437 0.527711 0.19411 0.521814 0 0 0 0.00281905 l
+0.175437 0.527711 0.166185 0.521681 0 0 0 0.00281905 l
+0.713185 -0.447193 0.71683 -0.451035 0 0 0 0.00281905 l
+0.713185 -0.447193 0.709487 -0.444744 0 0 0 0.00281905 l
+-0.0472505 0.00292533 -0.0544496 0.00872464 0 0 0 0.00281905 l
+-0.509305 0.452204 -0.512125 0.446648 0 0 0 0.00281905 l
+-0.509305 0.452204 -0.50986 0.456723 0 0 0 0.00281905 l
+-0.509305 0.452204 -0.494762 0.453668 0 0 0 0.00281905 l
+-0.656344 -0.248712 -0.669978 -0.242851 0 0 0 0.00281905 l
+0.179122 -0.969073 0.186992 -0.966804 0 0 0 0.00281905 l
+0.179122 -0.969073 0.168231 -0.962432 0 0 0 0.00281905 l
+0.453036 -0.00807106 0.437982 -0.0121583 0 0 0 0.00281905 l
+0.653521 0.656916 0.65422 0.661116 0 0 0 0.00281905 l
+0.653521 0.656916 0.661283 0.653904 0 0 0 0.00281905 l
+-0.0158993 0.452591 -0.0313276 0.468077 0 0 0 0.00281905 l
+-0.0158993 0.452591 -0.0127046 0.449114 0 0 0 0.00281905 l
+0.0150127 0.566974 0.00740765 0.566477 0 0 0 0.00281905 l
+-0.681561 0.665741 -0.657997 0.66921 0 0 0 0.00281905 l
+-0.681561 0.665741 -0.697551 0.653721 0 0 0 0.00281905 l
+-0.138862 0.860333 -0.137084 0.875066 0 0 0 0.00281905 l
+-0.138862 0.860333 -0.134641 0.855131 0 0 0 0.00281905 l
+0.721342 -0.306479 0.714817 -0.321722 0 0 0 0.00281905 l
+0.721342 -0.306479 0.732828 -0.302186 0 0 0 0.00281905 l
+-0.639116 0.451397 -0.634485 0.430165 0 0 0 0.00281905 l
+-0.639116 0.451397 -0.638583 0.465598 0 0 0 0.00281905 l
+-0.219317 0.139526 -0.224241 0.12919 0 0 0 0.00281905 l
+-0.219317 0.139526 -0.211865 0.147343 0 0 0 0.00281905 l
+0.250115 0.0297416 0.249946 0.0349665 0 0 0 0.00281905 l
+0.250115 0.0297416 0.247246 0.0284738 0 0 0 0.00281905 l
+-0.117226 -0.915239 -0.103724 -0.914929 0 0 0 0.00281905 l
+-0.117226 -0.915239 -0.120728 -0.908797 0 0 0 0.00281905 l
+-0.117226 -0.915239 -0.120081 -0.919621 0 0 0 0.00281905 l
+-0.561486 -0.0741459 -0.554198 -0.0564833 0 0 0 0.00281905 l
+-0.561486 -0.0741459 -0.5687 -0.0935616 0 0 0 0.00281905 l
+-0.478139 0.235726 -0.469679 0.237555 0 0 0 0.00281905 l
+-0.478139 0.235726 -0.487846 0.224646 0 0 0 0.00281905 l
+0.571265 -0.817467 0.584138 -0.804638 0 0 0 0.00281905 l
+0.571265 -0.817467 0.560634 -0.807125 0 0 0 0.00281905 l
+0.571265 -0.817467 0.567813 -0.823155 0 0 0 0.00281905 l
+0.881109 0.35713 0.88256 0.368883 0 0 0 0.00281905 l
+0.881109 0.35713 0.884472 0.354285 0 0 0 0.00281905 l
+0.881109 0.35713 0.876485 0.356104 0 0 0 0.00281905 l
+-0.168884 -0.366913 -0.166582 -0.353338 0 0 0 0.00281905 l
+-0.168884 -0.366913 -0.155672 -0.378808 0 0 0 0.00281905 l
+-0.168884 -0.366913 -0.184492 -0.363678 0 0 0 0.00281905 l
+0.409578 0.492415 0.420609 0.494587 0 0 0 0.00281905 l
+0.409578 0.492415 0.391223 0.493045 0 0 0 0.00281905 l
+-0.267296 0.133195 -0.248444 0.140185 0 0 0 0.00281905 l
+-0.267296 0.133195 -0.264621 0.127205 0 0 0 0.00281905 l
+0.234203 0.559019 0.239824 0.555415 0 0 0 0.00281905 l
+0.981781 -0.155444 0.980309 -0.161384 0 0 0 0.00281905 l
+0.981781 -0.155444 0.983043 -0.154139 0 0 0 0.00281905 l
+0.5181 0.21034 0.50948 0.209617 0 0 0 0.00281905 l
+0.355585 0.806148 0.355596 0.816879 0 0 0 0.00281905 l
+0.355585 0.806148 0.353419 0.803155 0 0 0 0.00281905 l
+-0.236174 -0.16674 -0.235673 -0.162976 0 0 0 0.00281905 l
+-0.236174 -0.16674 -0.23844 -0.173115 0 0 0 0.00281905 l
+0.291319 -0.405491 0.296479 -0.405795 0 0 0 0.00281905 l
+0.291319 -0.405491 0.280996 -0.412842 0 0 0 0.00281905 l
+0.398249 -0.187374 0.399399 -0.194367 0 0 0 0.00281905 l
+0.398249 -0.187374 0.398177 -0.173902 0 0 0 0.00281905 l
+0.398249 -0.187374 0.383165 -0.187575 0 0 0 0.00281905 l
+0.401122 -0.275663 0.400666 -0.275342 0 0 0 0.00281905 l
+-0.275831 0.841272 -0.267023 0.835398 0 0 0 0.00281905 l
+-0.275831 0.841272 -0.282038 0.845353 0 0 0 0.00281905 l
+-0.206937 0.51868 -0.214992 0.520323 0 0 0 0.00281905 l
+-0.328946 0.135076 -0.320403 0.137847 0 0 0 0.00281905 l
+-0.328946 0.135076 -0.332122 0.137755 0 0 0 0.00281905 l
+0.0858474 0.182462 0.0931468 0.173973 0 0 0 0.00281905 l
+0.0858474 0.182462 0.0715936 0.188876 0 0 0 0.00281905 l
+-0.208573 -0.647957 -0.202238 -0.63654 0 0 0 0.00281905 l
+-0.208573 -0.647957 -0.199851 -0.65383 0 0 0 0.00281905 l
+-0.208573 -0.647957 -0.209681 -0.648163 0 0 0 0.00281905 l
+-0.845333 0.527936 -0.843976 0.523075 0 0 0 0.00281905 l
+-0.764542 -0.116205 -0.76153 -0.114924 0 0 0 0.00281905 l
+-0.764542 -0.116205 -0.779251 -0.133185 0 0 0 0.00281905 l
+-0.0136998 0.864473 -0.00546681 0.853226 0 0 0 0.00281905 l
+-0.0136998 0.864473 -0.00882128 0.872963 0 0 0 0.00281905 l
+0.366186 0.838884 0.374748 0.828994 0 0 0 0.00281905 l
+0.366186 0.838884 0.35261 0.840797 0 0 0 0.00281905 l
+0.184813 0.706819 0.18318 0.69858 0 0 0 0.00281905 l
+0.184813 0.706819 0.197806 0.713923 0 0 0 0.00281905 l
+0.62031 0.695076 0.622368 0.686318 0 0 0 0.00281905 l
+0.62031 0.695076 0.6241 0.701227 0 0 0 0.00281905 l
+0.499758 0.00485662 0.503612 0.00190704 0 0 0 0.00281905 l
+0.237721 -0.227045 0.251124 -0.242378 0 0 0 0.00281905 l
+0.237721 -0.227045 0.243199 -0.217891 0 0 0 0.00281905 l
+-0.431849 -0.863055 -0.42977 -0.877337 0 0 0 0.00281905 l
+-0.431849 -0.863055 -0.439156 -0.848104 0 0 0 0.00281905 l
+0.0451443 0.294238 0.0423469 0.305498 0 0 0 0.00281905 l
+0.0451443 0.294238 0.0502007 0.287193 0 0 0 0.00281905 l
+-0.87579 -0.21098 -0.880928 -0.214931 0 0 0 0.00281905 l
+0.398519 -0.517217 0.399741 -0.536612 0 0 0 0.00281905 l
+0.398519 -0.517217 0.399311 -0.515174 0 0 0 0.00281905 l
+0.0414407 0.475033 0.0489667 0.474009 0 0 0 0.00281905 l
+0.0414407 0.475033 0.0239016 0.477041 0 0 0 0.00281905 l
+0.699856 -0.00523386 0.696773 -0.00134317 0 0 0 0.00281905 l
+0.699856 -0.00523386 0.696638 -0.00812394 0 0 0 0.00281905 l
+-0.718355 -0.692688 -0.697592 -0.685289 0 0 0 0.00281905 l
+-0.718355 -0.692688 -0.722619 -0.6836 0 0 0 0.00281905 l
+-0.0313276 0.468077 -0.0158993 0.452591 0 0 0 0.00281905 l
+0.0168384 -0.703194 0.026887 -0.700259 0 0 0 0.00281905 l
+0.0168384 -0.703194 0.010459 -0.699725 0 0 0 0.00281905 l
+0.170905 0.244406 0.178398 0.229837 0 0 0 0.00281905 l
+0.170905 0.244406 0.175865 0.249967 0 0 0 0.00281905 l
+0.170905 0.244406 0.160481 0.247179 0 0 0 0.00281905 l
+0.357471 -0.0910324 0.370927 -0.100477 0 0 0 0.00281905 l
+0.357471 -0.0910324 0.355767 -0.0920342 0 0 0 0.00281905 l
+-0.507112 -0.738336 -0.514247 -0.753812 0 0 0 0.00281905 l
+-0.507112 -0.738336 -0.500667 -0.735888 0 0 0 0.00281905 l
+0.710744 -0.274289 0.70289 -0.291814 0 0 0 0.00281905 l
+0.710744 -0.274289 0.704875 -0.253117 0 0 0 0.00281905 l
+0.710744 -0.274289 0.725653 -0.263959 0 0 0 0.00281905 l
+-0.462547 -0.3433 -0.452768 -0.330229 0 0 0 0.00281905 l
+-0.462547 -0.3433 -0.476571 -0.342684 0 0 0 0.00281905 l
+0.947116 0.309452 0.947893 0.316158 0 0 0 0.00281905 l
+0.947116 0.309452 0.942383 0.301691 0 0 0 0.00281905 l
+-0.397578 0.862035 -0.398773 0.860037 0 0 0 0.00281905 l
+0.171809 -0.502699 0.165484 -0.514362 0 0 0 0.00281905 l
+0.000946614 -0.165513 -0.00805386 -0.170471 0 0 0 0.00281905 l
+0.523183 -0.701531 0.517696 -0.6902 0 0 0 0.00281905 l
+0.523183 -0.701531 0.53529 -0.704376 0 0 0 0.00281905 l
+0.523183 -0.701531 0.52552 -0.713851 0 0 0 0.00281905 l
+0.0184842 -0.249749 0.0271997 -0.258809 0 0 0 0.00281905 l
+0.0184842 -0.249749 0.0219938 -0.232118 0 0 0 0.00281905 l
+0.744661 0.156336 0.752506 0.168586 0 0 0 0.00281905 l
+0.440782 0.271251 0.443774 0.260506 0 0 0 0.00281905 l
+0.440782 0.271251 0.459429 0.277492 0 0 0 0.00281905 l
+0.495979 -0.715204 0.500648 -0.70138 0 0 0 0.00281905 l
+0.495979 -0.715204 0.50791 -0.722794 0 0 0 0.00281905 l
+0.115106 0.93647 0.127978 0.930869 0 0 0 0.00281905 l
+0.115106 0.93647 0.108456 0.941648 0 0 0 0.00281905 l
+-0.265806 -0.108363 -0.266285 -0.104597 0 0 0 0.00281905 l
+-0.265806 -0.108363 -0.2671 -0.110215 0 0 0 0.00281905 l
+-0.416655 0.201279 -0.424907 0.185375 0 0 0 0.00281905 l
+-0.416655 0.201279 -0.416736 0.210163 0 0 0 0.00281905 l
+0.689488 -0.0872034 0.68313 -0.0896031 0 0 0 0.00281905 l
+0.554137 -0.656497 0.549349 -0.658081 0 0 0 0.00281905 l
+0.554137 -0.656497 0.554687 -0.655076 0 0 0 0.00281905 l
+-0.433849 0.550762 -0.435547 0.54589 0 0 0 0.00281905 l
+0.601651 -0.68348 0.60428 -0.671564 0 0 0 0.00281905 l
+0.601651 -0.68348 0.607404 -0.69953 0 0 0 0.00281905 l
+0.835501 -0.0188345 0.848 -0.010964 0 0 0 0.00281905 l
+0.835501 -0.0188345 0.839951 -0.025237 0 0 0 0.00281905 l
+0.835501 -0.0188345 0.829159 -0.0187002 0 0 0 0.00281905 l
+0.0319384 0.515609 0.0349781 0.517791 0 0 0 0.00281905 l
+0.0319384 0.515609 0.0256832 0.512626 0 0 0 0.00281905 l
+-0.74129 0.10342 -0.741436 0.107645 0 0 0 0.00281905 l
+-0.74129 0.10342 -0.752681 0.101229 0 0 0 0.00281905 l
+0.189989 0.968226 0.203703 0.977787 0 0 0 0.00281905 l
+-0.503707 0.850237 -0.497415 0.848694 0 0 0 0.00281905 l
+0.615764 -0.224644 0.611308 -0.240162 0 0 0 0.00281905 l
+0.615764 -0.224644 0.611341 -0.219099 0 0 0 0.00281905 l
+0.313471 0.11415 0.316353 0.106837 0 0 0 0.00281905 l
+0.313471 0.11415 0.320178 0.119231 0 0 0 0.00281905 l
+-0.453774 -0.294599 -0.455688 -0.29497 0 0 0 0.00281905 l
+0.198448 -0.830531 0.197163 -0.816542 0 0 0 0.00281905 l
+0.198448 -0.830531 0.203673 -0.82905 0 0 0 0.00281905 l
+0.198448 -0.830531 0.179786 -0.84089 0 0 0 0.00281905 l
+0.551623 0.501886 0.566212 0.490944 0 0 0 0.00281905 l
+0.551623 0.501886 0.537669 0.485628 0 0 0 0.00281905 l
+-0.444528 -0.829001 -0.444569 -0.818909 0 0 0 0.00281905 l
+-0.444528 -0.829001 -0.448888 -0.829842 0 0 0 0.00281905 l
+0.0271997 -0.258809 0.0184842 -0.249749 0 0 0 0.00281905 l
+0.0271997 -0.258809 0.0390585 -0.265315 0 0 0 0.00281905 l
+0.0271997 -0.258809 0.0209484 -0.265892 0 0 0 0.00281905 l
+0.0448701 0.0370715 0.0402859 0.0554464 0 0 0 0.00281905 l
+0.0448701 0.0370715 0.0526059 0.0210699 0 0 0 0.00281905 l
+0.0448701 0.0370715 0.0326995 0.0367904 0 0 0 0.00281905 l
+0.658426 0.699548 0.664553 0.696554 0 0 0 0.00281905 l
+0.658426 0.699548 0.64137 0.692715 0 0 0 0.00281905 l
+0.0423077 0.307247 0.0423469 0.305498 0 0 0 0.00281905 l
+0.0423077 0.307247 0.0323967 0.316593 0 0 0 0.00281905 l
+0.265404 0.0947701 0.258052 0.0768818 0 0 0 0.00281905 l
+0.265404 0.0947701 0.255564 0.113117 0 0 0 0.00281905 l
+0.800526 -0.329972 0.795263 -0.330564 0 0 0 0.00281905 l
+0.020818 -0.531706 0.0282344 -0.528635 0 0 0 0.00281905 l
+0.020818 -0.531706 0.0225929 -0.537784 0 0 0 0.00281905 l
+0.020818 -0.531706 0.0163499 -0.536184 0 0 0 0.00281905 l
+0.202967 -0.576562 0.201598 -0.588095 0 0 0 0.00281905 l
+-0.121914 0.809835 -0.124564 0.800847 0 0 0 0.00281905 l
+-0.121914 0.809835 -0.124624 0.817791 0 0 0 0.00281905 l
+0.664553 0.696554 0.672751 0.688111 0 0 0 0.00281905 l
+0.664553 0.696554 0.658426 0.699548 0 0 0 0.00281905 l
+0.160606 -0.801183 0.162478 -0.81296 0 0 0 0.00281905 l
+-0.359808 -0.357118 -0.340089 -0.35063 0 0 0 0.00281905 l
+-0.503469 -0.0307864 -0.498946 -0.0245071 0 0 0 0.00281905 l
+-0.503469 -0.0307864 -0.509276 -0.0330108 0 0 0 0.00281905 l
+-0.400065 0.897851 -0.410544 0.891817 0 0 0 0.00281905 l
+0.594812 -0.481815 0.602612 -0.473166 0 0 0 0.00281905 l
+0.594812 -0.481815 0.586064 -0.478355 0 0 0 0.00281905 l
+0.959013 0.00679028 0.954928 0.0216045 0 0 0 0.00281905 l
+0.959013 0.00679028 0.965689 0.0101854 0 0 0 0.00281905 l
+0.959013 0.00679028 0.949135 0.0061998 0 0 0 0.00281905 l
+0.662617 -0.550955 0.649469 -0.532547 0 0 0 0.00281905 l
+0.662617 -0.550955 0.661574 -0.557356 0 0 0 0.00281905 l
+-0.314054 0.640657 -0.299676 0.636399 0 0 0 0.00281905 l
+-0.314054 0.640657 -0.335392 0.638029 0 0 0 0.00281905 l
+-0.562156 -0.491196 -0.577132 -0.483894 0 0 0 0.00281905 l
+-0.562156 -0.491196 -0.569683 -0.500035 0 0 0 0.00281905 l
+0.908273 0.211592 0.901681 0.196523 0 0 0 0.00281905 l
+0.908273 0.211592 0.912829 0.215637 0 0 0 0.00281905 l
+-0.867436 0.292915 -0.851938 0.303416 0 0 0 0.00281905 l
+-0.867436 0.292915 -0.878127 0.292665 0 0 0 0.00281905 l
+0.440497 0.468303 0.439739 0.463384 0 0 0 0.00281905 l
+0.440497 0.468303 0.43761 0.470585 0 0 0 0.00281905 l
+-0.68958 0.623633 -0.694814 0.614002 0 0 0 0.00281905 l
+-0.68958 0.623633 -0.695532 0.629578 0 0 0 0.00281905 l
+0.236441 0.890676 0.239904 0.89836 0 0 0 0.00281905 l
+0.236441 0.890676 0.234652 0.882828 0 0 0 0.00281905 l
+-0.124509 0.551882 -0.110962 0.566268 0 0 0 0.00281905 l
+-0.124509 0.551882 -0.142378 0.541376 0 0 0 0.00281905 l
+0.422909 -0.462562 0.432164 -0.451936 0 0 0 0.00281905 l
+-0.13057 -0.590787 -0.114881 -0.600446 0 0 0 0.00281905 l
+-0.13057 -0.590787 -0.130867 -0.584762 0 0 0 0.00281905 l
+0.193461 0.755388 0.208282 0.764144 0 0 0 0.00281905 l
+0.193461 0.755388 0.176019 0.747925 0 0 0 0.00281905 l
+0.281094 0.866988 0.27486 0.876553 0 0 0 0.00281905 l
+0.281094 0.866988 0.272028 0.86479 0 0 0 0.00281905 l
+-0.222739 0.466137 -0.233425 0.453717 0 0 0 0.00281905 l
+-0.222739 0.466137 -0.223461 0.478037 0 0 0 0.00281905 l
+0.636645 -0.754293 0.639094 -0.75934 0 0 0 0.00281905 l
+0.636645 -0.754293 0.650099 -0.741363 0 0 0 0.00281905 l
+0.636645 -0.754293 0.633455 -0.755312 0 0 0 0.00281905 l
+-0.589766 0.715339 -0.596428 0.733788 0 0 0 0.00281905 l
+-0.589766 0.715339 -0.595225 0.70039 0 0 0 0.00281905 l
+0.201439 -0.547354 0.205715 -0.555007 0 0 0 0.00281905 l
+-0.686955 -0.66353 -0.686988 -0.668569 0 0 0 0.00281905 l
+-0.686955 -0.66353 -0.69285 -0.652463 0 0 0 0.00281905 l
+-0.348642 -0.795528 -0.34687 -0.806146 0 0 0 0.00281905 l
+-0.348642 -0.795528 -0.35685 -0.788066 0 0 0 0.00281905 l
+grestore
+grestore
+showpage
Index: doc/images/strongly_connected_components.eps
===================================================================
--- doc/images/strongly_connected_components.eps	(revision 1789)
+++ doc/images/strongly_connected_components.eps	(revision 1789)
@@ -0,0 +1,179 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Creator: LEMON, graphToEps()
+%%CreationDate: Fri Nov  4 13:47:12 2005
+%%BoundingBox: 0 0 596 842
+%%DocumentPaperSizes: a4
+%%EndComments
+/lb { setlinewidth setrgbcolor newpath moveto
+      4 2 roll 1 index 1 index curveto stroke } bind def
+/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def
+/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def
+/sq { newpath 2 index 1 index add 2 index 2 index add moveto
+      2 index 1 index sub 2 index 2 index add lineto
+      2 index 1 index sub 2 index 2 index sub lineto
+      2 index 1 index add 2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/di { newpath 2 index 1 index add 2 index moveto
+      2 index             2 index 2 index add lineto
+      2 index 1 index sub 2 index             lineto
+      2 index             2 index 2 index sub lineto
+      closepath pop pop pop} bind def
+/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill
+     setrgbcolor 1.1 div c fill
+   } bind def
+/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill
+     setrgbcolor 1.1 div sq fill
+   } bind def
+/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill
+     setrgbcolor 1.1 div di fill
+   } bind def
+/arrl 10 def
+/arrw 3 def
+/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def
+/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def
+       /w exch def /len exch def
+       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto
+       len w sub arrl sub dx dy lrl
+       arrw dy dx neg lrl
+       dx arrl w add mul dy w 2 div arrw add mul sub
+       dy arrl w add mul dx w 2 div arrw add mul add rlineto
+       dx arrl w add mul neg dy w 2 div arrw add mul sub
+       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto
+       arrw dy dx neg lrl
+       len w sub arrl sub neg dx dy lrl
+       closepath fill } bind def
+/cshow { 2 index 2 index moveto dup stringwidth pop
+         neg 2 div fosi .35 mul neg rmoveto show pop pop} def
+
+gsave
+77.1122 15 translate
+0.585745 dup scale
+90 rotate
+695.963 -397.916 translate
+%Edges:
+gsave
+2 setlinewidth 0 0 1 setrgbcolor newpath
+218.178 27.2723 moveto
+192.373 -40.1551 188.622 -49.9556 169.228 -100.631 curveto stroke
+newpath 164.939 -111.838 moveto 165.492 -99.2013 lineto 172.964 -102.061 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+44.8044 15.5841 moveto
+119.293 20.6059 129.775 21.3125 186.25 25.1199 curveto stroke
+newpath 198.223 25.927 moveto 186.519 21.1289 lineto 185.981 29.1108 lineto closepath fill
+2 setlinewidth 1 0 0 setrgbcolor newpath
+218.178 27.2723 moveto
+285.395 -87.4449 290.763 -96.6058 348.102 -194.464 curveto stroke
+newpath 354.169 -204.818 moveto 344.651 -196.487 lineto 351.554 -192.442 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+157.79 -130.517 moveto
+108.71 -67.0521 102.27 -58.7243 64.3804 -9.72954 curveto stroke
+newpath 57.0394 -0.236898 moveto 67.5446 -7.28254 lineto 61.2162 -12.1765 lineto closepath fill
+2 setlinewidth 1 0 0 setrgbcolor newpath
+-105.193 -261.035 moveto
+-35.6576 -132.801 -30.5923 -123.459 29.5506 -12.5464 curveto stroke
+newpath 35.2708 -1.99743 moveto 33.0669 -14.4531 lineto 26.0343 -10.6397 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-465.576 -42.8564 moveto
+-559.078 -25.5413 -569.47 -23.6169 -644.498 -9.72286 curveto stroke
+newpath -656.297 -7.5378 moveto -643.77 -5.78973 lineto -645.226 -13.656 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-574.666 -153.893 moveto
+-528.842 -107.252 -521.515 -99.794 -488.002 -65.683 curveto stroke
+newpath -479.592 -57.123 moveto -485.149 -68.4863 lineto -490.856 -62.8797 lineto closepath fill
+2 setlinewidth 1 0 0 setrgbcolor newpath
+-490.901 120.777 moveto
+-480.122 51.1328 -478.519 40.7713 -470.47 -11.2329 curveto stroke
+newpath -468.635 -23.0917 moveto -474.423 -11.8447 lineto -466.517 -10.6212 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-675.963 -3.89604 moveto
+-632.116 -68.8235 -626.228 -77.5422 -592.575 -127.374 curveto stroke
+newpath -585.859 -137.319 moveto -595.89 -129.612 lineto -589.26 -125.135 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-490.901 120.777 moveto
+-435.445 215.844 -430.107 224.995 -384.3 303.522 curveto stroke
+newpath -378.253 313.887 moveto -380.845 301.507 lineto -387.755 305.537 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-266.879 114.933 moveto
+-367.067 117.547 -377.642 117.822 -458.912 119.943 curveto stroke
+newpath -470.908 120.255 moveto -458.807 123.941 lineto -459.016 115.944 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-368.176 331.163 moveto
+-322.511 233.685 -318.018 224.095 -280.454 143.911 curveto stroke
+newpath -275.364 133.044 moveto -284.076 142.214 lineto -276.832 145.608 lineto closepath fill
+2 setlinewidth 1 0 0 setrgbcolor newpath
+-266.879 114.933 moveto
+-224.004 235.52 -220.448 245.52 -184.094 347.765 curveto stroke
+newpath -180.074 359.072 moveto -180.325 346.425 lineto -187.863 349.105 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-251.294 -335.059 moveto
+-189.25 -303.624 -179.902 -298.887 -133.738 -275.498 curveto stroke
+newpath -123.034 -270.074 moveto -131.93 -279.066 lineto -135.546 -271.93 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-389.604 -136.361 moveto
+-327.15 -226.083 -321.098 -234.777 -269.576 -308.795 curveto stroke
+newpath -262.72 -318.644 moveto -272.859 -311.081 lineto -266.293 -306.51 lineto closepath fill
+2 setlinewidth 1 0 0 setrgbcolor newpath
+5.84406 175.322 moveto
+-76.0754 267.926 -83.1051 275.873 -152.172 353.948 curveto stroke
+newpath -160.122 362.936 moveto -149.176 356.598 lineto -155.168 351.298 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+169.478 311.683 moveto
+96.8003 251.119 88.6819 244.353 30.4273 195.808 curveto stroke
+newpath 21.2086 188.126 moveto 27.8666 198.881 lineto 32.988 192.735 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+342.851 111.037 moveto
+263.766 202.563 256.831 210.589 190.4 287.47 curveto stroke
+newpath 182.554 296.55 moveto 193.427 290.085 lineto 187.373 284.855 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+5.84406 175.322 moveto
+163.16 145.314 173.605 143.321 311.418 117.033 curveto stroke
+newpath 323.205 114.784 moveto 310.668 113.104 lineto 312.167 120.962 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+342.851 111.037 moveto
+497.255 2.58683 505.964 -3.53033 643.932 -100.436 curveto stroke
+newpath 653.752 -107.334 moveto 641.633 -103.71 lineto 646.231 -97.163 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+364.28 -222.074 moveto
+354.298 -66.9063 353.616 -56.2971 344.905 79.1029 curveto stroke
+newpath 344.135 91.0781 moveto 348.897 79.3597 lineto 340.914 78.8461 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+670.118 -118.829 moveto
+528.037 -166.793 517.967 -170.192 394.599 -211.839 curveto stroke
+newpath 383.229 -215.677 moveto 393.32 -208.049 lineto 395.878 -215.629 lineto closepath fill
+2 setlinewidth 1 0 0 setrgbcolor newpath
+-105.193 -261.035 moveto
+118.401 -242.479 129.015 -241.598 332.39 -224.721 curveto stroke
+newpath 344.348 -223.728 moveto 332.72 -228.707 lineto 332.059 -220.734 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-105.193 -261.035 moveto
+-160.867 -161.176 -166.028 -151.918 -212.336 -68.858 curveto stroke
+newpath -218.179 -58.3769 moveto -208.842 -66.9102 lineto -215.829 -70.8058 lineto closepath fill
+2 setlinewidth 0 0 1 setrgbcolor newpath
+-227.918 -40.9084 moveto
+-298.35 -82.4884 -307.42 -87.8432 -362.048 -120.093 curveto stroke
+newpath -372.381 -126.193 moveto -364.081 -116.648 lineto -360.014 -123.537 lineto closepath fill
+grestore
+%Nodes:
+gsave
+-389.604 -136.361 20 0 1 0 nc
+-227.918 -40.9084 20 0 1 0 nc
+-105.193 -261.035 20 0 1 0 nc
+364.28 -222.074 20 1 1 0 nc
+670.118 -118.829 20 1 1 0 nc
+342.851 111.037 20 1 1 0 nc
+5.84406 175.322 20 1 1 0 nc
+169.478 311.683 20 1 1 0 nc
+-173.374 377.916 20 1 0 1 nc
+-251.294 -335.059 20 0 1 0 nc
+-266.879 114.933 20 0 0 0 nc
+-368.176 331.163 20 0 0 0 nc
+-490.901 120.777 20 0 0 0 nc
+-574.666 -153.893 20 1 0 0 nc
+-675.963 -3.89604 20 1 0 0 nc
+-465.576 -42.8564 20 1 0 0 nc
+44.8044 15.5841 20 0 0 1 nc
+157.79 -130.517 20 0 0 1 nc
+218.178 27.2723 20 0 0 1 nc
+grestore
+grestore
+showpage
Index: doc/images/swap_test.eps
===================================================================
--- doc/images/swap_test.eps	(revision 2084)
+++ doc/images/swap_test.eps	(revision 2084)
@@ -0,0 +1,763 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: swap_test.eps
+%%Creator: gnuplot 4.0 patchlevel 0
+%%CreationDate: Sat May 13 18:29:57 2006
+%%DocumentFonts: (atend)
+%%BoundingBox: 50 50 338 251
+%%Orientation: Portrait
+%%EndComments
+/gnudict 256 dict def
+gnudict begin
+/Color false def
+/Solid false def
+/gnulinewidth 5.000 def
+/userlinewidth gnulinewidth def
+/vshift -46 def
+/dl {10.0 mul} def
+/hpt_ 31.5 def
+/vpt_ 31.5 def
+/hpt hpt_ def
+/vpt vpt_ def
+/Rounded false def
+/M {moveto} bind def
+/L {lineto} bind def
+/R {rmoveto} bind def
+/V {rlineto} bind def
+/N {newpath moveto} bind def
+/C {setrgbcolor} bind def
+/f {rlineto fill} bind def
+/vpt2 vpt 2 mul def
+/hpt2 hpt 2 mul def
+/Lshow { currentpoint stroke M
+  0 vshift R show } def
+/Rshow { currentpoint stroke M
+  dup stringwidth pop neg vshift R show } def
+/Cshow { currentpoint stroke M
+  dup stringwidth pop -2 div vshift R show } def
+/UP { dup vpt_ mul /vpt exch def hpt_ mul /hpt exch def
+  /hpt2 hpt 2 mul def /vpt2 vpt 2 mul def } def
+/DL { Color {setrgbcolor Solid {pop []} if 0 setdash }
+ {pop pop pop 0 setgray Solid {pop []} if 0 setdash} ifelse } def
+/BL { stroke userlinewidth 2 mul setlinewidth
+      Rounded { 1 setlinejoin 1 setlinecap } if } def
+/AL { stroke userlinewidth 2 div setlinewidth
+      Rounded { 1 setlinejoin 1 setlinecap } if } def
+/UL { dup gnulinewidth mul /userlinewidth exch def
+      dup 1 lt {pop 1} if 10 mul /udl exch def } def
+/PL { stroke userlinewidth setlinewidth
+      Rounded { 1 setlinejoin 1 setlinecap } if } def
+/LTw { PL [] 1 setgray } def
+/LTb { BL [] 0 0 0 DL } def
+/LTa { AL [1 udl mul 2 udl mul] 0 setdash 0 0 0 setrgbcolor } def
+/LT0 { PL [] 1 0 0 DL } def
+/LT1 { PL [4 dl 2 dl] 0 1 0 DL } def
+/LT2 { PL [2 dl 3 dl] 0 0 1 DL } def
+/LT3 { PL [1 dl 1.5 dl] 1 0 1 DL } def
+/LT4 { PL [5 dl 2 dl 1 dl 2 dl] 0 1 1 DL } def
+/LT5 { PL [4 dl 3 dl 1 dl 3 dl] 1 1 0 DL } def
+/LT6 { PL [2 dl 2 dl 2 dl 4 dl] 0 0 0 DL } def
+/LT7 { PL [2 dl 2 dl 2 dl 2 dl 2 dl 4 dl] 1 0.3 0 DL } def
+/LT8 { PL [2 dl 2 dl 2 dl 2 dl 2 dl 2 dl 2 dl 4 dl] 0.5 0.5 0.5 DL } def
+/Pnt { stroke [] 0 setdash
+   gsave 1 setlinecap M 0 0 V stroke grestore } def
+/Dia { stroke [] 0 setdash 2 copy vpt add M
+  hpt neg vpt neg V hpt vpt neg V
+  hpt vpt V hpt neg vpt V closepath stroke
+  Pnt } def
+/Pls { stroke [] 0 setdash vpt sub M 0 vpt2 V
+  currentpoint stroke M
+  hpt neg vpt neg R hpt2 0 V stroke
+  } def
+/Box { stroke [] 0 setdash 2 copy exch hpt sub exch vpt add M
+  0 vpt2 neg V hpt2 0 V 0 vpt2 V
+  hpt2 neg 0 V closepath stroke
+  Pnt } def
+/Crs { stroke [] 0 setdash exch hpt sub exch vpt add M
+  hpt2 vpt2 neg V currentpoint stroke M
+  hpt2 neg 0 R hpt2 vpt2 V stroke } def
+/TriU { stroke [] 0 setdash 2 copy vpt 1.12 mul add M
+  hpt neg vpt -1.62 mul V
+  hpt 2 mul 0 V
+  hpt neg vpt 1.62 mul V closepath stroke
+  Pnt  } def
+/Star { 2 copy Pls Crs } def
+/BoxF { stroke [] 0 setdash exch hpt sub exch vpt add M
+  0 vpt2 neg V  hpt2 0 V  0 vpt2 V
+  hpt2 neg 0 V  closepath fill } def
+/TriUF { stroke [] 0 setdash vpt 1.12 mul add M
+  hpt neg vpt -1.62 mul V
+  hpt 2 mul 0 V
+  hpt neg vpt 1.62 mul V closepath fill } def
+/TriD { stroke [] 0 setdash 2 copy vpt 1.12 mul sub M
+  hpt neg vpt 1.62 mul V
+  hpt 2 mul 0 V
+  hpt neg vpt -1.62 mul V closepath stroke
+  Pnt  } def
+/TriDF { stroke [] 0 setdash vpt 1.12 mul sub M
+  hpt neg vpt 1.62 mul V
+  hpt 2 mul 0 V
+  hpt neg vpt -1.62 mul V closepath fill} def
+/DiaF { stroke [] 0 setdash vpt add M
+  hpt neg vpt neg V hpt vpt neg V
+  hpt vpt V hpt neg vpt V closepath fill } def
+/Pent { stroke [] 0 setdash 2 copy gsave
+  translate 0 hpt M 4 {72 rotate 0 hpt L} repeat
+  closepath stroke grestore Pnt } def
+/PentF { stroke [] 0 setdash gsave
+  translate 0 hpt M 4 {72 rotate 0 hpt L} repeat
+  closepath fill grestore } def
+/Circle { stroke [] 0 setdash 2 copy
+  hpt 0 360 arc stroke Pnt } def
+/CircleF { stroke [] 0 setdash hpt 0 360 arc fill } def
+/C0 { BL [] 0 setdash 2 copy moveto vpt 90 450  arc } bind def
+/C1 { BL [] 0 setdash 2 copy        moveto
+       2 copy  vpt 0 90 arc closepath fill
+               vpt 0 360 arc closepath } bind def
+/C2 { BL [] 0 setdash 2 copy moveto
+       2 copy  vpt 90 180 arc closepath fill
+               vpt 0 360 arc closepath } bind def
+/C3 { BL [] 0 setdash 2 copy moveto
+       2 copy  vpt 0 180 arc closepath fill
+               vpt 0 360 arc closepath } bind def
+/C4 { BL [] 0 setdash 2 copy moveto
+       2 copy  vpt 180 270 arc closepath fill
+               vpt 0 360 arc closepath } bind def
+/C5 { BL [] 0 setdash 2 copy moveto
+       2 copy  vpt 0 90 arc
+       2 copy moveto
+       2 copy  vpt 180 270 arc closepath fill
+               vpt 0 360 arc } bind def
+/C6 { BL [] 0 setdash 2 copy moveto
+      2 copy  vpt 90 270 arc closepath fill
+              vpt 0 360 arc closepath } bind def
+/C7 { BL [] 0 setdash 2 copy moveto
+      2 copy  vpt 0 270 arc closepath fill
+              vpt 0 360 arc closepath } bind def
+/C8 { BL [] 0 setdash 2 copy moveto
+      2 copy vpt 270 360 arc closepath fill
+              vpt 0 360 arc closepath } bind def
+/C9 { BL [] 0 setdash 2 copy moveto
+      2 copy  vpt 270 450 arc closepath fill
+              vpt 0 360 arc closepath } bind def
+/C10 { BL [] 0 setdash 2 copy 2 copy moveto vpt 270 360 arc closepath fill
+       2 copy moveto
+       2 copy vpt 90 180 arc closepath fill
+               vpt 0 360 arc closepath } bind def
+/C11 { BL [] 0 setdash 2 copy moveto
+       2 copy  vpt 0 180 arc closepath fill
+       2 copy moveto
+       2 copy  vpt 270 360 arc closepath fill
+               vpt 0 360 arc closepath } bind def
+/C12 { BL [] 0 setdash 2 copy moveto
+       2 copy  vpt 180 360 arc closepath fill
+               vpt 0 360 arc closepath } bind def
+/C13 { BL [] 0 setdash  2 copy moveto
+       2 copy  vpt 0 90 arc closepath fill
+       2 copy moveto
+       2 copy  vpt 180 360 arc closepath fill
+               vpt 0 360 arc closepath } bind def
+/C14 { BL [] 0 setdash 2 copy moveto
+       2 copy  vpt 90 360 arc closepath fill
+               vpt 0 360 arc } bind def
+/C15 { BL [] 0 setdash 2 copy vpt 0 360 arc closepath fill
+               vpt 0 360 arc closepath } bind def
+/Rec   { newpath 4 2 roll moveto 1 index 0 rlineto 0 exch rlineto
+       neg 0 rlineto closepath } bind def
+/Square { dup Rec } bind def
+/Bsquare { vpt sub exch vpt sub exch vpt2 Square } bind def
+/S0 { BL [] 0 setdash 2 copy moveto 0 vpt rlineto BL Bsquare } bind def
+/S1 { BL [] 0 setdash 2 copy vpt Square fill Bsquare } bind def
+/S2 { BL [] 0 setdash 2 copy exch vpt sub exch vpt Square fill Bsquare } bind def
+/S3 { BL [] 0 setdash 2 copy exch vpt sub exch vpt2 vpt Rec fill Bsquare } bind def
+/S4 { BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt Square fill Bsquare } bind def
+/S5 { BL [] 0 setdash 2 copy 2 copy vpt Square fill
+       exch vpt sub exch vpt sub vpt Square fill Bsquare } bind def
+/S6 { BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt vpt2 Rec fill Bsquare } bind def
+/S7 { BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt vpt2 Rec fill
+       2 copy vpt Square fill
+       Bsquare } bind def
+/S8 { BL [] 0 setdash 2 copy vpt sub vpt Square fill Bsquare } bind def
+/S9 { BL [] 0 setdash 2 copy vpt sub vpt vpt2 Rec fill Bsquare } bind def
+/S10 { BL [] 0 setdash 2 copy vpt sub vpt Square fill 2 copy exch vpt sub exch vpt Square fill
+       Bsquare } bind def
+/S11 { BL [] 0 setdash 2 copy vpt sub vpt Square fill 2 copy exch vpt sub exch vpt2 vpt Rec fill
+       Bsquare } bind def
+/S12 { BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill Bsquare } bind def
+/S13 { BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill
+       2 copy vpt Square fill Bsquare } bind def
+/S14 { BL [] 0 setdash 2 copy exch vpt sub exch vpt sub vpt2 vpt Rec fill
+       2 copy exch vpt sub exch vpt Square fill Bsquare } bind def
+/S15 { BL [] 0 setdash 2 copy Bsquare fill Bsquare } bind def
+/D0 { gsave translate 45 rotate 0 0 S0 stroke grestore } bind def
+/D1 { gsave translate 45 rotate 0 0 S1 stroke grestore } bind def
+/D2 { gsave translate 45 rotate 0 0 S2 stroke grestore } bind def
+/D3 { gsave translate 45 rotate 0 0 S3 stroke grestore } bind def
+/D4 { gsave translate 45 rotate 0 0 S4 stroke grestore } bind def
+/D5 { gsave translate 45 rotate 0 0 S5 stroke grestore } bind def
+/D6 { gsave translate 45 rotate 0 0 S6 stroke grestore } bind def
+/D7 { gsave translate 45 rotate 0 0 S7 stroke grestore } bind def
+/D8 { gsave translate 45 rotate 0 0 S8 stroke grestore } bind def
+/D9 { gsave translate 45 rotate 0 0 S9 stroke grestore } bind def
+/D10 { gsave translate 45 rotate 0 0 S10 stroke grestore } bind def
+/D11 { gsave translate 45 rotate 0 0 S11 stroke grestore } bind def
+/D12 { gsave translate 45 rotate 0 0 S12 stroke grestore } bind def
+/D13 { gsave translate 45 rotate 0 0 S13 stroke grestore } bind def
+/D14 { gsave translate 45 rotate 0 0 S14 stroke grestore } bind def
+/D15 { gsave translate 45 rotate 0 0 S15 stroke grestore } bind def
+/DiaE { stroke [] 0 setdash vpt add M
+  hpt neg vpt neg V hpt vpt neg V
+  hpt vpt V hpt neg vpt V closepath stroke } def
+/BoxE { stroke [] 0 setdash exch hpt sub exch vpt add M
+  0 vpt2 neg V hpt2 0 V 0 vpt2 V
+  hpt2 neg 0 V closepath stroke } def
+/TriUE { stroke [] 0 setdash vpt 1.12 mul add M
+  hpt neg vpt -1.62 mul V
+  hpt 2 mul 0 V
+  hpt neg vpt 1.62 mul V closepath stroke } def
+/TriDE { stroke [] 0 setdash vpt 1.12 mul sub M
+  hpt neg vpt 1.62 mul V
+  hpt 2 mul 0 V
+  hpt neg vpt -1.62 mul V closepath stroke } def
+/PentE { stroke [] 0 setdash gsave
+  translate 0 hpt M 4 {72 rotate 0 hpt L} repeat
+  closepath stroke grestore } def
+/CircE { stroke [] 0 setdash 
+  hpt 0 360 arc stroke } def
+/Opaque { gsave closepath 1 setgray fill grestore 0 setgray closepath } def
+/DiaW { stroke [] 0 setdash vpt add M
+  hpt neg vpt neg V hpt vpt neg V
+  hpt vpt V hpt neg vpt V Opaque stroke } def
+/BoxW { stroke [] 0 setdash exch hpt sub exch vpt add M
+  0 vpt2 neg V hpt2 0 V 0 vpt2 V
+  hpt2 neg 0 V Opaque stroke } def
+/TriUW { stroke [] 0 setdash vpt 1.12 mul add M
+  hpt neg vpt -1.62 mul V
+  hpt 2 mul 0 V
+  hpt neg vpt 1.62 mul V Opaque stroke } def
+/TriDW { stroke [] 0 setdash vpt 1.12 mul sub M
+  hpt neg vpt 1.62 mul V
+  hpt 2 mul 0 V
+  hpt neg vpt -1.62 mul V Opaque stroke } def
+/PentW { stroke [] 0 setdash gsave
+  translate 0 hpt M 4 {72 rotate 0 hpt L} repeat
+  Opaque stroke grestore } def
+/CircW { stroke [] 0 setdash 
+  hpt 0 360 arc Opaque stroke } def
+/BoxFill { gsave Rec 1 setgray fill grestore } def
+/BoxColFill {
+  gsave Rec
+  /Fillden exch def
+  currentrgbcolor
+  /ColB exch def /ColG exch def /ColR exch def
+  /ColR ColR Fillden mul Fillden sub 1 add def
+  /ColG ColG Fillden mul Fillden sub 1 add def
+  /ColB ColB Fillden mul Fillden sub 1 add def
+  ColR ColG ColB setrgbcolor
+  fill grestore } def
+%
+% PostScript Level 1 Pattern Fill routine
+% Usage: x y w h s a XX PatternFill
+%	x,y = lower left corner of box to be filled
+%	w,h = width and height of box
+%	  a = angle in degrees between lines and x-axis
+%	 XX = 0/1 for no/yes cross-hatch
+%
+/PatternFill { gsave /PFa [ 9 2 roll ] def
+    PFa 0 get PFa 2 get 2 div add PFa 1 get PFa 3 get 2 div add translate
+    PFa 2 get -2 div PFa 3 get -2 div PFa 2 get PFa 3 get Rec
+    gsave 1 setgray fill grestore clip
+    currentlinewidth 0.5 mul setlinewidth
+    /PFs PFa 2 get dup mul PFa 3 get dup mul add sqrt def
+    0 0 M PFa 5 get rotate PFs -2 div dup translate
+	0 1 PFs PFa 4 get div 1 add floor cvi
+	{ PFa 4 get mul 0 M 0 PFs V } for
+    0 PFa 6 get ne {
+	0 1 PFs PFa 4 get div 1 add floor cvi
+	{ PFa 4 get mul 0 2 1 roll M PFs 0 V } for
+    } if
+    stroke grestore } def
+%
+/Symbol-Oblique /Symbol findfont [1 0 .167 1 0 0] makefont
+dup length dict begin {1 index /FID eq {pop pop} {def} ifelse} forall
+currentdict end definefont pop
+end
+%%EndProlog
+gnudict begin
+gsave
+50 50 translate
+0.050 0.050 scale
+0 setgray
+newpath
+(Helvetica) findfont 140 scalefont setfont
+1.000 UL
+LTb
+574 280 M
+63 0 V
+4885 0 R
+-63 0 V
+490 280 M
+gsave 0 setgray
+( 0) Rshow
+grestore
+1.000 UL
+LTb
+574 606 M
+63 0 V
+4885 0 R
+-63 0 V
+490 606 M
+gsave 0 setgray
+( 0.5) Rshow
+grestore
+1.000 UL
+LTb
+574 932 M
+63 0 V
+4885 0 R
+-63 0 V
+490 932 M
+gsave 0 setgray
+( 1) Rshow
+grestore
+1.000 UL
+LTb
+574 1257 M
+63 0 V
+4885 0 R
+-63 0 V
+-4969 0 R
+gsave 0 setgray
+( 1.5) Rshow
+grestore
+1.000 UL
+LTb
+574 1583 M
+63 0 V
+4885 0 R
+-63 0 V
+-4969 0 R
+gsave 0 setgray
+( 2) Rshow
+grestore
+1.000 UL
+LTb
+574 1909 M
+63 0 V
+4885 0 R
+-63 0 V
+-4969 0 R
+gsave 0 setgray
+( 2.5) Rshow
+grestore
+1.000 UL
+LTb
+574 2235 M
+63 0 V
+4885 0 R
+-63 0 V
+-4969 0 R
+gsave 0 setgray
+( 3) Rshow
+grestore
+1.000 UL
+LTb
+574 2561 M
+63 0 V
+4885 0 R
+-63 0 V
+-4969 0 R
+gsave 0 setgray
+( 3.5) Rshow
+grestore
+1.000 UL
+LTb
+574 2887 M
+63 0 V
+4885 0 R
+-63 0 V
+-4969 0 R
+gsave 0 setgray
+( 4) Rshow
+grestore
+1.000 UL
+LTb
+574 3212 M
+63 0 V
+4885 0 R
+-63 0 V
+-4969 0 R
+gsave 0 setgray
+( 4.5) Rshow
+grestore
+1.000 UL
+LTb
+574 3538 M
+63 0 V
+4885 0 R
+-63 0 V
+-4969 0 R
+gsave 0 setgray
+( 5) Rshow
+grestore
+1.000 UL
+LTb
+574 3864 M
+63 0 V
+4885 0 R
+-63 0 V
+-4969 0 R
+gsave 0 setgray
+( 5.5) Rshow
+grestore
+1.000 UL
+LTb
+574 280 M
+0 63 V
+0 3521 R
+0 -63 V
+574 140 M
+gsave 0 setgray
+( 0) Cshow
+grestore
+1.000 UL
+LTb
+1069 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 1000) Cshow
+grestore
+1.000 UL
+LTb
+1564 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 2000) Cshow
+grestore
+1.000 UL
+LTb
+2058 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 3000) Cshow
+grestore
+1.000 UL
+LTb
+2553 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 4000) Cshow
+grestore
+1.000 UL
+LTb
+3048 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 5000) Cshow
+grestore
+1.000 UL
+LTb
+3543 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 6000) Cshow
+grestore
+1.000 UL
+LTb
+4038 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 7000) Cshow
+grestore
+1.000 UL
+LTb
+4532 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 8000) Cshow
+grestore
+1.000 UL
+LTb
+5027 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 9000) Cshow
+grestore
+1.000 UL
+LTb
+5522 280 M
+0 63 V
+0 3521 R
+0 -63 V
+0 -3661 R
+gsave 0 setgray
+( 10000) Cshow
+grestore
+1.000 UL
+LTb
+1.000 UL
+LTb
+574 280 M
+4948 0 V
+0 3584 V
+-4948 0 V
+574 280 L
+1.000 UP
+1.000 UL
+LT5
+LTb
+4871 3731 M
+gsave 0 setgray
+(Original) Rshow
+grestore
+LT5
+4955 3731 M
+399 0 V
+623 521 M
+50 2 V
+49 -7 V
+50 33 V
+49 -25 V
+50 21 V
+49 2 V
+50 0 V
+49 1 V
+50 -6 V
+49 5 V
+50 4 V
+49 4 V
+50 10 V
+49 0 V
+50 2 V
+49 -1 V
+50 9 V
+49 2 V
+50 6 V
+49 36 V
+50 2 V
+49 21 V
+50 8 V
+49 11 V
+49 5 V
+50 5 V
+49 2 V
+50 104 V
+49 -82 V
+50 13 V
+49 4 V
+50 16 V
+49 36 V
+50 32 V
+49 -5 V
+50 32 V
+49 36 V
+50 30 V
+49 -8 V
+50 42 V
+49 28 V
+50 33 V
+49 43 V
+50 58 V
+49 78 V
+50 95 V
+49 126 V
+50 285 V
+49 1708 V
+49 -665 V
+50 -235 V
+49 -143 V
+50 -103 V
+49 -101 V
+50 -118 V
+49 -94 V
+50 -40 V
+49 -57 V
+50 -133 V
+49 5 V
+50 -16 V
+49 57 V
+50 -144 V
+49 -37 V
+50 -48 V
+49 -64 V
+50 17 V
+49 -67 V
+50 -41 V
+49 -18 V
+50 -9 V
+49 10 V
+50 -5 V
+49 -2 V
+49 -26 V
+50 -26 V
+49 -42 V
+50 50 V
+49 -78 V
+50 -51 V
+49 -13 V
+50 9 V
+49 -8 V
+50 0 V
+49 -1 V
+50 -7 V
+49 1 V
+50 -4 V
+49 -13 V
+50 -7 V
+49 -25 V
+50 5 V
+49 -11 V
+50 -16 V
+49 -9 V
+50 -24 V
+49 -2 V
+50 -21 V
+1.000 UL
+LT0
+LTb
+4871 3591 M
+gsave 0 setgray
+(Swapped) Rshow
+grestore
+LT0
+4955 3591 M
+399 0 V
+623 1034 M
+50 -1 V
+49 30 V
+50 -5 V
+49 57 V
+50 -20 V
+49 26 V
+50 0 V
+49 11 V
+50 -10 V
+49 25 V
+50 6 V
+49 6 V
+50 -16 V
+49 21 V
+50 15 V
+49 82 V
+50 -88 V
+49 26 V
+50 37 V
+49 1 V
+50 22 V
+49 64 V
+50 21 V
+49 -3 V
+49 11 V
+50 -8 V
+49 29 V
+50 8 V
+49 6 V
+50 29 V
+49 7 V
+50 119 V
+49 26 V
+50 49 V
+49 32 V
+50 24 V
+49 64 V
+50 -9 V
+49 51 V
+50 35 V
+49 84 V
+50 99 V
+49 77 V
+50 87 V
+49 84 V
+50 212 V
+49 48 V
+50 281 V
+49 771 V
+49 -1861 V
+50 -283 V
+49 -116 V
+50 -117 V
+49 -89 V
+50 -47 V
+49 -54 V
+50 -29 V
+49 -32 V
+50 -39 V
+49 -18 V
+50 14 V
+49 -48 V
+50 -29 V
+49 -22 V
+50 -17 V
+49 -26 V
+50 4 V
+49 -30 V
+50 -12 V
+49 -12 V
+50 -1 V
+49 -21 V
+50 -9 V
+49 21 V
+49 -20 V
+50 -8 V
+49 -7 V
+50 -19 V
+49 -21 V
+50 -11 V
+49 2 V
+50 -6 V
+49 -7 V
+50 2 V
+49 72 V
+50 -87 V
+49 -7 V
+50 5 V
+49 -12 V
+50 1 V
+49 4 V
+50 -2 V
+49 -14 V
+50 -10 V
+49 -2 V
+50 19 V
+49 -29 V
+50 5 V
+1.000 UL
+LTb
+574 280 M
+4948 0 V
+0 3584 V
+-4948 0 V
+574 280 L
+1.000 UP
+stroke
+grestore
+end
+showpage
+%%Trailer
+%%DocumentFonts: Helvetica
Index: doc/lemon_file_format.dox
===================================================================
--- doc/lemon_file_format.dox	(revision 2553)
+++ doc/lemon_file_format.dox	(revision 2553)
@@ -0,0 +1,288 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+/*!
+
+
+\page lemon_file_format LEMON Graph File Format
+
+The standard graph IO enables one to store graphs and additional maps
+(i.e. functions on the nodes or edges) in a flexible and efficient way. 
+Before you read this page you should be familiar with LEMON 
+\ref graphs "graphs" and \ref maps-page "maps".
+
+\section format The general file format
+
+The file contains sections in the following order:
+
+\li nodeset
+\li edgeset
+\li nodes
+\li edges
+\li attributes
+
+Some of these sections can be omitted, but you will basicly need the nodeset
+section (unless your graph has no nodes at all) and the edgeset section
+(unless your graph has no edges at all). 
+
+The nodeset section describes the nodes of your graph: it identifies the nodes
+and gives the maps defined on them, if any. It starts with the
+following line:
+
+<tt>\@nodeset</tt>
+
+The next line contains the names of the nodemaps, separated by whitespaces.  Each
+following line describes a node in the graph: it contains the values of the
+maps in the right order. The map named "label" should contain unique values
+because it is regarded as a label map. These labels need not be numbers but they
+must identify the nodes uniquely for later reference. For example:
+
+\code
+@nodeset
+label  x-coord  y-coord  color
+3   1.0      4.0      blue
+5   2.3      5.7      red
+12  7.8      2.3      green
+\endcode
+
+The edgeset section is very similar to the nodeset section, it has
+the same coloumn oriented structure. It starts with the line 
+
+<tt>\@edgeset</tt>
+
+The next line contains the whitespace separated list of names of the edge
+maps.  Each of the next lines describes one edge. The first two elements in
+the line are the labels of the source and target (or tail and head) nodes of the
+edge as they occur in the label node map of the nodeset section. You can also
+have an optional label map on the edges for later reference (which has to be
+unique in this case).
+
+\code
+@edgeset
+             label      weight   note
+3   5        a          4.3      a-edge
+5   12       c          2.6      c-edge
+3   12       g          3.4      g-edge
+\endcode
+
+The \e nodes section contains <em>labeled (distinguished) nodes</em> 
+(i.e. nodes having a special
+label on them). The section starts with
+
+<tt> \@nodes </tt>
+
+Each of the next lines contains a label for a node in the graph 
+and then the label as described in the \e nodeset section.
+
+\code
+@nodes 
+source 3
+target 12
+\endcode
+
+The last section describes the <em>labeled (distinguished) edges</em>
+(i.e. edges having a special label on them). It starts with \c \@edges
+and then each line contains the name of the edge and the label.
+
+\code
+@edges 
+observed c
+\endcode
+
+
+The file may contain empty lines and comment lines. The comment lines
+start with an \c # character.
+
+The attributes section can handle some information about the graph. It
+contains key-value pairs in each line (a key and the mapped value to key). The
+key should be a string without whitespaces, the value can be of various types.
+
+\code
+@attributes
+title "Four colored planar graph"
+author "Balazs DEZSO"
+copyright "Lemon Library"
+version 12
+\endcode
+
+Finally, the file should be closed with \c \@end line.
+
+
+\section use Using graph input-output
+
+
+The graph input and output is based on <em> reading and writing
+commands</em>. The user gives reading and writing commands to the reader or
+writer class, then he calls the \c run() method that executes all the given
+commands.
+
+\subsection write Writing a graph
+
+The \ref lemon::GraphWriter "GraphWriter" template class
+provides the graph output. To write a graph
+you should first give writing commands to the writer. You can declare
+writing command as \c NodeMap or \c EdgeMap writing and labeled Node and
+Edge writing.
+
+\code
+GraphWriter<ListGraph> writer(std::cout, graph);
+\endcode
+
+The \ref lemon::GraphWriter::writeNodeMap() "writeNodeMap()"
+function declares a \c NodeMap writing command in the
+\ref lemon::GraphWriter "GraphWriter".
+You should give a name to the map and the map
+object as parameters. The NodeMap writing command with name "label" should write a 
+unique map because it will be regarded as a label map.
+
+\see IdMap, DescriptorMap  
+
+\code
+IdMap<ListGraph, Node> nodeLabelMap;
+writer.writeNodeMap("label", nodeLabelMap);
+
+writer.writeNodeMap("x-coord", xCoordMap);
+writer.writeNodeMap("y-coord", yCoordMap);
+writer.writeNodeMap("color", colorMap);
+\endcode
+
+With the \ref lemon::GraphWriter::writeEdgeMap() "writeEdgeMap()"
+member function you can give an edge map
+writing command similar to the NodeMaps.
+
+\see IdMap, DescriptorMap  
+
+\code
+DescriptorMap<ListGraph, Edge, ListGraph::EdgeMap<int> > edgeDescMap(graph);
+writer.writeEdgeMap("descriptor", edgeDescMap);
+
+writer.writeEdgeMap("weight", weightMap);
+writer.writeEdgeMap("note", noteMap);
+\endcode
+
+With \ref lemon::GraphWriter::writeNode() "writeNode()"
+and \ref lemon::GraphWriter::writeEdge() "writeEdge()"
+functions you can designate Nodes and
+Edges in the graph. For example, you can write out the source and target node
+of a maximum flow instance.
+
+\code
+writer.writeNode("source", sourceNode);
+writer.writeNode("target", targetNode);
+
+writer.writeEdge("observed", edge);
+\endcode
+
+With \ref lemon::GraphWriter::writeAttribute() "writeAttribute()"
+function you can write an attribute to the file.
+
+\code
+writer.writeAttribute("author", "Balazs DEZSO");
+writer.writeAttribute("version", 12);
+\endcode
+
+After you give all write commands you must call the
+\ref lemon::GraphWriter::run() "run()" member
+function, which executes all the writing commands.
+
+\code
+writer.run();
+\endcode
+
+\subsection reading Reading a graph
+
+The file to be read may contain several maps and labeled nodes or edges.
+If you read a graph you need not read all the maps and items just those
+that you need. The interface of the \ref lemon::GraphReader "GraphReader"
+is very similar to
+the \ref lemon::GraphWriter "GraphWriter"
+but the reading method does not depend on the order of the
+given commands.
+
+The reader object assumes that each not read value does not contain 
+whitespaces, therefore it has some extra possibilities to control how
+it should skip the values when the string representation contains spaces.
+
+\code
+GraphReader<ListGraph> reader(std::cin, graph);
+\endcode
+
+The \ref lemon::GraphReader::readNodeMap() "readNodeMap()"
+function reads a map from the \c nodeset section.
+If there is a map that you do not want to read from the file and there are
+whitespaces in the string represenation of the values then you should
+call the \ref lemon::GraphReader::skipNodeMap() "skipNodeMap()"
+template member function with proper parameters.
+
+\see QuotedStringReader
+
+\code
+reader.readNodeMap("x-coord", xCoordMap);
+reader.readNodeMap("y-coord", yCoordMap);
+
+reader.readNodeMap<QuotedStringReader>("label", labelMap);
+reader.skipNodeMap<QuotedStringReader>("description");
+
+reader.readNodeMap("color", colorMap);
+\endcode
+
+With the \ref lemon::GraphReader::readEdgeMap() "readEdgeMap()"
+member function you can give an edge map
+reading command similar to the NodeMaps. 
+
+\code
+reader.readEdgeMap("weight", weightMap);
+reader.readEdgeMap("label", labelMap);
+\endcode
+
+With \ref lemon::GraphReader::readNode() "readNode()"
+and \ref lemon::GraphReader::readEdge() "readEdge()"
+functions you can read labeled Nodes and
+Edges.
+
+\code
+reader.readNode("source", sourceNode);
+reader.readNode("target", targetNode);
+
+reader.readEdge("observed", edge);
+\endcode
+
+With \ref lemon::GraphReader::readAttribute() "readAttribute()"
+function you can read an attribute from the file.
+
+\code
+std::string author;
+writer.readAttribute("author", author);
+int version;
+writer.writeAttribute("version", version);
+\endcode
+
+After you give all read commands you must call the
+\ref lemon::GraphReader::run() "run()" member
+function, which executes all the commands.
+
+\code
+reader.run();
+\endcode
+
+If you want to lear more, read the \ref read_write_bg "background technics".
+
+\author Balazs Dezso
+*/
+}
Index: doc/license.dox
===================================================================
--- doc/license.dox	(revision 2553)
+++ doc/license.dox	(revision 2553)
@@ -0,0 +1,25 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/**
+
+\page license License Terms
+
+\verbinclude LICENSE
+
+*/
Index: doc/mainpage.dox
===================================================================
--- doc/mainpage.dox	(revision 2553)
+++ doc/mainpage.dox	(revision 2553)
@@ -0,0 +1,60 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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
+
+\subsection whatis What is LEMON
+
+LEMON stands for
+<b>L</b>ibrary of <b>E</b>fficient <b>M</b>odels
+and <b>O</b>ptimization in <b>N</b>etworks.
+It is a C++ template
+library aimed at combinatorial optimization tasks which
+often involve in working
+with graphs.
+
+<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>
+
+\subsection howtoread How to read the documentation
+
+If you want to get a quick start and see the most important features then 
+take a look at our \ref quicktour
+"Quick Tour to LEMON" which will guide you along.
+
+If you already feel like using our library, see the page that tells you 
+\ref getstart "How to start using LEMON".
+
+If you 
+want to see how LEMON works, see 
+some \ref demoprograms "demo programs"!
+
+If you know what you are looking for then try to find it under the
+<a class="el" href="modules.html">Modules</a>
+section.
+
+
+*/
Index: doc/maps.dox
===================================================================
--- doc/maps.dox	(revision 2568)
+++ doc/maps.dox	(revision 2568)
@@ -0,0 +1,164 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon{
+/*!
+
+\page maps-page Maps
+
+Maps play a central role in LEMON. As their name suggests, they map a
+certain range of \e keys to certain \e values. Each map has two
+<tt>typedef</tt>'s to determine the types of keys and values, like this:
+
+\code
+  typedef Edge Key;
+  typedef double Value;
+\endcode
+
+A map can be 
+\e readable (\ref lemon::concepts::ReadMap "ReadMap", for short),
+\e writable (\ref lemon::concepts::WriteMap "WriteMap") or both
+(\ref lemon::concepts::ReadWriteMap "ReadWriteMap").
+There also exists a special type of
+ReadWrite map called \ref lemon::concepts::ReferenceMap "reference map".
+In addition that you can
+read and write the values of a key, a reference map
+can also give you a reference to the
+value belonging to a key, so you have a direct access to the memory address
+where it is stored.
+
+Each graph structure in LEMON provides two standard map templates called
+\c EdgeMap and \c NodeMap. Both are reference maps and you can easily
+assign data to the nodes and to the edges of the graph. For example if you
+have a graph \c g defined as
+\code
+  ListGraph g;
+\endcode
+and you want to assign a floating point value to each edge, you can do
+it like this.
+\code
+  ListGraph::EdgeMap<double> length(g);
+\endcode
+Note that you must give the underlying graph to the constructor.
+
+The value of a readable map can be obtained by <tt>operator[]</tt>.
+\code
+  d=length[e];
+\endcode
+where \c e is an instance of \c ListGraph::Edge.
+(Or anything else
+that converts to \c ListGraph::Edge, like  \c ListGraph::EdgeIt or
+\c ListGraph::OutEdgeIt etc.)
+
+There are two ways to assign a new value to a key
+
+- In case of a <em>reference map</em> <tt>operator[]</tt>
+gives you a reference to the
+value, thus you can use this.
+\code
+  length[e]=3.5;
+\endcode
+- <em>Writable maps</em> have
+a member function \c set(Key,const Value &)
+for this purpose.
+\code
+  length.set(e,3.5);
+\endcode
+
+The first case is more comfortable and if you store complex structures in your
+map, it might be more efficient. However, there are writable but
+not reference maps, so if you want to write a generic algorithm, you should
+insist on the second way.
+
+\section how-to-write-your-own-map How to Write Your Own Maps
+
+\subsection read-maps Readable Maps
+
+Readable maps are very frequently used as the input of an
+algorithm.  For this purpose the most straightforward way is the use of the
+default maps provided by LEMON's graph structures.
+Very often however, it is more
+convenient and/or more efficient to write your own readable map.
+
+You can find some examples below. In these examples \c Graph is the
+type of the particular graph structure you use.
+
+
+This simple map assigns \f$\pi\f$ to each edge.
+
+\code
+struct MyMap 
+{
+  typedef double Value;
+  typedef Graph::Edge Key;
+  double operator[](Key e) const { return PI;}
+};
+\endcode
+
+An alternative way to define maps is to use \c MapBase
+
+\code
+struct MyMap : public MapBase<Graph::Edge,double>
+{
+  Value operator[](Key e) const { return PI;}
+};
+\endcode
+
+Here is a bit more complex example.
+It provides a length function obtained
+from a base length function shifted by a potential difference.
+
+\code
+class ReducedLengthMap  : public MapBase<Graph::Edge,double>
+{
+  const Graph &g;
+  const Graph::EdgeMap<double> &orig_len;
+  const Graph::NodeMap<double> &pot;
+  
+public:
+  Value operator[](Key e) const {
+    return orig_len[e]-(pot[g.target(e)]-pot[g.source(e)]);
+  }
+  
+  ReducedLengthMap(const Graph &_g,
+                   const Graph::EdgeMap &_o,
+                   const Graph::NodeMap &_p)
+    : g(_g), orig_len(_o), pot(_p) {};
+};
+\endcode
+
+Then, you can call e.g. Dijkstra algoritm on this map like this:
+\code
+  ...
+  ReducedLengthMap rm(g,len,pot);
+  Dijkstra<Graph,ReducedLengthMap> dij(g,rm);
+  dij.run(s);
+  ...
+\endcode
+
+
+\subsection write-maps Writable Maps
+
+To be written...
+
+\subsection side-effect-maps Maps with Side Effect
+
+To be written...
+
+*/
+}
Index: doc/maps1.dox
===================================================================
--- doc/maps1.dox	(revision 2553)
+++ doc/maps1.dox	(revision 2553)
@@ -0,0 +1,96 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+
+/**
+\page maps1 Maps I.
+
+In the previous section we discussed graph topology. That is the skeleton a complex
+graph represented data-set needs. But how to assign the data itself to that skeleton?<br>
+Here come the \b maps in.
+
+\section maps_intro Introduction to maps
+Maps play a central role in LEMON. As their name suggests, they map a certain range of <i>keys</i> to certain <i>values</i>.
+In LEMON there is many types of maps. Each map has two typedef's to determine the types of keys and values, like this:
+\code
+  typedef Edge Key;
+  typedef double Value;
+\endcode
+(Except matrix maps, they have two key types.)
+
+To make easy to use them - especially as template parameters - there are <i>map concepts</i> like by graph classes.
+<ul>
+<li>\ref concepts::ReadMap "ReadMap" - values can be read out with the \c operator[].
+\code value_typed_variable = map_instance[key_value]; \endcode
+</li>
+<li>\ref concepts::WriteMap "WriteMap" - values can be set with the \c set() member function.
+\code map_instance.set(key_value, value_typed_expression); \endcode
+</li>
+<li>\ref concepts::ReadWriteMap "ReadWriteMap" - it's just a shortcut to indicate that the map is both
+readable and writable. It is delivered from them.
+</li>
+<li>\ref concepts::ReferenceMap "ReferenceMap" - a subclass of ReadWriteMap. It has two additional typedefs
+<i>Reference</i> and <i>ConstReference</i> and two overloads of \c operator[] to
+providing you constant or non-constant reference to the value belonging to a key,
+so you have a direct access to the memory address where it is stored.
+</li>
+<li>And there are the Matrix version of these maps, where the values are assigned to a pair of keys.
+The keys can be different types. (\ref concepts::ReadMatrixMap "ReadMatrixMap", 
+\ref concepts::WriteMatrixMap "WriteMatrixMap", \ref concepts::ReadWriteMatrixMap "ReadWriteMatrixMap",
+\ref concepts::ReferenceMatrixMap "ReferenceMatrixMap")
+</li>
+</ul>
+
+\section maps_graph Graphs' maps
+Every \ref MappableGraphComponent "mappable" graph class has two public templates: NodeMap<VALUE> and EdgeMap<VALUE>
+satisfying the \ref GraphMap concept.
+If you want to assign data to nodes, just declare a NodeMap with the corresponding
+type. As an example, think of a edge-weighted directed graph.
+\code ListGraph::EdgeMap<int>  weight(graph); \endcode
+You can see that the map needs the graph whose edges will mapped, but nothing more.
+
+If the graph class is extendable or erasable the map will automatically follow
+the changes you make. If a new node is added a default value is mapped to it.
+You can define the default value by passing a second argument to the map's constructor.
+\code ListGraph::EdgeMap<int>  weight(graph, 13); \endcode
+But keep in mind that \c VALUE has to have copy constructor.
+
+Of course \c VALUE can be a rather complex type.
+
+For practice let's see the following template function (from \ref maps_summary "maps-summary.cc" in the \ref demo directory)!
+\dontinclude maps_summary.cc
+\skip template
+\until }
+The task is simple. We need the summary of some kind of data assigned to a graph's nodes.
+(Whit a little trick the summary can be calculated only to a sub-graph without changing
+this code. See \ref SubGraph techniques - that's LEMON's true potential.)
+
+And the usage is simpler than the declaration suggests. The compiler deduces the
+template specialization, so the usage is like a simple function call.
+\skip std
+\until ;
+
+Most of the time you will probably use graph maps, but keep in mind, that in LEMON maps are more general and can be used widely.
+
+If you want some 'real-life' examples see the next page, where we discuss \ref algorithms
+(coming soon) and will use maps hardly.
+Or if you want to know more about maps read these \ref maps2 "advanced map techniques".
+*/
+
+}
Index: doc/maps2.dox
===================================================================
--- doc/maps2.dox	(revision 2568)
+++ doc/maps2.dox	(revision 2568)
@@ -0,0 +1,90 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/**
+\page maps2 Maps II.
+
+Here we discuss some advanced map techniques. Like writing your own maps or how to
+extend/modify a maps functionality with adaptors.
+
+\section custom_maps Writing Custom ReadMap
+\subsection custom_read_maps Readable Maps
+
+Readable maps are very frequently used as the input of an
+algorithm.  For this purpose the most straightforward way is the use of the
+default maps provided by LEMON's graph structures.
+Very often however, it is more
+convenient and/or more efficient to write your own readable map.
+
+You can find some examples below. In these examples \c Graph is the
+type of the particular graph structure you use.
+
+
+This simple map assigns \f$\pi\f$ to each edge.
+
+\code
+struct MyMap 
+{
+  typedef double Value;
+  typedef Graph::Edge Key;
+  double operator[](const Key &e) const { return PI;}
+};
+\endcode
+
+An alternative way to define maps is to use MapBase
+
+\code
+struct MyMap : public MapBase<Graph::Edge,double>
+{
+  Value operator[](const Key& e) const { return PI;}
+};
+\endcode
+
+Here is a bit more complex example.
+It provides a length function obtained
+from a base length function shifted by a potential difference.
+
+\code
+class ReducedLengthMap  : public MapBase<Graph::Edge,double>
+{
+  const Graph &g;
+  const Graph::EdgeMap<double> &orig_len;
+  const Graph::NodeMap<double> &pot;
+  
+public:
+  Value operator[](Key e) const {
+    return orig_len[e]-(pot[g.target(e)]-pot[g.source(e)]);
+  }
+  
+  ReducedLengthMap(const Graph &_g,
+                   const Graph::EdgeMap &_o,
+                   const Graph::NodeMap &_p)
+    : g(_g), orig_len(_o), pot(_p) {};
+};
+\endcode
+
+Then, you can call e.g. Dijkstra algoritm on this map like this:
+\code
+  ...
+  ReducedLengthMap rm(g,len,pot);
+  Dijkstra<Graph,ReducedLengthMap> dij(g,rm);
+  dij.run(s);
+  ...
+\endcode
+
+*/
Index: doc/named-param.dox
===================================================================
--- doc/named-param.dox	(revision 2553)
+++ doc/named-param.dox	(revision 2553)
@@ -0,0 +1,133 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/*!
+
+\page named-param Named Parameters
+
+\section named-func-param Named Function Parameters
+
+C++ makes it possible to use default parameter values when calling a
+function. In such a case we do not have to give value for parameters,
+the program will use the default ones.  Unfortunately sometimes this
+is not enough. If we do not want to give values for all the
+parameters, only for some of them we come across problems, because an
+arbitrary set of parameters cannot be omitted. On the other hand
+parameters have a fixed order in the head of the function.  C++ can
+apply the default values only in the back of the order, if we do not
+give other value for them.  So we can not give the function for
+example the value of the first, and the third parameter, expecting
+that the program will aplly the default value for the second
+parameter.  However sometimes we would like to use some functinos
+exactly in this way. With a crafty trick and with some little
+inconvenience this is possible. We have implemented this little trick
+as an example below.
+
+\code
+class namedFn 
+{
+  int _id;
+  double _val;
+  int _dim;
+  
+  public:
+  namedFn() : _id(0), _val(1), _dim(2) {}
+  namedFn& id(int p)     { _id  = p ; return *this; }
+  namedFn& val(double p) { _val = p ; return *this; }
+  namedFn& dim(int p)    { _dim = p ; return *this; }
+
+  run() {
+    printf("Here is the function itself.");
+  }
+};
+\endcode
+
+
+The usage is the following.
+
+We have to define a class, let's call it \c namedFn.  Let us assume that
+we would like to use a parameter, called \c X. In the \c namedFn class we
+have to define an \c _X attribute, and a function \c X. The function
+expects a parameter with the type of \c _X, and sets the value of
+\c _X. After setting the value the function returns the class itself. The
+class also have to have a function, called for example <tt>run()</tt>, we have
+to implement here the original function itself. The constructor of the
+class have to give all the attributes like \c _X the default values of
+them.
+
+If we instantiate this class, the default values will be set for the
+attributes (originally the parameters), initially. If we call function
+\c X, we get a class with the modified parameter value of
+\c X. Therefore we can modify any parameter-value, independently from the
+order. To run the algorithm we have to call the <tt>run()</tt> function at the
+end of the row.
+
+Example:
+\code
+namedFn().id(3).val(2).run();
+\endcode
+
+\note Although it is a class, namedFn is used pretty much like as it were
+a function. That it why it is called namedFn and not \c NamedFn.
+
+\note In fact, the final <tt>.run()</tt> could be made unnecessary if the
+actual function code were put in the destructor instead. This however would make
+hard to implement functions with return values, and would also make the
+implementation of \ref named-templ-func-param "named template parameters"
+very problematic. <b>Therefore, by convention, <tt>.run()</tt> must be used
+to explicitly execute function having named parameters in Lemon.</b>
+
+
+\section traits-classes Traits Classes
+
+The procedure above can also be applied when defining classes. In this
+case the type of the attributes can be changed.  Initially we have to
+define a class with the default attribute types. This is the so called
+Traits Class. Later on the types of these attributes can be changed,
+as described below. In our software \ref lemon::DijkstraDefaultTraits is an
+example of how a traits class looks like.
+
+\section named-templ-param Named Class Template Parameters
+
+If we would like to change the type of an attribute in a class that
+was instantiated by using a traits class as a template parameter, and
+the class contains named parameters, we do not have to reinstantiate
+the class with new traits class. Instead of that, adaptor classes can
+be used like in the following cases.
+
+\code
+Dijkstra<>::SetPredNodeMap<NullMap<Node,Node> >::Create
+\endcode
+
+It can also be used in conjunction with other named template
+parameters in arbitrary order.
+
+\code
+Dijkstra<>::SetDistMap<MyMap>::SetPredMap<NullMap<Node,Edge> >::Create
+\endcode
+
+The result will be an instantiated Dijkstra class, in which the
+DistMap and the PredMap is modified.
+
+\section named-templ-func-param Named Function Template Parameters
+
+If the class has so called wizard functions, the new class with the
+modified tpye of attributes can be returned by the appropriate wizard
+function. The usage of these wizard functions is the following:
+
+*/
Index: doc/namespaces.dox
===================================================================
--- doc/namespaces.dox	(revision 2655)
+++ doc/namespaces.dox	(revision 2553)
@@ -1,2 +1,20 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
 /// The namespace of LEMON
 
@@ -9,4 +27,4 @@
   /// The namespace of LEMON concepts and concept checking classes
   ///
-  namespace concept {}
+  namespace concepts {}
 }
Index: doc/quicktour.dox
===================================================================
--- doc/quicktour.dox	(revision 2553)
+++ doc/quicktour.dox	(revision 2553)
@@ -0,0 +1,257 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/**
+
+\page quicktour Quick Tour to LEMON
+
+Let us first answer the question <b>"What do I want to use LEMON for?"</b>. 
+LEMON is a C++ library, so you can use it if you want to write C++ 
+programs. What kind of tasks does the library LEMON help to solve? 
+It helps to write programs that solve optimization problems that arise
+frequently when <b>designing and testing certain networks</b>, for example
+in telecommunication, computer networks, and other areas that I cannot
+think of now. A very natural way of modelling these networks is by means
+of a <b> graph</b> (we will always mean a directed graph by that and say
+<b> undirected graph </b> otherwise). 
+So if you want to write a program that works with 
+graphs then you might find it useful to use our library LEMON. LEMON 
+defines various graph concepts depending on what you want to do with the 
+graph: a very good description can be found in the page
+about \ref graphs "graphs".
+
+You will also want to assign data to the edges or nodes of the graph, for
+example a length or capacity function defined on the edges. You can do this in
+LEMON using so called \b maps. You can define a map on the nodes or on the edges of the graph and the value of the map (the range of the function) can be practically almost of any type. Read more about maps \ref maps-page "here".
+
+In this quick tour we want to show you some facilities LEMON library can provide through examples (simple demo programs). The examples will only show part of the functionality, but links will always be given to reach complete details. 
+You will find links next to the code fragments that help to download full demo programs: save them on your computer and compile them according to the description in the page about \ref getstart "How to start using LEMON". 
+
+Have fun!
+
+<ul> <li> The first thing to discuss is the way one can create data structures
+like graphs and maps in a program using LEMON. 
+//There are more graph types
+//implemented in LEMON and you can implement your own graph type just as well:
+//read more about this in the already mentioned page on \ref graphs "graphs".
+
+First we show how to add nodes and edges to a graph manually. We will also
+define a map on the edges of the graph. After this we show the way one can
+read a graph (and perhaps maps on it) from a stream (e.g. a file). Of course
+we also have routines that write a graph (and perhaps maps) to a stream
+(file): this will also be shown. LEMON supports the DIMACS file formats to
+read network optimization problems, but more importantly we also have our own
+file format that gives a more flexible way to store data related to network
+optimization.
+
+<ol> <li>The following code shows how to build a graph from scratch
+and iterate on its nodes and edges.  This example also shows how to
+give a map on the edges of the graph.  The type Listgraph is one of
+the LEMON graph types: the typedefs in the beginning are for
+convenience and we will assume them later as well.
+
+\dontinclude hello_lemon.cc
+\skip include
+\until }
+
+See the whole program in file \ref hello_lemon.cc in the \c demo subdir of
+LEMON package.
+
+    If you want to read more on the LEMON graph structures and
+concepts, read the page about \ref graphs "graphs".
+
+
+<li>LEMON has an own file format for storing graphs, maps on edges/nodes and some other things. Instead of any explanation let us give a
+short example file in this format: read the detailed description of the LEMON
+graph file format and input-output routines here: \ref graph-io-page.
+
+So here is a file describing a graph of 6 nodes (0 to 5), two nodemaps
+(called \c coordinates_x and \c coordinates_y), several edges, an edge map
+called \c capacity and two designated nodes (called \c source and \c target).
+
+\verbatim
+@nodeset
+id      coordinates_x   coordinates_y
+5       796.398 208.035
+4       573.002 63.002
+3       568.549 401.748
+2       277.889 68.476
+1       288.248 397.327
+0       102.239 257.532
+@edgeset
+                id      capacity
+4       5       6       8
+3       5       5       8
+2       4       4       5
+1       4       3       8
+1       3       2       5
+0       2       1       10
+0       1       0       10
+#This is a comment here
+@nodes
+source 0
+target 5
+@edges 
+@attributes 
+author "Attila BERNATH"
+@end
+\endverbatim
+
+Finally let us give a simple example that reads a graph from a file and writes
+it to the standard output.
+
+\dontinclude reader_writer_demo.cc
+\skip include
+\until return
+\until }
+
+See the whole program in file \ref reader_writer_demo.cc.
+
+<li> The following code shows how to read a graph from a stream
+(e.g. a file) in the DIMACS file format (find the documentation of the
+DIMACS file formats on the web).
+
+\code
+Graph g;
+std::ifstream f("graph.dim");
+readDimacs(f, g);
+\endcode
+
+One can also store network (graph+capacity on the edges) instances and
+other things (minimum cost flow instances etc.) in DIMACS format and
+read these in LEMON: to see the details read the documentation of the
+\ref dimacs.h "Dimacs file format reader". 
+
+</ol>
+<li> If you want to solve some transportation problems in a network then 
+you will want to find shortest paths between nodes of a graph. This is 
+usually solved using Dijkstra's algorithm. A utility
+that solves this is  the \ref lemon::Dijkstra "LEMON Dijkstra class".
+The following code is a simple program using the 
+\ref lemon::Dijkstra "LEMON Dijkstra class": it calculates the shortest path between node \c s and \c t in a graph \c g.
+We omit the part reading the graph  \c g and the length map \c len.
+
+\dontinclude dijkstra_demo.cc
+\skip ListGraph
+\until Graph g
+...
+\skip Dijkstra algorithm
+\until std::cout << g.id(s)
+
+See the whole program in \ref dijkstra_demo.cc.
+
+Some explanation: after instantiating a member of the Dijkstra class
+we run the Dijkstra algorithm from node \c s. After this we read some
+of the results.  You can do much more with the Dijkstra class, for
+example you can run it step by step and gain full control of the
+execution. For a detailed description, see the documentation of the
+\ref lemon::Dijkstra "LEMON Dijkstra class".
+
+
+<li> If you want to design a network and want to minimize the total
+length of wires then you might be looking for a <b>minimum spanning
+tree</b> in an undirected graph. This can be found using the Kruskal
+algorithm: the function \ref lemon::kruskal "LEMON Kruskal " does this
+job for you.  
+
+First make a graph \c g and a cost map \c
+edge_cost_map, then make a bool edgemap \c tree_map or a vector \c
+tree_edge_vec for the algorithm output. After calling the function it
+gives back the weight of the minimum spanning tree and the \c tree_map or
+the \c tree_edge_vec contains the edges of the tree.
+
+If you want to store the edges in a bool edgemap, then use the
+function as follows:
+
+\dontinclude kruskal_demo.cc
+\skip Kruskal with boolmap; 
+\until  std::endl
+
+And if you rather use a vector instead of a bool map:
+
+\skip Kruskal with vector; 
+\until std::endl
+
+See the whole program in \ref kruskal_demo.cc.
+
+
+
+<li>Many problems in network optimization can be formalized by means
+of a linear programming problem (LP problem, for short). In our
+library we decided not to write an LP solver, since such packages are
+available in the commercial world just as well as in the open source
+world, and it is also a difficult task to compete these. Instead we
+decided to develop an interface that makes it easier to use these
+solvers together with LEMON. The advantage of this approach is
+twofold. Firstly our C++ interface is more comfortable than the
+solvers' native interface. Secondly, changing the underlying solver in
+a certain software using LEMON's LP interface needs zero effort. So,
+for example, one may try his idea using a free solver, demonstrate its
+usability for a customer and if it works well, but the performance
+should be improved, then one may decide to purchase and use a better
+commercial solver.
+
+So far we have an
+interface for the commercial LP solver software \b CPLEX (developed by ILOG)
+and for the open source solver \b GLPK (a shorthand for Gnu Linear Programming
+Toolkit).
+
+We will show two examples, the first one shows how simple it is to formalize
+and solve an LP problem in LEMON, while the second one shows how LEMON
+facilitates solving network optimization problems using LP solvers.
+
+<ol>
+<li>The following code shows how to solve an LP problem using the LEMON lp
+interface. The code together with the comments is self-explanatory.
+
+\dontinclude lp_demo.cc
+\skip A default solver is taken
+\until End of LEMON style code
+
+See the whole code in \ref lp_demo.cc.
+
+<li>The second example shows how easy it is to formalize a max-flow
+problem as an LP problem using the LEMON LP interface: we are looking
+for a real valued function defined on the edges of the digraph
+satisfying the nonnegativity-, the capacity constraints and the
+flow-conservation constraints and giving the largest flow value
+between to designated nodes.
+
+In the following code we suppose that we already have the graph \c g,
+the capacity map \c cap, the source node \c s and the target node \c t
+in the memory. We will also omit the typedefs.
+
+\dontinclude lp_maxflow_demo.cc
+\skip Define a map on the edges for the variables of the LP problem
+\until lp.max();
+\skip Solve with the underlying solver
+\until lp.solve();
+
+
+The complete program can be found in file \ref lp_maxflow_demo.cc. After compiling run it in the form:
+
+<tt>./lp_maxflow_demo < sample.lgf</tt>
+
+where sample.lgf is a file in the lemon format containing a maxflow instance (designated "source", "target" nodes and "capacity" map on the edges).
+
+
+
+</ol>
+</ul>
+
+*/
Index: doc/read_write_bg.dox
===================================================================
--- doc/read_write_bg.dox	(revision 2553)
+++ doc/read_write_bg.dox	(revision 2553)
@@ -0,0 +1,237 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+/*!
+\page read_write_bg Background of Reading and Writing
+
+To read a map (on the nodes or edges)
+the \ref lemon::GraphReader "GraphReader"
+should know how to read a Value from the given map.
+By the default implementation the input operator reads a value from
+the stream and the type of the read value is the value type of the given map.
+When the reader should skip a value in the stream, because you do not
+want to store it in a map, the reader skips a character sequence without 
+whitespaces. 
+
+If you want to change the functionality of the reader, you can use
+template parameters to specialize it. When you give a reading
+command for a map you can give a Reader type as template parameter.
+With this template parameter you can control how the Reader reads
+a value from the stream.
+
+The reader has the next structure: 
+\code
+struct TypeReader {
+  typedef TypeName Value;
+
+  void read(std::istream& is, Value& value);
+};
+\endcode
+
+For example, the \c "strings" nodemap contains strings and you do not need
+the value of the string just the length. Then you can implement an own Reader
+struct.
+
+\code
+struct LengthReader {
+  typedef int Value;
+
+  void read(std::istream& is, Value& value) {
+    std::string tmp;
+    is >> tmp;
+    value = tmp.length();
+  }
+};
+...
+reader.readNodeMap<LengthReader>("strings", lengthMap);
+\endcode  
+
+The global functionality of the reader class can be changed by giving a
+special template parameter to the GraphReader class. By default, the
+template parameter is \c DefaultReaderTraits. A reader traits class 
+should provide a nested template class Reader for each type, and a 
+DefaultReader for skipping a value.
+
+The specialization of writing is very similar to that of reading.
+
+\section u Undirected graphs
+
+In a file describing an undirected graph (ugraph, for short) you find an
+\c uedgeset section instead of the \c edgeset section. The first line of
+the section describes the names of the maps on the undirected egdes and all
+next lines describe one undirected edge with the the incident nodes and the
+values of the map.
+
+The format handles directed edge maps as a syntactical sugar???, if there
+are two maps with names being the same with a \c '+' and a \c '-' prefix
+then this will be read as a directed map.
+
+\code
+@uedgeset
+             label      capacity        +flow   -flow
+32   2       1          4.3             2.0     0.0
+21   21      5          2.6             0.0     2.6
+21   12      8          3.4             0.0     0.0
+\endcode
+
+The \c edges section is changed to \c uedges section. This section
+describes labeled edges and undirected edges. The directed edge label
+should start with a \c '+' or a \c '-' prefix to decide the direction
+of the edge. 
+
+\code
+@uedges
+uedge 1
++edge 5
+-back 5
+\endcode
+
+There are similar classes to the \ref lemon::GraphReader "GraphReader" and
+\ref lemon::GraphWriter "GraphWriter" which
+handle the undirected graphs. These classes are
+the \ref lemon::UGraphReader "UGraphReader"
+and \ref lemon::UGraphWriter "UGraphWriter".
+
+The \ref lemon::UGraphReader::readUEdgeMap() "readUEdgeMap()"
+function reads an undirected map and the
+\ref lemon::UGraphReader::readUEdge() "readUEdge()"
+reads an undirected edge from the file, 
+
+\code
+reader.readUEdgeMap("capacity", capacityMap);
+reader.readEdgeMap("flow", flowMap);
+...
+reader.readUEdge("u_edge", u_edge);
+reader.readEdge("edge", edge);
+\endcode
+
+\section advanced Advanced features
+
+The graph reader and writer classes give an easy way to read and write
+graphs. But sometimes we want more advanced features. In this case we can
+use the more general <tt>lemon reader and writer</tt> interface.
+
+The LEMON file format is a section oriented file format. It contains one or
+more sections, each starting with a line identifying its type 
+(the word starting with the \c \@  character).
+The content of the section this way cannot contain line with \c \@ first
+character. The file may contains comment lines with \c # first character.
+
+The \ref lemon::LemonReader "LemonReader"
+and \ref lemon::LemonWriter "LemonWriter"
+gives a framework to read and
+write sections. There are various section reader and section writer
+classes which can be attached to a \ref lemon::LemonReader "LemonReader"
+or a \ref lemon::LemonWriter "LemonWriter".
+
+There are default section readers and writers for reading and writing
+item sets, and labeled items in the graph. These read and write
+the format described above. Other type of data can be handled with own
+section reader and writer classes which are inherited from the
+\c LemonReader::SectionReader or the
+\ref lemon::LemonWriter::SectionWriter "LemonWriter::SectionWriter"
+classes.
+
+The next example defines a special section reader which reads the
+\c \@description sections into a string:
+
+\code 
+class DescriptionReader : LemonReader::SectionReader {
+protected:
+  virtual bool header(const std::string& line) {
+    std::istringstream ls(line);
+    std::string head;
+    ls >> head;
+    return head == "@description";
+  }
+
+  virtual void read(std::istream& is) {
+    std::string line;
+    while (getline(is, line)) {
+      desc += line;
+    }
+  }
+public:
+
+  typedef LemonReader::SectionReader Parent;
+  
+  DescriptionReader(LemonReader& reader) : Parent(reader) {}
+
+  const std::string& description() const {
+    return description;
+  }
+
+private:
+  std::string desc;
+};
+\endcode
+
+The other advanced stuff of the generalized file format is that 
+multiple edgesets can be stored to the same nodeset. It can be used 
+for example as a network traffic matrix.
+
+In our example there is a network with symmetric links and there are assymetric
+traffic request on the network. This construction can be stored in an
+undirected graph and in a directed \c ListEdgeSet class. The example
+shows the input with the \ref lemon::LemonReader "LemonReader" class:
+
+\code
+ListUGraph network;
+ListUGraph::UEdgeMap<double> capacity;
+ListEdgeSet<ListUGraph> traffic(network);
+ListEdgeSet<ListUGraph>::EdgeMap<double> request(network);
+
+LemonReader reader(std::cin);
+NodeSetReader<ListUGraph> nodesetReader(reader, network);
+UEdgeSetReader<ListUGraph> 
+  uEdgesetReader(reader, network, nodesetReader);
+uEdgesetReader.readEdgeMap("capacity", capacity);
+EdgeSetReader<ListEdgeSet<ListUGraph> > 
+  edgesetReader(reader, traffic, nodesetReader, "traffic");
+edgesetReader.readEdgeMap("request", request);
+
+reader.run();
+\endcode
+
+Because both the \ref lemon::GraphReader "GraphReader"
+and the \ref lemon::UGraphReader "UGraphReader" can be converted
+to \ref lemon::LemonReader "LemonReader"
+and it can resolve the label's of the items, the previous
+result can be achived with the \ref lemon::UGraphReader "UGraphReader"
+class, too.
+
+
+\code
+ListUGraph network;
+ListUGraph::UEdgeSet<double> capacity;
+ListEdgeSet<ListUGraph> traffic(network);
+ListEdgeSet<ListUGraph>::EdgeMap<double> request(network);
+
+UGraphReader<ListUGraph> reader(std::cin, network);
+reader.readEdgeMap("capacity", capacity);
+EdgeSetReader<ListEdgeSet<ListUGraph> > 
+  edgesetReader(reader, traffic, reader, "traffic");
+edgesetReader.readEdgeMap("request", request);
+
+reader.run();
+\endcode
+
+\author Balazs Dezso
+*/
+}
Index: doc/template.h
===================================================================
--- doc/template.h	(revision 2553)
+++ doc/template.h	(revision 2553)
@@ -0,0 +1,22 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_TEMPLATE_H
+#define LEMON_TEMPLATE_H
+
+#endif // LEMON_TEMPLATE_H
Index: doc/tutorial.dox
===================================================================
--- doc/tutorial.dox	(revision 2553)
+++ doc/tutorial.dox	(revision 2553)
@@ -0,0 +1,67 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+namespace lemon {
+/**
+\page Tutorial LEMON Tutorial
+
+<H2>Table of Contents</H2>
+
+<OL style="padding-bottom: 60px">
+  <LI>\ref intro
+  <LI>\ref getting_started
+  <UL>
+    <LI>\ref hello_world
+    <LI>\ref compile_hw
+  </UL>
+  <LI>\ref basic_concepts
+  <UL>
+    <LI>\ref basic_ListGraph
+    <LI>\ref maps1
+  </UL>
+  <LI>\ref lemon_file_format
+  <UL>
+    <LI>\ref read_write_bg
+  </UL>
+  <LI>\ref algorithms
+  <UL>
+    <LI>\ref algo_bfs_dfs
+    <LI>\ref algo_dijkstra
+    <LI>\ref algo_kruskal
+  </UL>
+  <LI>\ref maps2
+  <UL>
+    <LI>\ref custom_maps
+    <LI>Map Adaptors
+    <LI>Special Purpose Maps
+  </UL>
+  <LI>\ref show_a_graph
+  <LI>Miscellaneous Tool
+  <UL>
+    <LI>LP solver
+    <LI>Simulated Annealing
+  </UL>
+</OL>
+
+\section intro Introduction
+In this tutorial we try to show you as many aspects of LEMON as possible. From
+the basics to the very advanced or highly optimized tools. The given examples
+are all available in \c demo directory, so feel free to look at them after the
+sections.
+*/
+}
Index: doc/ugraphs.dox
===================================================================
--- doc/ugraphs.dox	(revision 2553)
+++ doc/ugraphs.dox	(revision 2553)
@@ -0,0 +1,27 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/*!
+
+\page ugraphs Undirected graph structures
+
+The primary data structures of LEMON are the graph classes.
+
+Under construction.
+
+*/
Index: mon-stable.org
===================================================================
--- lemon-stable.org	(revision 2657)
+++ 	(revision )
@@ -1,83 +1,0 @@
-The LEMON-STABLE project  -*- mode: org; -*-
-
-#+TYP_TODO: TODO Ákos Alpár Attila Balázs Márk Jácint Péter ALL DONE
-
-* TODO Release 0.6 before any major changes in svn-trunk
-** Do we really need it?
-* DONE Separate GLEMON from LEMON
-** It should go to https://hugo.cs.elte.hu/svn/glemon/trunk
-** TODO Probably the main lemon trunk should also be renamed to
-   https://hugo.cs.elte.hu/svn/lemon/trunk
-* DONE Change to single makefile
-* DONE Set up a compilation environment in branches/lemon-1.0
-** Copy from the trunk
-** Comment out the missing files
-* TODO Revise/Clarify/Extend the naming conventions
-** setXYZ/getXYZ issue
-** class-local variables vs. access functions to them
-** standard naming rules for function/template parameters
-** template<class X> vs. template<typename X>
-* TODO Revise doc (globally)
-** Revise the module structures
-** Revise 'Related Pages'
-*** Intro/Tutorials
-**** What are missing?
-**** Aren't there some duplications?
-*** TODO Which include file is needed for a cartain macro?
-**** Say GRAPH_TYPEDEFS?
-
-* Revise Basic components
-** Graph Structures
-*** ALL Directed Graphs
-**** DONE Do we need concepts other than StaticGraph?
-***** If don't, rename StaticGraph to Graph
-**** Attila Revise doc
-**** TODO Revise check files
-**** DONE Disable copy constr's
-**** Concept doc:
-***** TODO NodeMap, EdgeMap
-***** TODO Why id() is not in the concept?
-***** TODO maxNodeNum(), maxEdgeNum?
-*** TODO Undirected Graph
-**** Revise doc
-**** Revise check files
-*** TODO Bipartite Graphs
-**** Revise doc
-**** Revise check files
-** Exceptions
-*** Ákos Revise error.h
-*** TODO Document if a function may throw an exception
-**** Use \exception for that
-** TODO Put ListUGraph into a separate header file
-* TODO Revise Tools
-** Graph Adaptors
-*** Revise doc
-*** Revise check files
-** Map Structures
-*** Special Maps
-*** Map Adaptors
-** Graph I/O
-*** Change @uedgeset to @edgeset
-** Graph Drawing
-** xy
-*** Doesn't follow the naming convention
-*** Should normSquare() be a member function?
-*** What about bezier.h
-*** What about linear transformations?
-*** What about xyz.h?
-* TODO Revise Algorithms
-* TODO Revise repository maintenance files
-** Péter Related files
-*** AUTHORS
-*** ChangeLog
-*** COPYING
-*** INSTALL
-*** LICENSE
-*** NEWS
-*** README
-* TODO Revise demos
-** What are missing?
-** What are superfluous?
-** Documentation
-** Add links from the doc of a data struct/alg to the related demo
-*** Create a \demo macro similar to \sa
Index: lemon.spec.in
===================================================================
--- lemon.spec.in	(revision 2241)
+++ lemon.spec.in	(revision 2241)
@@ -0,0 +1,46 @@
+Summary: A C++ template library aimed at combinatorial optimization tasks.
+Name: @PACKAGE_TARNAME@
+Version: @PACKAGE_VERSION@
+Release: 1
+License: Boost
+URL: http://lemon.cs.elte.hu
+Source0: %{name}-%{version}.tar.gz
+Group: Development/Libraries
+BuildRoot: %{_tmppath}/%{name}-root
+Requires: glpk
+BuildRequires: glpk-devel
+Provides: lemon = @PACKAGE_VERSION@
+Provides: lemon-devel = @PACKAGE_VERSION@
+
+
+%description
+LEMON stands for Library of Efficient Models and
+Optimization in Networks. It is a C++ template
+library aimed at combinatorial optimization tasks,
+especially those working with graphs and networks.
+
+%prep
+%setup -q
+
+%build
+%configure --with-glpk --without-cplex
+make
+
+%install
+rm -rf $RPM_BUILD_ROOT
+make DESTDIR=$RPM_BUILD_ROOT install
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post -p /sbin/ldconfig
+
+%postun -p /sbin/ldconfig
+
+%files
+%defattr(-,root,root)
+%{_includedir}/%{name}
+%{_libdir}/lib*
+%{_libdir}/pkgconfig/lemon.pc
+%doc %{_datadir}/doc/%{name}
+%doc AUTHORS COPYING LICENSE NEWS README
Index: lemon/Makefile.am
===================================================================
--- lemon/Makefile.am	(revision 2658)
+++ lemon/Makefile.am	(revision 2607)
@@ -8,117 +8,157 @@
 
 lemon_libemon_la_SOURCES = \
-##	lemon/lp_base.cc \
-##	lemon/lp_skeleton.cc \
+	lemon/arg_parser.cc \
+	lemon/lp_base.cc \
+	lemon/lp_utils.cc \
+	lemon/lp_skeleton.cc \
 	lemon/base.cc \
-	lemon/color.cc
-##	lemon/eps.cc \
-##	lemon/bits/mingw32_rand.cc \
-##	lemon/bits/mingw32_time.cc
+	lemon/color.cc \
+	lemon/eps.cc \
+	lemon/bits/mingw32_time.cc \
+	lemon/random.cc
 
-lemon_libemon_la_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS)
-lemon_libemon_la_LDFLAGS = $(GLPK_LIBS) $(CPLEX_LIBS)
+lemon_libemon_la_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS) $(SOPLEX_CXXFLAGS)
+lemon_libemon_la_LDFLAGS = $(GLPK_LIBS) $(CPLEX_LIBS) $(SOPLEX_LIBS)
 
 if HAVE_GLPK
-##lemon_libemon_la_SOURCES += lemon/lp_glpk.cc
+lemon_libemon_la_SOURCES += lemon/lp_glpk.cc
+lemon_libemon_la_SOURCES += lemon/mip_glpk.cc
 endif
 
 if HAVE_CPLEX
-##lemon_libemon_la_SOURCES += lemon/lp_cplex.cc
+lemon_libemon_la_SOURCES += lemon/lp_cplex.cc
+lemon_libemon_la_SOURCES += lemon/mip_cplex.cc
+endif
+
+if HAVE_SOPLEX
+lemon_libemon_la_SOURCES += lemon/lp_soplex.cc
 endif
 
 lemon_HEADERS += \
-##	lemon/bellman_ford.h \
-##	lemon/bezier.h \
-##	lemon/bfs.h \
-##	lemon/bin_heap.h \
-##	lemon/bipartite_matching.h \
-##	lemon/bpugraph_adaptor.h \
-##	lemon/bucket_heap.h \
+	lemon/arg_parser.h \
+	lemon/bellman_ford.h \
+	lemon/bfs.h \
+	lemon/bin_heap.h \
+	lemon/bipartite_matching.h \
+	lemon/bpugraph_adaptor.h \
+	lemon/bucket_heap.h \
+	lemon/capacity_scaling.h \
+	lemon/circulation.h \
 	lemon/color.h \
-##	lemon/config.h \
-##	lemon/counter.h \
-##	lemon/dag_shortest_path.h \
-##	lemon/dfs.h \
-##	lemon/dijkstra.h \
+	lemon/config.h \
+	lemon/concept_check.h \
+	lemon/cost_scaling.h \
+	lemon/counter.h \
+	lemon/csp.h \
+	lemon/cycle_canceling.h \
+	lemon/dag_shortest_path.h \
+	lemon/dfs.h \
+	lemon/dijkstra.h \
+	lemon/dinitz_sleator_tarjan.h \
+	lemon/dist_log.h \
 	lemon/dim2.h \
-##	lemon/dimacs.h \
-##	lemon/edge_set.h \
-##	lemon/edmonds_karp.h \
-##	lemon/eps.h \
-##	lemon/error.h \
-##	lemon/fib_heap.h \
-##	lemon/floyd_warshall.h \
-##	lemon/fredman_tarjan.h \
-##	lemon/full_graph.h \
-##	lemon/graph_adaptor.h \
-##	lemon/graph_reader.h \
-##	lemon/graph_to_eps.h \
-##	lemon/graph_utils.h \
-##	lemon/graph_writer.h \
-##	lemon/grid_ugraph.h \
-##	lemon/hypercube_graph.h \
-##	lemon/iterable_maps.h \
-##	lemon/johnson.h \
-##	lemon/kruskal.h \
-##	lemon/lemon_reader.h \
-##	lemon/lemon_writer.h \
-##	lemon/list_graph.h \
-##	lemon/lp.h \
-##	lemon/lp_base.h \
-##	lemon/lp_cplex.h \
-##	lemon/lp_glpk.h \
-##	lemon/lp_skeleton.h \
-##	lemon/map_iterator.h \
-##	lemon/maps.h \
-##	lemon/matrix_maps.h \
-##	lemon/max_matching.h \
-##	lemon/min_cost_arborescence.h \
-##	lemon/min_cost_flow.h \
-##	lemon/min_cut.h \
-##	lemon/path.h \
-##	lemon/polynomial.h \
-##	lemon/preflow.h \
-##	lemon/prim.h \
-##	lemon/radix_heap.h \
-##	lemon/radix_sort.h \
-##	lemon/refptr.h \
-##	lemon/simann.h \
-##	lemon/smart_graph.h \
-##	lemon/sub_graph.h \
-##	lemon/suurballe.h \
-##	lemon/tabu_search.h \
-##	lemon/time_measure.h \
-	lemon/tolerance.h
-##	lemon/topology.h \
-##	lemon/ugraph_adaptor.h \
-##	lemon/unionfind.h \
-##	lemon/xy.h
+	lemon/dimacs.h \
+	lemon/dynamic_tree.h \
+	lemon/edge_set.h \
+	lemon/edmonds_karp.h \
+	lemon/elevator.h \
+	lemon/eps.h \
+	lemon/error.h \
+	lemon/euler.h \
+	lemon/fib_heap.h \
+	lemon/floyd_warshall.h \
+	lemon/fredman_tarjan.h \
+	lemon/full_graph.h \
+	lemon/graph_adaptor.h \
+	lemon/graph_reader.h \
+	lemon/graph_to_eps.h \
+	lemon/graph_utils.h \
+	lemon/graph_writer.h \
+	lemon/grid_ugraph.h \
+	lemon/goldberg_tarjan.h \
+	lemon/gomory_hu_tree.h \
+	lemon/hao_orlin.h \
+	lemon/hypercube_graph.h \
+	lemon/iterable_maps.h \
+	lemon/johnson.h \
+	lemon/kruskal.h \
+	lemon/lemon_reader.h \
+	lemon/lemon_writer.h \
+	lemon/list_graph.h \
+	lemon/lp.h \
+	lemon/lp_base.h \
+	lemon/lp_cplex.h \
+	lemon/lp_glpk.h \
+	lemon/lp_skeleton.h \
+	lemon/lp_soplex.h \
+	lemon/lp_utils.h \
+	lemon/map_iterator.h \
+	lemon/maps.h \
+	lemon/math.h \
+	lemon/matrix_maps.h \
+	lemon/max_matching.h \
+	lemon/min_cost_arborescence.h \
+	lemon/min_cost_flow.h \
+	lemon/min_cost_max_flow.h \
+	lemon/min_mean_cycle.h \
+	lemon/mip_glpk.h \
+	lemon/mip_cplex.h \
+	lemon/nagamochi_ibaraki.h \
+	lemon/nauty_reader.h \
+	lemon/network_simplex.h \
+	lemon/path.h \
+	lemon/path_utils.h \
+	lemon/planarity.h \
+	lemon/polynomial.h \
+	lemon/preflow.h \
+	lemon/prim.h \
+	lemon/pr_bipartite_matching.h \
+	lemon/radix_heap.h \
+	lemon/radix_sort.h \
+	lemon/random.h \
+	lemon/refptr.h \
+	lemon/simann.h \
+	lemon/smart_graph.h \
+	lemon/static_graph.h \
+	lemon/steiner.h \
+	lemon/sub_graph.h \
+	lemon/suurballe.h \
+	lemon/tabu_search.h \
+	lemon/time_measure.h \
+	lemon/tolerance.h \
+	lemon/topology.h \
+	lemon/ugraph_adaptor.h \
+	lemon/unionfind.h
 
-bits_HEADERS +=
-##	lemon/bits/alteration_notifier.h \
-##	lemon/bits/array_map.h \
-##	lemon/bits/base_extender.h \
-##	lemon/bits/default_map.h \
-##	lemon/bits/edge_set_extender.h \
-##	lemon/bits/graph_adaptor_extender.h \
-##	lemon/bits/graph_extender.h \
-	lemon/bits/invalid.h
-##	lemon/bits/item_reader.h \
-##	lemon/bits/item_writer.h \
-##	lemon/bits/map_extender.h \
-##	lemon/bits/mingw32_rand.h \
-##	lemon/bits/mingw32_time.h \
-##	lemon/bits/traits.h \
-##	lemon/bits/utility.h \
-##	lemon/bits/vector_map.h
+bits_HEADERS += \
+	lemon/bits/alteration_notifier.h \
+	lemon/bits/array_map.h \
+	lemon/bits/base_extender.h \
+	lemon/bits/bezier.h \
+	lemon/bits/debug_map.h \
+	lemon/bits/default_map.h \
+	lemon/bits/edge_set_extender.h \
+	lemon/bits/graph_adaptor_extender.h \
+	lemon/bits/graph_extender.h \
+	lemon/bits/invalid.h \
+	lemon/bits/item_reader.h \
+	lemon/bits/item_writer.h \
+	lemon/bits/lp_id.h \
+	lemon/bits/map_extender.h \
+	lemon/bits/mingw32_time.h \
+	lemon/bits/path_dump.h \
+	lemon/bits/traits.h \
+	lemon/bits/utility.h \
+	lemon/bits/variant.h \
+	lemon/bits/vector_map.h
 
-concept_HEADERS +=
-##	lemon/concept_check.h \
-##	lemon/concept/bpugraph.h \
-##	lemon/concept/graph.h \
-##	lemon/concept/graph_component.h \
-##	lemon/concept/heap.h \
-##	lemon/concept/maps.h \
-##	lemon/concept/matrix_maps.h \
-##	lemon/concept/path.h \
-##	lemon/concept/ugraph.h
+concept_HEADERS += \
+	lemon/concept_check.h \
+	lemon/concepts/bpugraph.h \
+	lemon/concepts/graph.h \
+	lemon/concepts/graph_components.h \
+	lemon/concepts/heap.h \
+	lemon/concepts/maps.h \
+	lemon/concepts/matrix_maps.h \
+	lemon/concepts/path.h \
+	lemon/concepts/ugraph.h
Index: lemon/arg_parser.cc
===================================================================
--- lemon/arg_parser.cc	(revision 2553)
+++ lemon/arg_parser.cc	(revision 2553)
@@ -0,0 +1,469 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/arg_parser.h>
+
+namespace lemon {
+
+  void ArgParser::_showHelp(void *p)
+  {
+    (static_cast<ArgParser*>(p))->showHelp();
+    exit(1);
+  }
+
+  ArgParser::ArgParser(int argc, const char **argv) :_argc(argc), _argv(argv),
+                                                     _command_name(argv[0]) {
+    funcOption("-help","Print a short help message",_showHelp,this);
+    synonym("help","-help");
+    synonym("h","-help");
+
+  }
+
+  ArgParser::~ArgParser()
+  {
+    for(Opts::iterator i=_opts.begin();i!=_opts.end();++i)
+      if(i->second.self_delete)
+	switch(i->second.type) {
+	case BOOL:
+	  delete i->second.bool_p;
+	  break;
+	case STRING:
+	  delete i->second.string_p;
+	  break;
+	case DOUBLE:
+	  delete i->second.double_p;
+	  break;
+	case INTEGER:
+	  delete i->second.int_p;
+	  break;
+	case UNKNOWN:
+	  break;
+	case FUNC:
+	  break;
+	}
+  }
+  
+
+  ArgParser &ArgParser::intOption(const std::string &name,
+			       const std::string &help,
+			       int value, bool obl)
+  {
+    ParData p;
+    p.int_p=new int(value);
+    p.self_delete=true;
+    p.help=help;
+    p.type=INTEGER;
+    p.mandatory=obl;
+    p.self_delete=true;
+    _opts[name]=p;
+    return *this;
+  }
+
+  ArgParser &ArgParser::doubleOption(const std::string &name,
+			       const std::string &help,
+			       double value, bool obl)
+  {
+    ParData p;
+    p.double_p=new double(value);
+    p.self_delete=true;
+    p.help=help;
+    p.type=DOUBLE;
+    p.mandatory=obl;
+    _opts[name]=p;
+    return *this;
+  }
+
+  ArgParser &ArgParser::boolOption(const std::string &name,
+			       const std::string &help,
+			       bool value, bool obl)
+  {
+    ParData p;
+    p.bool_p=new bool(value);
+    p.self_delete=true;
+    p.help=help;
+    p.type=BOOL;
+    p.mandatory=obl;
+    _opts[name]=p;
+
+    value = false;
+
+    return *this;
+  }
+
+  ArgParser &ArgParser::stringOption(const std::string &name,
+			       const std::string &help,
+			       std::string value, bool obl)
+  {
+    ParData p;
+    p.string_p=new std::string(value);
+    p.self_delete=true;
+    p.help=help;
+    p.type=STRING;
+    p.mandatory=obl;
+    _opts[name]=p;
+    return *this;
+  }
+
+  ArgParser &ArgParser::refOption(const std::string &name,
+			       const std::string &help,
+			       int &ref, bool obl)
+  {
+    ParData p;
+    p.int_p=&ref;
+    p.self_delete=false;
+    p.help=help;
+    p.type=INTEGER;
+    p.mandatory=obl;
+    _opts[name]=p;
+    return *this;
+  }
+
+  ArgParser &ArgParser::refOption(const std::string &name,
+                                  const std::string &help,
+                                  double &ref, bool obl)
+  {
+    ParData p;
+    p.double_p=&ref;
+    p.self_delete=false;
+    p.help=help;
+    p.type=DOUBLE;
+    p.mandatory=obl;
+    _opts[name]=p;
+    return *this;
+  }
+
+  ArgParser &ArgParser::refOption(const std::string &name,
+                                  const std::string &help,
+                                  bool &ref, bool obl)
+  {
+    ParData p;
+    p.bool_p=&ref;
+    p.self_delete=false;
+    p.help=help;
+    p.type=BOOL;
+    p.mandatory=obl;
+    _opts[name]=p;
+
+    ref = false;
+
+    return *this;
+  }
+
+  ArgParser &ArgParser::refOption(const std::string &name,
+			       const std::string &help,
+			       std::string &ref, bool obl)
+  {
+    ParData p;
+    p.string_p=&ref;
+    p.self_delete=false;
+    p.help=help;
+    p.type=STRING;
+    p.mandatory=obl;
+    _opts[name]=p;
+    return *this;
+  }
+
+  ArgParser &ArgParser::funcOption(const std::string &name,
+			       const std::string &help,
+			       void (*func)(void *),void *data)
+  {
+    ParData p;
+    p.func_p.p=func;
+    p.func_p.data=data;
+    p.self_delete=false;
+    p.help=help;
+    p.type=FUNC;
+    p.mandatory=false;
+    _opts[name]=p;
+    return *this;
+  }
+
+  ArgParser &ArgParser::optionGroup(const std::string &group,
+				    const std::string &opt)
+  {
+    Opts::iterator i = _opts.find(opt);
+    LEMON_ASSERT(i!=_opts.end(), "Unknown option: '"+opt+"'");
+    LEMON_ASSERT(!(i->second.ingroup), 
+                 "Option already in option group: '"+opt+"'");
+    GroupData &g=_groups[group];
+    g.opts.push_back(opt);
+    i->second.ingroup=true;
+    return *this;
+  }
+
+  ArgParser &ArgParser::onlyOneGroup(const std::string &group)
+  {
+    GroupData &g=_groups[group];
+    g.only_one=true;
+    return *this;
+  }
+
+  ArgParser &ArgParser::synonym(const std::string &syn,
+				const std::string &opt)
+  {
+    Opts::iterator o = _opts.find(opt);
+    Opts::iterator s = _opts.find(syn);
+    LEMON_ASSERT(o!=_opts.end(), "Unknown option: '"+opt+"'");
+    LEMON_ASSERT(s==_opts.end(), "Option already used: '"+syn+"'");
+    ParData p;
+    p.help=opt;
+    p.mandatory=false;
+    p.syn=true;
+    _opts[syn]=p;
+    o->second.has_syn=true;
+    return *this;
+  }
+
+  ArgParser &ArgParser::mandatoryGroup(const std::string &group)
+  {
+    GroupData &g=_groups[group];
+    g.mandatory=true;
+    return *this;
+  }
+
+  ArgParser &ArgParser::other(const std::string &name,
+			      const std::string &help)
+  {
+    _others_help.push_back(OtherArg(name,help));
+    return *this;
+  }
+
+  void ArgParser::show(std::ostream &os,Opts::iterator i)
+  {
+    os << "-" << i->first;
+    if(i->second.has_syn)
+      for(Opts::iterator j=_opts.begin();j!=_opts.end();++j)
+	if(j->second.syn&&j->second.help==i->first)
+	  os << "|-" << j->first;
+    switch(i->second.type) {
+    case STRING:
+      os << " str";
+      break;
+    case INTEGER:
+      os << " int";
+      break;
+    case DOUBLE:
+      os << " num";
+      break;
+    default:
+      break;
+    }
+  }
+
+  void ArgParser::show(std::ostream &os,Groups::iterator i)
+  {
+    GroupData::Opts::iterator o=i->second.opts.begin();
+    while(o!=i->second.opts.end()) {
+      show(os,_opts.find(*o));
+      ++o;
+      if(o!=i->second.opts.end()) os<<'|';
+    }
+  }
+    
+  void ArgParser::showHelp(Opts::iterator i)
+  {
+    if(i->second.help.size()==0||i->second.syn) return;
+    std::cerr << "  ";
+    show(std::cerr,i);
+    std::cerr << std::endl;
+    std::cerr << "     " << i->second.help << std::endl;
+  }
+  void ArgParser::showHelp(std::vector<ArgParser::OtherArg>::iterator i)
+  {
+    if(i->help.size()==0) return;
+    std::cerr << "  " << i->name << std::endl
+	      << "     " << i->help << std::endl;
+  }
+    
+  void ArgParser::shortHelp()
+  {
+    const unsigned int LINE_LEN=77;
+    const std::string indent("    ");
+    std::cerr << "Usage:\n  " << _command_name;
+    int pos=_command_name.size()+2;
+    for(Groups::iterator g=_groups.begin();g!=_groups.end();++g) {
+      std::ostringstream cstr;
+      cstr << ' ';
+      if(!g->second.mandatory) cstr << '[';
+      show(cstr,g);
+      if(!g->second.mandatory) cstr << ']';
+      if(pos+cstr.str().size()>LINE_LEN) {
+	std::cerr << std::endl << indent;
+	pos=indent.size();
+      }
+      std::cerr << cstr.str();
+      pos+=cstr.str().size();
+    }
+    for(Opts::iterator i=_opts.begin();i!=_opts.end();++i)
+      if(!i->second.ingroup&&!i->second.syn) {
+	std::ostringstream cstr;
+	cstr << ' ';
+	if(!i->second.mandatory) cstr << '[';
+	show(cstr,i);
+	if(!i->second.mandatory) cstr << ']';
+	if(pos+cstr.str().size()>LINE_LEN) {
+	  std::cerr << std::endl << indent;
+	  pos=indent.size();
+	}
+	std::cerr << cstr.str();
+	pos+=cstr.str().size();
+      }
+    for(std::vector<OtherArg>::iterator i=_others_help.begin();
+	i!=_others_help.end();++i)
+      {
+	std::ostringstream cstr;
+	cstr << ' ' << i->name;
+      
+	if(pos+cstr.str().size()>LINE_LEN) {
+	  std::cerr << std::endl << indent;
+	  pos=indent.size();
+	}
+	std::cerr << cstr.str();
+	pos+=cstr.str().size();
+      }
+    std::cerr << std::endl;
+  }
+    
+  void ArgParser::showHelp()
+  {
+    shortHelp();
+    std::cerr << "Where:\n";
+    for(std::vector<OtherArg>::iterator i=_others_help.begin();
+	i!=_others_help.end();++i) showHelp(i);
+    for(Opts::iterator i=_opts.begin();i!=_opts.end();++i) showHelp(i);
+    exit(1);
+  }
+    
+      
+  void ArgParser::unknownOpt(std::string arg) 
+  {
+    std::cerr << "\nUnknown option: " << arg << "\n";
+    std::cerr << "\nType '" << _command_name <<
+      " --help' to obtain a short summary on the usage.\n\n";
+    exit(1);
+  }
+    
+  void ArgParser::requiresValue(std::string arg, OptType t) 
+  {
+    std::cerr << "Argument '" << arg << "' requires a";
+    switch(t) {
+    case STRING:
+      std::cerr << " string";
+      break;
+    case INTEGER:
+      std::cerr << "n integer";
+      break;
+    case DOUBLE:
+      std::cerr << " floating point";
+      break;
+    default:
+      break;
+    }
+    std::cerr << " value\n\n";
+    showHelp();
+  }
+    
+
+  void ArgParser::checkMandatories()
+  {
+    bool ok=true;
+    for(Opts::iterator i=_opts.begin();i!=_opts.end();++i)
+      if(i->second.mandatory&&!i->second.set) 
+	{
+	  if(ok)
+	    std::cerr << _command_name 
+		      << ": The following mandatory arguments are missing.\n";
+	  ok=false;
+	  showHelp(i);
+	}
+    for(Groups::iterator i=_groups.begin();i!=_groups.end();++i)
+      if(i->second.mandatory||i->second.only_one)
+	{
+	  int set=0;
+	  for(GroupData::Opts::iterator o=i->second.opts.begin();
+	      o!=i->second.opts.end();++o)
+	    if(_opts.find(*o)->second.set) ++set;
+	  if(i->second.mandatory&&!set) {
+	    std::cerr << _command_name 
+		      << ": At least one of the following arguments is mandatory.\n";
+	    ok=false;
+	    for(GroupData::Opts::iterator o=i->second.opts.begin();
+		o!=i->second.opts.end();++o)
+	      showHelp(_opts.find(*o));
+	  }
+	  if(i->second.only_one&&set>1) {
+	    std::cerr << _command_name 
+		      << ": At most one of the following arguments can be given.\n";
+	    ok=false;
+	    for(GroupData::Opts::iterator o=i->second.opts.begin();
+		o!=i->second.opts.end();++o)
+	      showHelp(_opts.find(*o));
+	  }
+	}
+    if(!ok) {
+      std::cerr << "\nType '" << _command_name <<
+	" --help' to obtain a short summary on the usage.\n\n";
+      exit(1);
+    }
+  }
+
+  ArgParser &ArgParser::parse()
+  {
+    for(int ar=1; ar<_argc; ++ar) {
+      std::string arg(_argv[ar]);
+      if (arg[0] != '-' || arg.size() == 1) {
+	_file_args.push_back(arg);
+      }
+      else {
+	Opts::iterator i = _opts.find(arg.substr(1));
+	if(i==_opts.end()) unknownOpt(arg);
+	else {
+	  if(i->second.syn) i=_opts.find(i->second.help);
+	  ParData &p(i->second);
+	  if (p.type==BOOL) *p.bool_p=true;
+	  else if (p.type==FUNC) p.func_p.p(p.func_p.data);
+	  else if(++ar==_argc) requiresValue(arg, p.type);
+	  else {
+	    std::string val(_argv[ar]);
+	    std::istringstream vals(val);
+	    switch(p.type) {
+	    case STRING:
+	      *p.string_p=val;
+	      break;
+	    case INTEGER:
+	      vals >> *p.int_p;
+	      break;
+	    case DOUBLE:
+	      vals >> *p.double_p;
+	      break;
+	    default:
+	      break;
+	    }
+	    if(p.type!=STRING&&(!vals||!vals.eof()))
+	      requiresValue(arg, p.type);
+	  }
+	  p.set = true;
+	}
+      }
+    }
+    checkMandatories();
+
+    return *this;
+  }  
+
+}
Index: lemon/arg_parser.h
===================================================================
--- lemon/arg_parser.h	(revision 2613)
+++ lemon/arg_parser.h	(revision 2613)
@@ -0,0 +1,368 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_ARG_PARSER
+#define LEMON_ARG_PARSER
+
+#include <vector>
+#include <map>
+#include <list>
+#include <string>
+#include <iostream>
+#include <sstream>
+#include <algorithm>
+#include <lemon/error.h>
+
+///\ingroup misc
+///\file
+///\brief A tools to parse command line arguments.
+///
+///\author Alpar Juttner
+
+namespace lemon {
+
+  ///Command line arguments parser
+
+  ///\ingroup misc
+  ///Command line arguments parser
+  ///
+  class ArgParser {
+    
+    static void _showHelp(void *p);
+  protected:
+    
+    int _argc;
+    const char **_argv;
+    
+    enum OptType { UNKNOWN=0, BOOL=1, STRING=2, DOUBLE=3, INTEGER=4, FUNC=5 };
+    
+    class ParData {
+    public:
+      union {
+	bool *bool_p;
+	int *int_p;
+	double *double_p;
+	std::string *string_p;
+	struct {
+	  void (*p)(void *);
+	  void *data;
+	} func_p;
+	  
+      };
+      std::string help;
+      bool mandatory;
+      OptType type;
+      bool set;
+      bool ingroup;
+      bool has_syn;
+      bool syn;
+      bool self_delete;
+      ParData() : mandatory(false), type(UNKNOWN), set(false), ingroup(false),
+		  has_syn(false), syn(false), self_delete(false) {}
+    };
+
+    typedef std::map<std::string,ParData> Opts;
+    Opts _opts;
+
+    class GroupData 
+    {
+    public:
+      typedef std::list<std::string> Opts;
+      Opts opts;
+      bool only_one;
+      bool mandatory;
+      GroupData() :only_one(false), mandatory(false) {}
+    };
+      
+    typedef std::map<std::string,GroupData> Groups;
+    Groups _groups;
+
+    struct OtherArg
+    {
+      std::string name;
+      std::string help;
+      OtherArg(std::string n, std::string h) :name(n), help(h) {}
+
+    };
+      
+    std::vector<OtherArg> _others_help;
+    std::vector<std::string> _file_args;
+    std::string _command_name;
+    
+  public:
+
+    ///\e
+    ArgParser(int argc, const char **argv);
+
+    ~ArgParser();
+
+    ///Add a new integer type option
+
+    ///\param name The name of the option. The leading '-' must be omitted.
+    ///\param help A help string.
+    ///\retval value The value of the argument will be written to this variable.
+    ///\param obl Indicate if the option is mandatory.
+    ArgParser &intOption(const std::string &name,
+		    const std::string &help,
+		    int value=0, bool obl=false);
+
+    ///Add a new floating type option
+
+    ///\param name The name of the option. The leading '-' must be omitted.
+    ///\param help A help string.
+    ///\retval value The value of the argument will be written to this variable.
+    ///\param obl Indicate if the option is mandatory.
+    ArgParser &doubleOption(const std::string &name,
+		      const std::string &help,
+		      double value=0, bool obl=false);
+
+    ///Add a new bool type option
+
+    ///\param name The name of the option. The leading '-' must be omitted.
+    ///\param help A help string.
+    ///\retval value The value of the argument will be written to this variable.
+    ///\param obl Indicate if the option is mandatory.
+    ////\note A mandatory bool obtion is of very little use.)
+    ArgParser &boolOption(const std::string &name,
+		      const std::string &help,
+		      bool value=false, bool obl=false);
+
+    ///Add a new string type option
+
+    ///\param name The name of the option. The leading '-' must be omitted.
+    ///\param help A help string.
+    ///\retval value The value of the argument will be written to this variable.
+    ///\param obl Indicate if the option is mandatory.
+    ArgParser &stringOption(const std::string &name,
+		      const std::string &help,
+		      std::string value="", bool obl=false);
+    
+    ///Bind a function to an option.
+
+    ///\param name The name of the option. The leading '-' must be omitted.
+    ///\param help A help string.
+    ///\retval func The function to be called when the option is given. It
+    ///  must be of type "void f(void *)"
+    ///\param data Data to be passed to \c func
+    ArgParser &funcOption(const std::string &name,
+		    const std::string &help,
+		    void (*func)(void *),void *data);
+
+    ///\name Options with an external strorage.
+    ///Using this functions, the value of the option will be directly written
+    ///into a variable once the option appears in the command line.
+
+    ///@{
+
+    ///Add a new integer type option with a storage reference
+
+    ///\param name The name of the option. The leading '-' must be omitted.
+    ///\param help A help string.
+    ///\retval ref The value of the argument will be written to this variable.
+    ///\param obl Indicate if the option is mandatory.
+    ArgParser &refOption(const std::string &name,
+		    const std::string &help,
+		    int &ref, bool obl=false);
+
+    ///Add a new floating type option with a storage reference
+
+    ///\param name The name of the option. The leading '-' must be omitted.
+    ///\param help A help string.
+    ///\retval ref The value of the argument will be written to this variable.
+    ///\param obl Indicate if the option is mandatory.
+    ArgParser &refOption(const std::string &name,
+		      const std::string &help,
+		      double &ref, bool obl=false);
+
+    ///Add a new bool type option with a storage reference
+
+    ///\param name The name of the option. The leading '-' must be omitted.
+    ///\param help A help string.
+    ///\retval ref The value of the argument will be written to this variable.
+    ///\param obl Indicate if the option is mandatory.
+    ////\note A mandatory bool obtion is of very little use.)
+    ArgParser &refOption(const std::string &name,
+		      const std::string &help,
+		      bool &ref, bool obl=false);
+
+    ///Add a new string type option with a storage reference
+
+    ///\param name The name of the option. The leading '-' must be omitted.
+    ///\param help A help string.
+    ///\retval ref The value of the argument will be written to this variable.
+    ///\param obl Indicate if the option is mandatory.
+    ArgParser &refOption(const std::string &name,
+		      const std::string &help,
+		      std::string &ref, bool obl=false);
+    
+    ///@}
+
+    ///\name Option Groups and Synonyms
+    ///
+    
+    ///@{
+
+    ///Boundle some options into a group
+
+    /// You can group some option by calling this function repeatedly for each
+    /// option to be grupped with the same groupname.
+    ///\param group The group name
+    ///\param opt The option name
+    ArgParser &optionGroup(const std::string &group,
+			   const std::string &opt);
+
+    ///Make the members of a group exclusive
+
+    ///If you call this function for a group, than at most one of them can be
+    ///given at the same time
+    ArgParser &onlyOneGroup(const std::string &group);
+  
+    ///Make a group mandatory
+
+    ///Using this function, at least one of the members of \c group
+    ///must be given.
+    ArgParser &mandatoryGroup(const std::string &group);
+    
+    ///Create synonym to an option
+
+    ///With this function you can create a sysnonym called \c sys of the
+    ///option \c opt.
+    ArgParser &synonym(const std::string &syn,
+			   const std::string &opt);
+    
+    ///@}
+
+    ///Give help string for non-parsed arguments.
+
+    ///With this function you can give help string for non-parsed arguments.
+    ///the parameter \c name will be printed in the short usage line, while
+    ///\c help gives a more detailed description.
+    ArgParser &other(const std::string &name,
+		     const std::string &help="");
+    
+    ///Non option type arguments.
+
+    ///Gives back a reference to a vector consisting of the program arguments
+    ///not starting with a '-' character.
+    std::vector<std::string> &files() { return _file_args; }
+
+    ///Give back the command name (the 0th argument)
+    const std::string &commandName() { return _command_name; }
+
+    void show(std::ostream &os,Opts::iterator i);
+    void show(std::ostream &os,Groups::iterator i);
+    void showHelp(Opts::iterator i);
+    void showHelp(std::vector<OtherArg>::iterator i);
+    void shortHelp();
+    void showHelp();
+
+    void unknownOpt(std::string arg);
+
+    void requiresValue(std::string arg, OptType t);
+    void checkMandatories();
+    
+    ///Start the parsing process
+    ArgParser &parse();
+
+    /// Synonym for parse()
+    ArgParser &run() 
+    {
+      return parse();
+    }
+    
+    ///Check if an opion has been given to the command.
+    bool given(std::string op) 
+    {
+      Opts::iterator i = _opts.find(op);
+      return i!=_opts.end()?i->second.set:false;
+    }
+
+
+    ///Magic type for operator[]
+    
+    ///This is the type of the return value of ArgParser::operator[]().
+    ///It automatically converts to int, double, bool or std::string, if it
+    ///match the type of the option, otherwise it throws an exception.
+    ///(i.e. it performs runtime type checking).
+    class RefType 
+    {
+      ArgParser &_parser;
+      std::string _name;
+    public:
+      ///\e
+      RefType(ArgParser &p,const std::string &n) :_parser(p),_name(n) {}
+      ///\e
+      operator bool() 
+      {
+	Opts::iterator i = _parser._opts.find(_name);
+	LEMON_ASSERT(i!=_parser._opts.end(),
+		     std::string()+"Unkown option: '"+_name+"'");
+	LEMON_ASSERT(i->second.type==ArgParser::BOOL,
+		     std::string()+"'"+_name+"' is a bool option");
+	return *(i->second.bool_p);
+      }
+      ///\e
+      operator std::string()
+      {
+	Opts::iterator i = _parser._opts.find(_name);
+	LEMON_ASSERT(i!=_parser._opts.end(),
+		     std::string()+"Unkown option: '"+_name+"'");
+	LEMON_ASSERT(i->second.type==ArgParser::STRING,
+		     std::string()+"'"+_name+"' is a string option");
+	return *(i->second.string_p);
+      }
+      ///\e
+      operator double() 
+      {
+	Opts::iterator i = _parser._opts.find(_name);
+	LEMON_ASSERT(i!=_parser._opts.end(),
+		     std::string()+"Unkown option: '"+_name+"'");
+	LEMON_ASSERT(i->second.type==ArgParser::DOUBLE ||
+		     i->second.type==ArgParser::INTEGER,
+		     std::string()+"'"+_name+"' is a floating point option");
+	return i->second.type==ArgParser::DOUBLE ?
+	  *(i->second.double_p) : *(i->second.int_p);
+      }
+      ///\e
+      operator int() 
+      {
+	Opts::iterator i = _parser._opts.find(_name);
+	LEMON_ASSERT(i!=_parser._opts.end(),
+		     std::string()+"Unkown option: '"+_name+"'");
+	LEMON_ASSERT(i->second.type==ArgParser::INTEGER,
+		     std::string()+"'"+_name+"' is an integer option");
+	return *(i->second.int_p);
+      }
+
+    };
+
+    ///Give back the value of an option
+    
+    ///Give back the value of an option
+    ///\sa RefType
+    RefType operator[](const std::string &n)
+    {
+      return RefType(*this, n);
+    }    
+ 
+  };
+}
+
+    
+
+#endif // LEMON_MAIN_PARAMS
Index: lemon/attic/debug.h
===================================================================
--- lemon/attic/debug.h	(revision 2553)
+++ lemon/attic/debug.h	(revision 2553)
@@ -0,0 +1,72 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_DEBUG_H
+#define LEMON_DEBUG_H
+
+//! \file
+//! \brief Basic definitions for debug control.
+
+namespace lemon {
+
+  //! Debug mode for testing/debugging
+
+  //! Use this debug mode if you want exhaustive range and consistency checks.
+  //! It also produces verbose debug messages.
+  struct DebugOn {
+    //! Example: check whether the edges added to a path are adjacent
+    static const bool consistensy_check = true;
+
+    static const bool range_check = true;
+
+    //! Examples: initialize maps with some value;
+    //! after deleting an item from UnionFindEnum set its value in the
+    //! corresponding map to NULL...
+    static const bool ensure_safe_state = true;
+
+    static const int verbose = 5;
+  };
+
+  //! Debug mode for turning off debug aids.
+
+  //! This debud mode switches off all range and consistency checks,
+  //! as well as the debug messages.
+  //!
+  struct DebugOff {
+    static const bool consistensy_check = false;
+    static const bool range_check = false;
+    static const bool ensure_safe_state = false;
+    static const int verbose = 0;
+  };
+
+#ifdef DEBUG
+  //! The default debug mode.
+
+  //! The default debug mode.
+  //!
+  typedef DebugOn DefaultDebugMode;
+#else
+  //! The default debug mode. 
+
+  //! The default debug mode. 
+  //!
+  typedef DebugOff DefaultDebugMode;
+#endif
+
+}
+#endif // LEMON_DEBUG_H
Index: lemon/base.cc
===================================================================
--- lemon/base.cc	(revision 2655)
+++ lemon/base.cc	(revision 2553)
@@ -3,5 +3,5 @@
  * This file is a part of LEMON, a generic C++ optimization library
  *
- * Copyright (C) 2003-2006
+ * Copyright (C) 2003-2008
  * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
  * (Egervary Research Group on Combinatorial Optimization, EGRES).
Index: lemon/bellman_ford.h
===================================================================
--- lemon/bellman_ford.h	(revision 2553)
+++ lemon/bellman_ford.h	(revision 2553)
@@ -0,0 +1,1057 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BELMANN_FORD_H
+#define LEMON_BELMANN_FORD_H
+
+/// \ingroup shortest_path
+/// \file
+/// \brief BellmanFord algorithm.
+///
+
+#include <lemon/list_graph.h>
+#include <lemon/bits/path_dump.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/graph_utils.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+
+#include <limits>
+
+namespace lemon {
+
+  /// \brief Default OperationTraits for the BellmanFord algorithm class.
+  ///  
+  /// It defines all computational operations and constants which are
+  /// used in the Bellman-Ford algorithm. The default implementation
+  /// is based on the numeric_limits class. If the numeric type does not
+  /// have infinity value then the maximum value is used as extremal
+  /// infinity value.
+  template <
+    typename Value, 
+    bool has_infinity = std::numeric_limits<Value>::has_infinity>
+  struct BellmanFordDefaultOperationTraits {
+    /// \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 true only if the first value less than the second.
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+
+  template <typename Value>
+  struct BellmanFordDefaultOperationTraits<Value, false> {
+    static Value zero() {
+      return static_cast<Value>(0);
+    }
+    static Value infinity() {
+      return std::numeric_limits<Value>::max();
+    }
+    static Value plus(const Value& left, const Value& right) {
+      if (left == infinity() || right == infinity()) return infinity();
+      return left + right;
+    }
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+  
+  /// \brief Default traits class of BellmanFord class.
+  ///
+  /// Default traits class of BellmanFord class.
+  /// \param _Graph Graph type.
+  /// \param _LegthMap Type of length map.
+  template<class _Graph, class _LengthMap>
+  struct BellmanFordDefaultTraits {
+    /// The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge lengths.
+    ///
+    /// The type of the map that stores the edge lengths.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _LengthMap LengthMap;
+
+    // The type of the length of the edges.
+    typedef typename _LengthMap::Value Value;
+
+    /// \brief Operation traits for Bellman-Ford algorithm.
+    ///
+    /// It defines the infinity type on the given Value type
+    /// and the used operation.
+    /// \see BellmanFordDefaultOperationTraits
+    typedef BellmanFordDefaultOperationTraits<Value> OperationTraits;
+ 
+    /// \brief The type of the map that stores the last edges of the 
+    /// shortest paths.
+    /// 
+    /// The type of the map that stores the last
+    /// edges of the shortest paths.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename _Graph::Edge> PredMap;
+
+    /// \brief Instantiates a PredMap.
+    /// 
+    /// This function instantiates a \ref PredMap. 
+    /// \param graph is the graph, to which we would like to define the PredMap.
+    static PredMap *createPredMap(const _Graph& graph) {
+      return new PredMap(graph);
+    }
+
+    /// \brief The type of the map that stores the dists of the nodes.
+    ///
+    /// The type of the map that stores the dists of the nodes.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename _LengthMap::Value> 
+    DistMap;
+
+    /// \brief Instantiates a DistMap.
+    ///
+    /// This function instantiates a \ref DistMap. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// \ref DistMap
+    static DistMap *createDistMap(const _Graph& graph) {
+      return new DistMap(graph);
+    }
+
+  };
+  
+  /// \brief %BellmanFord algorithm class.
+  ///
+  /// \ingroup shortest_path
+  /// This class provides an efficient implementation of \c Bellman-Ford 
+  /// algorithm. The edge lengths are passed to the algorithm using a
+  /// \ref concepts::ReadMap "ReadMap", so it is easy to change it to any 
+  /// kind of length.
+  ///
+  /// The Bellman-Ford algorithm solves the shortest path from one node
+  /// problem when the edges can have negative length but the graph should
+  /// not contain cycles with negative sum of length. If we can assume
+  /// that all edge is non-negative in the graph then the dijkstra algorithm
+  /// should be used rather.
+  ///
+  /// The maximal time complexity of the algorithm is \f$ O(ne) \f$.
+  ///
+  /// The type of the length is determined by the
+  /// \ref concepts::ReadMap::Value "Value" of the length map.
+  ///
+  /// \param _Graph The graph type the algorithm runs on. The default value
+  /// is \ref ListGraph. The value of _Graph is not used directly by
+  /// BellmanFord, it is only passed to \ref BellmanFordDefaultTraits.
+  /// \param _LengthMap This read-only EdgeMap determines the lengths of the
+  /// edges. The default map type is \ref concepts::Graph::EdgeMap 
+  /// "Graph::EdgeMap<int>".  The value of _LengthMap is not used directly 
+  /// by BellmanFord, it is only passed to \ref BellmanFordDefaultTraits.  
+  /// \param _Traits Traits class to set various data types used by the 
+  /// algorithm.  The default traits class is \ref BellmanFordDefaultTraits
+  /// "BellmanFordDefaultTraits<_Graph,_LengthMap>".  See \ref
+  /// BellmanFordDefaultTraits for the documentation of a BellmanFord traits
+  /// class.
+  ///
+  /// \author Balazs Dezso
+
+#ifdef DOXYGEN
+  template <typename _Graph, typename _LengthMap, typename _Traits>
+#else
+  template <typename _Graph=ListGraph,
+	    typename _LengthMap=typename _Graph::template EdgeMap<int>,
+	    typename _Traits=BellmanFordDefaultTraits<_Graph,_LengthMap> >
+#endif
+  class BellmanFord {
+  public:
+    
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::BellmanFord::UninitializedParameter";
+      }
+    };
+
+    typedef _Traits Traits;
+    ///The type of the underlying graph.
+    typedef typename _Traits::Graph Graph;
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    
+    /// \brief The type of the length of the edges.
+    typedef typename _Traits::LengthMap::Value Value;
+    /// \brief The type of the map that stores the edge lengths.
+    typedef typename _Traits::LengthMap LengthMap;
+    /// \brief The type of the map that stores the last
+    /// edges of the shortest paths.
+    typedef typename _Traits::PredMap PredMap;
+    /// \brief The type of the map that stores the dists of the nodes.
+    typedef typename _Traits::DistMap DistMap;
+    /// \brief The operation traits.
+    typedef typename _Traits::OperationTraits OperationTraits;
+  private:
+    /// Pointer to the underlying graph.
+    const Graph *graph;
+    /// Pointer to the length map
+    const LengthMap *length;
+    ///Pointer to the map of predecessors edges.
+    PredMap *_pred;
+    ///Indicates if \ref _pred is locally allocated (\c true) or not.
+    bool local_pred;
+    ///Pointer to the map of distances.
+    DistMap *_dist;
+    ///Indicates if \ref _dist is locally allocated (\c true) or not.
+    bool local_dist;
+
+    typedef typename Graph::template NodeMap<bool> MaskMap;
+    MaskMap *_mask;
+
+    std::vector<Node> _process;
+
+    /// Creates the maps if necessary.
+    void create_maps() {
+      if(!_pred) {
+	local_pred = true;
+	_pred = Traits::createPredMap(*graph);
+      }
+      if(!_dist) {
+	local_dist = true;
+	_dist = Traits::createDistMap(*graph);
+      }
+      _mask = new MaskMap(*graph, false);
+    }
+    
+  public :
+ 
+    typedef BellmanFord Create;
+
+    /// \name Named template parameters
+
+    ///@{
+
+    template <class T>
+    struct DefPredMapTraits : public Traits {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph&) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting PredMap 
+    /// type
+    /// \ref named-templ-param "Named parameter" for setting PredMap type
+    ///
+    template <class T>
+    struct DefPredMap 
+      : public BellmanFord< Graph, LengthMap, DefPredMapTraits<T> > {
+      typedef BellmanFord< Graph, LengthMap, DefPredMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefDistMapTraits : public Traits {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph&) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting DistMap 
+    /// type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting DistMap type
+    ///
+    template <class T>
+    struct DefDistMap 
+      : public BellmanFord< Graph, LengthMap, DefDistMapTraits<T> > {
+      typedef BellmanFord< Graph, LengthMap, DefDistMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefOperationTraitsTraits : public Traits {
+      typedef T OperationTraits;
+    };
+    
+    /// \brief \ref named-templ-param "Named parameter" for setting 
+    /// OperationTraits type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting OperationTraits
+    /// type
+    template <class T>
+    struct DefOperationTraits
+      : public BellmanFord< Graph, LengthMap, DefOperationTraitsTraits<T> > {
+      typedef BellmanFord< Graph, LengthMap, DefOperationTraitsTraits<T> >
+      Create;
+    };
+    
+    ///@}
+
+  protected:
+    
+    BellmanFord() {}
+
+  public:      
+    
+    /// \brief Constructor.
+    ///
+    /// \param _graph the graph the algorithm will run on.
+    /// \param _length the length map used by the algorithm.
+    BellmanFord(const Graph& _graph, const LengthMap& _length) :
+      graph(&_graph), length(&_length),
+      _pred(0), local_pred(false),
+      _dist(0), local_dist(false), _mask(0) {}
+    
+    ///Destructor.
+    ~BellmanFord() {
+      if(local_pred) delete _pred;
+      if(local_dist) delete _dist;
+      if(_mask) delete _mask;
+    }
+
+    /// \brief Sets the length map.
+    ///
+    /// Sets the length map.
+    /// \return \c (*this)
+    BellmanFord &lengthMap(const LengthMap &m) {
+      length = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the predecessor edges.
+    ///
+    /// Sets the map storing the predecessor edges.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    BellmanFord &predMap(PredMap &m) {
+      if(local_pred) {
+	delete _pred;
+	local_pred=false;
+      }
+      _pred = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the distances calculated by the algorithm.
+    ///
+    /// Sets the map storing the distances calculated by the algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    BellmanFord &distMap(DistMap &m) {
+      if(local_dist) {
+	delete _dist;
+	local_dist=false;
+      }
+      _dist = &m;
+      return *this;
+    }
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run(...).
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init(), then you can add several source nodes
+    /// with \ref addSource().
+    /// Finally \ref start() will perform the actual path
+    /// computation.
+
+    ///@{
+
+    /// \brief Initializes the internal data structures.
+    /// 
+    /// Initializes the internal data structures.
+    void init(const Value value = OperationTraits::infinity()) {
+      create_maps();
+      for (NodeIt it(*graph); it != INVALID; ++it) {
+	_pred->set(it, INVALID);
+	_dist->set(it, value);
+      }
+      _process.clear();
+      if (OperationTraits::less(value, OperationTraits::infinity())) {
+	for (NodeIt it(*graph); it != INVALID; ++it) {
+	  _process.push_back(it);
+	  _mask->set(it, true);
+	}
+      }
+    }
+    
+    /// \brief Adds a new source node.
+    ///
+    /// Adds a new source node. The optional second parameter is the 
+    /// initial distance of the node. It just sets the distance of the 
+    /// node to the given value.
+    void addSource(Node source, Value dst = OperationTraits::zero()) {
+      _dist->set(source, dst);
+      if (!(*_mask)[source]) {
+	_process.push_back(source);
+	_mask->set(source, true);
+      }
+    }
+
+    /// \brief Executes one round from the Bellman-Ford algorithm.
+    ///
+    /// If the algoritm calculated the distances in the previous round
+    /// exactly for all at most \f$ k \f$ length path lengths then it will
+    /// calculate the distances exactly for all at most \f$ k + 1 \f$
+    /// length path lengths. With \f$ k \f$ iteration this function
+    /// calculates the at most \f$ k \f$ length path lengths.
+    ///
+    /// \warning The paths with limited edge number cannot be retrieved
+    /// easily with \ref path() or \ref predEdge() functions. If you
+    /// need the shortest path and not just the distance you should store
+    /// after each iteration the \ref predMap() map and manually build
+    /// the path.
+    ///
+    /// \return \c true when the algorithm have not found more shorter
+    /// paths.
+    bool processNextRound() {
+      for (int i = 0; i < int(_process.size()); ++i) {
+	_mask->set(_process[i], false);
+      }
+      std::vector<Node> nextProcess;
+      std::vector<Value> values(_process.size());
+      for (int i = 0; i < int(_process.size()); ++i) {
+	values[i] = (*_dist)[_process[i]];
+      }
+      for (int i = 0; i < int(_process.size()); ++i) {
+	for (OutEdgeIt it(*graph, _process[i]); it != INVALID; ++it) {
+	  Node target = graph->target(it);
+	  Value relaxed = OperationTraits::plus(values[i], (*length)[it]);
+	  if (OperationTraits::less(relaxed, (*_dist)[target])) {
+	    _pred->set(target, it);
+	    _dist->set(target, relaxed);
+	    if (!(*_mask)[target]) {
+	      _mask->set(target, true);
+	      nextProcess.push_back(target);
+	    }
+	  }	  
+	}
+      }
+      _process.swap(nextProcess);
+      return _process.empty();
+    }
+
+    /// \brief Executes one weak round from the Bellman-Ford algorithm.
+    ///
+    /// If the algorithm calculated the distances in the
+    /// previous round at least for all at most k length paths then it will
+    /// calculate the distances at least for all at most k + 1 length paths.
+    /// This function does not make it possible to calculate strictly the
+    /// at most k length minimal paths, this is why it is
+    /// called just weak round.
+    /// \return \c true when the algorithm have not found more shorter paths.
+    bool processNextWeakRound() {
+      for (int i = 0; i < int(_process.size()); ++i) {
+	_mask->set(_process[i], false);
+      }
+      std::vector<Node> nextProcess;
+      for (int i = 0; i < int(_process.size()); ++i) {
+	for (OutEdgeIt it(*graph, _process[i]); it != INVALID; ++it) {
+	  Node target = graph->target(it);
+	  Value relaxed = 
+	    OperationTraits::plus((*_dist)[_process[i]], (*length)[it]);
+	  if (OperationTraits::less(relaxed, (*_dist)[target])) {
+	    _pred->set(target, it);
+	    _dist->set(target, relaxed);
+	    if (!(*_mask)[target]) {
+	      _mask->set(target, true);
+	      nextProcess.push_back(target);
+	    }
+	  }	  
+	}
+      }
+      _process.swap(nextProcess);
+      return _process.empty();
+    }
+
+    /// \brief Executes the algorithm.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    ///
+    /// This method runs the %BellmanFord algorithm from the root node(s)
+    /// in order to compute the shortest path to each node. The algorithm 
+    /// computes 
+    /// - The shortest path tree.
+    /// - The distance of each node from the root(s).
+    void start() {
+      int num = countNodes(*graph) - 1;
+      for (int i = 0; i < num; ++i) {
+	if (processNextWeakRound()) break;
+      }
+    }
+
+    /// \brief Executes the algorithm and checks the negative cycles.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function. 
+    ///
+    /// This method runs the %BellmanFord algorithm from the root node(s)
+    /// in order to compute the shortest path to each node. The algorithm 
+    /// computes 
+    /// - The shortest path tree.
+    /// - The distance of each node from the root(s).
+    /// 
+    /// \return \c false if there is a negative cycle in the graph.
+    bool checkedStart() {
+      int num = countNodes(*graph);
+      for (int i = 0; i < num; ++i) {
+	if (processNextWeakRound()) return true;
+      }
+      return _process.empty();
+    }
+
+    /// \brief Executes the algorithm with path length limit.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    ///
+    /// This method runs the %BellmanFord algorithm from the root
+    /// node(s) in order to compute the shortest path lengths with at
+    /// most \c num edge.
+    ///
+    /// \warning The paths with limited edge number cannot be retrieved
+    /// easily with \ref path() or \ref predEdge() functions. If you
+    /// need the shortest path and not just the distance you should store
+    /// after each iteration the \ref predMap() map and manually build
+    /// the path.
+    ///
+    /// The algorithm computes
+    /// - The predecessor edge from each node.
+    /// - The limited distance of each node from the root(s).
+    void limitedStart(int num) {
+      for (int i = 0; i < num; ++i) {
+	if (processNextRound()) break;
+      }
+    }
+    
+    /// \brief Runs %BellmanFord algorithm from node \c s.
+    ///    
+    /// This method runs the %BellmanFord algorithm from a root node \c s
+    /// in order to compute the shortest path to each node. The algorithm 
+    /// computes
+    /// - The shortest path tree.
+    /// - The distance of each node from the root.
+    ///
+    /// \note d.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.addSource(s);
+    ///  d.start();
+    ///\endcode
+    void run(Node s) {
+      init();
+      addSource(s);
+      start();
+    }
+    
+    /// \brief Runs %BellmanFord algorithm with limited path length 
+    /// from node \c s.
+    ///    
+    /// This method runs the %BellmanFord algorithm from a root node \c s
+    /// in order to compute the shortest path with at most \c len edges 
+    /// to each node. The algorithm computes
+    /// - The shortest path tree.
+    /// - The distance of each node from the root.
+    ///
+    /// \note d.run(s, num) is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.addSource(s);
+    ///  d.limitedStart(num);
+    ///\endcode
+    void run(Node s, int num) {
+      init();
+      addSource(s);
+      limitedStart(num);
+    }
+    
+    ///@}
+
+    /// \name Query Functions
+    /// The result of the %BellmanFord algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    /// \brief Lemon iterator for get the active nodes.
+    ///
+    /// Lemon iterator for get the active nodes. This class provides a
+    /// common style lemon iterator which gives back a subset of the
+    /// nodes. The iterated nodes are active in the algorithm after
+    /// the last phase so these should be checked in the next phase to
+    /// find augmenting edges from these.
+    class ActiveIt {
+    public:
+
+      /// \brief Constructor.
+      ///
+      /// Constructor for get the nodeset of the variable. 
+      ActiveIt(const BellmanFord& algorithm) : _algorithm(&algorithm)
+      {
+        _index = _algorithm->_process.size() - 1;
+      }
+
+      /// \brief Invalid constructor.
+      ///
+      /// Invalid constructor.
+      ActiveIt(Invalid) : _algorithm(0), _index(-1) {}
+
+      /// \brief Conversion to node.
+      ///
+      /// Conversion to node.
+      operator Node() const { 
+        return _index >= 0 ? _algorithm->_process[_index] : INVALID;
+      }
+
+      /// \brief Increment operator.
+      ///
+      /// Increment operator.
+      ActiveIt& operator++() {
+        --_index;
+        return *this; 
+      }
+
+      bool operator==(const ActiveIt& it) const { 
+        return static_cast<Node>(*this) == static_cast<Node>(it); 
+      }
+      bool operator!=(const ActiveIt& it) const { 
+        return static_cast<Node>(*this) != static_cast<Node>(it); 
+      }
+      bool operator<(const ActiveIt& it) const { 
+        return static_cast<Node>(*this) < static_cast<Node>(it); 
+      }
+      
+    private:
+      const BellmanFord* _algorithm;
+      int _index;
+    };
+
+    typedef PredMapPath<Graph, PredMap> Path;
+
+    /// \brief Gives back the shortest path.
+    ///    
+    /// Gives back the shortest path.
+    /// \pre The \c t should be reachable from the source.
+    Path path(Node t) 
+    {
+      return Path(*graph, *_pred, t);
+    }
+
+
+    // TODO : implement negative cycle
+//     /// \brief Gives back a negative cycle.
+//     ///    
+//     /// This function gives back a negative cycle.
+//     /// If the algorithm have not found yet negative cycle it will give back
+//     /// an empty path.
+//     Path negativeCycle() {
+//       typename Graph::template NodeMap<int> state(*graph, 0);
+//       for (ActiveIt it(*this); it != INVALID; ++it) {
+//         if (state[it] == 0) {
+//           for (Node t = it; predEdge(t) != INVALID; t = predNode(t)) {
+//             if (state[t] == 0) {
+//               state[t] = 1;
+//             } else if (state[t] == 2) {
+//               break;
+//             } else {
+//               p.clear();
+//               typename Path::Builder b(p);
+//               b.setStartNode(t);
+//               b.pushFront(predEdge(t));
+//               for(Node s = predNode(t); s != t; s = predNode(s)) {
+//                 b.pushFront(predEdge(s));
+//               }
+//               b.commit();
+//               return true;
+//             }
+//           }
+//           for (Node t = it; predEdge(t) != INVALID; t = predNode(t)) {
+//             if (state[t] == 1) {
+//               state[t] = 2;
+//             } else {
+//               break;
+//             }
+//           }
+//         }
+//       }
+//       return false;
+//     }
+	  
+    /// \brief The distance of a node from the root.
+    ///
+    /// Returns the distance of a node from the root.
+    /// \pre \ref run() must be called before using this function.
+    /// \warning If node \c v in unreachable from the root the return value
+    /// of this funcion is undefined.
+    Value dist(Node v) const { return (*_dist)[v]; }
+
+    /// \brief Returns the 'previous edge' of the shortest path tree.
+    ///
+    /// For a node \c v it returns the 'previous edge' of the shortest path 
+    /// tree, i.e. it returns the last edge of a shortest path from the root 
+    /// to \c v. It is \ref INVALID if \c v is unreachable from the root or 
+    /// if \c v=s. The shortest path tree used here is equal to the shortest 
+    /// path tree used in \ref predNode(). 
+    /// \pre \ref run() must be called before using
+    /// this function.
+    Edge predEdge(Node v) const { return (*_pred)[v]; }
+
+    /// \brief Returns the 'previous node' of the shortest path tree.
+    ///
+    /// For a node \c v it returns the 'previous node' of the shortest path 
+    /// tree, i.e. it returns the last but one node from a shortest path from 
+    /// the root to \c /v. It is INVALID if \c v is unreachable from the root 
+    /// or if \c v=s. The shortest path tree used here is equal to the 
+    /// shortest path tree used in \ref predEdge().  \pre \ref run() must be 
+    /// called before using this function.
+    Node predNode(Node v) const { 
+      return (*_pred)[v] == INVALID ? INVALID : graph->source((*_pred)[v]); 
+    }
+    
+    /// \brief Returns a reference to the NodeMap of distances.
+    ///
+    /// Returns a reference to the NodeMap of distances. \pre \ref run() must
+    /// be called before using this function.
+    const DistMap &distMap() const { return *_dist;}
+ 
+    /// \brief Returns a reference to the shortest path tree map.
+    ///
+    /// Returns a reference to the NodeMap of the edges of the
+    /// shortest path tree.
+    /// \pre \ref run() must be called before using this function.
+    const PredMap &predMap() const { return *_pred; }
+ 
+    /// \brief Checks if a node is reachable from the root.
+    ///
+    /// Returns \c true if \c v is reachable from the root.
+    /// \pre \ref run() must be called before using this function.
+    ///
+    bool reached(Node v) { return (*_dist)[v] != OperationTraits::infinity(); }
+    
+    ///@}
+  };
+ 
+  /// \brief Default traits class of BellmanFord function.
+  ///
+  /// Default traits class of BellmanFord function.
+  /// \param _Graph Graph type.
+  /// \param _LengthMap Type of length map.
+  template <typename _Graph, typename _LengthMap>
+  struct BellmanFordWizardDefaultTraits {
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge lengths.
+    ///
+    /// The type of the map that stores the edge lengths.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _LengthMap LengthMap;
+
+    /// \brief The value type of the length map.
+    typedef typename _LengthMap::Value Value;
+
+    /// \brief Operation traits for Bellman-Ford algorithm.
+    ///
+    /// It defines the infinity type on the given Value type
+    /// and the used operation.
+    /// \see BellmanFordDefaultOperationTraits
+    typedef BellmanFordDefaultOperationTraits<Value> OperationTraits;
+
+    /// \brief The type of the map that stores the last
+    /// edges of the shortest paths.
+    /// 
+    /// The type of the map that stores the last
+    /// edges of the shortest paths.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    typedef NullMap <typename _Graph::Node,typename _Graph::Edge> PredMap;
+
+    /// \brief Instantiates a PredMap.
+    /// 
+    /// This function instantiates a \ref PredMap. 
+    static PredMap *createPredMap(const _Graph &) {
+      return new PredMap();
+    }
+    /// \brief The type of the map that stores the dists of the nodes.
+    ///
+    /// The type of the map that stores the dists of the nodes.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    typedef NullMap<typename Graph::Node, Value> DistMap;
+    /// \brief Instantiates a DistMap.
+    ///
+    /// This function instantiates a \ref DistMap. 
+    static DistMap *createDistMap(const _Graph &) {
+      return new DistMap();
+    }
+  };
+  
+  /// \brief Default traits used by \ref BellmanFordWizard
+  ///
+  /// To make it easier to use BellmanFord algorithm
+  /// we have created a wizard class.
+  /// This \ref BellmanFordWizard class needs default traits,
+  /// as well as the \ref BellmanFord class.
+  /// The \ref BellmanFordWizardBase is a class to be the default traits of the
+  /// \ref BellmanFordWizard class.
+  /// \todo More named parameters are required...
+  template<class _Graph,class _LengthMap>
+  class BellmanFordWizardBase 
+    : public BellmanFordWizardDefaultTraits<_Graph,_LengthMap> {
+
+    typedef BellmanFordWizardDefaultTraits<_Graph,_LengthMap> Base;
+  protected:
+    /// Type of the nodes in the graph.
+    typedef typename Base::Graph::Node Node;
+
+    /// Pointer to the underlying graph.
+    void *_graph;
+    /// Pointer to the length map
+    void *_length;
+    ///Pointer to the map of predecessors edges.
+    void *_pred;
+    ///Pointer to the map of distances.
+    void *_dist;
+    ///Pointer to the source node.
+    Node _source;
+
+    public:
+    /// Constructor.
+    
+    /// This constructor does not require parameters, therefore it initiates
+    /// all of the attributes to default values (0, INVALID).
+    BellmanFordWizardBase() : _graph(0), _length(0), _pred(0),
+			   _dist(0), _source(INVALID) {}
+
+    /// Constructor.
+    
+    /// This constructor requires some parameters,
+    /// listed in the parameters list.
+    /// Others are initiated to 0.
+    /// \param graph is the initial value of  \ref _graph
+    /// \param length is the initial value of  \ref _length
+    /// \param source is the initial value of  \ref _source
+    BellmanFordWizardBase(const _Graph& graph, 
+			  const _LengthMap& length, 
+			  Node source = INVALID) :
+      _graph(reinterpret_cast<void*>(const_cast<_Graph*>(&graph))), 
+      _length(reinterpret_cast<void*>(const_cast<_LengthMap*>(&length))), 
+      _pred(0), _dist(0), _source(source) {}
+
+  };
+  
+  /// A class to make the usage of BellmanFord algorithm easier
+
+  /// This class is created to make it easier to use BellmanFord algorithm.
+  /// It uses the functions and features of the plain \ref BellmanFord,
+  /// but it is much simpler to use it.
+  ///
+  /// Simplicity means that the way to change the types defined
+  /// in the traits class is based on functions that returns the new class
+  /// and not on templatable built-in classes.
+  /// When using the plain \ref BellmanFord
+  /// the new class with the modified type comes from
+  /// the original class by using the ::
+  /// operator. In the case of \ref BellmanFordWizard only
+  /// a function have to be called and it will
+  /// return the needed class.
+  ///
+  /// It does not have own \ref run method. When its \ref run method is called
+  /// it initiates a plain \ref BellmanFord class, and calls the \ref 
+  /// BellmanFord::run method of it.
+  template<class _Traits>
+  class BellmanFordWizard : public _Traits {
+    typedef _Traits Base;
+
+    ///The type of the underlying graph.
+    typedef typename _Traits::Graph Graph;
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::OutEdgeIt EdgeIt;
+    
+    ///The type of the map that stores the edge lengths.
+    typedef typename _Traits::LengthMap LengthMap;
+
+    ///The type of the length of the edges.
+    typedef typename LengthMap::Value Value;
+
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    typedef typename _Traits::PredMap PredMap;
+
+    ///The type of the map that stores the dists of the nodes.
+    typedef typename _Traits::DistMap DistMap;
+
+  public:
+    /// Constructor.
+    BellmanFordWizard() : _Traits() {}
+
+    /// \brief Constructor that requires parameters.
+    ///
+    /// Constructor that requires parameters.
+    /// These parameters will be the default values for the traits class.
+    BellmanFordWizard(const Graph& graph, const LengthMap& length, 
+		      Node src = INVALID) 
+      : _Traits(graph, length, src) {}
+
+    /// \brief Copy constructor
+    BellmanFordWizard(const _Traits &b) : _Traits(b) {}
+
+    ~BellmanFordWizard() {}
+
+    /// \brief Runs BellmanFord algorithm from a given node.
+    ///    
+    /// Runs BellmanFord algorithm from a given node.
+    /// The node can be given by the \ref source function.
+    void run() {
+      if(Base::_source == INVALID) throw UninitializedParameter();
+      BellmanFord<Graph,LengthMap,_Traits> 
+	bf(*reinterpret_cast<const Graph*>(Base::_graph), 
+           *reinterpret_cast<const LengthMap*>(Base::_length));
+      if (Base::_pred) bf.predMap(*reinterpret_cast<PredMap*>(Base::_pred));
+      if (Base::_dist) bf.distMap(*reinterpret_cast<DistMap*>(Base::_dist));
+      bf.run(Base::_source);
+    }
+
+    /// \brief Runs BellmanFord algorithm from the given node.
+    ///
+    /// Runs BellmanFord algorithm from the given node.
+    /// \param src is the given source.
+    void run(Node src) {
+      Base::_source = src;
+      run();
+    }
+
+    template<class T>
+    struct DefPredMapBase : public Base {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph &) { return 0; };
+      DefPredMapBase(const _Traits &b) : _Traits(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting PredMap type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting PredMap type
+    ///
+    template<class T>
+    BellmanFordWizard<DefPredMapBase<T> > predMap(const T &t) 
+    {
+      Base::_pred=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return BellmanFordWizard<DefPredMapBase<T> >(*this);
+    }
+    
+    template<class T>
+    struct DefDistMapBase : public Base {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph &) { return 0; };
+      DefDistMapBase(const _Traits &b) : _Traits(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    template<class T>
+    BellmanFordWizard<DefDistMapBase<T> > distMap(const T &t) {
+      Base::_dist=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return BellmanFordWizard<DefDistMapBase<T> >(*this);
+    }
+
+    template<class T>
+    struct DefOperationTraitsBase : public Base {
+      typedef T OperationTraits;
+      DefOperationTraitsBase(const _Traits &b) : _Traits(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting OperationTraits type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting OperationTraits type
+    ///
+    template<class T>
+    BellmanFordWizard<DefOperationTraitsBase<T> > distMap() {
+      return BellmanFordWizard<DefDistMapBase<T> >(*this);
+    }
+    
+    /// \brief Sets the source node, from which the BellmanFord algorithm runs.
+    ///
+    /// Sets the source node, from which the BellmanFord algorithm runs.
+    /// \param src is the source node.
+    BellmanFordWizard<_Traits>& source(Node src) {
+      Base::_source = src;
+      return *this;
+    }
+    
+  };
+  
+  /// \brief Function type interface for BellmanFord algorithm.
+  ///
+  /// \ingroup shortest_path
+  /// Function type interface for BellmanFord algorithm.
+  ///
+  /// This function also has several \ref named-templ-func-param 
+  /// "named parameters", they are declared as the members of class 
+  /// \ref BellmanFordWizard.
+  /// The following
+  /// example shows how to use these parameters.
+  ///\code
+  /// bellmanford(g,length,source).predMap(preds).run();
+  ///\endcode
+  /// \warning Don't forget to put the \ref BellmanFordWizard::run() "run()"
+  /// to the end of the parameter list.
+  /// \sa BellmanFordWizard
+  /// \sa BellmanFord
+  template<class _Graph, class _LengthMap>
+  BellmanFordWizard<BellmanFordWizardBase<_Graph,_LengthMap> >
+  bellmanFord(const _Graph& graph,
+	      const _LengthMap& length, 
+	      typename _Graph::Node source = INVALID) {
+    return BellmanFordWizard<BellmanFordWizardBase<_Graph,_LengthMap> >
+      (graph, length, source);
+  }
+
+} //END OF NAMESPACE LEMON
+
+#endif
+
Index: lemon/bfs.h
===================================================================
--- lemon/bfs.h	(revision 2611)
+++ lemon/bfs.h	(revision 2611)
@@ -0,0 +1,1597 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BFS_H
+#define LEMON_BFS_H
+
+///\ingroup search
+///\file
+///\brief Bfs algorithm.
+
+#include <lemon/list_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/bits/path_dump.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+
+namespace lemon {
+
+
+  
+  ///Default traits class of Bfs class.
+
+  ///Default traits class of Bfs class.
+  ///\param GR Graph type.
+  template<class GR>
+  struct BfsDefaultTraits
+  {
+    ///The graph type the algorithm runs on. 
+    typedef GR Graph;
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    /// 
+    ///The type of the map that stores the last
+    ///edges of the shortest paths.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename GR::Edge> PredMap;
+    ///Instantiates a PredMap.
+ 
+    ///This function instantiates a \ref PredMap. 
+    ///\param G is the graph, to which we would like to define the PredMap.
+    ///\todo The graph alone may be insufficient to initialize
+    static PredMap *createPredMap(const GR &G) 
+    {
+      return new PredMap(G);
+    }
+    ///The type of the map that indicates which nodes are processed.
+ 
+    ///The type of the map that indicates which nodes are processed.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef NullMap<typename Graph::Node,bool> ProcessedMap;
+    ///Instantiates a ProcessedMap.
+ 
+    ///This function instantiates a \ref ProcessedMap. 
+    ///\param g is the graph, to which
+    ///we would like to define the \ref ProcessedMap
+#ifdef DOXYGEN
+    static ProcessedMap *createProcessedMap(const GR &g)
+#else
+    static ProcessedMap *createProcessedMap(const GR &)
+#endif
+    {
+      return new ProcessedMap();
+    }
+    ///The type of the map that indicates which nodes are reached.
+ 
+    ///The type of the map that indicates which nodes are reached.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef typename Graph::template NodeMap<bool> ReachedMap;
+    ///Instantiates a ReachedMap.
+ 
+    ///This function instantiates a \ref ReachedMap. 
+    ///\param G is the graph, to which
+    ///we would like to define the \ref ReachedMap.
+    static ReachedMap *createReachedMap(const GR &G)
+    {
+      return new ReachedMap(G);
+    }
+    ///The type of the map that stores the dists of the nodes.
+ 
+    ///The type of the map that stores the dists of the nodes.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<int> DistMap;
+    ///Instantiates a DistMap.
+ 
+    ///This function instantiates a \ref DistMap. 
+    ///\param G is the graph, to which we would like to define the \ref DistMap
+    static DistMap *createDistMap(const GR &G)
+    {
+      return new DistMap(G);
+    }
+  };
+  
+  ///%BFS algorithm class.
+  
+  ///\ingroup search
+  ///This class provides an efficient implementation of the %BFS algorithm.
+  ///
+  ///\param GR The graph type the algorithm runs on. The default value is
+  ///\ref ListGraph. The value of GR is not used directly by Bfs, it
+  ///is only passed to \ref BfsDefaultTraits.
+  ///\param TR Traits class to set various data types used by the algorithm.
+  ///The default traits class is
+  ///\ref BfsDefaultTraits "BfsDefaultTraits<GR>".
+  ///See \ref BfsDefaultTraits for the documentation of
+  ///a Bfs traits class.
+  ///
+  ///\author Alpar Juttner
+
+#ifdef DOXYGEN
+  template <typename GR,
+	    typename TR>
+#else
+  template <typename GR=ListGraph,
+	    typename TR=BfsDefaultTraits<GR> >
+#endif
+  class Bfs {
+  public:
+    /**
+     * \brief \ref Exception for uninitialized parameters.
+     *
+     * This error represents problems in the initialization
+     * of the parameters of the algorithms.
+     */
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::Bfs::UninitializedParameter";
+      }
+    };
+
+    typedef TR Traits;
+    ///The type of the underlying graph.
+    typedef typename TR::Graph Graph;
+    
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    typedef typename TR::PredMap PredMap;
+    ///The type of the map indicating which nodes are reached.
+    typedef typename TR::ReachedMap ReachedMap;
+    ///The type of the map indicating which nodes are processed.
+    typedef typename TR::ProcessedMap ProcessedMap;
+    ///The type of the map that stores the dists of the nodes.
+    typedef typename TR::DistMap DistMap;
+  private:
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+
+    /// Pointer to the underlying graph.
+    const Graph *G;
+    ///Pointer to the map of predecessors edges.
+    PredMap *_pred;
+    ///Indicates if \ref _pred is locally allocated (\c true) or not.
+    bool local_pred;
+    ///Pointer to the map of distances.
+    DistMap *_dist;
+    ///Indicates if \ref _dist is locally allocated (\c true) or not.
+    bool local_dist;
+    ///Pointer to the map of reached status of the nodes.
+    ReachedMap *_reached;
+    ///Indicates if \ref _reached is locally allocated (\c true) or not.
+    bool local_reached;
+    ///Pointer to the map of processed status of the nodes.
+    ProcessedMap *_processed;
+    ///Indicates if \ref _processed is locally allocated (\c true) or not.
+    bool local_processed;
+
+    std::vector<typename Graph::Node> _queue;
+    int _queue_head,_queue_tail,_queue_next_dist;
+    int _curr_dist;
+
+    ///Creates the maps if necessary.
+    
+    ///\todo Better memory allocation (instead of new).
+    void create_maps() 
+    {
+      if(!_pred) {
+	local_pred = true;
+	_pred = Traits::createPredMap(*G);
+      }
+      if(!_dist) {
+	local_dist = true;
+	_dist = Traits::createDistMap(*G);
+      }
+      if(!_reached) {
+	local_reached = true;
+	_reached = Traits::createReachedMap(*G);
+      }
+      if(!_processed) {
+	local_processed = true;
+	_processed = Traits::createProcessedMap(*G);
+      }
+    }
+
+  protected:
+    
+    Bfs() {}
+    
+  public:
+ 
+    typedef Bfs Create;
+
+    ///\name Named template parameters
+
+    ///@{
+
+    template <class T>
+    struct DefPredMapTraits : public Traits {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///PredMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting PredMap type
+    ///
+    template <class T>
+    struct DefPredMap : public Bfs< Graph, DefPredMapTraits<T> > { 
+      typedef Bfs< Graph, DefPredMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefDistMapTraits : public Traits {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///DistMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting DistMap type
+    ///
+    template <class T>
+    struct DefDistMap : public Bfs< Graph, DefDistMapTraits<T> > { 
+      typedef Bfs< Graph, DefDistMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefReachedMapTraits : public Traits {
+      typedef T ReachedMap;
+      static ReachedMap *createReachedMap(const Graph &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///ReachedMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting ReachedMap type
+    ///
+    template <class T>
+    struct DefReachedMap : public Bfs< Graph, DefReachedMapTraits<T> > { 
+      typedef Bfs< Graph, DefReachedMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefProcessedMapTraits : public Traits {
+      typedef T ProcessedMap;
+      static ProcessedMap *createProcessedMap(const Graph &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///ProcessedMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting ProcessedMap type
+    ///
+    template <class T>
+    struct DefProcessedMap : public Bfs< Graph, DefProcessedMapTraits<T> > {
+      typedef Bfs< Graph, DefProcessedMapTraits<T> > Create;
+    };
+    
+    struct DefGraphProcessedMapTraits : public Traits {
+      typedef typename Graph::template NodeMap<bool> ProcessedMap;
+      static ProcessedMap *createProcessedMap(const Graph &G) 
+      {
+	return new ProcessedMap(G);
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter"
+    ///for setting the ProcessedMap type to be Graph::NodeMap<bool>.
+    ///
+    ///\ref named-templ-param "Named parameter"
+    ///for setting the ProcessedMap type to be Graph::NodeMap<bool>.
+    ///If you don't set it explicitly, it will be automatically allocated.
+    template <class T>
+    struct DefProcessedMapToBeDefaultMap :
+      public Bfs< Graph, DefGraphProcessedMapTraits> { 
+      typedef Bfs< Graph, DefGraphProcessedMapTraits> Create;
+    };
+    
+    ///@}
+
+  public:      
+    
+    ///Constructor.
+    
+    ///\param _G the graph the algorithm will run on.
+    ///
+    Bfs(const Graph& _G) :
+      G(&_G),
+      _pred(NULL), local_pred(false),
+      _dist(NULL), local_dist(false),
+      _reached(NULL), local_reached(false),
+      _processed(NULL), local_processed(false)
+    { }
+    
+    ///Destructor.
+    ~Bfs() 
+    {
+      if(local_pred) delete _pred;
+      if(local_dist) delete _dist;
+      if(local_reached) delete _reached;
+      if(local_processed) delete _processed;
+    }
+
+    ///Sets the map storing the predecessor edges.
+
+    ///Sets the map storing the predecessor edges.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destructor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Bfs &predMap(PredMap &m) 
+    {
+      if(local_pred) {
+	delete _pred;
+	local_pred=false;
+      }
+      _pred = &m;
+      return *this;
+    }
+
+    ///Sets the map indicating the reached nodes.
+
+    ///Sets the map indicating the reached nodes.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destructor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Bfs &reachedMap(ReachedMap &m) 
+    {
+      if(local_reached) {
+	delete _reached;
+	local_reached=false;
+      }
+      _reached = &m;
+      return *this;
+    }
+
+    ///Sets the map indicating the processed nodes.
+
+    ///Sets the map indicating the processed nodes.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destructor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Bfs &processedMap(ProcessedMap &m) 
+    {
+      if(local_processed) {
+	delete _processed;
+	local_processed=false;
+      }
+      _processed = &m;
+      return *this;
+    }
+
+    ///Sets the map storing the distances calculated by the algorithm.
+
+    ///Sets the map storing the distances calculated by the algorithm.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destructor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Bfs &distMap(DistMap &m) 
+    {
+      if(local_dist) {
+	delete _dist;
+	local_dist=false;
+      }
+      _dist = &m;
+      return *this;
+    }
+
+  public:
+    ///\name Execution control
+    ///The simplest way to execute the algorithm is to use
+    ///one of the member functions called \c run(...).
+    ///\n
+    ///If you need more control on the execution,
+    ///first you must call \ref init(), then you can add several source nodes
+    ///with \ref addSource().
+    ///Finally \ref start() will perform the actual path
+    ///computation.
+
+    ///@{
+
+    ///\brief Initializes the internal data structures.
+    ///
+    ///Initializes the internal data structures.
+    ///
+    void init()
+    {
+      create_maps();
+      _queue.resize(countNodes(*G));
+      _queue_head=_queue_tail=0;
+      _curr_dist=1;
+      for ( NodeIt u(*G) ; u!=INVALID ; ++u ) {
+	_pred->set(u,INVALID);
+	_reached->set(u,false);
+	_processed->set(u,false);
+      }
+    }
+    
+    ///Adds a new source node.
+
+    ///Adds a new source node to the set of nodes to be processed.
+    ///
+    void addSource(Node s)
+    {
+      if(!(*_reached)[s])
+	{
+	  _reached->set(s,true);
+	  _pred->set(s,INVALID);
+	  _dist->set(s,0);
+	  _queue[_queue_head++]=s;
+	  _queue_next_dist=_queue_head;
+	}
+    }
+    
+    ///Processes the next node.
+
+    ///Processes the next node.
+    ///
+    ///\return The processed node.
+    ///
+    ///\warning The queue must not be empty!
+    Node processNextNode()
+    {
+      if(_queue_tail==_queue_next_dist) {
+	_curr_dist++;
+	_queue_next_dist=_queue_head;
+      }
+      Node n=_queue[_queue_tail++];
+      _processed->set(n,true);
+      Node m;
+      for(OutEdgeIt e(*G,n);e!=INVALID;++e)
+	if(!(*_reached)[m=G->target(e)]) {
+	  _queue[_queue_head++]=m;
+	  _reached->set(m,true);
+	  _pred->set(m,e);
+	  _dist->set(m,_curr_dist);
+	}
+      return n;
+    }
+
+    ///Processes the next node.
+
+    ///Processes the next node. And checks that the given target node
+    ///is reached. If the target node is reachable from the processed
+    ///node then the reached parameter will be set true. The reached
+    ///parameter should be initially false.
+    ///
+    ///\param target The target node.
+    ///\retval reach Indicates that the target node is reached.
+    ///\return The processed node.
+    ///
+    ///\warning The queue must not be empty!
+    Node processNextNode(Node target, bool& reach)
+    {
+      if(_queue_tail==_queue_next_dist) {
+	_curr_dist++;
+	_queue_next_dist=_queue_head;
+      }
+      Node n=_queue[_queue_tail++];
+      _processed->set(n,true);
+      Node m;
+      for(OutEdgeIt e(*G,n);e!=INVALID;++e)
+	if(!(*_reached)[m=G->target(e)]) {
+	  _queue[_queue_head++]=m;
+	  _reached->set(m,true);
+	  _pred->set(m,e);
+	  _dist->set(m,_curr_dist);
+          reach = reach || (target == m);
+	}
+      return n;
+    }
+
+    ///Processes the next node.
+
+    ///Processes the next node. And checks that at least one of
+    ///reached node has true value in the \c nm node map. If one node
+    ///with true value is reachable from the processed node then the
+    ///rnode parameter will be set to the first of such nodes.
+    ///
+    ///\param nm The node map of possible targets.
+    ///\retval rnode The reached target node.
+    ///\return The processed node.
+    ///
+    ///\warning The queue must not be empty!
+    template<class NM>
+    Node processNextNode(const NM& nm, Node& rnode)
+    {
+      if(_queue_tail==_queue_next_dist) {
+	_curr_dist++;
+	_queue_next_dist=_queue_head;
+      }
+      Node n=_queue[_queue_tail++];
+      _processed->set(n,true);
+      Node m;
+      for(OutEdgeIt e(*G,n);e!=INVALID;++e)
+	if(!(*_reached)[m=G->target(e)]) {
+	  _queue[_queue_head++]=m;
+	  _reached->set(m,true);
+	  _pred->set(m,e);
+	  _dist->set(m,_curr_dist);
+	  if (nm[m] && rnode == INVALID) rnode = m;
+	}
+      return n;
+    }
+      
+    ///Next node to be processed.
+
+    ///Next node to be processed.
+    ///
+    ///\return The next node to be processed or INVALID if the queue is
+    /// empty.
+    Node nextNode()
+    { 
+      return _queue_tail<_queue_head?_queue[_queue_tail]:INVALID;
+    }
+ 
+    ///\brief Returns \c false if there are nodes
+    ///to be processed in the queue
+    ///
+    ///Returns \c false if there are nodes
+    ///to be processed in the queue
+    bool emptyQueue() { return _queue_tail==_queue_head; }
+    ///Returns the number of the nodes to be processed.
+    
+    ///Returns the number of the nodes to be processed in the queue.
+    int queueSize() { return _queue_head-_queue_tail; }
+    
+    ///Executes the algorithm.
+
+    ///Executes the algorithm.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///This method runs the %BFS algorithm from the root node(s)
+    ///in order to
+    ///compute the
+    ///shortest path to each node. The algorithm computes
+    ///- The shortest path tree.
+    ///- The distance of each node from the root(s).
+    void start()
+    {
+      while ( !emptyQueue() ) processNextNode();
+    }
+    
+    ///Executes the algorithm until \c dest is reached.
+
+    ///Executes the algorithm until \c dest is reached.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///This method runs the %BFS algorithm from the root node(s)
+    ///in order to compute the shortest path to \c dest.
+    ///The algorithm computes
+    ///- The shortest path to \c  dest.
+    ///- The distance of \c dest from the root(s).
+    void start(Node dest)
+    {
+      bool reach = false;
+      while ( !emptyQueue() && !reach ) processNextNode(dest, reach);
+    }
+    
+    ///Executes the algorithm until a condition is met.
+
+    ///Executes the algorithm until a condition is met.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///\param nm must be a bool (or convertible) node map. The
+    ///algorithm will stop when it reaches a node \c v with
+    /// <tt>nm[v]</tt> true.
+    ///
+    ///\return The reached node \c v with <tt>nm[v]</tt> true or
+    ///\c INVALID if no such node was found.
+    template<class NM>
+    Node start(const NM &nm)
+    {
+      Node rnode = INVALID;
+      while ( !emptyQueue() && rnode == INVALID ) {
+	processNextNode(nm, rnode);
+      }
+      return rnode;
+    }
+    
+    ///Runs %BFS algorithm from node \c s.
+    
+    ///This method runs the %BFS algorithm from a root node \c s
+    ///in order to
+    ///compute the
+    ///shortest path to each node. The algorithm computes
+    ///- The shortest path tree.
+    ///- The distance of each node from the root.
+    ///
+    ///\note b.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  b.init();
+    ///  b.addSource(s);
+    ///  b.start();
+    ///\endcode
+    void run(Node s) {
+      init();
+      addSource(s);
+      start();
+    }
+    
+    ///Finds the shortest path between \c s and \c t.
+    
+    ///Finds the shortest path between \c s and \c t.
+    ///
+    ///\return The length of the shortest s---t path if there exists one,
+    ///0 otherwise.
+    ///\note Apart from the return value, b.run(s) is
+    ///just a shortcut of the following code.
+    ///\code
+    ///  b.init();
+    ///  b.addSource(s);
+    ///  b.start(t);
+    ///\endcode
+    int run(Node s,Node t) {
+      init();
+      addSource(s);
+      start(t);
+      return reached(t) ? _curr_dist : 0;
+    }
+    
+    ///@}
+
+    ///\name Query Functions
+    ///The result of the %BFS algorithm can be obtained using these
+    ///functions.\n
+    ///Before the use of these functions,
+    ///either run() or start() must be calleb.
+    
+    ///@{
+
+    typedef PredMapPath<Graph, PredMap> Path;
+
+    ///Gives back the shortest path.
+    
+    ///Gives back the shortest path.
+    ///\pre The \c t should be reachable from the source.
+    Path path(Node t) 
+    {
+      return Path(*G, *_pred, t);
+    }
+
+    ///The distance of a node from the root(s).
+
+    ///Returns the distance of a node from the root(s).
+    ///\pre \ref run() must be called before using this function.
+    ///\warning If node \c v in unreachable from the root(s) the return value
+    ///of this function is undefined.
+    int dist(Node v) const { return (*_dist)[v]; }
+
+    ///Returns the 'previous edge' of the shortest path tree.
+
+    ///For a node \c v it returns the 'previous edge'
+    ///of the shortest path tree,
+    ///i.e. it returns the last edge of a shortest path from the root(s) to \c
+    ///v. It is \ref INVALID
+    ///if \c v is unreachable from the root(s) or \c v is a root. The
+    ///shortest path tree used here is equal to the shortest path tree used in
+    ///\ref predNode().
+    ///\pre Either \ref run() or \ref start() must be called before using
+    ///this function.
+    Edge predEdge(Node v) const { return (*_pred)[v];}
+
+    ///Returns the 'previous node' of the shortest path tree.
+
+    ///For a node \c v it returns the 'previous node'
+    ///of the shortest path tree,
+    ///i.e. it returns the last but one node from a shortest path from the
+    ///root(a) to \c /v.
+    ///It is INVALID if \c v is unreachable from the root(s) or
+    ///if \c v itself a root.
+    ///The shortest path tree used here is equal to the shortest path
+    ///tree used in \ref predEdge().
+    ///\pre Either \ref run() or \ref start() must be called before
+    ///using this function.
+    Node predNode(Node v) const { return (*_pred)[v]==INVALID ? INVALID:
+				  G->source((*_pred)[v]); }
+    
+    ///Returns a reference to the NodeMap of distances.
+
+    ///Returns a reference to the NodeMap of distances.
+    ///\pre Either \ref run() or \ref init() must
+    ///be called before using this function.
+    const DistMap &distMap() const { return *_dist;}
+ 
+    ///Returns a reference to the shortest path tree map.
+
+    ///Returns a reference to the NodeMap of the edges of the
+    ///shortest path tree.
+    ///\pre Either \ref run() or \ref init()
+    ///must be called before using this function.
+    const PredMap &predMap() const { return *_pred;}
+ 
+    ///Checks if a node is reachable from the root.
+
+    ///Returns \c true if \c v is reachable from the root.
+    ///\warning The source nodes are indicated as unreached.
+    ///\pre Either \ref run() or \ref start()
+    ///must be called before using this function.
+    ///
+    bool reached(Node v) { return (*_reached)[v]; }
+    
+    ///@}
+  };
+
+  ///Default traits class of Bfs function.
+
+  ///Default traits class of Bfs function.
+  ///\param GR Graph type.
+  template<class GR>
+  struct BfsWizardDefaultTraits
+  {
+    ///The graph type the algorithm runs on. 
+    typedef GR Graph;
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    /// 
+    ///The type of the map that stores the last
+    ///edges of the shortest paths.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef NullMap<typename Graph::Node,typename GR::Edge> PredMap;
+    ///Instantiates a PredMap.
+ 
+    ///This function instantiates a \ref PredMap. 
+    ///\param g is the graph, to which we would like to define the PredMap.
+    ///\todo The graph alone may be insufficient to initialize
+#ifdef DOXYGEN
+    static PredMap *createPredMap(const GR &g) 
+#else
+    static PredMap *createPredMap(const GR &) 
+#endif
+    {
+      return new PredMap();
+    }
+
+    ///The type of the map that indicates which nodes are processed.
+ 
+    ///The type of the map that indicates which nodes are processed.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef NullMap<typename Graph::Node,bool> ProcessedMap;
+    ///Instantiates a ProcessedMap.
+ 
+    ///This function instantiates a \ref ProcessedMap. 
+    ///\param g is the graph, to which
+    ///we would like to define the \ref ProcessedMap
+#ifdef DOXYGEN
+    static ProcessedMap *createProcessedMap(const GR &g)
+#else
+    static ProcessedMap *createProcessedMap(const GR &)
+#endif
+    {
+      return new ProcessedMap();
+    }
+    ///The type of the map that indicates which nodes are reached.
+ 
+    ///The type of the map that indicates which nodes are reached.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef typename Graph::template NodeMap<bool> ReachedMap;
+    ///Instantiates a ReachedMap.
+ 
+    ///This function instantiates a \ref ReachedMap. 
+    ///\param G is the graph, to which
+    ///we would like to define the \ref ReachedMap.
+    static ReachedMap *createReachedMap(const GR &G)
+    {
+      return new ReachedMap(G);
+    }
+    ///The type of the map that stores the dists of the nodes.
+ 
+    ///The type of the map that stores the dists of the nodes.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef NullMap<typename Graph::Node,int> DistMap;
+    ///Instantiates a DistMap.
+ 
+    ///This function instantiates a \ref DistMap. 
+    ///\param g is the graph, to which we would like to define the \ref DistMap
+#ifdef DOXYGEN
+    static DistMap *createDistMap(const GR &g)
+#else
+    static DistMap *createDistMap(const GR &)
+#endif
+    {
+      return new DistMap();
+    }
+  };
+  
+  /// Default traits used by \ref BfsWizard
+
+  /// To make it easier to use Bfs algorithm
+  ///we have created a wizard class.
+  /// This \ref BfsWizard class needs default traits,
+  ///as well as the \ref Bfs class.
+  /// The \ref BfsWizardBase is a class to be the default traits of the
+  /// \ref BfsWizard class.
+  template<class GR>
+  class BfsWizardBase : public BfsWizardDefaultTraits<GR>
+  {
+
+    typedef BfsWizardDefaultTraits<GR> Base;
+  protected:
+    /// Type of the nodes in the graph.
+    typedef typename Base::Graph::Node Node;
+
+    /// Pointer to the underlying graph.
+    void *_g;
+    ///Pointer to the map of reached nodes.
+    void *_reached;
+    ///Pointer to the map of processed nodes.
+    void *_processed;
+    ///Pointer to the map of predecessors edges.
+    void *_pred;
+    ///Pointer to the map of distances.
+    void *_dist;
+    ///Pointer to the source node.
+    Node _source;
+    
+    public:
+    /// Constructor.
+    
+    /// This constructor does not require parameters, therefore it initiates
+    /// all of the attributes to default values (0, INVALID).
+    BfsWizardBase() : _g(0), _reached(0), _processed(0), _pred(0),
+			   _dist(0), _source(INVALID) {}
+
+    /// Constructor.
+    
+    /// This constructor requires some parameters,
+    /// listed in the parameters list.
+    /// Others are initiated to 0.
+    /// \param g is the initial value of  \ref _g
+    /// \param s is the initial value of  \ref _source
+    BfsWizardBase(const GR &g, Node s=INVALID) :
+      _g(reinterpret_cast<void*>(const_cast<GR*>(&g))), 
+      _reached(0), _processed(0), _pred(0), _dist(0), _source(s) {}
+
+  };
+  
+  /// A class to make the usage of Bfs algorithm easier
+
+  /// This class is created to make it easier to use Bfs algorithm.
+  /// It uses the functions and features of the plain \ref Bfs,
+  /// but it is much simpler to use it.
+  ///
+  /// Simplicity means that the way to change the types defined
+  /// in the traits class is based on functions that returns the new class
+  /// and not on templatable built-in classes.
+  /// When using the plain \ref Bfs
+  /// the new class with the modified type comes from
+  /// the original class by using the ::
+  /// operator. In the case of \ref BfsWizard only
+  /// a function have to be called and it will
+  /// return the needed class.
+  ///
+  /// It does not have own \ref run method. When its \ref run method is called
+  /// it initiates a plain \ref Bfs class, and calls the \ref Bfs::run
+  /// method of it.
+  template<class TR>
+  class BfsWizard : public TR
+  {
+    typedef TR Base;
+
+    ///The type of the underlying graph.
+    typedef typename TR::Graph Graph;
+    //\e
+    typedef typename Graph::Node Node;
+    //\e
+    typedef typename Graph::NodeIt NodeIt;
+    //\e
+    typedef typename Graph::Edge Edge;
+    //\e
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    
+    ///\brief The type of the map that stores
+    ///the reached nodes
+    typedef typename TR::ReachedMap ReachedMap;
+    ///\brief The type of the map that stores
+    ///the processed nodes
+    typedef typename TR::ProcessedMap ProcessedMap;
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    typedef typename TR::PredMap PredMap;
+    ///The type of the map that stores the dists of the nodes.
+    typedef typename TR::DistMap DistMap;
+
+  public:
+    /// Constructor.
+    BfsWizard() : TR() {}
+
+    /// Constructor that requires parameters.
+
+    /// Constructor that requires parameters.
+    /// These parameters will be the default values for the traits class.
+    BfsWizard(const Graph &g, Node s=INVALID) :
+      TR(g,s) {}
+
+    ///Copy constructor
+    BfsWizard(const TR &b) : TR(b) {}
+
+    ~BfsWizard() {}
+
+    ///Runs Bfs algorithm from a given node.
+    
+    ///Runs Bfs algorithm from a given node.
+    ///The node can be given by the \ref source function.
+    void run()
+    {
+      if(Base::_source==INVALID) throw UninitializedParameter();
+      Bfs<Graph,TR> alg(*reinterpret_cast<const Graph*>(Base::_g));
+      if(Base::_reached)
+	alg.reachedMap(*reinterpret_cast<ReachedMap*>(Base::_reached));
+      if(Base::_processed) 
+        alg.processedMap(*reinterpret_cast<ProcessedMap*>(Base::_processed));
+      if(Base::_pred) 
+        alg.predMap(*reinterpret_cast<PredMap*>(Base::_pred));
+      if(Base::_dist) 
+        alg.distMap(*reinterpret_cast<DistMap*>(Base::_dist));
+      alg.run(Base::_source);
+    }
+
+    ///Runs Bfs algorithm from the given node.
+
+    ///Runs Bfs algorithm from the given node.
+    ///\param s is the given source.
+    void run(Node s)
+    {
+      Base::_source=s;
+      run();
+    }
+
+    template<class T>
+    struct DefPredMapBase : public Base {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph &) { return 0; };
+      DefPredMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting PredMap
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting PredMap
+    ///
+    template<class T>
+    BfsWizard<DefPredMapBase<T> > predMap(const T &t) 
+    {
+      Base::_pred=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return BfsWizard<DefPredMapBase<T> >(*this);
+    }
+    
+ 
+    template<class T>
+    struct DefReachedMapBase : public Base {
+      typedef T ReachedMap;
+      static ReachedMap *createReachedMap(const Graph &) { return 0; };
+      DefReachedMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting ReachedMap
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting ReachedMap
+    ///
+    template<class T>
+    BfsWizard<DefReachedMapBase<T> > reachedMap(const T &t) 
+    {
+      Base::_reached=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return BfsWizard<DefReachedMapBase<T> >(*this);
+    }
+    
+
+    template<class T>
+    struct DefProcessedMapBase : public Base {
+      typedef T ProcessedMap;
+      static ProcessedMap *createProcessedMap(const Graph &) { return 0; };
+      DefProcessedMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting ProcessedMap
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting ProcessedMap
+    ///
+    template<class T>
+    BfsWizard<DefProcessedMapBase<T> > processedMap(const T &t) 
+    {
+      Base::_processed=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return BfsWizard<DefProcessedMapBase<T> >(*this);
+    }
+    
+   
+    template<class T>
+    struct DefDistMapBase : public Base {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph &) { return 0; };
+      DefDistMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    template<class T>
+    BfsWizard<DefDistMapBase<T> > distMap(const T &t) 
+    {
+      Base::_dist=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return BfsWizard<DefDistMapBase<T> >(*this);
+    }
+    
+    /// Sets the source node, from which the Bfs algorithm runs.
+
+    /// Sets the source node, from which the Bfs algorithm runs.
+    /// \param s is the source node.
+    BfsWizard<TR> &source(Node s) 
+    {
+      Base::_source=s;
+      return *this;
+    }
+    
+  };
+  
+  ///Function type interface for Bfs algorithm.
+
+  /// \ingroup search
+  ///Function type interface for Bfs algorithm.
+  ///
+  ///This function also has several
+  ///\ref named-templ-func-param "named parameters",
+  ///they are declared as the members of class \ref BfsWizard.
+  ///The following
+  ///example shows how to use these parameters.
+  ///\code
+  ///  bfs(g,source).predMap(preds).run();
+  ///\endcode
+  ///\warning Don't forget to put the \ref BfsWizard::run() "run()"
+  ///to the end of the parameter list.
+  ///\sa BfsWizard
+  ///\sa Bfs
+  template<class GR>
+  BfsWizard<BfsWizardBase<GR> >
+  bfs(const GR &g,typename GR::Node s=INVALID)
+  {
+    return BfsWizard<BfsWizardBase<GR> >(g,s);
+  }
+
+#ifdef DOXYGEN
+  /// \brief Visitor class for bfs.
+  ///  
+  /// This class defines the interface of the BfsVisit events, and
+  /// it could be the base of a real Visitor class.
+  template <typename _Graph>
+  struct BfsVisitor {
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::Node Node;
+    /// \brief Called when the edge reach a node.
+    /// 
+    /// It is called when the bfs find an edge which target is not
+    /// reached yet.
+    void discover(const Edge& edge) {}
+    /// \brief Called when the node reached first time.
+    /// 
+    /// It is Called when the node reached first time.
+    void reach(const Node& node) {}
+    /// \brief Called when the edge examined but target of the edge 
+    /// already discovered.
+    /// 
+    /// It called when the edge examined but the target of the edge 
+    /// already discovered.
+    void examine(const Edge& edge) {}
+    /// \brief Called for the source node of the bfs.
+    /// 
+    /// It is called for the source node of the bfs.
+    void start(const Node& node) {}
+    /// \brief Called when the node processed.
+    /// 
+    /// It is Called when the node processed.
+    void process(const Node& node) {}
+  };
+#else
+  template <typename _Graph>
+  struct BfsVisitor {
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::Node Node;
+    void discover(const Edge&) {}
+    void reach(const Node&) {}
+    void examine(const Edge&) {}
+    void start(const Node&) {}
+    void process(const Node&) {}
+
+    template <typename _Visitor>
+    struct Constraints {
+      void constraints() {
+	Edge edge;
+	Node node;
+	visitor.discover(edge);
+	visitor.reach(node);
+	visitor.examine(edge);
+	visitor.start(node);
+        visitor.process(node);
+      }
+      _Visitor& visitor;
+    };
+  };
+#endif
+
+  /// \brief Default traits class of BfsVisit class.
+  ///
+  /// Default traits class of BfsVisit class.
+  /// \param _Graph Graph type.
+  template<class _Graph>
+  struct BfsVisitDefaultTraits {
+
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that indicates which nodes are reached.
+    /// 
+    /// The type of the map that indicates which nodes are reached.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    /// \todo named parameter to set this type, function to read and write.
+    typedef typename Graph::template NodeMap<bool> ReachedMap;
+
+    /// \brief Instantiates a ReachedMap.
+    ///
+    /// This function instantiates a \ref ReachedMap. 
+    /// \param graph is the graph, to which
+    /// we would like to define the \ref ReachedMap.
+    static ReachedMap *createReachedMap(const Graph &graph) {
+      return new ReachedMap(graph);
+    }
+
+  };
+
+  /// \ingroup search
+  ///  
+  /// \brief %BFS Visit algorithm class.
+  ///  
+  /// This class provides an efficient implementation of the %BFS algorithm
+  /// with visitor interface.
+  ///
+  /// The %BfsVisit class provides an alternative interface to the Bfs
+  /// class. It works with callback mechanism, the BfsVisit object calls
+  /// on every bfs event the \c Visitor class member functions. 
+  ///
+  /// \param _Graph The graph type the algorithm runs on. The default value is
+  /// \ref ListGraph. The value of _Graph is not used directly by Bfs, it
+  /// is only passed to \ref BfsDefaultTraits.
+  /// \param _Visitor The Visitor object for the algorithm. The 
+  /// \ref BfsVisitor "BfsVisitor<_Graph>" is an empty Visitor which
+  /// does not observe the Bfs events. If you want to observe the bfs
+  /// events you should implement your own Visitor class.
+  /// \param _Traits Traits class to set various data types used by the 
+  /// algorithm. The default traits class is
+  /// \ref BfsVisitDefaultTraits "BfsVisitDefaultTraits<_Graph>".
+  /// See \ref BfsVisitDefaultTraits for the documentation of
+  /// a Bfs visit traits class.
+  ///
+  /// \author Jacint Szabo, Alpar Juttner and Balazs Dezso
+#ifdef DOXYGEN
+  template <typename _Graph, typename _Visitor, typename _Traits>
+#else
+  template <typename _Graph = ListGraph,
+	    typename _Visitor = BfsVisitor<_Graph>,
+	    typename _Traits = BfsDefaultTraits<_Graph> >
+#endif
+  class BfsVisit {
+  public:
+    
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() 
+      {
+	return "lemon::BfsVisit::UninitializedParameter";
+      }
+    };
+
+    typedef _Traits Traits;
+
+    typedef typename Traits::Graph Graph;
+
+    typedef _Visitor Visitor;
+
+    ///The type of the map indicating which nodes are reached.
+    typedef typename Traits::ReachedMap ReachedMap;
+
+  private:
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+
+    /// Pointer to the underlying graph.
+    const Graph *_graph;
+    /// Pointer to the visitor object.
+    Visitor *_visitor;
+    ///Pointer to the map of reached status of the nodes.
+    ReachedMap *_reached;
+    ///Indicates if \ref _reached is locally allocated (\c true) or not.
+    bool local_reached;
+
+    std::vector<typename Graph::Node> _list;
+    int _list_front, _list_back;
+
+    /// \brief Creates the maps if necessary.
+    ///
+    /// Creates the maps if necessary.
+    void create_maps() {
+      if(!_reached) {
+	local_reached = true;
+	_reached = Traits::createReachedMap(*_graph);
+      }
+    }
+
+  protected:
+
+    BfsVisit() {}
+    
+  public:
+
+    typedef BfsVisit Create;
+
+    /// \name Named template parameters
+
+    ///@{
+    template <class T>
+    struct DefReachedMapTraits : public Traits {
+      typedef T ReachedMap;
+      static ReachedMap *createReachedMap(const Graph &graph) {
+	throw UninitializedParameter();
+      }
+    };
+    /// \brief \ref named-templ-param "Named parameter" for setting 
+    /// ReachedMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting ReachedMap type
+    template <class T>
+    struct DefReachedMap : public BfsVisit< Graph, Visitor,
+					    DefReachedMapTraits<T> > {
+      typedef BfsVisit< Graph, Visitor, DefReachedMapTraits<T> > Create;
+    };
+    ///@}
+
+  public:      
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor.
+    ///
+    /// \param graph the graph the algorithm will run on.
+    /// \param visitor The visitor of the algorithm.
+    ///
+    BfsVisit(const Graph& graph, Visitor& visitor) 
+      : _graph(&graph), _visitor(&visitor),
+	_reached(0), local_reached(false) {}
+    
+    /// \brief Destructor.
+    ///
+    /// Destructor.
+    ~BfsVisit() {
+      if(local_reached) delete _reached;
+    }
+
+    /// \brief Sets the map indicating if a node is reached.
+    ///
+    /// Sets the map indicating if a node is reached.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return <tt> (*this) </tt>
+    BfsVisit &reachedMap(ReachedMap &m) {
+      if(local_reached) {
+	delete _reached;
+	local_reached = false;
+      }
+      _reached = &m;
+      return *this;
+    }
+
+  public:
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run(...).
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init(), then you can adda source node
+    /// with \ref addSource().
+    /// Finally \ref start() will perform the actual path
+    /// computation.
+
+    /// @{
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    ///
+    void init() {
+      create_maps();
+      _list.resize(countNodes(*_graph));
+      _list_front = _list_back = -1;
+      for (NodeIt u(*_graph) ; u != INVALID ; ++u) {
+	_reached->set(u, false);
+      }
+    }
+    
+    /// \brief Adds a new source node.
+    ///
+    /// Adds a new source node to the set of nodes to be processed.
+    void addSource(Node s) {
+      if(!(*_reached)[s]) {
+	  _reached->set(s,true);
+	  _visitor->start(s);
+	  _visitor->reach(s);
+          _list[++_list_back] = s;
+	}
+    }
+    
+    /// \brief Processes the next node.
+    ///
+    /// Processes the next node.
+    ///
+    /// \return The processed node.
+    ///
+    /// \pre The queue must not be empty!
+    Node processNextNode() { 
+      Node n = _list[++_list_front];
+      _visitor->process(n);
+      Edge e;
+      for (_graph->firstOut(e, n); e != INVALID; _graph->nextOut(e)) {
+        Node m = _graph->target(e);
+        if (!(*_reached)[m]) {
+          _visitor->discover(e);
+          _visitor->reach(m);
+          _reached->set(m, true);
+          _list[++_list_back] = m;
+        } else {
+          _visitor->examine(e);
+        }
+      }
+      return n;
+    }
+
+    /// \brief Processes the next node.
+    ///
+    /// Processes the next node. And checks that the given target node
+    /// is reached. If the target node is reachable from the processed
+    /// node then the reached parameter will be set true. The reached
+    /// parameter should be initially false.
+    ///
+    /// \param target The target node.
+    /// \retval reach Indicates that the target node is reached.
+    /// \return The processed node.
+    ///
+    /// \warning The queue must not be empty!
+    Node processNextNode(Node target, bool& reach) {
+      Node n = _list[++_list_front];
+      _visitor->process(n);
+      Edge e;
+      for (_graph->firstOut(e, n); e != INVALID; _graph->nextOut(e)) {
+        Node m = _graph->target(e);
+        if (!(*_reached)[m]) {
+          _visitor->discover(e);
+          _visitor->reach(m);
+          _reached->set(m, true);
+          _list[++_list_back] = m;
+          reach = reach || (target == m);
+        } else {
+          _visitor->examine(e);
+        }
+      }
+      return n;
+    }
+
+    /// \brief Processes the next node.
+    ///
+    /// Processes the next node. And checks that at least one of
+    /// reached node has true value in the \c nm node map. If one node
+    /// with true value is reachable from the processed node then the
+    /// rnode parameter will be set to the first of such nodes.
+    ///
+    /// \param nm The node map of possible targets.
+    /// \retval rnode The reached target node.
+    /// \return The processed node.
+    ///
+    /// \warning The queue must not be empty!
+    template <typename NM>
+    Node processNextNode(const NM& nm, Node& rnode) {
+      Node n = _list[++_list_front];
+      _visitor->process(n);
+      Edge e;
+      for (_graph->firstOut(e, n); e != INVALID; _graph->nextOut(e)) {
+        Node m = _graph->target(e);
+        if (!(*_reached)[m]) {
+          _visitor->discover(e);
+          _visitor->reach(m);
+          _reached->set(m, true);
+          _list[++_list_back] = m;
+          if (nm[m] && rnode == INVALID) rnode = m;
+        } else {
+          _visitor->examine(e);
+        }
+      }
+      return n;
+    }
+
+    /// \brief Next node to be processed.
+    ///
+    /// Next node to be processed.
+    ///
+    /// \return The next node to be processed or INVALID if the stack is
+    /// empty.
+    Node nextNode() { 
+      return _list_front != _list_back ? _list[_list_front + 1] : INVALID;
+    }
+
+    /// \brief Returns \c false if there are nodes
+    /// to be processed in the queue
+    ///
+    /// Returns \c false if there are nodes
+    /// to be processed in the queue
+    bool emptyQueue() { return _list_front == _list_back; }
+
+    /// \brief Returns the number of the nodes to be processed.
+    ///
+    /// Returns the number of the nodes to be processed in the queue.
+    int queueSize() { return _list_back - _list_front; }
+    
+    /// \brief Executes the algorithm.
+    ///
+    /// Executes the algorithm.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    void start() {
+      while ( !emptyQueue() ) processNextNode();
+    }
+    
+    /// \brief Executes the algorithm until \c dest is reached.
+    ///
+    /// Executes the algorithm until \c dest is reached.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    void start(Node dest) {
+      bool reach = false;
+      while ( !emptyQueue() && !reach ) processNextNode(dest, reach);
+    }
+    
+    /// \brief Executes the algorithm until a condition is met.
+    ///
+    /// Executes the algorithm until a condition is met.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    ///
+    ///\param nm must be a bool (or convertible) node map. The
+    ///algorithm will stop when it reaches a node \c v with
+    /// <tt>nm[v]</tt> true.
+    ///
+    ///\return The reached node \c v with <tt>nm[v]</tt> true or
+    ///\c INVALID if no such node was found.
+    template <typename NM>
+    Node start(const NM &nm) {
+      Node rnode = INVALID;
+      while ( !emptyQueue() && rnode == INVALID ) {
+	processNextNode(nm, rnode);
+      }
+      return rnode;
+    }
+
+    /// \brief Runs %BFSVisit algorithm from node \c s.
+    ///
+    /// This method runs the %BFS algorithm from a root node \c s.
+    /// \note b.run(s) is just a shortcut of the following code.
+    ///\code
+    ///   b.init();
+    ///   b.addSource(s);
+    ///   b.start();
+    ///\endcode
+    void run(Node s) {
+      init();
+      addSource(s);
+      start();
+    }
+
+    /// \brief Runs %BFSVisit algorithm to visit all nodes in the graph.
+    ///    
+    /// This method runs the %BFS algorithm in order to
+    /// compute the %BFS path to each node. The algorithm computes
+    /// - The %BFS tree.
+    /// - The distance of each node from the root in the %BFS tree.
+    ///
+    ///\note b.run() is just a shortcut of the following code.
+    ///\code
+    ///  b.init();
+    ///  for (NodeIt it(graph); it != INVALID; ++it) {
+    ///    if (!b.reached(it)) {
+    ///      b.addSource(it);
+    ///      b.start();
+    ///    }
+    ///  }
+    ///\endcode
+    void run() {
+      init();
+      for (NodeIt it(*_graph); it != INVALID; ++it) {
+        if (!reached(it)) {
+          addSource(it);
+          start();
+        }
+      }
+    }
+    ///@}
+
+    /// \name Query Functions
+    /// The result of the %BFS algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    ///@{
+
+    /// \brief Checks if a node is reachable from the root.
+    ///
+    /// Returns \c true if \c v is reachable from the root(s).
+    /// \warning The source nodes are inditated as unreachable.
+    /// \pre Either \ref run() or \ref start()
+    /// must be called before using this function.
+    ///
+    bool reached(Node v) { return (*_reached)[v]; }
+    ///@}
+  };
+
+} //END OF NAMESPACE LEMON
+
+#endif
+
Index: lemon/bin_heap.h
===================================================================
--- lemon/bin_heap.h	(revision 2553)
+++ lemon/bin_heap.h	(revision 2553)
@@ -0,0 +1,346 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BIN_HEAP_H
+#define LEMON_BIN_HEAP_H
+
+///\ingroup auxdat
+///\file
+///\brief Binary Heap implementation.
+
+#include <vector>
+#include <utility>
+#include <functional>
+
+namespace lemon {
+
+  ///\ingroup auxdat
+  ///
+  ///\brief A Binary Heap implementation.
+  ///
+  ///This class implements the \e binary \e heap data structure. A \e heap
+  ///is a data structure for storing items with specified values called \e
+  ///priorities in such a way that finding the item with minimum priority is
+  ///efficient. \c Compare specifies the ordering of the priorities. In a heap
+  ///one can change the priority of an item, add or erase an item, etc.
+  ///
+  ///\param _Prio Type of the priority of the items.
+  ///\param _ItemIntMap A read and writable Item int map, used internally
+  ///to handle the cross references.
+  ///\param _Compare A class for the ordering of the priorities. The
+  ///default is \c std::less<_Prio>.
+  ///
+  ///\sa FibHeap
+  ///\sa Dijkstra
+  template <typename _Prio, typename _ItemIntMap,
+	    typename _Compare = std::less<_Prio> >
+  class BinHeap {
+
+  public:
+    ///\e
+    typedef _ItemIntMap ItemIntMap;
+    ///\e
+    typedef _Prio Prio;
+    ///\e
+    typedef typename ItemIntMap::Key Item;
+    ///\e
+    typedef std::pair<Item,Prio> Pair;
+    ///\e
+    typedef _Compare Compare;
+
+    /// \brief Type to represent the items states.
+    ///
+    /// Each Item element have a state associated to it. It may be "in heap",
+    /// "pre heap" or "post heap". The latter two are indifferent from the
+    /// heap's point of view, but may be useful to the user.
+    ///
+    /// The ItemIntMap \e should be initialized in such way that it maps
+    /// PRE_HEAP (-1) to any element to be put in the heap...
+    enum State {
+      IN_HEAP = 0,
+      PRE_HEAP = -1,
+      POST_HEAP = -2
+    };
+
+  private:
+    std::vector<Pair> data;
+    Compare comp;
+    ItemIntMap &iim;
+
+  public:
+    /// \brief The constructor.
+    ///
+    /// The constructor.
+    /// \param _iim should be given to the constructor, since it is used
+    /// internally to handle the cross references. The value of the map
+    /// should be PRE_HEAP (-1) for each element.
+    explicit BinHeap(ItemIntMap &_iim) : iim(_iim) {}
+    
+    /// \brief The constructor.
+    ///
+    /// The constructor.
+    /// \param _iim should be given to the constructor, since it is used
+    /// internally to handle the cross references. The value of the map
+    /// should be PRE_HEAP (-1) for each element.
+    ///
+    /// \param _comp The comparator function object.
+    BinHeap(ItemIntMap &_iim, const Compare &_comp) 
+      : iim(_iim), comp(_comp) {}
+
+
+    /// The number of items stored in the heap.
+    ///
+    /// \brief Returns the number of items stored in the heap.
+    int size() const { return data.size(); }
+    
+    /// \brief Checks if the heap stores no items.
+    ///
+    /// Returns \c true if and only if the heap stores no items.
+    bool empty() const { return data.empty(); }
+
+    /// \brief Make empty this heap.
+    /// 
+    /// Make empty this heap. It does not change the cross reference map.
+    /// If you want to reuse what is not surely empty you should first clear
+    /// the heap and after that you should set the cross reference map for
+    /// each item to \c PRE_HEAP.
+    void clear() { 
+      data.clear(); 
+    }
+
+  private:
+    static int parent(int i) { return (i-1)/2; }
+
+    static int second_child(int i) { return 2*i+2; }
+    bool less(const Pair &p1, const Pair &p2) const {
+      return comp(p1.second, p2.second);
+    }
+
+    int bubble_up(int hole, Pair p) {
+      int par = parent(hole);
+      while( hole>0 && less(p,data[par]) ) {
+	move(data[par],hole);
+	hole = par;
+	par = parent(hole);
+      }
+      move(p, hole);
+      return hole;
+    }
+
+    int bubble_down(int hole, Pair p, int length) {
+      int child = second_child(hole);
+      while(child < length) {
+	if( less(data[child-1], data[child]) ) {
+	  --child;
+	}
+	if( !less(data[child], p) )
+	  goto ok;
+	move(data[child], hole);
+	hole = child;
+	child = second_child(hole);
+      }
+      child--;
+      if( child<length && less(data[child], p) ) {
+	move(data[child], hole);
+	hole=child;
+      }
+    ok:
+      move(p, hole);
+      return hole;
+    }
+
+    void move(const Pair &p, int i) {
+      data[i] = p;
+      iim.set(p.first, i);
+    }
+
+  public:
+    /// \brief Insert a pair of item and priority into the heap.
+    ///
+    /// Adds \c p.first to the heap with priority \c p.second.
+    /// \param p The pair to insert.
+    void push(const Pair &p) {
+      int n = data.size();
+      data.resize(n+1);
+      bubble_up(n, p);
+    }
+
+    /// \brief Insert an item into the heap with the given heap.
+    ///    
+    /// Adds \c i to the heap with priority \c p. 
+    /// \param i The item to insert.
+    /// \param p The priority of the item.
+    void push(const Item &i, const Prio &p) { push(Pair(i,p)); }
+
+    /// \brief Returns the item with minimum priority relative to \c Compare.
+    ///
+    /// This method returns the item with minimum priority relative to \c
+    /// Compare.  
+    /// \pre The heap must be nonempty.  
+    Item top() const {
+      return data[0].first;
+    }
+
+    /// \brief Returns the minimum priority relative to \c Compare.
+    ///
+    /// It returns the minimum priority relative to \c Compare.
+    /// \pre The heap must be nonempty.
+    Prio prio() const {
+      return data[0].second;
+    }
+
+    /// \brief Deletes the item with minimum priority relative to \c Compare.
+    ///
+    /// This method deletes the item with minimum priority relative to \c
+    /// Compare from the heap.  
+    /// \pre The heap must be non-empty.  
+    void pop() {
+      int n = data.size()-1;
+      iim.set(data[0].first, POST_HEAP);
+      if (n > 0) {
+	bubble_down(0, data[n], n);
+      }
+      data.pop_back();
+    }
+
+    /// \brief Deletes \c i from the heap.
+    ///
+    /// This method deletes item \c i from the heap.
+    /// \param i The item to erase.
+    /// \pre The item should be in the heap.
+    void erase(const Item &i) {
+      int h = iim[i];
+      int n = data.size()-1;
+      iim.set(data[h].first, POST_HEAP);
+      if( h < n ) {
+	if ( bubble_up(h, data[n]) == h) {
+	  bubble_down(h, data[n], n);
+	}
+      }
+      data.pop_back();
+    }
+
+    
+    /// \brief Returns the priority of \c i.
+    ///
+    /// This function returns the priority of item \c i.  
+    /// \pre \c i must be in the heap.
+    /// \param i The item.
+    Prio operator[](const Item &i) const {
+      int idx = iim[i];
+      return data[idx].second;
+    }
+
+    /// \brief \c i gets to the heap with priority \c p independently 
+    /// if \c i was already there.
+    ///
+    /// This method calls \ref push(\c i, \c p) if \c i is not stored
+    /// in the heap and sets the priority of \c i to \c p otherwise.
+    /// \param i The item.
+    /// \param p The priority.
+    void set(const Item &i, const Prio &p) {
+      int idx = iim[i];
+      if( idx < 0 ) {
+	push(i,p);
+      }
+      else if( comp(p, data[idx].second) ) {
+	bubble_up(idx, Pair(i,p));
+      }
+      else {
+	bubble_down(idx, Pair(i,p), data.size());
+      }
+    }
+
+    /// \brief Decreases the priority of \c i to \c p.
+    ///
+    /// This method decreases the priority of item \c i to \c p.
+    /// \pre \c i must be stored in the heap with priority at least \c
+    /// p relative to \c Compare.
+    /// \param i The item.
+    /// \param p The priority.
+    void decrease(const Item &i, const Prio &p) {
+      int idx = iim[i];
+      bubble_up(idx, Pair(i,p));
+    }
+    
+    /// \brief Increases the priority of \c i to \c p.
+    ///
+    /// This method sets the priority of item \c i to \c p. 
+    /// \pre \c i must be stored in the heap with priority at most \c
+    /// p relative to \c Compare.
+    /// \param i The item.
+    /// \param p The priority.
+    void increase(const Item &i, const Prio &p) {
+      int idx = iim[i];
+      bubble_down(idx, Pair(i,p), data.size());
+    }
+
+    /// \brief Returns if \c item is in, has already been in, or has 
+    /// never been in the heap.
+    ///
+    /// This method returns PRE_HEAP if \c item has never been in the
+    /// heap, IN_HEAP if it is in the heap at the moment, and POST_HEAP
+    /// otherwise. In the latter case it is possible that \c item will
+    /// get back to the heap again.
+    /// \param i The item.
+    State state(const Item &i) const {
+      int s = iim[i];
+      if( s>=0 )
+	s=0;
+      return State(s);
+    }
+
+    /// \brief Sets the state of the \c item in the heap.
+    ///
+    /// Sets the state of the \c item in the heap. It can be used to
+    /// manually clear the heap when it is important to achive the
+    /// better time complexity.
+    /// \param i The item.
+    /// \param st The state. It should not be \c IN_HEAP. 
+    void state(const Item& i, State st) {
+      switch (st) {
+      case POST_HEAP:
+      case PRE_HEAP:
+        if (state(i) == IN_HEAP) {
+          erase(i);
+        }
+        iim[i] = st;
+        break;
+      case IN_HEAP:
+        break;
+      }
+    }
+
+    /// \brief Replaces an item in the heap.
+    ///
+    /// The \c i item is replaced with \c j item. The \c i item should
+    /// be in the heap, while the \c j should be out of the heap. The
+    /// \c i item will out of the heap and \c j will be in the heap
+    /// with the same prioriority as prevoiusly the \c i item.
+    void replace(const Item& i, const Item& j) {
+      int idx = iim[i];
+      iim.set(i, iim[j]);
+      iim.set(j, idx);
+      data[idx].first = j;
+    }
+
+  }; // class BinHeap
+  
+} // namespace lemon
+
+#endif // LEMON_BIN_HEAP_H
Index: lemon/bipartite_matching.h
===================================================================
--- lemon/bipartite_matching.h	(revision 2553)
+++ lemon/bipartite_matching.h	(revision 2553)
@@ -0,0 +1,1727 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BIPARTITE_MATCHING
+#define LEMON_BIPARTITE_MATCHING
+
+#include <functional>
+
+#include <lemon/bin_heap.h>
+#include <lemon/maps.h>
+
+#include <iostream>
+
+///\ingroup matching
+///\file
+///\brief Maximum matching algorithms in bipartite graphs.
+///
+///\note The pr_bipartite_matching.h file also contains algorithms to
+///solve maximum cardinality bipartite matching problems.
+
+namespace lemon {
+
+  /// \ingroup matching
+  ///
+  /// \brief Bipartite Max Cardinality Matching algorithm
+  ///
+  /// Bipartite Max Cardinality Matching algorithm. This class implements
+  /// the Hopcroft-Karp algorithm which has \f$ O(e\sqrt{n}) \f$ time
+  /// complexity.
+  ///
+  /// \note In several cases the push-relabel based algorithms have
+  /// better runtime performance than the augmenting path based ones. 
+  ///
+  /// \see PrBipartiteMatching
+  template <typename BpUGraph>
+  class MaxBipartiteMatching {
+  protected:
+
+    typedef BpUGraph Graph;
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::ANodeIt ANodeIt;
+    typedef typename Graph::BNodeIt BNodeIt;
+    typedef typename Graph::UEdge UEdge;
+    typedef typename Graph::UEdgeIt UEdgeIt;
+    typedef typename Graph::IncEdgeIt IncEdgeIt;
+
+    typedef typename BpUGraph::template ANodeMap<UEdge> ANodeMatchingMap;
+    typedef typename BpUGraph::template BNodeMap<UEdge> BNodeMatchingMap;
+
+
+  public:
+
+    /// \brief Constructor.
+    ///
+    /// Constructor of the algorithm. 
+    MaxBipartiteMatching(const BpUGraph& graph) 
+      : _matching(graph), _rmatching(graph), _reached(graph), _graph(&graph) {}
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run().
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init() or one alternative for it.
+    /// Finally \ref start() will perform the matching computation or
+    /// with step-by-step execution you can augment the solution.
+
+    /// @{
+
+    /// \brief Initalize the data structures.
+    ///
+    /// It initalizes the data structures and creates an empty matching.
+    void init() {
+      for (ANodeIt it(*_graph); it != INVALID; ++it) {
+        _matching.set(it, INVALID);
+      }
+      for (BNodeIt it(*_graph); it != INVALID; ++it) {
+        _rmatching.set(it, INVALID);
+	_reached.set(it, -1);
+      }
+      _size = 0;
+      _phase = -1;
+    }
+
+    /// \brief Initalize the data structures.
+    ///
+    /// It initalizes the data structures and creates a greedy
+    /// matching.  From this matching sometimes it is faster to get
+    /// the matching than from the initial empty matching.
+    void greedyInit() {
+      _size = 0;
+      for (BNodeIt it(*_graph); it != INVALID; ++it) {
+        _rmatching.set(it, INVALID);
+	_reached.set(it, 0);
+      }
+      for (ANodeIt it(*_graph); it != INVALID; ++it) {
+        _matching[it] = INVALID;
+        for (IncEdgeIt jt(*_graph, it); jt != INVALID; ++jt) {
+          if (_rmatching[_graph->bNode(jt)] == INVALID) {
+            _matching.set(it, jt);
+	    _rmatching.set(_graph->bNode(jt), jt);
+	    _reached.set(_graph->bNode(jt), -1);
+            ++_size;
+            break;
+          }
+        }
+      }
+      _phase = 0;
+    }
+
+    /// \brief Initalize the data structures with an initial matching.
+    ///
+    /// It initalizes the data structures with an initial matching.
+    template <typename MatchingMap>
+    void matchingInit(const MatchingMap& mm) {
+      for (ANodeIt it(*_graph); it != INVALID; ++it) {
+        _matching.set(it, INVALID);
+      }
+      for (BNodeIt it(*_graph); it != INVALID; ++it) {
+        _rmatching.set(it, INVALID);
+	_reached.set(it, 0);
+      }
+      _size = 0;
+      for (UEdgeIt it(*_graph); it != INVALID; ++it) {
+        if (mm[it]) {
+          ++_size;
+          _matching.set(_graph->aNode(it), it);
+          _rmatching.set(_graph->bNode(it), it);
+	  _reached.set(it, 0);
+        }
+      }
+      _phase = 0;
+    }
+
+    /// \brief Initalize the data structures with an initial matching.
+    ///
+    /// It initalizes the data structures with an initial matching.
+    /// \return %True when the given map contains really a matching.
+    template <typename MatchingMap>
+    bool checkedMatchingInit(const MatchingMap& mm) {
+      for (ANodeIt it(*_graph); it != INVALID; ++it) {
+        _matching.set(it, INVALID);
+      }
+      for (BNodeIt it(*_graph); it != INVALID; ++it) {
+        _rmatching.set(it, INVALID);
+	_reached.set(it, 0);
+      }
+      _size = 0;
+      for (UEdgeIt it(*_graph); it != INVALID; ++it) {
+        if (mm[it]) {
+          ++_size;
+          if (_matching[_graph->aNode(it)] != INVALID) {
+            return false;
+          }
+          _matching.set(_graph->aNode(it), it);
+          if (_matching[_graph->bNode(it)] != INVALID) {
+            return false;
+          }
+          _matching.set(_graph->bNode(it), it);
+	  _reached.set(_graph->bNode(it), -1);
+        }
+      }
+      _phase = 0;
+      return true;
+    }
+
+  private:
+    
+    bool _find_path(Node anode, int maxlevel,
+		    typename Graph::template BNodeMap<int>& level) {
+      for (IncEdgeIt it(*_graph, anode); it != INVALID; ++it) {
+	Node bnode = _graph->bNode(it); 
+	if (level[bnode] == maxlevel) {
+	  level.set(bnode, -1);
+	  if (maxlevel == 0) {
+	    _matching.set(anode, it);
+	    _rmatching.set(bnode, it);
+	    return true;
+	  } else {
+	    Node nnode = _graph->aNode(_rmatching[bnode]);
+	    if (_find_path(nnode, maxlevel - 1, level)) {
+	      _matching.set(anode, it);
+	      _rmatching.set(bnode, it);
+	      return true;
+	    }
+	  }
+	}
+      }
+      return false;
+    }
+
+  public:
+
+    /// \brief An augmenting phase of the Hopcroft-Karp algorithm
+    ///
+    /// It runs an augmenting phase of the Hopcroft-Karp
+    /// algorithm. This phase finds maximal edge disjoint augmenting
+    /// paths and augments on these paths. The algorithm consists at
+    /// most of \f$ O(\sqrt{n}) \f$ phase and one phase is \f$ O(e)
+    /// \f$ long.
+    bool augment() {
+
+      ++_phase;
+      
+      typename Graph::template BNodeMap<int> _level(*_graph, -1);
+      typename Graph::template ANodeMap<bool> _found(*_graph, false);
+
+      std::vector<Node> queue, aqueue;
+      for (BNodeIt it(*_graph); it != INVALID; ++it) {
+        if (_rmatching[it] == INVALID) {
+          queue.push_back(it);
+          _reached.set(it, _phase);
+	  _level.set(it, 0);
+        }
+      }
+
+      bool success = false;
+
+      int level = 0;
+      while (!success && !queue.empty()) {
+        std::vector<Node> nqueue;
+        for (int i = 0; i < int(queue.size()); ++i) {
+          Node bnode = queue[i];
+          for (IncEdgeIt jt(*_graph, bnode); jt != INVALID; ++jt) {
+            Node anode = _graph->aNode(jt);
+            if (_matching[anode] == INVALID) {
+
+	      if (!_found[anode]) {
+		if (_find_path(anode, level, _level)) {
+		  ++_size;
+		}
+		_found.set(anode, true);
+	      }
+              success = true;
+            } else {           
+              Node nnode = _graph->bNode(_matching[anode]);
+              if (_reached[nnode] != _phase) {
+                _reached.set(nnode, _phase);
+                nqueue.push_back(nnode);
+		_level.set(nnode, level + 1);
+              }
+            }
+          }
+        }
+	++level;
+        queue.swap(nqueue);
+      }
+      
+      return success;
+    }
+  private:
+    
+    void _find_path_bfs(Node anode,
+			typename Graph::template ANodeMap<UEdge>& pred) {
+      while (true) {
+	UEdge uedge = pred[anode];
+	Node bnode = _graph->bNode(uedge);
+
+	UEdge nedge = _rmatching[bnode];
+
+	_matching.set(anode, uedge);
+	_rmatching.set(bnode, uedge);
+
+	if (nedge == INVALID) break;
+	anode = _graph->aNode(nedge);
+      }
+    }
+
+  public:
+
+    /// \brief An augmenting phase with single path augementing
+    ///
+    /// This phase finds only one augmenting paths and augments on
+    /// these paths. The algorithm consists at most of \f$ O(n) \f$
+    /// phase and one phase is \f$ O(e) \f$ long.
+    bool simpleAugment() { 
+      ++_phase;
+      
+      typename Graph::template ANodeMap<UEdge> _pred(*_graph);
+
+      std::vector<Node> queue, aqueue;
+      for (BNodeIt it(*_graph); it != INVALID; ++it) {
+        if (_rmatching[it] == INVALID) {
+          queue.push_back(it);
+          _reached.set(it, _phase);
+        }
+      }
+
+      bool success = false;
+
+      int level = 0;
+      while (!success && !queue.empty()) {
+        std::vector<Node> nqueue;
+        for (int i = 0; i < int(queue.size()); ++i) {
+          Node bnode = queue[i];
+          for (IncEdgeIt jt(*_graph, bnode); jt != INVALID; ++jt) {
+            Node anode = _graph->aNode(jt);
+            if (_matching[anode] == INVALID) {
+	      _pred.set(anode, jt);
+	      _find_path_bfs(anode, _pred);
+	      ++_size;
+	      return true;
+            } else {           
+              Node nnode = _graph->bNode(_matching[anode]);
+              if (_reached[nnode] != _phase) {
+		_pred.set(anode, jt);
+		_reached.set(nnode, _phase);
+                nqueue.push_back(nnode);
+              }
+            }
+          }
+        }
+	++level;
+        queue.swap(nqueue);
+      }
+      
+      return success;
+    }
+
+
+
+    /// \brief Starts the algorithm.
+    ///
+    /// Starts the algorithm. It runs augmenting phases until the optimal
+    /// solution reached.
+    void start() {
+      while (augment()) {}
+    }
+
+    /// \brief Runs the algorithm.
+    ///
+    /// It just initalize the algorithm and then start it.
+    void run() {
+      greedyInit();
+      start();
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the %Matching algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    /// \brief Return true if the given uedge is in the matching.
+    /// 
+    /// It returns true if the given uedge is in the matching.
+    bool matchingEdge(const UEdge& edge) const {
+      return _matching[_graph->aNode(edge)] == edge;
+    }
+
+    /// \brief Returns the matching edge from the node.
+    /// 
+    /// Returns the matching edge from the node. If there is not such
+    /// edge it gives back \c INVALID.
+    /// \note If the parameter node is a B-node then the running time is
+    /// propotional to the degree of the node.
+    UEdge matchingEdge(const Node& node) const {
+      if (_graph->aNode(node)) {
+        return _matching[node];
+      } else {
+        return _rmatching[node];
+      }
+    }
+
+    /// \brief Set true all matching uedge in the map.
+    /// 
+    /// Set true all matching uedge in the map. It does not change the
+    /// value mapped to the other uedges.
+    /// \return The number of the matching edges.
+    template <typename MatchingMap>
+    int quickMatching(MatchingMap& mm) const {
+      for (ANodeIt it(*_graph); it != INVALID; ++it) {
+        if (_matching[it] != INVALID) {
+          mm.set(_matching[it], true);
+        }
+      }
+      return _size;
+    }
+
+    /// \brief Set true all matching uedge in the map and the others to false.
+    /// 
+    /// Set true all matching uedge in the map and the others to false.
+    /// \return The number of the matching edges.
+    template <typename MatchingMap>
+    int matching(MatchingMap& mm) const {
+      for (UEdgeIt it(*_graph); it != INVALID; ++it) {
+        mm.set(it, it == _matching[_graph->aNode(it)]);
+      }
+      return _size;
+    }
+
+    ///Gives back the matching in an ANodeMap.
+
+    ///Gives back the matching in an ANodeMap. The parameter should
+    ///be a write ANodeMap of UEdge values.
+    ///\return The number of the matching edges.
+    template<class MatchingMap>
+    int aMatching(MatchingMap& mm) const {
+      for (ANodeIt it(*_graph); it != INVALID; ++it) {
+        mm.set(it, _matching[it]);
+      }
+      return _size;
+    }
+
+    ///Gives back the matching in a BNodeMap.
+
+    ///Gives back the matching in a BNodeMap. The parameter should
+    ///be a write BNodeMap of UEdge values.
+    ///\return The number of the matching edges.
+    template<class MatchingMap>
+    int bMatching(MatchingMap& mm) const {
+      for (BNodeIt it(*_graph); it != INVALID; ++it) {
+        mm.set(it, _rmatching[it]);
+      }
+      return _size;
+    }
+
+    /// \brief Returns a minimum covering of the nodes.
+    ///
+    /// The minimum covering set problem is the dual solution of the
+    /// maximum bipartite matching. It provides a solution for this
+    /// problem what is proof of the optimality of the matching.
+    /// \return The size of the cover set.
+    template <typename CoverMap>
+    int coverSet(CoverMap& covering) const {
+
+      int size = 0;
+      for (ANodeIt it(*_graph); it != INVALID; ++it) {
+	bool cn = _matching[it] != INVALID && 
+	  _reached[_graph->bNode(_matching[it])] == _phase;
+        covering.set(it, cn);
+        if (cn) ++size;
+      }
+      for (BNodeIt it(*_graph); it != INVALID; ++it) {
+	bool cn = _reached[it] != _phase;
+        covering.set(it, cn);
+        if (cn) ++size;
+      }
+      return size;
+    }
+
+    /// \brief Gives back a barrier on the A-nodes
+    ///    
+    /// The barrier is s subset of the nodes on the same side of the
+    /// graph, which size minus its neighbours is exactly the
+    /// unmatched nodes on the A-side.  
+    /// \retval barrier A WriteMap on the ANodes with bool value.
+    template <typename BarrierMap>
+    void aBarrier(BarrierMap& barrier) const {
+
+      for (ANodeIt it(*_graph); it != INVALID; ++it) {
+        barrier.set(it, _matching[it] == INVALID || 
+		    _reached[_graph->bNode(_matching[it])] != _phase);
+      }
+    }
+
+    /// \brief Gives back a barrier on the B-nodes
+    ///    
+    /// The barrier is s subset of the nodes on the same side of the
+    /// graph, which size minus its neighbours is exactly the
+    /// unmatched nodes on the B-side.  
+    /// \retval barrier A WriteMap on the BNodes with bool value.
+    template <typename BarrierMap>
+    void bBarrier(BarrierMap& barrier) const {
+
+      for (BNodeIt it(*_graph); it != INVALID; ++it) {
+        barrier.set(it, _reached[it] == _phase);
+      }
+    }
+
+    /// \brief Gives back the number of the matching edges.
+    ///
+    /// Gives back the number of the matching edges.
+    int matchingSize() const {
+      return _size;
+    }
+
+    /// @}
+
+  private:
+
+    typename BpUGraph::template ANodeMap<UEdge> _matching;
+    typename BpUGraph::template BNodeMap<UEdge> _rmatching;
+
+    typename BpUGraph::template BNodeMap<int> _reached;
+
+    int _phase;
+    const Graph *_graph;
+
+    int _size;
+  
+  };
+
+  /// \ingroup matching
+  ///
+  /// \brief Maximum cardinality bipartite matching
+  ///
+  /// This function calculates the maximum cardinality matching
+  /// in a bipartite graph. It gives back the matching in an undirected
+  /// edge map.
+  ///
+  /// \param graph The bipartite graph.
+  /// \return The size of the matching.
+  template <typename BpUGraph>
+  int maxBipartiteMatching(const BpUGraph& graph) {
+    MaxBipartiteMatching<BpUGraph> bpmatching(graph);
+    bpmatching.run();
+    return bpmatching.matchingSize();
+  }
+
+  /// \ingroup matching
+  ///
+  /// \brief Maximum cardinality bipartite matching
+  ///
+  /// This function calculates the maximum cardinality matching
+  /// in a bipartite graph. It gives back the matching in an undirected
+  /// edge map.
+  ///
+  /// \param graph The bipartite graph.
+  /// \retval matching The ANodeMap of UEdges which will be set to covered
+  /// matching undirected edge.
+  /// \return The size of the matching.
+  template <typename BpUGraph, typename MatchingMap>
+  int maxBipartiteMatching(const BpUGraph& graph, MatchingMap& matching) {
+    MaxBipartiteMatching<BpUGraph> bpmatching(graph);
+    bpmatching.run();
+    bpmatching.aMatching(matching);
+    return bpmatching.matchingSize();
+  }
+
+  /// \ingroup matching
+  ///
+  /// \brief Maximum cardinality bipartite matching
+  ///
+  /// This function calculates the maximum cardinality matching
+  /// in a bipartite graph. It gives back the matching in an undirected
+  /// edge map.
+  ///
+  /// \param graph The bipartite graph.
+  /// \retval matching The ANodeMap of UEdges which will be set to covered
+  /// matching undirected edge.
+  /// \retval barrier The BNodeMap of bools which will be set to a barrier
+  /// of the BNode-set.
+  /// \return The size of the matching.
+  template <typename BpUGraph, typename MatchingMap, typename BarrierMap>
+  int maxBipartiteMatching(const BpUGraph& graph, 
+			   MatchingMap& matching, BarrierMap& barrier) {
+    MaxBipartiteMatching<BpUGraph> bpmatching(graph);
+    bpmatching.run();
+    bpmatching.aMatching(matching);
+    bpmatching.bBarrier(barrier);
+    return bpmatching.matchingSize();
+  }
+
+  /// \brief Default traits class for weighted bipartite matching algoritms.
+  ///
+  /// Default traits class for weighted bipartite matching algoritms.
+  /// \param _BpUGraph The bipartite undirected graph type.
+  /// \param _WeightMap Type of weight map.
+  template <typename _BpUGraph, typename _WeightMap>
+  struct MaxWeightedBipartiteMatchingDefaultTraits {
+    /// \brief The type of the weight of the undirected edges.
+    typedef typename _WeightMap::Value Value;
+
+    /// The undirected bipartite graph type the algorithm runs on. 
+    typedef _BpUGraph BpUGraph;
+
+    /// The map of the edges weights
+    typedef _WeightMap WeightMap;
+
+    /// \brief The cross reference type used by heap.
+    ///
+    /// The cross reference type used by heap.
+    /// Usually it is \c Graph::ANodeMap<int>.
+    typedef typename BpUGraph::template ANodeMap<int> HeapCrossRef;
+
+    /// \brief Instantiates a HeapCrossRef.
+    ///
+    /// This function instantiates a \ref HeapCrossRef. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// HeapCrossRef.
+    static HeapCrossRef *createHeapCrossRef(const BpUGraph &graph) {
+      return new HeapCrossRef(graph);
+    }
+    
+    /// \brief The heap type used by weighted matching algorithms.
+    ///
+    /// The heap type used by weighted matching algorithms. It should
+    /// minimize the priorities and the heap's key type is the graph's
+    /// anode graph's node.
+    ///
+    /// \sa BinHeap
+    typedef BinHeap<Value, HeapCrossRef> Heap;
+    
+    /// \brief Instantiates a Heap.
+    ///
+    /// This function instantiates a \ref Heap. 
+    /// \param crossref The cross reference of the heap.
+    static Heap *createHeap(HeapCrossRef& crossref) {
+      return new Heap(crossref);
+    }
+
+  };
+
+
+  /// \ingroup matching
+  ///
+  /// \brief Bipartite Max Weighted Matching algorithm
+  ///
+  /// This class implements the bipartite Max Weighted Matching
+  /// algorithm.  It uses the successive shortest path algorithm to
+  /// calculate the maximum weighted matching in the bipartite
+  /// graph. The algorithm can be used also to calculate the maximum
+  /// cardinality maximum weighted matching. The time complexity
+  /// of the algorithm is \f$ O(ne\log(n)) \f$ with the default binary
+  /// heap implementation but this can be improved to 
+  /// \f$ O(n^2\log(n)+ne) \f$ if we use fibonacci heaps.
+  ///
+  /// The algorithm also provides a potential function on the nodes
+  /// which a dual solution of the matching algorithm and it can be
+  /// used to proof the optimality of the given pimal solution.
+#ifdef DOXYGEN
+  template <typename _BpUGraph, typename _WeightMap, typename _Traits>
+#else
+  template <typename _BpUGraph, 
+            typename _WeightMap = typename _BpUGraph::template UEdgeMap<int>,
+            typename _Traits = 
+	    MaxWeightedBipartiteMatchingDefaultTraits<_BpUGraph, _WeightMap> >
+#endif
+  class MaxWeightedBipartiteMatching {
+  public:
+
+    typedef _Traits Traits;
+    typedef typename Traits::BpUGraph BpUGraph;
+    typedef typename Traits::WeightMap WeightMap;
+    typedef typename Traits::Value Value;
+
+  protected:
+
+    typedef typename Traits::HeapCrossRef HeapCrossRef;
+    typedef typename Traits::Heap Heap; 
+
+    
+    typedef typename BpUGraph::Node Node;
+    typedef typename BpUGraph::ANodeIt ANodeIt;
+    typedef typename BpUGraph::BNodeIt BNodeIt;
+    typedef typename BpUGraph::UEdge UEdge;
+    typedef typename BpUGraph::UEdgeIt UEdgeIt;
+    typedef typename BpUGraph::IncEdgeIt IncEdgeIt;
+
+    typedef typename BpUGraph::template ANodeMap<UEdge> ANodeMatchingMap;
+    typedef typename BpUGraph::template BNodeMap<UEdge> BNodeMatchingMap;
+
+    typedef typename BpUGraph::template ANodeMap<Value> ANodePotentialMap;
+    typedef typename BpUGraph::template BNodeMap<Value> BNodePotentialMap;
+
+
+  public:
+
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::MaxWeightedBipartiteMatching::UninitializedParameter";
+      }
+    };
+
+    ///\name Named template parameters
+
+    ///@{
+
+    template <class H, class CR>
+    struct DefHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const BpUGraph &) {
+	throw UninitializedParameter();
+      }
+      static Heap *createHeap(HeapCrossRef &) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting heap 
+    /// and cross reference type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting heap and cross 
+    /// reference type
+    template <class H, class CR = typename BpUGraph::template NodeMap<int> >
+    struct DefHeap
+      : public MaxWeightedBipartiteMatching<BpUGraph, WeightMap, 
+                                            DefHeapTraits<H, CR> > { 
+      typedef MaxWeightedBipartiteMatching<BpUGraph, WeightMap, 
+                                           DefHeapTraits<H, CR> > Create;
+    };
+
+    template <class H, class CR>
+    struct DefStandardHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const BpUGraph &graph) {
+	return new HeapCrossRef(graph);
+      }
+      static Heap *createHeap(HeapCrossRef &crossref) {
+	return new Heap(crossref);
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting heap and 
+    /// cross reference type with automatic allocation
+    ///
+    /// \ref named-templ-param "Named parameter" for setting heap and cross 
+    /// reference type. It can allocate the heap and the cross reference 
+    /// object if the cross reference's constructor waits for the graph as 
+    /// parameter and the heap's constructor waits for the cross reference.
+    template <class H, class CR = typename BpUGraph::template NodeMap<int> >
+    struct DefStandardHeap
+      : public MaxWeightedBipartiteMatching<BpUGraph, WeightMap, 
+                                            DefStandardHeapTraits<H, CR> > { 
+      typedef MaxWeightedBipartiteMatching<BpUGraph, WeightMap, 
+                                           DefStandardHeapTraits<H, CR> > 
+      Create;
+    };
+
+    ///@}
+
+
+    /// \brief Constructor.
+    ///
+    /// Constructor of the algorithm. 
+    MaxWeightedBipartiteMatching(const BpUGraph& _graph, 
+                                 const WeightMap& _weight) 
+      : graph(&_graph), weight(&_weight),
+        anode_matching(_graph), bnode_matching(_graph),
+        anode_potential(_graph), bnode_potential(_graph),
+        _heap_cross_ref(0), local_heap_cross_ref(false),
+        _heap(0), local_heap(0) {}
+
+    /// \brief Destructor.
+    ///
+    /// Destructor of the algorithm.
+    ~MaxWeightedBipartiteMatching() {
+      destroyStructures();
+    }
+
+    /// \brief Sets the heap and the cross reference used by algorithm.
+    ///
+    /// Sets the heap and the cross reference used by algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    MaxWeightedBipartiteMatching& heap(Heap& hp, HeapCrossRef &cr) {
+      if(local_heap_cross_ref) {
+	delete _heap_cross_ref;
+	local_heap_cross_ref = false;
+      }
+      _heap_cross_ref = &cr;
+      if(local_heap) {
+	delete _heap;
+	local_heap = false;
+      }
+      _heap = &hp;
+      return *this;
+    }
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run().
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init() or one alternative for it.
+    /// Finally \ref start() will perform the matching computation or
+    /// with step-by-step execution you can augment the solution.
+
+    /// @{
+
+    /// \brief Initalize the data structures.
+    ///
+    /// It initalizes the data structures and creates an empty matching.
+    void init() {
+      initStructures();
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        anode_matching[it] = INVALID;
+        anode_potential[it] = 0;
+      }
+      for (BNodeIt it(*graph); it != INVALID; ++it) {
+        bnode_matching[it] = INVALID;
+        bnode_potential[it] = 0;
+        for (IncEdgeIt jt(*graph, it); jt != INVALID; ++jt) {
+          if ((*weight)[jt] > bnode_potential[it]) {
+            bnode_potential[it] = (*weight)[jt];
+          }
+        }
+      }
+      matching_value = 0;
+      matching_size = 0;
+    }
+
+
+    /// \brief An augmenting phase of the weighted matching algorithm
+    ///
+    /// It runs an augmenting phase of the weighted matching 
+    /// algorithm. This phase finds the best augmenting path and 
+    /// augments only on this paths. 
+    ///
+    /// The algorithm consists at most 
+    /// of \f$ O(n) \f$ phase and one phase is \f$ O(n\log(n)+e) \f$ 
+    /// long with Fibonacci heap or \f$ O((n+e)\log(n)) \f$ long 
+    /// with binary heap.
+    /// \param decrease If the given parameter true the matching value
+    /// can be decreased in the augmenting phase. If we would like
+    /// to calculate the maximum cardinality maximum weighted matching
+    /// then we should let the algorithm to decrease the matching
+    /// value in order to increase the number of the matching edges.
+    bool augment(bool decrease = false) {
+
+      typename BpUGraph::template BNodeMap<Value> bdist(*graph);
+      typename BpUGraph::template BNodeMap<UEdge> bpred(*graph, INVALID);
+
+      Node bestNode = INVALID;
+      Value bestValue = 0;
+
+      _heap->clear();
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        (*_heap_cross_ref)[it] = Heap::PRE_HEAP;
+      }
+
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        if (anode_matching[it] == INVALID) {
+          _heap->push(it, 0);
+        }
+      }
+
+      Value bdistMax = 0;
+      while (!_heap->empty()) {
+        Node anode = _heap->top();
+        Value avalue = _heap->prio();
+        _heap->pop();
+        for (IncEdgeIt jt(*graph, anode); jt != INVALID; ++jt) {
+          if (jt == anode_matching[anode]) continue;
+          Node bnode = graph->bNode(jt);
+          Value bvalue = avalue  - (*weight)[jt] +
+            anode_potential[anode] + bnode_potential[bnode];
+          if (bvalue > bdistMax) {
+            bdistMax = bvalue;
+          }
+          if (bpred[bnode] == INVALID || bvalue < bdist[bnode]) {
+            bdist[bnode] = bvalue;
+            bpred[bnode] = jt;
+          } else continue;
+          if (bnode_matching[bnode] != INVALID) {
+            Node newanode = graph->aNode(bnode_matching[bnode]);
+            switch (_heap->state(newanode)) {
+            case Heap::PRE_HEAP:
+              _heap->push(newanode, bvalue);
+              break;
+            case Heap::IN_HEAP:
+              if (bvalue < (*_heap)[newanode]) {
+                _heap->decrease(newanode, bvalue);
+              }
+              break;
+            case Heap::POST_HEAP:
+              break;
+            }
+          } else {
+            if (bestNode == INVALID || 
+                bnode_potential[bnode] - bvalue > bestValue) {
+              bestValue = bnode_potential[bnode] - bvalue;
+              bestNode = bnode;
+            }
+          }
+        }
+      }
+
+      if (bestNode == INVALID || (!decrease && bestValue < 0)) {
+        return false;
+      }
+
+      matching_value += bestValue;
+      ++matching_size;
+
+      for (BNodeIt it(*graph); it != INVALID; ++it) {
+        if (bpred[it] != INVALID) {
+          bnode_potential[it] -= bdist[it];
+        } else {
+          bnode_potential[it] -= bdistMax;
+        }
+      }
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        if (anode_matching[it] != INVALID) {
+          Node bnode = graph->bNode(anode_matching[it]);
+          if (bpred[bnode] != INVALID) {
+            anode_potential[it] += bdist[bnode];
+          } else {
+            anode_potential[it] += bdistMax;
+          }
+        }
+      }
+
+      while (bestNode != INVALID) {
+        UEdge uedge = bpred[bestNode];
+        Node anode = graph->aNode(uedge);
+        
+        bnode_matching[bestNode] = uedge;
+        if (anode_matching[anode] != INVALID) {
+          bestNode = graph->bNode(anode_matching[anode]);
+        } else {
+          bestNode = INVALID;
+        }
+        anode_matching[anode] = uedge;
+      }
+
+
+      return true;
+    }
+
+    /// \brief Starts the algorithm.
+    ///
+    /// Starts the algorithm. It runs augmenting phases until the
+    /// optimal solution reached.
+    ///
+    /// \param maxCardinality If the given value is true it will
+    /// calculate the maximum cardinality maximum matching instead of
+    /// the maximum matching.
+    void start(bool maxCardinality = false) {
+      while (augment(maxCardinality)) {}
+    }
+
+    /// \brief Runs the algorithm.
+    ///
+    /// It just initalize the algorithm and then start it.
+    ///
+    /// \param maxCardinality If the given value is true it will
+    /// calculate the maximum cardinality maximum matching instead of
+    /// the maximum matching.
+    void run(bool maxCardinality = false) {
+      init();
+      start(maxCardinality);
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the %Matching algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    /// \brief Gives back the potential in the NodeMap
+    ///
+    /// Gives back the potential in the NodeMap. The matching is optimal
+    /// with the current number of edges if \f$ \pi(a) + \pi(b) - w(ab) = 0 \f$
+    /// for each matching edges and \f$ \pi(a) + \pi(b) - w(ab) \ge 0 \f$
+    /// for each edges. 
+    template <typename PotentialMap>
+    void potential(PotentialMap& pt) const {
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        pt.set(it, anode_potential[it]);
+      }
+      for (BNodeIt it(*graph); it != INVALID; ++it) {
+        pt.set(it, bnode_potential[it]);
+      }
+    }
+
+    /// \brief Set true all matching uedge in the map.
+    /// 
+    /// Set true all matching uedge in the map. It does not change the
+    /// value mapped to the other uedges.
+    /// \return The number of the matching edges.
+    template <typename MatchingMap>
+    int quickMatching(MatchingMap& mm) const {
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        if (anode_matching[it] != INVALID) {
+          mm.set(anode_matching[it], true);
+        }
+      }
+      return matching_size;
+    }
+
+    /// \brief Set true all matching uedge in the map and the others to false.
+    /// 
+    /// Set true all matching uedge in the map and the others to false.
+    /// \return The number of the matching edges.
+    template <typename MatchingMap>
+    int matching(MatchingMap& mm) const {
+      for (UEdgeIt it(*graph); it != INVALID; ++it) {
+        mm.set(it, it == anode_matching[graph->aNode(it)]);
+      }
+      return matching_size;
+    }
+
+    ///Gives back the matching in an ANodeMap.
+
+    ///Gives back the matching in an ANodeMap. The parameter should
+    ///be a write ANodeMap of UEdge values.
+    ///\return The number of the matching edges.
+    template<class MatchingMap>
+    int aMatching(MatchingMap& mm) const {
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        mm.set(it, anode_matching[it]);
+      }
+      return matching_size;
+    }
+
+    ///Gives back the matching in a BNodeMap.
+
+    ///Gives back the matching in a BNodeMap. The parameter should
+    ///be a write BNodeMap of UEdge values.
+    ///\return The number of the matching edges.
+    template<class MatchingMap>
+    int bMatching(MatchingMap& mm) const {
+      for (BNodeIt it(*graph); it != INVALID; ++it) {
+        mm.set(it, bnode_matching[it]);
+      }
+      return matching_size;
+    }
+
+
+    /// \brief Return true if the given uedge is in the matching.
+    /// 
+    /// It returns true if the given uedge is in the matching.
+    bool matchingEdge(const UEdge& edge) const {
+      return anode_matching[graph->aNode(edge)] == edge;
+    }
+
+    /// \brief Returns the matching edge from the node.
+    /// 
+    /// Returns the matching edge from the node. If there is not such
+    /// edge it gives back \c INVALID.
+    UEdge matchingEdge(const Node& node) const {
+      if (graph->aNode(node)) {
+        return anode_matching[node];
+      } else {
+        return bnode_matching[node];
+      }
+    }
+
+    /// \brief Gives back the sum of weights of the matching edges.
+    ///
+    /// Gives back the sum of weights of the matching edges.
+    Value matchingValue() const {
+      return matching_value;
+    }
+
+    /// \brief Gives back the number of the matching edges.
+    ///
+    /// Gives back the number of the matching edges.
+    int matchingSize() const {
+      return matching_size;
+    }
+
+    /// @}
+
+  private:
+
+    void initStructures() {
+      if (!_heap_cross_ref) {
+	local_heap_cross_ref = true;
+	_heap_cross_ref = Traits::createHeapCrossRef(*graph);
+      }
+      if (!_heap) {
+	local_heap = true;
+	_heap = Traits::createHeap(*_heap_cross_ref);
+      }
+    }
+
+    void destroyStructures() {
+      if (local_heap_cross_ref) delete _heap_cross_ref;
+      if (local_heap) delete _heap;
+    }
+
+
+  private:
+    
+    const BpUGraph *graph;
+    const WeightMap* weight;
+
+    ANodeMatchingMap anode_matching;
+    BNodeMatchingMap bnode_matching;
+
+    ANodePotentialMap anode_potential;
+    BNodePotentialMap bnode_potential;
+
+    Value matching_value;
+    int matching_size;
+
+    HeapCrossRef *_heap_cross_ref;
+    bool local_heap_cross_ref;
+
+    Heap *_heap;
+    bool local_heap;
+  
+  };
+
+  /// \ingroup matching
+  ///
+  /// \brief Maximum weighted bipartite matching
+  ///
+  /// This function calculates the maximum weighted matching
+  /// in a bipartite graph. It gives back the matching in an undirected
+  /// edge map.
+  ///
+  /// \param graph The bipartite graph.
+  /// \param weight The undirected edge map which contains the weights.
+  /// \retval matching The undirected edge map which will be set to 
+  /// the matching.
+  /// \return The value of the matching.
+  template <typename BpUGraph, typename WeightMap, typename MatchingMap>
+  typename WeightMap::Value 
+  maxWeightedBipartiteMatching(const BpUGraph& graph, const WeightMap& weight,
+                               MatchingMap& matching) {
+    MaxWeightedBipartiteMatching<BpUGraph, WeightMap> 
+      bpmatching(graph, weight);
+    bpmatching.run();
+    bpmatching.matching(matching);
+    return bpmatching.matchingValue();
+  }
+
+  /// \ingroup matching
+  ///
+  /// \brief Maximum weighted maximum cardinality bipartite matching
+  ///
+  /// This function calculates the maximum weighted of the maximum cardinality
+  /// matchings of a bipartite graph. It gives back the matching in an 
+  /// undirected edge map.
+  ///
+  /// \param graph The bipartite graph.
+  /// \param weight The undirected edge map which contains the weights.
+  /// \retval matching The undirected edge map which will be set to 
+  /// the matching.
+  /// \return The value of the matching.
+  template <typename BpUGraph, typename WeightMap, typename MatchingMap>
+  typename WeightMap::Value 
+  maxWeightedMaxBipartiteMatching(const BpUGraph& graph, 
+                                  const WeightMap& weight,
+                                  MatchingMap& matching) {
+    MaxWeightedBipartiteMatching<BpUGraph, WeightMap> 
+      bpmatching(graph, weight);
+    bpmatching.run(true);
+    bpmatching.matching(matching);
+    return bpmatching.matchingValue();
+  }
+
+  /// \brief Default traits class for minimum cost bipartite matching
+  /// algoritms.
+  ///
+  /// Default traits class for minimum cost bipartite matching
+  /// algoritms.  
+  ///
+  /// \param _BpUGraph The bipartite undirected graph
+  /// type.  
+  ///
+  /// \param _CostMap Type of cost map.
+  template <typename _BpUGraph, typename _CostMap>
+  struct MinCostMaxBipartiteMatchingDefaultTraits {
+    /// \brief The type of the cost of the undirected edges.
+    typedef typename _CostMap::Value Value;
+
+    /// The undirected bipartite graph type the algorithm runs on. 
+    typedef _BpUGraph BpUGraph;
+
+    /// The map of the edges costs
+    typedef _CostMap CostMap;
+
+    /// \brief The cross reference type used by heap.
+    ///
+    /// The cross reference type used by heap.
+    /// Usually it is \c Graph::NodeMap<int>.
+    typedef typename BpUGraph::template NodeMap<int> HeapCrossRef;
+
+    /// \brief Instantiates a HeapCrossRef.
+    ///
+    /// This function instantiates a \ref HeapCrossRef. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// HeapCrossRef.
+    static HeapCrossRef *createHeapCrossRef(const BpUGraph &graph) {
+      return new HeapCrossRef(graph);
+    }
+    
+    /// \brief The heap type used by costed matching algorithms.
+    ///
+    /// The heap type used by costed matching algorithms. It should
+    /// minimize the priorities and the heap's key type is the graph's
+    /// anode graph's node.
+    ///
+    /// \sa BinHeap
+    typedef BinHeap<Value, HeapCrossRef> Heap;
+    
+    /// \brief Instantiates a Heap.
+    ///
+    /// This function instantiates a \ref Heap. 
+    /// \param crossref The cross reference of the heap.
+    static Heap *createHeap(HeapCrossRef& crossref) {
+      return new Heap(crossref);
+    }
+
+  };
+
+
+  /// \ingroup matching
+  ///
+  /// \brief Bipartite Min Cost Matching algorithm
+  ///
+  /// This class implements the bipartite Min Cost Matching algorithm.
+  /// It uses the successive shortest path algorithm to calculate the
+  /// minimum cost maximum matching in the bipartite graph. The time
+  /// complexity of the algorithm is \f$ O(ne\log(n)) \f$ with the
+  /// default binary heap implementation but this can be improved to
+  /// \f$ O(n^2\log(n)+ne) \f$ if we use fibonacci heaps.
+  ///
+  /// The algorithm also provides a potential function on the nodes
+  /// which a dual solution of the matching algorithm and it can be
+  /// used to proof the optimality of the given pimal solution.
+#ifdef DOXYGEN
+  template <typename _BpUGraph, typename _CostMap, typename _Traits>
+#else
+  template <typename _BpUGraph, 
+            typename _CostMap = typename _BpUGraph::template UEdgeMap<int>,
+            typename _Traits = 
+	    MinCostMaxBipartiteMatchingDefaultTraits<_BpUGraph, _CostMap> >
+#endif
+  class MinCostMaxBipartiteMatching {
+  public:
+
+    typedef _Traits Traits;
+    typedef typename Traits::BpUGraph BpUGraph;
+    typedef typename Traits::CostMap CostMap;
+    typedef typename Traits::Value Value;
+
+  protected:
+
+    typedef typename Traits::HeapCrossRef HeapCrossRef;
+    typedef typename Traits::Heap Heap; 
+
+    
+    typedef typename BpUGraph::Node Node;
+    typedef typename BpUGraph::ANodeIt ANodeIt;
+    typedef typename BpUGraph::BNodeIt BNodeIt;
+    typedef typename BpUGraph::UEdge UEdge;
+    typedef typename BpUGraph::UEdgeIt UEdgeIt;
+    typedef typename BpUGraph::IncEdgeIt IncEdgeIt;
+
+    typedef typename BpUGraph::template ANodeMap<UEdge> ANodeMatchingMap;
+    typedef typename BpUGraph::template BNodeMap<UEdge> BNodeMatchingMap;
+
+    typedef typename BpUGraph::template ANodeMap<Value> ANodePotentialMap;
+    typedef typename BpUGraph::template BNodeMap<Value> BNodePotentialMap;
+
+
+  public:
+
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::MinCostMaxBipartiteMatching::UninitializedParameter";
+      }
+    };
+
+    ///\name Named template parameters
+
+    ///@{
+
+    template <class H, class CR>
+    struct DefHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const BpUGraph &) {
+	throw UninitializedParameter();
+      }
+      static Heap *createHeap(HeapCrossRef &) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting heap 
+    /// and cross reference type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting heap and cross 
+    /// reference type
+    template <class H, class CR = typename BpUGraph::template NodeMap<int> >
+    struct DefHeap
+      : public MinCostMaxBipartiteMatching<BpUGraph, CostMap, 
+                                            DefHeapTraits<H, CR> > { 
+      typedef MinCostMaxBipartiteMatching<BpUGraph, CostMap, 
+                                           DefHeapTraits<H, CR> > Create;
+    };
+
+    template <class H, class CR>
+    struct DefStandardHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const BpUGraph &graph) {
+	return new HeapCrossRef(graph);
+      }
+      static Heap *createHeap(HeapCrossRef &crossref) {
+	return new Heap(crossref);
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting heap and 
+    /// cross reference type with automatic allocation
+    ///
+    /// \ref named-templ-param "Named parameter" for setting heap and cross 
+    /// reference type. It can allocate the heap and the cross reference 
+    /// object if the cross reference's constructor waits for the graph as 
+    /// parameter and the heap's constructor waits for the cross reference.
+    template <class H, class CR = typename BpUGraph::template NodeMap<int> >
+    struct DefStandardHeap
+      : public MinCostMaxBipartiteMatching<BpUGraph, CostMap, 
+                                            DefStandardHeapTraits<H, CR> > { 
+      typedef MinCostMaxBipartiteMatching<BpUGraph, CostMap, 
+                                           DefStandardHeapTraits<H, CR> > 
+      Create;
+    };
+
+    ///@}
+
+
+    /// \brief Constructor.
+    ///
+    /// Constructor of the algorithm. 
+    MinCostMaxBipartiteMatching(const BpUGraph& _graph, 
+                                 const CostMap& _cost) 
+      : graph(&_graph), cost(&_cost),
+        anode_matching(_graph), bnode_matching(_graph),
+        anode_potential(_graph), bnode_potential(_graph),
+        _heap_cross_ref(0), local_heap_cross_ref(false),
+        _heap(0), local_heap(0) {}
+
+    /// \brief Destructor.
+    ///
+    /// Destructor of the algorithm.
+    ~MinCostMaxBipartiteMatching() {
+      destroyStructures();
+    }
+
+    /// \brief Sets the heap and the cross reference used by algorithm.
+    ///
+    /// Sets the heap and the cross reference used by algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    MinCostMaxBipartiteMatching& heap(Heap& hp, HeapCrossRef &cr) {
+      if(local_heap_cross_ref) {
+	delete _heap_cross_ref;
+	local_heap_cross_ref = false;
+      }
+      _heap_cross_ref = &cr;
+      if(local_heap) {
+	delete _heap;
+	local_heap = false;
+      }
+      _heap = &hp;
+      return *this;
+    }
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run().
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init() or one alternative for it.
+    /// Finally \ref start() will perform the matching computation or
+    /// with step-by-step execution you can augment the solution.
+
+    /// @{
+
+    /// \brief Initalize the data structures.
+    ///
+    /// It initalizes the data structures and creates an empty matching.
+    void init() {
+      initStructures();
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        anode_matching[it] = INVALID;
+        anode_potential[it] = 0;
+      }
+      for (BNodeIt it(*graph); it != INVALID; ++it) {
+        bnode_matching[it] = INVALID;
+        bnode_potential[it] = 0;
+      }
+      matching_cost = 0;
+      matching_size = 0;
+    }
+
+
+    /// \brief An augmenting phase of the costed matching algorithm
+    ///
+    /// It runs an augmenting phase of the matching algorithm. The
+    /// phase finds the best augmenting path and augments only on this
+    /// paths.
+    ///
+    /// The algorithm consists at most 
+    /// of \f$ O(n) \f$ phase and one phase is \f$ O(n\log(n)+e) \f$ 
+    /// long with Fibonacci heap or \f$ O((n+e)\log(n)) \f$ long 
+    /// with binary heap.
+    bool augment() {
+
+      typename BpUGraph::template BNodeMap<Value> bdist(*graph);
+      typename BpUGraph::template BNodeMap<UEdge> bpred(*graph, INVALID);
+
+      Node bestNode = INVALID;
+      Value bestValue = 0;
+
+      _heap->clear();
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        (*_heap_cross_ref)[it] = Heap::PRE_HEAP;
+      }
+
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        if (anode_matching[it] == INVALID) {
+          _heap->push(it, 0);
+        }
+      }
+      Value bdistMax = 0;
+
+      while (!_heap->empty()) {
+        Node anode = _heap->top();
+        Value avalue = _heap->prio();
+        _heap->pop();
+        for (IncEdgeIt jt(*graph, anode); jt != INVALID; ++jt) {
+          if (jt == anode_matching[anode]) continue;
+          Node bnode = graph->bNode(jt);
+          Value bvalue = avalue + (*cost)[jt] + 
+            anode_potential[anode] - bnode_potential[bnode];
+          if (bvalue > bdistMax) {
+            bdistMax = bvalue;
+          }
+          if (bpred[bnode] == INVALID || bvalue < bdist[bnode]) {
+            bdist[bnode] = bvalue;
+            bpred[bnode] = jt;
+          } else continue;
+          if (bnode_matching[bnode] != INVALID) {
+            Node newanode = graph->aNode(bnode_matching[bnode]);
+            switch (_heap->state(newanode)) {
+            case Heap::PRE_HEAP:
+              _heap->push(newanode, bvalue);
+              break;
+            case Heap::IN_HEAP:
+              if (bvalue < (*_heap)[newanode]) {
+                _heap->decrease(newanode, bvalue);
+              }
+              break;
+            case Heap::POST_HEAP:
+              break;
+            }
+          } else {
+            if (bestNode == INVALID || 
+                bvalue + bnode_potential[bnode] < bestValue) {
+              bestValue = bvalue + bnode_potential[bnode];
+              bestNode = bnode;
+            }
+          }
+        }
+      }
+
+      if (bestNode == INVALID) {
+        return false;
+      }
+
+      matching_cost += bestValue;
+      ++matching_size;
+
+      for (BNodeIt it(*graph); it != INVALID; ++it) {
+        if (bpred[it] != INVALID) {
+          bnode_potential[it] += bdist[it];
+        } else {
+          bnode_potential[it] += bdistMax;
+        }
+      }
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        if (anode_matching[it] != INVALID) {
+          Node bnode = graph->bNode(anode_matching[it]);
+          if (bpred[bnode] != INVALID) {
+            anode_potential[it] += bdist[bnode];
+          } else {
+            anode_potential[it] += bdistMax;
+          }
+        }
+      }
+
+      while (bestNode != INVALID) {
+        UEdge uedge = bpred[bestNode];
+        Node anode = graph->aNode(uedge);
+        
+        bnode_matching[bestNode] = uedge;
+        if (anode_matching[anode] != INVALID) {
+          bestNode = graph->bNode(anode_matching[anode]);
+        } else {
+          bestNode = INVALID;
+        }
+        anode_matching[anode] = uedge;
+      }
+
+
+      return true;
+    }
+
+    /// \brief Starts the algorithm.
+    ///
+    /// Starts the algorithm. It runs augmenting phases until the
+    /// optimal solution reached.
+    void start() {
+      while (augment()) {}
+    }
+
+    /// \brief Runs the algorithm.
+    ///
+    /// It just initalize the algorithm and then start it.
+    void run() {
+      init();
+      start();
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the %Matching algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    /// \brief Gives back the potential in the NodeMap
+    ///
+    /// Gives back the potential in the NodeMap. The matching is optimal
+    /// with the current number of edges if \f$ \pi(a) + \pi(b) - w(ab) = 0 \f$
+    /// for each matching edges and \f$ \pi(a) + \pi(b) - w(ab) \ge 0 \f$
+    /// for each edges. 
+    template <typename PotentialMap>
+    void potential(PotentialMap& pt) const {
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        pt.set(it, anode_potential[it]);
+      }
+      for (BNodeIt it(*graph); it != INVALID; ++it) {
+        pt.set(it, bnode_potential[it]);
+      }
+    }
+
+    /// \brief Set true all matching uedge in the map.
+    /// 
+    /// Set true all matching uedge in the map. It does not change the
+    /// value mapped to the other uedges.
+    /// \return The number of the matching edges.
+    template <typename MatchingMap>
+    int quickMatching(MatchingMap& mm) const {
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        if (anode_matching[it] != INVALID) {
+          mm.set(anode_matching[it], true);
+        }
+      }
+      return matching_size;
+    }
+
+    /// \brief Set true all matching uedge in the map and the others to false.
+    /// 
+    /// Set true all matching uedge in the map and the others to false.
+    /// \return The number of the matching edges.
+    template <typename MatchingMap>
+    int matching(MatchingMap& mm) const {
+      for (UEdgeIt it(*graph); it != INVALID; ++it) {
+        mm.set(it, it == anode_matching[graph->aNode(it)]);
+      }
+      return matching_size;
+    }
+
+    /// \brief Gives back the matching in an ANodeMap.
+    ///
+    /// Gives back the matching in an ANodeMap. The parameter should
+    /// be a write ANodeMap of UEdge values.
+    /// \return The number of the matching edges.
+    template<class MatchingMap>
+    int aMatching(MatchingMap& mm) const {
+      for (ANodeIt it(*graph); it != INVALID; ++it) {
+        mm.set(it, anode_matching[it]);
+      }
+      return matching_size;
+    }
+
+    /// \brief Gives back the matching in a BNodeMap.
+    ///
+    /// Gives back the matching in a BNodeMap. The parameter should
+    /// be a write BNodeMap of UEdge values.
+    /// \return The number of the matching edges.
+    template<class MatchingMap>
+    int bMatching(MatchingMap& mm) const {
+      for (BNodeIt it(*graph); it != INVALID; ++it) {
+        mm.set(it, bnode_matching[it]);
+      }
+      return matching_size;
+    }
+
+    /// \brief Return true if the given uedge is in the matching.
+    /// 
+    /// It returns true if the given uedge is in the matching.
+    bool matchingEdge(const UEdge& edge) const {
+      return anode_matching[graph->aNode(edge)] == edge;
+    }
+
+    /// \brief Returns the matching edge from the node.
+    /// 
+    /// Returns the matching edge from the node. If there is not such
+    /// edge it gives back \c INVALID.
+    UEdge matchingEdge(const Node& node) const {
+      if (graph->aNode(node)) {
+        return anode_matching[node];
+      } else {
+        return bnode_matching[node];
+      }
+    }
+
+    /// \brief Gives back the sum of costs of the matching edges.
+    ///
+    /// Gives back the sum of costs of the matching edges.
+    Value matchingCost() const {
+      return matching_cost;
+    }
+
+    /// \brief Gives back the number of the matching edges.
+    ///
+    /// Gives back the number of the matching edges.
+    int matchingSize() const {
+      return matching_size;
+    }
+
+    /// @}
+
+  private:
+
+    void initStructures() {
+      if (!_heap_cross_ref) {
+	local_heap_cross_ref = true;
+	_heap_cross_ref = Traits::createHeapCrossRef(*graph);
+      }
+      if (!_heap) {
+	local_heap = true;
+	_heap = Traits::createHeap(*_heap_cross_ref);
+      }
+    }
+
+    void destroyStructures() {
+      if (local_heap_cross_ref) delete _heap_cross_ref;
+      if (local_heap) delete _heap;
+    }
+
+
+  private:
+    
+    const BpUGraph *graph;
+    const CostMap* cost;
+
+    ANodeMatchingMap anode_matching;
+    BNodeMatchingMap bnode_matching;
+
+    ANodePotentialMap anode_potential;
+    BNodePotentialMap bnode_potential;
+
+    Value matching_cost;
+    int matching_size;
+
+    HeapCrossRef *_heap_cross_ref;
+    bool local_heap_cross_ref;
+
+    Heap *_heap;
+    bool local_heap;
+  
+  };
+
+  /// \ingroup matching
+  ///
+  /// \brief Minimum cost maximum cardinality bipartite matching
+  ///
+  /// This function calculates the maximum cardinality matching with
+  /// minimum cost of a bipartite graph. It gives back the matching in
+  /// an undirected edge map.
+  ///
+  /// \param graph The bipartite graph.
+  /// \param cost The undirected edge map which contains the costs.
+  /// \retval matching The undirected edge map which will be set to 
+  /// the matching.
+  /// \return The cost of the matching.
+  template <typename BpUGraph, typename CostMap, typename MatchingMap>
+  typename CostMap::Value 
+  minCostMaxBipartiteMatching(const BpUGraph& graph, 
+                              const CostMap& cost,
+                              MatchingMap& matching) {
+    MinCostMaxBipartiteMatching<BpUGraph, CostMap> 
+      bpmatching(graph, cost);
+    bpmatching.run();
+    bpmatching.matching(matching);
+    return bpmatching.matchingCost();
+  }
+
+}
+
+#endif
Index: lemon/bits/alteration_notifier.h
===================================================================
--- lemon/bits/alteration_notifier.h	(revision 2553)
+++ lemon/bits/alteration_notifier.h	(revision 2553)
@@ -0,0 +1,485 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_ALTERATION_NOTIFIER_H
+#define LEMON_BITS_ALTERATION_NOTIFIER_H
+
+#include <vector>
+#include <list>
+
+#include <lemon/bits/utility.h>
+
+///\ingroup graphbits
+///\file
+///\brief Observer notifier for graph alteration observers.
+
+namespace lemon {
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Notifier class to notify observes about alterations in 
+  /// a container.
+  ///
+  /// The simple graph's can be refered as two containers, one node container
+  /// and one edge container. But they are not standard containers they
+  /// does not store values directly they are just key continars for more
+  /// value containers which are the node and edge maps.
+  ///
+  /// The graph's node and edge sets can be changed as we add or erase
+  /// nodes and edges in the graph. Lemon would like to handle easily
+  /// that the node and edge maps should contain values for all nodes or
+  /// edges. If we want to check on every indicing if the map contains
+  /// the current indicing key that cause a drawback in the performance
+  /// in the library. We use another solution we notify all maps about
+  /// an alteration in the graph, which cause only drawback on the
+  /// alteration of the graph.
+  ///
+  /// This class provides an interface to the container. The \e first() and \e 
+  /// next() member functions make possible to iterate on the keys of the
+  /// container. The \e id() function returns an integer id for each key.
+  /// The \e maxId() function gives back an upper bound of the ids.
+  ///
+  /// For the proper functonality of this class, we should notify it
+  /// about each alteration in the container. The alterations have four type
+  /// as \e add(), \e erase(), \e build() and \e clear(). The \e add() and
+  /// \e erase() signals that only one or few items added or erased to or
+  /// from the graph. If all items are erased from the graph or from an empty
+  /// graph a new graph is builded then it can be signaled with the
+  /// clear() and build() members. Important rule that if we erase items 
+  /// from graph we should first signal the alteration and after that erase
+  /// them from the container, on the other way on item addition we should
+  /// first extend the container and just after that signal the alteration.
+  ///
+  /// The alteration can be observed with a class inherited from the
+  /// \e ObserverBase nested class. The signals can be handled with
+  /// overriding the virtual functions defined in the base class.  The
+  /// observer base can be attached to the notifier with the 
+  /// \e attach() member and can be detached with detach() function. The
+  /// alteration handlers should not call any function which signals
+  /// an other alteration in the same notifier and should not
+  /// detach any observer from the notifier.
+  ///
+  /// Alteration observers try to be exception safe. If an \e add() or
+  /// a \e clear() function throws an exception then the remaining
+  /// observeres will not be notified and the fulfilled additions will
+  /// be rolled back by calling the \e erase() or \e clear()
+  /// functions. Thence the \e erase() and \e clear() should not throw
+  /// exception. Actullay, it can be throw only 
+  /// \ref AlterationObserver::ImmediateDetach ImmediateDetach
+  /// exception which detach the observer from the notifier.
+  ///
+  /// There are some place when the alteration observing is not completly
+  /// reliable. If we want to carry out the node degree in the graph
+  /// as in the \ref InDegMap and we use the reverseEdge that cause 
+  /// unreliable functionality. Because the alteration observing signals
+  /// only erasing and adding but not the reversing it will stores bad
+  /// degrees. The sub graph adaptors cannot signal the alterations because
+  /// just a setting in the filter map can modify the graph and this cannot
+  /// be watched in any way.
+  ///
+  /// \param _Container The container which is observed.
+  /// \param _Item The item type which is obserbved.
+  ///
+  /// \author Balazs Dezso
+
+  template <typename _Container, typename _Item>
+  class AlterationNotifier {
+  public:
+
+    typedef True Notifier;
+
+    typedef _Container Container;
+    typedef _Item Item;
+
+    /// \brief Exception which can be called from \e clear() and 
+    /// \e erase().
+    ///
+    /// From the \e clear() and \e erase() function only this
+    /// exception is allowed to throw. The exception immediatly
+    /// detaches the current observer from the notifier. Because the
+    /// \e clear() and \e erase() should not throw other exceptions
+    /// it can be used to invalidate the observer.
+    struct ImmediateDetach {};
+
+    /// \brief ObserverBase is the base class for the observers.
+    ///
+    /// ObserverBase is the abstract base class for the observers.
+    /// It will be notified about an item was inserted into or
+    /// erased from the graph.
+    ///
+    /// The observer interface contains some pure virtual functions
+    /// to override. The add() and erase() functions are
+    /// to notify the oberver when one item is added or
+    /// erased.
+    ///
+    /// The build() and clear() members are to notify the observer
+    /// about the container is built from an empty container or
+    /// is cleared to an empty container. 
+    /// 
+    /// \author Balazs Dezso
+
+    class ObserverBase {
+    protected:
+      typedef AlterationNotifier Notifier;
+
+      friend class AlterationNotifier;
+
+      /// \brief Default constructor.
+      ///
+      /// Default constructor for ObserverBase.
+      /// 
+      ObserverBase() : _notifier(0) {}
+
+      /// \brief Constructor which attach the observer into notifier.
+      ///
+      /// Constructor which attach the observer into notifier.
+      ObserverBase(AlterationNotifier& nf) {
+        attach(nf);
+      }
+
+      /// \brief Constructor which attach the obserever to the same notifier.
+      ///
+      /// Constructor which attach the obserever to the same notifier as
+      /// the other observer is attached to. 
+      ObserverBase(const ObserverBase& copy) {
+	if (copy.attached()) {
+          attach(*copy.notifier());
+	}
+      }
+	
+      /// \brief Destructor
+      virtual ~ObserverBase() {
+        if (attached()) {
+          detach();
+        }
+      }
+
+      /// \brief Attaches the observer into an AlterationNotifier.
+      ///
+      /// This member attaches the observer into an AlterationNotifier.
+      ///
+      void attach(AlterationNotifier& nf) {
+	nf.attach(*this);
+      }
+      
+      /// \brief Detaches the observer into an AlterationNotifier.
+      ///
+      /// This member detaches the observer from an AlterationNotifier.
+      ///
+      void detach() {
+        _notifier->detach(*this);
+      }
+      
+      /// \brief Gives back a pointer to the notifier which the map 
+      /// attached into.
+      ///
+      /// This function gives back a pointer to the notifier which the map
+      /// attached into.
+      ///
+      Notifier* notifier() const { return const_cast<Notifier*>(_notifier); }
+      
+      /// Gives back true when the observer is attached into a notifier.
+      bool attached() const { return _notifier != 0; }
+
+    private:
+
+      ObserverBase& operator=(const ObserverBase& copy);
+
+    protected:
+      
+      Notifier* _notifier;
+      typename std::list<ObserverBase*>::iterator _index;
+
+      /// \brief The member function to notificate the observer about an
+      /// item is added to the container.
+      ///
+      /// The add() member function notificates the observer about an item
+      /// is added to the container. It have to be overrided in the
+      /// subclasses.
+      virtual void add(const Item&) = 0;
+
+      /// \brief The member function to notificate the observer about 
+      /// more item is added to the container.
+      ///
+      /// The add() member function notificates the observer about more item
+      /// is added to the container. It have to be overrided in the
+      /// subclasses.
+      virtual void add(const std::vector<Item>& items) = 0;
+
+      /// \brief The member function to notificate the observer about an
+      /// item is erased from the container.
+      ///
+      /// The erase() member function notificates the observer about an
+      /// item is erased from the container. It have to be overrided in
+      /// the subclasses.	
+      virtual void erase(const Item&) = 0;
+
+      /// \brief The member function to notificate the observer about 
+      /// more item is erased from the container.
+      ///
+      /// The erase() member function notificates the observer about more item
+      /// is erased from the container. It have to be overrided in the
+      /// subclasses.
+      virtual void erase(const std::vector<Item>& items) = 0;
+
+      /// \brief The member function to notificate the observer about the
+      /// container is built.
+      ///
+      /// The build() member function notificates the observer about the
+      /// container is built from an empty container. It have to be
+      /// overrided in the subclasses.
+
+      virtual void build() = 0;
+
+      /// \brief The member function to notificate the observer about all
+      /// items are erased from the container.
+      ///
+      /// The clear() member function notificates the observer about all
+      /// items are erased from the container. It have to be overrided in
+      /// the subclasses.      
+      virtual void clear() = 0;
+
+    };
+	
+  protected:
+
+    const Container* container;
+
+    typedef std::list<ObserverBase*> Observers; 
+    Observers _observers;
+
+		
+  public:
+
+    /// \brief Default constructor.
+    ///
+    /// The default constructor of the AlterationNotifier. 
+    /// It creates an empty notifier.
+    AlterationNotifier() 
+      : container(0) {}
+
+    /// \brief Constructor.
+    ///
+    /// Constructor with the observed container parameter.
+    AlterationNotifier(const Container& _container) 
+      : container(&_container) {}
+
+    /// \brief Copy Constructor of the AlterationNotifier. 
+    ///
+    /// Copy constructor of the AlterationNotifier. 
+    /// It creates only an empty notifier because the copiable
+    /// notifier's observers have to be registered still into that notifier.
+    AlterationNotifier(const AlterationNotifier& _notifier) 
+      : container(_notifier.container) {}
+
+    /// \brief Destructor.
+    ///		
+    /// Destructor of the AlterationNotifier.
+    ///
+    ~AlterationNotifier() {
+      typename Observers::iterator it;
+      for (it = _observers.begin(); it != _observers.end(); ++it) {
+	(*it)->_notifier = 0;
+      }
+    }
+
+    /// \brief Sets the container.
+    ///
+    /// Sets the container.
+    void setContainer(const Container& _container) {
+      container = &_container;
+    }
+
+  protected:
+
+    AlterationNotifier& operator=(const AlterationNotifier&);
+
+  public:
+
+
+
+    /// \brief First item in the container.
+    ///
+    /// Returns the first item in the container. It is
+    /// for start the iteration on the container.
+    void first(Item& item) const {
+      container->first(item);
+    }
+
+    /// \brief Next item in the container.
+    ///
+    /// Returns the next item in the container. It is
+    /// for iterate on the container.
+    void next(Item& item) const {
+      container->next(item);
+    }
+
+    /// \brief Returns the id of the item.
+    ///
+    /// Returns the id of the item provided by the container.
+    int id(const Item& item) const {
+      return container->id(item);
+    }
+
+    /// \brief Returns the maximum id of the container.
+    ///
+    /// Returns the maximum id of the container.
+    int maxId() const {
+      return container->maxId(Item());
+    }
+		
+  protected:
+
+    void attach(ObserverBase& observer) {
+      observer._index = _observers.insert(_observers.begin(), &observer);
+      observer._notifier = this;
+    } 
+
+    void detach(ObserverBase& observer) {
+      _observers.erase(observer._index);
+      observer._index = _observers.end();
+      observer._notifier = 0;
+    }
+
+  public:
+	
+    /// \brief Notifies all the registed observers about an item added to 
+    /// the container.
+    ///
+    /// It notifies all the registed observers about an item added to 
+    /// the container.
+    /// 
+    void add(const Item& item) {
+      typename Observers::reverse_iterator it;
+      try {
+        for (it = _observers.rbegin(); it != _observers.rend(); ++it) {
+          (*it)->add(item);
+        }
+      } catch (...) {
+        typename Observers::iterator jt;
+        for (jt = it.base(); jt != _observers.end(); ++jt) {
+          (*jt)->erase(item);
+        }
+        throw;
+      }
+    }	
+
+    /// \brief Notifies all the registed observers about more item added to 
+    /// the container.
+    ///
+    /// It notifies all the registed observers about more item added to 
+    /// the container.
+    /// 
+    void add(const std::vector<Item>& items) {
+      typename Observers::reverse_iterator it;
+      try {
+        for (it = _observers.rbegin(); it != _observers.rend(); ++it) {
+          (*it)->add(items);
+        }
+      } catch (...) {
+        typename Observers::iterator jt;
+        for (jt = it.base(); jt != _observers.end(); ++jt) {
+          (*jt)->erase(items);
+        }
+        throw;
+      }
+    }	
+
+    /// \brief Notifies all the registed observers about an item erased from 
+    /// the container.
+    ///	
+    /// It notifies all the registed observers about an item erased from 
+    /// the container.
+    /// 
+    void erase(const Item& item) throw() {
+      typename Observers::iterator it = _observers.begin();
+      while (it != _observers.end()) {
+        try {
+          (*it)->erase(item);
+          ++it;
+        } catch (const ImmediateDetach&) {
+          it = _observers.erase(it);
+          (*it)->_index = _observers.end();
+          (*it)->_notifier = 0;
+        }
+      }
+    }
+
+    /// \brief Notifies all the registed observers about more item erased  
+    /// from the container.
+    ///	
+    /// It notifies all the registed observers about more item erased from 
+    /// the container.
+    /// 
+    void erase(const std::vector<Item>& items) {
+      typename Observers::iterator it = _observers.begin();
+      while (it != _observers.end()) {
+        try {
+          (*it)->erase(items);
+          ++it;
+        } catch (const ImmediateDetach&) {
+          it = _observers.erase(it);
+          (*it)->_index = _observers.end();
+          (*it)->_notifier = 0;
+        }
+      }
+    }
+
+    /// \brief Notifies all the registed observers about the container is 
+    /// built.
+    ///		
+    /// Notifies all the registed observers about the container is built
+    /// from an empty container.
+    void build() {
+      typename Observers::reverse_iterator it;
+      try {
+        for (it = _observers.rbegin(); it != _observers.rend(); ++it) {
+          (*it)->build();
+        }
+      } catch (...) {
+        typename Observers::iterator jt;
+        for (jt = it.base(); jt != _observers.end(); ++jt) {
+          (*jt)->clear();
+        }
+        throw;
+      }
+    }
+
+    /// \brief Notifies all the registed observers about all items are 
+    /// erased.
+    ///
+    /// Notifies all the registed observers about all items are erased
+    /// from the container.
+    void clear() {
+      typename Observers::iterator it = _observers.begin();
+      while (it != _observers.end()) {
+        try {
+          (*it)->clear();
+          ++it;
+        } catch (const ImmediateDetach&) {
+          it = _observers.erase(it);
+          (*it)->_index = _observers.end();
+          (*it)->_notifier = 0;
+        }
+      }
+    }
+  };
+
+}
+
+#endif
Index: lemon/bits/array_map.h
===================================================================
--- lemon/bits/array_map.h	(revision 2553)
+++ lemon/bits/array_map.h	(revision 2553)
@@ -0,0 +1,346 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_ARRAY_MAP_H
+#define LEMON_BITS_ARRAY_MAP_H
+
+#include <memory>
+
+#include <lemon/bits/traits.h>
+#include <lemon/bits/alteration_notifier.h>
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+
+/// \ingroup graphbits
+/// \file
+/// \brief Graph map based on the array storage.
+
+namespace lemon {
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Graph map based on the array storage.
+  ///
+  /// The ArrayMap template class is graph map structure what
+  /// automatically updates the map when a key is added to or erased from
+  /// the map. This map uses the allocators to implement 
+  /// the container functionality.
+  ///
+  /// The template parameters are the Graph the current Item type and
+  /// the Value type of the map.
+  template <typename _Graph, typename _Item, typename _Value>
+  class ArrayMap 
+    : public ItemSetTraits<_Graph, _Item>::ItemNotifier::ObserverBase {
+  public:
+    /// The graph type of the maps. 
+    typedef _Graph Graph;
+    /// The item type of the map.
+    typedef _Item Item;
+    /// The reference map tag.
+    typedef True ReferenceMapTag;
+
+    /// The key type of the maps.
+    typedef _Item Key;
+    /// The value type of the map.
+    typedef _Value Value;
+
+    /// The const reference type of the map.
+    typedef const _Value& ConstReference;
+    /// The reference type of the map.
+    typedef _Value& Reference;
+
+    /// The notifier type.
+    typedef typename ItemSetTraits<_Graph, _Item>::ItemNotifier Notifier;
+
+    /// The MapBase of the Map which imlements the core regisitry function.
+    typedef typename Notifier::ObserverBase Parent;
+		
+  private:
+    typedef std::allocator<Value> Allocator;
+
+  public:
+
+    /// \brief Graph initialized map constructor.
+    ///
+    /// Graph initialized map constructor.
+    explicit ArrayMap(const Graph& graph) {
+      Parent::attach(graph.notifier(Item()));
+      allocate_memory();
+      Notifier* nf = Parent::notifier();
+      Item it;
+      for (nf->first(it); it != INVALID; nf->next(it)) {
+	int id = nf->id(it);;
+	allocator.construct(&(values[id]), Value());
+      }								
+    }
+
+    /// \brief Constructor to use default value to initialize the map. 
+    ///
+    /// It constructs a map and initialize all of the the map. 
+    ArrayMap(const Graph& graph, const Value& value) {
+      Parent::attach(graph.notifier(Item()));
+      allocate_memory();
+      Notifier* nf = Parent::notifier();
+      Item it;
+      for (nf->first(it); it != INVALID; nf->next(it)) {
+	int id = nf->id(it);;
+	allocator.construct(&(values[id]), value);
+      }								
+    }
+
+    /// \brief Constructor to copy a map of the same map type.
+    ///
+    /// Constructor to copy a map of the same map type.     
+    ArrayMap(const ArrayMap& copy) : Parent() {
+      if (copy.attached()) {
+	attach(*copy.notifier());
+      }
+      capacity = copy.capacity;
+      if (capacity == 0) return;
+      values = allocator.allocate(capacity);
+      Notifier* nf = Parent::notifier();
+      Item it;
+      for (nf->first(it); it != INVALID; nf->next(it)) {
+	int id = nf->id(it);;
+	allocator.construct(&(values[id]), copy.values[id]);
+      }
+    }
+
+    /// \brief Assign operator.
+    ///
+    /// This operator assigns for each item in the map the
+    /// value mapped to the same item in the copied map.  
+    /// The parameter map should be indiced with the same
+    /// itemset because this assign operator does not change
+    /// the container of the map. 
+    ArrayMap& operator=(const ArrayMap& cmap) {
+      return operator=<ArrayMap>(cmap);
+    }
+
+
+    /// \brief Template assign operator.
+    ///
+    /// The given parameter should be conform to the ReadMap
+    /// concecpt and could be indiced by the current item set of
+    /// the NodeMap. In this case the value for each item
+    /// is assigned by the value of the given ReadMap. 
+    template <typename CMap>
+    ArrayMap& operator=(const CMap& cmap) {
+      checkConcept<concepts::ReadMap<Key, _Value>, CMap>();
+      const typename Parent::Notifier* nf = Parent::notifier();
+      Item it;
+      for (nf->first(it); it != INVALID; nf->next(it)) {
+        set(it, cmap[it]);
+      }
+      return *this;
+    }
+
+    /// \brief The destructor of the map.
+    ///     
+    /// The destructor of the map.
+    virtual ~ArrayMap() {      
+      if (attached()) {
+	clear();
+	detach();
+      }
+    }
+		
+  protected:
+
+    using Parent::attach;
+    using Parent::detach;
+    using Parent::attached;
+
+  public:
+
+    /// \brief The subscript operator. 
+    ///
+    /// The subscript operator. The map can be subscripted by the
+    /// actual keys of the graph. 
+    Value& operator[](const Key& key) {
+      int id = Parent::notifier()->id(key);
+      return values[id];
+    } 
+		
+    /// \brief The const subscript operator.
+    ///
+    /// The const subscript operator. The map can be subscripted by the
+    /// actual keys of the graph. 
+    const Value& operator[](const Key& key) const {
+      int id = Parent::notifier()->id(key);
+      return values[id];
+    }
+
+    /// \brief Setter function of the map.
+    ///	
+    /// Setter function of the map. Equivalent with map[key] = val.
+    /// This is a compatibility feature with the not dereferable maps.
+    void set(const Key& key, const Value& val) {
+      (*this)[key] = val;
+    }
+
+  protected:
+
+    /// \brief Adds a new key to the map.
+    ///		
+    /// It adds a new key to the map. It called by the observer notifier
+    /// and it overrides the add() member function of the observer base.     
+    virtual void add(const Key& key) {
+      Notifier* nf = Parent::notifier();
+      int id = nf->id(key);
+      if (id >= capacity) {
+	int new_capacity = (capacity == 0 ? 1 : capacity);
+	while (new_capacity <= id) {
+	  new_capacity <<= 1;
+	}
+	Value* new_values = allocator.allocate(new_capacity);
+	Item it;
+	for (nf->first(it); it != INVALID; nf->next(it)) {
+	  int jd = nf->id(it);;
+	  if (id != jd) {
+	    allocator.construct(&(new_values[jd]), values[jd]);
+	    allocator.destroy(&(values[jd]));
+	  }
+	}
+	if (capacity != 0) allocator.deallocate(values, capacity);
+	values = new_values;
+	capacity = new_capacity;
+      }
+      allocator.construct(&(values[id]), Value());
+    }
+
+    /// \brief Adds more new keys to the map.
+    ///		
+    /// It adds more new keys to the map. It called by the observer notifier
+    /// and it overrides the add() member function of the observer base.     
+    virtual void add(const std::vector<Key>& keys) {
+      Notifier* nf = Parent::notifier();
+      int max_id = -1;
+      for (int i = 0; i < int(keys.size()); ++i) {
+	int id = nf->id(keys[i]);
+	if (id > max_id) {
+	  max_id = id;
+	}
+      }
+      if (max_id >= capacity) {
+	int new_capacity = (capacity == 0 ? 1 : capacity);
+	while (new_capacity <= max_id) {
+	  new_capacity <<= 1;
+	}
+	Value* new_values = allocator.allocate(new_capacity);
+	Item it;
+	for (nf->first(it); it != INVALID; nf->next(it)) {
+	  int id = nf->id(it);
+	  bool found = false;
+	  for (int i = 0; i < int(keys.size()); ++i) {
+	    int jd = nf->id(keys[i]);
+	    if (id == jd) {
+	      found = true;
+	      break;
+	    }
+	  }
+	  if (found) continue;
+	  allocator.construct(&(new_values[id]), values[id]);
+	  allocator.destroy(&(values[id]));
+	}
+	if (capacity != 0) allocator.deallocate(values, capacity);
+	values = new_values;
+	capacity = new_capacity;
+      }
+      for (int i = 0; i < int(keys.size()); ++i) {
+	int id = nf->id(keys[i]);
+	allocator.construct(&(values[id]), Value());
+      }
+    }
+		
+    /// \brief Erase a key from the map.
+    ///
+    /// Erase a key from the map. It called by the observer notifier
+    /// and it overrides the erase() member function of the observer base.     
+    virtual void erase(const Key& key) {
+      int id = Parent::notifier()->id(key);
+      allocator.destroy(&(values[id]));
+    }
+
+    /// \brief Erase more keys from the map.
+    ///
+    /// Erase more keys from the map. It called by the observer notifier
+    /// and it overrides the erase() member function of the observer base.     
+    virtual void erase(const std::vector<Key>& keys) {
+      for (int i = 0; i < int(keys.size()); ++i) {
+	int id = Parent::notifier()->id(keys[i]);
+	allocator.destroy(&(values[id]));
+      }
+    }
+
+    /// \brief Buildes the map.
+    ///	
+    /// It buildes the map. It called by the observer notifier
+    /// and it overrides the build() member function of the observer base. 
+    virtual void build() {
+      Notifier* nf = Parent::notifier();
+      allocate_memory();
+      Item it;
+      for (nf->first(it); it != INVALID; nf->next(it)) {
+	int id = nf->id(it);;
+	allocator.construct(&(values[id]), Value());
+      }								
+    }
+
+    /// \brief Clear the map.
+    ///
+    /// It erase all items from the map. It called by the observer notifier
+    /// and it overrides the clear() member function of the observer base.     
+    virtual void clear() {	
+      Notifier* nf = Parent::notifier();
+      if (capacity != 0) {
+	Item it;
+	for (nf->first(it); it != INVALID; nf->next(it)) {
+	  int id = nf->id(it);
+	  allocator.destroy(&(values[id]));
+	}								
+	allocator.deallocate(values, capacity);
+	capacity = 0;
+      }
+    }
+
+  private:
+      
+    void allocate_memory() {
+      int max_id = Parent::notifier()->maxId();
+      if (max_id == -1) {
+	capacity = 0;
+	values = 0;
+	return;
+      }
+      capacity = 1;
+      while (capacity <= max_id) {
+	capacity <<= 1;
+      }
+      values = allocator.allocate(capacity);	
+    }      
+
+    int capacity;
+    Value* values;
+    Allocator allocator;
+
+  };		
+
+}
+
+#endif 
Index: lemon/bits/base_extender.h
===================================================================
--- lemon/bits/base_extender.h	(revision 2553)
+++ lemon/bits/base_extender.h	(revision 2553)
@@ -0,0 +1,495 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_BASE_EXTENDER_H
+#define LEMON_BITS_BASE_EXTENDER_H
+
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+
+#include <lemon/bits/map_extender.h>
+#include <lemon/bits/default_map.h>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+
+///\ingroup graphbits
+///\file
+///\brief Extenders for the graph types
+namespace lemon {
+
+  /// \ingroup graphbits
+  ///
+  /// \brief BaseGraph to BaseUGraph extender
+  template <typename Base>
+  class UndirGraphExtender : public Base {
+
+  public:
+
+    typedef Base Parent;
+    typedef typename Parent::Edge UEdge;
+    typedef typename Parent::Node Node;
+
+    typedef True UndirectedTag;
+
+    class Edge : public UEdge {
+      friend class UndirGraphExtender;
+
+    protected:
+      bool forward;
+
+      Edge(const UEdge &ue, bool _forward) :
+        UEdge(ue), forward(_forward) {}
+
+    public:
+      Edge() {}
+
+      /// Invalid edge constructor
+      Edge(Invalid i) : UEdge(i), forward(true) {}
+
+      bool operator==(const Edge &that) const {
+	return forward==that.forward && UEdge(*this)==UEdge(that);
+      }
+      bool operator!=(const Edge &that) const {
+	return forward!=that.forward || UEdge(*this)!=UEdge(that);
+      }
+      bool operator<(const Edge &that) const {
+	return forward<that.forward ||
+	  (!(that.forward<forward) && UEdge(*this)<UEdge(that));
+      }
+    };
+
+
+
+    using Parent::source;
+
+    /// Source of the given Edge.
+    Node source(const Edge &e) const {
+      return e.forward ? Parent::source(e) : Parent::target(e);
+    }
+
+    using Parent::target;
+
+    /// Target of the given Edge.
+    Node target(const Edge &e) const {
+      return e.forward ? Parent::target(e) : Parent::source(e);
+    }
+
+    /// \brief Directed edge from an undirected edge.
+    ///
+    /// Returns a directed edge corresponding to the specified UEdge.
+    /// If the given bool is true the given undirected edge and the
+    /// returned edge have the same source node.
+    static Edge direct(const UEdge &ue, bool d) {
+      return Edge(ue, d);
+    }
+
+    /// Returns whether the given directed edge is same orientation as the
+    /// corresponding undirected edge.
+    ///
+    /// \todo reference to the corresponding point of the undirected graph
+    /// concept. "What does the direction of an undirected edge mean?"
+    static bool direction(const Edge &e) { return e.forward; }
+
+
+    using Parent::first;
+    using Parent::next;
+
+    void first(Edge &e) const {
+      Parent::first(e);
+      e.forward=true;
+    }
+
+    void next(Edge &e) const {
+      if( e.forward ) {
+	e.forward = false;
+      }
+      else {
+	Parent::next(e);
+	e.forward = true;
+      }
+    }
+
+    void firstOut(Edge &e, const Node &n) const {
+      Parent::firstIn(e,n);
+      if( UEdge(e) != INVALID ) {
+	e.forward = false;
+      }
+      else {
+	Parent::firstOut(e,n);
+	e.forward = true;
+      }
+    }
+    void nextOut(Edge &e) const {
+      if( ! e.forward ) {
+	Node n = Parent::target(e);
+	Parent::nextIn(e);
+	if( UEdge(e) == INVALID ) {
+	  Parent::firstOut(e, n);
+	  e.forward = true;
+	}
+      }
+      else {
+	Parent::nextOut(e);
+      }
+    }
+
+    void firstIn(Edge &e, const Node &n) const {
+      Parent::firstOut(e,n);
+      if( UEdge(e) != INVALID ) {
+	e.forward = false;
+      }
+      else {
+	Parent::firstIn(e,n);
+	e.forward = true;
+      }
+    }
+    void nextIn(Edge &e) const {
+      if( ! e.forward ) {
+	Node n = Parent::source(e);
+	Parent::nextOut(e);
+	if( UEdge(e) == INVALID ) {
+	  Parent::firstIn(e, n);
+	  e.forward = true;
+	}
+      }
+      else {
+	Parent::nextIn(e);
+      }
+    }
+
+    void firstInc(UEdge &e, bool &d, const Node &n) const {
+      d = true;
+      Parent::firstOut(e, n);
+      if (e != INVALID) return;
+      d = false;
+      Parent::firstIn(e, n);
+    }
+
+    void nextInc(UEdge &e, bool &d) const {
+      if (d) {
+	Node s = Parent::source(e);
+	Parent::nextOut(e);
+	if (e != INVALID) return;
+	d = false;
+	Parent::firstIn(e, s);
+      } else {
+	Parent::nextIn(e);
+      }
+    }
+
+    Node nodeFromId(int ix) const {
+      return Parent::nodeFromId(ix);
+    }
+
+    Edge edgeFromId(int ix) const {
+      return direct(Parent::edgeFromId(ix >> 1), bool(ix & 1));
+    }
+
+    UEdge uEdgeFromId(int ix) const {
+      return Parent::edgeFromId(ix);
+    }
+
+    int id(const Node &n) const {
+      return Parent::id(n);
+    }
+
+    int id(const UEdge &e) const {
+      return Parent::id(e);
+    }
+
+    int id(const Edge &e) const {
+      return 2 * Parent::id(e) + int(e.forward);
+    }
+
+    int maxNodeId() const {
+      return Parent::maxNodeId();
+    }
+
+    int maxEdgeId() const {
+      return 2 * Parent::maxEdgeId() + 1;
+    }
+
+    int maxUEdgeId() const {
+      return Parent::maxEdgeId();
+    }
+
+
+    int edgeNum() const {
+      return 2 * Parent::edgeNum();
+    }
+
+    int uEdgeNum() const {
+      return Parent::edgeNum();
+    }
+
+    Edge findEdge(Node s, Node t, Edge p = INVALID) const {
+      if (p == INVALID) {
+	UEdge edge = Parent::findEdge(s, t);
+	if (edge != INVALID) return direct(edge, true);
+	edge = Parent::findEdge(t, s);
+	if (edge != INVALID) return direct(edge, false);
+      } else if (direction(p)) {
+	UEdge edge = Parent::findEdge(s, t, p);
+	if (edge != INVALID) return direct(edge, true);
+	edge = Parent::findEdge(t, s);
+	if (edge != INVALID) return direct(edge, false);	
+      } else {
+	UEdge edge = Parent::findEdge(t, s, p);
+	if (edge != INVALID) return direct(edge, false);	      
+      }
+      return INVALID;
+    }
+
+    UEdge findUEdge(Node s, Node t, UEdge p = INVALID) const {
+      if (s != t) {
+        if (p == INVALID) {
+          UEdge edge = Parent::findEdge(s, t);
+          if (edge != INVALID) return edge;
+          edge = Parent::findEdge(t, s);
+          if (edge != INVALID) return edge;
+        } else if (Parent::s(p) == s) {
+          UEdge edge = Parent::findEdge(s, t, p);
+          if (edge != INVALID) return edge;
+          edge = Parent::findEdge(t, s);
+          if (edge != INVALID) return edge;	
+        } else {
+          UEdge edge = Parent::findEdge(t, s, p);
+          if (edge != INVALID) return edge;	      
+        }
+      } else {
+        return Parent::findEdge(s, t, p);
+      }
+      return INVALID;
+    }
+  };
+
+  template <typename Base>
+  class BidirBpUGraphExtender : public Base {
+  public:
+    typedef Base Parent;
+    typedef BidirBpUGraphExtender Graph;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::UEdge UEdge;
+
+
+    using Parent::first;
+    using Parent::next;
+
+    using Parent::id;
+
+    class ANode : public Node {
+      friend class BidirBpUGraphExtender;
+    public:
+      ANode() {}
+      ANode(const Node& node) : Node(node) {
+	LEMON_ASSERT(Parent::aNode(node) || node == INVALID, 
+		     typename Parent::NodeSetError());
+      }
+      ANode& operator=(const Node& node) {
+	LEMON_ASSERT(Parent::aNode(node) || node == INVALID, 
+		     typename Parent::NodeSetError());
+        Node::operator=(node);
+        return *this;
+      }
+      ANode(Invalid) : Node(INVALID) {}
+      ANode& operator=(Invalid) {
+        Node::operator=(INVALID);
+        return *this;
+      }
+    };
+
+    void first(ANode& node) const {
+      Parent::firstANode(static_cast<Node&>(node));
+    }
+    void next(ANode& node) const {
+      Parent::nextANode(static_cast<Node&>(node));
+    }
+
+    int id(const ANode& node) const {
+      return Parent::aNodeId(node);
+    }
+
+    class BNode : public Node {
+      friend class BidirBpUGraphExtender;
+    public:
+      BNode() {}
+      BNode(const Node& node) : Node(node) {
+	LEMON_ASSERT(Parent::bNode(node) || node == INVALID,
+		     typename Parent::NodeSetError());
+      }
+      BNode& operator=(const Node& node) {
+	LEMON_ASSERT(Parent::bNode(node) || node == INVALID, 
+		     typename Parent::NodeSetError());
+        Node::operator=(node);
+        return *this;
+      }
+      BNode(Invalid) : Node(INVALID) {}
+      BNode& operator=(Invalid) {
+        Node::operator=(INVALID);
+        return *this;
+      }
+    };
+
+    void first(BNode& node) const {
+      Parent::firstBNode(static_cast<Node&>(node));
+    }
+    void next(BNode& node) const {
+      Parent::nextBNode(static_cast<Node&>(node));
+    }
+  
+    int id(const BNode& node) const {
+      return Parent::aNodeId(node);
+    }
+
+    Node source(const UEdge& edge) const {
+      return aNode(edge);
+    }
+    Node target(const UEdge& edge) const {
+      return bNode(edge);
+    }
+
+    void firstInc(UEdge& edge, bool& dir, const Node& node) const {
+      if (Parent::aNode(node)) {
+	Parent::firstFromANode(edge, node);
+	dir = true;
+      } else {
+	Parent::firstFromBNode(edge, node);
+	dir = static_cast<UEdge&>(edge) == INVALID;
+      }
+    }
+    void nextInc(UEdge& edge, bool& dir) const {
+      if (dir) {
+	Parent::nextFromANode(edge);
+      } else {
+	Parent::nextFromBNode(edge);
+	if (edge == INVALID) dir = true;
+      }
+    }
+
+    class Edge : public UEdge {
+      friend class BidirBpUGraphExtender;
+    protected:
+      bool forward;
+
+      Edge(const UEdge& edge, bool _forward)
+	: UEdge(edge), forward(_forward) {}
+
+    public:
+      Edge() {}
+      Edge (Invalid) : UEdge(INVALID), forward(true) {}
+      bool operator==(const Edge& i) const {
+	return UEdge::operator==(i) && forward == i.forward;
+      }
+      bool operator!=(const Edge& i) const {
+	return UEdge::operator!=(i) || forward != i.forward;
+      }
+      bool operator<(const Edge& i) const {
+	return UEdge::operator<(i) || 
+	  (!(i.forward<forward) && UEdge(*this)<UEdge(i));
+      }
+    };
+
+    void first(Edge& edge) const {
+      Parent::first(static_cast<UEdge&>(edge));
+      edge.forward = true;
+    }
+
+    void next(Edge& edge) const {
+      if (!edge.forward) {
+	Parent::next(static_cast<UEdge&>(edge));
+      }
+      edge.forward = !edge.forward;
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      if (Parent::aNode(node)) {
+	Parent::firstFromANode(edge, node);
+	edge.forward = true;
+      } else {
+	Parent::firstFromBNode(edge, node);
+	edge.forward = static_cast<UEdge&>(edge) == INVALID;
+      }
+    }
+    void nextOut(Edge& edge) const {
+      if (edge.forward) {
+	Parent::nextFromANode(edge);
+      } else {
+	Parent::nextFromBNode(edge);
+        edge.forward = static_cast<UEdge&>(edge) == INVALID;
+      }
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      if (Parent::bNode(node)) {
+	Parent::firstFromBNode(edge, node);
+	edge.forward = true;	
+      } else {
+	Parent::firstFromANode(edge, node);
+	edge.forward = static_cast<UEdge&>(edge) == INVALID;
+      }
+    }
+    void nextIn(Edge& edge) const {
+      if (edge.forward) {
+	Parent::nextFromBNode(edge);
+      } else {
+	Parent::nextFromANode(edge);
+	edge.forward = static_cast<UEdge&>(edge) == INVALID;
+      }
+    }
+
+    Node source(const Edge& edge) const {
+      return edge.forward ? Parent::aNode(edge) : Parent::bNode(edge);
+    }
+    Node target(const Edge& edge) const {
+      return edge.forward ? Parent::bNode(edge) : Parent::aNode(edge);
+    }
+
+    int id(const Edge& edge) const {
+      return (Parent::id(static_cast<const UEdge&>(edge)) << 1) + 
+        (edge.forward ? 0 : 1);
+    }
+    Edge edgeFromId(int ix) const {
+      return Edge(Parent::fromUEdgeId(ix >> 1), (ix & 1) == 0);
+    }
+    int maxEdgeId() const {
+      return (Parent::maxUEdgeId() << 1) + 1;
+    }
+
+    bool direction(const Edge& edge) const {
+      return edge.forward;
+    }
+
+    Edge direct(const UEdge& edge, bool dir) const {
+      return Edge(edge, dir);
+    }
+
+    int edgeNum() const {
+      return 2 * Parent::uEdgeNum();
+    }
+
+    int uEdgeNum() const {
+      return Parent::uEdgeNum();
+    }
+
+
+  };
+}
+
+#endif
Index: lemon/bits/bezier.h
===================================================================
--- lemon/bits/bezier.h	(revision 2618)
+++ lemon/bits/bezier.h	(revision 2618)
@@ -0,0 +1,176 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BEZIER_H
+#define LEMON_BEZIER_H
+
+///\ingroup misc
+///\file
+///\brief Classes to compute with Bezier curves.
+///
+///Up to now this file is used internally by \ref graph_to_eps.h
+///
+///\author Alpar Juttner
+
+#include<lemon/dim2.h>
+
+namespace lemon {
+  namespace dim2 {
+
+class BezierBase {
+public:
+  typedef lemon::dim2::Point<double> Point;
+protected:
+  static Point conv(Point x,Point y,double t) {return (1-t)*x+t*y;}
+};
+
+class Bezier1 : public BezierBase
+{
+public:
+  Point p1,p2;
+
+  Bezier1() {}
+  Bezier1(Point _p1, Point _p2) :p1(_p1), p2(_p2) {}
+  
+  Point operator()(double t) const
+  {
+    //    return conv(conv(p1,p2,t),conv(p2,p3,t),t);
+    return conv(p1,p2,t);
+  }
+  Bezier1 before(double t) const
+  {
+    return Bezier1(p1,conv(p1,p2,t));
+  }
+  
+  Bezier1 after(double t) const
+  {
+    return Bezier1(conv(p1,p2,t),p2);
+  }
+
+  Bezier1 revert() const { return Bezier1(p2,p1);}
+  Bezier1 operator()(double a,double b) const { return before(b).after(a/b); }
+  Point grad() const { return p2-p1; }
+  Point norm() const { return rot90(p2-p1); }
+  Point grad(double) const { return grad(); }
+  Point norm(double t) const { return rot90(grad(t)); }
+};
+
+class Bezier2 : public BezierBase
+{
+public:
+  Point p1,p2,p3;
+
+  Bezier2() {}
+  Bezier2(Point _p1, Point _p2, Point _p3) :p1(_p1), p2(_p2), p3(_p3) {}
+  Bezier2(const Bezier1 &b) : p1(b.p1), p2(conv(b.p1,b.p2,.5)), p3(b.p2) {}
+  Point operator()(double t) const
+  {
+    //    return conv(conv(p1,p2,t),conv(p2,p3,t),t);
+    return ((1-t)*(1-t))*p1+(2*(1-t)*t)*p2+(t*t)*p3;
+  }
+  Bezier2 before(double t) const
+  {
+    Point q(conv(p1,p2,t));
+    Point r(conv(p2,p3,t));
+    return Bezier2(p1,q,conv(q,r,t));
+  }
+  
+  Bezier2 after(double t) const
+  {
+    Point q(conv(p1,p2,t));
+    Point r(conv(p2,p3,t));
+    return Bezier2(conv(q,r,t),r,p3);
+  }
+  Bezier2 revert() const { return Bezier2(p3,p2,p1);}
+  Bezier2 operator()(double a,double b) const { return before(b).after(a/b); }
+  Bezier1 grad() const { return Bezier1(2.0*(p2-p1),2.0*(p3-p2)); }
+  Bezier1 norm() const { return Bezier1(2.0*rot90(p2-p1),2.0*rot90(p3-p2)); }
+  Point grad(double t) const { return grad()(t); }
+  Point norm(double t) const { return rot90(grad(t)); }
+};
+
+class Bezier3 : public BezierBase
+{
+public:
+  Point p1,p2,p3,p4;
+
+  Bezier3() {}
+  Bezier3(Point _p1, Point _p2, Point _p3, Point _p4)
+    : p1(_p1), p2(_p2), p3(_p3), p4(_p4) {}
+  Bezier3(const Bezier1 &b) : p1(b.p1), p2(conv(b.p1,b.p2,1.0/3.0)), 
+			      p3(conv(b.p1,b.p2,2.0/3.0)), p4(b.p2) {}
+  Bezier3(const Bezier2 &b) : p1(b.p1), p2(conv(b.p1,b.p2,2.0/3.0)),
+			      p3(conv(b.p2,b.p3,1.0/3.0)), p4(b.p3) {}
+  
+  Point operator()(double t) const 
+    {
+      //    return Bezier2(conv(p1,p2,t),conv(p2,p3,t),conv(p3,p4,t))(t);
+      return ((1-t)*(1-t)*(1-t))*p1+(3*t*(1-t)*(1-t))*p2+
+	(3*t*t*(1-t))*p3+(t*t*t)*p4;
+    }
+  Bezier3 before(double t) const
+    {
+      Point p(conv(p1,p2,t));
+      Point q(conv(p2,p3,t));
+      Point r(conv(p3,p4,t));
+      Point a(conv(p,q,t));
+      Point b(conv(q,r,t));
+      Point c(conv(a,b,t));
+      return Bezier3(p1,p,a,c);
+    }
+  
+  Bezier3 after(double t) const
+    {
+      Point p(conv(p1,p2,t));
+      Point q(conv(p2,p3,t));
+      Point r(conv(p3,p4,t));
+      Point a(conv(p,q,t));
+      Point b(conv(q,r,t));
+      Point c(conv(a,b,t));
+      return Bezier3(c,b,r,p4);
+    }
+  Bezier3 revert() const { return Bezier3(p4,p3,p2,p1);}
+  Bezier3 operator()(double a,double b) const { return before(b).after(a/b); }
+  Bezier2 grad() const { return Bezier2(3.0*(p2-p1),3.0*(p3-p2),3.0*(p4-p3)); }
+  Bezier2 norm() const { return Bezier2(3.0*rot90(p2-p1),
+				  3.0*rot90(p3-p2),
+				  3.0*rot90(p4-p3)); }
+  Point grad(double t) const { return grad()(t); }
+  Point norm(double t) const { return rot90(grad(t)); }
+
+  template<class R,class F,class S,class D>
+  R recSplit(F &_f,const S &_s,D _d) const 
+  {
+    const Point a=(p1+p2)/2;
+    const Point b=(p2+p3)/2;
+    const Point c=(p3+p4)/2;
+    const Point d=(a+b)/2;
+    const Point e=(b+c)/2;
+    const Point f=(d+e)/2;
+    R f1=_f(Bezier3(p1,a,d,e),_d);
+    R f2=_f(Bezier3(e,d,c,p4),_d);
+    return _s(f1,f2);
+  }
+  
+};
+
+
+} //END OF NAMESPACE dim2
+} //END OF NAMESPACE lemon
+
+#endif // LEMON_BEZIER_H
Index: lemon/bits/debug_map.h
===================================================================
--- lemon/bits/debug_map.h	(revision 2553)
+++ lemon/bits/debug_map.h	(revision 2553)
@@ -0,0 +1,382 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_DEBUG_MAP_H
+#define LEMON_BITS_DEBUG_MAP_H
+
+#include <vector>
+#include <algorithm>
+
+#include <lemon/bits/traits.h>
+#include <lemon/bits/utility.h>
+#include <lemon/error.h>
+
+#include <lemon/bits/alteration_notifier.h>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+
+///\ingroup graphbits
+///
+///\file
+///\brief Vector based graph maps for debugging.
+namespace lemon {
+
+#ifndef LEMON_STRICT_DEBUG_MAP
+#define LEMON_STRICT_DEBUG_MAP false
+#endif
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Graph map based on the std::vector storage.
+  ///
+  /// The DebugMap template class is graph map structure what
+  /// automatically updates the map when a key is added to or erased from
+  /// the map. This map also checks some programming failures by example
+  /// multiple addition of items, erasing of not existing item or
+  /// not erased items at the destruction of the map. It helps the
+  /// programmer to avoid segmentation faults and memory leaks.
+  ///
+  /// \param Notifier The AlterationNotifier that will notify this map.
+  /// \param Item The item type of the graph items.
+  /// \param Value The value type of the map.
+  /// 
+  /// \author Balazs Dezso  	
+  template <typename _Graph, typename _Item, typename _Value>
+  class DebugMap 
+    : public ItemSetTraits<_Graph, _Item>::ItemNotifier::ObserverBase {
+  private:
+		
+    /// The container type of the map.
+    typedef std::vector<_Value> Container;	
+
+    /// The container type of the debug flags.
+    typedef std::vector<bool> Flag;	
+
+  public:
+
+    static const bool strictCheck = LEMON_STRICT_DEBUG_MAP;
+
+    struct MapError {
+    public:
+      virtual ~MapError() {}
+      virtual const char* what() const throw() {
+        return "lemon::DebugMap::MapError";
+      }
+    };
+
+    /// The graph type of the map. 
+    typedef _Graph Graph;
+    /// The item type of the map.
+    typedef _Item Item;
+    /// The reference map tag.
+    typedef True ReferenceMapTag;
+
+    /// The key type of the map.
+    typedef _Item Key;
+    /// The value type of the map.
+    typedef _Value Value;
+
+    /// The notifier type.
+    typedef typename ItemSetTraits<_Graph, _Item>::ItemNotifier Notifier;
+
+    /// The map type.
+    typedef DebugMap Map;
+    /// The base class of the map.
+    typedef typename Notifier::ObserverBase Parent;
+
+    /// The reference type of the map;
+    typedef typename Container::reference Reference;
+    /// The const reference type of the map;
+    typedef typename Container::const_reference ConstReference;
+
+
+    /// \brief Constructor to attach the new map into the notifier.
+    ///
+    /// It constructs a map and attachs it into the notifier.
+    /// It adds all the items of the graph to the map.
+    DebugMap(const Graph& graph) {
+      Parent::attach(graph.notifier(Item()));
+      container.resize(Parent::notifier()->maxId() + 1);
+      flag.resize(Parent::notifier()->maxId() + 1, false);
+      const typename Parent::Notifier* notifier = Parent::notifier();
+      Item it;
+      for (notifier->first(it); it != INVALID; notifier->next(it)) {
+        flag[Parent::notifier()->id(it)] = true;
+      }
+    }
+
+    /// \brief Constructor uses given value to initialize the map. 
+    ///
+    /// It constructs a map uses a given value to initialize the map. 
+    /// It adds all the items of the graph to the map.
+    DebugMap(const Graph& graph, const Value& value) {
+      Parent::attach(graph.notifier(Item()));
+      container.resize(Parent::notifier()->maxId() + 1, value);
+      flag.resize(Parent::notifier()->maxId() + 1, false);
+      const typename Parent::Notifier* notifier = Parent::notifier();
+      Item it;
+      for (notifier->first(it); it != INVALID; notifier->next(it)) {
+        flag[Parent::notifier()->id(it)] = true;
+      }
+    }
+
+    /// \brief Copy constructor
+    ///
+    /// Copy constructor.
+    DebugMap(const DebugMap& _copy) : Parent() {
+      if (_copy.attached()) {
+	Parent::attach(*_copy.notifier());
+	container = _copy.container;
+      }
+      flag.resize(Parent::notifier()->maxId() + 1, false);
+      const typename Parent::Notifier* notifier = Parent::notifier();
+      Item it;
+      for (notifier->first(it); it != INVALID; notifier->next(it)) {
+        flag[Parent::notifier()->id(it)] = true;
+        LEMON_ASSERT(_copy.flag[Parent::notifier()->id(it)], MapError());
+      }
+    }
+
+    /// \brief Destructor
+    ///
+    /// Destructor.
+    ~DebugMap() {
+      const typename Parent::Notifier* notifier = Parent::notifier();
+      if (notifier != 0) {
+        Item it;
+        for (notifier->first(it); it != INVALID; notifier->next(it)) {
+          LEMON_ASSERT(flag[Parent::notifier()->id(it)], MapError());
+          flag[Parent::notifier()->id(it)] = false;
+        }
+      }
+      for (int i = 0; i < int(flag.size()); ++i) {
+        LEMON_ASSERT(!flag[i], MapError());
+      }
+    }
+
+    /// \brief Assign operator.
+    ///
+    /// This operator assigns for each item in the map the
+    /// value mapped to the same item in the copied map.  
+    /// The parameter map should be indiced with the same
+    /// itemset because this assign operator does not change
+    /// the container of the map. 
+    DebugMap& operator=(const DebugMap& cmap) {
+      return operator=<DebugMap>(cmap);
+    }
+
+
+    /// \brief Template assign operator.
+    ///
+    /// The given parameter should be conform to the ReadMap
+    /// concecpt and could be indiced by the current item set of
+    /// the NodeMap. In this case the value for each item
+    /// is assigned by the value of the given ReadMap. 
+    template <typename CMap>
+    DebugMap& operator=(const CMap& cmap) {
+      checkConcept<concepts::ReadMap<Key, _Value>, CMap>();
+      const typename Parent::Notifier* notifier = Parent::notifier();
+      Item it;
+      for (notifier->first(it); it != INVALID; notifier->next(it)) {
+        set(it, cmap[it]);
+      }
+      return *this;
+    }
+    
+  public:
+
+    /// \brief The subcript operator.
+    ///
+    /// The subscript operator. The map can be subscripted by the
+    /// actual items of the graph.      
+    Reference operator[](const Key& key) {
+      LEMON_ASSERT(flag[Parent::notifier()->id(key)], MapError());
+      return container[Parent::notifier()->id(key)];
+    } 
+		
+    /// \brief The const subcript operator.
+    ///
+    /// The const subscript operator. The map can be subscripted by the
+    /// actual items of the graph. 
+    ConstReference operator[](const Key& key) const {
+      LEMON_ASSERT(flag[Parent::notifier()->id(key)], MapError());
+      return container[Parent::notifier()->id(key)];
+    }
+
+
+    /// \brief The setter function of the map.
+    ///
+    /// It the same as operator[](key) = value expression.
+    void set(const Key& key, const Value& value) {
+      (*this)[key] = value;
+    }
+
+  protected:
+
+    /// \brief Adds a new key to the map.
+    ///		
+    /// It adds a new key to the map. It called by the observer notifier
+    /// and it overrides the add() member function of the observer base.     
+    virtual void add(const Key& key) {
+      int id = Parent::notifier()->id(key);
+      if (id >= int(container.size())) {
+	container.resize(id + 1);
+        flag.resize(id + 1, false);
+      }
+      LEMON_ASSERT(!flag[Parent::notifier()->id(key)], MapError());
+      flag[Parent::notifier()->id(key)] = true;
+      if (strictCheck) {
+        std::vector<bool> fl(flag.size(), false);
+        const typename Parent::Notifier* notifier = Parent::notifier();
+        Item it;
+        for (notifier->first(it); it != INVALID; notifier->next(it)) {
+          int jd = Parent::notifier()->id(it);
+          fl[jd] = true;
+        }
+        LEMON_ASSERT(fl == flag, MapError());
+      }
+    }
+
+    /// \brief Adds more new keys to the map.
+    ///		
+    /// It adds more new keys to the map. It called by the observer notifier
+    /// and it overrides the add() member function of the observer base.     
+    virtual void add(const std::vector<Key>& keys) {
+      int max = container.size() - 1;
+      for (int i = 0; i < int(keys.size()); ++i) {
+        int id = Parent::notifier()->id(keys[i]);
+        if (id >= max) {
+          max = id;
+        }
+      }
+      container.resize(max + 1);
+      flag.resize(max + 1, false);
+      for (int i = 0; i < int(keys.size()); ++i) {
+        LEMON_ASSERT(!flag[Parent::notifier()->id(keys[i])], MapError());
+        flag[Parent::notifier()->id(keys[i])] = true;
+      }
+      if (strictCheck) {
+        std::vector<bool> fl(flag.size(), false);
+        const typename Parent::Notifier* notifier = Parent::notifier();
+        Item it;
+        for (notifier->first(it); it != INVALID; notifier->next(it)) {
+          int id = Parent::notifier()->id(it);
+          fl[id] = true;
+        }
+        LEMON_ASSERT(fl == flag, MapError());
+      }
+    }
+
+    /// \brief Erase a key from the map.
+    ///
+    /// Erase a key from the map. It called by the observer notifier
+    /// and it overrides the erase() member function of the observer base.     
+    virtual void erase(const Key& key) {
+      if (strictCheck) {
+        std::vector<bool> fl(flag.size(), false);
+        const typename Parent::Notifier* notifier = Parent::notifier();
+        Item it;
+        for (notifier->first(it); it != INVALID; notifier->next(it)) {
+          int id = Parent::notifier()->id(it);
+          fl[id] = true;
+        }
+        LEMON_ASSERT(fl == flag, MapError());
+      }
+      container[Parent::notifier()->id(key)] = Value();
+      LEMON_ASSERT(flag[Parent::notifier()->id(key)], MapError());
+      flag[Parent::notifier()->id(key)] = false;
+    }
+
+    /// \brief Erase more keys from the map.
+    ///
+    /// Erase more keys from the map. It called by the observer notifier
+    /// and it overrides the erase() member function of the observer base.     
+    virtual void erase(const std::vector<Key>& keys) {
+      if (strictCheck) {
+        std::vector<bool> fl(flag.size(), false);
+        const typename Parent::Notifier* notifier = Parent::notifier();
+        Item it;
+        for (notifier->first(it); it != INVALID; notifier->next(it)) {
+          int id = Parent::notifier()->id(it);
+          fl[id] = true;
+        }
+        LEMON_ASSERT(fl == flag, MapError());
+      }
+      for (int i = 0; i < int(keys.size()); ++i) {
+	container[Parent::notifier()->id(keys[i])] = Value();
+        LEMON_ASSERT(flag[Parent::notifier()->id(keys[i])], MapError());
+        flag[Parent::notifier()->id(keys[i])] = false;
+      }
+    }
+    
+    /// \brief Buildes the map.
+    ///	
+    /// It buildes the map. It called by the observer notifier
+    /// and it overrides the build() member function of the observer base.
+    virtual void build() { 
+      if (strictCheck) {
+        for (int i = 0; i < int(flag.size()); ++i) {
+          LEMON_ASSERT(flag[i], MapError());
+        }
+      }
+      int size = Parent::notifier()->maxId() + 1;
+      container.reserve(size);
+      container.resize(size);
+      flag.reserve(size);
+      flag.resize(size, false);
+      const typename Parent::Notifier* notifier = Parent::notifier();
+      Item it;
+      for (notifier->first(it); it != INVALID; notifier->next(it)) {
+        int id = Parent::notifier()->id(it);
+        LEMON_ASSERT(!flag[id], MapError());
+        flag[id] = true;
+      }
+    }
+
+    /// \brief Clear the map.
+    ///
+    /// It erase all items from the map. It called by the observer notifier
+    /// and it overrides the clear() member function of the observer base.     
+    virtual void clear() { 
+      const typename Parent::Notifier* notifier = Parent::notifier();
+      Item it;
+      for (notifier->first(it); it != INVALID; notifier->next(it)) {
+        int id = Parent::notifier()->id(it);
+        LEMON_ASSERT(flag[id], MapError());
+        flag[id] = false;
+      }
+      if (strictCheck) {
+        for (int i = 0; i < int(flag.size()); ++i) {
+          LEMON_ASSERT(!flag[i], MapError());
+        }
+      }
+      container.clear();
+      flag.clear();
+    }
+    
+  private:
+		
+    Container container;
+    Flag flag;
+
+  };
+
+}
+
+#endif
Index: lemon/bits/default_map.h
===================================================================
--- lemon/bits/default_map.h	(revision 2553)
+++ lemon/bits/default_map.h	(revision 2553)
@@ -0,0 +1,181 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_DEFAULT_MAP_H
+#define LEMON_BITS_DEFAULT_MAP_H
+
+
+#include <lemon/bits/array_map.h>
+#include <lemon/bits/vector_map.h>
+#include <lemon/bits/debug_map.h>
+
+///\ingroup graphbits
+///\file
+///\brief Graph maps that construct and destruct their elements dynamically.
+
+namespace lemon {
+  
+  
+#ifndef LEMON_USE_DEBUG_MAP
+
+  template <typename _Graph, typename _Item, typename _Value>
+  struct DefaultMapSelector {
+    typedef ArrayMap<_Graph, _Item, _Value> Map;
+  };
+
+  // bool
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, bool> {
+    typedef VectorMap<_Graph, _Item, bool> Map;
+  };
+
+  // char
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, char> {
+    typedef VectorMap<_Graph, _Item, char> Map;
+  };
+
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, signed char> {
+    typedef VectorMap<_Graph, _Item, signed char> Map;
+  };
+
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, unsigned char> {
+    typedef VectorMap<_Graph, _Item, unsigned char> Map;
+  };
+
+
+  // int
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, signed int> {
+    typedef VectorMap<_Graph, _Item, signed int> Map;
+  };
+
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, unsigned int> {
+    typedef VectorMap<_Graph, _Item, unsigned int> Map;
+  };
+
+
+  // short
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, signed short> {
+    typedef VectorMap<_Graph, _Item, signed short> Map;
+  };
+
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, unsigned short> {
+    typedef VectorMap<_Graph, _Item, unsigned short> Map;
+  };
+
+
+  // long
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, signed long> {
+    typedef VectorMap<_Graph, _Item, signed long> Map;
+  };
+
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, unsigned long> {
+    typedef VectorMap<_Graph, _Item, unsigned long> Map;
+  };
+
+
+#if defined __GNUC__ && !defined __STRICT_ANSI__
+
+  // long long
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, signed long long> {
+    typedef VectorMap<_Graph, _Item, signed long long> Map;
+  };
+
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, unsigned long long> {
+    typedef VectorMap<_Graph, _Item, unsigned long long> Map;
+  };
+
+#endif
+
+
+  // float
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, float> {
+    typedef VectorMap<_Graph, _Item, float> Map;
+  };
+
+
+  // double
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, double> {
+    typedef VectorMap<_Graph, _Item,  double> Map;
+  };
+
+
+  // long double
+  template <typename _Graph, typename _Item>
+  struct DefaultMapSelector<_Graph, _Item, long double> {
+    typedef VectorMap<_Graph, _Item, long double> Map;
+  };
+
+
+  // pointer
+  template <typename _Graph, typename _Item, typename _Ptr>
+  struct DefaultMapSelector<_Graph, _Item, _Ptr*> {
+    typedef VectorMap<_Graph, _Item, _Ptr*> Map;
+  };
+
+#else 
+
+  template <typename _Graph, typename _Item, typename _Value>
+  struct DefaultMapSelector {
+    typedef DebugMap<_Graph, _Item, _Value> Map;
+  };
+
+#endif  
+
+  /// \e
+  template <typename _Graph, typename _Item, typename _Value>
+  class DefaultMap 
+    : public DefaultMapSelector<_Graph, _Item, _Value>::Map {
+  public:
+    typedef typename DefaultMapSelector<_Graph, _Item, _Value>::Map Parent;
+    typedef DefaultMap<_Graph, _Item, _Value> Map;
+    
+    typedef typename Parent::Graph Graph;
+    typedef typename Parent::Value Value;
+
+    explicit DefaultMap(const Graph& graph) : Parent(graph) {}
+    DefaultMap(const Graph& graph, const Value& value) 
+      : Parent(graph, value) {}
+
+    DefaultMap& operator=(const DefaultMap& cmap) {
+      return operator=<DefaultMap>(cmap);
+    }
+
+    template <typename CMap>
+    DefaultMap& operator=(const CMap& cmap) {
+      Parent::operator=(cmap);
+      return *this;
+    }
+
+  };
+
+}
+
+#endif
Index: lemon/bits/edge_set_extender.h
===================================================================
--- lemon/bits/edge_set_extender.h	(revision 2553)
+++ lemon/bits/edge_set_extender.h	(revision 2553)
@@ -0,0 +1,630 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_EDGE_SET_EXTENDER_H
+#define LEMON_BITS_EDGE_SET_EXTENDER_H
+
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+
+#include <lemon/bits/default_map.h>
+
+///\ingroup graphbits
+///\file
+///\brief Extenders for the edge set types
+namespace lemon {
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Extender for the EdgeSets
+  template <typename Base>
+  class EdgeSetExtender : public Base {
+  public:
+
+    typedef Base Parent;
+    typedef EdgeSetExtender Graph;
+
+    // Base extensions
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+    int maxId(Node) const {
+      return Parent::maxNodeId();
+    }
+
+    int maxId(Edge) const {
+      return Parent::maxEdgeId();
+    }
+
+    Node fromId(int id, Node) const {
+      return Parent::nodeFromId(id);
+    }
+
+    Edge fromId(int id, Edge) const {
+      return Parent::edgeFromId(id);
+    }
+
+    Node oppositeNode(const Node &n, const Edge &e) const {
+      if (n == Parent::source(e))
+	return Parent::target(e);
+      else if(n==Parent::target(e))
+	return Parent::source(e);
+      else
+	return INVALID;
+    }
+
+
+    // Alteration notifier extensions
+
+    /// The edge observer registry.
+    typedef AlterationNotifier<EdgeSetExtender, Edge> EdgeNotifier;
+
+  protected:
+
+    mutable EdgeNotifier edge_notifier;
+
+  public:
+
+    using Parent::notifier;
+
+    /// \brief Gives back the edge alteration notifier.
+    ///
+    /// Gives back the edge alteration notifier.
+    EdgeNotifier& notifier(Edge) const {
+      return edge_notifier;
+    }
+
+    // Iterable extensions
+
+    class NodeIt : public Node { 
+      const Graph* graph;
+    public:
+
+      NodeIt() {}
+
+      NodeIt(Invalid i) : Node(i) { }
+
+      explicit NodeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Node&>(*this));
+      }
+
+      NodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+
+      NodeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class EdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      EdgeIt() { }
+
+      EdgeIt(Invalid i) : Edge(i) { }
+
+      explicit EdgeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Edge&>(*this));
+      }
+
+      EdgeIt(const Graph& _graph, const Edge& e) : 
+	Edge(e), graph(&_graph) { }
+
+      EdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class OutEdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      OutEdgeIt() { }
+
+      OutEdgeIt(Invalid i) : Edge(i) { }
+
+      OutEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstOut(*this, node);
+      }
+
+      OutEdgeIt(const Graph& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) {}
+
+      OutEdgeIt& operator++() { 
+	graph->nextOut(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class InEdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      InEdgeIt() { }
+
+      InEdgeIt(Invalid i) : Edge(i) { }
+
+      InEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstIn(*this, node);
+      }
+
+      InEdgeIt(const Graph& _graph, const Edge& edge) : 
+	Edge(edge), graph(&_graph) {}
+
+      InEdgeIt& operator++() { 
+	graph->nextIn(*this);
+	return *this; 
+      }
+
+    };
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the source in this case) of the iterator
+    Node baseNode(const OutEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the target in this case) of the
+    /// iterator
+    Node runningNode(const OutEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the target in this case) of the iterator
+    Node baseNode(const InEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the source in this case) of the
+    /// iterator
+    Node runningNode(const InEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+
+    using Parent::first;
+
+    // Mappable extension
+    
+    template <typename _Value>
+    class EdgeMap 
+      : public MapExtender<DefaultMap<Graph, Edge, _Value> > {
+    public:
+      typedef EdgeSetExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, Edge, _Value> > Parent;
+
+      explicit EdgeMap(const Graph& _g) 
+	: Parent(_g) {}
+      EdgeMap(const Graph& _g, const _Value& _v) 
+	: Parent(_g, _v) {}
+
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+
+    };
+
+
+    // Alteration extension
+
+    Edge addEdge(const Node& from, const Node& to) {
+      Edge edge = Parent::addEdge(from, to);
+      notifier(Edge()).add(edge);
+      return edge;
+    }
+    
+    void clear() {
+      notifier(Edge()).clear();
+      Parent::clear();
+    }
+
+    void erase(const Edge& edge) {
+      notifier(Edge()).erase(edge);
+      Parent::erase(edge);
+    }
+
+    EdgeSetExtender() {
+      edge_notifier.setContainer(*this);
+    }
+
+    ~EdgeSetExtender() {
+      edge_notifier.clear();
+    }
+
+  };
+
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Extender for the UEdgeSets
+  template <typename Base>
+  class UEdgeSetExtender : public Base {
+
+  public:
+
+    typedef Base Parent;
+    typedef UEdgeSetExtender Graph;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+    typedef typename Parent::UEdge UEdge;
+
+
+    int maxId(Node) const {
+      return Parent::maxNodeId();
+    }
+
+    int maxId(Edge) const {
+      return Parent::maxEdgeId();
+    }
+
+    int maxId(UEdge) const {
+      return Parent::maxUEdgeId();
+    }
+
+    Node fromId(int id, Node) const {
+      return Parent::nodeFromId(id);
+    }
+
+    Edge fromId(int id, Edge) const {
+      return Parent::edgeFromId(id);
+    }
+
+    UEdge fromId(int id, UEdge) const {
+      return Parent::uEdgeFromId(id);
+    }
+
+    Node oppositeNode(const Node &n, const UEdge &e) const {
+      if( n == Parent::source(e))
+	return Parent::target(e);
+      else if( n == Parent::target(e))
+	return Parent::source(e);
+      else
+	return INVALID;
+    }
+
+    Edge oppositeEdge(const Edge &e) const {
+      return Parent::direct(e, !Parent::direction(e));
+    }
+
+    using Parent::direct;
+    Edge direct(const UEdge &ue, const Node &s) const {
+      return Parent::direct(ue, Parent::source(ue) == s);
+    }
+
+    typedef AlterationNotifier<UEdgeSetExtender, Edge> EdgeNotifier;
+    typedef AlterationNotifier<UEdgeSetExtender, UEdge> UEdgeNotifier;
+
+
+  protected:
+
+    mutable EdgeNotifier edge_notifier;
+    mutable UEdgeNotifier uedge_notifier;
+
+  public:
+
+    using Parent::notifier;
+    
+    EdgeNotifier& notifier(Edge) const {
+      return edge_notifier;
+    }
+
+    UEdgeNotifier& notifier(UEdge) const {
+      return uedge_notifier;
+    }
+
+
+    class NodeIt : public Node { 
+      const Graph* graph;
+    public:
+
+      NodeIt() {}
+
+      NodeIt(Invalid i) : Node(i) { }
+
+      explicit NodeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Node&>(*this));
+      }
+
+      NodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+
+      NodeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class EdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      EdgeIt() { }
+
+      EdgeIt(Invalid i) : Edge(i) { }
+
+      explicit EdgeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Edge&>(*this));
+      }
+
+      EdgeIt(const Graph& _graph, const Edge& e) : 
+	Edge(e), graph(&_graph) { }
+
+      EdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class OutEdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      OutEdgeIt() { }
+
+      OutEdgeIt(Invalid i) : Edge(i) { }
+
+      OutEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstOut(*this, node);
+      }
+
+      OutEdgeIt(const Graph& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) {}
+
+      OutEdgeIt& operator++() { 
+	graph->nextOut(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class InEdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      InEdgeIt() { }
+
+      InEdgeIt(Invalid i) : Edge(i) { }
+
+      InEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstIn(*this, node);
+      }
+
+      InEdgeIt(const Graph& _graph, const Edge& edge) : 
+	Edge(edge), graph(&_graph) {}
+
+      InEdgeIt& operator++() { 
+	graph->nextIn(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class UEdgeIt : public Parent::UEdge { 
+      const Graph* graph;
+    public:
+
+      UEdgeIt() { }
+
+      UEdgeIt(Invalid i) : UEdge(i) { }
+
+      explicit UEdgeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<UEdge&>(*this));
+      }
+
+      UEdgeIt(const Graph& _graph, const UEdge& e) : 
+	UEdge(e), graph(&_graph) { }
+
+      UEdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+    class IncEdgeIt : public Parent::UEdge {
+      friend class UEdgeSetExtender;
+      const Graph* graph;
+      bool direction;
+    public:
+
+      IncEdgeIt() { }
+
+      IncEdgeIt(Invalid i) : UEdge(i), direction(false) { }
+
+      IncEdgeIt(const Graph& _graph, const Node &n) : graph(&_graph) {
+	_graph.firstInc(*this, direction, n);
+      }
+
+      IncEdgeIt(const Graph& _graph, const UEdge &ue, const Node &n)
+	: graph(&_graph), UEdge(ue) {
+	direction = (_graph.source(ue) == n);
+      }
+
+      IncEdgeIt& operator++() {
+	graph->nextInc(*this, direction);
+	return *this; 
+      }
+    };
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the source in this case) of the iterator
+    Node baseNode(const OutEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the target in this case) of the
+    /// iterator
+    Node runningNode(const OutEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the target in this case) of the iterator
+    Node baseNode(const InEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the source in this case) of the
+    /// iterator
+    Node runningNode(const InEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+
+    /// Base node of the iterator
+    ///
+    /// Returns the base node of the iterator
+    Node baseNode(const IncEdgeIt &e) const {
+      return e.direction ? source(e) : target(e);
+    }
+    /// Running node of the iterator
+    ///
+    /// Returns the running node of the iterator
+    Node runningNode(const IncEdgeIt &e) const {
+      return e.direction ? target(e) : source(e);
+    }
+
+
+    template <typename _Value>
+    class EdgeMap 
+      : public MapExtender<DefaultMap<Graph, Edge, _Value> > {
+    public:
+      typedef UEdgeSetExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, Edge, _Value> > Parent;
+
+      EdgeMap(const Graph& _g) 
+	: Parent(_g) {}
+      EdgeMap(const Graph& _g, const _Value& _v) 
+	: Parent(_g, _v) {}
+
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+
+    };
+
+
+    template <typename _Value>
+    class UEdgeMap 
+      : public MapExtender<DefaultMap<Graph, UEdge, _Value> > {
+    public:
+      typedef UEdgeSetExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, UEdge, _Value> > Parent;
+
+      UEdgeMap(const Graph& _g) 
+	: Parent(_g) {}
+
+      UEdgeMap(const Graph& _g, const _Value& _v) 
+	: Parent(_g, _v) {}
+
+      UEdgeMap& operator=(const UEdgeMap& cmap) {
+	return operator=<UEdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      UEdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+
+    };
+
+
+    // Alteration extension
+
+    UEdge addEdge(const Node& from, const Node& to) {
+      UEdge uedge = Parent::addEdge(from, to);
+      notifier(UEdge()).add(uedge);
+      std::vector<Edge> edges;
+      edges.push_back(Parent::direct(uedge, true));
+      edges.push_back(Parent::direct(uedge, false));
+      notifier(Edge()).add(edges);
+      return uedge;
+    }
+    
+    void clear() {
+      notifier(Edge()).clear();
+      notifier(UEdge()).clear();
+      Parent::clear();
+    }
+
+    void erase(const UEdge& uedge) {
+      std::vector<Edge> edges;
+      edges.push_back(Parent::direct(uedge, true));
+      edges.push_back(Parent::direct(uedge, false));
+      notifier(Edge()).erase(edges);
+      notifier(UEdge()).erase(uedge);
+      Parent::erase(uedge);
+    }
+
+
+    UEdgeSetExtender() {
+      edge_notifier.setContainer(*this);
+      uedge_notifier.setContainer(*this);
+    }
+
+    ~UEdgeSetExtender() {
+      uedge_notifier.clear();
+      edge_notifier.clear();
+    }
+    
+  };
+
+}
+
+#endif
Index: lemon/bits/graph_adaptor_extender.h
===================================================================
--- lemon/bits/graph_adaptor_extender.h	(revision 2553)
+++ lemon/bits/graph_adaptor_extender.h	(revision 2553)
@@ -0,0 +1,742 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_GRAPH_ADAPTOR_EXTENDER_H
+#define LEMON_BITS_GRAPH_ADAPTOR_EXTENDER_H
+
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+
+#include <lemon/bits/default_map.h>
+
+
+///\ingroup graphbits
+///\file
+///\brief Extenders for the graph adaptor types
+namespace lemon {
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Extender for the GraphAdaptors
+  template <typename _Graph>
+  class GraphAdaptorExtender : public _Graph {
+  public:
+
+    typedef _Graph Parent;
+    typedef _Graph Graph;
+    typedef GraphAdaptorExtender Adaptor;
+
+    // Base extensions
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+    int maxId(Node) const {
+      return Parent::maxNodeId();
+    }
+
+    int maxId(Edge) const {
+      return Parent::maxEdgeId();
+    }
+
+    Node fromId(int id, Node) const {
+      return Parent::nodeFromId(id);
+    }
+
+    Edge fromId(int id, Edge) const {
+      return Parent::edgeFromId(id);
+    }
+
+    Node oppositeNode(const Node &n, const Edge &e) const {
+      if (n == Parent::source(e))
+	return Parent::target(e);
+      else if(n==Parent::target(e))
+	return Parent::source(e);
+      else
+	return INVALID;
+    }
+
+    class NodeIt : public Node { 
+      const Adaptor* graph;
+    public:
+
+      NodeIt() {}
+
+      NodeIt(Invalid i) : Node(i) { }
+
+      explicit NodeIt(const Adaptor& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Node&>(*this));
+      }
+
+      NodeIt(const Adaptor& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+
+      NodeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class EdgeIt : public Edge { 
+      const Adaptor* graph;
+    public:
+
+      EdgeIt() { }
+
+      EdgeIt(Invalid i) : Edge(i) { }
+
+      explicit EdgeIt(const Adaptor& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Edge&>(*this));
+      }
+
+      EdgeIt(const Adaptor& _graph, const Edge& e) : 
+	Edge(e), graph(&_graph) { }
+
+      EdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class OutEdgeIt : public Edge { 
+      const Adaptor* graph;
+    public:
+
+      OutEdgeIt() { }
+
+      OutEdgeIt(Invalid i) : Edge(i) { }
+
+      OutEdgeIt(const Adaptor& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstOut(*this, node);
+      }
+
+      OutEdgeIt(const Adaptor& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) {}
+
+      OutEdgeIt& operator++() { 
+	graph->nextOut(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class InEdgeIt : public Edge { 
+      const Adaptor* graph;
+    public:
+
+      InEdgeIt() { }
+
+      InEdgeIt(Invalid i) : Edge(i) { }
+
+      InEdgeIt(const Adaptor& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstIn(*this, node);
+      }
+
+      InEdgeIt(const Adaptor& _graph, const Edge& edge) : 
+	Edge(edge), graph(&_graph) {}
+
+      InEdgeIt& operator++() { 
+	graph->nextIn(*this);
+	return *this; 
+      }
+
+    };
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the source in this case) of the iterator
+    Node baseNode(const OutEdgeIt &e) const {
+      return Parent::source(e);
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the target in this case) of the
+    /// iterator
+    Node runningNode(const OutEdgeIt &e) const {
+      return Parent::target(e);
+    }
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the target in this case) of the iterator
+    Node baseNode(const InEdgeIt &e) const {
+      return Parent::target(e);
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the source in this case) of the
+    /// iterator
+    Node runningNode(const InEdgeIt &e) const {
+      return Parent::source(e);
+    }
+
+  };
+
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Extender for the UGraphAdaptors
+  template <typename _UGraph> 
+  class UGraphAdaptorExtender : public _UGraph {
+  public:
+    
+    typedef _UGraph Parent;
+    typedef _UGraph UGraph;
+    typedef UGraphAdaptorExtender Adaptor;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+    typedef typename Parent::UEdge UEdge;
+
+    // UGraph extension    
+
+    int maxId(Node) const {
+      return Parent::maxNodeId();
+    }
+
+    int maxId(Edge) const {
+      return Parent::maxEdgeId();
+    }
+
+    int maxId(UEdge) const {
+      return Parent::maxUEdgeId();
+    }
+
+    Node fromId(int id, Node) const {
+      return Parent::nodeFromId(id);
+    }
+
+    Edge fromId(int id, Edge) const {
+      return Parent::edgeFromId(id);
+    }
+
+    UEdge fromId(int id, UEdge) const {
+      return Parent::uEdgeFromId(id);
+    }
+
+    Node oppositeNode(const Node &n, const UEdge &e) const {
+      if( n == Parent::source(e))
+	return Parent::target(e);
+      else if( n == Parent::target(e))
+	return Parent::source(e);
+      else
+	return INVALID;
+    }
+
+    Edge oppositeEdge(const Edge &e) const {
+      return Parent::direct(e, !Parent::direction(e));
+    }
+
+    using Parent::direct;
+    Edge direct(const UEdge &ue, const Node &s) const {
+      return Parent::direct(ue, Parent::source(ue) == s);
+    }
+
+
+    class NodeIt : public Node { 
+      const Adaptor* graph;
+    public:
+
+      NodeIt() {}
+
+      NodeIt(Invalid i) : Node(i) { }
+
+      explicit NodeIt(const Adaptor& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Node&>(*this));
+      }
+
+      NodeIt(const Adaptor& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+
+      NodeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class EdgeIt : public Edge { 
+      const Adaptor* graph;
+    public:
+
+      EdgeIt() { }
+
+      EdgeIt(Invalid i) : Edge(i) { }
+
+      explicit EdgeIt(const Adaptor& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Edge&>(*this));
+      }
+
+      EdgeIt(const Adaptor& _graph, const Edge& e) : 
+	Edge(e), graph(&_graph) { }
+
+      EdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class OutEdgeIt : public Edge { 
+      const Adaptor* graph;
+    public:
+
+      OutEdgeIt() { }
+
+      OutEdgeIt(Invalid i) : Edge(i) { }
+
+      OutEdgeIt(const Adaptor& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstOut(*this, node);
+      }
+
+      OutEdgeIt(const Adaptor& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) {}
+
+      OutEdgeIt& operator++() { 
+	graph->nextOut(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class InEdgeIt : public Edge { 
+      const Adaptor* graph;
+    public:
+
+      InEdgeIt() { }
+
+      InEdgeIt(Invalid i) : Edge(i) { }
+
+      InEdgeIt(const Adaptor& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstIn(*this, node);
+      }
+
+      InEdgeIt(const Adaptor& _graph, const Edge& edge) : 
+	Edge(edge), graph(&_graph) {}
+
+      InEdgeIt& operator++() { 
+	graph->nextIn(*this);
+	return *this; 
+      }
+
+    };
+
+    class UEdgeIt : public Parent::UEdge { 
+      const Adaptor* graph;
+    public:
+
+      UEdgeIt() { }
+
+      UEdgeIt(Invalid i) : UEdge(i) { }
+
+      explicit UEdgeIt(const Adaptor& _graph) : graph(&_graph) {
+	_graph.first(static_cast<UEdge&>(*this));
+      }
+
+      UEdgeIt(const Adaptor& _graph, const UEdge& e) : 
+	UEdge(e), graph(&_graph) { }
+
+      UEdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+    class IncEdgeIt : public Parent::UEdge { 
+      friend class UGraphAdaptorExtender;
+      const Adaptor* graph;
+      bool direction;
+    public:
+
+      IncEdgeIt() { }
+
+      IncEdgeIt(Invalid i) : UEdge(i), direction(false) { }
+
+      IncEdgeIt(const Adaptor& _graph, const Node &n) : graph(&_graph) {
+	_graph.firstInc(static_cast<UEdge&>(*this), direction, n);
+      }
+
+      IncEdgeIt(const Adaptor& _graph, const UEdge &ue, const Node &n)
+	: graph(&_graph), UEdge(ue) {
+	direction = (_graph.source(ue) == n);
+      }
+
+      IncEdgeIt& operator++() {
+	graph->nextInc(*this, direction);
+	return *this; 
+      }
+    };
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the source in this case) of the iterator
+    Node baseNode(const OutEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the target in this case) of the
+    /// iterator
+    Node runningNode(const OutEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the target in this case) of the iterator
+    Node baseNode(const InEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the source in this case) of the
+    /// iterator
+    Node runningNode(const InEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+
+    /// Base node of the iterator
+    ///
+    /// Returns the base node of the iterator
+    Node baseNode(const IncEdgeIt &e) const {
+      return e.direction ? source(e) : target(e);
+    }
+    /// Running node of the iterator
+    ///
+    /// Returns the running node of the iterator
+    Node runningNode(const IncEdgeIt &e) const {
+      return e.direction ? target(e) : source(e);
+    }
+
+  };
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Extender for the BpUGraphAdaptors
+  template <typename Base>
+  class BpUGraphAdaptorExtender : public Base {
+  public:
+    typedef Base Parent;
+    typedef BpUGraphAdaptorExtender Graph;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::BNode BNode;
+    typedef typename Parent::ANode ANode;
+    typedef typename Parent::Edge Edge;
+    typedef typename Parent::UEdge UEdge;
+
+
+    int maxId(Node) const {
+      return Parent::maxNodeId();
+    }
+    int maxId(BNode) const {
+      return Parent::maxBNodeId();
+    }
+    int maxId(ANode) const {
+      return Parent::maxANodeId();
+    }
+    int maxId(Edge) const {
+      return Parent::maxEdgeId();
+    }
+    int maxId(UEdge) const {
+      return Parent::maxUEdgeId();
+    }
+
+
+    Node fromId(int id, Node) const {
+      return Parent::nodeFromId(id);
+    }
+    ANode fromId(int id, ANode) const {
+      return Parent::nodeFromANodeId(id);
+    }
+    BNode fromId(int id, BNode) const {
+      return Parent::nodeFromBNodeId(id);
+    }
+    Edge fromId(int id, Edge) const {
+      return Parent::edgeFromId(id);
+    }
+    UEdge fromId(int id, UEdge) const {
+      return Parent::uEdgeFromId(id);
+    }  
+  
+    class NodeIt : public Node { 
+      const Graph* graph;
+    public:
+    
+      NodeIt() { }
+    
+      NodeIt(Invalid i) : Node(INVALID) { }
+    
+      explicit NodeIt(const Graph& _graph) : graph(&_graph) {
+	graph->first(static_cast<Node&>(*this));
+      }
+
+      NodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) { }
+    
+      NodeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+    class ANodeIt : public Node { 
+      friend class BpUGraphAdaptorExtender;
+      const Graph* graph;
+    public:
+    
+      ANodeIt() { }
+    
+      ANodeIt(Invalid i) : Node(INVALID) { }
+    
+      explicit ANodeIt(const Graph& _graph) : graph(&_graph) {
+	graph->firstANode(static_cast<Node&>(*this));
+      }
+
+      ANodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+    
+      ANodeIt& operator++() { 
+	graph->nextANode(*this);
+	return *this; 
+      }
+    };
+
+    class BNodeIt : public Node { 
+      friend class BpUGraphAdaptorExtender;
+      const Graph* graph;
+    public:
+    
+      BNodeIt() { }
+    
+      BNodeIt(Invalid i) : Node(INVALID) { }
+    
+      explicit BNodeIt(const Graph& _graph) : graph(&_graph) {
+	graph->firstBNode(static_cast<Node&>(*this));
+      }
+
+      BNodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+    
+      BNodeIt& operator++() { 
+	graph->nextBNode(*this);
+	return *this; 
+      }
+    };
+
+    class EdgeIt : public Edge { 
+      friend class BpUGraphAdaptorExtender;
+      const Graph* graph;
+    public:
+    
+      EdgeIt() { }
+    
+      EdgeIt(Invalid i) : Edge(INVALID) { }
+    
+      explicit EdgeIt(const Graph& _graph) : graph(&_graph) {
+	graph->first(static_cast<Edge&>(*this));
+      }
+
+      EdgeIt(const Graph& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) { }
+    
+      EdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+    class UEdgeIt : public UEdge { 
+      friend class BpUGraphAdaptorExtender;
+      const Graph* graph;
+    public:
+    
+      UEdgeIt() { }
+    
+      UEdgeIt(Invalid i) : UEdge(INVALID) { }
+    
+      explicit UEdgeIt(const Graph& _graph) : graph(&_graph) {
+	graph->first(static_cast<UEdge&>(*this));
+      }
+
+      UEdgeIt(const Graph& _graph, const UEdge& edge) 
+	: UEdge(edge), graph(&_graph) { }
+    
+      UEdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+    };
+
+    class OutEdgeIt : public Edge { 
+      friend class BpUGraphAdaptorExtender;
+      const Graph* graph;
+    public:
+    
+      OutEdgeIt() { }
+    
+      OutEdgeIt(Invalid i) : Edge(i) { }
+    
+      OutEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	graph->firstOut(*this, node);
+      }
+    
+      OutEdgeIt(const Graph& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) {}
+    
+      OutEdgeIt& operator++() { 
+	graph->nextOut(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class InEdgeIt : public Edge { 
+      friend class BpUGraphAdaptorExtender;
+      const Graph* graph;
+    public:
+    
+      InEdgeIt() { }
+    
+      InEdgeIt(Invalid i) : Edge(i) { }
+    
+      InEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	graph->firstIn(*this, node);
+      }
+    
+      InEdgeIt(const Graph& _graph, const Edge& edge) : 
+	Edge(edge), graph(&_graph) {}
+    
+      InEdgeIt& operator++() { 
+	graph->nextIn(*this);
+	return *this; 
+      }
+
+    };
+  
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the source in this case) of the iterator
+    Node baseNode(const OutEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the target in this case) of the
+    /// iterator
+    Node runningNode(const OutEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+  
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the target in this case) of the iterator
+    Node baseNode(const InEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the source in this case) of the
+    /// iterator
+    Node runningNode(const InEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+  
+    class IncEdgeIt : public Parent::UEdge { 
+      friend class BpUGraphAdaptorExtender;
+      const Graph* graph;
+      bool direction;
+    public:
+    
+      IncEdgeIt() { }
+    
+      IncEdgeIt(Invalid i) : UEdge(i), direction(true) { }
+    
+      IncEdgeIt(const Graph& _graph, const Node &n) : graph(&_graph) {
+	graph->firstInc(*this, direction, n);
+      }
+
+      IncEdgeIt(const Graph& _graph, const UEdge &ue, const Node &n)
+	: graph(&_graph), UEdge(ue) {
+	direction = (graph->source(ue) == n);
+      }
+
+      IncEdgeIt& operator++() {
+	graph->nextInc(*this, direction);
+	return *this; 
+      }
+    };
+  
+
+    /// Base node of the iterator
+    ///
+    /// Returns the base node of the iterator
+    Node baseNode(const IncEdgeIt &e) const {
+      return e.direction ? source(e) : target(e);
+    }
+
+    /// Running node of the iterator
+    ///
+    /// Returns the running node of the iterator
+    Node runningNode(const IncEdgeIt &e) const {
+      return e.direction ? target(e) : source(e);
+    }
+
+    Node oppositeNode(const Node &n, const UEdge &e) const {
+      if( n == Parent::source(e))
+	return Parent::target(e);
+      else if( n == Parent::target(e))
+	return Parent::source(e);
+      else
+	return INVALID;
+    }
+
+    Edge oppositeEdge(const Edge &e) const {
+      return Parent::direct(e, !Parent::direction(e));
+    }
+
+    using Parent::direct;
+    Edge direct(const UEdge &ue, const Node &s) const {
+      return Parent::direct(ue, Parent::source(ue) == s);
+    }
+
+  };
+
+
+}
+
+
+#endif
Index: lemon/bits/graph_extender.h
===================================================================
--- lemon/bits/graph_extender.h	(revision 2585)
+++ lemon/bits/graph_extender.h	(revision 2585)
@@ -0,0 +1,1397 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_GRAPH_EXTENDER_H
+#define LEMON_BITS_GRAPH_EXTENDER_H
+
+#include <lemon/bits/invalid.h>
+#include <lemon/bits/utility.h>
+#include <lemon/error.h>
+
+#include <lemon/bits/map_extender.h>
+#include <lemon/bits/default_map.h>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+
+///\ingroup graphbits
+///\file
+///\brief Extenders for the graph types
+namespace lemon {
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Extender for the Graphs
+  template <typename Base>
+  class GraphExtender : public Base {
+  public:
+
+    typedef Base Parent;
+    typedef GraphExtender Graph;
+
+    // Base extensions
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+    int maxId(Node) const {
+      return Parent::maxNodeId();
+    }
+
+    int maxId(Edge) const {
+      return Parent::maxEdgeId();
+    }
+
+    Node fromId(int id, Node) const {
+      return Parent::nodeFromId(id);
+    }
+
+    Edge fromId(int id, Edge) const {
+      return Parent::edgeFromId(id);
+    }
+
+    Node oppositeNode(const Node &n, const Edge &e) const {
+      if (n == Parent::source(e))
+	return Parent::target(e);
+      else if(n==Parent::target(e))
+	return Parent::source(e);
+      else
+	return INVALID;
+    }
+
+    // Alterable extension
+
+    typedef AlterationNotifier<GraphExtender, Node> NodeNotifier;
+    typedef AlterationNotifier<GraphExtender, Edge> EdgeNotifier;
+
+
+  protected:
+
+    mutable NodeNotifier node_notifier;
+    mutable EdgeNotifier edge_notifier;
+
+  public:
+
+    NodeNotifier& notifier(Node) const {
+      return node_notifier;
+    }
+    
+    EdgeNotifier& notifier(Edge) const {
+      return edge_notifier;
+    }
+
+    class NodeIt : public Node { 
+      const Graph* graph;
+    public:
+
+      NodeIt() {}
+
+      NodeIt(Invalid i) : Node(i) { }
+
+      explicit NodeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Node&>(*this));
+      }
+
+      NodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+
+      NodeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class EdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      EdgeIt() { }
+
+      EdgeIt(Invalid i) : Edge(i) { }
+
+      explicit EdgeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Edge&>(*this));
+      }
+
+      EdgeIt(const Graph& _graph, const Edge& e) : 
+	Edge(e), graph(&_graph) { }
+
+      EdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class OutEdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      OutEdgeIt() { }
+
+      OutEdgeIt(Invalid i) : Edge(i) { }
+
+      OutEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstOut(*this, node);
+      }
+
+      OutEdgeIt(const Graph& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) {}
+
+      OutEdgeIt& operator++() { 
+	graph->nextOut(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class InEdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      InEdgeIt() { }
+
+      InEdgeIt(Invalid i) : Edge(i) { }
+
+      InEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstIn(*this, node);
+      }
+
+      InEdgeIt(const Graph& _graph, const Edge& edge) : 
+	Edge(edge), graph(&_graph) {}
+
+      InEdgeIt& operator++() { 
+	graph->nextIn(*this);
+	return *this; 
+      }
+
+    };
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (i.e. the source in this case) of the iterator
+    Node baseNode(const OutEdgeIt &e) const {
+      return Parent::source(e);
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (i.e. the target in this case) of the
+    /// iterator
+    Node runningNode(const OutEdgeIt &e) const {
+      return Parent::target(e);
+    }
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (i.e. the target in this case) of the iterator
+    Node baseNode(const InEdgeIt &e) const {
+      return Parent::target(e);
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (i.e. the source in this case) of the
+    /// iterator
+    Node runningNode(const InEdgeIt &e) const {
+      return Parent::source(e);
+    }
+
+    
+    template <typename _Value>
+    class NodeMap 
+      : public MapExtender<DefaultMap<Graph, Node, _Value> > {
+    public:
+      typedef GraphExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, Node, _Value> > Parent;
+
+      explicit NodeMap(const Graph& graph) 
+	: Parent(graph) {}
+      NodeMap(const Graph& graph, const _Value& value) 
+	: Parent(graph, value) {}
+
+      NodeMap& operator=(const NodeMap& cmap) {
+	return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+
+    };
+
+    template <typename _Value>
+    class EdgeMap 
+      : public MapExtender<DefaultMap<Graph, Edge, _Value> > {
+    public:
+      typedef GraphExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, Edge, _Value> > Parent;
+
+      explicit EdgeMap(const Graph& graph) 
+	: Parent(graph) {}
+      EdgeMap(const Graph& graph, const _Value& value) 
+	: Parent(graph, value) {}
+
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+
+    Node addNode() {
+      Node node = Parent::addNode();
+      notifier(Node()).add(node);
+      return node;
+    }
+    
+    Edge addEdge(const Node& from, const Node& to) {
+      Edge edge = Parent::addEdge(from, to);
+      notifier(Edge()).add(edge);
+      return edge;
+    }
+
+    void clear() {
+      notifier(Edge()).clear();
+      notifier(Node()).clear();
+      Parent::clear();
+    }
+
+    template <typename Graph, typename NodeRefMap, typename EdgeRefMap>
+    void build(const Graph& graph, NodeRefMap& nodeRef, EdgeRefMap& edgeRef) {
+      Parent::build(graph, nodeRef, edgeRef);
+      notifier(Node()).build();
+      notifier(Edge()).build();
+    }
+
+    void erase(const Node& node) {
+      Edge edge;
+      Parent::firstOut(edge, node);
+      while (edge != INVALID ) {
+	erase(edge);
+	Parent::firstOut(edge, node);
+      } 
+
+      Parent::firstIn(edge, node);
+      while (edge != INVALID ) {
+	erase(edge);
+	Parent::firstIn(edge, node);
+      }
+
+      notifier(Node()).erase(node);
+      Parent::erase(node);
+    }
+    
+    void erase(const Edge& edge) {
+      notifier(Edge()).erase(edge);
+      Parent::erase(edge);
+    }
+
+    GraphExtender() {
+      node_notifier.setContainer(*this);
+      edge_notifier.setContainer(*this);
+    } 
+    
+
+    ~GraphExtender() {
+      edge_notifier.clear();
+      node_notifier.clear();
+    }
+  };
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Extender for the UGraphs
+  template <typename Base> 
+  class UGraphExtender : public Base {
+  public:
+
+    typedef Base Parent;
+    typedef UGraphExtender Graph;
+
+    typedef True UndirectedTag;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+    typedef typename Parent::UEdge UEdge;
+
+    // UGraph extension    
+
+    int maxId(Node) const {
+      return Parent::maxNodeId();
+    }
+
+    int maxId(Edge) const {
+      return Parent::maxEdgeId();
+    }
+
+    int maxId(UEdge) const {
+      return Parent::maxUEdgeId();
+    }
+
+    Node fromId(int id, Node) const {
+      return Parent::nodeFromId(id);
+    }
+
+    Edge fromId(int id, Edge) const {
+      return Parent::edgeFromId(id);
+    }
+
+    UEdge fromId(int id, UEdge) const {
+      return Parent::uEdgeFromId(id);
+    }
+
+    Node oppositeNode(const Node &n, const UEdge &e) const {
+      if( n == Parent::source(e))
+	return Parent::target(e);
+      else if( n == Parent::target(e))
+	return Parent::source(e);
+      else
+	return INVALID;
+    }
+
+    Edge oppositeEdge(const Edge &e) const {
+      return Parent::direct(e, !Parent::direction(e));
+    }
+
+    using Parent::direct;
+    Edge direct(const UEdge &ue, const Node &s) const {
+      return Parent::direct(ue, Parent::source(ue) == s);
+    }
+
+    // Alterable extension
+
+    typedef AlterationNotifier<UGraphExtender, Node> NodeNotifier;
+    typedef AlterationNotifier<UGraphExtender, Edge> EdgeNotifier;
+    typedef AlterationNotifier<UGraphExtender, UEdge> UEdgeNotifier;
+
+
+  protected:
+
+    mutable NodeNotifier node_notifier;
+    mutable EdgeNotifier edge_notifier;
+    mutable UEdgeNotifier uedge_notifier;
+
+  public:
+
+    NodeNotifier& notifier(Node) const {
+      return node_notifier;
+    }
+    
+    EdgeNotifier& notifier(Edge) const {
+      return edge_notifier;
+    }
+
+    UEdgeNotifier& notifier(UEdge) const {
+      return uedge_notifier;
+    }
+
+
+
+    class NodeIt : public Node { 
+      const Graph* graph;
+    public:
+
+      NodeIt() {}
+
+      NodeIt(Invalid i) : Node(i) { }
+
+      explicit NodeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Node&>(*this));
+      }
+
+      NodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+
+      NodeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class EdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      EdgeIt() { }
+
+      EdgeIt(Invalid i) : Edge(i) { }
+
+      explicit EdgeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<Edge&>(*this));
+      }
+
+      EdgeIt(const Graph& _graph, const Edge& e) : 
+	Edge(e), graph(&_graph) { }
+
+      EdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class OutEdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      OutEdgeIt() { }
+
+      OutEdgeIt(Invalid i) : Edge(i) { }
+
+      OutEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstOut(*this, node);
+      }
+
+      OutEdgeIt(const Graph& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) {}
+
+      OutEdgeIt& operator++() { 
+	graph->nextOut(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class InEdgeIt : public Edge { 
+      const Graph* graph;
+    public:
+
+      InEdgeIt() { }
+
+      InEdgeIt(Invalid i) : Edge(i) { }
+
+      InEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	_graph.firstIn(*this, node);
+      }
+
+      InEdgeIt(const Graph& _graph, const Edge& edge) : 
+	Edge(edge), graph(&_graph) {}
+
+      InEdgeIt& operator++() { 
+	graph->nextIn(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class UEdgeIt : public Parent::UEdge { 
+      const Graph* graph;
+    public:
+
+      UEdgeIt() { }
+
+      UEdgeIt(Invalid i) : UEdge(i) { }
+
+      explicit UEdgeIt(const Graph& _graph) : graph(&_graph) {
+	_graph.first(static_cast<UEdge&>(*this));
+      }
+
+      UEdgeIt(const Graph& _graph, const UEdge& e) : 
+	UEdge(e), graph(&_graph) { }
+
+      UEdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+    class IncEdgeIt : public Parent::UEdge {
+      friend class UGraphExtender;
+      const Graph* graph;
+      bool direction;
+    public:
+
+      IncEdgeIt() { }
+
+      IncEdgeIt(Invalid i) : UEdge(i), direction(false) { }
+
+      IncEdgeIt(const Graph& _graph, const Node &n) : graph(&_graph) {
+	_graph.firstInc(*this, direction, n);
+      }
+
+      IncEdgeIt(const Graph& _graph, const UEdge &ue, const Node &n)
+	: graph(&_graph), UEdge(ue) {
+	direction = (_graph.source(ue) == n);
+      }
+
+      IncEdgeIt& operator++() {
+	graph->nextInc(*this, direction);
+	return *this; 
+      }
+    };
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the source in this case) of the iterator
+    Node baseNode(const OutEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the target in this case) of the
+    /// iterator
+    Node runningNode(const OutEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the target in this case) of the iterator
+    Node baseNode(const InEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the source in this case) of the
+    /// iterator
+    Node runningNode(const InEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+
+    /// Base node of the iterator
+    ///
+    /// Returns the base node of the iterator
+    Node baseNode(const IncEdgeIt &e) const {
+      return e.direction ? source(e) : target(e);
+    }
+    /// Running node of the iterator
+    ///
+    /// Returns the running node of the iterator
+    Node runningNode(const IncEdgeIt &e) const {
+      return e.direction ? target(e) : source(e);
+    }
+
+    // Mappable extension
+
+    template <typename _Value>
+    class NodeMap 
+      : public MapExtender<DefaultMap<Graph, Node, _Value> > {
+    public:
+      typedef UGraphExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, Node, _Value> > Parent;
+
+      NodeMap(const Graph& graph) 
+	: Parent(graph) {}
+      NodeMap(const Graph& graph, const _Value& value) 
+	: Parent(graph, value) {}
+
+      NodeMap& operator=(const NodeMap& cmap) {
+	return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+
+    };
+
+    template <typename _Value>
+    class EdgeMap 
+      : public MapExtender<DefaultMap<Graph, Edge, _Value> > {
+    public:
+      typedef UGraphExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, Edge, _Value> > Parent;
+
+      EdgeMap(const Graph& graph) 
+	: Parent(graph) {}
+      EdgeMap(const Graph& graph, const _Value& value) 
+	: Parent(graph, value) {}
+
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+
+    template <typename _Value>
+    class UEdgeMap 
+      : public MapExtender<DefaultMap<Graph, UEdge, _Value> > {
+    public:
+      typedef UGraphExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, UEdge, _Value> > Parent;
+
+      UEdgeMap(const Graph& graph) 
+	: Parent(graph) {}
+
+      UEdgeMap(const Graph& graph, const _Value& value) 
+	: Parent(graph, value) {}
+
+      UEdgeMap& operator=(const UEdgeMap& cmap) {
+	return operator=<UEdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      UEdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+
+    };
+
+    // Alteration extension
+
+    Node addNode() {
+      Node node = Parent::addNode();
+      notifier(Node()).add(node);
+      return node;
+    }
+
+    UEdge addEdge(const Node& from, const Node& to) {
+      UEdge uedge = Parent::addEdge(from, to);
+      notifier(UEdge()).add(uedge);
+      std::vector<Edge> ev;
+      ev.push_back(Parent::direct(uedge, true));
+      ev.push_back(Parent::direct(uedge, false));      
+      notifier(Edge()).add(ev);
+      return uedge;
+    }
+    
+    void clear() {
+      notifier(Edge()).clear();
+      notifier(UEdge()).clear();
+      notifier(Node()).clear();
+      Parent::clear();
+    }
+
+    template <typename Graph, typename NodeRefMap, typename UEdgeRefMap>
+    void build(const Graph& graph, NodeRefMap& nodeRef, 
+               UEdgeRefMap& uEdgeRef) {
+      Parent::build(graph, nodeRef, uEdgeRef);
+      notifier(Node()).build();
+      notifier(UEdge()).build();
+      notifier(Edge()).build();
+    }
+
+    void erase(const Node& node) {
+      Edge edge;
+      Parent::firstOut(edge, node);
+      while (edge != INVALID ) {
+	erase(edge);
+	Parent::firstOut(edge, node);
+      } 
+
+      Parent::firstIn(edge, node);
+      while (edge != INVALID ) {
+	erase(edge);
+	Parent::firstIn(edge, node);
+      }
+
+      notifier(Node()).erase(node);
+      Parent::erase(node);
+    }
+
+    void erase(const UEdge& uedge) {
+      std::vector<Edge> ev;
+      ev.push_back(Parent::direct(uedge, true));
+      ev.push_back(Parent::direct(uedge, false));      
+      notifier(Edge()).erase(ev);
+      notifier(UEdge()).erase(uedge);
+      Parent::erase(uedge);
+    }
+
+    UGraphExtender() {
+      node_notifier.setContainer(*this); 
+      edge_notifier.setContainer(*this);
+      uedge_notifier.setContainer(*this);
+    } 
+
+    ~UGraphExtender() {
+      uedge_notifier.clear();
+      edge_notifier.clear();
+      node_notifier.clear(); 
+    } 
+
+  };
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Extender for the BpUGraphs
+  template <typename Base>
+  class BpUGraphExtender : public Base {
+  public:
+
+    typedef Base Parent;
+    typedef BpUGraphExtender Graph;
+
+    typedef True UndirectedTag;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::ANode ANode;
+    typedef typename Parent::BNode BNode;
+    typedef typename Parent::Edge Edge;
+    typedef typename Parent::UEdge UEdge;
+
+
+    Node oppositeNode(const Node& node, const UEdge& edge) const {
+      return Parent::aNode(edge) == node ? 
+	Parent::bNode(edge) : Parent::aNode(edge);
+    }
+
+    using Parent::direct;
+    Edge direct(const UEdge& edge, const Node& node) const {
+      return Parent::direct(edge, node == Parent::source(edge));
+    }
+
+    Edge oppositeEdge(const Edge& edge) const {
+      return direct(edge, !Parent::direction(edge));
+    }
+    
+    int maxId(Node) const {
+      return Parent::maxNodeId();
+    }
+    int maxId(BNode) const {
+      return Parent::maxBNodeId();
+    }
+    int maxId(ANode) const {
+      return Parent::maxANodeId();
+    }
+    int maxId(Edge) const {
+      return Parent::maxEdgeId();
+    }
+    int maxId(UEdge) const {
+      return Parent::maxUEdgeId();
+    }
+
+
+    Node fromId(int id, Node) const {
+      return Parent::nodeFromId(id);
+    }
+    ANode fromId(int id, ANode) const {
+      return Parent::nodeFromANodeId(id);
+    }
+    BNode fromId(int id, BNode) const {
+      return Parent::nodeFromBNodeId(id);
+    }
+    Edge fromId(int id, Edge) const {
+      return Parent::edgeFromId(id);
+    }
+    UEdge fromId(int id, UEdge) const {
+      return Parent::uEdgeFromId(id);
+    }  
+  
+    typedef AlterationNotifier<BpUGraphExtender, ANode> ANodeNotifier;
+    typedef AlterationNotifier<BpUGraphExtender, BNode> BNodeNotifier;
+    typedef AlterationNotifier<BpUGraphExtender, Node> NodeNotifier;
+    typedef AlterationNotifier<BpUGraphExtender, Edge> EdgeNotifier;
+    typedef AlterationNotifier<BpUGraphExtender, UEdge> UEdgeNotifier;
+
+  protected:
+
+    mutable ANodeNotifier anode_notifier;
+    mutable BNodeNotifier bnode_notifier;
+    mutable NodeNotifier node_notifier;
+    mutable EdgeNotifier edge_notifier;
+    mutable UEdgeNotifier uedge_notifier;
+
+  public:
+
+    NodeNotifier& notifier(Node) const {
+      return node_notifier;
+    }
+
+    ANodeNotifier& notifier(ANode) const {
+      return anode_notifier;
+    }
+
+    BNodeNotifier& notifier(BNode) const {
+      return bnode_notifier;
+    }
+
+    EdgeNotifier& notifier(Edge) const {
+      return edge_notifier;
+    }
+
+    UEdgeNotifier& notifier(UEdge) const {
+      return uedge_notifier;
+    }
+
+    class NodeIt : public Node { 
+      const Graph* graph;
+    public:
+    
+      NodeIt() { }
+    
+      NodeIt(Invalid i) : Node(INVALID) { }
+    
+      explicit NodeIt(const Graph& _graph) : graph(&_graph) {
+	graph->first(static_cast<Node&>(*this));
+      }
+
+      NodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) { }
+    
+      NodeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+    class ANodeIt : public Node { 
+      friend class BpUGraphExtender;
+      const Graph* graph;
+    public:
+    
+      ANodeIt() { }
+    
+      ANodeIt(Invalid i) : Node(INVALID) { }
+    
+      explicit ANodeIt(const Graph& _graph) : graph(&_graph) {
+	graph->firstANode(static_cast<Node&>(*this));
+      }
+
+      ANodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+    
+      ANodeIt& operator++() { 
+	graph->nextANode(*this);
+	return *this; 
+      }
+    };
+
+    class BNodeIt : public Node { 
+      friend class BpUGraphExtender;
+      const Graph* graph;
+    public:
+    
+      BNodeIt() { }
+    
+      BNodeIt(Invalid i) : Node(INVALID) { }
+    
+      explicit BNodeIt(const Graph& _graph) : graph(&_graph) {
+	graph->firstBNode(static_cast<Node&>(*this));
+      }
+
+      BNodeIt(const Graph& _graph, const Node& node) 
+	: Node(node), graph(&_graph) {}
+    
+      BNodeIt& operator++() { 
+	graph->nextBNode(*this);
+	return *this; 
+      }
+    };
+
+    class EdgeIt : public Edge { 
+      friend class BpUGraphExtender;
+      const Graph* graph;
+    public:
+    
+      EdgeIt() { }
+    
+      EdgeIt(Invalid i) : Edge(INVALID) { }
+    
+      explicit EdgeIt(const Graph& _graph) : graph(&_graph) {
+	graph->first(static_cast<Edge&>(*this));
+      }
+
+      EdgeIt(const Graph& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) { }
+    
+      EdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+
+    };
+
+    class UEdgeIt : public UEdge { 
+      friend class BpUGraphExtender;
+      const Graph* graph;
+    public:
+    
+      UEdgeIt() { }
+    
+      UEdgeIt(Invalid i) : UEdge(INVALID) { }
+    
+      explicit UEdgeIt(const Graph& _graph) : graph(&_graph) {
+	graph->first(static_cast<UEdge&>(*this));
+      }
+
+      UEdgeIt(const Graph& _graph, const UEdge& edge) 
+	: UEdge(edge), graph(&_graph) { }
+    
+      UEdgeIt& operator++() { 
+	graph->next(*this);
+	return *this; 
+      }
+    };
+
+    class OutEdgeIt : public Edge { 
+      friend class BpUGraphExtender;
+      const Graph* graph;
+    public:
+    
+      OutEdgeIt() { }
+    
+      OutEdgeIt(Invalid i) : Edge(i) { }
+    
+      OutEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	graph->firstOut(*this, node);
+      }
+    
+      OutEdgeIt(const Graph& _graph, const Edge& edge) 
+	: Edge(edge), graph(&_graph) {}
+    
+      OutEdgeIt& operator++() { 
+	graph->nextOut(*this);
+	return *this; 
+      }
+
+    };
+
+
+    class InEdgeIt : public Edge { 
+      friend class BpUGraphExtender;
+      const Graph* graph;
+    public:
+    
+      InEdgeIt() { }
+    
+      InEdgeIt(Invalid i) : Edge(i) { }
+    
+      InEdgeIt(const Graph& _graph, const Node& node) 
+	: graph(&_graph) {
+	graph->firstIn(*this, node);
+      }
+    
+      InEdgeIt(const Graph& _graph, const Edge& edge) : 
+	Edge(edge), graph(&_graph) {}
+    
+      InEdgeIt& operator++() { 
+	graph->nextIn(*this);
+	return *this; 
+      }
+
+    };
+  
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the source in this case) of the iterator
+    Node baseNode(const OutEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the target in this case) of the
+    /// iterator
+    Node runningNode(const OutEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+  
+    /// \brief Base node of the iterator
+    ///
+    /// Returns the base node (ie. the target in this case) of the iterator
+    Node baseNode(const InEdgeIt &e) const {
+      return Parent::target(static_cast<const Edge&>(e));
+    }
+    /// \brief Running node of the iterator
+    ///
+    /// Returns the running node (ie. the source in this case) of the
+    /// iterator
+    Node runningNode(const InEdgeIt &e) const {
+      return Parent::source(static_cast<const Edge&>(e));
+    }
+  
+    class IncEdgeIt : public Parent::UEdge { 
+      friend class BpUGraphExtender;
+      const Graph* graph;
+      bool direction;
+    public:
+    
+      IncEdgeIt() { }
+    
+      IncEdgeIt(Invalid i) : UEdge(i), direction(true) { }
+    
+      IncEdgeIt(const Graph& _graph, const Node &n) : graph(&_graph) {
+	graph->firstInc(*this, direction, n);
+      }
+
+      IncEdgeIt(const Graph& _graph, const UEdge &ue, const Node &n)
+	: graph(&_graph), UEdge(ue) {
+	direction = (graph->source(ue) == n);
+      }
+
+      IncEdgeIt& operator++() {
+	graph->nextInc(*this, direction);
+	return *this; 
+      }
+    };
+  
+
+    /// Base node of the iterator
+    ///
+    /// Returns the base node of the iterator
+    Node baseNode(const IncEdgeIt &e) const {
+      return e.direction ? source(e) : target(e);
+    }
+
+    /// Running node of the iterator
+    ///
+    /// Returns the running node of the iterator
+    Node runningNode(const IncEdgeIt &e) const {
+      return e.direction ? target(e) : source(e);
+    }
+
+    template <typename _Value>
+    class ANodeMap 
+      : public MapExtender<DefaultMap<Graph, ANode, _Value> > {
+    public:
+      typedef BpUGraphExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, ANode, _Value> > Parent;
+    
+      ANodeMap(const Graph& graph) 
+	: Parent(graph) {}
+      ANodeMap(const Graph& graph, const _Value& value) 
+	: Parent(graph, value) {}
+    
+      ANodeMap& operator=(const ANodeMap& cmap) {
+	return operator=<ANodeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      ANodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    
+    };
+
+    template <typename _Value>
+    class BNodeMap 
+      : public MapExtender<DefaultMap<Graph, BNode, _Value> > {
+    public:
+      typedef BpUGraphExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, BNode, _Value> > Parent;
+    
+      BNodeMap(const Graph& graph) 
+	: Parent(graph) {}
+      BNodeMap(const Graph& graph, const _Value& value) 
+	: Parent(graph, value) {}
+    
+      BNodeMap& operator=(const BNodeMap& cmap) {
+	return operator=<BNodeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      BNodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    
+    };
+
+  public:
+
+    template <typename _Value>
+    class NodeMap {
+    public:
+      typedef BpUGraphExtender Graph;
+
+      typedef Node Key;
+      typedef _Value Value;
+
+      /// The reference type of the map;
+      typedef typename ANodeMap<_Value>::Reference Reference;
+      /// The const reference type of the map;
+      typedef typename ANodeMap<_Value>::ConstReference ConstReference;
+
+      typedef True ReferenceMapTag;
+
+      NodeMap(const Graph& _graph) 
+	: graph(_graph), aNodeMap(_graph), bNodeMap(_graph) {}
+      NodeMap(const Graph& _graph, const _Value& _value) 
+	: graph(_graph), aNodeMap(_graph, _value), bNodeMap(_graph, _value) {}
+
+      NodeMap& operator=(const NodeMap& cmap) {
+	return operator=<NodeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+	checkConcept<concepts::ReadMap<Node, _Value>, CMap>();
+        aNodeMap = cmap;
+        bNodeMap = cmap;
+        return *this;
+      }
+
+      ConstReference operator[](const Key& node) const {
+	if (Parent::aNode(node)) {
+	  return aNodeMap[node];
+	} else {
+	  return bNodeMap[node];
+	}
+      } 
+
+      Reference operator[](const Key& node) {
+	if (Parent::aNode(node)) {
+	  return aNodeMap[node];
+	} else {
+	  return bNodeMap[node];
+	}
+      }
+
+      void set(const Key& node, const Value& value) {
+	if (Parent::aNode(node)) {
+	  aNodeMap.set(node, value);
+	} else {
+	  bNodeMap.set(node, value);
+	}
+      }
+
+      class MapIt : public NodeIt {
+      public:
+
+        typedef NodeIt Parent;
+        
+        explicit MapIt(NodeMap& _map) 
+          : Parent(_map.graph), map(_map) {}
+        
+        typename MapTraits<NodeMap>::ConstReturnValue operator*() const {
+          return map[*this];
+        }
+        
+        typename MapTraits<NodeMap>::ReturnValue operator*() {
+          return map[*this];
+        }
+        
+        void set(const Value& value) {
+          map.set(*this, value);
+        }
+
+      private:
+        NodeMap& map;
+      };
+
+      class ConstMapIt : public NodeIt {
+      public:
+
+        typedef NodeIt Parent;
+        
+        explicit ConstMapIt(const NodeMap& _map) 
+          : Parent(_map.graph), map(_map) {}
+        
+        typename MapTraits<NodeMap>::ConstReturnValue operator*() const {
+          return map[*this];
+        }
+        
+      private:
+        const NodeMap& map;
+      };
+
+      class ItemIt : public NodeIt {
+      public:
+
+        typedef NodeIt Parent;
+
+        explicit ItemIt(const NodeMap& _map)
+          : Parent(_map.graph) {}
+        
+      };
+      
+    private:
+      const Graph& graph;
+      ANodeMap<_Value> aNodeMap;
+      BNodeMap<_Value> bNodeMap;
+    };
+    
+
+    template <typename _Value>
+    class EdgeMap 
+      : public MapExtender<DefaultMap<Graph, Edge, _Value> > {
+    public:
+      typedef BpUGraphExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, Edge, _Value> > Parent;
+    
+      EdgeMap(const Graph& graph) 
+	: Parent(graph) {}
+      EdgeMap(const Graph& graph, const _Value& value) 
+	: Parent(graph, value) {}
+    
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class UEdgeMap 
+      : public MapExtender<DefaultMap<Graph, UEdge, _Value> > {
+    public:
+      typedef BpUGraphExtender Graph;
+      typedef MapExtender<DefaultMap<Graph, UEdge, _Value> > Parent;
+    
+      UEdgeMap(const Graph& graph) 
+	: Parent(graph) {}
+      UEdgeMap(const Graph& graph, const _Value& value) 
+	: Parent(graph, value) {}
+    
+      UEdgeMap& operator=(const UEdgeMap& cmap) {
+	return operator=<UEdgeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      UEdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+  
+    Node addANode() {
+      Node node = Parent::addANode();
+      notifier(ANode()).add(node);
+      notifier(Node()).add(node);
+      return node;
+    }
+
+    Node addBNode() {
+      Node node = Parent::addBNode();
+      notifier(BNode()).add(node);
+      notifier(Node()).add(node);
+      return node;
+    }
+  
+    UEdge addEdge(const Node& s, const Node& t) {
+      UEdge uedge = Parent::addEdge(s, t);
+      notifier(UEdge()).add(uedge);
+    
+      std::vector<Edge> ev;
+      ev.push_back(Parent::direct(uedge, true));
+      ev.push_back(Parent::direct(uedge, false));
+      notifier(Edge()).add(ev);
+    
+      return uedge;
+    }
+
+    void clear() {
+      notifier(Edge()).clear();
+      notifier(UEdge()).clear();
+      notifier(Node()).clear();
+      notifier(BNode()).clear();
+      notifier(ANode()).clear();
+      Parent::clear();
+    }
+
+    template <typename Graph, typename ANodeRefMap, 
+              typename BNodeRefMap, typename UEdgeRefMap>
+    void build(const Graph& graph, ANodeRefMap& aNodeRef, 
+               BNodeRefMap& bNodeRef, UEdgeRefMap& uEdgeRef) {
+      Parent::build(graph, aNodeRef, bNodeRef, uEdgeRef);
+      notifier(ANode()).build();
+      notifier(BNode()).build();
+      notifier(Node()).build();
+      notifier(UEdge()).build();
+      notifier(Edge()).build();
+    }
+
+    void erase(const Node& node) {
+      UEdge uedge;
+      if (Parent::aNode(node)) {
+        Parent::firstFromANode(uedge, node);
+        while (uedge != INVALID) {
+          erase(uedge);
+          Parent::firstFromANode(uedge, node);
+        }
+        notifier(ANode()).erase(node);
+      } else {
+        Parent::firstFromBNode(uedge, node);
+        while (uedge != INVALID) {
+          erase(uedge);
+          Parent::firstFromBNode(uedge, node);
+        }
+        notifier(BNode()).erase(node);
+      }
+
+      notifier(Node()).erase(node);
+      Parent::erase(node);
+    }
+    
+    void erase(const UEdge& uedge) {
+      std::vector<Edge> ev;
+      ev.push_back(Parent::direct(uedge, true));
+      ev.push_back(Parent::direct(uedge, false));
+      notifier(Edge()).erase(ev);
+      notifier(UEdge()).erase(uedge);
+      Parent::erase(uedge);
+    }
+
+
+    BpUGraphExtender() {
+      anode_notifier.setContainer(*this); 
+      bnode_notifier.setContainer(*this); 
+      node_notifier.setContainer(*this); 
+      edge_notifier.setContainer(*this); 
+      uedge_notifier.setContainer(*this);
+    } 
+
+    ~BpUGraphExtender() {
+      uedge_notifier.clear();
+      edge_notifier.clear(); 
+      node_notifier.clear(); 
+      anode_notifier.clear(); 
+      bnode_notifier.clear(); 
+    }
+
+    Edge findEdge(Node u, Node v, Edge prev = INVALID) const {
+      UEdge uedge = Parent::findUEdge(u, v, prev);
+      if (uedge != INVALID) {
+        return Parent::direct(uedge, Parent::aNode(u));
+      } else {
+        return INVALID;
+      }
+    }
+
+  };
+
+}
+
+#endif
Index: lemon/bits/invalid.h
===================================================================
--- lemon/bits/invalid.h	(revision 2655)
+++ lemon/bits/invalid.h	(revision 2553)
@@ -3,5 +3,5 @@
  * This file is a part of LEMON, a generic C++ optimization library
  *
- * Copyright (C) 2003-2006
+ * Copyright (C) 2003-2008
  * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
  * (Egervary Research Group on Combinatorial Optimization, EGRES).
Index: lemon/bits/item_reader.h
===================================================================
--- lemon/bits/item_reader.h	(revision 2553)
+++ lemon/bits/item_reader.h	(revision 2553)
@@ -0,0 +1,685 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup item_io
+/// \file
+/// \brief Item reader bits for lemon input.
+
+#ifndef LEMON_BITS_ITEM_READER_H
+#define LEMON_BITS_ITEM_READER_H
+
+#include <iostream>
+#include <string>
+
+#include <vector>
+#include <deque>
+#include <list>
+#include <set>
+#include <map>
+
+#include <lemon/error.h>
+
+namespace lemon {
+  
+  template <typename Value>
+  class DefaultReader;
+
+  /// \ingroup item_io
+  ///
+  /// \brief Reader class for unformatted strings.
+  ///
+  /// Reader class for unformatted strings. This class want to be
+  /// a general reader type which can read the most 
+  ///
+  /// \author Balazs Dezso
+  class UnformattedReader {
+  public:
+    /// \brief The value type of reader.
+    ///
+    /// The value type of reader.
+    typedef std::string Value;
+    
+    /// \brief Constructor for the reader.
+    ///
+    /// Constructor for the reader.
+    UnformattedReader() {} 
+    
+    /// \brief Reads an unformatted string from the given stream.
+    ///
+    /// Reads an unformatted string from the given stream.
+    void read(std::istream& is, std::string& value) const {
+      char c;
+      value.clear();
+      is >> std::ws;
+      while (is.get(c) && !whiteSpace(c)) {
+        processChar(c, is, value);
+      }
+    }
+
+  private:
+
+    void processChar(char c, std::istream& is, Value& value) const {
+      switch (c) {
+      case '(':
+        is.putback(c);
+        readParsed('(', ')', is, value);
+        break;
+      case '[':
+        is.putback(c);
+        readParsed('[', ']', is, value);
+        break;
+      case '{':
+        is.putback(c);
+        readParsed('{', '}', is, value);
+        break;
+      case '/':
+        is.putback(c);
+        readParsed('/', '/', is, value);
+        break;
+      case '\"':
+        is.putback(c);
+        readQuoted('\"', is, value);
+        break;
+      case '\'':
+        is.putback(c);
+        readQuoted('\'', is, value);
+        break;
+      default:
+        value += c;
+        break;
+      }
+    }
+
+    void readParsed(char open, char close, 
+                    std::istream& is, Value& value) const {
+      char c;
+      if (!is.get(c) || c != open)
+	throw DataFormatError("Unformatted string format error");
+      value += c;
+      while (is.get(c) && c != close) {
+        processChar(c, is, value);
+      }
+      if (!is) 
+        throw DataFormatError("Unformatted string format error");
+      value += c;      
+    }
+
+    void readQuoted(char quote, std::istream& is, Value& value) const {
+      char c;
+      bool esc = false;
+      if (!is.get(c) || c != quote)
+	throw DataFormatError("Unformatted string format error");
+      value += c;
+      while (is.get(c) && (c != quote || esc)) {
+        if (c == '\\') esc = !esc;
+        else esc = false;
+        value += c;
+      }
+      if (!is) 
+        throw DataFormatError("Unformatted string format error");
+      value += c;
+    }
+
+
+
+    static bool whiteSpace(char c) {
+      return c == ' ' || c == '\t' || c == '\v' || 
+        c == '\n' || c == '\r' || c == '\f'; 
+    }
+
+    
+  };
+
+  /// \ingroup item_io
+  ///
+  /// \brief Reader class for quoted strings.
+  ///
+  /// Reader class for quoted strings. It can process the escape
+  /// sequences in the string.
+  ///
+  /// \author Balazs Dezso
+  class QuotedStringReader {
+    friend class QuotedCharReader;
+  public:
+    /// \brief The value type of reader.
+    ///
+    /// The value type of reader.
+    typedef std::string Value;
+    
+    /// \brief Constructor for the reader.
+    ///
+    /// Constructor for the reader. If the given parameter is true
+    /// the reader processes the escape sequences.
+    QuotedStringReader(bool _escaped = true) 
+      : escaped(_escaped) {}
+    
+    /// \brief Reads a quoted string from the given stream.
+    ///
+    /// Reads a quoted string from the given stream.
+    void read(std::istream& is, std::string& value) const {
+      char c;
+      value.clear();
+      is >> std::ws;
+      if (!is.get(c) || (c != '\"' && c != '\'')) 
+	throw DataFormatError("Quoted format error");
+      char quote = c;
+      while (is.get(c) && c != quote) {
+	if (escaped && c == '\\') {
+	  value += readEscape(is);
+	} else {
+	  value += c;
+	}
+      }
+      if (!is) throw DataFormatError("Quoted format error");
+    }
+
+  private:
+    
+    static char readEscape(std::istream& is) {
+      char c;
+      switch (is.get(c), c) {
+      case '\\':
+	return '\\';
+      case '\"':
+	return '\"';
+      case '\'':
+	return '\'';
+      case '\?':
+	return '\?';
+      case 'a':
+	return '\a';
+      case 'b':
+	return '\b';
+      case 'f':
+	return '\f';
+      case 'n':
+	return '\n';
+      case 'r':
+	return '\r';
+      case 't':
+	return '\t';
+      case 'v':
+	return '\v';
+      case 'x':
+	{
+	  int code;
+	  if (!is.get(c) || !isHex(c)) 
+	    throw DataFormatError("Escape format error");
+	  else if (code = valueHex(c), !is.get(c) || !isHex(c)) is.putback(c);
+	  else code = code * 16 + valueHex(c);
+	  return code;
+	}
+      default:
+	{
+	  int code;
+	  if (!isOct(c)) 
+	    throw DataFormatError("Escape format error");
+	  else if (code = valueOct(c), !is.get(c) || !isOct(c)) 
+	    is.putback(c);
+	  else if (code = code * 8 + valueOct(c), !is.get(c) || !isOct(c)) 
+	    is.putback(c);
+	  else code = code * 8 + valueOct(c);
+	  return code;
+	}	      
+      } 
+    }
+
+    static bool isOct(char c) {
+      return '0' <= c && c <='7'; 
+    }
+    
+    static int valueOct(char c) {
+      return c - '0';
+    }
+
+   static bool isHex(char c) {
+      return ('0' <= c && c <= '9') || 
+	('a' <= c && c <= 'z') || 
+	('A' <= c && c <= 'Z'); 
+    }
+    
+    static int valueHex(char c) {
+      if ('0' <= c && c <= '9') return c - '0';
+      if ('a' <= c && c <= 'z') return c - 'a' + 10;
+      return c - 'A' + 10;
+    }
+
+    bool escaped;
+  };
+
+  /// \ingroup item_io
+  ///
+  /// \brief Reader class for quoted strings.
+  ///
+  /// Reader class for quoted strings. It can process the escape
+  /// sequences in the string.
+  ///
+  /// \author Balazs Dezso
+  class QuotedCharReader {
+  public:
+    /// \brief The value type of reader.
+    ///
+    /// The value type of reader.
+    typedef char Value;
+    
+    /// \brief Constructor for the reader.
+    ///
+    /// Constructor for the reader. If the given parameter is true
+    /// the reader processes the escape sequences.
+    QuotedCharReader(bool _escaped = true) 
+      : escaped(_escaped) {}
+    
+    /// \brief Reads a quoted string from the given stream.
+    ///
+    /// Reads a quoted string from the given stream.
+    void read(std::istream& is, char& value) const {
+      char c;
+      is >> std::ws;
+      if (!is.get(c) || c != '\'') 
+	throw DataFormatError("Quoted format error");
+      if (!is.get(c)) 
+        throw DataFormatError("Quoted format error");
+      if (escaped && c == '\\') {
+        value = QuotedStringReader::readEscape(is);
+      } else {
+        value = c;
+      }
+      if (!is.get(c) || c != '\'') 
+	throw DataFormatError("Quoted format error");
+    }
+
+  private:
+    bool escaped;
+  };
+
+  /// \ingroup item_io
+  /// \brief Reader for standard containers.
+  ///
+  /// Reader for back insertable standard containers. The representation
+  /// of the container is the values enumerated between an open and a
+  /// close parse. 
+  ///
+  /// \author Balazs Dezso
+  template <
+    typename _Container, 
+    typename _ItemReader = DefaultReader<typename _Container::value_type> 
+  >
+  class PushBackReader {
+  public:
+    typedef _Container Value;
+    typedef _ItemReader ItemReader;
+
+  private:
+
+    ItemReader item_reader;
+
+  public:
+
+    /// \brief Constructor for InsertReader
+    ///
+    /// Constructor for InsertReader
+    PushBackReader(const ItemReader& _item_reader = ItemReader())
+      : item_reader(_item_reader) {}
+
+    /// \brief Reads the values into the container from the given stream.
+    ///
+    /// Reads the values into the container from the given stream.
+    void read(std::istream& is, Value& value) const {
+      char c;
+      if (!(is >> c) || c != '(') 
+	throw DataFormatError("PushBackReader format error");
+      while (is >> c && c != ')') {
+	is.putback(c);
+	typename ItemReader::Value item;
+	item_reader.read(is, item);
+	value.push_back(item);
+      }
+      if (!is) throw DataFormatError("PushBackReader format error");
+    }
+
+  };
+
+  /// \ingroup item_io
+  ///
+  /// \brief Reader for standard containers.
+  ///
+  /// Reader for insertable standard containers. The representation
+  /// of the container is the values enumerated between an open and a
+  /// close parse. 
+  ///
+  /// \author Balazs Dezso
+  template <
+    typename _Container, 
+    typename _ItemReader = DefaultReader<typename _Container::value_type> 
+  >
+  class InsertReader {
+  public:
+    typedef _Container Value;
+    typedef _ItemReader ItemReader;
+
+  private:
+
+    ItemReader item_reader;
+
+  public:
+
+    /// \brief Constructor for InsertReader
+    ///
+    /// Constructor for InsertReader
+    InsertReader(const ItemReader& _item_reader = ItemReader())
+      : item_reader(_item_reader) {}
+
+    /// \brief Reads the values into the container from the given stream.
+    ///
+    /// Reads the values into the container from the given stream.
+    void read(std::istream& is, Value& value) const {
+      char c;
+      if (!(is >> c) || c != '(') 
+	throw DataFormatError("InsertReader format error");
+      while (is >> c && c != ')') {
+	is.putback(c);
+	typename ItemReader::Value item;
+	item_reader.read(is, item);
+	value.insert(item);
+      }
+      if (!is) throw DataFormatError("PushBackReader format error");
+    }
+
+  };
+
+  /// \ingroup item_io
+  /// \brief Reader for parsed string.
+  ///
+  /// Reader for parsed strings. You can define the open and close
+  /// parse characters. It reads from the input a character sequence
+  /// which is right parsed.
+  ///
+  /// \author Balazs Dezso
+  class ParsedStringReader {
+  public:
+    typedef std::string Value;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for ParsedStringReader. You can give as parameter
+    /// the open and close parse characters.
+    ParsedStringReader(char _open = '(', char _close = ')')
+      : open(_open), close(_close) {}
+    
+    
+    /// \brief Reads the parsed string from the given stream.
+    ///
+    /// Reads the parsed string from the given stream.
+    void read(std::istream& is, Value& value) const {
+      char c;
+      value.clear();
+      if (!(is >> c) || c != open) {
+	throw DataFormatError("ParsedStringReader format error");
+      }
+      value += c;
+      int counter = 1;
+      while (counter > 0 && is >> c) {
+	if (c == close) {
+	  --counter;
+	} else if (c == open) {
+	  ++counter;
+	}
+	value += c;
+      }
+      if (!is) {
+	throw DataFormatError("ParsedStrinReader format error");
+      }
+    }
+
+  private:
+    char open, close;
+
+  };
+
+  /// \ingroup item_io
+  /// \brief Reader for read the whole line.
+  ///
+  /// Reader for read the whole line.
+  ///
+  /// \author Balazs Dezso
+  class LineReader {
+  public:
+    typedef std::string Value;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for the LineReader. If the given parameter is
+    /// true then the spaces before the first not space character are
+    /// skipped.
+    LineReader(bool _skipSpaces = true) : skipSpaces(_skipSpaces) {}
+    
+    /// \brief Reads the line from the given stream.
+    ///
+    /// Reads the line from the given stream.
+    void read(std::istream& is, Value& value) const {
+      if (skipSpaces) is >> std::ws;
+      if (!getline(is, value)) {
+	throw DataFormatError("LineReader format error");
+      }
+    }
+  private:
+    bool skipSpaces;
+  };
+
+  /// \ingroup item_io
+  /// \brief Reader for std::pair.
+  ///
+  /// Reader for std::pair.
+  ///
+  /// \author Balazs Dezso
+  template <typename _Pair, 
+	    typename _FirstReader = 
+	    DefaultReader<typename _Pair::first_type>,
+	    typename _SecondReader = 
+	    DefaultReader<typename _Pair::second_type> >
+  class PairReader {
+  public:
+    typedef _Pair Value;
+
+    typedef _FirstReader FirstReader;
+    typedef _SecondReader SecondReader;
+
+  private:
+
+    FirstReader first_reader;
+    SecondReader second_reader;
+
+  public:
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor for the PairReader.
+    PairReader(const FirstReader& _first_reader = FirstReader(), 
+	       const SecondReader& _second_reader = SecondReader()) 
+      : first_reader(_first_reader), second_reader(_second_reader) {}
+    
+    /// \brief Reads the pair from the given stream.
+    ///
+    /// Reads the pair from the given stream.
+    void read(std::istream& is, Value& value) const {
+      char c;
+      if (!(is >> c) || c != '(') {
+	throw DataFormatError("PairReader format error");
+      }
+      first_reader.read(is, value.first);
+      if (!(is >> c) || c != '=') {
+	throw DataFormatError("PairReader format error");
+      }
+      if (!(is >> c) || c != '>') {
+	throw DataFormatError("PairReader format error");
+      }
+      second_reader.read(is, value.second);
+      if (!(is >> c) || c != ')') {
+	throw DataFormatError("PairReader format error");
+      }
+    }
+  };
+
+  /// \ingroup item_io
+  /// 
+  /// \brief The default item reader template class.
+  ///
+  /// The default item reader template class. If some section reader
+  /// needs to read a value from a stream it will give the default way for it.
+  ///
+  /// \author Balazs Dezso
+  template <typename _Value>
+  class DefaultReader {
+  public:
+    /// The value type.
+    typedef _Value Value;
+    /// \brief Reads a value from the given stream.
+    ///
+    /// Reads a value from the given stream.
+    void read(std::istream& is, Value& value) const {
+      if (!(is >> value)) 
+	throw DataFormatError("DefaultReader format error");
+    }
+  };
+
+  template <>
+  class DefaultReader<std::string> {
+  public:
+    typedef std::string Value;
+    
+    void read(std::istream& is, Value& value) const {
+      char c;
+      if (!(is >> std::ws >> c)) 
+        throw DataFormatError("DefaultReader<string> format error");
+      is.putback(c);
+      switch (c) {
+      case '\"':
+	QuotedStringReader().read(is, value);
+	break;
+      default:
+        UnformattedReader().read(is, value);
+	break;
+      }
+    }
+    
+  };
+
+  template <>
+  class DefaultReader<char> {
+  public:
+    typedef char Value;
+    
+    void read(std::istream& is, Value& value) const {
+      char c;
+      if (!(is >> std::ws >> c))
+        throw DataFormatError("DefaultReader<char> format error");
+      is.putback(c);
+      switch (c) {
+      case '\'':
+	QuotedCharReader().read(is, value);
+	break;
+      default:
+        { 
+          int temp;          
+          if (!(is >> temp)) 
+            throw DataFormatError("DefaultReader<char> format error");
+          value = static_cast<char>(temp);
+          break;
+        }
+      }
+    }    
+  };
+
+  template <>
+  class DefaultReader<bool> {
+  public:
+    typedef bool Value;
+    
+    void read(std::istream& is, Value& value) const {
+      std::string rep;
+      if (!(is >> rep))
+        throw DataFormatError("DefaultReader<bool> format error");
+      if (rep == "true" || rep == "t" || rep == "1") {
+        value = true;
+      } else if (rep == "false" || rep == "f" || rep == "0") {
+        value = false;
+      } else throw DataFormatError("DefaultReader<bool> format error");
+    }    
+  };
+
+  template <typename Item>
+  class DefaultReader<std::vector<Item> > 
+    : public PushBackReader<std::vector<Item> > {};
+
+  template <typename Item>
+  class DefaultReader<std::deque<Item> > 
+    : public PushBackReader<std::deque<Item> > {};
+
+  template <typename Item>
+  class DefaultReader<std::list<Item> > 
+    : public PushBackReader<std::list<Item> > {};
+
+  template <typename Item>
+  class DefaultReader<std::set<Item> > 
+    : public InsertReader<std::set<Item> > {};
+
+  template <typename Key, typename Value>
+  class DefaultReader<std::map<Key, Value> > 
+    : public InsertReader<std::map<Key, Value>,
+			  DefaultReader<std::pair<Key, Value> > > {};
+
+  template <typename Item>
+  class DefaultReader<std::multiset<Item> > 
+    : public InsertReader<std::multiset<Item> > {};
+
+  template <typename Key, typename Value>
+  class DefaultReader<std::multimap<Key, Value> > 
+    : public InsertReader<std::multimap<Key, Value>,
+			  DefaultReader<std::pair<Key, Value> > > {};
+
+  template <typename First, typename Second>
+  class DefaultReader<std::pair<First, Second> > 
+    : public PairReader<std::pair<First, Second> > {};
+
+  /// \ingroup item_io
+  /// 
+  /// \brief The default item reader for skipping a value in the stream.
+  ///
+  /// The default item reader for skipping a value in the stream.
+  ///
+  /// \author Balazs Dezso
+  class DefaultSkipper : public UnformattedReader {};
+
+  /// \ingroup item_io  
+  /// \brief Standard ReaderTraits for the GraphReader class.
+  ///
+  /// Standard ReaderTraits for the GraphReader class.
+  /// It defines standard reading method for all type of value. 
+  /// \author Balazs Dezso
+  struct DefaultReaderTraits {
+
+    template <typename _Value>
+    struct Reader : DefaultReader<_Value> {};
+
+    typedef DefaultSkipper Skipper;
+
+  };
+
+}
+
+#endif
Index: lemon/bits/item_writer.h
===================================================================
--- lemon/bits/item_writer.h	(revision 2553)
+++ lemon/bits/item_writer.h	(revision 2553)
@@ -0,0 +1,491 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup item_io
+/// \file
+/// \brief Item writer bits for lemon output.
+
+#ifndef LEMON_BITS_ITEM_WRITER_H
+#define LEMON_BITS_ITEM_WRITER_H
+
+#include <iostream>
+#include <sstream>
+#include <string>
+
+#include <vector>
+#include <deque>
+#include <list>
+#include <set>
+#include <map>
+
+#include <lemon/error.h>
+
+namespace lemon {
+  
+  template <typename Value>
+  class DefaultWriter;
+
+  /// \ingroup item_io
+  /// \brief Writer class for quoted strings.
+  ///
+  /// Writer class for unformatted strings.
+  /// \author Balazs Dezso
+  class UnformattedWriter {
+  public:
+    typedef std::string Value;
+
+    /// \brief Constructor for the writer.
+    ///
+    /// Constructor for the writer.
+    UnformattedWriter() {}
+
+    /// \brief Writes an unformatted string to the given stream.
+    ///
+    /// Writes an unformatted string to the given stream.
+    void write(std::ostream& os, const std::string& value) const {
+      os << value;
+    }
+
+    bool readable(const std::string& value) const {
+      std::istringstream is(value);
+      char c;
+      while (is.get(c) && !whiteSpace(c)) {
+        if (!processChar(c, is)) return false;
+      }
+      if (is) return false;
+      return true;
+    }
+
+  private:
+
+    bool processChar(char c, std::istream& is) const {
+      switch (c) {
+      case '(':
+        is.putback(c);
+        if (!readableParsed('(', ')', is)) return false;
+        break;
+      case '[':
+        is.putback(c);
+        if (!readableParsed('[', ']', is)) return false;
+        break;
+      case '{':
+        is.putback(c);
+        if (!readableParsed('{', '}', is)) return false;
+        break;
+      case '/':
+        is.putback(c);
+        if (!readableParsed('/', '/', is)) return false;
+        break;
+      case '\"':
+        is.putback(c);
+        if (!readableQuoted('\"', is)) return false;
+        break;
+      case '\'':
+        is.putback(c);
+        if (!readableQuoted('\'', is)) return false;
+        break;
+      default:
+        break;
+      }
+      return true;
+    }
+
+    bool readableParsed(char open, char close, std::istream& is) const {
+      char c;
+      if (!is.get(c) || c != open) return false;
+      while (is.get(c) && c != close) {
+        if (!processChar(c, is)) return false;
+      }
+      if (!is) return false;
+      return true;
+    }
+
+    bool readableQuoted(char quote, std::istream& is) const {
+      char c;
+      bool esc = false;
+      if (!is.get(c) || c != quote) return false;
+      while (is.get(c) && (c != quote || esc)) {
+        if (c == '\\') esc = !esc;
+        else esc = false;
+      }
+      if (!is) return false;
+      return true;
+    }
+
+    static bool whiteSpace(char c) {
+      return c == ' ' || c == '\t' || c == '\v' || 
+        c == '\n' || c == '\r' || c == '\f'; 
+    }
+
+  };
+
+  /// \ingroup item_io
+  /// \brief Writer class for quoted strings.
+  ///
+  /// Writer class for quoted strings. It can process the escape
+  /// sequences in the string.
+  /// \author Balazs Dezso
+  class QuotedStringWriter {
+    friend class QuotedCharWriter;
+  public:
+    typedef std::string Value;
+
+    /// \brief Constructor for the writer.
+    ///
+    /// Constructor for the writer. If the given parameter is true
+    /// the writer creates escape sequences from special characters.
+    QuotedStringWriter(bool _escaped = true, char _quote = '\"') 
+      : escaped(_escaped), quote(_quote) {}
+
+    /// \brief Writes a quoted string to the given stream.
+    ///
+    /// Writes a quoted string to the given stream.
+    void write(std::ostream& os, const std::string& value) const {
+      os << quote;
+      if (escaped) {
+	std::ostringstream ls;
+	for (int i = 0; i < int(value.size()); ++i) {
+	  writeEscape(ls, value[i]);
+	}
+	os << ls.str();
+      } else {
+	os << value;
+      }
+      os << quote;
+    }
+
+  private:
+    
+    static void writeEscape(std::ostream& os, char c) {
+      switch (c) {
+      case '\\':
+	os << "\\\\";
+	return;
+      case '\"':
+	os << "\\\"";
+	return;
+      case '\'':
+	os << "\\\'";
+	return;
+      case '\?':
+	os << "\\\?";
+	return;
+      case '\a':
+	os << "\\a";
+	return;
+      case '\b':
+	os << "\\b";
+	return;
+      case '\f':
+	os << "\\f";
+	return;
+      case '\r':
+	os << "\\r";
+	return;
+      case '\n':
+	os << "\\n";
+	return;
+      case '\t':
+	os << "\\t";
+	return;
+      case '\v':
+	os << "\\v";
+	return;
+      default:
+	if (c < 0x20) {
+	  os << '\\' << std::oct << static_cast<int>(c);
+	} else {
+	  os << c;
+	}
+	return;
+      }     
+    }
+  private:
+    bool escaped;
+    char quote;
+  };
+
+  /// \ingroup item_io
+  /// \brief Writer class for quoted chars.
+  ///
+  /// Writer class for quoted char. It can process the escape
+  /// sequences in the string.
+  /// \author Balazs Dezso
+  class QuotedCharWriter {
+  public:
+    typedef char Value;
+
+    /// \brief Constructor for the writer.
+    ///
+    /// Constructor for the writer. If the given parameter is true
+    /// the writer creates escape sequences from special characters.
+    QuotedCharWriter(bool _escaped = true) : escaped(_escaped) {}
+
+    /// \brief Writes a quoted char to the given stream.
+    ///
+    /// Writes a quoted char to the given stream.
+    void write(std::ostream& os, const char& value) const {
+      os << "\'";
+      if (escaped) {
+	std::ostringstream ls;
+        QuotedStringWriter::writeEscape(ls, value);
+	os << ls.str();
+      } else {
+	os << value;
+      }
+      os << "\'";
+    }
+
+  private:
+    bool escaped;
+  };
+
+  /// \ingroup item_io
+  /// \brief Writer class for quoted char array.
+  ///
+  /// Writer class for quoted char array. It can process the escape
+  /// sequences in the char array.
+  /// \author Balazs Dezso
+  class QuotedCharArrayWriter {
+  public:
+    typedef const char* Value;
+
+    /// \brief Constructor for the writer.
+    ///
+    /// Constructor for the writer. If the given parameter is true
+    /// the writer creates escape sequences from special characters.
+    QuotedCharArrayWriter(bool _escaped = true) : escaped(_escaped) {}
+
+    /// \brief Writes a quoted char array to the given stream.
+    ///
+    /// Writes a quoted char array to the given stream.
+    void write(std::ostream& os, const char* value) const {
+      QuotedStringWriter(escaped).write(os, std::string(value));
+    }
+
+  private:    
+    bool escaped;
+  };
+
+
+  /// \ingroup item_io
+  ///
+  /// \brief Writer for standard containers.
+  ///
+  /// Writer for each iterable standard containers. The representation
+  /// of the container is the values enumerated between an open and a
+  /// close parse. 
+  ///
+  /// \author Balazs Dezso
+  template <
+    typename _Container, 
+    typename _ItemWriter = DefaultWriter<typename _Container::value_type> 
+  >
+  class IterableWriter {
+  public:
+    typedef _Container Value;
+    typedef _ItemWriter ItemWriter;
+
+  private:
+
+    ItemWriter item_writer;
+
+  public:
+
+    IterableWriter(const ItemWriter& _item_writer = ItemWriter())
+      : item_writer(_item_writer) {}
+
+    /// \brief Writes the values of the container to the given stream.
+    ///
+    /// Writes the values of the container to the given stream.
+    void write(std::ostream& os, const Value& value) const {
+      typename Value::const_iterator it;
+      os << '(';
+      for (it = value.begin(); it != value.end(); ++it) {
+	item_writer.write(os, *it);
+	os << ' ';
+      }
+      os << ')';
+    }
+
+  };
+
+  /// \ingroup item_io
+  ///
+  /// \brief Writer for standard pairs.
+  ///
+  /// Writer for standard pairs. The representation of a pair is
+  ///\code ( first_value => second_value ) \endcode.
+  /// \author Balazs Dezso
+  template <typename _Pair, 
+	    typename _FirstWriter = 
+	    DefaultWriter<typename _Pair::first_type>,
+	    typename _SecondWriter = 
+	    DefaultWriter<typename _Pair::second_type> >
+  class PairWriter {
+  public:
+
+    typedef _Pair Value;
+
+    typedef _FirstWriter FirstWriter;
+    typedef _SecondWriter SecondWriter;
+
+  private:
+
+    FirstWriter first_writer;
+    SecondWriter second_writer;
+
+  public:
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor for the PairWriter.
+    PairWriter(const FirstWriter& _first_writer = FirstWriter(), 
+	       const SecondWriter& _second_writer = SecondWriter()) 
+      : first_writer(_first_writer), second_writer(_second_writer) {}
+    
+    /// \brief Writes the pair from the given stream.
+    ///
+    /// Writes the pair from the given stream.
+    void write(std::ostream& os, const Value& value) const {
+      os << "( ";
+      first_writer.write(os, value.first);
+      os << " => ";
+      second_writer.write(os, value.second);
+      os << " )";
+    }
+
+  };
+
+  /// \ingroup item_io
+  /// 
+  /// \brief The default item writer template class.
+  ///
+  /// The default item writer template class. If some section writer
+  /// needs to write a value to the stream it will give the default way for it.
+  ///
+  /// \author Balazs Dezso
+  template <typename _Value>
+  class DefaultWriter {
+  public:
+    /// The value type.
+    typedef _Value Value;
+    /// \brief Writes the value to the given stream.
+    ///
+    /// Writes the value to the given stream.
+    void write(std::ostream& os, const Value& value) const {
+      os << value;
+    }
+  };
+
+  template <>
+  class DefaultWriter<std::string> {
+  public:
+    typedef std::string Value;
+    
+    void write(std::ostream& os, const Value& value) const {
+      if (UnformattedWriter().readable(value)) {
+        UnformattedWriter().write(os, value);
+      } else {
+        QuotedStringWriter().write(os, value);
+      }
+    }
+      
+  };
+
+  template <>
+  class DefaultWriter<char> 
+    : public QuotedCharWriter {};
+
+  template <>
+  class DefaultWriter<bool> {
+  public:
+    typedef bool Value;
+    
+    void write(std::ostream& os, const Value& value) const {
+      os << (value ? "1" : "0");
+    }
+      
+  };
+
+  template <int length>
+  class DefaultWriter<char[length]> 
+    : public QuotedCharArrayWriter {};
+
+  template <int length>
+  class DefaultWriter<const char[length]> 
+    : public QuotedCharArrayWriter {};
+
+  template <>
+  class DefaultWriter<char*> 
+    : public QuotedCharArrayWriter {};
+
+  template <>
+  class DefaultWriter<const char*> 
+    : public QuotedCharArrayWriter {};
+
+  template <typename Item>
+  class DefaultWriter<std::vector<Item> > 
+    : public IterableWriter<std::vector<Item> > {};
+
+  template <typename Item>
+  class DefaultWriter<std::deque<Item> > 
+    : public IterableWriter<std::deque<Item> > {};
+
+  template <typename Item>
+  class DefaultWriter<std::list<Item> > 
+    : public IterableWriter<std::list<Item> > {};
+  
+  template <typename Item>
+  class DefaultWriter<std::set<Item> > 
+    : public IterableWriter<std::set<Item> > {};
+
+  template <typename Key, typename Value>
+  class DefaultWriter<std::map<Key, Value> > 
+    : public IterableWriter<std::map<Key, Value> > {};
+
+  template <typename Item>
+  class DefaultWriter<std::multiset<Item> > 
+    : public IterableWriter<std::multiset<Item> > {};
+
+  template <typename Key, typename Value>
+  class DefaultWriter<std::multimap<Key, Value> > 
+    : public IterableWriter<std::multimap<Key, Value> > {};
+
+  template <typename First, typename Second>
+  class DefaultWriter<std::pair<First, Second> > 
+    : public PairWriter<std::pair<First, Second> > {};
+
+  /// \ingroup item_io
+  /// \brief Standard WriterTraits for the section writers.
+  ///
+  /// Standard WriterTraits for the section writers.
+  /// It defines standard writing method for all type of value. 
+  /// \author Balazs Dezso
+  struct DefaultWriterTraits {
+
+    template <typename _Value>
+    struct Writer : DefaultWriter<_Value> {
+      typedef DefaultWriter<_Value> Parent;
+    };
+
+  };
+
+}
+
+#endif
Index: lemon/bits/lp_id.h
===================================================================
--- lemon/bits/lp_id.h	(revision 2553)
+++ lemon/bits/lp_id.h	(revision 2553)
@@ -0,0 +1,146 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_LP_SOLVER_ID_H
+#define LEMON_BITS_LP_SOLVER_ID_H
+
+namespace lemon {
+  
+  namespace _lp_bits {
+
+    struct LpIdImpl {
+      std::vector<int> index;
+      std::vector<int> cross;
+      int first_index;
+      int first_free;      
+    };
+
+    class LpId {
+    public:
+      
+      class IdHandler {
+      public:
+        virtual ~IdHandler() {}
+        virtual int addId(LpIdImpl&) = 0;
+        virtual void eraseId(LpIdImpl&, int xn) = 0;
+      };
+      
+      LpId(int min_index = 0) {
+        id_handler = 0;
+        impl.first_free = -1;
+        impl.first_index = min_index;
+        impl.cross.resize(impl.first_index);
+      }
+
+      void setIdHandler(IdHandler& ih) {
+        id_handler = &ih;
+      }
+      
+      int fixId(int fn) const {return impl.cross[fn];}
+      int floatingId(int xn) const {return impl.index[xn];}
+      
+      int addId() {
+        if (id_handler == 0) {
+          int xn, fn = impl.cross.size();
+          if (impl.first_free == -1) {
+            xn = impl.index.size();
+            impl.index.push_back(fn);
+          } else {
+            xn = impl.first_free;
+            impl.first_free = impl.index[impl.first_free];
+            impl.index[xn] = fn;
+          }
+          impl.cross.push_back(xn);
+          return xn;
+        } else {
+          return id_handler->addId(impl);
+        }
+      }
+
+      void eraseId(int xn) {
+        if (id_handler == 0) {
+          int fn = impl.index[xn];
+          impl.index[xn] = impl.first_free;
+          impl.first_free = xn;
+          for(int i = fn + 1; i < int(impl.cross.size()); ++i) {
+            impl.cross[i - 1] = impl.cross[i];
+            impl.index[impl.cross[i]]--;
+          }
+          impl.cross.pop_back();
+        } else {
+          id_handler->eraseId(impl, xn);
+        }
+      }
+
+      void firstFloating(int& fn) const {
+        fn = impl.first_index;
+        if (fn == int(impl.cross.size())) fn = -1;
+      }
+
+      void nextFloating(int& fn) const {
+        ++fn;
+        if (fn == int(impl.cross.size())) fn = -1;
+      }
+
+      void firstFix(int& xn) const {
+        int fn;
+        firstFloating(fn);
+        xn = fn != -1 ? fixId(fn) : -1;
+      }
+      
+      void nextFix(int& xn) const {
+        int fn = floatingId(xn);
+        nextFloating(fn);
+        xn = fn != -1 ? fixId(fn) : -1;    
+      }
+
+    protected:
+      LpIdImpl impl;
+      IdHandler *id_handler;
+    };
+  
+    class RelocateIdHandler : public LpId::IdHandler {
+    public:
+
+      virtual int addId(LpIdImpl& impl) {
+        int xn, fn = impl.cross.size();
+        if (impl.first_free == -1) {
+          xn = impl.index.size();
+          impl.index.push_back(fn);
+        } else {
+          xn = impl.first_free;
+          impl.first_free = impl.index[impl.first_free];
+          impl.index[xn] = fn;
+        }
+        impl.cross.push_back(xn);
+        return xn;
+      }
+
+      virtual void eraseId(LpIdImpl& impl, int xn) {
+        int fn = impl.index[xn];
+        impl.index[xn] = impl.first_free;
+        impl.first_free = xn;
+        impl.cross[fn] = impl.cross.back();
+        impl.index[impl.cross.back()] = fn;
+        impl.cross.pop_back();
+      }
+    };
+  }  
+}
+
+#endif
Index: lemon/bits/map_extender.h
===================================================================
--- lemon/bits/map_extender.h	(revision 2553)
+++ lemon/bits/map_extender.h	(revision 2553)
@@ -0,0 +1,321 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_MAP_EXTENDER_H
+#define LEMON_BITS_MAP_EXTENDER_H
+
+#include <iterator>
+
+#include <lemon/bits/traits.h>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+
+///\file
+///\brief Extenders for iterable maps.
+
+namespace lemon {
+
+  /// \ingroup graphbits
+  /// 
+  /// \brief Extender for maps
+  template <typename _Map>
+  class MapExtender : public _Map {
+  public:
+
+    typedef _Map Parent;
+    typedef MapExtender Map;
+
+
+    typedef typename Parent::Graph Graph;
+    typedef typename Parent::Key Item;
+
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    class MapIt;
+    class ConstMapIt;
+
+    friend class MapIt;
+    friend class ConstMapIt;
+
+  public:
+
+    MapExtender(const Graph& graph) 
+      : Parent(graph) {}
+
+    MapExtender(const Graph& graph, const Value& value) 
+      : Parent(graph, value) {}
+
+    MapExtender& operator=(const MapExtender& cmap) {
+      return operator=<MapExtender>(cmap);
+    }
+
+    template <typename CMap>
+    MapExtender& operator=(const CMap& cmap) {
+      Parent::operator=(cmap);
+      return *this;
+    } 
+
+    class MapIt : public Item {
+    public:
+      
+      typedef Item Parent;
+      typedef typename Map::Value Value;
+      
+      MapIt() {}
+
+      MapIt(Invalid i) : Parent(i) { }
+
+      explicit MapIt(Map& _map) : map(_map) {
+        map.notifier()->first(*this);
+      }
+
+      MapIt(const Map& _map, const Item& item) 
+	: Parent(item), map(_map) {}
+
+      MapIt& operator++() { 
+	map.notifier()->next(*this);
+	return *this; 
+      }
+      
+      typename MapTraits<Map>::ConstReturnValue operator*() const {
+	return map[*this];
+      }
+
+      typename MapTraits<Map>::ReturnValue operator*() {
+	return map[*this];
+      }
+      
+      void set(const Value& value) {
+	map.set(*this, value);
+      }
+      
+    protected:
+      Map& map;
+      
+    };
+
+    class ConstMapIt : public Item {
+    public:
+
+      typedef Item Parent;
+
+      typedef typename Map::Value Value;
+      
+      ConstMapIt() {}
+
+      ConstMapIt(Invalid i) : Parent(i) { }
+
+      explicit ConstMapIt(Map& _map) : map(_map) {
+        map.notifier()->first(*this);
+      }
+
+      ConstMapIt(const Map& _map, const Item& item) 
+	: Parent(item), map(_map) {}
+
+      ConstMapIt& operator++() { 
+	map.notifier()->next(*this);
+	return *this; 
+      }
+
+      typename MapTraits<Map>::ConstReturnValue operator*() const {
+	return map[*this];
+      }
+
+    protected:
+      const Map& map;
+    };
+
+    class ItemIt : public Item {
+    public:
+      
+      typedef Item Parent;
+      
+      ItemIt() {}
+
+      ItemIt(Invalid i) : Parent(i) { }
+
+      explicit ItemIt(Map& _map) : map(_map) {
+        map.notifier()->first(*this);
+      }
+
+      ItemIt(const Map& _map, const Item& item) 
+	: Parent(item), map(_map) {}
+
+      ItemIt& operator++() { 
+	map.notifier()->next(*this);
+	return *this; 
+      }
+
+    protected:
+      const Map& map;
+      
+    };
+  };
+
+  /// \ingroup graphbits
+  /// 
+  /// \brief Extender for maps which use a subset of the items.
+  template <typename _Graph, typename _Map>
+  class SubMapExtender : public _Map {
+  public:
+
+    typedef _Map Parent;
+    typedef SubMapExtender Map;
+
+    typedef _Graph Graph;
+
+    typedef typename Parent::Key Item;
+
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    class MapIt;
+    class ConstMapIt;
+
+    friend class MapIt;
+    friend class ConstMapIt;
+
+  public:
+
+    SubMapExtender(const Graph& _graph) 
+      : Parent(_graph), graph(_graph) {}
+
+    SubMapExtender(const Graph& _graph, const Value& _value) 
+      : Parent(_graph, _value), graph(_graph) {}
+
+    SubMapExtender& operator=(const SubMapExtender& cmap) {
+      return operator=<MapExtender>(cmap);
+    }
+
+    template <typename CMap>
+    SubMapExtender& operator=(const CMap& cmap) {
+      checkConcept<concepts::ReadMap<Key, Value>, CMap>();
+      Item it;
+      for (graph.first(it); it != INVALID; graph.next(it)) {
+        Parent::set(it, cmap[it]);
+      }
+      return *this;
+    } 
+
+    class MapIt : public Item {
+    public:
+      
+      typedef Item Parent;
+      typedef typename Map::Value Value;
+      
+      MapIt() {}
+
+      MapIt(Invalid i) : Parent(i) { }
+
+      explicit MapIt(Map& _map) : map(_map) {
+        map.graph.first(*this);
+      }
+
+      MapIt(const Map& _map, const Item& item) 
+	: Parent(item), map(_map) {}
+
+      MapIt& operator++() { 
+	map.graph.next(*this);
+	return *this; 
+      }
+      
+      typename MapTraits<Map>::ConstReturnValue operator*() const {
+	return map[*this];
+      }
+
+      typename MapTraits<Map>::ReturnValue operator*() {
+	return map[*this];
+      }
+      
+      void set(const Value& value) {
+	map.set(*this, value);
+      }
+      
+    protected:
+      Map& map;
+      
+    };
+
+    class ConstMapIt : public Item {
+    public:
+
+      typedef Item Parent;
+
+      typedef typename Map::Value Value;
+      
+      ConstMapIt() {}
+
+      ConstMapIt(Invalid i) : Parent(i) { }
+
+      explicit ConstMapIt(Map& _map) : map(_map) {
+        map.graph.first(*this);
+      }
+
+      ConstMapIt(const Map& _map, const Item& item) 
+	: Parent(item), map(_map) {}
+
+      ConstMapIt& operator++() { 
+	map.graph.next(*this);
+	return *this; 
+      }
+
+      typename MapTraits<Map>::ConstReturnValue operator*() const {
+	return map[*this];
+      }
+
+    protected:
+      const Map& map;
+    };
+
+    class ItemIt : public Item {
+    public:
+      
+      typedef Item Parent;
+      
+      ItemIt() {}
+
+      ItemIt(Invalid i) : Parent(i) { }
+
+      explicit ItemIt(Map& _map) : map(_map) {
+        map.graph.first(*this);
+      }
+
+      ItemIt(const Map& _map, const Item& item) 
+	: Parent(item), map(_map) {}
+
+      ItemIt& operator++() { 
+	map.graph.next(*this);
+	return *this; 
+      }
+
+    protected:
+      const Map& map;
+      
+    };
+    
+  private:
+
+    const Graph& graph;
+    
+  };
+
+}
+
+#endif
Index: lemon/bits/mingw32_time.cc
===================================================================
--- lemon/bits/mingw32_time.cc	(revision 2553)
+++ lemon/bits/mingw32_time.cc	(revision 2553)
@@ -0,0 +1,122 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifdef WIN32
+
+#include <lemon/bits/mingw32_time.h>
+
+#include <windows.h>
+#include <ctime>
+#include "dos.h"
+
+static const char days[] = 
+"Sun Mon Tue Wed Thu Fri Sat ";
+static const char months[] = 
+"Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec ";
+
+void num2str(char *c,int i) {
+  c[0]=i/10+'0';
+  c[1]=i%10+'0';
+}
+
+char *asctime_r(const struct tm *t, char *buf) {
+  *(int*)buf=*(int*)(days+(t->tm_wday<<2));
+  *(int*)(buf+4)=*(int*)(months+(t->tm_mon<<2));
+  num2str(buf+8,t->tm_mday);
+  if (buf[8]=='0') buf[8]=' ';
+  buf[10]=' ';
+  num2str(buf+11,t->tm_hour);
+  buf[13]=':';
+  num2str(buf+14,t->tm_min);
+  buf[16]=':';
+  num2str(buf+17,t->tm_sec);
+  buf[19]=' ';
+  num2str(buf+20,(t->tm_year+1900)/100);
+  num2str(buf+22,(t->tm_year+1900)%100);
+  buf[24]='\n'; buf[25]='\0';
+  return buf;
+}
+
+struct tm * localtime_r (const time_t *t, struct tm *tm) {
+  struct tm *tmp;
+  
+  if ((tmp = localtime(t)) && tm)
+    *tm = *tmp;
+  else
+    return 0;
+  
+  return tm;
+}
+
+char *ctime_r(const time_t * tim_p , char * result) {
+  struct tm tm;
+  return asctime_r (localtime_r (tim_p, &tm), result);
+}
+
+
+int gettimeofday(struct timeval * tp, struct timezone *) {
+  SYSTEMTIME systime;
+
+  if (tp) {
+    struct tm tmrec;
+    time_t theTime = time(NULL);
+    
+    
+    tmrec = *localtime(&theTime);
+    tp->tv_sec = mktime(&tmrec);
+    GetLocalTime(&systime); /* system time */
+
+    tp->tv_usec = systime.wMilliseconds * 1000;
+  }
+  return 0;
+}
+
+long filetime_to_clock(FILETIME *ft)
+{
+  __int64 qw = ft->dwHighDateTime;
+  qw <<= 32;
+  qw |= ft->dwLowDateTime;
+  qw /= 10000;  
+  return (long) qw;
+
+}
+
+int times(struct tms *tmbuf)
+{
+  FILETIME create, exit, kernel, user;
+  if (GetProcessTimes(GetCurrentProcess(),&create, &exit, &kernel, &user)) {
+    tmbuf->tms_utime = filetime_to_clock(&user);
+    tmbuf->tms_stime = filetime_to_clock(&kernel);
+    tmbuf->tms_cutime = 0;
+    tmbuf->tms_cstime = 0;
+  }
+  else {
+    tmbuf->tms_utime = clock();
+    tmbuf->tms_stime = 0;
+    tmbuf->tms_cutime = 0;
+    tmbuf->tms_cstime = 0;
+  }
+  return 0;
+}
+
+int sysconf(int)
+{
+  return 1;
+}
+
+#endif
Index: lemon/bits/mingw32_time.h
===================================================================
--- lemon/bits/mingw32_time.h	(revision 2553)
+++ lemon/bits/mingw32_time.h	(revision 2553)
@@ -0,0 +1,50 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_MINGW32_TIME_H
+#define LEMON_BITS_MINGW32_TIME_H
+
+#ifdef WIN32
+
+#include <windows.h>
+#include <ctime>
+#include "dos.h"
+
+char *asctime_r(const struct tm *t, char *buf);
+struct tm * localtime_r (const time_t *t, struct tm *tm);
+char *ctime_r(const time_t * tim_p , char * result);
+int gettimeofday(struct timeval * tp, struct timezone *);
+
+struct tms {
+  long	tms_utime;
+  long	tms_stime;
+  long	tms_cutime;
+  long	tms_cstime;
+};
+
+long filetime_to_clock(FILETIME *ft);
+
+int times(struct tms *tmbuf);
+
+#define _SC_CLK_TCK 1
+
+int sysconf(int);
+
+#endif
+
+#endif
Index: lemon/bits/path_dump.h
===================================================================
--- lemon/bits/path_dump.h	(revision 2553)
+++ lemon/bits/path_dump.h	(revision 2553)
@@ -0,0 +1,174 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_PRED_MAP_PATH_H
+#define LEMON_BITS_PRED_MAP_PATH_H
+
+namespace lemon {
+
+  template <typename _Graph, typename _PredMap>
+  class PredMapPath {
+  public:
+    typedef True RevPathTag;
+
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+    typedef _PredMap PredMap;
+
+    PredMapPath(const Graph& _graph, const PredMap& _predMap,
+                typename Graph::Node _target)
+      : graph(_graph), predMap(_predMap), target(_target) {}
+
+    int length() const {
+      int len = 0;
+      typename Graph::Node node = target;
+      typename Graph::Edge edge;
+      while ((edge = predMap[node]) != INVALID) {
+        node = graph.source(edge);
+        ++len;
+      }
+      return len;
+    }
+
+    bool empty() const {
+      return predMap[target] != INVALID;
+    }
+
+    class RevEdgeIt {
+    public:
+      RevEdgeIt() {}
+      RevEdgeIt(Invalid) : path(0), current(INVALID) {}
+      RevEdgeIt(const PredMapPath& _path) 
+        : path(&_path), current(_path.target) {
+        if (path->predMap[current] == INVALID) current = INVALID;
+      }
+
+      operator const typename Graph::Edge() const {
+        return path->predMap[current];
+      }
+
+      RevEdgeIt& operator++() {
+        current = path->graph.source(path->predMap[current]);
+        if (path->predMap[current] == INVALID) current = INVALID;
+        return *this;
+      }
+
+      bool operator==(const RevEdgeIt& e) const { 
+        return current == e.current; 
+      }
+
+      bool operator!=(const RevEdgeIt& e) const {
+        return current != e.current; 
+      }
+
+      bool operator<(const RevEdgeIt& e) const { 
+        return current < e.current; 
+      }
+      
+    private:
+      const PredMapPath* path;
+      typename Graph::Node current;
+    };
+
+  private:
+    const Graph& graph;
+    const PredMap& predMap;
+    typename Graph::Node target;
+  };
+
+
+  template <typename _Graph, typename _PredMatrixMap>
+  class PredMatrixMapPath {
+  public:
+    typedef True RevPathTag;
+
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+    typedef _PredMatrixMap PredMatrixMap;
+
+    PredMatrixMapPath(const Graph& _graph, 
+                      const PredMatrixMap& _predMatrixMap,
+                      typename Graph::Node _source, 
+                      typename Graph::Node _target)
+      : graph(_graph), predMatrixMap(_predMatrixMap), 
+        source(_source), target(_target) {}
+
+    int length() const {
+      int len = 0;
+      typename Graph::Node node = target;
+      typename Graph::Edge edge;
+      while ((edge = predMatrixMap(source, node)) != INVALID) {
+        node = graph.source(edge);
+        ++len;
+      }
+      return len;
+    }
+
+    bool empty() const {
+      return source != target;
+    }
+
+    class RevEdgeIt {
+    public:
+      RevEdgeIt() {}
+      RevEdgeIt(Invalid) : path(0), current(INVALID) {}
+      RevEdgeIt(const PredMatrixMapPath& _path) 
+        : path(&_path), current(_path.target) {
+        if (path->predMatrixMap(path->source, current) == INVALID) 
+          current = INVALID;
+      }
+
+      operator const typename Graph::Edge() const {
+        return path->predMatrixMap(path->source, current);
+      }
+
+      RevEdgeIt& operator++() {
+        current = 
+          path->graph.source(path->predMatrixMap(path->source, current));
+        if (path->predMatrixMap(path->source, current) == INVALID) 
+          current = INVALID;
+        return *this;
+      }
+
+      bool operator==(const RevEdgeIt& e) const { 
+        return current == e.current; 
+      }
+
+      bool operator!=(const RevEdgeIt& e) const {
+        return current != e.current; 
+      }
+
+      bool operator<(const RevEdgeIt& e) const { 
+        return current < e.current; 
+      }
+      
+    private:
+      const PredMatrixMapPath* path;
+      typename Graph::Node current;
+    };
+
+  private:
+    const Graph& graph;
+    const PredMatrixMap& predMatrixMap;
+    typename Graph::Node source;
+    typename Graph::Node target;
+  };
+
+}
+
+#endif
Index: lemon/bits/traits.h
===================================================================
--- lemon/bits/traits.h	(revision 2618)
+++ lemon/bits/traits.h	(revision 2618)
@@ -0,0 +1,346 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_TRAITS_H
+#define LEMON_BITS_TRAITS_H
+
+#include <lemon/bits/utility.h>
+
+///\file
+///\brief Traits for graphs and maps
+///
+
+namespace lemon {
+  template <typename _Graph, typename _Item>
+  class ItemSetTraits {};
+  
+
+  template <typename Graph, typename Enable = void>
+  struct NodeNotifierIndicator {
+    typedef InvalidType Type;
+  };
+  template <typename Graph>
+  struct NodeNotifierIndicator<
+    Graph, 
+    typename enable_if<typename Graph::NodeNotifier::Notifier, void>::type
+  > { 
+    typedef typename Graph::NodeNotifier Type;
+  };
+
+  template <typename _Graph>
+  class ItemSetTraits<_Graph, typename _Graph::Node> {
+  public:
+    
+    typedef _Graph Graph;
+
+    typedef typename Graph::Node Item;
+    typedef typename Graph::NodeIt ItemIt;
+
+    typedef typename NodeNotifierIndicator<Graph>::Type ItemNotifier;
+
+    template <typename _Value>
+    class Map : public Graph::template NodeMap<_Value> {
+    public:
+      typedef typename Graph::template NodeMap<_Value> Parent; 
+      typedef typename Graph::template NodeMap<_Value> Type; 
+      typedef typename Parent::Value Value;
+
+      Map(const Graph& _graph) : Parent(_graph) {}
+      Map(const Graph& _graph, const Value& _value) 
+	: Parent(_graph, _value) {}
+
+     };
+
+  };
+
+  template <typename Graph, typename Enable = void>
+  struct EdgeNotifierIndicator {
+    typedef InvalidType Type;
+  };
+  template <typename Graph>
+  struct EdgeNotifierIndicator<
+    Graph, 
+    typename enable_if<typename Graph::EdgeNotifier::Notifier, void>::type
+  > { 
+    typedef typename Graph::EdgeNotifier Type;
+  };
+
+  template <typename _Graph>
+  class ItemSetTraits<_Graph, typename _Graph::Edge> {
+  public:
+    
+    typedef _Graph Graph;
+
+    typedef typename Graph::Edge Item;
+    typedef typename Graph::EdgeIt ItemIt;
+
+    typedef typename EdgeNotifierIndicator<Graph>::Type ItemNotifier;
+
+    template <typename _Value>
+    class Map : public Graph::template EdgeMap<_Value> {
+    public:
+      typedef typename Graph::template EdgeMap<_Value> Parent; 
+      typedef typename Graph::template EdgeMap<_Value> Type; 
+      typedef typename Parent::Value Value;
+
+      Map(const Graph& _graph) : Parent(_graph) {}
+      Map(const Graph& _graph, const Value& _value) 
+	: Parent(_graph, _value) {}
+    };
+
+  };
+
+  template <typename Graph, typename Enable = void>
+  struct UEdgeNotifierIndicator {
+    typedef InvalidType Type;
+  };
+  template <typename Graph>
+  struct UEdgeNotifierIndicator<
+    Graph, 
+    typename enable_if<typename Graph::UEdgeNotifier::Notifier, void>::type
+  > { 
+    typedef typename Graph::UEdgeNotifier Type;
+  };
+
+  template <typename _Graph>
+  class ItemSetTraits<_Graph, typename _Graph::UEdge> {
+  public:
+    
+    typedef _Graph Graph;
+
+    typedef typename Graph::UEdge Item;
+    typedef typename Graph::UEdgeIt ItemIt;
+
+    typedef typename UEdgeNotifierIndicator<Graph>::Type ItemNotifier;
+
+    template <typename _Value>
+    class Map : public Graph::template UEdgeMap<_Value> {
+    public:
+      typedef typename Graph::template UEdgeMap<_Value> Parent; 
+      typedef typename Graph::template UEdgeMap<_Value> Type; 
+      typedef typename Parent::Value Value;
+
+      Map(const Graph& _graph) : Parent(_graph) {}
+      Map(const Graph& _graph, const Value& _value) 
+	: Parent(_graph, _value) {}
+    };
+
+  };
+
+  template <typename Graph, typename Enable = void>
+  struct ANodeNotifierIndicator {
+    typedef InvalidType Type;
+  };
+  template <typename Graph>
+  struct ANodeNotifierIndicator<
+    Graph, 
+    typename enable_if<typename Graph::ANodeNotifier::Notifier, void>::type
+  > { 
+    typedef typename Graph::ANodeNotifier Type;
+  };
+
+  template <typename _Graph>
+  class ItemSetTraits<_Graph, typename _Graph::ANode> {
+  public:
+    
+    typedef _Graph Graph;
+
+    typedef typename Graph::ANode Item;
+    typedef typename Graph::ANodeIt ItemIt;
+
+    typedef typename ANodeNotifierIndicator<Graph>::Type ItemNotifier;
+
+    template <typename _Value>
+    class Map : public Graph::template ANodeMap<_Value> {
+    public:
+      typedef typename Graph::template ANodeMap<_Value> Parent; 
+      typedef typename Graph::template ANodeMap<_Value> Type; 
+      typedef typename Parent::Value Value;
+
+      Map(const Graph& _graph) : Parent(_graph) {}
+      Map(const Graph& _graph, const Value& _value) 
+	: Parent(_graph, _value) {}
+    };
+
+  };
+
+  template <typename Graph, typename Enable = void>
+  struct BNodeNotifierIndicator {
+    typedef InvalidType Type;
+  };
+  template <typename Graph>
+  struct BNodeNotifierIndicator<
+    Graph, 
+    typename enable_if<typename Graph::BNodeNotifier::Notifier, void>::type
+  > { 
+    typedef typename Graph::BNodeNotifier Type;
+  };
+
+  template <typename _Graph>
+  class ItemSetTraits<_Graph, typename _Graph::BNode> {
+  public:
+    
+    typedef _Graph Graph;
+
+    typedef typename Graph::BNode Item;
+    typedef typename Graph::BNodeIt ItemIt;
+
+    typedef typename BNodeNotifierIndicator<Graph>::Type ItemNotifier;
+
+    template <typename _Value>
+    class Map : public Graph::template BNodeMap<_Value> {
+    public:
+      typedef typename Graph::template BNodeMap<_Value> Parent; 
+      typedef typename Graph::template BNodeMap<_Value> Type; 
+      typedef typename Parent::Value Value;
+
+      Map(const Graph& _graph) : Parent(_graph) {}
+      Map(const Graph& _graph, const Value& _value) 
+	: Parent(_graph, _value) {}
+    };
+
+  };
+
+
+  template <typename Map, typename Enable = void>
+  struct MapTraits {
+    typedef False ReferenceMapTag;
+
+    typedef typename Map::Key Key;
+    typedef typename Map::Value Value;
+
+    typedef Value ConstReturnValue;
+    typedef Value ReturnValue;
+  };
+
+  template <typename Map>
+  struct MapTraits<
+    Map, typename enable_if<typename Map::ReferenceMapTag, void>::type > 
+  {
+    typedef True ReferenceMapTag;
+    
+    typedef typename Map::Key Key;
+    typedef typename Map::Value Value;
+
+    typedef typename Map::ConstReference ConstReturnValue;
+    typedef typename Map::Reference ReturnValue;
+
+    typedef typename Map::ConstReference ConstReference; 
+    typedef typename Map::Reference Reference;
+ };
+
+  template <typename MatrixMap, typename Enable = void>
+  struct MatrixMapTraits {
+    typedef False ReferenceMapTag;
+
+    typedef typename MatrixMap::FirstKey FirstKey;
+    typedef typename MatrixMap::SecondKey SecondKey;
+    typedef typename MatrixMap::Value Value;
+
+    typedef Value ConstReturnValue;
+    typedef Value ReturnValue;
+  };
+
+  template <typename MatrixMap>
+  struct MatrixMapTraits<
+    MatrixMap, typename enable_if<typename MatrixMap::ReferenceMapTag, 
+                                  void>::type > 
+  {
+    typedef True ReferenceMapTag;
+    
+    typedef typename MatrixMap::FirstKey FirstKey;
+    typedef typename MatrixMap::SecondKey SecondKey;
+    typedef typename MatrixMap::Value Value;
+
+    typedef typename MatrixMap::ConstReference ConstReturnValue;
+    typedef typename MatrixMap::Reference ReturnValue;
+
+    typedef typename MatrixMap::ConstReference ConstReference; 
+    typedef typename MatrixMap::Reference Reference;
+ };
+
+  // Indicators for the tags
+
+  template <typename Graph, typename Enable = void>
+  struct NodeNumTagIndicator {
+    static const bool value = false;
+  };
+
+  template <typename Graph>
+  struct NodeNumTagIndicator<
+    Graph, 
+    typename enable_if<typename Graph::NodeNumTag, void>::type
+  > {
+    static const bool value = true;
+  };
+
+  template <typename Graph, typename Enable = void>
+  struct EdgeNumTagIndicator {
+    static const bool value = false;
+  };
+
+  template <typename Graph>
+  struct EdgeNumTagIndicator<
+    Graph, 
+    typename enable_if<typename Graph::EdgeNumTag, void>::type
+  > {
+    static const bool value = true;
+  };
+
+  template <typename Graph, typename Enable = void>
+  struct FindEdgeTagIndicator {
+    static const bool value = false;
+  };
+
+  template <typename Graph>
+  struct FindEdgeTagIndicator<
+    Graph, 
+    typename enable_if<typename Graph::FindEdgeTag, void>::type
+  > {
+    static const bool value = true;
+  };
+
+  template <typename Graph, typename Enable = void>
+  struct UndirectedTagIndicator {
+    static const bool value = false;
+  };
+
+  template <typename Graph>
+  struct UndirectedTagIndicator<
+    Graph, 
+    typename enable_if<typename Graph::UndirectedTag, void>::type
+  > {
+    static const bool value = true;
+  };
+
+  template <typename Graph, typename Enable = void>
+  struct BuildTagIndicator {
+    static const bool value = false;
+  };
+
+  template <typename Graph>
+  struct BuildTagIndicator<
+    Graph, 
+    typename enable_if<typename Graph::BuildTag, void>::type
+  > {
+    static const bool value = true;
+  };
+
+}
+
+#endif
Index: lemon/bits/utility.h
===================================================================
--- lemon/bits/utility.h	(revision 2553)
+++ lemon/bits/utility.h	(revision 2553)
@@ -0,0 +1,140 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+// This file contains a modified version of the enable_if library from BOOST.
+// See the appropriate copyright notice below.
+
+// Boost enable_if library
+
+// Copyright 2003 © The Trustees of Indiana University.
+
+// Use, modification, and distribution is subject to the Boost Software
+// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+
+//    Authors: Jaakko Järvi (jajarvi at osl.iu.edu)
+//             Jeremiah Willcock (jewillco at osl.iu.edu)
+//             Andrew Lumsdaine (lums at osl.iu.edu)
+
+
+#ifndef LEMON_BITS_UTILITY_H
+#define LEMON_BITS_UTILITY_H
+
+///\file
+///\brief Miscellaneous basic utilities
+///
+///\todo Please rethink the organisation of the basic files like this.
+///E.g. this file might be merged with invalid.h.
+
+
+namespace lemon
+{
+
+  /// Basic type for defining "tags". A "YES" condition for \c enable_if.
+
+  /// Basic type for defining "tags". A "YES" condition for \c enable_if.
+  ///
+  ///\sa False
+  ///
+  /// \todo This should go to a separate "basic_types.h" (or something)
+  /// file.
+  struct True {
+    ///\e
+    static const bool value = true;
+  };
+
+  /// Basic type for defining "tags". A "NO" condition for \c enable_if.
+
+  /// Basic type for defining "tags". A "NO" condition for \c enable_if.
+  ///
+  ///\sa True
+  struct False {
+    ///\e
+    static const bool value = false;
+  };
+
+
+  struct InvalidType {
+  };
+
+  template <typename T>
+  struct Wrap {
+    const T &value;
+    Wrap(const T &t) : value(t) {}
+  };
+
+  /**************** dummy class to avoid ambiguity ****************/
+
+  template<int T> struct dummy { dummy(int) {} };
+
+  /**************** enable_if from BOOST ****************/
+  
+  template <typename Type, typename T = void>
+  struct exists {
+    typedef T type;
+  };
+
+ 
+  template <bool B, class T = void>
+  struct enable_if_c {
+    typedef T type;
+  };
+
+  template <class T>
+  struct enable_if_c<false, T> {};
+
+  template <class Cond, class T = void> 
+  struct enable_if : public enable_if_c<Cond::value, T> {};
+
+  template <bool B, class T>
+  struct lazy_enable_if_c {
+    typedef typename T::type type;
+  };
+
+  template <class T>
+  struct lazy_enable_if_c<false, T> {};
+
+  template <class Cond, class T> 
+  struct lazy_enable_if : public lazy_enable_if_c<Cond::value, T> {};
+
+
+  template <bool B, class T = void>
+  struct disable_if_c {
+    typedef T type;
+  };
+
+  template <class T>
+  struct disable_if_c<true, T> {};
+
+  template <class Cond, class T = void> 
+  struct disable_if : public disable_if_c<Cond::value, T> {};
+
+  template <bool B, class T>
+  struct lazy_disable_if_c {
+    typedef typename T::type type;
+  };
+
+  template <class T>
+  struct lazy_disable_if_c<true, T> {};
+
+  template <class Cond, class T> 
+  struct lazy_disable_if : public lazy_disable_if_c<Cond::value, T> {};
+
+} // namespace lemon
+
+#endif
Index: lemon/bits/variant.h
===================================================================
--- lemon/bits/variant.h	(revision 2553)
+++ lemon/bits/variant.h	(revision 2553)
@@ -0,0 +1,508 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_VARIANT_H
+#define LEMON_BITS_VARIANT_H
+
+#include <lemon/error.h>
+
+/// \file
+/// \brief Variant types
+
+namespace lemon {
+
+  namespace _variant_bits {
+  
+    template <int left, int right>
+    struct CTMax {
+      static const int value = left < right ? right : left;
+    };
+
+  }
+
+
+  /// \brief Simple Variant type for two types
+  ///
+  /// Simple Variant type for two types. The Variant type is a type
+  /// safe union. The C++ has strong limitations for using unions, by
+  /// example we can not store type with non default constructor or
+  /// destructor in an union. This class always knowns the current
+  /// state of the variant and it cares for the proper construction
+  /// and destruction.
+  template <typename _First, typename _Second>
+  class BiVariant {
+  public:
+
+    /// \brief The \c First type.
+    typedef _First First;
+    /// \brief The \c Second type.
+    typedef _Second Second;
+
+    struct WrongStateError : public lemon::LogicError {
+    public:
+      virtual const char* what() const throw() {
+        return "lemon::BiVariant::WrongStateError";
+      }
+    };
+
+    /// \brief Constructor
+    ///
+    /// This constructor initalizes to the default value of the \c First
+    /// type.
+    BiVariant() {
+      flag = true;
+      new(reinterpret_cast<First*>(data)) First();
+    }
+
+    /// \brief Constructor
+    ///
+    /// This constructor initalizes to the given value of the \c First
+    /// type.
+    BiVariant(const First& f) {
+      flag = true;
+      new(reinterpret_cast<First*>(data)) First(f);
+    }
+
+    /// \brief Constructor
+    ///
+    /// This constructor initalizes to the given value of the \c
+    /// Second type.
+    BiVariant(const Second& s) {
+      flag = false;
+      new(reinterpret_cast<Second*>(data)) Second(s);
+    }
+
+    /// \brief Copy constructor
+    ///
+    /// Copy constructor
+    BiVariant(const BiVariant& bivariant) {
+      flag = bivariant.flag;
+      if (flag) {
+        new(reinterpret_cast<First*>(data)) First(bivariant.first());      
+      } else {
+        new(reinterpret_cast<Second*>(data)) Second(bivariant.second());      
+      }
+    }
+
+    /// \brief Destrcutor
+    ///
+    /// Destructor
+    ~BiVariant() {
+      destroy();
+    }
+
+    /// \brief Set to the default value of the \c First type.
+    ///
+    /// This function sets the variant to the default value of the \c
+    /// First type.
+    BiVariant& setFirst() {
+      destroy();
+      flag = true;
+      new(reinterpret_cast<First*>(data)) First();   
+      return *this;
+    }
+
+    /// \brief Set to the given value of the \c First type.
+    ///
+    /// This function sets the variant to the given value of the \c
+    /// First type.
+    BiVariant& setFirst(const First& f) {
+      destroy();
+      flag = true;
+      new(reinterpret_cast<First*>(data)) First(f);   
+      return *this;
+    }
+
+    /// \brief Set to the default value of the \c Second type.
+    ///
+    /// This function sets the variant to the default value of the \c
+    /// Second type.
+    BiVariant& setSecond() {
+      destroy();
+      flag = false;
+      new(reinterpret_cast<Second*>(data)) Second();   
+      return *this;
+    }
+
+    /// \brief Set to the given value of the \c Second type.
+    ///
+    /// This function sets the variant to the given value of the \c
+    /// Second type.
+    BiVariant& setSecond(const Second& s) {
+      destroy();
+      flag = false;
+      new(reinterpret_cast<Second*>(data)) Second(s);   
+      return *this;
+    }
+
+    /// \brief Operator form of the \c setFirst()
+    BiVariant& operator=(const First& f) {
+      return setFirst(f);
+    }
+
+    /// \brief Operator form of the \c setSecond()
+    BiVariant& operator=(const Second& s) {
+      return setSecond(s);
+    }
+
+    /// \brief Assign operator
+    BiVariant& operator=(const BiVariant& bivariant) {
+      if (this == &bivariant) return *this;
+      destroy();
+      flag = bivariant.flag;
+      if (flag) {
+        new(reinterpret_cast<First*>(data)) First(bivariant.first());      
+      } else {
+        new(reinterpret_cast<Second*>(data)) Second(bivariant.second());      
+      }
+      return *this;
+    }
+
+    /// \brief Reference to the value
+    ///
+    /// Reference to the value of the \c First type.
+    /// \pre The BiVariant should store value of \c First type.
+    First& first() {
+      LEMON_ASSERT(flag, WrongStateError());
+      return *reinterpret_cast<First*>(data); 
+    }
+
+    /// \brief Const reference to the value
+    ///
+    /// Const reference to the value of the \c First type.
+    /// \pre The BiVariant should store value of \c First type.
+    const First& first() const { 
+      LEMON_ASSERT(flag, WrongStateError());
+      return *reinterpret_cast<const First*>(data); 
+    }
+
+    /// \brief Operator form of the \c first()
+    operator First&() { return first(); }
+    /// \brief Operator form of the const \c first()
+    operator const First&() const { return first(); }
+
+    /// \brief Reference to the value
+    ///
+    /// Reference to the value of the \c Second type.
+    /// \pre The BiVariant should store value of \c Second type.
+    Second& second() { 
+      LEMON_ASSERT(!flag, WrongStateError());
+      return *reinterpret_cast<Second*>(data); 
+    }
+
+    /// \brief Const reference to the value
+    ///
+    /// Const reference to the value of the \c Second type.
+    /// \pre The BiVariant should store value of \c Second type.
+    const Second& second() const { 
+      LEMON_ASSERT(!flag, WrongStateError());
+      return *reinterpret_cast<const Second*>(data); 
+    }
+
+    /// \brief Operator form of the \c second()
+    operator Second&() { return second(); }
+    /// \brief Operator form of the const \c second()
+    operator const Second&() const { return second(); }
+
+    /// \brief %True when the variant is in the first state
+    ///
+    /// %True when the variant stores value of the \c First type.
+    bool firstState() const { return flag; }
+
+    /// \brief %True when the variant is in the second state
+    ///
+    /// %True when the variant stores value of the \c Second type.
+    bool secondState() const { return !flag; }
+
+  private:
+
+    void destroy() {
+      if (flag) {
+        reinterpret_cast<First*>(data)->~First();
+      } else {
+        reinterpret_cast<Second*>(data)->~Second();
+      }
+    }
+    
+    char data[_variant_bits::CTMax<sizeof(First), sizeof(Second)>::value];
+    bool flag;
+  };
+
+  namespace _variant_bits {
+    
+    template <int _idx, typename _TypeMap>
+    struct Memory {
+
+      typedef typename _TypeMap::template Map<_idx>::Type Current;
+
+      static void destroy(int index, char* place) {
+        if (index == _idx) {
+          reinterpret_cast<Current*>(place)->~Current();
+        } else {
+          Memory<_idx - 1, _TypeMap>::destroy(index, place);
+        }
+      }
+
+      static void copy(int index, char* to, const char* from) {
+        if (index == _idx) {
+          new (reinterpret_cast<Current*>(to))
+            Current(reinterpret_cast<const Current*>(from));
+        } else {
+          Memory<_idx - 1, _TypeMap>::copy(index, to, from);
+        }
+      }
+
+    };
+
+    template <typename _TypeMap>
+    struct Memory<-1, _TypeMap> {
+
+      static void destroy(int, char*) {
+        LEMON_ASSERT(false, "Wrong Variant Index.");
+      }
+
+      static void copy(int, char*, const char*) {
+        LEMON_ASSERT(false, "Wrong Variant Index.");
+      }
+    };
+
+    template <int _idx, typename _TypeMap>
+    struct Size {
+      static const int value = 
+      CTMax<sizeof(typename _TypeMap::template Map<_idx>::Type), 
+            Size<_idx - 1, _TypeMap>::value>::value;
+    };
+
+    template <typename _TypeMap>
+    struct Size<0, _TypeMap> {
+      static const int value = 
+      sizeof(typename _TypeMap::template Map<0>::Type);
+    };
+
+  }
+
+  /// \brief Variant type
+  ///
+  /// Simple Variant type. The Variant type is a type safe union. The
+  /// C++ has strong limitations for using unions, by example we
+  /// cannot store type with non default constructor or destructor in
+  /// a union. This class always knowns the current state of the
+  /// variant and it cares for the proper construction and
+  /// destruction.
+  ///
+  /// \param _num The number of the types which can be stored in the
+  /// variant type.
+  /// \param _TypeMap This class describes the types of the Variant. The
+  /// _TypeMap::Map<index>::Type should be a valid type for each index 
+  /// in the range {0, 1, ..., _num - 1}. The \c VariantTypeMap is helper
+  /// class to define such type mappings up to 10 types.
+  ///
+  /// And the usage of the class:
+  ///\code
+  /// typedef Variant<3, VariantTypeMap<int, std::string, double> > MyVariant;
+  /// MyVariant var;
+  /// var.set<0>(12);
+  /// std::cout << var.get<0>() << std::endl;
+  /// var.set<1>("alpha");
+  /// std::cout << var.get<1>() << std::endl;
+  /// var.set<2>(0.75);
+  /// std::cout << var.get<2>() << std::endl;
+  ///\endcode
+  ///
+  /// The result of course:
+  ///\code
+  /// 12
+  /// alpha
+  /// 0.75
+  ///\endcode
+  template <int _num, typename _TypeMap>
+  class Variant {
+  public:
+
+    static const int num = _num;
+
+    typedef _TypeMap TypeMap;
+
+    struct WrongStateError : public lemon::LogicError {
+    public:
+      virtual const char* what() const throw() {
+        return "lemon::Variant::WrongStateError";
+      }
+    };
+
+    /// \brief Constructor
+    ///
+    /// This constructor initalizes to the default value of the \c type
+    /// with 0 index.
+    Variant() {
+      flag = 0;
+      new(reinterpret_cast<typename TypeMap::template Map<0>::Type*>(data)) 
+        typename TypeMap::template Map<0>::Type();
+    }
+
+
+    /// \brief Copy constructor
+    ///
+    /// Copy constructor
+    Variant(const Variant& variant) {
+      flag = variant.flag;
+      _variant_bits::Memory<num - 1, TypeMap>::copy(flag, data, variant.data);
+    }
+
+    /// \brief Assign operator
+    ///
+    /// Assign operator
+    Variant& operator=(const Variant& variant) {
+      if (this == &variant) return *this;
+      _variant_bits::Memory<num - 1, TypeMap>::
+        destroy(flag, data);
+      flag = variant.flag;
+      _variant_bits::Memory<num - 1, TypeMap>::
+        copy(flag, data, variant.data);
+      return *this;
+    }
+
+    /// \brief Destrcutor
+    ///
+    /// Destructor
+    ~Variant() {
+      _variant_bits::Memory<num - 1, TypeMap>::destroy(flag, data);
+    }
+
+    /// \brief Set to the default value of the type with \c _idx index.
+    ///
+    /// This function sets the variant to the default value of the
+    /// type with \c _idx index.
+    template <int _idx>
+    Variant& set() {
+      _variant_bits::Memory<num - 1, TypeMap>::destroy(flag, data);
+      flag = _idx;
+      new(reinterpret_cast<typename TypeMap::template Map<_idx>::Type*>(data)) 
+        typename TypeMap::template Map<_idx>::Type();
+      return *this;
+    }
+
+    /// \brief Set to the given value of the type with \c _idx index.
+    ///
+    /// This function sets the variant to the given value of the type
+    /// with \c _idx index.
+    template <int _idx>
+    Variant& set(const typename _TypeMap::template Map<_idx>::Type& init) {
+      _variant_bits::Memory<num - 1, TypeMap>::destroy(flag, data);
+      flag = _idx;
+      new(reinterpret_cast<typename TypeMap::template Map<_idx>::Type*>(data)) 
+        typename TypeMap::template Map<_idx>::Type(init);
+      return *this;
+    }
+
+    /// \brief Gets the current value of the type with \c _idx index.
+    ///
+    /// Gets the current value of the type with \c _idx index.
+    template <int _idx>
+    const typename TypeMap::template Map<_idx>::Type& get() const {
+      LEMON_ASSERT(_idx == flag, "Wrong Variant Index.");
+      return *reinterpret_cast<const typename TypeMap::
+        template Map<_idx>::Type*>(data); 
+    }
+
+    /// \brief Gets the current value of the type with \c _idx index.
+    ///
+    /// Gets the current value of the type with \c _idx index.
+    template <int _idx>
+    typename _TypeMap::template Map<_idx>::Type& get() {
+      LEMON_ASSERT(_idx == flag, "Wrong Variant Index.");
+      return *reinterpret_cast<typename TypeMap::template Map<_idx>::Type*>
+        (data); 
+    }
+
+    /// \brief Returns the current state of the variant.
+    ///
+    /// Returns the current state of the variant.
+    int state() const {
+      return flag;
+    }
+
+  private:
+    
+    char data[_variant_bits::Size<num - 1, TypeMap>::value];
+    int flag;
+  };
+
+  namespace _variant_bits {
+
+    template <int _index, typename _List>
+    struct Get {
+      typedef typename Get<_index - 1, typename _List::Next>::Type Type;
+    };
+
+    template <typename _List>
+    struct Get<0, _List> {
+      typedef typename _List::Type Type;
+    };
+
+    struct List {};
+    
+    template <typename _Type, typename _List>
+    struct Insert {
+      typedef _List Next;
+      typedef _Type Type;
+    };
+
+    template <int _idx, typename _T0, typename _T1, typename _T2, 
+              typename _T3, typename _T5, typename _T4, typename _T6,
+              typename _T7, typename _T8, typename _T9>
+    struct Mapper {
+      typedef List L10;
+      typedef Insert<_T9, L10> L9;
+      typedef Insert<_T8, L9> L8;
+      typedef Insert<_T7, L8> L7;
+      typedef Insert<_T6, L7> L6;
+      typedef Insert<_T5, L6> L5;
+      typedef Insert<_T4, L5> L4;
+      typedef Insert<_T3, L4> L3;
+      typedef Insert<_T2, L3> L2;
+      typedef Insert<_T1, L2> L1;
+      typedef Insert<_T0, L1> L0;
+      typedef typename Get<_idx, L0>::Type Type;
+    };
+    
+  }
+
+  /// \brief Helper class for Variant
+  ///
+  /// Helper class to define type mappings for Variant. This class
+  /// converts the template parameters to be mappable by integer.
+  /// \see Variant
+  template <
+    typename _T0, 
+    typename _T1 = void, typename _T2 = void, typename _T3 = void,
+    typename _T5 = void, typename _T4 = void, typename _T6 = void,
+    typename _T7 = void, typename _T8 = void, typename _T9 = void>
+  struct VariantTypeMap {
+    template <int _idx>
+    struct Map {
+      typedef typename _variant_bits::
+      Mapper<_idx, _T0, _T1, _T2, _T3, _T4, _T5, _T6, _T7, _T8, _T9>::Type
+      Type;
+    };
+  };
+  
+}
+
+
+#endif
Index: lemon/bits/vector_map.h
===================================================================
--- lemon/bits/vector_map.h	(revision 2553)
+++ lemon/bits/vector_map.h	(revision 2553)
@@ -0,0 +1,243 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BITS_VECTOR_MAP_H
+#define LEMON_BITS_VECTOR_MAP_H
+
+#include <vector>
+#include <algorithm>
+
+#include <lemon/bits/traits.h>
+#include <lemon/bits/utility.h>
+
+#include <lemon/bits/alteration_notifier.h>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+
+///\ingroup graphbits
+///
+///\file
+///\brief Vector based graph maps.
+namespace lemon {
+
+  /// \ingroup graphbits
+  ///
+  /// \brief Graph map based on the std::vector storage.
+  ///
+  /// The VectorMap template class is graph map structure what
+  /// automatically updates the map when a key is added to or erased from
+  /// the map. This map type uses the std::vector to store the values.
+  ///
+  /// \param Notifier The AlterationNotifier that will notify this map.
+  /// \param Item The item type of the graph items.
+  /// \param Value The value type of the map.
+  /// 
+  /// \author Balazs Dezso  	
+  template <typename _Graph, typename _Item, typename _Value>
+  class VectorMap 
+    : public ItemSetTraits<_Graph, _Item>::ItemNotifier::ObserverBase {
+  private:
+		
+    /// The container type of the map.
+    typedef std::vector<_Value> Container;	
+
+  public:
+
+    /// The graph type of the map. 
+    typedef _Graph Graph;
+    /// The item type of the map.
+    typedef _Item Item;
+    /// The reference map tag.
+    typedef True ReferenceMapTag;
+
+    /// The key type of the map.
+    typedef _Item Key;
+    /// The value type of the map.
+    typedef _Value Value;
+
+    /// The notifier type.
+    typedef typename ItemSetTraits<_Graph, _Item>::ItemNotifier Notifier;
+
+    /// The map type.
+    typedef VectorMap Map;
+    /// The base class of the map.
+    typedef typename Notifier::ObserverBase Parent;
+
+    /// The reference type of the map;
+    typedef typename Container::reference Reference;
+    /// The const reference type of the map;
+    typedef typename Container::const_reference ConstReference;
+
+
+    /// \brief Constructor to attach the new map into the notifier.
+    ///
+    /// It constructs a map and attachs it into the notifier.
+    /// It adds all the items of the graph to the map.
+    VectorMap(const Graph& graph) {
+      Parent::attach(graph.notifier(Item()));
+      container.resize(Parent::notifier()->maxId() + 1);
+    }
+
+    /// \brief Constructor uses given value to initialize the map. 
+    ///
+    /// It constructs a map uses a given value to initialize the map. 
+    /// It adds all the items of the graph to the map.
+    VectorMap(const Graph& graph, const Value& value) {
+      Parent::attach(graph.notifier(Item()));
+      container.resize(Parent::notifier()->maxId() + 1, value);
+    }
+
+    /// \brief Copy constructor
+    ///
+    /// Copy constructor.
+    VectorMap(const VectorMap& _copy) : Parent() {
+      if (_copy.attached()) {
+	Parent::attach(*_copy.notifier());
+	container = _copy.container;
+      }
+    }
+
+    /// \brief Assign operator.
+    ///
+    /// This operator assigns for each item in the map the
+    /// value mapped to the same item in the copied map.  
+    /// The parameter map should be indiced with the same
+    /// itemset because this assign operator does not change
+    /// the container of the map. 
+    VectorMap& operator=(const VectorMap& cmap) {
+      return operator=<VectorMap>(cmap);
+    }
+
+
+    /// \brief Template assign operator.
+    ///
+    /// The given parameter should be conform to the ReadMap
+    /// concecpt and could be indiced by the current item set of
+    /// the NodeMap. In this case the value for each item
+    /// is assigned by the value of the given ReadMap. 
+    template <typename CMap>
+    VectorMap& operator=(const CMap& cmap) {
+      checkConcept<concepts::ReadMap<Key, _Value>, CMap>();
+      const typename Parent::Notifier* nf = Parent::notifier();
+      Item it;
+      for (nf->first(it); it != INVALID; nf->next(it)) {
+        set(it, cmap[it]);
+      }
+      return *this;
+    }
+    
+  public:
+
+    /// \brief The subcript operator.
+    ///
+    /// The subscript operator. The map can be subscripted by the
+    /// actual items of the graph.      
+    Reference operator[](const Key& key) {
+      return container[Parent::notifier()->id(key)];
+    } 
+		
+    /// \brief The const subcript operator.
+    ///
+    /// The const subscript operator. The map can be subscripted by the
+    /// actual items of the graph. 
+    ConstReference operator[](const Key& key) const {
+      return container[Parent::notifier()->id(key)];
+    }
+
+
+    /// \brief The setter function of the map.
+    ///
+    /// It the same as operator[](key) = value expression.
+    void set(const Key& key, const Value& value) {
+      (*this)[key] = value;
+    }
+
+  protected:
+
+    /// \brief Adds a new key to the map.
+    ///		
+    /// It adds a new key to the map. It called by the observer notifier
+    /// and it overrides the add() member function of the observer base.     
+    virtual void add(const Key& key) {
+      int id = Parent::notifier()->id(key);
+      if (id >= int(container.size())) {
+	container.resize(id + 1);
+      }
+    }
+
+    /// \brief Adds more new keys to the map.
+    ///		
+    /// It adds more new keys to the map. It called by the observer notifier
+    /// and it overrides the add() member function of the observer base.     
+    virtual void add(const std::vector<Key>& keys) {
+      int max = container.size() - 1;
+      for (int i = 0; i < int(keys.size()); ++i) {
+        int id = Parent::notifier()->id(keys[i]);
+        if (id >= max) {
+          max = id;
+        }
+      }
+      container.resize(max + 1);
+    }
+
+    /// \brief Erase a key from the map.
+    ///
+    /// Erase a key from the map. It called by the observer notifier
+    /// and it overrides the erase() member function of the observer base.     
+    virtual void erase(const Key& key) {
+      container[Parent::notifier()->id(key)] = Value();
+    }
+
+    /// \brief Erase more keys from the map.
+    ///
+    /// Erase more keys from the map. It called by the observer notifier
+    /// and it overrides the erase() member function of the observer base.     
+    virtual void erase(const std::vector<Key>& keys) {
+      for (int i = 0; i < int(keys.size()); ++i) {
+	container[Parent::notifier()->id(keys[i])] = Value();
+      }
+    }
+    
+    /// \brief Buildes the map.
+    ///	
+    /// It buildes the map. It called by the observer notifier
+    /// and it overrides the build() member function of the observer base.
+    virtual void build() { 
+      int size = Parent::notifier()->maxId() + 1;
+      container.reserve(size);
+      container.resize(size);
+    }
+
+    /// \brief Clear the map.
+    ///
+    /// It erase all items from the map. It called by the observer notifier
+    /// and it overrides the clear() member function of the observer base.     
+    virtual void clear() { 
+      container.clear();
+    }
+    
+  private:
+		
+    Container container;
+
+  };
+
+}
+
+#endif
Index: lemon/bpugraph_adaptor.h
===================================================================
--- lemon/bpugraph_adaptor.h	(revision 2617)
+++ lemon/bpugraph_adaptor.h	(revision 2617)
@@ -0,0 +1,606 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BPUGRAPH_ADAPTOR_H
+#define LEMON_BPUGRAPH_ADAPTOR_H
+
+#include <lemon/bits/invalid.h>
+#include <lemon/maps.h>
+
+#include <lemon/bits/graph_adaptor_extender.h>
+
+#include <lemon/bits/traits.h>
+
+#include <iostream>
+
+///\ingroup graph_adaptors
+///\file
+///\brief Several graph adaptors.
+///
+///This file contains several useful bpugraph adaptor functions.
+///
+///\author Balazs Dezso
+
+namespace lemon {
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief Base type for the Bipartite Undirected Graph Adaptors
+  ///
+  /// This is the base type for most of LEMON bpugraph adaptors. 
+  /// This class implements a trivial graph adaptor i.e. it only wraps the 
+  /// functions and types of the graph. The purpose of this class is to 
+  /// make easier implementing graph adaptors. E.g. if an adaptor is 
+  /// considered which differs from the wrapped graph only in some of its 
+  /// functions or types, then it can be derived from BpUGraphAdaptor, and 
+  /// only the differences should be implemented.
+  ///
+  /// \author Balazs Dezso 
+  template<typename _BpUGraph>
+  class BpUGraphAdaptorBase {
+  public:
+    typedef _BpUGraph Graph;
+    typedef Graph ParentGraph;
+
+  protected:
+    Graph* graph;
+
+    BpUGraphAdaptorBase() : graph(0) {}
+
+    void setGraph(Graph& _graph) { graph = &_graph; }
+
+    Graph& getGraph() { return *graph; }
+    const Graph& getGraph() const { return *graph; }
+
+  public:
+
+    BpUGraphAdaptorBase(Graph& _graph) : graph(&_graph) {}
+ 
+    typedef typename Graph::Node Node;
+    typedef typename Graph::ANode ANode;
+    typedef typename Graph::BNode BNode;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+   
+    void first(Node& i) const { graph->first(i); }
+    void firstANode(Node& i) const { graph->firstANode(i); }
+    void firstBNode(Node& i) const { graph->firstBNode(i); }
+    void first(Edge& i) const { graph->first(i); }
+    void first(UEdge& i) const { graph->first(i); }
+    void firstIn(Edge& i, const Node& n) const { graph->firstIn(i, n); }
+    void firstOut(Edge& i, const Node& n ) const { graph->firstOut(i, n); }
+    void firstInc(UEdge &i, bool &d, const Node &n) const {
+      graph->firstInc(i, d, n);
+    }
+    void firstFromANode(UEdge& i, const Node& n) const {
+      graph->firstFromANode(i, n);
+    }
+    void firstFromBNode(UEdge& i, const Node& n) const {
+      graph->firstFromBNode(i, n);
+    }
+
+    void next(Node& i) const { graph->next(i); }
+    void nextANode(Node& i) const { graph->nextANode(i); }
+    void nextBNode(Node& i) const { graph->nextBNode(i); }
+    void next(Edge& i) const { graph->next(i); }
+    void next(UEdge& i) const { graph->next(i); }
+    void nextIn(Edge& i) const { graph->nextIn(i); }
+    void nextOut(Edge& i) const { graph->nextOut(i); }
+    void nextInc(UEdge &i, bool &d) const { graph->nextInc(i, d); }
+    void nextFromANode(UEdge& i) const { graph->nextFromANode(i); }
+    void nextFromBNode(UEdge& i) const { graph->nextFromBNode(i); }
+
+    Node source(const UEdge& e) const { return graph->source(e); }
+    Node target(const UEdge& e) const { return graph->target(e); }
+
+    Node source(const Edge& e) const { return graph->source(e); }
+    Node target(const Edge& e) const { return graph->target(e); }
+
+    Node aNode(const UEdge& e) const { return graph->aNode(e); }
+    Node bNode(const UEdge& e) const { return graph->bNode(e); }
+
+    bool aNode(const Node& n) const { return graph->aNode(n); }
+    bool bNode(const Node& n) const { return graph->bNode(n); }
+
+    typedef NodeNumTagIndicator<Graph> NodeNumTag;
+    int nodeNum() const { return graph->nodeNum(); }
+    int aNodeNum() const { return graph->aNodeNum(); }
+    int bNodeNum() const { return graph->bNodeNum(); }
+    
+    typedef EdgeNumTagIndicator<Graph> EdgeNumTag;
+    int edgeNum() const { return graph->edgeNum(); }
+    int uEdgeNum() const { return graph->uEdgeNum(); }
+
+    typedef FindEdgeTagIndicator<Graph> FindEdgeTag;
+    Edge findEdge(const Node& u, const Node& v, 
+		  const Edge& prev = INVALID) {
+      return graph->findEdge(u, v, prev);
+    }
+    UEdge findUEdge(const Node& u, const Node& v, 
+                    const UEdge& prev = INVALID) {
+      return graph->findUEdge(u, v, prev);
+    }
+  
+    Node addANode() const { return graph->addANode(); }
+    Node addBNode() const { return graph->addBNode(); }
+    UEdge addEdge(const Node& u, const Node& v) const { 
+      return graph->addEdge(u, v); 
+    }
+
+    void erase(const Node& i) const { graph->erase(i); }
+    void erase(const UEdge& i) const { graph->erase(i); }
+  
+    void clear() const { graph->clear(); }
+
+    bool direction(const Edge& e) const { return graph->direction(e); }
+    Edge direct(const UEdge& e, bool d) const { return graph->direct(e, d); }
+    
+    int id(const Node& v) const { return graph->id(v); }
+    int id(const ANode& v) const { return graph->id(v); }
+    int id(const BNode& v) const { return graph->id(v); }
+    int id(const Edge& e) const { return graph->id(e); }
+    int id(const UEdge& e) const { return graph->id(e); }
+
+    Node nodeFromId(int ix) const { return graph->nodeFromId(ix); }
+    ANode nodeFromANodeId(int ix) const { return graph->nodeFromANodeId(ix); }
+    BNode nodeFromBNodeId(int ix) const { return graph->nodeFromBNodeId(ix); }
+    Edge edgeFromId(int ix) const { return graph->edgeFromId(ix); }
+    UEdge uEdgeFromId(int ix) const { return graph->uEdgeFromId(ix); }
+
+    int maxNodeId() const { return graph->maxNodeId(); }
+    int maxANodeId() const { return graph->maxANodeId(); }
+    int maxBNodeId() const { return graph->maxBNodeId(); }
+    int maxEdgeId() const { return graph->maxEdgeId(); }
+    int maxUEdgeId() const { return graph->maxEdgeId(); }
+
+    typedef typename ItemSetTraits<Graph, Node>::ItemNotifier NodeNotifier;
+    NodeNotifier& notifier(Node) const {
+      return graph->notifier(Node()); 
+    } 
+
+    typedef typename ItemSetTraits<Graph, ANode>::ItemNotifier ANodeNotifier;
+    ANodeNotifier& notifier(ANode) const {
+      return graph->notifier(ANode());
+    } 
+
+    typedef typename ItemSetTraits<Graph, BNode>::ItemNotifier BNodeNotifier;
+    BNodeNotifier& notifier(BNode) const {
+      return graph->notifier(BNode());
+    } 
+
+    typedef typename ItemSetTraits<Graph, Edge>::ItemNotifier EdgeNotifier;
+    EdgeNotifier& notifier(Edge) const {
+      return graph->notifier(Edge());
+    } 
+
+    typedef typename ItemSetTraits<Graph, UEdge>::ItemNotifier UEdgeNotifier;
+    UEdgeNotifier& notifier(UEdge) const {
+      return graph->notifier(UEdge());
+    } 
+
+    template <typename _Value>
+    class NodeMap : public Graph::template NodeMap<_Value> {
+    public:
+      typedef typename Graph::template NodeMap<_Value> Parent;
+      explicit NodeMap(const BpUGraphAdaptorBase<Graph>& ga) 
+	: Parent(*ga.graph) {}
+      NodeMap(const BpUGraphAdaptorBase<Graph>& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      NodeMap& operator=(const NodeMap& cmap) {
+	return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class ANodeMap : public Graph::template ANodeMap<_Value> {
+    public:
+      typedef typename Graph::template ANodeMap<_Value> Parent;
+      explicit ANodeMap(const BpUGraphAdaptorBase& ga) 
+	: Parent(*ga.graph) {}
+      ANodeMap(const BpUGraphAdaptorBase& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      ANodeMap& operator=(const ANodeMap& cmap) {
+	return operator=<ANodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      ANodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class BNodeMap : public Graph::template BNodeMap<_Value> {
+    public:
+      typedef typename Graph::template BNodeMap<_Value> Parent;
+      explicit BNodeMap(const BpUGraphAdaptorBase<Graph>& ga) 
+	: Parent(*ga.graph) {}
+      BNodeMap(const BpUGraphAdaptorBase<Graph>& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      BNodeMap& operator=(const BNodeMap& cmap) {
+	return operator=<BNodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      BNodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class EdgeMap : public Graph::template EdgeMap<_Value> {
+    public:
+      typedef typename Graph::template EdgeMap<_Value> Parent;
+      explicit EdgeMap(const BpUGraphAdaptorBase<Graph>& ga) 
+	: Parent(*ga.graph) {}
+      EdgeMap(const BpUGraphAdaptorBase<Graph>& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class UEdgeMap : public Graph::template UEdgeMap<_Value> {
+    public:
+      typedef typename Graph::template UEdgeMap<_Value> Parent;
+      explicit UEdgeMap(const BpUGraphAdaptorBase<Graph>& ga) 
+	: Parent(*ga.graph) {}
+      UEdgeMap(const BpUGraphAdaptorBase<Graph>& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      UEdgeMap& operator=(const UEdgeMap& cmap) {
+	return operator=<UEdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      UEdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+  };
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief Trivial Bipartite Undirected Graph Adaptor
+  ///
+  /// Trivial Bipartite Undirected Graph Adaptor. It does not change
+  /// the functionality of the adapted graph.
+  template <typename _BpUGraph>
+  class BpUGraphAdaptor 
+    : public BpUGraphAdaptorExtender< BpUGraphAdaptorBase<_BpUGraph> > { 
+  public:
+    typedef _BpUGraph Graph;
+    typedef BpUGraphAdaptorExtender<BpUGraphAdaptorBase<_BpUGraph> > Parent;
+  protected:
+    BpUGraphAdaptor() : Parent() {}
+
+  public:
+    explicit BpUGraphAdaptor(Graph& _graph) { setGraph(_graph); }
+  };
+
+  template <typename _BpUGraph>
+  class SwapBpUGraphAdaptorBase : public BpUGraphAdaptorBase<_BpUGraph> {
+  public:
+    
+    typedef _BpUGraph Graph;
+    typedef BpUGraphAdaptorBase<_BpUGraph> Parent;
+
+  protected:
+    
+    SwapBpUGraphAdaptorBase() {}
+
+  public:
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::BNode ANode;
+    typedef typename Parent::ANode BNode;
+    typedef typename Parent::Edge Edge;
+    typedef typename Parent::UEdge UEdge;
+
+    bool direction(const Edge& e) const { return !Parent::direction(e); }
+    Edge direct(const UEdge& e, bool b) const { return Parent::direct(e, !b); }
+
+    Node aNode(const UEdge& e) const { return Parent::bNode(e); }
+    Node bNode(const UEdge& e) const { return Parent::aNode(e); }
+
+    bool aNode(const Node& n) const { return Parent::bNode(n); }
+    bool bNode(const Node& n) const { return Parent::aNode(n); }
+
+    void firstANode(Node& i) const { Parent::firstBNode(i); }
+    void firstBNode(Node& i) const { Parent::firstANode(i); }
+
+    void nextANode(Node& i) const { Parent::nextBNode(i); }
+    void nextBNode(Node& i) const { Parent::nextANode(i); }
+
+    void firstFromANode(UEdge& i, const Node& n) const {
+      Parent::firstFromBNode(i, n);
+    }
+    void firstFromBNode(UEdge& i, const Node& n) const {
+      Parent::firstFromANode(i, n);
+    }
+
+    void nextFromANode(UEdge& i) const { Parent::nextFromBNode(i); }
+    void nextFromBNode(UEdge& i) const { Parent::nextFromANode(i); }
+
+    int id(const ANode& v) const { return Parent::id(v); }
+    int id(const BNode& v) const { return Parent::id(v); }
+
+    ANode nodeFromANodeId(int ix) const { return Parent::nodeFromBNodeId(ix); }
+    BNode nodeFromBNodeId(int ix) const { return Parent::nodeFromANodeId(ix); }
+
+    int maxANodeId() const { return Parent::maxBNodeId(); }
+    int maxBNodeId() const { return Parent::maxANodeId(); }
+
+    int aNodeNum() const { return Parent::bNodeNum(); }
+    int bNodeNum() const { return Parent::aNodeNum(); }
+
+    typedef typename Parent::BNodeNotifier ANodeNotifier;
+    ANodeNotifier& notifier(ANode) const {
+      return Parent::notifier(typename Parent::BNode());
+    } 
+
+    typedef typename Parent::ANodeNotifier BNodeNotifier;
+    BNodeNotifier& notifier(BNode) const {
+      return Parent::notifier(typename Parent::ANode());
+    } 
+
+    template <typename _Value>
+    class ANodeMap : public Graph::template BNodeMap<_Value> {
+    public:
+      typedef typename Graph::template BNodeMap<_Value> Parent;
+      explicit ANodeMap(const SwapBpUGraphAdaptorBase& ga) 
+	: Parent(*ga.graph) {}
+      ANodeMap(const SwapBpUGraphAdaptorBase& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      ANodeMap& operator=(const ANodeMap& cmap) {
+	return operator=<ANodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      ANodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class BNodeMap : public Graph::template ANodeMap<_Value> {
+    public:
+      typedef typename Graph::template ANodeMap<_Value> Parent;
+      explicit BNodeMap(const SwapBpUGraphAdaptorBase<Graph>& ga) 
+	: Parent(*ga.graph) {}
+      BNodeMap(const SwapBpUGraphAdaptorBase<Graph>& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      BNodeMap& operator=(const BNodeMap& cmap) {
+	return operator=<BNodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      BNodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+    
+  };
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief Bipartite graph adaptor which swaps the two nodeset.
+  ///
+  /// Bipartite graph adaptor which swaps the two nodeset. The adaptor's
+  /// anode-set will be the original graph's bnode-set and the adaptor's
+  /// bnode-set will be the original graph's anode-set.
+  ///
+  /// As example look at an algorithm what can be sped up with the
+  /// swap bipartite undirected graph adaptor. If we want to find the
+  /// maximum matching in the bipartite graph then it will be not changed
+  /// if we swap the two nodesets. But the algorithm use the two nodeset
+  /// different way. If we swap the nodesets it provides different
+  /// running time. We run a test on random bipartite graphs with
+  /// different rate of the anode-set size and bnode-set size.
+  /// We always made graphs with 10000 nodes and 20000 edges and we
+  /// computed the maximum cardinality matching with the Hopcroft-Karp 
+  /// algorithm.
+  ///
+  /// The next diagram shows the running time of the tests. If the anode-set
+  /// is smaller than the bnode-set the running time is better than with 
+  /// the swapped graph. Other conclusion is that the running time
+  /// is greater when the two nodesets size are nearly equal. 
+  ///
+  /// \image html swap_test.png
+  /// \image latex swap_test.eps "Swapping nodesets" width=\textwidth
+  /// 
+  /// The next part shows how can we swap the two nodeset:
+  ///
+  ///\code
+  /// typedef SwapBpUGraphAdaptor<BpUGraph> SBpUGraph;
+  /// SBpUGraph sbpugraph(bpugraph);
+  /// MaxBipartiteMatching<SBpUGraph> sbpumatch(sbpugraph);
+  ///\endcode
+  template <typename _BpUGraph>
+  class SwapBpUGraphAdaptor 
+    : public BpUGraphAdaptorExtender<SwapBpUGraphAdaptorBase<_BpUGraph> > { 
+  public:
+
+    typedef _BpUGraph Graph;
+    typedef BpUGraphAdaptorExtender<SwapBpUGraphAdaptorBase<_BpUGraph> > 
+    Parent;
+
+  protected:
+    SwapBpUGraphAdaptor() : Parent() {}
+
+  public:
+
+    /// \brief Construct a swapped graph.
+    ///
+    /// Construct a swapped graph.
+    explicit SwapBpUGraphAdaptor(Graph& _graph) { setGraph(_graph); }
+
+  };
+
+
+  template <typename _BpUGraph, 
+            typename _ANMatchingMap, typename _BNMatchingMap>
+  class MatchingBpUGraphAdaptorBase 
+    : public BpUGraphAdaptorBase<const _BpUGraph>
+  {
+  public:
+    
+    typedef _BpUGraph Graph;
+    typedef _ANMatchingMap ANodeMatchingMap;
+    typedef _BNMatchingMap BNodeMatchingMap;
+
+    typedef BpUGraphAdaptorBase<const _BpUGraph> Parent;
+
+  protected:
+    
+    MatchingBpUGraphAdaptorBase() {}
+
+    void setANodeMatchingMap(ANodeMatchingMap& _anode_matching) {
+      anode_matching = &_anode_matching;
+    }
+
+    void setBNodeMatchingMap(BNodeMatchingMap& _bnode_matching) {
+      bnode_matching = &_bnode_matching;
+    }
+
+  public:
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+    void firstOut(Edge& edge, const Node& node) const {
+      if (Parent::aNode(node)) {
+        Parent::firstOut(edge, node);
+        if (edge != INVALID && (*anode_matching)[node] == edge) {
+          Parent::nextOut(edge);
+        }
+      } else {
+        edge = (*bnode_matching)[node] != INVALID ?
+          Parent::direct((*bnode_matching)[node], false) : INVALID;
+      }
+    }
+
+    void nextOut(Edge& edge) const {
+      if (Parent::aNode(Parent::source(edge))) {
+        Parent::nextOut(edge);
+        if (edge != INVALID && (*anode_matching)[Parent::aNode(edge)] == edge) {
+          Parent::nextOut(edge);
+        }
+      } else {
+        edge = INVALID;
+      }
+    }
+ 
+    void firstIn(Edge& edge, const Node& node) const {
+      if (Parent::aNode(node)) {
+        edge = (*bnode_matching)[node] != INVALID ?
+          Parent::direct((*anode_matching)[node], false) : INVALID;
+      } else {
+        Parent::firstIn(edge, node);
+        if (edge != INVALID && (*bnode_matching)[node] == edge) {
+          Parent::nextIn(edge);
+        }
+      }
+    }
+
+    void nextIn(Edge& edge) const {
+      if (Parent::aNode(Parent::target(edge))) {
+        edge = INVALID;
+      } else {
+        Parent::nextIn(edge);
+        if (edge != INVALID && (*bnode_matching)[Parent::bNode(edge)] == edge) {
+          Parent::nextIn(edge);
+        }
+      }
+    } 
+
+  private:
+    ANodeMatchingMap* anode_matching;
+    BNodeMatchingMap* bnode_matching;
+  };
+
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief Bipartite graph adaptor to implement matching algorithms.
+  ///
+  /// Bipartite graph adaptor to implement matchings. It implements
+  /// the residual graph of the matching.
+  template <typename _BpUGraph, 
+            typename _ANMatchingMap = 
+            typename _BpUGraph::template ANodeMap<typename _BpUGraph::UEdge>, 
+            typename _BNMatchingMap =
+            typename _BpUGraph::template BNodeMap<typename _BpUGraph::UEdge> >
+  class MatchingBpUGraphAdaptor 
+    : public BpUGraphAdaptorExtender<
+    MatchingBpUGraphAdaptorBase<_BpUGraph, _ANMatchingMap, _BNMatchingMap> > 
+  { 
+  public:
+
+    typedef _BpUGraph BpUGraph;
+    typedef _BpUGraph Graph;
+    typedef _ANMatchingMap ANodeMatchingMap;
+    typedef _BNMatchingMap BNodeMatchingMap;
+    typedef BpUGraphAdaptorExtender<
+      MatchingBpUGraphAdaptorBase<BpUGraph, 
+                                  ANodeMatchingMap, BNodeMatchingMap> > 
+    Parent;
+
+  protected:
+    MatchingBpUGraphAdaptor() : Parent() {}
+
+  public:
+
+    MatchingBpUGraphAdaptor(const Graph& _graph, 
+                            ANodeMatchingMap& _anode_matching,
+                            BNodeMatchingMap& _bnode_matching) {
+      setGraph(_graph);
+      setANodeMatchingMap(_anode_matching);
+      setBNodeMatchingMap(_bnode_matching);
+    }
+
+  };
+
+}
+
+#endif
Index: lemon/bucket_heap.h
===================================================================
--- lemon/bucket_heap.h	(revision 2553)
+++ lemon/bucket_heap.h	(revision 2553)
@@ -0,0 +1,831 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BUCKET_HEAP_H
+#define LEMON_BUCKET_HEAP_H
+
+///\ingroup auxdat
+///\file
+///\brief Bucket Heap implementation.
+
+#include <vector>
+#include <utility>
+#include <functional>
+
+namespace lemon {
+
+  /// \ingroup auxdat
+  ///
+  /// \brief A Bucket Heap implementation.
+  ///
+  /// This class implements the \e bucket \e heap data structure. A \e heap
+  /// is a data structure for storing items with specified values called \e
+  /// priorities in such a way that finding the item with minimum priority is
+  /// efficient. The bucket heap is very simple implementation, it can store
+  /// only integer priorities and it stores for each priority in the 
+  /// \f$ [0..C) \f$ range a list of items. So it should be used only when 
+  /// the priorities are small. It is not intended to use as dijkstra heap.
+  ///
+  /// \param _ItemIntMap A read and writable Item int map, used internally
+  /// to handle the cross references.
+  /// \param minimize If the given parameter is true then the heap gives back
+  /// the lowest priority. 
+  template <typename _ItemIntMap, bool minimize = true >
+  class BucketHeap {
+
+  public:
+    /// \e
+    typedef typename _ItemIntMap::Key Item;
+    /// \e
+    typedef int Prio;
+    /// \e
+    typedef std::pair<Item, Prio> Pair;
+    /// \e
+    typedef _ItemIntMap ItemIntMap;
+
+    /// \brief Type to represent the items states.
+    ///
+    /// Each Item element have a state associated to it. It may be "in heap",
+    /// "pre heap" or "post heap". The latter two are indifferent from the
+    /// heap's point of view, but may be useful to the user.
+    ///
+    /// The ItemIntMap \e should be initialized in such way that it maps
+    /// PRE_HEAP (-1) to any element to be put in the heap...
+    enum State {
+      IN_HEAP = 0,
+      PRE_HEAP = -1,
+      POST_HEAP = -2
+    };
+
+  public:
+    /// \brief The constructor.
+    ///
+    /// The constructor.
+    /// \param _index should be given to the constructor, since it is used
+    /// internally to handle the cross references. The value of the map
+    /// should be PRE_HEAP (-1) for each element.
+    explicit BucketHeap(ItemIntMap &_index) : index(_index), minimal(0) {}
+    
+    /// The number of items stored in the heap.
+    ///
+    /// \brief Returns the number of items stored in the heap.
+    int size() const { return data.size(); }
+    
+    /// \brief Checks if the heap stores no items.
+    ///
+    /// Returns \c true if and only if the heap stores no items.
+    bool empty() const { return data.empty(); }
+
+    /// \brief Make empty this heap.
+    /// 
+    /// Make empty this heap. It does not change the cross reference
+    /// map.  If you want to reuse a heap what is not surely empty you
+    /// should first clear the heap and after that you should set the
+    /// cross reference map for each item to \c PRE_HEAP.
+    void clear() { 
+      data.clear(); first.clear(); minimal = 0;
+    }
+
+  private:
+
+    void relocate_last(int idx) {
+      if (idx + 1 < int(data.size())) {
+	data[idx] = data.back();
+	if (data[idx].prev != -1) {
+	  data[data[idx].prev].next = idx;
+	} else {
+	  first[data[idx].value] = idx;
+	}
+	if (data[idx].next != -1) {
+	  data[data[idx].next].prev = idx;
+	}
+	index[data[idx].item] = idx;
+      }
+      data.pop_back();
+    }
+
+    void unlace(int idx) {
+      if (data[idx].prev != -1) {
+	data[data[idx].prev].next = data[idx].next;
+      } else {
+	first[data[idx].value] = data[idx].next;
+      }
+      if (data[idx].next != -1) {
+	data[data[idx].next].prev = data[idx].prev;
+      }
+    }
+
+    void lace(int idx) {
+      if (int(first.size()) <= data[idx].value) {
+	first.resize(data[idx].value + 1, -1);
+      }
+      data[idx].next = first[data[idx].value];
+      if (data[idx].next != -1) {
+	data[data[idx].next].prev = idx;
+      }
+      first[data[idx].value] = idx;
+      data[idx].prev = -1;
+    }
+
+  public:
+    /// \brief Insert a pair of item and priority into the heap.
+    ///
+    /// Adds \c p.first to the heap with priority \c p.second.
+    /// \param p The pair to insert.
+    void push(const Pair& p) {
+      push(p.first, p.second);
+    }
+
+    /// \brief Insert an item into the heap with the given priority.
+    ///    
+    /// Adds \c i to the heap with priority \c p. 
+    /// \param i The item to insert.
+    /// \param p The priority of the item.
+    void push(const Item &i, const Prio &p) { 
+      int idx = data.size();
+      index[i] = idx;
+      data.push_back(BucketItem(i, p));
+      lace(idx);
+      if (p < minimal) {
+	minimal = p;
+      }
+    }
+
+    /// \brief Returns the item with minimum priority.
+    ///
+    /// This method returns the item with minimum priority.
+    /// \pre The heap must be nonempty.  
+    Item top() const {
+      while (first[minimal] == -1) {
+	++minimal;
+      }
+      return data[first[minimal]].item;
+    }
+
+    /// \brief Returns the minimum priority.
+    ///
+    /// It returns the minimum priority.
+    /// \pre The heap must be nonempty.
+    Prio prio() const {
+      while (first[minimal] == -1) {
+	++minimal;
+      }
+      return minimal;
+    }
+
+    /// \brief Deletes the item with minimum priority.
+    ///
+    /// This method deletes the item with minimum priority from the heap.  
+    /// \pre The heap must be non-empty.  
+    void pop() {
+      while (first[minimal] == -1) {
+	++minimal;
+      }
+      int idx = first[minimal];
+      index[data[idx].item] = -2;
+      unlace(idx);
+      relocate_last(idx);
+    }
+
+    /// \brief Deletes \c i from the heap.
+    ///
+    /// This method deletes item \c i from the heap, if \c i was
+    /// already stored in the heap.
+    /// \param i The item to erase. 
+    void erase(const Item &i) {
+      int idx = index[i];
+      index[data[idx].item] = -2;
+      unlace(idx);
+      relocate_last(idx);
+    }
+
+    
+    /// \brief Returns the priority of \c i.
+    ///
+    /// This function returns the priority of item \c i.  
+    /// \pre \c i must be in the heap.
+    /// \param i The item.
+    Prio operator[](const Item &i) const {
+      int idx = index[i];
+      return data[idx].value;
+    }
+
+    /// \brief \c i gets to the heap with priority \c p independently 
+    /// if \c i was already there.
+    ///
+    /// This method calls \ref push(\c i, \c p) if \c i is not stored
+    /// in the heap and sets the priority of \c i to \c p otherwise.
+    /// \param i The item.
+    /// \param p The priority.
+    void set(const Item &i, const Prio &p) {
+      int idx = index[i];
+      if (idx < 0) {
+	push(i,p);
+      } else if (p > data[idx].value) {
+	increase(i, p);
+      } else {
+	decrease(i, p);
+      }
+    }
+
+    /// \brief Decreases the priority of \c i to \c p.
+    ///
+    /// This method decreases the priority of item \c i to \c p.
+    /// \pre \c i must be stored in the heap with priority at least \c
+    /// p relative to \c Compare.
+    /// \param i The item.
+    /// \param p The priority.
+    void decrease(const Item &i, const Prio &p) {
+      int idx = index[i];
+      unlace(idx);
+      data[idx].value = p;
+      if (p < minimal) {
+	minimal = p;
+      }
+      lace(idx);
+    }
+    
+    /// \brief Increases the priority of \c i to \c p.
+    ///
+    /// This method sets the priority of item \c i to \c p. 
+    /// \pre \c i must be stored in the heap with priority at most \c
+    /// p relative to \c Compare.
+    /// \param i The item.
+    /// \param p The priority.
+    void increase(const Item &i, const Prio &p) {
+      int idx = index[i];
+      unlace(idx);
+      data[idx].value = p;
+      lace(idx);
+    }
+
+    /// \brief Returns if \c item is in, has already been in, or has 
+    /// never been in the heap.
+    ///
+    /// This method returns PRE_HEAP if \c item has never been in the
+    /// heap, IN_HEAP if it is in the heap at the moment, and POST_HEAP
+    /// otherwise. In the latter case it is possible that \c item will
+    /// get back to the heap again.
+    /// \param i The item.
+    State state(const Item &i) const {
+      int idx = index[i];
+      if (idx >= 0) idx = 0;
+      return State(idx);
+    }
+
+    /// \brief Sets the state of the \c item in the heap.
+    ///
+    /// Sets the state of the \c item in the heap. It can be used to
+    /// manually clear the heap when it is important to achive the
+    /// better time complexity.
+    /// \param i The item.
+    /// \param st The state. It should not be \c IN_HEAP. 
+    void state(const Item& i, State st) {
+      switch (st) {
+      case POST_HEAP:
+      case PRE_HEAP:
+        if (state(i) == IN_HEAP) {
+          erase(i);
+        }
+        index[i] = st;
+        break;
+      case IN_HEAP:
+        break;
+      }
+    }
+
+  private:
+
+    struct BucketItem {
+      BucketItem(const Item& _item, int _value) 
+	: item(_item), value(_value) {}
+
+      Item item;
+      int value;
+
+      int prev, next;
+    };
+
+    ItemIntMap& index;
+    std::vector<int> first;
+    std::vector<BucketItem> data;
+    mutable int minimal;
+
+  }; // class BucketHeap
+
+
+  template <typename _ItemIntMap>
+  class BucketHeap<_ItemIntMap, false> {
+
+  public:
+    typedef typename _ItemIntMap::Key Item;
+    typedef int Prio;
+    typedef std::pair<Item, Prio> Pair;
+    typedef _ItemIntMap ItemIntMap;
+
+    enum State {
+      IN_HEAP = 0,
+      PRE_HEAP = -1,
+      POST_HEAP = -2
+    };
+
+  public:
+
+    explicit BucketHeap(ItemIntMap &_index) : index(_index), maximal(-1) {}
+
+    int size() const { return data.size(); }
+    bool empty() const { return data.empty(); }
+
+    void clear() { 
+      data.clear(); first.clear(); maximal = -1; 
+    }
+
+  private:
+
+    void relocate_last(int idx) {
+      if (idx + 1 != int(data.size())) {
+	data[idx] = data.back();
+	if (data[idx].prev != -1) {
+	  data[data[idx].prev].next = idx;
+	} else {
+	  first[data[idx].value] = idx;
+	}
+	if (data[idx].next != -1) {
+	  data[data[idx].next].prev = idx;
+	}
+	index[data[idx].item] = idx;
+      }
+      data.pop_back();
+    }
+
+    void unlace(int idx) {
+      if (data[idx].prev != -1) {
+	data[data[idx].prev].next = data[idx].next;
+      } else {
+	first[data[idx].value] = data[idx].next;
+      }
+      if (data[idx].next != -1) {
+	data[data[idx].next].prev = data[idx].prev;
+      }
+    }
+
+    void lace(int idx) {
+      if (int(first.size()) <= data[idx].value) {
+	first.resize(data[idx].value + 1, -1);
+      }
+      data[idx].next = first[data[idx].value];
+      if (data[idx].next != -1) {
+	data[data[idx].next].prev = idx;
+      }
+      first[data[idx].value] = idx;
+      data[idx].prev = -1;
+    }
+
+  public:
+
+    void push(const Pair& p) {
+      push(p.first, p.second);
+    }
+
+    void push(const Item &i, const Prio &p) { 
+      int idx = data.size();
+      index[i] = idx;
+      data.push_back(BucketItem(i, p));
+      lace(idx);
+      if (data[idx].value > maximal) {
+	maximal = data[idx].value;
+      }
+    }
+
+    Item top() const {
+      while (first[maximal] == -1) {
+	--maximal;
+      }
+      return data[first[maximal]].item;
+    }
+
+    Prio prio() const {
+      while (first[maximal] == -1) {
+	--maximal;
+      }
+      return maximal;
+    }
+
+    void pop() {
+      while (first[maximal] == -1) {
+	--maximal;
+      }
+      int idx = first[maximal];
+      index[data[idx].item] = -2;
+      unlace(idx);
+      relocate_last(idx);
+    }
+
+    void erase(const Item &i) {
+      int idx = index[i];
+      index[data[idx].item] = -2;
+      unlace(idx);
+      relocate_last(idx);
+    }
+
+    Prio operator[](const Item &i) const {
+      int idx = index[i];
+      return data[idx].value;
+    }
+
+    void set(const Item &i, const Prio &p) {
+      int idx = index[i];
+      if (idx < 0) {
+	push(i,p);
+      } else if (p > data[idx].value) {
+	decrease(i, p);
+      } else {
+	increase(i, p);
+      }
+    }
+
+    void decrease(const Item &i, const Prio &p) {
+      int idx = index[i];
+      unlace(idx);
+      data[idx].value = p;
+      if (p > maximal) {
+	maximal = p;
+      }
+      lace(idx);
+    }
+    
+    void increase(const Item &i, const Prio &p) {
+      int idx = index[i];
+      unlace(idx);
+      data[idx].value = p;
+      lace(idx);
+    }
+
+    State state(const Item &i) const {
+      int idx = index[i];
+      if (idx >= 0) idx = 0;
+      return State(idx);
+    }
+
+    void state(const Item& i, State st) {
+      switch (st) {
+      case POST_HEAP:
+      case PRE_HEAP:
+        if (state(i) == IN_HEAP) {
+          erase(i);
+        }
+        index[i] = st;
+        break;
+      case IN_HEAP:
+        break;
+      }
+    }
+
+  private:
+
+    struct BucketItem {
+      BucketItem(const Item& _item, int _value) 
+	: item(_item), value(_value) {}
+
+      Item item;
+      int value;
+
+      int prev, next;
+    };
+
+    ItemIntMap& index;
+    std::vector<int> first;
+    std::vector<BucketItem> data;
+    mutable int maximal;
+
+  }; // class BucketHeap
+
+  /// \ingroup auxdat
+  ///
+  /// \brief A Simplified Bucket Heap implementation.
+  ///
+  /// This class implements a simplified \e bucket \e heap data
+  /// structure.  It does not provide some functionality but it faster
+  /// and simplier data structure than the BucketHeap. The main
+  /// difference is that the BucketHeap stores for every key a double
+  /// linked list while this class stores just simple lists. In the
+  /// other way it does not supports erasing each elements just the
+  /// minimal and it does not supports key increasing, decreasing.
+  ///
+  /// \param _ItemIntMap A read and writable Item int map, used internally
+  /// to handle the cross references.
+  /// \param minimize If the given parameter is true then the heap gives back
+  /// the lowest priority.
+  ///
+  /// \sa BucketHeap 
+  template <typename _ItemIntMap, bool minimize = true >
+  class SimpleBucketHeap {
+
+  public:
+    typedef typename _ItemIntMap::Key Item;
+    typedef int Prio;
+    typedef std::pair<Item, Prio> Pair;
+    typedef _ItemIntMap ItemIntMap;
+
+    /// \brief Type to represent the items states.
+    ///
+    /// Each Item element have a state associated to it. It may be "in heap",
+    /// "pre heap" or "post heap". The latter two are indifferent from the
+    /// heap's point of view, but may be useful to the user.
+    ///
+    /// The ItemIntMap \e should be initialized in such way that it maps
+    /// PRE_HEAP (-1) to any element to be put in the heap...
+    enum State {
+      IN_HEAP = 0,
+      PRE_HEAP = -1,
+      POST_HEAP = -2
+    };
+
+  public:
+
+    /// \brief The constructor.
+    ///
+    /// The constructor.
+    /// \param _index should be given to the constructor, since it is used
+    /// internally to handle the cross references. The value of the map
+    /// should be PRE_HEAP (-1) for each element.
+    explicit SimpleBucketHeap(ItemIntMap &_index) 
+      : index(_index), free(-1), num(0), minimal(0) {}
+    
+    /// \brief Returns the number of items stored in the heap.
+    ///
+    /// The number of items stored in the heap.
+    int size() const { return num; }
+    
+    /// \brief Checks if the heap stores no items.
+    ///
+    /// Returns \c true if and only if the heap stores no items.
+    bool empty() const { return num == 0; }
+
+    /// \brief Make empty this heap.
+    /// 
+    /// Make empty this heap. It does not change the cross reference
+    /// map.  If you want to reuse a heap what is not surely empty you
+    /// should first clear the heap and after that you should set the
+    /// cross reference map for each item to \c PRE_HEAP.
+    void clear() { 
+      data.clear(); first.clear(); free = -1; num = 0; minimal = 0;
+    }
+
+    /// \brief Insert a pair of item and priority into the heap.
+    ///
+    /// Adds \c p.first to the heap with priority \c p.second.
+    /// \param p The pair to insert.
+    void push(const Pair& p) {
+      push(p.first, p.second);
+    }
+
+    /// \brief Insert an item into the heap with the given priority.
+    ///    
+    /// Adds \c i to the heap with priority \c p. 
+    /// \param i The item to insert.
+    /// \param p The priority of the item.
+    void push(const Item &i, const Prio &p) {
+      int idx;
+      if (free == -1) {
+        idx = data.size();
+        data.push_back(BucketItem(i));
+      } else {
+        idx = free;
+        free = data[idx].next;
+        data[idx].item = i;
+      }
+      index[i] = idx;
+      if (p >= int(first.size())) first.resize(p + 1, -1);
+      data[idx].next = first[p];
+      first[p] = idx;
+      if (p < minimal) {
+	minimal = p;
+      }
+      ++num;
+    }
+
+    /// \brief Returns the item with minimum priority.
+    ///
+    /// This method returns the item with minimum priority.
+    /// \pre The heap must be nonempty.  
+    Item top() const {
+      while (first[minimal] == -1) {
+	++minimal;
+      }
+      return data[first[minimal]].item;
+    }
+
+    /// \brief Returns the minimum priority.
+    ///
+    /// It returns the minimum priority.
+    /// \pre The heap must be nonempty.
+    Prio prio() const {
+      while (first[minimal] == -1) {
+	++minimal;
+      }
+      return minimal;
+    }
+
+    /// \brief Deletes the item with minimum priority.
+    ///
+    /// This method deletes the item with minimum priority from the heap.  
+    /// \pre The heap must be non-empty.  
+    void pop() {
+      while (first[minimal] == -1) {
+	++minimal;
+      }
+      int idx = first[minimal];
+      index[data[idx].item] = -2;
+      first[minimal] = data[idx].next;
+      data[idx].next = free;
+      free = idx;
+      --num;
+    }
+    
+    /// \brief Returns the priority of \c i.
+    ///
+    /// This function returns the priority of item \c i.
+    /// \warning This operator is not a constant time function
+    /// because it scans the whole data structure to find the proper
+    /// value.  
+    /// \pre \c i must be in the heap.
+    /// \param i The item.
+    Prio operator[](const Item &i) const {
+      for (int k = 0; k < first.size(); ++k) {
+        int idx = first[k];
+        while (idx != -1) {
+          if (data[idx].item == i) {
+            return k;
+          }
+          idx = data[idx].next;
+        }
+      }
+      return -1;
+    }
+
+    /// \brief Returns if \c item is in, has already been in, or has 
+    /// never been in the heap.
+    ///
+    /// This method returns PRE_HEAP if \c item has never been in the
+    /// heap, IN_HEAP if it is in the heap at the moment, and POST_HEAP
+    /// otherwise. In the latter case it is possible that \c item will
+    /// get back to the heap again.
+    /// \param i The item.
+    State state(const Item &i) const {
+      int idx = index[i];
+      if (idx >= 0) idx = 0;
+      return State(idx);
+    }
+
+  private:
+
+    struct BucketItem {
+      BucketItem(const Item& _item) 
+	: item(_item) {}
+
+      Item item;
+      int next;
+    };
+
+    ItemIntMap& index;
+    std::vector<int> first;
+    std::vector<BucketItem> data;
+    int free, num;
+    mutable int minimal;
+
+  }; // class SimpleBucketHeap
+
+  template <typename _ItemIntMap>
+  class SimpleBucketHeap<_ItemIntMap, false> {
+
+  public:
+    typedef typename _ItemIntMap::Key Item;
+    typedef int Prio;
+    typedef std::pair<Item, Prio> Pair;
+    typedef _ItemIntMap ItemIntMap;
+
+    enum State {
+      IN_HEAP = 0,
+      PRE_HEAP = -1,
+      POST_HEAP = -2
+    };
+
+  public:
+
+    explicit SimpleBucketHeap(ItemIntMap &_index) 
+      : index(_index), free(-1), num(0), maximal(0) {}
+    
+    int size() const { return num; }
+    
+    bool empty() const { return num == 0; }
+
+    void clear() { 
+      data.clear(); first.clear(); free = -1; num = 0; maximal = 0;
+    }
+
+    void push(const Pair& p) {
+      push(p.first, p.second);
+    }
+
+    void push(const Item &i, const Prio &p) {
+      int idx;
+      if (free == -1) {
+        idx = data.size();
+        data.push_back(BucketItem(i));
+      } else {
+        idx = free;
+        free = data[idx].next;
+        data[idx].item = i;
+      }
+      index[i] = idx;
+      if (p >= int(first.size())) first.resize(p + 1, -1);
+      data[idx].next = first[p];
+      first[p] = idx;
+      if (p > maximal) {
+	maximal = p;
+      }
+      ++num;
+    }
+
+    Item top() const {
+      while (first[maximal] == -1) {
+	--maximal;
+      }
+      return data[first[maximal]].item;
+    }
+
+    Prio prio() const {
+      while (first[maximal] == -1) {
+	--maximal;
+      }
+      return maximal;
+    }
+
+    void pop() {
+      while (first[maximal] == -1) {
+	--maximal;
+      }
+      int idx = first[maximal];
+      index[data[idx].item] = -2;
+      first[maximal] = data[idx].next;
+      data[idx].next = free;
+      free = idx;
+      --num;
+    }
+    
+    Prio operator[](const Item &i) const {
+      for (int k = 0; k < first.size(); ++k) {
+        int idx = first[k];
+        while (idx != -1) {
+          if (data[idx].item == i) {
+            return k;
+          }
+          idx = data[idx].next;
+        }
+      }
+      return -1;
+    }
+
+    State state(const Item &i) const {
+      int idx = index[i];
+      if (idx >= 0) idx = 0;
+      return State(idx);
+    }
+
+  private:
+
+    struct BucketItem {
+      BucketItem(const Item& _item) : item(_item) {}
+
+      Item item;
+
+      int next;
+    };
+
+    ItemIntMap& index;
+    std::vector<int> first;
+    std::vector<BucketItem> data;
+    int free, num;
+    mutable int maximal;
+
+  };
+
+}
+  
+#endif
Index: lemon/cancel_and_tighten.h
===================================================================
--- lemon/cancel_and_tighten.h	(revision 2636)
+++ lemon/cancel_and_tighten.h	(revision 2636)
@@ -0,0 +1,795 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_CANCEL_AND_TIGHTEN_H
+#define LEMON_CANCEL_AND_TIGHTEN_H
+
+/// \ingroup min_cost_flow
+///
+/// \file
+/// \brief Cancel and Tighten algorithm for finding a minimum cost flow.
+
+#include <vector>
+
+#include <lemon/circulation.h>
+#include <lemon/bellman_ford.h>
+#include <lemon/min_mean_cycle.h>
+#include <lemon/graph_adaptor.h>
+#include <lemon/tolerance.h>
+#include <lemon/math.h>
+
+#include <lemon/static_graph.h>
+
+namespace lemon {
+
+  /// \addtogroup min_cost_flow
+  /// @{
+
+  /// \brief Implementation of the Cancel and Tighten algorithm for
+  /// finding a minimum cost flow.
+  ///
+  /// \ref CancelAndTighten implements the Cancel and Tighten algorithm for
+  /// finding a minimum cost flow.
+  ///
+  /// \tparam Graph The directed graph type the algorithm runs on.
+  /// \tparam LowerMap The type of the lower bound map.
+  /// \tparam CapacityMap The type of the capacity (upper bound) map.
+  /// \tparam CostMap The type of the cost (length) map.
+  /// \tparam SupplyMap The type of the supply map.
+  ///
+  /// \warning
+  /// - Edge capacities and costs should be \e non-negative \e integers.
+  /// - Supply values should be \e signed \e integers.
+  /// - The value types of the maps should be convertible to each other.
+  /// - \c CostMap::Value must be signed type.
+  ///
+  /// \author Peter Kovacs
+  template < typename Graph,
+             typename LowerMap = typename Graph::template EdgeMap<int>,
+             typename CapacityMap = typename Graph::template EdgeMap<int>,
+             typename CostMap = typename Graph::template EdgeMap<int>,
+             typename SupplyMap = typename Graph::template NodeMap<int> >
+  class CancelAndTighten
+  {
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename CapacityMap::Value Capacity;
+    typedef typename CostMap::Value Cost;
+    typedef typename SupplyMap::Value Supply;
+    typedef typename Graph::template EdgeMap<Capacity> CapacityEdgeMap;
+    typedef typename Graph::template NodeMap<Supply> SupplyNodeMap;
+
+    typedef ResGraphAdaptor< const Graph, Capacity,
+                             CapacityEdgeMap, CapacityEdgeMap > ResGraph;
+
+  public:
+
+    /// The type of the flow map.
+    typedef typename Graph::template EdgeMap<Capacity> FlowMap;
+    /// The type of the potential map.
+    typedef typename Graph::template NodeMap<Cost> PotentialMap;
+
+  private:
+
+    /// \brief Map adaptor class for handling residual edge costs.
+    ///
+    /// Map adaptor class for handling residual edge costs.
+    class ResidualCostMap : public MapBase<typename ResGraph::Edge, Cost>
+    {
+      typedef typename ResGraph::Edge Edge;
+      
+    private:
+
+      const CostMap &_cost_map;
+
+    public:
+
+      ///\e
+      ResidualCostMap(const CostMap &cost_map) : _cost_map(cost_map) {}
+
+      ///\e
+      Cost operator[](const Edge &e) const {
+        return ResGraph::forward(e) ? _cost_map[e] : -_cost_map[e];
+      }
+
+    }; //class ResidualCostMap
+
+    /// \brief Map adaptor class for handling reduced edge costs.
+    ///
+    /// Map adaptor class for handling reduced edge costs.
+    class ReducedCostMap : public MapBase<Edge, Cost>
+    {
+    private:
+
+      const Graph &_gr;
+      const CostMap &_cost_map;
+      const PotentialMap &_pot_map;
+
+    public:
+
+      ///\e
+      ReducedCostMap( const Graph &gr,
+                      const CostMap &cost_map,
+                      const PotentialMap &pot_map ) :
+        _gr(gr), _cost_map(cost_map), _pot_map(pot_map) {}
+
+      ///\e
+      inline Cost operator[](const Edge &e) const {
+        return _cost_map[e] + _pot_map[_gr.source(e)]
+                            - _pot_map[_gr.target(e)];
+      }
+
+    }; //class ReducedCostMap
+
+    struct BFOperationTraits {
+      static double zero() { return 0; }
+
+      static double infinity() {
+        return std::numeric_limits<double>::infinity();
+      }
+
+      static double plus(const double& left, const double& right) {
+        return left + right;
+      }
+
+      static bool less(const double& left, const double& right) {
+        return left + 1e-6 < right;
+      }
+    }; // class BFOperationTraits
+
+  private:
+
+    // The directed graph the algorithm runs on
+    const Graph &_graph;
+    // The original lower bound map
+    const LowerMap *_lower;
+    // The modified capacity map
+    CapacityEdgeMap _capacity;
+    // The original cost map
+    const CostMap &_cost;
+    // The modified supply map
+    SupplyNodeMap _supply;
+    bool _valid_supply;
+
+    // Edge map of the current flow
+    FlowMap *_flow;
+    bool _local_flow;
+    // Node map of the current potentials
+    PotentialMap *_potential;
+    bool _local_potential;
+
+    // The residual graph
+    ResGraph *_res_graph;
+    // The residual cost map
+    ResidualCostMap _res_cost;
+
+  public:
+
+    /// \brief General constructor (with lower bounds).
+    ///
+    /// General constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    CancelAndTighten( const Graph &graph,
+                      const LowerMap &lower,
+                      const CapacityMap &capacity,
+                      const CostMap &cost,
+                      const SupplyMap &supply ) :
+      _graph(graph), _lower(&lower), _capacity(capacity), _cost(cost),
+      _supply(supply), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false),
+      _res_graph(NULL), _res_cost(_cost)
+    {
+      // Check the sum of supply values
+      Supply sum = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) sum += _supply[n];
+      _valid_supply = sum == 0;
+
+      // Remove non-zero lower bounds
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if (lower[e] != 0) {
+          _capacity[e] -= lower[e];
+          _supply[_graph.source(e)] -= lower[e];
+          _supply[_graph.target(e)] += lower[e];
+        }
+      }
+    }
+
+    /// \brief General constructor (without lower bounds).
+    ///
+    /// General constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    CancelAndTighten( const Graph &graph,
+                      const CapacityMap &capacity,
+                      const CostMap &cost,
+                      const SupplyMap &supply ) :
+      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
+      _supply(supply), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false),
+      _res_graph(NULL), _res_cost(_cost)
+    {
+      // Check the sum of supply values
+      Supply sum = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) sum += _supply[n];
+      _valid_supply = sum == 0;
+    }
+
+    /// \brief Simple constructor (with lower bounds).
+    ///
+    /// Simple constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    CancelAndTighten( const Graph &graph,
+                      const LowerMap &lower,
+                      const CapacityMap &capacity,
+                      const CostMap &cost,
+                      Node s, Node t,
+                      Supply flow_value ) :
+      _graph(graph), _lower(&lower), _capacity(capacity), _cost(cost),
+      _supply(graph, 0), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false),
+      _res_graph(NULL), _res_cost(_cost)
+    {
+      // Remove non-zero lower bounds
+      _supply[s] =  flow_value;
+      _supply[t] = -flow_value;
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if (lower[e] != 0) {
+          _capacity[e] -= lower[e];
+          _supply[_graph.source(e)] -= lower[e];
+          _supply[_graph.target(e)] += lower[e];
+        }
+      }
+      _valid_supply = true;
+    }
+
+    /// \brief Simple constructor (without lower bounds).
+    ///
+    /// Simple constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    CancelAndTighten( const Graph &graph,
+                      const CapacityMap &capacity,
+                      const CostMap &cost,
+                      Node s, Node t,
+                      Supply flow_value ) :
+      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
+      _supply(graph, 0), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false),
+      _res_graph(NULL), _res_cost(_cost)
+    {
+      _supply[s] =  flow_value;
+      _supply[t] = -flow_value;
+      _valid_supply = true;
+    }
+
+    /// Destructor.
+    ~CancelAndTighten() {
+      if (_local_flow) delete _flow;
+      if (_local_potential) delete _potential;
+      delete _res_graph;
+    }
+
+    /// \brief Set the flow map.
+    ///
+    /// Set the flow map.
+    ///
+    /// \return \c (*this)
+    CancelAndTighten& flowMap(FlowMap &map) {
+      if (_local_flow) {
+        delete _flow;
+        _local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Set the potential map.
+    ///
+    /// Set the potential map.
+    ///
+    /// \return \c (*this)
+    CancelAndTighten& potentialMap(PotentialMap &map) {
+      if (_local_potential) {
+        delete _potential;
+        _local_potential = false;
+      }
+      _potential = &map;
+      return *this;
+    }
+
+    /// \name Execution control
+
+    /// @{
+
+    /// \brief Run the algorithm.
+    ///
+    /// Run the algorithm.
+    ///
+    /// \return \c true if a feasible flow can be found.
+    bool run() {
+      return init() && start();
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the algorithm can be obtained using these
+    /// functions.\n
+    /// \ref lemon::CancelAndTighten::run() "run()" must be called before
+    /// using them.
+
+    /// @{
+
+    /// \brief Return a const reference to the edge map storing the
+    /// found flow.
+    ///
+    /// Return a const reference to the edge map storing the found flow.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const FlowMap& flowMap() const {
+      return *_flow;
+    }
+
+    /// \brief Return a const reference to the node map storing the
+    /// found potentials (the dual solution).
+    ///
+    /// Return a const reference to the node map storing the found
+    /// potentials (the dual solution).
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const PotentialMap& potentialMap() const {
+      return *_potential;
+    }
+
+    /// \brief Return the flow on the given edge.
+    ///
+    /// Return the flow on the given edge.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Capacity flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// \brief Return the potential of the given node.
+    ///
+    /// Return the potential of the given node.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost potential(const Node& node) const {
+      return (*_potential)[node];
+    }
+
+    /// \brief Return the total cost of the found flow.
+    ///
+    /// Return the total cost of the found flow. The complexity of the
+    /// function is \f$ O(e) \f$.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost totalCost() const {
+      Cost c = 0;
+      for (EdgeIt e(_graph); e != INVALID; ++e)
+        c += (*_flow)[e] * _cost[e];
+      return c;
+    }
+
+    /// @}
+
+  private:
+
+    /// Initialize the algorithm.
+    bool init() {
+      if (!_valid_supply) return false;
+
+      // Initialize flow and potential maps
+      if (!_flow) {
+        _flow = new FlowMap(_graph);
+        _local_flow = true;
+      }
+      if (!_potential) {
+        _potential = new PotentialMap(_graph);
+        _local_potential = true;
+      }
+
+      _res_graph = new ResGraph(_graph, _capacity, *_flow);
+
+      // Find a feasible flow using Circulation
+      Circulation< Graph, ConstMap<Edge, Capacity>,
+                   CapacityEdgeMap, SupplyMap >
+        circulation( _graph, constMap<Edge>(Capacity(0)),
+                     _capacity, _supply );
+      return circulation.flowMap(*_flow).run();
+    }
+
+    bool start() {
+      const double LIMIT_FACTOR = 0.01;
+      const int MIN_LIMIT = 3;
+
+      typedef typename Graph::template NodeMap<double> FloatPotentialMap;
+      typedef typename Graph::template NodeMap<int> LevelMap;
+      typedef typename Graph::template NodeMap<bool> BoolNodeMap;
+      typedef typename Graph::template NodeMap<Node> PredNodeMap;
+      typedef typename Graph::template NodeMap<Edge> PredEdgeMap;
+      typedef typename ResGraph::template EdgeMap<double> ResShiftCostMap;
+      FloatPotentialMap pi(_graph);
+      LevelMap level(_graph);
+      BoolNodeMap reached(_graph);
+      BoolNodeMap processed(_graph);
+      PredNodeMap pred_node(_graph);
+      PredEdgeMap pred_edge(_graph);
+      int node_num = countNodes(_graph);
+      typedef std::pair<Edge, bool> pair;
+      std::vector<pair> stack(node_num);
+      std::vector<Node> proc_vector(node_num);
+      ResShiftCostMap shift_cost(*_res_graph);
+
+      Tolerance<double> tol;
+      tol.epsilon(1e-6);
+
+      Timer t1, t2, t3;
+      t1.reset();
+      t2.reset();
+      t3.reset();
+
+      // Initialize epsilon and the node potentials
+      double epsilon = 0;
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if (_capacity[e] - (*_flow)[e] > 0 && _cost[e] < -epsilon)
+          epsilon = -_cost[e];
+        else if ((*_flow)[e] > 0 && _cost[e] > epsilon)
+          epsilon = _cost[e];
+      }
+      for (NodeIt v(_graph); v != INVALID; ++v) {
+        pi[v] = 0;
+      }
+
+      // Start phases
+      int limit = int(LIMIT_FACTOR * node_num);
+      if (limit < MIN_LIMIT) limit = MIN_LIMIT;
+      int iter = limit;
+      while (epsilon * node_num >= 1) {
+        t1.start();
+        // Find and cancel cycles in the admissible graph using DFS
+        for (NodeIt n(_graph); n != INVALID; ++n) {
+          reached[n] = false;
+          processed[n] = false;
+        }
+        int stack_head = -1;
+        int proc_head = -1;
+
+        for (NodeIt start(_graph); start != INVALID; ++start) {
+          if (reached[start]) continue;
+
+          // New start node
+          reached[start] = true;
+          pred_edge[start] = INVALID;
+          pred_node[start] = INVALID;
+
+          // Find the first admissible residual outgoing edge
+          double p = pi[start];
+          Edge e;
+          _graph.firstOut(e, start);
+          while ( e != INVALID && (_capacity[e] - (*_flow)[e] == 0 ||
+                  !tol.negative(_cost[e] + p - pi[_graph.target(e)])) )
+            _graph.nextOut(e);
+          if (e != INVALID) {
+            stack[++stack_head] = pair(e, true);
+            goto next_step_1;
+          }
+          _graph.firstIn(e, start);
+          while ( e != INVALID && ((*_flow)[e] == 0 ||
+                  !tol.negative(-_cost[e] + p - pi[_graph.source(e)])) )
+            _graph.nextIn(e);
+          if (e != INVALID) {
+            stack[++stack_head] = pair(e, false);
+            goto next_step_1;
+          }
+          processed[start] = true;
+          proc_vector[++proc_head] = start;
+          continue;
+        next_step_1:
+
+          while (stack_head >= 0) {
+            Edge se = stack[stack_head].first;
+            bool sf = stack[stack_head].second;
+            Node u, v;
+            if (sf) {
+              u = _graph.source(se);
+              v = _graph.target(se);
+            } else {
+              u = _graph.target(se);
+              v = _graph.source(se);
+            }
+
+            if (!reached[v]) {
+              // A new node is reached
+              reached[v] = true;
+              pred_node[v] = u;
+              pred_edge[v] = se;
+              // Find the first admissible residual outgoing edge
+              double p = pi[v];
+              Edge e;
+              _graph.firstOut(e, v);
+              while ( e != INVALID && (_capacity[e] - (*_flow)[e] == 0 ||
+                      !tol.negative(_cost[e] + p - pi[_graph.target(e)])) )
+                _graph.nextOut(e);
+              if (e != INVALID) {
+                stack[++stack_head] = pair(e, true);
+                goto next_step_2;
+              }
+              _graph.firstIn(e, v);
+              while ( e != INVALID && ((*_flow)[e] == 0 ||
+                      !tol.negative(-_cost[e] + p - pi[_graph.source(e)])) )
+                _graph.nextIn(e);
+              stack[++stack_head] = pair(e, false);
+            next_step_2: ;
+            } else {
+              if (!processed[v]) {
+                // A cycle is found
+                Node n, w = u;
+                Capacity d, delta = sf ? _capacity[se] - (*_flow)[se] :
+                                         (*_flow)[se];
+                for (n = u; n != v; n = pred_node[n]) {
+                  d = _graph.target(pred_edge[n]) == n ?
+                      _capacity[pred_edge[n]] - (*_flow)[pred_edge[n]] :
+                      (*_flow)[pred_edge[n]];
+                  if (d <= delta) {
+                    delta = d;
+                    w = pred_node[n];
+                  }
+                }
+
+/*
+                std::cout << "CYCLE FOUND: ";
+                if (sf)
+                  std::cout << _cost[se] + pi[_graph.source(se)] - pi[_graph.target(se)];
+                else
+                  std::cout << _graph.id(se) << ":" << -(_cost[se] + pi[_graph.source(se)] - pi[_graph.target(se)]);
+                for (n = u; n != v; n = pred_node[n]) {
+                  if (_graph.target(pred_edge[n]) == n)
+                    std::cout << " " << _cost[pred_edge[n]] + pi[_graph.source(pred_edge[n])] - pi[_graph.target(pred_edge[n])];
+                  else
+                    std::cout << " " << -(_cost[pred_edge[n]] + pi[_graph.source(pred_edge[n])] - pi[_graph.target(pred_edge[n])]);
+                }
+                std::cout << "\n";
+*/
+                // Augment along the cycle
+                (*_flow)[se] = sf ? (*_flow)[se] + delta :
+                                    (*_flow)[se] - delta;
+                for (n = u; n != v; n = pred_node[n]) {
+                  if (_graph.target(pred_edge[n]) == n)
+                    (*_flow)[pred_edge[n]] += delta;
+                  else
+                    (*_flow)[pred_edge[n]] -= delta;
+                }
+                for (n = u; stack_head > 0 && n != w; n = pred_node[n]) {
+                  --stack_head;
+                  reached[n] = false;
+                }
+                u = w;
+              }
+              v = u;
+
+              // Find the next admissible residual outgoing edge
+              double p = pi[v];
+              Edge e = stack[stack_head].first;
+              if (!stack[stack_head].second) {
+                _graph.nextIn(e);
+                goto in_edge_3;
+              }
+              _graph.nextOut(e);
+              while ( e != INVALID && (_capacity[e] - (*_flow)[e] == 0 ||
+                      !tol.negative(_cost[e] + p - pi[_graph.target(e)])) )
+                _graph.nextOut(e);
+              if (e != INVALID) {
+                stack[stack_head] = pair(e, true);
+                goto next_step_3;
+              }
+              _graph.firstIn(e, v);
+            in_edge_3:
+              while ( e != INVALID && ((*_flow)[e] == 0 ||
+                      !tol.negative(-_cost[e] + p - pi[_graph.source(e)])) )
+                _graph.nextIn(e);
+              stack[stack_head] = pair(e, false);
+            next_step_3: ;
+            }
+
+            while (stack_head >= 0 && stack[stack_head].first == INVALID) {
+              processed[v] = true;
+              proc_vector[++proc_head] = v;
+              if (--stack_head >= 0) {
+                v = stack[stack_head].second ?
+                    _graph.source(stack[stack_head].first) :
+                    _graph.target(stack[stack_head].first);
+                // Find the next admissible residual outgoing edge
+                double p = pi[v];
+                Edge e = stack[stack_head].first;
+                if (!stack[stack_head].second) {
+                  _graph.nextIn(e);
+                  goto in_edge_4;
+                }
+                _graph.nextOut(e);
+                while ( e != INVALID && (_capacity[e] - (*_flow)[e] == 0 ||
+                        !tol.negative(_cost[e] + p - pi[_graph.target(e)])) )
+                  _graph.nextOut(e);
+                if (e != INVALID) {
+                  stack[stack_head] = pair(e, true);
+                  goto next_step_4;
+                }
+                _graph.firstIn(e, v);
+              in_edge_4:
+                while ( e != INVALID && ((*_flow)[e] == 0 ||
+                        !tol.negative(-_cost[e] + p - pi[_graph.source(e)])) )
+                  _graph.nextIn(e);
+                stack[stack_head] = pair(e, false);
+              next_step_4: ;
+              }
+            }
+          }
+        }
+        t1.stop();
+
+        // Tighten potentials and epsilon
+        if (--iter > 0) {
+          // Compute levels
+          t2.start();
+          for (int i = proc_head; i >= 0; --i) {
+            Node v = proc_vector[i];
+            double p = pi[v];
+            int l = 0;
+            for (InEdgeIt e(_graph, v); e != INVALID; ++e) {
+              Node u = _graph.source(e);
+              if ( _capacity[e] - (*_flow)[e] > 0 &&
+                   tol.negative(_cost[e] + pi[u] - p) &&
+                   level[u] + 1 > l ) l = level[u] + 1;
+            }
+            for (OutEdgeIt e(_graph, v); e != INVALID; ++e) {
+              Node u = _graph.target(e);
+              if ( (*_flow)[e] > 0 &&
+                   tol.negative(-_cost[e] + pi[u] - p) &&
+                   level[u] + 1 > l ) l = level[u] + 1;
+            }
+            level[v] = l;
+          }
+
+          // Modify potentials
+          double p, q = -1;
+          for (EdgeIt e(_graph); e != INVALID; ++e) {
+            Node u = _graph.source(e);
+            Node v = _graph.target(e);
+            if (_capacity[e] - (*_flow)[e] > 0 && level[u] - level[v] > 0) {
+              p = (_cost[e] + pi[u] - pi[v] + epsilon) /
+                  (level[u] - level[v] + 1);
+              if (q < 0 || p < q) q = p;
+            }
+            else if ((*_flow)[e] > 0 && level[v] - level[u] > 0) {
+              p = (-_cost[e] - pi[u] + pi[v] + epsilon) /
+                  (level[v] - level[u] + 1);
+              if (q < 0 || p < q) q = p;
+            }
+          }
+          for (NodeIt v(_graph); v != INVALID; ++v) {
+            pi[v] -= q * level[v];
+          }
+
+          // Modify epsilon
+          epsilon = 0;
+          for (EdgeIt e(_graph); e != INVALID; ++e) {
+            double curr = _cost[e] + pi[_graph.source(e)]
+                                   - pi[_graph.target(e)];
+            if (_capacity[e] - (*_flow)[e] > 0 && curr < -epsilon)
+              epsilon = -curr;
+            else if ((*_flow)[e] > 0 && curr > epsilon)
+              epsilon = curr;
+          }
+          t2.stop();
+        } else {
+          // Set epsilon to the minimum cycle mean
+          t3.start();
+
+/**/
+          StaticGraph static_graph;
+          typename ResGraph::template NodeMap<typename StaticGraph::Node> node_ref(*_res_graph);
+          typename ResGraph::template EdgeMap<typename StaticGraph::Edge> edge_ref(*_res_graph);
+          static_graph.build(*_res_graph, node_ref, edge_ref);
+          typename StaticGraph::template NodeMap<double> static_pi(static_graph);
+          typename StaticGraph::template EdgeMap<double> static_cost(static_graph);
+
+          for (typename ResGraph::EdgeIt e(*_res_graph); e != INVALID; ++e)
+            static_cost[edge_ref[e]] = _res_cost[e];
+
+          MinMeanCycle<StaticGraph, typename StaticGraph::template EdgeMap<double> >
+            mmc(static_graph, static_cost);
+          mmc.init();
+          mmc.findMinMean();
+          epsilon = -mmc.cycleMean();
+/**/
+
+/*
+          MinMeanCycle<ResGraph, ResidualCostMap> mmc(*_res_graph, _res_cost);
+          mmc.init();
+          mmc.findMinMean();
+          epsilon = -mmc.cycleMean();
+*/
+
+          // Compute feasible potentials for the current epsilon
+          for (typename StaticGraph::EdgeIt e(static_graph); e != INVALID; ++e)
+            static_cost[e] += epsilon;
+          typename BellmanFord<StaticGraph, typename StaticGraph::template EdgeMap<double> >::
+            template DefDistMap<typename StaticGraph::template NodeMap<double> >::
+            template DefOperationTraits<BFOperationTraits>::Create
+              bf(static_graph, static_cost);
+          bf.distMap(static_pi).init(0);
+          bf.start();
+          for (NodeIt n(_graph); n != INVALID; ++n)
+            pi[n] = static_pi[node_ref[n]];
+          
+/*
+          for (typename ResGraph::EdgeIt e(*_res_graph); e != INVALID; ++e)
+            shift_cost[e] = _res_cost[e] + epsilon;
+          typename BellmanFord<ResGraph, ResShiftCostMap>::
+            template DefDistMap<FloatPotentialMap>::
+            template DefOperationTraits<BFOperationTraits>::Create
+              bf(*_res_graph, shift_cost);
+          bf.distMap(pi).init(0);
+          bf.start();
+*/
+
+          iter = limit;
+          t3.stop();
+        }
+      }
+
+//      std::cout << t1.realTime() << " " << t2.realTime() << " " << t3.realTime() << "\n";
+
+      // Handle non-zero lower bounds
+      if (_lower) {
+        for (EdgeIt e(_graph); e != INVALID; ++e)
+          (*_flow)[e] += (*_lower)[e];
+      }
+      return true;
+    }
+
+  }; //class CancelAndTighten
+
+  ///@}
+
+} //namespace lemon
+
+#endif //LEMON_CANCEL_AND_TIGHTEN_H
Index: lemon/capacity_scaling.h
===================================================================
--- lemon/capacity_scaling.h	(revision 2629)
+++ lemon/capacity_scaling.h	(revision 2629)
@@ -0,0 +1,710 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_CAPACITY_SCALING_H
+#define LEMON_CAPACITY_SCALING_H
+
+/// \ingroup min_cost_flow
+///
+/// \file
+/// \brief Capacity scaling algorithm for finding a minimum cost flow.
+
+#include <vector>
+#include <lemon/bin_heap.h>
+
+namespace lemon {
+
+  /// \addtogroup min_cost_flow
+  /// @{
+
+  /// \brief Implementation of the capacity scaling algorithm for
+  /// finding a minimum cost flow.
+  ///
+  /// \ref CapacityScaling implements the capacity scaling version
+  /// of the successive shortest path algorithm for finding a minimum
+  /// cost flow.
+  ///
+  /// \tparam Graph The directed graph type the algorithm runs on.
+  /// \tparam LowerMap The type of the lower bound map.
+  /// \tparam CapacityMap The type of the capacity (upper bound) map.
+  /// \tparam CostMap The type of the cost (length) map.
+  /// \tparam SupplyMap The type of the supply map.
+  ///
+  /// \warning
+  /// - Edge capacities and costs should be \e non-negative \e integers.
+  /// - Supply values should be \e signed \e integers.
+  /// - The value types of the maps should be convertible to each other.
+  /// - \c CostMap::Value must be signed type.
+  ///
+  /// \author Peter Kovacs
+  template < typename Graph,
+             typename LowerMap = typename Graph::template EdgeMap<int>,
+             typename CapacityMap = typename Graph::template EdgeMap<int>,
+             typename CostMap = typename Graph::template EdgeMap<int>,
+             typename SupplyMap = typename Graph::template NodeMap<int> >
+  class CapacityScaling
+  {
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename CapacityMap::Value Capacity;
+    typedef typename CostMap::Value Cost;
+    typedef typename SupplyMap::Value Supply;
+    typedef typename Graph::template EdgeMap<Capacity> CapacityEdgeMap;
+    typedef typename Graph::template NodeMap<Supply> SupplyNodeMap;
+    typedef typename Graph::template NodeMap<Edge> PredMap;
+
+  public:
+
+    /// The type of the flow map.
+    typedef typename Graph::template EdgeMap<Capacity> FlowMap;
+    /// The type of the potential map.
+    typedef typename Graph::template NodeMap<Cost> PotentialMap;
+
+  private:
+
+    /// \brief Special implementation of the \ref Dijkstra algorithm
+    /// for finding shortest paths in the residual network.
+    ///
+    /// \ref ResidualDijkstra is a special implementation of the
+    /// \ref Dijkstra algorithm for finding shortest paths in the
+    /// residual network of the graph with respect to the reduced edge
+    /// costs and modifying the node potentials according to the
+    /// distance of the nodes.
+    class ResidualDijkstra
+    {
+      typedef typename Graph::template NodeMap<int> HeapCrossRef;
+      typedef BinHeap<Cost, HeapCrossRef> Heap;
+
+    private:
+
+      // The directed graph the algorithm runs on
+      const Graph &_graph;
+
+      // The main maps
+      const FlowMap &_flow;
+      const CapacityEdgeMap &_res_cap;
+      const CostMap &_cost;
+      const SupplyNodeMap &_excess;
+      PotentialMap &_potential;
+
+      // The distance map
+      PotentialMap _dist;
+      // The pred edge map
+      PredMap &_pred;
+      // The processed (i.e. permanently labeled) nodes
+      std::vector<Node> _proc_nodes;
+
+    public:
+
+      /// Constructor.
+      ResidualDijkstra( const Graph &graph,
+                        const FlowMap &flow,
+                        const CapacityEdgeMap &res_cap,
+                        const CostMap &cost,
+                        const SupplyMap &excess,
+                        PotentialMap &potential,
+                        PredMap &pred ) :
+        _graph(graph), _flow(flow), _res_cap(res_cap), _cost(cost),
+        _excess(excess), _potential(potential), _dist(graph),
+        _pred(pred)
+      {}
+
+      /// Run the algorithm from the given source node.
+      Node run(Node s, Capacity delta = 1) {
+        HeapCrossRef heap_cross_ref(_graph, Heap::PRE_HEAP);
+        Heap heap(heap_cross_ref);
+        heap.push(s, 0);
+        _pred[s] = INVALID;
+        _proc_nodes.clear();
+
+        // Processing nodes
+        while (!heap.empty() && _excess[heap.top()] > -delta) {
+          Node u = heap.top(), v;
+          Cost d = heap.prio() + _potential[u], nd;
+          _dist[u] = heap.prio();
+          heap.pop();
+          _proc_nodes.push_back(u);
+
+          // Traversing outgoing edges
+          for (OutEdgeIt e(_graph, u); e != INVALID; ++e) {
+            if (_res_cap[e] >= delta) {
+              v = _graph.target(e);
+              switch(heap.state(v)) {
+              case Heap::PRE_HEAP:
+                heap.push(v, d + _cost[e] - _potential[v]);
+                _pred[v] = e;
+                break;
+              case Heap::IN_HEAP:
+                nd = d + _cost[e] - _potential[v];
+                if (nd < heap[v]) {
+                  heap.decrease(v, nd);
+                  _pred[v] = e;
+                }
+                break;
+              case Heap::POST_HEAP:
+                break;
+              }
+            }
+          }
+
+          // Traversing incoming edges
+          for (InEdgeIt e(_graph, u); e != INVALID; ++e) {
+            if (_flow[e] >= delta) {
+              v = _graph.source(e);
+              switch(heap.state(v)) {
+              case Heap::PRE_HEAP:
+                heap.push(v, d - _cost[e] - _potential[v]);
+                _pred[v] = e;
+                break;
+              case Heap::IN_HEAP:
+                nd = d - _cost[e] - _potential[v];
+                if (nd < heap[v]) {
+                  heap.decrease(v, nd);
+                  _pred[v] = e;
+                }
+                break;
+              case Heap::POST_HEAP:
+                break;
+              }
+            }
+          }
+        }
+        if (heap.empty()) return INVALID;
+
+        // Updating potentials of processed nodes
+        Node t = heap.top();
+        Cost t_dist = heap.prio();
+        for (int i = 0; i < int(_proc_nodes.size()); ++i)
+          _potential[_proc_nodes[i]] += _dist[_proc_nodes[i]] - t_dist;
+
+        return t;
+      }
+
+    }; //class ResidualDijkstra
+
+  private:
+
+    // The directed graph the algorithm runs on
+    const Graph &_graph;
+    // The original lower bound map
+    const LowerMap *_lower;
+    // The modified capacity map
+    CapacityEdgeMap _capacity;
+    // The original cost map
+    const CostMap &_cost;
+    // The modified supply map
+    SupplyNodeMap _supply;
+    bool _valid_supply;
+
+    // Edge map of the current flow
+    FlowMap *_flow;
+    bool _local_flow;
+    // Node map of the current potentials
+    PotentialMap *_potential;
+    bool _local_potential;
+
+    // The residual capacity map
+    CapacityEdgeMap _res_cap;
+    // The excess map
+    SupplyNodeMap _excess;
+    // The excess nodes (i.e. nodes with positive excess)
+    std::vector<Node> _excess_nodes;
+    // The deficit nodes (i.e. nodes with negative excess)
+    std::vector<Node> _deficit_nodes;
+
+    // The delta parameter used for capacity scaling
+    Capacity _delta;
+    // The maximum number of phases
+    int _phase_num;
+
+    // The pred edge map
+    PredMap _pred;
+    // Implementation of the Dijkstra algorithm for finding augmenting
+    // shortest paths in the residual network
+    ResidualDijkstra *_dijkstra;
+
+  public:
+
+    /// \brief General constructor (with lower bounds).
+    ///
+    /// General constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    CapacityScaling( const Graph &graph,
+                     const LowerMap &lower,
+                     const CapacityMap &capacity,
+                     const CostMap &cost,
+                     const SupplyMap &supply ) :
+      _graph(graph), _lower(&lower), _capacity(capacity), _cost(cost),
+      _supply(supply), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false),
+      _res_cap(capacity), _excess(supply), _pred(graph), _dijkstra(NULL)
+    {
+      // Check the sum of supply values
+      Supply sum = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) sum += _supply[n];
+      _valid_supply = sum == 0;
+
+      // Remove non-zero lower bounds
+      typename LowerMap::Value lcap;
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if ((lcap = lower[e]) != 0) {
+          _capacity[e] -= lcap;
+          _res_cap[e] -= lcap;
+          _supply[_graph.source(e)] -= lcap;
+          _supply[_graph.target(e)] += lcap;
+          _excess[_graph.source(e)] -= lcap;
+          _excess[_graph.target(e)] += lcap;
+        }
+      }
+    }
+
+    /// \brief General constructor (without lower bounds).
+    ///
+    /// General constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    CapacityScaling( const Graph &graph,
+                     const CapacityMap &capacity,
+                     const CostMap &cost,
+                     const SupplyMap &supply ) :
+      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
+      _supply(supply), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false),
+      _res_cap(capacity), _excess(supply), _pred(graph), _dijkstra(NULL)
+    {
+      // Check the sum of supply values
+      Supply sum = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) sum += _supply[n];
+      _valid_supply = sum == 0;
+    }
+
+    /// \brief Simple constructor (with lower bounds).
+    ///
+    /// Simple constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    CapacityScaling( const Graph &graph,
+                     const LowerMap &lower,
+                     const CapacityMap &capacity,
+                     const CostMap &cost,
+                     Node s, Node t,
+                     Supply flow_value ) :
+      _graph(graph), _lower(&lower), _capacity(capacity), _cost(cost),
+      _supply(graph, 0), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false),
+      _res_cap(capacity), _excess(graph, 0), _pred(graph), _dijkstra(NULL)
+    {
+      // Remove non-zero lower bounds
+      _supply[s] = _excess[s] =  flow_value;
+      _supply[t] = _excess[t] = -flow_value;
+      typename LowerMap::Value lcap;
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if ((lcap = lower[e]) != 0) {
+          _capacity[e] -= lcap;
+          _res_cap[e] -= lcap;
+          _supply[_graph.source(e)] -= lcap;
+          _supply[_graph.target(e)] += lcap;
+          _excess[_graph.source(e)] -= lcap;
+          _excess[_graph.target(e)] += lcap;
+        }
+      }
+      _valid_supply = true;
+    }
+
+    /// \brief Simple constructor (without lower bounds).
+    ///
+    /// Simple constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    CapacityScaling( const Graph &graph,
+                     const CapacityMap &capacity,
+                     const CostMap &cost,
+                     Node s, Node t,
+                     Supply flow_value ) :
+      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
+      _supply(graph, 0), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false),
+      _res_cap(capacity), _excess(graph, 0), _pred(graph), _dijkstra(NULL)
+    {
+      _supply[s] = _excess[s] =  flow_value;
+      _supply[t] = _excess[t] = -flow_value;
+      _valid_supply = true;
+    }
+
+    /// Destructor.
+    ~CapacityScaling() {
+      if (_local_flow) delete _flow;
+      if (_local_potential) delete _potential;
+      delete _dijkstra;
+    }
+
+    /// \brief Set the flow map.
+    ///
+    /// Set the flow map.
+    ///
+    /// \return \c (*this)
+    CapacityScaling& flowMap(FlowMap &map) {
+      if (_local_flow) {
+        delete _flow;
+        _local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Set the potential map.
+    ///
+    /// Set the potential map.
+    ///
+    /// \return \c (*this)
+    CapacityScaling& potentialMap(PotentialMap &map) {
+      if (_local_potential) {
+        delete _potential;
+        _local_potential = false;
+      }
+      _potential = &map;
+      return *this;
+    }
+
+    /// \name Execution control
+
+    /// @{
+
+    /// \brief Run the algorithm.
+    ///
+    /// This function runs the algorithm.
+    ///
+    /// \param scaling Enable or disable capacity scaling.
+    /// If the maximum edge capacity and/or the amount of total supply
+    /// is rather small, the algorithm could be slightly faster without
+    /// scaling.
+    ///
+    /// \return \c true if a feasible flow can be found.
+    bool run(bool scaling = true) {
+      return init(scaling) && start();
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The results of the algorithm can be obtained using these
+    /// functions.\n
+    /// \ref lemon::CapacityScaling::run() "run()" must be called before
+    /// using them.
+
+    /// @{
+
+    /// \brief Return a const reference to the edge map storing the
+    /// found flow.
+    ///
+    /// Return a const reference to the edge map storing the found flow.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const FlowMap& flowMap() const {
+      return *_flow;
+    }
+
+    /// \brief Return a const reference to the node map storing the
+    /// found potentials (the dual solution).
+    ///
+    /// Return a const reference to the node map storing the found
+    /// potentials (the dual solution).
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const PotentialMap& potentialMap() const {
+      return *_potential;
+    }
+
+    /// \brief Return the flow on the given edge.
+    ///
+    /// Return the flow on the given edge.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Capacity flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// \brief Return the potential of the given node.
+    ///
+    /// Return the potential of the given node.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost potential(const Node& node) const {
+      return (*_potential)[node];
+    }
+
+    /// \brief Return the total cost of the found flow.
+    ///
+    /// Return the total cost of the found flow. The complexity of the
+    /// function is \f$ O(e) \f$.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost totalCost() const {
+      Cost c = 0;
+      for (EdgeIt e(_graph); e != INVALID; ++e)
+        c += (*_flow)[e] * _cost[e];
+      return c;
+    }
+
+    /// @}
+
+  private:
+
+    /// Initialize the algorithm.
+    bool init(bool scaling) {
+      if (!_valid_supply) return false;
+
+      // Initializing maps
+      if (!_flow) {
+        _flow = new FlowMap(_graph);
+        _local_flow = true;
+      }
+      if (!_potential) {
+        _potential = new PotentialMap(_graph);
+        _local_potential = true;
+      }
+      for (EdgeIt e(_graph); e != INVALID; ++e) (*_flow)[e] = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) (*_potential)[n] = 0;
+
+      _dijkstra = new ResidualDijkstra( _graph, *_flow, _res_cap, _cost,
+                                        _excess, *_potential, _pred );
+
+      // Initializing delta value
+      if (scaling) {
+        // With scaling
+        Supply max_sup = 0, max_dem = 0;
+        for (NodeIt n(_graph); n != INVALID; ++n) {
+          if ( _supply[n] > max_sup) max_sup =  _supply[n];
+          if (-_supply[n] > max_dem) max_dem = -_supply[n];
+        }
+        Capacity max_cap = 0;
+        for (EdgeIt e(_graph); e != INVALID; ++e) {
+          if (_capacity[e] > max_cap) max_cap = _capacity[e];
+        }
+        max_sup = std::min(std::min(max_sup, max_dem), max_cap);
+        _phase_num = 0;
+        for (_delta = 1; 2 * _delta <= max_sup; _delta *= 2)
+          ++_phase_num;
+      } else {
+        // Without scaling
+        _delta = 1;
+      }
+
+      return true;
+    }
+
+    bool start() {
+      if (_delta > 1)
+        return startWithScaling();
+      else
+        return startWithoutScaling();
+    }
+
+    /// Execute the capacity scaling algorithm.
+    bool startWithScaling() {
+      // Processing capacity scaling phases
+      Node s, t;
+      int phase_cnt = 0;
+      int factor = 4;
+      while (true) {
+        // Saturating all edges not satisfying the optimality condition
+        for (EdgeIt e(_graph); e != INVALID; ++e) {
+          Node u = _graph.source(e), v = _graph.target(e);
+          Cost c = _cost[e] + (*_potential)[u] - (*_potential)[v];
+          if (c < 0 && _res_cap[e] >= _delta) {
+            _excess[u] -= _res_cap[e];
+            _excess[v] += _res_cap[e];
+            (*_flow)[e] = _capacity[e];
+            _res_cap[e] = 0;
+          }
+          else if (c > 0 && (*_flow)[e] >= _delta) {
+            _excess[u] += (*_flow)[e];
+            _excess[v] -= (*_flow)[e];
+            (*_flow)[e] = 0;
+            _res_cap[e] = _capacity[e];
+          }
+        }
+
+        // Finding excess nodes and deficit nodes
+        _excess_nodes.clear();
+        _deficit_nodes.clear();
+        for (NodeIt n(_graph); n != INVALID; ++n) {
+          if (_excess[n] >=  _delta) _excess_nodes.push_back(n);
+          if (_excess[n] <= -_delta) _deficit_nodes.push_back(n);
+        }
+        int next_node = 0, next_def_node = 0;
+
+        // Finding augmenting shortest paths
+        while (next_node < int(_excess_nodes.size())) {
+          // Checking deficit nodes
+          if (_delta > 1) {
+            bool delta_deficit = false;
+            for ( ; next_def_node < int(_deficit_nodes.size());
+                    ++next_def_node ) {
+              if (_excess[_deficit_nodes[next_def_node]] <= -_delta) {
+                delta_deficit = true;
+                break;
+              }
+            }
+            if (!delta_deficit) break;
+          }
+
+          // Running Dijkstra
+          s = _excess_nodes[next_node];
+          if ((t = _dijkstra->run(s, _delta)) == INVALID) {
+            if (_delta > 1) {
+              ++next_node;
+              continue;
+            }
+            return false;
+          }
+
+          // Augmenting along a shortest path from s to t.
+          Capacity d = std::min(_excess[s], -_excess[t]);
+          Node u = t;
+          Edge e;
+          if (d > _delta) {
+            while ((e = _pred[u]) != INVALID) {
+              Capacity rc;
+              if (u == _graph.target(e)) {
+                rc = _res_cap[e];
+                u = _graph.source(e);
+              } else {
+                rc = (*_flow)[e];
+                u = _graph.target(e);
+              }
+              if (rc < d) d = rc;
+            }
+          }
+          u = t;
+          while ((e = _pred[u]) != INVALID) {
+            if (u == _graph.target(e)) {
+              (*_flow)[e] += d;
+              _res_cap[e] -= d;
+              u = _graph.source(e);
+            } else {
+              (*_flow)[e] -= d;
+              _res_cap[e] += d;
+              u = _graph.target(e);
+            }
+          }
+          _excess[s] -= d;
+          _excess[t] += d;
+
+          if (_excess[s] < _delta) ++next_node;
+        }
+
+        if (_delta == 1) break;
+        if (++phase_cnt > _phase_num / 4) factor = 2;
+        _delta = _delta <= factor ? 1 : _delta / factor;
+      }
+
+      // Handling non-zero lower bounds
+      if (_lower) {
+        for (EdgeIt e(_graph); e != INVALID; ++e)
+          (*_flow)[e] += (*_lower)[e];
+      }
+      return true;
+    }
+
+    /// Execute the successive shortest path algorithm.
+    bool startWithoutScaling() {
+      // Finding excess nodes
+      for (NodeIt n(_graph); n != INVALID; ++n)
+        if (_excess[n] > 0) _excess_nodes.push_back(n);
+      if (_excess_nodes.size() == 0) return true;
+      int next_node = 0;
+
+      // Finding shortest paths
+      Node s, t;
+      while ( _excess[_excess_nodes[next_node]] > 0 ||
+              ++next_node < int(_excess_nodes.size()) )
+      {
+        // Running Dijkstra
+        s = _excess_nodes[next_node];
+        if ((t = _dijkstra->run(s)) == INVALID) return false;
+
+        // Augmenting along a shortest path from s to t
+        Capacity d = std::min(_excess[s], -_excess[t]);
+        Node u = t;
+        Edge e;
+        if (d > 1) {
+          while ((e = _pred[u]) != INVALID) {
+            Capacity rc;
+            if (u == _graph.target(e)) {
+              rc = _res_cap[e];
+              u = _graph.source(e);
+            } else {
+              rc = (*_flow)[e];
+              u = _graph.target(e);
+            }
+            if (rc < d) d = rc;
+          }
+        }
+        u = t;
+        while ((e = _pred[u]) != INVALID) {
+          if (u == _graph.target(e)) {
+            (*_flow)[e] += d;
+            _res_cap[e] -= d;
+            u = _graph.source(e);
+          } else {
+            (*_flow)[e] -= d;
+            _res_cap[e] += d;
+            u = _graph.target(e);
+          }
+        }
+        _excess[s] -= d;
+        _excess[t] += d;
+      }
+
+      // Handling non-zero lower bounds
+      if (_lower) {
+        for (EdgeIt e(_graph); e != INVALID; ++e)
+          (*_flow)[e] += (*_lower)[e];
+      }
+      return true;
+    }
+
+  }; //class CapacityScaling
+
+  ///@}
+
+} //namespace lemon
+
+#endif //LEMON_CAPACITY_SCALING_H
Index: lemon/circulation.h
===================================================================
--- lemon/circulation.h	(revision 2618)
+++ lemon/circulation.h	(revision 2618)
@@ -0,0 +1,648 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_CIRCULATION_H
+#define LEMON_CIRCULATION_H
+
+#include <lemon/graph_utils.h>
+#include <iostream>
+#include <queue>
+#include <lemon/tolerance.h>
+#include <lemon/elevator.h>
+
+///\ingroup max_flow
+///\file
+///\brief Push-prelabel algorithm for finding a feasible circulation.
+///
+namespace lemon {
+
+  /// \brief Default traits class of Circulation class.
+  ///
+  /// Default traits class of Circulation class.
+  /// \param _Graph Graph type.
+  /// \param _CapacityMap Type of capacity map.
+  template <typename _Graph, typename _LCapMap, 
+	    typename _UCapMap, typename _DeltaMap>
+  struct CirculationDefaultTraits {
+
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the circulation lower
+    /// bound.
+    ///
+    /// The type of the map that stores the circulation lower bound.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _LCapMap LCapMap;
+
+    /// \brief The type of the map that stores the circulation upper
+    /// bound.
+    ///
+    /// The type of the map that stores the circulation upper bound.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _UCapMap UCapMap;
+
+    /// \brief The type of the map that stores the upper bound of
+    /// node excess.
+    ///
+    /// The type of the map that stores the lower bound of node
+    /// excess. It must meet the \ref concepts::ReadMap "ReadMap"
+    /// concept.
+    typedef _DeltaMap DeltaMap;
+
+    /// \brief The type of the length of the edges.
+    typedef typename DeltaMap::Value Value;
+
+    /// \brief The map type that stores the flow values.
+    ///
+    /// The map type that stores the flow values. 
+    /// It must meet the \ref concepts::ReadWriteMap "ReadWriteMap" concept.
+    typedef typename Graph::template EdgeMap<Value> FlowMap;
+
+    /// \brief Instantiates a FlowMap.
+    ///
+    /// This function instantiates a \ref FlowMap. 
+    /// \param graph The graph, to which we would like to define the flow map.
+    static FlowMap* createFlowMap(const Graph& graph) {
+      return new FlowMap(graph);
+    }
+
+    /// \brief The eleavator type used by Circulation algorithm.
+    /// 
+    /// The elevator type used by Circulation algorithm.
+    ///
+    /// \sa Elevator
+    /// \sa LinkedElevator
+    typedef lemon::Elevator<Graph, typename Graph::Node> Elevator;
+    
+    /// \brief Instantiates an Elevator.
+    ///
+    /// This function instantiates a \ref Elevator. 
+    /// \param graph The graph, to which we would like to define the elevator.
+    /// \param max_level The maximum level of the elevator.
+    static Elevator* createElevator(const Graph& graph, int max_level) {
+      return new Elevator(graph, max_level);
+    }
+
+    /// \brief The tolerance used by the algorithm
+    ///
+    /// The tolerance used by the algorithm to handle inexact computation.
+    typedef lemon::Tolerance<Value> Tolerance;
+
+  };
+  
+  ///Push-relabel algorithm for the Network Circulation Problem.
+  
+  ///\ingroup max_flow
+  ///This class implements a push-relabel algorithm
+  ///for the Network Circulation Problem.
+  ///The exact formulation of this problem is the following.
+  /// \f[\sum_{e\in\rho(v)}x(e)-\sum_{e\in\delta(v)}x(e)\leq -delta(v)\quad \forall v\in V \f]
+  /// \f[ lo(e)\leq x(e) \leq up(e) \quad \forall e\in E \f]
+  ///
+  template<class _Graph,
+	   class _LCapMap=typename _Graph::template EdgeMap<int>,
+	   class _UCapMap=_LCapMap,
+	   class _DeltaMap=typename _Graph::template NodeMap<
+	     typename _UCapMap::Value>,
+	   class _Traits=CirculationDefaultTraits<_Graph, _LCapMap, 
+						  _UCapMap, _DeltaMap> >
+  class Circulation {
+
+    typedef _Traits Traits;
+    typedef typename Traits::Graph Graph;
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename Traits::Value Value;
+
+    typedef typename Traits::LCapMap LCapMap;
+    typedef typename Traits::UCapMap UCapMap;
+    typedef typename Traits::DeltaMap DeltaMap;
+    typedef typename Traits::FlowMap FlowMap;
+    typedef typename Traits::Elevator Elevator;
+    typedef typename Traits::Tolerance Tolerance;
+
+    typedef typename Graph::template NodeMap<Value> ExcessMap;
+
+    const Graph &_g;
+    int _node_num;
+
+    const LCapMap *_lo;
+    const UCapMap *_up;
+    const DeltaMap *_delta;
+
+    FlowMap *_flow;
+    bool _local_flow;
+
+    Elevator* _level;
+    bool _local_level;
+
+    ExcessMap* _excess;
+
+    Tolerance _tol;
+    int _el;
+
+  public:
+
+    typedef Circulation Create;
+
+    ///\name Named template parameters
+
+    ///@{
+
+    template <typename _FlowMap>
+    struct DefFlowMapTraits : public Traits {
+      typedef _FlowMap FlowMap;
+      static FlowMap *createFlowMap(const Graph&) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// FlowMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting FlowMap
+    /// type
+    template <typename _FlowMap>
+    struct DefFlowMap 
+      : public Circulation<Graph, LCapMap, UCapMap, DeltaMap, 
+			   DefFlowMapTraits<_FlowMap> > {
+      typedef Circulation<Graph, LCapMap, UCapMap, DeltaMap, 
+			  DefFlowMapTraits<_FlowMap> > Create;
+    };
+
+    template <typename _Elevator>
+    struct DefElevatorTraits : public Traits {
+      typedef _Elevator Elevator;
+      static Elevator *createElevator(const Graph&, int) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// Elevator type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting Elevator
+    /// type
+    template <typename _Elevator>
+    struct DefElevator 
+      : public Circulation<Graph, LCapMap, UCapMap, DeltaMap, 
+			   DefElevatorTraits<_Elevator> > {
+      typedef Circulation<Graph, LCapMap, UCapMap, DeltaMap,
+			  DefElevatorTraits<_Elevator> > Create;
+    };
+
+    template <typename _Elevator>
+    struct DefStandardElevatorTraits : public Traits {
+      typedef _Elevator Elevator;
+      static Elevator *createElevator(const Graph& graph, int max_level) {
+	return new Elevator(graph, max_level);
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// Elevator type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting Elevator
+    /// type. The Elevator should be standard constructor interface, ie.
+    /// the graph and the maximum level should be passed to it.
+    template <typename _Elevator>
+    struct DefStandardElevator 
+      : public Circulation<Graph, LCapMap, UCapMap, DeltaMap, 
+		       DefStandardElevatorTraits<_Elevator> > {
+      typedef Circulation<Graph, LCapMap, UCapMap, DeltaMap,
+		      DefStandardElevatorTraits<_Elevator> > Create;
+    };    
+
+    /// @}
+
+  protected:
+
+    Circulation() {}
+  
+  public:
+
+    /// The constructor of the class.
+
+    /// The constructor of the class. 
+    /// \param g The directed graph the algorithm runs on. 
+    /// \param lo The lower bound capacity of the edges. 
+    /// \param up The upper bound capacity of the edges.
+    /// \param delta The lower bound on node excess.
+    Circulation(const Graph &g,const LCapMap &lo,
+		const UCapMap &up,const DeltaMap &delta) 
+      : _g(g), _node_num(),
+	_lo(&lo),_up(&up),_delta(&delta),_flow(0),_local_flow(false),
+	_level(0), _local_level(false), _excess(0), _el() {}
+
+    /// Destrcutor.
+    ~Circulation() {
+      destroyStructures();
+    }
+
+  private:
+
+    void createStructures() {
+      _node_num = _el = countNodes(_g);
+
+      if (!_flow) {
+	_flow = Traits::createFlowMap(_g);
+	_local_flow = true;
+      }
+      if (!_level) {
+	_level = Traits::createElevator(_g, _node_num);
+	_local_level = true;
+      }
+      if (!_excess) {
+	_excess = new ExcessMap(_g);
+      }
+    }
+
+    void destroyStructures() {
+      if (_local_flow) {
+	delete _flow;
+      }
+      if (_local_level) {
+	delete _level;
+      }
+      if (_excess) {
+	delete _excess;
+      }
+    }
+
+  public:
+
+    /// Sets the lower bound capacity map.
+
+    /// Sets the lower bound capacity map.
+    /// \return \c (*this)
+    Circulation& lowerCapMap(const LCapMap& map) {
+      _lo = &map;
+      return *this;
+    }
+
+    /// Sets the upper bound capacity map.
+
+    /// Sets the upper bound capacity map.
+    /// \return \c (*this)
+    Circulation& upperCapMap(const LCapMap& map) {
+      _up = &map;
+      return *this;
+    }
+
+    /// Sets the lower bound map on excess.
+
+    /// Sets the lower bound map on excess.
+    /// \return \c (*this)
+    Circulation& deltaMap(const DeltaMap& map) {
+      _delta = &map;
+      return *this;
+    }
+
+    /// Sets the flow map.
+
+    /// Sets the flow map.
+    /// \return \c (*this)
+    Circulation& flowMap(FlowMap& map) {
+      if (_local_flow) {
+	delete _flow;
+	_local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// Returns the flow map.
+
+    /// \return The flow map.
+    ///
+    const FlowMap& flowMap() {
+      return *_flow;
+    }
+
+    /// Sets the elevator.
+
+    /// Sets the elevator.
+    /// \return \c (*this)
+    Circulation& elevator(Elevator& elevator) {
+      if (_local_level) {
+	delete _level;
+	_local_level = false;
+      }
+      _level = &elevator;
+      return *this;
+    }
+
+    /// Returns the elevator.
+
+    /// \return The elevator.
+    ///
+    const Elevator& elevator() {
+      return *_level;
+    }
+    
+    /// Sets the tolerance used by algorithm.
+
+    /// Sets the tolerance used by algorithm.
+    ///
+    Circulation& tolerance(const Tolerance& tolerance) const {
+      _tol = tolerance;
+      return *this;
+    } 
+
+    /// Returns the tolerance used by algorithm.
+
+    /// Returns the tolerance used by algorithm.
+    ///
+    const Tolerance& tolerance() const {
+      return tolerance;
+    } 
+    
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use one of the
+    /// member functions called \c run().
+    /// \n 
+    /// If you need more control on initial solution or execution then
+    /// you have to call one \ref init() function and then the start()
+    /// function.
+    
+    ///@{
+  
+    /// Initializes the internal data structures.
+
+    /// Initializes the internal data structures. This function sets
+    /// all flow values to the lower bound.  
+    /// \return This function returns false if the initialization
+    /// process found a barrier.
+    void init() 
+    {
+      createStructures();
+
+      for(NodeIt n(_g);n!=INVALID;++n) {
+	_excess->set(n, (*_delta)[n]);
+      }
+     
+      for (EdgeIt e(_g);e!=INVALID;++e) {
+	_flow->set(e, (*_lo)[e]);
+	_excess->set(_g.target(e), (*_excess)[_g.target(e)] + (*_flow)[e]);
+	_excess->set(_g.source(e), (*_excess)[_g.source(e)] - (*_flow)[e]);
+      }
+
+      // global relabeling tested, but in general case it provides
+      // worse performance for random graphs
+      _level->initStart();
+      for(NodeIt n(_g);n!=INVALID;++n)
+	_level->initAddItem(n);
+      _level->initFinish();
+      for(NodeIt n(_g);n!=INVALID;++n)
+	if(_tol.positive((*_excess)[n]))
+	  _level->activate(n);
+    }
+
+    /// Initializes the internal data structures.
+
+    /// Initializes the internal data structures. This functions uses
+    /// greedy approach to construct the initial solution. 
+    void greedyInit() 
+    {
+      createStructures();
+     
+      for(NodeIt n(_g);n!=INVALID;++n) {
+	_excess->set(n, (*_delta)[n]);
+      }
+     
+      for (EdgeIt e(_g);e!=INVALID;++e) {
+	if (!_tol.positive((*_excess)[_g.target(e)] + (*_up)[e])) {
+	  _flow->set(e, (*_up)[e]);
+	  _excess->set(_g.target(e), (*_excess)[_g.target(e)] + (*_up)[e]);
+	  _excess->set(_g.source(e), (*_excess)[_g.source(e)] - (*_up)[e]);
+	} else if (_tol.positive((*_excess)[_g.target(e)] + (*_lo)[e])) {
+	  _flow->set(e, (*_lo)[e]);
+	  _excess->set(_g.target(e), (*_excess)[_g.target(e)] + (*_lo)[e]);
+	  _excess->set(_g.source(e), (*_excess)[_g.source(e)] - (*_lo)[e]);
+	} else {
+	  Value fc = -(*_excess)[_g.target(e)];
+	  _flow->set(e, fc);
+	  _excess->set(_g.target(e), 0);
+	  _excess->set(_g.source(e), (*_excess)[_g.source(e)] - fc);
+	}
+      }
+     
+      _level->initStart();
+      for(NodeIt n(_g);n!=INVALID;++n)
+	_level->initAddItem(n);
+      _level->initFinish();
+      for(NodeIt n(_g);n!=INVALID;++n)
+	if(_tol.positive((*_excess)[n]))
+	  _level->activate(n);
+    }
+
+    ///Starts the algorithm
+
+    ///This function starts the algorithm.
+    ///\return This function returns true if it found a feasible circulation.
+    ///
+    ///\sa barrier()
+    bool start() 
+    {
+      
+      Node act;
+      Node bact=INVALID;
+      Node last_activated=INVALID;
+      while((act=_level->highestActive())!=INVALID) {
+	int actlevel=(*_level)[act];
+	int mlevel=_node_num;
+	Value exc=(*_excess)[act];
+
+	for(OutEdgeIt e(_g,act);e!=INVALID; ++e) {
+	  Node v = _g.target(e);
+	  Value fc=(*_up)[e]-(*_flow)[e];
+	  if(!_tol.positive(fc)) continue;
+	  if((*_level)[v]<actlevel) {
+	    if(!_tol.less(fc, exc)) {
+	      _flow->set(e, (*_flow)[e] + exc);
+	      _excess->set(v, (*_excess)[v] + exc);
+	      if(!_level->active(v) && _tol.positive((*_excess)[v]))
+		_level->activate(v);
+	      _excess->set(act,0);
+	      _level->deactivate(act);
+	      goto next_l;
+	    }
+	    else {
+	      _flow->set(e, (*_up)[e]);
+	      _excess->set(v, (*_excess)[v] + fc);
+	      if(!_level->active(v) && _tol.positive((*_excess)[v]))
+		_level->activate(v);
+	      exc-=fc;
+	    }
+	  } 
+	  else if((*_level)[v]<mlevel) mlevel=(*_level)[v];
+	}
+	for(InEdgeIt e(_g,act);e!=INVALID; ++e) {
+	  Node v = _g.source(e);
+	  Value fc=(*_flow)[e]-(*_lo)[e];
+	  if(!_tol.positive(fc)) continue;
+	  if((*_level)[v]<actlevel) {
+	    if(!_tol.less(fc, exc)) {
+	      _flow->set(e, (*_flow)[e] - exc);
+	      _excess->set(v, (*_excess)[v] + exc);
+	      if(!_level->active(v) && _tol.positive((*_excess)[v]))
+		_level->activate(v);
+	      _excess->set(act,0);
+	      _level->deactivate(act);
+	      goto next_l;
+	    }
+	    else {
+	      _flow->set(e, (*_lo)[e]);
+	      _excess->set(v, (*_excess)[v] + fc);
+	      if(!_level->active(v) && _tol.positive((*_excess)[v]))
+		_level->activate(v);
+	      exc-=fc;
+	    }
+	  } 
+	  else if((*_level)[v]<mlevel) mlevel=(*_level)[v];
+	}
+   
+	_excess->set(act, exc);
+	if(!_tol.positive(exc)) _level->deactivate(act);
+	else if(mlevel==_node_num) {
+	  _level->liftHighestActiveToTop();
+	  _el = _node_num;
+	  return false;
+	}
+	else {
+	  _level->liftHighestActive(mlevel+1);
+	  if(_level->onLevel(actlevel)==0) {
+	    _el = actlevel;
+	    return false;
+	  }
+	}
+      next_l:
+	;
+      }
+      return true;
+    }
+
+    /// Runs the circulation algorithm.  
+
+    /// Runs the circulation algorithm.
+    /// \note fc.run() is just a shortcut of the following code.
+    /// \code
+    ///   fc.greedyInit();
+    ///   return fc.start();
+    /// \endcode
+    bool run() {
+      greedyInit();
+      return start();
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the %Circulation algorithm can be obtained using
+    /// these functions.
+    /// \n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+    
+    ///Returns a barrier
+    
+    ///Barrier is a set \e B of nodes for which
+    /// \f[ \sum_{v\in B}-delta(v)<\sum_{e\in\rho(B)}lo(e)-\sum_{e\in\delta(B)}up(e) \f]
+    ///holds. The existence of a set with this property prooves that a feasible
+    ///flow cannot exists.
+    ///\sa checkBarrier()
+    ///\sa run()
+    template<class GT>
+    void barrierMap(GT &bar) 
+    {
+      for(NodeIt n(_g);n!=INVALID;++n)
+	bar.set(n, (*_level)[n] >= _el);
+    }  
+
+    ///Returns true if the node is in the barrier
+
+    ///Returns true if the node is in the barrier
+    ///\sa barrierMap()
+    bool barrier(const Node& node) 
+    {
+      return (*_level)[node] >= _el;
+    }  
+
+    /// \brief Returns the flow on the edge.
+    ///
+    /// Sets the \c flowMap to the flow on the edges. This method can
+    /// be called after the second phase of algorithm.
+    Value flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// @}
+
+    /// \name Checker Functions
+    /// The feasibility  of the results can be checked using
+    /// these functions.
+    /// \n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    ///Check if the  \c flow is a feasible circulation
+    bool checkFlow() {
+      for(EdgeIt e(_g);e!=INVALID;++e)
+	if((*_flow)[e]<(*_lo)[e]||(*_flow)[e]>(*_up)[e]) return false;
+      for(NodeIt n(_g);n!=INVALID;++n)
+	{
+	  Value dif=-(*_delta)[n];
+	  for(InEdgeIt e(_g,n);e!=INVALID;++e) dif-=(*_flow)[e];
+	  for(OutEdgeIt e(_g,n);e!=INVALID;++e) dif+=(*_flow)[e];
+	  if(_tol.negative(dif)) return false;
+	}
+      return true;
+    }
+
+    ///Check whether or not the last execution provides a barrier
+
+    ///Check whether or not the last execution provides a barrier
+    ///\sa barrier()
+    bool checkBarrier() 
+    {
+      Value delta=0;
+      for(NodeIt n(_g);n!=INVALID;++n)
+	if(barrier(n))
+	  delta-=(*_delta)[n];
+      for(EdgeIt e(_g);e!=INVALID;++e)
+	{
+	  Node s=_g.source(e);
+	  Node t=_g.target(e);
+	  if(barrier(s)&&!barrier(t)) delta+=(*_up)[e];
+	  else if(barrier(t)&&!barrier(s)) delta-=(*_lo)[e];
+	}
+      return _tol.negative(delta);
+    }
+
+    /// @}
+
+  };
+  
+}
+
+#endif
Index: lemon/color.cc
===================================================================
--- lemon/color.cc	(revision 2174)
+++ lemon/color.cc	(revision 2553)
@@ -1,7 +1,7 @@
- /* -*- C++ -*-
+/* -*- C++ -*-
  *
  * This file is a part of LEMON, a generic C++ optimization library
  *
- * Copyright (C) 2003-2006
+ * Copyright (C) 2003-2008
  * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
  * (Egervary Research Group on Combinatorial Optimization, EGRES).
Index: lemon/color.h
===================================================================
--- lemon/color.h	(revision 2656)
+++ lemon/color.h	(revision 2569)
@@ -3,5 +3,5 @@
  * This file is a part of LEMON, a generic C++ optimization library
  *
- * Copyright (C) 2003-2006
+ * Copyright (C) 2003-2008
  * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
  * (Egervary Research Group on Combinatorial Optimization, EGRES).
@@ -21,5 +21,5 @@
 
 #include<vector>
-#include<cmath>
+#include<lemon/math.h>
 #include<lemon/maps.h>
 
@@ -33,34 +33,34 @@
 namespace lemon {
 
+
   /// \addtogroup misc
   /// @{
 
-///Data structure representing RGB colors.
-
-///Data structure representing RGB colors.
-///\ingroup misc
-class Color
-{
-  double _r,_g,_b;
-public:
-  ///Default constructor
-  Color() {}
-  ///Constructor
-  Color(double r,double g,double b) :_r(r),_g(g),_b(b) {};
-  ///Set the red component
-  double & red() {return _r;}
-  ///Return the red component
-  const double & red() const {return _r;}
-  ///Set the green component
-  double & green() {return _g;}
-  ///Return the green component
-  const double & green() const {return _g;}
-  ///Set the blue component
-  double & blue() {return _b;}
-  ///Return the blue component
-  const double & blue() const {return _b;}
-  ///Set the color components
-  void set(double r,double g,double b) { _r=r;_g=g;_b=b; };
-};
+  ///Data structure representing RGB colors.
+
+  ///Data structure representing RGB colors.
+  class Color
+  {
+    double _r,_g,_b;
+  public:
+    ///Default constructor
+    Color() {}
+    ///Constructor
+    Color(double r,double g,double b) :_r(r),_g(g),_b(b) {};
+    ///Set the red component
+    double & red() {return _r;}
+    ///Return the red component
+    const double & red() const {return _r;}
+    ///Set the green component
+    double & green() {return _g;}
+    ///Return the green component
+    const double & green() const {return _g;}
+    ///Set the blue component
+    double & blue() {return _b;}
+    ///Return the blue component
+    const double & blue() const {return _b;}
+    ///Set the color components
+    void set(double r,double g,double b) { _r=r;_g=g;_b=b; };
+  };
 
   /// White color constant
@@ -95,103 +95,111 @@
   extern const Color DARK_CYAN;
 
-///Map <tt>int</tt>s to different \ref Color "Color"s
-
-///This map assigns one of the predefined \ref Color "Color"s
-///to each <tt>int</tt>. It is possible to change the colors as well as their
-///number. The integer range is cyclically mapped to the provided set of colors.
-///
-///This is a true \ref concept::ReferenceMap "reference map", so you can also
-///change the actual colors.
-
-class Palette : public MapBase<int,Color>
-{
-  std::vector<Color> colors;
-public:
-  ///Constructor
-
-  ///Constructor
-  ///\param have_white indicates whether white is
-  ///amongst the provided color (\c true) or not (\c false). If it is true,
-  ///white will be assigned to \c 0.
-  ///\param num the number of the allocated colors. If it is \c 0,
-  ///the default color configuration is set up (26 color plus the white).
-  ///If \c num is less then 26/27 then the default color list is cut. Otherwise
-  ///the color list is filled repeatedly with the default color list.
-  ///(The colors can be changed later on.)
-  Palette(bool have_white=false,int num=0)
+  ///Map <tt>int</tt>s to different \ref Color "Color"s
+
+  ///This map assigns one of the predefined \ref Color "Color"s to
+  ///each <tt>int</tt>. It is possible to change the colors as well as
+  ///their number. The integer range is cyclically mapped to the
+  ///provided set of colors.
+  ///
+  ///This is a true \ref concepts::ReferenceMap "reference map", so
+  ///you can also change the actual colors.
+
+  class Palette : public MapBase<int,Color>
   {
-    do {
-      if(have_white) colors.push_back(Color(1,1,1));
-
-      colors.push_back(Color(0,0,0));
-      colors.push_back(Color(1,0,0));
-      colors.push_back(Color(0,1,0));
-      colors.push_back(Color(0,0,1));
-      colors.push_back(Color(1,1,0));
-      colors.push_back(Color(1,0,1));
-      colors.push_back(Color(0,1,1));
+    std::vector<Color> colors;
+  public:
+    ///Constructor
+
+    ///Constructor 
+    ///\param num the number of the allocated colors. If it is \c -1,
+    ///the default color configuration is set up (26 color plus the
+    ///white).  If \c num is less then 26/27 then the default color
+    ///list is cut. Otherwise the color list is filled repeatedly with
+    ///the default color list.  (The colors can be changed later on.)
+    ///\param have_white indicates whether white is amongst the
+    ///provided color (\c true) or not (\c false). If it is true,
+    ///white will be assigned to \c 0.
+    Palette(int num=-1,bool have_white=false)
+    {
+      if (num==0) return;
+      do {
+        if(have_white) colors.push_back(Color(1,1,1));
+
+        colors.push_back(Color(0,0,0));
+        colors.push_back(Color(1,0,0));
+        colors.push_back(Color(0,1,0));
+        colors.push_back(Color(0,0,1));
+        colors.push_back(Color(1,1,0));
+        colors.push_back(Color(1,0,1));
+        colors.push_back(Color(0,1,1));
       
-      colors.push_back(Color(.5,0,0));
-      colors.push_back(Color(0,.5,0));
-      colors.push_back(Color(0,0,.5));
-      colors.push_back(Color(.5,.5,0));
-      colors.push_back(Color(.5,0,.5));
-      colors.push_back(Color(0,.5,.5));
+        colors.push_back(Color(.5,0,0));
+        colors.push_back(Color(0,.5,0));
+        colors.push_back(Color(0,0,.5));
+        colors.push_back(Color(.5,.5,0));
+        colors.push_back(Color(.5,0,.5));
+        colors.push_back(Color(0,.5,.5));
       
-      colors.push_back(Color(.5,.5,.5));
-      colors.push_back(Color(1,.5,.5));
-      colors.push_back(Color(.5,1,.5));
-      colors.push_back(Color(.5,.5,1));
-      colors.push_back(Color(1,1,.5));
-      colors.push_back(Color(1,.5,1));
-      colors.push_back(Color(.5,1,1));
+        colors.push_back(Color(.5,.5,.5));
+        colors.push_back(Color(1,.5,.5));
+        colors.push_back(Color(.5,1,.5));
+        colors.push_back(Color(.5,.5,1));
+        colors.push_back(Color(1,1,.5));
+        colors.push_back(Color(1,.5,1));
+        colors.push_back(Color(.5,1,1));
       
-      colors.push_back(Color(1,.5,0));
-      colors.push_back(Color(.5,1,0));
-      colors.push_back(Color(1,0,.5));
-      colors.push_back(Color(0,1,.5));
-      colors.push_back(Color(0,.5,1));
-      colors.push_back(Color(.5,0,1));
-    } while(int(colors.size())<num);
-    //    colors.push_back(Color(1,1,1));
-    if(num>0) colors.resize(num);
+        colors.push_back(Color(1,.5,0));
+        colors.push_back(Color(.5,1,0));
+        colors.push_back(Color(1,0,.5));
+        colors.push_back(Color(0,1,.5));
+        colors.push_back(Color(0,.5,1));
+        colors.push_back(Color(.5,0,1));
+      } while(int(colors.size())<num);
+      //    colors.push_back(Color(1,1,1));
+      if(num>=0) colors.resize(num);
+    }
+    ///\e
+    Color &operator[](int i)
+    {
+      return colors[i%colors.size()];
+    }
+    ///\e
+    const Color &operator[](int i) const
+    {
+      return colors[i%colors.size()];
+    }
+    ///\e
+    void set(int i,const Color &c)
+    {
+      colors[i%colors.size()]=c;
+    }
+    ///\e
+    void add(const Color &c) 
+    {
+      colors.push_back(c);
+    }
+
+    ///Sets the number of the exiting colors.
+    void resize(int s) { colors.resize(s);}
+    ///Returns the number of the existing colors.
+    int size() const { return int(colors.size());}
+  };
+
+  ///Returns a visible distinct \ref Color
+
+  ///Returns a \ref Color which is as different from the given parameter
+  ///as it is possible.
+  inline Color distantColor(const Color &c) 
+  {
+    return Color(c.red()<.5?1:0,c.green()<.5?1:0,c.blue()<.5?1:0);
   }
-  ///\e
-  Color &operator[](int i)
-  {
-    return colors[i%colors.size()];
+  ///Returns black for light colors and white for the dark ones.
+
+  ///Returns black for light colors and white for the dark ones.
+  inline Color distantBW(const Color &c){
+    return (.2125*c.red()+.7154*c.green()+.0721*c.blue())<.5 ? WHITE : BLACK;
   }
-  ///\e
-  const Color &operator[](int i) const
-  {
-    return colors[i%colors.size()];
-  }
-  ///\e
-  void set(int i,const Color &c)
-  {
-    colors[i%colors.size()]=c;
-  }
-  ///Sets the number of the exiting colors.
-  void resize(int s) { colors.resize(s);}
-  ///Returns the number of the existing colors.
-  std::size_t size() const { return colors.size();}
-};
-
-///Returns a visible distinct \ref Color
-
-///Returns a \ref Color which is as different from the given parameter
-///as it is possible.
-inline Color distantColor(const Color &c) 
-{
-  return Color(c.red()<.5?1:0,c.green()<.5?1:0,c.blue()<.5?1:0);
-}
-///Returns black for light colors and white for the dark ones.
-
-///Returns black for light colors and white for the dark ones.
-inline Color distantBW(const Color &c){
-  return (.2125*c.red()+.7154*c.green()+.0721*c.blue())<.5 ? WHITE : BLACK;
-}
-
-/// @}
+
+  /// @}
 
 } //END OF NAMESPACE LEMON
Index: lemon/concept_check.h
===================================================================
--- lemon/concept_check.h	(revision 2553)
+++ lemon/concept_check.h	(revision 2553)
@@ -0,0 +1,105 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+// Modified for use in LEMON.
+// We should really consider using Boost...
+
+//
+// (C) Copyright Jeremy Siek 2000.
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// Revision History:
+//   05 May   2001: Workarounds for HP aCC from Thomas Matelich. (Jeremy Siek)
+//   02 April 2001: Removed limits header altogether. (Jeremy Siek)
+//   01 April 2001: Modified to use new <boost/limits.hpp> header. (JMaddock)
+//
+
+// See http://www.boost.org/libs/concept_check for documentation.
+
+#ifndef LEMON_BOOST_CONCEPT_CHECKS_HPP
+#define LEMON_BOOST_CONCEPT_CHECKS_HPP
+
+namespace lemon {
+
+  /*
+    "inline" is used for ignore_unused_variable_warning()
+    and function_requires() to make sure there is no
+    overtarget with g++.
+  */
+
+  template <class T> inline void ignore_unused_variable_warning(const T&) { }
+
+  template <class Concept>
+  inline void function_requires()
+  {
+#if !defined(NDEBUG)
+    void (Concept::*x)() = & Concept::constraints;
+    ignore_unused_variable_warning(x);
+#endif
+  }
+
+  template <typename Concept, typename Type>
+  inline void checkConcept() {
+#if !defined(NDEBUG)
+    typedef typename Concept::template Constraints<Type> ConceptCheck;
+    void (ConceptCheck::*x)() = & ConceptCheck::constraints;
+    ignore_unused_variable_warning(x);
+#endif
+  }
+
+#define BOOST_CLASS_REQUIRE(type_var, ns, concept) \
+  typedef void (ns::concept <type_var>::* func##type_var##concept)(); \
+  template <func##type_var##concept Tp1_> \
+  struct concept_checking_##type_var##concept { }; \
+  typedef concept_checking_##type_var##concept< \
+    BOOST_FPTR ns::concept<type_var>::constraints> \
+    concept_checking_typedef_##type_var##concept
+
+#define BOOST_CLASS_REQUIRE2(type_var1, type_var2, ns, concept) \
+  typedef void (ns::concept <type_var1,type_var2>::* \
+     func##type_var1##type_var2##concept)(); \
+  template <func##type_var1##type_var2##concept Tp1_> \
+  struct concept_checking_##type_var1##type_var2##concept { }; \
+  typedef concept_checking_##type_var1##type_var2##concept< \
+    BOOST_FPTR ns::concept<type_var1,type_var2>::constraints> \
+    concept_checking_typedef_##type_var1##type_var2##concept
+
+#define BOOST_CLASS_REQUIRE3(tv1, tv2, tv3, ns, concept) \
+  typedef void (ns::concept <tv1,tv2,tv3>::* \
+     func##tv1##tv2##tv3##concept)(); \
+  template <func##tv1##tv2##tv3##concept Tp1_> \
+  struct concept_checking_##tv1##tv2##tv3##concept { }; \
+  typedef concept_checking_##tv1##tv2##tv3##concept< \
+    BOOST_FPTR ns::concept<tv1,tv2,tv3>::constraints> \
+    concept_checking_typedef_##tv1##tv2##tv3##concept
+
+#define BOOST_CLASS_REQUIRE4(tv1, tv2, tv3, tv4, ns, concept) \
+  typedef void (ns::concept <tv1,tv2,tv3,tv4>::* \
+     func##tv1##tv2##tv3##tv4##concept)(); \
+  template <func##tv1##tv2##tv3##tv4##concept Tp1_> \
+  struct concept_checking_##tv1##tv2##tv3##tv4##concept { }; \
+  typedef concept_checking_##tv1##tv2##tv3##tv4##concept< \
+    BOOST_FPTR ns::concept<tv1,tv2,tv3,tv4>::constraints> \
+    concept_checking_typedef_##tv1##tv2##tv3##tv4##concept
+
+
+} // namespace lemon
+
+#endif // LEMON_BOOST_CONCEPT_CHECKS_HPP
Index: lemon/concepts/bpugraph.h
===================================================================
--- lemon/concepts/bpugraph.h	(revision 2553)
+++ lemon/concepts/bpugraph.h	(revision 2553)
@@ -0,0 +1,1004 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/// \ingroup graph_concepts
+/// \file
+/// \brief The concept of Bipartite Undirected Graphs.
+
+#ifndef LEMON_CONCEPT_BPUGRAPH_H
+#define LEMON_CONCEPT_BPUGRAPH_H
+
+#include <lemon/concepts/graph_components.h>
+
+#include <lemon/concepts/graph.h>
+#include <lemon/concepts/ugraph.h>
+
+#include <lemon/bits/utility.h>
+
+namespace lemon {
+  namespace concepts {
+
+    /// \ingroup graph_concepts
+    ///
+    /// \brief Class describing the concept of Bipartite Undirected Graphs.
+    ///
+    /// This class describes the common interface of all 
+    /// Undirected Bipartite Graphs.
+    ///
+    /// As all concept describing classes it provides only interface
+    /// without any sensible implementation. So any algorithm for
+    /// bipartite undirected graph should compile with this class, but it 
+    /// will not run properly, of course.
+    ///
+    /// In LEMON bipartite undirected graphs also fulfill the concept of 
+    /// the undirected graphs (\ref lemon::concepts::UGraph "UGraph Concept"). 
+    ///
+    /// You can assume that all undirected bipartite graph can be handled
+    /// as an undirected graph and consequently as a static graph.
+    ///
+    /// The bipartite graph stores two types of nodes which are named
+    /// ANode and BNode. The graph type contains two types ANode and
+    /// BNode which are inherited from Node type. Moreover they have
+    /// constructor which converts Node to either ANode or BNode when
+    /// it is possible. Therefor everywhere the Node type can be used
+    /// instead of ANode and BNode. So the usage of the ANode and
+    /// BNode is not suggested.
+    ///
+    /// The iteration on the partition can be done with the ANodeIt and 
+    /// BNodeIt classes. The node map can be used to map values to the nodes
+    /// and similarly we can use to map values for just the ANodes and
+    /// BNodes the ANodeMap and BNodeMap template classes.
+
+    class BpUGraph {
+    public:
+      /// \brief The undirected graph should be tagged by the
+      /// UndirectedTag.
+      ///
+      /// The undirected graph should be tagged by the UndirectedTag. This
+      /// tag helps the enable_if technics to make compile time 
+      /// specializations for undirected graphs.  
+      typedef True UndirectedTag;
+
+      /// \brief The base type of node iterators, 
+      /// or in other words, the trivial node iterator.
+      ///
+      /// This is the base type of each node iterator,
+      /// thus each kind of node iterator converts to this.
+      /// More precisely each kind of node iterator should be inherited 
+      /// from the trivial node iterator. The Node class represents
+      /// both of two types of nodes. 
+      class Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        Node() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        Node(const Node&) { }
+
+        /// Invalid constructor \& conversion.
+
+        /// This constructor initializes the iterator to be invalid.
+        /// \sa Invalid for more details.
+        Node(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(Node) const { return true; }
+
+        /// Inequality operator
+        
+        /// \sa operator==(Node n)
+        ///
+        bool operator!=(Node) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(Node) const { return false; }
+
+      };
+
+      /// \brief Helper class for ANodes.
+      ///
+      /// This class is just a helper class for ANodes, it is not
+      /// suggested to use it directly. It can be converted easily to
+      /// node and vice versa. The usage of this class is limited
+      /// to use just as template parameters for special map types. 
+      class ANode : public Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        ANode() : Node() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        ANode(const ANode&) : Node() { }
+
+        /// Construct the same node as ANode.
+
+        /// Construct the same node as ANode. It may throws assertion
+        /// when the given node is from the BNode set.
+        ANode(const Node&) : Node() { }
+
+        /// Assign node to A-node.
+
+        /// Besides the core graph item functionality each node should
+        /// be convertible to the represented A-node if it is it possible. 
+        ANode& operator=(const Node&) { return *this; }
+
+        /// Invalid constructor \& conversion.
+
+        /// This constructor initializes the iterator to be invalid.
+        /// \sa Invalid for more details.
+        ANode(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(ANode) const { return true; }
+
+        /// Inequality operator
+        
+        /// \sa operator==(ANode n)
+        ///
+        bool operator!=(ANode) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(ANode) const { return false; }
+
+      };
+
+      /// \brief Helper class for BNodes.
+      ///
+      /// This class is just a helper class for BNodes, it is not
+      /// suggested to use it directly. It can be converted easily to
+      /// node and vice versa. The usage of this class is limited
+      /// to use just as template parameters for special map types. 
+      class BNode : public Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        BNode() : Node() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        BNode(const BNode&) : Node() { }
+
+        /// Construct the same node as BNode.
+
+        /// Construct the same node as BNode. It may throws assertion
+        /// when the given node is from the ANode set.
+        BNode(const Node&) : Node() { }
+
+        /// Assign node to B-node.
+
+        /// Besides the core graph item functionality each node should
+        /// be convertible to the represented B-node if it is it possible. 
+        BNode& operator=(const Node&) { return *this; }
+
+        /// Invalid constructor \& conversion.
+
+        /// This constructor initializes the iterator to be invalid.
+        /// \sa Invalid for more details.
+        BNode(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(BNode) const { return true; }
+
+        /// Inequality operator
+        
+        /// \sa operator==(BNode n)
+        ///
+        bool operator!=(BNode) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(BNode) const { return false; }
+
+      };
+    
+      /// This iterator goes through each node.
+
+      /// This iterator goes through each node.
+      /// Its usage is quite simple, for example you can count the number
+      /// of nodes in graph \c g of type \c Graph like this:
+      ///\code
+      /// int count=0;
+      /// for (Graph::NodeIt n(g); n!=INVALID; ++n) ++count;
+      ///\endcode
+      class NodeIt : public Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        NodeIt() { }
+        /// Copy constructor.
+        
+        /// Copy constructor.
+        ///
+        NodeIt(const NodeIt& n) : Node(n) { }
+        /// Invalid constructor \& conversion.
+
+        /// Initialize the iterator to be invalid.
+        /// \sa Invalid for more details.
+        NodeIt(Invalid) { }
+        /// Sets the iterator to the first node.
+
+        /// Sets the iterator to the first node of \c g.
+        ///
+        NodeIt(const BpUGraph&) { }
+        /// Node -> NodeIt conversion.
+
+        /// Sets the iterator to the node of \c the graph pointed by 
+	/// the trivial iterator.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        NodeIt(const BpUGraph&, const Node&) { }
+        /// Next node.
+
+        /// Assign the iterator to the next node.
+        ///
+        NodeIt& operator++() { return *this; }
+      };
+
+      /// This iterator goes through each ANode.
+
+      /// This iterator goes through each ANode.
+      /// Its usage is quite simple, for example you can count the number
+      /// of nodes in graph \c g of type \c Graph like this:
+      ///\code
+      /// int count=0;
+      /// for (Graph::ANodeIt n(g); n!=INVALID; ++n) ++count;
+      ///\endcode
+      class ANodeIt : public Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        ANodeIt() { }
+        /// Copy constructor.
+        
+        /// Copy constructor.
+        ///
+        ANodeIt(const ANodeIt& n) : Node(n) { }
+        /// Invalid constructor \& conversion.
+
+        /// Initialize the iterator to be invalid.
+        /// \sa Invalid for more details.
+        ANodeIt(Invalid) { }
+        /// Sets the iterator to the first node.
+
+        /// Sets the iterator to the first node of \c g.
+        ///
+        ANodeIt(const BpUGraph&) { }
+        /// Node -> ANodeIt conversion.
+
+        /// Sets the iterator to the node of \c the graph pointed by 
+	/// the trivial iterator.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        ANodeIt(const BpUGraph&, const Node&) { }
+        /// Next node.
+
+        /// Assign the iterator to the next node.
+        ///
+        ANodeIt& operator++() { return *this; }
+      };
+
+      /// This iterator goes through each BNode.
+
+      /// This iterator goes through each BNode.
+      /// Its usage is quite simple, for example you can count the number
+      /// of nodes in graph \c g of type \c Graph like this:
+      ///\code
+      /// int count=0;
+      /// for (Graph::BNodeIt n(g); n!=INVALID; ++n) ++count;
+      ///\endcode
+      class BNodeIt : public Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        BNodeIt() { }
+        /// Copy constructor.
+        
+        /// Copy constructor.
+        ///
+        BNodeIt(const BNodeIt& n) : Node(n) { }
+        /// Invalid constructor \& conversion.
+
+        /// Initialize the iterator to be invalid.
+        /// \sa Invalid for more details.
+        BNodeIt(Invalid) { }
+        /// Sets the iterator to the first node.
+
+        /// Sets the iterator to the first node of \c g.
+        ///
+        BNodeIt(const BpUGraph&) { }
+        /// Node -> BNodeIt conversion.
+
+        /// Sets the iterator to the node of \c the graph pointed by 
+	/// the trivial iterator.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        BNodeIt(const BpUGraph&, const Node&) { }
+        /// Next node.
+
+        /// Assign the iterator to the next node.
+        ///
+        BNodeIt& operator++() { return *this; }
+      };
+    
+    
+      /// The base type of the undirected edge iterators.
+
+      /// The base type of the undirected edge iterators.
+      ///
+      class UEdge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        UEdge() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        UEdge(const UEdge&) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        UEdge(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(UEdge) const { return true; }
+        /// Inequality operator
+
+        /// \sa operator==(UEdge n)
+        ///
+        bool operator!=(UEdge) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(UEdge) const { return false; }
+      };
+
+      /// This iterator goes through each undirected edge.
+
+      /// This iterator goes through each undirected edge of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of undirected edges in a graph \c g of type \c Graph as follows:
+      ///\code
+      /// int count=0;
+      /// for(Graph::UEdgeIt e(g); e!=INVALID; ++e) ++count;
+      ///\endcode
+      class UEdgeIt : public UEdge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        UEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        UEdgeIt(const UEdgeIt& e) : UEdge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        UEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to the first undirected edge.
+    
+        /// This constructor sets the iterator to the first undirected edge.
+        UEdgeIt(const BpUGraph&) { }
+        /// UEdge -> UEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator.
+        /// This feature necessitates that each time we
+        /// iterate the undirected edge-set, the iteration order is the 
+	/// same.
+        UEdgeIt(const BpUGraph&, const UEdge&) { } 
+        /// Next undirected edge
+        
+        /// Assign the iterator to the next undirected edge.
+        UEdgeIt& operator++() { return *this; }
+      };
+
+      /// \brief This iterator goes trough the incident undirected 
+      /// edges of a node.
+      ///
+      /// This iterator goes trough the incident undirected edges
+      /// of a certain node
+      /// of a graph.
+      /// Its usage is quite simple, for example you can compute the
+      /// degree (i.e. count the number
+      /// of incident edges of a node \c n
+      /// in graph \c g of type \c Graph as follows.
+      ///\code
+      /// int count=0;
+      /// for(Graph::IncEdgeIt e(g, n); e!=INVALID; ++e) ++count;
+      ///\endcode
+      class IncEdgeIt : public UEdge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        IncEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        IncEdgeIt(const IncEdgeIt& e) : UEdge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        IncEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to first incident edge.
+    
+        /// This constructor set the iterator to the first incident edge of
+        /// the node.
+        IncEdgeIt(const BpUGraph&, const Node&) { }
+        /// UEdge -> IncEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator \c e.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        IncEdgeIt(const BpUGraph&, const UEdge&) { }
+        /// Next incident edge
+
+        /// Assign the iterator to the next incident edge
+	/// of the corresponding node.
+        IncEdgeIt& operator++() { return *this; }
+      };
+
+      /// The directed edge type.
+
+      /// The directed edge type. It can be converted to the
+      /// undirected edge.
+      class Edge : public UEdge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        Edge() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        Edge(const Edge& e) : UEdge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        Edge(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(Edge) const { return true; }
+        /// Inequality operator
+
+        /// \sa operator==(Edge n)
+        ///
+        bool operator!=(Edge) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(Edge) const { return false; }
+	
+      }; 
+      /// This iterator goes through each directed edge.
+
+      /// This iterator goes through each edge of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of edges in a graph \c g of type \c Graph as follows:
+      ///\code
+      /// int count=0;
+      /// for(Graph::EdgeIt e(g); e!=INVALID; ++e) ++count;
+      ///\endcode
+      class EdgeIt : public Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        EdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        EdgeIt(const EdgeIt& e) : Edge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        EdgeIt(Invalid) { }
+        /// This constructor sets the iterator to the first edge.
+    
+        /// This constructor sets the iterator to the first edge of \c g.
+        ///@param g the graph
+        EdgeIt(const BpUGraph &g) { ignore_unused_variable_warning(g); }
+        /// Edge -> EdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator \c e.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        EdgeIt(const BpUGraph&, const Edge&) { } 
+        ///Next edge
+        
+        /// Assign the iterator to the next edge.
+        EdgeIt& operator++() { return *this; }
+      };
+   
+      /// This iterator goes trough the outgoing directed edges of a node.
+
+      /// This iterator goes trough the \e outgoing edges of a certain node
+      /// of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of outgoing edges of a node \c n
+      /// in graph \c g of type \c Graph as follows.
+      ///\code
+      /// int count=0;
+      /// for (Graph::OutEdgeIt e(g, n); e!=INVALID; ++e) ++count;
+      ///\endcode
+    
+      class OutEdgeIt : public Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        OutEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        OutEdgeIt(const OutEdgeIt& e) : Edge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        OutEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to the first outgoing edge.
+    
+        /// This constructor sets the iterator to the first outgoing edge of
+        /// the node.
+        ///@param n the node
+        ///@param g the graph
+        OutEdgeIt(const BpUGraph& n, const Node& g) {
+	  ignore_unused_variable_warning(n);
+	  ignore_unused_variable_warning(g);
+	}
+        /// Edge -> OutEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator.
+	/// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        OutEdgeIt(const BpUGraph&, const Edge&) { }
+        ///Next outgoing edge
+        
+        /// Assign the iterator to the next 
+        /// outgoing edge of the corresponding node.
+        OutEdgeIt& operator++() { return *this; }
+      };
+
+      /// This iterator goes trough the incoming directed edges of a node.
+
+      /// This iterator goes trough the \e incoming edges of a certain node
+      /// of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of outgoing edges of a node \c n
+      /// in graph \c g of type \c Graph as follows.
+      ///\code
+      /// int count=0;
+      /// for(Graph::InEdgeIt e(g, n); e!=INVALID; ++e) ++count;
+      ///\endcode
+
+      class InEdgeIt : public Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        InEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        InEdgeIt(const InEdgeIt& e) : Edge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        InEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to first incoming edge.
+    
+        /// This constructor set the iterator to the first incoming edge of
+        /// the node.
+        ///@param n the node
+        ///@param g the graph
+        InEdgeIt(const BpUGraph& g, const Node& n) { 
+	  ignore_unused_variable_warning(n);
+	  ignore_unused_variable_warning(g);
+	}
+        /// Edge -> InEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator \c e.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        InEdgeIt(const BpUGraph&, const Edge&) { }
+        /// Next incoming edge
+
+        /// Assign the iterator to the next inedge of the corresponding node.
+        ///
+        InEdgeIt& operator++() { return *this; }
+      };
+
+      /// \brief Read write map of the nodes to type \c T.
+      /// 
+      /// ReadWrite map of the nodes to type \c T.
+      /// \sa Reference
+      /// \todo Wrong documentation
+      template<class T> 
+      class NodeMap : public ReadWriteMap< Node, T >
+      {
+      public:
+
+        ///\e
+        NodeMap(const BpUGraph&) { }
+        ///\e
+        NodeMap(const BpUGraph&, T) { }
+
+        ///Copy constructor
+        NodeMap(const NodeMap& nm) : ReadWriteMap< Node, T >(nm) { }
+        ///Assignment operator
+        NodeMap& operator=(const NodeMap&) { return *this; }
+        ///Assignment operator
+        template <typename CMap>
+        NodeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Node, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      /// \brief Read write map of the ANodes to type \c T.
+      /// 
+      /// ReadWrite map of the ANodes to type \c T.
+      /// \sa Reference
+      /// \todo Wrong documentation
+      template<class T> 
+      class ANodeMap : public ReadWriteMap< Node, T >
+      {
+      public:
+
+        ///\e
+        ANodeMap(const BpUGraph&) { }
+        ///\e
+        ANodeMap(const BpUGraph&, T) { }
+
+        ///Copy constructor
+        ANodeMap(const ANodeMap& nm) : ReadWriteMap< Node, T >(nm) { }
+        ///Assignment operator
+        ANodeMap& operator=(const ANodeMap&) { return *this; }
+        ///Assignment operator
+        template <typename CMap>
+        ANodeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Node, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      /// \brief Read write map of the BNodes to type \c T.
+      /// 
+      /// ReadWrite map of the BNodes to type \c T.
+      /// \sa Reference
+      /// \todo Wrong documentation
+      template<class T> 
+      class BNodeMap : public ReadWriteMap< Node, T >
+      {
+      public:
+
+        ///\e
+        BNodeMap(const BpUGraph&) { }
+        ///\e
+        BNodeMap(const BpUGraph&, T) { }
+
+        ///Copy constructor
+        BNodeMap(const BNodeMap& nm) : ReadWriteMap< Node, T >(nm) { }
+        ///Assignment operator
+        BNodeMap& operator=(const BNodeMap&) { return *this; }
+        ///Assignment operator
+        template <typename CMap>
+        BNodeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Node, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      /// \brief Read write map of the directed edges to type \c T.
+      ///
+      /// Reference map of the directed edges to type \c T.
+      /// \sa Reference
+      /// \todo Wrong documentation
+      template<class T> 
+      class EdgeMap : public ReadWriteMap<Edge,T>
+      {
+      public:
+
+        ///\e
+        EdgeMap(const BpUGraph&) { }
+        ///\e
+        EdgeMap(const BpUGraph&, T) { }
+        ///Copy constructor
+        EdgeMap(const EdgeMap& em) : ReadWriteMap<Edge,T>(em) { }
+        ///Assignment operator
+        EdgeMap& operator=(const EdgeMap&) { return *this; }
+        ///Assignment operator
+        template <typename CMap>
+        EdgeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Edge, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      /// Read write map of the undirected edges to type \c T.
+
+      /// Reference map of the edges to type \c T.
+      /// \sa Reference
+      /// \todo Wrong documentation
+      template<class T> 
+      class UEdgeMap : public ReadWriteMap<UEdge,T>
+      {
+      public:
+
+        ///\e
+        UEdgeMap(const BpUGraph&) { }
+        ///\e
+        UEdgeMap(const BpUGraph&, T) { }
+        ///Copy constructor
+        UEdgeMap(const UEdgeMap& em) : ReadWriteMap<UEdge,T>(em) {}
+        ///Assignment operator
+        UEdgeMap &operator=(const UEdgeMap&) { return *this; }
+        ///Assignment operator
+        template <typename CMap>
+        UEdgeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<UEdge, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      /// \brief Direct the given undirected edge.
+      ///
+      /// Direct the given undirected edge. The returned edge source
+      /// will be the given node.
+      Edge direct(const UEdge&, const Node&) const {
+	return INVALID;
+      }
+
+      /// \brief Direct the given undirected edge.
+      ///
+      /// Direct the given undirected edge. The returned edge
+      /// represents the given undirected edge and the direction comes
+      /// from the given bool.  The source of the undirected edge and
+      /// the directed edge is the same when the given bool is true.
+      Edge direct(const UEdge&, bool) const {
+	return INVALID;
+      }
+
+      /// \brief Returns true when the given node is an ANode.
+      ///
+      /// Returns true when the given node is an ANode.
+      bool aNode(Node) const { return true;}
+
+      /// \brief Returns true when the given node is an BNode.
+      ///
+      /// Returns true when the given node is an BNode.
+      bool bNode(Node) const { return true;}
+
+      /// \brief Returns the edge's end node which is in the ANode set.
+      ///
+      /// Returns the edge's end node which is in the ANode set.
+      Node aNode(UEdge) const { return INVALID;}
+
+      /// \brief Returns the edge's end node which is in the BNode set.
+      ///
+      /// Returns the edge's end node which is in the BNode set.
+      Node bNode(UEdge) const { return INVALID;}
+
+      /// \brief Returns true if the edge has default orientation.
+      ///
+      /// Returns whether the given directed edge is same orientation as
+      /// the corresponding undirected edge's default orientation.
+      bool direction(Edge) const { return true; }
+
+      /// \brief Returns the opposite directed edge.
+      ///
+      /// Returns the opposite directed edge.
+      Edge oppositeEdge(Edge) const { return INVALID; }
+
+      /// \brief Opposite node on an edge
+      ///
+      /// \return the opposite of the given Node on the given UEdge
+      Node oppositeNode(Node, UEdge) const { return INVALID; }
+
+      /// \brief First node of the undirected edge.
+      ///
+      /// \return the first node of the given UEdge.
+      ///
+      /// Naturally undirected edges don't have direction and thus
+      /// don't have source and target node. But we use these two methods
+      /// to query the two endnodes of the edge. The direction of the edge
+      /// which arises this way is called the inherent direction of the
+      /// undirected edge, and is used to define the "default" direction
+      /// of the directed versions of the edges.
+      /// \sa direction
+      Node source(UEdge) const { return INVALID; }
+
+      /// \brief Second node of the undirected edge.
+      Node target(UEdge) const { return INVALID; }
+
+      /// \brief Source node of the directed edge.
+      Node source(Edge) const { return INVALID; }
+
+      /// \brief Target node of the directed edge.
+      Node target(Edge) const { return INVALID; }
+
+      /// \brief Base node of the iterator
+      ///
+      /// Returns the base node (the source in this case) of the iterator
+      Node baseNode(OutEdgeIt e) const {
+	return source(e);
+      }
+
+      /// \brief Running node of the iterator
+      ///
+      /// Returns the running node (the target in this case) of the
+      /// iterator
+      Node runningNode(OutEdgeIt e) const {
+	return target(e);
+      }
+
+      /// \brief Base node of the iterator
+      ///
+      /// Returns the base node (the target in this case) of the iterator
+      Node baseNode(InEdgeIt e) const {
+	return target(e);
+      }
+      /// \brief Running node of the iterator
+      ///
+      /// Returns the running node (the source in this case) of the
+      /// iterator
+      Node runningNode(InEdgeIt e) const {
+	return source(e);
+      }
+
+      /// \brief Base node of the iterator
+      ///
+      /// Returns the base node of the iterator
+      Node baseNode(IncEdgeIt) const {
+	return INVALID;
+      }
+      
+      /// \brief Running node of the iterator
+      ///
+      /// Returns the running node of the iterator
+      Node runningNode(IncEdgeIt) const {
+	return INVALID;
+      }
+
+      void first(Node&) const {}
+      void next(Node&) const {}
+
+      void first(Edge&) const {}
+      void next(Edge&) const {}
+
+      void first(UEdge&) const {}
+      void next(UEdge&) const {}
+
+      void firstANode(Node&) const {}
+      void nextANode(Node&) const {}
+
+      void firstBNode(Node&) const {}
+      void nextBNode(Node&) const {}
+
+      void firstIn(Edge&, const Node&) const {}
+      void nextIn(Edge&) const {}
+
+      void firstOut(Edge&, const Node&) const {}
+      void nextOut(Edge&) const {}
+
+      void firstInc(UEdge &, bool &, const Node &) const {}
+      void nextInc(UEdge &, bool &) const {}
+
+      void firstFromANode(UEdge&, const Node&) const {}
+      void nextFromANode(UEdge&) const {}
+
+      void firstFromBNode(UEdge&, const Node&) const {}
+      void nextFromBNode(UEdge&) const {}
+
+      template <typename Graph>
+      struct Constraints {
+	void constraints() {
+	  checkConcept<IterableBpUGraphComponent<>, Graph>();
+	  checkConcept<MappableBpUGraphComponent<>, Graph>();
+	}
+      };
+
+    };
+
+  }
+
+}
+
+#endif
Index: lemon/concepts/graph.h
===================================================================
--- lemon/concepts/graph.h	(revision 2553)
+++ lemon/concepts/graph.h	(revision 2553)
@@ -0,0 +1,453 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_CONCEPT_GRAPH_H
+#define LEMON_CONCEPT_GRAPH_H
+
+///\ingroup graph_concepts
+///\file
+///\brief The concept of Directed Graphs.
+
+#include <lemon/bits/invalid.h>
+#include <lemon/bits/utility.h>
+#include <lemon/concepts/maps.h>
+#include <lemon/concept_check.h>
+#include <lemon/concepts/graph_components.h>
+
+namespace lemon {
+  namespace concepts {
+
+    /// \ingroup graph_concepts
+    ///
+    /// \brief Class describing the concept of Directed Graphs.
+    ///
+    /// This class describes the \ref concept "concept" of the
+    /// immutable directed graphs.
+    ///
+    /// Note that actual graph implementation like @ref ListGraph or
+    /// @ref SmartGraph may have several additional functionality.
+    ///
+    /// \sa concept
+    class Graph {
+    private:
+      ///Graphs are \e not copy constructible. Use GraphCopy() instead.
+      
+      ///Graphs are \e not copy constructible. Use GraphCopy() instead.
+      ///
+      Graph(const Graph &) {};
+      ///\brief Assignment of \ref Graph "Graph"s to another ones are
+      ///\e not allowed. Use GraphCopy() instead.
+      
+      ///Assignment of \ref Graph "Graph"s to another ones are
+      ///\e not allowed.  Use GraphCopy() instead.
+
+      void operator=(const Graph &) {}
+    public:
+      ///\e
+
+      /// Defalult constructor.
+
+      /// Defalult constructor.
+      ///
+      Graph() { }
+      /// Class for identifying a node of the graph
+
+      /// This class identifies a node of the graph. It also serves
+      /// as a base class of the node iterators,
+      /// thus they will convert to this type.
+      class Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        Node() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        Node(const Node&) { }
+
+        /// Invalid constructor \& conversion.
+
+        /// This constructor initializes the iterator to be invalid.
+        /// \sa Invalid for more details.
+        Node(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(Node) const { return true; }
+
+        /// Inequality operator
+        
+        /// \sa operator==(Node n)
+        ///
+        bool operator!=(Node) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(Node) const { return false; }
+
+      };
+    
+      /// This iterator goes through each node.
+
+      /// This iterator goes through each node.
+      /// Its usage is quite simple, for example you can count the number
+      /// of nodes in graph \c g of type \c Graph like this:
+      ///\code
+      /// int count=0;
+      /// for (Graph::NodeIt n(g); n!=INVALID; ++n) ++count;
+      ///\endcode
+      class NodeIt : public Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        NodeIt() { }
+        /// Copy constructor.
+        
+        /// Copy constructor.
+        ///
+        NodeIt(const NodeIt& n) : Node(n) { }
+        /// Invalid constructor \& conversion.
+
+        /// Initialize the iterator to be invalid.
+        /// \sa Invalid for more details.
+        NodeIt(Invalid) { }
+        /// Sets the iterator to the first node.
+
+        /// Sets the iterator to the first node of \c g.
+        ///
+        NodeIt(const Graph&) { }
+        /// Node -> NodeIt conversion.
+
+        /// Sets the iterator to the node of \c the graph pointed by 
+	/// the trivial iterator.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        NodeIt(const Graph&, const Node&) { }
+        /// Next node.
+
+        /// Assign the iterator to the next node.
+        ///
+        NodeIt& operator++() { return *this; }
+      };
+    
+    
+      /// Class for identifying an edge of the graph
+
+      /// This class identifies an edge of the graph. It also serves
+      /// as a base class of the edge iterators,
+      /// thus they will convert to this type.
+      class Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        Edge() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        Edge(const Edge&) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        Edge(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(Edge) const { return true; }
+        /// Inequality operator
+
+        /// \sa operator==(Edge n)
+        ///
+        bool operator!=(Edge) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(Edge) const { return false; }
+      };
+    
+      /// This iterator goes trough the outgoing edges of a node.
+
+      /// This iterator goes trough the \e outgoing edges of a certain node
+      /// of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of outgoing edges of a node \c n
+      /// in graph \c g of type \c Graph as follows.
+      ///\code
+      /// int count=0;
+      /// for (Graph::OutEdgeIt e(g, n); e!=INVALID; ++e) ++count;
+      ///\endcode
+    
+      class OutEdgeIt : public Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        OutEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        OutEdgeIt(const OutEdgeIt& e) : Edge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        OutEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to the first outgoing edge.
+    
+        /// This constructor sets the iterator to the first outgoing edge of
+        /// the node.
+        OutEdgeIt(const Graph&, const Node&) { }
+        /// Edge -> OutEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator.
+	/// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        OutEdgeIt(const Graph&, const Edge&) { }
+        ///Next outgoing edge
+        
+        /// Assign the iterator to the next 
+        /// outgoing edge of the corresponding node.
+        OutEdgeIt& operator++() { return *this; }
+      };
+
+      /// This iterator goes trough the incoming edges of a node.
+
+      /// This iterator goes trough the \e incoming edges of a certain node
+      /// of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of outgoing edges of a node \c n
+      /// in graph \c g of type \c Graph as follows.
+      ///\code
+      /// int count=0;
+      /// for(Graph::InEdgeIt e(g, n); e!=INVALID; ++e) ++count;
+      ///\endcode
+
+      class InEdgeIt : public Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        InEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        InEdgeIt(const InEdgeIt& e) : Edge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        InEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to first incoming edge.
+    
+        /// This constructor set the iterator to the first incoming edge of
+        /// the node.
+        InEdgeIt(const Graph&, const Node&) { }
+        /// Edge -> InEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator \c e.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        InEdgeIt(const Graph&, const Edge&) { }
+        /// Next incoming edge
+
+        /// Assign the iterator to the next inedge of the corresponding node.
+        ///
+        InEdgeIt& operator++() { return *this; }
+      };
+      /// This iterator goes through each edge.
+
+      /// This iterator goes through each edge of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of edges in a graph \c g of type \c Graph as follows:
+      ///\code
+      /// int count=0;
+      /// for(Graph::EdgeIt e(g); e!=INVALID; ++e) ++count;
+      ///\endcode
+      class EdgeIt : public Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        EdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        EdgeIt(const EdgeIt& e) : Edge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        EdgeIt(Invalid) { }
+        /// This constructor sets the iterator to the first edge.
+    
+        /// This constructor sets the iterator to the first edge of \c g.
+        ///@param g the graph
+        EdgeIt(const Graph& g) { ignore_unused_variable_warning(g); }
+        /// Edge -> EdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator \c e.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        EdgeIt(const Graph&, const Edge&) { } 
+        ///Next edge
+        
+        /// Assign the iterator to the next edge.
+        EdgeIt& operator++() { return *this; }
+      };
+      ///Gives back the target node of an edge.
+
+      ///Gives back the target node of an edge.
+      ///
+      Node target(Edge) const { return INVALID; }
+      ///Gives back the source node of an edge.
+
+      ///Gives back the source node of an edge.
+      ///
+      Node source(Edge) const { return INVALID; }
+
+      void first(Node&) const {}
+      void next(Node&) const {}
+
+      void first(Edge&) const {}
+      void next(Edge&) const {}
+
+
+      void firstIn(Edge&, const Node&) const {}
+      void nextIn(Edge&) const {}
+
+      void firstOut(Edge&, const Node&) const {}
+      void nextOut(Edge&) const {}
+
+      /// \brief The base node of the iterator.
+      ///
+      /// Gives back the base node of the iterator.
+      /// It is always the target of the pointed edge.
+      Node baseNode(const InEdgeIt&) const { return INVALID; }
+
+      /// \brief The running node of the iterator.
+      ///
+      /// Gives back the running node of the iterator.
+      /// It is always the source of the pointed edge.
+      Node runningNode(const InEdgeIt&) const { return INVALID; }
+
+      /// \brief The base node of the iterator.
+      ///
+      /// Gives back the base node of the iterator.
+      /// It is always the source of the pointed edge.
+      Node baseNode(const OutEdgeIt&) const { return INVALID; }
+
+      /// \brief The running node of the iterator.
+      ///
+      /// Gives back the running node of the iterator.
+      /// It is always the target of the pointed edge.
+      Node runningNode(const OutEdgeIt&) const { return INVALID; }
+
+      /// \brief The opposite node on the given edge.
+      ///
+      /// Gives back the opposite node on the given edge.
+      Node oppositeNode(const Node&, const Edge&) const { return INVALID; }
+
+      /// \brief Read write map of the nodes to type \c T.
+      /// 
+      /// ReadWrite map of the nodes to type \c T.
+      /// \sa Reference
+      template<class T> 
+      class NodeMap : public ReadWriteMap< Node, T > {
+      public:
+
+        ///\e
+        NodeMap(const Graph&) { }
+        ///\e
+        NodeMap(const Graph&, T) { }
+
+        ///Copy constructor
+        NodeMap(const NodeMap& nm) : ReadWriteMap< Node, T >(nm) { }
+        ///Assignment operator
+        template <typename CMap>
+        NodeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Node, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      /// \brief Read write map of the edges to type \c T.
+      ///
+      /// Reference map of the edges to type \c T.
+      /// \sa Reference
+      template<class T> 
+      class EdgeMap : public ReadWriteMap<Edge,T> {
+      public:
+
+        ///\e
+        EdgeMap(const Graph&) { }
+        ///\e
+        EdgeMap(const Graph&, T) { }
+        ///Copy constructor
+        EdgeMap(const EdgeMap& em) : ReadWriteMap<Edge,T>(em) { }
+        ///Assignment operator
+        template <typename CMap>
+        EdgeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Edge, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      template <typename RGraph>
+      struct Constraints {
+        void constraints() {
+          checkConcept<IterableGraphComponent<>, Graph>();
+          checkConcept<MappableGraphComponent<>, Graph>();
+        }
+      };
+
+    };
+    
+  } //namespace concepts  
+} //namespace lemon
+
+
+
+#endif // LEMON_CONCEPT_GRAPH_H
Index: lemon/concepts/graph_components.h
===================================================================
--- lemon/concepts/graph_components.h	(revision 2553)
+++ lemon/concepts/graph_components.h	(revision 2553)
@@ -0,0 +1,2093 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup graph_concepts
+///\file
+///\brief The concept of graph components.
+
+
+#ifndef LEMON_CONCEPT_GRAPH_COMPONENTS_H
+#define LEMON_CONCEPT_GRAPH_COMPONENTS_H
+
+#include <lemon/bits/invalid.h>
+#include <lemon/concepts/maps.h>
+
+#include <lemon/bits/alteration_notifier.h>
+
+namespace lemon {
+  namespace concepts {
+
+    /// \brief Skeleton class for graph Node and Edge types
+    ///
+    /// This class describes the interface of Node and Edge (and UEdge
+    /// in undirected graphs) subtypes of graph types.
+    ///
+    /// \note This class is a template class so that we can use it to
+    /// create graph skeleton classes. The reason for this is than Node
+    /// and Edge types should \em not derive from the same base class.
+    /// For Node you should instantiate it with character 'n' and for Edge
+    /// with 'e'.
+
+#ifndef DOXYGEN
+    template <char _selector = '0'>
+#endif
+    class GraphItem {
+    public:
+      /// \brief Default constructor.
+      ///      
+      /// \warning The default constructor is not required to set
+      /// the item to some well-defined value. So you should consider it
+      /// as uninitialized.
+      GraphItem() {}
+      /// \brief Copy constructor.
+      ///
+      /// Copy constructor.
+      ///
+      GraphItem(const GraphItem &) {}
+      /// \brief Invalid constructor \& conversion.
+      ///
+      /// This constructor initializes the item to be invalid.
+      /// \sa Invalid for more details.
+      GraphItem(Invalid) {}
+      /// \brief Assign operator for nodes.
+      ///
+      /// The nodes are assignable. 
+      ///
+      GraphItem& operator=(GraphItem const&) { return *this; }
+      /// \brief Equality operator.
+      ///
+      /// Two iterators are equal if and only if they represents the
+      /// same node in the graph or both are invalid.
+      bool operator==(GraphItem) const { return false; }
+      /// \brief Inequality operator.
+      ///
+      /// \sa operator==(const Node& n)
+      ///
+      bool operator!=(GraphItem) const { return false; }
+
+      /// \brief Artificial ordering operator.
+      ///
+      /// To allow the use of graph descriptors as key type in std::map or
+      /// similar associative container we require this.
+      ///
+      /// \note This operator only have to define some strict ordering of
+      /// the items; this order has nothing to do with the iteration
+      /// ordering of the items.
+      bool operator<(GraphItem) const { return false; }
+
+      template<typename _GraphItem>
+      struct Constraints {
+	void constraints() {
+	  _GraphItem i1;
+	  _GraphItem i2 = i1;
+	  _GraphItem i3 = INVALID;
+	  
+	  i1 = i2 = i3;
+
+	  bool b;
+	  //	  b = (ia == ib) && (ia != ib) && (ia < ib);
+	  b = (ia == ib) && (ia != ib);
+	  b = (ia == INVALID) && (ib != INVALID);
+          b = (ia < ib);
+	}
+
+	const _GraphItem &ia;
+	const _GraphItem &ib;
+      };
+    };
+
+    /// \brief An empty base graph class.
+    ///  
+    /// This class provides the minimal set of features needed for a graph
+    /// structure. All graph concepts have to be conform to this base
+    /// graph. It just provides types for nodes and edges and functions to
+    /// get the source and the target of the edges.
+    class BaseGraphComponent {
+    public:
+
+      typedef BaseGraphComponent Graph;
+      
+      /// \brief Node class of the graph.
+      ///
+      /// This class represents the Nodes of the graph. 
+      ///
+      typedef GraphItem<'n'> Node;
+
+      /// \brief Edge class of the graph.
+      ///
+      /// This class represents the Edges of the graph. 
+      ///
+      typedef GraphItem<'e'> Edge;
+
+      /// \brief Gives back the target node of an edge.
+      ///
+      /// Gives back the target node of an edge.
+      ///
+      Node target(const Edge&) const { return INVALID;}
+
+      /// \brief Gives back the source node of an edge.
+      ///
+      /// Gives back the source node of an edge.
+      ///
+      Node source(const Edge&) const { return INVALID;}
+
+      /// \brief Gives back the opposite node on the given edge.
+      ///
+      /// Gives back the opposite node on the given edge.
+      Node oppositeNode(const Node&, const Edge&) const {
+        return INVALID;
+      }
+
+      template <typename _Graph>
+      struct Constraints {
+	typedef typename _Graph::Node Node;
+	typedef typename _Graph::Edge Edge;
+      
+	void constraints() {
+	  checkConcept<GraphItem<'n'>, Node>();
+	  checkConcept<GraphItem<'e'>, Edge>();
+	  {
+	    Node n;
+	    Edge e(INVALID);
+	    n = graph.source(e);
+	    n = graph.target(e);
+            n = graph.oppositeNode(n, e);
+	  }      
+	}
+      
+	const _Graph& graph;
+      };
+    };
+
+    /// \brief An empty base undirected graph class.
+    ///  
+    /// This class provides the minimal set of features needed for an
+    /// undirected graph structure. All undirected graph concepts have
+    /// to be conform to this base graph. It just provides types for
+    /// nodes, edges and undirected edges and functions to get the
+    /// source and the target of the edges and undirected edges,
+    /// conversion from edges to undirected edges and function to get
+    /// both direction of the undirected edges.
+    class BaseUGraphComponent : public BaseGraphComponent {
+    public:
+      typedef BaseGraphComponent::Node Node;
+      typedef BaseGraphComponent::Edge Edge;
+      /// \brief Undirected edge class of the graph.
+      ///
+      /// This class represents the undirected edges of the graph.
+      /// The undirected graphs can be used as a directed graph which
+      /// for each edge contains the opposite edge too so the graph is
+      /// bidirected. The undirected edge represents two opposite
+      /// directed edges.
+      class UEdge : public GraphItem<'u'> {
+      public:
+        typedef GraphItem<'u'> Parent;
+        /// \brief Default constructor.
+        ///      
+        /// \warning The default constructor is not required to set
+        /// the item to some well-defined value. So you should consider it
+        /// as uninitialized.
+        UEdge() {}
+        /// \brief Copy constructor.
+        ///
+        /// Copy constructor.
+        ///
+        UEdge(const UEdge &) : Parent() {}
+        /// \brief Invalid constructor \& conversion.
+        ///
+        /// This constructor initializes the item to be invalid.
+        /// \sa Invalid for more details.
+        UEdge(Invalid) {}
+        /// \brief Converter from edge to undirected edge.
+        ///
+        /// Besides the core graph item functionality each edge should
+        /// be convertible to the represented undirected edge. 
+        UEdge(const Edge&) {}
+        /// \brief Assign edge to undirected edge.
+        ///
+        /// Besides the core graph item functionality each edge should
+        /// be convertible to the represented undirected edge. 
+        UEdge& operator=(const Edge&) { return *this; }
+      };
+
+      /// \brief Returns the direction of the edge.
+      ///
+      /// Returns the direction of the edge. Each edge represents an
+      /// undirected edge with a direction. It gives back the
+      /// direction.
+      bool direction(const Edge&) const { return true; }
+
+      /// \brief Returns the directed edge.
+      ///
+      /// Returns the directed edge from its direction and the
+      /// represented undirected edge.
+      Edge direct(const UEdge&, bool) const { return INVALID;} 
+
+      /// \brief Returns the directed edge.
+      ///
+      /// Returns the directed edge from its source and the
+      /// represented undirected edge.
+      Edge direct(const UEdge&, const Node&) const { return INVALID;} 
+
+      /// \brief Returns the opposite edge.
+      ///
+      /// Returns the opposite edge. It is the edge representing the
+      /// same undirected edge and has opposite direction.
+      Edge oppositeEdge(const Edge&) const { return INVALID;}
+
+      /// \brief Gives back the target node of an undirected edge.
+      ///
+      /// Gives back the target node of an undirected edge. The name
+      /// target is a little confusing because the undirected edge
+      /// does not have target but it just means that one of the end 
+      /// node.
+      Node target(const UEdge&) const { return INVALID;}
+
+      /// \brief Gives back the source node of an undirected edge.
+      ///
+      /// Gives back the source node of an undirected edge. The name
+      /// source is a little confusing because the undirected edge
+      /// does not have source but it just means that one of the end 
+      /// node.
+      Node source(const UEdge&) const { return INVALID;}
+      
+      template <typename _Graph>
+      struct Constraints {
+	typedef typename _Graph::Node Node;
+	typedef typename _Graph::Edge Edge;
+	typedef typename _Graph::UEdge UEdge;
+      
+	void constraints() {
+          checkConcept<BaseGraphComponent, _Graph>();
+	  checkConcept<GraphItem<'u'>, UEdge>();
+	  {
+	    Node n;
+	    UEdge ue(INVALID);
+            Edge e;
+	    n = graph.source(ue);
+	    n = graph.target(ue);
+            e = graph.direct(ue, true);
+            e = graph.direct(ue, n);
+            e = graph.oppositeEdge(e);
+            ue = e;
+            bool d = graph.direction(e);
+            ignore_unused_variable_warning(d);
+	  }      
+	}
+      
+	const _Graph& graph;
+      };
+
+    };
+
+    /// \brief An empty base bipartite undirected graph class.
+    ///  
+    /// This class provides the minimal set of features needed for an
+    /// bipartite undirected graph structure. All bipartite undirected
+    /// graph concepts have to be conform to this base graph. It just
+    /// provides types for nodes, A-nodes, B-nodes, edges and
+    /// undirected edges and functions to get the source and the
+    /// target of the edges and undirected edges, conversion from
+    /// edges to undirected edges and function to get both direction
+    /// of the undirected edges.
+    class BaseBpUGraphComponent : public BaseUGraphComponent {
+    public:
+      typedef BaseUGraphComponent::Node Node;
+      typedef BaseUGraphComponent::Edge Edge;
+      typedef BaseUGraphComponent::UEdge UEdge;
+
+      /// \brief Helper class for A-nodes.
+      ///
+      /// This class is just a helper class for A-nodes, it is not
+      /// suggested to use it directly. It can be converted easily to
+      /// node and vice versa. The usage of this class is limited
+      /// to use just as template parameters for special map types. 
+      class ANode : public Node {
+      public:
+        typedef Node Parent;
+
+        /// \brief Default constructor.
+        ///      
+        /// \warning The default constructor is not required to set
+        /// the item to some well-defined value. So you should consider it
+        /// as uninitialized.
+        ANode() {}
+        /// \brief Copy constructor.
+        ///
+        /// Copy constructor.
+        ///
+        ANode(const ANode &) : Parent() {}
+        /// \brief Invalid constructor \& conversion.
+        ///
+        /// This constructor initializes the item to be invalid.
+        /// \sa Invalid for more details.
+        ANode(Invalid) {}
+        /// \brief Converter from node to A-node.
+        ///
+        /// Besides the core graph item functionality each node should
+        /// be convertible to the represented A-node if it is it possible. 
+        ANode(const Node&) {}
+        /// \brief Assign node to A-node.
+        ///
+        /// Besides the core graph item functionality each node should
+        /// be convertible to the represented A-node if it is it possible. 
+        ANode& operator=(const Node&) { return *this; }
+      };
+
+      /// \brief Helper class for B-nodes.
+      ///
+      /// This class is just a helper class for B-nodes, it is not
+      /// suggested to use it directly. It can be converted easily to
+      /// node and vice versa. The usage of this class is limited
+      /// to use just as template parameters for special map types. 
+      class BNode : public Node {
+      public:
+        typedef Node Parent;
+
+        /// \brief Default constructor.
+        ///      
+        /// \warning The default constructor is not required to set
+        /// the item to some well-defined value. So you should consider it
+        /// as uninitialized.
+        BNode() {}
+        /// \brief Copy constructor.
+        ///
+        /// Copy constructor.
+        ///
+        BNode(const BNode &) : Parent() {}
+        /// \brief Invalid constructor \& conversion.
+        ///
+        /// This constructor initializes the item to be invalid.
+        /// \sa Invalid for more details.
+        BNode(Invalid) {}
+        /// \brief Converter from node to B-node.
+        ///
+        /// Besides the core graph item functionality each node should
+        /// be convertible to the represented B-node if it is it possible. 
+        BNode(const Node&) {}
+        /// \brief Assign node to B-node.
+        ///
+        /// Besides the core graph item functionality each node should
+        /// be convertible to the represented B-node if it is it possible. 
+        BNode& operator=(const Node&) { return *this; }
+      };
+      
+      /// \brief Gives back %true when the node is A-node.
+      ///
+      /// Gives back %true when the node is A-node.
+      bool aNode(const Node&) const { return false; }
+
+      /// \brief Gives back %true when the node is B-node.
+      ///
+      /// Gives back %true when the node is B-node.
+      bool bNode(const Node&) const { return false; }
+
+      /// \brief Gives back the A-node of the undirected edge.
+      ///
+      /// Gives back the A-node of the undirected edge.
+      Node aNode(const UEdge&) const { return INVALID; }
+
+      /// \brief Gives back the B-node of the undirected edge.
+      ///
+      /// Gives back the B-node of the undirected edge.
+      Node bNode(const UEdge&) const { return INVALID; }
+      
+      template <typename _Graph>
+      struct Constraints {
+	typedef typename _Graph::Node Node;
+	typedef typename _Graph::ANode ANode;
+	typedef typename _Graph::BNode BNode;
+	typedef typename _Graph::Edge Edge;
+	typedef typename _Graph::UEdge UEdge;
+      
+	void constraints() {
+          checkConcept<BaseUGraphComponent, _Graph>();
+	  checkConcept<GraphItem<'a'>, ANode>();
+	  checkConcept<GraphItem<'b'>, BNode>();
+	  {
+	    Node n;
+	    UEdge ue(INVALID);
+            bool b;
+	    n = graph.aNode(ue);
+	    n = graph.bNode(ue);
+            b = graph.aNode(n);
+            b = graph.bNode(n);
+            ANode an;
+            an = n; n = an;
+            BNode bn;
+            bn = n; n = bn;            
+            ignore_unused_variable_warning(b);
+	  }      
+	}
+      
+	const _Graph& graph;
+      };
+
+    };
+
+    /// \brief An empty idable base graph class.
+    ///  
+    /// This class provides beside the core graph features
+    /// core id functions for the graph structure.
+    /// The most of the base graphs should be conform to this concept.
+    /// The id's are unique and immutable.
+    template <typename _Base = BaseGraphComponent>
+    class IDableGraphComponent : public _Base {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+      typedef typename Base::Edge Edge;
+
+      /// \brief Gives back an unique integer id for the Node. 
+      ///
+      /// Gives back an unique integer id for the Node. 
+      ///
+      int id(const Node&) const { return -1;}
+
+      /// \brief Gives back the node by the unique id.
+      ///
+      /// Gives back the node by the unique id.
+      /// If the graph does not contain node with the given id
+      /// then the result of the function is undetermined. 
+      Node nodeFromId(int) const { return INVALID;}
+
+      /// \brief Gives back an unique integer id for the Edge. 
+      ///
+      /// Gives back an unique integer id for the Edge. 
+      ///
+      int id(const Edge&) const { return -1;}
+
+      /// \brief Gives back the edge by the unique id.
+      ///
+      /// Gives back the edge by the unique id.
+      /// If the graph does not contain edge with the given id
+      /// then the result of the function is undetermined. 
+      Edge edgeFromId(int) const { return INVALID;}
+
+      /// \brief Gives back an integer greater or equal to the maximum
+      /// Node id.
+      ///
+      /// Gives back an integer greater or equal to the maximum Node
+      /// id.
+      int maxNodeId() const { return -1;}
+
+      /// \brief Gives back an integer greater or equal to the maximum
+      /// Edge id.
+      ///
+      /// Gives back an integer greater or equal to the maximum Edge
+      /// id.
+      int maxEdgeId() const { return -1;}
+
+      template <typename _Graph>
+      struct Constraints {
+
+	void constraints() {
+	  checkConcept<Base, _Graph >();
+	  typename _Graph::Node node;
+	  int nid = graph.id(node);
+	  nid = graph.id(node);
+	  node = graph.nodeFromId(nid);
+	  typename _Graph::Edge edge;
+	  int eid = graph.id(edge);
+	  eid = graph.id(edge);
+	  edge = graph.edgeFromId(eid);
+
+	  nid = graph.maxNodeId();
+	  ignore_unused_variable_warning(nid);
+	  eid = graph.maxEdgeId();
+	  ignore_unused_variable_warning(eid);
+	}
+
+	const _Graph& graph;
+      };
+    };
+
+    /// \brief An empty idable base undirected graph class.
+    ///  
+    /// This class provides beside the core undirected graph features
+    /// core id functions for the undirected graph structure.  The
+    /// most of the base undirected graphs should be conform to this
+    /// concept.  The id's are unique and immutable.
+    template <typename _Base = BaseUGraphComponent>
+    class IDableUGraphComponent : public IDableGraphComponent<_Base> {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::UEdge UEdge;
+
+      using IDableGraphComponent<_Base>::id;
+
+      /// \brief Gives back an unique integer id for the UEdge. 
+      ///
+      /// Gives back an unique integer id for the UEdge. 
+      ///
+      int id(const UEdge&) const { return -1;}
+
+      /// \brief Gives back the undirected edge by the unique id.
+      ///
+      /// Gives back the undirected edge by the unique id.  If the
+      /// graph does not contain edge with the given id then the
+      /// result of the function is undetermined.
+      UEdge uEdgeFromId(int) const { return INVALID;}
+
+      /// \brief Gives back an integer greater or equal to the maximum
+      /// UEdge id.
+      ///
+      /// Gives back an integer greater or equal to the maximum UEdge
+      /// id.
+      int maxUEdgeId() const { return -1;}
+
+      template <typename _Graph>
+      struct Constraints {
+
+	void constraints() {
+	  checkConcept<Base, _Graph >();
+	  checkConcept<IDableGraphComponent<Base>, _Graph >();
+	  typename _Graph::UEdge uedge;
+	  int ueid = graph.id(uedge);
+	  ueid = graph.id(uedge);
+	  uedge = graph.uEdgeFromId(ueid);
+	  ueid = graph.maxUEdgeId();
+	  ignore_unused_variable_warning(ueid);
+	}
+
+	const _Graph& graph;
+      };
+    };
+
+    /// \brief An empty idable base bipartite undirected graph class.
+    ///  
+    /// This class provides beside the core bipartite undirected graph
+    /// features core id functions for the bipartite undirected graph
+    /// structure.  The most of the base undirected graphs should be
+    /// conform to this concept.
+    template <typename _Base = BaseBpUGraphComponent>
+    class IDableBpUGraphComponent : public IDableUGraphComponent<_Base> {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+
+      using IDableUGraphComponent<_Base>::id;
+
+      /// \brief Gives back an unique integer id for the ANode. 
+      ///
+      /// Gives back an unique integer id for the ANode. 
+      ///
+      int aNodeId(const Node&) const { return -1;}
+
+      /// \brief Gives back the undirected edge by the unique id.
+      ///
+      /// Gives back the undirected edge by the unique id.  If the
+      /// graph does not contain edge with the given id then the
+      /// result of the function is undetermined.
+      Node nodeFromANodeId(int) const { return INVALID;}
+
+      /// \brief Gives back an integer greater or equal to the maximum
+      /// ANode id.
+      ///
+      /// Gives back an integer greater or equal to the maximum ANode
+      /// id.
+      int maxANodeId() const { return -1;}
+
+      /// \brief Gives back an unique integer id for the BNode. 
+      ///
+      /// Gives back an unique integer id for the BNode. 
+      ///
+      int bNodeId(const Node&) const { return -1;}
+
+      /// \brief Gives back the undirected edge by the unique id.
+      ///
+      /// Gives back the undirected edge by the unique id.  If the
+      /// graph does not contain edge with the given id then the
+      /// result of the function is undetermined.
+      Node nodeFromBNodeId(int) const { return INVALID;}
+
+      /// \brief Gives back an integer greater or equal to the maximum
+      /// BNode id.
+      ///
+      /// Gives back an integer greater or equal to the maximum BNode
+      /// id.
+      int maxBNodeId() const { return -1;}
+
+      template <typename _Graph>
+      struct Constraints {
+
+	void constraints() {
+	  checkConcept<Base, _Graph >();
+	  checkConcept<IDableGraphComponent<Base>, _Graph >();
+	  typename _Graph::Node node(INVALID);
+	  int id;
+          id = graph.aNodeId(node);
+          id = graph.bNodeId(node);
+          node = graph.nodeFromANodeId(id);
+          node = graph.nodeFromBNodeId(id);
+          id = graph.maxANodeId();
+          id = graph.maxBNodeId();
+	}
+
+	const _Graph& graph;
+      };
+    };
+
+    /// \brief Skeleton class for graph NodeIt and EdgeIt
+    ///
+    /// Skeleton class for graph NodeIt and EdgeIt.
+    ///
+    template <typename _Graph, typename _Item>
+    class GraphItemIt : public _Item {
+    public:
+      /// \brief Default constructor.
+      ///
+      /// @warning The default constructor sets the iterator
+      /// to an undefined value.
+      GraphItemIt() {}
+      /// \brief Copy constructor.
+      ///
+      /// Copy constructor.
+      ///
+      GraphItemIt(const GraphItemIt& ) {}
+      /// \brief Sets the iterator to the first item.
+      ///
+      /// Sets the iterator to the first item of \c the graph.
+      ///
+      explicit GraphItemIt(const _Graph&) {}
+      /// \brief Invalid constructor \& conversion.
+      ///
+      /// This constructor initializes the item to be invalid.
+      /// \sa Invalid for more details.
+      GraphItemIt(Invalid) {}
+      /// \brief Assign operator for items.
+      ///
+      /// The items are assignable. 
+      ///
+      GraphItemIt& operator=(const GraphItemIt&) { return *this; }      
+      /// \brief Next item.
+      /// 
+      /// Assign the iterator to the next item.
+      ///
+      GraphItemIt& operator++() { return *this; }
+      /// \brief Equality operator
+      /// 
+      /// Two iterators are equal if and only if they point to the
+      /// same object or both are invalid.
+      bool operator==(const GraphItemIt&) const { return true;}
+      /// \brief Inequality operator
+      ///	
+      /// \sa operator==(Node n)
+      ///
+      bool operator!=(const GraphItemIt&) const { return true;}
+      
+      template<typename _GraphItemIt>
+      struct Constraints {
+	void constraints() {
+	  _GraphItemIt it1(g);	
+	  _GraphItemIt it2;
+
+	  it2 = ++it1;
+	  ++it2 = it1;
+	  ++(++it1);
+
+	  _Item bi = it1;
+	  bi = it2;
+	}
+	_Graph& g;
+      };
+    };
+
+    /// \brief Skeleton class for graph InEdgeIt and OutEdgeIt
+    ///
+    /// \note Because InEdgeIt and OutEdgeIt may not inherit from the same
+    /// base class, the _selector is a additional template parameter. For 
+    /// InEdgeIt you should instantiate it with character 'i' and for 
+    /// OutEdgeIt with 'o'.
+    template <typename _Graph,
+	      typename _Item = typename _Graph::Edge,
+              typename _Base = typename _Graph::Node, 
+	      char _selector = '0'>
+    class GraphIncIt : public _Item {
+    public:
+      /// \brief Default constructor.
+      ///
+      /// @warning The default constructor sets the iterator
+      /// to an undefined value.
+      GraphIncIt() {}
+      /// \brief Copy constructor.
+      ///
+      /// Copy constructor.
+      ///
+      GraphIncIt(GraphIncIt const& gi) : _Item(gi) {}
+      /// \brief Sets the iterator to the first edge incoming into or outgoing 
+      /// from the node.
+      ///
+      /// Sets the iterator to the first edge incoming into or outgoing 
+      /// from the node.
+      ///
+      explicit GraphIncIt(const _Graph&, const _Base&) {}
+      /// \brief Invalid constructor \& conversion.
+      ///
+      /// This constructor initializes the item to be invalid.
+      /// \sa Invalid for more details.
+      GraphIncIt(Invalid) {}
+      /// \brief Assign operator for iterators.
+      ///
+      /// The iterators are assignable. 
+      ///
+      GraphIncIt& operator=(GraphIncIt const&) { return *this; }      
+      /// \brief Next item.
+      ///
+      /// Assign the iterator to the next item.
+      ///
+      GraphIncIt& operator++() { return *this; }
+
+      /// \brief Equality operator
+      ///
+      /// Two iterators are equal if and only if they point to the
+      /// same object or both are invalid.
+      bool operator==(const GraphIncIt&) const { return true;}
+
+      /// \brief Inequality operator
+      ///
+      /// \sa operator==(Node n)
+      ///
+      bool operator!=(const GraphIncIt&) const { return true;}
+
+      template <typename _GraphIncIt>
+      struct Constraints {
+	void constraints() {
+	  checkConcept<GraphItem<_selector>, _GraphIncIt>();
+	  _GraphIncIt it1(graph, node);
+	  _GraphIncIt it2;
+
+	  it2 = ++it1;
+	  ++it2 = it1;
+	  ++(++it1);
+	  _Item e = it1;
+	  e = it2;
+
+	}
+
+	_Item edge;
+	_Base node;
+	_Graph graph;
+	_GraphIncIt it;
+      };
+    };
+
+
+    /// \brief An empty iterable graph class.
+    ///
+    /// This class provides beside the core graph features
+    /// iterator based iterable interface for the graph structure.
+    /// This concept is part of the Graph concept.
+    template <typename _Base = BaseGraphComponent>
+    class IterableGraphComponent : public _Base {
+
+    public:
+    
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+      typedef typename Base::Edge Edge;
+
+      typedef IterableGraphComponent Graph;
+
+      /// \name Base iteration
+      /// 
+      /// This interface provides functions for iteration on graph items
+      ///
+      /// @{  
+
+      /// \brief Gives back the first node in the iterating order.
+      ///      
+      /// Gives back the first node in the iterating order.
+      ///     
+      void first(Node&) const {}
+
+      /// \brief Gives back the next node in the iterating order.
+      ///
+      /// Gives back the next node in the iterating order.
+      ///     
+      void next(Node&) const {}
+
+      /// \brief Gives back the first edge in the iterating order.
+      ///
+      /// Gives back the first edge in the iterating order.
+      ///     
+      void first(Edge&) const {}
+
+      /// \brief Gives back the next edge in the iterating order.
+      ///
+      /// Gives back the next edge in the iterating order.
+      ///     
+      void next(Edge&) const {}
+
+
+      /// \brief Gives back the first of the edges point to the given
+      /// node.
+      ///
+      /// Gives back the first of the edges point to the given node.
+      ///     
+      void firstIn(Edge&, const Node&) const {}
+
+      /// \brief Gives back the next of the edges points to the given
+      /// node.
+      ///
+      /// Gives back the next of the edges points to the given node.
+      ///
+      void nextIn(Edge&) const {}
+
+      /// \brief Gives back the first of the edges start from the
+      /// given node.
+      ///      
+      /// Gives back the first of the edges start from the given node.
+      ///     
+      void firstOut(Edge&, const Node&) const {}
+
+      /// \brief Gives back the next of the edges start from the given
+      /// node.
+      ///
+      /// Gives back the next of the edges start from the given node.
+      ///     
+      void nextOut(Edge&) const {}
+
+      /// @}
+
+      /// \name Class based iteration
+      /// 
+      /// This interface provides functions for iteration on graph items
+      ///
+      /// @{
+
+      /// \brief This iterator goes through each node.
+      ///
+      /// This iterator goes through each node.
+      ///
+      typedef GraphItemIt<Graph, Node> NodeIt;
+
+      /// \brief This iterator goes through each node.
+      ///
+      /// This iterator goes through each node.
+      ///
+      typedef GraphItemIt<Graph, Edge> EdgeIt;
+
+      /// \brief This iterator goes trough the incoming edges of a node.
+      ///
+      /// This iterator goes trough the \e inccoming edges of a certain node
+      /// of a graph.
+      typedef GraphIncIt<Graph, Edge, Node, 'i'> InEdgeIt;
+
+      /// \brief This iterator goes trough the outgoing edges of a node.
+      ///
+      /// This iterator goes trough the \e outgoing edges of a certain node
+      /// of a graph.
+      typedef GraphIncIt<Graph, Edge, Node, 'o'> OutEdgeIt;
+
+      /// \brief The base node of the iterator.
+      ///
+      /// Gives back the base node of the iterator.
+      /// It is always the target of the pointed edge.
+      Node baseNode(const InEdgeIt&) const { return INVALID; }
+
+      /// \brief The running node of the iterator.
+      ///
+      /// Gives back the running node of the iterator.
+      /// It is always the source of the pointed edge.
+      Node runningNode(const InEdgeIt&) const { return INVALID; }
+
+      /// \brief The base node of the iterator.
+      ///
+      /// Gives back the base node of the iterator.
+      /// It is always the source of the pointed edge.
+      Node baseNode(const OutEdgeIt&) const { return INVALID; }
+
+      /// \brief The running node of the iterator.
+      ///
+      /// Gives back the running node of the iterator.
+      /// It is always the target of the pointed edge.
+      Node runningNode(const OutEdgeIt&) const { return INVALID; }
+
+      /// @}
+
+      template <typename _Graph> 
+      struct Constraints {
+	void constraints() {
+	  checkConcept<Base, _Graph>();
+
+          {
+            typename _Graph::Node node(INVALID);      
+            typename _Graph::Edge edge(INVALID);
+            {
+              graph.first(node);
+              graph.next(node);
+            }
+            {
+              graph.first(edge);
+              graph.next(edge);
+            }
+            {
+              graph.firstIn(edge, node);
+              graph.nextIn(edge);
+            }
+            {
+              graph.firstOut(edge, node);
+              graph.nextOut(edge);
+            }
+          }           
+
+          {
+            checkConcept<GraphItemIt<_Graph, typename _Graph::Edge>,
+              typename _Graph::EdgeIt >();
+            checkConcept<GraphItemIt<_Graph, typename _Graph::Node>,
+              typename _Graph::NodeIt >();
+            checkConcept<GraphIncIt<_Graph, typename _Graph::Edge, 
+              typename _Graph::Node, 'i'>, typename _Graph::InEdgeIt>();
+            checkConcept<GraphIncIt<_Graph, typename _Graph::Edge, 
+              typename _Graph::Node, 'o'>, typename _Graph::OutEdgeIt>();
+
+            typename _Graph::Node n;
+            typename _Graph::InEdgeIt ieit(INVALID);
+            typename _Graph::OutEdgeIt oeit(INVALID);
+            n = graph.baseNode(ieit);
+            n = graph.runningNode(ieit);
+            n = graph.baseNode(oeit);
+            n = graph.runningNode(oeit);
+            ignore_unused_variable_warning(n);
+          }
+        }
+	
+	const _Graph& graph;
+	
+      };
+    };
+
+    /// \brief An empty iterable undirected graph class.
+    ///
+    /// This class provides beside the core graph features iterator
+    /// based iterable interface for the undirected graph structure.
+    /// This concept is part of the UGraph concept.
+    template <typename _Base = BaseUGraphComponent>
+    class IterableUGraphComponent : public IterableGraphComponent<_Base> {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+      typedef typename Base::Edge Edge;
+      typedef typename Base::UEdge UEdge;
+
+    
+      typedef IterableUGraphComponent Graph;
+
+      /// \name Base iteration
+      /// 
+      /// This interface provides functions for iteration on graph items
+      /// @{  
+
+      using IterableGraphComponent<_Base>::first;
+      using IterableGraphComponent<_Base>::next;
+
+      /// \brief Gives back the first undirected edge in the iterating
+      /// order.
+      ///
+      /// Gives back the first undirected edge in the iterating order.
+      ///     
+      void first(UEdge&) const {}
+
+      /// \brief Gives back the next undirected edge in the iterating
+      /// order.
+      ///
+      /// Gives back the next undirected edge in the iterating order.
+      ///     
+      void next(UEdge&) const {}
+
+
+      /// \brief Gives back the first of the undirected edges from the
+      /// given node.
+      ///
+      /// Gives back the first of the undirected edges from the given
+      /// node. The bool parameter gives back that direction which
+      /// gives a good direction of the uedge so the source of the
+      /// directed edge is the given node.
+      void firstInc(UEdge&, bool&, const Node&) const {}
+
+      /// \brief Gives back the next of the undirected edges from the
+      /// given node.
+      ///
+      /// Gives back the next of the undirected edges from the given
+      /// node. The bool parameter should be used as the \c firstInc()
+      /// use it.
+      void nextInc(UEdge&, bool&) const {}
+
+      using IterableGraphComponent<_Base>::baseNode;
+      using IterableGraphComponent<_Base>::runningNode;
+
+      /// @}
+
+      /// \name Class based iteration
+      /// 
+      /// This interface provides functions for iteration on graph items
+      ///
+      /// @{
+
+      /// \brief This iterator goes through each node.
+      ///
+      /// This iterator goes through each node.
+      typedef GraphItemIt<Graph, UEdge> UEdgeIt;
+      /// \brief This iterator goes trough the incident edges of a
+      /// node.
+      ///
+      /// This iterator goes trough the incident edges of a certain
+      /// node of a graph.
+      typedef GraphIncIt<Graph, UEdge, Node, 'u'> IncEdgeIt;
+      /// \brief The base node of the iterator.
+      ///
+      /// Gives back the base node of the iterator.
+      Node baseNode(const IncEdgeIt&) const { return INVALID; }
+
+      /// \brief The running node of the iterator.
+      ///
+      /// Gives back the running node of the iterator.
+      Node runningNode(const IncEdgeIt&) const { return INVALID; }
+
+      /// @}
+
+      template <typename _Graph> 
+      struct Constraints {
+	void constraints() {
+	  checkConcept<IterableGraphComponent<Base>, _Graph>();
+
+          {
+            typename _Graph::Node node(INVALID);
+            typename _Graph::UEdge uedge(INVALID);
+            bool dir;
+            {
+              graph.first(uedge);
+              graph.next(uedge);
+            }
+            {
+              graph.firstInc(uedge, dir, node);
+              graph.nextInc(uedge, dir);
+            }
+            
+          }	
+  
+          {
+            checkConcept<GraphItemIt<_Graph, typename _Graph::UEdge>,
+              typename _Graph::UEdgeIt >();
+            checkConcept<GraphIncIt<_Graph, typename _Graph::UEdge, 
+              typename _Graph::Node, 'u'>, typename _Graph::IncEdgeIt>();
+            
+            typename _Graph::Node n;
+            typename _Graph::IncEdgeIt ueit(INVALID);
+            n = graph.baseNode(ueit);
+            n = graph.runningNode(ueit);
+          }
+        }
+	
+	const _Graph& graph;
+	
+      };
+    };
+
+    /// \brief An empty iterable bipartite undirected graph class.
+    ///
+    /// This class provides beside the core graph features iterator
+    /// based iterable interface for the bipartite undirected graph
+    /// structure. This concept is part of the BpUGraph concept.
+    template <typename _Base = BaseUGraphComponent>
+    class IterableBpUGraphComponent : public IterableUGraphComponent<_Base> {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+      typedef typename Base::UEdge UEdge;
+    
+      typedef IterableBpUGraphComponent Graph;
+
+      /// \name Base iteration
+      /// 
+      /// This interface provides functions for iteration on graph items
+      /// @{  
+
+      using IterableUGraphComponent<_Base>::first;
+      using IterableUGraphComponent<_Base>::next;
+
+      /// \brief Gives back the first A-node in the iterating order.
+      ///
+      /// Gives back the first undirected A-node in the iterating
+      /// order.
+      ///     
+      void firstANode(Node&) const {}
+
+      /// \brief Gives back the next A-node in the iterating order.
+      ///
+      /// Gives back the next A-node in the iterating order.
+      ///     
+      void nextANode(Node&) const {}
+
+      /// \brief Gives back the first B-node in the iterating order.
+      ///
+      /// Gives back the first undirected B-node in the iterating
+      /// order.
+      ///     
+      void firstBNode(Node&) const {}
+
+      /// \brief Gives back the next B-node in the iterating order.
+      ///
+      /// Gives back the next B-node in the iterating order.
+      ///     
+      void nextBNode(Node&) const {}
+
+
+      /// \brief Gives back the first of the undirected edges start
+      /// from the given A-node.
+      ///      
+      /// Gives back the first of the undirected edges start from the
+      /// given A-node.
+      void firstFromANode(UEdge&, const Node&) const {}
+
+      /// \brief Gives back the next of the undirected edges start
+      /// from the given A-node.
+      ///      
+      /// Gives back the next of the undirected edges start from the
+      /// given A-node.
+      void nextFromANode(UEdge&) const {}
+
+      /// \brief Gives back the first of the undirected edges start
+      /// from the given B-node.
+      ///      
+      /// Gives back the first of the undirected edges start from the
+      /// given B-node.
+      void firstFromBNode(UEdge&, const Node&) const {}
+
+      /// \brief Gives back the next of the undirected edges start
+      /// from the given B-node.
+      ///      
+      /// Gives back the next of the undirected edges start from the
+      /// given B-node.
+      void nextFromBNode(UEdge&) const {}
+
+
+      /// @}
+
+      /// \name Class based iteration
+      /// 
+      /// This interface provides functions for iteration on graph items
+      ///
+      /// @{
+
+      /// \brief This iterator goes through each A-node.
+      ///
+      /// This iterator goes through each A-node.
+      typedef GraphItemIt<Graph, Node> ANodeIt;
+
+      /// \brief This iterator goes through each B-node.
+      ///
+      /// This iterator goes through each B-node.
+      typedef GraphItemIt<Graph, Node> BNodeIt;
+
+      /// @}
+
+      template <typename _Graph> 
+      struct Constraints {
+	void constraints() {
+	  checkConcept<IterableUGraphComponent<Base>, _Graph>();
+
+          {
+            typename _Graph::Node node(INVALID);
+            typename _Graph::UEdge uedge(INVALID);
+            graph.firstANode(node);
+            graph.nextANode(node);
+            graph.firstBNode(node);
+            graph.nextBNode(node);
+
+            graph.firstFromANode(uedge, node);
+            graph.nextFromANode(uedge);
+            graph.firstFromBNode(uedge, node);
+            graph.nextFromBNode(uedge);
+          }
+          {
+            checkConcept<GraphItemIt<_Graph, typename _Graph::Node>,
+              typename _Graph::ANodeIt >();
+            checkConcept<GraphItemIt<_Graph, typename _Graph::Node>,
+              typename _Graph::BNodeIt >();
+          }
+
+	}
+	
+	const _Graph& graph;
+	
+      };
+    };
+
+    /// \brief An empty alteration notifier graph class.
+    ///  
+    /// This class provides beside the core graph features alteration
+    /// notifier interface for the graph structure.  This implements
+    /// an observer-notifier pattern for each graph item. More
+    /// obsevers can be registered into the notifier and whenever an
+    /// alteration occured in the graph all the observers will
+    /// notified about it.
+    template <typename _Base = BaseGraphComponent>
+    class AlterableGraphComponent : public _Base {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+      typedef typename Base::Edge Edge;
+
+
+      /// The node observer registry.
+      typedef AlterationNotifier<AlterableGraphComponent, Node> 
+      NodeNotifier;
+      /// The edge observer registry.
+      typedef AlterationNotifier<AlterableGraphComponent, Edge> 
+      EdgeNotifier;
+      
+      /// \brief Gives back the node alteration notifier.
+      ///
+      /// Gives back the node alteration notifier.
+      NodeNotifier& notifier(Node) const {
+	return NodeNotifier();
+      }
+      
+      /// \brief Gives back the edge alteration notifier.
+      ///
+      /// Gives back the edge alteration notifier.
+      EdgeNotifier& notifier(Edge) const {
+	return EdgeNotifier();
+      }
+
+      template <typename _Graph> 
+      struct Constraints {
+	void constraints() {
+	  checkConcept<Base, _Graph>();
+          typename _Graph::NodeNotifier& nn 
+            = graph.notifier(typename _Graph::Node());
+
+          typename _Graph::EdgeNotifier& en 
+            = graph.notifier(typename _Graph::Edge());
+          
+          ignore_unused_variable_warning(nn);
+          ignore_unused_variable_warning(en);
+	}
+	
+	const _Graph& graph;
+	
+      };
+      
+    };
+
+    /// \brief An empty alteration notifier undirected graph class.
+    ///  
+    /// This class provides beside the core graph features alteration
+    /// notifier interface for the graph structure.  This implements
+    /// an observer-notifier pattern for each graph item. More
+    /// obsevers can be registered into the notifier and whenever an
+    /// alteration occured in the graph all the observers will
+    /// notified about it.
+    template <typename _Base = BaseUGraphComponent>
+    class AlterableUGraphComponent : public AlterableGraphComponent<_Base> {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::UEdge UEdge;
+
+
+      /// The edge observer registry.
+      typedef AlterationNotifier<AlterableUGraphComponent, UEdge> 
+      UEdgeNotifier;
+      
+      /// \brief Gives back the edge alteration notifier.
+      ///
+      /// Gives back the edge alteration notifier.
+      UEdgeNotifier& notifier(UEdge) const {
+	return UEdgeNotifier();
+      }
+
+      template <typename _Graph> 
+      struct Constraints {
+	void constraints() {
+	  checkConcept<AlterableGraphComponent<Base>, _Graph>();
+          typename _Graph::UEdgeNotifier& uen 
+            = graph.notifier(typename _Graph::UEdge());
+          ignore_unused_variable_warning(uen);
+	}
+	
+	const _Graph& graph;
+	
+      };
+      
+    };
+
+    /// \brief An empty alteration notifier bipartite undirected graph
+    /// class.
+    ///  
+    /// This class provides beside the core graph features alteration
+    /// notifier interface for the graph structure.  This implements
+    /// an observer-notifier pattern for each graph item. More
+    /// obsevers can be registered into the notifier and whenever an
+    /// alteration occured in the graph all the observers will
+    /// notified about it.
+    template <typename _Base = BaseUGraphComponent>
+    class AlterableBpUGraphComponent : public AlterableUGraphComponent<_Base> {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::ANode ANode;
+      typedef typename Base::BNode BNode;
+
+
+      /// The A-node observer registry.
+      typedef AlterationNotifier<AlterableBpUGraphComponent, ANode> 
+      ANodeNotifier;
+
+      /// The B-node observer registry.
+      typedef AlterationNotifier<AlterableBpUGraphComponent, BNode> 
+      BNodeNotifier;
+      
+      /// \brief Gives back the A-node alteration notifier.
+      ///
+      /// Gives back the A-node alteration notifier.
+      ANodeNotifier& notifier(ANode) const {
+	return ANodeNotifier();
+      }
+
+      /// \brief Gives back the B-node alteration notifier.
+      ///
+      /// Gives back the B-node alteration notifier.
+      BNodeNotifier& notifier(BNode) const {
+	return BNodeNotifier();
+      }
+
+      template <typename _Graph> 
+      struct Constraints {
+	void constraints() {
+          checkConcept<AlterableUGraphComponent<Base>, _Graph>();
+          typename _Graph::ANodeNotifier& ann 
+            = graph.notifier(typename _Graph::ANode());
+          typename _Graph::BNodeNotifier& bnn 
+            = graph.notifier(typename _Graph::BNode());
+          ignore_unused_variable_warning(ann);
+          ignore_unused_variable_warning(bnn);
+	}
+	
+	const _Graph& graph;
+	
+      };
+      
+    };
+
+
+    /// \brief Class describing the concept of graph maps
+    /// 
+    /// This class describes the common interface of the graph maps
+    /// (NodeMap, EdgeMap), that is \ref maps-page "maps" which can be used to
+    /// associate data to graph descriptors (nodes or edges).
+    template <typename _Graph, typename _Item, typename _Value>
+    class GraphMap : public ReadWriteMap<_Item, _Value> {
+    public:
+
+      typedef ReadWriteMap<_Item, _Value> Parent;
+
+      /// The graph type of the map.
+      typedef _Graph Graph;
+      /// The key type of the map.
+      typedef _Item Key;
+      /// The value type of the map.
+      typedef _Value Value;
+
+      /// \brief Construct a new map.
+      ///
+      /// Construct a new map for the graph.
+      explicit GraphMap(const Graph&) {}
+      /// \brief Construct a new map with default value.
+      ///
+      /// Construct a new map for the graph and initalise the values.
+      GraphMap(const Graph&, const Value&) {}
+      /// \brief Copy constructor.
+      ///
+      /// Copy Constructor.
+      GraphMap(const GraphMap&) : Parent() {}
+      
+      /// \brief Assign operator.
+      ///
+      /// Assign operator. It does not mofify the underlying graph,
+      /// it just iterates on the current item set and set the  map
+      /// with the value returned by the assigned map. 
+      template <typename CMap>
+      GraphMap& operator=(const CMap&) { 
+        checkConcept<ReadMap<Key, Value>, CMap>();
+        return *this;
+      }
+
+      template<typename _Map>
+      struct Constraints {
+	void constraints() {
+	  checkConcept<ReadWriteMap<Key, Value>, _Map >();
+	  // Construction with a graph parameter
+	  _Map a(g);
+	  // Constructor with a graph and a default value parameter
+	  _Map a2(g,t);
+	  // Copy constructor.
+	  _Map b(c);
+          
+          ReadMap<Key, Value> cmap;
+          b = cmap;
+
+	  ignore_unused_variable_warning(a2);
+	  ignore_unused_variable_warning(b);
+	}
+
+	const _Map &c;
+	const Graph &g;
+	const typename GraphMap::Value &t;
+      };
+
+    };
+
+    /// \brief An empty mappable graph class.
+    ///
+    /// This class provides beside the core graph features
+    /// map interface for the graph structure.
+    /// This concept is part of the Graph concept.
+    template <typename _Base = BaseGraphComponent>
+    class MappableGraphComponent : public _Base  {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+      typedef typename Base::Edge Edge;
+
+      typedef MappableGraphComponent Graph;
+
+      /// \brief ReadWrite map of the nodes.
+      ///
+      /// ReadWrite map of the nodes.
+      ///
+      template <typename _Value>
+      class NodeMap : public GraphMap<Graph, Node, _Value> {
+      public:
+        typedef GraphMap<MappableGraphComponent, Node, _Value> Parent;
+
+	/// \brief Construct a new map.
+	///
+	/// Construct a new map for the graph.
+	explicit NodeMap(const MappableGraphComponent& graph) 
+          : Parent(graph) {}
+
+	/// \brief Construct a new map with default value.
+	///
+	/// Construct a new map for the graph and initalise the values.
+	NodeMap(const MappableGraphComponent& graph, const _Value& value)
+          : Parent(graph, value) {}
+
+	/// \brief Copy constructor.
+	///
+	/// Copy Constructor.
+	NodeMap(const NodeMap& nm) : Parent(nm) {}
+
+	/// \brief Assign operator.
+	///
+	/// Assign operator.
+        template <typename CMap>
+        NodeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Node, _Value>, CMap>();
+          return *this;
+        }
+
+      };
+
+      /// \brief ReadWrite map of the edges.
+      ///
+      /// ReadWrite map of the edges.
+      ///
+      template <typename _Value>
+      class EdgeMap : public GraphMap<Graph, Edge, _Value> {
+      public:
+        typedef GraphMap<MappableGraphComponent, Edge, _Value> Parent;
+
+	/// \brief Construct a new map.
+	///
+	/// Construct a new map for the graph.
+	explicit EdgeMap(const MappableGraphComponent& graph) 
+          : Parent(graph) {}
+
+	/// \brief Construct a new map with default value.
+	///
+	/// Construct a new map for the graph and initalise the values.
+	EdgeMap(const MappableGraphComponent& graph, const _Value& value)
+          : Parent(graph, value) {}
+
+	/// \brief Copy constructor.
+	///
+	/// Copy Constructor.
+	EdgeMap(const EdgeMap& nm) : Parent(nm) {}
+
+	/// \brief Assign operator.
+	///
+	/// Assign operator.
+        template <typename CMap>
+        EdgeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Edge, _Value>, CMap>();
+          return *this;
+        }
+
+      };
+
+
+      template <typename _Graph>
+      struct Constraints {
+
+	struct Dummy {
+	  int value;
+	  Dummy() : value(0) {}
+	  Dummy(int _v) : value(_v) {}
+	};
+
+	void constraints() {
+	  checkConcept<Base, _Graph>();
+	  { // int map test
+	    typedef typename _Graph::template NodeMap<int> IntNodeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::Node, int>, 
+	      IntNodeMap >();
+	  } { // bool map test
+	    typedef typename _Graph::template NodeMap<bool> BoolNodeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::Node, bool>,
+	      BoolNodeMap >();
+	  } { // Dummy map test
+	    typedef typename _Graph::template NodeMap<Dummy> DummyNodeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::Node, Dummy>,
+	      DummyNodeMap >();
+	  } 
+
+	  { // int map test
+	    typedef typename _Graph::template EdgeMap<int> IntEdgeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::Edge, int>,
+	      IntEdgeMap >();
+	  } { // bool map test
+	    typedef typename _Graph::template EdgeMap<bool> BoolEdgeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::Edge, bool>,
+	      BoolEdgeMap >();
+	  } { // Dummy map test
+	    typedef typename _Graph::template EdgeMap<Dummy> DummyEdgeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::Edge, Dummy>, 
+	      DummyEdgeMap >();
+	  } 
+	}
+
+	_Graph& graph;
+      };
+    };
+
+    /// \brief An empty mappable base bipartite undirected graph class.
+    ///
+    /// This class provides beside the core graph features
+    /// map interface for the graph structure.
+    /// This concept is part of the UGraph concept.
+    template <typename _Base = BaseUGraphComponent>
+    class MappableUGraphComponent : public MappableGraphComponent<_Base>  {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::UEdge UEdge;
+
+      typedef MappableUGraphComponent Graph;
+
+      /// \brief ReadWrite map of the uedges.
+      ///
+      /// ReadWrite map of the uedges.
+      ///
+      template <typename _Value>
+      class UEdgeMap : public GraphMap<Graph, UEdge, _Value> {  
+      public:
+        typedef GraphMap<MappableUGraphComponent, UEdge, _Value> Parent;
+
+	/// \brief Construct a new map.
+	///
+	/// Construct a new map for the graph.
+	explicit UEdgeMap(const MappableUGraphComponent& graph) 
+          : Parent(graph) {}
+
+	/// \brief Construct a new map with default value.
+	///
+	/// Construct a new map for the graph and initalise the values.
+	UEdgeMap(const MappableUGraphComponent& graph, const _Value& value)
+          : Parent(graph, value) {}
+
+	/// \brief Copy constructor.
+	///
+	/// Copy Constructor.
+	UEdgeMap(const UEdgeMap& nm) : Parent(nm) {}
+
+	/// \brief Assign operator.
+	///
+	/// Assign operator.
+        template <typename CMap>
+        UEdgeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<UEdge, _Value>, CMap>();
+          return *this;
+        }
+
+      };
+
+
+      template <typename _Graph>
+      struct Constraints {
+
+	struct Dummy {
+	  int value;
+	  Dummy() : value(0) {}
+	  Dummy(int _v) : value(_v) {}
+	};
+
+	void constraints() {
+	  checkConcept<MappableGraphComponent<Base>, _Graph>();
+
+	  { // int map test
+	    typedef typename _Graph::template UEdgeMap<int> IntUEdgeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::UEdge, int>,
+	      IntUEdgeMap >();
+	  } { // bool map test
+	    typedef typename _Graph::template UEdgeMap<bool> BoolUEdgeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::UEdge, bool>,
+	      BoolUEdgeMap >();
+	  } { // Dummy map test
+	    typedef typename _Graph::template UEdgeMap<Dummy> DummyUEdgeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::UEdge, Dummy>, 
+	      DummyUEdgeMap >();
+	  } 
+	}
+
+	_Graph& graph;
+      };
+    };
+
+    /// \brief An empty mappable base bipartite undirected graph
+    /// class.
+    ///
+    /// This class provides beside the core graph features
+    /// map interface for the graph structure.
+    /// This concept is part of the BpUGraph concept.
+    template <typename _Base = BaseBpUGraphComponent>
+    class MappableBpUGraphComponent : public MappableUGraphComponent<_Base>  {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+
+      typedef MappableBpUGraphComponent Graph;
+
+      /// \brief ReadWrite map of the A-nodes.
+      ///
+      /// ReadWrite map of the A-nodes.
+      ///
+      template <typename _Value>
+      class ANodeMap : public GraphMap<Graph, Node, _Value> {  
+      public:
+        typedef GraphMap<MappableBpUGraphComponent, Node, _Value> Parent;
+
+	/// \brief Construct a new map.
+	///
+	/// Construct a new map for the graph.
+	explicit ANodeMap(const MappableBpUGraphComponent& graph) 
+          : Parent(graph) {}
+
+	/// \brief Construct a new map with default value.
+	///
+	/// Construct a new map for the graph and initalise the values.
+	ANodeMap(const MappableBpUGraphComponent& graph, const _Value& value)
+          : Parent(graph, value) {}
+
+	/// \brief Copy constructor.
+	///
+	/// Copy Constructor.
+	ANodeMap(const ANodeMap& nm) : Parent(nm) {}
+
+	/// \brief Assign operator.
+	///
+	/// Assign operator.
+        template <typename CMap>
+        ANodeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Node, _Value>, CMap>();
+          return *this;
+        }
+
+      };
+
+      /// \brief ReadWrite map of the B-nodes.
+      ///
+      /// ReadWrite map of the A-nodes.
+      ///
+      template <typename _Value>
+      class BNodeMap : public GraphMap<Graph, Node, _Value> {  
+      public:
+        typedef GraphMap<MappableBpUGraphComponent, Node, _Value> Parent;
+
+	/// \brief Construct a new map.
+	///
+	/// Construct a new map for the graph.
+	explicit BNodeMap(const MappableBpUGraphComponent& graph) 
+          : Parent(graph) {}
+
+	/// \brief Construct a new map with default value.
+	///
+	/// Construct a new map for the graph and initalise the values.
+	BNodeMap(const MappableBpUGraphComponent& graph, const _Value& value)
+          : Parent(graph, value) {}
+
+	/// \brief Copy constructor.
+	///
+	/// Copy Constructor.
+	BNodeMap(const BNodeMap& nm) : Parent(nm) {}
+
+	/// \brief Assign operator.
+	///
+	/// Assign operator.
+        template <typename CMap>
+        BNodeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Node, _Value>, CMap>();
+          return *this;
+        }
+
+      };
+
+
+      template <typename _Graph>
+      struct Constraints {
+
+	struct Dummy {
+	  int value;
+	  Dummy() : value(0) {}
+	  Dummy(int _v) : value(_v) {}
+	};
+
+	void constraints() {
+	  checkConcept<MappableUGraphComponent<Base>, _Graph>();
+
+	  { // int map test
+	    typedef typename _Graph::template ANodeMap<int> IntANodeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::ANode, int>,
+	      IntANodeMap >();
+	  } { // bool map test
+	    typedef typename _Graph::template ANodeMap<bool> BoolANodeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::ANode, bool>,
+	      BoolANodeMap >();
+	  } { // Dummy map test
+	    typedef typename _Graph::template ANodeMap<Dummy> DummyANodeMap;
+	    checkConcept<GraphMap<_Graph, typename _Graph::ANode, Dummy>, 
+	      DummyANodeMap >();
+	  } 
+	}
+
+	_Graph& graph;
+      };
+    };
+
+
+    /// \brief An empty extendable graph class.
+    ///
+    /// This class provides beside the core graph features graph
+    /// extendable interface for the graph structure.  The main
+    /// difference between the base and this interface is that the
+    /// graph alterations should handled already on this level.
+    template <typename _Base = BaseGraphComponent>
+    class ExtendableGraphComponent : public _Base {
+    public:
+      typedef _Base Base;
+
+      typedef typename _Base::Node Node;
+      typedef typename _Base::Edge Edge;
+
+      /// \brief Adds a new node to the graph.
+      ///
+      /// Adds a new node to the graph.
+      ///
+      Node addNode() {
+	return INVALID;
+      }
+    
+      /// \brief Adds a new edge connects the given two nodes.
+      ///
+      /// Adds a new edge connects the the given two nodes.
+      Edge addEdge(const Node&, const Node&) {
+	return INVALID;
+      }
+
+      template <typename _Graph>
+      struct Constraints {
+	void constraints() {
+          checkConcept<Base, _Graph>();
+	  typename _Graph::Node node_a, node_b;
+	  node_a = graph.addNode();
+	  node_b = graph.addNode();
+	  typename _Graph::Edge edge;
+	  edge = graph.addEdge(node_a, node_b);
+	}
+
+	_Graph& graph;
+      };
+    };
+
+    /// \brief An empty extendable base undirected graph class.
+    ///
+    /// This class provides beside the core undirected graph features
+    /// core undircted graph extend interface for the graph structure.
+    /// The main difference between the base and this interface is
+    /// that the graph alterations should handled already on this
+    /// level.
+    template <typename _Base = BaseUGraphComponent>
+    class ExtendableUGraphComponent : public _Base {
+    public:
+
+      typedef _Base Base;
+      typedef typename _Base::Node Node;
+      typedef typename _Base::UEdge UEdge;
+
+      /// \brief Adds a new node to the graph.
+      ///
+      /// Adds a new node to the graph.
+      ///
+      Node addNode() {
+	return INVALID;
+      }
+    
+      /// \brief Adds a new edge connects the given two nodes.
+      ///
+      /// Adds a new edge connects the the given two nodes.
+      UEdge addEdge(const Node&, const Node&) {
+	return INVALID;
+      }
+
+      template <typename _Graph>
+      struct Constraints {
+	void constraints() {
+	  checkConcept<Base, _Graph>();
+	  typename _Graph::Node node_a, node_b;
+	  node_a = graph.addNode();
+	  node_b = graph.addNode();
+	  typename _Graph::UEdge uedge;
+	  uedge = graph.addUEdge(node_a, node_b);
+	}
+
+	_Graph& graph;
+      };
+    };
+
+    /// \brief An empty extendable base undirected graph class.
+    ///
+    /// This class provides beside the core bipartite undirected graph
+    /// features core undircted graph extend interface for the graph
+    /// structure.  The main difference between the base and this
+    /// interface is that the graph alterations should handled already
+    /// on this level.
+    template <typename _Base = BaseBpUGraphComponent>
+    class ExtendableBpUGraphComponent 
+      : public ExtendableUGraphComponent<_Base> {
+
+      typedef _Base Base;
+
+      template <typename _Graph>
+      struct Constraints {
+	void constraints() {
+          checkConcept<ExtendableUGraphComponent<Base>, _Graph>();
+	}
+      };
+    };
+
+    /// \brief An empty erasable graph class.
+    ///  
+    /// This class provides beside the core graph features core erase
+    /// functions for the graph structure. The main difference between
+    /// the base and this interface is that the graph alterations
+    /// should handled already on this level.
+    template <typename _Base = BaseGraphComponent>
+    class ErasableGraphComponent : public _Base {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+      typedef typename Base::Edge Edge;
+
+      /// \brief Erase a node from the graph.
+      ///
+      /// Erase a node from the graph. This function should 
+      /// erase all edges connecting to the node.
+      void erase(const Node&) {}    
+
+      /// \brief Erase an edge from the graph.
+      ///
+      /// Erase an edge from the graph.
+      ///
+      void erase(const Edge&) {}
+
+      template <typename _Graph>
+      struct Constraints {
+	void constraints() {
+          checkConcept<Base, _Graph>();
+	  typename _Graph::Node node;
+	  graph.erase(node);
+	  typename _Graph::Edge edge;
+	  graph.erase(edge);
+	}
+
+	_Graph& graph;
+      };
+    };
+
+    /// \brief An empty erasable base undirected graph class.
+    ///  
+    /// This class provides beside the core undirected graph features
+    /// core erase functions for the undirceted graph structure. The
+    /// main difference between the base and this interface is that
+    /// the graph alterations should handled already on this level.
+    template <typename _Base = BaseUGraphComponent>
+    class ErasableUGraphComponent : public _Base {
+    public:
+
+      typedef _Base Base;
+      typedef typename Base::Node Node;
+      typedef typename Base::UEdge UEdge;
+
+      /// \brief Erase a node from the graph.
+      ///
+      /// Erase a node from the graph. This function should erase
+      /// edges connecting to the node.
+      void erase(const Node&) {}    
+
+      /// \brief Erase an edge from the graph.
+      ///
+      /// Erase an edge from the graph.
+      ///
+      void erase(const UEdge&) {}
+
+      template <typename _Graph>
+      struct Constraints {
+	void constraints() {
+          checkConcept<Base, _Graph>();
+	  typename _Graph::Node node;
+	  graph.erase(node);
+	  typename _Graph::Edge edge;
+	  graph.erase(edge);
+	}
+
+	_Graph& graph;
+      };
+    };
+
+    /// \brief An empty erasable base bipartite undirected graph class.
+    ///  
+    /// This class provides beside the core bipartite undirected graph
+    /// features core erase functions for the undirceted graph
+    /// structure. The main difference between the base and this
+    /// interface is that the graph alterations should handled already
+    /// on this level.
+    template <typename _Base = BaseBpUGraphComponent>
+    class ErasableBpUGraphComponent : public ErasableUGraphComponent<_Base> {
+    public:
+
+      typedef _Base Base;
+
+      template <typename _Graph>
+      struct Constraints {
+	void constraints() {
+          checkConcept<ErasableUGraphComponent<Base>, _Graph>();
+	}
+      };
+    };
+
+    /// \brief An empty clearable base graph class.
+    ///
+    /// This class provides beside the core graph features core clear
+    /// functions for the graph structure. The main difference between
+    /// the base and this interface is that the graph alterations
+    /// should handled already on this level.
+    template <typename _Base = BaseGraphComponent>
+    class ClearableGraphComponent : public _Base {
+    public:
+
+      typedef _Base Base;
+
+      /// \brief Erase all nodes and edges from the graph.
+      ///
+      /// Erase all nodes and edges from the graph.
+      ///
+      void clear() {}    
+
+      template <typename _Graph>
+      struct Constraints {
+	void constraints() {
+          checkConcept<Base, _Graph>();
+	  graph.clear();
+	}
+
+	_Graph graph;
+      };
+    };
+
+    /// \brief An empty clearable base undirected graph class.
+    ///
+    /// This class provides beside the core undirected graph features
+    /// core clear functions for the undirected graph structure. The
+    /// main difference between the base and this interface is that
+    /// the graph alterations should handled already on this level.
+    template <typename _Base = BaseUGraphComponent>
+    class ClearableUGraphComponent : public ClearableGraphComponent<_Base> {
+    public:
+
+      typedef _Base Base;
+
+      template <typename _Graph>
+      struct Constraints {
+	void constraints() {
+          checkConcept<ClearableUGraphComponent<Base>, _Graph>();
+	}
+
+	_Graph graph;
+      };
+    };
+
+    /// \brief An empty clearable base bipartite undirected graph
+    /// class.
+    ///
+    /// This class provides beside the core bipartite undirected graph
+    /// features core clear functions for the undirected graph
+    /// structure. The main difference between the base and this
+    /// interface is that the graph alterations should handled already
+    /// on this level.
+    template <typename _Base = BaseUGraphComponent>
+    class ClearableBpUGraphComponent : public ClearableUGraphComponent<_Base> {
+    public:
+
+      typedef _Base Base;
+
+      template <typename _Graph>
+      struct Constraints {
+	void constraints() {
+          checkConcept<ClearableBpUGraphComponent<Base>, _Graph>();
+	}
+
+      };
+
+    };
+
+  }
+
+}
+
+#endif
Index: lemon/concepts/heap.h
===================================================================
--- lemon/concepts/heap.h	(revision 2553)
+++ lemon/concepts/heap.h	(revision 2553)
@@ -0,0 +1,226 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup concept
+///\file
+///\brief Classes for representing heaps.
+///
+
+#ifndef LEMON_CONCEPT_HEAP_H
+#define LEMON_CONCEPT_HEAP_H
+
+#include <lemon/bits/invalid.h>
+
+namespace lemon {
+  namespace concepts {
+    /// \addtogroup concept
+    /// @{
+
+
+    /// \brief A concept structure describes the main interface of heaps.
+    ///
+    /// A concept structure describes the main interface of heaps.
+    ///
+    template <typename Prio, typename ItemIntMap>
+    class Heap {
+    public:
+
+      ///\brief Type of the items stored in the heap.
+      typedef typename ItemIntMap::Key  Item;
+  
+
+      /// \brief Type to represent the items states.
+      ///
+      /// Each Item element have a state associated to it. It may be "in heap",
+      /// "pre heap" or "post heap". The later two are indifferent from the
+      /// heap's point of view, but may be useful to the user.
+      ///
+      /// The ItemIntMap _should_ be initialized in such way, that it maps
+      /// PRE_HEAP (-1) to any element to be put in the heap...
+      enum State {
+	IN_HEAP = 0,
+	PRE_HEAP = -1,
+	POST_HEAP = -2
+      };
+      
+      /// \brief The constructor.
+      ///
+      /// The constructor.
+      /// \param _iim should be given to the constructor, since it is used
+      /// internally to handle the cross references. The value of the map
+      /// should be PRE_HEAP (-1) for each element.
+      explicit Heap(ItemIntMap &_iim) {}
+
+      /// \brief The number of items stored in the heap.
+      ///
+      /// Returns the number of items stored in the heap.
+      int size() const { return 0; }
+
+      /// \brief Checks if the heap stores no items.
+      ///
+      /// Returns \c true if and only if the heap stores no items.
+      bool empty() const { return false; }
+
+      /// \brief Makes empty this heap.
+      ///
+      /// Makes this heap empty.
+      void clear();
+
+      /// \brief Insert an item into the heap with the given heap.
+      ///    
+      /// Adds \c i to the heap with priority \c p. 
+      /// \param i The item to insert.
+      /// \param p The priority of the item.
+      void push(const Item &i, const Prio &p) {}
+
+      /// \brief Returns the item with minimum priority.
+      ///
+      /// This method returns the item with minimum priority.  
+      /// \pre The heap must be nonempty.  
+      Item top() const {}
+
+      /// \brief Returns the minimum priority.
+      ///
+      /// It returns the minimum priority.
+      /// \pre The heap must be nonempty.
+      Prio prio() const {}
+
+      /// \brief Deletes the item with minimum priority.
+      ///
+      /// This method deletes the item with minimum priority.
+      /// \pre The heap must be non-empty.  
+      void pop() {}
+
+      /// \brief Deletes \c i from the heap.
+      ///
+      /// This method deletes item \c i from the heap, if \c i was
+      /// already stored in the heap.
+      /// \param i The item to erase. 
+      void erase(const Item &i) {}
+
+      /// \brief Returns the priority of \c i.
+      ///
+      /// This function returns the priority of item \c i.  
+      /// \pre \c i must be in the heap.
+      /// \param i The item.
+      Prio operator[](const Item &i) const {}
+
+      /// \brief \c i gets to the heap with priority \c p independently 
+      /// if \c i was already there.
+      ///
+      /// This method calls \ref push(\c i, \c p) if \c i is not stored
+      /// in the heap and sets the priority of \c i to \c p otherwise.
+      /// It may throw an \e UnderFlowPriorityException. 
+      /// \param i The item.
+      /// \param p The priority.
+      void set(const Item &i, const Prio &p) {}
+      
+      /// \brief Decreases the priority of \c i to \c p.
+      ///
+      /// This method decreases the priority of item \c i to \c p.
+      /// \pre \c i must be stored in the heap with priority at least \c p.
+      /// \param i The item.
+      /// \param p The priority.
+      void decrease(const Item &i, const Prio &p) {}
+
+      /// \brief Increases the priority of \c i to \c p.
+      ///
+      /// This method sets the priority of item \c i to \c p. 
+      /// \pre \c i must be stored in the heap with priority at most \c
+      /// p relative to \c Compare.
+      /// \param i The item.
+      /// \param p The priority.
+      void increase(const Item &i, const Prio &p) {}
+
+      /// \brief Returns if \c item is in, has already been in, or has 
+      /// never been in the heap.
+      ///
+      /// This method returns PRE_HEAP if \c item has never been in the
+      /// heap, IN_HEAP if it is in the heap at the moment, and POST_HEAP
+      /// otherwise. In the latter case it is possible that \c item will
+      /// get back to the heap again.
+      /// \param i The item.
+      State state(const Item &i) const {}
+
+      /// \brief Sets the state of the \c item in the heap.
+      ///
+      /// Sets the state of the \c item in the heap. It can be used to
+      /// manually clear the heap when it is important to achive the
+      /// better time complexity.
+      /// \param i The item.
+      /// \param st The state. It should not be \c IN_HEAP. 
+      void state(const Item& i, State st) {}
+
+
+      template <typename _Heap>
+      struct Constraints {
+      public:
+    
+	void constraints() {
+	  Item item;
+	  Prio prio;
+
+	  item=Item();
+	  prio=Prio();
+
+	  ignore_unused_variable_warning(item);
+	  ignore_unused_variable_warning(prio);
+
+	  typedef typename _Heap::State State;
+	  State state;
+
+	  ignore_unused_variable_warning(state);
+      
+	  _Heap heap1 = _Heap(map);
+
+	  ignore_unused_variable_warning(heap1);
+      
+	  heap.push(item, prio);
+
+	  prio = heap.prio();
+	  item = heap.top();
+
+	  heap.pop();
+
+	  heap.set(item, prio);
+	  heap.decrease(item, prio);
+	  heap.increase(item, prio);
+	  prio = heap[item];
+
+	  heap.erase(item);
+
+	  state = heap.state(item);
+
+	  state = _Heap::PRE_HEAP;
+	  state = _Heap::IN_HEAP;
+	  state = _Heap::POST_HEAP;
+
+	  heap.clear();
+	}
+    
+	_Heap& heap;
+	ItemIntMap& map;
+
+	Constraints() : heap(0), map(0) {}
+      };
+    };
+
+    /// @}
+  } // namespace lemon
+}
+#endif // LEMON_CONCEPT_PATH_H
Index: lemon/concepts/maps.h
===================================================================
--- lemon/concepts/maps.h	(revision 2564)
+++ lemon/concepts/maps.h	(revision 2564)
@@ -0,0 +1,208 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_CONCEPT_MAPS_H
+#define LEMON_CONCEPT_MAPS_H
+
+#include <lemon/bits/utility.h>
+#include <lemon/concept_check.h>
+
+///\ingroup concept
+///\file
+///\brief Map concepts checking classes for testing and documenting.
+
+namespace lemon {
+
+  namespace concepts {
+  
+    /// \addtogroup concept
+    /// @{
+
+    /// Readable map concept
+
+    /// Readable map concept.
+    ///
+    template<typename K, typename T>
+    class ReadMap
+    {
+    public:
+      /// The key type of the map.
+      typedef K Key;    
+      /// The value type of the map. (The type of objects associated with the keys).
+      typedef T Value;
+
+      /// Returns the value associated with a key.
+
+      /// Returns the value associated with a key.
+      /// \bug Value shouldn't need to be default constructible.
+      ///
+      Value operator[](const Key &) const {return Value();}
+
+      template<typename _ReadMap>
+      struct Constraints {
+
+	void constraints() {
+	  Value val = m[key];
+	  val = m[key];
+	  typename _ReadMap::Value own_val = m[own_key]; 
+	  own_val = m[own_key]; 
+
+	  ignore_unused_variable_warning(val);
+	  ignore_unused_variable_warning(own_val);
+	  ignore_unused_variable_warning(key);
+	}
+	Key& key;
+	typename _ReadMap::Key& own_key;
+	_ReadMap& m;
+      };
+      
+    };
+
+
+    /// Writable map concept
+    
+    /// Writable map concept.
+    ///
+    template<typename K, typename T>
+    class WriteMap
+    {
+    public:
+      /// The key type of the map.
+      typedef K Key;    
+      /// The value type of the map. (The type of objects associated with the keys).
+      typedef T Value;
+
+      /// Sets the value associated with a key.
+      void set(const Key &,const Value &) {}
+
+      ///Default constructor
+      WriteMap() {}
+
+      template <typename _WriteMap>
+      struct Constraints {
+	void constraints() {
+	  // No constraints for constructor.
+	  m.set(key, val);
+	  m.set(own_key, own_val);
+	  ignore_unused_variable_warning(key);
+	  ignore_unused_variable_warning(val);
+	  ignore_unused_variable_warning(own_key);
+	  ignore_unused_variable_warning(own_val);
+	}
+
+	Value& val;
+	typename _WriteMap::Value own_val;
+	Key& key;
+	typename _WriteMap::Key& own_key;
+	_WriteMap& m;
+
+      };
+    };
+
+    /// Read/writable map concept
+    
+    /// Read/writable map concept.
+    ///
+    template<typename K, typename T>
+    class ReadWriteMap : public ReadMap<K,T>,
+			 public WriteMap<K,T>
+    {
+    public:
+      /// The key type of the map.
+      typedef K Key;    
+      /// The value type of the map. (The type of objects associated with the keys).
+      typedef T Value;
+
+      /// Returns the value associated with a key.
+      Value operator[](const Key &) const {return Value();}
+      /// Sets the value associated with a key.
+      void set(const Key & ,const Value &) {}
+
+      template<typename _ReadWriteMap>
+      struct Constraints {
+	void constraints() {
+	  checkConcept<ReadMap<K, T>, _ReadWriteMap >();
+	  checkConcept<WriteMap<K, T>, _ReadWriteMap >();
+	}
+      };
+    };
+  
+  
+    ///Dereferable map concept
+    
+    /// Dereferable map concept.
+    ///
+    /// \todo Rethink this concept.
+    template<typename K, typename T, typename R, typename CR>
+    class ReferenceMap : public ReadWriteMap<K,T>
+    {
+    public:
+      /// Tag for reference maps.
+      typedef True ReferenceMapTag;
+      /// The key type of the map.
+      typedef K Key;    
+      /// The value type of the map. (The type of objects associated with the keys).
+      typedef T Value;
+      /// The reference type of the map.
+      typedef R Reference;
+      /// The const reference type of the map.
+      typedef CR ConstReference;
+
+    protected:
+      Value tmp;
+    public:
+
+      ///Returns a reference to the value associated with a key.
+      Reference operator[](const Key &) { return tmp; }
+      ///Returns a const reference to the value associated with a key.
+      ConstReference operator[](const Key &) const { return tmp; }
+      /// Sets the value associated with a key.
+      void set(const Key &k,const Value &t) { operator[](k)=t; }
+
+      template<typename _ReferenceMap>
+      struct Constraints {
+
+	void constraints() {
+	  checkConcept<ReadWriteMap<K, T>, _ReferenceMap >();
+	  m[key] = val;
+	  val  = m[key];
+	  m[key] = ref;
+	  ref = m[key];
+	  m[own_key] = own_val;
+	  own_val  = m[own_key];
+	  m[own_key] = own_ref;
+	  own_ref = m[own_key];	  	  
+	}
+
+	typename _ReferenceMap::Key& own_key;
+	typename _ReferenceMap::Value& own_val;
+	typename _ReferenceMap::Reference own_ref;
+	Key& key;
+	Value& val;
+	Reference ref;
+	_ReferenceMap& m;
+      };
+    };
+
+    // @}
+
+  } //namespace concepts
+
+} //namespace lemon
+
+#endif // LEMON_CONCEPT_MAPS_H
Index: lemon/concepts/matrix_maps.h
===================================================================
--- lemon/concepts/matrix_maps.h	(revision 2553)
+++ lemon/concepts/matrix_maps.h	(revision 2553)
@@ -0,0 +1,207 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_CONCEPT_MATRIX_MAPS_H
+#define LEMON_CONCEPT_MATRIX_MAPS_H
+
+#include <lemon/bits/utility.h>
+#include <lemon/concept_check.h>
+
+///\ingroup concept
+///\file
+///\brief MatrixMap concepts checking classes for testing and documenting.
+
+namespace lemon {
+
+  namespace concepts {
+  
+    /// \addtogroup concept
+    /// @{
+
+    /// Readable matrix map concept
+    template <typename K1, typename K2, typename V>
+    class ReadMatrixMap
+    {
+    public:
+      /// Map's first key type.
+      typedef K1 FirstKey;    
+      /// Map's second key type.
+      typedef K2 SecondKey;    
+      /// \brief Map's value type. 
+      /// (The type of objects associated with the pairs of keys).
+      typedef V Value;
+
+      // \bug Value don't need to be default constructible.
+      /// Returns the value associated with a key.
+      Value operator()(const FirstKey&, const SecondKey&) const {
+	return Value();
+      }
+
+      template <typename _ReadMatrixMap>
+      struct Constraints {
+
+	void constraints() {
+	  Value val = m(first_key, second_key);
+	  val = m(first_key, second_key);
+	  typename _ReadMatrixMap::Value own_val = 
+	    m(own_first_key, own_second_key); 
+	  own_val = m(own_first_key, own_second_key);
+	  ignore_unused_variable_warning(val);
+	  ignore_unused_variable_warning(own_val);
+	}
+
+	FirstKey& first_key;
+	SecondKey& second_key;	
+	typename _ReadMatrixMap::FirstKey& own_first_key;
+	typename _ReadMatrixMap::SecondKey& own_second_key;
+	_ReadMatrixMap& m;
+      };
+      
+    };
+
+
+    /// Writable map concept
+    template <typename K1, typename K2, typename V>
+    class WriteMatrixMap {
+    public:
+      /// Map's first key type.
+      typedef K1 FirstKey;    
+      /// Map's second key type.
+      typedef K2 SecondKey;    
+      /// \brief Map's value type. 
+      /// (The type of objects associated with the pairs of keys).
+      typedef V Value;
+
+      /// Sets the value associated with the pair of keys.
+      void set(const FirstKey&, const SecondKey& ,const Value&) {}
+
+      template <typename _WriteMatrixMap>
+      struct Constraints {
+	void constraints() {
+	  // No constraints for constructor.
+	  m.set(first_key, second_key, val);
+	  m.set(own_first_key, own_second_key, own_val);
+	}
+
+	Value& val;
+	typename _WriteMatrixMap::Value own_val;
+	FirstKey& first_key;
+	SecondKey& second_key;
+	typename _WriteMatrixMap::FirstKey& own_first_key;
+	typename _WriteMatrixMap::SecondKey& own_second_key;
+	_WriteMatrixMap& m;
+
+      };
+    };
+
+    ///Read/Writable map concept
+    template<typename K1, typename K2, typename V>
+    class ReadWriteMatrixMap 
+      : public ReadMatrixMap<K1, K2, V>, public WriteMatrixMap<K1, K2, V> {
+    public:
+      /// Map's first key type.
+      typedef K1 FirstKey;    
+      /// Map's second key type.
+      typedef K2 SecondKey;    
+      /// \brief Map's value type. 
+      /// (The type of objects associated with the pairs of keys).
+      typedef V Value;
+
+      /// Returns the value associated with a pair of keys.
+      Value operator()(const FirstKey&, const SecondKey&) const { 
+	return Value(); 
+      }
+      /// Sets the value associated with the pair of keys.
+      void set(const FirstKey&, const SecondKey& ,const Value&) {}
+
+      template<typename _ReadWriteMatrixMap>
+      struct Constraints {
+	void constraints() {
+	  checkConcept<ReadMatrixMap<K1, K2, V>, _ReadWriteMatrixMap >();
+	  checkConcept<WriteMatrixMap<K1, K2, V>, _ReadWriteMatrixMap >();
+	}
+      };
+    };
+  
+  
+    ///Dereferable matrix map concept
+    template<typename K1, typename K2, typename V, typename R, typename CR>
+    class ReferenceMatrixMap : public ReadWriteMatrixMap<K1, K2, V>
+    {
+    public:
+      /// Tag for reference maps.
+      typedef True ReferenceMapTag;
+      /// Map's first key type.
+      typedef K1 FirstKey;    
+      /// Map's second key type.
+      typedef K1 SecondKey;    
+      /// Map's value type. (The type of objects associated with the keys).
+      typedef V Value;
+      /// Map's reference type.
+      typedef R Reference;
+      /// Map's const reference type.
+      typedef CR ConstReference;
+
+    protected:
+      Value tmp;
+    public:
+
+      ///Returns a reference to the value associated to a pair of keys.
+      Reference operator()(const FirstKey&, const SecondKey&) { 
+	return tmp; 
+      }
+      ///Returns a const reference to the value associated to a pair of keys.
+      ConstReference operator()(const FirstKey&, const SecondKey&) const { 
+	return tmp; 
+      }
+      /// Sets the value associated with the pair of keys.
+      void set(const FirstKey&, const SecondKey& ,const Value&) {}
+
+      // \todo rethink this concept
+      template<typename _ReferenceMatrixMap>
+      struct ReferenceMapConcept {
+
+	void constraints() {
+	  checkConcept<ReadWriteMatrixMap, _ReferenceMatrixMap >();
+	  m(first_key, second_key) = val;
+	  val  = m(first_key, second_key);
+	  m(first_key, second_key) = ref;
+	  ref = m(first_key, second_key);
+	  m(own_first_key, own_second_key) = own_val;
+	  own_val  = m(own_first_key, own_second_key);
+	  m(own_first_key, own_second_key) = own_ref;
+	  own_ref = m(own_first_key, own_second_key); 
+	}
+
+	typename _ReferenceMatrixMap::Key& own_first_key;
+	typename _ReferenceMatrixMap::Key& own_second_key;
+	typename _ReferenceMatrixMap::Value& own_val;
+	typename _ReferenceMatrixMap::Reference& own_ref;
+	FirstKey& first_key;
+	SecondKey& second_key;
+	Value& val;
+	Reference& ref;
+	_ReferenceMatrixMap& m;
+      };
+    };
+
+    // @}
+
+  } //namespace concepts
+} //namespace lemon
+#endif // LEMON_CONCEPT_MATRIX_MAPS_H
Index: lemon/concepts/path.h
===================================================================
--- lemon/concepts/path.h	(revision 2553)
+++ lemon/concepts/path.h	(revision 2553)
@@ -0,0 +1,307 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup concept
+///\file
+///\brief Classes for representing paths in graphs.
+///
+///\todo Iterators have obsolete style
+
+#ifndef LEMON_CONCEPT_PATH_H
+#define LEMON_CONCEPT_PATH_H
+
+#include <lemon/bits/invalid.h>
+#include <lemon/bits/utility.h>
+#include <lemon/concept_check.h>
+
+namespace lemon {
+  namespace concepts {
+
+    /// \addtogroup concept
+    /// @{
+
+    /// \brief A skeleton structure for representing directed paths in
+    /// a graph.
+    ///
+    /// A skeleton structure for representing directed paths in a
+    /// graph.  
+    /// \param _Graph The graph type in which the path is.
+    ///
+    /// In a sense, the path can be treated as a list of edges. The
+    /// lemon path type stores just this list. As a consequence it
+    /// cannot enumerate the nodes in the path and the zero length
+    /// paths cannot store the source.
+    ///
+    template <typename _Graph>
+    class Path {
+    public:
+
+      /// Type of the underlying graph.
+      typedef _Graph Graph;
+      /// Edge type of the underlying graph.
+      typedef typename Graph::Edge Edge;
+
+      class EdgeIt;
+
+      /// \brief Default constructor
+      Path() {}
+
+      /// \brief Template constructor
+      template <typename CPath>
+      Path(const CPath& cpath) {}
+
+      /// \brief Template assigment
+      template <typename CPath>
+      Path& operator=(const CPath& cpath) {}
+
+      /// Length of the path ie. the number of edges in the path.
+      int length() const { return 0;}
+
+      /// Returns whether the path is empty.
+      bool empty() const { return true;}
+
+      /// Resets the path to an empty path.
+      void clear() {}
+
+      /// \brief Lemon style iterator for path edges
+      ///
+      /// This class is used to iterate on the edges of the paths.
+      class EdgeIt {
+      public:
+	/// Default constructor
+	EdgeIt() {}
+	/// Invalid constructor
+	EdgeIt(Invalid) {}
+	/// Constructor for first edge
+	EdgeIt(const Path &) {}
+
+        /// Conversion to Edge
+	operator Edge() const { return INVALID; }
+
+	/// Next edge
+	EdgeIt& operator++() {return *this;}
+
+	/// Comparison operator
+	bool operator==(const EdgeIt&) const {return true;}
+	/// Comparison operator
+	bool operator!=(const EdgeIt&) const {return true;}
+ 	/// Comparison operator
+ 	bool operator<(const EdgeIt&) const {return false;}
+
+      };
+
+      template <typename _Path>
+      struct Constraints {
+        void constraints() {
+          Path<Graph> pc;
+          _Path p, pp(pc);
+          int l = p.length();
+          int e = p.empty();
+          p.clear();
+
+          p = pc;
+
+          typename _Path::EdgeIt id, ii(INVALID), i(p);
+
+          ++i;
+          typename Graph::Edge ed = i;
+
+          e = (i == ii);
+          e = (i != ii);
+          e = (i < ii);
+
+          ignore_unused_variable_warning(l);
+          ignore_unused_variable_warning(pp);
+          ignore_unused_variable_warning(e);
+          ignore_unused_variable_warning(id);
+          ignore_unused_variable_warning(ii);
+          ignore_unused_variable_warning(ed);
+        }
+      };
+
+    };
+
+    namespace _path_bits {
+      
+      template <typename _Graph, typename _Path, typename RevPathTag = void>
+      struct PathDumperConstraints {
+        void constraints() {
+          int l = p.length();
+          int e = p.empty();
+
+          typename _Path::EdgeIt id, i(p);
+
+          ++i;
+          typename _Graph::Edge ed = i;
+
+          e = (i == INVALID);
+          e = (i != INVALID);
+
+          ignore_unused_variable_warning(l);
+          ignore_unused_variable_warning(e);
+          ignore_unused_variable_warning(id);
+          ignore_unused_variable_warning(ed);
+        }
+        _Path& p;
+      };
+
+      template <typename _Graph, typename _Path>
+      struct PathDumperConstraints<
+        _Graph, _Path, 
+        typename enable_if<typename _Path::RevPathTag, void>::type
+      > {
+        void constraints() {
+          int l = p.length();
+          int e = p.empty();
+
+          typename _Path::RevEdgeIt id, i(p);
+
+          ++i;
+          typename _Graph::Edge ed = i;
+
+          e = (i == INVALID);
+          e = (i != INVALID);
+
+          ignore_unused_variable_warning(l);
+          ignore_unused_variable_warning(e);
+          ignore_unused_variable_warning(id);
+          ignore_unused_variable_warning(ed);
+        }
+        _Path& p;
+      };
+    
+    }
+
+
+    /// \brief A skeleton structure for path dumpers.
+    ///
+    /// A skeleton structure for path dumpers. The path dumpers are
+    /// the generalization of the paths. The path dumpers can
+    /// enumerate the edges of the path wheter in forward or in
+    /// backward order.  In most time these classes are not used
+    /// directly rather it used to assign a dumped class to a real
+    /// path type.
+    ///
+    /// The main purpose of this concept is that the shortest path
+    /// algorithms can enumerate easily the edges in reverse order.
+    /// If we would like to give back a real path from these
+    /// algorithms then we should create a temporarly path object. In
+    /// Lemon such algorithms gives back a path dumper what can
+    /// assigned to a real path and the dumpers can be implemented as
+    /// an adaptor class to the predecessor map.
+
+    /// \param _Graph  The graph type in which the path is.
+    ///
+    /// The paths can be constructed from any path type by a
+    /// template constructor or a template assignment operator.
+    /// 
+    template <typename _Graph>
+    class PathDumper {
+    public:
+
+      /// Type of the underlying graph.
+      typedef _Graph Graph;
+      /// Edge type of the underlying graph.
+      typedef typename Graph::Edge Edge;
+
+      /// Length of the path ie. the number of edges in the path.
+      int length() const { return 0;}
+
+      /// Returns whether the path is empty.
+      bool empty() const { return true;}
+
+      /// \brief Forward or reverse dumping
+      ///
+      /// If the RevPathTag is defined and true then reverse dumping
+      /// is provided in the path dumper. In this case instead of the
+      /// EdgeIt the RevEdgeIt iterator should be implemented in the
+      /// dumper.
+      typedef False RevPathTag;
+
+      /// \brief Lemon style iterator for path edges
+      ///
+      /// This class is used to iterate on the edges of the paths.
+      class EdgeIt {
+      public:
+	/// Default constructor
+	EdgeIt() {}
+	/// Invalid constructor
+	EdgeIt(Invalid) {}
+	/// Constructor for first edge
+	EdgeIt(const PathDumper&) {}
+
+        /// Conversion to Edge
+	operator Edge() const { return INVALID; }
+
+	/// Next edge
+	EdgeIt& operator++() {return *this;}
+
+	/// Comparison operator
+	bool operator==(const EdgeIt&) const {return true;}
+	/// Comparison operator
+	bool operator!=(const EdgeIt&) const {return true;}
+ 	/// Comparison operator
+ 	bool operator<(const EdgeIt&) const {return false;}
+
+      };
+
+      /// \brief Lemon style iterator for path edges
+      ///
+      /// This class is used to iterate on the edges of the paths in
+      /// reverse direction.
+      class RevEdgeIt {
+      public:
+	/// Default constructor
+	RevEdgeIt() {}
+	/// Invalid constructor
+	RevEdgeIt(Invalid) {}
+	/// Constructor for first edge
+	RevEdgeIt(const PathDumper &) {}
+
+        /// Conversion to Edge
+	operator Edge() const { return INVALID; }
+
+	/// Next edge
+	RevEdgeIt& operator++() {return *this;}
+
+	/// Comparison operator
+	bool operator==(const RevEdgeIt&) const {return true;}
+	/// Comparison operator
+	bool operator!=(const RevEdgeIt&) const {return true;}
+ 	/// Comparison operator
+ 	bool operator<(const RevEdgeIt&) const {return false;}
+
+      };
+
+      template <typename _Path>
+      struct Constraints {
+        void constraints() {
+          function_requires<_path_bits::
+            PathDumperConstraints<Graph, _Path> >();
+        }
+      };
+
+    };
+
+
+    ///@}
+  }
+
+} // namespace lemon
+
+#endif // LEMON_CONCEPT_PATH_H
Index: lemon/concepts/ugraph.h
===================================================================
--- lemon/concepts/ugraph.h	(revision 2553)
+++ lemon/concepts/ugraph.h	(revision 2553)
@@ -0,0 +1,702 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup graph_concepts
+///\file
+///\brief The concept of Undirected Graphs.
+
+#ifndef LEMON_CONCEPT_UGRAPH_H
+#define LEMON_CONCEPT_UGRAPH_H
+
+#include <lemon/concepts/graph_components.h>
+#include <lemon/concepts/graph.h>
+#include <lemon/bits/utility.h>
+
+namespace lemon {
+  namespace concepts {
+
+    /// \ingroup graph_concepts
+    ///
+    /// \brief Class describing the concept of Undirected Graphs.
+    ///
+    /// This class describes the common interface of all Undirected
+    /// Graphs.
+    ///
+    /// As all concept describing classes it provides only interface
+    /// without any sensible implementation. So any algorithm for
+    /// undirected graph should compile with this class, but it will not
+    /// run properly, of course.
+    ///
+    /// The LEMON undirected graphs also fulfill the concept of
+    /// directed graphs (\ref lemon::concepts::Graph "Graph
+    /// Concept"). Each undirected edges can be seen as two opposite
+    /// directed edge and consequently the undirected graph can be
+    /// seen as the direceted graph of these directed edges. The
+    /// UGraph has the UEdge inner class for the undirected edges and
+    /// the Edge type for the directed edges. The Edge type is
+    /// convertible to UEdge or inherited from it so from a directed
+    /// edge we can get the represented undirected edge.
+    ///
+    /// In the sense of the LEMON each undirected edge has a default
+    /// direction (it should be in every computer implementation,
+    /// because the order of undirected edge's nodes defines an
+    /// orientation). With the default orientation we can define that
+    /// the directed edge is forward or backward directed. With the \c
+    /// direction() and \c direct() function we can get the direction
+    /// of the directed edge and we can direct an undirected edge.
+    ///
+    /// The UEdgeIt is an iterator for the undirected edges. We can use
+    /// the UEdgeMap to map values for the undirected edges. The InEdgeIt and
+    /// OutEdgeIt iterates on the same undirected edges but with opposite
+    /// direction. The IncEdgeIt iterates also on the same undirected edges
+    /// as the OutEdgeIt and InEdgeIt but it is not convertible to Edge just
+    /// to UEdge.  
+    class UGraph {
+    public:
+      /// \brief The undirected graph should be tagged by the
+      /// UndirectedTag.
+      ///
+      /// The undirected graph should be tagged by the UndirectedTag. This
+      /// tag helps the enable_if technics to make compile time 
+      /// specializations for undirected graphs.  
+      typedef True UndirectedTag;
+
+      /// \brief The base type of node iterators, 
+      /// or in other words, the trivial node iterator.
+      ///
+      /// This is the base type of each node iterator,
+      /// thus each kind of node iterator converts to this.
+      /// More precisely each kind of node iterator should be inherited 
+      /// from the trivial node iterator.
+      class Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        Node() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        Node(const Node&) { }
+
+        /// Invalid constructor \& conversion.
+
+        /// This constructor initializes the iterator to be invalid.
+        /// \sa Invalid for more details.
+        Node(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(Node) const { return true; }
+
+        /// Inequality operator
+        
+        /// \sa operator==(Node n)
+        ///
+        bool operator!=(Node) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(Node) const { return false; }
+
+      };
+    
+      /// This iterator goes through each node.
+
+      /// This iterator goes through each node.
+      /// Its usage is quite simple, for example you can count the number
+      /// of nodes in graph \c g of type \c Graph like this:
+      ///\code
+      /// int count=0;
+      /// for (Graph::NodeIt n(g); n!=INVALID; ++n) ++count;
+      ///\endcode
+      class NodeIt : public Node {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        NodeIt() { }
+        /// Copy constructor.
+        
+        /// Copy constructor.
+        ///
+        NodeIt(const NodeIt& n) : Node(n) { }
+        /// Invalid constructor \& conversion.
+
+        /// Initialize the iterator to be invalid.
+        /// \sa Invalid for more details.
+        NodeIt(Invalid) { }
+        /// Sets the iterator to the first node.
+
+        /// Sets the iterator to the first node of \c g.
+        ///
+        NodeIt(const UGraph&) { }
+        /// Node -> NodeIt conversion.
+
+        /// Sets the iterator to the node of \c the graph pointed by 
+	/// the trivial iterator.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        NodeIt(const UGraph&, const Node&) { }
+        /// Next node.
+
+        /// Assign the iterator to the next node.
+        ///
+        NodeIt& operator++() { return *this; }
+      };
+    
+    
+      /// The base type of the undirected edge iterators.
+
+      /// The base type of the undirected edge iterators.
+      ///
+      class UEdge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        UEdge() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        UEdge(const UEdge&) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        UEdge(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(UEdge) const { return true; }
+        /// Inequality operator
+
+        /// \sa operator==(UEdge n)
+        ///
+        bool operator!=(UEdge) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(UEdge) const { return false; }
+      };
+
+      /// This iterator goes through each undirected edge.
+
+      /// This iterator goes through each undirected edge of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of undirected edges in a graph \c g of type \c Graph as follows:
+      ///\code
+      /// int count=0;
+      /// for(Graph::UEdgeIt e(g); e!=INVALID; ++e) ++count;
+      ///\endcode
+      class UEdgeIt : public UEdge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        UEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        UEdgeIt(const UEdgeIt& e) : UEdge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        UEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to the first undirected edge.
+    
+        /// This constructor sets the iterator to the first undirected edge.
+        UEdgeIt(const UGraph&) { }
+        /// UEdge -> UEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator.
+        /// This feature necessitates that each time we
+        /// iterate the undirected edge-set, the iteration order is the 
+	/// same.
+        UEdgeIt(const UGraph&, const UEdge&) { } 
+        /// Next undirected edge
+        
+        /// Assign the iterator to the next undirected edge.
+        UEdgeIt& operator++() { return *this; }
+      };
+
+      /// \brief This iterator goes trough the incident undirected 
+      /// edges of a node.
+      ///
+      /// This iterator goes trough the incident undirected edges
+      /// of a certain node of a graph. You should assume that the 
+      /// loop edges will be iterated twice.
+      /// 
+      /// Its usage is quite simple, for example you can compute the
+      /// degree (i.e. count the number of incident edges of a node \c n
+      /// in graph \c g of type \c Graph as follows. 
+      ///
+      ///\code
+      /// int count=0;
+      /// for(Graph::IncEdgeIt e(g, n); e!=INVALID; ++e) ++count;
+      ///\endcode
+      class IncEdgeIt : public UEdge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        IncEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        IncEdgeIt(const IncEdgeIt& e) : UEdge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        IncEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to first incident edge.
+    
+        /// This constructor set the iterator to the first incident edge of
+        /// the node.
+        IncEdgeIt(const UGraph&, const Node&) { }
+        /// UEdge -> IncEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator \c e.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        IncEdgeIt(const UGraph&, const UEdge&) { }
+        /// Next incident edge
+
+        /// Assign the iterator to the next incident edge
+	/// of the corresponding node.
+        IncEdgeIt& operator++() { return *this; }
+      };
+
+      /// The directed edge type.
+
+      /// The directed edge type. It can be converted to the
+      /// undirected edge or it should be inherited from the undirected
+      /// edge.
+      class Edge : public UEdge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        Edge() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        Edge(const Edge& e) : UEdge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        Edge(Invalid) { }
+        /// Equality operator
+
+        /// Two iterators are equal if and only if they point to the
+        /// same object or both are invalid.
+        bool operator==(Edge) const { return true; }
+        /// Inequality operator
+
+        /// \sa operator==(Edge n)
+        ///
+        bool operator!=(Edge) const { return true; }
+
+	/// Artificial ordering operator.
+	
+	/// To allow the use of graph descriptors as key type in std::map or
+	/// similar associative container we require this.
+	///
+	/// \note This operator only have to define some strict ordering of
+	/// the items; this order has nothing to do with the iteration
+	/// ordering of the items.
+	bool operator<(Edge) const { return false; }
+	
+      }; 
+      /// This iterator goes through each directed edge.
+
+      /// This iterator goes through each edge of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of edges in a graph \c g of type \c Graph as follows:
+      ///\code
+      /// int count=0;
+      /// for(Graph::EdgeIt e(g); e!=INVALID; ++e) ++count;
+      ///\endcode
+      class EdgeIt : public Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        EdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        EdgeIt(const EdgeIt& e) : Edge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        EdgeIt(Invalid) { }
+        /// This constructor sets the iterator to the first edge.
+    
+        /// This constructor sets the iterator to the first edge of \c g.
+        ///@param g the graph
+        EdgeIt(const UGraph &g) { ignore_unused_variable_warning(g); }
+        /// Edge -> EdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator \c e.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        EdgeIt(const UGraph&, const Edge&) { } 
+        ///Next edge
+        
+        /// Assign the iterator to the next edge.
+        EdgeIt& operator++() { return *this; }
+      };
+   
+      /// This iterator goes trough the outgoing directed edges of a node.
+
+      /// This iterator goes trough the \e outgoing edges of a certain node
+      /// of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of outgoing edges of a node \c n
+      /// in graph \c g of type \c Graph as follows.
+      ///\code
+      /// int count=0;
+      /// for (Graph::OutEdgeIt e(g, n); e!=INVALID; ++e) ++count;
+      ///\endcode
+    
+      class OutEdgeIt : public Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        OutEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        OutEdgeIt(const OutEdgeIt& e) : Edge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        OutEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to the first outgoing edge.
+    
+        /// This constructor sets the iterator to the first outgoing edge of
+        /// the node.
+        ///@param n the node
+        ///@param g the graph
+        OutEdgeIt(const UGraph& n, const Node& g) {
+	  ignore_unused_variable_warning(n);
+	  ignore_unused_variable_warning(g);
+	}
+        /// Edge -> OutEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator.
+	/// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        OutEdgeIt(const UGraph&, const Edge&) { }
+        ///Next outgoing edge
+        
+        /// Assign the iterator to the next 
+        /// outgoing edge of the corresponding node.
+        OutEdgeIt& operator++() { return *this; }
+      };
+
+      /// This iterator goes trough the incoming directed edges of a node.
+
+      /// This iterator goes trough the \e incoming edges of a certain node
+      /// of a graph.
+      /// Its usage is quite simple, for example you can count the number
+      /// of outgoing edges of a node \c n
+      /// in graph \c g of type \c Graph as follows.
+      ///\code
+      /// int count=0;
+      /// for(Graph::InEdgeIt e(g, n); e!=INVALID; ++e) ++count;
+      ///\endcode
+
+      class InEdgeIt : public Edge {
+      public:
+        /// Default constructor
+
+        /// @warning The default constructor sets the iterator
+        /// to an undefined value.
+        InEdgeIt() { }
+        /// Copy constructor.
+
+        /// Copy constructor.
+        ///
+        InEdgeIt(const InEdgeIt& e) : Edge(e) { }
+        /// Initialize the iterator to be invalid.
+
+        /// Initialize the iterator to be invalid.
+        ///
+        InEdgeIt(Invalid) { }
+        /// This constructor sets the iterator to first incoming edge.
+    
+        /// This constructor set the iterator to the first incoming edge of
+        /// the node.
+        ///@param n the node
+        ///@param g the graph
+        InEdgeIt(const UGraph& g, const Node& n) { 
+	  ignore_unused_variable_warning(n);
+	  ignore_unused_variable_warning(g);
+	}
+        /// Edge -> InEdgeIt conversion
+
+        /// Sets the iterator to the value of the trivial iterator \c e.
+        /// This feature necessitates that each time we 
+        /// iterate the edge-set, the iteration order is the same.
+        InEdgeIt(const UGraph&, const Edge&) { }
+        /// Next incoming edge
+
+        /// Assign the iterator to the next inedge of the corresponding node.
+        ///
+        InEdgeIt& operator++() { return *this; }
+      };
+
+      /// \brief Read write map of the nodes to type \c T.
+      /// 
+      /// ReadWrite map of the nodes to type \c T.
+      /// \sa Reference
+      template<class T> 
+      class NodeMap : public ReadWriteMap< Node, T >
+      {
+      public:
+
+        ///\e
+        NodeMap(const UGraph&) { }
+        ///\e
+        NodeMap(const UGraph&, T) { }
+
+        ///Copy constructor
+        NodeMap(const NodeMap& nm) : ReadWriteMap< Node, T >(nm) { }
+        ///Assignment operator
+        template <typename CMap>
+        NodeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Node, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      /// \brief Read write map of the directed edges to type \c T.
+      ///
+      /// Reference map of the directed edges to type \c T.
+      /// \sa Reference
+      template<class T> 
+      class EdgeMap : public ReadWriteMap<Edge,T>
+      {
+      public:
+
+        ///\e
+        EdgeMap(const UGraph&) { }
+        ///\e
+        EdgeMap(const UGraph&, T) { }
+        ///Copy constructor
+        EdgeMap(const EdgeMap& em) : ReadWriteMap<Edge,T>(em) { }
+        ///Assignment operator
+        template <typename CMap>
+        EdgeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<Edge, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      /// Read write map of the undirected edges to type \c T.
+
+      /// Reference map of the edges to type \c T.
+      /// \sa Reference
+      template<class T> 
+      class UEdgeMap : public ReadWriteMap<UEdge,T>
+      {
+      public:
+
+        ///\e
+        UEdgeMap(const UGraph&) { }
+        ///\e
+        UEdgeMap(const UGraph&, T) { }
+        ///Copy constructor
+        UEdgeMap(const UEdgeMap& em) : ReadWriteMap<UEdge,T>(em) {}
+        ///Assignment operator
+        template <typename CMap>
+        UEdgeMap& operator=(const CMap&) { 
+          checkConcept<ReadMap<UEdge, T>, CMap>();
+          return *this; 
+        }
+      };
+
+      /// \brief Direct the given undirected edge.
+      ///
+      /// Direct the given undirected edge. The returned edge source
+      /// will be the given node.
+      Edge direct(const UEdge&, const Node&) const {
+	return INVALID;
+      }
+
+      /// \brief Direct the given undirected edge.
+      ///
+      /// Direct the given undirected edge. The returned edge
+      /// represents the given undirected edge and the direction comes
+      /// from the given bool.  The source of the undirected edge and
+      /// the directed edge is the same when the given bool is true.
+      Edge direct(const UEdge&, bool) const {
+	return INVALID;
+      }
+
+      /// \brief Returns true if the edge has default orientation.
+      ///
+      /// Returns whether the given directed edge is same orientation as
+      /// the corresponding undirected edge's default orientation.
+      bool direction(Edge) const { return true; }
+
+      /// \brief Returns the opposite directed edge.
+      ///
+      /// Returns the opposite directed edge.
+      Edge oppositeEdge(Edge) const { return INVALID; }
+
+      /// \brief Opposite node on an edge
+      ///
+      /// \return the opposite of the given Node on the given UEdge
+      Node oppositeNode(Node, UEdge) const { return INVALID; }
+
+      /// \brief First node of the undirected edge.
+      ///
+      /// \return the first node of the given UEdge.
+      ///
+      /// Naturally undirected edges don't have direction and thus
+      /// don't have source and target node. But we use these two methods
+      /// to query the two nodes of the edge. The direction of the edge
+      /// which arises this way is called the inherent direction of the
+      /// undirected edge, and is used to define the "default" direction
+      /// of the directed versions of the edges.
+      /// \sa direction
+      Node source(UEdge) const { return INVALID; }
+
+      /// \brief Second node of the undirected edge.
+      Node target(UEdge) const { return INVALID; }
+
+      /// \brief Source node of the directed edge.
+      Node source(Edge) const { return INVALID; }
+
+      /// \brief Target node of the directed edge.
+      Node target(Edge) const { return INVALID; }
+
+      void first(Node&) const {}
+      void next(Node&) const {}
+
+      void first(UEdge&) const {}
+      void next(UEdge&) const {}
+
+      void first(Edge&) const {}
+      void next(Edge&) const {}
+
+      void firstOut(Edge&, Node) const {}
+      void nextOut(Edge&) const {}
+
+      void firstIn(Edge&, Node) const {}
+      void nextIn(Edge&) const {}
+
+
+      void firstInc(UEdge &, bool &, const Node &) const {}
+      void nextInc(UEdge &, bool &) const {}
+
+      /// \brief Base node of the iterator
+      ///
+      /// Returns the base node (the source in this case) of the iterator
+      Node baseNode(OutEdgeIt e) const {
+	return source(e);
+      }
+      /// \brief Running node of the iterator
+      ///
+      /// Returns the running node (the target in this case) of the
+      /// iterator
+      Node runningNode(OutEdgeIt e) const {
+	return target(e);
+      }
+
+      /// \brief Base node of the iterator
+      ///
+      /// Returns the base node (the target in this case) of the iterator
+      Node baseNode(InEdgeIt e) const {
+	return target(e);
+      }
+      /// \brief Running node of the iterator
+      ///
+      /// Returns the running node (the source in this case) of the
+      /// iterator
+      Node runningNode(InEdgeIt e) const {
+	return source(e);
+      }
+
+      /// \brief Base node of the iterator
+      ///
+      /// Returns the base node of the iterator
+      Node baseNode(IncEdgeIt) const {
+	return INVALID;
+      }
+      
+      /// \brief Running node of the iterator
+      ///
+      /// Returns the running node of the iterator
+      Node runningNode(IncEdgeIt) const {
+	return INVALID;
+      }
+
+      template <typename Graph>
+      struct Constraints {
+	void constraints() {
+	  checkConcept<IterableUGraphComponent<>, Graph>();
+	  checkConcept<MappableUGraphComponent<>, Graph>();
+	}
+      };
+
+    };
+
+  }
+
+}
+
+#endif
Index: lemon/config.h.in
===================================================================
--- lemon/config.h.in	(revision 2647)
+++ lemon/config.h.in	(revision 2605)
@@ -4,2 +4,5 @@
 /* Define to 1 if you have GLPK. */
 #undef HAVE_GLPK
+
+/* Define to 1 if you have SOPLEX. */
+#undef HAVE_SOPLEX
Index: lemon/cost_scaling.h
===================================================================
--- lemon/cost_scaling.h	(revision 2629)
+++ lemon/cost_scaling.h	(revision 2629)
@@ -0,0 +1,842 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_COST_SCALING_H
+#define LEMON_COST_SCALING_H
+
+/// \ingroup min_cost_flow
+/// \file
+/// \brief Cost scaling algorithm for finding a minimum cost flow.
+
+#include <deque>
+#include <lemon/graph_adaptor.h>
+#include <lemon/graph_utils.h>
+#include <lemon/maps.h>
+#include <lemon/math.h>
+
+#include <lemon/circulation.h>
+#include <lemon/bellman_ford.h>
+
+namespace lemon {
+
+  /// \addtogroup min_cost_flow
+  /// @{
+
+  /// \brief Implementation of the cost scaling algorithm for finding a
+  /// minimum cost flow.
+  ///
+  /// \ref CostScaling implements the cost scaling algorithm performing
+  /// augment/push and relabel operations for finding a minimum cost
+  /// flow.
+  ///
+  /// \tparam Graph The directed graph type the algorithm runs on.
+  /// \tparam LowerMap The type of the lower bound map.
+  /// \tparam CapacityMap The type of the capacity (upper bound) map.
+  /// \tparam CostMap The type of the cost (length) map.
+  /// \tparam SupplyMap The type of the supply map.
+  ///
+  /// \warning
+  /// - Edge capacities and costs should be \e non-negative \e integers.
+  /// - Supply values should be \e signed \e integers.
+  /// - The value types of the maps should be convertible to each other.
+  /// - \c CostMap::Value must be signed type.
+  ///
+  /// \note Edge costs are multiplied with the number of nodes during
+  /// the algorithm so overflow problems may arise more easily than with
+  /// other minimum cost flow algorithms.
+  /// If it is available, <tt>long long int</tt> type is used instead of
+  /// <tt>long int</tt> in the inside computations.
+  ///
+  /// \author Peter Kovacs
+  template < typename Graph,
+             typename LowerMap = typename Graph::template EdgeMap<int>,
+             typename CapacityMap = typename Graph::template EdgeMap<int>,
+             typename CostMap = typename Graph::template EdgeMap<int>,
+             typename SupplyMap = typename Graph::template NodeMap<int> >
+  class CostScaling
+  {
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename CapacityMap::Value Capacity;
+    typedef typename CostMap::Value Cost;
+    typedef typename SupplyMap::Value Supply;
+    typedef typename Graph::template EdgeMap<Capacity> CapacityEdgeMap;
+    typedef typename Graph::template NodeMap<Supply> SupplyNodeMap;
+
+    typedef ResGraphAdaptor< const Graph, Capacity,
+                             CapacityEdgeMap, CapacityEdgeMap > ResGraph;
+    typedef typename ResGraph::Edge ResEdge;
+
+#if defined __GNUC__ && !defined __STRICT_ANSI__
+    typedef long long int LCost;
+#else
+    typedef long int LCost;
+#endif
+    typedef typename Graph::template EdgeMap<LCost> LargeCostMap;
+
+  public:
+
+    /// The type of the flow map.
+    typedef typename Graph::template EdgeMap<Capacity> FlowMap;
+    /// The type of the potential map.
+    typedef typename Graph::template NodeMap<LCost> PotentialMap;
+
+  private:
+
+    /// \brief Map adaptor class for handling residual edge costs.
+    ///
+    /// Map adaptor class for handling residual edge costs.
+    template <typename Map>
+    class ResidualCostMap : public MapBase<ResEdge, typename Map::Value>
+    {
+    private:
+
+      const Map &_cost_map;
+
+    public:
+
+      ///\e
+      ResidualCostMap(const Map &cost_map) :
+        _cost_map(cost_map) {}
+
+      ///\e
+      inline typename Map::Value operator[](const ResEdge &e) const {
+        return ResGraph::forward(e) ? _cost_map[e] : -_cost_map[e];
+      }
+
+    }; //class ResidualCostMap
+
+    /// \brief Map adaptor class for handling reduced edge costs.
+    ///
+    /// Map adaptor class for handling reduced edge costs.
+    class ReducedCostMap : public MapBase<Edge, LCost>
+    {
+    private:
+
+      const Graph &_gr;
+      const LargeCostMap &_cost_map;
+      const PotentialMap &_pot_map;
+
+    public:
+
+      ///\e
+      ReducedCostMap( const Graph &gr,
+                      const LargeCostMap &cost_map,
+                      const PotentialMap &pot_map ) :
+        _gr(gr), _cost_map(cost_map), _pot_map(pot_map) {}
+
+      ///\e
+      inline LCost operator[](const Edge &e) const {
+        return _cost_map[e] + _pot_map[_gr.source(e)]
+                            - _pot_map[_gr.target(e)];
+      }
+
+    }; //class ReducedCostMap
+
+  private:
+
+    // The directed graph the algorithm runs on
+    const Graph &_graph;
+    // The original lower bound map
+    const LowerMap *_lower;
+    // The modified capacity map
+    CapacityEdgeMap _capacity;
+    // The original cost map
+    const CostMap &_orig_cost;
+    // The scaled cost map
+    LargeCostMap _cost;
+    // The modified supply map
+    SupplyNodeMap _supply;
+    bool _valid_supply;
+
+    // Edge map of the current flow
+    FlowMap *_flow;
+    bool _local_flow;
+    // Node map of the current potentials
+    PotentialMap *_potential;
+    bool _local_potential;
+
+    // The residual cost map
+    ResidualCostMap<LargeCostMap> _res_cost;
+    // The residual graph
+    ResGraph *_res_graph;
+    // The reduced cost map
+    ReducedCostMap *_red_cost;
+    // The excess map
+    SupplyNodeMap _excess;
+    // The epsilon parameter used for cost scaling
+    LCost _epsilon;
+    // The scaling factor
+    int _alpha;
+
+  public:
+
+    /// \brief General constructor (with lower bounds).
+    ///
+    /// General constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    CostScaling( const Graph &graph,
+                 const LowerMap &lower,
+                 const CapacityMap &capacity,
+                 const CostMap &cost,
+                 const SupplyMap &supply ) :
+      _graph(graph), _lower(&lower), _capacity(capacity), _orig_cost(cost),
+      _cost(graph), _supply(supply), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false), _res_cost(_cost),
+      _res_graph(NULL), _red_cost(NULL), _excess(graph, 0)
+    {
+      // Check the sum of supply values
+      Supply sum = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) sum += _supply[n];
+      _valid_supply = sum == 0;
+
+      // Remove non-zero lower bounds
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if (lower[e] != 0) {
+          _capacity[e] -= lower[e];
+          _supply[_graph.source(e)] -= lower[e];
+          _supply[_graph.target(e)] += lower[e];
+        }
+      }
+    }
+
+    /// \brief General constructor (without lower bounds).
+    ///
+    /// General constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    CostScaling( const Graph &graph,
+                 const CapacityMap &capacity,
+                 const CostMap &cost,
+                 const SupplyMap &supply ) :
+      _graph(graph), _lower(NULL), _capacity(capacity), _orig_cost(cost),
+      _cost(graph), _supply(supply), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false), _res_cost(_cost),
+      _res_graph(NULL), _red_cost(NULL), _excess(graph, 0)
+    {
+      // Check the sum of supply values
+      Supply sum = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) sum += _supply[n];
+      _valid_supply = sum == 0;
+    }
+
+    /// \brief Simple constructor (with lower bounds).
+    ///
+    /// Simple constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    CostScaling( const Graph &graph,
+                 const LowerMap &lower,
+                 const CapacityMap &capacity,
+                 const CostMap &cost,
+                 Node s, Node t,
+                 Supply flow_value ) :
+      _graph(graph), _lower(&lower), _capacity(capacity), _orig_cost(cost),
+      _cost(graph), _supply(graph, 0), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false), _res_cost(_cost),
+      _res_graph(NULL), _red_cost(NULL), _excess(graph, 0)
+    {
+      // Remove non-zero lower bounds
+      _supply[s] =  flow_value;
+      _supply[t] = -flow_value;
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if (lower[e] != 0) {
+          _capacity[e] -= lower[e];
+          _supply[_graph.source(e)] -= lower[e];
+          _supply[_graph.target(e)] += lower[e];
+        }
+      }
+      _valid_supply = true;
+    }
+
+    /// \brief Simple constructor (without lower bounds).
+    ///
+    /// Simple constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    CostScaling( const Graph &graph,
+                 const CapacityMap &capacity,
+                 const CostMap &cost,
+                 Node s, Node t,
+                 Supply flow_value ) :
+      _graph(graph), _lower(NULL), _capacity(capacity), _orig_cost(cost),
+      _cost(graph), _supply(graph, 0), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false), _res_cost(_cost),
+      _res_graph(NULL), _red_cost(NULL), _excess(graph, 0)
+    {
+      _supply[s] =  flow_value;
+      _supply[t] = -flow_value;
+      _valid_supply = true;
+    }
+
+    /// Destructor.
+    ~CostScaling() {
+      if (_local_flow) delete _flow;
+      if (_local_potential) delete _potential;
+      delete _res_graph;
+      delete _red_cost;
+    }
+
+    /// \brief Set the flow map.
+    ///
+    /// Set the flow map.
+    ///
+    /// \return \c (*this)
+    CostScaling& flowMap(FlowMap &map) {
+      if (_local_flow) {
+        delete _flow;
+        _local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Set the potential map.
+    ///
+    /// Set the potential map.
+    ///
+    /// \return \c (*this)
+    CostScaling& potentialMap(PotentialMap &map) {
+      if (_local_potential) {
+        delete _potential;
+        _local_potential = false;
+      }
+      _potential = &map;
+      return *this;
+    }
+
+    /// \name Execution control
+
+    /// @{
+
+    /// \brief Run the algorithm.
+    ///
+    /// Run the algorithm.
+    ///
+    /// \param partial_augment By default the algorithm performs
+    /// partial augment and relabel operations in the cost scaling
+    /// phases. Set this parameter to \c false for using local push and
+    /// relabel operations instead.
+    ///
+    /// \return \c true if a feasible flow can be found.
+    bool run(bool partial_augment = true) {
+      if (partial_augment) {
+        return init() && startPartialAugment();
+      } else {
+        return init() && startPushRelabel();
+      }
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the algorithm can be obtained using these
+    /// functions.\n
+    /// \ref lemon::CostScaling::run() "run()" must be called before
+    /// using them.
+
+    /// @{
+
+    /// \brief Return a const reference to the edge map storing the
+    /// found flow.
+    ///
+    /// Return a const reference to the edge map storing the found flow.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const FlowMap& flowMap() const {
+      return *_flow;
+    }
+
+    /// \brief Return a const reference to the node map storing the
+    /// found potentials (the dual solution).
+    ///
+    /// Return a const reference to the node map storing the found
+    /// potentials (the dual solution).
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const PotentialMap& potentialMap() const {
+      return *_potential;
+    }
+
+    /// \brief Return the flow on the given edge.
+    ///
+    /// Return the flow on the given edge.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Capacity flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// \brief Return the potential of the given node.
+    ///
+    /// Return the potential of the given node.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost potential(const Node& node) const {
+      return (*_potential)[node];
+    }
+
+    /// \brief Return the total cost of the found flow.
+    ///
+    /// Return the total cost of the found flow. The complexity of the
+    /// function is \f$ O(e) \f$.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost totalCost() const {
+      Cost c = 0;
+      for (EdgeIt e(_graph); e != INVALID; ++e)
+        c += (*_flow)[e] * _orig_cost[e];
+      return c;
+    }
+
+    /// @}
+
+  private:
+
+    /// Initialize the algorithm.
+    bool init() {
+      if (!_valid_supply) return false;
+      // The scaling factor
+      _alpha = 8;
+
+      // Initialize flow and potential maps
+      if (!_flow) {
+        _flow = new FlowMap(_graph);
+        _local_flow = true;
+      }
+      if (!_potential) {
+        _potential = new PotentialMap(_graph);
+        _local_potential = true;
+      }
+
+      _red_cost = new ReducedCostMap(_graph, _cost, *_potential);
+      _res_graph = new ResGraph(_graph, _capacity, *_flow);
+
+      // Initialize the scaled cost map and the epsilon parameter
+      Cost max_cost = 0;
+      int node_num = countNodes(_graph);
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        _cost[e] = LCost(_orig_cost[e]) * node_num * _alpha;
+        if (_orig_cost[e] > max_cost) max_cost = _orig_cost[e];
+      }
+      _epsilon = max_cost * node_num;
+
+      // Find a feasible flow using Circulation
+      Circulation< Graph, ConstMap<Edge, Capacity>, CapacityEdgeMap,
+                   SupplyMap >
+        circulation( _graph, constMap<Edge>(Capacity(0)), _capacity,
+                     _supply );
+      return circulation.flowMap(*_flow).run();
+    }
+
+    /// Execute the algorithm performing partial augmentation and
+    /// relabel operations.
+    bool startPartialAugment() {
+      // Paramters for heuristics
+      const int BF_HEURISTIC_EPSILON_BOUND = 1000;
+      const int BF_HEURISTIC_BOUND_FACTOR  = 3;
+      // Maximum augment path length
+      const int MAX_PATH_LENGTH = 4;
+
+      // Variables
+      typename Graph::template NodeMap<Edge> pred_edge(_graph);
+      typename Graph::template NodeMap<bool> forward(_graph);
+      typename Graph::template NodeMap<OutEdgeIt> next_out(_graph);
+      typename Graph::template NodeMap<InEdgeIt> next_in(_graph);
+      typename Graph::template NodeMap<bool> next_dir(_graph);
+      std::deque<Node> active_nodes;
+      std::vector<Node> path_nodes;
+
+      int node_num = countNodes(_graph);
+      for ( ; _epsilon >= 1; _epsilon = _epsilon < _alpha && _epsilon > 1 ?
+                                        1 : _epsilon / _alpha )
+      {
+        // "Early Termination" heuristic: use Bellman-Ford algorithm
+        // to check if the current flow is optimal
+        if (_epsilon <= BF_HEURISTIC_EPSILON_BOUND) {
+          typedef ShiftMap< ResidualCostMap<LargeCostMap> > ShiftCostMap;
+          ShiftCostMap shift_cost(_res_cost, 1);
+          BellmanFord<ResGraph, ShiftCostMap> bf(*_res_graph, shift_cost);
+          bf.init(0);
+          bool done = false;
+          int K = int(BF_HEURISTIC_BOUND_FACTOR * sqrt(node_num));
+          for (int i = 0; i < K && !done; ++i)
+            done = bf.processNextWeakRound();
+          if (done) break;
+        }
+
+        // Saturate edges not satisfying the optimality condition
+        Capacity delta;
+        for (EdgeIt e(_graph); e != INVALID; ++e) {
+          if (_capacity[e] - (*_flow)[e] > 0 && (*_red_cost)[e] < 0) {
+            delta = _capacity[e] - (*_flow)[e];
+            _excess[_graph.source(e)] -= delta;
+            _excess[_graph.target(e)] += delta;
+            (*_flow)[e] = _capacity[e];
+          }
+          if ((*_flow)[e] > 0 && -(*_red_cost)[e] < 0) {
+            _excess[_graph.target(e)] -= (*_flow)[e];
+            _excess[_graph.source(e)] += (*_flow)[e];
+            (*_flow)[e] = 0;
+          }
+        }
+
+        // Find active nodes (i.e. nodes with positive excess)
+        for (NodeIt n(_graph); n != INVALID; ++n) {
+          if (_excess[n] > 0) active_nodes.push_back(n);
+        }
+
+        // Initialize the next edge maps
+        for (NodeIt n(_graph); n != INVALID; ++n) {
+          next_out[n] = OutEdgeIt(_graph, n);
+          next_in[n] = InEdgeIt(_graph, n);
+          next_dir[n] = true;
+        }
+
+        // Perform partial augment and relabel operations
+        while (active_nodes.size() > 0) {
+          // Select an active node (FIFO selection)
+          if (_excess[active_nodes[0]] <= 0) {
+            active_nodes.pop_front();
+            continue;
+          }
+          Node start = active_nodes[0];
+          path_nodes.clear();
+          path_nodes.push_back(start);
+
+          // Find an augmenting path from the start node
+          Node u, tip = start;
+          LCost min_red_cost;
+          while ( _excess[tip] >= 0 &&
+                  int(path_nodes.size()) <= MAX_PATH_LENGTH )
+          {
+            if (next_dir[tip]) {
+              for (OutEdgeIt e = next_out[tip]; e != INVALID; ++e) {
+                if (_capacity[e] - (*_flow)[e] > 0 && (*_red_cost)[e] < 0) {
+                  u = _graph.target(e);
+                  pred_edge[u] = e;
+                  forward[u] = true;
+                  next_out[tip] = e;
+                  tip = u;
+                  path_nodes.push_back(tip);
+                  goto next_step;
+                }
+              }
+              next_dir[tip] = false;
+            }
+            for (InEdgeIt e = next_in[tip]; e != INVALID; ++e) {
+              if ((*_flow)[e] > 0 && -(*_red_cost)[e] < 0) {
+                u = _graph.source(e);
+                pred_edge[u] = e;
+                forward[u] = false;
+                next_in[tip] = e;
+                tip = u;
+                path_nodes.push_back(tip);
+                goto next_step;
+              }
+            }
+
+            // Relabel tip node
+            min_red_cost = std::numeric_limits<LCost>::max() / 2;
+            for (OutEdgeIt oe(_graph, tip); oe != INVALID; ++oe) {
+              if ( _capacity[oe] - (*_flow)[oe] > 0 &&
+                   (*_red_cost)[oe] < min_red_cost )
+                min_red_cost = (*_red_cost)[oe];
+            }
+            for (InEdgeIt ie(_graph, tip); ie != INVALID; ++ie) {
+              if ((*_flow)[ie] > 0 && -(*_red_cost)[ie] < min_red_cost)
+                min_red_cost = -(*_red_cost)[ie];
+            }
+            (*_potential)[tip] -= min_red_cost + _epsilon;
+
+            // Reset the next edge maps
+            next_out[tip] = OutEdgeIt(_graph, tip);
+            next_in[tip] = InEdgeIt(_graph, tip);
+            next_dir[tip] = true;
+
+            // Step back
+            if (tip != start) {
+              path_nodes.pop_back();
+              tip = path_nodes[path_nodes.size()-1];
+            }
+
+          next_step:
+            continue;
+          }
+
+          // Augment along the found path (as much flow as possible)
+          Capacity delta;
+          for (int i = 1; i < int(path_nodes.size()); ++i) {
+            u = path_nodes[i];
+            delta = forward[u] ?
+              _capacity[pred_edge[u]] - (*_flow)[pred_edge[u]] :
+              (*_flow)[pred_edge[u]];
+            delta = std::min(delta, _excess[path_nodes[i-1]]);
+            (*_flow)[pred_edge[u]] += forward[u] ? delta : -delta;
+            _excess[path_nodes[i-1]] -= delta;
+            _excess[u] += delta;
+            if (_excess[u] > 0 && _excess[u] <= delta) active_nodes.push_back(u);
+          }
+        }
+      }
+
+      // Compute node potentials for the original costs
+      ResidualCostMap<CostMap> res_cost(_orig_cost);
+      BellmanFord< ResGraph, ResidualCostMap<CostMap> >
+        bf(*_res_graph, res_cost);
+      bf.init(0); bf.start();
+      for (NodeIt n(_graph); n != INVALID; ++n)
+        (*_potential)[n] = bf.dist(n);
+
+      // Handle non-zero lower bounds
+      if (_lower) {
+        for (EdgeIt e(_graph); e != INVALID; ++e)
+          (*_flow)[e] += (*_lower)[e];
+      }
+      return true;
+    }
+
+    /// Execute the algorithm performing push and relabel operations.
+    bool startPushRelabel() {
+      // Paramters for heuristics
+      const int BF_HEURISTIC_EPSILON_BOUND = 1000;
+      const int BF_HEURISTIC_BOUND_FACTOR  = 3;
+
+      typename Graph::template NodeMap<bool> hyper(_graph, false);
+      typename Graph::template NodeMap<Edge> pred_edge(_graph);
+      typename Graph::template NodeMap<bool> forward(_graph);
+      typename Graph::template NodeMap<OutEdgeIt> next_out(_graph);
+      typename Graph::template NodeMap<InEdgeIt> next_in(_graph);
+      typename Graph::template NodeMap<bool> next_dir(_graph);
+      std::deque<Node> active_nodes;
+
+      int node_num = countNodes(_graph);
+      for ( ; _epsilon >= 1; _epsilon = _epsilon < _alpha && _epsilon > 1 ?
+                                        1 : _epsilon / _alpha )
+      {
+        // "Early Termination" heuristic: use Bellman-Ford algorithm
+        // to check if the current flow is optimal
+        if (_epsilon <= BF_HEURISTIC_EPSILON_BOUND) {
+          typedef ShiftMap< ResidualCostMap<LargeCostMap> > ShiftCostMap;
+          ShiftCostMap shift_cost(_res_cost, 1);
+          BellmanFord<ResGraph, ShiftCostMap> bf(*_res_graph, shift_cost);
+          bf.init(0);
+          bool done = false;
+          int K = int(BF_HEURISTIC_BOUND_FACTOR * sqrt(node_num));
+          for (int i = 0; i < K && !done; ++i)
+            done = bf.processNextWeakRound();
+          if (done) break;
+        }
+
+        // Saturate edges not satisfying the optimality condition
+        Capacity delta;
+        for (EdgeIt e(_graph); e != INVALID; ++e) {
+          if (_capacity[e] - (*_flow)[e] > 0 && (*_red_cost)[e] < 0) {
+            delta = _capacity[e] - (*_flow)[e];
+            _excess[_graph.source(e)] -= delta;
+            _excess[_graph.target(e)] += delta;
+            (*_flow)[e] = _capacity[e];
+          }
+          if ((*_flow)[e] > 0 && -(*_red_cost)[e] < 0) {
+            _excess[_graph.target(e)] -= (*_flow)[e];
+            _excess[_graph.source(e)] += (*_flow)[e];
+            (*_flow)[e] = 0;
+          }
+        }
+
+        // Find active nodes (i.e. nodes with positive excess)
+        for (NodeIt n(_graph); n != INVALID; ++n) {
+          if (_excess[n] > 0) active_nodes.push_back(n);
+        }
+
+        // Initialize the next edge maps
+        for (NodeIt n(_graph); n != INVALID; ++n) {
+          next_out[n] = OutEdgeIt(_graph, n);
+          next_in[n] = InEdgeIt(_graph, n);
+          next_dir[n] = true;
+        }
+
+        // Perform push and relabel operations
+        while (active_nodes.size() > 0) {
+          // Select an active node (FIFO selection)
+          Node n = active_nodes[0], t;
+          bool relabel_enabled = true;
+
+          // Perform push operations if there are admissible edges
+          if (_excess[n] > 0 && next_dir[n]) {
+            OutEdgeIt e = next_out[n];
+            for ( ; e != INVALID; ++e) {
+              if (_capacity[e] - (*_flow)[e] > 0 && (*_red_cost)[e] < 0) {
+                delta = std::min(_capacity[e] - (*_flow)[e], _excess[n]);
+                t = _graph.target(e);
+
+                // Push-look-ahead heuristic
+                Capacity ahead = -_excess[t];
+                for (OutEdgeIt oe(_graph, t); oe != INVALID; ++oe) {
+                  if (_capacity[oe] - (*_flow)[oe] > 0 && (*_red_cost)[oe] < 0)
+                    ahead += _capacity[oe] - (*_flow)[oe];
+                }
+                for (InEdgeIt ie(_graph, t); ie != INVALID; ++ie) {
+                  if ((*_flow)[ie] > 0 && -(*_red_cost)[ie] < 0)
+                    ahead += (*_flow)[ie];
+                }
+                if (ahead < 0) ahead = 0;
+
+                // Push flow along the edge
+                if (ahead < delta) {
+                  (*_flow)[e] += ahead;
+                  _excess[n] -= ahead;
+                  _excess[t] += ahead;
+                  active_nodes.push_front(t);
+                  hyper[t] = true;
+                  relabel_enabled = false;
+                  break;
+                } else {
+                  (*_flow)[e] += delta;
+                  _excess[n] -= delta;
+                  _excess[t] += delta;
+                  if (_excess[t] > 0 && _excess[t] <= delta)
+                    active_nodes.push_back(t);
+                }
+
+                if (_excess[n] == 0) break;
+              }
+            }
+            if (e != INVALID) {
+              next_out[n] = e;
+            } else {
+              next_dir[n] = false;
+            }
+          }
+
+          if (_excess[n] > 0 && !next_dir[n]) {
+            InEdgeIt e = next_in[n];
+            for ( ; e != INVALID; ++e) {
+              if ((*_flow)[e] > 0 && -(*_red_cost)[e] < 0) {
+                delta = std::min((*_flow)[e], _excess[n]);
+                t = _graph.source(e);
+
+                // Push-look-ahead heuristic
+                Capacity ahead = -_excess[t];
+                for (OutEdgeIt oe(_graph, t); oe != INVALID; ++oe) {
+                  if (_capacity[oe] - (*_flow)[oe] > 0 && (*_red_cost)[oe] < 0)
+                    ahead += _capacity[oe] - (*_flow)[oe];
+                }
+                for (InEdgeIt ie(_graph, t); ie != INVALID; ++ie) {
+                  if ((*_flow)[ie] > 0 && -(*_red_cost)[ie] < 0)
+                    ahead += (*_flow)[ie];
+                }
+                if (ahead < 0) ahead = 0;
+
+                // Push flow along the edge
+                if (ahead < delta) {
+                  (*_flow)[e] -= ahead;
+                  _excess[n] -= ahead;
+                  _excess[t] += ahead;
+                  active_nodes.push_front(t);
+                  hyper[t] = true;
+                  relabel_enabled = false;
+                  break;
+                } else {
+                  (*_flow)[e] -= delta;
+                  _excess[n] -= delta;
+                  _excess[t] += delta;
+                  if (_excess[t] > 0 && _excess[t] <= delta)
+                    active_nodes.push_back(t);
+                }
+
+                if (_excess[n] == 0) break;
+              }
+            }
+            next_in[n] = e;
+          }
+
+          // Relabel the node if it is still active (or hyper)
+          if (relabel_enabled && (_excess[n] > 0 || hyper[n])) {
+            LCost min_red_cost = std::numeric_limits<LCost>::max() / 2;
+            for (OutEdgeIt oe(_graph, n); oe != INVALID; ++oe) {
+              if ( _capacity[oe] - (*_flow)[oe] > 0 &&
+                   (*_red_cost)[oe] < min_red_cost )
+                min_red_cost = (*_red_cost)[oe];
+            }
+            for (InEdgeIt ie(_graph, n); ie != INVALID; ++ie) {
+              if ((*_flow)[ie] > 0 && -(*_red_cost)[ie] < min_red_cost)
+                min_red_cost = -(*_red_cost)[ie];
+            }
+            (*_potential)[n] -= min_red_cost + _epsilon;
+            hyper[n] = false;
+
+            // Reset the next edge maps
+            next_out[n] = OutEdgeIt(_graph, n);
+            next_in[n] = InEdgeIt(_graph, n);
+            next_dir[n] = true;
+          }
+
+          // Remove nodes that are not active nor hyper
+          while ( active_nodes.size() > 0 &&
+                  _excess[active_nodes[0]] <= 0 &&
+                  !hyper[active_nodes[0]] ) {
+            active_nodes.pop_front();
+          }
+        }
+      }
+
+      // Compute node potentials for the original costs
+      ResidualCostMap<CostMap> res_cost(_orig_cost);
+      BellmanFord< ResGraph, ResidualCostMap<CostMap> >
+        bf(*_res_graph, res_cost);
+      bf.init(0); bf.start();
+      for (NodeIt n(_graph); n != INVALID; ++n)
+        (*_potential)[n] = bf.dist(n);
+
+      // Handle non-zero lower bounds
+      if (_lower) {
+        for (EdgeIt e(_graph); e != INVALID; ++e)
+          (*_flow)[e] += (*_lower)[e];
+      }
+      return true;
+    }
+
+  }; //class CostScaling
+
+  ///@}
+
+} //namespace lemon
+
+#endif //LEMON_COST_SCALING_H
Index: lemon/counter.h
===================================================================
--- lemon/counter.h	(revision 2553)
+++ lemon/counter.h	(revision 2553)
@@ -0,0 +1,181 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_COUNTER_H
+#define LEMON_COUNTER_H
+
+#include <string>
+#include <iostream>
+
+///\ingroup timecount
+///\file
+///\brief Tools for counting steps and events
+
+namespace lemon 
+{
+
+  template<class P> class _SubNoCounter;
+
+  template<class P>
+  class _SubCounter 
+  {
+    P &_parent;
+    std::string _title;
+    std::ostream &_os;
+    int count;
+  public:
+
+    typedef _SubCounter<_SubCounter<P> > SubCounter;
+    typedef _SubNoCounter<_SubCounter<P> > SubNoCounter;
+
+    _SubCounter(P &parent)
+      : _parent(parent), _title(), _os(std::cerr), count(0) {}
+    _SubCounter(P &parent,std::string title,std::ostream &os=std::cerr)
+      : _parent(parent), _title(title), _os(os), count(0) {}
+    _SubCounter(P &parent,const char *title,std::ostream &os=std::cerr)
+      : _parent(parent), _title(title), _os(os), count(0) {}
+    ~_SubCounter() { 
+      _os << _title << count <<std::endl;
+      _parent+=count;
+    }
+    _SubCounter &operator++() { count++; return *this;}
+    int operator++(int) { return count++; }
+    _SubCounter &operator--() { count--; return *this;}
+    int operator--(int) { return count--; }
+    _SubCounter &operator+=(int c) { count+=c; return *this;}
+    _SubCounter &operator-=(int c) { count-=c; return *this;}
+    void reset(int c=0) {count=c;}
+    operator int() {return count;}
+  };
+
+  template<class P>
+  class _SubNoCounter 
+  {
+    P &_parent;
+  public:
+    typedef _SubNoCounter<_SubNoCounter<P> > SubCounter;
+    typedef _SubNoCounter<_SubNoCounter<P> > SubNoCounter;
+  
+    _SubNoCounter(P &parent) :_parent(parent) {}
+    _SubNoCounter(P &parent,std::string,std::ostream &) 
+      :_parent(parent) {}
+    _SubNoCounter(P &parent,std::string) 
+      :_parent(parent) {}
+    _SubNoCounter(P &parent,const char *,std::ostream &)
+      :_parent(parent) {}
+    _SubNoCounter(P &parent,const char *)
+      :_parent(parent) {}
+    ~_SubNoCounter() {}
+    _SubNoCounter &operator++() { ++_parent; return *this;}
+    int operator++(int) { _parent++; return 0;}
+    _SubNoCounter &operator--() { --_parent; return *this;}
+    int operator--(int) { _parent--; return 0;}
+    _SubNoCounter &operator+=(int c) { _parent+=c; return *this;}
+    _SubNoCounter &operator-=(int c) { _parent-=c; return *this;}
+    void reset(int) {}
+    void reset() {}
+    operator int() {return 0;}
+  };
+
+
+  /// \addtogroup timecount
+  /// @{
+
+  ///A counter class
+
+  ///This class makes it easier to count certain events. You can increment
+  ///or decrement the counter using operator++ and operator--.
+  ///A report is automatically printed on destruction.
+  ///\todo More doc
+  class Counter 
+  {
+    std::string _title;
+    std::ostream &_os;
+    int count;
+  public:
+    ///\e
+
+    ///\todo document please.
+    ///
+    typedef _SubCounter<Counter> SubCounter;
+    ///\e
+
+    ///\todo document please.
+    ///
+    typedef _SubNoCounter<Counter> SubNoCounter;
+
+    ///\e
+    Counter() : _title(), _os(std::cerr), count(0) {}
+    ///\e
+    Counter(std::string title,std::ostream &os=std::cerr) 
+      : _title(title), _os(os), count(0) {}
+    ///\e
+    Counter(const char *title,std::ostream &os=std::cerr)
+      : _title(title), _os(os), count(0) {}
+    ///Destructor. Prints the given title and the value of the counter.
+    ~Counter() {
+      _os << _title << count <<std::endl;
+    }
+    ///\e
+    Counter &operator++() { count++; return *this;}
+    ///\e
+    int operator++(int) { return count++;}
+    ///\e
+    Counter &operator--() { count--; return *this;}
+    ///\e
+    int operator--(int) { return count--;}
+    ///\e
+    Counter &operator+=(int c) { count+=c; return *this;}
+    ///\e
+    Counter &operator-=(int c) { count-=c; return *this;}
+    ///\e
+    void reset(int c=0) {count=c;}
+    ///\e
+    operator int() {return count;}
+  };
+
+  ///'Do nothing' version of \ref Counter
+
+  ///'Do nothing' version of \ref Counter.
+  ///\sa Counter
+  class NoCounter
+  {
+  public:
+    typedef _SubNoCounter<NoCounter> SubCounter;
+    typedef _SubNoCounter<NoCounter> SubNoCounter;
+
+    NoCounter() {}
+    NoCounter(std::string,std::ostream &) {}
+    NoCounter(const char *,std::ostream &) {}
+    NoCounter(std::string) {}
+    NoCounter(const char *) {}
+    NoCounter &operator++() { return *this; }
+    int operator++(int) { return 0; }
+    NoCounter &operator--() { return *this; }
+    int operator--(int) { return 0; }
+    NoCounter &operator+=(int) { return *this;}
+    NoCounter &operator-=(int) { return *this;}
+    void reset(int) {}
+    void reset() {}
+    operator int() {return 0;}
+  };
+
+  ///@}
+}
+
+#endif
Index: lemon/csp.h
===================================================================
--- lemon/csp.h	(revision 2553)
+++ lemon/csp.h	(revision 2553)
@@ -0,0 +1,182 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_CSP_H
+#define LEMON_CSP_H
+
+///\ingroup approx
+///\file
+///\brief Algorithm for the Resource Constrained Shortest Path problem.
+///
+
+#include <lemon/list_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+#include <lemon/tolerance.h>
+#include <lemon/dijkstra.h>
+#include <lemon/path.h>
+#include <lemon/counter.h>
+namespace lemon {
+
+  ///\ingroup approx
+  ///
+  ///\brief Algorithms for the Resource Constrained Shortest Path Problem
+  ///
+  ///The Resource Constrained Shortest (Least Cost) Path problem is the
+  ///following. We are given a directed graph with two additive weightings
+  ///on the edges, referred as \e cost and \e delay. In addition,
+  ///a source and a destination node \e s and \e t and a delay
+  ///constraint \e D is given. A path \e p is called \e feasible
+  ///if <em>delay(p)\<=D</em>. Then, the task is to find the least cost
+  ///feasible path.
+  ///
+  template<class Graph,
+	   class CM=typename Graph:: template EdgeMap<double>,
+	   class DM=CM>
+  class ConstrainedShortestPath 
+  {
+  public:
+    
+    GRAPH_TYPEDEFS(typename Graph);
+    
+    typedef SimplePath<Graph> Path;
+    
+  private:
+    
+    const Graph &_g;
+    Tolerance<double> tol;
+
+    const CM &_cost;
+    const DM &_delay;
+
+    class CoMap 
+    {
+      const CM &_cost;
+      const DM &_delay;
+      double _lambda;
+    public:
+      typedef typename CM::Key Key;
+      typedef double Value;
+      CoMap(const CM &c, const DM &d) :_cost(c), _delay(d), _lambda(0) {}
+      double lambda() const { return _lambda; }
+      void lambda(double l)  { _lambda=l; }
+      Value operator[](Key &e) const 
+      {
+	return _cost[e]+_lambda*_delay[e];
+      }
+    };
+
+    CoMap _co_map;
+    
+    
+    Dijkstra<Graph, CoMap> _dij;
+
+  public:
+    
+    /// \brief Constructor
+    
+    ///Constructor
+    ///
+    ConstrainedShortestPath(const Graph &g, const CM &ct, const DM &dl)
+      : _g(g), _cost(ct), _delay(dl),
+	_co_map(ct, dl), _dij(_g,_co_map) {}
+    
+
+    ///Compute the cost of a path
+    double cost(const Path &p) const
+    {
+      double s=0;
+      //      Path r;  
+      for(typename Path::EdgeIt e(p);e!=INVALID;++e) s+=_cost[e];
+      return s;
+    }
+
+    ///Compute the delay of a path
+    double delay(const Path &p) const
+    {
+      double s=0;
+      for(typename Path::EdgeIt e(p);e!=INVALID;++e) s+=_delay[e];
+      return s;
+    }
+    
+    ///Runs the LARAC algorithm
+    
+    ///This function runs a Lagrange relaxation based heuristic to find
+    ///a delay constrained least cost path.
+    ///\param s source node
+    ///\param t target node
+    ///\param delta upper bound on the delta
+    ///\retval lo_bo a lower bound on the optimal solution
+    ///\return the found path or an empty 
+    Path larac(Node s, Node t, double delta, double &lo_bo) 
+    {
+      double lambda=0;
+      double cp,cq,dp,dq,cr,dr;
+      Path p;
+      Path q;
+      Path r;
+      {
+	Dijkstra<Graph,CM> dij(_g,_cost);
+	dij.run(s,t);
+	if(!dij.reached(t)) return Path();
+	p=dij.path(t);
+	cp=cost(p);
+	dp=delay(p);
+      }
+      if(delay(p)<=delta) return p;
+      {
+	Dijkstra<Graph,DM> dij(_g,_delay);
+	dij.run(s,t);
+	q=dij.path(t);
+	cq=cost(q);
+	dq=delay(q);
+      }
+      if(delay(q)>delta) return Path();
+      while (true) {
+	lambda=(cp-cq)/(dq-dp);
+	_co_map.lambda(lambda);
+	_dij.run(s,t);
+	r=_dij.path(t);
+	cr=cost(r);
+	dr=delay(r);
+	if(!tol.less(cr+lambda*dr,cp+lambda*dp)) {
+	  lo_bo=cq+lambda*(dq-delta);
+	  return q;
+	}
+	else if(tol.less(dr,delta)) 
+	  {
+	    q=r;
+	    cq=cr;
+	    dq=dr;
+	  }
+	else if(tol.less(delta,dr))
+	  {
+	    p=r;
+	    cp=cr;
+	    dp=dr;
+	  }
+	else return r;
+      }
+    }
+  };
+  
+
+} //END OF NAMESPACE LEMON
+
+#endif
Index: lemon/cycle_canceling.h
===================================================================
--- lemon/cycle_canceling.h	(revision 2629)
+++ lemon/cycle_canceling.h	(revision 2629)
@@ -0,0 +1,556 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_CYCLE_CANCELING_H
+#define LEMON_CYCLE_CANCELING_H
+
+/// \ingroup min_cost_flow
+///
+/// \file
+/// \brief Cycle-canceling algorithm for finding a minimum cost flow.
+
+#include <vector>
+#include <lemon/graph_adaptor.h>
+#include <lemon/path.h>
+
+#include <lemon/circulation.h>
+#include <lemon/bellman_ford.h>
+#include <lemon/min_mean_cycle.h>
+
+namespace lemon {
+
+  /// \addtogroup min_cost_flow
+  /// @{
+
+  /// \brief Implementation of a cycle-canceling algorithm for
+  /// finding a minimum cost flow.
+  ///
+  /// \ref CycleCanceling implements a cycle-canceling algorithm for
+  /// finding a minimum cost flow.
+  ///
+  /// \tparam Graph The directed graph type the algorithm runs on.
+  /// \tparam LowerMap The type of the lower bound map.
+  /// \tparam CapacityMap The type of the capacity (upper bound) map.
+  /// \tparam CostMap The type of the cost (length) map.
+  /// \tparam SupplyMap The type of the supply map.
+  ///
+  /// \warning
+  /// - Edge capacities and costs should be \e non-negative \e integers.
+  /// - Supply values should be \e signed \e integers.
+  /// - The value types of the maps should be convertible to each other.
+  /// - \c CostMap::Value must be signed type.
+  ///
+  /// \note By default the \ref BellmanFord "Bellman-Ford" algorithm is
+  /// used for negative cycle detection with limited iteration number.
+  /// However \ref CycleCanceling also provides the "Minimum Mean
+  /// Cycle-Canceling" algorithm, which is \e strongly \e polynomial,
+  /// but rather slower in practice.
+  /// To use this version of the algorithm, call \ref run() with \c true
+  /// parameter.
+  ///
+  /// \author Peter Kovacs
+  template < typename Graph,
+             typename LowerMap = typename Graph::template EdgeMap<int>,
+             typename CapacityMap = typename Graph::template EdgeMap<int>,
+             typename CostMap = typename Graph::template EdgeMap<int>,
+             typename SupplyMap = typename Graph::template NodeMap<int> >
+  class CycleCanceling
+  {
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename CapacityMap::Value Capacity;
+    typedef typename CostMap::Value Cost;
+    typedef typename SupplyMap::Value Supply;
+    typedef typename Graph::template EdgeMap<Capacity> CapacityEdgeMap;
+    typedef typename Graph::template NodeMap<Supply> SupplyNodeMap;
+
+    typedef ResGraphAdaptor< const Graph, Capacity,
+                             CapacityEdgeMap, CapacityEdgeMap > ResGraph;
+    typedef typename ResGraph::Node ResNode;
+    typedef typename ResGraph::NodeIt ResNodeIt;
+    typedef typename ResGraph::Edge ResEdge;
+    typedef typename ResGraph::EdgeIt ResEdgeIt;
+
+  public:
+
+    /// The type of the flow map.
+    typedef typename Graph::template EdgeMap<Capacity> FlowMap;
+    /// The type of the potential map.
+    typedef typename Graph::template NodeMap<Cost> PotentialMap;
+
+  private:
+
+    /// \brief Map adaptor class for handling residual edge costs.
+    ///
+    /// Map adaptor class for handling residual edge costs.
+    class ResidualCostMap : public MapBase<ResEdge, Cost>
+    {
+    private:
+
+      const CostMap &_cost_map;
+
+    public:
+
+      ///\e
+      ResidualCostMap(const CostMap &cost_map) : _cost_map(cost_map) {}
+
+      ///\e
+      Cost operator[](const ResEdge &e) const {
+        return ResGraph::forward(e) ? _cost_map[e] : -_cost_map[e];
+      }
+
+    }; //class ResidualCostMap
+
+  private:
+
+    // The maximum number of iterations for the first execution of the
+    // Bellman-Ford algorithm. It should be at least 2.
+    static const int BF_FIRST_LIMIT  = 2;
+    // The iteration limit for the Bellman-Ford algorithm is multiplied
+    // by BF_LIMIT_FACTOR/100 in every round.
+    static const int BF_LIMIT_FACTOR = 150;
+
+  private:
+
+    // The directed graph the algorithm runs on
+    const Graph &_graph;
+    // The original lower bound map
+    const LowerMap *_lower;
+    // The modified capacity map
+    CapacityEdgeMap _capacity;
+    // The original cost map
+    const CostMap &_cost;
+    // The modified supply map
+    SupplyNodeMap _supply;
+    bool _valid_supply;
+
+    // Edge map of the current flow
+    FlowMap *_flow;
+    bool _local_flow;
+    // Node map of the current potentials
+    PotentialMap *_potential;
+    bool _local_potential;
+
+    // The residual graph
+    ResGraph *_res_graph;
+    // The residual cost map
+    ResidualCostMap _res_cost;
+
+  public:
+
+    /// \brief General constructor (with lower bounds).
+    ///
+    /// General constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    CycleCanceling( const Graph &graph,
+                    const LowerMap &lower,
+                    const CapacityMap &capacity,
+                    const CostMap &cost,
+                    const SupplyMap &supply ) :
+      _graph(graph), _lower(&lower), _capacity(capacity), _cost(cost),
+      _supply(supply), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false), _res_graph(NULL),
+      _res_cost(_cost)
+    {
+      // Check the sum of supply values
+      Supply sum = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) sum += _supply[n];
+      _valid_supply = sum == 0;
+
+      // Remove non-zero lower bounds
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if (lower[e] != 0) {
+          _capacity[e] -= lower[e];
+          _supply[_graph.source(e)] -= lower[e];
+          _supply[_graph.target(e)] += lower[e];
+        }
+      }
+    }
+
+    /// \brief General constructor (without lower bounds).
+    ///
+    /// General constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    CycleCanceling( const Graph &graph,
+                    const CapacityMap &capacity,
+                    const CostMap &cost,
+                    const SupplyMap &supply ) :
+      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
+      _supply(supply), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false), _res_graph(NULL),
+      _res_cost(_cost)
+    {
+      // Check the sum of supply values
+      Supply sum = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) sum += _supply[n];
+      _valid_supply = sum == 0;
+    }
+
+    /// \brief Simple constructor (with lower bounds).
+    ///
+    /// Simple constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    CycleCanceling( const Graph &graph,
+                    const LowerMap &lower,
+                    const CapacityMap &capacity,
+                    const CostMap &cost,
+                    Node s, Node t,
+                    Supply flow_value ) :
+      _graph(graph), _lower(&lower), _capacity(capacity), _cost(cost),
+      _supply(graph, 0), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false), _res_graph(NULL),
+      _res_cost(_cost)
+    {
+      // Remove non-zero lower bounds
+      _supply[s] =  flow_value;
+      _supply[t] = -flow_value;
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if (lower[e] != 0) {
+          _capacity[e] -= lower[e];
+          _supply[_graph.source(e)] -= lower[e];
+          _supply[_graph.target(e)] += lower[e];
+        }
+      }
+      _valid_supply = true;
+    }
+
+    /// \brief Simple constructor (without lower bounds).
+    ///
+    /// Simple constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    CycleCanceling( const Graph &graph,
+                    const CapacityMap &capacity,
+                    const CostMap &cost,
+                    Node s, Node t,
+                    Supply flow_value ) :
+      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
+      _supply(graph, 0), _flow(NULL), _local_flow(false),
+      _potential(NULL), _local_potential(false), _res_graph(NULL),
+      _res_cost(_cost)
+    {
+      _supply[s] =  flow_value;
+      _supply[t] = -flow_value;
+      _valid_supply = true;
+    }
+
+    /// Destructor.
+    ~CycleCanceling() {
+      if (_local_flow) delete _flow;
+      if (_local_potential) delete _potential;
+      delete _res_graph;
+    }
+
+    /// \brief Set the flow map.
+    ///
+    /// Set the flow map.
+    ///
+    /// \return \c (*this)
+    CycleCanceling& flowMap(FlowMap &map) {
+      if (_local_flow) {
+        delete _flow;
+        _local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Set the potential map.
+    ///
+    /// Set the potential map.
+    ///
+    /// \return \c (*this)
+    CycleCanceling& potentialMap(PotentialMap &map) {
+      if (_local_potential) {
+        delete _potential;
+        _local_potential = false;
+      }
+      _potential = &map;
+      return *this;
+    }
+
+    /// \name Execution control
+
+    /// @{
+
+    /// \brief Run the algorithm.
+    ///
+    /// Run the algorithm.
+    ///
+    /// \param min_mean_cc Set this parameter to \c true to run the
+    /// "Minimum Mean Cycle-Canceling" algorithm, which is strongly
+    /// polynomial, but rather slower in practice.
+    ///
+    /// \return \c true if a feasible flow can be found.
+    bool run(bool min_mean_cc = false) {
+      return init() && start(min_mean_cc);
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the algorithm can be obtained using these
+    /// functions.\n
+    /// \ref lemon::CycleCanceling::run() "run()" must be called before
+    /// using them.
+
+    /// @{
+
+    /// \brief Return a const reference to the edge map storing the
+    /// found flow.
+    ///
+    /// Return a const reference to the edge map storing the found flow.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const FlowMap& flowMap() const {
+      return *_flow;
+    }
+
+    /// \brief Return a const reference to the node map storing the
+    /// found potentials (the dual solution).
+    ///
+    /// Return a const reference to the node map storing the found
+    /// potentials (the dual solution).
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const PotentialMap& potentialMap() const {
+      return *_potential;
+    }
+
+    /// \brief Return the flow on the given edge.
+    ///
+    /// Return the flow on the given edge.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Capacity flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// \brief Return the potential of the given node.
+    ///
+    /// Return the potential of the given node.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost potential(const Node& node) const {
+      return (*_potential)[node];
+    }
+
+    /// \brief Return the total cost of the found flow.
+    ///
+    /// Return the total cost of the found flow. The complexity of the
+    /// function is \f$ O(e) \f$.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost totalCost() const {
+      Cost c = 0;
+      for (EdgeIt e(_graph); e != INVALID; ++e)
+        c += (*_flow)[e] * _cost[e];
+      return c;
+    }
+
+    /// @}
+
+  private:
+
+    /// Initialize the algorithm.
+    bool init() {
+      if (!_valid_supply) return false;
+
+      // Initializing flow and potential maps
+      if (!_flow) {
+        _flow = new FlowMap(_graph);
+        _local_flow = true;
+      }
+      if (!_potential) {
+        _potential = new PotentialMap(_graph);
+        _local_potential = true;
+      }
+
+      _res_graph = new ResGraph(_graph, _capacity, *_flow);
+
+      // Finding a feasible flow using Circulation
+      Circulation< Graph, ConstMap<Edge, Capacity>, CapacityEdgeMap,
+                   SupplyMap >
+        circulation( _graph, constMap<Edge>(Capacity(0)), _capacity,
+                     _supply );
+      return circulation.flowMap(*_flow).run();
+    }
+
+    bool start(bool min_mean_cc) {
+      if (min_mean_cc)
+        startMinMean();
+      else
+        start();
+
+      // Handling non-zero lower bounds
+      if (_lower) {
+        for (EdgeIt e(_graph); e != INVALID; ++e)
+          (*_flow)[e] += (*_lower)[e];
+      }
+      return true;
+    }
+
+    /// \brief Execute the algorithm using \ref BellmanFord.
+    ///
+    /// Execute the algorithm using the \ref BellmanFord
+    /// "Bellman-Ford" algorithm for negative cycle detection with
+    /// successively larger limit for the number of iterations.
+    void start() {
+      typename BellmanFord<ResGraph, ResidualCostMap>::PredMap pred(*_res_graph);
+      typename ResGraph::template NodeMap<int> visited(*_res_graph);
+      std::vector<ResEdge> cycle;
+      int node_num = countNodes(_graph);
+
+      int length_bound = BF_FIRST_LIMIT;
+      bool optimal = false;
+      while (!optimal) {
+        BellmanFord<ResGraph, ResidualCostMap> bf(*_res_graph, _res_cost);
+        bf.predMap(pred);
+        bf.init(0);
+        int iter_num = 0;
+        bool cycle_found = false;
+        while (!cycle_found) {
+          int curr_iter_num = iter_num + length_bound <= node_num ?
+                              length_bound : node_num - iter_num;
+          iter_num += curr_iter_num;
+          int real_iter_num = curr_iter_num;
+          for (int i = 0; i < curr_iter_num; ++i) {
+            if (bf.processNextWeakRound()) {
+              real_iter_num = i;
+              break;
+            }
+          }
+          if (real_iter_num < curr_iter_num) {
+            // Optimal flow is found
+            optimal = true;
+            // Setting node potentials
+            for (NodeIt n(_graph); n != INVALID; ++n)
+              (*_potential)[n] = bf.dist(n);
+            break;
+          } else {
+            // Searching for node disjoint negative cycles
+            for (ResNodeIt n(*_res_graph); n != INVALID; ++n)
+              visited[n] = 0;
+            int id = 0;
+            for (ResNodeIt n(*_res_graph); n != INVALID; ++n) {
+              if (visited[n] > 0) continue;
+              visited[n] = ++id;
+              ResNode u = pred[n] == INVALID ?
+                          INVALID : _res_graph->source(pred[n]);
+              while (u != INVALID && visited[u] == 0) {
+                visited[u] = id;
+                u = pred[u] == INVALID ?
+                    INVALID : _res_graph->source(pred[u]);
+              }
+              if (u != INVALID && visited[u] == id) {
+                // Finding the negative cycle
+                cycle_found = true;
+                cycle.clear();
+                ResEdge e = pred[u];
+                cycle.push_back(e);
+                Capacity d = _res_graph->rescap(e);
+                while (_res_graph->source(e) != u) {
+                  cycle.push_back(e = pred[_res_graph->source(e)]);
+                  if (_res_graph->rescap(e) < d)
+                    d = _res_graph->rescap(e);
+                }
+
+                // Augmenting along the cycle
+                for (int i = 0; i < int(cycle.size()); ++i)
+                  _res_graph->augment(cycle[i], d);
+              }
+            }
+          }
+
+          if (!cycle_found)
+            length_bound = length_bound * BF_LIMIT_FACTOR / 100;
+        }
+      }
+    }
+
+    /// \brief Execute the algorithm using \ref MinMeanCycle.
+    ///
+    /// Execute the algorithm using \ref MinMeanCycle for negative
+    /// cycle detection.
+    void startMinMean() {
+      typedef Path<ResGraph> ResPath;
+      MinMeanCycle<ResGraph, ResidualCostMap> mmc(*_res_graph, _res_cost);
+      ResPath cycle;
+
+      mmc.cyclePath(cycle).init();
+      if (mmc.findMinMean()) {
+        while (mmc.cycleLength() < 0) {
+          // Finding the cycle
+          mmc.findCycle();
+
+          // Finding the largest flow amount that can be augmented
+          // along the cycle
+          Capacity delta = 0;
+          for (typename ResPath::EdgeIt e(cycle); e != INVALID; ++e) {
+            if (delta == 0 || _res_graph->rescap(e) < delta)
+              delta = _res_graph->rescap(e);
+          }
+
+          // Augmenting along the cycle
+          for (typename ResPath::EdgeIt e(cycle); e != INVALID; ++e)
+            _res_graph->augment(e, delta);
+
+          // Finding the minimum cycle mean for the modified residual
+          // graph
+          mmc.reset();
+          if (!mmc.findMinMean()) break;
+        }
+      }
+
+      // Computing node potentials
+      BellmanFord<ResGraph, ResidualCostMap> bf(*_res_graph, _res_cost);
+      bf.init(0); bf.start();
+      for (NodeIt n(_graph); n != INVALID; ++n)
+        (*_potential)[n] = bf.dist(n);
+    }
+
+  }; //class CycleCanceling
+
+  ///@}
+
+} //namespace lemon
+
+#endif //LEMON_CYCLE_CANCELING_H
Index: lemon/dag_shortest_path.h
===================================================================
--- lemon/dag_shortest_path.h	(revision 2553)
+++ lemon/dag_shortest_path.h	(revision 2553)
@@ -0,0 +1,1075 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_DAG_SHORTEST_PATH_H
+#define LEMON_DAG_SHORTEST_PATH_H
+
+///\ingroup flowalgs
+/// \file
+/// \brief DagShortestPath algorithm.
+///
+
+#include <lemon/list_graph.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+#include <lemon/topology.h>
+
+#include <limits>
+
+namespace lemon {
+
+  /// \brief Default OperationTraits for the DagShortestPath algorithm class.
+  ///  
+  /// It defines all computational operations and constants which are
+  /// used in the dag shortest path algorithm. The default implementation
+  /// is based on the numeric_limits class. If the numeric type does not
+  /// have infinity value then the maximum value is used as extremal
+  /// infinity value.
+  template <
+    typename Value, 
+    bool has_infinity = std::numeric_limits<Value>::has_infinity>
+  struct DagShortestPathDefaultOperationTraits {
+    /// \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 true only if the first value less than the second.
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+
+  template <typename Value>
+  struct DagShortestPathDefaultOperationTraits<Value, false> {
+    static Value zero() {
+      return static_cast<Value>(0);
+    }
+    static Value infinity() {
+      return std::numeric_limits<Value>::max();
+    }
+    static Value plus(const Value& left, const Value& right) {
+      if (left == infinity() || right == infinity()) return infinity();
+      return left + right;
+    }
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+  
+  /// \brief Default traits class of DagShortestPath class.
+  ///
+  /// Default traits class of DagShortestPath class.
+  /// \param _Graph Graph type.
+  /// \param _LegthMap Type of length map.
+  template<class _Graph, class _LengthMap>
+  struct DagShortestPathDefaultTraits {
+    /// The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge lengths.
+    ///
+    /// The type of the map that stores the edge lengths.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _LengthMap LengthMap;
+
+    // The type of the length of the edges.
+    typedef typename _LengthMap::Value Value;
+
+    /// \brief Operation traits for dag shortest path algorithm.
+    ///
+    /// It defines the infinity type on the given Value type
+    /// and the used operation.
+    /// \see DagShortestPathDefaultOperationTraits
+    typedef DagShortestPathDefaultOperationTraits<Value> OperationTraits;
+ 
+    /// \brief The type of the map that stores the last edges of the 
+    /// shortest paths.
+    /// 
+    /// The type of the map that stores the last
+    /// edges of the shortest paths.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename _Graph::Edge> PredMap;
+
+    /// \brief Instantiates a PredMap.
+    /// 
+    /// This function instantiates a \ref PredMap. 
+    /// \param graph is the graph, to which we would
+    /// like to define the PredMap.
+    /// \todo The graph alone may be insufficient for the initialization
+    static PredMap *createPredMap(const _Graph& graph) {
+      return new PredMap(graph);
+    }
+
+    /// \brief The type of the map that stores the dists of the nodes.
+    ///
+    /// The type of the map that stores the dists of the nodes.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename _LengthMap::Value> 
+    DistMap;
+
+    /// \brief Instantiates a DistMap.
+    ///
+    /// This function instantiates a \ref DistMap. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// \ref DistMap
+    static DistMap *createDistMap(const _Graph& graph) {
+      return new DistMap(graph);
+    }
+
+  };
+  
+  /// \brief Inverse OperationTraits for the DagShortestPath algorithm class.
+  /// 
+  /// It defines all computational operations and constants which are
+  /// used in the dag shortest path algorithm. It is the inverse of
+  /// \ref DagShortestPathDefaultOperationTraits, so it can be used to
+  /// calculate the longest path. The default implementation
+  /// is based on the numeric_limits class. If the numeric type does not
+  /// have infinity value then the minimum value is used as extremal
+  /// infinity value.
+  template <
+    typename Value, 
+    bool has_infinity = std::numeric_limits<Value>::has_infinity>
+  struct DagLongestPathOperationTraits {
+    /// \brief Gives back the zero value of the type.
+    static Value zero() {
+      return static_cast<Value>(0);
+    }
+    /// \brief Gives back the negative 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 true only if the first value less than the second.
+    static bool less(const Value& left, const Value& right) {
+      return left > right;
+    }
+  };
+
+  template <typename Value>
+  struct DagLongestPathOperationTraits<Value, false> {
+    static Value zero() {
+      return static_cast<Value>(0);
+    }
+    static Value infinity() {
+      return std::numeric_limits<Value>::min();
+    }
+    static Value plus(const Value& left, const Value& right) {
+      if (left == infinity() || right == infinity()) return infinity();
+      return left + right;
+    }
+    static bool less(const Value& left, const Value& right) {
+      return left > right;
+    }
+  };
+
+  /// \brief Inverse traits class of DagShortestPath class.
+  ///
+  /// Inverse traits class of DagShortestPath class.
+  /// \param _Graph Graph type.
+  /// \param _LegthMap Type of length map.
+  template<class _Graph, class _LengthMap>
+  struct DagLongestPathTraits {
+    /// The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge lengths.
+    ///
+    /// The type of the map that stores the edge lengths.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _LengthMap LengthMap;
+
+    // The type of the length of the edges.
+    typedef typename _LengthMap::Value Value;
+
+    /// \brief Inverse operation traits for dag shortest path algorithm.
+    ///
+    /// It defines the infinity type on the given Value type
+    /// and the used operation.
+    /// \see DagLongestPathOperationTraits
+    typedef DagLongestPathOperationTraits<Value> OperationTraits;
+ 
+    /// \brief The type of the map that stores the last edges of the 
+    /// longest paths.
+    /// 
+    /// The type of the map that stores the last
+    /// edges of the longest paths.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename _Graph::Edge> PredMap;
+
+    /// \brief Instantiates a PredMap.
+    /// 
+    /// This function instantiates a \ref PredMap. 
+    /// \param graph is the graph,
+    /// to which we would like to define the PredMap.
+    /// \todo The graph alone may be insufficient for the initialization
+    static PredMap *createPredMap(const _Graph& graph) {
+      return new PredMap(graph);
+    }
+
+    /// \brief The type of the map that stores the dists of the nodes.
+    ///
+    /// The type of the map that stores the dists of the nodes.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename _LengthMap::Value> 
+    DistMap;
+
+    /// \brief Instantiates a DistMap.
+    ///
+    /// This function instantiates a \ref DistMap. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// \ref DistMap
+    static DistMap *createDistMap(const _Graph& graph) {
+      return new DistMap(graph);
+    }
+
+  };
+  
+
+  /// \brief %DagShortestPath algorithm class.
+  ///
+  /// \ingroup flowalgs
+  /// This class provides an efficient implementation of a Dag sortest path
+  /// searching algorithm. The edge lengths are passed to the algorithm
+  /// using a \ref concepts::ReadMap "ReadMap", so it is easy to change it
+  /// to any kind of length.
+  ///
+  /// The complexity of the algorithm is O(n + e).
+  ///
+  /// The type of the length is determined by the
+  /// \ref concepts::ReadMap::Value "Value" of the length map.
+  ///
+  /// \param _Graph The graph type the algorithm runs on. The default value
+  /// is \ref ListGraph. The value of _Graph is not used directly by
+  /// DagShortestPath, it is only passed to \ref DagShortestPathDefaultTraits.
+  /// \param _LengthMap This read-only EdgeMap determines the lengths of the
+  /// edges. The default map type is \ref concepts::Graph::EdgeMap 
+  /// "Graph::EdgeMap<int>".  The value of _LengthMap is not used directly 
+  /// by DagShortestPath, it is only passed to \ref DagShortestPathDefaultTraits.  
+  /// \param _Traits Traits class to set various data types used by the 
+  /// algorithm.  The default traits class is \ref DagShortestPathDefaultTraits
+  /// "DagShortestPathDefaultTraits<_Graph,_LengthMap>".  See \ref
+  /// DagShortestPathDefaultTraits for the documentation of a DagShortestPath traits
+  /// class.
+  ///
+  /// \author Balazs Attila Mihaly (based on Balazs Dezso's work)
+
+#ifdef DOXYGEN
+  template <typename _Graph, typename _LengthMap, typename _Traits>
+#else
+  template <typename _Graph=ListGraph,
+	    typename _LengthMap=typename _Graph::template EdgeMap<int>,
+	    typename _Traits=DagShortestPathDefaultTraits<_Graph,_LengthMap> >
+#endif
+  class DagShortestPath {
+  public:
+    
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::DagShortestPath::UninitializedParameter";
+      }
+    };
+
+    typedef _Traits Traits;
+    ///The type of the underlying graph.
+    typedef typename _Traits::Graph Graph;
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::EdgeIt EdgeIt;
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    
+    /// \brief The type of the length of the edges.
+    typedef typename _Traits::LengthMap::Value Value;
+    /// \brief The type of the map that stores the edge lengths.
+    typedef typename _Traits::LengthMap LengthMap;
+    /// \brief The type of the map that stores the last
+    /// edges of the shortest paths.
+    typedef typename _Traits::PredMap PredMap;
+    /// \brief The type of the map that stores the dists of the nodes.
+    typedef typename _Traits::DistMap DistMap;
+    /// \brief The operation traits.
+    typedef typename _Traits::OperationTraits OperationTraits;
+    /// \brief The Node weight map.
+    typedef typename Graph::template NodeMap<Value> WeightMap;
+  private:
+    /// Pointer to the underlying graph
+    const Graph *graph;
+    /// Pointer to the length map
+    const LengthMap *length;
+    ///Pointer to the map of predecessors edges
+    PredMap *_pred;
+    ///Indicates if \ref _pred is locally allocated (\c true) or not
+    bool local_pred;
+    ///Pointer to the map of distances
+    DistMap *_dist;
+    ///Indicates if \ref _dist is locally allocated (\c true) or not
+    bool local_dist;
+    ///Process step counter
+    unsigned int _process_step;
+
+    std::vector<Node> _node_order;
+
+    /// Creates the maps if necessary.
+    void create_maps() {
+      if(!_pred) {
+	local_pred = true;
+	_pred = Traits::createPredMap(*graph);
+      }
+      if(!_dist) {
+	local_dist = true;
+	_dist = Traits::createDistMap(*graph);
+      }
+    }
+    
+  public :
+ 
+    typedef DagShortestPath Create;
+
+    /// \name Named template parameters
+
+    ///@{
+
+    template <class T>
+    struct DefPredMapTraits : public Traits {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph&) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting PredMap 
+    /// type
+    /// \ref named-templ-param "Named parameter" for setting PredMap type
+    ///
+    template <class T>
+    struct DefPredMap {
+      typedef DagShortestPath< Graph, LengthMap, DefPredMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefDistMapTraits : public Traits {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph& graph) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting DistMap 
+    /// type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting DistMap type
+    ///
+    template <class T>
+    struct DefDistMap 
+      : public DagShortestPath< Graph, LengthMap, DefDistMapTraits<T> > {
+      typedef DagShortestPath< Graph, LengthMap, DefDistMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefOperationTraitsTraits : public Traits {
+      typedef T OperationTraits;
+    };
+    
+    /// \brief \ref named-templ-param "Named parameter" for setting 
+    /// OperationTraits type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting OperationTraits
+    /// type
+    template <class T>
+    struct DefOperationTraits
+      : public DagShortestPath< Graph, LengthMap, DefOperationTraitsTraits<T> > {
+      typedef DagShortestPath< Graph, LengthMap, DefOperationTraitsTraits<T> >
+      Create;
+    };
+    
+    ///@}
+
+  protected:
+    
+    DagShortestPath() {}
+
+  public:      
+    
+    /// \brief Constructor.
+    ///
+    /// \param _graph the graph the algorithm will run on.
+    /// \param _length the length map used by the algorithm.
+    DagShortestPath(const Graph& _graph, const LengthMap& _length) :
+      graph(&_graph), length(&_length),
+      _pred(0), local_pred(false),
+      _dist(0), local_dist(false){}
+
+    /// \brief Constructor with node weight map.
+    ///
+    /// \param _graph the graph the algorithm will run on.
+    /// \param _length the length map used by the algorithm.
+    /// The NodeMap _length will be used as the weight map.
+    /// Each edge will have the weight of its target node.
+    DagShortestPath(const Graph& _graph, const WeightMap& _length) :
+      graph(&_graph),
+      _pred(0), local_pred(false),
+      _dist(0), local_dist(false){
+      length=new LengthMap(_graph);
+      _dist=new DistMap(_graph);
+      for(EdgeIt eit(_graph);eit!=INVALID;++eit)
+	(const_cast<LengthMap*>(length))->set(eit,_length[_graph.target(eit)]);
+      }
+
+    ///Destructor.
+    ~DagShortestPath() {
+      if(local_pred) delete _pred;
+      if(local_dist) delete _dist;
+    }
+
+    /// \brief Sets the length map.
+    ///
+    /// Sets the length map.
+    /// \return \c (*this)
+    DagShortestPath &lengthMap(const LengthMap &m) {
+      length = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the predecessor edges.
+    ///
+    /// Sets the map storing the predecessor edges.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    DagShortestPath &predMap(PredMap &m) {
+      if(local_pred) {
+	delete _pred;
+	local_pred=false;
+      }
+      _pred = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the distances calculated by the algorithm.
+    ///
+    /// Sets the map storing the distances calculated by the algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    DagShortestPath &distMap(DistMap &m) {
+      if(local_dist) {
+	delete _dist;
+	local_dist=false;
+      }
+      _dist = &m;
+      return *this;
+    }
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run(...)
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init(...), then you can add several source
+    /// nodes with \ref addSource().
+    /// Finally \ref start() will perform the actual path computation.
+    /// Some functions have an alternative form (\ref checkedInit(...),
+    /// \ref checkedRun(...)) which also verifies if the graph given in the
+    /// constructor is a dag.
+
+    ///@{
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    void init(const Value value = OperationTraits::infinity()) {
+      typedef typename Graph::template NodeMap<int> NodeOrderMap;
+      _process_step=0;
+      NodeOrderMap node_order(*graph);
+      topologicalSort(*graph,node_order);
+      _node_order.resize(countNodes(*graph),INVALID);
+      create_maps();
+      for (NodeIt it(*graph); it != INVALID; ++it) {
+        _node_order[node_order[it]]=it;
+        _pred->set(it, INVALID);
+        _dist->set(it, value);
+      }
+    }
+
+    /// \brief Initializes the internal data structures
+    /// with a given topological sort (NodeMap).
+    ///
+    /// Initializes the internal data structures
+    /// with a given topological sort (NodeMap).
+    void init(const typename Graph::template NodeMap<int>& node_order,
+         const Value value = OperationTraits::infinity()) {
+      _process_step=0;
+      _node_order.resize(countNodes(*graph),INVALID);
+      create_maps();
+      for (NodeIt it(*graph); it != INVALID; ++it) {
+        _node_order[node_order[it]]=it;
+        _pred->set(it, INVALID);
+        _dist->set(it, value);
+      }
+    }
+
+    /// \brief Initializes the internal data structures
+    /// with a given topological sort (std::vector).
+    ///
+    /// Initializes the internal data structures
+    /// with a given topological sort (std::vector).
+    void init(const std::vector<Node>& node_order,
+        const Value value = OperationTraits::infinity()) {
+      _process_step=0;
+      _node_order=node_order;
+      create_maps();
+      for (NodeIt it(*graph); it != INVALID; ++it) {
+        _pred->set(it, INVALID);
+        _dist->set(it, value);
+      }
+    }
+
+    /// \brief Initializes the internal data structures. It also checks if the graph is dag.
+    ///
+    /// Initializes the internal data structures. It also checks if the graph is dag.
+    /// \return true if the graph (given in the constructor) is dag, false otherwise.
+    bool checkedInit(const Value value = OperationTraits::infinity()) {
+      typedef typename Graph::template NodeMap<int> NodeOrderMap;
+      NodeOrderMap node_order(*graph);
+      if(!checkedTopologicalSort(*graph,node_order))return false;
+      init(node_order,value);
+      return true;
+    }
+
+    /// \brief Initializes the internal data structures with a given
+    /// topological sort (NodeMap). It also checks if the graph is dag.
+    ///
+    /// Initializes the internal data structures with a given
+    /// topological sort (NodeMap). It also checks if the graph is dag.
+    /// \return true if the graph (given in the constructor) is dag, false otherwise.
+    bool checkedInit(const typename Graph::template NodeMap<int>& node_order, 
+                     const Value value = OperationTraits::infinity()) {
+      for(NodeIt it(*graph);it!=INVALID;++it){
+        for(OutEdgeIt oeit(*graph,it);oeit!=INVALID;++oeit){
+          if(node_order[graph->target(oeit)]<node_order[it])return false;
+        }
+      }
+      init(node_order,value);
+      return true;
+    }
+
+    /// \brief Initializes the internal data structures with a given
+    /// topological sort (std::vector). It also checks if the graph is dag.
+    ///
+    /// Initializes the internal data structures with a given
+    /// topological sort (std::vector). It also checks if the graph is dag.
+    /// \return true if the graph (given in the constructor) is dag, false otherwise.
+    bool checkedInit(const std::vector<Node>& node_order, 
+                     const Value value = OperationTraits::infinity()) {
+      typedef typename Graph::template NodeMap<bool> BoolNodeMap;
+      BoolNodeMap _processed(*graph,false);
+      for(unsigned int i=0;i<_node_order.size();++i){
+        _processed[node_order[i]]=true;
+        for(OutEdgeIt oeit(*graph,node_order[i]);oeit!=INVALID;++oeit){
+          if(_processed[graph->target(oeit)])return false;
+        }
+      }
+      init(node_order,value);
+      return true;
+    }
+
+    /// \brief Adds a new source node.
+    ///
+    /// The optional second parameter is the initial distance of the node.
+    /// It just sets the distance of the node to the given value.
+    void addSource(Node source, Value dst = OperationTraits::zero()) {
+      if((*_dist)[source] != dst){
+        _dist->set(source, dst);
+      }
+    }
+
+    /// \brief Executes one step from the dag shortest path algorithm.
+    ///
+    /// If the algoritm calculated the distances in the previous step 
+    /// strictly for all at most k length paths then it will calculate the 
+    /// distances strictly for all at most k + 1 length paths. With k
+    /// iteration this function calculates the at most k length paths.
+    ///\pre the queue is not empty
+    ///\return the currently processed node
+    Node processNextNode() {
+      if(reached(_node_order[_process_step])){
+        for (OutEdgeIt it(*graph, _node_order[_process_step]); it != INVALID; ++it) {
+	  Node target = graph->target(it);
+	  Value relaxed =
+	    OperationTraits::plus((*_dist)[_node_order[_process_step]], (*length)[it]);
+	  if (OperationTraits::less(relaxed, (*_dist)[target])) {
+	    _pred->set(target, it);
+	    _dist->set(target, relaxed);
+	  }
+        }
+      }
+      ++_process_step;
+      return _node_order[_process_step-1];
+    }
+
+    ///\brief Returns \c false if there are nodes
+    ///to be processed in the queue
+    ///
+    ///Returns \c false if there are nodes
+    ///to be processed in the queue
+    bool emptyQueue() { return _node_order.size()-1==_process_step; }
+
+    ///\brief Returns the number of the nodes to be processed.
+    ///
+    ///Returns the number of the nodes to be processed in the queue.
+    int queueSize() { return _node_order.size()-1-_process_step; }
+
+    /// \brief Executes the algorithm.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    ///
+    /// This method runs the %DagShortestPath algorithm from the root node(s)
+    /// in order to compute the shortest path to each node. The algorithm 
+    /// computes 
+    /// - The shortest path tree.
+    /// - The distance of each node from the root(s).
+    void start() {
+      while(!emptyQueue()) {
+	processNextNode();
+      }
+    }
+
+    /// \brief Runs %DagShortestPath algorithm from node \c s.
+    ///    
+    /// This method runs the %DagShortestPath algorithm from a root node \c s
+    /// in order to compute the shortest path to each node. The algorithm 
+    /// computes
+    /// - The shortest path tree.
+    /// - The distance of each node from the root.
+    ///
+    /// \note d.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.addSource(s);
+    ///  d.start();
+    ///\endcode
+    void run(Node s) {
+      init();
+      addSource(s);
+      start();
+    }
+    
+    /// \brief Runs %DagShortestPath algorithm from node \c s.
+    /// It also checks if the graph is a dag.
+    ///    
+    /// This method runs the %DagShortestPath algorithm from a root node \c s
+    /// in order to compute the shortest path to each node. The algorithm 
+    /// computes
+    /// - The shortest path tree.
+    /// - The distance of each node from the root.
+    /// The algorithm checks if the graph given int the constructor is a dag.
+    bool checkedRun(Node s) {
+      if(!checkedInit())return false;
+      addSource(s);
+      start();
+      return true;
+    }
+    
+    ///@}
+
+    /// \name Query Functions
+    /// The result of the %DagShortestPath algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    typedef PredMapPath<Graph, PredMap> Path;
+
+    ///Gives back the shortest path.
+    
+    ///Gives back the shortest path.
+    ///\pre The \c t should be reachable from the source.
+    Path path(Node t) 
+    {
+      return Path(*graph, *_pred, t);
+    }
+	  
+    /// \brief The distance of a node from the root.
+    ///
+    /// Returns the distance of a node from the root.
+    /// \pre \ref run() must be called before using this function.
+    /// \warning If node \c v in unreachable from the root the return value
+    /// of this funcion is undefined.
+    Value dist(Node v) const { return (*_dist)[v]; }
+
+    /// \brief Returns the 'previous edge' of the shortest path tree.
+    ///
+    /// For a node \c v it returns the 'previous edge' of the shortest path 
+    /// tree, i.e. it returns the last edge of a shortest path from the root 
+    /// to \c v. It is \ref INVALID if \c v is unreachable from the root or 
+    /// if \c v=s. The shortest path tree used here is equal to the shortest 
+    /// path tree used in \ref predNode(). 
+    /// \pre \ref run() must be called before using
+    /// this function.
+    Edge predEdge(Node v) const { return (*_pred)[v]; }
+
+    /// \brief Returns the 'previous node' of the shortest path tree.
+    ///
+    /// For a node \c v it returns the 'previous node' of the shortest path 
+    /// tree, i.e. it returns the last but one node from a shortest path from 
+    /// the root to \c /v. It is INVALID if \c v is unreachable from the root 
+    /// or if \c v=s. The shortest path tree used here is equal to the 
+    /// shortest path tree used in \ref predEdge().  \pre \ref run() must be 
+    /// called before using this function.
+    Node predNode(Node v) const { 
+      return (*_pred)[v] == INVALID ? INVALID : graph->source((*_pred)[v]); 
+    }
+    
+    /// \brief Returns a reference to the NodeMap of distances.
+    ///
+    /// Returns a reference to the NodeMap of distances. \pre \ref run() must
+    /// be called before using this function.
+    const DistMap &distMap() const { return *_dist;}
+ 
+    /// \brief Returns a reference to the shortest path tree map.
+    ///
+    /// Returns a reference to the NodeMap of the edges of the
+    /// shortest path tree.
+    /// \pre \ref run() must be called before using this function.
+    const PredMap &predMap() const { return *_pred; }
+ 
+    /// \brief Checks if a node is reachable from the root.
+    ///
+    /// Returns \c true if \c v is reachable from the root.
+    /// \pre \ref run() must be called before using this function.
+    ///
+    bool reached(Node v) { return (*_dist)[v] != OperationTraits::infinity(); }
+    
+    ///@}
+  };
+ 
+  /// \brief Default traits class of DagShortestPath function.
+  ///
+  /// Default traits class of DagShortestPath function.
+  /// \param _Graph Graph type.
+  /// \param _LengthMap Type of length map.
+  template <typename _Graph, typename _LengthMap>
+  struct DagShortestPathWizardDefaultTraits {
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge lengths.
+    ///
+    /// The type of the map that stores the edge lengths.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _LengthMap LengthMap;
+
+    /// \brief The value type of the length map.
+    typedef typename _LengthMap::Value Value;
+
+    /// \brief Operation traits for dag shortest path algorithm.
+    ///
+    /// It defines the infinity type on the given Value type
+    /// and the used operation.
+    /// \see DagShortestPathDefaultOperationTraits
+    typedef DagShortestPathDefaultOperationTraits<Value> OperationTraits;
+
+    /// \brief The type of the map that stores the last
+    /// edges of the shortest paths.
+    /// 
+    /// The type of the map that stores the last
+    /// edges of the shortest paths.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    typedef NullMap <typename _Graph::Node,typename _Graph::Edge> PredMap;
+
+    /// \brief Instantiates a PredMap.
+    /// 
+    /// This function instantiates a \ref PredMap. 
+    static PredMap *createPredMap(const _Graph &) {
+      return new PredMap();
+    }
+    /// \brief The type of the map that stores the dists of the nodes.
+    ///
+    /// The type of the map that stores the dists of the nodes.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    typedef NullMap<typename Graph::Node, Value> DistMap;
+    /// \brief Instantiates a DistMap.
+    ///
+    /// This function instantiates a \ref DistMap. 
+    static DistMap *createDistMap(const _Graph &) {
+      return new DistMap();
+    }
+  };
+  
+  /// \brief Default traits used by \ref DagShortestPathWizard
+  ///
+  /// To make it easier to use DagShortestPath algorithm
+  /// we have created a wizard class.
+  /// This \ref DagShortestPathWizard class needs default traits,
+  /// as well as the \ref DagShortestPath class.
+  /// The \ref DagShortestPathWizardBase is a class to be the default traits of the
+  /// \ref DagShortestPathWizard class.
+  /// \todo More named parameters are required...
+  template<class _Graph,class _LengthMap>
+  class DagShortestPathWizardBase 
+    : public DagShortestPathWizardDefaultTraits<_Graph,_LengthMap> {
+
+    typedef DagShortestPathWizardDefaultTraits<_Graph,_LengthMap> Base;
+  protected:
+    /// Type of the nodes in the graph.
+    typedef typename Base::Graph::Node Node;
+
+    /// Pointer to the underlying graph.
+    void *_graph;
+    /// Pointer to the length map
+    void *_length;
+    ///Pointer to the map of predecessors edges.
+    void *_pred;
+    ///Pointer to the map of distances.
+    void *_dist;
+    ///Pointer to the source node.
+    Node _source;
+
+    public:
+    /// Constructor.
+    
+    /// This constructor does not require parameters, therefore it initiates
+    /// all of the attributes to default values (0, INVALID).
+    DagShortestPathWizardBase() : _graph(0), _length(0), _pred(0),
+			   _dist(0), _source(INVALID) {}
+
+    /// Constructor.
+    
+    /// This constructor requires some parameters,
+    /// listed in the parameters list.
+    /// Others are initiated to 0.
+    /// \param graph is the initial value of  \ref _graph
+    /// \param length is the initial value of  \ref _length
+    /// \param source is the initial value of  \ref _source
+    DagShortestPathWizardBase(const _Graph& graph, 
+			  const _LengthMap& length, 
+			  Node source = INVALID) :
+      _graph((void *)&graph), _length((void *)&length), _pred(0),
+      _dist(0), _source(source) {}
+
+  };
+  
+  /// A class to make the usage of DagShortestPath algorithm easier
+
+  /// This class is created to make it easier to use DagShortestPath algorithm.
+  /// It uses the functions and features of the plain \ref DagShortestPath,
+  /// but it is much simpler to use it.
+  ///
+  /// Simplicity means that the way to change the types defined
+  /// in the traits class is based on functions that returns the new class
+  /// and not on templatable built-in classes.
+  /// When using the plain \ref DagShortestPath
+  /// the new class with the modified type comes from
+  /// the original class by using the ::
+  /// operator. In the case of \ref DagShortestPathWizard only
+  /// a function have to be called and it will
+  /// return the needed class.
+  ///
+  /// It does not have own \ref run method. When its \ref run method is called
+  /// it initiates a plain \ref DagShortestPath class, and calls the \ref 
+  /// DagShortestPath::run() method of it.
+  template<class _Traits>
+  class DagShortestPathWizard : public _Traits {
+    typedef _Traits Base;
+
+    ///The type of the underlying graph.
+    typedef typename _Traits::Graph Graph;
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::OutEdgeIt EdgeIt;
+    
+    ///The type of the map that stores the edge lengths.
+    typedef typename _Traits::LengthMap LengthMap;
+
+    ///The type of the length of the edges.
+    typedef typename LengthMap::Value Value;
+
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    typedef typename _Traits::PredMap PredMap;
+
+    ///The type of the map that stores the dists of the nodes.
+    typedef typename _Traits::DistMap DistMap;
+
+  public:
+    /// Constructor.
+    DagShortestPathWizard() : _Traits() {}
+
+    /// \brief Constructor that requires parameters.
+    ///
+    /// Constructor that requires parameters.
+    /// These parameters will be the default values for the traits class.
+    DagShortestPathWizard(const Graph& graph, const LengthMap& length, 
+		      Node source = INVALID) 
+      : _Traits(graph, length, source) {}
+
+    /// \brief Copy constructor
+    DagShortestPathWizard(const _Traits &b) : _Traits(b) {}
+
+    ~DagShortestPathWizard() {}
+
+    /// \brief Runs DagShortestPath algorithm from a given node.
+    ///    
+    /// Runs DagShortestPath algorithm from a given node.
+    /// The node can be given by the \ref source function.
+    void run() {
+      if(Base::_source == INVALID) throw UninitializedParameter();
+      DagShortestPath<Graph,LengthMap,_Traits> 
+	bf(*(Graph*)Base::_graph, *(LengthMap*)Base::_length);
+      if (Base::_pred) bf.predMap(*(PredMap*)Base::_pred);
+      if (Base::_dist) bf.distMap(*(DistMap*)Base::_dist);
+      bf.run(Base::_source);
+    }
+
+    /// \brief Runs DagShortestPath algorithm from the given node.
+    ///
+    /// Runs DagShortestPath algorithm from the given node.
+    /// \param source is the given source.
+    void run(Node source) {
+      Base::_source = source;
+      run();
+    }
+
+    template<class T>
+    struct DefPredMapBase : public Base {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph &) { return 0; };
+      DefPredMapBase(const _Traits &b) : _Traits(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting PredMap type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting PredMap type
+    ///
+    template<class T>
+    DagShortestPathWizard<DefPredMapBase<T> > predMap(const T &t) 
+    {
+      Base::_pred=(void *)&t;
+      return DagShortestPathWizard<DefPredMapBase<T> >(*this);
+    }
+    
+    template<class T>
+    struct DefDistMapBase : public Base {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph &) { return 0; };
+      DefDistMapBase(const _Traits &b) : _Traits(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    template<class T>
+    DagShortestPathWizard<DefDistMapBase<T> > distMap(const T &t) {
+      Base::_dist=(void *)&t;
+      return DagShortestPathWizard<DefDistMapBase<T> >(*this);
+    }
+
+    template<class T>
+    struct DefOperationTraitsBase : public Base {
+      typedef T OperationTraits;
+      DefOperationTraitsBase(const _Traits &b) : _Traits(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting OperationTraits type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting OperationTraits type
+    ///
+    template<class T>
+    DagShortestPathWizard<DefOperationTraitsBase<T> > distMap() {
+      return DagShortestPathWizard<DefDistMapBase<T> >(*this);
+    }
+    
+    /// \brief Sets the source node, from which the DagShortestPath algorithm runs.
+    ///
+    /// Sets the source node, from which the DagShortestPath algorithm runs.
+    /// \param source is the source node.
+    DagShortestPathWizard<_Traits>& source(Node source) {
+      Base::_source = source;
+      return *this;
+    }
+    
+  };
+  
+  /// \brief Function type interface for DagShortestPath algorithm.
+  ///
+  /// \ingroup flowalgs
+  /// Function type interface for DagShortestPath algorithm.
+  ///
+  /// This function also has several \ref named-templ-func-param 
+  /// "named parameters", they are declared as the members of class 
+  /// \ref DagShortestPathWizard.
+  /// The following
+  /// example shows how to use these parameters.
+  ///\code
+  /// dagShortestPath(g,length,source).predMap(preds).run();
+  ///\endcode
+  /// \warning Don't forget to put the \ref DagShortestPathWizard::run() "run()"
+  /// to the end of the parameter list.
+  /// \sa DagShortestPathWizard
+  /// \sa DagShortestPath
+  template<class _Graph, class _LengthMap>
+  DagShortestPathWizard<DagShortestPathWizardBase<_Graph,_LengthMap> >
+  dagShortestPath(const _Graph& graph,
+	      const _LengthMap& length, 
+	      typename _Graph::Node source = INVALID) {
+    return DagShortestPathWizard<DagShortestPathWizardBase<_Graph,_LengthMap> >
+      (graph, length, source);
+  }
+
+} //END OF NAMESPACE LEMON
+
+#endif
+
Index: lemon/dfs.h
===================================================================
--- lemon/dfs.h	(revision 2611)
+++ lemon/dfs.h	(revision 2611)
@@ -0,0 +1,1543 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_DFS_H
+#define LEMON_DFS_H
+
+///\ingroup search
+///\file
+///\brief Dfs algorithm.
+
+#include <lemon/list_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/bits/path_dump.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+
+#include <lemon/concept_check.h>
+
+namespace lemon {
+
+  
+  ///Default traits class of Dfs class.
+
+  ///Default traits class of Dfs class.
+  ///\param GR Graph type.
+  template<class GR>
+  struct DfsDefaultTraits
+  {
+    ///The graph type the algorithm runs on. 
+    typedef GR Graph;
+    ///\brief The type of the map that stores the last
+    ///edges of the %DFS paths.
+    /// 
+    ///The type of the map that stores the last
+    ///edges of the %DFS paths.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename GR::Edge> PredMap;
+    ///Instantiates a PredMap.
+ 
+    ///This function instantiates a \ref PredMap. 
+    ///\param G is the graph, to which we would like to define the PredMap.
+    ///\todo The graph alone may be insufficient to initialize
+    static PredMap *createPredMap(const GR &G) 
+    {
+      return new PredMap(G);
+    }
+
+    ///The type of the map that indicates which nodes are processed.
+ 
+    ///The type of the map that indicates which nodes are processed.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef NullMap<typename Graph::Node,bool> ProcessedMap;
+    ///Instantiates a ProcessedMap.
+ 
+    ///This function instantiates a \ref ProcessedMap. 
+    ///\param g is the graph, to which
+    ///we would like to define the \ref ProcessedMap
+#ifdef DOXYGEN
+    static ProcessedMap *createProcessedMap(const GR &g)
+#else
+    static ProcessedMap *createProcessedMap(const GR &)
+#endif
+    {
+      return new ProcessedMap();
+    }
+    ///The type of the map that indicates which nodes are reached.
+ 
+    ///The type of the map that indicates which nodes are reached.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef typename Graph::template NodeMap<bool> ReachedMap;
+    ///Instantiates a ReachedMap.
+ 
+    ///This function instantiates a \ref ReachedMap. 
+    ///\param G is the graph, to which
+    ///we would like to define the \ref ReachedMap.
+    static ReachedMap *createReachedMap(const GR &G)
+    {
+      return new ReachedMap(G);
+    }
+    ///The type of the map that stores the dists of the nodes.
+ 
+    ///The type of the map that stores the dists of the nodes.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<int> DistMap;
+    ///Instantiates a DistMap.
+ 
+    ///This function instantiates a \ref DistMap. 
+    ///\param G is the graph, to which we would like to define the \ref DistMap
+    static DistMap *createDistMap(const GR &G)
+    {
+      return new DistMap(G);
+    }
+  };
+  
+  ///%DFS algorithm class.
+  
+  ///\ingroup search
+  ///This class provides an efficient implementation of the %DFS algorithm.
+  ///
+  ///\param GR The graph type the algorithm runs on. The default value is
+  ///\ref ListGraph. The value of GR is not used directly by Dfs, it
+  ///is only passed to \ref DfsDefaultTraits.
+  ///\param TR Traits class to set various data types used by the algorithm.
+  ///The default traits class is
+  ///\ref DfsDefaultTraits "DfsDefaultTraits<GR>".
+  ///See \ref DfsDefaultTraits for the documentation of
+  ///a Dfs traits class.
+  ///
+  ///\author Jacint Szabo and Alpar Juttner
+#ifdef DOXYGEN
+  template <typename GR,
+	    typename TR>
+#else
+  template <typename GR=ListGraph,
+	    typename TR=DfsDefaultTraits<GR> >
+#endif
+  class Dfs {
+  public:
+    /**
+     * \brief \ref Exception for uninitialized parameters.
+     *
+     * This error represents problems in the initialization
+     * of the parameters of the algorithms.
+     */
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::Dfs::UninitializedParameter";
+      }
+    };
+
+    typedef TR Traits;
+    ///The type of the underlying graph.
+    typedef typename TR::Graph Graph;
+    ///\e
+    typedef typename Graph::Node Node;
+    ///\e
+    typedef typename Graph::NodeIt NodeIt;
+    ///\e
+    typedef typename Graph::Edge Edge;
+    ///\e
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    
+    ///\brief The type of the map that stores the last
+    ///edges of the %DFS paths.
+    typedef typename TR::PredMap PredMap;
+    ///The type of the map indicating which nodes are reached.
+    typedef typename TR::ReachedMap ReachedMap;
+    ///The type of the map indicating which nodes are processed.
+    typedef typename TR::ProcessedMap ProcessedMap;
+    ///The type of the map that stores the dists of the nodes.
+    typedef typename TR::DistMap DistMap;
+  private:
+    /// Pointer to the underlying graph.
+    const Graph *G;
+    ///Pointer to the map of predecessors edges.
+    PredMap *_pred;
+    ///Indicates if \ref _pred is locally allocated (\c true) or not.
+    bool local_pred;
+    ///Pointer to the map of distances.
+    DistMap *_dist;
+    ///Indicates if \ref _dist is locally allocated (\c true) or not.
+    bool local_dist;
+    ///Pointer to the map of reached status of the nodes.
+    ReachedMap *_reached;
+    ///Indicates if \ref _reached is locally allocated (\c true) or not.
+    bool local_reached;
+    ///Pointer to the map of processed status of the nodes.
+    ProcessedMap *_processed;
+    ///Indicates if \ref _processed is locally allocated (\c true) or not.
+    bool local_processed;
+
+    std::vector<typename Graph::OutEdgeIt> _stack;
+    int _stack_head;
+
+    ///Creates the maps if necessary.
+    
+    ///\todo Better memory allocation (instead of new).
+    void create_maps() 
+    {
+      if(!_pred) {
+	local_pred = true;
+	_pred = Traits::createPredMap(*G);
+      }
+      if(!_dist) {
+	local_dist = true;
+	_dist = Traits::createDistMap(*G);
+      }
+      if(!_reached) {
+	local_reached = true;
+	_reached = Traits::createReachedMap(*G);
+      }
+      if(!_processed) {
+	local_processed = true;
+	_processed = Traits::createProcessedMap(*G);
+      }
+    }
+
+  protected:
+
+    Dfs() {}
+    
+  public:
+
+    typedef Dfs Create;
+
+    ///\name Named template parameters
+
+    ///@{
+
+    template <class T>
+    struct DefPredMapTraits : public Traits {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph &G) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///PredMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting PredMap type
+    ///
+    template <class T>
+    struct DefPredMap : public Dfs<Graph, DefPredMapTraits<T> > {
+      typedef Dfs<Graph, DefPredMapTraits<T> > Create;
+    };
+    
+    
+    template <class T>
+    struct DefDistMapTraits : public Traits {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///DistMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting DistMap
+    ///type
+    template <class T>
+    struct DefDistMap {
+      typedef Dfs<Graph, DefDistMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefReachedMapTraits : public Traits {
+      typedef T ReachedMap;
+      static ReachedMap *createReachedMap(const Graph &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///ReachedMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting ReachedMap type
+    ///
+    template <class T>
+    struct DefReachedMap : public Dfs< Graph, DefReachedMapTraits<T> > {
+      typedef Dfs< Graph, DefReachedMapTraits<T> > Create;
+    };
+
+    template <class T>
+    struct DefProcessedMapTraits : public Traits {
+      typedef T ProcessedMap;
+      static ProcessedMap *createProcessedMap(const Graph &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///ProcessedMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting ProcessedMap type
+    ///
+    template <class T>
+    struct DefProcessedMap : public Dfs< Graph, DefProcessedMapTraits<T> > { 
+      typedef Dfs< Graph, DefProcessedMapTraits<T> > Create;
+    };
+    
+    struct DefGraphProcessedMapTraits : public Traits {
+      typedef typename Graph::template NodeMap<bool> ProcessedMap;
+      static ProcessedMap *createProcessedMap(const Graph &G) 
+      {
+	return new ProcessedMap(G);
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter"
+    ///for setting the ProcessedMap type to be Graph::NodeMap<bool>.
+    ///
+    ///\ref named-templ-param "Named parameter"
+    ///for setting the ProcessedMap type to be Graph::NodeMap<bool>.
+    ///If you don't set it explicitely, it will be automatically allocated.
+    template <class T>
+    class DefProcessedMapToBeDefaultMap :
+      public Dfs< Graph, DefGraphProcessedMapTraits> { 
+      typedef Dfs< Graph, DefGraphProcessedMapTraits> Create;
+    };
+    
+    ///@}
+
+  public:      
+    
+    ///Constructor.
+    
+    ///\param _G the graph the algorithm will run on.
+    ///
+    Dfs(const Graph& _G) :
+      G(&_G),
+      _pred(NULL), local_pred(false),
+      _dist(NULL), local_dist(false),
+      _reached(NULL), local_reached(false),
+      _processed(NULL), local_processed(false)
+    { }
+    
+    ///Destructor.
+    ~Dfs() 
+    {
+      if(local_pred) delete _pred;
+      if(local_dist) delete _dist;
+      if(local_reached) delete _reached;
+      if(local_processed) delete _processed;
+    }
+
+    ///Sets the map storing the predecessor edges.
+
+    ///Sets the map storing the predecessor edges.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Dfs &predMap(PredMap &m) 
+    {
+      if(local_pred) {
+	delete _pred;
+	local_pred=false;
+      }
+      _pred = &m;
+      return *this;
+    }
+
+    ///Sets the map storing the distances calculated by the algorithm.
+
+    ///Sets the map storing the distances calculated by the algorithm.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Dfs &distMap(DistMap &m) 
+    {
+      if(local_dist) {
+	delete _dist;
+	local_dist=false;
+      }
+      _dist = &m;
+      return *this;
+    }
+
+    ///Sets the map indicating if a node is reached.
+
+    ///Sets the map indicating if a node is reached.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Dfs &reachedMap(ReachedMap &m) 
+    {
+      if(local_reached) {
+	delete _reached;
+	local_reached=false;
+      }
+      _reached = &m;
+      return *this;
+    }
+
+    ///Sets the map indicating if a node is processed.
+
+    ///Sets the map indicating if a node is processed.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Dfs &processedMap(ProcessedMap &m) 
+    {
+      if(local_processed) {
+	delete _processed;
+	local_processed=false;
+      }
+      _processed = &m;
+      return *this;
+    }
+
+  public:
+    ///\name Execution control
+    ///The simplest way to execute the algorithm is to use
+    ///one of the member functions called \c run(...).
+    ///\n
+    ///If you need more control on the execution,
+    ///first you must call \ref init(), then you can add a source node
+    ///with \ref addSource().
+    ///Finally \ref start() will perform the actual path
+    ///computation.
+
+    ///@{
+
+    ///Initializes the internal data structures.
+
+    ///Initializes the internal data structures.
+    ///
+    void init()
+    {
+      create_maps();
+      _stack.resize(countNodes(*G));
+      _stack_head=-1;
+      for ( NodeIt u(*G) ; u!=INVALID ; ++u ) {
+	_pred->set(u,INVALID);
+	// _predNode->set(u,INVALID);
+	_reached->set(u,false);
+	_processed->set(u,false);
+      }
+    }
+    
+    ///Adds a new source node.
+
+    ///Adds a new source node to the set of nodes to be processed.
+    ///
+    ///\warning dists are wrong (or at least strange)
+    ///in case of multiple sources.
+    void addSource(Node s)
+    {
+      if(!(*_reached)[s])
+	{
+	  _reached->set(s,true);
+	  _pred->set(s,INVALID);
+	  OutEdgeIt e(*G,s);
+	  if(e!=INVALID) {
+	    _stack[++_stack_head]=e;
+	    _dist->set(s,_stack_head);
+	  }
+	  else {
+	    _processed->set(s,true);
+	    _dist->set(s,0);
+	  }
+	}
+    }
+    
+    ///Processes the next edge.
+
+    ///Processes the next edge.
+    ///
+    ///\return The processed edge.
+    ///
+    ///\pre The stack must not be empty!
+    Edge processNextEdge()
+    { 
+      Node m;
+      Edge e=_stack[_stack_head];
+      if(!(*_reached)[m=G->target(e)]) {
+	_pred->set(m,e);
+	_reached->set(m,true);
+	++_stack_head;
+	_stack[_stack_head] = OutEdgeIt(*G, m);
+	_dist->set(m,_stack_head);
+      }
+      else {
+	m=G->source(e);
+	++_stack[_stack_head];
+      }
+      while(_stack_head>=0 && _stack[_stack_head]==INVALID) {
+	_processed->set(m,true);
+	--_stack_head;
+	if(_stack_head>=0) {
+	  m=G->source(_stack[_stack_head]);
+	  ++_stack[_stack_head];
+	}
+      }
+      return e;
+    }
+    ///Next edge to be processed.
+
+    ///Next edge to be processed.
+    ///
+    ///\return The next edge to be processed or INVALID if the stack is
+    /// empty.
+    OutEdgeIt nextEdge()
+    { 
+      return _stack_head>=0?_stack[_stack_head]:INVALID;
+    }
+
+    ///\brief Returns \c false if there are nodes
+    ///to be processed in the queue
+    ///
+    ///Returns \c false if there are nodes
+    ///to be processed in the queue
+    bool emptyQueue() { return _stack_head<0; }
+    ///Returns the number of the nodes to be processed.
+    
+    ///Returns the number of the nodes to be processed in the queue.
+    int queueSize() { return _stack_head+1; }
+    
+    ///Executes the algorithm.
+
+    ///Executes the algorithm.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///This method runs the %DFS algorithm from the root node(s)
+    ///in order to
+    ///compute the
+    ///%DFS path to each node. The algorithm computes
+    ///- The %DFS tree.
+    ///- The distance of each node from the root(s) in the %DFS tree.
+    ///
+    void start()
+    {
+      while ( !emptyQueue() ) processNextEdge();
+    }
+    
+    ///Executes the algorithm until \c dest is reached.
+
+    ///Executes the algorithm until \c dest is reached.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///This method runs the %DFS algorithm from the root node(s)
+    ///in order to
+    ///compute the
+    ///%DFS path to \c dest. The algorithm computes
+    ///- The %DFS path to \c  dest.
+    ///- The distance of \c dest from the root(s) in the %DFS tree.
+    ///
+    void start(Node dest)
+    {
+      while ( !emptyQueue() && G->target(_stack[_stack_head])!=dest ) 
+	processNextEdge();
+    }
+    
+    ///Executes the algorithm until a condition is met.
+
+    ///Executes the algorithm until a condition is met.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///\param em must be a bool (or convertible) edge map. The algorithm
+    ///will stop when it reaches an edge \c e with <tt>em[e]</tt> true.
+    ///
+    ///\return The reached edge \c e with <tt>em[e]</tt> true or
+    ///\c INVALID if no such edge was found.
+    ///
+    ///\warning Contrary to \ref Bfs and \ref Dijkstra, \c em is an edge map,
+    ///not a node map.
+    template<class EM>
+    Edge start(const EM &em)
+    {
+      while ( !emptyQueue() && !em[_stack[_stack_head]] )
+        processNextEdge();
+      return emptyQueue() ? INVALID : _stack[_stack_head];
+    }
+
+    ///Runs %DFS algorithm to visit all nodes in the graph.
+    
+    ///This method runs the %DFS algorithm in order to
+    ///compute the
+    ///%DFS path to each node. The algorithm computes
+    ///- The %DFS tree.
+    ///- The distance of each node from the root in the %DFS tree.
+    ///
+    ///\note d.run() is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  for (NodeIt it(graph); it != INVALID; ++it) {
+    ///    if (!d.reached(it)) {
+    ///      d.addSource(it);
+    ///      d.start();
+    ///    }
+    ///  }
+    ///\endcode
+    void run() {
+      init();
+      for (NodeIt it(*G); it != INVALID; ++it) {
+        if (!reached(it)) {
+          addSource(it);
+          start();
+        }
+      }
+    }
+
+    ///Runs %DFS algorithm from node \c s.
+    
+    ///This method runs the %DFS algorithm from a root node \c s
+    ///in order to
+    ///compute the
+    ///%DFS path to each node. The algorithm computes
+    ///- The %DFS tree.
+    ///- The distance of each node from the root in the %DFS tree.
+    ///
+    ///\note d.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.addSource(s);
+    ///  d.start();
+    ///\endcode
+    void run(Node s) {
+      init();
+      addSource(s);
+      start();
+    }
+    
+    ///Finds the %DFS path between \c s and \c t.
+    
+    ///Finds the %DFS path between \c s and \c t.
+    ///
+    ///\return The length of the %DFS s---t path if there exists one,
+    ///0 otherwise.
+    ///\note Apart from the return value, d.run(s,t) is
+    ///just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.addSource(s);
+    ///  d.start(t);
+    ///\endcode
+    int run(Node s,Node t) {
+      init();
+      addSource(s);
+      start(t);
+      return reached(t)?_stack_head+1:0;
+    }
+    
+    ///@}
+
+    ///\name Query Functions
+    ///The result of the %DFS algorithm can be obtained using these
+    ///functions.\n
+    ///Before the use of these functions,
+    ///either run() or start() must be called.
+    
+    ///@{
+
+    typedef PredMapPath<Graph, PredMap> Path;
+
+    ///Gives back the shortest path.
+    
+    ///Gives back the shortest path.
+    ///\pre The \c t should be reachable from the source.
+    Path path(Node t) 
+    {
+      return Path(*G, *_pred, t);
+    }
+
+    ///The distance of a node from the root(s).
+
+    ///Returns the distance of a node from the root(s).
+    ///\pre \ref run() must be called before using this function.
+    ///\warning If node \c v is unreachable from the root(s) then the return 
+    ///value of this funcion is undefined.
+    int dist(Node v) const { return (*_dist)[v]; }
+
+    ///Returns the 'previous edge' of the %DFS tree.
+
+    ///For a node \c v it returns the 'previous edge'
+    ///of the %DFS path,
+    ///i.e. it returns the last edge of a %DFS path from the root(s) to \c
+    ///v. It is \ref INVALID
+    ///if \c v is unreachable from the root(s) or \c v is a root. The
+    ///%DFS tree used here is equal to the %DFS tree used in
+    ///\ref predNode().
+    ///\pre Either \ref run() or \ref start() must be called before using
+    ///this function.
+    Edge predEdge(Node v) const { return (*_pred)[v];}
+
+    ///Returns the 'previous node' of the %DFS tree.
+
+    ///For a node \c v it returns the 'previous node'
+    ///of the %DFS tree,
+    ///i.e. it returns the last but one node from a %DFS path from the
+    ///root(s) to \c v.
+    ///It is INVALID if \c v is unreachable from the root(s) or
+    ///if \c v itself a root.
+    ///The %DFS tree used here is equal to the %DFS
+    ///tree used in \ref predEdge().
+    ///\pre Either \ref run() or \ref start() must be called before
+    ///using this function.
+    Node predNode(Node v) const { return (*_pred)[v]==INVALID ? INVALID:
+				  G->source((*_pred)[v]); }
+    
+    ///Returns a reference to the NodeMap of distances.
+
+    ///Returns a reference to the NodeMap of distances.
+    ///\pre Either \ref run() or \ref init() must
+    ///be called before using this function.
+    const DistMap &distMap() const { return *_dist;}
+ 
+    ///Returns a reference to the %DFS edge-tree map.
+
+    ///Returns a reference to the NodeMap of the edges of the
+    ///%DFS tree.
+    ///\pre Either \ref run() or \ref init()
+    ///must be called before using this function.
+    const PredMap &predMap() const { return *_pred;}
+ 
+    ///Checks if a node is reachable from the root.
+
+    ///Returns \c true if \c v is reachable from the root(s).
+    ///\warning The source nodes are inditated as unreachable.
+    ///\pre Either \ref run() or \ref start()
+    ///must be called before using this function.
+    ///
+    bool reached(Node v) { return (*_reached)[v]; }
+    
+    ///@}
+  };
+
+  ///Default traits class of Dfs function.
+
+  ///Default traits class of Dfs function.
+  ///\param GR Graph type.
+  template<class GR>
+  struct DfsWizardDefaultTraits
+  {
+    ///The graph type the algorithm runs on. 
+    typedef GR Graph;
+    ///\brief The type of the map that stores the last
+    ///edges of the %DFS paths.
+    /// 
+    ///The type of the map that stores the last
+    ///edges of the %DFS paths.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef NullMap<typename Graph::Node,typename GR::Edge> PredMap;
+    ///Instantiates a PredMap.
+ 
+    ///This function instantiates a \ref PredMap. 
+    ///\param g is the graph, to which we would like to define the PredMap.
+    ///\todo The graph alone may be insufficient to initialize
+#ifdef DOXYGEN
+    static PredMap *createPredMap(const GR &g) 
+#else
+    static PredMap *createPredMap(const GR &) 
+#endif
+    {
+      return new PredMap();
+    }
+
+    ///The type of the map that indicates which nodes are processed.
+ 
+    ///The type of the map that indicates which nodes are processed.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef NullMap<typename Graph::Node,bool> ProcessedMap;
+    ///Instantiates a ProcessedMap.
+ 
+    ///This function instantiates a \ref ProcessedMap. 
+    ///\param g is the graph, to which
+    ///we would like to define the \ref ProcessedMap
+#ifdef DOXYGEN
+    static ProcessedMap *createProcessedMap(const GR &g)
+#else
+    static ProcessedMap *createProcessedMap(const GR &)
+#endif
+    {
+      return new ProcessedMap();
+    }
+    ///The type of the map that indicates which nodes are reached.
+ 
+    ///The type of the map that indicates which nodes are reached.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef typename Graph::template NodeMap<bool> ReachedMap;
+    ///Instantiates a ReachedMap.
+ 
+    ///This function instantiates a \ref ReachedMap. 
+    ///\param G is the graph, to which
+    ///we would like to define the \ref ReachedMap.
+    static ReachedMap *createReachedMap(const GR &G)
+    {
+      return new ReachedMap(G);
+    }
+    ///The type of the map that stores the dists of the nodes.
+ 
+    ///The type of the map that stores the dists of the nodes.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef NullMap<typename Graph::Node,int> DistMap;
+    ///Instantiates a DistMap.
+ 
+    ///This function instantiates a \ref DistMap. 
+    ///\param g is the graph, to which we would like to define the \ref DistMap
+#ifdef DOXYGEN
+    static DistMap *createDistMap(const GR &g)
+#else
+    static DistMap *createDistMap(const GR &)
+#endif
+    {
+      return new DistMap();
+    }
+  };
+  
+  /// Default traits used by \ref DfsWizard
+
+  /// To make it easier to use Dfs algorithm
+  ///we have created a wizard class.
+  /// This \ref DfsWizard class needs default traits,
+  ///as well as the \ref Dfs class.
+  /// The \ref DfsWizardBase is a class to be the default traits of the
+  /// \ref DfsWizard class.
+  template<class GR>
+  class DfsWizardBase : public DfsWizardDefaultTraits<GR>
+  {
+
+    typedef DfsWizardDefaultTraits<GR> Base;
+  protected:
+    /// Type of the nodes in the graph.
+    typedef typename Base::Graph::Node Node;
+
+    /// Pointer to the underlying graph.
+    void *_g;
+    ///Pointer to the map of reached nodes.
+    void *_reached;
+    ///Pointer to the map of processed nodes.
+    void *_processed;
+    ///Pointer to the map of predecessors edges.
+    void *_pred;
+    ///Pointer to the map of distances.
+    void *_dist;
+    ///Pointer to the source node.
+    Node _source;
+    
+    public:
+    /// Constructor.
+    
+    /// This constructor does not require parameters, therefore it initiates
+    /// all of the attributes to default values (0, INVALID).
+    DfsWizardBase() : _g(0), _reached(0), _processed(0), _pred(0),
+			   _dist(0), _source(INVALID) {}
+
+    /// Constructor.
+    
+    /// This constructor requires some parameters,
+    /// listed in the parameters list.
+    /// Others are initiated to 0.
+    /// \param g is the initial value of  \ref _g
+    /// \param s is the initial value of  \ref _source
+    DfsWizardBase(const GR &g, Node s=INVALID) :
+      _g(reinterpret_cast<void*>(const_cast<GR*>(&g))), 
+      _reached(0), _processed(0), _pred(0), _dist(0), _source(s) {}
+
+  };
+  
+  /// A class to make the usage of the Dfs algorithm easier
+
+  /// This class is created to make it easier to use the Dfs algorithm.
+  /// It uses the functions and features of the plain \ref Dfs,
+  /// but it is much simpler to use it.
+  ///
+  /// Simplicity means that the way to change the types defined
+  /// in the traits class is based on functions that returns the new class
+  /// and not on templatable built-in classes.
+  /// When using the plain \ref Dfs
+  /// the new class with the modified type comes from
+  /// the original class by using the ::
+  /// operator. In the case of \ref DfsWizard only
+  /// a function have to be called and it will
+  /// return the needed class.
+  ///
+  /// It does not have own \ref run method. When its \ref run method is called
+  /// it initiates a plain \ref Dfs object, and calls the \ref Dfs::run
+  /// method of it.
+  template<class TR>
+  class DfsWizard : public TR
+  {
+    typedef TR Base;
+
+    ///The type of the underlying graph.
+    typedef typename TR::Graph Graph;
+    //\e
+    typedef typename Graph::Node Node;
+    //\e
+    typedef typename Graph::NodeIt NodeIt;
+    //\e
+    typedef typename Graph::Edge Edge;
+    //\e
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    
+    ///\brief The type of the map that stores
+    ///the reached nodes
+    typedef typename TR::ReachedMap ReachedMap;
+    ///\brief The type of the map that stores
+    ///the processed nodes
+    typedef typename TR::ProcessedMap ProcessedMap;
+    ///\brief The type of the map that stores the last
+    ///edges of the %DFS paths.
+    typedef typename TR::PredMap PredMap;
+    ///The type of the map that stores the distances of the nodes.
+    typedef typename TR::DistMap DistMap;
+
+  public:
+    /// Constructor.
+    DfsWizard() : TR() {}
+
+    /// Constructor that requires parameters.
+
+    /// Constructor that requires parameters.
+    /// These parameters will be the default values for the traits class.
+    DfsWizard(const Graph &g, Node s=INVALID) :
+      TR(g,s) {}
+
+    ///Copy constructor
+    DfsWizard(const TR &b) : TR(b) {}
+
+    ~DfsWizard() {}
+
+    ///Runs Dfs algorithm from a given node.
+    
+    ///Runs Dfs algorithm from a given node.
+    ///The node can be given by the \ref source function.
+    void run()
+    {
+      if(Base::_source==INVALID) throw UninitializedParameter();
+      Dfs<Graph,TR> alg(*reinterpret_cast<const Graph*>(Base::_g));
+      if(Base::_reached) 
+        alg.reachedMap(*reinterpret_cast<ReachedMap*>(Base::_reached));
+      if(Base::_processed) 
+        alg.processedMap(*reinterpret_cast<ProcessedMap*>(Base::_processed));
+      if(Base::_pred) 
+        alg.predMap(*reinterpret_cast<PredMap*>(Base::_pred));
+      if(Base::_dist) 
+        alg.distMap(*reinterpret_cast<DistMap*>(Base::_dist));
+      alg.run(Base::_source);
+    }
+
+    ///Runs Dfs algorithm from the given node.
+
+    ///Runs Dfs algorithm from the given node.
+    ///\param s is the given source.
+    void run(Node s)
+    {
+      Base::_source=s;
+      run();
+    }
+
+    template<class T>
+    struct DefPredMapBase : public Base {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph &) { return 0; };
+      DefPredMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting PredMap type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting PredMap type
+    ///
+    template<class T>
+    DfsWizard<DefPredMapBase<T> > predMap(const T &t) 
+    {
+      Base::_pred=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return DfsWizard<DefPredMapBase<T> >(*this);
+    }
+    
+ 
+    template<class T>
+    struct DefReachedMapBase : public Base {
+      typedef T ReachedMap;
+      static ReachedMap *createReachedMap(const Graph &) { return 0; };
+      DefReachedMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting ReachedMap
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting ReachedMap
+    ///
+    template<class T>
+    DfsWizard<DefReachedMapBase<T> > reachedMap(const T &t) 
+    {
+      Base::_reached=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return DfsWizard<DefReachedMapBase<T> >(*this);
+    }
+    
+
+    template<class T>
+    struct DefProcessedMapBase : public Base {
+      typedef T ProcessedMap;
+      static ProcessedMap *createProcessedMap(const Graph &) { return 0; };
+      DefProcessedMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting ProcessedMap
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting ProcessedMap
+    ///
+    template<class T>
+    DfsWizard<DefProcessedMapBase<T> > processedMap(const T &t) 
+    {
+      Base::_processed=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return DfsWizard<DefProcessedMapBase<T> >(*this);
+    }
+    
+    template<class T>
+    struct DefDistMapBase : public Base {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph &) { return 0; };
+      DefDistMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    template<class T>
+    DfsWizard<DefDistMapBase<T> > distMap(const T &t) 
+    {
+      Base::_dist=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return DfsWizard<DefDistMapBase<T> >(*this);
+    }
+    
+    /// Sets the source node, from which the Dfs algorithm runs.
+
+    /// Sets the source node, from which the Dfs algorithm runs.
+    /// \param s is the source node.
+    DfsWizard<TR> &source(Node s) 
+    {
+      Base::_source=s;
+      return *this;
+    }
+    
+  };
+  
+  ///Function type interface for Dfs algorithm.
+
+  ///\ingroup search
+  ///Function type interface for Dfs algorithm.
+  ///
+  ///This function also has several
+  ///\ref named-templ-func-param "named parameters",
+  ///they are declared as the members of class \ref DfsWizard.
+  ///The following
+  ///example shows how to use these parameters.
+  ///\code
+  ///  dfs(g,source).predMap(preds).run();
+  ///\endcode
+  ///\warning Don't forget to put the \ref DfsWizard::run() "run()"
+  ///to the end of the parameter list.
+  ///\sa DfsWizard
+  ///\sa Dfs
+  template<class GR>
+  DfsWizard<DfsWizardBase<GR> >
+  dfs(const GR &g,typename GR::Node s=INVALID)
+  {
+    return DfsWizard<DfsWizardBase<GR> >(g,s);
+  }
+
+#ifdef DOXYGEN
+  /// \brief Visitor class for dfs.
+  ///  
+  /// It gives a simple interface for a functional interface for dfs 
+  /// traversal. The traversal on a linear data structure. 
+  template <typename _Graph>
+  struct DfsVisitor {
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::Node Node;
+    /// \brief Called when the edge reach a node.
+    /// 
+    /// It is called when the dfs find an edge which target is not
+    /// reached yet.
+    void discover(const Edge& edge) {}
+    /// \brief Called when the node reached first time.
+    /// 
+    /// It is Called when the node reached first time.
+    void reach(const Node& node) {}
+    /// \brief Called when we step back on an edge.
+    /// 
+    /// It is called when the dfs should step back on the edge.
+    void backtrack(const Edge& edge) {}
+    /// \brief Called when we step back from the node.
+    /// 
+    /// It is called when we step back from the node.
+    void leave(const Node& node) {}
+    /// \brief Called when the edge examined but target of the edge 
+    /// already discovered.
+    /// 
+    /// It called when the edge examined but the target of the edge 
+    /// already discovered.
+    void examine(const Edge& edge) {}
+    /// \brief Called for the source node of the dfs.
+    /// 
+    /// It is called for the source node of the dfs.
+    void start(const Node& node) {}
+    /// \brief Called when we leave the source node of the dfs.
+    /// 
+    /// It is called when we leave the source node of the dfs.
+    void stop(const Node& node) {}
+
+  };
+#else
+  template <typename _Graph>
+  struct DfsVisitor {
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::Node Node;
+    void discover(const Edge&) {}
+    void reach(const Node&) {}
+    void backtrack(const Edge&) {}
+    void leave(const Node&) {}
+    void examine(const Edge&) {}
+    void start(const Node&) {}
+    void stop(const Node&) {}
+
+    template <typename _Visitor>
+    struct Constraints {
+      void constraints() {
+	Edge edge;
+	Node node;
+	visitor.discover(edge);
+	visitor.reach(node);
+	visitor.backtrack(edge);
+	visitor.leave(node);
+	visitor.examine(edge);
+	visitor.start(node);
+	visitor.stop(edge);
+      }
+      _Visitor& visitor;
+    };
+  };
+#endif
+
+  /// \brief Default traits class of DfsVisit class.
+  ///
+  /// Default traits class of DfsVisit class.
+  /// \param _Graph Graph type.
+  template<class _Graph>
+  struct DfsVisitDefaultTraits {
+
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that indicates which nodes are reached.
+    /// 
+    /// The type of the map that indicates which nodes are reached.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    /// \todo named parameter to set this type, function to read and write.
+    typedef typename Graph::template NodeMap<bool> ReachedMap;
+
+    /// \brief Instantiates a ReachedMap.
+    ///
+    /// This function instantiates a \ref ReachedMap. 
+    /// \param graph is the graph, to which
+    /// we would like to define the \ref ReachedMap.
+    static ReachedMap *createReachedMap(const Graph &graph) {
+      return new ReachedMap(graph);
+    }
+
+  };
+  
+  /// %DFS Visit algorithm class.
+  
+  /// \ingroup search
+  /// This class provides an efficient implementation of the %DFS algorithm
+  /// with visitor interface.
+  ///
+  /// The %DfsVisit class provides an alternative interface to the Dfs
+  /// class. It works with callback mechanism, the DfsVisit object calls
+  /// on every dfs event the \c Visitor class member functions. 
+  ///
+  /// \param _Graph The graph type the algorithm runs on. The default value is
+  /// \ref ListGraph. The value of _Graph is not used directly by Dfs, it
+  /// is only passed to \ref DfsDefaultTraits.
+  /// \param _Visitor The Visitor object for the algorithm. The 
+  /// \ref DfsVisitor "DfsVisitor<_Graph>" is an empty Visitor which
+  /// does not observe the Dfs events. If you want to observe the dfs
+  /// events you should implement your own Visitor class.
+  /// \param _Traits Traits class to set various data types used by the 
+  /// algorithm. The default traits class is
+  /// \ref DfsVisitDefaultTraits "DfsVisitDefaultTraits<_Graph>".
+  /// See \ref DfsVisitDefaultTraits for the documentation of
+  /// a Dfs visit traits class.
+  ///
+  /// \author Jacint Szabo, Alpar Juttner and Balazs Dezso
+#ifdef DOXYGEN
+  template <typename _Graph, typename _Visitor, typename _Traits>
+#else
+  template <typename _Graph = ListGraph,
+	    typename _Visitor = DfsVisitor<_Graph>,
+	    typename _Traits = DfsDefaultTraits<_Graph> >
+#endif
+  class DfsVisit {
+  public:
+    
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() 
+      {
+	return "lemon::DfsVisit::UninitializedParameter";
+      }
+    };
+
+    typedef _Traits Traits;
+
+    typedef typename Traits::Graph Graph;
+
+    typedef _Visitor Visitor;
+
+    ///The type of the map indicating which nodes are reached.
+    typedef typename Traits::ReachedMap ReachedMap;
+
+  private:
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+
+    /// Pointer to the underlying graph.
+    const Graph *_graph;
+    /// Pointer to the visitor object.
+    Visitor *_visitor;
+    ///Pointer to the map of reached status of the nodes.
+    ReachedMap *_reached;
+    ///Indicates if \ref _reached is locally allocated (\c true) or not.
+    bool local_reached;
+
+    std::vector<typename Graph::Edge> _stack;
+    int _stack_head;
+
+    /// \brief Creates the maps if necessary.
+    ///
+    /// Creates the maps if necessary.
+    void create_maps() {
+      if(!_reached) {
+	local_reached = true;
+	_reached = Traits::createReachedMap(*_graph);
+      }
+    }
+
+  protected:
+
+    DfsVisit() {}
+    
+  public:
+
+    typedef DfsVisit Create;
+
+    /// \name Named template parameters
+
+    ///@{
+    template <class T>
+    struct DefReachedMapTraits : public Traits {
+      typedef T ReachedMap;
+      static ReachedMap *createReachedMap(const Graph &graph) {
+	throw UninitializedParameter();
+      }
+    };
+    /// \brief \ref named-templ-param "Named parameter" for setting 
+    /// ReachedMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting ReachedMap type
+    template <class T>
+    struct DefReachedMap : public DfsVisit< Graph, Visitor,
+					    DefReachedMapTraits<T> > {
+      typedef DfsVisit< Graph, Visitor, DefReachedMapTraits<T> > Create;
+    };
+    ///@}
+
+  public:      
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor.
+    ///
+    /// \param graph the graph the algorithm will run on.
+    /// \param visitor The visitor of the algorithm.
+    ///
+    DfsVisit(const Graph& graph, Visitor& visitor) 
+      : _graph(&graph), _visitor(&visitor),
+	_reached(0), local_reached(false) {}
+    
+    /// \brief Destructor.
+    ///
+    /// Destructor.
+    ~DfsVisit() {
+      if(local_reached) delete _reached;
+    }
+
+    /// \brief Sets the map indicating if a node is reached.
+    ///
+    /// Sets the map indicating if a node is reached.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return <tt> (*this) </tt>
+    DfsVisit &reachedMap(ReachedMap &m) {
+      if(local_reached) {
+	delete _reached;
+	local_reached=false;
+      }
+      _reached = &m;
+      return *this;
+    }
+
+  public:
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run(...).
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init(), then you can adda source node
+    /// with \ref addSource().
+    /// Finally \ref start() will perform the actual path
+    /// computation.
+
+    /// @{
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    ///
+    void init() {
+      create_maps();
+      _stack.resize(countNodes(*_graph));
+      _stack_head = -1;
+      for (NodeIt u(*_graph) ; u != INVALID ; ++u) {
+	_reached->set(u, false);
+      }
+    }
+    
+    /// \brief Adds a new source node.
+    ///
+    /// Adds a new source node to the set of nodes to be processed.
+    void addSource(Node s) {
+      if(!(*_reached)[s]) {
+	  _reached->set(s,true);
+	  _visitor->start(s);
+	  _visitor->reach(s);
+	  Edge e; 
+	  _graph->firstOut(e, s);
+	  if (e != INVALID) {
+	    _stack[++_stack_head] = e;
+	  } else {
+	    _visitor->leave(s);
+	  }
+	}
+    }
+    
+    /// \brief Processes the next edge.
+    ///
+    /// Processes the next edge.
+    ///
+    /// \return The processed edge.
+    ///
+    /// \pre The stack must not be empty!
+    Edge processNextEdge() { 
+      Edge e = _stack[_stack_head];
+      Node m = _graph->target(e);
+      if(!(*_reached)[m]) {
+	_visitor->discover(e);
+	_visitor->reach(m);
+	_reached->set(m, true);
+	_graph->firstOut(_stack[++_stack_head], m);
+      } else {
+	_visitor->examine(e);
+	m = _graph->source(e);
+	_graph->nextOut(_stack[_stack_head]);
+      }
+      while (_stack_head>=0 && _stack[_stack_head] == INVALID) {
+	_visitor->leave(m);
+	--_stack_head;
+	if (_stack_head >= 0) {
+	  _visitor->backtrack(_stack[_stack_head]);
+	  m = _graph->source(_stack[_stack_head]);
+	  _graph->nextOut(_stack[_stack_head]);
+	} else {
+	  _visitor->stop(m);	  
+	}
+      }
+      return e;
+    }
+
+    /// \brief Next edge to be processed.
+    ///
+    /// Next edge to be processed.
+    ///
+    /// \return The next edge to be processed or INVALID if the stack is
+    /// empty.
+    Edge nextEdge() { 
+      return _stack_head >= 0 ? _stack[_stack_head] : INVALID;
+    }
+
+    /// \brief Returns \c false if there are nodes
+    /// to be processed in the queue
+    ///
+    /// Returns \c false if there are nodes
+    /// to be processed in the queue
+    bool emptyQueue() { return _stack_head < 0; }
+
+    /// \brief Returns the number of the nodes to be processed.
+    ///
+    /// Returns the number of the nodes to be processed in the queue.
+    int queueSize() { return _stack_head + 1; }
+    
+    /// \brief Executes the algorithm.
+    ///
+    /// Executes the algorithm.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    void start() {
+      while ( !emptyQueue() ) processNextEdge();
+    }
+    
+    /// \brief Executes the algorithm until \c dest is reached.
+    ///
+    /// Executes the algorithm until \c dest is reached.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    void start(Node dest) {
+      while ( !emptyQueue() && _graph->target(_stack[_stack_head]) != dest ) 
+	processNextEdge();
+    }
+    
+    /// \brief Executes the algorithm until a condition is met.
+    ///
+    /// Executes the algorithm until a condition is met.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    ///
+    /// \param em must be a bool (or convertible) edge map. The algorithm
+    /// will stop when it reaches an edge \c e with <tt>em[e]</tt> true.
+    ///
+    ///\return The reached edge \c e with <tt>em[e]</tt> true or
+    ///\c INVALID if no such edge was found.
+    ///
+    /// \warning Contrary to \ref Bfs and \ref Dijkstra, \c em is an edge map,
+    /// not a node map.
+    template <typename EM>
+    Edge start(const EM &em) {
+      while ( !emptyQueue() && !em[_stack[_stack_head]] )
+        processNextEdge();
+      return emptyQueue() ? INVALID : _stack[_stack_head];
+    }
+
+    /// \brief Runs %DFSVisit algorithm from node \c s.
+    ///
+    /// This method runs the %DFS algorithm from a root node \c s.
+    /// \note d.run(s) is just a shortcut of the following code.
+    ///\code
+    ///   d.init();
+    ///   d.addSource(s);
+    ///   d.start();
+    ///\endcode
+    void run(Node s) {
+      init();
+      addSource(s);
+      start();
+    }
+
+    /// \brief Runs %DFSVisit algorithm to visit all nodes in the graph.
+    
+    /// This method runs the %DFS algorithm in order to
+    /// compute the %DFS path to each node. The algorithm computes
+    /// - The %DFS tree.
+    /// - The distance of each node from the root in the %DFS tree.
+    ///
+    ///\note d.run() is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  for (NodeIt it(graph); it != INVALID; ++it) {
+    ///    if (!d.reached(it)) {
+    ///      d.addSource(it);
+    ///      d.start();
+    ///    }
+    ///  }
+    ///\endcode
+    void run() {
+      init();
+      for (NodeIt it(*_graph); it != INVALID; ++it) {
+        if (!reached(it)) {
+          addSource(it);
+          start();
+        }
+      }
+    }
+    ///@}
+
+    /// \name Query Functions
+    /// The result of the %DFS algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    ///@{
+    /// \brief Checks if a node is reachable from the root.
+    ///
+    /// Returns \c true if \c v is reachable from the root(s).
+    /// \warning The source nodes are inditated as unreachable.
+    /// \pre Either \ref run() or \ref start()
+    /// must be called before using this function.
+    ///
+    bool reached(Node v) { return (*_reached)[v]; }
+    ///@}
+  };
+
+
+} //END OF NAMESPACE LEMON
+
+#endif
+
Index: lemon/dijkstra.h
===================================================================
--- lemon/dijkstra.h	(revision 2618)
+++ lemon/dijkstra.h	(revision 2618)
@@ -0,0 +1,1211 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_DIJKSTRA_H
+#define LEMON_DIJKSTRA_H
+
+///\ingroup shortest_path
+///\file
+///\brief Dijkstra algorithm.
+///
+
+#include <lemon/list_graph.h>
+#include <lemon/bin_heap.h>
+#include <lemon/bits/path_dump.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+
+#include <limits>
+
+
+namespace lemon {
+
+  /// \brief Default OperationTraits for the Dijkstra algorithm class.
+  ///  
+  /// It defines all computational operations and constants which are
+  /// used in the Dijkstra algorithm.
+  template <typename Value>
+  struct DijkstraDefaultOperationTraits {
+    /// \brief Gives back the zero value of the type.
+    static Value zero() {
+      return static_cast<Value>(0);
+    }
+    /// \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 true only if the first value less than the second.
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+
+  /// \brief Widest path OperationTraits for the Dijkstra algorithm class.
+  ///  
+  /// It defines all computational operations and constants which are
+  /// used in the Dijkstra algorithm for widest path computation.
+  template <typename Value>
+  struct DijkstraWidestPathOperationTraits {
+    /// \brief Gives back the maximum value of the type.
+    static Value zero() {
+      return std::numeric_limits<Value>::max();
+    }
+    /// \brief Gives back the minimum of the given two elements.
+    static Value plus(const Value& left, const Value& right) {
+      return std::min(left, right);
+    }
+    /// \brief Gives back true only if the first value less than the second.
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+  
+  ///Default traits class of Dijkstra class.
+
+  ///Default traits class of Dijkstra class.
+  ///\param GR Graph type.
+  ///\param LM Type of length map.
+  template<class GR, class LM>
+  struct DijkstraDefaultTraits
+  {
+    ///The graph type the algorithm runs on. 
+    typedef GR Graph;
+    ///The type of the map that stores the edge lengths.
+
+    ///The type of the map that stores the edge lengths.
+    ///It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef LM LengthMap;
+    //The type of the length of the edges.
+    typedef typename LM::Value Value;
+    /// Operation traits for Dijkstra algorithm.
+
+    /// It defines the used operation by the algorithm.
+    /// \see DijkstraDefaultOperationTraits
+    typedef DijkstraDefaultOperationTraits<Value> OperationTraits;
+    /// The cross reference type used by heap.
+
+
+    /// The cross reference type used by heap.
+    /// Usually it is \c Graph::NodeMap<int>.
+    typedef typename Graph::template NodeMap<int> HeapCrossRef;
+    ///Instantiates a HeapCrossRef.
+
+    ///This function instantiates a \c HeapCrossRef. 
+    /// \param G is the graph, to which we would like to define the 
+    /// HeapCrossRef.
+    static HeapCrossRef *createHeapCrossRef(const GR &G) 
+    {
+      return new HeapCrossRef(G);
+    }
+    
+    ///The heap type used by Dijkstra algorithm.
+
+    ///The heap type used by Dijkstra algorithm.
+    ///
+    ///\sa BinHeap
+    ///\sa Dijkstra
+    typedef BinHeap<typename LM::Value, HeapCrossRef, std::less<Value> > Heap;
+
+    static Heap *createHeap(HeapCrossRef& R) 
+    {
+      return new Heap(R);
+    }
+
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    /// 
+    ///The type of the map that stores the last
+    ///edges of the shortest paths.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename GR::Edge> PredMap;
+    ///Instantiates a PredMap.
+ 
+    ///This function instantiates a \c PredMap. 
+    ///\param G is the graph, to which we would like to define the PredMap.
+    ///\todo The graph alone may be insufficient for the initialization
+    static PredMap *createPredMap(const GR &G) 
+    {
+      return new PredMap(G);
+    }
+
+    ///The type of the map that stores whether a nodes is processed.
+ 
+    ///The type of the map that stores whether a nodes is processed.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///By default it is a NullMap.
+    ///\todo If it is set to a real map,
+    ///Dijkstra::processed() should read this.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef NullMap<typename Graph::Node,bool> ProcessedMap;
+    ///Instantiates a ProcessedMap.
+ 
+    ///This function instantiates a \c ProcessedMap. 
+    ///\param g is the graph, to which
+    ///we would like to define the \c ProcessedMap
+#ifdef DOXYGEN
+    static ProcessedMap *createProcessedMap(const GR &g)
+#else
+    static ProcessedMap *createProcessedMap(const GR &)
+#endif
+    {
+      return new ProcessedMap();
+    }
+    ///The type of the map that stores the dists of the nodes.
+ 
+    ///The type of the map that stores the dists of the nodes.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename Graph::template NodeMap<typename LM::Value> DistMap;
+    ///Instantiates a DistMap.
+ 
+    ///This function instantiates a \ref DistMap. 
+    ///\param G is the graph, to which we would like to define the \ref DistMap
+    static DistMap *createDistMap(const GR &G)
+    {
+      return new DistMap(G);
+    }
+  };
+  
+  ///%Dijkstra algorithm class.
+  
+  /// \ingroup shortest_path
+  ///This class provides an efficient implementation of %Dijkstra algorithm.
+  ///The edge lengths are passed to the algorithm using a
+  ///\ref concepts::ReadMap "ReadMap",
+  ///so it is easy to change it to any kind of length.
+  ///
+  ///The type of the length is determined by the
+  ///\ref concepts::ReadMap::Value "Value" of the length map.
+  ///
+  ///It is also possible to change the underlying priority heap.
+  ///
+  ///\param GR The graph type the algorithm runs on. The default value
+  ///is \ref ListGraph. The value of GR is not used directly by
+  ///Dijkstra, it is only passed to \ref DijkstraDefaultTraits.
+  ///\param LM This read-only EdgeMap determines the lengths of the
+  ///edges. It is read once for each edge, so the map may involve in
+  ///relatively time consuming process to compute the edge length if
+  ///it is necessary. The default map type is \ref
+  ///concepts::Graph::EdgeMap "Graph::EdgeMap<int>".  The value
+  ///of LM is not used directly by Dijkstra, it is only passed to \ref
+  ///DijkstraDefaultTraits.  \param TR Traits class to set
+  ///various data types used by the algorithm.  The default traits
+  ///class is \ref DijkstraDefaultTraits
+  ///"DijkstraDefaultTraits<GR,LM>".  See \ref
+  ///DijkstraDefaultTraits for the documentation of a Dijkstra traits
+  ///class.
+  ///
+  ///\author Jacint Szabo and Alpar Juttner
+
+#ifdef DOXYGEN
+  template <typename GR, typename LM, typename TR>
+#else
+  template <typename GR=ListGraph,
+	    typename LM=typename GR::template EdgeMap<int>,
+	    typename TR=DijkstraDefaultTraits<GR,LM> >
+#endif
+  class Dijkstra {
+  public:
+    /**
+     * \brief \ref Exception for uninitialized parameters.
+     *
+     * This error represents problems in the initialization
+     * of the parameters of the algorithms.
+     */
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::Dijkstra::UninitializedParameter";
+      }
+    };
+
+    typedef TR Traits;
+    ///The type of the underlying graph.
+    typedef typename TR::Graph Graph;
+    ///\e
+    typedef typename Graph::Node Node;
+    ///\e
+    typedef typename Graph::NodeIt NodeIt;
+    ///\e
+    typedef typename Graph::Edge Edge;
+    ///\e
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    
+    ///The type of the length of the edges.
+    typedef typename TR::LengthMap::Value Value;
+    ///The type of the map that stores the edge lengths.
+    typedef typename TR::LengthMap LengthMap;
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    typedef typename TR::PredMap PredMap;
+    ///The type of the map indicating if a node is processed.
+    typedef typename TR::ProcessedMap ProcessedMap;
+    ///The type of the map that stores the dists of the nodes.
+    typedef typename TR::DistMap DistMap;
+    ///The cross reference type used for the current heap.
+    typedef typename TR::HeapCrossRef HeapCrossRef;
+    ///The heap type used by the dijkstra algorithm.
+    typedef typename TR::Heap Heap;
+    ///The operation traits.
+    typedef typename TR::OperationTraits OperationTraits;
+  private:
+    /// Pointer to the underlying graph.
+    const Graph *G;
+    /// Pointer to the length map
+    const LengthMap *length;
+    ///Pointer to the map of predecessors edges.
+    PredMap *_pred;
+    ///Indicates if \ref _pred is locally allocated (\c true) or not.
+    bool local_pred;
+    ///Pointer to the map of distances.
+    DistMap *_dist;
+    ///Indicates if \ref _dist is locally allocated (\c true) or not.
+    bool local_dist;
+    ///Pointer to the map of processed status of the nodes.
+    ProcessedMap *_processed;
+    ///Indicates if \ref _processed is locally allocated (\c true) or not.
+    bool local_processed;
+    ///Pointer to the heap cross references.
+    HeapCrossRef *_heap_cross_ref;
+    ///Indicates if \ref _heap_cross_ref is locally allocated (\c true) or not.
+    bool local_heap_cross_ref;
+    ///Pointer to the heap.
+    Heap *_heap;
+    ///Indicates if \ref _heap is locally allocated (\c true) or not.
+    bool local_heap;
+
+    ///Creates the maps if necessary.
+    
+    ///\todo Better memory allocation (instead of new).
+    void create_maps() 
+    {
+      if(!_pred) {
+	local_pred = true;
+	_pred = Traits::createPredMap(*G);
+      }
+      if(!_dist) {
+	local_dist = true;
+	_dist = Traits::createDistMap(*G);
+      }
+      if(!_processed) {
+	local_processed = true;
+	_processed = Traits::createProcessedMap(*G);
+      }
+      if (!_heap_cross_ref) {
+	local_heap_cross_ref = true;
+	_heap_cross_ref = Traits::createHeapCrossRef(*G);
+      }
+      if (!_heap) {
+	local_heap = true;
+	_heap = Traits::createHeap(*_heap_cross_ref);
+      }
+    }
+    
+  public :
+
+    typedef Dijkstra Create;
+ 
+    ///\name Named template parameters
+
+    ///@{
+
+    template <class T>
+    struct DefPredMapTraits : public Traits {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph &)
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\ref named-templ-param "Named parameter" for setting PredMap type
+
+    ///\ref named-templ-param "Named parameter" for setting PredMap type
+    ///
+    template <class T>
+    struct DefPredMap 
+      : public Dijkstra< Graph,	LengthMap, DefPredMapTraits<T> > {
+      typedef Dijkstra< Graph,	LengthMap, DefPredMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefDistMapTraits : public Traits {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph &)
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\ref named-templ-param "Named parameter" for setting DistMap type
+
+    ///\ref named-templ-param "Named parameter" for setting DistMap type
+    ///
+    template <class T>
+    struct DefDistMap 
+      : public Dijkstra< Graph, LengthMap, DefDistMapTraits<T> > { 
+      typedef Dijkstra< Graph, LengthMap, DefDistMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefProcessedMapTraits : public Traits {
+      typedef T ProcessedMap;
+      static ProcessedMap *createProcessedMap(const Graph &G) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\ref named-templ-param "Named parameter" for setting ProcessedMap type
+
+    ///\ref named-templ-param "Named parameter" for setting ProcessedMap type
+    ///
+    template <class T>
+    struct DefProcessedMap 
+      : public Dijkstra< Graph,	LengthMap, DefProcessedMapTraits<T> > { 
+      typedef Dijkstra< Graph,	LengthMap, DefProcessedMapTraits<T> > Create;
+    };
+    
+    struct DefGraphProcessedMapTraits : public Traits {
+      typedef typename Graph::template NodeMap<bool> ProcessedMap;
+      static ProcessedMap *createProcessedMap(const Graph &G) 
+      {
+	return new ProcessedMap(G);
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter"
+    ///for setting the ProcessedMap type to be Graph::NodeMap<bool>.
+    ///
+    ///\ref named-templ-param "Named parameter"
+    ///for setting the ProcessedMap type to be Graph::NodeMap<bool>.
+    ///If you don't set it explicitely, it will be automatically allocated.
+    template <class T>
+    struct DefProcessedMapToBeDefaultMap 
+      : public Dijkstra< Graph, LengthMap, DefGraphProcessedMapTraits> {
+      typedef Dijkstra< Graph, LengthMap, DefGraphProcessedMapTraits> Create;
+    };
+
+    template <class H, class CR>
+    struct DefHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const Graph &) {
+	throw UninitializedParameter();
+      }
+      static Heap *createHeap(HeapCrossRef &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///heap and cross reference type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting heap and cross 
+    ///reference type
+    ///
+    template <class H, class CR = typename Graph::template NodeMap<int> >
+    struct DefHeap
+      : public Dijkstra< Graph,	LengthMap, DefHeapTraits<H, CR> > { 
+      typedef Dijkstra< Graph,	LengthMap, DefHeapTraits<H, CR> > Create;
+    };
+
+    template <class H, class CR>
+    struct DefStandardHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const Graph &G) {
+	return new HeapCrossRef(G);
+      }
+      static Heap *createHeap(HeapCrossRef &R) 
+      {
+	return new Heap(R);
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///heap and cross reference type with automatic allocation
+    ///
+    ///\ref named-templ-param "Named parameter" for setting heap and cross 
+    ///reference type. It can allocate the heap and the cross reference 
+    ///object if the cross reference's constructor waits for the graph as 
+    ///parameter and the heap's constructor waits for the cross reference.
+    template <class H, class CR = typename Graph::template NodeMap<int> >
+    struct DefStandardHeap
+      : public Dijkstra< Graph,	LengthMap, DefStandardHeapTraits<H, CR> > { 
+      typedef Dijkstra< Graph,	LengthMap, DefStandardHeapTraits<H, CR> > 
+      Create;
+    };
+
+    template <class T>
+    struct DefOperationTraitsTraits : public Traits {
+      typedef T OperationTraits;
+    };
+    
+    /// \brief \ref named-templ-param "Named parameter" for setting 
+    /// OperationTraits type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting OperationTraits
+    /// type
+    template <class T>
+    struct DefOperationTraits
+      : public Dijkstra<Graph, LengthMap, DefOperationTraitsTraits<T> > {
+      typedef Dijkstra<Graph, LengthMap, DefOperationTraitsTraits<T> >
+      Create;
+    };
+    
+    ///@}
+
+
+  protected:
+
+    Dijkstra() {}
+
+  public:      
+    
+    ///Constructor.
+    
+    ///\param _G the graph the algorithm will run on.
+    ///\param _length the length map used by the algorithm.
+    Dijkstra(const Graph& _G, const LengthMap& _length) :
+      G(&_G), length(&_length),
+      _pred(NULL), local_pred(false),
+      _dist(NULL), local_dist(false),
+      _processed(NULL), local_processed(false),
+      _heap_cross_ref(NULL), local_heap_cross_ref(false),
+      _heap(NULL), local_heap(false)
+    { }
+    
+    ///Destructor.
+    ~Dijkstra() 
+    {
+      if(local_pred) delete _pred;
+      if(local_dist) delete _dist;
+      if(local_processed) delete _processed;
+      if(local_heap_cross_ref) delete _heap_cross_ref;
+      if(local_heap) delete _heap;
+    }
+
+    ///Sets the length map.
+
+    ///Sets the length map.
+    ///\return <tt> (*this) </tt>
+    Dijkstra &lengthMap(const LengthMap &m) 
+    {
+      length = &m;
+      return *this;
+    }
+
+    ///Sets the map storing the predecessor edges.
+
+    ///Sets the map storing the predecessor edges.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Dijkstra &predMap(PredMap &m) 
+    {
+      if(local_pred) {
+	delete _pred;
+	local_pred=false;
+      }
+      _pred = &m;
+      return *this;
+    }
+
+    ///Sets the map storing the distances calculated by the algorithm.
+
+    ///Sets the map storing the distances calculated by the algorithm.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Dijkstra &distMap(DistMap &m) 
+    {
+      if(local_dist) {
+	delete _dist;
+	local_dist=false;
+      }
+      _dist = &m;
+      return *this;
+    }
+
+    ///Sets the heap and the cross reference used by algorithm.
+
+    ///Sets the heap and the cross reference used by algorithm.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated heap and cross reference, of course.
+    ///\return <tt> (*this) </tt>
+    Dijkstra &heap(Heap& hp, HeapCrossRef &cr)
+    {
+      if(local_heap_cross_ref) {
+	delete _heap_cross_ref;
+	local_heap_cross_ref=false;
+      }
+      _heap_cross_ref = &cr;
+      if(local_heap) {
+	delete _heap;
+	local_heap=false;
+      }
+      _heap = &hp;
+      return *this;
+    }
+
+  private:
+    void finalizeNodeData(Node v,Value dst)
+    {
+      _processed->set(v,true);
+      _dist->set(v, dst);
+    }
+
+  public:
+
+    typedef PredMapPath<Graph, PredMap> Path;
+
+    ///\name Execution control
+    ///The simplest way to execute the algorithm is to use
+    ///one of the member functions called \c run(...).
+    ///\n
+    ///If you need more control on the execution,
+    ///first you must call \ref init(), then you can add several source nodes
+    ///with \ref addSource().
+    ///Finally \ref start() will perform the actual path
+    ///computation.
+
+    ///@{
+
+    ///Initializes the internal data structures.
+
+    ///Initializes the internal data structures.
+    ///
+    void init()
+    {
+      create_maps();
+      _heap->clear();
+      for ( NodeIt u(*G) ; u!=INVALID ; ++u ) {
+	_pred->set(u,INVALID);
+	_processed->set(u,false);
+	_heap_cross_ref->set(u,Heap::PRE_HEAP);
+      }
+    }
+    
+    ///Adds a new source node.
+
+    ///Adds a new source node to the priority heap.
+    ///
+    ///The optional second parameter is the initial distance of the node.
+    ///
+    ///It checks if the node has already been added to the heap and
+    ///it is pushed to the heap only if either it was not in the heap
+    ///or the shortest path found till then is shorter than \c dst.
+    void addSource(Node s,Value dst=OperationTraits::zero())
+    {
+      if(_heap->state(s) != Heap::IN_HEAP) {
+	_heap->push(s,dst);
+      } else if(OperationTraits::less((*_heap)[s], dst)) {
+	_heap->set(s,dst);
+	_pred->set(s,INVALID);
+      }
+    }
+    
+    ///Processes the next node in the priority heap
+
+    ///Processes the next node in the priority heap.
+    ///
+    ///\return The processed node.
+    ///
+    ///\warning The priority heap must not be empty!
+    Node processNextNode()
+    {
+      Node v=_heap->top(); 
+      Value oldvalue=_heap->prio();
+      _heap->pop();
+      finalizeNodeData(v,oldvalue);
+      
+      for(OutEdgeIt e(*G,v); e!=INVALID; ++e) {
+	Node w=G->target(e); 
+	switch(_heap->state(w)) {
+	case Heap::PRE_HEAP:
+	  _heap->push(w,OperationTraits::plus(oldvalue, (*length)[e])); 
+	  _pred->set(w,e);
+	  break;
+	case Heap::IN_HEAP:
+	  {
+	    Value newvalue = OperationTraits::plus(oldvalue, (*length)[e]);
+	    if ( OperationTraits::less(newvalue, (*_heap)[w]) ) {
+	      _heap->decrease(w, newvalue); 
+	      _pred->set(w,e);
+	    }
+	  }
+	  break;
+	case Heap::POST_HEAP:
+	  break;
+	}
+      }
+      return v;
+    }
+
+    ///Next node to be processed.
+    
+    ///Next node to be processed.
+    ///
+    ///\return The next node to be processed or INVALID if the priority heap
+    /// is empty.
+    Node nextNode()
+    { 
+      return !_heap->empty()?_heap->top():INVALID;
+    }
+ 
+    ///\brief Returns \c false if there are nodes
+    ///to be processed in the priority heap
+    ///
+    ///Returns \c false if there are nodes
+    ///to be processed in the priority heap
+    bool emptyQueue() { return _heap->empty(); }
+    ///Returns the number of the nodes to be processed in the priority heap
+
+    ///Returns the number of the nodes to be processed in the priority heap
+    ///
+    int queueSize() { return _heap->size(); }
+    
+    ///Executes the algorithm.
+
+    ///Executes the algorithm.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///This method runs the %Dijkstra algorithm from the root node(s)
+    ///in order to
+    ///compute the
+    ///shortest path to each node. The algorithm computes
+    ///- The shortest path tree.
+    ///- The distance of each node from the root(s).
+    ///
+    void start()
+    {
+      while ( !_heap->empty() ) processNextNode();
+    }
+    
+    ///Executes the algorithm until \c dest is reached.
+
+    ///Executes the algorithm until \c dest is reached.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///This method runs the %Dijkstra algorithm from the root node(s)
+    ///in order to
+    ///compute the
+    ///shortest path to \c dest. The algorithm computes
+    ///- The shortest path to \c  dest.
+    ///- The distance of \c dest from the root(s).
+    ///
+    void start(Node dest)
+    {
+      while ( !_heap->empty() && _heap->top()!=dest ) processNextNode();
+      if ( !_heap->empty() ) finalizeNodeData(_heap->top(),_heap->prio());
+    }
+    
+    ///Executes the algorithm until a condition is met.
+
+    ///Executes the algorithm until a condition is met.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///\param nm must be a bool (or convertible) node map. The algorithm
+    ///will stop when it reaches a node \c v with <tt>nm[v]</tt> true.
+    ///
+    ///\return The reached node \c v with <tt>nm[v]</tt> true or
+    ///\c INVALID if no such node was found.
+    template<class NodeBoolMap>
+    Node start(const NodeBoolMap &nm)
+    {
+      while ( !_heap->empty() && !nm[_heap->top()] ) processNextNode();
+      if ( _heap->empty() ) return INVALID;
+      finalizeNodeData(_heap->top(),_heap->prio());
+      return _heap->top();
+    }
+    
+    ///Runs %Dijkstra algorithm from node \c s.
+    
+    ///This method runs the %Dijkstra algorithm from a root node \c s
+    ///in order to
+    ///compute the
+    ///shortest path to each node. The algorithm computes
+    ///- The shortest path tree.
+    ///- The distance of each node from the root.
+    ///
+    ///\note d.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.addSource(s);
+    ///  d.start();
+    ///\endcode
+    void run(Node s) {
+      init();
+      addSource(s);
+      start();
+    }
+    
+    ///Finds the shortest path between \c s and \c t.
+    
+    ///Finds the shortest path between \c s and \c t.
+    ///
+    ///\return The length of the shortest s---t path if there exists one,
+    ///0 otherwise.
+    ///\note Apart from the return value, d.run(s) is
+    ///just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.addSource(s);
+    ///  d.start(t);
+    ///\endcode
+    Value run(Node s,Node t) {
+      init();
+      addSource(s);
+      start(t);
+      return (*_pred)[t]==INVALID?OperationTraits::zero():(*_dist)[t];
+    }
+    
+    ///@}
+
+    ///\name Query Functions
+    ///The result of the %Dijkstra algorithm can be obtained using these
+    ///functions.\n
+    ///Before the use of these functions,
+    ///either run() or start() must be called.
+    
+    ///@{
+
+    ///Gives back the shortest path.
+    
+    ///Gives back the shortest path.
+    ///\pre The \c t should be reachable from the source.
+    Path path(Node t) 
+    {
+      return Path(*G, *_pred, t);
+    }
+
+    ///The distance of a node from the root.
+
+    ///Returns the distance of a node from the root.
+    ///\pre \ref run() must be called before using this function.
+    ///\warning If node \c v in unreachable from the root the return value
+    ///of this funcion is undefined.
+    Value dist(Node v) const { return (*_dist)[v]; }
+
+    ///The current distance of a node from the root.
+
+    ///Returns the current distance of a node from the root.
+    ///It may be decreased in the following processes.
+    ///\pre \c node should be reached but not processed
+    Value currentDist(Node v) const { return (*_heap)[v]; }
+
+    ///Returns the 'previous edge' of the shortest path tree.
+
+    ///For a node \c v it returns the 'previous edge' of the shortest path tree,
+    ///i.e. it returns the last edge of a shortest path from the root to \c
+    ///v. It is \ref INVALID
+    ///if \c v is unreachable from the root or if \c v=s. The
+    ///shortest path tree used here is equal to the shortest path tree used in
+    ///\ref predNode().  \pre \ref run() must be called before using
+    ///this function.
+    Edge predEdge(Node v) const { return (*_pred)[v]; }
+
+    ///Returns the 'previous node' of the shortest path tree.
+
+    ///For a node \c v it returns the 'previous node' of the shortest path tree,
+    ///i.e. it returns the last but one node from a shortest path from the
+    ///root to \c /v. It is INVALID if \c v is unreachable from the root or if
+    ///\c v=s. The shortest path tree used here is equal to the shortest path
+    ///tree used in \ref predEdge().  \pre \ref run() must be called before
+    ///using this function.
+    Node predNode(Node v) const { return (*_pred)[v]==INVALID ? INVALID:
+				  G->source((*_pred)[v]); }
+    
+    ///Returns a reference to the NodeMap of distances.
+
+    ///Returns a reference to the NodeMap of distances. \pre \ref run() must
+    ///be called before using this function.
+    const DistMap &distMap() const { return *_dist;}
+ 
+    ///Returns a reference to the shortest path tree map.
+
+    ///Returns a reference to the NodeMap of the edges of the
+    ///shortest path tree.
+    ///\pre \ref run() must be called before using this function.
+    const PredMap &predMap() const { return *_pred;}
+ 
+    ///Checks if a node is reachable from the root.
+
+    ///Returns \c true if \c v is reachable from the root.
+    ///\warning The source nodes are inditated as unreached.
+    ///\pre \ref run() must be called before using this function.
+    ///
+    bool reached(Node v) { return (*_heap_cross_ref)[v] != Heap::PRE_HEAP; }
+
+    ///Checks if a node is processed.
+
+    ///Returns \c true if \c v is processed, i.e. the shortest
+    ///path to \c v has already found.
+    ///\pre \ref run() must be called before using this function.
+    ///
+    bool processed(Node v) { return (*_heap_cross_ref)[v] == Heap::POST_HEAP; }
+    
+    ///@}
+  };
+
+
+
+
+ 
+  ///Default traits class of Dijkstra function.
+
+  ///Default traits class of Dijkstra function.
+  ///\param GR Graph type.
+  ///\param LM Type of length map.
+  template<class GR, class LM>
+  struct DijkstraWizardDefaultTraits
+  {
+    ///The graph type the algorithm runs on. 
+    typedef GR Graph;
+    ///The type of the map that stores the edge lengths.
+
+    ///The type of the map that stores the edge lengths.
+    ///It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef LM LengthMap;
+    //The type of the length of the edges.
+    typedef typename LM::Value Value;
+    /// Operation traits for Dijkstra algorithm.
+
+    /// It defines the used operation by the algorithm.
+    /// \see DijkstraDefaultOperationTraits
+    typedef DijkstraDefaultOperationTraits<Value> OperationTraits;
+    ///The heap type used by Dijkstra algorithm.
+
+    /// The cross reference type used by heap.
+
+    /// The cross reference type used by heap.
+    /// Usually it is \c Graph::NodeMap<int>.
+    typedef typename Graph::template NodeMap<int> HeapCrossRef;
+    ///Instantiates a HeapCrossRef.
+
+    ///This function instantiates a \ref HeapCrossRef. 
+    /// \param G is the graph, to which we would like to define the 
+    /// HeapCrossRef.
+    /// \todo The graph alone may be insufficient for the initialization
+    static HeapCrossRef *createHeapCrossRef(const GR &G) 
+    {
+      return new HeapCrossRef(G);
+    }
+    
+    ///The heap type used by Dijkstra algorithm.
+
+    ///The heap type used by Dijkstra algorithm.
+    ///
+    ///\sa BinHeap
+    ///\sa Dijkstra
+    typedef BinHeap<typename LM::Value, typename GR::template NodeMap<int>,
+		    std::less<Value> > Heap;
+
+    static Heap *createHeap(HeapCrossRef& R) 
+    {
+      return new Heap(R);
+    }
+
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    /// 
+    ///The type of the map that stores the last
+    ///edges of the shortest paths.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef NullMap <typename GR::Node,typename GR::Edge> PredMap;
+    ///Instantiates a PredMap.
+ 
+    ///This function instantiates a \ref PredMap. 
+    ///\param g is the graph, to which we would like to define the PredMap.
+    ///\todo The graph alone may be insufficient for the initialization
+#ifdef DOXYGEN
+    static PredMap *createPredMap(const GR &g) 
+#else
+    static PredMap *createPredMap(const GR &) 
+#endif
+    {
+      return new PredMap();
+    }
+    ///The type of the map that stores whether a nodes is processed.
+ 
+    ///The type of the map that stores whether a nodes is processed.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///By default it is a NullMap.
+    ///\todo If it is set to a real map,
+    ///Dijkstra::processed() should read this.
+    ///\todo named parameter to set this type, function to read and write.
+    typedef NullMap<typename Graph::Node,bool> ProcessedMap;
+    ///Instantiates a ProcessedMap.
+ 
+    ///This function instantiates a \ref ProcessedMap. 
+    ///\param g is the graph, to which
+    ///we would like to define the \ref ProcessedMap
+#ifdef DOXYGEN
+    static ProcessedMap *createProcessedMap(const GR &g)
+#else
+    static ProcessedMap *createProcessedMap(const GR &)
+#endif
+    {
+      return new ProcessedMap();
+    }
+    ///The type of the map that stores the dists of the nodes.
+ 
+    ///The type of the map that stores the dists of the nodes.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef NullMap<typename Graph::Node,typename LM::Value> DistMap;
+    ///Instantiates a DistMap.
+ 
+    ///This function instantiates a \ref DistMap. 
+    ///\param g is the graph, to which we would like to define the \ref DistMap
+#ifdef DOXYGEN
+    static DistMap *createDistMap(const GR &g)
+#else
+    static DistMap *createDistMap(const GR &)
+#endif
+    {
+      return new DistMap();
+    }
+  };
+  
+  /// Default traits used by \ref DijkstraWizard
+
+  /// To make it easier to use Dijkstra algorithm
+  ///we have created a wizard class.
+  /// This \ref DijkstraWizard class needs default traits,
+  ///as well as the \ref Dijkstra class.
+  /// The \ref DijkstraWizardBase is a class to be the default traits of the
+  /// \ref DijkstraWizard class.
+  /// \todo More named parameters are required...
+  template<class GR,class LM>
+  class DijkstraWizardBase : public DijkstraWizardDefaultTraits<GR,LM>
+  {
+
+    typedef DijkstraWizardDefaultTraits<GR,LM> Base;
+  protected:
+    /// Type of the nodes in the graph.
+    typedef typename Base::Graph::Node Node;
+
+    /// Pointer to the underlying graph.
+    void *_g;
+    /// Pointer to the length map
+    void *_length;
+    ///Pointer to the map of predecessors edges.
+    void *_pred;
+    ///Pointer to the map of distances.
+    void *_dist;
+    ///Pointer to the source node.
+    Node _source;
+
+    public:
+    /// Constructor.
+    
+    /// This constructor does not require parameters, therefore it initiates
+    /// all of the attributes to default values (0, INVALID).
+    DijkstraWizardBase() : _g(0), _length(0), _pred(0),
+			   _dist(0), _source(INVALID) {}
+
+    /// Constructor.
+    
+    /// This constructor requires some parameters,
+    /// listed in the parameters list.
+    /// Others are initiated to 0.
+    /// \param g is the initial value of  \ref _g
+    /// \param l is the initial value of  \ref _length
+    /// \param s is the initial value of  \ref _source
+    DijkstraWizardBase(const GR &g,const LM &l, Node s=INVALID) :
+      _g(reinterpret_cast<void*>(const_cast<GR*>(&g))), 
+      _length(reinterpret_cast<void*>(const_cast<LM*>(&l))), 
+      _pred(0), _dist(0), _source(s) {}
+
+  };
+  
+  /// A class to make the usage of Dijkstra algorithm easier
+
+  /// This class is created to make it easier to use Dijkstra algorithm.
+  /// It uses the functions and features of the plain \ref Dijkstra,
+  /// but it is much simpler to use it.
+  ///
+  /// Simplicity means that the way to change the types defined
+  /// in the traits class is based on functions that returns the new class
+  /// and not on templatable built-in classes.
+  /// When using the plain \ref Dijkstra
+  /// the new class with the modified type comes from
+  /// the original class by using the ::
+  /// operator. In the case of \ref DijkstraWizard only
+  /// a function have to be called and it will
+  /// return the needed class.
+  ///
+  /// It does not have own \ref run method. When its \ref run method is called
+  /// it initiates a plain \ref Dijkstra class, and calls the \ref 
+  /// Dijkstra::run method of it.
+  template<class TR>
+  class DijkstraWizard : public TR
+  {
+    typedef TR Base;
+
+    ///The type of the underlying graph.
+    typedef typename TR::Graph Graph;
+    //\e
+    typedef typename Graph::Node Node;
+    //\e
+    typedef typename Graph::NodeIt NodeIt;
+    //\e
+    typedef typename Graph::Edge Edge;
+    //\e
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    
+    ///The type of the map that stores the edge lengths.
+    typedef typename TR::LengthMap LengthMap;
+    ///The type of the length of the edges.
+    typedef typename LengthMap::Value Value;
+    ///\brief The type of the map that stores the last
+    ///edges of the shortest paths.
+    typedef typename TR::PredMap PredMap;
+    ///The type of the map that stores the dists of the nodes.
+    typedef typename TR::DistMap DistMap;
+    ///The heap type used by the dijkstra algorithm.
+    typedef typename TR::Heap Heap;
+  public:
+    /// Constructor.
+    DijkstraWizard() : TR() {}
+
+    /// Constructor that requires parameters.
+
+    /// Constructor that requires parameters.
+    /// These parameters will be the default values for the traits class.
+    DijkstraWizard(const Graph &g,const LengthMap &l, Node s=INVALID) :
+      TR(g,l,s) {}
+
+    ///Copy constructor
+    DijkstraWizard(const TR &b) : TR(b) {}
+
+    ~DijkstraWizard() {}
+
+    ///Runs Dijkstra algorithm from a given node.
+    
+    ///Runs Dijkstra algorithm from a given node.
+    ///The node can be given by the \ref source function.
+    void run()
+    {
+      if(Base::_source==INVALID) throw UninitializedParameter();
+      Dijkstra<Graph,LengthMap,TR> 
+	dij(*reinterpret_cast<const Graph*>(Base::_g),
+            *reinterpret_cast<const LengthMap*>(Base::_length));
+      if(Base::_pred) dij.predMap(*reinterpret_cast<PredMap*>(Base::_pred));
+      if(Base::_dist) dij.distMap(*reinterpret_cast<DistMap*>(Base::_dist));
+      dij.run(Base::_source);
+    }
+
+    ///Runs Dijkstra algorithm from the given node.
+
+    ///Runs Dijkstra algorithm from the given node.
+    ///\param s is the given source.
+    void run(Node s)
+    {
+      Base::_source=s;
+      run();
+    }
+
+    template<class T>
+    struct DefPredMapBase : public Base {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph &) { return 0; };
+      DefPredMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting PredMap type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting PredMap type
+    ///
+    template<class T>
+    DijkstraWizard<DefPredMapBase<T> > predMap(const T &t) 
+    {
+      Base::_pred=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return DijkstraWizard<DefPredMapBase<T> >(*this);
+    }
+    
+    template<class T>
+    struct DefDistMapBase : public Base {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph &) { return 0; };
+      DefDistMapBase(const TR &b) : TR(b) {}
+    };
+    
+    ///\brief \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    /// \ref named-templ-param "Named parameter"
+    ///function for setting DistMap type
+    ///
+    template<class T>
+    DijkstraWizard<DefDistMapBase<T> > distMap(const T &t) 
+    {
+      Base::_dist=reinterpret_cast<void*>(const_cast<T*>(&t));
+      return DijkstraWizard<DefDistMapBase<T> >(*this);
+    }
+    
+    /// Sets the source node, from which the Dijkstra algorithm runs.
+
+    /// Sets the source node, from which the Dijkstra algorithm runs.
+    /// \param s is the source node.
+    DijkstraWizard<TR> &source(Node s) 
+    {
+      Base::_source=s;
+      return *this;
+    }
+    
+  };
+  
+  ///Function type interface for Dijkstra algorithm.
+
+  /// \ingroup shortest_path
+  ///Function type interface for Dijkstra algorithm.
+  ///
+  ///This function also has several
+  ///\ref named-templ-func-param "named parameters",
+  ///they are declared as the members of class \ref DijkstraWizard.
+  ///The following
+  ///example shows how to use these parameters.
+  ///\code
+  ///  dijkstra(g,length,source).predMap(preds).run();
+  ///\endcode
+  ///\warning Don't forget to put the \ref DijkstraWizard::run() "run()"
+  ///to the end of the parameter list.
+  ///\sa DijkstraWizard
+  ///\sa Dijkstra
+  template<class GR, class LM>
+  DijkstraWizard<DijkstraWizardBase<GR,LM> >
+  dijkstra(const GR &g,const LM &l,typename GR::Node s=INVALID)
+  {
+    return DijkstraWizard<DijkstraWizardBase<GR,LM> >(g,l,s);
+  }
+
+} //END OF NAMESPACE LEMON
+
+#endif
Index: lemon/dim2.h
===================================================================
--- lemon/dim2.h	(revision 2658)
+++ lemon/dim2.h	(revision 2562)
@@ -3,5 +3,5 @@
  * This file is a part of LEMON, a generic C++ optimization library
  *
- * Copyright (C) 2003-2006
+ * Copyright (C) 2003-2008
  * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
  * (Egervary Research Group on Combinatorial Optimization, EGRES).
@@ -53,7 +53,5 @@
 
   /// A simple two dimensional vector (plainvector) implementation
-  ///with the usual vector
-  /// operators.
-  ///
+  /// with the usual vector operations.
   template<typename T>
     class Point {
@@ -63,7 +61,7 @@
       typedef T Value;
 
-      ///First co-ordinate
+      ///First coordinate
       T x;
-      ///Second co-ordinate
+      ///Second coordinate
       T y;     
       
@@ -76,5 +74,5 @@
       ///The dimension of the vector.
 
-      ///This class give back always 2.
+      ///This function always returns 2.
       ///
       int size() const { return 2; }
@@ -100,5 +98,5 @@
       }
   
-      ///Increment the left hand side by u
+      ///Increment the left hand side by \c u
       Point<T>& operator +=(const Point<T>& u) {
         x += u.x;
@@ -107,5 +105,5 @@
       }
   
-      ///Decrement the left hand side by u
+      ///Decrement the left hand side by \c u
       Point<T>& operator -=(const Point<T>& u) {
         x -= u.x;
@@ -139,5 +137,5 @@
       }
 
-      ///Return the neg of the vectors
+      ///Return the negative of the vector
       Point<T> operator-() const {
         Point<T> b=*this;
@@ -176,7 +174,7 @@
     };
 
-  ///Return an Point 
-
-  ///Return an Point
+  ///Return a Point 
+
+  ///Return a Point.
   ///\relates Point
   template <typename T>
@@ -273,5 +271,5 @@
   ///
   ///\author Attila Bernath
-  template<typename T>
+    template<typename T>
     class BoundingBox {
       Point<T> bottom_left, top_right;
@@ -284,10 +282,46 @@
       ///Construct an instance from one point
       BoundingBox(Point<T> a) { bottom_left=top_right=a; _empty = false; }
-
-      ///Were any points added?
+      
+      ///Construct an instance from two points
+      
+      ///Construct an instance from two points.
+      ///\param a The bottom left corner.
+      ///\param b The top right corner.
+      ///\warning The coordinates of the bottom left corner must be no more
+      ///than those of the top right one.
+      BoundingBox(Point<T> a,Point<T> b)
+      {
+	bottom_left=a;
+	top_right=b;
+	_empty = false;
+      }
+      
+      ///Construct an instance from four numbers
+
+      ///Construct an instance from four numbers.
+      ///\param l The left side of the box.
+      ///\param b The bottom of the box.
+      ///\param r The right side of the box.
+      ///\param t The top of the box.
+      ///\warning The left side must be no more than the right side and
+      ///bottom must be no more than the top. 
+      BoundingBox(T l,T b,T r,T t)
+      {
+	bottom_left=Point<T>(l,b);
+	top_right=Point<T>(r,t);
+	_empty = false;
+      }
+      
+      ///Return \c true if the bounding box is empty.
+      
+      ///Return \c true if the bounding box is empty (i.e. return \c false
+      ///if at least one point was added to the box or the coordinates of
+      ///the box were set).
+      ///
+      ///The coordinates of an empty bounding box are not defined. 
       bool empty() const {
         return _empty;
       }
-
+      
       ///Make the BoundingBox empty
       void clear() {
@@ -295,7 +329,7 @@
       }
 
-      ///Give back the bottom left corner
-
-      ///Give back the bottom left corner.
+      ///Give back the bottom left corner of the box
+
+      ///Give back the bottom left corner of the box.
       ///If the bounding box is empty, then the return value is not defined.
       Point<T> bottomLeft() const {
@@ -303,15 +337,15 @@
       }
 
-      ///Set the bottom left corner
-
-      ///Set the bottom left corner.
-      ///It should only bee used for non-empty box.
+      ///Set the bottom left corner of the box
+
+      ///Set the bottom left corner of the box.
+      ///It should only be used for non-empty box.
       void bottomLeft(Point<T> p) {
 	bottom_left = p;
       }
 
-      ///Give back the top right corner
-
-      ///Give back the top right corner.
+      ///Give back the top right corner of the box
+
+      ///Give back the top right corner of the box.
       ///If the bounding box is empty, then the return value is not defined.
       Point<T> topRight() const {
@@ -319,15 +353,15 @@
       }
 
-      ///Set the top right corner
-
-      ///Set the top right corner.
-      ///It should only bee used for non-empty box.
+      ///Set the top right corner of the box
+
+      ///Set the top right corner of the box.
+      ///It should only be used for non-empty box.
       void topRight(Point<T> p) {
 	top_right = p;
       }
 
-      ///Give back the bottom right corner
-
-      ///Give back the bottom right corner.
+      ///Give back the bottom right corner of the box
+
+      ///Give back the bottom right corner of the box.
       ///If the bounding box is empty, then the return value is not defined.
       Point<T> bottomRight() const {
@@ -335,8 +369,8 @@
       }
 
-      ///Set the bottom right corner
-
-      ///Set the bottom right corner.
-      ///It should only bee used for non-empty box.
+      ///Set the bottom right corner of the box
+
+      ///Set the bottom right corner of the box.
+      ///It should only be used for non-empty box.
       void bottomRight(Point<T> p) {
 	top_right.x = p.x;
@@ -344,7 +378,7 @@
       }
  
-      ///Give back the top left corner
-
-      ///Give back the top left corner.
+      ///Give back the top left corner of the box
+
+      ///Give back the top left corner of the box.
       ///If the bounding box is empty, then the return value is not defined.
       Point<T> topLeft() const {
@@ -352,8 +386,8 @@
       }
 
-      ///Set the top left corner
-
-      ///Set the top left corner.
-      ///It should only bee used for non-empty box.
+      ///Set the top left corner of the box
+
+      ///Set the top left corner of the box.
+      ///It should only be used for non-empty box.
       void topLeft(Point<T> p) {
 	top_right.y = p.y;
@@ -372,5 +406,5 @@
 
       ///Set the bottom of the box.
-      ///It should only bee used for non-empty box.
+      ///It should only be used for non-empty box.
       void bottom(T t) {
 	bottom_left.y = t;
@@ -388,5 +422,5 @@
 
       ///Set the top of the box.
-      ///It should only bee used for non-empty box.
+      ///It should only be used for non-empty box.
       void top(T t) {
 	top_right.y = t;
@@ -404,5 +438,5 @@
 
       ///Set the left side of the box.
-      ///It should only bee used for non-empty box
+      ///It should only be used for non-empty box.
       void left(T t) {
 	bottom_left.x = t;
@@ -420,5 +454,5 @@
 
       ///Set the right side of the box.
-      ///It should only bee used for non-empty box
+      ///It should only be used for non-empty box.
       void right(T t) {
 	top_right.x = t;
@@ -442,5 +476,5 @@
 
       ///Checks whether a point is inside a bounding box
-      bool inside(const Point<T>& u){
+      bool inside(const Point<T>& u) const {
         if (_empty)
           return false;
@@ -452,4 +486,7 @@
   
       ///Increments a bounding box with a point
+
+      ///Increments a bounding box with a point.
+      ///
       BoundingBox& add(const Point<T>& u){
         if (_empty){
@@ -466,5 +503,8 @@
       }
     
-      ///Increments a bounding to contain another bounding box
+      ///Increments a bounding box to contain another bounding box
+      
+      ///Increments a bounding box to contain another bounding box.
+      ///
       BoundingBox& add(const BoundingBox &u){
         if ( !u.empty() ){
@@ -476,12 +516,19 @@
   
       ///Intersection of two bounding boxes
-      BoundingBox operator &(const BoundingBox& u){
+
+      ///Intersection of two bounding boxes.
+      ///
+      BoundingBox operator&(const BoundingBox& u) const {
         BoundingBox b;
-	b.bottom_left.x=std::max(this->bottom_left.x,u.bottom_left.x);
-	b.bottom_left.y=std::max(this->bottom_left.y,u.bottom_left.y);
-	b.top_right.x=std::min(this->top_right.x,u.top_right.x);
-	b.top_right.y=std::min(this->top_right.y,u.top_right.y);
-	b._empty = this->_empty || u._empty ||
-	  b.bottom_left.x>top_right.x && b.bottom_left.y>top_right.y;
+        if (this->_empty || u._empty) {
+	  b._empty = true;
+	} else {
+	  b.bottom_left.x=std::max(this->bottom_left.x,u.bottom_left.x);
+	  b.bottom_left.y=std::max(this->bottom_left.y,u.bottom_left.y);
+	  b.top_right.x=std::min(this->top_right.x,u.top_right.x);
+	  b.top_right.y=std::min(this->top_right.y,u.top_right.y);
+	  b._empty = b.bottom_left.x > b.top_right.x ||
+	             b.bottom_left.y > b.top_right.y;
+	} 
         return b;
       }
@@ -490,8 +537,8 @@
 
 
-  ///Map of x-coordinates of a dim2::Point<>-map
-
-  ///\ingroup maps
-  ///Map of x-coordinates of a dim2::Point<>-map
+  ///Map of x-coordinates of a \ref Point "Point"-map
+
+  ///\ingroup maps
+  ///Map of x-coordinates of a \ref Point "Point"-map.
   ///
   template<class M>
@@ -547,5 +594,5 @@
   ///Returns a \ref ConstXMap class
 
-  ///This function just returns an \ref ConstXMap class.
+  ///This function just returns a \ref ConstXMap class.
   ///
   ///\ingroup maps
@@ -557,8 +604,8 @@
   }
 
-  ///Map of y-coordinates of a dim2::Point<>-map
+  ///Map of y-coordinates of a \ref Point "Point"-map
     
   ///\ingroup maps
-  ///Map of y-coordinates of a dim2::Point<>-map
+  ///Map of y-coordinates of a \ref Point "Point"-map.
   ///
   template<class M>
@@ -576,7 +623,7 @@
   };
 
-  ///Returns an \ref YMap class
-
-  ///This function just returns an \ref YMap class.
+  ///Returns a \ref YMap class
+
+  ///This function just returns a \ref YMap class.
   ///
   ///\ingroup maps
@@ -614,5 +661,5 @@
   ///Returns a \ref ConstYMap class
 
-  ///This function just returns an \ref ConstYMap class.
+  ///This function just returns a \ref ConstYMap class.
   ///
   ///\ingroup maps
@@ -625,10 +672,10 @@
 
 
-    ///\brief Map of the \ref Point::normSquare() "normSquare()"
-    ///of an \ref Point "Point"-map
-    ///
-    ///Map of the \ref Point::normSquare() "normSquare()"
-    ///of an \ref Point "Point"-map
-    ///\ingroup maps
+  ///\brief Map of the \ref Point::normSquare() "normSquare()"
+  ///of a \ref Point "Point"-map
+  ///
+  ///Map of the \ref Point::normSquare() "normSquare()"
+  ///of a \ref Point "Point"-map.
+  ///\ingroup maps
     ///
   template<class M>
@@ -647,5 +694,5 @@
   ///Returns a \ref NormSquareMap class
 
-  ///This function just returns an \ref NormSquareMap class.
+  ///This function just returns a \ref NormSquareMap class.
   ///
   ///\ingroup maps
Index: lemon/dimacs.h
===================================================================
--- lemon/dimacs.h	(revision 2553)
+++ lemon/dimacs.h	(revision 2553)
@@ -0,0 +1,260 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_DIMACS_H
+#define LEMON_DIMACS_H
+
+#include <iostream>
+#include <string>
+#include <vector>
+#include <lemon/maps.h>
+#include <lemon/bits/invalid.h>
+
+/// \ingroup dimacs_group
+/// \file
+/// \brief DIMACS file format reader.
+
+namespace lemon {
+
+  ///@defgroup dimacs_group DIMACS format
+  ///\brief Read and write files in DIMACS format
+  ///
+  ///Tools to read a graph from or write it to a file in DIMACS format
+  ///data
+  ///\ingroup io_group
+
+  /// \addtogroup dimacs_group
+  /// @{
+  
+  /// DIMACS min cost flow reader function.
+  ///
+  /// This function reads a min cost flow instance from DIMACS format,
+  /// i.e. from DIMACS files having a line starting with
+  /// \code
+  ///   p min
+  /// \endcode
+  /// At the beginning \c g is cleared by \c g.clear(). The supply 
+  /// amount of the nodes are written to \c supply (signed). The 
+  /// lower bounds, capacities and costs of the edges are written to 
+  /// \c lower, \c capacity and \c cost.
+  ///
+  /// \author Marton Makai and Peter Kovacs
+  template <typename Graph, typename LowerMap, 
+    typename CapacityMap, typename CostMap, 
+    typename SupplyMap>
+  void readDimacs( std::istream& is,
+		   Graph &g,
+		   LowerMap& lower, 
+		   CapacityMap& capacity, 
+		   CostMap& cost,
+		   SupplyMap& supply )
+  {
+    g.clear();
+    std::vector<typename Graph::Node> nodes;
+    typename Graph::Edge e;
+    std::string problem, str;
+    char c;
+    int n, m; 
+    int i, j;
+    typename SupplyMap::Value sup;
+    typename CapacityMap::Value low;
+    typename CapacityMap::Value cap;
+    typename CostMap::Value co;
+    while (is >> c) {
+      switch (c) {
+      case 'c': // comment line
+	getline(is, str);
+	break;
+      case 'p': // problem definition line
+	is >> problem >> n >> m;
+	getline(is, str);
+	if (problem != "min") return;
+	nodes.resize(n + 1);
+	for (int k = 1; k <= n; ++k) {
+	  nodes[k] = g.addNode();
+	  supply.set(nodes[k], 0);
+	}
+	break;
+      case 'n': // node definition line
+	is >> i >> sup;
+	getline(is, str);
+	supply.set(nodes[i], sup);
+	break;
+      case 'a': // edge (arc) definition line
+	is >> i >> j >> low >> cap >> co;
+	getline(is, str);
+	e = g.addEdge(nodes[i], nodes[j]);
+	lower.set(e, low);
+	if (cap >= 0)
+	  capacity.set(e, cap);
+	else
+	  capacity.set(e, -1);
+	cost.set(e, co);
+	break;
+      }
+    }
+  }
+
+  /// DIMACS max flow reader function.
+  ///
+  /// This function reads a max flow instance from DIMACS format,
+  /// i.e. from DIMACS files having a line starting with
+  /// \code
+  ///   p max
+  /// \endcode
+  /// At the beginning \c g is cleared by \c g.clear(). The edge 
+  /// capacities are written to \c capacity and \c s and \c t are
+  /// set to the source and the target nodes.
+  ///
+  /// \author Marton Makai
+  template<typename Graph, typename CapacityMap>
+  void readDimacs(std::istream& is, Graph &g, CapacityMap& capacity, 
+		  typename Graph::Node &s, typename Graph::Node &t) {
+    g.clear();
+    std::vector<typename Graph::Node> nodes;
+    typename Graph::Edge e;
+    std::string problem;
+    char c, d;
+    int n, m; 
+    int i, j;
+    typename CapacityMap::Value _cap;
+    std::string str;
+    while (is >> c) {
+      switch (c) {
+      case 'c': // comment line
+	getline(is, str);
+	break;
+      case 'p': // problem definition line
+	is >> problem >> n >> m;
+	getline(is, str);
+	nodes.resize(n + 1);
+	for (int k = 1; k <= n; ++k)
+	  nodes[k] = g.addNode();
+	break;
+      case 'n': // node definition line
+	if (problem == "sp") { // shortest path problem
+	  is >> i;
+	  getline(is, str);
+	  s = nodes[i];
+	}
+	if (problem == "max") { // max flow problem
+	  is >> i >> d;
+	  getline(is, str);
+	  if (d == 's') s = nodes[i];
+	  if (d == 't') t = nodes[i];
+	}
+	break;
+      case 'a': // edge (arc) definition line
+	if (problem == "max" || problem == "sp") {
+	  is >> i >> j >> _cap;
+	  getline(is, str);
+	  e = g.addEdge(nodes[i], nodes[j]);
+	  capacity.set(e, _cap);
+	} else {
+	  is >> i >> j;
+	  getline(is, str);
+	  g.addEdge(nodes[i], nodes[j]);
+	}
+	break;
+      }
+    }
+  }
+
+  /// DIMACS shortest path reader function.
+  ///
+  /// This function reads a shortest path instance from DIMACS format,
+  /// i.e. from DIMACS files having a line starting with
+  /// \code
+  ///   p sp
+  /// \endcode
+  /// At the beginning \c g is cleared by \c g.clear(). The edge
+  /// capacities are written to \c capacity and \c s is set to the
+  /// source node.
+  ///
+  /// \author Marton Makai
+  template<typename Graph, typename CapacityMap>
+  void readDimacs(std::istream& is, Graph &g, CapacityMap& capacity, 
+		  typename Graph::Node &s) {
+    readDimacs(is, g, capacity, s, s);
+  }
+
+  /// DIMACS capacitated graph reader function.
+  ///
+  /// This function reads an edge capacitated graph instance from
+  /// DIMACS format. At the beginning \c g is cleared by \c g.clear()
+  /// and the edge capacities are written to \c capacity.
+  ///
+  /// \author Marton Makai
+  template<typename Graph, typename CapacityMap>
+  void readDimacs(std::istream& is, Graph &g, CapacityMap& capacity) {
+    typename Graph::Node u;
+    readDimacs(is, g, capacity, u, u);
+  }
+
+  /// DIMACS plain graph reader function.
+  ///
+  /// This function reads a graph without any designated nodes and
+  /// maps from DIMACS format, i.e. from DIMACS files having a line
+  /// starting with
+  /// \code
+  ///   p mat
+  /// \endcode
+  /// At the beginning \c g is cleared by \c g.clear().
+  ///
+  /// \author Marton Makai
+  template<typename Graph>
+  void readDimacs(std::istream& is, Graph &g) {
+    typename Graph::Node u;
+    NullMap<typename Graph::Edge, int> n;
+    readDimacs(is, g, n, u, u);
+  }
+  
+  /// DIMACS plain graph writer function.
+  ///
+  /// This function writes a graph without any designated nodes and
+  /// maps into DIMACS format, i.e. into DIMACS file having a line 
+  /// starting with
+  /// \code
+  ///   p mat
+  /// \endcode
+  ///
+  /// \author Marton Makai
+  template<typename Graph>
+  void writeDimacs(std::ostream& os, const Graph &g) {
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::EdgeIt EdgeIt;  
+    
+    os << "c matching problem" << std::endl;
+    os << "p mat " << g.nodeNum() << " " << g.edgeNum() << std::endl;
+
+    typename Graph::template NodeMap<int> nodes(g);
+    int i = 1;
+    for(NodeIt v(g); v != INVALID; ++v) {
+      nodes.set(v, i);
+      ++i;
+    }    
+    for(EdgeIt e(g); e != INVALID; ++e) {
+      os << "a " << nodes[g.source(e)] << " " << nodes[g.target(e)] << std::endl; 
+    }
+  }
+
+  /// @}
+
+} //namespace lemon
+
+#endif //LEMON_DIMACS_H
Index: lemon/dinitz_sleator_tarjan.h
===================================================================
--- lemon/dinitz_sleator_tarjan.h	(revision 2553)
+++ lemon/dinitz_sleator_tarjan.h	(revision 2553)
@@ -0,0 +1,765 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_DINITZ_SLEATOR_TARJAN_H
+#define LEMON_DINITZ_SLEATOR_TARJAN_H
+
+/// \file 
+/// \ingroup max_flow 
+/// \brief Implementation the dynamic tree data structure of Sleator
+/// and Tarjan.
+
+#include <lemon/graph_utils.h>
+#include <lemon/tolerance.h>
+#include <lemon/dynamic_tree.h>
+
+#include <vector>
+#include <limits>
+#include <fstream>
+
+
+namespace lemon {
+
+  /// \brief Default traits class of DinitzSleatorTarjan class.
+  ///
+  /// Default traits class of DinitzSleatorTarjan class.
+  /// \param _Graph Graph type.
+  /// \param _CapacityMap Type of capacity map.
+  template <typename _Graph, typename _CapacityMap>
+  struct DinitzSleatorTarjanDefaultTraits {
+
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge capacities.
+    ///
+    /// The type of the map that stores the edge capacities.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _CapacityMap CapacityMap;
+
+    /// \brief The type of the length of the edges.
+    typedef typename CapacityMap::Value Value;
+
+    /// \brief The map type that stores the flow values.
+    ///
+    /// The map type that stores the flow values. 
+    /// It must meet the \ref concepts::ReadWriteMap "ReadWriteMap" concept.
+    typedef typename Graph::template EdgeMap<Value> FlowMap;
+
+    /// \brief Instantiates a FlowMap.
+    ///
+    /// This function instantiates a \ref FlowMap. 
+    /// \param graph The graph, to which we would like to define the flow map.
+    static FlowMap* createFlowMap(const Graph& graph) {
+      return new FlowMap(graph);
+    }
+
+    /// \brief The tolerance used by the algorithm
+    ///
+    /// The tolerance used by the algorithm to handle inexact computation.
+    typedef Tolerance<Value> Tolerance;
+
+  };
+
+  /// \ingroup max_flow
+  ///
+  /// \brief Dinitz-Sleator-Tarjan algorithms class.
+  ///
+  /// This class provides an implementation of the \e
+  /// Dinitz-Sleator-Tarjan \e algorithm producing a flow of maximum
+  /// value in a directed graph. The DinitzSleatorTarjan algorithm is
+  /// the fastest known max flow algorithms wich using blocking
+  /// flow. It is an improvement of the Dinitz algorithm by using the
+  /// \ref DynamicTree "dynamic tree" data structure of Sleator and
+  /// Tarjan.
+  ///
+  /// This blocking flow algorithms builds a layered graph according
+  /// to \ref Bfs "breadth-first search" distance from the target node
+  /// in the reversed residual graph. The layered graph contains each
+  /// residual edge which steps one level down. After that the
+  /// algorithm constructs a blocking flow on the layered graph and
+  /// augments the overall flow with it. The number of the levels in
+  /// the layered graph is strictly increasing in each augmenting
+  /// phase therefore the number of the augmentings is at most
+  /// \f$n-1\f$.  The length of each phase is at most
+  /// \f$O(m\log(n))\f$, that the overall time complexity is
+  /// \f$O(nm\log(n))\f$.
+  ///
+  /// \param _Graph The directed graph type the algorithm runs on.
+  /// \param _CapacityMap The capacity map type.
+  /// \param _Traits Traits class to set various data types used by
+  /// the algorithm.  The default traits class is \ref
+  /// DinitzSleatorTarjanDefaultTraits.  See \ref
+  /// DinitzSleatorTarjanDefaultTraits for the documentation of a
+  /// Dinitz-Sleator-Tarjan traits class.
+  ///
+  /// \author Tamas Hamori and Balazs Dezso
+#ifdef DOXYGEN
+  template <typename _Graph, typename _CapacityMap, typename _Traits>
+#else
+  template <typename _Graph, 
+	    typename _CapacityMap = typename _Graph::template EdgeMap<int>,
+	    typename _Traits = 
+	    DinitzSleatorTarjanDefaultTraits<_Graph, _CapacityMap> >
+#endif
+  class DinitzSleatorTarjan {
+  public:
+
+    typedef _Traits Traits;
+    typedef typename Traits::Graph Graph;
+    typedef typename Traits::CapacityMap CapacityMap;
+    typedef typename Traits::Value Value; 
+
+    typedef typename Traits::FlowMap FlowMap;
+    typedef typename Traits::Tolerance Tolerance;
+
+
+  private:
+
+    GRAPH_TYPEDEFS(typename Graph);
+
+
+    typedef typename Graph::template NodeMap<int> LevelMap;
+    typedef typename Graph::template NodeMap<int> IntNodeMap;
+    typedef typename Graph::template NodeMap<Edge> EdgeNodeMap;
+    typedef DynamicTree<Value, IntNodeMap, Tolerance, false> DynTree;
+
+  private:
+    
+    const Graph& _graph;
+    const CapacityMap* _capacity;
+
+    Node _source, _target;
+
+    FlowMap* _flow;
+    bool _local_flow;
+
+    IntNodeMap* _level;
+    EdgeNodeMap* _dt_edges;
+    
+    IntNodeMap* _dt_index;
+    DynTree* _dt;
+
+    std::vector<Node> _queue;
+
+    Tolerance _tolerance;
+    
+    Value _flow_value;
+    Value _max_value;
+
+
+  public:
+
+    typedef DinitzSleatorTarjan Create;
+
+    ///\name Named template parameters
+
+    ///@{
+
+    template <typename _FlowMap>
+    struct DefFlowMapTraits : public Traits {
+      typedef _FlowMap FlowMap;
+      static FlowMap *createFlowMap(const Graph&) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// FlowMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting FlowMap
+    /// type
+    template <typename _FlowMap>
+    struct DefFlowMap 
+      : public DinitzSleatorTarjan<Graph, CapacityMap, 
+			      DefFlowMapTraits<_FlowMap> > {
+      typedef DinitzSleatorTarjan<Graph, CapacityMap, 
+			     DefFlowMapTraits<_FlowMap> > Create;
+    };
+
+    template <typename _Elevator>
+    struct DefElevatorTraits : public Traits {
+      typedef _Elevator Elevator;
+      static Elevator *createElevator(const Graph&, int) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// @}
+
+    /// \brief \ref Exception for the case when the source equals the target.
+    ///
+    /// \ref Exception for the case when the source equals the target.
+    ///
+    class InvalidArgument : public lemon::LogicError {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::DinitzSleatorTarjan::InvalidArgument";
+      }
+    };
+
+  protected:
+    
+    DinitzSleatorTarjan() {}
+
+  public:
+
+    /// \brief The constructor of the class.
+    ///
+    /// The constructor of the class. 
+    /// \param graph The directed graph the algorithm runs on. 
+    /// \param capacity The capacity of the edges. 
+    /// \param source The source node.
+    /// \param target The target node.
+    DinitzSleatorTarjan(const Graph& graph, const CapacityMap& capacity,
+			Node source, Node target)
+      : _graph(graph), _capacity(&capacity),
+	_source(source), _target(target),
+	_flow(0), _local_flow(false),
+	_level(0), _dt_edges(0),
+	_dt_index(0), _dt(0), _queue(),
+	_tolerance(), _flow_value(), _max_value()
+    {
+      if (_source == _target) {
+	throw InvalidArgument();
+      }
+    }
+
+    /// \brief Destrcutor.
+    ///
+    /// Destructor.
+    ~DinitzSleatorTarjan() {
+      destroyStructures();
+    }
+
+    /// \brief Sets the capacity map.
+    ///
+    /// Sets the capacity map.
+    /// \return \c (*this)
+    DinitzSleatorTarjan& capacityMap(const CapacityMap& map) {
+      _capacity = &map;
+      return *this;
+    }
+
+    /// \brief Sets the flow map.
+    ///
+    /// Sets the flow map.
+    /// \return \c (*this)
+    DinitzSleatorTarjan& flowMap(FlowMap& map) {
+      if (_local_flow) {
+	delete _flow;
+	_local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Returns the flow map.
+    ///
+    /// \return The flow map.
+    const FlowMap& flowMap() {
+      return *_flow;
+    }
+
+    /// \brief Sets the source node.
+    ///
+    /// Sets the source node.
+    /// \return \c (*this)
+    DinitzSleatorTarjan& source(const Node& node) {
+      _source = node;
+      return *this;
+    }
+
+    /// \brief Sets the target node.
+    ///
+    /// Sets the target node.
+    /// \return \c (*this)
+    DinitzSleatorTarjan& target(const Node& node) {
+      _target = node;
+      return *this;
+    }
+
+    /// \brief Sets the tolerance used by algorithm.
+    ///
+    /// Sets the tolerance used by algorithm.
+    DinitzSleatorTarjan& tolerance(const Tolerance& tolerance) const {
+      _tolerance = tolerance;
+      if (_dt) {
+	_dt.tolerance(_tolerance);
+      }
+      return *this;
+    } 
+
+    /// \brief Returns the tolerance used by algorithm.
+    ///
+    /// Returns the tolerance used by algorithm.
+    const Tolerance& tolerance() const {
+      return tolerance;
+    } 
+
+  private:
+        
+    void createStructures() {
+      if (!_flow) {
+	_flow = Traits::createFlowMap(_graph);
+	_local_flow = true;
+      }
+      if (!_level) {
+	_level = new LevelMap(_graph);
+      }
+      if (!_dt_index && !_dt) {
+	_dt_index = new IntNodeMap(_graph);
+	_dt = new DynTree(*_dt_index, _tolerance);
+      }
+      if (!_dt_edges) {
+	_dt_edges = new EdgeNodeMap(_graph);
+      }
+      _queue.resize(countNodes(_graph));
+      _max_value = _dt->maxValue();
+    }
+
+    void destroyStructures() {
+      if (_local_flow) {
+	delete _flow;
+      }
+      if (_level) {
+	delete _level;
+      }
+      if (_dt) {
+	delete _dt;
+      }
+      if (_dt_index) {
+	delete _dt_index;
+      }
+      if (_dt_edges) {
+	delete _dt_edges;
+      }
+    }
+
+    bool createLayeredGraph() {
+
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	_level->set(n, -2);
+      }
+      
+      int level = 0;
+
+      _queue[0] = _target;
+      _level->set(_target, level);
+
+      int first = 0, last = 1, limit = 0;
+      
+      while (first != last && (*_level)[_source] == -2) {
+	if (first == limit) {
+	  limit = last;
+	  ++level;
+	}
+	
+	Node n = _queue[first++];
+	  
+	for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Node v = _graph.target(e);
+	  if ((*_level)[v] != -2) continue;
+	  Value rem = (*_flow)[e];
+	  if (!_tolerance.positive(rem)) continue;
+	  _level->set(v, level);
+	  _queue[last++] = v;
+	}
+	
+	for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Node v = _graph.source(e);
+	  if ((*_level)[v] != -2) continue;
+	  Value rem = (*_capacity)[e] - (*_flow)[e];
+	  if (!_tolerance.positive(rem)) continue;
+	  _level->set(v, level);
+	  _queue[last++] = v;
+	}
+      }
+      return (*_level)[_source] != -2;
+    }
+
+    void initEdges() {
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	_graph.firstOut((*_dt_edges)[n], n);
+      }
+    }
+        
+    
+    void augmentPath() {
+      Value rem;
+      Node n = _dt->findCost(_source, rem);
+      _flow_value += rem;
+      _dt->addCost(_source, - rem);
+
+      _dt->cut(n);
+      _dt->addCost(n, _max_value);
+
+      Edge e = (*_dt_edges)[n];
+      if (_graph.source(e) == n) {
+	_flow->set(e, (*_capacity)[e]);
+	
+	_graph.nextOut(e);
+	if (e == INVALID) {
+	  _graph.firstIn(e, n);
+	}
+      } else {
+	_flow->set(e, 0);
+	_graph.nextIn(e);
+      }
+      _dt_edges->set(n, e);
+
+    }
+
+    bool advance(Node n) {
+      Edge e = (*_dt_edges)[n];
+      if (e == INVALID) return false;
+
+      Node u;
+      Value rem;      
+      if (_graph.source(e) == n) {
+	u = _graph.target(e);
+	while ((*_level)[n] != (*_level)[u] + 1 || 
+	       !_tolerance.positive((*_capacity)[e] - (*_flow)[e])) {
+	  _graph.nextOut(e);
+	  if (e == INVALID) break;
+	  u = _graph.target(e);
+	}
+	if (e != INVALID) {
+	  rem = (*_capacity)[e] - (*_flow)[e];
+	} else {
+	  _graph.firstIn(e, n);
+	  if (e == INVALID) {
+	    _dt_edges->set(n, INVALID);
+	    return false;
+	  }
+	  u = _graph.source(e);
+	  while ((*_level)[n] != (*_level)[u] + 1 ||
+		 !_tolerance.positive((*_flow)[e])) {
+	    _graph.nextIn(e);
+	    if (e == INVALID) {
+	      _dt_edges->set(n, INVALID);
+	      return false;
+	    }
+	    u = _graph.source(e);
+	  }
+	  rem = (*_flow)[e];
+	}
+      } else {
+	u = _graph.source(e);
+	while ((*_level)[n] != (*_level)[u] + 1 ||
+	       !_tolerance.positive((*_flow)[e])) {
+	  _graph.nextIn(e);
+	  if (e == INVALID) {
+	    _dt_edges->set(n, INVALID);
+	    return false;
+	  }
+	  u = _graph.source(e);
+	}
+	rem = (*_flow)[e];
+      }
+
+      _dt->addCost(n, - std::numeric_limits<Value>::max());
+      _dt->addCost(n, rem);
+      _dt->link(n, u);
+      _dt_edges->set(n, e);
+      return true;
+    }
+
+    void retreat(Node n) {
+      _level->set(n, -1);
+      
+      for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	Node u = _graph.target(e);
+	if ((*_dt_edges)[u] == e && _dt->findRoot(u) == n) {
+	  Value rem;
+	  _dt->findCost(u, rem);
+	  _flow->set(e, rem);
+	  _dt->cut(u);
+	  _dt->addCost(u, - rem);
+	  _dt->addCost(u, _max_value);
+	}
+      }
+      for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	Node u = _graph.source(e);
+	if ((*_dt_edges)[u] == e && _dt->findRoot(u) == n) {
+	  Value rem;
+	  _dt->findCost(u, rem);
+	  _flow->set(e, (*_capacity)[e] - rem);
+	  _dt->cut(u);
+	  _dt->addCost(u, - rem);
+	  _dt->addCost(u, _max_value);
+	}
+      }
+    }
+
+    void extractTrees() {
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	
+	Node w = _dt->findRoot(n);
+      
+	while (w != n) {
+      
+	  Value rem;      
+	  Node u = _dt->findCost(n, rem);
+
+	  _dt->cut(u);
+	  _dt->addCost(u, - rem);
+	  _dt->addCost(u, _max_value);
+	  
+	  Edge e = (*_dt_edges)[u];
+	  _dt_edges->set(u, INVALID);
+	  
+	  if (u == _graph.source(e)) {
+	    _flow->set(e, (*_capacity)[e] - rem);
+	  } else {
+	    _flow->set(e, rem);
+	  }
+	  
+	  w = _dt->findRoot(n);
+	}      
+      }
+    }
+
+
+  public:
+    
+    /// \name Execution control The simplest way to execute the
+    /// algorithm is to use the \c run() member functions.
+    /// \n
+    /// If you need more control on initial solution or
+    /// execution then you have to call one \ref init() function and then
+    /// the start() or multiple times the \c augment() member function.  
+    
+    ///@{
+
+    /// \brief Initializes the algorithm
+    /// 
+    /// It sets the flow to empty flow.
+    void init() {
+      createStructures();
+
+      _dt->clear();
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+        _dt->makeTree(n);
+        _dt->addCost(n, _max_value);
+      }
+
+      for (EdgeIt it(_graph); it != INVALID; ++it) {
+        _flow->set(it, 0);
+      }
+      _flow_value = 0;
+    }
+    
+    /// \brief Initializes the algorithm
+    /// 
+    /// Initializes the flow to the \c flowMap. The \c flowMap should
+    /// contain a feasible flow, ie. in each node excluding the source
+    /// and the target the incoming flow should be equal to the
+    /// outgoing flow.
+    template <typename FlowMap>
+    void flowInit(const FlowMap& flowMap) {
+      createStructures();
+
+      _dt->clear();
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+        _dt->makeTree(n);
+        _dt->addCost(n, _max_value);
+      }
+
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+	_flow->set(e, flowMap[e]);
+      }
+      _flow_value = 0;
+      for (OutEdgeIt jt(_graph, _source); jt != INVALID; ++jt) {
+        _flow_value += (*_flow)[jt];
+      }
+      for (InEdgeIt jt(_graph, _source); jt != INVALID; ++jt) {
+        _flow_value -= (*_flow)[jt];
+      }
+    }
+
+    /// \brief Initializes the algorithm
+    /// 
+    /// Initializes the flow to the \c flowMap. The \c flowMap should
+    /// contain a feasible flow, ie. in each node excluding the source
+    /// and the target the incoming flow should be equal to the
+    /// outgoing flow.  
+    /// \return %False when the given flowMap does not contain
+    /// feasible flow.
+    template <typename FlowMap>
+    bool checkedFlowInit(const FlowMap& flowMap) {
+      createStructures();
+
+      _dt->clear();
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+        _dt->makeTree(n);
+        _dt->addCost(n, _max_value);
+      }
+
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+	_flow->set(e, flowMap[e]);
+      }
+      for (NodeIt it(_graph); it != INVALID; ++it) {
+        if (it == _source || it == _target) continue;
+        Value outFlow = 0;
+        for (OutEdgeIt jt(_graph, it); jt != INVALID; ++jt) {
+          outFlow += (*_flow)[jt];
+        }
+        Value inFlow = 0;
+        for (InEdgeIt jt(_graph, it); jt != INVALID; ++jt) {
+          inFlow += (*_flow)[jt];
+        }
+        if (_tolerance.different(outFlow, inFlow)) {
+          return false;
+        }
+      }
+      for (EdgeIt it(_graph); it != INVALID; ++it) {
+        if (_tolerance.less((*_flow)[it], 0)) return false;
+        if (_tolerance.less((*_capacity)[it], (*_flow)[it])) return false;
+      }
+      _flow_value = 0;
+      for (OutEdgeIt jt(_graph, _source); jt != INVALID; ++jt) {
+        _flow_value += (*_flow)[jt];
+      }
+      for (InEdgeIt jt(_graph, _source); jt != INVALID; ++jt) {
+        _flow_value -= (*_flow)[jt];
+      }
+      return true;
+    }
+
+    /// \brief Executes the algorithm
+    ///
+    /// It runs augmenting phases by adding blocking flow until the
+    /// optimal solution is reached.
+    void start() {
+      while (augment());
+    }
+
+    /// \brief Augments the flow with a blocking flow on a layered
+    /// graph.
+    /// 
+    /// This function builds a layered graph and then find a blocking
+    /// flow on this graph. The number of the levels in the layered
+    /// graph is strictly increasing in each augmenting phase
+    /// therefore the number of the augmentings is at most \f$ n-1
+    /// \f$.  The length of each phase is at most \f$ O(m \log(n))
+    /// \f$, that the overall time complexity is \f$ O(nm \log(n)) \f$.
+    /// \return %False when there is not residual path between the
+    /// source and the target so the current flow is a feasible and
+    /// optimal solution.
+    bool augment() {
+      Node n;
+
+      if (createLayeredGraph()) {
+	
+	Timer bf_timer;
+	initEdges();
+
+	n = _dt->findRoot(_source);
+	while (true) {
+	  Edge e;
+	  if (n == _target) {
+	    augmentPath();
+	  } else if (!advance(n)) {
+	    if (n != _source) {
+	      retreat(n);
+	    } else {
+	      break;
+	    }
+	  }
+	  n = _dt->findRoot(_source);
+	}     
+	extractTrees();
+
+	return true;
+      } else {
+	return false;
+      }
+    }
+    
+    /// \brief runs the algorithm.
+    /// 
+    /// It is just a shorthand for:
+    ///
+    ///\code 
+    /// ek.init();
+    /// ek.start();
+    ///\endcode
+    void run() {
+      init();
+      start();
+    }
+
+    /// @}
+
+    /// \name Query Functions 
+    /// The result of the Dinitz-Sleator-Tarjan algorithm can be
+    /// obtained using these functions.
+    /// \n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    /// \brief Returns the value of the maximum flow.
+    ///
+    /// Returns the value of the maximum flow by returning the excess
+    /// of the target node \c t. This value equals to the value of
+    /// the maximum flow already after the first phase.
+    Value flowValue() const {
+      return _flow_value;
+    }
+
+
+    /// \brief Returns the flow on the edge.
+    ///
+    /// Sets the \c flowMap to the flow on the edges. This method can
+    /// be called after the second phase of algorithm.
+    Value flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// \brief Returns true when the node is on the source side of minimum cut.
+    ///
+
+    /// Returns true when the node is on the source side of minimum
+    /// cut. This method can be called both after running \ref
+    /// startFirstPhase() and \ref startSecondPhase().
+    bool minCut(const Node& node) const {
+      return (*_level)[node] == -2;
+    }
+
+    /// \brief Returns a minimum value cut.
+    ///
+    /// Sets \c cut to the characteristic vector of a minimum value cut
+    /// It simply calls the minMinCut member.
+    /// \retval cut Write node bool map. 
+    template <typename CutMap>
+    void minCutMap(CutMap& cutMap) const {
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	cutMap.set(n, (*_level)[n] == -2);
+      }
+      cutMap.set(_source, true);
+    }    
+
+    /// @}
+
+  };
+}
+
+#endif
Index: lemon/dist_log.h
===================================================================
--- lemon/dist_log.h	(revision 2553)
+++ lemon/dist_log.h	(revision 2553)
@@ -0,0 +1,137 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_RANDOM_H
+#define LEMON_RANDOM_H
+
+#include<iostream>
+#include<fstream>
+#include<string>
+
+#include <lemon/dim2.h>
+
+///\ingroup misc
+///\file
+///\brief Measure a Distribution
+///
+///\todo Needs lot more docs
+///
+
+
+namespace lemon {
+
+  ///Measure a distribution
+  class DistLog
+  {
+    std::vector<int> _dist;
+    double _lo,_up;
+    int _count;
+    bool _cut;
+  public:
+    ///\e
+    Dist(double lo,double up,int gr,bool cut=true) 
+      : _dist(gr,0),_lo(lo),_up(up),_count(0),_cut(cut) {}
+    ///\e
+    void operator()(double v)
+    {
+      if(_cut) {
+	if(_lo<=v && v<_up)
+	  _dist[int((v-_lo)/(_up-_lo)*_dist.size())]++;
+      }
+      else {
+	_dist[std::max(0,std::min(int(_dist.size())-1,
+				  int((v-_lo)/(_up-_lo)*_dist.size())
+				  ))]++;
+      }
+      _count++;
+    }
+    ///\e
+    void dump(std::ostream& os=std::cout)
+    {
+      for(int i=0;i<_dist.size();i++)
+	os << _lo+(i+0.5)*(_up-_lo)/_dist.size() << ' '
+	   << double(_dist[i])/_count << std::endl;
+    }
+    ///\e
+    void dump(const std::string& file_name)
+    {
+      dump(std::ofstream(file_name.c_str()));
+    }
+  };
+  
+  ///Measure a two dimensional distribution
+  class DistLog2
+  {
+  public:
+    typedef dim2::Point<double> Point;
+  private:
+    std::vector<int> _dist;
+    int _gr;
+    Point _lo,_up;
+    int _count;
+    bool _cut;
+  public:  
+    ///\e
+    Dist2(Point a,Point b,int gr,bool cut=true) :
+      _dist(gr*gr,0),_gr(gr),
+      _lo(a),_up(b),_count(0),_cut(cut) {}
+    ///\e
+    Dist2(double lox,double upx,double loy,double upy,int gr,bool cut=true) :
+      _dist(gr*gr,0),_gr(gr),
+      _lo(Point(lox,loy)),_up(Point(upx,upy)),_count(0),_cut(cut) {}
+    ///\e
+    void operator()(Point v)
+    {
+      if(_cut)
+	{
+	  if(v.x>=_lo.x && v.x<_up.x && v.y>=_lo.y && v.y<_up.y)
+	    _dist[int((v.x-_lo.x)/(_up.x-_lo.x)*_gr)*_gr+
+		  int((v.y-_lo.y)/(_up.y-_lo.y)*_gr)]++;
+	}
+      else {
+	_dist[std::max(0,std::min(_gr-1,
+				  int((v.x-_lo.x)/(_up.x-_lo.x)*_gr)
+				  ))*_gr+
+	      std::max(0,std::min(_gr-1,
+				  int((v.y-_lo.y)/(_up.y-_lo.y)*_gr)
+				  ))
+	      ]++;
+      }
+      _count++;
+    }
+    ///\e
+    void dump(std::ostream& os=std::cout)
+    {
+      for(int i=0;i<_gr;i++)
+	{
+	  for(int j=0;j<_gr;j++)
+	    os << _lo.x+(i+0.5)*(_up.x-_lo.x)/_gr << ' '
+	       << _lo.y+(j+0.5)*(_up.y-_lo.y)/_gr << ' '
+	       << double(_dist[i*_gr+j])/_count << std::endl;
+	  os << std::endl;
+	}
+    }
+    ///\e
+    void dump(const std::string& file_name)
+    {
+      dump(std::ofstream(file_name.c_str()));
+    }
+  };
+}
+
+#endif
Index: lemon/dynamic_tree.h
===================================================================
--- lemon/dynamic_tree.h	(revision 2553)
+++ lemon/dynamic_tree.h	(revision 2553)
@@ -0,0 +1,1078 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_DYNAMIC_TREE_H
+#define LEMON_DYNAMIC_TREE_H
+
+/// \ingroup auxdata
+/// \file
+/// \brief The dynamic tree data structure of Sleator and Tarjan.
+///
+
+#include <vector>
+#include <limits>
+#include <lemon/tolerance.h>
+
+namespace lemon {
+
+  /// \ingroup auxdata
+  ///
+  /// \brief The dynamic tree data structure of Sleator and Tarjan.
+  ///
+  /// This class provides an implementation of the dynamic tree data
+  /// structure for maintaining a set of node-disjoint rooted
+  /// trees. Each item has an associated value, and the item with
+  /// minimum value can be find in \f$O(\log(n)\f$ on the path from a
+  /// node to the its root, and the items on such path can be
+  /// increased or decreased globally with a certain value in the same
+  /// running time. We regard a tree edge as directed toward the root,
+  /// that is from child to parent. Its structure can be modified by
+  /// two basic operations: \e link(v,w) adds an edge between a root v
+  /// and a node w in a different component; \e cut(v) removes the
+  /// edge between v and its parent.
+  /// 
+  /// \param _Value The value type of the items.  
+  /// \param _ItemIntMap Converts item type of node to integer.
+  /// \param _Tolerance The tolerance class to handle computation
+  /// problems.
+  /// \param _enableSize If true then the data structre manatain the
+  /// size of each tree. The feature is used in \ref GoldbergTarjan
+  /// algorithm. The default value is true.
+  ///
+  /// \author Hamori Tamas
+#ifdef DOXYGEN
+  template <typename _Value, typename _ItemIntMap, 
+	    typename _Tolerance, bool _enableSize>
+#else
+  template <typename _Value, typename _ItemIntMap, 
+	    typename _Tolerance = lemon::Tolerance<_Value>,
+	    bool _enableSize = true>
+#endif
+  class DynamicTree {
+  public:
+    /// \brief The integer map on the items.
+    typedef _ItemIntMap ItemIntMap;
+    /// \brief The item type of nodes.
+    typedef typename ItemIntMap::Key Item;
+    /// \brief The value type of the algorithms.
+    typedef _Value Value;
+    /// \brief The tolerance used by the algorithm.
+    typedef _Tolerance Tolerance;
+
+  private:
+  
+    class ItemData;
+
+    std::vector<ItemData> _data;
+    ItemIntMap &_iim;
+    Value _max_value;
+    Tolerance _tolerance;
+
+  public:
+    /// \brief The constructor of the class.
+    ///
+    /// \param iim The integer map on the items. 
+    /// \param tolerance Tolerance class.
+    DynamicTree(ItemIntMap &iim, const Tolerance& tolerance = Tolerance())
+      : _iim(iim), _max_value(std::numeric_limits<Value>::max()), 
+	_tolerance(tolerance) {}
+  
+    ~DynamicTree() {}
+
+    /// \brief Clears the data structure
+    ///
+    /// Clears the data structure
+    void clear() {
+      _data.clear();
+    }
+
+    /// \brief Sets the tolerance used by algorithm.
+    ///
+    /// Sets the tolerance used by algorithm.
+    void tolerance(const Tolerance& tolerance) const {
+      _tolerance = tolerance;
+      return *this;
+    } 
+  
+    /// \brief Returns the tolerance used by algorithm.
+    ///
+    /// Returns the tolerance used by algorithm.
+    const Tolerance& tolerance() const {
+      return tolerance;
+    } 
+  
+    /// \brief Create a new tree containing a single node with cost zero.
+    void makeTree(const Item &item) {
+      _data[makePath(item)].successor = -1;
+    }
+    
+    /// \brief Return the root of the tree containing node with itemtype
+    /// \e item.
+    Item findRoot(const Item &item) {
+      return _data[findTail(expose(_iim[item]))].id;
+    }
+    
+    /// \brief Return the the value of nodes in the tree containing
+    /// node with itemtype \e item.
+    int findSize(const Item &item) {
+      return _data[expose(_iim[item])].size;
+    }
+    
+    /// \brief Return the minimum cost containing node.
+    /// 
+    /// Return into \e d the minimum cost on the tree path from \e item
+    /// to findRoot(item).  Return the last item (closest to its root)
+    /// on this path of the minimum cost.
+    Item findCost(const Item &item, Value& d){
+      return _data[findPathCost(expose(_iim[item]),d)].id;
+    }
+    
+    /// \brief Add \e x value to the cost of every node on the path from
+    /// \e item to findRoot(item).
+    void addCost(const Item &item, Value x) {
+      addPathCost(expose(_iim[item]), x);
+    }
+    
+    /// \brief Combine the trees containing nodes \e item1 and \e item2
+    /// by adding an edge from \e item1 \e item2.
+    /// 
+    /// This operation assumes that \e item1 is root and \e item2 is in
+    /// a different tree.
+    void link(const Item &item1, const Item &item2){
+      int v = _iim[item1];
+      int w = _iim[item2];
+      int p = expose(w);
+      join(-1, expose(v), p);
+      _data[v].successor = -1;
+      _data[v].size += _data[p].size;
+
+    }    
+    
+    /// \brief Divide the tree containing node \e item into two trees by
+    /// deleting the edge out of \e item.
+    /// 
+    /// This operation assumes that \e item is not a tree root.
+    void cut(const Item &item) {
+      int v = _iim[item];
+      int p, q;
+      expose(v);
+      split(p, v, q);
+      if (p != -1) {
+	_data[p].successor = v;
+      }
+      _data[v].size -= _data[q].size;
+      if (q != -1) {
+	_data[q].successor = _data[v].successor;
+      }
+      _data[v].successor = -1;
+    }
+
+    ///\brief 
+    Item parent(const Item &item){
+      return _data[_iim[item].p].id;
+    }
+
+    ///\brief Return the upper bound of the costs.
+    Value maxValue() const {
+      return _max_value;
+    }
+    
+  private:
+
+    int makePath(const Item &item) {
+      _iim.set(item, _data.size());
+      ItemData v(item);
+      _data.push_back(v);
+      return _iim[item];
+    }
+
+    int findPath(int v) {
+      splay(v);
+      return v;
+    }
+    
+    int findPathCost(int p, Value &d) {
+      while ((_data[p].right != -1 && 
+	      !_tolerance.less(0, _data[_data[p].right].dmin)) || 
+	     (_data[p].left != -1 && _tolerance.less(0, _data[p].dcost))) {
+	if (_data[p].right != -1 && 
+	    !_tolerance.less(0, _data[_data[p].right].dmin)) {
+	  p = _data[p].right;
+	} else if (_data[p].left != -1 && 
+		   !_tolerance.less(0, _data[_data[p].left].dmin)) {
+	  p = _data[p].left;
+	}
+      }
+      splay(p);
+      d = _data[p].dmin;
+      return p; 
+    }
+
+    int findTail(int p){
+      while (_data[p].right != -1) {
+	p = _data[p].right;
+      }
+      splay(p);
+      return p;
+    }
+    
+    void addPathCost(int p, Value x) {
+      if (!_tolerance.less(x, _max_value)) {
+	_data[p].dmin = x;
+	_data[p].dcost = x;
+      } else if (!_tolerance.less(-x, _max_value)) {
+	_data[p].dmin = 0;
+	_data[p].dcost = 0;
+      } else {
+	_data[p].dmin += x;
+      }
+    }
+
+    void join(int p, int v, int q) {
+      Value min = _max_value;
+      Value pmin = _max_value;
+      Value vmin = _data[v].dmin;
+      Value qmin = _max_value;
+      if (p != -1){
+	pmin = _data[p].dmin;
+      }
+      if (q != -1){
+	qmin = _data[q].dmin;
+      }
+        
+      if (_tolerance.less(vmin, qmin)) {
+	if (_tolerance.less(vmin,pmin)) {
+	  min = vmin;
+	} else {
+	  min = pmin;
+	}
+      } else if (_tolerance.less(qmin,pmin)) {
+	min = qmin;
+      } else {
+	min = pmin;
+      }
+
+      if (p != -1){
+	_data[p].parent = v;
+	_data[p].dmin -= min;
+      }
+      if (q!=-1){
+	_data[q].parent = v;
+	if (_tolerance.less(_data[q].dmin,_max_value)) {
+	  _data[q].dmin -= min;
+	}
+      }
+      _data[v].left = p;
+      _data[v].right = q;
+      if (_tolerance.less(min,_max_value)) {
+	_data[v].dcost = _data[v].dmin - min;
+      }
+      _data[v].dmin = min;
+    }
+
+    void split(int &p, int v, int &q){
+      splay(v);
+      p = -1;
+      if (_data[v].left != -1){
+	p = _data[v].left;
+	_data[p].dmin += _data[v].dmin;
+	_data[p].parent = -1;
+	_data[v].left = -1;
+      }
+      q = -1;
+      if (_data[v].right != -1) {
+	q=_data[v].right;
+	if (_tolerance.less(_data[q].dmin, _max_value)) {
+	  _data[q].dmin += _data[v].dmin;
+	}
+	_data[q].parent = -1;
+	_data[v].right = -1;
+      } 
+      if (_tolerance.less(_data[v].dcost, _max_value)) {
+	_data[v].dmin += _data[v].dcost;
+	_data[v].dcost = 0;
+      } else {
+	_data[v].dmin = _data[v].dcost;
+      }
+    }
+ 
+    int expose(int v) {
+      int p, q, r, w;
+      p = -1;
+      while (v != -1) {
+	w = _data[findPath(v)].successor;
+	split(q, v, r);
+	if (q != -1) {
+	  _data[q].successor = v;
+	}
+	join(p, v, r);
+	p = v;
+	v = w;
+      }
+      _data[p].successor = -1;
+      return p;
+    }
+
+    void splay(int v) {
+      while (_data[v].parent != -1) {
+	if (v == _data[_data[v].parent].left) {
+	  if (_data[_data[v].parent].parent == -1) {
+	    zig(v);
+	  } else {
+	    if (_data[v].parent == _data[_data[_data[v].parent].parent].left) {
+	      zig(_data[v].parent);
+	      zig(v);
+	    } else {
+	      zig(v);
+	      zag(v);
+	    }
+	  }
+	} else {
+	  if (_data[_data[v].parent].parent == -1) {
+	    zag(v);
+	  } else {
+	    if (_data[v].parent == _data[_data[_data[v].parent].parent].left) {
+	      zag(v);
+	      zig(v);
+	    } else {
+	      zag(_data[v].parent);
+	      zag(v);
+	    }
+	  }
+	}
+      }
+    }
+
+
+    void zig(int v) {
+      Value min = _data[_data[v].parent].dmin;
+      int a = _data[v].parent;
+        
+      Value aa = _data[a].dcost;
+      if (_tolerance.less(aa, _max_value)) { 
+	aa += min;
+      }
+
+
+      int b = v;
+      Value ab = min + _data[b].dmin;
+      Value bb = _data[b].dcost;
+      if (_tolerance.less(bb, _max_value)) { 
+	bb += ab;
+      }
+
+      int c = -1;
+      Value cc = _max_value;
+      if (_data[a].right != -1) {
+	c = _data[a].right;
+	cc = _data[c].dmin;
+	if (_tolerance.less(cc, _max_value)) {
+	  cc += min;
+	}
+      }
+
+      int d = -1;
+      Value dd = _max_value;
+      if (_data[v].left != -1){
+	d = _data[v].left;
+	dd = ab + _data[d].dmin;
+      }
+
+      int e = -1;
+      Value ee = _max_value;
+      if (_data[v].right != -1) {
+	e = _data[v].right;
+	ee = ab + _data[e].dmin;
+      }
+
+      Value min2;
+      if (_tolerance.less(0, _data[b].dmin) || 
+	  (e != -1 && !_tolerance.less(0, _data[e].dmin))) {
+	min2 = min;
+      } else {
+	if (_tolerance.less(aa, cc)) {
+	  if (_tolerance.less(aa, ee)) {
+	    min2 = aa;
+	  } else {
+	    min2 = ee;
+	  }
+	} else if (_tolerance.less(cc, ee)) {
+	  min2 = cc;
+	} else {
+	  min2 = ee;
+	}
+      }
+        
+      _data[a].dcost = aa;
+      if (_tolerance.less(aa, _max_value)) { 
+	_data[a].dcost -= min2;
+      }
+      _data[a].dmin = min2;
+      if (_tolerance.less(min2,_max_value)) { 
+	_data[a].dmin -= min; 
+      }
+      _data[a].size -= _data[b].size;
+      _data[b].dcost = bb;
+      if (_tolerance.less(bb, _max_value)) { 
+	_data[b].dcost -= min;
+      }
+      _data[b].dmin = min;
+      _data[b].size += _data[a].size;
+      if (c != -1) {
+	_data[c].dmin = cc;
+	if (_tolerance.less(cc, _max_value)) {
+	  _data[c].dmin -= min2;
+	}
+      }
+      if (d != -1) {
+	_data[d].dmin = dd - min;
+	_data[a].size += _data[d].size;
+	_data[b].size -= _data[d].size;
+      }
+      if (e != -1) {
+	_data[e].dmin = ee - min2;
+      }
+        
+      int w = _data[v].parent;
+      _data[v].successor = _data[w].successor;
+      _data[w].successor = -1;
+      _data[v].parent = _data[w].parent;
+      _data[w].parent = v;
+      _data[w].left = _data[v].right;
+      _data[v].right = w;
+      if (_data[v].parent != -1){
+	if (_data[_data[v].parent].right == w) {
+	  _data[_data[v].parent].right = v;
+	} else {
+	  _data[_data[v].parent].left = v;
+	}
+      }
+      if (_data[w].left != -1){
+	_data[_data[w].left].parent = w;
+      }
+    }
+
+
+    void zag(int v) {
+
+      Value min = _data[_data[v].parent].dmin;
+
+      int a = _data[v].parent;
+      Value aa = _data[a].dcost;
+      if (_tolerance.less(aa, _max_value)) { 
+	aa += min;
+      }
+        
+      int b = v;
+      Value ab = min + _data[b].dmin;
+      Value bb = _data[b].dcost;
+      if (_tolerance.less(bb, _max_value)) {
+	bb += ab;
+      }
+
+      int c = -1;
+      Value cc = _max_value;
+      if (_data[a].left != -1){
+	c = _data[a].left;
+	cc = min + _data[c].dmin;
+      }
+
+      int d = -1;
+      Value dd = _max_value;
+      if (_data[v].right!=-1) {
+	d = _data[v].right;
+	dd = _data[d].dmin;
+	if (_tolerance.less(dd, _max_value)) {
+	  dd += ab;
+	}
+      }
+
+      int e = -1;
+      Value ee = _max_value;
+      if (_data[v].left != -1){
+	e = _data[v].left;
+	ee = ab + _data[e].dmin;
+      }
+
+      Value min2;
+      if (_tolerance.less(0, _data[b].dmin) || 
+	  (e != -1 && !_tolerance.less(0, _data[e].dmin))) {
+	min2 = min;
+      } else {
+	if (_tolerance.less(aa, cc)) {
+	  if (_tolerance.less(aa, ee)) {
+	    min2 = aa;
+	  } else {
+	    min2 = ee;
+	  }
+	} else if (_tolerance.less(cc, ee)) {
+	  min2 = cc;
+	} else {
+	  min2 = ee;
+	}
+      }
+      _data[a].dcost = aa;
+      if (_tolerance.less(aa, _max_value)) { 
+	_data[a].dcost -= min2;
+      }
+      _data[a].dmin = min2;
+      if (_tolerance.less(min2, _max_value)) {
+	_data[a].dmin -= min;
+      }
+      _data[a].size -= _data[b].size;
+      _data[b].dcost = bb;
+      if (_tolerance.less(bb, _max_value)) { 
+	_data[b].dcost -= min;
+      }
+      _data[b].dmin = min;
+      _data[b].size += _data[a].size;
+      if (c != -1) {
+	_data[c].dmin = cc - min2;
+      }
+      if (d != -1) {
+	_data[d].dmin = dd;
+	_data[a].size += _data[d].size;
+	_data[b].size -= _data[d].size;
+	if (_tolerance.less(dd, _max_value)) {
+	  _data[d].dmin -= min;
+	}
+      }
+      if (e != -1) {
+	_data[e].dmin = ee - min2;
+      }
+        
+      int w = _data[v].parent;
+      _data[v].successor = _data[w].successor;
+      _data[w].successor = -1;
+      _data[v].parent = _data[w].parent;
+      _data[w].parent = v;
+      _data[w].right = _data[v].left;
+      _data[v].left = w;
+      if (_data[v].parent != -1){
+	if (_data[_data[v].parent].left == w) {
+	  _data[_data[v].parent].left = v;
+	} else {
+	  _data[_data[v].parent].right = v;
+	}
+      }
+      if (_data[w].right != -1){
+	_data[_data[w].right].parent = w;
+      }
+    }
+
+  private:
+
+    class ItemData {
+    public:
+      Item id;
+      int size;
+      int successor;
+      int parent;
+      int left;
+      int right;
+      Value dmin;
+      Value dcost;
+        
+    public:
+      ItemData(const Item &item)
+	: id(item), size(1), successor(), parent(-1), 
+	  left(-1), right(-1), dmin(0), dcost(0) {}
+    };
+     
+  };
+
+  template <typename _Value, typename _ItemIntMap, typename _Tolerance>
+  class DynamicTree<_Value, _ItemIntMap, _Tolerance, false> {
+  public:
+    typedef _ItemIntMap ItemIntMap;
+    typedef typename ItemIntMap::Key Item;
+    typedef _Value Value;
+    typedef _Tolerance Tolerance;
+
+  private:
+  
+    class ItemData;
+
+    std::vector<ItemData> _data;
+    ItemIntMap &_iim;
+    Value _max_value;
+    Tolerance _tolerance;
+
+  public:
+    DynamicTree(ItemIntMap &iim, const Tolerance& tolerance = Tolerance())
+      : _iim(iim), _max_value(std::numeric_limits<Value>::max()), 
+	_tolerance(tolerance) {}
+  
+    ~DynamicTree() {}
+
+    void clear() {
+      _data.clear();
+    }
+
+    void tolerance(const Tolerance& tolerance) const {
+      _tolerance = tolerance;
+      return *this;
+    } 
+  
+    const Tolerance& tolerance() const {
+      return tolerance;
+    } 
+  
+    void makeTree(const Item &item) {
+      _data[makePath(item)].successor = -1;
+    }
+    
+    Item findRoot(const Item &item) {
+      return _data[findTail(expose(_iim[item]))].id;
+    }
+    
+    Item findCost(const Item &item, Value& d){
+      return _data[findPathCost(expose(_iim[item]),d)].id;
+    }
+    
+    void addCost(const Item &item, Value x){
+      addPathCost(expose(_iim[item]), x);
+    }
+    
+    void link(const Item &item1, const Item &item2){
+      int v = _iim[item1];
+      int w = _iim[item2];
+      int p = expose(w);
+      join(-1, expose(v), p);
+      _data[v].successor = -1;
+    }    
+    
+    void cut(const Item &item) {
+      int v = _iim[item];
+      int p, q;
+      expose(v);
+      split(p, v, q);
+      if (p != -1) {
+	_data[p].successor = v;
+      }
+      if (q != -1) {
+	_data[q].successor = _data[v].successor;
+      }
+      _data[v].successor = -1;
+    }
+
+    Item parent(const Item &item){
+      return _data[_iim[item].p].id;
+    }
+
+    Value maxValue() const {
+      return _max_value;
+    }
+    
+  private:
+
+    int makePath(const Item &item) {
+      _iim.set(item, _data.size());
+      ItemData v(item);
+      _data.push_back(v);
+      return _iim[item];
+    }
+
+    int findPath(int v) {
+      splay(v);
+      return v;
+    }
+    
+    int findPathCost(int p, Value &d) {
+      while ((_data[p].right != -1 && 
+	      !_tolerance.less(0, _data[_data[p].right].dmin)) || 
+	     (_data[p].left != -1 && _tolerance.less(0, _data[p].dcost))) {
+	if (_data[p].right != -1 && 
+	    !_tolerance.less(0, _data[_data[p].right].dmin)) {
+	  p = _data[p].right;
+	} else if (_data[p].left != -1 && 
+		   !_tolerance.less(0, _data[_data[p].left].dmin)){
+	  p = _data[p].left;
+	}
+      }
+      splay(p);
+      d = _data[p].dmin;
+      return p; 
+    }
+
+    int findTail(int p) {
+      while (_data[p].right != -1) {
+	p = _data[p].right;
+      }
+      splay(p);
+      return p;
+    }
+    
+    void addPathCost(int p, Value x) {
+      if (!_tolerance.less(x, _max_value)) {
+	_data[p].dmin = x;_data[p].dcost = x;
+      } else if (!_tolerance.less(-x, _max_value)) {
+	_data[p].dmin = 0;
+	_data[p].dcost = 0;
+      } else {
+	_data[p].dmin += x;
+      }
+    }
+
+    void join(int p, int v, int q) {
+      Value min = _max_value;
+      Value pmin = _max_value;
+      Value vmin = _data[v].dmin;
+      Value qmin = _max_value;
+      if (p != -1){
+	pmin = _data[p].dmin;
+      }
+      if (q != -1){
+	qmin = _data[q].dmin;
+      }
+        
+      if (_tolerance.less(vmin, qmin)) {
+	if (_tolerance.less(vmin,pmin)) {
+	  min = vmin;
+	} else {
+	  min = pmin;
+	}
+      } else if (_tolerance.less(qmin,pmin)) {
+	min = qmin;
+      } else {
+	min = pmin;
+      }
+
+      if (p != -1){
+	_data[p].parent = v;
+	_data[p].dmin -= min;
+      }
+      if (q != -1){
+	_data[q].parent = v;
+	if (_tolerance.less(_data[q].dmin,_max_value)) {
+	  _data[q].dmin -= min;
+	}
+      }
+      _data[v].left = p;
+      _data[v].right = q;
+      if (_tolerance.less(min, _max_value)) {
+	_data[v].dcost = _data[v].dmin - min;
+      }
+      _data[v].dmin = min;
+    }
+
+    void split(int &p, int v, int &q){
+      splay(v);
+      p = -1;
+      if (_data[v].left != -1){
+	p = _data[v].left;
+	_data[p].dmin += _data[v].dmin;
+	_data[p].parent = -1;
+	_data[v].left = -1;
+      }
+      q = -1;
+      if (_data[v].right != -1) {
+	q=_data[v].right;
+	if (_tolerance.less(_data[q].dmin, _max_value)) {
+	  _data[q].dmin += _data[v].dmin;
+	}
+	_data[q].parent = -1;
+	_data[v].right = -1;
+      } 
+      if (_tolerance.less(_data[v].dcost, _max_value)) {
+	_data[v].dmin += _data[v].dcost;
+	_data[v].dcost = 0;
+      } else {
+	_data[v].dmin = _data[v].dcost;
+      }
+    }
+ 
+    int expose(int v) {
+      int p, q, r, w;
+      p = -1;
+      while (v != -1) {
+	w = _data[findPath(v)].successor;
+	split(q, v, r);
+	if (q != -1) {
+	  _data[q].successor = v;
+	}
+	join(p, v, r);
+	p = v;
+	v = w;
+      }
+      _data[p].successor = -1;
+      return p;
+    }
+
+    void splay(int v) {
+      while (_data[v].parent != -1) {
+	if (v == _data[_data[v].parent].left) {
+	  if (_data[_data[v].parent].parent == -1) {
+	    zig(v);
+	  } else {
+	    if (_data[v].parent == _data[_data[_data[v].parent].parent].left) {
+	      zig(_data[v].parent);
+	      zig(v);
+	    } else {
+	      zig(v);
+	      zag(v);
+	    }
+	  }
+	} else {
+	  if (_data[_data[v].parent].parent == -1) {
+	    zag(v);
+	  } else {
+	    if (_data[v].parent == _data[_data[_data[v].parent].parent].left) {
+	      zag(v);
+	      zig(v);
+	    } else {
+	      zag(_data[v].parent);
+	      zag(v);
+	    }
+	  }
+	}
+      }
+    }
+
+
+    void zig(int v) {
+      Value min = _data[_data[v].parent].dmin;
+      int a = _data[v].parent;
+        
+      Value aa = _data[a].dcost;
+      if (_tolerance.less(aa, _max_value)) { 
+	aa+= min;
+      }
+
+
+      int b = v;
+      Value ab = min + _data[b].dmin;
+      Value bb = _data[b].dcost;
+      if (_tolerance.less(bb, _max_value)) { 
+	bb+= ab;
+      }
+
+      int c = -1;
+      Value cc = _max_value;
+      if (_data[a].right != -1) {
+	c = _data[a].right;
+	cc = _data[c].dmin;
+	if (_tolerance.less(cc, _max_value)) {
+	  cc+=min;
+	}
+      }
+
+      int d = -1;
+      Value dd = _max_value;
+      if (_data[v].left != -1){
+	d = _data[v].left;
+	dd = ab + _data[d].dmin;
+      }
+
+      int e = -1;
+      Value ee = _max_value;
+      if (_data[v].right != -1) {
+	e = _data[v].right;
+	ee = ab + _data[e].dmin;
+      }
+
+      Value min2;
+      if (_tolerance.less(0, _data[b].dmin) || 
+	  (e != -1 && !_tolerance.less(0, _data[e].dmin))) {
+	min2 = min;
+      } else {
+	if (_tolerance.less(aa, cc)) {
+	  if (_tolerance.less(aa, ee)) {
+	    min2 = aa;
+	  } else {
+	    min2 = ee;
+	  }
+	} else if (_tolerance.less(cc, ee)) {
+	  min2 = cc;
+	} else {
+	  min2 = ee;
+	}
+      }
+        
+      _data[a].dcost = aa;
+      if (_tolerance.less(aa, _max_value)) { 
+	_data[a].dcost -= min2;
+      }
+      _data[a].dmin = min2;
+      if (_tolerance.less(min2,_max_value)) { 
+	_data[a].dmin -= min; 
+      }
+      _data[b].dcost = bb;
+      if (_tolerance.less(bb, _max_value)) { 
+	_data[b].dcost -= min;
+      }
+      _data[b].dmin = min;
+      if (c != -1) {
+	_data[c].dmin = cc;
+	if (_tolerance.less(cc, _max_value)) {
+	  _data[c].dmin -= min2;
+	}
+      }
+      if (d != -1) {
+	_data[d].dmin = dd - min;
+      }
+      if (e != -1) {
+	_data[e].dmin = ee - min2;
+      }
+        
+      int w = _data[v].parent;
+      _data[v].successor = _data[w].successor;
+      _data[w].successor = -1;
+      _data[v].parent = _data[w].parent;
+      _data[w].parent = v;
+      _data[w].left = _data[v].right;
+      _data[v].right = w;
+      if (_data[v].parent != -1){
+	if (_data[_data[v].parent].right == w) {
+	  _data[_data[v].parent].right = v;
+	} else {
+	  _data[_data[v].parent].left = v;
+	}
+      }
+      if (_data[w].left != -1){
+	_data[_data[w].left].parent = w;
+      }
+    }
+
+
+    void zag(int v) {
+
+      Value min = _data[_data[v].parent].dmin;
+
+      int a = _data[v].parent;
+      Value aa = _data[a].dcost;
+      if (_tolerance.less(aa, _max_value)) { 
+	aa += min;
+      }
+        
+      int b = v;
+      Value ab = min + _data[b].dmin;
+      Value bb = _data[b].dcost;
+      if (_tolerance.less(bb, _max_value)) {
+	bb += ab;
+      }
+
+      int c = -1;
+      Value cc = _max_value;
+      if (_data[a].left != -1){
+	c = _data[a].left;
+	cc = min + _data[c].dmin;
+      }
+
+      int d = -1;
+      Value dd = _max_value;
+      if (_data[v].right!=-1) {
+	d = _data[v].right;
+	dd = _data[d].dmin;
+	if (_tolerance.less(dd, _max_value)) {
+	  dd += ab;
+	}
+      }
+
+      int e = -1;
+      Value ee = _max_value;
+      if (_data[v].left != -1){
+	e = _data[v].left;
+	ee = ab + _data[e].dmin;
+      }
+
+      Value min2;
+      if (_tolerance.less(0, _data[b].dmin) || 
+	  (e != -1 && !_tolerance.less(0, _data[e].dmin))) {
+	min2 = min;
+      } else {
+	if (_tolerance.less(aa, cc)) {
+	  if (_tolerance.less(aa, ee)) {
+	    min2 = aa;
+	  } else {
+	    min2 = ee;
+	  }
+	} else if (_tolerance.less(cc, ee)) {
+	  min2 = cc;
+	} else {
+	  min2 = ee;
+	}
+      }
+      _data[a].dcost = aa;
+      if (_tolerance.less(aa, _max_value)) { 
+	_data[a].dcost -= min2;
+      }
+      _data[a].dmin = min2;
+      if (_tolerance.less(min2, _max_value)) {
+	_data[a].dmin -= min;
+      }
+      _data[b].dcost = bb;
+      if (_tolerance.less(bb, _max_value)) { 
+	_data[b].dcost -= min;
+      }
+      _data[b].dmin = min;
+      if (c != -1) {
+	_data[c].dmin = cc - min2;
+      }
+      if (d != -1) {
+	_data[d].dmin = dd;
+	if (_tolerance.less(dd, _max_value)) {
+	  _data[d].dmin -= min;
+	}
+      }
+      if (e != -1) {
+	_data[e].dmin = ee - min2;
+      }
+        
+      int w = _data[v].parent;
+      _data[v].successor = _data[w].successor;
+      _data[w].successor = -1;
+      _data[v].parent = _data[w].parent;
+      _data[w].parent = v;
+      _data[w].right = _data[v].left;
+      _data[v].left = w;
+      if (_data[v].parent != -1){
+	if (_data[_data[v].parent].left == w) {
+	  _data[_data[v].parent].left = v;
+	} else {
+	  _data[_data[v].parent].right = v;
+	}
+      }
+      if (_data[w].right != -1){
+	_data[_data[w].right].parent = w;
+      }
+    }
+
+  private:
+
+    class ItemData {
+    public:
+      Item id;
+      int successor;
+      int parent;
+      int left;
+      int right;
+      Value dmin;
+      Value dcost;
+        
+    public:
+      ItemData(const Item &item)
+	: id(item), successor(), parent(-1), 
+	  left(-1), right(-1), dmin(0), dcost(0) {}
+    };
+     
+  };
+
+}
+
+#endif
Index: lemon/edge_set.h
===================================================================
--- lemon/edge_set.h	(revision 2618)
+++ lemon/edge_set.h	(revision 2618)
@@ -0,0 +1,1288 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_EDGE_SET_H
+#define LEMON_EDGE_SET_H
+
+
+#include <lemon/bits/default_map.h>
+#include <lemon/bits/edge_set_extender.h>
+
+/// \ingroup semi_adaptors
+/// \file
+/// \brief EdgeSet classes.
+///
+/// Graphs which use another graph's node-set as own. 
+
+namespace lemon {
+
+  template <typename _Graph>
+  class ListEdgeSetBase {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+
+  protected:
+
+    struct NodeT {
+      int first_out, first_in;
+      NodeT() : first_out(-1), first_in(-1) {}
+    };
+
+    typedef DefaultMap<Graph, Node, NodeT> NodesImplBase;
+
+    NodesImplBase* nodes;
+
+    struct EdgeT {
+      Node source, target;
+      int next_out, next_in;
+      int prev_out, prev_in;
+      EdgeT() : prev_out(-1), prev_in(-1) {}
+    };
+
+    std::vector<EdgeT> edges;
+
+    int first_edge;
+    int first_free_edge;
+
+    const Graph* graph;
+
+    void initalize(const Graph& _graph, NodesImplBase& _nodes) {
+      graph = &_graph;
+      nodes = &_nodes;
+    }
+    
+  public:
+
+    class Edge {
+      friend class ListEdgeSetBase<Graph>;
+    protected:
+      Edge(int _id) : id(_id) {}
+      int id;
+    public:
+      Edge() {}
+      Edge(Invalid) : id(-1) {}
+      bool operator==(const Edge& edge) const { return id == edge.id; }
+      bool operator!=(const Edge& edge) const { return id != edge.id; }
+      bool operator<(const Edge& edge) const { return id < edge.id; }
+    };
+
+    ListEdgeSetBase() : first_edge(-1), first_free_edge(-1) {} 
+
+    Edge addEdge(const Node& u, const Node& v) {
+      int n;
+      if (first_free_edge == -1) {
+	n = edges.size();
+	edges.push_back(EdgeT());
+      } else {
+	n = first_free_edge;
+	first_free_edge = edges[first_free_edge].next_in;
+      }
+      edges[n].next_in = (*nodes)[v].first_in;
+      if ((*nodes)[v].first_in != -1) {
+        edges[(*nodes)[v].first_in].prev_in = n;
+      }
+      (*nodes)[v].first_in = n;
+      edges[n].next_out = (*nodes)[u].first_out;
+      if ((*nodes)[u].first_out != -1) {
+        edges[(*nodes)[u].first_out].prev_out = n;
+      }
+      (*nodes)[u].first_out = n;
+      edges[n].source = u;
+      edges[n].target = v;
+      return Edge(n);
+    }
+
+    void erase(const Edge& edge) {
+      int n = edge.id;
+      if (edges[n].prev_in != -1) {
+	edges[edges[n].prev_in].next_in = edges[n].next_in;
+      } else {
+	(*nodes)[edges[n].target].first_in = edges[n].next_in;
+      }
+      if (edges[n].next_in != -1) {
+	edges[edges[n].next_in].prev_in = edges[n].prev_in;
+      }
+
+      if (edges[n].prev_out != -1) {
+	edges[edges[n].prev_out].next_out = edges[n].next_out;
+      } else {
+	(*nodes)[edges[n].source].first_out = edges[n].next_out;
+      }
+      if (edges[n].next_out != -1) {
+	edges[edges[n].next_out].prev_out = edges[n].prev_out;
+      }
+           
+    }
+
+    void clear() {
+      Node node;
+      for (first(node); node != INVALID; next(node)) {
+        (*nodes)[node].first_in = -1;
+        (*nodes)[node].first_out = -1;
+      }
+      edges.clear();
+      first_edge = -1;
+      first_free_edge = -1;
+    }
+
+    void first(Node& node) const {
+      graph->first(node);
+    }
+
+    void next(Node& node) const {
+      graph->next(node);
+    }
+
+    void first(Edge& edge) const {
+      Node node;
+      for (first(node); node != INVALID && (*nodes)[node].first_in == -1; 
+	   next(node)) { }
+      edge.id = (node == INVALID) ? -1 : (*nodes)[node].first_in;
+    }
+
+    void next(Edge& edge) const {
+      if (edges[edge.id].next_in != -1) {
+	edge.id = edges[edge.id].next_in;
+      } else {
+	Node node = edges[edge.id].target;
+	for (next(node); node != INVALID && (*nodes)[node].first_in == -1; 
+	     next(node)) { }
+	edge.id = (node == INVALID) ? -1 : (*nodes)[node].first_in;
+      }      
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      edge.id = (*nodes)[node].first_out;    
+    }
+    
+    void nextOut(Edge& edge) const {
+      edge.id = edges[edge.id].next_out;        
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      edge.id = (*nodes)[node].first_in;          
+    }
+
+    void nextIn(Edge& edge) const {
+      edge.id = edges[edge.id].next_in;    
+    }
+
+    int id(const Node& node) const { return graph->id(node); }
+    int id(const Edge& edge) const { return edge.id; }
+
+    Node nodeFromId(int ix) const { return graph->nodeFromId(ix); }
+    Edge edgeFromId(int ix) const { return Edge(ix); }
+
+    int maxNodeId() const { return graph->maxNodeId(); };
+    int maxEdgeId() const { return edges.size() - 1; }
+
+    Node source(const Edge& edge) const { return edges[edge.id].source;}
+    Node target(const Edge& edge) const { return edges[edge.id].target;}
+
+    typedef typename ItemSetTraits<Graph, Node>::ItemNotifier NodeNotifier;
+
+    NodeNotifier& notifier(Node) const {
+      return graph->notifier(Node());
+    } 
+
+    template <typename _Value>
+    class NodeMap : public Graph::template NodeMap<_Value> {
+    public:
+
+      typedef typename _Graph::template NodeMap<_Value> Parent;
+
+      explicit NodeMap(const ListEdgeSetBase<Graph>& edgeset) 
+	: Parent(*edgeset.graph) {}
+
+      NodeMap(const ListEdgeSetBase<Graph>& edgeset, const _Value& value)
+	: Parent(*edgeset.graph, value) {}
+
+      NodeMap& operator=(const NodeMap& cmap) {
+        return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+    };
+
+  };
+
+  /// \ingroup semi_adaptors
+  ///
+  /// \brief Graph using a node set of another graph and an
+  /// own edge set.
+  ///
+  /// This structure can be used to establish another graph over a node set
+  /// of an existing one. The node iterator will go through the nodes of the
+  /// original graph.
+  ///
+  /// \param _Graph The type of the graph which shares its node set with 
+  /// this class. Its interface must conform to the \ref concepts::Graph
+  /// "Graph" concept.
+  ///
+  template <typename _Graph>
+  class ListEdgeSet : public EdgeSetExtender<ListEdgeSetBase<_Graph> > {
+
+  public:
+
+    typedef EdgeSetExtender<ListEdgeSetBase<_Graph> > Parent;
+    
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+    
+    typedef _Graph Graph;
+
+
+    typedef typename Parent::NodesImplBase NodesImplBase;
+
+    void eraseNode(const Node& node) {
+      Edge edge;
+      Parent::firstOut(edge, node);
+      while (edge != INVALID ) {
+	erase(edge);
+	Parent::firstOut(edge, node);
+      } 
+
+      Parent::firstIn(edge, node);
+      while (edge != INVALID ) {
+	erase(edge);
+	Parent::firstIn(edge, node);
+      }
+    }
+    
+    void clearNodes() {
+      Parent::clear();
+    }
+
+    class NodesImpl : public NodesImplBase {
+    public:
+      typedef NodesImplBase Parent;
+      
+      NodesImpl(const Graph& graph, ListEdgeSet& edgeset) 
+	: Parent(graph), _edgeset(edgeset) {}
+
+      virtual ~NodesImpl() {}
+      
+    protected:
+
+      virtual void erase(const Node& node) {
+	_edgeset.eraseNode(node);
+	Parent::erase(node);
+      }
+      virtual void erase(const std::vector<Node>& nodes) {
+        for (int i = 0; i < int(nodes.size()); ++i) {
+          _edgeset.eraseNode(nodes[i]);
+        }
+	Parent::erase(nodes);
+      }
+      virtual void clear() {
+	_edgeset.clearNodes();
+	Parent::clear();
+      }
+
+    private:
+      ListEdgeSet& _edgeset;
+    };
+
+    NodesImpl nodes;
+    
+  public:
+
+    /// \brief Constructor of the adaptor.
+    /// 
+    /// Constructor of the adaptor.
+    ListEdgeSet(const Graph& graph) : nodes(graph, *this) {
+      Parent::initalize(graph, nodes);
+    }
+    
+  };
+
+  template <typename _Graph>
+  class ListUEdgeSetBase {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+
+  protected:
+
+    struct NodeT {
+      int first_out;
+      NodeT() : first_out(-1) {}
+    };
+
+    typedef DefaultMap<Graph, Node, NodeT> NodesImplBase;
+
+    NodesImplBase* nodes;
+
+    struct EdgeT {
+      Node target;
+      int prev_out, next_out;
+      EdgeT() : prev_out(-1), next_out(-1) {}
+    };
+
+    std::vector<EdgeT> edges;
+
+    int first_edge;
+    int first_free_edge;
+
+    const Graph* graph;
+
+    void initalize(const Graph& _graph, NodesImplBase& _nodes) {
+      graph = &_graph;
+      nodes = &_nodes;
+    }
+    
+  public:
+
+    class UEdge {
+      friend class ListUEdgeSetBase;
+    protected:
+
+      int id;
+      explicit UEdge(int _id) { id = _id;}
+
+    public:
+      UEdge() {}
+      UEdge (Invalid) { id = -1; }
+      bool operator==(const UEdge& edge) const {return id == edge.id;}
+      bool operator!=(const UEdge& edge) const {return id != edge.id;}
+      bool operator<(const UEdge& edge) const {return id < edge.id;}
+    };
+
+    class Edge {
+      friend class ListUEdgeSetBase;
+    protected:
+      Edge(int _id) : id(_id) {}
+      int id;
+    public:
+      operator UEdge() const { return uEdgeFromId(id / 2); }
+
+      Edge() {}
+      Edge(Invalid) : id(-1) {}
+      bool operator==(const Edge& edge) const { return id == edge.id; }
+      bool operator!=(const Edge& edge) const { return id != edge.id; }
+      bool operator<(const Edge& edge) const { return id < edge.id; }
+    };
+
+    ListUEdgeSetBase() : first_edge(-1), first_free_edge(-1) {} 
+
+    UEdge addEdge(const Node& u, const Node& v) {
+      int n;
+
+      if (first_free_edge == -1) {
+	n = edges.size();
+	edges.push_back(EdgeT());
+	edges.push_back(EdgeT());
+      } else {
+	n = first_free_edge;
+	first_free_edge = edges[n].next_out;
+      }
+      
+      edges[n].target = u;
+      edges[n | 1].target = v;
+
+      edges[n].next_out = (*nodes)[v].first_out;
+      if ((*nodes)[v].first_out != -1) {
+	edges[(*nodes)[v].first_out].prev_out = n;
+      }
+      (*nodes)[v].first_out = n;
+      edges[n].prev_out = -1;
+      
+      if ((*nodes)[u].first_out != -1) {
+	edges[(*nodes)[u].first_out].prev_out = (n | 1);
+      }
+      edges[n | 1].next_out = (*nodes)[u].first_out;
+      (*nodes)[u].first_out = (n | 1);
+      edges[n | 1].prev_out = -1;
+
+      return UEdge(n / 2);
+    }
+
+    void erase(const UEdge& edge) {
+      int n = edge.id * 2;
+      
+      if (edges[n].next_out != -1) {
+	edges[edges[n].next_out].prev_out = edges[n].prev_out;
+      } 
+
+      if (edges[n].prev_out != -1) {
+	edges[edges[n].prev_out].next_out = edges[n].next_out;
+      } else {
+	(*nodes)[edges[n | 1].target].first_out = edges[n].next_out;
+      }
+
+      if (edges[n | 1].next_out != -1) {
+	edges[edges[n | 1].next_out].prev_out = edges[n | 1].prev_out;
+      } 
+
+      if (edges[n | 1].prev_out != -1) {
+	edges[edges[n | 1].prev_out].next_out = edges[n | 1].next_out;
+      } else {
+	(*nodes)[edges[n].target].first_out = edges[n | 1].next_out;
+      }
+      
+      edges[n].next_out = first_free_edge;
+      first_free_edge = n;      
+           
+    }
+
+    void clear() {
+      Node node;
+      for (first(node); node != INVALID; next(node)) {
+        (*nodes)[node].first_out = -1;
+      }
+      edges.clear();
+      first_edge = -1;
+      first_free_edge = -1;
+    }
+
+    void first(Node& node) const {
+      graph->first(node);
+    }
+
+    void next(Node& node) const {
+      graph->next(node);
+    }
+
+    void first(Edge& edge) const {
+      Node node;
+      first(node);
+      while (node != INVALID && (*nodes)[node].first_out == -1) {
+        next(node);
+      }
+      edge.id = (node == INVALID) ? -1 : (*nodes)[node].first_out;
+    }
+
+    void next(Edge& edge) const {
+      if (edges[edge.id].next_out != -1) {
+	edge.id = edges[edge.id].next_out;
+      } else {
+	Node node = edges[edge.id ^ 1].target;
+	next(node);
+        while(node != INVALID && (*nodes)[node].first_out == -1) {
+          next(node);
+        }
+	edge.id = (node == INVALID) ? -1 : (*nodes)[node].first_out;
+      }      
+    }
+
+    void first(UEdge& uedge) const {
+      Node node;
+      first(node);
+      while (node != INVALID) {
+        uedge.id = (*nodes)[node].first_out;
+        while ((uedge.id & 1) != 1) {
+          uedge.id = edges[uedge.id].next_out;
+        }
+        if (uedge.id != -1) {
+          uedge.id /= 2;
+          return;
+        } 
+        next(node);
+      }
+      uedge.id = -1;
+    }
+
+    void next(UEdge& uedge) const {
+      Node node = edges[uedge.id * 2].target;
+      uedge.id = edges[(uedge.id * 2) | 1].next_out;
+      while ((uedge.id & 1) != 1) {
+        uedge.id = edges[uedge.id].next_out;
+      }
+      if (uedge.id != -1) {
+        uedge.id /= 2;
+        return;
+      } 
+      next(node);
+      while (node != INVALID) {
+        uedge.id = (*nodes)[node].first_out;
+        while ((uedge.id & 1) != 1) {
+          uedge.id = edges[uedge.id].next_out;
+        }
+        if (uedge.id != -1) {
+          uedge.id /= 2;
+          return;
+        } 
+	next(node);
+      }
+      uedge.id = -1;
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      edge.id = (*nodes)[node].first_out;
+    }
+    
+    void nextOut(Edge& edge) const {
+      edge.id = edges[edge.id].next_out;        
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      edge.id = (((*nodes)[node].first_out) ^ 1);
+      if (edge.id == -2) edge.id = -1;
+    }
+
+    void nextIn(Edge& edge) const {
+      edge.id = ((edges[edge.id ^ 1].next_out) ^ 1);
+      if (edge.id == -2) edge.id = -1;
+    }
+
+    void firstInc(UEdge &edge, bool& dir, const Node& node) const {
+      int de = (*nodes)[node].first_out;
+      if (de != -1 ) {
+        edge.id = de / 2;
+        dir = ((de & 1) == 1);
+      } else {
+        edge.id = -1;
+        dir = true;
+      }
+    }
+    void nextInc(UEdge &edge, bool& dir) const {
+      int de = (edges[(edge.id * 2) | (dir ? 1 : 0)].next_out);
+      if (de != -1 ) {
+        edge.id = de / 2;
+        dir = ((de & 1) == 1);
+      } else {
+        edge.id = -1;
+        dir = true;
+      }
+    }
+
+    static bool direction(Edge edge) {
+      return (edge.id & 1) == 1;
+    }
+
+    static Edge direct(UEdge uedge, bool dir) {
+      return Edge(uedge.id * 2 + (dir ? 1 : 0));
+    }
+
+    int id(const Node& node) const { return graph->id(node); }
+    static int id(Edge e) { return e.id; }
+    static int id(UEdge e) { return e.id; }
+
+    Node nodeFromId(int id) const { return graph->nodeFromId(id); }
+    static Edge edgeFromId(int id) { return Edge(id);}
+    static UEdge uEdgeFromId(int id) { return UEdge(id);}
+
+    int maxNodeId() const { return graph->maxNodeId(); };
+    int maxUEdgeId() const { return edges.size() / 2 - 1; }
+    int maxEdgeId() const { return edges.size()-1; }
+
+    Node source(Edge e) const { return edges[e.id ^ 1].target; }
+    Node target(Edge e) const { return edges[e.id].target; }
+
+    Node source(UEdge e) const { return edges[2 * e.id].target; }
+    Node target(UEdge e) const { return edges[2 * e.id + 1].target; }
+
+    typedef typename ItemSetTraits<Graph, Node>::ItemNotifier NodeNotifier;
+
+    NodeNotifier& notifier(Node) const {
+      return graph->notifier(Node());
+    } 
+
+    template <typename _Value>
+    class NodeMap : public Graph::template NodeMap<_Value> {
+    public:
+
+      typedef typename _Graph::template NodeMap<_Value> Parent;
+
+      explicit NodeMap(const ListUEdgeSetBase<Graph>& edgeset) 
+	: Parent(*edgeset.graph) {}
+
+      NodeMap(const ListUEdgeSetBase<Graph>& edgeset, const _Value& value)
+	: Parent(*edgeset.graph, value) {}
+
+      NodeMap& operator=(const NodeMap& cmap) {
+        return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+    };
+
+  };
+
+  /// \ingroup semi_adaptors
+  ///
+  /// \brief Graph using a node set of another graph and an
+  /// own uedge set.
+  ///
+  /// This structure can be used to establish another graph over a node set
+  /// of an existing one. The node iterator will go through the nodes of the
+  /// original graph.
+  ///
+  /// \param _Graph The type of the graph which shares its node set with 
+  /// this class. Its interface must conform to the \ref concepts::Graph
+  /// "Graph" concept.
+  ///
+  /// In the edge extension and removing it conforms to the 
+  /// \ref concepts::UGraph "UGraph" concept.
+  template <typename _Graph>
+  class ListUEdgeSet : public UEdgeSetExtender<ListUEdgeSetBase<_Graph> > {
+
+  public:
+
+    typedef UEdgeSetExtender<ListUEdgeSetBase<_Graph> > Parent;
+    
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+    
+    typedef _Graph Graph;
+
+
+    typedef typename Parent::NodesImplBase NodesImplBase;
+
+    void eraseNode(const Node& node) {
+      Edge edge;
+      Parent::firstOut(edge, node);
+      while (edge != INVALID ) {
+	erase(edge);
+	Parent::firstOut(edge, node);
+      } 
+
+    }
+    
+    void clearNodes() {
+      Parent::clear();
+    }
+
+    class NodesImpl : public NodesImplBase {
+    public:
+      typedef NodesImplBase Parent;
+      
+      NodesImpl(const Graph& graph, ListUEdgeSet& edgeset) 
+	: Parent(graph), _edgeset(edgeset) {}
+
+      virtual ~NodesImpl() {}
+      
+    protected:
+
+      virtual void erase(const Node& node) {
+	_edgeset.eraseNode(node);
+	Parent::erase(node);
+      }
+      virtual void erase(const std::vector<Node>& nodes) {
+	for (int i = 0; i < int(nodes.size()); ++i) {
+	  _edgeset.eraseNode(nodes[i]);
+	}
+	Parent::erase(nodes);
+      }
+      virtual void clear() {
+	_edgeset.clearNodes();
+	Parent::clear();
+      }
+
+    private:
+      ListUEdgeSet& _edgeset;
+    };
+
+    NodesImpl nodes;
+    
+  public:
+
+    /// \brief Constructor of the adaptor.
+    /// 
+    /// Constructor of the adaptor.
+    ListUEdgeSet(const Graph& graph) : nodes(graph, *this) {
+      Parent::initalize(graph, nodes);
+    }
+    
+  };
+
+  template <typename _Graph>
+  class SmartEdgeSetBase {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+
+  protected:
+
+    struct NodeT {
+      int first_out, first_in;
+      NodeT() : first_out(-1), first_in(-1) {}
+    };
+
+    typedef DefaultMap<Graph, Node, NodeT> NodesImplBase;
+
+    NodesImplBase* nodes;
+
+    struct EdgeT {
+      Node source, target;
+      int next_out, next_in;
+      EdgeT() {}
+    };
+
+    std::vector<EdgeT> edges;
+
+    const Graph* graph;
+
+    void initalize(const Graph& _graph, NodesImplBase& _nodes) {
+      graph = &_graph;
+      nodes = &_nodes;
+    }
+    
+  public:
+
+    class Edge {
+      friend class SmartEdgeSetBase<Graph>;
+    protected:
+      Edge(int _id) : id(_id) {}
+      int id;
+    public:
+      Edge() {}
+      Edge(Invalid) : id(-1) {}
+      bool operator==(const Edge& edge) const { return id == edge.id; }
+      bool operator!=(const Edge& edge) const { return id != edge.id; }
+      bool operator<(const Edge& edge) const { return id < edge.id; }
+    };
+
+    SmartEdgeSetBase() {} 
+
+    Edge addEdge(const Node& u, const Node& v) {
+      int n = edges.size();
+      edges.push_back(EdgeT());
+      edges[n].next_in = (*nodes)[v].first_in;
+      (*nodes)[v].first_in = n;
+      edges[n].next_out = (*nodes)[u].first_out;
+      (*nodes)[u].first_out = n;
+      edges[n].source = u;
+      edges[n].target = v;
+      return Edge(n);
+    }
+
+    void clear() {
+      Node node;
+      for (first(node); node != INVALID; next(node)) {
+        (*nodes)[node].first_in = -1;
+        (*nodes)[node].first_out = -1;
+      }
+      edges.clear();
+    }
+
+    void first(Node& node) const {
+      graph->first(node);
+    }
+
+    void next(Node& node) const {
+      graph->next(node);
+    }
+
+    void first(Edge& edge) const {
+      edge.id = edges.size() - 1;
+    }
+
+    void next(Edge& edge) const {
+      --edge.id;
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      edge.id = (*nodes)[node].first_out;    
+    }
+    
+    void nextOut(Edge& edge) const {
+      edge.id = edges[edge.id].next_out;        
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      edge.id = (*nodes)[node].first_in;          
+    }
+
+    void nextIn(Edge& edge) const {
+      edge.id = edges[edge.id].next_in;    
+    }
+
+    int id(const Node& node) const { return graph->id(node); }
+    int id(const Edge& edge) const { return edge.id; }
+
+    Node nodeFromId(int ix) const { return graph->nodeFromId(ix); }
+    Edge edgeFromId(int ix) const { return Edge(ix); }
+
+    int maxNodeId() const { return graph->maxNodeId(); };
+    int maxEdgeId() const { return edges.size() - 1; }
+
+    Node source(const Edge& edge) const { return edges[edge.id].source;}
+    Node target(const Edge& edge) const { return edges[edge.id].target;}
+
+    typedef typename ItemSetTraits<Graph, Node>::ItemNotifier NodeNotifier;
+
+    NodeNotifier& notifier(Node) const {
+      return graph->notifier(Node());
+    } 
+
+    template <typename _Value>
+    class NodeMap : public Graph::template NodeMap<_Value> {
+    public:
+
+      typedef typename _Graph::template NodeMap<_Value> Parent;
+
+      explicit NodeMap(const SmartEdgeSetBase<Graph>& edgeset) 
+	: Parent(*edgeset.graph) { }
+
+      NodeMap(const SmartEdgeSetBase<Graph>& edgeset, const _Value& value)
+	: Parent(*edgeset.graph, value) { }
+
+      NodeMap& operator=(const NodeMap& cmap) {
+        return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+    };
+
+  };
+
+
+  /// \ingroup semi_adaptors
+  ///
+  /// \brief Graph using a node set of another graph and an
+  /// own edge set.
+  ///
+  /// This structure can be used to establish another graph over a node set
+  /// of an existing one. The node iterator will go through the nodes of the
+  /// original graph.
+  ///
+  /// \param _Graph The type of the graph which shares its node set with 
+  /// this class. Its interface must conform to the \ref concepts::Graph
+  /// "Graph" concept.
+  ///
+  /// In the edge extension and removing it conforms to the 
+  /// \ref concepts::Graph "Graph" concept.
+  template <typename _Graph>
+  class SmartEdgeSet : public EdgeSetExtender<SmartEdgeSetBase<_Graph> > {
+
+  public:
+
+    typedef EdgeSetExtender<SmartEdgeSetBase<_Graph> > Parent;
+    
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+    
+    typedef _Graph Graph;
+
+  protected:
+
+    typedef typename Parent::NodesImplBase NodesImplBase;
+
+    void eraseNode(const Node& node) {
+      if (Parent::InEdgeIt(*this, node) == INVALID &&
+          Parent::OutEdgeIt(*this, node) == INVALID) {
+        return;
+      }
+      throw typename NodesImplBase::Notifier::ImmediateDetach();
+    }
+    
+    void clearNodes() {
+      Parent::clear();
+    }
+
+    class NodesImpl : public NodesImplBase {
+    public:
+      typedef NodesImplBase Parent;
+      
+      NodesImpl(const Graph& graph, SmartEdgeSet& edgeset) 
+	: Parent(graph), _edgeset(edgeset) {}
+
+      virtual ~NodesImpl() {}
+      
+      bool attached() const {
+        return Parent::attached();
+      }
+
+    protected:
+
+      virtual void erase(const Node& node) {
+        try {
+          _edgeset.eraseNode(node);
+          Parent::erase(node);
+        } catch (const typename NodesImplBase::Notifier::ImmediateDetach&) {
+          Parent::clear();
+          throw;
+        }
+      }
+      virtual void erase(const std::vector<Node>& nodes) {
+        try {
+          for (int i = 0; i < int(nodes.size()); ++i) {
+            _edgeset.eraseNode(nodes[i]);
+          }
+          Parent::erase(nodes);
+        } catch (const typename NodesImplBase::Notifier::ImmediateDetach&) {
+          Parent::clear();
+          throw;
+        }
+      }
+      virtual void clear() {
+	_edgeset.clearNodes();
+	Parent::clear();
+      }
+
+    private:
+      SmartEdgeSet& _edgeset;
+    };
+
+    NodesImpl nodes;
+    
+  public:
+
+    /// \brief Constructor of the adaptor.
+    /// 
+    /// Constructor of the adaptor.
+    SmartEdgeSet(const Graph& graph) : nodes(graph, *this) {
+      Parent::initalize(graph, nodes);
+    }
+
+    bool valid() const {
+      return nodes.attached();
+    }
+    
+  };
+
+
+  template <typename _Graph>
+  class SmartUEdgeSetBase {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+
+  protected:
+
+    struct NodeT {
+      int first_out;
+      NodeT() : first_out(-1) {}
+    };
+
+    typedef DefaultMap<Graph, Node, NodeT> NodesImplBase;
+
+    NodesImplBase* nodes;
+
+    struct EdgeT {
+      Node target;
+      int next_out;
+      EdgeT() {}
+    };
+
+    std::vector<EdgeT> edges;
+
+    const Graph* graph;
+
+    void initalize(const Graph& _graph, NodesImplBase& _nodes) {
+      graph = &_graph;
+      nodes = &_nodes;
+    }
+    
+  public:
+
+    class UEdge {
+      friend class SmartUEdgeSetBase;
+    protected:
+
+      int id;
+      explicit UEdge(int _id) { id = _id;}
+
+    public:
+      UEdge() {}
+      UEdge (Invalid) { id = -1; }
+      bool operator==(const UEdge& edge) const {return id == edge.id;}
+      bool operator!=(const UEdge& edge) const {return id != edge.id;}
+      bool operator<(const UEdge& edge) const {return id < edge.id;}
+    };
+
+    class Edge {
+      friend class SmartUEdgeSetBase;
+    protected:
+      Edge(int _id) : id(_id) {}
+      int id;
+    public:
+      operator UEdge() const { return uEdgeFromId(id / 2); }
+
+      Edge() {}
+      Edge(Invalid) : id(-1) {}
+      bool operator==(const Edge& edge) const { return id == edge.id; }
+      bool operator!=(const Edge& edge) const { return id != edge.id; }
+      bool operator<(const Edge& edge) const { return id < edge.id; }
+    };
+
+    SmartUEdgeSetBase() {} 
+
+    UEdge addEdge(const Node& u, const Node& v) {
+      int n = edges.size();
+      edges.push_back(EdgeT());
+      edges.push_back(EdgeT());
+      
+      edges[n].target = u;
+      edges[n | 1].target = v;
+
+      edges[n].next_out = (*nodes)[v].first_out;
+      (*nodes)[v].first_out = n;
+
+      edges[n | 1].next_out = (*nodes)[u].first_out;	
+      (*nodes)[u].first_out = (n | 1);
+
+      return UEdge(n / 2);
+    }
+
+    void clear() {
+      Node node;
+      for (first(node); node != INVALID; next(node)) {
+        (*nodes)[node].first_out = -1;
+      }
+      edges.clear();
+    }
+
+    void first(Node& node) const {
+      graph->first(node);
+    }
+
+    void next(Node& node) const {
+      graph->next(node);
+    }
+
+    void first(Edge& edge) const { 
+      edge.id = edges.size() - 1;
+    }
+
+    void next(Edge& edge) const {
+      --edge.id;
+    }
+
+    void first(UEdge& edge) const { 
+      edge.id = edges.size() / 2 - 1;
+    }
+
+    void next(UEdge& edge) const {
+      --edge.id;
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      edge.id = (*nodes)[node].first_out;    
+    }
+    
+    void nextOut(Edge& edge) const {
+      edge.id = edges[edge.id].next_out;        
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      edge.id = (((*nodes)[node].first_out) ^ 1);
+      if (edge.id == -2) edge.id = -1;
+    }
+
+    void nextIn(Edge& edge) const {
+      edge.id = ((edges[edge.id ^ 1].next_out) ^ 1);
+      if (edge.id == -2) edge.id = -1;
+    }
+
+    void firstInc(UEdge &edge, bool& dir, const Node& node) const {
+      int de = (*nodes)[node].first_out;
+      if (de != -1 ) {
+        edge.id = de / 2;
+        dir = ((de & 1) == 1);
+      } else {
+        edge.id = -1;
+        dir = true;
+      }
+    }
+    void nextInc(UEdge &edge, bool& dir) const {
+      int de = (edges[(edge.id * 2) | (dir ? 1 : 0)].next_out);
+      if (de != -1 ) {
+        edge.id = de / 2;
+        dir = ((de & 1) == 1);
+      } else {
+        edge.id = -1;
+        dir = true;
+      }
+    }
+
+    static bool direction(Edge edge) {
+      return (edge.id & 1) == 1;
+    }
+
+    static Edge direct(UEdge uedge, bool dir) {
+      return Edge(uedge.id * 2 + (dir ? 1 : 0));
+    }
+
+    int id(Node node) const { return graph->id(node); }
+    static int id(Edge edge) { return edge.id; }
+    static int id(UEdge edge) { return edge.id; }
+
+    Node nodeFromId(int id) const { return graph->nodeFromId(id); }
+    static Edge edgeFromId(int id) { return Edge(id); }
+    static UEdge uEdgeFromId(int id) { return UEdge(id);}
+
+    int maxNodeId() const { return graph->maxNodeId(); };
+    int maxEdgeId() const { return edges.size() - 1; }
+    int maxUEdgeId() const { return edges.size() / 2 - 1; }
+
+    Node source(Edge e) const { return edges[e.id ^ 1].target; }
+    Node target(Edge e) const { return edges[e.id].target; }
+
+    Node source(UEdge e) const { return edges[2 * e.id].target; }
+    Node target(UEdge e) const { return edges[2 * e.id + 1].target; }
+
+    typedef typename ItemSetTraits<Graph, Node>::ItemNotifier NodeNotifier;
+
+    NodeNotifier& notifier(Node) const {
+      return graph->notifier(Node());
+    } 
+
+    template <typename _Value>
+    class NodeMap : public Graph::template NodeMap<_Value> {
+    public:
+
+      typedef typename _Graph::template NodeMap<_Value> Parent;
+
+      explicit NodeMap(const SmartUEdgeSetBase<Graph>& edgeset) 
+	: Parent(*edgeset.graph) { }
+
+      NodeMap(const SmartUEdgeSetBase<Graph>& edgeset, const _Value& value)
+	: Parent(*edgeset.graph, value) { }
+
+      NodeMap& operator=(const NodeMap& cmap) {
+        return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+    };
+
+  };
+
+  /// \ingroup semi_adaptors
+  ///
+  /// \brief Graph using a node set of another graph and an
+  /// own uedge set.
+  ///
+  /// This structure can be used to establish another graph over a node set
+  /// of an existing one. The node iterator will go through the nodes of the
+  /// original graph.
+  ///
+  /// \param _Graph The type of the graph which shares its node set with 
+  /// this class. Its interface must conform to the \ref concepts::Graph
+  /// "Graph" concept.
+  ///
+  /// In the edge extension and removing it conforms to the 
+  /// \ref concepts::UGraph "UGraph" concept.
+  template <typename _Graph>
+  class SmartUEdgeSet : public UEdgeSetExtender<SmartUEdgeSetBase<_Graph> > {
+
+  public:
+
+    typedef UEdgeSetExtender<SmartUEdgeSetBase<_Graph> > Parent;
+    
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+    
+    typedef _Graph Graph;
+
+  protected:
+
+    typedef typename Parent::NodesImplBase NodesImplBase;
+
+    void eraseNode(const Node& node) {
+      if (typename Parent::IncEdgeIt(*this, node) == INVALID) {
+        return;
+      }
+      throw typename NodesImplBase::Notifier::ImmediateDetach();
+    }
+    
+    void clearNodes() {
+      Parent::clear();
+    }
+
+    class NodesImpl : public NodesImplBase {
+    public:
+      typedef NodesImplBase Parent;
+      
+      NodesImpl(const Graph& graph, SmartUEdgeSet& edgeset) 
+	: Parent(graph), _edgeset(edgeset) {}
+
+      virtual ~NodesImpl() {}
+
+      bool attached() const {
+        return Parent::attached();
+      }
+      
+    protected:
+
+      virtual void erase(const Node& node) {
+        try {
+          _edgeset.eraseNode(node);
+          Parent::erase(node);
+        } catch (const typename NodesImplBase::Notifier::ImmediateDetach&) {
+          Parent::clear();
+          throw;
+        }
+      }
+      virtual void erase(const std::vector<Node>& nodes) {
+        try {
+          for (int i = 0; i < int(nodes.size()); ++i) {
+            _edgeset.eraseNode(nodes[i]);
+          }
+          Parent::erase(nodes);
+        } catch (const typename NodesImplBase::Notifier::ImmediateDetach&) {
+          Parent::clear();
+          throw;
+        }
+      }
+      virtual void clear() {
+	_edgeset.clearNodes();
+	Parent::clear();
+      }
+
+    private:
+      SmartUEdgeSet& _edgeset;
+    };
+
+    NodesImpl nodes;
+    
+  public:
+
+    /// \brief Constructor of the adaptor.
+    /// 
+    /// Constructor of the adaptor.
+    SmartUEdgeSet(const Graph& graph) : nodes(graph, *this) {
+      Parent::initalize(graph, nodes);
+    }
+
+    bool valid() const {
+      return nodes.attached();
+    }
+    
+  };
+
+}
+
+#endif
Index: lemon/edmonds_karp.h
===================================================================
--- lemon/edmonds_karp.h	(revision 2553)
+++ lemon/edmonds_karp.h	(revision 2553)
@@ -0,0 +1,530 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_EDMONDS_KARP_H
+#define LEMON_EDMONDS_KARP_H
+
+/// \file
+/// \ingroup max_flow
+/// \brief Implementation of the Edmonds-Karp algorithm.
+
+#include <lemon/tolerance.h>
+#include <vector>
+
+namespace lemon {
+
+  /// \brief Default traits class of EdmondsKarp class.
+  ///
+  /// Default traits class of EdmondsKarp class.
+  /// \param _Graph Graph type.
+  /// \param _CapacityMap Type of capacity map.
+  template <typename _Graph, typename _CapacityMap>
+  struct EdmondsKarpDefaultTraits {
+
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge capacities.
+    ///
+    /// The type of the map that stores the edge capacities.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _CapacityMap CapacityMap;
+
+    /// \brief The type of the length of the edges.
+    typedef typename CapacityMap::Value Value;
+
+    /// \brief The map type that stores the flow values.
+    ///
+    /// The map type that stores the flow values. 
+    /// It must meet the \ref concepts::ReadWriteMap "ReadWriteMap" concept.
+    typedef typename Graph::template EdgeMap<Value> FlowMap;
+
+    /// \brief Instantiates a FlowMap.
+    ///
+    /// This function instantiates a \ref FlowMap. 
+    /// \param graph The graph, to which we would like to define the flow map.
+    static FlowMap* createFlowMap(const Graph& graph) {
+      return new FlowMap(graph);
+    }
+
+    /// \brief The tolerance used by the algorithm
+    ///
+    /// The tolerance used by the algorithm to handle inexact computation.
+    typedef Tolerance<Value> Tolerance;
+
+  };
+
+  /// \ingroup max_flow
+  ///
+  /// \brief Edmonds-Karp algorithms class.
+  ///
+  /// This class provides an implementation of the \e Edmonds-Karp \e
+  /// algorithm producing a flow of maximum value in a directed
+  /// graphs. The Edmonds-Karp algorithm is slower than the Preflow
+  /// algorithm but it has an advantage of the step-by-step execution
+  /// control with feasible flow solutions. The \e source node, the \e
+  /// target node, the \e capacity of the edges and the \e starting \e
+  /// flow value of the edges should be passed to the algorithm
+  /// through the constructor.
+  ///
+  /// The time complexity of the algorithm is \f$ O(nm^2) \f$ in
+  /// worst case.  Always try the preflow algorithm instead of this if
+  /// you just want to compute the optimal flow.
+  ///
+  /// \param _Graph The directed graph type the algorithm runs on.
+  /// \param _CapacityMap The capacity map type.
+  /// \param _Traits Traits class to set various data types used by
+  /// the algorithm.  The default traits class is \ref
+  /// EdmondsKarpDefaultTraits.  See \ref EdmondsKarpDefaultTraits for the
+  /// documentation of a Edmonds-Karp traits class. 
+  ///
+  /// \author Balazs Dezso 
+#ifdef DOXYGEN
+  template <typename _Graph, typename _CapacityMap, typename _Traits>
+#else 
+  template <typename _Graph,
+	    typename _CapacityMap = typename _Graph::template EdgeMap<int>,
+            typename _Traits = EdmondsKarpDefaultTraits<_Graph, _CapacityMap> >
+#endif
+  class EdmondsKarp {
+  public:
+
+    typedef _Traits Traits;
+    typedef typename Traits::Graph Graph;
+    typedef typename Traits::CapacityMap CapacityMap;
+    typedef typename Traits::Value Value; 
+
+    typedef typename Traits::FlowMap FlowMap;
+    typedef typename Traits::Tolerance Tolerance;
+
+    /// \brief \ref Exception for the case when the source equals the target.
+    ///
+    /// \ref Exception for the case when the source equals the target.
+    ///
+    class InvalidArgument : public lemon::LogicError {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::EdmondsKarp::InvalidArgument";
+      }
+    };
+
+
+  private:
+
+    GRAPH_TYPEDEFS(typename Graph);
+    typedef typename Graph::template NodeMap<Edge> PredMap;
+    
+    const Graph& _graph;
+    const CapacityMap* _capacity;
+
+    Node _source, _target;
+
+    FlowMap* _flow;
+    bool _local_flow;
+
+    PredMap* _pred;
+    std::vector<Node> _queue;
+    
+    Tolerance _tolerance;
+    Value _flow_value;
+
+    void createStructures() {
+      if (!_flow) {
+	_flow = Traits::createFlowMap(_graph);
+	_local_flow = true;
+      }
+      if (!_pred) {
+	_pred = new PredMap(_graph);
+      }
+      _queue.resize(countNodes(_graph));
+    }
+
+    void destroyStructures() {
+      if (_local_flow) {
+	delete _flow;
+      }
+      if (_pred) {
+	delete _pred;
+      }
+    }
+    
+  public:
+
+    ///\name Named template parameters
+
+    ///@{
+
+    template <typename _FlowMap>
+    struct DefFlowMapTraits : public Traits {
+      typedef _FlowMap FlowMap;
+      static FlowMap *createFlowMap(const Graph&) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// FlowMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting FlowMap
+    /// type
+    template <typename _FlowMap>
+    struct DefFlowMap 
+      : public EdmondsKarp<Graph, CapacityMap, DefFlowMapTraits<_FlowMap> > {
+      typedef EdmondsKarp<Graph, CapacityMap, DefFlowMapTraits<_FlowMap> > 
+      Create;
+    };
+
+
+    /// @}
+
+  protected:
+    
+    EdmondsKarp() {}
+
+  public:
+
+    /// \brief The constructor of the class.
+    ///
+    /// The constructor of the class. 
+    /// \param graph The directed graph the algorithm runs on. 
+    /// \param capacity The capacity of the edges. 
+    /// \param source The source node.
+    /// \param target The target node.
+    EdmondsKarp(const Graph& graph, const CapacityMap& capacity,
+		Node source, Node target)
+      : _graph(graph), _capacity(&capacity), _source(source), _target(target),
+	_flow(0), _local_flow(false), _pred(0), _tolerance(), _flow_value()
+    {
+      if (_source == _target) {
+        throw InvalidArgument();
+      }
+    }
+
+    /// \brief Destrcutor.
+    ///
+    /// Destructor.
+    ~EdmondsKarp() {
+      destroyStructures();
+    }
+
+    /// \brief Sets the capacity map.
+    ///
+    /// Sets the capacity map.
+    /// \return \c (*this)
+    EdmondsKarp& capacityMap(const CapacityMap& map) {
+      _capacity = &map;
+      return *this;
+    }
+
+    /// \brief Sets the flow map.
+    ///
+    /// Sets the flow map.
+    /// \return \c (*this)
+    EdmondsKarp& flowMap(FlowMap& map) {
+      if (_local_flow) {
+	delete _flow;
+	_local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Returns the flow map.
+    ///
+    /// \return The flow map.
+    const FlowMap& flowMap() {
+      return *_flow;
+    }
+
+    /// \brief Sets the source node.
+    ///
+    /// Sets the source node.
+    /// \return \c (*this)
+    EdmondsKarp& source(const Node& node) {
+      _source = node;
+      return *this;
+    }
+
+    /// \brief Sets the target node.
+    ///
+    /// Sets the target node.
+    /// \return \c (*this)
+    EdmondsKarp& target(const Node& node) {
+      _target = node;
+      return *this;
+    }
+
+    /// \brief Sets the tolerance used by algorithm.
+    ///
+    /// Sets the tolerance used by algorithm.
+    EdmondsKarp& tolerance(const Tolerance& tolerance) const {
+      _tolerance = tolerance;
+      return *this;
+    } 
+
+    /// \brief Returns the tolerance used by algorithm.
+    ///
+    /// Returns the tolerance used by algorithm.
+    const Tolerance& tolerance() const {
+      return tolerance;
+    } 
+
+    /// \name Execution control The simplest way to execute the
+    /// algorithm is to use the \c run() member functions.
+    /// \n
+    /// If you need more control on initial solution or
+    /// execution then you have to call one \ref init() function and then
+    /// the start() or multiple times the \c augment() member function.  
+    
+    ///@{
+
+    /// \brief Initializes the algorithm
+    /// 
+    /// It sets the flow to empty flow.
+    void init() {
+      createStructures();
+      for (EdgeIt it(_graph); it != INVALID; ++it) {
+        _flow->set(it, 0);
+      }
+      _flow_value = 0;
+    }
+    
+    /// \brief Initializes the algorithm
+    /// 
+    /// Initializes the flow to the \c flowMap. The \c flowMap should
+    /// contain a feasible flow, ie. in each node excluding the source
+    /// and the target the incoming flow should be equal to the
+    /// outgoing flow.
+    template <typename FlowMap>
+    void flowInit(const FlowMap& flowMap) {
+      createStructures();
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+	_flow->set(e, flowMap[e]);
+      }
+      _flow_value = 0;
+      for (OutEdgeIt jt(_graph, _source); jt != INVALID; ++jt) {
+        _flow_value += (*_flow)[jt];
+      }
+      for (InEdgeIt jt(_graph, _source); jt != INVALID; ++jt) {
+        _flow_value -= (*_flow)[jt];
+      }
+    }
+
+    /// \brief Initializes the algorithm
+    /// 
+    /// Initializes the flow to the \c flowMap. The \c flowMap should
+    /// contain a feasible flow, ie. in each node excluding the source
+    /// and the target the incoming flow should be equal to the
+    /// outgoing flow.  
+    /// \return %False when the given flowMap does not contain
+    /// feasible flow.
+    template <typename FlowMap>
+    bool checkedFlowInit(const FlowMap& flowMap) {
+      createStructures();
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+	_flow->set(e, flowMap[e]);
+      }
+      for (NodeIt it(_graph); it != INVALID; ++it) {
+        if (it == _source || it == _target) continue;
+        Value outFlow = 0;
+        for (OutEdgeIt jt(_graph, it); jt != INVALID; ++jt) {
+          outFlow += (*_flow)[jt];
+        }
+        Value inFlow = 0;
+        for (InEdgeIt jt(_graph, it); jt != INVALID; ++jt) {
+          inFlow += (*_flow)[jt];
+        }
+        if (_tolerance.different(outFlow, inFlow)) {
+          return false;
+        }
+      }
+      for (EdgeIt it(_graph); it != INVALID; ++it) {
+        if (_tolerance.less((*_flow)[it], 0)) return false;
+        if (_tolerance.less((*_capacity)[it], (*_flow)[it])) return false;
+      }
+      _flow_value = 0;
+      for (OutEdgeIt jt(_graph, _source); jt != INVALID; ++jt) {
+        _flow_value += (*_flow)[jt];
+      }
+      for (InEdgeIt jt(_graph, _source); jt != INVALID; ++jt) {
+        _flow_value -= (*_flow)[jt];
+      }
+      return true;
+    }
+
+    /// \brief Augment the solution on an edge shortest path.
+    /// 
+    /// Augment the solution on an edge shortest path. It search an
+    /// edge shortest path between the source and the target
+    /// in the residual graph with the bfs algoritm.
+    /// Then it increase the flow on this path with the minimal residual
+    /// capacity on the path. If there is not such path it gives back
+    /// false.
+    /// \return %False when the augmenting is not success so the
+    /// current flow is a feasible and optimal solution.
+    bool augment() {
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	_pred->set(n, INVALID);
+      }
+      
+      int first = 0, last = 1;
+      
+      _queue[0] = _source;
+      _pred->set(_source, OutEdgeIt(_graph, _source));
+
+      while (first != last && (*_pred)[_target] == INVALID) {
+	Node n = _queue[first++];
+	
+	for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Value rem = (*_capacity)[e] - (*_flow)[e];
+	  Node t = _graph.target(e);
+	  if (_tolerance.positive(rem) && (*_pred)[t] == INVALID) {
+	    _pred->set(t, e);
+	    _queue[last++] = t;
+	  }
+	}
+	for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Value rem = (*_flow)[e];
+	  Node t = _graph.source(e);
+	  if (_tolerance.positive(rem) && (*_pred)[t] == INVALID) {
+	    _pred->set(t, e);
+	    _queue[last++] = t;
+	  }
+	}
+      }
+
+      if ((*_pred)[_target] != INVALID) {
+	Node n = _target;
+	Edge e = (*_pred)[n];
+
+	Value prem = (*_capacity)[e] - (*_flow)[e];
+	n = _graph.source(e);
+	while (n != _source) {
+	  e = (*_pred)[n];
+	  if (_graph.target(e) == n) {
+	    Value rem = (*_capacity)[e] - (*_flow)[e];
+	    if (rem < prem) prem = rem;
+	    n = _graph.source(e);
+	  } else {
+	    Value rem = (*_flow)[e];
+	    if (rem < prem) prem = rem;
+	    n = _graph.target(e);   
+	  } 
+	}
+
+	n = _target;
+	e = (*_pred)[n];
+
+	_flow->set(e, (*_flow)[e] + prem);
+	n = _graph.source(e);
+	while (n != _source) {
+	  e = (*_pred)[n];
+	  if (_graph.target(e) == n) {
+	    _flow->set(e, (*_flow)[e] + prem);
+	    n = _graph.source(e);
+	  } else {
+	    _flow->set(e, (*_flow)[e] - prem);
+	    n = _graph.target(e);   
+	  } 
+	}
+
+	_flow_value += prem;	
+	return true;
+      } else {
+	return false;
+      }
+    }
+
+    /// \brief Executes the algorithm
+    ///
+    /// It runs augmenting phases until the optimal solution is reached. 
+    void start() {
+      while (augment()) {}
+    }
+
+    /// \brief runs the algorithm.
+    /// 
+    /// It is just a shorthand for:
+    ///
+    ///\code 
+    /// ek.init();
+    /// ek.start();
+    ///\endcode
+    void run() {
+      init();
+      start();
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the Edmonds-Karp algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    /// \brief Returns the value of the maximum flow.
+    ///
+    /// Returns the value of the maximum flow by returning the excess
+    /// of the target node \c t. This value equals to the value of
+    /// the maximum flow already after the first phase.
+    Value flowValue() const {
+      return _flow_value;
+    }
+
+
+    /// \brief Returns the flow on the edge.
+    ///
+    /// Sets the \c flowMap to the flow on the edges. This method can
+    /// be called after the second phase of algorithm.
+    Value flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// \brief Returns true when the node is on the source side of minimum cut.
+    ///
+
+    /// Returns true when the node is on the source side of minimum
+    /// cut. This method can be called both after running \ref
+    /// startFirstPhase() and \ref startSecondPhase().
+    bool minCut(const Node& node) const {
+      return (*_pred)[node] != INVALID;
+    }
+
+    /// \brief Returns a minimum value cut.
+    ///
+    /// Sets \c cut to the characteristic vector of a minimum value cut
+    /// It simply calls the minMinCut member.
+    /// \retval cut Write node bool map. 
+    template <typename CutMap>
+    void minCutMap(CutMap& cutMap) const {
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	cutMap.set(n, (*_pred)[n] != INVALID);
+      }
+      cutMap.set(_source, true);
+    }    
+
+    /// @}
+
+  };
+
+}
+
+#endif
Index: lemon/elevator.h
===================================================================
--- lemon/elevator.h	(revision 2633)
+++ lemon/elevator.h	(revision 2633)
@@ -0,0 +1,1002 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_ELEVATOR_H
+#define LEMON_ELEVATOR_H
+
+///\ingroup auxdat
+///\file
+///\brief Elevator class
+///
+///Elevator class implements an efficient data structure
+///for labeling items in push-relabel type algorithms.
+///
+
+namespace lemon {
+
+  ///Class for handling "labels" in push-relabel type algorithms.
+  
+  ///A class for handling "labels" in push-relabel type algorithms.
+  ///
+  ///\ingroup auxdat
+  ///Using this class you can assign "labels" (nonnegative integer numbers)
+  ///to the edges or nodes of a graph, manipulate and query them through
+  ///operations typically arising in "push-relabel" type algorithms.
+  ///
+  ///Each item is either \em active or not, and you can also choose a
+  ///highest level active item.
+  ///
+  ///\sa LinkedElevator
+  ///
+  ///\param Graph the underlying graph type
+  ///\param Item Type of the items the data is assigned to (Graph::Node,
+  ///Graph::Edge, Graph::UEdge)
+  template<class Graph, class Item>
+  class Elevator 
+  {
+  public:
+
+    typedef Item Key;
+    typedef int Value;
+
+  private:
+
+    typedef typename std::vector<Item>::iterator Vit;
+    typedef typename ItemSetTraits<Graph,Item>::template Map<Vit>::Type VitMap;
+    typedef typename ItemSetTraits<Graph,Item>::template Map<int>::Type IntMap;
+
+    const Graph &_g;
+    int _max_level;
+    int _item_num;
+    VitMap _where;
+    IntMap _level;
+    std::vector<Item> _items;
+    std::vector<Vit> _first;
+    std::vector<Vit> _last_active;
+
+    int _highest_active;
+
+    void copy(Item i, Vit p)
+    {
+      _where[*p=i]=p;
+    }
+    void copy(Vit s, Vit p)
+    {
+      if(s!=p) 
+	{
+	  Item i=*s;
+	  *p=i;
+	  _where[i]=p;
+	}
+    }
+    void swap(Vit i, Vit j)
+    {
+      Item ti=*i;
+      Vit ct = _where[ti];
+      _where[ti]=_where[*i=*j];
+      _where[*j]=ct;
+      *j=ti;
+    }
+    
+  public:
+        
+    ///Constructor with given maximum level.
+
+    ///Constructor with given maximum level.
+    ///
+    ///\param g The underlying graph
+    ///\param max_level Set the range of the possible labels to
+    ///[0...\c max_level]
+    Elevator(const Graph &g,int max_level) :
+      _g(g),
+      _max_level(max_level),
+      _item_num(_max_level),
+      _where(g),
+      _level(g,0),
+      _items(_max_level),
+      _first(_max_level+2),
+      _last_active(_max_level+2),
+      _highest_active(-1) {}
+    ///Constructor.
+
+    ///Constructor.
+    ///
+    ///\param g The underlying graph
+    ///The range of the possible labels is [0...\c max_level],
+    ///where \c max_level is equal to the number of labeled items in the graph.
+    Elevator(const Graph &g) :
+      _g(g),
+      _max_level(countItems<Graph, Item>(g)),
+      _item_num(_max_level),
+      _where(g),
+      _level(g,0),
+      _items(_max_level),
+      _first(_max_level+2),
+      _last_active(_max_level+2),
+      _highest_active(-1)
+    {
+    }
+    
+    ///Activate item \c i.
+
+    ///Activate item \c i.
+    ///\pre Item \c i shouldn't be active before.
+    void activate(Item i)
+    {
+      const int l=_level[i];
+      swap(_where[i],++_last_active[l]);
+      if(l>_highest_active) _highest_active=l;
+    }
+  
+    ///Deactivate item \c i.
+
+    ///Deactivate item \c i.
+    ///\pre Item \c i must be active before.
+    void deactivate(Item i)  
+    {
+      swap(_where[i],_last_active[_level[i]]--);
+      while(_highest_active>=0 &&
+	    _last_active[_highest_active]<_first[_highest_active])
+	_highest_active--;
+    }
+
+    ///Query whether item \c i is active
+    bool active(Item i) const { return _where[i]<=_last_active[_level[i]]; }
+    
+    ///Return the level of item \c i.
+    int operator[](Item i) const { return _level[i]; }
+
+    ///Return the number of items on level \c l.
+    int onLevel(int l) const
+    {
+      return _first[l+1]-_first[l];
+    }
+    ///Return true if the level is empty.
+    bool emptyLevel(int l) const
+    {
+      return _first[l+1]-_first[l]==0;
+    }
+    ///Return the number of items above level \c l.
+    int aboveLevel(int l) const
+    {
+      return _first[_max_level+1]-_first[l+1];
+    }
+    ///Return the number of active items on level \c l.
+    int activesOnLevel(int l) const
+    {
+      return _last_active[l]-_first[l]+1;
+    }
+    ///Return true if there is not active item on level \c l.
+    bool activeFree(int l) const
+    {
+      return _last_active[l]<_first[l];
+    }
+    ///Return the maximum allowed level.
+    int maxLevel() const 
+    {
+      return _max_level;
+    }    
+
+    ///\name Highest Active Item
+    ///Functions for working with the highest level
+    ///active item.
+
+    ///@{
+
+    ///Return a highest level active item.
+  
+    ///Return a highest level active item.
+    ///
+    ///\return the highest level active item or INVALID if there is no active
+    ///item.
+    Item highestActive() const 
+    {
+      return _highest_active>=0?*_last_active[_highest_active]:INVALID;
+    }
+
+    ///Return a highest active level.
+
+    ///Return a highest active level.
+    ///
+    ///\return the level of the highest active item or -1 if there is no active
+    ///item.
+    int highestActiveLevel() const 
+    {
+      return _highest_active;
+    }
+
+    ///Lift the highest active item by one.
+
+    ///Lift the item returned by highestActive() by one.
+    ///
+    void liftHighestActive() 
+    {
+      ++_level[*_last_active[_highest_active]];
+      swap(_last_active[_highest_active]--,_last_active[_highest_active+1]);
+      --_first[++_highest_active];
+    }
+
+    ///Lift the highest active item.
+
+    ///Lift the item returned by highestActive() to level \c new_level.
+    ///
+    ///\warning \c new_level must be strictly higher
+    ///than the current level.
+    ///
+    void liftHighestActive(int new_level) 
+    {
+      const Item li = *_last_active[_highest_active];
+      
+      copy(--_first[_highest_active+1],_last_active[_highest_active]--);
+      for(int l=_highest_active+1;l<new_level;l++)
+	{
+	  copy(--_first[l+1],_first[l]);
+	  --_last_active[l];
+	}
+      copy(li,_first[new_level]);
+      _level[li]=new_level;
+      _highest_active=new_level;
+    }
+
+    ///Lift the highest active item.
+
+    ///Lift the item returned by highestActive() to the top level and
+    ///deactivates it.
+    ///
+    ///\warning \c new_level must be strictly higher
+    ///than the current level.
+    ///
+    void liftHighestActiveToTop() 
+    {
+      const Item li = *_last_active[_highest_active];
+      
+      copy(--_first[_highest_active+1],_last_active[_highest_active]--);
+      for(int l=_highest_active+1;l<_max_level;l++)
+	{
+	  copy(--_first[l+1],_first[l]);
+	  --_last_active[l];
+	}
+      copy(li,_first[_max_level]);
+      --_last_active[_max_level];
+      _level[li]=_max_level;
+
+      while(_highest_active>=0 &&
+	    _last_active[_highest_active]<_first[_highest_active])
+	_highest_active--;
+    }
+    
+    ///@}
+    
+    ///\name Active Item on Certain Level 
+    ///Functions for working with the active items.
+
+    ///@{
+
+    ///Returns an active item on level \c l.
+    
+    ///Returns an active item on level \c l.
+    ///
+    ///Returns an active item on level \c l or \ref INVALID if there is no such
+    ///an item. (\c l must be from the range [0...\c max_level].
+    Item activeOn(int l) const
+    { 
+      return _last_active[l]>=_first[l]?*_last_active[l]:INVALID;
+    }
+
+    ///Lifts the active item returned by \c activeOn() member function.
+    
+    ///Lifts the active item returned by \c activeOn() member function
+    ///by one.
+    Item liftActiveOn(int level)
+    { 
+      ++_level[*_last_active[level]];
+      swap(_last_active[level]--, --_first[level+1]);
+      if (level+1>_highest_active) ++_highest_active;
+    }
+
+    ///Lifts the active item returned by \c activeOn() member function.
+    
+    ///Lifts the active item returned by \c activeOn() member function
+    ///to the given level.
+    void liftActiveOn(int level, int new_level)
+    { 
+      const Item ai = *_last_active[level];
+      
+      copy(--_first[level+1], _last_active[level]--);
+      for(int l=level+1;l<new_level;l++)
+	{
+	  copy(_last_active[l],_first[l]);
+	  copy(--_first[l+1], _last_active[l]--);
+	}
+      copy(ai,_first[new_level]);
+      _level[ai]=new_level;
+      if (new_level>_highest_active) _highest_active=new_level;
+    }
+
+    ///Lifts the active item returned by \c activeOn() member function.
+    
+    ///Lifts the active item returned by \c activeOn() member function
+    ///to the top level.
+    void liftActiveToTop(int level)
+    {
+      const Item ai = *_last_active[level];
+      
+      copy(--_first[level+1],_last_active[level]--);
+      for(int l=level+1;l<_max_level;l++)
+	{
+	  copy(_last_active[l],_first[l]);
+	  copy(--_first[l+1], _last_active[l]--);
+	}
+      copy(ai,_first[_max_level]);
+      --_last_active[_max_level];
+      _level[ai]=_max_level;
+
+      if (_highest_active==level) {
+	while(_highest_active>=0 && 
+	      _last_active[_highest_active]<_first[_highest_active]) 
+	  _highest_active--;
+      }
+    }
+
+    ///@}
+    
+    ///Lift an active item to a higher level.
+
+    ///Lift an active item to a higher level.
+    ///\param i The item to be lifted. It must be active.
+    ///\param new_level The new level of \c i. It must be strictly higher
+    ///than the current level.
+    ///
+    void lift(Item i, int new_level) 
+    {
+      const int lo = _level[i];
+      const Vit w = _where[i];
+
+      copy(_last_active[lo],w);
+      copy(--_first[lo+1],_last_active[lo]--);
+      for(int l=lo+1;l<new_level;l++)
+	{
+	  copy(_last_active[l],_first[l]);
+	  copy(--_first[l+1],_last_active[l]--);
+	}
+      copy(i,_first[new_level]);
+      _level[i]=new_level;
+      if(new_level>_highest_active) _highest_active=new_level;
+    }
+
+    ///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 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 - 1;
+    }
+    
+    ///Lift all nodes on and above a level to the top (and deactivate them).
+
+    ///This function lifts all nodes on and above level \c l to \c
+    ///maxLevel(), and also deactivates them.
+    void liftToTop(int l) 
+    {
+      const Vit f=_first[l];
+      const Vit tl=_first[_max_level];
+      for(Vit i=f;i!=tl;++i)
+	_level[*i]=_max_level;
+      for(int i=l;i<=_max_level;i++)
+	{
+	  _first[i]=f;
+	  _last_active[i]=f-1;
+	}
+      for(_highest_active=l-1;
+	  _highest_active>=0 &&
+	    _last_active[_highest_active]<_first[_highest_active];
+	  _highest_active--) ;
+    }
+    
+  private:
+    int _init_lev;
+    Vit _init_num;
+
+  public:
+
+    ///\name Initialization
+    ///Using this function you can initialize the levels of the item.
+    ///\n
+    ///This initializatios is started with calling \c initStart().
+    ///Then the
+    ///items should be listed levels by levels statring with the lowest one
+    ///(with level 0). This is done by using \c initAddItem()
+    ///and \c initNewLevel(). Finally \c initFinish() must be called.
+    ///The items not listed will be put on the highest level.
+    ///@{
+
+    ///Start the initialization process.
+
+    void initStart() 
+    {
+      _init_lev=0;
+      _init_num=_items.begin();
+      _first[0]=_items.begin();
+      _last_active[0]=_items.begin()-1;
+      Vit n=_items.begin();
+      for(typename ItemSetTraits<Graph,Item>::ItemIt i(_g);i!=INVALID;++i)
+	{
+	  *n=i;
+	  _where[i]=n;
+	  _level[i]=_max_level;
+	  ++n;
+	}
+    }
+
+    ///Add an item to the current level.
+
+    void initAddItem(Item i)
+    { 
+     swap(_where[i],_init_num);
+      _level[i]=_init_lev;
+      ++_init_num;
+    }
+
+    ///Start a new level.
+
+    ///Start a new level.
+    ///It shouldn't be used before the items on level 0 are listed.
+    void initNewLevel() 
+    {
+      _init_lev++;
+      _first[_init_lev]=_init_num;
+      _last_active[_init_lev]=_init_num-1;
+    }
+
+    ///Finalize the initialization process.
+
+    void initFinish()
+    {
+      for(_init_lev++;_init_lev<=_max_level;_init_lev++)
+	{
+	  _first[_init_lev]=_init_num;
+	  _last_active[_init_lev]=_init_num-1;
+	}
+      _first[_max_level+1]=_items.begin()+_item_num;
+      _last_active[_max_level+1]=_items.begin()+_item_num-1;
+      _highest_active = -1;
+    }
+
+    ///@}
+
+  };
+
+  ///Class for handling "labels" in push-relabel type algorithms.
+  
+  ///A class for handling "labels" in push-relabel type algorithms.
+  ///
+  ///\ingroup auxdat
+  ///Using this class you can assign "labels" (nonnegative integer numbers)
+  ///to the edges or nodes of a graph, manipulate and query them through
+  ///operations typically arising in "push-relabel" type algorithms.
+  ///
+  ///Each item is either \em active or not, and you can also choose a
+  ///highest level active item.
+  ///
+  ///\sa Elevator
+  ///
+  ///\param Graph the underlying graph type
+  ///\param Item Type of the items the data is assigned to (Graph::Node,
+  ///Graph::Edge, Graph::UEdge)
+  template <class Graph, class Item>
+  class LinkedElevator {
+  public:
+
+    typedef Item Key;
+    typedef int Value;
+
+  private:
+
+    typedef typename ItemSetTraits<Graph,Item>::
+    template Map<Item>::Type ItemMap;
+    typedef typename ItemSetTraits<Graph,Item>::
+    template Map<int>::Type IntMap;
+    typedef typename ItemSetTraits<Graph,Item>::
+    template Map<bool>::Type BoolMap;
+
+    const Graph &_graph;
+    int _max_level;
+    int _item_num;
+    std::vector<Item> _first, _last;
+    ItemMap _prev, _next;    
+    int _highest_active;
+    IntMap _level;
+    BoolMap _active;
+    
+  public:
+    ///Constructor with given maximum level.
+
+    ///Constructor with given maximum level.
+    ///
+    ///\param g The underlying graph
+    ///\param max_level Set the range of the possible labels to
+    ///[0...\c max_level]
+    LinkedElevator(const Graph& graph, int max_level) 
+      : _graph(graph), _max_level(max_level), _item_num(_max_level), 
+	_first(_max_level + 1), _last(_max_level + 1),
+	_prev(graph), _next(graph),      
+	_highest_active(-1), _level(graph), _active(graph) {}
+
+    ///Constructor.
+
+    ///Constructor.
+    ///
+    ///\param g The underlying graph
+    ///The range of the possible labels is [0...\c max_level],
+    ///where \c max_level is equal to the number of labeled items in the graph.
+    LinkedElevator(const Graph& graph) 
+      : _graph(graph), _max_level(countItems<Graph, Item>(graph)), 
+	_item_num(_max_level), 
+	_first(_max_level + 1), _last(_max_level + 1),
+	_prev(graph, INVALID), _next(graph, INVALID),      
+	_highest_active(-1), _level(graph), _active(graph) {}
+  
+
+    ///Activate item \c i.
+
+    ///Activate item \c i.
+    ///\pre Item \c i shouldn't be active before.
+    void activate(Item i) {
+      _active.set(i, true);
+
+      int level = _level[i];
+      if (level > _highest_active) {
+	_highest_active = level;
+      }
+
+      if (_prev[i] == INVALID || _active[_prev[i]]) return;	    
+      //unlace
+      _next.set(_prev[i], _next[i]);
+      if (_next[i] != INVALID) {
+	_prev.set(_next[i], _prev[i]);
+      } else {
+	_last[level] = _prev[i];
+      }
+      //lace
+      _next.set(i, _first[level]);
+      _prev.set(_first[level], i);
+      _prev.set(i, INVALID);
+      _first[level] = i;
+
+    }
+  
+    ///Deactivate item \c i.
+
+    ///Deactivate item \c i.
+    ///\pre Item \c i must be active before.
+    void deactivate(Item i) {
+      _active.set(i, false);
+      int level = _level[i];
+
+      if (_next[i] == INVALID || !_active[_next[i]])
+	goto find_highest_level;
+
+      //unlace
+      _prev.set(_next[i], _prev[i]);
+      if (_prev[i] != INVALID) {
+	_next.set(_prev[i], _next[i]);
+      } else {
+	_first[_level[i]] = _next[i];
+      }
+      //lace
+      _prev.set(i, _last[level]);
+      _next.set(_last[level], i);
+      _next.set(i, INVALID);
+      _last[level] = i;
+      
+    find_highest_level:
+      if (level == _highest_active) {
+	while (_highest_active >= 0 && activeFree(_highest_active)) 
+	  --_highest_active;
+      }
+    }
+
+    ///Query whether item \c i is active
+    bool active(Item i) const { return _active[i]; }
+    
+    ///Return the level of item \c i.
+    int operator[](Item i) const { return _level[i]; }
+    
+    ///Return the number of items on level \c l.
+    int onLevel(int l) const {
+      int num = 0;
+      Item n = _first[l];
+      while (n != INVALID) {
+	++num;
+	n = _next[n];
+      }
+      return num;
+    }
+
+    ///Return true if the level is empty.
+    bool emptyLevel(int l) const {
+      return _first[l] == INVALID;
+    }
+
+    ///Return the number of items above level \c l.
+    int aboveLevel(int l) const {
+      int num = 0;
+      for (int level = l + 1; level < _max_level; ++level)
+	num += onLevel(level);
+      return num;
+    }
+
+    ///Return the number of active items on level \c l.
+    int activesOnLevel(int l) const {
+      int num = 0;
+      Item n = _first[l];
+      while (n != INVALID && _active[n]) {
+	++num;
+	n = _next[n];
+      }
+      return num;
+    }
+
+    ///Return true if there is not active item on level \c l.
+    bool activeFree(int l) const {
+      return _first[l] == INVALID || !_active[_first[l]];
+    }
+
+    ///Return the maximum allowed level.
+    int maxLevel() const {
+      return _max_level;
+    }    
+
+    ///\name Highest Active Item
+    ///Functions for working with the highest level
+    ///active item.
+
+    ///@{
+
+    ///Return a highest level active item.
+  
+    ///Return a highest level active item.
+    ///
+    ///\return the highest level active item or INVALID if there is no
+    ///active item.
+    Item highestActive() const {
+      return _highest_active >= 0 ? _first[_highest_active] : INVALID;
+    }
+
+    ///Return a highest active level.
+
+    ///Return a highest active level.
+    ///
+    ///\return the level of the highest active item or -1 if there is
+    ///no active item.
+    int highestActiveLevel() const {
+      return _highest_active;
+    }
+
+    ///Lift the highest active item by one.
+
+    ///Lift the item returned by highestActive() by one.
+    ///
+    void liftHighestActive() {
+      Item i = _first[_highest_active];
+      if (_next[i] != INVALID) {
+	_prev.set(_next[i], INVALID);
+	_first[_highest_active] = _next[i]; 
+      } else {
+	_first[_highest_active] = INVALID;
+	_last[_highest_active] = INVALID;
+      }
+      _level.set(i, ++_highest_active);
+      if (_first[_highest_active] == INVALID) {
+	_first[_highest_active] = i;
+	_last[_highest_active] = i;
+	_prev.set(i, INVALID);
+	_next.set(i, INVALID);
+      } else {
+	_prev.set(_first[_highest_active], i);
+	_next.set(i, _first[_highest_active]);
+	_first[_highest_active] = i;
+      }
+    }
+
+    ///Lift the highest active item.
+
+    ///Lift the item returned by highestActive() to level \c new_level.
+    ///
+    ///\warning \c new_level must be strictly higher
+    ///than the current level.
+    ///
+    void liftHighestActive(int new_level) {
+      Item i = _first[_highest_active];
+      if (_next[i] != INVALID) {
+	_prev.set(_next[i], INVALID);
+	_first[_highest_active] = _next[i]; 
+      } else {
+	_first[_highest_active] = INVALID;
+	_last[_highest_active] = INVALID;
+      }
+      _level.set(i, _highest_active = new_level);
+      if (_first[_highest_active] == INVALID) {
+	_first[_highest_active] = _last[_highest_active] = i;
+	_prev.set(i, INVALID);
+	_next.set(i, INVALID);
+      } else {
+	_prev.set(_first[_highest_active], i);
+	_next.set(i, _first[_highest_active]);
+	_first[_highest_active] = i;
+      }
+    }
+
+    ///Lift the highest active to top.
+
+    ///Lift the item returned by highestActive() to the top level and
+    ///deactivates the node.
+    ///
+    void liftHighestActiveToTop() {
+      Item i = _first[_highest_active];
+      _level.set(i, _max_level);
+      if (_next[i] != INVALID) {
+	_prev.set(_next[i], INVALID);
+	_first[_highest_active] = _next[i]; 
+      } else {
+	_first[_highest_active] = INVALID;
+	_last[_highest_active] = INVALID;
+      }
+      while (_highest_active >= 0 && activeFree(_highest_active)) 
+	--_highest_active;
+    }
+    
+    ///@}
+
+    ///\name Active Item on Certain Level 
+    ///Functions for working with the active items.
+
+    ///@{
+
+    ///Returns an active item on level \c l.
+    
+    ///Returns an active item on level \c l.
+    ///
+    ///Returns an active item on level \c l or \ref INVALID if there is no such
+    ///an item. (\c l must be from the range [0...\c max_level].
+    Item activeOn(int l) const
+    { 
+      return _active[_first[l]] ? _first[l] : INVALID;
+    }
+
+    ///Lifts the active item returned by \c activeOn() member function.
+    
+    ///Lifts the active item returned by \c activeOn() member function
+    ///by one.
+    Item liftActiveOn(int l)
+    { 
+      Item i = _first[l];
+      if (_next[i] != INVALID) {
+	_prev.set(_next[i], INVALID);
+	_first[l] = _next[i]; 
+      } else {
+	_first[l] = INVALID;
+	_last[l] = INVALID;
+      }
+      _level.set(i, ++l);
+      if (_first[l] == INVALID) {
+	_first[l] = _last[l] = i;
+	_prev.set(i, INVALID);
+	_next.set(i, INVALID);
+      } else {
+	_prev.set(_first[l], i);
+	_next.set(i, _first[l]);
+	_first[l] = i;
+      }
+      if (_highest_active < l) {
+	_highest_active = l;
+      }
+    }
+
+    /// \brief Lifts the active item returned by \c activeOn() member function.
+    ///    
+    /// Lifts the active item returned by \c activeOn() member function
+    /// to the given level.
+    void liftActiveOn(int l, int new_level)
+    { 
+      Item i = _first[l];
+      if (_next[i] != INVALID) {
+	_prev.set(_next[i], INVALID);
+	_first[l] = _next[i]; 
+      } else {
+	_first[l] = INVALID;
+	_last[l] = INVALID;
+      }
+      _level.set(i, l = new_level);
+      if (_first[l] == INVALID) {
+	_first[l] = _last[l] = i;
+	_prev.set(i, INVALID);
+	_next.set(i, INVALID);
+      } else {
+	_prev.set(_first[l], i);
+	_next.set(i, _first[l]);
+	_first[l] = i;
+      }
+      if (_highest_active < l) {
+	_highest_active = l;
+      }
+    }
+
+    ///Lifts the active item returned by \c activeOn() member function.
+    
+    ///Lifts the active item returned by \c activeOn() member function
+    ///to the top level.
+    void liftActiveToTop(int l)
+    { 
+      Item i = _first[l];
+      if (_next[i] != INVALID) {
+	_prev.set(_next[i], INVALID);
+	_first[l] = _next[i]; 
+      } else {
+	_first[l] = INVALID;
+	_last[l] = INVALID;
+      }
+      _level.set(i, _max_level);
+      if (l == _highest_active) {
+	while (_highest_active >= 0 && activeFree(_highest_active)) 
+	  --_highest_active;
+      }
+    }
+
+    ///@}
+    
+    /// \brief Lift an active item to a higher level.
+    ///
+    /// Lift an active item to a higher level.
+    /// \param i The item to be lifted. It must be active.
+    /// \param new_level The new level of \c i. It must be strictly higher
+    /// than the current level.
+    ///
+    void lift(Item i, int new_level) {
+      if (_next[i] != INVALID) {
+	_prev.set(_next[i], _prev[i]);
+      } else {
+	_last[new_level] = _prev[i];
+      }
+      if (_prev[i] != INVALID) {
+	_next.set(_prev[i], _next[i]);
+      } else {
+	_first[new_level] = _next[i];
+      }
+      _level.set(i, new_level);
+      if (_first[new_level] == INVALID) {
+	_first[new_level] = _last[new_level] = i;
+	_prev.set(i, INVALID);
+	_next.set(i, INVALID);
+      } else {
+	_prev.set(_first[new_level], i);
+	_next.set(i, _first[new_level]);
+	_first[new_level] = i;
+      }
+      if (_highest_active < new_level) {
+	_highest_active = new_level;
+      }
+    }
+    
+    ///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 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.set(i, _max_level - 1);
+    }
+
+    ///Lift all nodes on and above a level to the top (and deactivate them).
+
+    ///This function lifts all nodes on and above level \c l to \c
+    ///maxLevel(), and also deactivates them. 
+    void liftToTop(int l)  {
+      for (int i = l + 1; _first[i] != INVALID; ++i) {
+	Item n = _first[i];
+	while (n != INVALID) {
+	  _level.set(n, _max_level);
+	  n = _next[n];
+	}
+	_first[i] = INVALID;
+	_last[i] = INVALID;
+      }
+      if (_highest_active > l - 1) {
+	_highest_active = l - 1;
+	while (_highest_active >= 0 && activeFree(_highest_active)) 
+	  --_highest_active;
+      }
+    }
+    
+  private:
+
+    int _init_level;
+
+  public:
+
+    ///\name Initialization
+    ///Using this function you can initialize the levels of the item.
+    ///\n
+    ///This initializatios is started with calling \c initStart().
+    ///Then the
+    ///items should be listed levels by levels statring with the lowest one
+    ///(with level 0). This is done by using \c initAddItem()
+    ///and \c initNewLevel(). Finally \c initFinish() must be called.
+    ///The items not listed will be put on the highest level.
+    ///@{
+
+    ///Start the initialization process.
+
+    void initStart() {
+      
+      for (int i = 0; i <= _max_level; ++i) {
+	_first[i] = _last[i] = INVALID;
+      }
+      _init_level = 0;
+      for(typename ItemSetTraits<Graph,Item>::ItemIt i(_graph); 
+	  i != INVALID; ++i) {
+	_level.set(i, _max_level);
+	_active.set(i, false);
+      }
+    }
+
+    ///Add an item to the current level.
+
+    void initAddItem(Item i) {
+      _level.set(i, _init_level);
+      if (_last[_init_level] == INVALID) {
+	_first[_init_level] = i;
+	_last[_init_level] = i;
+	_prev.set(i, INVALID);
+	_next.set(i, INVALID);
+      } else {
+	_prev.set(i, _last[_init_level]);
+	_next.set(i, INVALID);
+	_next.set(_last[_init_level], i);
+	_last[_init_level] = i;
+      }
+    }
+
+    ///Start a new level.
+
+    ///Start a new level.
+    ///It shouldn't be used before the items on level 0 are listed.
+    void initNewLevel() {
+      ++_init_level;
+    }
+
+    ///Finalize the initialization process.
+
+    void initFinish() {
+      _highest_active = -1;
+    }
+
+    ///@}
+
+  };
+
+
+} //END OF NAMESPACE LEMON
+
+#endif
+
Index: lemon/eps.cc
===================================================================
--- lemon/eps.cc	(revision 2553)
+++ lemon/eps.cc	(revision 2553)
@@ -0,0 +1,381 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/eps.h>
+
+namespace lemon {
+  
+  void EpsDrawer::defMacros()
+  {
+    out << "/clmode true def\n" <<
+      "/cshowmode false def\n" <<
+      "/defont (Helvetica) findfont def\n" <<
+      "/fosi 12 def\n" <<
+      "\n" <<
+      "/st { clmode { currentpoint stroke newpath moveto } if } bind def\n" <<
+      "/str { currentpoint stroke newpath moveto /clmode true def } bind def\n"
+	<<
+      "/fl { currentpoint fill newpath moveto /clmode true def } bind def\n" <<
+      "/eofl { currentpoint eofill newpath moveto /clmode true def } bind def\n"
+	<<
+      "/cl { currentpoint clip newpath moveto /clmode true def } bind def\n"
+	<<
+      "/eocl { currentpoint eoclip newpath moveto /clmode true def } bind def\n"
+	<<
+      "\n" <<
+      "/l { moveto lineto st } bind def\n" <<
+      "/lt { lineto st } bind def\n" <<
+      "/mt { moveto } bind def\n" <<
+      "/c { dup 3 index add 2 index moveto 0 360 arc st } bind def\n" <<
+      "/collect { /clmode false def currentpoint newpath moveto } bind def\n" <<
+      "\n" <<
+      "/fontset { defont fosi scalefont setfont } bind def\n" <<
+      "/stfs { /fosi exch def fontset } bind def\n" <<
+      "/cshow { dup stringwidth pop\n" <<
+      "   neg 2 div 0 rmoveto show } bind def\n" <<
+      "/xshow { cshowmode { cshow } { show } ifelse } def\n" <<
+      "\n" <<
+      "fontset\n" <<
+      "newpath\n" <<
+      "0 0 moveto\n" <<
+      "1 setlinecap\n";
+  }
+
+  void EpsDrawer::init(int x1,int y1,int x2,int y2)
+  {
+    out << "%!PS-Adobe-2.0 EPSF-2.0\n" <<
+      "%%BoundingBox: " << x1 << ' ' << y1 << ' ' << x2 << ' ' << y2 <<
+      "\n%%EndComments\n";
+    defMacros();
+  }
+
+  void EpsDrawer::init(double x1,double y1,double x2,double y2)
+  {
+    out << "%!PS-Adobe-2.0\n" <<
+      "%%HiResBoundingBox: " << 
+      x1 << ' ' << y1 << ' ' << x2 << ' ' << y2 <<
+      "\n%%EndComments\n";
+    defMacros();
+  }
+
+
+  EpsDrawer::EpsDrawer(std::ostream &os,int x,int y) : local_stream(false),
+						       out(os)
+  {
+    init(0,0,x,y);
+  }
+
+  EpsDrawer::EpsDrawer(std::ostream &os,int x1,int y1,int x2,int y2) : 
+    local_stream(false),
+    out(os)
+  {
+    init(x1,y1,x2,y2);
+  }
+
+  EpsDrawer::EpsDrawer(std::ostream &os,dim2::Point<double> s) : local_stream(false),
+							out(os)
+  {
+    init(0.0,0.0,s.x,s.y);
+  }
+
+  EpsDrawer::EpsDrawer(std::ostream &os,dim2::Point<double> a, dim2::Point<double> b) :
+    local_stream(false),
+    out(os)
+  {
+    init(a.x,a.y,b.x,b.y);
+  }
+
+
+  EpsDrawer::EpsDrawer(const std::string &name,int x,int y) :
+    local_stream(true),
+    out(*new std::ofstream(name.c_str()))
+  {
+    init(0,0,x,y);
+  }
+
+  EpsDrawer::EpsDrawer(const std::string &name,int x1,int y1,int x2,int y2) : 
+    local_stream(true),
+    out(*new std::ofstream(name.c_str()))
+  {
+    init(x1,y1,x2,y2);
+  }
+  
+  EpsDrawer::EpsDrawer(const std::string &name,dim2::Point<double> s) :
+    local_stream(true),
+    out(*new std::ofstream(name.c_str()))
+  {
+    init(0.0,0.0,s.x,s.y);
+  }
+
+  EpsDrawer::EpsDrawer(const std::string &name,dim2::Point<double> a, dim2::Point<double> b) :
+    local_stream(true),
+    out(*new std::ofstream(name.c_str()))
+  {
+    init(a.x,a.y,b.x,b.y);
+  }
+
+
+  EpsDrawer::~EpsDrawer()
+  {
+    out << "showpage\n";
+    if(local_stream) delete &out;
+  }
+
+  EpsDrawer &EpsDrawer::save()
+  {
+    out << "gsave\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::restore()
+  {
+    out << "grestore\n";
+    return *this;  
+  }
+ 
+  EpsDrawer &EpsDrawer::line(double x1,double y1,double x2,double y2)
+  {
+    out << x1 << ' ' << y1 << ' ' << x2 << ' ' << y2 << " l\n";
+    return *this;
+  
+  }
+
+  EpsDrawer &EpsDrawer::lineTo(double x1,double y1)
+  {
+    out << x1 << ' ' << y1 << " lt\n";
+    return *this;
+  
+  }
+
+  EpsDrawer &EpsDrawer::moveTo(double x1,double y1)
+  {
+    out << x1 << ' ' << y1 << " mt\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::circle(double x,double y, double r)
+  {
+    out << x << ' ' << y << ' ' << r << " c\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::operator<<(const std::string &s)
+  {
+    out << "(" << s <<") xshow\n";
+    return *this;
+  }
+
+  EpsDrawer &EpsDrawer::operator<<(const char *s)
+  {
+    out << "(" << s <<") xshow\n";
+    return *this;
+  }
+
+  EpsDrawer &EpsDrawer::operator<<(int i)
+  {
+    out << "(" << i <<") xshow\n";
+    return *this;
+  }
+
+  EpsDrawer &EpsDrawer::operator<<(double d)
+  {
+    out << "(" << d <<") xshow\n";
+    return *this;
+  }
+
+  EpsDrawer &EpsDrawer::fontSize(double si)
+  {
+    out << si << " stfs\n";
+    return *this;
+  }
+  EpsDrawer &EpsDrawer::font(std::string s)
+  {
+    out << "/defont ("<<s<<") findfont def fontset\n";
+    return *this;
+  }
+
+
+  EpsDrawer &EpsDrawer::collect()
+  {
+    out << "collect\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::closePath()
+  {
+    out << "closepath\n";
+    return *this;
+  }
+
+  EpsDrawer &EpsDrawer::stroke()
+  {
+    out << "str\n";
+    return *this;  
+  }
+  EpsDrawer &EpsDrawer::fill()
+  {
+    out << "fl\n";
+    return *this;  
+  }
+  EpsDrawer &EpsDrawer::eoFill()
+  {
+    out << "eofl\n";
+    return *this;  
+  }
+  EpsDrawer &EpsDrawer::clip()
+  {
+    out << "cl\n";
+    return *this;  
+  }
+  EpsDrawer &EpsDrawer::eoClip()
+  {
+    out << "eocl\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::lineWidth(double w)
+  {
+    out << w << " setlinewidth\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::lineCap(int i)
+  {
+    out << i << " setlinecap\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::lineJoin(int i)
+  {
+    out << i << " setlinejoin\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::miterLimit(double w)
+  {
+    out << w << " setmiterlimit\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::color(double r, double g, double b)
+  {
+    out << r << ' ' << g << ' ' << b << " setrgbcolor\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::translate(double x,double y)
+  {
+    out << x << ' ' << y << " translate\n";
+    return *this;  
+  }
+
+  EpsDrawer &EpsDrawer::rotate(double r)
+  {
+    out << r << " rotate\n";
+    return *this;  
+  }
+  EpsDrawer &EpsDrawer::scale(double sx, double sy)
+  {
+    out << sx << ' ' << sy << " scale\n";
+    return *this;  
+  }
+  
+  EpsDrawer &EpsDrawer::clear()
+  {
+    out << "erasepage\n";
+    return *this;  
+  }
+  
+  EpsDrawer &EpsDrawer::centerMode(bool m)
+  {
+    if(m) out << "/cshowmode true def\n";
+    else out << "/cshowmode false def\n";
+
+    return *this;  
+  }
+  
+  EpsDrawer &EpsDrawer::flush()
+  {
+    out << "flush\n";
+    //  fflush(fp);
+    return *this;
+  }
+
+  EpsDrawer &EpsDrawer::node(NodeShapes t, double x, double y, double r,
+			     Color col, Color brd)
+  {
+    out << "gsave\n"
+	<< brd.red() << ' ' << brd.green() << ' ' << brd.blue() 
+	<< " setrgbcolor\n";
+    switch(t) {
+    case CIRCLE:
+      out << "newpath " << x << ' ' << y << ' ' << r 
+	  << " dup 3 index add 2 index moveto 0 360 arc fill\n";
+      break;
+    case SQUARE:
+      out << "newpath\n"
+	  << x-r << ' ' << y-r << " moveto\n"
+	  << x-r << ' ' << y+r << " lineto\n"
+	  << x+r << ' ' << y+r << " lineto\n"
+	  << x+r << ' ' << y-r << " lineto closepath fill\n";
+      break;
+    case DIAMOND:
+      out << "newpath\n"
+	  << x-r << ' ' << y   << " moveto\n"
+	  << x   << ' ' << y+r << " lineto\n"
+	  << x+r << ' ' << y   << " lineto\n"
+	  << x   << ' ' << y-r << " lineto closepath fill\n";
+      break;
+    case MALE:
+      break;
+    case FEMALE:
+      break;
+    }
+    r/=1.1;
+    out << col.red() << ' ' << col.green() << ' ' << col.blue() 
+	<< " setrgbcolor\n";
+    switch(t) {
+    case CIRCLE:
+      out << "newpath " << x << ' ' << y << ' ' << r 
+	  << " dup 3 index add 2 index moveto 0 360 arc fill\n";
+      break;
+    case SQUARE:
+      out << "newpath\n"
+	  << x-r << ' ' << y-r << " moveto\n"
+	  << x-r << ' ' << y+r << " lineto\n"
+	  << x+r << ' ' << y+r << " lineto\n"
+	  << x+r << ' ' << y-r << " lineto closepath fill\n";
+      break;
+    case DIAMOND:
+      out << "newpath\n"
+	  << x-r << ' ' << y   << " moveto\n"
+	  << x   << ' ' << y+r << " lineto\n"
+	  << x+r << ' ' << y   << " lineto\n"
+	  << x   << ' ' << y-r << " lineto closepath fill\n";
+      break;
+    case MALE:
+      break;
+    case FEMALE:
+      break;
+    }
+
+    out << "grestore\n";
+    return *this;
+  }
+  
+}
Index: lemon/eps.h
===================================================================
--- lemon/eps.h	(revision 2553)
+++ lemon/eps.h	(revision 2553)
@@ -0,0 +1,351 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_EPS_H
+#define LEMON_EPS_H
+
+#include<string>
+#include<iostream>
+#include<fstream>
+#include<sstream>
+#include<lemon/color.h>
+#include<lemon/dim2.h>
+
+  ///\ingroup eps_io
+  ///\file
+  ///\brief Simple tool to create \c .eps files
+  ///
+  ///\author Alpar Juttner
+
+namespace lemon {
+  
+  ///\ingroup eps_io
+  ///\brief A simple tool to create \c .eps files
+  ///
+  ///A simple tool to create \c .eps files
+  ///\author Alpar Juttner
+  class EpsDrawer
+  {
+    void defMacros();
+    void init(int x1,int y1,int x2,int y2);
+    void init(double x1,double y1,double x2,double y2);
+    bool local_stream;
+  public:
+    
+    std::ostream &out;
+    
+    ///Node shapes
+    ///
+    enum NodeShapes { 
+      /// = 0
+      ///\image html nodeshape_0.png
+      ///\image latex nodeshape_0.eps "CIRCLE shape (0)" width=2cm
+      CIRCLE=0, 
+      /// = 1
+      ///\image html nodeshape_1.png
+      ///\image latex nodeshape_1.eps "SQUARE shape (1)" width=2cm
+      ///
+      SQUARE=1, 
+      /// = 2
+      ///\image html nodeshape_2.png
+      ///\image latex nodeshape_2.eps "DIAMOND shape (2)" width=2cm
+      ///
+      DIAMOND=2,
+      /// = 3
+      ///\image html nodeshape_3.png
+      ///\image latex nodeshape_2.eps "MALE shape (4)" width=2cm
+      ///
+      ///\warning Not implemented
+      MALE=3,
+      /// = 4
+      ///\image html nodeshape_4.png
+      ///\image latex nodeshape_2.eps "FEMALE shape (4)" width=2cm
+      ///
+      ///\warning Not implemented
+      FEMALE=4
+    };
+    ///\e 
+
+    ///The generated file is put to \c os.
+    ///
+    /// \c x and \c y determine the upper
+    ///right corner of the bounding box. The lower left corner is (0,0).
+    EpsDrawer(std::ostream &os,int x,int y);
+    ///\e
+
+    ///The generated file is put to \c os.
+    ///
+    ///(x1,y1) and (x2,y2)
+    /// determine the lower left and the upper right corners of
+    ///the bounding box, respectively.
+    EpsDrawer(std::ostream &os,int x1,int y1,int x2,int y2);
+    ///\e
+
+    ///The generated file is put to \c os.
+    ///
+    ///\c s determines the upper
+    ///right corner of the bounding box. The lower left corner is (0,0).
+    EpsDrawer(std::ostream &os,dim2::Point<double> s);
+    ///\e
+
+    ///The generated file is put to \c os.
+    ///
+    ///\c a and \c b
+    /// determine the lower left and the upper right corners of
+    ///the bounding box, respectively.
+    EpsDrawer(std::ostream &os,dim2::Point<double> a, dim2::Point<double> b);
+    ///\e
+
+    ///The generated picture is put to the file \c name.
+    ///
+    ///\c x and \c y determine the upper
+    ///right corner of the bounding box. The lower left corner is (0,0).
+    EpsDrawer(const std::string &name,int x,int y);
+    ///\e
+
+    ///The generated picture is put to the file \c name.
+    ///
+    ///(x1,y1) and (x2,y2)
+    /// determine the lower left and the upper right corners of
+    ///the bounding box, respectively.
+    EpsDrawer(const std::string &name,int x1,int y1,int x2,int y2);
+    ///\e
+
+    ///The generated picture is put to the file \c name.
+    ///
+    ///\c s determines the upper
+    ///right corner of the bounding box. The lower left corner is (0,0).
+    EpsDrawer(const std::string &name,dim2::Point<double> s);
+    ///\e
+
+    ///The generated picture is put to the file \c name.
+    ///
+    ///\c a and \c b
+    /// determine the lower left and the upper right corners of
+    ///the bounding box, respectively.
+    EpsDrawer(const std::string &name,dim2::Point<double> a, dim2::Point<double> b);
+
+//     template<class T> EpsDrawer(std::ostream &os,BoundingBox<T> b) 
+//     template<class T> EpsDrawer(std::ostream &os,BoundingBox<T> b);
+    
+    ~EpsDrawer();
+    
+    ///Save the current graphic state.
+
+    ///This function saves the current coordinate system, and the parameters
+    ///set by \ref color(), \ref lineWidth() etc.
+    ///The can be \ref restore "restore()"d later.
+    ///
+    ///The \ref save() - \ref restore() pairs can be nested.
+    ///
+    EpsDrawer &save();
+    ///Restore the saves graphic state.
+
+    EpsDrawer &restore();
+    
+    ///Draw a line
+    EpsDrawer &line(double x1,double y1,double x2,double y2);
+    ///Draw a line from the current point
+    EpsDrawer &lineTo(double x1,double y1);
+    ///Move the current point
+    EpsDrawer &moveTo(double x1,double y1);
+    ///Draw a circle
+    EpsDrawer &circle(double x,double y, double r);
+    
+    ///Draw a line
+    template<class T> EpsDrawer &line(dim2::Point<T> p1,dim2::Point<T> p2) 
+    {
+      return line(p1.x,p1.y,p2.x,p2.y);
+    }
+    ///Draw a line from the current point
+    template<class T> EpsDrawer &lineTo(dim2::Point<T> p)
+    {
+      return lineTo(p.x,p.y);
+    }
+    ///Move the current point
+    template<class T> EpsDrawer &moveTo(dim2::Point<T> p)
+    {
+      return moveTo(p.x,p.y);
+    }
+    ///Draw a circle
+    template<class T> EpsDrawer &circle(dim2::Point<T> p, double r)
+    {
+      return circle(p.x,p.y,r);
+    }
+    
+    ///Set the font size
+    EpsDrawer &fontSize(double si);
+    ///Set the fint type
+    EpsDrawer &font(std::string );
+    ///Sets whether text output is centerized of not
+
+    ///Sets whether text output is centerized of not.
+    ///
+    ///\warning \ref save() doesn't save this setting.
+    ///
+    EpsDrawer &centerMode(bool m);
+    ///Turn to collect mode.
+
+    ///If you call this function, then the drawing operations like \ref line(),
+    ///\ref lineTo(), \ref moveTo() will not take place immediately, but istead
+    ///they
+    ///are collected. These operations form a \e path.
+    ///Then you can \ref stroke(), \ref fill(), \ref eoFill(), \ref clip() or
+    ///\ref eoClip() it.
+    ///When drawing, you can also use \ref closePath() to - surprise - close the
+    ///current path.
+    ///
+    ///This example draws a red filled diamond.
+    ///\code
+    ///  EpsDraw ed("diamond.eps",-1,-1,1,1);
+    ///  ed.color(1,0,0,).collect().line(0,-1,1,0).lineTo(0,1)
+    ///    .lineTo(-1,0).closePath().fill();
+    ///\endcode
+    EpsDrawer &collect();
+    ///Close the current drawing path
+    EpsDrawer &closePath();
+    ///Stroke (draw) a path
+
+    ///Stroke (draw) a path.
+    ///\sa collect()
+    ///
+    EpsDrawer &stroke();
+    ///Fill a path
+
+    ///Fill a path.
+    ///\sa collect()
+    ///
+    EpsDrawer &fill();
+    ///Even-odd fill a path
+
+    ///Even-odd fill a path.
+    ///\sa collect()
+    ///
+    EpsDrawer &eoFill();
+    ///Set a clipping area.
+
+    ///This function sets a clipping area. After that, the drawing operations
+    ///will affect only this area.
+    ///\sa collect()
+    ///
+    EpsDrawer &clip();
+    ///Set a clipping area using even-odd rule.
+
+    ///This function sets a clipping area using even-odd rule.
+    ///After that, the drawing operations
+    ///will affect only this area.
+    ///\sa collect()
+    ///
+    EpsDrawer &eoClip();
+    
+    ///Set the line width.
+    EpsDrawer &lineWidth(double w);
+    ///Set the style of the line ends
+
+    ///\param i It can be 0, 1 or 2
+    ///
+    EpsDrawer &lineCap(int i);
+    ///Set the style of the line joins
+
+    ///\param i It can be 0, 1 or 2
+    ///
+    EpsDrawer &lineJoin(int i);
+    ///Set the cut length of near parallel joining lines.
+    EpsDrawer &miterLimit(double w);
+    
+    ///Set the drawing color
+    EpsDrawer &color(double r, double g, double b);
+    ///Set the drawing color
+    EpsDrawer &color(Color c)
+    {
+      return color(c.red(),c.green(),c.blue());
+    }
+    
+    ///Draw a node shape
+
+    ///Draw a node shape.
+    ///
+    ///\param t The shape of the drawn object
+    ///\param x The \c x coordinate of the node
+    ///\param y The \c y coordinate of the node
+    ///\param r The size (radius) of the node
+    ///\param col Color of the node. The default color is white
+    ///\param brd Color of the node border. The default color is black
+    EpsDrawer &node(NodeShapes t, double x, double y, double r,
+		    Color col=WHITE, Color brd=BLACK);
+    ///Draw a node shape
+    
+    ///Draw a node shape.
+    ///
+    ///\param t The shape of the drawn object
+    ///\param pos Position of the node
+    ///\param r The size (radius) of the node
+    ///\param col Color of the node. The default color is white
+    ///\param brd Color of the node border. The default color is black
+    template<class T>
+    EpsDrawer &node(NodeShapes t, dim2::Point<T> pos, double r,
+		    Color col=WHITE, Color brd=BLACK)
+    {
+      return node(t,pos.x,pos.y,r,col,brd);
+    }
+
+    ///Translate the coordinate system
+    EpsDrawer &translate(double x,double y);
+    ///Translate the coordinate system
+    template<class T> EpsDrawer &translate(dim2::Point<T> p)
+    {
+      return translate(p.x,p.y);
+    }
+    ///Rotate the coordinate system
+    EpsDrawer &rotate(double r);
+    ///Scale the coordinate system
+    EpsDrawer &scale(double sx, double sy);
+    ///Scale the coordinate system
+    EpsDrawer &scale(double s) { return scale(s,s); }
+    ///Scale the coordinate system
+    template<class T> EpsDrawer &scale(dim2::Point<T> p)
+    {
+      return scale(p.x,p.y);
+    }
+    
+    ///\e
+    EpsDrawer &flush();
+    ///Clear the image
+    EpsDrawer &clear();
+    
+    ///Print a text at the current point
+    EpsDrawer &operator<<(const std::string &s);
+    ///Print a text at the current point
+    EpsDrawer &operator<<(const char *s);
+    ///Print a number at the current point
+    EpsDrawer &operator<<(int i);
+    ///Print a number at the current point
+    EpsDrawer &operator<<(double d);
+    ///Print a coordinate at the current point
+    template<class T>
+    EpsDrawer &operator<<(dim2::Point<T> p) 
+    {
+      out << "((" << p.x << ',' << p.y <<")) show\n";
+      return *this;
+    }
+    
+  };
+  
+}
+
+#endif
Index: lemon/error.h
===================================================================
--- lemon/error.h	(revision 2553)
+++ lemon/error.h	(revision 2553)
@@ -0,0 +1,683 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_ERROR_H
+#define LEMON_ERROR_H
+
+//! \ingroup exceptions
+//! \file
+//! \brief Basic exception classes and error handling.
+
+#include <exception>
+#include <string>
+#include <sstream>
+#include <iostream>
+#include <cstdlib>
+#include <memory>
+
+namespace lemon {
+
+  /// \addtogroup exceptions
+  /// @{
+  
+  /// \brief Exception safe wrapper class.
+  ///
+  /// Exception safe wrapper class to implement the members of exceptions.
+  template <typename _Type>
+  class ExceptionMember {
+  public:
+    typedef _Type Type;
+
+    ExceptionMember() throw () {
+      try {
+	ptr.reset(new Type());
+      } catch (...) {}
+    }
+
+    ExceptionMember(const Type& type) throw () {
+      try {
+	ptr.reset(new Type());
+	if (ptr.get() == 0) return;
+	*ptr = type;
+      } catch (...) {}
+    }
+
+    ExceptionMember(const ExceptionMember& copy) throw() {
+      try {
+	if (!copy.valid()) return;
+	ptr.reset(new Type());
+	if (ptr.get() == 0) return;
+	*ptr = copy.get();
+      } catch (...) {}
+    }
+
+    ExceptionMember& operator=(const ExceptionMember& copy) {
+      if (ptr.get() == 0) return;
+      try {
+	if (!copy.valid()) return;
+ 	*ptr = copy.get();
+      } catch (...) {}
+    }
+
+    void set(const Type& type) {
+      if (ptr.get() == 0) return;
+      try {
+	*ptr = type;
+      } catch (...) {}
+    }
+
+    const Type& get() const {
+      return *ptr;
+    }
+
+    bool valid() const {
+      return ptr.get() != 0;
+    }
+    
+  private:
+    std::auto_ptr<_Type> ptr;
+  };
+
+  /// Exception-safe convenient "error message" class.
+
+  /// Helper class which provides a convenient ostream-like (operator <<
+  /// based) interface to create a string message. Mostly useful in
+  /// exception classes (therefore the name).
+  class ErrorMessage {
+  protected:
+    ///\e 
+
+    ///\todo The good solution is boost::shared_ptr...
+    ///
+    mutable
+    std::auto_ptr<std::ostringstream> buf;
+    
+    ///\e 
+    bool init() throw() {
+      try {
+	buf.reset(new std::ostringstream);
+      }
+      catch(...) {
+	buf.reset();
+      }
+      return buf.get();
+    }
+
+  public:
+
+    ///\e 
+    ErrorMessage() throw() { init(); }
+
+    ErrorMessage(const ErrorMessage& em) throw() : buf(em.buf) { }
+
+    ///\e 
+    ErrorMessage(const char *msg) throw() {
+      init();
+      *this << msg;
+    }
+
+    ///\e 
+    ErrorMessage(const std::string &msg) throw() {
+      init();
+      *this << msg;
+    }
+
+    ///\e 
+    template <typename T>
+    ErrorMessage& operator<<(const T &t) throw() {
+      if( ! buf.get() ) return *this;
+
+      try {
+	*buf << t;
+      }
+      catch(...) {
+	buf.reset();
+      }
+      return *this;
+    }
+
+    ///\e 
+    const char* message() throw() {
+      if( ! buf.get() ) return 0;
+
+      const char* mes = 0;
+      try {
+	mes = buf->str().c_str();
+      }
+      catch(...) {}
+      return mes;
+    }
+    
+  };
+
+  /**
+   * \brief Generic exception class.
+   *
+   * Base class for exceptions used in LEMON.
+   */
+  class Exception : public std::exception {
+  public:
+    ///\e 
+    Exception() {}
+    ///\e 
+    virtual ~Exception() throw() {}
+    ///\e 
+    virtual const char* what() const throw() {
+      return "lemon::Exception";
+    }
+  };
+
+  /**
+   * \brief One of the two main subclasses of \ref Exception.
+   *
+   * Logic errors represent problems in the internal logic of a program;
+   * in theory, these are preventable, and even detectable before the
+   * program runs (e.g., violations of class invariants).
+   *
+   * A typical example for this is \ref UninitializedParameter.
+   */
+  class LogicError : public Exception {
+  public:
+    virtual const char* what() const throw() {
+      return "lemon::LogicError";
+    }
+  };
+
+  /**
+   * \brief \ref Exception for uninitialized parameters.
+   *
+   * This error represents problems in the initialization
+   * of the parameters of the algorithms.
+   */
+  class UninitializedParameter : public LogicError {
+  public:
+    virtual const char* what() const throw() {
+      return "lemon::UninitializedParameter";
+    }
+  };
+
+  
+  /**
+   * \brief One of the two main subclasses of \ref Exception.
+   *
+   * Runtime errors represent problems outside the scope of a program;
+   * they cannot be easily predicted and can generally only be caught as
+   * the program executes.
+   */
+  class RuntimeError : public Exception {
+  public:
+    virtual const char* what() const throw() {
+      return "lemon::RuntimeError";
+    }
+  };
+
+  ///\e
+  class RangeError : public RuntimeError {
+  public:
+    virtual const char* what() const throw() {
+      return "lemon::RangeError";
+    }
+  };
+
+  ///\e 
+  class IoError : public RuntimeError {
+  public:
+    virtual const char* what() const throw() {
+      return "lemon::IoError";
+    }
+  };
+
+  ///\e 
+  class DataFormatError : public IoError {
+  protected:
+    ExceptionMember<std::string> _message;
+    ExceptionMember<std::string> _file;
+    int _line;
+
+    mutable ExceptionMember<std::string> _message_holder;
+  public:
+
+    DataFormatError(const DataFormatError &dfe) : 
+      IoError(dfe), _message(dfe._message), _file(dfe._file),
+      _line(dfe._line) {}
+
+    ///\e 
+    explicit DataFormatError(const char *the_message)
+      : _message(the_message), _line(0) {}
+
+    ///\e 
+    DataFormatError(const std::string &file_name, int line_num,
+		    const char *the_message)
+      : _message(the_message), _line(line_num) { file(file_name); }
+
+    ///\e 
+    void line(int ln) { _line = ln; }
+    ///\e 
+    void message(const std::string& msg) { _message.set(msg); }
+    ///\e 
+    void file(const std::string &fl) { _file.set(fl); }
+ 
+    ///\e
+    int line() const { return _line; }
+    ///\e
+    const char* message() const { 
+      if (_message.valid() && !_message.get().empty()) {
+	return _message.get().c_str();
+      } else {
+	return 0;
+      }
+    }
+
+    /// \brief Returns the filename.
+    ///
+    /// Returns \e null if the filename was not specified.
+    const char* file() const {
+      if (_file.valid() && !_file.get().empty()) {
+	return _file.get().c_str();
+      } else {
+	return 0;
+      }
+    }
+
+    ///\e 
+    virtual const char* what() const throw() {
+      try {
+	std::ostringstream ostr;
+	ostr << "lemon:DataFormatError" << ": ";
+	if (message()) ostr << message();
+	if( file() || line() != 0 ) {
+	  ostr << " (";
+	  if( file() ) ostr << "in file '" << file() << "'";
+	  if( file() && line() != 0 ) ostr << " ";
+	  if( line() != 0 ) ostr << "at line " << line();
+	  ostr << ")";
+	}
+	_message_holder.set(ostr.str());
+      }
+      catch (...) {}
+      if( _message_holder.valid()) return _message_holder.get().c_str();
+      return "lemon:DataFormatError";
+    }
+
+    virtual ~DataFormatError() throw() {}
+  };
+
+  ///\e 
+  class FileOpenError : public IoError {
+  protected:
+    ExceptionMember<std::string> _file;
+
+    mutable ExceptionMember<std::string> _message_holder;
+  public:
+
+    FileOpenError(const FileOpenError &foe) : 
+      IoError(foe), _file(foe._file) {}
+
+    ///\e 
+    explicit FileOpenError(const std::string& fl)
+      : _file(fl) {}
+
+
+    ///\e 
+    void file(const std::string &fl) { _file.set(fl); }
+ 
+    /// \brief Returns the filename.
+    ///
+    /// Returns \e null if the filename was not specified.
+    const char* file() const {
+      if (_file.valid() && !_file.get().empty()) {
+	return _file.get().c_str();
+      } else {
+	return 0;
+      }
+    }
+
+    ///\e 
+    virtual const char* what() const throw() {
+      try {
+	std::ostringstream ostr;
+	ostr << "lemon::FileOpenError" << ": ";
+	ostr << "Cannot open file - " << file();
+	_message_holder.set(ostr.str());
+      }
+      catch (...) {}
+      if( _message_holder.valid()) return _message_holder.get().c_str();
+      return "lemon::FileOpenError";
+    }
+    virtual ~FileOpenError() throw() {}
+  };
+
+  class IoParameterError : public IoError {
+  protected:
+    ExceptionMember<std::string> _message;
+    ExceptionMember<std::string> _file;
+
+    mutable ExceptionMember<std::string> _message_holder;
+  public:
+
+    IoParameterError(const IoParameterError &ile) : 
+      IoError(ile), _message(ile._message), _file(ile._file) {}
+
+    ///\e 
+    explicit IoParameterError(const char *the_message)
+      : _message(the_message) {}
+
+    ///\e 
+    IoParameterError(const char *file_name, const char *the_message)
+      : _message(the_message), _file(file_name) {}
+
+     ///\e 
+    void message(const std::string& msg) { _message.set(msg); }
+    ///\e 
+    void file(const std::string &fl) { _file.set(fl); }
+ 
+     ///\e
+    const char* message() const { 
+      if (_message.valid()) {
+	return _message.get().c_str();
+      } else {
+	return 0;
+      }
+    }
+
+    /// \brief Returns the filename.
+    ///
+    /// Returns \e null if the filename was not specified.
+    const char* file() const {
+      if (_file.valid()) {
+	return _file.get().c_str();
+      } else {
+	return 0;
+      }
+    }
+
+    ///\e 
+    virtual const char* what() const throw() {
+      try {
+	std::ostringstream ostr;
+	if (message()) ostr << message();
+	if (file()) ostr << "(when reading file '" << file() << "')";
+	_message_holder.set(ostr.str());
+      }
+      catch (...) {}
+      if( _message_holder.valid() ) return _message_holder.get().c_str();
+      return "lemon:IoParameterError";
+    }
+    virtual ~IoParameterError() throw() {}
+  };
+
+
+  ///\e
+  class AssertionFailedError : public LogicError {
+  protected:
+    const char *assertion;
+    const char *file;
+    int line;
+    const char *function;
+    const char *message;
+
+    mutable ExceptionMember<std::string> _message_holder;
+  public:
+    ///\e
+    AssertionFailedError(const char *_file, int _line, const char *func,
+			 const char *msg, const char *_assertion = 0) :
+      assertion(_assertion), file(_file), line(_line), function(func),
+      message(msg) {}
+
+    ///\e
+    const char* get_assertion() const { return assertion; }
+    ///\e
+    const char* get_message() const { return message; }
+    ///\e
+    const char* get_file() const { return file; }
+    ///\e
+    const char* get_function() const { return function; }
+    ///\e
+    int get_line() const { return line; }
+
+
+    virtual const char* what() const throw() {
+      try {
+	std::ostringstream ostr;
+	ostr << file << ":" << line << ": ";
+	if( function )
+	  ostr << function << ": ";
+	ostr << message;
+	if( assertion )
+	   ostr << " (assertion '" << assertion << "' failed)";
+	_message_holder.set(ostr.str());
+	return ostr.str().c_str();
+      }
+      catch(...) {}
+      if( _message_holder.valid() ) return _message_holder.get().c_str();
+      return "lemon::AssertionFailedError";
+    }
+   virtual ~AssertionFailedError() throw() {}
+  };
+
+
+  /****************  Macros  ****************/
+
+
+  template <typename Exception>
+  inline void assert_fail(const char *file, int line, 
+                          const char *func,
+                          Exception exception, 
+                          const char *assertion = 0,
+                          bool do_abort=true)
+  {
+    using namespace std;
+    cerr << file << ":" << line << ": ";
+    if( func )
+      cerr << func << ": ";
+    cerr << exception.what();
+    if( assertion )
+      cerr << " (assertion '" << assertion << "' failed)";
+    cerr << endl;
+    if(do_abort)
+      abort();
+  }
+
+  template <>
+  inline void assert_fail<const char *>(const char *file, int line, 
+                                        const char *func,
+                                        const char *message, 
+                                        const char *assertion,
+                                        bool do_abort)
+  {
+    using namespace std;
+    cerr << file << ":" << line << ": ";
+    if( func )
+      cerr << func << ": ";
+    cerr << message;
+    if( assertion )
+      cerr << " (assertion '" << assertion << "' failed)";
+    cerr << endl;
+    if(do_abort)
+      abort();
+  }
+
+  template <>
+  inline void assert_fail<std::string>(const char *file, int line, 
+                                       const char *func,
+                                       std::string message, 
+                                       const char *assertion,
+                                       bool do_abort)
+  {
+    assert_fail(file, line, func, message.c_str(), assertion, do_abort);
+  }
+
+  template <typename Exception>
+  inline void assert_fail_failure(const char *file, int line, const char *func,
+			   Exception exception, 
+			   const char *assertion = 0,
+			   bool = true)
+  {
+    throw AssertionFailedError(file, line, func, exception.what(), assertion);
+  }
+
+  template <>
+  inline void assert_fail_failure<const char *>(const char *file, int line, 
+                                                const char *func,
+                                                const char *message, 
+                                                const char *assertion,
+                                                bool)
+  {
+    throw AssertionFailedError(file, line, func, message, assertion);
+  }
+
+  template <>
+  inline void assert_fail_failure<std::string>(const char *file, int line, 
+                                               const char *func,
+                                               std::string message, 
+                                               const char *assertion,
+                                               bool)
+  {
+    assert_fail_failure(file, line, func, message.c_str(), assertion, true);
+  }
+
+  template <typename Exception> 
+  inline void assert_fail_exception(const char *file, int line, const char *func,
+			     Exception exception, 
+			     const char *assertion = 0, bool = true)
+  {
+    throw exception;
+  }
+
+  template <> 
+  inline void assert_fail_exception<const char *>(const char *file, int line, 
+					   const char *func,
+					   const char *message, 
+					   const char *assertion,
+					   bool)
+  {
+    throw AssertionFailedError(file, line, func, message, assertion);
+  }
+
+  template <>
+  inline void assert_fail_exception<std::string>(const char *file, int line, 
+                                                 const char *func,
+                                                 std::string message, 
+                                                 const char *assertion,
+                                                 bool)
+  {
+    assert_fail_exception(file, line, func, message.c_str(), assertion, true);    
+  }
+
+/// @}
+
+}
+#endif // LEMON_ERROR_H
+
+#undef LEMON_ASSERT
+#undef LEMON_FIXME
+
+#ifdef LEMON_ENABLE_ASSERTS
+#  define LEMON_ASSERT_ABORT
+#endif
+
+#ifndef LEMON_ASSERT_DO_ABORT
+#  define LEMON_ASSERT_DO_ABORT 1
+#endif
+
+#ifndef LEMON_ASSERT_HANDLER
+#  if defined LEMON_ASSERT_EXCEPTION
+#    define LEMON_ASSERT_HANDLER ::lemon::assert_fail_exception
+#  elif defined LEMON_ASSERT_FAILURE
+#    define LEMON_ASSERT_HANDLER ::lemon::assert_fail_failure
+#  elif defined LEMON_ASSERT_ABORT
+#    define LEMON_ASSERT_HANDLER ::lemon::assert_fail
+#  else
+#    define LEMON_DISABLE_ASSERTS
+#  endif
+#endif
+
+#ifdef DOXYGEN
+
+/// \brief Macro for assertions with customizable message
+///
+/// Macro for assertions with customizable message.
+///
+/// The assertions are disabled in the default behaviour. You can
+/// enable the assertions with the
+/// \code
+/// #define LEMON_ENABLE_ASSERTS
+/// \endcode
+/// Then an assert
+/// provides a log on the standard error about the assertion and aborts
+/// the program if LEMON_ASSERT_DO_ABORT is also defined (otherwise the
+/// program keeps on running).
+/// By defining LEMON_ASSERT_FAILURE or
+/// LEMON_ASSERT_EXCEPTION, you can set other behaviour to the
+/// assertions. In case LEMON_ASSERT_FAILURE is given, LEMON_ASSERT
+/// will always throw an \c AssertionFailedError exception with
+/// the \c msg error message. By using
+/// LEMON_ASSERT_EXCEPTION, one can define an arbitrary exception to be thrown.
+///
+/// The LEMON_ASSERT macro should be called with the \c exp parameter
+/// which should be an expression convertible to bool. If the given
+/// parameter is false the assertion is raised and one of the assertion
+/// behaviour will be activated. The \c msg should be either a const
+/// char* message or an exception. When the \c msg is an exception the
+/// \ref lemon::Exception::what() "what()" function is called to retrieve and
+/// display the error message.
+///
+/// \todo We should provide some way to reset to the default behaviour,
+/// shouldn't we?
+///
+/// \todo This whole 'assert' business should be placed in a separate
+/// include file. The boost assert is not guarded by header sentries
+/// which may help to change the behaviour of the assertions in 
+/// the files.
+///
+/// \todo __PRETTY_FUNCTION__ should be replaced by something
+/// compiler-independent, like BOOST_CURRENT_FUNCTION
+
+#  define LEMON_ASSERT(exp, msg)                 \
+     (static_cast<void> (!!(exp) ? 0 : (         \
+       LEMON_ASSERT_HANDLER(__FILE__, __LINE__,  \
+                            __PRETTY_FUNCTION__, \
+                            msg, #exp, LEMON_ASSERT_DO_ABORT), 0)))
+
+#else 
+#  if defined LEMON_DISABLE_ASSERTS
+
+#    define LEMON_ASSERT(exp, msg)  (static_cast<void> (0))
+
+#  else
+#    define LEMON_ASSERT(exp, msg)                 \
+       (static_cast<void> (!!(exp) ? 0 : (         \
+         LEMON_ASSERT_HANDLER(__FILE__, __LINE__,  \
+                              __PRETTY_FUNCTION__, \
+                              msg, #exp, LEMON_ASSERT_DO_ABORT), 0)))
+#  endif
+#endif
+
+/**
+ * \brief Macro for mark not yet implemented features.
+ *
+ * \todo Is this the right place for this? It should be used only in
+ * modules under development.
+ *
+ * \todo __PRETTY_FUNCTION__ should be replaced by something
+ * compiler-independent, like BOOST_CURRENT_FUNCTION
+ */
+
+# define LEMON_FIXME(msg) \
+    (LEMON_ASSERT_HANDLER(__FILE__, __LINE__, __PRETTY_FUNCTION__, \
+			  "FIXME: " msg))
Index: lemon/euler.h
===================================================================
--- lemon/euler.h	(revision 2553)
+++ lemon/euler.h	(revision 2553)
@@ -0,0 +1,261 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<lemon/bits/invalid.h>
+#include<lemon/topology.h>
+#include <list>
+
+/// \ingroup graph_prop
+/// \file
+/// \brief Euler tour
+///
+///This file provides an Euler tour iterator and ways to check
+///if a graph is euler.
+
+
+namespace lemon {
+
+  ///Euler iterator for directed graphs.
+
+  /// \ingroup graph_prop
+  ///This iterator converts to the \c Edge type of the graph and using
+  ///operator ++ it provides an Euler tour of a \e directed
+  ///graph (if there exists).
+  ///
+  ///For example
+  ///if the given graph if Euler (i.e it has only one nontrivial component
+  ///and the in-degree is equal to the out-degree for all nodes),
+  ///the following code will put the edges of \c g
+  ///to the vector \c et according to an
+  ///Euler tour of \c g.
+  ///\code
+  ///  std::vector<ListGraph::Edge> et;
+  ///  for(EulerIt<ListGraph> e(g),e!=INVALID;++e)
+  ///    et.push_back(e);
+  ///\endcode
+  ///If \c g is not Euler then the resulted tour will not be full or closed.
+  ///\sa UEulerIt
+  ///\todo Test required
+  template<class Graph>
+  class EulerIt 
+  {
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::EdgeIt EdgeIt;
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    typedef typename Graph::InEdgeIt InEdgeIt;
+    
+    const Graph &g;
+    typename Graph::template NodeMap<OutEdgeIt> nedge;
+    std::list<Edge> euler;
+
+  public:
+    
+    ///Constructor
+
+    ///\param _g A directed graph.
+    ///\param start The starting point of the tour. If it is not given
+    ///       the tour will start from the first node.
+    EulerIt(const Graph &_g,typename Graph::Node start=INVALID)
+      : g(_g), nedge(g)
+    {
+      if(start==INVALID) start=NodeIt(g);
+      for(NodeIt n(g);n!=INVALID;++n) nedge[n]=OutEdgeIt(g,n);
+      while(nedge[start]!=INVALID) {
+	euler.push_back(nedge[start]);
+	Node next=g.target(nedge[start]);
+	++nedge[start];
+	start=next;
+      }
+    }
+    
+    ///Edge Conversion
+    operator Edge() { return euler.empty()?INVALID:euler.front(); }
+    bool operator==(Invalid) { return euler.empty(); }
+    bool operator!=(Invalid) { return !euler.empty(); }
+    
+    ///Next edge of the tour
+    EulerIt &operator++() {
+      Node s=g.target(euler.front());
+      euler.pop_front();
+      //This produces a warning.Strange.
+      //std::list<Edge>::iterator next=euler.begin();
+      typename std::list<Edge>::iterator next=euler.begin();
+      while(nedge[s]!=INVALID) {
+	euler.insert(next,nedge[s]);
+	Node n=g.target(nedge[s]);
+	++nedge[s];
+	s=n;
+      }
+      return *this;
+    }
+    ///Postfix incrementation
+    
+    ///\warning This incrementation
+    ///returns an \c Edge, not an \ref EulerIt, as one may
+    ///expect.
+    Edge operator++(int) 
+    {
+      Edge e=*this;
+      ++(*this);
+      return e;
+    }
+  };
+
+  ///Euler iterator for undirected graphs.
+
+  /// \ingroup graph_prop
+  ///This iterator converts to the \c Edge (or \c UEdge)
+  ///type of the graph and using
+  ///operator ++ it provides an Euler tour of an undirected
+  ///graph (if there exists).
+  ///
+  ///For example
+  ///if the given graph if Euler (i.e it has only one nontrivial component
+  ///and the degree of each node is even),
+  ///the following code will print the edge IDs according to an
+  ///Euler tour of \c g.
+  ///\code
+  ///  for(UEulerIt<ListUGraph> e(g),e!=INVALID;++e) {
+  ///    std::cout << g.id(UEdge(e)) << std::eol;
+  ///  }
+  ///\endcode
+  ///Although the iterator provides an Euler tour of an undirected graph,
+  ///in order to indicate the direction of the tour, UEulerIt
+  ///returns directed edges (that convert to the undirected ones, of course).
+  ///
+  ///If \c g is not Euler then the resulted tour will not be full or closed.
+  ///\sa EulerIt
+  ///\todo Test required
+  template<class Graph>
+  class UEulerIt
+  {
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+    typedef typename Graph::EdgeIt EdgeIt;
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    typedef typename Graph::InEdgeIt InEdgeIt;
+    
+    const Graph &g;
+    typename Graph::template NodeMap<OutEdgeIt> nedge;
+    typename Graph::template UEdgeMap<bool> visited;
+    std::list<Edge> euler;
+
+  public:
+    
+    ///Constructor
+
+    ///\param _g An undirected graph.
+    ///\param start The starting point of the tour. If it is not given
+    ///       the tour will start from the first node.
+    UEulerIt(const Graph &_g,typename Graph::Node start=INVALID)
+      : g(_g), nedge(g), visited(g,false)
+    {
+      if(start==INVALID) start=NodeIt(g);
+      for(NodeIt n(g);n!=INVALID;++n) nedge[n]=OutEdgeIt(g,n);
+      while(nedge[start]!=INVALID) {
+	euler.push_back(nedge[start]);
+	visited[nedge[start]]=true;
+	Node next=g.target(nedge[start]);
+	++nedge[start];
+	start=next;
+	while(nedge[start]!=INVALID && visited[nedge[start]]) ++nedge[start];
+      }
+    }
+    
+    ///Edge Conversion
+    operator Edge() const { return euler.empty()?INVALID:euler.front(); }
+    ///Edge Conversion
+    operator UEdge() const { return euler.empty()?INVALID:euler.front(); }
+    ///\e
+    bool operator==(Invalid) const { return euler.empty(); }
+    ///\e
+    bool operator!=(Invalid) const { return !euler.empty(); }
+    
+    ///Next edge of the tour
+    UEulerIt &operator++() {
+      Node s=g.target(euler.front());
+      euler.pop_front();
+      typename std::list<Edge>::iterator next=euler.begin();
+
+      while(nedge[s]!=INVALID) {
+	while(nedge[s]!=INVALID && visited[nedge[s]]) ++nedge[s];
+	if(nedge[s]==INVALID) break;
+	else {
+	  euler.insert(next,nedge[s]);
+	  visited[nedge[s]]=true;
+	  Node n=g.target(nedge[s]);
+	  ++nedge[s];
+	  s=n;
+	}
+      }
+      return *this;
+    }
+    
+    ///Postfix incrementation
+    
+    ///\warning This incrementation
+    ///returns an \c Edge, not an \ref UEulerIt, as one may
+    ///expect.
+    Edge operator++(int) 
+    {
+      Edge e=*this;
+      ++(*this);
+      return e;
+    }
+  };
+
+
+  ///Checks if the graph is Euler
+
+  /// \ingroup graph_prop
+  ///Checks if the graph is Euler. It works for both directed and
+  ///undirected graphs.
+  ///\note By definition, a directed graph is called \e Euler if
+  ///and only if connected and the number of it is incoming and outgoing edges
+  ///are the same for each node.
+  ///Similarly, an undirected graph is called \e Euler if
+  ///and only if it is connected and the number of incident edges is even
+  ///for each node. <em>Therefore, there are graphs which are not Euler, but
+  ///still have an Euler tour</em>.
+  ///\todo Test required
+  template<class Graph>
+#ifdef DOXYGEN
+  bool
+#else
+  typename enable_if<UndirectedTagIndicator<Graph>,bool>::type
+  euler(const Graph &g) 
+  {
+    for(typename Graph::NodeIt n(g);n!=INVALID;++n)
+      if(countIncEdges(g,n)%2) return false;
+    return connected(g);
+  }
+  template<class Graph>
+  typename disable_if<UndirectedTagIndicator<Graph>,bool>::type
+#endif
+  euler(const Graph &g) 
+  {
+    for(typename Graph::NodeIt n(g);n!=INVALID;++n)
+      if(countInEdges(g,n)!=countOutEdges(g,n)) return false;
+    return connected(g);
+  }
+  
+}
Index: lemon/fib_heap.h
===================================================================
--- lemon/fib_heap.h	(revision 2569)
+++ lemon/fib_heap.h	(revision 2569)
@@ -0,0 +1,464 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_FIB_HEAP_H
+#define LEMON_FIB_HEAP_H
+
+///\file
+///\ingroup auxdat
+///\brief Fibonacci Heap implementation.
+
+#include <vector>
+#include <functional>
+#include <lemon/math.h>
+
+namespace lemon {
+  
+  /// \ingroup auxdat
+  ///
+  ///\brief Fibonacci Heap.
+  ///
+  ///This class implements the \e Fibonacci \e heap data structure. A \e heap
+  ///is a data structure for storing items with specified values called \e
+  ///priorities in such a way that finding the item with minimum priority is
+  ///efficient. \c Compare specifies the ordering of the priorities. In a heap
+  ///one can change the priority of an item, add or erase an item, etc.
+  ///
+  ///The methods \ref increase and \ref erase are not efficient in a Fibonacci
+  ///heap. In case of many calls to these operations, it is better to use a
+  ///\ref BinHeap "binary heap".
+  ///
+  ///\param _Prio Type of the priority of the items.
+  ///\param _ItemIntMap A read and writable Item int map, used internally
+  ///to handle the cross references.
+  ///\param _Compare A class for the ordering of the priorities. The
+  ///default is \c std::less<_Prio>.
+  ///
+  ///\sa BinHeap
+  ///\sa Dijkstra
+  ///\author Jacint Szabo 
+ 
+#ifdef DOXYGEN
+  template <typename _Prio, 
+	    typename _ItemIntMap, 
+	    typename _Compare>
+#else
+  template <typename _Prio, 
+	    typename _ItemIntMap, 
+	    typename _Compare = std::less<_Prio> >
+#endif
+  class FibHeap {
+  public:
+    typedef _ItemIntMap ItemIntMap;
+    typedef _Prio Prio;
+    typedef typename ItemIntMap::Key Item;
+    typedef std::pair<Item,Prio> Pair;
+    typedef _Compare Compare;
+    
+  private:
+    class store;
+    
+    std::vector<store> container;
+    int minimum;
+    ItemIntMap &iimap;
+    Compare comp;
+    int num_items;
+    
+  public:
+    ///Status of the nodes
+    enum State {
+      ///The node is in the heap
+      IN_HEAP = 0,
+      ///The node has never been in the heap
+      PRE_HEAP = -1,
+      ///The node was in the heap but it got out of it
+      POST_HEAP = -2
+    };
+    
+    /// \brief The constructor
+    ///
+    /// \c _iimap should be given to the constructor, since it is
+    ///   used internally to handle the cross references.
+    explicit FibHeap(ItemIntMap &_iimap) 
+      : minimum(0), iimap(_iimap), num_items() {} 
+ 
+    /// \brief The constructor
+    ///
+    /// \c _iimap should be given to the constructor, since it is used
+    /// internally to handle the cross references. \c _comp is an
+    /// object for ordering of the priorities. 
+    FibHeap(ItemIntMap &_iimap, const Compare &_comp) 
+      : minimum(0), iimap(_iimap), comp(_comp), num_items() {}
+    
+    /// \brief The number of items stored in the heap.
+    ///
+    /// Returns the number of items stored in the heap.
+    int size() const { return num_items; }
+
+    /// \brief Checks if the heap stores no items.
+    ///
+    ///   Returns \c true if and only if the heap stores no items.
+    bool empty() const { return num_items==0; }
+
+    /// \brief Make empty this heap.
+    /// 
+    /// Make empty this heap. It does not change the cross reference
+    /// map.  If you want to reuse a heap what is not surely empty you
+    /// should first clear the heap and after that you should set the
+    /// cross reference map for each item to \c PRE_HEAP.
+    void clear() {
+      container.clear(); minimum = 0; num_items = 0;
+    }
+
+    /// \brief \c item gets to the heap with priority \c value independently 
+    /// if \c item was already there.
+    ///
+    /// This method calls \ref push(\c item, \c value) if \c item is not
+    /// stored in the heap and it calls \ref decrease(\c item, \c value) or
+    /// \ref increase(\c item, \c value) otherwise.
+    void set (const Item& item, const Prio& value) {
+      int i=iimap[item];
+      if ( i >= 0 && container[i].in ) {
+	if ( comp(value, container[i].prio) ) decrease(item, value); 
+	if ( comp(container[i].prio, value) ) increase(item, value); 
+      } else push(item, value);
+    }
+    
+    /// \brief Adds \c item to the heap with priority \c value. 
+    ///    
+    /// Adds \c item to the heap with priority \c value. 
+    /// \pre \c item must not be stored in the heap. 
+    void push (const Item& item, const Prio& value) {
+      int i=iimap[item];      
+      if ( i < 0 ) {
+	int s=container.size();
+	iimap.set( item, s );	
+	store st;
+	st.name=item;
+	container.push_back(st);
+	i=s;
+      } else {
+	container[i].parent=container[i].child=-1;
+	container[i].degree=0;
+	container[i].in=true;
+	container[i].marked=false;
+      }
+
+      if ( num_items ) {
+	container[container[minimum].right_neighbor].left_neighbor=i;
+	container[i].right_neighbor=container[minimum].right_neighbor;
+	container[minimum].right_neighbor=i;
+	container[i].left_neighbor=minimum;
+	if ( comp( value, container[minimum].prio) ) minimum=i; 
+      } else {
+	container[i].right_neighbor=container[i].left_neighbor=i;
+	minimum=i;	
+      }
+      container[i].prio=value;
+      ++num_items;
+    }
+    
+    /// \brief Returns the item with minimum priority relative to \c Compare.
+    ///
+    /// This method returns the item with minimum priority relative to \c
+    /// Compare.  
+    /// \pre The heap must be nonempty.  
+    Item top() const { return container[minimum].name; }
+
+    /// \brief Returns the minimum priority relative to \c Compare.
+    ///
+    /// It returns the minimum priority relative to \c Compare.
+    /// \pre The heap must be nonempty.
+    const Prio& prio() const { return container[minimum].prio; }
+        
+    /// \brief Returns the priority of \c item.
+    ///
+    /// It returns the priority of \c item.
+    /// \pre \c item must be in the heap.
+    const Prio& operator[](const Item& item) const { 
+      return container[iimap[item]].prio; 
+    }
+
+    /// \brief Deletes the item with minimum priority relative to \c Compare.
+    ///
+    /// This method deletes the item with minimum priority relative to \c
+    /// Compare from the heap.  
+    /// \pre The heap must be non-empty.  
+    void pop() {
+      /*The first case is that there are only one root.*/
+      if ( container[minimum].left_neighbor==minimum ) {
+	container[minimum].in=false;
+	if ( container[minimum].degree!=0 ) { 
+	  makeroot(container[minimum].child);
+	  minimum=container[minimum].child;
+	  balance();
+	}
+      } else {
+	int right=container[minimum].right_neighbor;
+	unlace(minimum);
+	container[minimum].in=false;
+	if ( container[minimum].degree > 0 ) {
+	  int left=container[minimum].left_neighbor;
+	  int child=container[minimum].child;
+	  int last_child=container[child].left_neighbor;
+	  
+	  makeroot(child);
+	  
+	  container[left].right_neighbor=child;
+	  container[child].left_neighbor=left;
+	  container[right].left_neighbor=last_child;
+	  container[last_child].right_neighbor=right;
+	}
+	minimum=right;
+	balance();
+      } // the case where there are more roots
+      --num_items;   
+    }
+
+    /// \brief Deletes \c item from the heap.
+    ///
+    /// This method deletes \c item from the heap, if \c item was already
+    /// stored in the heap. It is quite inefficient in Fibonacci heaps.
+    void erase (const Item& item) {
+      int i=iimap[item];
+      
+      if ( i >= 0 && container[i].in ) { 	
+	if ( container[i].parent!=-1 ) {
+	  int p=container[i].parent;
+	  cut(i,p);	    
+	  cascade(p);
+	}
+	minimum=i;     //As if its prio would be -infinity
+	pop();
+      }
+    }
+
+    /// \brief Decreases the priority of \c item to \c value.
+    ///
+    /// This method decreases the priority of \c item to \c value.
+    /// \pre \c item must be stored in the heap with priority at least \c
+    ///   value relative to \c Compare.
+    void decrease (Item item, const Prio& value) {
+      int i=iimap[item];
+      container[i].prio=value;
+      int p=container[i].parent;
+      
+      if ( p!=-1 && comp(value, container[p].prio) ) {
+	cut(i,p);	    
+	cascade(p);
+      }      
+      if ( comp(value, container[minimum].prio) ) minimum=i; 
+    }
+
+    /// \brief Increases the priority of \c item to \c value.
+    ///
+    /// This method sets the priority of \c item to \c value. Though
+    /// there is no precondition on the priority of \c item, this
+    /// method should be used only if it is indeed necessary to increase
+    /// (relative to \c Compare) the priority of \c item, because this
+    /// method is inefficient.
+    void increase (Item item, const Prio& value) {
+      erase(item);
+      push(item, value);
+    }
+
+
+    /// \brief Returns if \c item is in, has already been in, or has never 
+    /// been in the heap.
+    ///
+    /// This method returns PRE_HEAP if \c item has never been in the
+    /// heap, IN_HEAP if it is in the heap at the moment, and POST_HEAP
+    /// otherwise. In the latter case it is possible that \c item will
+    /// get back to the heap again.
+    State state(const Item &item) const {
+      int i=iimap[item];
+      if( i>=0 ) {
+	if ( container[i].in ) i=0;
+	else i=-2; 
+      }
+      return State(i);
+    }    
+
+    /// \brief Sets the state of the \c item in the heap.
+    ///
+    /// Sets the state of the \c item in the heap. It can be used to
+    /// manually clear the heap when it is important to achive the
+    /// better time complexity.
+    /// \param i The item.
+    /// \param st The state. It should not be \c IN_HEAP. 
+    void state(const Item& i, State st) {
+      switch (st) {
+      case POST_HEAP:
+      case PRE_HEAP:
+        if (state(i) == IN_HEAP) {
+          erase(i);
+        }
+        iimap[i] = st;
+        break;
+      case IN_HEAP:
+        break;
+      }
+    }
+    
+  private:
+    
+    void balance() {
+
+      int maxdeg=int( std::floor( 2.08*log(double(container.size()))))+1;
+  
+      std::vector<int> A(maxdeg,-1); 
+    
+      /*
+       *Recall that now minimum does not point to the minimum prio element.
+       *We set minimum to this during balance().
+       */
+      int anchor=container[minimum].left_neighbor; 
+      int next=minimum; 
+      bool end=false; 
+    	
+      do {
+	int active=next;
+	if ( anchor==active ) end=true;
+	int d=container[active].degree;
+	next=container[active].right_neighbor;
+
+	while (A[d]!=-1) {	  
+	  if( comp(container[active].prio, container[A[d]].prio) ) {
+	    fuse(active,A[d]); 
+	  } else { 
+	    fuse(A[d],active);
+	    active=A[d];
+	  } 
+	  A[d]=-1;
+	  ++d;
+	}	
+	A[d]=active;
+      } while ( !end );
+
+
+      while ( container[minimum].parent >=0 ) 
+	minimum=container[minimum].parent;
+      int s=minimum;
+      int m=minimum;
+      do {  
+	if ( comp(container[s].prio, container[minimum].prio) ) minimum=s;
+	s=container[s].right_neighbor;
+      } while ( s != m );
+    }
+
+    void makeroot(int c) {
+      int s=c;
+      do {  
+	container[s].parent=-1;
+	s=container[s].right_neighbor;
+      } while ( s != c );
+    }
+
+    void cut(int a, int b) {
+      /*
+       *Replacing a from the children of b.
+       */
+      --container[b].degree;
+    
+      if ( container[b].degree !=0 ) {
+	int child=container[b].child;
+	if ( child==a ) 
+	  container[b].child=container[child].right_neighbor;
+	unlace(a);
+      }
+    
+    
+      /*Lacing a to the roots.*/
+      int right=container[minimum].right_neighbor;
+      container[minimum].right_neighbor=a;
+      container[a].left_neighbor=minimum;
+      container[a].right_neighbor=right;
+      container[right].left_neighbor=a;
+    
+      container[a].parent=-1;
+      container[a].marked=false;
+    }
+
+    void cascade(int a) {
+      if ( container[a].parent!=-1 ) {
+	int p=container[a].parent;
+	
+	if ( container[a].marked==false ) container[a].marked=true;
+	else {
+	  cut(a,p);
+	  cascade(p);
+	}
+      }
+    }
+
+    void fuse(int a, int b) {
+      unlace(b);
+      
+      /*Lacing b under a.*/
+      container[b].parent=a;
+
+      if (container[a].degree==0) {
+	container[b].left_neighbor=b;
+	container[b].right_neighbor=b;
+	container[a].child=b;	
+      } else {
+	int child=container[a].child;
+	int last_child=container[child].left_neighbor;
+	container[child].left_neighbor=b;
+	container[b].right_neighbor=child;
+	container[last_child].right_neighbor=b;
+	container[b].left_neighbor=last_child;
+      }
+
+      ++container[a].degree;
+      
+      container[b].marked=false;
+    }
+
+    /*
+     *It is invoked only if a has siblings.
+     */
+    void unlace(int a) {
+      int leftn=container[a].left_neighbor;
+      int rightn=container[a].right_neighbor;
+      container[leftn].right_neighbor=rightn;
+      container[rightn].left_neighbor=leftn;
+    }
+
+
+    class store {
+      friend class FibHeap;
+      
+      Item name;
+      int parent;
+      int left_neighbor;
+      int right_neighbor;
+      int child;
+      int degree;  
+      bool marked;
+      bool in;
+      Prio prio;
+      
+      store() : parent(-1), child(-1), degree(), marked(false), in(true) {} 
+    };
+  };    
+
+} //namespace lemon
+
+#endif //LEMON_FIB_HEAP_H
+
Index: lemon/floyd_warshall.h
===================================================================
--- lemon/floyd_warshall.h	(revision 2553)
+++ lemon/floyd_warshall.h	(revision 2553)
@@ -0,0 +1,561 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_FLOYD_WARSHALL_H
+#define LEMON_FLOYD_WARSHALL_H
+
+///\ingroup shortest_path
+/// \file
+/// \brief FloydWarshall algorithm.
+///
+
+#include <lemon/list_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/bits/path_dump.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+#include <lemon/matrix_maps.h>
+#include <lemon/maps.h>
+
+#include <limits>
+
+namespace lemon {
+
+  /// \brief Default OperationTraits for the FloydWarshall algorithm class.
+  ///  
+  /// It defines all computational operations and constants which are
+  /// used in the Floyd-Warshall algorithm. The default implementation
+  /// is based on the numeric_limits class. If the numeric type does not
+  /// have infinity value then the maximum value is used as extremal
+  /// infinity value.
+  template <
+    typename Value, 
+    bool has_infinity = std::numeric_limits<Value>::has_infinity>
+  struct FloydWarshallDefaultOperationTraits {
+    /// \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 true only if the first value less than the second.
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+
+  template <typename Value>
+  struct FloydWarshallDefaultOperationTraits<Value, false> {
+    static Value zero() {
+      return static_cast<Value>(0);
+    }
+    static Value infinity() {
+      return std::numeric_limits<Value>::max();
+    }
+    static Value plus(const Value& left, const Value& right) {
+      if (left == infinity() || right == infinity()) return infinity();
+      return left + right;
+    }
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+  
+  /// \brief Default traits class of FloydWarshall class.
+  ///
+  /// Default traits class of FloydWarshall class.
+  /// \param _Graph Graph type.
+  /// \param _LegthMap Type of length map.
+  template<class _Graph, class _LengthMap>
+  struct FloydWarshallDefaultTraits {
+    /// The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge lengths.
+    ///
+    /// The type of the map that stores the edge lengths.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _LengthMap LengthMap;
+
+    // The type of the length of the edges.
+    typedef typename _LengthMap::Value Value;
+
+    /// \brief Operation traits for floyd-warshall algorithm.
+    ///
+    /// It defines the infinity type on the given Value type
+    /// and the used operation.
+    /// \see FloydWarshallDefaultOperationTraits
+    typedef FloydWarshallDefaultOperationTraits<Value> OperationTraits;
+ 
+    /// \brief The type of the matrix map that stores the last edges of the 
+    /// shortest paths.
+    /// 
+    /// The type of the map that stores the last edges of the shortest paths.
+    /// It must be a matrix map with \c Graph::Edge value type.
+    ///
+    typedef DynamicMatrixMap<Graph, typename Graph::Node, 
+			     typename Graph::Edge> PredMap;
+
+    /// \brief Instantiates a PredMap.
+    /// 
+    /// This function instantiates a \ref PredMap. 
+    /// \param graph is the graph,
+    /// to which we would like to define the PredMap.
+    /// \todo The graph alone may be insufficient for the initialization
+    static PredMap *createPredMap(const _Graph& graph) {
+      return new PredMap(graph);
+    }
+
+    /// \brief The type of the map that stores the dists of the nodes.
+    ///
+    /// The type of the map that stores the dists of the nodes.
+    /// It must meet the \ref concepts::WriteMatrixMap "WriteMatrixMap" concept.
+    ///
+    typedef DynamicMatrixMap<Graph, typename Graph::Node, Value> DistMap;
+
+    /// \brief Instantiates a DistMap.
+    ///
+    /// This function instantiates a \ref DistMap. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// \ref DistMap
+    static DistMap *createDistMap(const _Graph& graph) {
+      return new DistMap(graph);
+    }
+
+  };
+  
+  /// \brief %FloydWarshall algorithm class.
+  ///
+  /// \ingroup shortest_path
+  /// This class provides an efficient implementation of \c Floyd-Warshall 
+  /// algorithm. The edge lengths are passed to the algorithm using a
+  /// \ref concepts::ReadMap "ReadMap", so it is easy to change it to any 
+  /// kind of length.
+  ///
+  /// The algorithm solves the shortest path problem for each pair
+  /// of node when the edges can have negative length but the graph should
+  /// not contain cycles with negative sum of length. If we can assume
+  /// that all edge is non-negative in the graph then the dijkstra algorithm
+  /// should be used from each node rather and if the graph is sparse and
+  /// there are negative circles then the johnson algorithm.
+  ///
+  /// The complexity of this algorithm is \f$ O(n^3+e) \f$.
+  ///
+  /// The type of the length is determined by the
+  /// \ref concepts::ReadMap::Value "Value" of the length map.
+  ///
+  /// \param _Graph The graph type the algorithm runs on. The default value
+  /// is \ref ListGraph. The value of _Graph is not used directly by
+  /// FloydWarshall, it is only passed to \ref FloydWarshallDefaultTraits.
+  /// \param _LengthMap This read-only EdgeMap determines the lengths of the
+  /// edges. It is read once for each edge, so the map may involve in
+  /// relatively time consuming process to compute the edge length if
+  /// it is necessary. The default map type is \ref
+  /// concepts::Graph::EdgeMap "Graph::EdgeMap<int>".  The value
+  /// of _LengthMap is not used directly by FloydWarshall, it is only passed 
+  /// to \ref FloydWarshallDefaultTraits.  \param _Traits Traits class to set
+  /// various data types used by the algorithm.  The default traits
+  /// class is \ref FloydWarshallDefaultTraits
+  /// "FloydWarshallDefaultTraits<_Graph,_LengthMap>".  See \ref
+  /// FloydWarshallDefaultTraits for the documentation of a FloydWarshall 
+  /// traits class.
+  ///
+  /// \author Balazs Dezso
+  /// \todo A function type interface would be nice.
+  /// \todo Implement \c nextNode() and \c nextEdge()
+#ifdef DOXYGEN
+  template <typename _Graph, typename _LengthMap, typename _Traits >
+#else
+  template <typename _Graph=ListGraph,
+	    typename _LengthMap=typename _Graph::template EdgeMap<int>,
+	    typename _Traits=FloydWarshallDefaultTraits<_Graph,_LengthMap> >
+#endif
+  class FloydWarshall {
+  public:
+    
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::FloydWarshall::UninitializedParameter";
+      }
+    };
+
+    typedef _Traits Traits;
+    ///The type of the underlying graph.
+    typedef typename _Traits::Graph Graph;
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::EdgeIt EdgeIt;
+    
+    /// \brief The type of the length of the edges.
+    typedef typename _Traits::LengthMap::Value Value;
+    /// \brief The type of the map that stores the edge lengths.
+    typedef typename _Traits::LengthMap LengthMap;
+    /// \brief The type of the map that stores the last
+    /// edges of the shortest paths. The type of the PredMap
+    /// is a matrix map for Edges
+    typedef typename _Traits::PredMap PredMap;
+    /// \brief The type of the map that stores the dists of the nodes.
+    /// The type of the DistMap is a matrix map for Values
+    ///
+    /// \todo It should rather be
+    /// called \c DistMatrix
+    typedef typename _Traits::DistMap DistMap;
+    /// \brief The operation traits.
+    typedef typename _Traits::OperationTraits OperationTraits;
+  private:
+    /// Pointer to the underlying graph.
+    const Graph *graph;
+    /// Pointer to the length map
+    const LengthMap *length;
+    ///Pointer to the map of predecessors edges.
+    PredMap *_pred;
+    ///Indicates if \ref _pred is locally allocated (\c true) or not.
+    bool local_pred;
+    ///Pointer to the map of distances.
+    DistMap *_dist;
+    ///Indicates if \ref _dist is locally allocated (\c true) or not.
+    bool local_dist;
+
+    /// Creates the maps if necessary.
+    void create_maps() {
+      if(!_pred) {
+	local_pred = true;
+	_pred = Traits::createPredMap(*graph);
+      }
+      if(!_dist) {
+	local_dist = true;
+	_dist = Traits::createDistMap(*graph);
+      }
+    }
+    
+  public :
+ 
+    /// \name Named template parameters
+
+    ///@{
+
+    template <class T>
+    struct DefPredMapTraits : public Traits {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph& graph) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting PredMap 
+    /// type
+    /// \ref named-templ-param "Named parameter" for setting PredMap type
+    ///
+    template <class T>
+    struct DefPredMap 
+      : public FloydWarshall< Graph, LengthMap, DefPredMapTraits<T> > {
+      typedef FloydWarshall< Graph, LengthMap, DefPredMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefDistMapTraits : public Traits {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph& graph) {
+	throw UninitializedParameter();
+      }
+    };
+    /// \brief \ref named-templ-param "Named parameter" for setting DistMap 
+    /// type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting DistMap type
+    ///
+    template <class T>
+    struct DefDistMap 
+      : public FloydWarshall< Graph, LengthMap, DefDistMapTraits<T> > {
+      typedef FloydWarshall< Graph, LengthMap, DefDistMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefOperationTraitsTraits : public Traits {
+      typedef T OperationTraits;
+    };
+    
+    /// \brief \ref named-templ-param "Named parameter" for setting 
+    /// OperationTraits type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting PredMap type
+    template <class T>
+    struct DefOperationTraits
+      : public FloydWarshall< Graph, LengthMap, DefOperationTraitsTraits<T> > {
+      typedef FloydWarshall< Graph, LengthMap, DefOperationTraitsTraits<T> >
+      Create;
+    };
+    
+    ///@}
+
+  protected:
+
+    FloydWarshall() {}
+
+  public:      
+
+    typedef FloydWarshall Create;
+    
+    /// \brief Constructor.
+    ///
+    /// \param _graph the graph the algorithm will run on.
+    /// \param _length the length map used by the algorithm.
+    FloydWarshall(const Graph& _graph, const LengthMap& _length) :
+      graph(&_graph), length(&_length),
+      _pred(0), local_pred(false),
+      _dist(0), local_dist(false) {}
+    
+    ///Destructor.
+    ~FloydWarshall() {
+      if(local_pred) delete _pred;
+      if(local_dist) delete _dist;
+    }
+
+    /// \brief Sets the length map.
+    ///
+    /// Sets the length map.
+    /// \return \c (*this)
+    FloydWarshall &lengthMap(const LengthMap &m) {
+      length = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the predecessor edges.
+    ///
+    /// Sets the map storing the predecessor edges.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    FloydWarshall &predMap(PredMap &m) {
+      if(local_pred) {
+	delete _pred;
+	local_pred=false;
+      }
+      _pred = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the distances calculated by the algorithm.
+    ///
+    /// Sets the map storing the distances calculated by the algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    FloydWarshall &distMap(DistMap &m) {
+      if(local_dist) {
+	delete _dist;
+	local_dist=false;
+      }
+      _dist = &m;
+      return *this;
+    }
+
+    ///\name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run(...).
+    /// \n
+    /// If you need more control on the execution,
+    /// Finally \ref start() will perform the actual path
+    /// computation.
+
+    ///@{
+
+    /// \brief Initializes the internal data structures.
+    /// 
+    /// Initializes the internal data structures.
+    void init() {
+      create_maps();
+      for (NodeIt it(*graph); it != INVALID; ++it) {
+	for (NodeIt jt(*graph); jt != INVALID; ++jt) {
+	  _pred->set(it, jt, INVALID);
+	  _dist->set(it, jt, OperationTraits::infinity());
+	}
+	_dist->set(it, it, OperationTraits::zero());
+      }
+      for (EdgeIt it(*graph); it != INVALID; ++it) {
+	Node source = graph->source(it);
+	Node target = graph->target(it);	
+	if (OperationTraits::less((*length)[it], (*_dist)(source, target))) {
+	  _dist->set(source, target, (*length)[it]);
+	  _pred->set(source, target, it);
+	}
+      }
+    }
+    
+    /// \brief Executes the algorithm.
+    ///
+    /// This method runs the %FloydWarshall algorithm in order to compute 
+    /// the shortest path to each node pairs. The algorithm 
+    /// computes 
+    /// - The shortest path tree for each node.
+    /// - The distance between each node pairs.
+    void start() {
+      for (NodeIt kt(*graph); kt != INVALID; ++kt) {
+	for (NodeIt it(*graph); it != INVALID; ++it) {
+	  for (NodeIt jt(*graph); jt != INVALID; ++jt) {
+	    Value relaxed = OperationTraits::plus((*_dist)(it, kt),
+						  (*_dist)(kt, jt));
+	    if (OperationTraits::less(relaxed, (*_dist)(it, jt))) {
+	      _dist->set(it, jt, relaxed);
+	      _pred->set(it, jt, (*_pred)(kt, jt));
+	    }
+	  }
+	}
+      }
+    }
+
+    /// \brief Executes the algorithm and checks the negative cycles.
+    ///
+    /// This method runs the %FloydWarshall algorithm in order to compute 
+    /// the shortest path to each node pairs. If there is a negative cycle 
+    /// in the graph it gives back false. 
+    /// The algorithm computes 
+    /// - The shortest path tree for each node.
+    /// - The distance between each node pairs.
+    bool checkedStart() {
+      start();
+      for (NodeIt it(*graph); it != INVALID; ++it) {
+	if (OperationTraits::less((*dist)(it, it), OperationTraits::zero())) {
+	  return false;
+	}
+      }
+      return true;
+    }
+    
+    /// \brief Runs %FloydWarshall algorithm.
+    ///    
+    /// This method runs the %FloydWarshall algorithm from a each node
+    /// in order to compute the shortest path to each node pairs. 
+    /// The algorithm computes
+    /// - The shortest path tree for each node.
+    /// - The distance between each node pairs.
+    ///
+    /// \note d.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.start();
+    ///\endcode
+    void run() {
+      init();
+      start();
+    }
+    
+    ///@}
+
+    /// \name Query Functions
+    /// The result of the %FloydWarshall algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    typedef PredMatrixMapPath<Graph, PredMap> Path;
+
+    ///Gives back the shortest path.
+    
+    ///Gives back the shortest path.
+    ///\pre The \c t should be reachable from the \c t.
+    Path path(Node s, Node t) 
+    {
+      return Path(*graph, *_pred, s, t);
+    }
+	  
+    /// \brief The distance between two nodes.
+    ///
+    /// Returns the distance between two nodes.
+    /// \pre \ref run() must be called before using this function.
+    /// \warning If node \c v in unreachable from the root the return value
+    /// of this funcion is undefined.
+    Value dist(Node source, Node target) const { 
+      return (*_dist)(source, target); 
+    }
+
+    /// \brief Returns the 'previous edge' of the shortest path tree.
+    ///
+    /// For the node \c node it returns the 'previous edge' of the shortest 
+    /// path tree to direction of the node \c root 
+    /// i.e. it returns the last edge of a shortest path from the node \c root 
+    /// to \c node. It is \ref INVALID if \c node is unreachable from the root
+    /// or if \c node=root. The shortest path tree used here is equal to the 
+    /// shortest path tree used in \ref predNode(). 
+    /// \pre \ref run() must be called before using this function.
+    Edge predEdge(Node root, Node node) const { 
+      return (*_pred)(root, node); 
+    }
+
+    /// \brief Returns the 'previous node' of the shortest path tree.
+    ///
+    /// For a node \c node it returns the 'previous node' of the shortest path 
+    /// tree to direction of the node \c root, i.e. it returns the last but 
+    /// one node from a shortest path from the \c root to \c node. It is 
+    /// INVALID if \c node is unreachable from the root or if \c node=root. 
+    /// The shortest path tree used here is equal to the 
+    /// shortest path tree used in \ref predEdge().  
+    /// \pre \ref run() must be called before using this function.
+    Node predNode(Node root, Node node) const { 
+      return (*_pred)(root, node) == INVALID ? 
+      INVALID : graph->source((*_pred)(root, node)); 
+    }
+    
+    /// \brief Returns a reference to the matrix node map of distances.
+    ///
+    /// Returns a reference to the matrix node map of distances. 
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const DistMap &distMap() const { return *_dist;}
+ 
+    /// \brief Returns a reference to the shortest path tree map.
+    ///
+    /// Returns a reference to the matrix node map of the edges of the
+    /// shortest path tree.
+    /// \pre \ref run() must be called before using this function.
+    const PredMap &predMap() const { return *_pred;}
+ 
+    /// \brief Checks if a node is reachable from the root.
+    ///
+    /// Returns \c true if \c v is reachable from the root.
+    /// \pre \ref run() must be called before using this function.
+    ///
+    bool connected(Node source, Node target) { 
+      return (*_dist)(source, target) != OperationTraits::infinity(); 
+    }
+    
+    ///@}
+  };
+ 
+} //END OF NAMESPACE LEMON
+
+#endif
+
Index: lemon/fredman_tarjan.h
===================================================================
--- lemon/fredman_tarjan.h	(revision 2553)
+++ lemon/fredman_tarjan.h	(revision 2553)
@@ -0,0 +1,523 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_FREDMAN_TARJAN_H
+#define LEMON_FREDMAN_TARJAN_H
+
+///\ingroup spantree
+///\file
+///\brief FredmanTarjan algorithm to compute minimum spanning forest.
+
+#include <limits>
+#include <vector>
+
+#include <lemon/list_graph.h>
+#include <lemon/smart_graph.h>
+#include <lemon/fib_heap.h>
+#include <lemon/radix_sort.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+#include <lemon/bits/traits.h>
+#include <lemon/graph_utils.h>
+
+#include <lemon/concepts/ugraph.h>
+
+namespace lemon {
+
+  ///Default traits class of FredmanTarjan class.
+
+  ///Default traits class of FredmanTarjan class.
+  ///\param GR Graph type.
+  ///\param CM Type of cost map.
+  template<class GR, class CM>
+  struct FredmanTarjanDefaultTraits{
+    ///The graph type the algorithm runs on. 
+    typedef GR UGraph;
+    ///The type of the map that stores the edge costs.
+
+    ///The type of the map that stores the edge costs.
+    ///It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef CM CostMap;
+    //The type of the cost of the edges.
+    typedef typename CM::Value Value;
+    ///The type of the map that stores whether an edge is in the
+    ///spanning tree or not.
+
+    ///The type of the map that stores whether an edge is in the
+    ///spanning tree or not.
+    ///It must meet the \ref concepts::ReadWriteMap "ReadWriteMap" concept.
+    ///By default it is a BoolEdgeMap.
+    typedef typename UGraph::template UEdgeMap<bool> TreeMap;
+    ///Instantiates a TreeMap.
+
+    ///This function instantiates a \ref TreeMap.
+    ///\param _graph is the graph, to which
+    ///we would like to define the \ref TreeMap
+    static TreeMap *createTreeMap(const GR &_graph){
+      return new TreeMap(_graph);
+    }
+  };
+  
+  ///%FredmanTarjan algorithm class to find a minimum spanning tree.
+  
+  /// \ingroup spantree 
+  ///
+  ///This class provides an efficient implementation of %FredmanTarjan
+  ///algorithm whitch is sometimes a bit quicker than the Prim
+  ///algorithm on larger graphs.  Due to the structure of the
+  ///algorithm, it has less controll functions than Prim.
+  ///
+  /// The running time is \f$ O(e\beta(e,n)) \f$ where 
+  /// \f$ \beta(e,n) = \min\{ i | \log^{i}(n) \le e/n\} \f$ and 
+  /// \f$ \log^{i+1}(n)=\log(\log^{i}(n)) \f$
+  ///
+  ///The edge costs are passed to the algorithm using a \ref
+  ///concepts::ReadMap "ReadMap", so it is easy to change it to any
+  ///kind of cost.
+  ///
+  ///The type of the cost is determined by the \ref
+  ///concepts::ReadMap::Value "Value" of the cost map.
+  ///
+  ///\param GR The graph type the algorithm runs on. The default value
+  ///is \ref ListUGraph. The value of GR is not used directly by
+  ///FredmanTarjan, it is only passed to \ref
+  ///FredmanTarjanDefaultTraits.
+  ///
+  ///\param CM This read-only UEdgeMap determines the costs of the
+  ///edges. It is read once for each edge, so the map may involve in
+  ///relatively time consuming process to compute the edge cost if it
+  ///is necessary. The default map type is \ref
+  ///concepts::UGraph::UEdgeMap "UGraph::UEdgeMap<int>". The value of
+  ///CM is not used directly by FredmanTarjan, it is only passed to
+  ///\ref FredmanTarjanDefaultTraits.
+  ///
+  ///\param TR Traits class to set various data types used by the
+  ///algorithm.  The default traits class is \ref
+  ///FredmanTarjanDefaultTraits "FredmanTarjanDefaultTraits<GR,CM>".
+  ///See \ref FredmanTarjanDefaultTraits for the documentation of a
+  ///FredmanTarjan traits class.
+  ///
+  ///\author Balazs Attila Mihaly
+
+#ifdef DOXYGEN
+  template <typename GR,
+	    typename CM,
+	    typename TR>
+#else
+  template <typename GR=ListUGraph,
+	    typename CM=typename GR::template UEdgeMap<int>,
+	    typename TR=FredmanTarjanDefaultTraits<GR,CM> >
+#endif
+  class FredmanTarjan {
+  public:
+    ///\brief \ref Exception for uninitialized parameters.
+    ///
+    ///This error represents problems in the initialization
+    ///of the parameters of the algorithms.
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::FredmanTarjan::UninitializedParameter";
+      }
+    };
+
+    typedef GR Graph;
+    typedef TR Traits;
+    ///The type of the underlying graph.
+    typedef typename TR::UGraph UGraph;
+    ///\e
+    typedef typename UGraph::Node Node;
+    ///\e
+    typedef typename UGraph::NodeIt NodeIt;
+    ///\e
+    typedef typename UGraph::UEdge UEdge;
+    ///\e
+    typedef typename UGraph::UEdgeIt UEdgeIt;
+    ///\e
+    typedef typename UGraph::IncEdgeIt IncEdgeIt;
+    
+    ///The type of the cost of the edges.
+    typedef typename TR::CostMap::Value Value;
+    ///The type of the map that stores the edge costs.
+    typedef typename TR::CostMap CostMap;
+    ///Edges of the spanning tree.
+    typedef typename TR::TreeMap TreeMap;
+  private:
+    ///Pointer to the underlying graph.
+    const UGraph *graph;
+    ///Pointer to the cost map
+    const CostMap *cost;
+    ///Pointer to the map of tree edges.
+    TreeMap *_tree;
+    ///Indicates if \ref _tree is locally allocated (\c true) or not.
+    bool local_tree;
+
+    ///Creates the maps if necessary.
+    
+    void create_maps(){
+      if(!_tree){
+	local_tree=true;
+	_tree=Traits::createTreeMap(*graph);
+      }
+    }
+    
+  public :
+
+    typedef FredmanTarjan Create;
+ 
+    ///\name Named template parameters
+
+    ///@{
+
+    template <class TM>
+    struct DefTreeMapTraits : public Traits {
+      typedef TM TreeMap;
+      static TreeMap *createTreeMap(const UGraph &) {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting TreeMap 
+    ///
+    ///\ref named-templ-param "Named parameter" for setting TreeMap
+    ///
+    template <class TM>
+    struct DefTreeMap
+      : public FredmanTarjan< UGraph, CostMap, DefTreeMapTraits<TM> > { 
+      typedef FredmanTarjan< UGraph, CostMap, DefTreeMapTraits<TM> > Create;
+    };
+
+    ///@}
+
+
+  protected:
+
+    FredmanTarjan() {}
+
+  private:
+
+    template<class SrcGraph,class OrigMap,class Heap,class HeapCrossRef,
+             class ProcessedMap,class PredMap>
+    void processNextTree(const SrcGraph& graph,const OrigMap& orig,
+                         Heap &heap, HeapCrossRef& crossref,
+                         ProcessedMap& processed,PredMap& pred,
+                         int& tree_counter,const int limit){
+      std::vector<typename SrcGraph::Node> tree_nodes;
+      int tree_index=tree_counter;
+      bool stop=false;
+      while(!heap.empty() && !stop){
+        typename SrcGraph::Node v=heap.top();
+        heap.pop();
+	if(processed[v]!=-1){
+	  heap.state(v,Heap::PRE_HEAP);
+	  tree_index=processed[v];
+	  _tree->set(orig[pred[v]],true);
+	  stop=true;
+	  break;
+        }
+	tree_nodes.push_back(v);
+	for(typename SrcGraph::IncEdgeIt e(graph,v);e!=INVALID;++e){
+	  typename SrcGraph::Node w=graph.oppositeNode(v,e);
+	  switch(heap.state(w)){
+	  case Heap::PRE_HEAP:
+	    if(heap.size()>=limit){
+	      stop=true;
+	    }
+	    else{
+	      heap.push(w,(*cost)[orig[e]]);
+	      pred.set(w,e);
+	    }
+	    break;
+	  case Heap::IN_HEAP:
+	    if ((*cost)[orig[e]]<heap[w]){
+	      heap.decrease(w,(*cost)[orig[e]]); 
+	      pred.set(w,e);
+	    }
+	    break;
+	  case Heap::POST_HEAP:
+	    break;
+	  }
+	}
+      }
+      for(int i=1;i<(int)tree_nodes.size();++i){
+	_tree->set(orig[pred[tree_nodes[i]]],true);
+        processed.set(tree_nodes[i],tree_index);
+        crossref[tree_nodes[i]] = Heap::PRE_HEAP;
+      }
+      processed.set(tree_nodes[0],tree_index);
+      crossref[tree_nodes[0]] = Heap::PRE_HEAP;
+      while (!heap.empty()) {
+        typename SrcGraph::Node v=heap.top();
+	heap.pop();
+        crossref[v] = Heap::PRE_HEAP;
+      }
+      heap.clear();
+      if(!stop)++tree_counter;
+    }
+
+    template<class SrcGraph,class OrigMap,class ProcessedMap>
+    void createTrees(const SrcGraph& graph, const OrigMap& orig, 
+                     ProcessedMap& processed,
+                     int edgenum,int& tree_counter){
+      typedef typename SrcGraph::Node Node;
+      typedef typename SrcGraph::UEdge UEdge;
+      typedef typename SrcGraph::NodeIt NodeIt;
+      typedef typename SrcGraph::template NodeMap<int> HeapCrossRef;
+      typedef typename SrcGraph::template NodeMap<UEdge> PredMap;
+      HeapCrossRef crossref(graph,-1);
+      FibHeap<Value,HeapCrossRef> heap(crossref);
+      PredMap pred(graph,INVALID);
+      int rate=2*edgenum/countNodes(graph);
+      int limit=(rate>std::numeric_limits<int>::digits)?
+      std::numeric_limits<int>::max() : (1<<rate);
+      for(NodeIt i(graph);i!=INVALID;++i){
+	if(processed[i]==-1){
+	  heap.push(i, Value());
+	  processNextTree(graph,orig,heap,crossref,
+                          processed,pred,tree_counter,limit);
+	}
+      }
+    }
+
+    template<class SrcGraph,class DestGraph,class SrcOrigMap,
+             class DestOrigMap,class ProcessedMap>
+    void collect(const SrcGraph& srcgraph,const SrcOrigMap& srcorig,
+                 DestGraph& destgraph,DestOrigMap& destorig,
+                 const ProcessedMap& processed,const int tree_counter){
+      typedef typename SrcGraph::Node Node;
+      typedef typename DestGraph::Node DNode;
+      typedef typename SrcGraph::UEdge UEdge;
+      typedef typename DestGraph::UEdge DUEdge;
+      typedef typename SrcGraph::Edge Edge;
+      typedef typename SrcGraph::EdgeIt EdgeIt;
+      std::vector<Edge> edges;
+      std::vector<DNode> nodes(tree_counter, INVALID);
+      for(EdgeIt i(srcgraph);i!=INVALID;++i){
+	if(processed[srcgraph.source(i)]<processed[srcgraph.target(i)]){
+	  edges.push_back(i);
+          if(nodes[processed[srcgraph.source(i)]]==INVALID) {
+	    nodes[processed[srcgraph.source(i)]]=destgraph.addNode();
+	  }
+          if(nodes[processed[srcgraph.target(i)]]==INVALID) {
+	    nodes[processed[srcgraph.target(i)]]=destgraph.addNode();
+	  }
+	}
+      }
+      
+      radixSort(edges.begin(),edges.end(),
+                mapFunctor(composeMap(processed,sourceMap(srcgraph))));
+      counterSort(edges.begin(),edges.end(),
+                  mapFunctor(composeMap(processed,targetMap(srcgraph))));
+      for(int i=0;i!=(int)edges.size();++i){
+	int srcproc=processed[srcgraph.source(edges[i])];
+	int trgproc=processed[srcgraph.target(edges[i])];
+        Value minval=(*cost)[srcorig[edges[i]]];
+        UEdge minpos=edges[i];
+	while (i+1!=(int)edges.size() && 
+               srcproc==processed[srcgraph.source(edges[i+1])] &&
+	  trgproc==processed[srcgraph.target(edges[i+1])]) {
+	  if (minval>(*cost)[srcorig[edges[i+1]]]) {
+            minval=(*cost)[srcorig[edges[i+1]]];
+            minpos=edges[i+1];
+	  }
+          ++i;
+	} 
+	destorig[destgraph.addEdge(nodes[srcproc],nodes[trgproc])]=
+          srcorig[minpos];
+      }
+    }
+
+    template<class SrcGraph,class OrigMap>
+    void phase(const SrcGraph& graph,const OrigMap& orig,int edgenum){
+      int tree_counter = 0;
+      typename SrcGraph::template NodeMap<int> processed(graph,-1);
+      SmartUGraph destgraph;
+      SmartUGraph::UEdgeMap<typename OrigMap::Value> destorig(destgraph);
+      createTrees(graph,orig,processed,edgenum,tree_counter);
+      collect(graph,orig,destgraph,destorig,processed,tree_counter);
+      if (countNodes(destgraph)>1) {
+        phase(destgraph,destorig,edgenum);
+      }
+    }
+
+  public:      
+    
+    ///Constructor.
+    
+    ///\param _graph the graph the algorithm will run on.
+    ///\param _cost the cost map used by the algorithm.
+    FredmanTarjan(const UGraph& _graph, const CostMap& _cost) :
+      graph(&_graph), cost(&_cost),
+      _tree(0), local_tree(false)
+    {
+      checkConcept<concepts::UGraph, UGraph>();
+    }
+    
+    ///Destructor.
+    ~FredmanTarjan(){
+      if(local_tree) delete _tree;
+    }
+
+    ///Sets the cost map.
+
+    ///Sets the cost map.
+    ///\return <tt> (*this) </tt>
+    FredmanTarjan &costMap(const CostMap &m){
+      cost = &m;
+      return *this;
+    }
+
+    ///Sets the map storing the tree edges.
+
+    ///Sets the map storing the tree edges.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///By default this is a BoolEdgeMap.
+    ///\return <tt> (*this) </tt>
+    FredmanTarjan &treeMap(TreeMap &m){
+      if(local_tree) {
+	delete _tree;
+	local_tree=false;
+      }
+      _tree = &m;
+      return *this;
+    }
+
+  public:
+    ///\name Execution control
+    ///The simplest way to execute the algorithm is to use
+    ///one of the member functions called \c run(...).
+
+    ///@{
+
+    ///Initializes the internal data structures.
+
+    ///Initializes the internal data structures.
+    ///
+    void init(){
+      create_maps();
+      for(typename Graph::UEdgeIt i(*graph);i!=INVALID;++i){
+	_tree->set(i,false);
+      }
+    }
+
+    ///Executes the algorithm.
+
+    ///Executes the algorithm.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///This method runs the %FredmanTarjan algorithm from the node(s)
+    ///in order to compute the
+    ///minimum spanning tree.
+    void start(){
+	phase(*graph,identityMap<UEdge>(),countEdges(*graph));
+    }
+    
+    ///Runs %FredmanTarjan algorithm.
+    
+    ///This method runs the %FredmanTarjan algorithm
+    ///in order to compute the minimum spanning forest.
+    ///
+    ///\note ft.run() is just a shortcut of the following code.
+    ///\code
+    ///  ft.init();
+    ///  ft.start();
+    ///\endcode
+    void run() {
+      init();
+      start();
+    }
+
+    ///@}
+
+    ///\name Query Functions
+    ///The result of the %FredmanTarjan algorithm can be obtained using these
+    ///functions.\n
+    ///Before the use of these functions,
+    ///either run() or start() must be called.
+    
+    ///@{
+
+    ///Returns a reference to the tree edges map.
+
+    ///Returns a reference to the TreeEdgeMap of the edges of the
+    ///minimum spanning tree. The value of the map is \c true only if the 
+    ///edge is in the minimum spanning tree.
+    ///
+    ///\pre \ref run() or \ref start() must be called before using this 
+    ///function.
+    const TreeMap &treeMap() const { return *_tree;}
+ 
+    ///Sets the tree edges map.
+
+    ///Sets the TreeMap of the edges of the minimum spanning tree.
+    ///The map values belonging to the edges of the minimum
+    ///spanning tree are set to \c tree_edge_value or \c true by default 
+    ///while the edge values not belonging to the minimum spanning tree are 
+    ///set to
+    ///\c tree_default_value or \c false by default.
+    ///
+    ///\pre \ref run() or \ref start() must be called before using this 
+    ///function.
+
+    template<class TreeMap>
+    void treeEdges(
+        TreeMap& tree,
+        const typename TreeMap::Value& tree_edge_value=true,
+        const typename TreeMap::Value& tree_default_value=false) const {
+      for(typename UGraph::UEdgeIt i(*graph);i!=INVALID;++i){
+	(*_tree)[i]?tree.set(i,tree_edge_value):tree.set(i,tree_default_value);
+      }
+    }
+
+    ///\brief Checks if an edge is in the spanning tree or not.
+
+    ///Checks if an edge is in the spanning tree or not.
+    ///\param e is the edge that will be checked
+    ///\return \c true if e is in the spanning tree, \c false otherwise
+    bool tree(UEdge e){
+      return (*_tree)[e];
+    }
+    ///@}
+  };
+
+  /// \ingroup spantree
+  ///
+  /// \brief Function type interface for FredmanTarjan algorithm.
+  ///
+  /// Function type interface for FredmanTarjan algorithm.
+  /// \param graph the UGraph that the algorithm runs on
+  /// \param cost the CostMap of the edges
+  /// \retval tree the EdgeMap that contains whether an edge is in the 
+  /// spanning tree or not
+  ///
+  /// \sa Prim
+  template<class Graph,class CostMap,class TreeMap>
+  void fredmanTarjan(const Graph& graph, const CostMap& cost,TreeMap& tree){
+    typename FredmanTarjan<Graph,CostMap>::template DefTreeMap<TreeMap>::
+      Create ft(graph,cost);
+    ft.treeMap(tree);
+    ft.run();
+  }
+
+} //END OF NAMESPACE LEMON
+
+#endif
Index: lemon/full_graph.h
===================================================================
--- lemon/full_graph.h	(revision 2569)
+++ lemon/full_graph.h	(revision 2569)
@@ -0,0 +1,789 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_FULL_GRAPH_H
+#define LEMON_FULL_GRAPH_H
+
+#include <lemon/math.h>
+
+#include <lemon/bits/base_extender.h>
+#include <lemon/bits/graph_extender.h>
+
+#include <lemon/bits/invalid.h>
+#include <lemon/bits/utility.h>
+
+
+///\ingroup graphs
+///\file
+///\brief FullGraph and FullUGraph classes.
+
+
+namespace lemon {
+
+  class FullGraphBase {
+    int _nodeNum;
+    int _edgeNum;
+  public:
+
+    typedef FullGraphBase Graph;
+
+    class Node;
+    class Edge;
+
+  protected:
+
+    FullGraphBase() {}
+
+    void construct(int n) { _nodeNum = n; _edgeNum = n * n; }
+
+  public:
+    
+    typedef True NodeNumTag;
+    typedef True EdgeNumTag;
+
+    Node operator()(int ix) const { return Node(ix); }
+    int index(const Node& node) const { return node.id; }
+
+    Edge edge(const Node& u, const Node& v) const { 
+      return Edge(*this, u.id, v.id); 
+    }
+
+    int nodeNum() const { return _nodeNum; }
+    int edgeNum() const { return _edgeNum; }
+
+    int maxNodeId() const { return _nodeNum-1; }
+    int maxEdgeId() const { return _edgeNum-1; }
+
+    Node source(Edge e) const { return e.id % _nodeNum; }
+    Node target(Edge e) const { return e.id / _nodeNum; }
+
+
+    static int id(Node v) { return v.id; }
+    static int id(Edge e) { return e.id; }
+
+    static Node nodeFromId(int id) { return Node(id);}
+    
+    static Edge edgeFromId(int id) { return Edge(id);}
+
+    typedef True FindEdgeTag;
+
+    Edge findEdge(Node u,Node v, Edge prev = INVALID) const {
+      return prev.id == -1 ? Edge(*this, u.id, v.id) : INVALID;
+    }
+    
+      
+    class Node {
+      friend class FullGraphBase;
+
+    protected:
+      int id;
+      Node(int _id) : id(_id) {}
+    public:
+      Node() {}
+      Node (Invalid) : id(-1) {}
+      bool operator==(const Node node) const {return id == node.id;}
+      bool operator!=(const Node node) const {return id != node.id;}
+      bool operator<(const Node node) const {return id < node.id;}
+    };
+    
+
+
+    class Edge {
+      friend class FullGraphBase;
+      
+    protected:
+      int id;  // _nodeNum * target + source;
+
+      Edge(int _id) : id(_id) {}
+
+      Edge(const FullGraphBase& _graph, int source, int target) 
+	: id(_graph._nodeNum * target+source) {}
+    public:
+      Edge() { }
+      Edge (Invalid) { id = -1; }
+      bool operator==(const Edge edge) const {return id == edge.id;}
+      bool operator!=(const Edge edge) const {return id != edge.id;}
+      bool operator<(const Edge edge) const {return id < edge.id;}
+    };
+
+    void first(Node& node) const {
+      node.id = _nodeNum-1;
+    }
+
+    static void next(Node& node) {
+      --node.id;
+    }
+
+    void first(Edge& e) const {
+      e.id = _edgeNum-1;
+    }
+
+    static void next(Edge& e) {
+      --e.id;
+    }
+
+    void firstOut(Edge& e, const Node& n) const {
+      e.id = _edgeNum + n.id - _nodeNum;
+    }
+
+    void nextOut(Edge& e) const {
+      e.id -= _nodeNum;
+      if (e.id < 0) e.id = -1;
+    }
+
+    void firstIn(Edge& e, const Node& n) const {
+      e.id = n.id * _nodeNum;
+    }
+    
+    void nextIn(Edge& e) const {
+      ++e.id;
+      if (e.id % _nodeNum == 0) e.id = -1;
+    }
+
+  };
+
+  typedef GraphExtender<FullGraphBase> ExtendedFullGraphBase;
+
+  /// \ingroup graphs
+  ///
+  /// \brief A full graph class.
+  ///
+  /// This is a simple and fast directed full graph implementation.
+  /// It is completely static, so you can neither add nor delete either
+  /// edges or nodes.
+  /// Thus it conforms to
+  /// the \ref concepts::Graph "Graph" concept and
+  ///it also has an
+  ///important extra feature that
+  ///its maps are real \ref concepts::ReferenceMap "reference map"s.
+  /// \sa concepts::Graph.
+  ///
+  /// \sa FullUGraph
+  ///
+  /// \author Alpar Juttner
+  class FullGraph : public ExtendedFullGraphBase {
+  public:
+
+    typedef ExtendedFullGraphBase Parent;
+
+    /// \brief Constructor
+    FullGraph() { construct(0); }
+
+    /// \brief Constructor
+    ///
+    FullGraph(int n) { construct(n); }
+
+    /// \brief Resize the graph
+    ///
+    /// Resize the graph. The function will fully destroy and build the graph.
+    /// This cause that the maps of the graph will reallocated
+    /// automatically and the previous values will be lost.
+    void resize(int n) {
+      Parent::notifier(Edge()).clear();
+      Parent::notifier(Node()).clear();
+      construct(n);
+      Parent::notifier(Node()).build();
+      Parent::notifier(Edge()).build();
+    }
+
+    /// \brief Returns the node with the given index.
+    ///
+    /// Returns the node with the given index. Because it is a
+    /// static size graph the node's of the graph can be indiced
+    /// by the range from 0 to \e nodeNum()-1 and the index of
+    /// the node can accessed by the \e index() member.
+    Node operator()(int ix) const { return Parent::operator()(ix); }
+
+    /// \brief Returns the index of the node.
+    ///
+    /// Returns the index of the node. Because it is a
+    /// static size graph the node's of the graph can be indiced
+    /// by the range from 0 to \e nodeNum()-1 and the index of
+    /// the node can accessed by the \e index() member.
+    int index(const Node& node) const { return Parent::index(node); }
+
+    /// \brief Returns the edge connects the given nodes.
+    ///
+    /// Returns the edge connects the given nodes.
+    Edge edge(const Node& u, const Node& v) const { 
+      return Parent::edge(u, v); 
+    }
+
+    /// \brief Number of nodes.
+    int nodeNum() const { return Parent::nodeNum(); }
+    /// \brief Number of edges.
+    int edgeNum() const { return Parent::edgeNum(); }
+  };
+
+
+  class FullUGraphBase {
+    int _nodeNum;
+    int _edgeNum;
+  public:
+
+    typedef FullUGraphBase Graph;
+
+    class Node;
+    class Edge;
+
+  protected:
+
+    FullUGraphBase() {}
+
+    void construct(int n) { _nodeNum = n; _edgeNum = n * (n - 1) / 2; }
+
+  public:
+
+
+    Node operator()(int ix) const { return Node(ix); }
+    int index(const Node& node) const { return node.id; }
+
+    Edge edge(const Node& u, const Node& v) const { 
+      return Edge(u.id * (u.id - 1) / 2 + v.id);
+    }
+
+    typedef True NodeNumTag;
+    typedef True EdgeNumTag;
+
+    int nodeNum() const { return _nodeNum; }
+    int edgeNum() const { return _edgeNum; }
+
+    int maxNodeId() const { return _nodeNum-1; }
+    int maxEdgeId() const { return _edgeNum-1; }
+
+    static Node nodeFromId(int id) { return Node(id);}
+    static Edge edgeFromId(int id) { return Edge(id);}
+
+    Node source(Edge e) const { 
+      /// \todo we may do it faster
+      return Node((int(sqrt(double(1 + 8 * e.id)) + 1)) / 2);
+    }
+
+    Node target(Edge e) const { 
+      int s = (int(sqrt(double(1 + 8 * e.id)) + 1)) / 2;
+      return Node(e.id - s * (s - 1) / 2);
+    }
+
+    static int id(Node v) { return v.id; }
+    static int id(Edge e) { return e.id; }
+
+    Edge findEdge(Node u, Node v, Edge prev = INVALID) const {
+      if (prev.id != -1 || u.id <= v.id) return Edge(-1);
+      return Edge(u.id * (u.id - 1) / 2 + v.id);
+    }
+
+    typedef True FindEdgeTag;
+    
+      
+    class Node {
+      friend class FullUGraphBase;
+
+    protected:
+      int id;
+      Node(int _id) { id = _id;}
+    public:
+      Node() {}
+      Node (Invalid) { id = -1; }
+      bool operator==(const Node node) const {return id == node.id;}
+      bool operator!=(const Node node) const {return id != node.id;}
+      bool operator<(const Node node) const {return id < node.id;}
+    };
+    
+
+
+    class Edge {
+      friend class FullUGraphBase;
+      
+    protected:
+      int id;  // _nodeNum * target + source;
+
+      Edge(int _id) : id(_id) {}
+
+    public:
+      Edge() { }
+      Edge (Invalid) { id = -1; }
+      bool operator==(const Edge edge) const {return id == edge.id;}
+      bool operator!=(const Edge edge) const {return id != edge.id;}
+      bool operator<(const Edge edge) const {return id < edge.id;}
+    };
+
+    void first(Node& n) const {
+      n.id = _nodeNum - 1;
+    }
+
+    static void next(Node& n) {
+      --n.id;
+    }
+
+    void first(Edge& e) const {
+      e.id = _edgeNum - 1;
+    }
+
+    static void next(Edge& e) {
+      --e.id;
+    }
+
+    void firstOut(Edge& e, const Node& n) const {      
+      int src = n.id;
+      int trg = 0;
+      e.id = (trg < src ? src * (src - 1) / 2 + trg : -1);
+    }
+
+    /// \todo with specialized iterators we can make faster iterating
+    void nextOut(Edge& e) const {
+      int src = source(e).id;
+      int trg = target(e).id;
+      ++trg;
+      e.id = (trg < src ? src * (src - 1) / 2 + trg : -1);
+    }
+
+    void firstIn(Edge& e, const Node& n) const {
+      int src = n.id + 1;
+      int trg = n.id;
+      e.id = (src < _nodeNum ? src * (src - 1) / 2 + trg : -1);
+    }
+    
+    void nextIn(Edge& e) const {
+      int src = source(e).id;
+      int trg = target(e).id;
+      ++src;
+      e.id = (src < _nodeNum ? src * (src - 1) / 2 + trg : -1);
+    }
+
+  };
+
+  typedef UGraphExtender<UndirGraphExtender<FullUGraphBase> > 
+  ExtendedFullUGraphBase;
+
+  /// \ingroup graphs
+  ///
+  /// \brief An undirected full graph class.
+  ///
+  /// This is a simple and fast undirected full graph implementation.
+  /// It is completely static, so you can neither add nor delete either
+  /// edges or nodes.
+  ///
+  /// The main difference beetween the \e FullGraph and \e FullUGraph class
+  /// is that this class conforms to the undirected graph concept and
+  /// it does not contain the loop edges.
+  ///
+  ///It also has an
+  ///important extra feature that
+  ///its maps are real \ref concepts::ReferenceMap "reference map"s.
+  ///
+  /// \sa FullGraph
+  ///
+  /// \author Balazs Dezso
+  class FullUGraph : public ExtendedFullUGraphBase {
+  public:
+
+    typedef ExtendedFullUGraphBase Parent;
+
+    /// \brief Constructor
+    FullUGraph() { construct(0); }
+
+    /// \brief Constructor
+    FullUGraph(int n) { construct(n); }
+
+    /// \brief Resize the graph
+    ///
+    /// Resize the graph. The function will fully destroy and build the graph.
+    /// This cause that the maps of the graph will reallocated
+    /// automatically and the previous values will be lost.
+    void resize(int n) {
+      Parent::notifier(Edge()).clear();
+      Parent::notifier(UEdge()).clear();
+      Parent::notifier(Node()).clear();
+      construct(n);
+      Parent::notifier(Node()).build();
+      Parent::notifier(UEdge()).build();
+      Parent::notifier(Edge()).build();
+    }
+
+    /// \brief Returns the node with the given index.
+    ///
+    /// Returns the node with the given index. Because it is a
+    /// static size graph the node's of the graph can be indiced
+    /// by the range from 0 to \e nodeNum()-1 and the index of
+    /// the node can accessed by the \e index() member.
+    Node operator()(int ix) const { return Parent::operator()(ix); }
+
+    /// \brief Returns the index of the node.
+    ///
+    /// Returns the index of the node. Because it is a
+    /// static size graph the node's of the graph can be indiced
+    /// by the range from 0 to \e nodeNum()-1 and the index of
+    /// the node can accessed by the \e index() member.
+    int index(const Node& node) const { return Parent::index(node); }
+
+    /// \brief Number of nodes.
+    int nodeNum() const { return Parent::nodeNum(); }
+    /// \brief Number of edges.
+    int edgeNum() const { return Parent::edgeNum(); }
+    /// \brief Number of undirected edges.
+    int uEdgeNum() const { return Parent::uEdgeNum(); }
+
+    /// \brief Returns the edge connects the given nodes.
+    ///
+    /// Returns the edge connects the given nodes.
+    Edge edge(const Node& u, const Node& v) const { 
+      if (Parent::index(u) > Parent::index(v)) {
+        return Parent::direct(Parent::edge(u, v), true);
+      } else if (Parent::index(u) == Parent::index(v)) {
+        return INVALID;
+      } else {
+        return Parent::direct(Parent::edge(v, u), false); 
+      }
+    }
+
+    /// \brief Returns the undirected edge connects the given nodes.
+    ///
+    /// Returns the undirected edge connects the given nodes.
+    UEdge uEdge(const Node& u, const Node& v) const {
+      if (Parent::index(u) > Parent::index(v)) {
+        return Parent::edge(u, v);
+      } else if (Parent::index(u) == Parent::index(v)) {
+        return INVALID;
+      } else {
+        return Parent::edge(v, u);
+      }
+    }
+  };
+
+
+  class FullBpUGraphBase {
+  protected:
+
+    int _aNodeNum;
+    int _bNodeNum;
+
+    int _edgeNum;
+
+  protected:
+
+    FullBpUGraphBase() {}
+
+    void construct(int ann, int bnn) {
+      _aNodeNum = ann;
+      _bNodeNum = bnn;
+      _edgeNum = ann * bnn;
+    }
+
+  public:
+
+    class NodeSetError : public LogicError {
+    public:
+      virtual const char* what() const throw() { 
+	return "lemon::FullBpUGraph::NodeSetError";
+      }
+    };
+  
+    class Node {
+      friend class FullBpUGraphBase;
+    protected:
+      int id;
+
+      Node(int _id) : id(_id) {}
+    public:
+      Node() {}
+      Node(Invalid) { id = -1; }
+      bool operator==(const Node i) const {return id==i.id;}
+      bool operator!=(const Node i) const {return id!=i.id;}
+      bool operator<(const Node i) const {return id<i.id;}
+    };
+
+    class UEdge {
+      friend class FullBpUGraphBase;
+    protected:
+      int id;
+
+      UEdge(int _id) { id = _id;}
+    public:
+      UEdge() {}
+      UEdge (Invalid) { id = -1; }
+      bool operator==(const UEdge i) const {return id==i.id;}
+      bool operator!=(const UEdge i) const {return id!=i.id;}
+      bool operator<(const UEdge i) const {return id<i.id;}
+    };
+
+    Node aNode(int ix) const { return Node(ix << 1); }
+    Node bNode(int ix) const { return Node((ix << 1) + 1); }
+
+    int aNodeIndex(const Node& node) const { return node.id >> 1; }
+    int bNodeIndex(const Node& node) const { return node.id >> 1; }
+
+    UEdge uEdge(const Node& u, const Node& v) const { 
+      if (((u.id ^ v.id) & 1) != 1) {
+        return UEdge(-1);
+      } else if ((u.id & 1) == 0) {
+        return UEdge((u.id >> 1) * _bNodeNum + (v.id >> 1));
+      } else {
+        return UEdge((v.id >> 1) * _bNodeNum + (u.id >> 1));
+      }
+    }
+
+    void firstANode(Node& node) const {
+      node.id = 2 * _aNodeNum - 2;
+      if (node.id < 0) node.id = -1; 
+    }
+    void nextANode(Node& node) const {
+      node.id -= 2;
+      if (node.id < 0) node.id = -1; 
+    }
+
+    void firstBNode(Node& node) const {
+      node.id = 2 * _bNodeNum - 1;
+    }
+    void nextBNode(Node& node) const {
+      node.id -= 2;
+    }
+
+    void first(Node& node) const {
+      if (_aNodeNum > 0) {
+	node.id = 2 * _aNodeNum - 2;
+      } else {
+	node.id = 2 * _bNodeNum - 1;
+      }
+    }
+    void next(Node& node) const {
+      node.id -= 2;
+      if (node.id == -2) {
+	node.id = 2 * _bNodeNum - 1;
+      }
+    }
+  
+    void first(UEdge& edge) const {
+      edge.id = _edgeNum - 1;
+    }
+    void next(UEdge& edge) const {
+      --edge.id;
+    }
+
+    void firstFromANode(UEdge& edge, const Node& node) const {
+      LEMON_ASSERT((node.id & 1) == 0, NodeSetError());
+      edge.id = (node.id >> 1) * _bNodeNum;
+    }
+    void nextFromANode(UEdge& edge) const {
+      ++(edge.id);
+      if (edge.id % _bNodeNum == 0) edge.id = -1;
+    }
+
+    void firstFromBNode(UEdge& edge, const Node& node) const {
+      LEMON_ASSERT((node.id & 1) == 1, NodeSetError());
+      edge.id = (node.id >> 1);
+    }
+    void nextFromBNode(UEdge& edge) const {
+      edge.id += _bNodeNum;
+      if (edge.id >= _edgeNum) edge.id = -1;
+    }
+
+    static int id(const Node& node) {
+      return node.id;
+    }
+    static Node nodeFromId(int id) {
+      return Node(id);
+    }
+    int maxNodeId() const {
+      return _aNodeNum > _bNodeNum ? 
+	_aNodeNum * 2 - 2 : _bNodeNum * 2 - 1;
+    }
+  
+    static int id(const UEdge& edge) {
+      return edge.id;
+    }
+    static UEdge uEdgeFromId(int id) {
+      return UEdge(id);
+    }
+    int maxUEdgeId() const {
+      return _edgeNum - 1;
+    }
+  
+    static int aNodeId(const Node& node) {
+      return node.id >> 1;
+    }
+    static Node nodeFromANodeId(int id) {
+      return Node(id << 1);
+    }
+    int maxANodeId() const {
+      return _aNodeNum;
+    }
+
+    static int bNodeId(const Node& node) {
+      return node.id >> 1;
+    }
+    static Node nodeFromBNodeId(int id) {
+      return Node((id << 1) + 1);
+    }
+    int maxBNodeId() const {
+      return _bNodeNum;
+    }
+
+    Node aNode(const UEdge& edge) const {
+      return Node((edge.id / _bNodeNum) << 1);
+    }
+    Node bNode(const UEdge& edge) const {
+      return Node(((edge.id % _bNodeNum) << 1) + 1);
+    }
+
+    static bool aNode(const Node& node) {
+      return (node.id & 1) == 0;
+    }
+
+    static bool bNode(const Node& node) {
+      return (node.id & 1) == 1;
+    }
+
+
+    typedef True NodeNumTag;
+    int nodeNum() const { return _aNodeNum + _bNodeNum; }
+    int aNodeNum() const { return _aNodeNum; }
+    int bNodeNum() const { return _bNodeNum; }
+
+    typedef True EdgeNumTag;
+    int uEdgeNum() const { return _edgeNum; }
+
+
+    typedef True FindEdgeTag;
+    UEdge findUEdge(Node u, Node v, UEdge prev = INVALID) const {
+      if (prev.id != -1 || ((u.id ^ v.id) & 1) != 1) {
+        return UEdge(-1);
+      } else if ((u.id & 1) == 0) {
+        return UEdge((u.id >> 1) * _bNodeNum + (v.id >> 1));
+      } else {
+        return UEdge((v.id >> 1) * _bNodeNum + (u.id >> 1));
+      }
+    }
+
+  };
+
+
+  typedef BpUGraphExtender<BidirBpUGraphExtender<FullBpUGraphBase> > 
+  ExtendedFullBpUGraphBase;
+
+
+  /// \ingroup graphs
+  ///
+  /// \brief An undirected full bipartite graph class.
+  ///
+  /// This is a simple and fast bipartite undirected full graph implementation.
+  /// It is completely static, so you can neither add nor delete either
+  /// edges or nodes.
+  ///
+  /// \author Balazs Dezso
+  class FullBpUGraph : 
+    public ExtendedFullBpUGraphBase {
+  public:
+
+    typedef ExtendedFullBpUGraphBase Parent;
+
+    FullBpUGraph() {
+      Parent::construct(0, 0);
+    }
+
+    FullBpUGraph(int ann, int bnn) {
+      Parent::construct(ann, bnn);
+    }
+
+    /// \brief Resize the graph
+    ///
+    /// Resize the graph
+    void resize(int n, int m) {
+      Parent::notifier(Edge()).clear();
+      Parent::notifier(UEdge()).clear();
+      Parent::notifier(Node()).clear();
+      Parent::notifier(ANode()).clear();
+      Parent::notifier(BNode()).clear();
+      construct(n, m);
+      Parent::notifier(ANode()).build();
+      Parent::notifier(BNode()).build();
+      Parent::notifier(Node()).build();
+      Parent::notifier(UEdge()).build();
+      Parent::notifier(Edge()).build();
+    }
+
+    /// \brief Number of nodes.
+    int nodeNum() const { return Parent::nodeNum(); }
+    /// \brief Number of A-nodes.
+    int aNodeNum() const { return Parent::aNodeNum(); }
+    /// \brief Number of B-nodes.
+    int bNodeNum() const { return Parent::bNodeNum(); }
+    /// \brief Number of edges.
+    int edgeNum() const { return Parent::edgeNum(); }
+    /// \brief Number of undirected edges.
+    int uEdgeNum() const { return Parent::uEdgeNum(); }
+
+
+    using Parent::aNode;
+    using Parent::bNode;
+
+    /// \brief Returns the A-node with the given index.
+    ///
+    /// Returns the A-node with the given index. Because it is a
+    /// static size graph the node's of the graph can be indiced
+    /// by the range from 0 to \e aNodeNum()-1 and the index of
+    /// the node can accessed by the \e aNodeIndex() member.
+    Node aNode(int ix) const { return Parent::aNode(ix); }
+
+    /// \brief Returns the B-node with the given index.
+    ///
+    /// Returns the B-node with the given index. Because it is a
+    /// static size graph the node's of the graph can be indiced
+    /// by the range from 0 to \e bNodeNum()-1 and the index of
+    /// the node can accessed by the \e bNodeIndex() member.
+    Node bNode(int ix) const { return Parent::bNode(ix); }
+
+    /// \brief Returns the index of the A-node.
+    ///
+    /// Returns the index of the A-node. Because it is a
+    /// static size graph the node's of the graph can be indiced
+    /// by the range from 0 to \e aNodeNum()-1 and the index of
+    /// the node can accessed by the \e aNodeIndex() member.
+    int aNodeIndex(const Node& node) const { return Parent::aNodeIndex(node); }
+
+    /// \brief Returns the index of the B-node.
+    ///
+    /// Returns the index of the B-node. Because it is a
+    /// static size graph the node's of the graph can be indiced
+    /// by the range from 0 to \e bNodeNum()-1 and the index of
+    /// the node can accessed by the \e bNodeIndex() member.
+    int bNodeIndex(const Node& node) const { return Parent::bNodeIndex(node); }
+
+    /// \brief Returns the edge connects the given nodes.
+    ///
+    /// Returns the edge connects the given nodes.
+    Edge edge(const Node& u, const Node& v) const {
+      UEdge uedge = Parent::uEdge(u, v);
+      if (uedge != INVALID) {
+        return Parent::direct(uedge, Parent::aNode(u));
+      } else {
+        return INVALID;
+      }
+    }
+
+    /// \brief Returns the undirected edge connects the given nodes.
+    ///
+    /// Returns the undirected edge connects the given nodes.
+    UEdge uEdge(const Node& u, const Node& v) const {
+      return Parent::uEdge(u, v);
+    }
+  };
+
+} //namespace lemon
+
+
+#endif //LEMON_FULL_GRAPH_H
Index: lemon/goldberg_tarjan.h
===================================================================
--- lemon/goldberg_tarjan.h	(revision 2553)
+++ lemon/goldberg_tarjan.h	(revision 2553)
@@ -0,0 +1,1027 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_GOLDBERG_TARJAN_H
+#define LEMON_GOLDBERG_TARJAN_H
+
+#include <vector>
+#include <queue>
+
+#include <lemon/error.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/tolerance.h>
+#include <lemon/maps.h>
+#include <lemon/graph_utils.h>
+#include <lemon/dynamic_tree.h>
+#include <limits>
+
+/// \file
+/// \ingroup max_flow
+/// \brief Implementation of the preflow algorithm.
+
+namespace lemon {
+
+  /// \brief Default traits class of GoldbergTarjan class.
+  ///
+  /// Default traits class of GoldbergTarjan class.
+  /// \param _Graph Graph type.
+  /// \param _CapacityMap Type of capacity map.
+  template <typename _Graph, typename _CapacityMap>
+  struct GoldbergTarjanDefaultTraits {
+
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge capacities.
+    ///
+    /// The type of the map that stores the edge capacities.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _CapacityMap CapacityMap;
+
+    /// \brief The type of the length of the edges.
+    typedef typename CapacityMap::Value Value;
+
+    /// \brief The map type that stores the flow values.
+    ///
+    /// The map type that stores the flow values. 
+    /// It must meet the \ref concepts::ReadWriteMap "ReadWriteMap" concept.
+    typedef typename Graph::template EdgeMap<Value> FlowMap;
+
+    /// \brief Instantiates a FlowMap.
+    ///
+    /// This function instantiates a \ref FlowMap. 
+    /// \param graph The graph, to which we would like to define the flow map.
+    static FlowMap* createFlowMap(const Graph& graph) {
+      return new FlowMap(graph);
+    }
+
+    /// \brief The eleavator type used by GoldbergTarjan algorithm.
+    /// 
+    /// The elevator type used by GoldbergTarjan algorithm.
+    ///
+    /// \sa Elevator
+    /// \sa LinkedElevator
+    typedef LinkedElevator<Graph, typename Graph::Node> Elevator;
+    
+    /// \brief Instantiates an Elevator.
+    ///
+    /// This function instantiates a \ref Elevator. 
+    /// \param graph The graph, to which we would like to define the elevator.
+    /// \param max_level The maximum level of the elevator.
+    static Elevator* createElevator(const Graph& graph, int max_level) {
+      return new Elevator(graph, max_level);
+    }
+
+    /// \brief The tolerance used by the algorithm
+    ///
+    /// The tolerance used by the algorithm to handle inexact computation.
+    typedef Tolerance<Value> Tolerance;
+
+  };
+
+  /// \ingroup max_flow
+  /// \brief Goldberg-Tarjan algorithms class.
+  ///
+  /// This class provides an implementation of the \e GoldbergTarjan
+  /// \e algorithm producing a flow of maximum value in a directed
+  /// graph. The GoldbergTarjan algorithm is a theoretical improvement
+  /// of the Goldberg's \ref Preflow "preflow" algorithm by using the \ref
+  /// DynamicTree "dynamic tree" data structure of Sleator and Tarjan.
+  /// 
+  /// The original preflow algorithm with \e highest \e label
+  /// heuristic has \f$O(n^2\sqrt{e})\f$ or with \e FIFO heuristic has
+  /// \f$O(n^3)\f$ time complexity. The current algorithm improved
+  /// this complexity to \f$O(nm\log(\frac{n^2}{m}))\f$. The algorithm
+  /// builds limited size dynamic trees on the residual graph, which
+  /// can be used to make multilevel push operations and gives a
+  /// better bound on the number of non-saturating pushes.
+  ///
+  /// \param Graph The directed graph type the algorithm runs on.
+  /// \param CapacityMap The capacity map type.
+  /// \param _Traits Traits class to set various data types used by
+  /// the algorithm.  The default traits class is \ref
+  /// GoldbergTarjanDefaultTraits.  See \ref
+  /// GoldbergTarjanDefaultTraits for the documentation of a
+  /// Goldberg-Tarjan traits class.
+  ///
+  /// \author Tamas Hamori and Balazs Dezso
+#ifdef DOXYGEN
+  template <typename _Graph, typename _CapacityMap, typename _Traits> 
+#else
+  template <typename _Graph,
+	    typename _CapacityMap = typename _Graph::template EdgeMap<int>,
+            typename _Traits = 
+	    GoldbergTarjanDefaultTraits<_Graph, _CapacityMap> >
+#endif
+  class GoldbergTarjan {
+  public:
+
+    typedef _Traits Traits;
+    typedef typename Traits::Graph Graph;
+    typedef typename Traits::CapacityMap CapacityMap;
+    typedef typename Traits::Value Value; 
+
+    typedef typename Traits::FlowMap FlowMap;
+    typedef typename Traits::Elevator Elevator;
+    typedef typename Traits::Tolerance Tolerance;
+    
+  protected:
+
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename Graph::template NodeMap<Node> NodeNodeMap;
+    typedef typename Graph::template NodeMap<int> IntNodeMap;
+
+    typedef typename Graph::template NodeMap<Edge> EdgeNodeMap;
+    typedef typename Graph::template EdgeMap<Edge> EdgeEdgeMap;
+
+    typedef typename std::vector<Node> VecNode;
+ 
+    typedef DynamicTree<Value,IntNodeMap,Tolerance> DynTree;
+
+    const Graph& _graph;
+    const CapacityMap* _capacity;
+    int _node_num; //the number of nodes of G
+
+    Node _source;
+    Node _target;
+
+    FlowMap* _flow;
+    bool _local_flow;
+
+    Elevator* _level;
+    bool _local_level;
+
+    typedef typename Graph::template NodeMap<Value> ExcessMap;
+    ExcessMap* _excess;
+    
+    Tolerance _tolerance;
+
+    bool _phase;
+
+    // constant for treesize
+    static const double _tree_bound = 2;
+    int _max_tree_size;
+    
+    //tags for the dynamic tree
+    DynTree *_dt; 
+    //datastructure of dyanamic tree
+    IntNodeMap *_dt_index;
+    //datastrucure for solution of the communication between the two class
+    EdgeNodeMap *_dt_edges; 
+    //nodeMap for storing the outgoing edge from the node in the tree  
+
+    //max of the type Value
+    const Value _max_value;
+            
+  public:
+
+    typedef GoldbergTarjan Create;
+
+    ///\name Named template parameters
+
+    ///@{
+
+    template <typename _FlowMap>
+    struct DefFlowMapTraits : public Traits {
+      typedef _FlowMap FlowMap;
+      static FlowMap *createFlowMap(const Graph&) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// FlowMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting FlowMap
+    /// type
+    template <typename _FlowMap>
+    struct DefFlowMap 
+      : public GoldbergTarjan<Graph, CapacityMap, 
+			      DefFlowMapTraits<_FlowMap> > {
+      typedef GoldbergTarjan<Graph, CapacityMap, 
+			     DefFlowMapTraits<_FlowMap> > Create;
+    };
+
+    template <typename _Elevator>
+    struct DefElevatorTraits : public Traits {
+      typedef _Elevator Elevator;
+      static Elevator *createElevator(const Graph&, int) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// Elevator type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting Elevator
+    /// type
+    template <typename _Elevator>
+    struct DefElevator 
+      : public GoldbergTarjan<Graph, CapacityMap, 
+			      DefElevatorTraits<_Elevator> > {
+      typedef GoldbergTarjan<Graph, CapacityMap, 
+			     DefElevatorTraits<_Elevator> > Create;
+    };
+
+    template <typename _Elevator>
+    struct DefStandardElevatorTraits : public Traits {
+      typedef _Elevator Elevator;
+      static Elevator *createElevator(const Graph& graph, int max_level) {
+	return new Elevator(graph, max_level);
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// Elevator type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting Elevator
+    /// type. The Elevator should be standard constructor interface, ie.
+    /// the graph and the maximum level should be passed to it.
+    template <typename _Elevator>
+    struct DefStandardElevator 
+      : public GoldbergTarjan<Graph, CapacityMap, 
+			      DefStandardElevatorTraits<_Elevator> > {
+      typedef GoldbergTarjan<Graph, CapacityMap, 
+			     DefStandardElevatorTraits<_Elevator> > Create;
+    };    
+
+
+    ///\ref Exception for the case when s=t.
+
+    ///\ref Exception for the case when the source equals the target.
+    class InvalidArgument : public lemon::LogicError {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::GoldbergTarjan::InvalidArgument";
+      }
+    };
+
+  protected:
+    
+    GoldbergTarjan() {}
+
+  public:
+
+    /// \brief The constructor of the class.
+    ///
+    /// The constructor of the class. 
+    /// \param graph The directed graph the algorithm runs on. 
+    /// \param capacity The capacity of the edges. 
+    /// \param source The source node.
+    /// \param target The target node.
+    /// Except the graph, all of these parameters can be reset by
+    /// calling \ref source, \ref target, \ref capacityMap and \ref
+    /// flowMap, resp.
+    GoldbergTarjan(const Graph& graph, const CapacityMap& capacity,
+		   Node source, Node target) 
+      : _graph(graph), _capacity(&capacity), 
+	_node_num(), _source(source), _target(target),
+	_flow(0), _local_flow(false),
+	_level(0), _local_level(false),
+	_excess(0), _tolerance(), 
+	_phase(), _max_tree_size(),
+	_dt(0), _dt_index(0), _dt_edges(0), 
+	_max_value(std::numeric_limits<Value>::max()) { 
+      if (_source == _target) throw InvalidArgument();
+    }
+
+    /// \brief Destrcutor.
+    ///
+    /// Destructor.
+    ~GoldbergTarjan() {
+      destroyStructures();
+    }
+    
+    /// \brief Sets the capacity map.
+    ///
+    /// Sets the capacity map.
+    /// \return \c (*this)
+    GoldbergTarjan& capacityMap(const CapacityMap& map) {
+      _capacity = &map;
+      return *this;
+    }
+
+    /// \brief Sets the flow map.
+    ///
+    /// Sets the flow map.
+    /// \return \c (*this)
+    GoldbergTarjan& flowMap(FlowMap& map) {
+      if (_local_flow) {
+	delete _flow;
+	_local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Returns the flow map.
+    ///
+    /// \return The flow map.
+    const FlowMap& flowMap() {
+      return *_flow;
+    }
+
+    /// \brief Sets the elevator.
+    ///
+    /// Sets the elevator.
+    /// \return \c (*this)
+    GoldbergTarjan& elevator(Elevator& elevator) {
+      if (_local_level) {
+	delete _level;
+	_local_level = false;
+      }
+      _level = &elevator;
+      return *this;
+    }
+
+    /// \brief Returns the elevator.
+    ///
+    /// \return The elevator.
+    const Elevator& elevator() {
+      return *_level;
+    }
+
+    /// \brief Sets the source node.
+    ///
+    /// Sets the source node.
+    /// \return \c (*this)
+    GoldbergTarjan& source(const Node& node) {
+      _source = node;
+      return *this;
+    }
+
+    /// \brief Sets the target node.
+    ///
+    /// Sets the target node.
+    /// \return \c (*this)
+    GoldbergTarjan& target(const Node& node) {
+      _target = node;
+      return *this;
+    }
+ 
+    /// \brief Sets the tolerance used by algorithm.
+    ///
+    /// Sets the tolerance used by algorithm.
+    GoldbergTarjan& tolerance(const Tolerance& tolerance) const {
+      _tolerance = tolerance;
+      if (_dt) {
+	_dt->tolerance(_tolerance);
+      }
+      return *this;
+    } 
+
+    /// \brief Returns the tolerance used by algorithm.
+    ///
+    /// Returns the tolerance used by algorithm.
+    const Tolerance& tolerance() const {
+      return tolerance;
+    } 
+
+         
+  private:
+    
+    void createStructures() {
+      _node_num = countNodes(_graph);
+
+      _max_tree_size = int((double(_node_num) * double(_node_num)) / 
+			   double(countEdges(_graph)));
+
+      if (!_flow) {
+	_flow = Traits::createFlowMap(_graph);
+	_local_flow = true;
+      }
+      if (!_level) {
+	_level = Traits::createElevator(_graph, _node_num);
+	_local_level = true;
+      }
+      if (!_excess) {
+	_excess = new ExcessMap(_graph);
+      }
+      if (!_dt_index && !_dt) {
+	_dt_index = new IntNodeMap(_graph);
+	_dt = new DynTree(*_dt_index, _tolerance);
+      }
+      if (!_dt_edges) {
+	_dt_edges = new EdgeNodeMap(_graph);
+      }
+    }
+
+    void destroyStructures() {
+      if (_local_flow) {
+	delete _flow;
+      }
+      if (_local_level) {
+	delete _level;
+      }
+      if (_excess) {
+	delete _excess;
+      }
+      if (_dt) {
+	delete _dt;
+      }
+      if (_dt_index) {
+	delete _dt_index;
+      }
+      if (_dt_edges) {
+	delete _dt_edges;
+      }
+    }
+
+    bool sendOut(Node n, Value& excess) {
+
+      Node w = _dt->findRoot(n);
+      
+      while (w != n) {
+      
+	Value rem;      
+	Node u = _dt->findCost(n, rem);
+
+        if (_tolerance.positive(rem) && !_level->active(w) && w != _target) {
+	  _level->activate(w);
+        }
+
+        if (!_tolerance.less(rem, excess)) {
+	  _dt->addCost(n, - excess);
+	  _excess->set(w, (*_excess)[w] + excess);
+	  excess = 0;
+	  return true;
+	}
+	
+	
+        _dt->addCost(n, - rem);
+
+        excess -= rem;
+        _excess->set(w, (*_excess)[w] + rem);
+        
+	_dt->cut(u);
+	_dt->addCost(u, _max_value);
+	  
+	Edge e = (*_dt_edges)[u];
+	_dt_edges->set(u, INVALID);
+        
+	if (u == _graph.source(e)) {
+	  _flow->set(e, (*_capacity)[e]);
+	} else {
+	  _flow->set(e, 0);
+	}           
+
+        w = _dt->findRoot(n);
+      }      
+      return false;
+    }
+
+    bool sendIn(Node n, Value& excess) {
+
+      Node w = _dt->findRoot(n);
+      
+      while (w != n) {
+      
+	Value rem;      
+	Node u = _dt->findCost(n, rem);
+
+        if (_tolerance.positive(rem) && !_level->active(w) && w != _source) {
+	  _level->activate(w);
+        }
+
+        if (!_tolerance.less(rem, excess)) {
+	  _dt->addCost(n, - excess);
+	  _excess->set(w, (*_excess)[w] + excess);
+	  excess = 0;
+	  return true;
+	}
+	
+	
+        _dt->addCost(n, - rem);
+
+        excess -= rem;
+        _excess->set(w, (*_excess)[w] + rem);
+        
+	_dt->cut(u);
+	_dt->addCost(u, _max_value);
+	  
+	Edge e = (*_dt_edges)[u];
+	_dt_edges->set(u, INVALID);
+        
+	if (u == _graph.source(e)) {
+	  _flow->set(e, (*_capacity)[e]);
+	} else {
+	  _flow->set(e, 0);
+	}           
+
+        w = _dt->findRoot(n);
+      }      
+      return false;
+    }
+
+    void cutChildren(Node n) {
+    
+      for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+        
+        Node v = _graph.target(e);
+        
+        if ((*_dt_edges)[v] != INVALID && (*_dt_edges)[v] == e) {
+          _dt->cut(v);
+          _dt_edges->set(v, INVALID);
+	  Value rem;
+          _dt->findCost(v, rem);
+          _dt->addCost(v, - rem);
+          _dt->addCost(v, _max_value);
+          _flow->set(e, rem);
+
+        }      
+      }
+
+      for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+        
+        Node v = _graph.source(e);
+        
+        if ((*_dt_edges)[v] != INVALID && (*_dt_edges)[v] == e) {
+          _dt->cut(v);
+          _dt_edges->set(v, INVALID);
+	  Value rem;
+          _dt->findCost(v, rem);
+          _dt->addCost(v, - rem);
+          _dt->addCost(v, _max_value);
+          _flow->set(e, (*_capacity)[e] - rem);
+
+        }      
+      }
+    }
+
+    void extractTrees() {
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	
+	Node w = _dt->findRoot(n);
+      
+	while (w != n) {
+      
+	  Value rem;      
+	  Node u = _dt->findCost(n, rem);
+
+	  _dt->cut(u);
+	  _dt->addCost(u, - rem);
+	  _dt->addCost(u, _max_value);
+	  
+	  Edge e = (*_dt_edges)[u];
+	  _dt_edges->set(u, INVALID);
+	  
+	  if (u == _graph.source(e)) {
+	    _flow->set(e, (*_capacity)[e] - rem);
+	  } else {
+	    _flow->set(e, rem);
+	  }
+	  
+	  w = _dt->findRoot(n);
+	}      
+      }
+    }
+
+  public:    
+
+    /// \name Execution control The simplest way to execute the
+    /// algorithm is to use one of the member functions called \c
+    /// run().  
+    /// \n
+    /// If you need more control on initial solution or
+    /// execution then you have to call one \ref init() function and then
+    /// the startFirstPhase() and if you need the startSecondPhase().  
+    
+    ///@{
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    ///
+    void init() {
+      createStructures();
+
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	_excess->set(n, 0);
+      }
+
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+	_flow->set(e, 0);
+      }
+
+      _dt->clear();
+      for (NodeIt v(_graph); v != INVALID; ++v) {
+        (*_dt_edges)[v] = INVALID;
+        _dt->makeTree(v);
+        _dt->addCost(v, _max_value);
+      }
+
+      typename Graph::template NodeMap<bool> reached(_graph, false);
+
+      _level->initStart();
+      _level->initAddItem(_target);
+
+      std::vector<Node> queue;
+      reached.set(_source, true);
+
+      queue.push_back(_target);
+      reached.set(_target, true);
+      while (!queue.empty()) {
+	_level->initNewLevel();
+	std::vector<Node> nqueue;
+	for (int i = 0; i < int(queue.size()); ++i) {
+	  Node n = queue[i];
+	  for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node u = _graph.source(e);
+	    if (!reached[u] && _tolerance.positive((*_capacity)[e])) {
+	      reached.set(u, true);
+	      _level->initAddItem(u);
+	      nqueue.push_back(u);
+	    }
+	  }
+	}
+	queue.swap(nqueue);
+      }
+      _level->initFinish();
+
+      for (OutEdgeIt e(_graph, _source); e != INVALID; ++e) {
+	if (_tolerance.positive((*_capacity)[e])) {
+	  Node u = _graph.target(e);
+	  if ((*_level)[u] == _level->maxLevel()) continue;
+	  _flow->set(e, (*_capacity)[e]);
+	  _excess->set(u, (*_excess)[u] + (*_capacity)[e]);
+	  if (u != _target && !_level->active(u)) {
+	    _level->activate(u);
+	  }
+	}
+      }
+    }
+
+    /// \brief Starts the first phase of the preflow algorithm.
+    ///
+    /// The preflow algorithm consists of two phases, this method runs
+    /// the first phase. After the first phase the maximum flow value
+    /// and a minimum value cut can already be computed, although a
+    /// maximum flow is not yet obtained. So after calling this method
+    /// \ref flowValue() returns the value of a maximum flow and \ref
+    /// minCut() returns a minimum cut.     
+    /// \pre One of the \ref init() functions should be called. 
+    void startFirstPhase() {
+      _phase = true;
+      Node n;
+
+      while ((n = _level->highestActive()) != INVALID) {
+	Value excess = (*_excess)[n];
+	int level = _level->highestActiveLevel();
+	int new_level = _level->maxLevel();
+
+	if (_dt->findRoot(n) != n) {
+	  if (sendOut(n, excess)) goto no_more_push;
+	}
+	
+	for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Value rem = (*_capacity)[e] - (*_flow)[e];
+	  Node v = _graph.target(e);
+	  
+	  if (!_tolerance.positive(rem) && (*_dt_edges)[v] != e) continue;
+
+	  if ((*_level)[v] < level) {
+	    
+	    if (_dt->findSize(n) + _dt->findSize(v) < 
+		_tree_bound * _max_tree_size) {
+	      _dt->addCost(n, -_max_value);
+	      _dt->addCost(n, rem);
+	      _dt->link(n, v);
+	      _dt_edges->set(n, e);
+	      if (sendOut(n, excess)) goto no_more_push;
+	    } else {
+	      if (!_level->active(v) && v != _target) {
+		_level->activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] + excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;		  
+		goto no_more_push;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, (*_capacity)[e]);
+	      }		
+	    }
+	  } else if (new_level > (*_level)[v]) {
+	    new_level = (*_level)[v];
+	  }
+	}
+
+	for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Value rem = (*_flow)[e];
+	  Node v = _graph.source(e);
+	  if (!_tolerance.positive(rem) && (*_dt_edges)[v] != e) continue;
+
+	  if ((*_level)[v] < level) {
+	    
+	    if (_dt->findSize(n) + _dt->findSize(v) < 
+		_tree_bound * _max_tree_size) {
+	      _dt->addCost(n, - _max_value);
+	      _dt->addCost(n, rem);
+	      _dt->link(n, v);
+	      _dt_edges->set(n, e);
+	      if (sendOut(n, excess)) goto no_more_push;
+	    } else {
+	      if (!_level->active(v) && v != _target) {
+		_level->activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] - excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;		  
+		goto no_more_push;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, 0);
+	      }		
+	    }
+	  } else if (new_level > (*_level)[v]) {
+	    new_level = (*_level)[v];
+	  }
+	}
+		
+      no_more_push:
+
+	_excess->set(n, excess);
+	
+	if (excess != 0) {
+	  cutChildren(n);
+	  if (new_level + 1 < _level->maxLevel()) {
+	    _level->liftHighestActive(new_level + 1);
+	  } else {
+	    _level->liftHighestActiveToTop();
+	  }
+	  if (_level->emptyLevel(level)) {
+	    _level->liftToTop(level);
+	  }
+	} else {
+	  _level->deactivate(n);
+	}	
+      }
+      extractTrees();
+    }
+
+    /// \brief Starts the second phase of the preflow algorithm.
+    ///
+    /// The preflow algorithm consists of two phases, this method runs
+    /// the second phase. After calling \ref init() and \ref
+    /// startFirstPhase() and then \ref startSecondPhase(), \ref
+    /// flowMap() return a maximum flow, \ref flowValue() returns the
+    /// value of a maximum flow, \ref minCut() returns a minimum cut
+    /// \pre The \ref init() and startFirstPhase() functions should be
+    /// called before.
+    void startSecondPhase() {
+      _phase = false;
+      
+      typename Graph::template NodeMap<bool> reached(_graph, false);
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	reached.set(n, (*_level)[n] < _level->maxLevel());
+      }
+
+      _level->initStart();
+      _level->initAddItem(_source);
+ 
+      std::vector<Node> queue;
+      queue.push_back(_source);
+      reached.set(_source, true);
+
+      while (!queue.empty()) {
+	_level->initNewLevel();
+	std::vector<Node> nqueue;
+	for (int i = 0; i < int(queue.size()); ++i) {
+	  Node n = queue[i];
+	  for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node v = _graph.target(e);
+	    if (!reached[v] && _tolerance.positive((*_flow)[e])) {
+	      reached.set(v, true);
+	      _level->initAddItem(v);
+	      nqueue.push_back(v);
+	    }
+	  }
+	  for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node u = _graph.source(e);
+	    if (!reached[u] && 
+		_tolerance.positive((*_capacity)[e] - (*_flow)[e])) {
+	      reached.set(u, true);
+	      _level->initAddItem(u);
+	      nqueue.push_back(u);
+	    }
+	  }
+	}
+	queue.swap(nqueue);
+      }
+      _level->initFinish();
+
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	if (!reached[n]) {
+	  _level->markToBottom(n);
+	} else if ((*_excess)[n] > 0 && _target != n) {
+	  _level->activate(n);
+	}
+      }
+
+      Node n;
+
+      while ((n = _level->highestActive()) != INVALID) {
+	Value excess = (*_excess)[n];
+	int level = _level->highestActiveLevel();
+	int new_level = _level->maxLevel();
+
+	if (_dt->findRoot(n) != n) {
+	  if (sendIn(n, excess)) goto no_more_push;
+	}
+	
+	for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Value rem = (*_capacity)[e] - (*_flow)[e];
+	  Node v = _graph.target(e);
+	  
+	  if (!_tolerance.positive(rem) && (*_dt_edges)[v] != e) continue;
+
+	  if ((*_level)[v] < level) {
+	    
+	    if (_dt->findSize(n) + _dt->findSize(v) < 
+		_tree_bound * _max_tree_size) {
+	      _dt->addCost(n, -_max_value);
+	      _dt->addCost(n, rem);
+	      _dt->link(n, v);
+	      _dt_edges->set(n, e);
+	      if (sendIn(n, excess)) goto no_more_push;
+	    } else {
+	      if (!_level->active(v) && v != _source) {
+		_level->activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] + excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;		  
+		goto no_more_push;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, (*_capacity)[e]);
+	      }		
+	    }
+	  } else if (new_level > (*_level)[v]) {
+	    new_level = (*_level)[v];
+	  }
+	}
+
+	for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Value rem = (*_flow)[e];
+	  Node v = _graph.source(e);
+	  if (!_tolerance.positive(rem) && (*_dt_edges)[v] != e) continue;
+
+	  if ((*_level)[v] < level) {
+	    
+	    if (_dt->findSize(n) + _dt->findSize(v) < 
+		_tree_bound * _max_tree_size) {
+	      _dt->addCost(n, - _max_value);
+	      _dt->addCost(n, rem);
+	      _dt->link(n, v);
+	      _dt_edges->set(n, e);
+	      if (sendIn(n, excess)) goto no_more_push;
+	    } else {
+	      if (!_level->active(v) && v != _source) {
+		_level->activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] - excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;		  
+		goto no_more_push;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, 0);
+	      }		
+	    }
+	  } else if (new_level > (*_level)[v]) {
+	    new_level = (*_level)[v];
+	  }
+	}
+		
+      no_more_push:
+
+	_excess->set(n, excess);
+	
+	if (excess != 0) {
+	  cutChildren(n);
+	  if (new_level + 1 < _level->maxLevel()) {
+	    _level->liftHighestActive(new_level + 1);
+	  } else {
+	    _level->liftHighestActiveToTop();
+	  }
+	  if (_level->emptyLevel(level)) {
+	    _level->liftToTop(level);
+	  }
+	} else {
+	  _level->deactivate(n);
+	}	
+      }
+      extractTrees();
+    }
+
+    /// \brief Runs the Goldberg-Tarjan algorithm.  
+    ///
+    /// Runs the Goldberg-Tarjan algorithm.
+    /// \note pf.run() is just a shortcut of the following code.
+    /// \code
+    ///   pf.init();
+    ///   pf.startFirstPhase();
+    ///   pf.startSecondPhase();
+    /// \endcode
+    void run() {
+      init();
+      startFirstPhase();
+      startSecondPhase();
+    }
+
+    /// \brief Runs the Goldberg-Tarjan algorithm to compute the minimum cut.  
+    ///
+    /// Runs the Goldberg-Tarjan algorithm to compute the minimum cut.
+    /// \note pf.runMinCut() is just a shortcut of the following code.
+    /// \code
+    ///   pf.init();
+    ///   pf.startFirstPhase();
+    /// \endcode
+    void runMinCut() {
+      init();
+      startFirstPhase();
+    }
+
+    /// @}
+
+    /// \name Query Functions 
+    /// The result of the Goldberg-Tarjan algorithm can be obtained
+    /// using these functions.
+    /// \n
+    /// Before the use of these functions, either run() or start() must
+    /// be called.
+    
+    ///@{
+
+    /// \brief Returns the value of the maximum flow.
+    ///
+    /// Returns the value of the maximum flow by returning the excess
+    /// of the target node \c t. This value equals to the value of
+    /// the maximum flow already after the first phase.
+    Value flowValue() const {
+      return (*_excess)[_target];
+    }
+
+    /// \brief Returns true when the node is on the source side of minimum cut.
+    ///
+    /// Returns true when the node is on the source side of minimum
+    /// cut. This method can be called both after running \ref
+    /// startFirstPhase() and \ref startSecondPhase().
+    bool minCut(const Node& node) const {
+      return ((*_level)[node] == _level->maxLevel()) == _phase;
+    }
+ 
+    /// \brief Returns a minimum value cut.
+    ///
+    /// Sets the \c cutMap to the characteristic vector of a minimum value
+    /// cut. This method can be called both after running \ref
+    /// startFirstPhase() and \ref startSecondPhase(). The result after second
+    /// phase could be changed slightly if inexact computation is used.
+    /// \pre The \c cutMap should be a bool-valued node-map.
+    template <typename CutMap>
+    void minCutMap(CutMap& cutMap) const {
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	cutMap.set(n, minCut(n));
+      }
+    }
+
+    /// \brief Returns the flow on the edge.
+    ///
+    /// Sets the \c flowMap to the flow on the edges. This method can
+    /// be called after the second phase of algorithm.
+    Value flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// @}
+
+  }; 
+  
+} //namespace lemon
+
+#endif
Index: lemon/gomory_hu_tree.h
===================================================================
--- lemon/gomory_hu_tree.h	(revision 2553)
+++ lemon/gomory_hu_tree.h	(revision 2553)
@@ -0,0 +1,296 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_GOMORY_HU_TREE_H
+#define LEMON_GOMORY_HU_TREE_H
+
+#include <lemon/preflow.h>
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+
+/// \ingroup min_cut
+/// \file 
+/// \brief Gomory-Hu cut tree in undirected graphs.
+
+namespace lemon {
+
+  /// \ingroup min_cut
+  ///
+  /// \brief Gomory-Hu cut tree algorithm
+  ///
+  /// The Gomory-Hu tree is a tree on the nodeset of the graph, but it
+  /// may contain edges which are not in the original graph. It helps
+  /// to calculate the minimum cut between all pairs of nodes, because
+  /// the minimum capacity edge on the tree path between two nodes has
+  /// the same weight as the minimum cut in the graph between these
+  /// nodes. Moreover this edge separates the nodes to two parts which
+  /// determine this minimum cut.
+  /// 
+  /// The algorithm calculates \e n-1 distinict minimum cuts with
+  /// preflow algorithm, therefore the algorithm has
+  /// \f$(O(n^3\sqrt{e})\f$ overall time complexity. It calculates a
+  /// rooted Gomory-Hu tree, the structure of the tree and the weights
+  /// can be obtained with \c predNode() and \c predValue()
+  /// functions. The \c minCutValue() and \c minCutMap() calculates
+  /// the minimum cut and the minimum cut value between any two node
+  /// in the graph.
+  template <typename _UGraph, 
+	    typename _Capacity = typename _UGraph::template UEdgeMap<int> >
+  class GomoryHuTree {
+  public:
+
+    /// The undirected graph type
+    typedef _UGraph UGraph;
+    /// The capacity on undirected edges
+    typedef _Capacity Capacity;
+    /// The value type of capacities
+    typedef typename Capacity::Value Value;
+    
+  private:
+
+    UGRAPH_TYPEDEFS(typename UGraph);
+
+    const UGraph& _ugraph;
+    const Capacity& _capacity;
+
+    Node _root;
+    typename UGraph::template NodeMap<Node>* _pred;
+    typename UGraph::template NodeMap<Value>* _weight;
+    typename UGraph::template NodeMap<int>* _order;
+
+    void createStructures() {
+      if (!_pred) {
+	_pred = new typename UGraph::template NodeMap<Node>(_ugraph);
+      }
+      if (!_weight) {
+	_weight = new typename UGraph::template NodeMap<Value>(_ugraph);
+      }
+      if (!_order) {
+	_order = new typename UGraph::template NodeMap<int>(_ugraph);
+      }
+    }
+
+    void destroyStructures() {
+      if (_pred) {
+	delete _pred;
+      }
+      if (_weight) {
+	delete _weight;
+      }
+      if (_order) {
+	delete _order;
+      }
+    }
+  
+  public:
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    /// \param ugraph The undirected graph type.
+    /// \param capacity The capacity map.
+    GomoryHuTree(const UGraph& ugraph, const Capacity& capacity) 
+      : _ugraph(ugraph), _capacity(capacity),
+	_pred(0), _weight(0), _order(0) 
+    {
+      checkConcept<concepts::ReadMap<UEdge, Value>, Capacity>();
+    }
+
+
+    /// \brief Destructor
+    ///
+    /// Destructor
+    ~GomoryHuTree() {
+      destroyStructures();
+    }
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    ///
+    void init() {
+      createStructures();
+
+      _root = NodeIt(_ugraph);
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	_pred->set(n, _root);
+	_order->set(n, -1);
+      }
+      _pred->set(_root, INVALID);
+      _weight->set(_root, std::numeric_limits<Value>::max()); 
+    }
+
+
+    /// \brief Starts the algorithm
+    ///
+    /// Starts the algorithm.
+    void start() {
+      Preflow<UGraph, Capacity> fa(_ugraph, _capacity, _root, INVALID);
+
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	if (n == _root) continue;
+
+	Node pn = (*_pred)[n];
+	fa.source(n);
+	fa.target(pn);
+
+	fa.runMinCut();
+
+	_weight->set(n, fa.flowValue());
+
+	for (NodeIt nn(_ugraph); nn != INVALID; ++nn) {
+	  if (nn != n && fa.minCut(nn) && (*_pred)[nn] == pn) {
+	    _pred->set(nn, n);
+	  }
+	}
+	if ((*_pred)[pn] != INVALID && fa.minCut((*_pred)[pn])) {
+	  _pred->set(n, (*_pred)[pn]);
+	  _pred->set(pn, n);
+	  _weight->set(n, (*_weight)[pn]);
+	  _weight->set(pn, fa.flowValue());	
+	}
+      }
+
+      _order->set(_root, 0);
+      int index = 1;
+
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	std::vector<Node> st;
+	Node nn = n;
+	while ((*_order)[nn] == -1) {
+	  st.push_back(nn);
+	  nn = (*_pred)[nn];
+	}
+	while (!st.empty()) {
+	  _order->set(st.back(), index++);
+	  st.pop_back();
+	}
+      }
+    }
+
+    /// \brief Runs the Gomory-Hu algorithm.  
+    ///
+    /// Runs the Gomory-Hu algorithm.
+    /// \note gh.run() is just a shortcut of the following code.
+    /// \code
+    ///   ght.init();
+    ///   ght.start();
+    /// \endcode
+    void run() {
+      init();
+      start();
+    }
+
+    /// \brief Returns the predecessor node in the Gomory-Hu tree.
+    ///
+    /// Returns the predecessor node in the Gomory-Hu tree. If the node is
+    /// the root of the Gomory-Hu tree, then it returns \c INVALID.
+    Node predNode(const Node& node) {
+      return (*_pred)[node];
+    }
+
+    /// \brief Returns the weight of the predecessor edge in the
+    /// Gomory-Hu tree.
+    ///
+    /// Returns the weight of the predecessor edge in the Gomory-Hu
+    /// tree.  If the node is the root of the Gomory-Hu tree, the
+    /// result is undefined.
+    Value predValue(const Node& node) {
+      return (*_weight)[node];
+    }
+
+    /// \brief Returns the minimum cut value between two nodes
+    ///
+    /// Returns the minimum cut value between two nodes. The
+    /// algorithm finds the nearest common ancestor in the Gomory-Hu
+    /// tree and calculates the minimum weight edge on the paths to
+    /// the ancestor.
+    Value minCutValue(const Node& s, const Node& t) const {
+      Node sn = s, tn = t;
+      Value value = std::numeric_limits<Value>::max();
+      
+      while (sn != tn) {
+	if ((*_order)[sn] < (*_order)[tn]) {
+	  if ((*_weight)[tn] < value) value = (*_weight)[tn];
+	  tn = (*_pred)[tn];
+	} else {
+	  if ((*_weight)[sn] < value) value = (*_weight)[sn];
+	  sn = (*_pred)[sn];
+	}
+      }
+      return value;
+    }
+
+    /// \brief Returns the minimum cut between two nodes
+    ///
+    /// Returns the minimum cut value between two nodes. The
+    /// algorithm finds the nearest common ancestor in the Gomory-Hu
+    /// tree and calculates the minimum weight edge on the paths to
+    /// the ancestor. Then it sets all nodes to the cut determined by
+    /// this edge. The \c cutMap should be \ref concepts::ReadWriteMap
+    /// "ReadWriteMap".
+    template <typename CutMap>
+    Value minCutMap(const Node& s, const Node& t, CutMap& cutMap) const {
+      Node sn = s, tn = t;
+
+      Node rn = INVALID;
+      Value value = std::numeric_limits<Value>::max();
+      
+      while (sn != tn) {
+	if ((*_order)[sn] < (*_order)[tn]) {
+	  if ((*_weight)[tn] < value) {
+	    rn = tn;
+	    value = (*_weight)[tn];
+	  }
+	  tn = (*_pred)[tn];
+	} else {
+	  if ((*_weight)[sn] < value) {
+	    rn = sn;
+	    value = (*_weight)[sn];
+	  }
+	  sn = (*_pred)[sn];
+	}
+      }
+
+      typename UGraph::template NodeMap<bool> reached(_ugraph, false);
+      reached.set(_root, true);
+      cutMap.set(_root, false);
+      reached.set(rn, true);
+      cutMap.set(rn, true);
+
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	std::vector<Node> st;
+	Node nn = n;
+	while (!reached[nn]) {
+	  st.push_back(nn);
+	  nn = (*_pred)[nn];
+	}
+	while (!st.empty()) {
+	  cutMap.set(st.back(), cutMap[nn]);
+	  st.pop_back();
+	}
+      }
+      
+      return value;
+    }
+
+  };
+
+}
+
+#endif
Index: lemon/graph_adaptor.h
===================================================================
--- lemon/graph_adaptor.h	(revision 2617)
+++ lemon/graph_adaptor.h	(revision 2617)
@@ -0,0 +1,2720 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_GRAPH_ADAPTOR_H
+#define LEMON_GRAPH_ADAPTOR_H
+
+///\ingroup graph_adaptors
+///\file
+///\brief Several graph adaptors.
+///
+///This file contains several useful graph adaptor functions.
+///
+///\author Marton Makai and Balazs Dezso
+
+#include <lemon/bits/invalid.h>
+#include <lemon/bits/variant.h>
+#include <lemon/maps.h>
+
+#include <lemon/bits/base_extender.h>
+#include <lemon/bits/graph_adaptor_extender.h>
+#include <lemon/bits/graph_extender.h>
+#include <lemon/tolerance.h>
+
+#include <algorithm>
+
+namespace lemon {
+
+  ///\brief Base type for the Graph Adaptors
+  ///
+  ///Base type for the Graph Adaptors
+  ///
+  ///This is the base type for most of LEMON graph adaptors. 
+  ///This class implements a trivial graph adaptor i.e. it only wraps the 
+  ///functions and types of the graph. The purpose of this class is to 
+  ///make easier implementing graph adaptors. E.g. if an adaptor is 
+  ///considered which differs from the wrapped graph only in some of its 
+  ///functions or types, then it can be derived from GraphAdaptor,
+  ///and only the 
+  ///differences should be implemented.
+  ///
+  ///author Marton Makai 
+  template<typename _Graph>
+  class GraphAdaptorBase {
+  public:
+    typedef _Graph Graph;
+    typedef GraphAdaptorBase Adaptor;
+    typedef Graph ParentGraph;
+
+  protected:
+    Graph* graph;
+    GraphAdaptorBase() : graph(0) { }
+    void setGraph(Graph& _graph) { graph=&_graph; }
+
+  public:
+    GraphAdaptorBase(Graph& _graph) : graph(&_graph) { }
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+   
+    void first(Node& i) const { graph->first(i); }
+    void first(Edge& i) const { graph->first(i); }
+    void firstIn(Edge& i, const Node& n) const { graph->firstIn(i, n); }
+    void firstOut(Edge& i, const Node& n ) const { graph->firstOut(i, n); }
+
+    void next(Node& i) const { graph->next(i); }
+    void next(Edge& i) const { graph->next(i); }
+    void nextIn(Edge& i) const { graph->nextIn(i); }
+    void nextOut(Edge& i) const { graph->nextOut(i); }
+
+    Node source(const Edge& e) const { return graph->source(e); }
+    Node target(const Edge& e) const { return graph->target(e); }
+
+    typedef NodeNumTagIndicator<Graph> NodeNumTag;
+    int nodeNum() const { return graph->nodeNum(); }
+    
+    typedef EdgeNumTagIndicator<Graph> EdgeNumTag;
+    int edgeNum() const { return graph->edgeNum(); }
+
+    typedef FindEdgeTagIndicator<Graph> FindEdgeTag;
+    Edge findEdge(const Node& u, const Node& v, 
+		  const Edge& prev = INVALID) {
+      return graph->findEdge(u, v, prev);
+    }
+  
+    Node addNode() const { 
+      return Node(graph->addNode()); 
+    }
+
+    Edge addEdge(const Node& u, const Node& v) const { 
+      return Edge(graph->addEdge(u, v)); 
+    }
+
+    void erase(const Node& i) const { graph->erase(i); }
+    void erase(const Edge& i) const { graph->erase(i); }
+  
+    void clear() const { graph->clear(); }
+    
+    int id(const Node& v) const { return graph->id(v); }
+    int id(const Edge& e) const { return graph->id(e); }
+
+    Node nodeFromId(int ix) const {
+      return graph->nodeFromId(ix);
+    }
+
+    Edge edgeFromId(int ix) const {
+      return graph->edgeFromId(ix);
+    }
+
+    int maxNodeId() const {
+      return graph->maxNodeId();
+    }
+
+    int maxEdgeId() const {
+      return graph->maxEdgeId();
+    }
+
+    typedef typename ItemSetTraits<Graph, Node>::ItemNotifier NodeNotifier;
+
+    NodeNotifier& notifier(Node) const {
+      return graph->notifier(Node());
+    } 
+
+    typedef typename ItemSetTraits<Graph, Edge>::ItemNotifier EdgeNotifier;
+
+    EdgeNotifier& notifier(Edge) const {
+      return graph->notifier(Edge());
+    } 
+    
+    template <typename _Value>
+    class NodeMap : public Graph::template NodeMap<_Value> {
+    public:
+
+      typedef typename Graph::template NodeMap<_Value> Parent;
+
+      explicit NodeMap(const Adaptor& ga) 
+	: Parent(*ga.graph) {}
+
+      NodeMap(const Adaptor& ga, const _Value& value)
+	: Parent(*ga.graph, value) { }
+
+      NodeMap& operator=(const NodeMap& cmap) {
+        return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+      
+    };
+
+    template <typename _Value>
+    class EdgeMap : public Graph::template EdgeMap<_Value> {
+    public:
+      
+      typedef typename Graph::template EdgeMap<_Value> Parent;
+      
+      explicit EdgeMap(const Adaptor& ga) 
+	: Parent(*ga.graph) {}
+
+      EdgeMap(const Adaptor& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      EdgeMap& operator=(const EdgeMap& cmap) {
+        return operator=<EdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+
+    };
+
+  };
+
+  ///\ingroup graph_adaptors
+  ///
+  ///\brief Trivial Graph Adaptor
+  /// 
+  /// This class is an adaptor which does not change the adapted graph.
+  /// It can be used only to test the graph adaptors.
+  template <typename _Graph>
+  class GraphAdaptor :
+    public GraphAdaptorExtender<GraphAdaptorBase<_Graph> > { 
+  public:
+    typedef _Graph Graph;
+    typedef GraphAdaptorExtender<GraphAdaptorBase<_Graph> > Parent;
+  protected:
+    GraphAdaptor() : Parent() { }
+
+  public:
+    explicit GraphAdaptor(Graph& _graph) { setGraph(_graph); }
+  };
+
+  /// \brief Just gives back a graph adaptor
+  ///
+  /// Just gives back a graph adaptor which 
+  /// should be provide original graph
+  template<typename Graph>
+  GraphAdaptor<const Graph>
+  graphAdaptor(const Graph& graph) {
+    return GraphAdaptor<const Graph>(graph);
+  }
+
+
+  template <typename _Graph>
+  class RevGraphAdaptorBase : public GraphAdaptorBase<_Graph> {
+  public:
+    typedef _Graph Graph;
+    typedef GraphAdaptorBase<_Graph> Parent;
+  protected:
+    RevGraphAdaptorBase() : Parent() { }
+  public:
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+    void firstIn(Edge& i, const Node& n) const { Parent::firstOut(i, n); }
+    void firstOut(Edge& i, const Node& n ) const { Parent::firstIn(i, n); }
+
+    void nextIn(Edge& i) const { Parent::nextOut(i); }
+    void nextOut(Edge& i) const { Parent::nextIn(i); }
+
+    Node source(const Edge& e) const { return Parent::target(e); }
+    Node target(const Edge& e) const { return Parent::source(e); }
+
+    typedef FindEdgeTagIndicator<Graph> FindEdgeTag;
+    Edge findEdge(const Node& u, const Node& v, 
+		  const Edge& prev = INVALID) {
+      return Parent::findEdge(v, u, prev);
+    }
+
+  };
+    
+
+  ///\ingroup graph_adaptors
+  ///
+  ///\brief A graph adaptor which reverses the orientation of the edges.
+  ///
+  /// If \c g is defined as
+  ///\code
+  /// ListGraph g;
+  ///\endcode
+  /// then
+  ///\code
+  /// RevGraphAdaptor<ListGraph> ga(g);
+  ///\endcode
+  /// implements the graph obtained from \c g by 
+  /// reversing the orientation of its edges.
+  ///
+  /// A good example of using RevGraphAdaptor is to decide that the
+  /// directed graph is wheter strongly connected or not. If from one
+  /// node each node is reachable and from each node is reachable this
+  /// node then and just then the graph is strongly connected. Instead of
+  /// this condition we use a little bit different. From one node each node
+  /// ahould be reachable in the graph and in the reversed graph. Now this
+  /// condition can be checked with the Dfs algorithm class and the
+  /// RevGraphAdaptor algorithm class.
+  ///
+  /// And look at the code:
+  ///
+  ///\code
+  /// bool stronglyConnected(const Graph& graph) {
+  ///   if (NodeIt(graph) == INVALID) return true;
+  ///   Dfs<Graph> dfs(graph);
+  ///   dfs.run(NodeIt(graph));
+  ///   for (NodeIt it(graph); it != INVALID; ++it) {
+  ///     if (!dfs.reached(it)) {
+  ///       return false;
+  ///     }
+  ///   }
+  ///   typedef RevGraphAdaptor<const Graph> RGraph;
+  ///   RGraph rgraph(graph);
+  ///   DfsVisit<RGraph> rdfs(rgraph);
+  ///   rdfs.run(NodeIt(graph));
+  ///   for (NodeIt it(graph); it != INVALID; ++it) {
+  ///     if (!rdfs.reached(it)) {
+  ///       return false;
+  ///     }
+  ///   }
+  ///   return true;
+  /// }
+  ///\endcode
+  template<typename _Graph>
+  class RevGraphAdaptor : 
+    public GraphAdaptorExtender<RevGraphAdaptorBase<_Graph> > {
+  public:
+    typedef _Graph Graph;
+    typedef GraphAdaptorExtender<
+      RevGraphAdaptorBase<_Graph> > Parent;
+  protected:
+    RevGraphAdaptor() { }
+  public:
+    explicit RevGraphAdaptor(_Graph& _graph) { setGraph(_graph); }
+  };
+
+  /// \brief Just gives back a reverse graph adaptor
+  ///
+  /// Just gives back a reverse graph adaptor
+  template<typename Graph>
+  RevGraphAdaptor<const Graph>
+  revGraphAdaptor(const Graph& graph) {
+    return RevGraphAdaptor<const Graph>(graph);
+  }
+
+  template <typename _Graph, typename NodeFilterMap, 
+	    typename EdgeFilterMap, bool checked = true>
+  class SubGraphAdaptorBase : public GraphAdaptorBase<_Graph> {
+  public:
+    typedef _Graph Graph;
+    typedef SubGraphAdaptorBase Adaptor;
+    typedef GraphAdaptorBase<_Graph> Parent;
+  protected:
+    NodeFilterMap* node_filter_map;
+    EdgeFilterMap* edge_filter_map;
+    SubGraphAdaptorBase() : Parent(), 
+			    node_filter_map(0), edge_filter_map(0) { }
+
+    void setNodeFilterMap(NodeFilterMap& _node_filter_map) {
+      node_filter_map=&_node_filter_map;
+    }
+    void setEdgeFilterMap(EdgeFilterMap& _edge_filter_map) {
+      edge_filter_map=&_edge_filter_map;
+    }
+
+  public:
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+    void first(Node& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && !(*node_filter_map)[i]) Parent::next(i); 
+    }
+
+    void first(Edge& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && (!(*edge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)]
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::next(i); 
+    }
+
+    void firstIn(Edge& i, const Node& n) const { 
+      Parent::firstIn(i, n); 
+      while (i!=INVALID && (!(*edge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)])) Parent::nextIn(i); 
+    }
+
+    void firstOut(Edge& i, const Node& n) const { 
+      Parent::firstOut(i, n); 
+      while (i!=INVALID && (!(*edge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::nextOut(i); 
+    }
+
+    void next(Node& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && !(*node_filter_map)[i]) Parent::next(i); 
+    }
+
+    void next(Edge& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && (!(*edge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)]
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::next(i); 
+    }
+
+    void nextIn(Edge& i) const { 
+      Parent::nextIn(i); 
+      while (i!=INVALID && (!(*edge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)])) Parent::nextIn(i); 
+    }
+
+    void nextOut(Edge& i) const { 
+      Parent::nextOut(i); 
+      while (i!=INVALID && (!(*edge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::nextOut(i); 
+    }
+
+    ///\e
+
+    /// This function hides \c n in the graph, i.e. the iteration 
+    /// jumps over it. This is done by simply setting the value of \c n  
+    /// to be false in the corresponding node-map.
+    void hide(const Node& n) const { node_filter_map->set(n, false); }
+
+    ///\e
+
+    /// This function hides \c e in the graph, i.e. the iteration 
+    /// jumps over it. This is done by simply setting the value of \c e  
+    /// to be false in the corresponding edge-map.
+    void hide(const Edge& e) const { edge_filter_map->set(e, false); }
+
+    ///\e
+
+    /// The value of \c n is set to be true in the node-map which stores 
+    /// hide information. If \c n was hidden previuosly, then it is shown 
+    /// again
+     void unHide(const Node& n) const { node_filter_map->set(n, true); }
+
+    ///\e
+
+    /// The value of \c e is set to be true in the edge-map which stores 
+    /// hide information. If \c e was hidden previuosly, then it is shown 
+    /// again
+    void unHide(const Edge& e) const { edge_filter_map->set(e, true); }
+
+    /// Returns true if \c n is hidden.
+    
+    ///\e
+    ///
+    bool hidden(const Node& n) const { return !(*node_filter_map)[n]; }
+
+    /// Returns true if \c n is hidden.
+    
+    ///\e
+    ///
+    bool hidden(const Edge& e) const { return !(*edge_filter_map)[e]; }
+
+    typedef False NodeNumTag;
+    typedef False EdgeNumTag;
+
+    typedef FindEdgeTagIndicator<Graph> FindEdgeTag;
+    Edge findEdge(const Node& source, const Node& target, 
+		  const Edge& prev = INVALID) {
+      if (!(*node_filter_map)[source] || !(*node_filter_map)[target]) {
+        return INVALID;
+      }
+      Edge edge = Parent::findEdge(source, target, prev);
+      while (edge != INVALID && !(*edge_filter_map)[edge]) {
+        edge = Parent::findEdge(source, target, edge);
+      }
+      return edge;
+    }
+
+    template <typename _Value>
+    class NodeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template NodeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template NodeMap<_Value> > Parent;
+    
+      NodeMap(const Graph& g) 
+	: Parent(g) {}
+      NodeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      NodeMap& operator=(const NodeMap& cmap) {
+	return operator=<NodeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class EdgeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template EdgeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template EdgeMap<_Value> > Parent;
+    
+      EdgeMap(const Graph& g) 
+	: Parent(g) {}
+      EdgeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+  };
+
+  template <typename _Graph, typename NodeFilterMap, typename EdgeFilterMap>
+  class SubGraphAdaptorBase<_Graph, NodeFilterMap, EdgeFilterMap, false> 
+    : public GraphAdaptorBase<_Graph> {
+  public:
+    typedef _Graph Graph;
+    typedef SubGraphAdaptorBase Adaptor;
+    typedef GraphAdaptorBase<_Graph> Parent;
+  protected:
+    NodeFilterMap* node_filter_map;
+    EdgeFilterMap* edge_filter_map;
+    SubGraphAdaptorBase() : Parent(), 
+			    node_filter_map(0), edge_filter_map(0) { }
+
+    void setNodeFilterMap(NodeFilterMap& _node_filter_map) {
+      node_filter_map=&_node_filter_map;
+    }
+    void setEdgeFilterMap(EdgeFilterMap& _edge_filter_map) {
+      edge_filter_map=&_edge_filter_map;
+    }
+
+  public:
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+    void first(Node& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && !(*node_filter_map)[i]) Parent::next(i); 
+    }
+
+    void first(Edge& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && !(*edge_filter_map)[i]) Parent::next(i); 
+    }
+
+    void firstIn(Edge& i, const Node& n) const { 
+      Parent::firstIn(i, n); 
+      while (i!=INVALID && !(*edge_filter_map)[i]) Parent::nextIn(i); 
+    }
+
+    void firstOut(Edge& i, const Node& n) const { 
+      Parent::firstOut(i, n); 
+      while (i!=INVALID && !(*edge_filter_map)[i]) Parent::nextOut(i); 
+    }
+
+    void next(Node& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && !(*node_filter_map)[i]) Parent::next(i); 
+    }
+    void next(Edge& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && !(*edge_filter_map)[i]) Parent::next(i); 
+    }
+    void nextIn(Edge& i) const { 
+      Parent::nextIn(i); 
+      while (i!=INVALID && !(*edge_filter_map)[i]) Parent::nextIn(i); 
+    }
+
+    void nextOut(Edge& i) const { 
+      Parent::nextOut(i); 
+      while (i!=INVALID && !(*edge_filter_map)[i]) Parent::nextOut(i); 
+    }
+
+    ///\e
+
+    /// This function hides \c n in the graph, i.e. the iteration 
+    /// jumps over it. This is done by simply setting the value of \c n  
+    /// to be false in the corresponding node-map.
+    void hide(const Node& n) const { node_filter_map->set(n, false); }
+
+    ///\e
+
+    /// This function hides \c e in the graph, i.e. the iteration 
+    /// jumps over it. This is done by simply setting the value of \c e  
+    /// to be false in the corresponding edge-map.
+    void hide(const Edge& e) const { edge_filter_map->set(e, false); }
+
+    ///\e
+
+    /// The value of \c n is set to be true in the node-map which stores 
+    /// hide information. If \c n was hidden previuosly, then it is shown 
+    /// again
+     void unHide(const Node& n) const { node_filter_map->set(n, true); }
+
+    ///\e
+
+    /// The value of \c e is set to be true in the edge-map which stores 
+    /// hide information. If \c e was hidden previuosly, then it is shown 
+    /// again
+    void unHide(const Edge& e) const { edge_filter_map->set(e, true); }
+
+    /// Returns true if \c n is hidden.
+    
+    ///\e
+    ///
+    bool hidden(const Node& n) const { return !(*node_filter_map)[n]; }
+
+    /// Returns true if \c n is hidden.
+    
+    ///\e
+    ///
+    bool hidden(const Edge& e) const { return !(*edge_filter_map)[e]; }
+
+    typedef False NodeNumTag;
+    typedef False EdgeNumTag;
+
+    typedef FindEdgeTagIndicator<Graph> FindEdgeTag;
+    Edge findEdge(const Node& source, const Node& target, 
+		  const Edge& prev = INVALID) {
+      if (!(*node_filter_map)[source] || !(*node_filter_map)[target]) {
+        return INVALID;
+      }
+      Edge edge = Parent::findEdge(source, target, prev);
+      while (edge != INVALID && !(*edge_filter_map)[edge]) {
+        edge = Parent::findEdge(source, target, edge);
+      }
+      return edge;
+    }
+
+    template <typename _Value>
+    class NodeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template NodeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template NodeMap<_Value> > Parent;
+    
+      NodeMap(const Graph& g) 
+	: Parent(g) {}
+      NodeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      NodeMap& operator=(const NodeMap& cmap) {
+	return operator=<NodeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class EdgeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template EdgeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template EdgeMap<_Value> > Parent;
+    
+      EdgeMap(const Graph& g) 
+	: Parent(g) {}
+      EdgeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+  };
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief A graph adaptor for hiding nodes and edges from a graph.
+  /// 
+  /// SubGraphAdaptor shows the graph with filtered node-set and 
+  /// edge-set. If the \c checked parameter is true then it filters the edgeset
+  /// to do not get invalid edges without source or target.
+  /// Let \f$ G=(V, A) \f$ be a directed graph
+  /// and suppose that the graph instance \c g of type ListGraph
+  /// implements \f$ G \f$.
+  /// Let moreover \f$ b_V \f$ and \f$ b_A \f$ be bool-valued functions resp.
+  /// on the node-set and edge-set.
+  /// SubGraphAdaptor<...>::NodeIt iterates 
+  /// on the node-set \f$ \{v\in V : b_V(v)=true\} \f$ and 
+  /// SubGraphAdaptor<...>::EdgeIt iterates 
+  /// on the edge-set \f$ \{e\in A : b_A(e)=true\} \f$. Similarly, 
+  /// SubGraphAdaptor<...>::OutEdgeIt and
+  /// SubGraphAdaptor<...>::InEdgeIt iterates 
+  /// only on edges leaving and entering a specific node which have true value.
+  /// 
+  /// If the \c checked template parameter is false then we have to note that 
+  /// the node-iterator cares only the filter on the node-set, and the 
+  /// edge-iterator cares only the filter on the edge-set.
+  /// This way the edge-map
+  /// should filter all edges which's source or target is filtered by the 
+  /// node-filter.
+  ///\code
+  /// typedef ListGraph Graph;
+  /// Graph g;
+  /// typedef Graph::Node Node;
+  /// typedef Graph::Edge Edge;
+  /// Node u=g.addNode(); //node of id 0
+  /// Node v=g.addNode(); //node of id 1
+  /// Node e=g.addEdge(u, v); //edge of id 0
+  /// Node f=g.addEdge(v, u); //edge of id 1
+  /// Graph::NodeMap<bool> nm(g, true);
+  /// nm.set(u, false);
+  /// Graph::EdgeMap<bool> em(g, true);
+  /// em.set(e, false);
+  /// typedef SubGraphAdaptor<Graph, Graph::NodeMap<bool>, Graph::EdgeMap<bool> > SubGA;
+  /// SubGA ga(g, nm, em);
+  /// for (SubGA::NodeIt n(ga); n!=INVALID; ++n) std::cout << g.id(n) << std::endl;
+  /// std::cout << ":-)" << std::endl;
+  /// for (SubGA::EdgeIt e(ga); e!=INVALID; ++e) std::cout << g.id(e) << std::endl;
+  ///\endcode
+  /// The output of the above code is the following.
+  ///\code
+  /// 1
+  /// :-)
+  /// 1
+  ///\endcode
+  /// Note that \c n is of type \c SubGA::NodeIt, but it can be converted to
+  /// \c Graph::Node that is why \c g.id(n) can be applied.
+  /// 
+  /// For other examples see also the documentation of NodeSubGraphAdaptor and 
+  /// EdgeSubGraphAdaptor.
+  /// 
+  /// \author Marton Makai
+
+  template<typename _Graph, typename NodeFilterMap, 
+	   typename EdgeFilterMap, bool checked = true>
+  class SubGraphAdaptor : 
+    public GraphAdaptorExtender<
+    SubGraphAdaptorBase<_Graph, NodeFilterMap, EdgeFilterMap, checked> > {
+  public:
+    typedef _Graph Graph;
+    typedef GraphAdaptorExtender< SubGraphAdaptorBase<_Graph, NodeFilterMap, 
+                                                      EdgeFilterMap, checked> >
+    Parent;
+
+  protected:
+    SubGraphAdaptor() { }
+  public:
+
+    SubGraphAdaptor(_Graph& _graph, NodeFilterMap& _node_filter_map, 
+		    EdgeFilterMap& _edge_filter_map) { 
+      setGraph(_graph);
+      setNodeFilterMap(_node_filter_map);
+      setEdgeFilterMap(_edge_filter_map);
+    }
+
+  };
+
+  /// \brief Just gives back a sub graph adaptor
+  ///
+  /// Just gives back a sub graph adaptor
+  template<typename Graph, typename NodeFilterMap, typename EdgeFilterMap>
+  SubGraphAdaptor<const Graph, NodeFilterMap, EdgeFilterMap>
+  subGraphAdaptor(const Graph& graph, 
+                   NodeFilterMap& nfm, EdgeFilterMap& efm) {
+    return SubGraphAdaptor<const Graph, NodeFilterMap, EdgeFilterMap>
+      (graph, nfm, efm);
+  }
+
+  template<typename Graph, typename NodeFilterMap, typename EdgeFilterMap>
+  SubGraphAdaptor<const Graph, const NodeFilterMap, EdgeFilterMap>
+  subGraphAdaptor(const Graph& graph, 
+                   NodeFilterMap& nfm, EdgeFilterMap& efm) {
+    return SubGraphAdaptor<const Graph, const NodeFilterMap, EdgeFilterMap>
+      (graph, nfm, efm);
+  }
+
+  template<typename Graph, typename NodeFilterMap, typename EdgeFilterMap>
+  SubGraphAdaptor<const Graph, NodeFilterMap, const EdgeFilterMap>
+  subGraphAdaptor(const Graph& graph, 
+                   NodeFilterMap& nfm, EdgeFilterMap& efm) {
+    return SubGraphAdaptor<const Graph, NodeFilterMap, const EdgeFilterMap>
+      (graph, nfm, efm);
+  }
+
+  template<typename Graph, typename NodeFilterMap, typename EdgeFilterMap>
+  SubGraphAdaptor<const Graph, const NodeFilterMap, const EdgeFilterMap>
+  subGraphAdaptor(const Graph& graph, 
+                   NodeFilterMap& nfm, EdgeFilterMap& efm) {
+    return SubGraphAdaptor<const Graph, const NodeFilterMap, 
+      const EdgeFilterMap>(graph, nfm, efm);
+  }
+
+
+
+  ///\ingroup graph_adaptors
+  ///
+  ///\brief An adaptor for hiding nodes from a graph.
+  ///
+  ///An adaptor for hiding nodes from a graph.
+  ///This adaptor specializes SubGraphAdaptor in the way that only
+  ///the node-set 
+  ///can be filtered. In usual case the checked parameter is true, we get the
+  ///induced subgraph. But if the checked parameter is false then we can
+  ///filter only isolated nodes.
+  ///\author Marton Makai
+  template<typename Graph, typename NodeFilterMap, bool checked = true>
+  class NodeSubGraphAdaptor : 
+    public SubGraphAdaptor<Graph, NodeFilterMap, 
+			   ConstMap<typename Graph::Edge,bool>, checked> {
+  public:
+
+    typedef SubGraphAdaptor<Graph, NodeFilterMap, 
+			    ConstMap<typename Graph::Edge,bool>, checked > 
+    Parent;
+
+  protected:
+    ConstMap<typename Graph::Edge, bool> const_true_map;
+
+    NodeSubGraphAdaptor() : const_true_map(true) {
+      Parent::setEdgeFilterMap(const_true_map);
+    }
+
+  public:
+
+    NodeSubGraphAdaptor(Graph& _graph, NodeFilterMap& _node_filter_map) : 
+      Parent(), const_true_map(true) { 
+      Parent::setGraph(_graph);
+      Parent::setNodeFilterMap(_node_filter_map);
+      Parent::setEdgeFilterMap(const_true_map);
+    }
+
+  };
+
+
+  /// \brief Just gives back a node sub graph adaptor
+  ///
+  /// Just gives back a node sub graph adaptor
+  template<typename Graph, typename NodeFilterMap>
+  NodeSubGraphAdaptor<const Graph, NodeFilterMap>
+  nodeSubGraphAdaptor(const Graph& graph, NodeFilterMap& nfm) {
+    return NodeSubGraphAdaptor<const Graph, NodeFilterMap>(graph, nfm);
+  }
+
+  template<typename Graph, typename NodeFilterMap>
+  NodeSubGraphAdaptor<const Graph, const NodeFilterMap>
+  nodeSubGraphAdaptor(const Graph& graph, const NodeFilterMap& nfm) {
+    return NodeSubGraphAdaptor<const Graph, const NodeFilterMap>(graph, nfm);
+  }
+
+  ///\ingroup graph_adaptors
+  ///
+  ///\brief An adaptor for hiding edges from a graph.
+  ///
+  ///An adaptor for hiding edges from a graph.
+  ///This adaptor specializes SubGraphAdaptor in the way that
+  ///only the edge-set 
+  ///can be filtered. The usefulness of this adaptor is demonstrated in the 
+  ///problem of searching a maximum number of edge-disjoint shortest paths 
+  ///between 
+  ///two nodes \c s and \c t. Shortest here means being shortest w.r.t. 
+  ///non-negative edge-lengths. Note that 
+  ///the comprehension of the presented solution 
+  ///need's some elementary knowledge from combinatorial optimization. 
+  ///
+  ///If a single shortest path is to be 
+  ///searched between \c s and \c t, then this can be done easily by 
+  ///applying the Dijkstra algorithm. What happens, if a maximum number of 
+  ///edge-disjoint shortest paths is to be computed. It can be proved that an 
+  ///edge can be in a shortest path if and only
+  ///if it is tight with respect to 
+  ///the potential function computed by Dijkstra.
+  ///Moreover, any path containing 
+  ///only such edges is a shortest one.
+  ///Thus we have to compute a maximum number 
+  ///of edge-disjoint paths between \c s and \c t in
+  ///the graph which has edge-set 
+  ///all the tight edges. The computation will be demonstrated
+  ///on the following 
+  ///graph, which is read from the dimacs file \c sub_graph_adaptor_demo.dim. 
+  ///The full source code is available in \ref sub_graph_adaptor_demo.cc. 
+  ///If you are interested in more demo programs, you can use 
+  ///\ref dim_to_dot.cc to generate .dot files from dimacs files. 
+  ///The .dot file of the following figure was generated by  
+  ///the demo program \ref dim_to_dot.cc.
+  ///
+  ///\dot
+  ///digraph lemon_dot_example {
+  ///node [ shape=ellipse, fontname=Helvetica, fontsize=10 ];
+  ///n0 [ label="0 (s)" ];
+  ///n1 [ label="1" ];
+  ///n2 [ label="2" ];
+  ///n3 [ label="3" ];
+  ///n4 [ label="4" ];
+  ///n5 [ label="5" ];
+  ///n6 [ label="6 (t)" ];
+  ///edge [ shape=ellipse, fontname=Helvetica, fontsize=10 ];
+  ///n5 ->  n6 [ label="9, length:4" ];
+  ///n4 ->  n6 [ label="8, length:2" ];
+  ///n3 ->  n5 [ label="7, length:1" ];
+  ///n2 ->  n5 [ label="6, length:3" ];
+  ///n2 ->  n6 [ label="5, length:5" ];
+  ///n2 ->  n4 [ label="4, length:2" ];
+  ///n1 ->  n4 [ label="3, length:3" ];
+  ///n0 ->  n3 [ label="2, length:1" ];
+  ///n0 ->  n2 [ label="1, length:2" ];
+  ///n0 ->  n1 [ label="0, length:3" ];
+  ///}
+  ///\enddot
+  ///
+  ///\code
+  ///Graph g;
+  ///Node s, t;
+  ///LengthMap length(g);
+  ///
+  ///readDimacs(std::cin, g, length, s, t);
+  ///
+  ///cout << "edges with lengths (of form id, source--length->target): " << endl;
+  ///for(EdgeIt e(g); e!=INVALID; ++e) 
+  ///  cout << g.id(e) << ", " << g.id(g.source(e)) << "--" 
+  ///       << length[e] << "->" << g.id(g.target(e)) << endl;
+  ///
+  ///cout << "s: " << g.id(s) << " t: " << g.id(t) << endl;
+  ///\endcode
+  ///Next, the potential function is computed with Dijkstra.
+  ///\code
+  ///typedef Dijkstra<Graph, LengthMap> Dijkstra;
+  ///Dijkstra dijkstra(g, length);
+  ///dijkstra.run(s);
+  ///\endcode
+  ///Next, we consrtruct a map which filters the edge-set to the tight edges.
+  ///\code
+  ///typedef TightEdgeFilterMap<Graph, const Dijkstra::DistMap, LengthMap> 
+  ///  TightEdgeFilter;
+  ///TightEdgeFilter tight_edge_filter(g, dijkstra.distMap(), length);
+  ///
+  ///typedef EdgeSubGraphAdaptor<Graph, TightEdgeFilter> SubGA;
+  ///SubGA ga(g, tight_edge_filter);
+  ///\endcode
+  ///Then, the maximum nimber of edge-disjoint \c s-\c t paths are computed 
+  ///with a max flow algorithm Preflow.
+  ///\code
+  ///ConstMap<Edge, int> const_1_map(1);
+  ///Graph::EdgeMap<int> flow(g, 0);
+  ///
+  ///Preflow<SubGA, ConstMap<Edge, int>, Graph::EdgeMap<int> > 
+  ///  preflow(ga, const_1_map, s, t);
+  ///preflow.run();
+  ///\endcode
+  ///Last, the output is:
+  ///\code  
+  ///cout << "maximum number of edge-disjoint shortest path: " 
+  ///     << preflow.flowValue() << endl;
+  ///cout << "edges of the maximum number of edge-disjoint shortest s-t paths: " 
+  ///     << endl;
+  ///for(EdgeIt e(g); e!=INVALID; ++e) 
+  ///  if (preflow.flow(e))
+  ///    cout << " " << g.id(g.source(e)) << "--"
+  ///         << length[e] << "->" << g.id(g.target(e)) << endl;
+  ///\endcode
+  ///The program has the following (expected :-)) output:
+  ///\code
+  ///edges with lengths (of form id, source--length->target):
+  /// 9, 5--4->6
+  /// 8, 4--2->6
+  /// 7, 3--1->5
+  /// 6, 2--3->5
+  /// 5, 2--5->6
+  /// 4, 2--2->4
+  /// 3, 1--3->4
+  /// 2, 0--1->3
+  /// 1, 0--2->2
+  /// 0, 0--3->1
+  ///s: 0 t: 6
+  ///maximum number of edge-disjoint shortest path: 2
+  ///edges of the maximum number of edge-disjoint shortest s-t paths:
+  /// 9, 5--4->6
+  /// 8, 4--2->6
+  /// 7, 3--1->5
+  /// 4, 2--2->4
+  /// 2, 0--1->3
+  /// 1, 0--2->2
+  ///\endcode
+  ///
+  ///\author Marton Makai
+  template<typename Graph, typename EdgeFilterMap>
+  class EdgeSubGraphAdaptor : 
+    public SubGraphAdaptor<Graph, ConstMap<typename Graph::Node,bool>, 
+			   EdgeFilterMap, false> {
+  public:
+    typedef SubGraphAdaptor<Graph, ConstMap<typename Graph::Node,bool>, 
+			    EdgeFilterMap, false> Parent;
+  protected:
+    ConstMap<typename Graph::Node, bool> const_true_map;
+
+    EdgeSubGraphAdaptor() : const_true_map(true) {
+      Parent::setNodeFilterMap(const_true_map);
+    }
+
+  public:
+
+    EdgeSubGraphAdaptor(Graph& _graph, EdgeFilterMap& _edge_filter_map) : 
+      Parent(), const_true_map(true) { 
+      Parent::setGraph(_graph);
+      Parent::setNodeFilterMap(const_true_map);
+      Parent::setEdgeFilterMap(_edge_filter_map);
+    }
+
+  };
+
+  /// \brief Just gives back an edge sub graph adaptor
+  ///
+  /// Just gives back an edge sub graph adaptor
+  template<typename Graph, typename EdgeFilterMap>
+  EdgeSubGraphAdaptor<const Graph, EdgeFilterMap>
+  edgeSubGraphAdaptor(const Graph& graph, EdgeFilterMap& efm) {
+    return EdgeSubGraphAdaptor<const Graph, EdgeFilterMap>(graph, efm);
+  }
+
+  template<typename Graph, typename EdgeFilterMap>
+  EdgeSubGraphAdaptor<const Graph, const EdgeFilterMap>
+  edgeSubGraphAdaptor(const Graph& graph, const EdgeFilterMap& efm) {
+    return EdgeSubGraphAdaptor<const Graph, const EdgeFilterMap>(graph, efm);
+  }
+
+  template <typename _Graph>
+  class UndirGraphAdaptorBase : 
+    public UndirGraphExtender<GraphAdaptorBase<_Graph> > {
+  public:
+    typedef _Graph Graph;
+    typedef UndirGraphAdaptorBase Adaptor;
+    typedef UndirGraphExtender<GraphAdaptorBase<_Graph> > Parent;
+
+  protected:
+
+    UndirGraphAdaptorBase() : Parent() {}
+
+  public:
+
+    typedef typename Parent::UEdge UEdge;
+    typedef typename Parent::Edge Edge;
+
+  private:
+    
+    template <typename _Value>
+    class EdgeMapBase {
+    private:
+      
+      typedef typename _Graph::template EdgeMap<_Value> MapImpl;
+      
+    public:
+
+      typedef typename MapTraits<MapImpl>::ReferenceMapTag ReferenceMapTag;
+
+      typedef _Value Value;
+      typedef Edge Key;
+      
+      EdgeMapBase(const Adaptor& adaptor) :
+	forward_map(*adaptor.graph), backward_map(*adaptor.graph) {}
+
+      EdgeMapBase(const Adaptor& adaptor, const Value& v) 
+        : forward_map(*adaptor.graph, v), backward_map(*adaptor.graph, v) {}
+      
+      void set(const Edge& e, const Value& a) { 
+	if (Parent::direction(e)) {
+	  forward_map.set(e, a); 
+        } else { 
+	  backward_map.set(e, a);
+        } 
+      }
+
+      typename MapTraits<MapImpl>::ConstReturnValue operator[](Edge e) const { 
+	if (Parent::direction(e)) {
+	  return forward_map[e]; 
+	} else { 
+	  return backward_map[e]; 
+        }
+      }
+
+      typename MapTraits<MapImpl>::ReturnValue operator[](Edge e) { 
+	if (Parent::direction(e)) {
+	  return forward_map[e]; 
+	} else { 
+	  return backward_map[e]; 
+        }
+      }
+
+    protected:
+
+      MapImpl forward_map, backward_map; 
+
+    };
+
+  public:
+
+    template <typename _Value>
+    class EdgeMap 
+      : public SubMapExtender<Adaptor, EdgeMapBase<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, EdgeMapBase<_Value> > Parent;
+    
+      EdgeMap(const Graph& g) 
+	: Parent(g) {}
+      EdgeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+        
+    template <typename _Value>
+    class UEdgeMap : public Graph::template EdgeMap<_Value> {
+    public:
+      
+      typedef typename Graph::template EdgeMap<_Value> Parent;
+      
+      explicit UEdgeMap(const Adaptor& ga) 
+	: Parent(*ga.graph) {}
+
+      UEdgeMap(const Adaptor& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      UEdgeMap& operator=(const UEdgeMap& cmap) {
+        return operator=<UEdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      UEdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+
+    };
+      
+  };
+
+  template <typename _Graph, typename Enable = void>
+  class AlterableUndirGraphAdaptor 
+    : public UGraphAdaptorExtender<UndirGraphAdaptorBase<_Graph> > {
+  public:
+    typedef UGraphAdaptorExtender<UndirGraphAdaptorBase<_Graph> > Parent;
+    
+  protected:
+
+    AlterableUndirGraphAdaptor() : Parent() {}
+
+  public:
+
+    typedef typename Parent::EdgeNotifier UEdgeNotifier;
+    typedef InvalidType EdgeNotifier;
+
+  };
+
+  template <typename _Graph>
+  class AlterableUndirGraphAdaptor<
+    _Graph, 
+    typename enable_if<typename _Graph::EdgeNotifier::Notifier>::type > 
+    : public UGraphAdaptorExtender<UndirGraphAdaptorBase<_Graph> > {
+  public:
+
+    typedef UGraphAdaptorExtender<UndirGraphAdaptorBase<_Graph> > Parent;
+    typedef _Graph Graph;
+    typedef typename _Graph::Edge GraphEdge;
+    
+  protected:
+
+    AlterableUndirGraphAdaptor() 
+      : Parent(), edge_notifier(*this), edge_notifier_proxy(*this) {}
+
+    void setGraph(_Graph& g) {
+      Parent::setGraph(g);
+      edge_notifier_proxy.setNotifier(g.notifier(GraphEdge()));
+    }
+
+  public:
+
+    ~AlterableUndirGraphAdaptor() {
+      edge_notifier.clear();
+    }
+
+    typedef typename Parent::UEdge UEdge;
+    typedef typename Parent::Edge Edge;
+
+    typedef typename Parent::EdgeNotifier UEdgeNotifier;
+
+    using Parent::notifier;
+
+    typedef AlterationNotifier<AlterableUndirGraphAdaptor, 
+                               Edge> EdgeNotifier;
+    EdgeNotifier& notifier(Edge) const { return edge_notifier; }
+
+  protected:
+
+    class NotifierProxy : public Graph::EdgeNotifier::ObserverBase {
+    public:
+
+      typedef typename Graph::EdgeNotifier::ObserverBase Parent;
+      typedef AlterableUndirGraphAdaptor AdaptorBase;
+      
+      NotifierProxy(const AdaptorBase& _adaptor)
+        : Parent(), adaptor(&_adaptor) {
+      }
+
+      virtual ~NotifierProxy() {
+        if (Parent::attached()) {
+          Parent::detach();
+        }
+      }
+
+      void setNotifier(typename Graph::EdgeNotifier& nf) {
+        Parent::attach(nf);
+      }
+
+      
+    protected:
+
+      virtual void add(const GraphEdge& ge) {
+        std::vector<Edge> edges;
+        edges.push_back(AdaptorBase::Parent::direct(ge, true));
+        edges.push_back(AdaptorBase::Parent::direct(ge, false));
+        adaptor->notifier(Edge()).add(edges);
+      }
+      virtual void add(const std::vector<GraphEdge>& ge) {
+        std::vector<Edge> edges;
+        for (int i = 0; i < int(ge.size()); ++i) { 
+          edges.push_back(AdaptorBase::Parent::direct(ge[i], true));
+          edges.push_back(AdaptorBase::Parent::direct(ge[i], false));
+        }
+        adaptor->notifier(Edge()).add(edges);
+      }
+      virtual void erase(const GraphEdge& ge) {
+        std::vector<Edge> edges;
+        edges.push_back(AdaptorBase::Parent::direct(ge, true));
+        edges.push_back(AdaptorBase::Parent::direct(ge, false));
+        adaptor->notifier(Edge()).erase(edges);
+      }
+      virtual void erase(const std::vector<GraphEdge>& ge) {
+        std::vector<Edge> edges;
+        for (int i = 0; i < int(ge.size()); ++i) { 
+          edges.push_back(AdaptorBase::Parent::direct(ge[i], true));
+          edges.push_back(AdaptorBase::Parent::direct(ge[i], false));
+        }
+        adaptor->notifier(Edge()).erase(edges);
+      }
+      virtual void build() {
+        adaptor->notifier(Edge()).build();
+      }
+      virtual void clear() {
+        adaptor->notifier(Edge()).clear();
+      }
+
+      const AdaptorBase* adaptor;
+    };
+
+
+    mutable EdgeNotifier edge_notifier;
+    NotifierProxy edge_notifier_proxy;
+
+  };
+
+
+  ///\ingroup graph_adaptors
+  ///
+  /// \brief An undirected graph is made from a directed graph by an adaptor
+  ///
+  /// This adaptor makes an undirected graph from a directed
+  /// graph. All edge of the underlying will be showed in the adaptor
+  /// as an undirected edge. Let's see an informal example about using
+  /// this adaptor:
+  ///
+  /// There is a network of the streets of a town. Of course there are
+  /// some one-way street in the town hence the network is a directed
+  /// one. There is a crazy driver who go oppositely in the one-way
+  /// street without moral sense. Of course he can pass this streets
+  /// slower than the regular way, in fact his speed is half of the
+  /// normal speed. How long should he drive to get from a source
+  /// point to the target? Let see the example code which calculate it:
+  ///
+  ///\code
+  /// typedef UndirGraphAdaptor<Graph> UGraph;
+  /// UGraph ugraph(graph);
+  ///
+  /// typedef SimpleMap<LengthMap> FLengthMap;
+  /// FLengthMap flength(length);
+  ///
+  /// typedef ScaleMap<LengthMap> RLengthMap;
+  /// RLengthMap rlength(length, 2.0);
+  ///
+  /// typedef UGraph::CombinedEdgeMap<FLengthMap, RLengthMap > ULengthMap;
+  /// ULengthMap ulength(flength, rlength);
+  /// 
+  /// Dijkstra<UGraph, ULengthMap> dijkstra(ugraph, ulength);
+  /// std::cout << "Driving time : " << dijkstra.run(src, trg) << std::endl;
+  ///\endcode
+  ///
+  /// The combined edge map makes the length map for the undirected
+  /// graph. It is created from a forward and reverse map. The forward
+  /// map is created from the original length map with a SimpleMap
+  /// adaptor which just makes a read-write map from the reference map
+  /// i.e. it forgets that it can be return reference to values. The
+  /// reverse map is just the scaled original map with the ScaleMap
+  /// adaptor. The combination solves that passing the reverse way
+  /// takes double time than the original. To get the driving time we
+  /// run the dijkstra algorithm on the undirected graph.
+  ///
+  /// \author Marton Makai and Balazs Dezso
+  template<typename _Graph>
+  class UndirGraphAdaptor : public AlterableUndirGraphAdaptor<_Graph> {
+  public:
+    typedef _Graph Graph;
+    typedef AlterableUndirGraphAdaptor<_Graph> Parent;
+  protected:
+    UndirGraphAdaptor() { }
+  public:
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    UndirGraphAdaptor(_Graph& _graph) { 
+      setGraph(_graph);
+    }
+
+    /// \brief EdgeMap combined from two original EdgeMap
+    ///
+    /// This class adapts two original graph EdgeMap to
+    /// get an edge map on the adaptor.
+    template <typename _ForwardMap, typename _BackwardMap>
+    class CombinedEdgeMap {
+    public:
+      
+      typedef _ForwardMap ForwardMap;
+      typedef _BackwardMap BackwardMap;
+
+      typedef typename MapTraits<ForwardMap>::ReferenceMapTag ReferenceMapTag;
+
+      typedef typename ForwardMap::Value Value;
+      typedef typename Parent::Edge Key;
+
+      /// \brief Constructor      
+      ///
+      /// Constructor      
+      CombinedEdgeMap() : forward_map(0), backward_map(0) {}
+
+      /// \brief Constructor      
+      ///
+      /// Constructor      
+      CombinedEdgeMap(ForwardMap& _forward_map, BackwardMap& _backward_map) 
+        : forward_map(&_forward_map), backward_map(&_backward_map) {}
+      
+
+      /// \brief Sets the value associated with a key.
+      ///
+      /// Sets the value associated with a key.
+      void set(const Key& e, const Value& a) { 
+	if (Parent::direction(e)) {
+	  forward_map->set(e, a); 
+        } else { 
+	  backward_map->set(e, a);
+        } 
+      }
+
+      /// \brief Returns the value associated with a key.
+      ///
+      /// Returns the value associated with a key.
+      typename MapTraits<ForwardMap>::ConstReturnValue 
+      operator[](const Key& e) const { 
+	if (Parent::direction(e)) {
+	  return (*forward_map)[e]; 
+	} else { 
+	  return (*backward_map)[e]; 
+        }
+      }
+
+      /// \brief Returns the value associated with a key.
+      ///
+      /// Returns the value associated with a key.
+      typename MapTraits<ForwardMap>::ReturnValue 
+      operator[](const Key& e) { 
+	if (Parent::direction(e)) {
+	  return (*forward_map)[e]; 
+	} else { 
+	  return (*backward_map)[e]; 
+        }
+      }
+
+      /// \brief Sets the forward map
+      ///
+      /// Sets the forward map
+      void setForwardMap(ForwardMap& _forward_map) {
+        forward_map = &_forward_map;
+      }
+
+      /// \brief Sets the backward map
+      ///
+      /// Sets the backward map
+      void setBackwardMap(BackwardMap& _backward_map) {
+        backward_map = &_backward_map;
+      }
+
+    protected:
+
+      ForwardMap* forward_map;
+      BackwardMap* backward_map; 
+
+    };
+
+  };
+
+  /// \brief Just gives back an undir graph adaptor
+  ///
+  /// Just gives back an undir graph adaptor
+  template<typename Graph>
+  UndirGraphAdaptor<const Graph>
+  undirGraphAdaptor(const Graph& graph) {
+    return UndirGraphAdaptor<const Graph>(graph);
+  }
+
+  template<typename Graph, typename Number,  
+           typename CapacityMap, typename FlowMap, 
+           typename Tol = Tolerance<Number> >
+  class ResForwardFilter {
+    const CapacityMap* capacity;
+    const FlowMap* flow;
+    Tol tolerance;
+  public:
+    typedef typename Graph::Edge Key;
+    typedef bool Value;
+
+    ResForwardFilter(const CapacityMap& _capacity, const FlowMap& _flow,
+                     const Tol& _tolerance = Tol()) 
+      : capacity(&_capacity), flow(&_flow), tolerance(_tolerance) { }
+
+    ResForwardFilter(const Tol& _tolerance) 
+      : capacity(0), flow(0), tolerance(_tolerance)  { }
+
+    void setCapacity(const CapacityMap& _capacity) { capacity = &_capacity; }
+    void setFlow(const FlowMap& _flow) { flow = &_flow; }
+
+    bool operator[](const typename Graph::Edge& e) const {
+      return tolerance.positive((*capacity)[e] - (*flow)[e]);
+    }
+  };
+
+  template<typename Graph, typename Number,
+	   typename CapacityMap, typename FlowMap,
+           typename Tol = Tolerance<Number> >
+  class ResBackwardFilter {
+    const CapacityMap* capacity;
+    const FlowMap* flow;
+    Tol tolerance;
+  public:
+    typedef typename Graph::Edge Key;
+    typedef bool Value;
+
+    ResBackwardFilter(const CapacityMap& _capacity, const FlowMap& _flow,
+                      const Tol& _tolerance = Tol())
+      : capacity(&_capacity), flow(&_flow), tolerance(_tolerance) { }
+    ResBackwardFilter(const Tol& _tolerance = Tol())
+      : capacity(0), flow(0), tolerance(_tolerance) { }
+    void setCapacity(const CapacityMap& _capacity) { capacity = &_capacity; }
+    void setFlow(const FlowMap& _flow) { flow = &_flow; }
+    bool operator[](const typename Graph::Edge& e) const {
+      return tolerance.positive((*flow)[e]);
+    }
+  };
+
+  
+  ///\ingroup graph_adaptors
+  ///
+  ///\brief An adaptor for composing the residual
+  ///graph for directed flow and circulation problems.
+  ///
+  ///An adaptor for composing the residual graph for directed flow and
+  ///circulation problems.  Let \f$ G=(V, A) \f$ be a directed graph
+  ///and let \f$ F \f$ be a number type. Let moreover \f$ f,c:A\to F \f$,
+  ///be functions on the edge-set.
+  ///
+  ///In the appications of ResGraphAdaptor, \f$ f \f$ usually stands
+  ///for a flow and \f$ c \f$ for a capacity function.  Suppose that a
+  ///graph instange \c g of type \c ListGraph implements \f$ G \f$.
+  ///
+  ///\code 
+  ///  ListGraph g;
+  ///\endcode 
+  ///
+  ///Then ResGraphAdaptor implements the graph structure with node-set
+  /// \f$ V \f$ and edge-set \f$ A_{forward}\cup A_{backward} \f$,
+  ///where \f$ A_{forward}=\{uv : uv\in A, f(uv)<c(uv)\} \f$ and 
+  /// \f$ A_{backward}=\{vu : uv\in A, f(uv)>0\} \f$, i.e. the so called
+  ///residual graph.  When we take the union 
+  /// \f$ A_{forward}\cup A_{backward} \f$, multilicities are counted, i.e. 
+  ///if an edge is in both \f$ A_{forward} \f$ and \f$ A_{backward} \f$, 
+  ///then in the adaptor it appears twice. The following code shows how 
+  ///such an instance can be constructed.
+  ///
+  ///\code 
+  ///  typedef ListGraph Graph; 
+  ///  Graph::EdgeMap<int> f(g);
+  ///  Graph::EdgeMap<int> c(g); 
+  ///  ResGraphAdaptor<Graph, int, Graph::EdgeMap<int>, Graph::EdgeMap<int> > ga(g); 
+  ///\endcode
+  ///\author Marton Makai
+  ///
+  template<typename Graph, typename Number, 
+	   typename CapacityMap, typename FlowMap,
+           typename Tol = Tolerance<Number> >
+  class ResGraphAdaptor : 
+    public EdgeSubGraphAdaptor< 
+    UndirGraphAdaptor<const Graph>, 
+    typename UndirGraphAdaptor<const Graph>::template CombinedEdgeMap<
+    ResForwardFilter<const Graph, Number, CapacityMap, FlowMap>,  
+    ResBackwardFilter<const Graph, Number, CapacityMap, FlowMap> > > {
+  public:
+
+    typedef UndirGraphAdaptor<const Graph> UGraph;
+
+    typedef ResForwardFilter<const Graph, Number, CapacityMap, FlowMap> 
+    ForwardFilter;
+
+    typedef ResBackwardFilter<const Graph, Number, CapacityMap, FlowMap> 
+    BackwardFilter;
+
+    typedef typename UGraph::
+    template CombinedEdgeMap<ForwardFilter, BackwardFilter>
+    EdgeFilter;
+
+    typedef EdgeSubGraphAdaptor<UGraph, EdgeFilter> Parent;
+
+  protected:
+
+    const CapacityMap* capacity;
+    FlowMap* flow;
+
+    UGraph ugraph;
+    ForwardFilter forward_filter;
+    BackwardFilter backward_filter;
+    EdgeFilter edge_filter;
+
+    void setCapacityMap(const CapacityMap& _capacity) {
+      capacity=&_capacity;
+      forward_filter.setCapacity(_capacity);
+      backward_filter.setCapacity(_capacity);
+    }
+
+    void setFlowMap(FlowMap& _flow) {
+      flow=&_flow;
+      forward_filter.setFlow(_flow);
+      backward_filter.setFlow(_flow);
+    }
+
+  public:
+
+    /// \brief Constructor of the residual graph.
+    ///
+    /// Constructor of the residual graph. The parameters are the graph type,
+    /// the flow map, the capacity map and a tolerance object.
+    ResGraphAdaptor(const Graph& _graph, const CapacityMap& _capacity, 
+                    FlowMap& _flow, const Tol& _tolerance = Tol()) 
+      : Parent(), capacity(&_capacity), flow(&_flow), ugraph(_graph),
+        forward_filter(_capacity, _flow, _tolerance), 
+        backward_filter(_capacity, _flow, _tolerance),
+        edge_filter(forward_filter, backward_filter)
+    {
+      Parent::setGraph(ugraph);
+      Parent::setEdgeFilterMap(edge_filter);
+    }
+
+    typedef typename Parent::Edge Edge;
+
+    /// \brief Gives back the residual capacity of the edge.
+    ///
+    /// Gives back the residual capacity of the edge.
+    Number rescap(const Edge& edge) const {
+      if (UGraph::direction(edge)) {
+        return (*capacity)[edge]-(*flow)[edge]; 
+      } else {
+        return (*flow)[edge];
+      }
+    } 
+
+    /// \brief Augment on the given edge in the residual graph.
+    ///
+    /// Augment on the given edge in the residual graph. It increase
+    /// or decrease the flow on the original edge depend on the direction
+    /// of the residual edge.
+    void augment(const Edge& e, Number a) const {
+      if (UGraph::direction(e)) {
+        flow->set(e, (*flow)[e] + a);
+      } else {  
+        flow->set(e, (*flow)[e] - a);
+      }
+    }
+
+    /// \brief Returns the direction of the edge.
+    ///
+    /// Returns true when the edge is same oriented as the original edge.
+    static bool forward(const Edge& e) {
+      return UGraph::direction(e);
+    }
+
+    /// \brief Returns the direction of the edge.
+    ///
+    /// Returns true when the edge is opposite oriented as the original edge.
+    static bool backward(const Edge& e) {
+      return !UGraph::direction(e);
+    }
+
+    /// \brief Gives back the forward oriented residual edge.
+    ///
+    /// Gives back the forward oriented residual edge.
+    static Edge forward(const typename Graph::Edge& e) {
+      return UGraph::direct(e, true);
+    }
+
+    /// \brief Gives back the backward oriented residual edge.
+    ///
+    /// Gives back the backward oriented residual edge.
+    static Edge backward(const typename Graph::Edge& e) {
+      return UGraph::direct(e, false);
+    }
+
+    /// \brief Residual capacity map.
+    ///
+    /// In generic residual graphs the residual capacity can be obtained 
+    /// as a map. 
+    class ResCap {
+    protected:
+      const ResGraphAdaptor* res_graph;
+    public:
+      typedef Number Value;
+      typedef Edge Key;
+      ResCap(const ResGraphAdaptor& _res_graph) 
+        : res_graph(&_res_graph) {}
+      
+      Number operator[](const Edge& e) const {
+        return res_graph->rescap(e);
+      }
+      
+    };
+
+  };
+
+
+
+  template <typename _Graph, typename FirstOutEdgesMap>
+  class ErasingFirstGraphAdaptorBase : public GraphAdaptorBase<_Graph> {
+  public:
+    typedef _Graph Graph;
+    typedef GraphAdaptorBase<_Graph> Parent;
+  protected:
+    FirstOutEdgesMap* first_out_edges;
+    ErasingFirstGraphAdaptorBase() : Parent(), 
+				     first_out_edges(0) { }
+
+    void setFirstOutEdgesMap(FirstOutEdgesMap& _first_out_edges) {
+      first_out_edges=&_first_out_edges;
+    }
+
+  public:
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+    void firstOut(Edge& i, const Node& n) const { 
+      i=(*first_out_edges)[n];
+    }
+
+    void erase(const Edge& e) const {
+      Node n=source(e);
+      Edge f=e;
+      Parent::nextOut(f);
+      first_out_edges->set(n, f);
+    }    
+  };
+
+
+  ///\ingroup graph_adaptors
+  ///
+  ///\brief For blocking flows.
+  ///
+  ///This graph adaptor is used for on-the-fly 
+  ///Dinits blocking flow computations.
+  ///For each node, an out-edge is stored which is used when the 
+  ///\code
+  ///OutEdgeIt& first(OutEdgeIt&, const Node&)
+  ///\endcode
+  ///is called. 
+  ///
+  ///\author Marton Makai
+  ///
+  template <typename _Graph, typename FirstOutEdgesMap>
+  class ErasingFirstGraphAdaptor : 
+    public GraphAdaptorExtender<
+    ErasingFirstGraphAdaptorBase<_Graph, FirstOutEdgesMap> > {
+  public:
+    typedef _Graph Graph;
+    typedef GraphAdaptorExtender<
+      ErasingFirstGraphAdaptorBase<_Graph, FirstOutEdgesMap> > Parent;
+    ErasingFirstGraphAdaptor(Graph& _graph, 
+			     FirstOutEdgesMap& _first_out_edges) { 
+      setGraph(_graph);
+      setFirstOutEdgesMap(_first_out_edges);
+    } 
+
+  };
+
+  /// \brief Base class for split graph adaptor
+  ///
+  /// Base class of split graph adaptor. In most case you do not need to
+  /// use it directly but the documented member functions of this class can 
+  /// be used with the SplitGraphAdaptor class.
+  /// \sa SplitGraphAdaptor
+  template <typename _Graph>
+  class SplitGraphAdaptorBase 
+    : public GraphAdaptorBase<const _Graph> {
+  public:
+
+    typedef _Graph Graph;
+
+    typedef GraphAdaptorBase<const _Graph> Parent;
+
+    typedef typename Graph::Node GraphNode;
+    typedef typename Graph::Edge GraphEdge;
+
+    class Node;
+    class Edge;
+
+    template <typename T> class NodeMap;
+    template <typename T> class EdgeMap;
+    
+
+    class Node : public GraphNode {
+      friend class SplitGraphAdaptorBase;
+      template <typename T> friend class NodeMap;
+    private:
+
+      bool in_node;
+      Node(GraphNode _node, bool _in_node)
+	: GraphNode(_node), in_node(_in_node) {}
+      
+    public:
+
+      Node() {}
+      Node(Invalid) : GraphNode(INVALID), in_node(true) {}
+
+      bool operator==(const Node& node) const {
+	return GraphNode::operator==(node) && in_node == node.in_node;
+      }
+      
+      bool operator!=(const Node& node) const {
+	return !(*this == node);
+      }
+      
+      bool operator<(const Node& node) const {
+	return GraphNode::operator<(node) || 
+	  (GraphNode::operator==(node) && in_node < node.in_node);
+      }
+    };
+
+    class Edge {
+      friend class SplitGraphAdaptorBase;
+      template <typename T> friend class EdgeMap;
+    private:
+      typedef BiVariant<GraphEdge, GraphNode> EdgeImpl;
+
+      explicit Edge(const GraphEdge& edge) : item(edge) {}
+      explicit Edge(const GraphNode& node) : item(node) {}
+      
+      EdgeImpl item;
+
+    public:
+      Edge() {}
+      Edge(Invalid) : item(GraphEdge(INVALID)) {}
+
+      bool operator==(const Edge& edge) const {
+        if (item.firstState()) {
+          if (edge.item.firstState()) {
+            return item.first() == edge.item.first();
+          }
+        } else {
+          if (edge.item.secondState()) {
+            return item.second() == edge.item.second();
+          }
+        }
+        return false;
+      }
+      
+      bool operator!=(const Edge& edge) const {
+	return !(*this == edge);
+      }
+      
+      bool operator<(const Edge& edge) const {
+        if (item.firstState()) {
+          if (edge.item.firstState()) {
+            return item.first() < edge.item.first();
+          }
+          return false;
+        } else {
+          if (edge.item.secondState()) {
+            return item.second() < edge.item.second();
+          }
+          return true;
+        }
+      }
+
+      operator GraphEdge() const { return item.first(); }
+      operator GraphNode() const { return item.second(); }
+
+    };
+
+    void first(Node& n) const {
+      Parent::first(n);
+      n.in_node = true;
+    }
+
+    void next(Node& n) const {
+      if (n.in_node) {
+	n.in_node = false;
+      } else {
+	n.in_node = true;
+	Parent::next(n);
+      }
+    }
+
+    void first(Edge& e) const {
+      e.item.setSecond();
+      Parent::first(e.item.second());
+      if (e.item.second() == INVALID) {
+        e.item.setFirst();
+	Parent::first(e.item.first());
+      }
+    }
+
+    void next(Edge& e) const {
+      if (e.item.secondState()) {
+	Parent::next(e.item.second());
+        if (e.item.second() == INVALID) {
+          e.item.setFirst();
+          Parent::first(e.item.first());
+        }
+      } else {
+	Parent::next(e.item.first());
+      }      
+    }
+
+    void firstOut(Edge& e, const Node& n) const {
+      if (n.in_node) {
+        e.item.setSecond(n);
+      } else {
+        e.item.setFirst();
+	Parent::firstOut(e.item.first(), n);
+      }
+    }
+
+    void nextOut(Edge& e) const {
+      if (!e.item.firstState()) {
+	e.item.setFirst(INVALID);
+      } else {
+	Parent::nextOut(e.item.first());
+      }      
+    }
+
+    void firstIn(Edge& e, const Node& n) const {
+      if (!n.in_node) {
+        e.item.setSecond(n);        
+      } else {
+        e.item.setFirst();
+	Parent::firstIn(e.item.first(), n);
+      }
+    }
+
+    void nextIn(Edge& e) const {
+      if (!e.item.firstState()) {
+	e.item.setFirst(INVALID);
+      } else {
+	Parent::nextIn(e.item.first());
+      }
+    }
+
+    Node source(const Edge& e) const {
+      if (e.item.firstState()) {
+	return Node(Parent::source(e.item.first()), false);
+      } else {
+	return Node(e.item.second(), true);
+      }
+    }
+
+    Node target(const Edge& e) const {
+      if (e.item.firstState()) {
+	return Node(Parent::target(e.item.first()), true);
+      } else {
+	return Node(e.item.second(), false);
+      }
+    }
+
+    int id(const Node& n) const {
+      return (Parent::id(n) << 1) | (n.in_node ? 0 : 1);
+    }
+    Node nodeFromId(int ix) const {
+      return Node(Parent::nodeFromId(ix >> 1), (ix & 1) == 0);
+    }
+    int maxNodeId() const {
+      return 2 * Parent::maxNodeId() + 1;
+    }
+
+    int id(const Edge& e) const {
+      if (e.item.firstState()) {
+        return Parent::id(e.item.first()) << 1;
+      } else {
+        return (Parent::id(e.item.second()) << 1) | 1;
+      }
+    }
+    Edge edgeFromId(int ix) const {
+      if ((ix & 1) == 0) {
+        return Edge(Parent::edgeFromId(ix >> 1));
+      } else {
+        return Edge(Parent::nodeFromId(ix >> 1));
+      }
+    }
+    int maxEdgeId() const {
+      return std::max(Parent::maxNodeId() << 1, 
+                      (Parent::maxEdgeId() << 1) | 1);
+    }
+
+    /// \brief Returns true when the node is in-node.
+    ///
+    /// Returns true when the node is in-node.
+    static bool inNode(const Node& n) {
+      return n.in_node;
+    }
+
+    /// \brief Returns true when the node is out-node.
+    ///
+    /// Returns true when the node is out-node.
+    static bool outNode(const Node& n) {
+      return !n.in_node;
+    }
+
+    /// \brief Returns true when the edge is edge in the original graph.
+    ///
+    /// Returns true when the edge is edge in the original graph.
+    static bool origEdge(const Edge& e) {
+      return e.item.firstState();
+    }
+
+    /// \brief Returns true when the edge binds an in-node and an out-node.
+    ///
+    /// Returns true when the edge binds an in-node and an out-node.
+    static bool bindEdge(const Edge& e) {
+      return e.item.secondState();
+    }
+
+    /// \brief Gives back the in-node created from the \c node.
+    ///
+    /// Gives back the in-node created from the \c node.
+    static Node inNode(const GraphNode& n) {
+      return Node(n, true);
+    }
+
+    /// \brief Gives back the out-node created from the \c node.
+    ///
+    /// Gives back the out-node created from the \c node.
+    static Node outNode(const GraphNode& n) {
+      return Node(n, false);
+    }
+
+    /// \brief Gives back the edge binds the two part of the node.
+    /// 
+    /// Gives back the edge binds the two part of the node.
+    static Edge edge(const GraphNode& n) {
+      return Edge(n);
+    }
+
+    /// \brief Gives back the edge of the original edge.
+    /// 
+    /// Gives back the edge of the original edge.
+    static Edge edge(const GraphEdge& e) {
+      return Edge(e);
+    }
+
+    typedef True NodeNumTag;
+
+    int nodeNum() const {
+      return  2 * countNodes(*Parent::graph);
+    }
+
+    typedef True EdgeNumTag;
+    
+    int edgeNum() const {
+      return countEdges(*Parent::graph) + countNodes(*Parent::graph);
+    }
+
+    typedef True FindEdgeTag;
+
+    Edge findEdge(const Node& u, const Node& v, 
+		  const Edge& prev = INVALID) const {
+      if (inNode(u)) {
+        if (outNode(v)) {
+          if (static_cast<const GraphNode&>(u) == 
+              static_cast<const GraphNode&>(v) && prev == INVALID) {
+            return Edge(u);
+          }
+        }
+      } else {
+        if (inNode(v)) {
+          return Edge(findEdge(*Parent::graph, u, v, prev));
+        }
+      }
+      return INVALID;
+    }
+
+    
+    template <typename T>
+    class NodeMap : public MapBase<Node, T> {
+      typedef typename Parent::template NodeMap<T> NodeImpl;
+    public:
+      NodeMap(const SplitGraphAdaptorBase& _graph) 
+	: inNodeMap(_graph), outNodeMap(_graph) {}
+      NodeMap(const SplitGraphAdaptorBase& _graph, const T& t) 
+	: inNodeMap(_graph, t), outNodeMap(_graph, t) {}
+      NodeMap& operator=(const NodeMap& cmap) {
+        return operator=<NodeMap>(cmap);
+      }
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+
+      void set(const Node& key, const T& val) {
+	if (SplitGraphAdaptorBase::inNode(key)) { inNodeMap.set(key, val); }
+	else {outNodeMap.set(key, val); }
+      }
+      
+      typename MapTraits<NodeImpl>::ReturnValue 
+      operator[](const Node& key) {
+	if (SplitGraphAdaptorBase::inNode(key)) { return inNodeMap[key]; }
+	else { return outNodeMap[key]; }
+      }
+
+      typename MapTraits<NodeImpl>::ConstReturnValue
+      operator[](const Node& key) const {
+	if (SplitGraphAdaptorBase::inNode(key)) { return inNodeMap[key]; }
+	else { return outNodeMap[key]; }
+      }
+
+    private:
+      NodeImpl inNodeMap, outNodeMap;
+    };
+
+    template <typename T>
+    class EdgeMap : public MapBase<Edge, T> {
+      typedef typename Parent::template EdgeMap<T> EdgeMapImpl;
+      typedef typename Parent::template NodeMap<T> NodeMapImpl;
+    public:
+
+      EdgeMap(const SplitGraphAdaptorBase& _graph) 
+	: edge_map(_graph), node_map(_graph) {}
+      EdgeMap(const SplitGraphAdaptorBase& _graph, const T& t) 
+	: edge_map(_graph, t), node_map(_graph, t) {}
+      EdgeMap& operator=(const EdgeMap& cmap) {
+        return operator=<EdgeMap>(cmap);
+      }
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+      
+      void set(const Edge& key, const T& val) {
+	if (SplitGraphAdaptorBase::origEdge(key)) { 
+          edge_map.set(key.item.first(), val); 
+        } else {
+          node_map.set(key.item.second(), val); 
+        }
+      }
+      
+      typename MapTraits<EdgeMapImpl>::ReturnValue
+      operator[](const Edge& key) {
+	if (SplitGraphAdaptorBase::origEdge(key)) { 
+          return edge_map[key.item.first()];
+        } else {
+          return node_map[key.item.second()];
+        }
+      }
+
+      typename MapTraits<EdgeMapImpl>::ConstReturnValue
+      operator[](const Edge& key) const {
+	if (SplitGraphAdaptorBase::origEdge(key)) { 
+          return edge_map[key.item.first()];
+        } else {
+          return node_map[key.item.second()];
+        }
+      }
+
+    private:
+      typename Parent::template EdgeMap<T> edge_map;
+      typename Parent::template NodeMap<T> node_map;
+    };
+
+
+  };
+
+  template <typename _Graph, typename NodeEnable = void, 
+            typename EdgeEnable = void>
+  class AlterableSplitGraphAdaptor 
+    : public GraphAdaptorExtender<SplitGraphAdaptorBase<_Graph> > {
+  public:
+
+    typedef GraphAdaptorExtender<SplitGraphAdaptorBase<_Graph> > Parent;
+    typedef _Graph Graph;
+
+    typedef typename Graph::Node GraphNode;
+    typedef typename Graph::Node GraphEdge;
+
+  protected:
+
+    AlterableSplitGraphAdaptor() : Parent() {}
+
+  public:
+    
+    typedef InvalidType NodeNotifier;
+    typedef InvalidType EdgeNotifier;
+
+  };
+
+  template <typename _Graph, typename EdgeEnable>
+  class AlterableSplitGraphAdaptor<
+    _Graph,
+    typename enable_if<typename _Graph::NodeNotifier::Notifier>::type,
+    EdgeEnable> 
+      : public GraphAdaptorExtender<SplitGraphAdaptorBase<_Graph> > {
+  public:
+
+    typedef GraphAdaptorExtender<SplitGraphAdaptorBase<_Graph> > Parent;
+    typedef _Graph Graph;
+
+    typedef typename Graph::Node GraphNode;
+    typedef typename Graph::Edge GraphEdge;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+ 
+  protected:
+
+    AlterableSplitGraphAdaptor() 
+      : Parent(), node_notifier(*this), node_notifier_proxy(*this) {}
+
+    void setGraph(_Graph& graph) {
+      Parent::setGraph(graph);
+      node_notifier_proxy.setNotifier(graph.notifier(GraphNode()));
+    }
+
+  public:
+
+    ~AlterableSplitGraphAdaptor() {
+      node_notifier.clear();
+    }
+
+    typedef AlterationNotifier<AlterableSplitGraphAdaptor, Node> NodeNotifier;
+    typedef InvalidType EdgeNotifier;
+
+    NodeNotifier& notifier(Node) const { return node_notifier; }
+
+  protected:
+
+    class NodeNotifierProxy : public Graph::NodeNotifier::ObserverBase {
+    public:
+
+      typedef typename Graph::NodeNotifier::ObserverBase Parent;
+      typedef AlterableSplitGraphAdaptor AdaptorBase;
+      
+      NodeNotifierProxy(const AdaptorBase& _adaptor)
+        : Parent(), adaptor(&_adaptor) {
+      }
+
+      virtual ~NodeNotifierProxy() {
+        if (Parent::attached()) {
+          Parent::detach();
+        }
+      }
+
+      void setNotifier(typename Graph::NodeNotifier& graph_notifier) {
+        Parent::attach(graph_notifier);
+      }
+
+      
+    protected:
+
+      virtual void add(const GraphNode& gn) {
+        std::vector<Node> nodes;
+        nodes.push_back(AdaptorBase::Parent::inNode(gn));
+        nodes.push_back(AdaptorBase::Parent::outNode(gn));
+        adaptor->notifier(Node()).add(nodes);
+      }
+
+      virtual void add(const std::vector<GraphNode>& gn) {
+        std::vector<Node> nodes;
+        for (int i = 0; i < int(gn.size()); ++i) {
+          nodes.push_back(AdaptorBase::Parent::inNode(gn[i]));
+          nodes.push_back(AdaptorBase::Parent::outNode(gn[i]));
+        }
+        adaptor->notifier(Node()).add(nodes);
+      }
+
+      virtual void erase(const GraphNode& gn) {
+        std::vector<Node> nodes;
+        nodes.push_back(AdaptorBase::Parent::inNode(gn));
+        nodes.push_back(AdaptorBase::Parent::outNode(gn));
+        adaptor->notifier(Node()).erase(nodes);
+      }
+
+      virtual void erase(const std::vector<GraphNode>& gn) {
+        std::vector<Node> nodes;
+        for (int i = 0; i < int(gn.size()); ++i) {
+          nodes.push_back(AdaptorBase::Parent::inNode(gn[i]));
+          nodes.push_back(AdaptorBase::Parent::outNode(gn[i]));
+        }
+        adaptor->notifier(Node()).erase(nodes);
+      }
+      virtual void build() {
+        adaptor->notifier(Node()).build();
+      }
+      virtual void clear() {
+        adaptor->notifier(Node()).clear();
+      }
+
+      const AdaptorBase* adaptor;
+    };
+
+
+    mutable NodeNotifier node_notifier;
+
+    NodeNotifierProxy node_notifier_proxy;
+
+  };
+
+  template <typename _Graph>
+  class AlterableSplitGraphAdaptor<
+    _Graph,
+    typename enable_if<typename _Graph::NodeNotifier::Notifier>::type,
+    typename enable_if<typename _Graph::EdgeNotifier::Notifier>::type> 
+      : public GraphAdaptorExtender<SplitGraphAdaptorBase<_Graph> > {
+  public:
+
+    typedef GraphAdaptorExtender<SplitGraphAdaptorBase<_Graph> > Parent;
+    typedef _Graph Graph;
+
+    typedef typename Graph::Node GraphNode;
+    typedef typename Graph::Edge GraphEdge;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+ 
+  protected:
+    
+    AlterableSplitGraphAdaptor() 
+      : Parent(), node_notifier(*this), edge_notifier(*this), 
+        node_notifier_proxy(*this), edge_notifier_proxy(*this) {}
+    
+    void setGraph(_Graph& g) {
+      Parent::setGraph(g);
+      node_notifier_proxy.setNotifier(g.notifier(GraphNode()));
+      edge_notifier_proxy.setNotifier(g.notifier(GraphEdge()));
+    }
+
+  public:
+
+    ~AlterableSplitGraphAdaptor() {
+      node_notifier.clear();
+      edge_notifier.clear();
+    }
+
+    typedef AlterationNotifier<AlterableSplitGraphAdaptor, Node> NodeNotifier;
+    typedef AlterationNotifier<AlterableSplitGraphAdaptor, Edge> EdgeNotifier;
+
+    NodeNotifier& notifier(Node) const { return node_notifier; }
+    EdgeNotifier& notifier(Edge) const { return edge_notifier; }
+
+  protected:
+
+    class NodeNotifierProxy : public Graph::NodeNotifier::ObserverBase {
+    public:
+      
+      typedef typename Graph::NodeNotifier::ObserverBase Parent;
+      typedef AlterableSplitGraphAdaptor AdaptorBase;
+      
+      NodeNotifierProxy(const AdaptorBase& _adaptor)
+        : Parent(), adaptor(&_adaptor) {
+      }
+
+      virtual ~NodeNotifierProxy() {
+        if (Parent::attached()) {
+          Parent::detach();
+        }
+      }
+
+      void setNotifier(typename Graph::NodeNotifier& graph_notifier) {
+        Parent::attach(graph_notifier);
+      }
+
+      
+    protected:
+
+      virtual void add(const GraphNode& gn) {
+        std::vector<Node> nodes;
+        nodes.push_back(AdaptorBase::Parent::inNode(gn));
+        nodes.push_back(AdaptorBase::Parent::outNode(gn));
+        adaptor->notifier(Node()).add(nodes);
+        adaptor->notifier(Edge()).add(AdaptorBase::Parent::edge(gn));
+      }
+      virtual void add(const std::vector<GraphNode>& gn) {
+        std::vector<Node> nodes;
+        std::vector<Edge> edges;
+        for (int i = 0; i < int(gn.size()); ++i) {
+          edges.push_back(AdaptorBase::Parent::edge(gn[i]));
+          nodes.push_back(AdaptorBase::Parent::inNode(gn[i]));
+          nodes.push_back(AdaptorBase::Parent::outNode(gn[i]));
+        }
+        adaptor->notifier(Node()).add(nodes);
+        adaptor->notifier(Edge()).add(edges);
+      }
+      virtual void erase(const GraphNode& gn) {
+        adaptor->notifier(Edge()).erase(AdaptorBase::Parent::edge(gn));
+        std::vector<Node> nodes;
+        nodes.push_back(AdaptorBase::Parent::inNode(gn));
+        nodes.push_back(AdaptorBase::Parent::outNode(gn));
+        adaptor->notifier(Node()).erase(nodes);
+      }
+      virtual void erase(const std::vector<GraphNode>& gn) {
+        std::vector<Node> nodes;
+        std::vector<Edge> edges;
+        for (int i = 0; i < int(gn.size()); ++i) {
+          edges.push_back(AdaptorBase::Parent::edge(gn[i]));
+          nodes.push_back(AdaptorBase::Parent::inNode(gn[i]));
+          nodes.push_back(AdaptorBase::Parent::outNode(gn[i]));
+        }
+        adaptor->notifier(Edge()).erase(edges);
+        adaptor->notifier(Node()).erase(nodes);
+      }
+      virtual void build() {
+        std::vector<Edge> edges;
+        const typename Parent::Notifier* nf = Parent::notifier();
+        GraphNode it;
+        for (nf->first(it); it != INVALID; nf->next(it)) {
+          edges.push_back(AdaptorBase::Parent::edge(it));
+        }
+        adaptor->notifier(Node()).build();
+        adaptor->notifier(Edge()).add(edges);        
+      }
+      virtual void clear() {
+        std::vector<Edge> edges;
+        const typename Parent::Notifier* nf = Parent::notifier();
+        GraphNode it;
+        for (nf->first(it); it != INVALID; nf->next(it)) {
+          edges.push_back(AdaptorBase::Parent::edge(it));
+        }
+        adaptor->notifier(Edge()).erase(edges);        
+        adaptor->notifier(Node()).clear();
+      }
+
+      const AdaptorBase* adaptor;
+    };
+
+    class EdgeNotifierProxy : public Graph::EdgeNotifier::ObserverBase {
+    public:
+
+      typedef typename Graph::EdgeNotifier::ObserverBase Parent;
+      typedef AlterableSplitGraphAdaptor AdaptorBase;
+      
+      EdgeNotifierProxy(const AdaptorBase& _adaptor)
+        : Parent(), adaptor(&_adaptor) {
+      }
+
+      virtual ~EdgeNotifierProxy() {
+        if (Parent::attached()) {
+          Parent::detach();
+        }
+      }
+
+      void setNotifier(typename Graph::EdgeNotifier& graph_notifier) {
+        Parent::attach(graph_notifier);
+      }
+
+      
+    protected:
+
+      virtual void add(const GraphEdge& ge) {
+        adaptor->notifier(Edge()).add(AdaptorBase::edge(ge));
+      }
+      virtual void add(const std::vector<GraphEdge>& ge) {
+        std::vector<Edge> edges;
+        for (int i = 0; i < int(ge.size()); ++i) {
+          edges.push_back(AdaptorBase::edge(ge[i]));
+        }
+        adaptor->notifier(Edge()).add(edges);
+      }
+      virtual void erase(const GraphEdge& ge) {
+        adaptor->notifier(Edge()).erase(AdaptorBase::edge(ge));
+      }
+      virtual void erase(const std::vector<GraphEdge>& ge) {
+        std::vector<Edge> edges;
+        for (int i = 0; i < int(ge.size()); ++i) {
+          edges.push_back(AdaptorBase::edge(ge[i]));
+        }
+        adaptor->notifier(Edge()).erase(edges);
+      }
+      virtual void build() {
+        std::vector<Edge> edges;
+        const typename Parent::Notifier* nf = Parent::notifier();
+        GraphEdge it;
+        for (nf->first(it); it != INVALID; nf->next(it)) {
+          edges.push_back(AdaptorBase::Parent::edge(it));
+        }
+        adaptor->notifier(Edge()).add(edges);
+      }
+      virtual void clear() {
+        std::vector<Edge> edges;
+        const typename Parent::Notifier* nf = Parent::notifier();
+        GraphEdge it;
+        for (nf->first(it); it != INVALID; nf->next(it)) {
+          edges.push_back(AdaptorBase::Parent::edge(it));
+        }
+        adaptor->notifier(Edge()).erase(edges);
+      }
+
+      const AdaptorBase* adaptor;
+    };
+
+
+    mutable NodeNotifier node_notifier;
+    mutable EdgeNotifier edge_notifier;
+
+    NodeNotifierProxy node_notifier_proxy;
+    EdgeNotifierProxy edge_notifier_proxy;
+
+  };
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief Split graph adaptor class
+  /// 
+  /// This is an graph adaptor which splits all node into an in-node
+  /// and an out-node. Formaly, the adaptor replaces each \f$ u \f$
+  /// node in the graph with two node, \f$ u_{in} \f$ node and 
+  /// \f$ u_{out} \f$ node. If there is an \f$ (v, u) \f$ edge in the 
+  /// original graph the new target of the edge will be \f$ u_{in} \f$ and
+  /// similarly the source of the original \f$ (u, v) \f$ edge will be
+  /// \f$ u_{out} \f$.  The adaptor will add for each node in the 
+  /// original graph an additional edge which will connect 
+  /// \f$ (u_{in}, u_{out}) \f$.
+  ///
+  /// The aim of this class is to run algorithm with node costs if the 
+  /// algorithm can use directly just edge costs. In this case we should use
+  /// a \c SplitGraphAdaptor and set the node cost of the graph to the
+  /// bind edge in the adapted graph.
+  /// 
+  /// By example a maximum flow algoritm can compute how many edge
+  /// disjoint paths are in the graph. But we would like to know how
+  /// many node disjoint paths are in the graph. First we have to
+  /// adapt the graph with the \c SplitGraphAdaptor. Then run the flow
+  /// algorithm on the adapted graph. The bottleneck of the flow will
+  /// be the bind edges which bounds the flow with the count of the
+  /// node disjoint paths.
+  ///
+  ///\code
+  ///
+  /// typedef SplitGraphAdaptor<SmartGraph> SGraph;
+  ///
+  /// SGraph sgraph(graph);
+  ///
+  /// typedef ConstMap<SGraph::Edge, int> SCapacity;
+  /// SCapacity scapacity(1);
+  ///
+  /// SGraph::EdgeMap<int> sflow(sgraph);
+  ///
+  /// Preflow<SGraph, SCapacity> 
+  ///   spreflow(sgraph, scapacity, 
+  ///            SGraph::outNode(source), SGraph::inNode(target));
+  ///                                            
+  /// spreflow.run();
+  ///
+  ///\endcode
+  ///
+  /// The result of the mamixum flow on the original graph
+  /// shows the next figure:
+  ///
+  /// \image html edge_disjoint.png
+  /// \image latex edge_disjoint.eps "Edge disjoint paths" width=\textwidth
+  /// 
+  /// And the maximum flow on the adapted graph:
+  ///
+  /// \image html node_disjoint.png
+  /// \image latex node_disjoint.eps "Node disjoint paths" width=\textwidth
+  ///
+  /// The second solution contains just 3 disjoint paths while the first 4.
+  /// The full code can be found in the \ref disjoint_paths_demo.cc demo file.
+  ///
+  /// This graph adaptor is fully conform to the 
+  /// \ref concepts::Graph "Graph" concept and
+  /// contains some additional member functions and types. The 
+  /// documentation of some member functions may be found just in the
+  /// SplitGraphAdaptorBase class.
+  ///
+  /// \sa SplitGraphAdaptorBase
+  template <typename _Graph>
+  class SplitGraphAdaptor : public AlterableSplitGraphAdaptor<_Graph> {
+  public:
+    typedef AlterableSplitGraphAdaptor<_Graph> Parent;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+    /// \brief Constructor of the adaptor.
+    ///
+    /// Constructor of the adaptor.
+    SplitGraphAdaptor(_Graph& g) {
+      Parent::setGraph(g);
+    }
+
+    /// \brief NodeMap combined from two original NodeMap
+    ///
+    /// This class adapt two of the original graph NodeMap to
+    /// get a node map on the adapted graph.
+    template <typename InNodeMap, typename OutNodeMap>
+    class CombinedNodeMap {
+    public:
+
+      typedef Node Key;
+      typedef typename InNodeMap::Value Value;
+
+      /// \brief Constructor
+      ///
+      /// Constructor.
+      CombinedNodeMap(InNodeMap& _inNodeMap, OutNodeMap& _outNodeMap) 
+	: inNodeMap(_inNodeMap), outNodeMap(_outNodeMap) {}
+
+      /// \brief The subscript operator.
+      ///
+      /// The subscript operator.
+      Value& operator[](const Key& key) {
+	if (Parent::inNode(key)) {
+	  return inNodeMap[key];
+	} else {
+	  return outNodeMap[key];
+	}
+      }
+
+      /// \brief The const subscript operator.
+      ///
+      /// The const subscript operator.
+      Value operator[](const Key& key) const {
+	if (Parent::inNode(key)) {
+	  return inNodeMap[key];
+	} else {
+	  return outNodeMap[key];
+	}
+      }
+
+      /// \brief The setter function of the map.
+      /// 
+      /// The setter function of the map.
+      void set(const Key& key, const Value& value) {
+	if (Parent::inNode(key)) {
+	  inNodeMap.set(key, value);
+	} else {
+	  outNodeMap.set(key, value);
+	}
+      }
+      
+    private:
+      
+      InNodeMap& inNodeMap;
+      OutNodeMap& outNodeMap;
+      
+    };
+
+
+    /// \brief Just gives back a combined node map.
+    /// 
+    /// Just gives back a combined node map.
+    template <typename InNodeMap, typename OutNodeMap>
+    static CombinedNodeMap<InNodeMap, OutNodeMap> 
+    combinedNodeMap(InNodeMap& in_map, OutNodeMap& out_map) {
+      return CombinedNodeMap<InNodeMap, OutNodeMap>(in_map, out_map);
+    }
+
+    template <typename InNodeMap, typename OutNodeMap>
+    static CombinedNodeMap<const InNodeMap, OutNodeMap> 
+    combinedNodeMap(const InNodeMap& in_map, OutNodeMap& out_map) {
+      return CombinedNodeMap<const InNodeMap, OutNodeMap>(in_map, out_map);
+    }
+
+    template <typename InNodeMap, typename OutNodeMap>
+    static CombinedNodeMap<InNodeMap, const OutNodeMap> 
+    combinedNodeMap(InNodeMap& in_map, const OutNodeMap& out_map) {
+      return CombinedNodeMap<InNodeMap, const OutNodeMap>(in_map, out_map);
+    }
+
+    template <typename InNodeMap, typename OutNodeMap>
+    static CombinedNodeMap<const InNodeMap, const OutNodeMap> 
+    combinedNodeMap(const InNodeMap& in_map, const OutNodeMap& out_map) {
+      return CombinedNodeMap<const InNodeMap, 
+        const OutNodeMap>(in_map, out_map);
+    }
+
+    /// \brief EdgeMap combined from an original EdgeMap and NodeMap
+    ///
+    /// This class adapt an original graph EdgeMap and NodeMap to
+    /// get an edge map on the adapted graph.
+    template <typename GraphEdgeMap, typename GraphNodeMap>
+    class CombinedEdgeMap {
+    public:
+      
+      typedef Edge Key;
+      typedef typename GraphEdgeMap::Value Value;
+      
+      /// \brief Constructor
+      ///
+      /// Constructor.
+      CombinedEdgeMap(GraphEdgeMap& _edge_map, GraphNodeMap& _node_map) 
+	: edge_map(_edge_map), node_map(_node_map) {}
+
+      /// \brief The subscript operator.
+      ///
+      /// The subscript operator.
+      void set(const Edge& edge, const Value& val) {
+	if (Parent::origEdge(edge)) {
+	  edge_map.set(edge, val);
+	} else {
+	  node_map.set(edge, val);
+	}
+      }
+
+      /// \brief The const subscript operator.
+      ///
+      /// The const subscript operator.
+      Value operator[](const Key& edge) const {
+	if (Parent::origEdge(edge)) {
+	  return edge_map[edge];
+	} else {
+	  return node_map[edge];
+	}
+      }      
+
+      /// \brief The const subscript operator.
+      ///
+      /// The const subscript operator.
+      Value& operator[](const Key& edge) {
+	if (Parent::origEdge(edge)) {
+	  return edge_map[edge];
+	} else {
+	  return node_map[edge];
+	}
+      }      
+      
+    private:
+      GraphEdgeMap& edge_map;
+      GraphNodeMap& node_map;
+    };
+                    
+    /// \brief Just gives back a combined edge map.
+    /// 
+    /// Just gives back a combined edge map.
+    template <typename GraphEdgeMap, typename GraphNodeMap>
+    static CombinedEdgeMap<GraphEdgeMap, GraphNodeMap> 
+    combinedEdgeMap(GraphEdgeMap& edge_map, GraphNodeMap& node_map) {
+      return CombinedEdgeMap<GraphEdgeMap, GraphNodeMap>(edge_map, node_map);
+    }
+
+    template <typename GraphEdgeMap, typename GraphNodeMap>
+    static CombinedEdgeMap<const GraphEdgeMap, GraphNodeMap> 
+    combinedEdgeMap(const GraphEdgeMap& edge_map, GraphNodeMap& node_map) {
+      return CombinedEdgeMap<const GraphEdgeMap, 
+        GraphNodeMap>(edge_map, node_map);
+    }
+
+    template <typename GraphEdgeMap, typename GraphNodeMap>
+    static CombinedEdgeMap<GraphEdgeMap, const GraphNodeMap> 
+    combinedEdgeMap(GraphEdgeMap& edge_map, const GraphNodeMap& node_map) {
+      return CombinedEdgeMap<GraphEdgeMap, 
+        const GraphNodeMap>(edge_map, node_map);
+    }
+
+    template <typename GraphEdgeMap, typename GraphNodeMap>
+    static CombinedEdgeMap<const GraphEdgeMap, const GraphNodeMap> 
+    combinedEdgeMap(const GraphEdgeMap& edge_map, 
+                    const GraphNodeMap& node_map) {
+      return CombinedEdgeMap<const GraphEdgeMap, 
+        const GraphNodeMap>(edge_map, node_map);
+    }
+
+  };
+
+  /// \brief Just gives back a split graph adaptor
+  ///
+  /// Just gives back a split graph adaptor
+  template<typename Graph>
+  SplitGraphAdaptor<Graph>
+  splitGraphAdaptor(const Graph& graph) {
+    return SplitGraphAdaptor<Graph>(graph);
+  }
+
+
+} //namespace lemon
+
+#endif //LEMON_GRAPH_ADAPTOR_H
+
Index: lemon/graph_reader.h
===================================================================
--- lemon/graph_reader.h	(revision 2553)
+++ lemon/graph_reader.h	(revision 2553)
@@ -0,0 +1,1195 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup lemon_io
+///\file
+///\brief Lemon Graph Format reader.
+
+#ifndef LEMON_GRAPH_READER_H
+#define LEMON_GRAPH_READER_H
+
+#include <iostream>
+
+#include <lemon/error.h>
+#include <lemon/lemon_reader.h>
+
+namespace lemon {
+
+  /// \addtogroup lemon_io
+  /// @{
+
+  /// \brief The graph reader class.
+  ///
+  /// The \c GraphReader class provides the graph input. 
+  /// Before you read this documentation it might be useful to read the general
+  /// description of  \ref graph-io-page "Graph Input-Output".
+  ///
+  /// The file to be read may contain several maps and labeled
+  /// (designated) nodes or edges.
+  ///
+  /// If you read a graph you need not read all the maps and items just those
+  /// that you need. The interface of the \c GraphReader is very similar to
+  /// the GraphWriter but the reading method does not depend on the order the
+  /// given commands (i.e. you don't have to insist on the order in which the
+  /// maps are given in the file).
+  ///
+  /// The reader object assumes that not read values do not contain 
+  /// whitespaces, therefore it has some extra possibilities to control how
+  /// it should skip the values when the string representation contains spaces.
+  ///
+  ///\code
+  /// GraphReader<ListGraph> reader(std::cin, graph);
+  ///\endcode
+  ///
+  /// The \c readNodeMap() function reads a map from the \c \@nodeset section.
+  /// If there is a map that you do not want to read from the file and there is
+  /// whitespace in the string represenation of the values then you should
+  /// call the \c skipNodeMap() template member function with proper 
+  /// parameters.
+  ///
+  ///\code
+  /// reader.readNodeMap("coords", coords);
+  ///
+  /// reader.skipNodeMap("description", desc);
+  ///
+  /// reader.readNodeMap("color", colorMap);
+  ///\endcode
+  ///
+  /// With the \c readEdgeMap() member function you can give an edge map
+  /// reading command similar to the NodeMaps. 
+  ///
+  ///\code
+  /// reader.readEdgeMap("weight", weightMap);
+  /// reader.readEdgeMap("label", labelMap);
+  ///\endcode
+  ///
+  /// With \c readNode() and \c readEdge() functions you can read 
+  /// labeled Nodes and Edges.
+  ///
+  ///\code
+  /// reader.readNode("source", sourceNode);
+  /// reader.readNode("target", targetNode);
+  ///
+  /// reader.readEdge("observed", edge);
+  ///\endcode
+  ///
+  /// With the \c readAttribute() functions you can read an attribute
+  /// into a variable. You can specify the reader for the attribute as
+  /// the nodemaps.
+  ///
+  /// After you give all read commands you must call the \c run() member
+  /// function, which executes all the commands.
+  ///
+  ///\code
+  /// reader.run();
+  ///\endcode
+  ///
+  /// \see DefaultReaderTraits
+  /// \see QuotedStringReader
+  /// \see \ref GraphWriter
+  /// \see \ref graph-io-page
+  /// \author Balazs Dezso
+  template <typename _Graph, typename _ReaderTraits = DefaultReaderTraits> 
+  class GraphReader {
+  public:
+    
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+
+    typedef _ReaderTraits ReaderTraits;
+    typedef typename ReaderTraits::Skipper DefaultSkipper;
+
+    /// \brief Construct a new GraphReader.
+    ///
+    /// Construct a new GraphReader. It reads into the given graph
+    /// and it uses the given reader as the default skipper.
+    GraphReader(std::istream& _is, Graph& _graph, 
+		const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : reader(new LemonReader(_is)), own_reader(true), skipper(_skipper),
+	nodeset_reader(*reader, _graph, std::string(), skipper),
+	edgeset_reader(*reader, _graph, nodeset_reader, 
+		       std::string(), skipper),
+	node_reader(*reader, nodeset_reader, std::string()),
+	edge_reader(*reader, edgeset_reader, std::string()),
+	attribute_reader(*reader, std::string()) {}
+
+    /// \brief Construct a new GraphReader.
+    ///
+    /// Construct a new GraphReader. It reads into the given graph
+    /// and it uses the given reader as the default skipper.
+    GraphReader(const std::string& _filename, Graph& _graph, 
+		const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : reader(new LemonReader(_filename)), own_reader(true), 
+	skipper(_skipper),
+	nodeset_reader(*reader, _graph, std::string(), skipper),
+	edgeset_reader(*reader, _graph, nodeset_reader, 
+		       std::string(), skipper),
+	node_reader(*reader, nodeset_reader, std::string()),
+	edge_reader(*reader, edgeset_reader, std::string()),
+	attribute_reader(*reader, std::string()) {}
+
+    /// \brief Construct a new GraphReader.
+    ///
+    /// Construct a new GraphReader. It reads into the given graph
+    /// and it uses the given reader as the default skipper.
+    GraphReader(LemonReader& _reader, Graph& _graph, 
+		const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : reader(_reader), own_reader(false), skipper(_skipper),
+	nodeset_reader(*reader, _graph, std::string(), skipper),
+	edgeset_reader(*reader, _graph, nodeset_reader, 
+		       std::string(), skipper),
+	node_reader(*reader, nodeset_reader, std::string()),
+	edge_reader(*reader, edgeset_reader, std::string()),
+	attribute_reader(*reader, std::string()) {}
+
+    /// \brief Destruct the graph reader.
+    ///
+    /// Destruct the graph reader.
+    ~GraphReader() {
+      if (own_reader) 
+	delete reader;
+    }
+
+    /// \brief Give a new node map reading command to the reader.
+    ///
+    /// Give a new node map reading command to the reader.
+    template <typename Map>
+    GraphReader& readNodeMap(std::string name, Map& map) {
+      nodeset_reader.readNodeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    GraphReader& readNodeMap(std::string name, const Map& map) {
+      nodeset_reader.readNodeMap(name, map);
+      return *this;
+    }
+
+    /// \brief Give a new node map reading command to the reader.
+    ///
+    /// Give a new node map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    GraphReader& readNodeMap(std::string name, Map& map, 
+			     const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readNodeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    GraphReader& readNodeMap(std::string name, const Map& map, 
+			     const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readNodeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new node map skipping command to the reader.
+    ///
+    /// Give a new node map skipping command to the reader.
+    template <typename ItemReader>
+    GraphReader& skipNodeMap(std::string name, 
+			     const ItemReader& ir = ItemReader()) {
+      nodeset_reader.skipNodeMap(name, ir);
+      return *this;
+    }
+
+    /// \brief Give a new edge map reading command to the reader.
+    ///
+    /// Give a new edge map reading command to the reader.
+    template <typename Map>
+    GraphReader& readEdgeMap(std::string name, Map& map) { 
+      edgeset_reader.readEdgeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    GraphReader& readEdgeMap(std::string name, const Map& map) { 
+      edgeset_reader.readEdgeMap(name, map);
+      return *this;
+    }
+
+
+    /// \brief Give a new edge map reading command to the reader.
+    ///
+    /// Give a new edge map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    GraphReader& readEdgeMap(std::string name, Map& map,
+			     const ItemReader& ir = ItemReader()) {
+      edgeset_reader.readEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    GraphReader& readEdgeMap(std::string name, const Map& map,
+			     const ItemReader& ir = ItemReader()) {
+      edgeset_reader.readEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new edge map skipping command to the reader.
+    ///
+    /// Give a new edge map skipping command to the reader.
+    template <typename ItemReader>
+    GraphReader& skipEdgeMap(std::string name, 
+			     const ItemReader& ir = ItemReader()) {
+      edgeset_reader.skipEdgeMap(name, ir);
+      return *this;
+    }
+
+    /// \brief Give a new labeled node reading command to the reader.
+    ///
+    /// Give a new labeled node reading command to the reader.
+    GraphReader& readNode(std::string name, Node& node) {
+      node_reader.readNode(name, node);
+      return *this;
+    }
+
+    /// \brief Give a new labeled edge reading command to the reader.
+    ///
+    /// Give a new labeled edge reading command to the reader.
+    GraphReader& readEdge(std::string name, Edge& edge) {
+      edge_reader.readEdge(name, edge);
+      return *this;
+    }
+
+    /// \brief Give a new attribute reading command.
+    ///
+    ///  Give a new attribute reading command.
+    template <typename Value>
+    GraphReader& readAttribute(std::string name, Value& value) {
+      attribute_reader.readAttribute(name, value);
+      return *this;
+    }
+    
+    /// \brief Give a new attribute reading command.
+    ///
+    ///  Give a new attribute reading command.
+    template <typename ItemReader, typename Value>
+    GraphReader& readAttribute(std::string name, Value& value, 
+			       const ItemReader& ir = ItemReader()) {
+      attribute_reader.readAttribute(name, value, ir);
+      return *this;
+    }
+
+    /// \brief Conversion operator to LemonReader.
+    ///
+    /// Conversion operator to LemonReader. It makes possible to access the
+    /// encapsulated \e LemonReader, this way you can attach to this reader
+    /// new instances of \e LemonReader::SectionReader. For more details see
+    /// the \ref rwbackground "Background of Reading and Writing".
+    operator LemonReader&() {
+      return *reader;
+    }
+
+    /// \brief Executes the reading commands.
+    ///
+    /// Executes the reading commands.
+    void run() {
+      reader->run();
+    }
+
+
+    /// \brief Returns true if the reader can give back the items by its label.
+    ///
+    /// \brief Returns true if the reader can give back the items by its label.
+    bool isLabelReader() const {
+      return nodeset_reader.isLabelReader() && edgeset_reader.isLabelReader();
+    }
+
+    /// \brief Gives back the node by its label.
+    ///
+    /// It reads an label from the stream and gives back which node belongs to
+    /// it. It is possible only if there was read a "label" named node map.
+    void readLabel(std::istream& is, Node& node) const {
+      nodeset_reader.readLabel(is, node);
+    } 
+
+    /// \brief Gives back the edge by its label.
+    ///
+    /// It reads an label from the stream and gives back which edge belongs to
+    /// it. It is possible only if there was read a "label" named edge map.
+    void readLabel(std::istream& is, Edge& edge) const {
+      edgeset_reader.readLabel(is, edge);
+    } 
+
+  private:
+
+    LemonReader* reader;
+    bool own_reader;
+
+    DefaultSkipper skipper;
+
+    NodeSetReader<Graph, ReaderTraits> nodeset_reader;
+    EdgeSetReader<Graph, ReaderTraits> edgeset_reader;
+
+    NodeReader<Graph> node_reader;
+    EdgeReader<Graph> edge_reader;
+    
+    AttributeReader<ReaderTraits> attribute_reader;
+  };
+
+
+  /// \brief The undirected graph reader class.
+  ///
+  /// The \c UGraphReader class provides the graph input. 
+  /// Before you read this documentation it might be useful to read the general
+  /// description of  \ref graph-io-page "Graph Input-Output".
+  ///
+  /// The given file format may contain several maps and labeled nodes or 
+  /// edges.
+  ///
+  /// If you read a graph you need not read all the maps and items just those
+  /// that you need. The interface of the \c UGraphReader is very similar
+  /// to the UGraphWriter but the reading method does not depend on the
+  /// order of the given commands.
+  ///
+  /// The reader object suppose that each not read value does not contain 
+  /// whitespaces, therefore it has some extra possibilities to control how
+  /// it should skip the values when the string representation contains spaces.
+  ///
+  ///\code
+  /// UGraphReader<ListUGraph> reader(std::cin, graph);
+  ///\endcode
+  ///
+  /// The \c readNodeMap() function reads a map from the \c \@nodeset section.
+  /// If there is a map that you do not want to read from the file and there is
+  /// whitespace in the string represenation of the values then you should
+  /// call the \c skipNodeMap() template member function with proper 
+  /// parameters.
+  ///
+  ///\code
+  /// reader.readNodeMap("coords", coords);
+  ///
+  /// reader.skipNodeMap("description", desc);
+  ///
+  /// reader.readNodeMap("color", colorMap);
+  ///\endcode
+  ///
+  /// With the \c readUEdgeMap() member function you can give an 
+  /// uedge map reading command similar to the NodeMaps. 
+  ///
+  ///\code
+  /// reader.readUEdgeMap("capacity", capacityMap);
+  ///\endcode
+  ///
+  /// The reading of the directed edge maps is just a syntactical sugar.
+  /// It reads two undirected edgemaps into a directed edge map. The 
+  /// undirected edge maps' name should be start with the \c '+' and the
+  /// \c '-' character and the same.
+  ///
+  ///\code
+  /// reader.readEdgeMap("flow", flowMap);
+  ///\endcode 
+  ///
+  /// With \c readNode() and \c readUEdge() functions you can read 
+  /// labeled Nodes and UEdges.
+  ///
+  ///\code
+  /// reader.readNode("source", sourceNode);
+  /// reader.readNode("target", targetNode);
+  ///
+  /// reader.readUEdge("observed", uEdge);
+  ///\endcode
+  ///
+  /// With the \c readAttribute() functions you can read an attribute
+  /// in a variable. You can specify the reader for the attribute as
+  /// the nodemaps.
+  ///
+  /// After you give all read commands you must call the \c run() member
+  /// function, which execute all the commands.
+  ///
+  ///\code
+  /// reader.run();
+  ///\endcode
+  ///
+  /// \see GraphReader
+  /// \see DefaultReaderTraits
+  /// \see \ref UGraphWriter
+  /// \see \ref graph-io-page
+  ///
+  /// \author Balazs Dezso
+  template <typename _Graph, typename _ReaderTraits = DefaultReaderTraits> 
+  class UGraphReader {
+  public:
+    
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+
+    typedef _ReaderTraits ReaderTraits;
+    typedef typename ReaderTraits::Skipper DefaultSkipper;
+
+    /// \brief Construct a new UGraphReader.
+    ///
+    /// Construct a new UGraphReader. It reads into the given graph
+    /// and it use the given reader as the default skipper.
+    UGraphReader(std::istream& _is, Graph& _graph, 
+		     const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : reader(new LemonReader(_is)), own_reader(true), skipper(_skipper),
+	nodeset_reader(*reader, _graph, std::string(), skipper),
+	uedgeset_reader(*reader, _graph, nodeset_reader, 
+			     std::string(), skipper),
+	node_reader(*reader, nodeset_reader, std::string()),
+	uedge_reader(*reader, uedgeset_reader, std::string()),
+	attribute_reader(*reader, std::string()) {}
+
+    /// \brief Construct a new UGraphReader.
+    ///
+    /// Construct a new UGraphReader. It reads into the given graph
+    /// and it use the given reader as the default skipper.
+    UGraphReader(const std::string& _filename, Graph& _graph, 
+		     const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : reader(new LemonReader(_filename)), own_reader(true), 
+	skipper(_skipper),
+	nodeset_reader(*reader, _graph, std::string(), skipper),
+	uedgeset_reader(*reader, _graph, nodeset_reader, 
+			     std::string(), skipper),
+	node_reader(*reader, nodeset_reader, std::string()),
+	uedge_reader(*reader, uedgeset_reader, std::string()),
+	attribute_reader(*reader, std::string()) {}
+
+    /// \brief Construct a new UGraphReader.
+    ///
+    /// Construct a new UGraphReader. It reads into the given graph
+    /// and it use the given reader as the default skipper.
+    UGraphReader(LemonReader& _reader, Graph& _graph, 
+		     const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : reader(_reader), own_reader(false), skipper(_skipper),
+	nodeset_reader(*reader, _graph, std::string(), skipper),
+	uedgeset_reader(*reader, _graph, nodeset_reader, 
+			     std::string(), skipper),
+	node_reader(*reader, nodeset_reader, std::string()),
+	uedge_reader(*reader, uedgeset_reader, std::string()),
+	attribute_reader(*reader, std::string()) {}
+
+    /// \brief Destruct the graph reader.
+    ///
+    /// Destruct the graph reader.
+    ~UGraphReader() {
+      if (own_reader) 
+	delete reader;
+    }
+
+    /// \brief Give a new node map reading command to the reader.
+    ///
+    /// Give a new node map reading command to the reader.
+    template <typename Map>
+    UGraphReader& readNodeMap(std::string name, Map& map) {
+      nodeset_reader.readNodeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    UGraphReader& readNodeMap(std::string name, const Map& map) {
+      nodeset_reader.readNodeMap(name, map);
+      return *this;
+    }
+
+    /// \brief Give a new node map reading command to the reader.
+    ///
+    /// Give a new node map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    UGraphReader& readNodeMap(std::string name, Map& map, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readNodeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    UGraphReader& readNodeMap(std::string name, const Map& map, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readNodeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new node map skipping command to the reader.
+    ///
+    /// Give a new node map skipping command to the reader.
+    template <typename ItemReader>
+    UGraphReader& skipNodeMap(std::string name, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.skipNodeMap(name, ir);
+      return *this;
+    }
+
+    /// \brief Give a new undirected edge map reading command to the reader.
+    ///
+    /// Give a new undirected edge map reading command to the reader.
+    template <typename Map>
+    UGraphReader& readUEdgeMap(std::string name, Map& map) { 
+      uedgeset_reader.readUEdgeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    UGraphReader& readUEdgeMap(std::string name, const Map& map) { 
+      uedgeset_reader.readUEdgeMap(name, map);
+      return *this;
+    }
+
+
+    /// \brief Give a new undirected edge map reading command to the reader.
+    ///
+    /// Give a new undirected edge map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    UGraphReader& readUEdgeMap(std::string name, Map& map,
+                               const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.readUEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    UGraphReader& readUEdgeMap(std::string name, const Map& map,
+                               const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.readUEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new undirected edge map skipping command to the reader.
+    ///
+    /// Give a new undirected edge map skipping command to the reader.
+    template <typename ItemReader>
+    UGraphReader& skipUEdgeMap(std::string name,
+				       const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.skipUMap(name, ir);
+      return *this;
+    }
+
+
+    /// \brief Give a new edge map reading command to the reader.
+    ///
+    /// Give a new edge map reading command to the reader.
+    template <typename Map>
+    UGraphReader& readEdgeMap(std::string name, Map& map) { 
+      uedgeset_reader.readEdgeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    UGraphReader& readEdgeMap(std::string name, const Map& map) { 
+      uedgeset_reader.readEdgeMap(name, map);
+      return *this;
+    }
+
+
+    /// \brief Give a new edge map reading command to the reader.
+    ///
+    /// Give a new edge map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    UGraphReader& readEdgeMap(std::string name, Map& map,
+                              const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.readEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    UGraphReader& readEdgeMap(std::string name, const Map& map,
+                              const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.readEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new edge map skipping command to the reader.
+    ///
+    /// Give a new edge map skipping command to the reader.
+    template <typename ItemReader>
+    UGraphReader& skipEdgeMap(std::string name,
+                              const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.skipEdgeMap(name, ir);
+      return *this;
+    }
+
+    /// \brief Give a new labeled node reading command to the reader.
+    ///
+    /// Give a new labeled node reading command to the reader.
+    UGraphReader& readNode(std::string name, Node& node) {
+      node_reader.readNode(name, node);
+      return *this;
+    }
+
+    /// \brief Give a new labeled edge reading command to the reader.
+    ///
+    /// Give a new labeled edge reading command to the reader.
+    UGraphReader& readEdge(std::string name, Edge& edge) {
+      uedge_reader.readEdge(name, edge);
+    }
+
+    /// \brief Give a new labeled undirected edge reading command to the
+    /// reader.
+    ///
+    /// Give a new labeled undirected edge reading command to the reader.
+    UGraphReader& readUEdge(std::string name, UEdge& edge) {
+      uedge_reader.readUEdge(name, edge);
+    }
+
+    /// \brief Give a new attribute reading command.
+    ///
+    ///  Give a new attribute reading command.
+    template <typename Value>
+    UGraphReader& readAttribute(std::string name, Value& value) {
+      attribute_reader.readAttribute(name, value);
+      return *this;
+    }
+    
+    /// \brief Give a new attribute reading command.
+    ///
+    ///  Give a new attribute reading command.
+    template <typename ItemReader, typename Value>
+    UGraphReader& readAttribute(std::string name, Value& value, 
+			       const ItemReader& ir = ItemReader()) {
+      attribute_reader.readAttribute(name, value, ir);
+      return *this;
+    }
+
+    /// \brief Conversion operator to LemonReader.
+    ///
+    /// Conversion operator to LemonReader. It make possible
+    /// to access the encapsulated \e LemonReader, this way
+    /// you can attach to this reader new instances of 
+    /// \e LemonReader::SectionReader.
+    operator LemonReader&() {
+      return *reader;
+    }
+
+    /// \brief Executes the reading commands.
+    ///
+    /// Executes the reading commands.
+    void run() {
+      reader->run();
+    }
+
+
+    /// \brief Returns true if the reader can give back the items by its label.
+    ///
+    /// Returns true if the reader can give back the items by its label.
+    bool isLabelReader() const {
+      return nodeset_reader.isLabelReader() && 
+        uedgeset_reader.isLabelReader();
+    }
+
+    /// \brief Gives back the node by its label.
+    ///
+    /// It reads an label from the stream and gives back which node belongs to
+    /// it. It is possible only if there was read a "label" named node map.
+    void readLabel(std::istream& is, Node& node) const {
+      return nodeset_reader.readLabel(is, node);
+    } 
+
+    /// \brief Gives back the edge by its label
+    ///
+    /// It reads an label from the stream and gives back which edge belongs to
+    /// it. It is possible only if there was read a "label" named edge map.
+    void readLabel(std::istream& is, Edge& edge) const {
+      return uedgeset_reader.readLabel(is, edge);
+    } 
+
+    /// \brief Gives back the undirected edge by its label.
+    ///
+    /// It reads an label from the stream and gives back which undirected edge 
+    /// belongs to it. It is possible only if there was read a "label" named 
+    /// edge map.
+    void readLabel(std::istream& is, UEdge& uedge) const {
+      return uedgeset_reader.readLabel(is, uedge);
+    } 
+    
+
+  private:
+
+    LemonReader* reader;
+    bool own_reader;
+
+    DefaultSkipper skipper;
+
+    NodeSetReader<Graph, ReaderTraits> nodeset_reader;
+    UEdgeSetReader<Graph, ReaderTraits> uedgeset_reader;
+
+    NodeReader<Graph> node_reader;
+    UEdgeReader<Graph> uedge_reader;
+    
+    AttributeReader<ReaderTraits> attribute_reader;
+  };
+
+  /// \brief The bipartite graph reader class.
+  ///
+  /// The \c BpUGraphReader class provides the graph input. 
+  /// Before you read this documentation it might be useful to read the general
+  /// description of  \ref graph-io-page "Graph Input-Output".
+  ///
+  /// The given file format may contain several maps and labeled nodes or 
+  /// edges.
+  ///
+  /// If you read a graph you need not read all the maps and items just those
+  /// that you need. The interface of the \c BpUGraphReader is very similar
+  /// to the BpUGraphWriter but the reading method does not depend on the
+  /// order of the given commands.
+  ///
+  /// The reader object suppose that each not read value does not contain 
+  /// whitespaces, therefore it has some extra possibilities to control how
+  /// it should skip the values when the string representation contains spaces.
+  ///
+  ///\code
+  /// BpUGraphReader<ListBpUGraph> reader(std::cin, graph);
+  ///\endcode
+  ///
+  /// The \c readANodeMap() function reads a map from the A-part of
+  /// the\c \@bpnodeset section, while the \c readBNodeMap() reads
+  /// from the B-part of the section.  If you use the \c readNodeMap()
+  /// function, then the given map should appear in both part of the
+  /// section. If there is a map that you do not want to read from the
+  /// file and there is whitespace in the string represenation of the
+  /// values then you should call the \c skipANodeMap(), \c
+  /// skipBNodeMap() or \c skipNodeMap() template member function with
+  /// proper parameters.
+  ///
+  ///\code
+  /// reader.readNodeMap("coords", coords);
+  /// reader.readANodeMap("range", range);
+  /// reader.readANodeMap("benefit", benefit);
+  ///
+  /// reader.skipNodeMap("description", desc);
+  ///
+  /// reader.readNodeMap("color", colorMap);
+  ///\endcode
+  ///
+  /// With the \c readUEdgeMap() member function you can give an 
+  /// uedge map reading command similar to the NodeMaps. 
+  ///
+  ///\code
+  /// reader.readUEdgeMap("capacity", capacityMap);
+  /// reader.readEdgeMap("flow", flowMap);
+  ///\endcode 
+  ///
+  /// With \c readNode() and \c readUEdge() functions you can read 
+  /// labeled Nodes and UEdges.
+  ///
+  ///\code
+  /// reader.readNode("source", sourceNode);
+  /// reader.readNode("target", targetNode);
+  ///
+  /// reader.readUEdge("observed", uEdge);
+  ///\endcode
+  ///
+  /// With the \c readAttribute() functions you can read an attribute
+  /// in a variable. You can specify the reader for the attribute as
+  /// the nodemaps.
+  ///
+  /// After you give all read commands you must call the \c run() member
+  /// function, which execute all the commands.
+  ///
+  ///\code
+  /// reader.run();
+  ///\endcode
+  ///
+  /// \see GraphReader
+  /// \see DefaultReaderTraits
+  /// \see \ref UGraphWriter
+  /// \see \ref graph-io-page
+  ///
+  /// \author Balazs Dezso
+  template <typename _Graph, typename _ReaderTraits = DefaultReaderTraits> 
+  class BpUGraphReader {
+  public:
+    
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+
+    typedef _ReaderTraits ReaderTraits;
+    typedef typename ReaderTraits::Skipper DefaultSkipper;
+
+    /// \brief Construct a new BpUGraphReader.
+    ///
+    /// Construct a new BpUGraphReader. It reads into the given graph
+    /// and it use the given reader as the default skipper.
+    BpUGraphReader(std::istream& _is, Graph& _graph, 
+		     const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : reader(new LemonReader(_is)), own_reader(true), skipper(_skipper),
+	nodeset_reader(*reader, _graph, std::string(), skipper),
+	uedgeset_reader(*reader, _graph, nodeset_reader, 
+			     std::string(), skipper),
+	node_reader(*reader, nodeset_reader, std::string()),
+	uedge_reader(*reader, uedgeset_reader, std::string()),
+	attribute_reader(*reader, std::string()) {}
+
+    /// \brief Construct a new BpUGraphReader.
+    ///
+    /// Construct a new BpUGraphReader. It reads into the given graph
+    /// and it use the given reader as the default skipper.
+    BpUGraphReader(const std::string& _filename, Graph& _graph, 
+		     const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : reader(new LemonReader(_filename)), own_reader(true), 
+	skipper(_skipper),
+	nodeset_reader(*reader, _graph, std::string(), skipper),
+	uedgeset_reader(*reader, _graph, nodeset_reader, 
+			     std::string(), skipper),
+	node_reader(*reader, nodeset_reader, std::string()),
+	uedge_reader(*reader, uedgeset_reader, std::string()),
+	attribute_reader(*reader, std::string()) {}
+
+    /// \brief Construct a new BpUGraphReader.
+    ///
+    /// Construct a new BpUGraphReader. It reads into the given graph
+    /// and it use the given reader as the default skipper.
+    BpUGraphReader(LemonReader& _reader, Graph& _graph, 
+		     const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : reader(_reader), own_reader(false), skipper(_skipper),
+	nodeset_reader(*reader, _graph, std::string(), skipper),
+	uedgeset_reader(*reader, _graph, nodeset_reader, 
+			     std::string(), skipper),
+	node_reader(*reader, nodeset_reader, std::string()),
+	uedge_reader(*reader, uedgeset_reader, std::string()),
+	attribute_reader(*reader, std::string()) {}
+
+    /// \brief Destruct the graph reader.
+    ///
+    /// Destruct the graph reader.
+    ~BpUGraphReader() {
+      if (own_reader) 
+	delete reader;
+    }
+
+    /// \brief Give a new node map reading command to the reader.
+    ///
+    /// Give a new node map reading command to the reader.
+    template <typename Map>
+    BpUGraphReader& readNodeMap(std::string name, Map& map) {
+      nodeset_reader.readNodeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    BpUGraphReader& readNodeMap(std::string name, const Map& map) {
+      nodeset_reader.readNodeMap(name, map);
+      return *this;
+    }
+
+    /// \brief Give a new node map reading command to the reader.
+    ///
+    /// Give a new node map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readNodeMap(std::string name, Map& map, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readNodeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readNodeMap(std::string name, const Map& map, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readNodeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new node map skipping command to the reader.
+    ///
+    /// Give a new node map skipping command to the reader.
+    template <typename ItemReader>
+    BpUGraphReader& skipNodeMap(std::string name, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.skipNodeMap(name, ir);
+      return *this;
+    }
+
+    /// \brief Give a new A-node map reading command to the reader.
+    ///
+    /// Give a new A-node map reading command to the reader.
+    template <typename Map>
+    BpUGraphReader& readANodeMap(std::string name, Map& map) {
+      nodeset_reader.readANodeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    BpUGraphReader& readANodeMap(std::string name, const Map& map) {
+      nodeset_reader.readANodeMap(name, map);
+      return *this;
+    }
+
+    /// \brief Give a new A-node map reading command to the reader.
+    ///
+    /// Give a new A-node map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readANodeMap(std::string name, Map& map, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readANodeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readANodeMap(std::string name, const Map& map, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readNodeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new A-node map skipping command to the reader.
+    ///
+    /// Give a new A-node map skipping command to the reader.
+    template <typename ItemReader>
+    BpUGraphReader& skipANodeMap(std::string name, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.skipANodeMap(name, ir);
+      return *this;
+    }
+
+    /// \brief Give a new B-node map reading command to the reader.
+    ///
+    /// Give a new B-node map reading command to the reader.
+    template <typename Map>
+    BpUGraphReader& readBNodeMap(std::string name, Map& map) {
+      nodeset_reader.readBNodeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    BpUGraphReader& readBNodeMap(std::string name, const Map& map) {
+      nodeset_reader.readBNodeMap(name, map);
+      return *this;
+    }
+
+    /// \brief Give a new B-node map reading command to the reader.
+    ///
+    /// Give a new B-node map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readBNodeMap(std::string name, Map& map, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readBNodeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readBNodeMap(std::string name, const Map& map, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.readNodeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new B-node map skipping command to the reader.
+    ///
+    /// Give a new B-node map skipping command to the reader.
+    template <typename ItemReader>
+    BpUGraphReader& skipBNodeMap(std::string name, 
+                              const ItemReader& ir = ItemReader()) {
+      nodeset_reader.skipBNodeMap(name, ir);
+      return *this;
+    }
+
+    /// \brief Give a new undirected edge map reading command to the reader.
+    ///
+    /// Give a new undirected edge map reading command to the reader.
+    template <typename Map>
+    BpUGraphReader& readUEdgeMap(std::string name, Map& map) { 
+      uedgeset_reader.readUEdgeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    BpUGraphReader& readUEdgeMap(std::string name, const Map& map) { 
+      uedgeset_reader.readUEdgeMap(name, map);
+      return *this;
+    }
+
+
+    /// \brief Give a new undirected edge map reading command to the reader.
+    ///
+    /// Give a new undirected edge map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readUEdgeMap(std::string name, Map& map,
+                               const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.readUEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readUEdgeMap(std::string name, const Map& map,
+                               const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.readUEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new undirected edge map skipping command to the reader.
+    ///
+    /// Give a new undirected edge map skipping command to the reader.
+    template <typename ItemReader>
+    BpUGraphReader& skipUEdgeMap(std::string name,
+				       const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.skipUMap(name, ir);
+      return *this;
+    }
+
+
+    /// \brief Give a new edge map reading command to the reader.
+    ///
+    /// Give a new edge map reading command to the reader.
+    template <typename Map>
+    BpUGraphReader& readEdgeMap(std::string name, Map& map) { 
+      uedgeset_reader.readEdgeMap(name, map);
+      return *this;
+    }
+
+    template <typename Map>
+    BpUGraphReader& readEdgeMap(std::string name, const Map& map) { 
+      uedgeset_reader.readEdgeMap(name, map);
+      return *this;
+    }
+
+
+    /// \brief Give a new edge map reading command to the reader.
+    ///
+    /// Give a new edge map reading command to the reader.
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readEdgeMap(std::string name, Map& map,
+                              const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.readEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    template <typename ItemReader, typename Map>
+    BpUGraphReader& readEdgeMap(std::string name, const Map& map,
+                              const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.readEdgeMap(name, map, ir);
+      return *this;
+    }
+
+    /// \brief Give a new edge map skipping command to the reader.
+    ///
+    /// Give a new edge map skipping command to the reader.
+    template <typename ItemReader>
+    BpUGraphReader& skipEdgeMap(std::string name,
+                              const ItemReader& ir = ItemReader()) {
+      uedgeset_reader.skipEdgeMap(name, ir);
+      return *this;
+    }
+
+    /// \brief Give a new labeled node reading command to the reader.
+    ///
+    /// Give a new labeled node reading command to the reader.
+    BpUGraphReader& readNode(std::string name, Node& node) {
+      node_reader.readNode(name, node);
+      return *this;
+    }
+
+    /// \brief Give a new labeled edge reading command to the reader.
+    ///
+    /// Give a new labeled edge reading command to the reader.
+    BpUGraphReader& readEdge(std::string name, Edge& edge) {
+      uedge_reader.readEdge(name, edge);
+    }
+
+    /// \brief Give a new labeled undirected edge reading command to the
+    /// reader.
+    ///
+    /// Give a new labeled undirected edge reading command to the reader.
+    BpUGraphReader& readUEdge(std::string name, UEdge& edge) {
+      uedge_reader.readUEdge(name, edge);
+    }
+
+    /// \brief Give a new attribute reading command.
+    ///
+    ///  Give a new attribute reading command.
+    template <typename Value>
+    BpUGraphReader& readAttribute(std::string name, Value& value) {
+      attribute_reader.readAttribute(name, value);
+      return *this;
+    }
+    
+    /// \brief Give a new attribute reading command.
+    ///
+    ///  Give a new attribute reading command.
+    template <typename ItemReader, typename Value>
+    BpUGraphReader& readAttribute(std::string name, Value& value, 
+			       const ItemReader& ir = ItemReader()) {
+      attribute_reader.readAttribute(name, value, ir);
+      return *this;
+    }
+
+    /// \brief Conversion operator to LemonReader.
+    ///
+    /// Conversion operator to LemonReader. It make possible
+    /// to access the encapsulated \e LemonReader, this way
+    /// you can attach to this reader new instances of 
+    /// \e LemonReader::SectionReader.
+    operator LemonReader&() {
+      return *reader;
+    }
+
+    /// \brief Executes the reading commands.
+    ///
+    /// Executes the reading commands.
+    void run() {
+      reader->run();
+    }
+
+
+    /// \brief Returns true if the reader can give back the items by its label.
+    ///
+    /// Returns true if the reader can give back the items by its label.
+    bool isLabelReader() const {
+      return nodeset_reader.isLabelReader() && 
+        uedgeset_reader.isLabelReader();
+    }
+
+    /// \brief Gives back the node by its label.
+    ///
+    /// It reads an label from the stream and gives back which node belongs to
+    /// it. It is possible only if there was read a "label" named node map.
+    void readLabel(std::istream& is, Node& node) const {
+      return nodeset_reader.readLabel(is, node);
+    } 
+
+    /// \brief Gives back the edge by its label
+    ///
+    /// It reads an label from the stream and gives back which edge belongs to
+    /// it. It is possible only if there was read a "label" named edge map.
+    void readLabel(std::istream& is, Edge& edge) const {
+      return uedgeset_reader.readLabel(is, edge);
+    } 
+
+    /// \brief Gives back the undirected edge by its label.
+    ///
+    /// It reads an label from the stream and gives back which undirected edge 
+    /// belongs to it. It is possible only if there was read a "label" named 
+    /// edge map.
+    void readLabel(std::istream& is, UEdge& uedge) const {
+      return uedgeset_reader.readLabel(is, uedge);
+    } 
+    
+
+  private:
+
+    LemonReader* reader;
+    bool own_reader;
+
+    DefaultSkipper skipper;
+
+    BpNodeSetReader<Graph, ReaderTraits> nodeset_reader;
+    UEdgeSetReader<Graph, ReaderTraits> uedgeset_reader;
+
+    NodeReader<Graph> node_reader;
+    UEdgeReader<Graph> uedge_reader;
+    
+    AttributeReader<ReaderTraits> attribute_reader;
+  };
+
+
+  /// @}
+}
+
+#endif
Index: lemon/graph_to_eps.h
===================================================================
--- lemon/graph_to_eps.h	(revision 2618)
+++ lemon/graph_to_eps.h	(revision 2618)
@@ -0,0 +1,1171 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_GRAPH_TO_EPS_H
+#define LEMON_GRAPH_TO_EPS_H
+
+#include <sys/time.h>
+
+#ifdef WIN32
+#include <lemon/bits/mingw32_time.h>
+#endif
+
+#include<iostream>
+#include<fstream>
+#include<sstream>
+#include<algorithm>
+#include<vector>
+
+#include<ctime>
+
+#include<lemon/math.h>
+#include<lemon/bits/invalid.h>
+#include<lemon/dim2.h>
+#include<lemon/maps.h>
+#include<lemon/color.h>
+#include<lemon/bits/bezier.h>
+
+
+///\ingroup eps_io
+///\file
+///\brief Simple graph drawer
+///
+///\author Alpar Juttner
+
+namespace lemon {
+
+template<class MT>
+class _NegY {
+public:
+  typedef typename MT::Key Key;
+  typedef typename MT::Value Value;
+  const MT &map;
+  int yscale;
+  _NegY(const MT &m,bool b) : map(m), yscale(1-b*2) {}
+  Value operator[](Key n) { return Value(map[n].x,map[n].y*yscale);}
+};
+
+///Default traits class of \ref GraphToEps
+
+///Default traits class of \ref GraphToEps
+///
+///\c G is the type of the underlying graph.
+template<class G>
+struct DefaultGraphToEpsTraits
+{
+  typedef G Graph;
+  typedef typename Graph::Node Node;
+  typedef typename Graph::NodeIt NodeIt;
+  typedef typename Graph::Edge Edge;
+  typedef typename Graph::EdgeIt EdgeIt;
+  typedef typename Graph::InEdgeIt InEdgeIt;
+  typedef typename Graph::OutEdgeIt OutEdgeIt;
+  
+
+  const Graph &g;
+
+  std::ostream& os;
+  
+  typedef ConstMap<typename Graph::Node,dim2::Point<double> > CoordsMapType;
+  CoordsMapType _coords;
+  ConstMap<typename Graph::Node,double > _nodeSizes;
+  ConstMap<typename Graph::Node,int > _nodeShapes;
+
+  ConstMap<typename Graph::Node,Color > _nodeColors;
+  ConstMap<typename Graph::Edge,Color > _edgeColors;
+
+  ConstMap<typename Graph::Edge,double > _edgeWidths;
+
+  double _edgeWidthScale;
+  
+  double _nodeScale;
+  double _xBorder, _yBorder;
+  double _scale;
+  double _nodeBorderQuotient;
+  
+  bool _drawArrows;
+  double _arrowLength, _arrowWidth;
+  
+  bool _showNodes, _showEdges;
+
+  bool _enableParallel;
+  double _parEdgeDist;
+
+  bool _showNodeText;
+  ConstMap<typename Graph::Node,bool > _nodeTexts;  
+  double _nodeTextSize;
+
+  bool _showNodePsText;
+  ConstMap<typename Graph::Node,bool > _nodePsTexts;  
+  char *_nodePsTextsPreamble;
+  
+  bool _undirected;
+
+  bool _pleaseRemoveOsStream;
+
+  bool _scaleToA4;
+
+  std::string _title;
+  std::string _copyright;
+
+  enum NodeTextColorType 
+    { DIST_COL=0, DIST_BW=1, CUST_COL=2, SAME_COL=3 } _nodeTextColorType;
+  ConstMap<typename Graph::Node,Color > _nodeTextColors;
+
+  bool _autoNodeScale;
+  bool _autoEdgeWidthScale;
+
+  bool _absoluteNodeSizes;
+  bool _absoluteEdgeWidths;
+
+  bool _negY;
+
+  bool _preScale;
+  ///Constructor
+
+  ///Constructor
+  ///\param _g is a reference to the graph to be printed
+  ///\param _os is a reference to the output stream.
+  ///\param _os is a reference to the output stream.
+  ///\param _pros If it is \c true, then the \c ostream referenced by \c _os
+  ///will be explicitly deallocated by the destructor.
+  ///By default it is <tt>std::cout</tt>
+  DefaultGraphToEpsTraits(const G &_g,std::ostream& _os=std::cout,
+			  bool _pros=false) :
+    g(_g), os(_os),
+    _coords(dim2::Point<double>(1,1)), _nodeSizes(.01), _nodeShapes(0),
+    _nodeColors(WHITE), _edgeColors(BLACK),
+    _edgeWidths(1.0), _edgeWidthScale(0.003),
+    _nodeScale(1.0), _xBorder(10), _yBorder(10), _scale(1.0),
+    _nodeBorderQuotient(.1),
+    _drawArrows(false), _arrowLength(1), _arrowWidth(0.3),
+    _showNodes(true), _showEdges(true),
+    _enableParallel(false), _parEdgeDist(1),
+    _showNodeText(false), _nodeTexts(false), _nodeTextSize(1),
+    _showNodePsText(false), _nodePsTexts(false), _nodePsTextsPreamble(0),
+    _undirected(false),
+    _pleaseRemoveOsStream(_pros), _scaleToA4(false),
+    _nodeTextColorType(SAME_COL), _nodeTextColors(BLACK),
+    _autoNodeScale(false),
+    _autoEdgeWidthScale(false),
+    _absoluteNodeSizes(false),
+    _absoluteEdgeWidths(false),
+    _negY(false),
+    _preScale(true)
+  {}
+};
+
+///Helper class to implement the named parameters of \ref graphToEps()
+
+///Helper class to implement the named parameters of \ref graphToEps()
+///\todo Is 'helper class' a good name for this?
+///
+///\todo Follow PostScript's DSC.
+/// Use own dictionary.
+///\todo Useful new features.
+/// - Linestyles: dotted, dashed etc.
+/// - A second color and percent value for the lines.
+template<class T> class GraphToEps : public T 
+{
+  // Can't believe it is required by the C++ standard
+  using T::g;
+  using T::os;
+
+  using T::_coords;
+  using T::_nodeSizes;
+  using T::_nodeShapes;
+  using T::_nodeColors;
+  using T::_edgeColors;
+  using T::_edgeWidths;
+
+  using T::_edgeWidthScale;
+  using T::_nodeScale;
+  using T::_xBorder;
+  using T::_yBorder;
+  using T::_scale;
+  using T::_nodeBorderQuotient;
+  
+  using T::_drawArrows;
+  using T::_arrowLength;
+  using T::_arrowWidth;
+  
+  using T::_showNodes;
+  using T::_showEdges;
+
+  using T::_enableParallel;
+  using T::_parEdgeDist;
+
+  using T::_showNodeText;
+  using T::_nodeTexts;  
+  using T::_nodeTextSize;
+
+  using T::_showNodePsText;
+  using T::_nodePsTexts;  
+  using T::_nodePsTextsPreamble;
+  
+  using T::_undirected;
+
+  using T::_pleaseRemoveOsStream;
+
+  using T::_scaleToA4;
+
+  using T::_title;
+  using T::_copyright;
+
+  using T::NodeTextColorType;
+  using T::CUST_COL;
+  using T::DIST_COL;
+  using T::DIST_BW;
+  using T::_nodeTextColorType;
+  using T::_nodeTextColors;
+
+  using T::_autoNodeScale;
+  using T::_autoEdgeWidthScale;
+
+  using T::_absoluteNodeSizes;
+  using T::_absoluteEdgeWidths;
+
+
+  using T::_negY;
+  using T::_preScale;
+
+  // dradnats ++C eht yb deriuqer si ti eveileb t'naC
+
+  typedef typename T::Graph Graph;
+  typedef typename Graph::Node Node;
+  typedef typename Graph::NodeIt NodeIt;
+  typedef typename Graph::Edge Edge;
+  typedef typename Graph::EdgeIt EdgeIt;
+  typedef typename Graph::InEdgeIt InEdgeIt;
+  typedef typename Graph::OutEdgeIt OutEdgeIt;
+
+  static const int INTERPOL_PREC;
+  static const double A4HEIGHT;
+  static const double A4WIDTH;
+  static const double A4BORDER;
+
+  bool dontPrint;
+
+public:
+  ///Node shapes
+
+  ///Node shapes
+  ///
+  enum NodeShapes { 
+    /// = 0
+    ///\image html nodeshape_0.png
+    ///\image latex nodeshape_0.eps "CIRCLE shape (0)" width=2cm
+    CIRCLE=0, 
+    /// = 1
+    ///\image html nodeshape_1.png
+    ///\image latex nodeshape_1.eps "SQUARE shape (1)" width=2cm
+    ///
+    SQUARE=1, 
+    /// = 2
+    ///\image html nodeshape_2.png
+    ///\image latex nodeshape_2.eps "DIAMOND shape (2)" width=2cm
+    ///
+    DIAMOND=2,
+    /// = 3
+    ///\image html nodeshape_3.png
+    ///\image latex nodeshape_2.eps "MALE shape (4)" width=2cm
+    ///
+    MALE=3,
+    /// = 4
+    ///\image html nodeshape_4.png
+    ///\image latex nodeshape_2.eps "FEMALE shape (4)" width=2cm
+    ///
+    FEMALE=4
+  };
+
+private:
+  class edgeLess {
+    const Graph &g;
+  public:
+    edgeLess(const Graph &_g) : g(_g) {}
+    bool operator()(Edge a,Edge b) const 
+    {
+      Node ai=std::min(g.source(a),g.target(a));
+      Node aa=std::max(g.source(a),g.target(a));
+      Node bi=std::min(g.source(b),g.target(b));
+      Node ba=std::max(g.source(b),g.target(b));
+      return ai<bi ||
+	(ai==bi && (aa < ba || 
+		    (aa==ba && ai==g.source(a) && bi==g.target(b))));
+    }
+  };
+  bool isParallel(Edge e,Edge f) const
+  {
+    return (g.source(e)==g.source(f)&&
+	    g.target(e)==g.target(f)) ||
+      (g.source(e)==g.target(f)&&
+       g.target(e)==g.source(f));
+  }
+  template<class TT>
+  static std::string psOut(const dim2::Point<TT> &p) 
+    {
+      std::ostringstream os;	
+      os << p.x << ' ' << p.y;
+      return os.str();
+    }
+  static std::string psOut(const Color &c) 
+    {
+      std::ostringstream os;	
+      os << c.red() << ' ' << c.green() << ' ' << c.blue();
+      return os.str();
+    }
+  
+public:
+  GraphToEps(const T &t) : T(t), dontPrint(false) {};
+  
+  template<class X> struct CoordsTraits : public T {
+  typedef X CoordsMapType;
+    const X &_coords;
+    CoordsTraits(const T &t,const X &x) : T(t), _coords(x) {}
+  };
+  ///Sets the map of the node coordinates
+
+  ///Sets the map of the node coordinates.
+  ///\param x must be a node map with dim2::Point<double> or
+  ///\ref dim2::Point "dim2::Point<int>" values. 
+  template<class X> GraphToEps<CoordsTraits<X> > coords(const X &x) {
+    dontPrint=true;
+    return GraphToEps<CoordsTraits<X> >(CoordsTraits<X>(*this,x));
+  }
+  template<class X> struct NodeSizesTraits : public T {
+    const X &_nodeSizes;
+    NodeSizesTraits(const T &t,const X &x) : T(t), _nodeSizes(x) {}
+  };
+  ///Sets the map of the node sizes
+
+  ///Sets the map of the node sizes
+  ///\param x must be a node map with \c double (or convertible) values. 
+  template<class X> GraphToEps<NodeSizesTraits<X> > nodeSizes(const X &x)
+  {
+    dontPrint=true;
+    return GraphToEps<NodeSizesTraits<X> >(NodeSizesTraits<X>(*this,x));
+  }
+  template<class X> struct NodeShapesTraits : public T {
+    const X &_nodeShapes;
+    NodeShapesTraits(const T &t,const X &x) : T(t), _nodeShapes(x) {}
+  };
+  ///Sets the map of the node shapes
+
+  ///Sets the map of the node shapes.
+  ///The availabe shape values
+  ///can be found in \ref NodeShapes "enum NodeShapes".
+  ///\param x must be a node map with \c int (or convertible) values. 
+  ///\sa NodeShapes
+  template<class X> GraphToEps<NodeShapesTraits<X> > nodeShapes(const X &x)
+  {
+    dontPrint=true;
+    return GraphToEps<NodeShapesTraits<X> >(NodeShapesTraits<X>(*this,x));
+  }
+  template<class X> struct NodeTextsTraits : public T {
+    const X &_nodeTexts;
+    NodeTextsTraits(const T &t,const X &x) : T(t), _nodeTexts(x) {}
+  };
+  ///Sets the text printed on the nodes
+
+  ///Sets the text printed on the nodes
+  ///\param x must be a node map with type that can be pushed to a standard
+  ///ostream. 
+  template<class X> GraphToEps<NodeTextsTraits<X> > nodeTexts(const X &x)
+  {
+    dontPrint=true;
+    _showNodeText=true;
+    return GraphToEps<NodeTextsTraits<X> >(NodeTextsTraits<X>(*this,x));
+  }
+  template<class X> struct NodePsTextsTraits : public T {
+    const X &_nodePsTexts;
+    NodePsTextsTraits(const T &t,const X &x) : T(t), _nodePsTexts(x) {}
+  };
+  ///Inserts a PostScript block to the nodes
+
+  ///With this command it is possible to insert a verbatim PostScript
+  ///block to the nodes.
+  ///The PS current point will be moved to the centre of the node before
+  ///the PostScript block inserted.
+  ///
+  ///Before and after the block a newline character is inserted so you
+  ///don't have to bother with the separators.
+  ///
+  ///\param x must be a node map with type that can be pushed to a standard
+  ///ostream.
+  ///
+  ///\sa nodePsTextsPreamble()
+  ///\todo Offer the choise not to move to the centre but pass the coordinates
+  ///to the Postscript block inserted.
+  template<class X> GraphToEps<NodePsTextsTraits<X> > nodePsTexts(const X &x)
+  {
+    dontPrint=true;
+    _showNodePsText=true;
+    return GraphToEps<NodePsTextsTraits<X> >(NodePsTextsTraits<X>(*this,x));
+  }
+  template<class X> struct EdgeWidthsTraits : public T {
+    const X &_edgeWidths;
+    EdgeWidthsTraits(const T &t,const X &x) : T(t), _edgeWidths(x) {}
+  };
+  ///Sets the map of the edge widths
+
+  ///Sets the map of the edge widths
+  ///\param x must be a edge map with \c double (or convertible) values. 
+  template<class X> GraphToEps<EdgeWidthsTraits<X> > edgeWidths(const X &x)
+  {
+    dontPrint=true;
+    return GraphToEps<EdgeWidthsTraits<X> >(EdgeWidthsTraits<X>(*this,x));
+  }
+
+  template<class X> struct NodeColorsTraits : public T {
+    const X &_nodeColors;
+    NodeColorsTraits(const T &t,const X &x) : T(t), _nodeColors(x) {}
+  };
+  ///Sets the map of the node colors
+
+  ///Sets the map of the node colors
+  ///\param x must be a node map with \ref Color values.
+  ///
+  ///\sa Palette
+  template<class X> GraphToEps<NodeColorsTraits<X> >
+  nodeColors(const X &x)
+  {
+    dontPrint=true;
+    return GraphToEps<NodeColorsTraits<X> >(NodeColorsTraits<X>(*this,x));
+  }
+  template<class X> struct NodeTextColorsTraits : public T {
+    const X &_nodeTextColors;
+    NodeTextColorsTraits(const T &t,const X &x) : T(t), _nodeTextColors(x) {}
+  };
+  ///Sets the map of the node text colors
+
+  ///Sets the map of the node text colors
+  ///\param x must be a node map with \ref Color values. 
+  ///
+  ///\sa Palette
+  template<class X> GraphToEps<NodeTextColorsTraits<X> >
+  nodeTextColors(const X &x)
+  {
+    dontPrint=true;
+    _nodeTextColorType=CUST_COL;
+    return GraphToEps<NodeTextColorsTraits<X> >
+      (NodeTextColorsTraits<X>(*this,x));
+  }
+  template<class X> struct EdgeColorsTraits : public T {
+    const X &_edgeColors;
+    EdgeColorsTraits(const T &t,const X &x) : T(t), _edgeColors(x) {}
+  };
+  ///Sets the map of the edge colors
+
+  ///Sets the map of the edge colors
+  ///\param x must be a edge map with \ref Color values. 
+  ///
+  ///\sa Palette
+  template<class X> GraphToEps<EdgeColorsTraits<X> >
+  edgeColors(const X &x)
+  {
+    dontPrint=true;
+    return GraphToEps<EdgeColorsTraits<X> >(EdgeColorsTraits<X>(*this,x));
+  }
+  ///Sets a global scale factor for node sizes
+
+  ///Sets a global scale factor for node sizes.
+  /// 
+  /// If nodeSizes() is not given, this function simply sets the node
+  /// sizes to \c d.  If nodeSizes() is given, but
+  /// autoNodeScale() is not, then the node size given by
+  /// nodeSizes() will be multiplied by the value \c d.
+  /// If both nodeSizes() and autoNodeScale() are used, then the
+  /// node sizes will be scaled in such a way that the greatest size will be
+  /// equal to \c d.
+  /// \sa nodeSizes()
+  /// \sa autoNodeScale()
+  GraphToEps<T> &nodeScale(double d) {_nodeScale=d;return *this;}
+  ///Turns on/off the automatic node width scaling.
+
+  ///Turns on/off the automatic node width scaling.
+  ///
+  ///\sa nodeScale()
+  ///
+  GraphToEps<T> &autoNodeScale(bool b=true) {
+    _autoNodeScale=b;return *this;
+  }
+
+  ///Turns on/off the absolutematic node width scaling.
+
+  ///Turns on/off the absolutematic node width scaling.
+  ///
+  ///\sa nodeScale()
+  ///
+  GraphToEps<T> &absoluteNodeSizes(bool b=true) {
+    _absoluteNodeSizes=b;return *this;
+  }
+
+  ///Negates the Y coordinates.
+
+  ///Negates the Y coordinates.
+  ///
+  ///\todo More docs.
+  ///
+  GraphToEps<T> &negateY(bool b=true) {
+    _negY=b;return *this;
+  }
+
+  ///Turn on/off prescaling
+
+  ///By default graphToEps() rescales the whole image in order to avoid
+  ///very big or very small bounding boxes.
+  ///
+  ///This (p)rescaling can be turned off with this function.
+  ///
+  GraphToEps<T> &preScale(bool b=true) {
+    _preScale=b;return *this;
+  }
+
+  ///Sets a global scale factor for edge widths
+
+  /// Sets a global scale factor for edge widths.
+  ///
+  /// If edgeWidths() is not given, this function simply sets the edge
+  /// widths to \c d.  If edgeWidths() is given, but
+  /// autoEdgeWidthScale() is not, then the edge withs given by
+  /// edgeWidths() will be multiplied by the value \c d.
+  /// If both edgeWidths() and autoEdgeWidthScale() are used, then the
+  /// edge withs will be scaled in such a way that the greatest width will be
+  /// equal to \c d.
+  GraphToEps<T> &edgeWidthScale(double d) {_edgeWidthScale=d;return *this;}
+  ///Turns on/off the automatic edge width scaling.
+
+  ///Turns on/off the automatic edge width scaling.
+  ///
+  ///\sa edgeWidthScale()
+  ///
+  GraphToEps<T> &autoEdgeWidthScale(bool b=true) {
+    _autoEdgeWidthScale=b;return *this;
+  }
+  ///Turns on/off the absolutematic edge width scaling.
+
+  ///Turns on/off the absolutematic edge width scaling.
+  ///
+  ///\sa edgeWidthScale()
+  ///
+  GraphToEps<T> &absoluteEdgeWidths(bool b=true) {
+    _absoluteEdgeWidths=b;return *this;
+  }
+  ///Sets a global scale factor for the whole picture
+
+  ///Sets a global scale factor for the whole picture
+  ///
+
+  GraphToEps<T> &scale(double d) {_scale=d;return *this;}
+  ///Sets the width of the border around the picture
+
+  ///Sets the width of the border around the picture
+  ///
+  GraphToEps<T> &border(double b) {_xBorder=_yBorder=b;return *this;}
+  ///Sets the width of the border around the picture
+
+  ///Sets the width of the border around the picture
+  ///
+  GraphToEps<T> &border(double x, double y) {
+    _xBorder=x;_yBorder=y;return *this;
+  }
+  ///Sets whether to draw arrows
+
+  ///Sets whether to draw arrows
+  ///
+  GraphToEps<T> &drawArrows(bool b=true) {_drawArrows=b;return *this;}
+  ///Sets the length of the arrowheads
+
+  ///Sets the length of the arrowheads
+  ///
+  GraphToEps<T> &arrowLength(double d) {_arrowLength*=d;return *this;}
+  ///Sets the width of the arrowheads
+
+  ///Sets the width of the arrowheads
+  ///
+  GraphToEps<T> &arrowWidth(double d) {_arrowWidth*=d;return *this;}
+  
+  ///Scales the drawing to fit to A4 page
+
+  ///Scales the drawing to fit to A4 page
+  ///
+  GraphToEps<T> &scaleToA4() {_scaleToA4=true;return *this;}
+  
+  ///Enables parallel edges
+
+  ///Enables parallel edges
+  GraphToEps<T> &enableParallel(bool b=true) {_enableParallel=b;return *this;}
+  
+  ///Sets the distance 
+  
+  ///Sets the distance 
+  ///
+  GraphToEps<T> &parEdgeDist(double d) {_parEdgeDist*=d;return *this;}
+  
+  ///Hides the edges
+  
+  ///Hides the edges
+  ///
+  GraphToEps<T> &hideEdges(bool b=true) {_showEdges=!b;return *this;}
+  ///Hides the nodes
+  
+  ///Hides the nodes
+  ///
+  GraphToEps<T> &hideNodes(bool b=true) {_showNodes=!b;return *this;}
+  
+  ///Sets the size of the node texts
+  
+  ///Sets the size of the node texts
+  ///
+  GraphToEps<T> &nodeTextSize(double d) {_nodeTextSize=d;return *this;}
+
+  ///Sets the color of the node texts to be different from the node color
+
+  ///Sets the color of the node texts to be as different from the node color
+  ///as it is possible
+  ///
+  GraphToEps<T> &distantColorNodeTexts()
+  {_nodeTextColorType=DIST_COL;return *this;}
+  ///Sets the color of the node texts to be black or white and always visible.
+
+  ///Sets the color of the node texts to be black or white according to
+  ///which is more 
+  ///different from the node color
+  ///
+  GraphToEps<T> &distantBWNodeTexts()
+  {_nodeTextColorType=DIST_BW;return *this;}
+
+  ///Gives a preamble block for node Postscript block.
+  
+  ///Gives a preamble block for node Postscript block.
+  ///
+  ///\sa nodePsTexts()
+  GraphToEps<T> & nodePsTextsPreamble(const char *str) {
+    _nodePsTextsPreamble=str ;return *this;
+  }
+  ///Sets whether the the graph is undirected
+
+  ///Sets whether the the graph is undirected
+  ///
+  GraphToEps<T> &undirected(bool b=true) {_undirected=b;return *this;}
+
+  ///Sets whether the the graph is directed
+
+  ///Sets whether the the graph is directed.
+  ///Use it to show the undirected edges as a pair of directed ones.
+  GraphToEps<T> &bidir(bool b=true) {_undirected=!b;return *this;}
+
+  ///Sets the title.
+
+  ///Sets the title of the generated image,
+  ///namely it inserts a <tt>%%Title:</tt> DSC field to the header of
+  ///the EPS file.
+  GraphToEps<T> &title(const std::string &t) {_title=t;return *this;}
+  ///Sets the copyright statement.
+
+  ///Sets the copyright statement of the generated image,
+  ///namely it inserts a <tt>%%Copyright:</tt> DSC field to the header of
+  ///the EPS file.
+  ///\todo Multiline copyright notice could be supported.
+  GraphToEps<T> &copyright(const std::string &t) {_copyright=t;return *this;}
+
+protected:
+  bool isInsideNode(dim2::Point<double> p, double r,int t) 
+  {
+    switch(t) {
+    case CIRCLE:
+    case MALE:
+    case FEMALE:
+      return p.normSquare()<=r*r;
+    case SQUARE:
+      return p.x<=r&&p.x>=-r&&p.y<=r&&p.y>=-r;
+    case DIAMOND:
+      return p.x+p.y<=r && p.x-p.y<=r && -p.x+p.y<=r && -p.x-p.y<=r;
+    }
+    return false;
+  }
+
+public:
+  ~GraphToEps() { }
+  
+  ///Draws the graph.
+
+  ///Like other functions using
+  ///\ref named-templ-func-param "named template parameters",
+  ///this function calles the algorithm itself, i.e. in this case
+  ///it draws the graph.
+  void run() {
+    ///\todo better 'epsilon' would be nice here.
+    const double EPSILON=1e-9;
+    if(dontPrint) return;
+    
+    _NegY<typename T::CoordsMapType> mycoords(_coords,_negY);
+
+    os << "%!PS-Adobe-2.0 EPSF-2.0\n";
+    if(_title.size()>0) os << "%%Title: " << _title << '\n';
+     if(_copyright.size()>0) os << "%%Copyright: " << _copyright << '\n';
+//        << "%%Copyright: XXXX\n"
+    os << "%%Creator: LEMON, graphToEps()\n";
+    
+    {
+      char cbuf[50];
+      timeval tv;
+      gettimeofday(&tv, 0);
+      ctime_r(&tv.tv_sec,cbuf);
+      os << "%%CreationDate: " << cbuf;
+    }
+
+    if (_autoEdgeWidthScale) {
+      double max_w=0;
+      for(EdgeIt e(g);e!=INVALID;++e)
+	max_w=std::max(double(_edgeWidths[e]),max_w);
+      ///\todo better 'epsilon' would be nice here.
+      if(max_w>EPSILON) {
+	_edgeWidthScale/=max_w;
+      }
+    }
+
+    if (_autoNodeScale) {
+      double max_s=0;
+      for(NodeIt n(g);n!=INVALID;++n)
+	max_s=std::max(double(_nodeSizes[n]),max_s);
+      ///\todo better 'epsilon' would be nice here.
+      if(max_s>EPSILON) {
+	_nodeScale/=max_s;
+      }
+    }
+
+    double diag_len = 1;
+    if(!(_absoluteNodeSizes&&_absoluteEdgeWidths)) {
+      dim2::BoundingBox<double> bb;
+      for(NodeIt n(g);n!=INVALID;++n) bb.add(mycoords[n]);
+      if (bb.empty()) {
+	bb = dim2::BoundingBox<double>(dim2::Point<double>(0,0));
+      }
+      diag_len = std::sqrt((bb.bottomLeft()-bb.topRight()).normSquare());
+      if(diag_len<EPSILON) diag_len = 1;
+      if(!_absoluteNodeSizes) _nodeScale*=diag_len;
+      if(!_absoluteEdgeWidths) _edgeWidthScale*=diag_len;
+    }
+    
+    dim2::BoundingBox<double> bb;
+    for(NodeIt n(g);n!=INVALID;++n) {
+      double ns=_nodeSizes[n]*_nodeScale;
+      dim2::Point<double> p(ns,ns);
+      switch(_nodeShapes[n]) {
+      case CIRCLE:
+      case SQUARE:
+      case DIAMOND:
+	bb.add(p+mycoords[n]);
+	bb.add(-p+mycoords[n]);
+	break;
+      case MALE:
+	bb.add(-p+mycoords[n]);
+	bb.add(dim2::Point<double>(1.5*ns,1.5*std::sqrt(3.0)*ns)+mycoords[n]);
+	break;
+      case FEMALE:
+	bb.add(p+mycoords[n]);
+	bb.add(dim2::Point<double>(-ns,-3.01*ns)+mycoords[n]);
+	break;
+      }
+    }
+    if (bb.empty()) {
+      bb = dim2::BoundingBox<double>(dim2::Point<double>(0,0));
+    }
+    
+    if(_scaleToA4)
+      os <<"%%BoundingBox: 0 0 596 842\n%%DocumentPaperSizes: a4\n";
+    else {
+      if(_preScale) {
+	//Rescale so that BoundingBox won't be neither to big nor too small.
+	while(bb.height()*_scale>1000||bb.width()*_scale>1000) _scale/=10;
+	while(bb.height()*_scale<100||bb.width()*_scale<100) _scale*=10;
+      }
+      
+      os << "%%BoundingBox: "
+	 << int(floor(bb.left()   * _scale - _xBorder)) << ' '
+	 << int(floor(bb.bottom() * _scale - _yBorder)) << ' '
+	 << int(ceil(bb.right()  * _scale + _xBorder)) << ' '
+	 << int(ceil(bb.top()    * _scale + _yBorder)) << '\n';
+    }
+    
+    os << "%%EndComments\n";
+    
+    //x1 y1 x2 y2 x3 y3 cr cg cb w
+    os << "/lb { setlinewidth setrgbcolor newpath moveto\n"
+       << "      4 2 roll 1 index 1 index curveto stroke } bind def\n";
+    os << "/l { setlinewidth setrgbcolor newpath moveto lineto stroke } bind def\n";
+    //x y r
+    os << "/c { newpath dup 3 index add 2 index moveto 0 360 arc closepath } bind def\n";
+    //x y r
+    os << "/sq { newpath 2 index 1 index add 2 index 2 index add moveto\n"
+       << "      2 index 1 index sub 2 index 2 index add lineto\n"
+       << "      2 index 1 index sub 2 index 2 index sub lineto\n"
+       << "      2 index 1 index add 2 index 2 index sub lineto\n"
+       << "      closepath pop pop pop} bind def\n";
+    //x y r
+    os << "/di { newpath 2 index 1 index add 2 index moveto\n"
+       << "      2 index             2 index 2 index add lineto\n"
+       << "      2 index 1 index sub 2 index             lineto\n"
+       << "      2 index             2 index 2 index sub lineto\n"
+       << "      closepath pop pop pop} bind def\n";
+    // x y r cr cg cb
+    os << "/nc { 0 0 0 setrgbcolor 5 index 5 index 5 index c fill\n"
+       << "     setrgbcolor " << 1+_nodeBorderQuotient << " div c fill\n"
+       << "   } bind def\n";
+    os << "/nsq { 0 0 0 setrgbcolor 5 index 5 index 5 index sq fill\n"
+       << "     setrgbcolor " << 1+_nodeBorderQuotient << " div sq fill\n"
+       << "   } bind def\n";
+    os << "/ndi { 0 0 0 setrgbcolor 5 index 5 index 5 index di fill\n"
+       << "     setrgbcolor " << 1+_nodeBorderQuotient << " div di fill\n"
+       << "   } bind def\n";
+    os << "/nfemale { 0 0 0 setrgbcolor 3 index "
+       << _nodeBorderQuotient/(1+_nodeBorderQuotient)
+       << " 1.5 mul mul setlinewidth\n"
+       << "  newpath 5 index 5 index moveto "
+       << "5 index 5 index 5 index 3.01 mul sub\n"
+       << "  lineto 5 index 4 index .7 mul sub 5 index 5 index 2.2 mul sub moveto\n"
+       << "  5 index 4 index .7 mul add 5 index 5 index 2.2 mul sub lineto stroke\n"
+       << "  5 index 5 index 5 index c fill\n"
+       << "  setrgbcolor " << 1+_nodeBorderQuotient << " div c fill\n"
+       << "  } bind def\n";
+    os << "/nmale {\n"
+       << "  0 0 0 setrgbcolor 3 index "
+       << _nodeBorderQuotient/(1+_nodeBorderQuotient)
+       <<" 1.5 mul mul setlinewidth\n"
+       << "  newpath 5 index 5 index moveto\n"
+       << "  5 index 4 index 1 mul 1.5 mul add\n"
+       << "  5 index 5 index 3 sqrt 1.5 mul mul add\n"
+       << "  1 index 1 index lineto\n"
+       << "  1 index 1 index 7 index sub moveto\n"
+       << "  1 index 1 index lineto\n"
+       << "  exch 5 index 3 sqrt .5 mul mul sub exch 5 index .5 mul sub lineto\n"
+       << "  stroke\n"
+       << "  5 index 5 index 5 index c fill\n"
+       << "  setrgbcolor " << 1+_nodeBorderQuotient << " div c fill\n"
+       << "  } bind def\n";
+    
+
+    os << "/arrl " << _arrowLength << " def\n";
+    os << "/arrw " << _arrowWidth << " def\n";
+    // l dx_norm dy_norm
+    os << "/lrl { 2 index mul exch 2 index mul exch rlineto pop} bind def\n";
+    //len w dx_norm dy_norm x1 y1 cr cg cb
+    os << "/arr { setrgbcolor /y1 exch def /x1 exch def /dy exch def /dx exch def\n"
+       << "       /w exch def /len exch def\n"
+      //	 << "       0.1 setlinewidth x1 y1 moveto dx len mul dy len mul rlineto stroke"
+       << "       newpath x1 dy w 2 div mul add y1 dx w 2 div mul sub moveto\n"
+       << "       len w sub arrl sub dx dy lrl\n"
+       << "       arrw dy dx neg lrl\n"
+       << "       dx arrl w add mul dy w 2 div arrw add mul sub\n"
+       << "       dy arrl w add mul dx w 2 div arrw add mul add rlineto\n"
+       << "       dx arrl w add mul neg dy w 2 div arrw add mul sub\n"
+       << "       dy arrl w add mul neg dx w 2 div arrw add mul add rlineto\n"
+       << "       arrw dy dx neg lrl\n"
+       << "       len w sub arrl sub neg dx dy lrl\n"
+       << "       closepath fill } bind def\n";
+    os << "/cshow { 2 index 2 index moveto dup stringwidth pop\n"
+       << "         neg 2 div fosi .35 mul neg rmoveto show pop pop} def\n";
+
+    os << "\ngsave\n";
+    if(_scaleToA4)
+      if(bb.height()>bb.width()) {
+	double sc= std::min((A4HEIGHT-2*A4BORDER)/bb.height(),
+		  (A4WIDTH-2*A4BORDER)/bb.width());
+	os << ((A4WIDTH -2*A4BORDER)-sc*bb.width())/2 + A4BORDER << ' '
+	   << ((A4HEIGHT-2*A4BORDER)-sc*bb.height())/2 + A4BORDER
+	   << " translate\n"
+	   << sc << " dup scale\n"
+	   << -bb.left() << ' ' << -bb.bottom() << " translate\n";
+      }
+      else {
+	//\todo Verify centering
+	double sc= std::min((A4HEIGHT-2*A4BORDER)/bb.width(),
+		  (A4WIDTH-2*A4BORDER)/bb.height());
+	os << ((A4WIDTH -2*A4BORDER)-sc*bb.height())/2 + A4BORDER << ' '
+	   << ((A4HEIGHT-2*A4BORDER)-sc*bb.width())/2 + A4BORDER 
+	   << " translate\n"
+	   << sc << " dup scale\n90 rotate\n"
+	   << -bb.left() << ' ' << -bb.top() << " translate\n";	
+	}
+    else if(_scale!=1.0) os << _scale << " dup scale\n";
+    
+    if(_showEdges) {
+      os << "%Edges:\ngsave\n";      
+      if(_enableParallel) {
+	std::vector<Edge> el;
+	for(EdgeIt e(g);e!=INVALID;++e)
+	  if((!_undirected||g.source(e)<g.target(e))&&_edgeWidths[e]>0
+	     &&g.source(e)!=g.target(e))
+	    el.push_back(e);
+	std::sort(el.begin(),el.end(),edgeLess(g));
+	
+	typename std::vector<Edge>::iterator j;
+	for(typename std::vector<Edge>::iterator i=el.begin();i!=el.end();i=j) {
+	  for(j=i+1;j!=el.end()&&isParallel(*i,*j);++j) ;
+
+	  double sw=0;
+	  for(typename std::vector<Edge>::iterator e=i;e!=j;++e)
+	    sw+=_edgeWidths[*e]*_edgeWidthScale+_parEdgeDist;
+	  sw-=_parEdgeDist;
+	  sw/=-2.0;
+	  dim2::Point<double>
+	    dvec(mycoords[g.target(*i)]-mycoords[g.source(*i)]);
+	  double l=std::sqrt(dvec.normSquare()); 
+	  ///\todo better 'epsilon' would be nice here.
+	  dim2::Point<double> d(dvec/std::max(l,EPSILON));
+ 	  dim2::Point<double> m;
+// 	  m=dim2::Point<double>(mycoords[g.target(*i)]+mycoords[g.source(*i)])/2.0;
+
+//  	  m=dim2::Point<double>(mycoords[g.source(*i)])+
+// 	    dvec*(double(_nodeSizes[g.source(*i)])/
+// 	       (_nodeSizes[g.source(*i)]+_nodeSizes[g.target(*i)]));
+
+ 	  m=dim2::Point<double>(mycoords[g.source(*i)])+
+	    d*(l+_nodeSizes[g.source(*i)]-_nodeSizes[g.target(*i)])/2.0;
+
+	  for(typename std::vector<Edge>::iterator e=i;e!=j;++e) {
+	    sw+=_edgeWidths[*e]*_edgeWidthScale/2.0;
+	    dim2::Point<double> mm=m+rot90(d)*sw/.75;
+	    if(_drawArrows) {
+	      int node_shape;
+	      dim2::Point<double> s=mycoords[g.source(*e)];
+	      dim2::Point<double> t=mycoords[g.target(*e)];
+	      double rn=_nodeSizes[g.target(*e)]*_nodeScale;
+	      node_shape=_nodeShapes[g.target(*e)];
+	      dim2::Bezier3 bez(s,mm,mm,t);
+	      double t1=0,t2=1;
+	      for(int ii=0;ii<INTERPOL_PREC;++ii)
+		if(isInsideNode(bez((t1+t2)/2)-t,rn,node_shape)) t2=(t1+t2)/2;
+		else t1=(t1+t2)/2;
+	      dim2::Point<double> apoint=bez((t1+t2)/2);
+	      rn = _arrowLength+_edgeWidths[*e]*_edgeWidthScale;
+	      rn*=rn;
+	      t2=(t1+t2)/2;t1=0;
+	      for(int ii=0;ii<INTERPOL_PREC;++ii)
+		if((bez((t1+t2)/2)-apoint).normSquare()>rn) t1=(t1+t2)/2;
+		else t2=(t1+t2)/2;
+	      dim2::Point<double> linend=bez((t1+t2)/2);	      
+	      bez=bez.before((t1+t2)/2);
+// 	      rn=_nodeSizes[g.source(*e)]*_nodeScale;
+// 	      node_shape=_nodeShapes[g.source(*e)];
+// 	      t1=0;t2=1;
+// 	      for(int i=0;i<INTERPOL_PREC;++i)
+// 		if(isInsideNode(bez((t1+t2)/2)-t,rn,node_shape)) t1=(t1+t2)/2;
+// 		else t2=(t1+t2)/2;
+// 	      bez=bez.after((t1+t2)/2);
+	      os << _edgeWidths[*e]*_edgeWidthScale << " setlinewidth "
+		 << _edgeColors[*e].red() << ' '
+		 << _edgeColors[*e].green() << ' '
+		 << _edgeColors[*e].blue() << " setrgbcolor newpath\n"
+		 << bez.p1.x << ' ' <<  bez.p1.y << " moveto\n"
+		 << bez.p2.x << ' ' << bez.p2.y << ' '
+		 << bez.p3.x << ' ' << bez.p3.y << ' '
+		 << bez.p4.x << ' ' << bez.p4.y << " curveto stroke\n";
+	      dim2::Point<double> dd(rot90(linend-apoint));
+	      dd*=(.5*_edgeWidths[*e]*_edgeWidthScale+_arrowWidth)/
+		std::sqrt(dd.normSquare());
+	      os << "newpath " << psOut(apoint) << " moveto "
+		 << psOut(linend+dd) << " lineto "
+		 << psOut(linend-dd) << " lineto closepath fill\n";
+	    }
+	    else {
+	      os << mycoords[g.source(*e)].x << ' '
+		 << mycoords[g.source(*e)].y << ' '
+		 << mm.x << ' ' << mm.y << ' '
+		 << mycoords[g.target(*e)].x << ' '
+		 << mycoords[g.target(*e)].y << ' '
+		 << _edgeColors[*e].red() << ' '
+		 << _edgeColors[*e].green() << ' '
+		 << _edgeColors[*e].blue() << ' '
+		 << _edgeWidths[*e]*_edgeWidthScale << " lb\n";
+	    }
+	    sw+=_edgeWidths[*e]*_edgeWidthScale/2.0+_parEdgeDist;
+	  }
+	}
+      }
+      else for(EdgeIt e(g);e!=INVALID;++e)
+	if((!_undirected||g.source(e)<g.target(e))&&_edgeWidths[e]>0
+	   &&g.source(e)!=g.target(e)) {
+	  if(_drawArrows) {
+	    dim2::Point<double> d(mycoords[g.target(e)]-mycoords[g.source(e)]);
+	    double rn=_nodeSizes[g.target(e)]*_nodeScale;
+	    int node_shape=_nodeShapes[g.target(e)];
+	    double t1=0,t2=1;
+	    for(int i=0;i<INTERPOL_PREC;++i)
+	      if(isInsideNode((-(t1+t2)/2)*d,rn,node_shape)) t1=(t1+t2)/2;
+	      else t2=(t1+t2)/2;
+	    double l=std::sqrt(d.normSquare());
+	    d/=l;
+	    
+	    os << l*(1-(t1+t2)/2) << ' '
+	       << _edgeWidths[e]*_edgeWidthScale << ' '
+	       << d.x << ' ' << d.y << ' '
+	       << mycoords[g.source(e)].x << ' '
+	       << mycoords[g.source(e)].y << ' '
+	       << _edgeColors[e].red() << ' '
+	       << _edgeColors[e].green() << ' '
+	       << _edgeColors[e].blue() << " arr\n";
+	  }
+	  else os << mycoords[g.source(e)].x << ' '
+		  << mycoords[g.source(e)].y << ' '
+		  << mycoords[g.target(e)].x << ' '
+		  << mycoords[g.target(e)].y << ' '
+		  << _edgeColors[e].red() << ' '
+		  << _edgeColors[e].green() << ' '
+		  << _edgeColors[e].blue() << ' '
+		  << _edgeWidths[e]*_edgeWidthScale << " l\n";
+	}
+      os << "grestore\n";
+    }
+    if(_showNodes) {
+      os << "%Nodes:\ngsave\n";
+      for(NodeIt n(g);n!=INVALID;++n) {
+	os << mycoords[n].x << ' ' << mycoords[n].y << ' '
+	   << _nodeSizes[n]*_nodeScale << ' '
+	   << _nodeColors[n].red() << ' '
+	   << _nodeColors[n].green() << ' '
+	   << _nodeColors[n].blue() << ' ';
+	switch(_nodeShapes[n]) {
+	case CIRCLE:
+	  os<< "nc";break;
+	case SQUARE:
+	  os<< "nsq";break;
+	case DIAMOND:
+	  os<< "ndi";break;
+	case MALE:
+	  os<< "nmale";break;
+	case FEMALE:
+	  os<< "nfemale";break;
+	}
+	os<<'\n';
+      }
+      os << "grestore\n";
+    }
+    if(_showNodeText) {
+      os << "%Node texts:\ngsave\n";
+      os << "/fosi " << _nodeTextSize << " def\n";
+      os << "(Helvetica) findfont fosi scalefont setfont\n";
+      for(NodeIt n(g);n!=INVALID;++n) {
+	switch(_nodeTextColorType) {
+	case DIST_COL:
+	  os << psOut(distantColor(_nodeColors[n])) << " setrgbcolor\n";
+	  break;
+	case DIST_BW:
+	  os << psOut(distantBW(_nodeColors[n])) << " setrgbcolor\n";
+	  break;
+	case CUST_COL:
+	  os << psOut(distantColor(_nodeTextColors[n])) << " setrgbcolor\n";
+	  break;
+	default:
+	  os << "0 0 0 setrgbcolor\n";
+	}
+	os << mycoords[n].x << ' ' << mycoords[n].y
+	   << " (" << _nodeTexts[n] << ") cshow\n";
+      }
+      os << "grestore\n";
+    }
+    if(_showNodePsText) {
+      os << "%Node PS blocks:\ngsave\n";
+      for(NodeIt n(g);n!=INVALID;++n)
+	os << mycoords[n].x << ' ' << mycoords[n].y
+	   << " moveto\n" << _nodePsTexts[n] << "\n";
+      os << "grestore\n";
+    }
+    
+    os << "grestore\nshowpage\n";
+
+    //CleanUp:
+    if(_pleaseRemoveOsStream) {delete &os;}
+  } 
+};
+
+template<class T>
+const int GraphToEps<T>::INTERPOL_PREC = 20;
+template<class T>
+const double GraphToEps<T>::A4HEIGHT = 841.8897637795276;
+template<class T>
+const double GraphToEps<T>::A4WIDTH  = 595.275590551181;
+template<class T>
+const double GraphToEps<T>::A4BORDER = 15;
+
+
+///Generates an EPS file from a graph
+
+///\ingroup eps_io
+///Generates an EPS file from a graph.
+///\param g is a reference to the graph to be printed
+///\param os is a reference to the output stream.
+///By default it is <tt>std::cout</tt>
+///
+///This function also has a lot of
+///\ref named-templ-func-param "named parameters",
+///they are declared as the members of class \ref GraphToEps. The following
+///example shows how to use these parameters.
+///\code
+/// graphToEps(g,os).scale(10).coords(coords)
+///              .nodeScale(2).nodeSizes(sizes)
+///              .edgeWidthScale(.4).run();
+///\endcode
+///\warning Don't forget to put the \ref GraphToEps::run() "run()"
+///to the end of the parameter list.
+///\sa GraphToEps
+///\sa graphToEps(G &g, const char *file_name)
+template<class G>
+GraphToEps<DefaultGraphToEpsTraits<G> > 
+graphToEps(G &g, std::ostream& os=std::cout)
+{
+  return 
+    GraphToEps<DefaultGraphToEpsTraits<G> >(DefaultGraphToEpsTraits<G>(g,os));
+}
+ 
+///Generates an EPS file from a graph
+
+///\ingroup eps_io
+///This function does the same as
+///\ref graphToEps(G &g,std::ostream& os)
+///but it writes its output into the file \c file_name
+///instead of a stream.
+///\sa graphToEps(G &g, std::ostream& os)
+template<class G>
+GraphToEps<DefaultGraphToEpsTraits<G> > 
+graphToEps(G &g,const char *file_name)
+{
+  return GraphToEps<DefaultGraphToEpsTraits<G> >
+    (DefaultGraphToEpsTraits<G>(g,*new std::ofstream(file_name),true));
+}
+
+///Generates an EPS file from a graph
+
+///\ingroup eps_io
+///This function does the same as
+///\ref graphToEps(G &g,std::ostream& os)
+///but it writes its output into the file \c file_name
+///instead of a stream.
+///\sa graphToEps(G &g, std::ostream& os)
+template<class G>
+GraphToEps<DefaultGraphToEpsTraits<G> > 
+graphToEps(G &g,const std::string& file_name)
+{
+  return GraphToEps<DefaultGraphToEpsTraits<G> >
+    (DefaultGraphToEpsTraits<G>(g,*new std::ofstream(file_name.c_str()),true));
+}
+
+} //END OF NAMESPACE LEMON
+
+#endif // LEMON_GRAPH_TO_EPS_H
Index: lemon/graph_utils.h
===================================================================
--- lemon/graph_utils.h	(revision 2616)
+++ lemon/graph_utils.h	(revision 2616)
@@ -0,0 +1,3181 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_GRAPH_UTILS_H
+#define LEMON_GRAPH_UTILS_H
+
+#include <iterator>
+#include <vector>
+#include <map>
+#include <lemon/math.h>
+#include <algorithm>
+
+#include <lemon/bits/invalid.h>
+#include <lemon/bits/utility.h>
+#include <lemon/maps.h>
+#include <lemon/bits/traits.h>
+
+#include <lemon/bits/alteration_notifier.h>
+#include <lemon/bits/default_map.h>
+
+///\ingroup gutils
+///\file
+///\brief Graph utilities.
+
+namespace lemon {
+
+  /// \addtogroup gutils
+  /// @{
+
+  ///Creates convenience typedefs for the graph types and iterators
+
+  ///This \c \#define creates convenience typedefs for the following types
+  ///of \c Graph: \c Node,  \c NodeIt, \c Edge, \c EdgeIt, \c InEdgeIt,
+  ///\c OutEdgeIt
+  ///\note If \c G it a template parameter, it should be used in this way.
+  ///\code
+  ///  GRAPH_TYPEDEFS(typename G);
+  ///\endcode
+  ///
+  ///\warning There are no typedefs for the graph maps because of the lack of
+  ///template typedefs in C++.
+#define GRAPH_TYPEDEFS(Graph)				\
+  typedef Graph::     Node      Node;			\
+    typedef Graph::   NodeIt    NodeIt;			\
+    typedef Graph::   Edge      Edge;			\
+    typedef Graph::   EdgeIt    EdgeIt;			\
+    typedef Graph:: InEdgeIt  InEdgeIt;			\
+    typedef Graph::OutEdgeIt OutEdgeIt
+
+  ///Creates convenience typedefs for the undirected graph types and iterators
+
+  ///This \c \#define creates the same convenience typedefs as defined by
+  ///\ref GRAPH_TYPEDEFS(Graph) and three more, namely it creates
+  ///\c UEdge, \c UEdgeIt, \c IncEdgeIt,
+  ///
+  ///\note If \c G it a template parameter, it should be used in this way.
+  ///\code
+  ///  UGRAPH_TYPEDEFS(typename G);
+  ///\endcode
+  ///
+  ///\warning There are no typedefs for the graph maps because of the lack of
+  ///template typedefs in C++.
+#define UGRAPH_TYPEDEFS(Graph)				\
+  GRAPH_TYPEDEFS(Graph);				\
+    typedef Graph:: UEdge   UEdge;			\
+    typedef Graph:: UEdgeIt UEdgeIt;			\
+    typedef Graph:: IncEdgeIt   IncEdgeIt
+
+  ///\brief Creates convenience typedefs for the bipartite undirected graph 
+  ///types and iterators
+
+  ///This \c \#define creates the same convenience typedefs as defined by
+  ///\ref UGRAPH_TYPEDEFS(Graph) and two more, namely it creates
+  ///\c ANodeIt, \c BNodeIt, 
+  ///
+  ///\note If \c G it a template parameter, it should be used in this way.
+  ///\code
+  ///  BPUGRAPH_TYPEDEFS(typename G);
+  ///\endcode
+  ///
+  ///\warning There are no typedefs for the graph maps because of the lack of
+  ///template typedefs in C++.
+#define BPUGRAPH_TYPEDEFS(Graph)            \
+  UGRAPH_TYPEDEFS(Graph);		    \
+    typedef Graph::ANode ANode;             \
+    typedef Graph::BNode BNode;             \
+    typedef Graph::ANodeIt ANodeIt;	    \
+    typedef Graph::BNodeIt BNodeIt
+
+  /// \brief Function to count the items in the graph.
+  ///
+  /// This function counts the items (nodes, edges etc) in the graph.
+  /// The complexity of the function is O(n) because
+  /// it iterates on all of the items.
+
+  template <typename Graph, typename Item>
+  inline int countItems(const Graph& g) {
+    typedef typename ItemSetTraits<Graph, Item>::ItemIt ItemIt;
+    int num = 0;
+    for (ItemIt it(g); it != INVALID; ++it) {
+      ++num;
+    }
+    return num;
+  }
+
+  // Node counting:
+
+  namespace _graph_utils_bits {
+    
+    template <typename Graph, typename Enable = void>
+    struct CountNodesSelector {
+      static int count(const Graph &g) {
+        return countItems<Graph, typename Graph::Node>(g);
+      }
+    };
+
+    template <typename Graph>
+    struct CountNodesSelector<
+      Graph, typename 
+      enable_if<typename Graph::NodeNumTag, void>::type> 
+    {
+      static int count(const Graph &g) {
+        return g.nodeNum();
+      }
+    };    
+  }
+
+  /// \brief Function to count the nodes in the graph.
+  ///
+  /// This function counts the nodes in the graph.
+  /// The complexity of the function is O(n) but for some
+  /// graph structures it is specialized to run in O(1).
+  ///
+  /// If the graph contains a \e nodeNum() member function and a 
+  /// \e NodeNumTag tag then this function calls directly the member
+  /// function to query the cardinality of the node set.
+  template <typename Graph>
+  inline int countNodes(const Graph& g) {
+    return _graph_utils_bits::CountNodesSelector<Graph>::count(g);
+  }
+
+  namespace _graph_utils_bits {
+    
+    template <typename Graph, typename Enable = void>
+    struct CountANodesSelector {
+      static int count(const Graph &g) {
+        return countItems<Graph, typename Graph::ANode>(g);
+      }
+    };
+
+    template <typename Graph>
+    struct CountANodesSelector<
+      Graph, typename 
+      enable_if<typename Graph::NodeNumTag, void>::type> 
+    {
+      static int count(const Graph &g) {
+        return g.aNodeNum();
+      }
+    };    
+  }
+
+  /// \brief Function to count the anodes in the graph.
+  ///
+  /// This function counts the anodes in the graph.
+  /// The complexity of the function is O(an) but for some
+  /// graph structures it is specialized to run in O(1).
+  ///
+  /// If the graph contains an \e aNodeNum() member function and a 
+  /// \e NodeNumTag tag then this function calls directly the member
+  /// function to query the cardinality of the A-node set.
+  template <typename Graph>
+  inline int countANodes(const Graph& g) {
+    return _graph_utils_bits::CountANodesSelector<Graph>::count(g);
+  }
+
+  namespace _graph_utils_bits {
+    
+    template <typename Graph, typename Enable = void>
+    struct CountBNodesSelector {
+      static int count(const Graph &g) {
+        return countItems<Graph, typename Graph::BNode>(g);
+      }
+    };
+
+    template <typename Graph>
+    struct CountBNodesSelector<
+      Graph, typename 
+      enable_if<typename Graph::NodeNumTag, void>::type> 
+    {
+      static int count(const Graph &g) {
+        return g.bNodeNum();
+      }
+    };    
+  }
+
+  /// \brief Function to count the bnodes in the graph.
+  ///
+  /// This function counts the bnodes in the graph.
+  /// The complexity of the function is O(bn) but for some
+  /// graph structures it is specialized to run in O(1).
+  ///
+  /// If the graph contains a \e bNodeNum() member function and a 
+  /// \e NodeNumTag tag then this function calls directly the member
+  /// function to query the cardinality of the B-node set.
+  template <typename Graph>
+  inline int countBNodes(const Graph& g) {
+    return _graph_utils_bits::CountBNodesSelector<Graph>::count(g);
+  }
+
+
+  // Edge counting:
+
+  namespace _graph_utils_bits {
+    
+    template <typename Graph, typename Enable = void>
+    struct CountEdgesSelector {
+      static int count(const Graph &g) {
+        return countItems<Graph, typename Graph::Edge>(g);
+      }
+    };
+
+    template <typename Graph>
+    struct CountEdgesSelector<
+      Graph, 
+      typename enable_if<typename Graph::EdgeNumTag, void>::type> 
+    {
+      static int count(const Graph &g) {
+        return g.edgeNum();
+      }
+    };    
+  }
+
+  /// \brief Function to count the edges in the graph.
+  ///
+  /// This function counts the edges in the graph.
+  /// The complexity of the function is O(e) but for some
+  /// graph structures it is specialized to run in O(1).
+  ///
+  /// If the graph contains a \e edgeNum() member function and a 
+  /// \e EdgeNumTag tag then this function calls directly the member
+  /// function to query the cardinality of the edge set.
+  template <typename Graph>
+  inline int countEdges(const Graph& g) {
+    return _graph_utils_bits::CountEdgesSelector<Graph>::count(g);
+  }
+
+  // Undirected edge counting:
+  namespace _graph_utils_bits {
+    
+    template <typename Graph, typename Enable = void>
+    struct CountUEdgesSelector {
+      static int count(const Graph &g) {
+        return countItems<Graph, typename Graph::UEdge>(g);
+      }
+    };
+
+    template <typename Graph>
+    struct CountUEdgesSelector<
+      Graph, 
+      typename enable_if<typename Graph::EdgeNumTag, void>::type> 
+    {
+      static int count(const Graph &g) {
+        return g.uEdgeNum();
+      }
+    };    
+  }
+
+  /// \brief Function to count the undirected edges in the graph.
+  ///
+  /// This function counts the undirected edges in the graph.
+  /// The complexity of the function is O(e) but for some
+  /// graph structures it is specialized to run in O(1).
+  ///
+  /// If the graph contains a \e uEdgeNum() member function and a 
+  /// \e EdgeNumTag tag then this function calls directly the member
+  /// function to query the cardinality of the undirected edge set.
+  template <typename Graph>
+  inline int countUEdges(const Graph& g) {
+    return _graph_utils_bits::CountUEdgesSelector<Graph>::count(g);
+
+  }
+
+
+  template <typename Graph, typename DegIt>
+  inline int countNodeDegree(const Graph& _g, const typename Graph::Node& _n) {
+    int num = 0;
+    for (DegIt it(_g, _n); it != INVALID; ++it) {
+      ++num;
+    }
+    return num;
+  }
+
+  /// \brief Function to count the number of the out-edges from node \c n.
+  ///
+  /// This function counts the number of the out-edges from node \c n
+  /// in the graph.  
+  template <typename Graph>
+  inline int countOutEdges(const Graph& _g,  const typename Graph::Node& _n) {
+    return countNodeDegree<Graph, typename Graph::OutEdgeIt>(_g, _n);
+  }
+
+  /// \brief Function to count the number of the in-edges to node \c n.
+  ///
+  /// This function counts the number of the in-edges to node \c n
+  /// in the graph.  
+  template <typename Graph>
+  inline int countInEdges(const Graph& _g,  const typename Graph::Node& _n) {
+    return countNodeDegree<Graph, typename Graph::InEdgeIt>(_g, _n);
+  }
+
+  /// \brief Function to count the number of the inc-edges to node \c n.
+  ///
+  /// This function counts the number of the inc-edges to node \c n
+  /// in the graph.  
+  template <typename Graph>
+  inline int countIncEdges(const Graph& _g,  const typename Graph::Node& _n) {
+    return countNodeDegree<Graph, typename Graph::IncEdgeIt>(_g, _n);
+  }
+
+  namespace _graph_utils_bits {
+    
+    template <typename Graph, typename Enable = void>
+    struct FindEdgeSelector {
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge Edge;
+      static Edge find(const Graph &g, Node u, Node v, Edge e) {
+        if (e == INVALID) {
+          g.firstOut(e, u);
+        } else {
+          g.nextOut(e);
+        }
+        while (e != INVALID && g.target(e) != v) {
+          g.nextOut(e);
+        }
+        return e;
+      }
+    };
+
+    template <typename Graph>
+    struct FindEdgeSelector<
+      Graph, 
+      typename enable_if<typename Graph::FindEdgeTag, void>::type> 
+    {
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge Edge;
+      static Edge find(const Graph &g, Node u, Node v, Edge prev) {
+        return g.findEdge(u, v, prev);
+      }
+    };    
+  }
+
+  /// \brief Finds an edge between two nodes of a graph.
+  ///
+  /// Finds an edge from node \c u to node \c v in graph \c g.
+  ///
+  /// If \c prev is \ref INVALID (this is the default value), then
+  /// it finds the first edge from \c u to \c v. Otherwise it looks for
+  /// the next edge from \c u to \c v after \c prev.
+  /// \return The found edge or \ref INVALID if there is no such an edge.
+  ///
+  /// Thus you can iterate through each edge from \c u to \c v as it follows.
+  ///\code
+  /// for(Edge e=findEdge(g,u,v);e!=INVALID;e=findEdge(g,u,v,e)) {
+  ///   ...
+  /// }
+  ///\endcode
+  ///
+  ///\sa EdgeLookUp
+  ///\sa AllEdgeLookUp
+  ///\sa DynEdgeLookUp
+  ///\sa ConEdgeIt
+  template <typename Graph>
+  inline typename Graph::Edge 
+  findEdge(const Graph &g, typename Graph::Node u, typename Graph::Node v,
+           typename Graph::Edge prev = INVALID) {
+    return _graph_utils_bits::FindEdgeSelector<Graph>::find(g, u, v, prev);
+  }
+
+  /// \brief Iterator for iterating on edges connected the same nodes.
+  ///
+  /// Iterator for iterating on edges connected the same nodes. It is 
+  /// higher level interface for the findEdge() function. You can
+  /// use it the following way:
+  ///\code
+  /// for (ConEdgeIt<Graph> it(g, src, trg); it != INVALID; ++it) {
+  ///   ...
+  /// }
+  ///\endcode
+  /// 
+  ///\sa findEdge()
+  ///\sa EdgeLookUp
+  ///\sa AllEdgeLookUp
+  ///\sa DynEdgeLookUp
+  ///
+  /// \author Balazs Dezso 
+  template <typename _Graph>
+  class ConEdgeIt : public _Graph::Edge {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Parent;
+
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::Node Node;
+
+    /// \brief Constructor.
+    ///
+    /// Construct a new ConEdgeIt iterating on the edges which
+    /// connects the \c u and \c v node.
+    ConEdgeIt(const Graph& g, Node u, Node v) : graph(g) {
+      Parent::operator=(findEdge(graph, u, v));
+    }
+
+    /// \brief Constructor.
+    ///
+    /// Construct a new ConEdgeIt which continues the iterating from 
+    /// the \c e edge.
+    ConEdgeIt(const Graph& g, Edge e) : Parent(e), graph(g) {}
+    
+    /// \brief Increment operator.
+    ///
+    /// It increments the iterator and gives back the next edge.
+    ConEdgeIt& operator++() {
+      Parent::operator=(findEdge(graph, graph.source(*this), 
+				 graph.target(*this), *this));
+      return *this;
+    }
+  private:
+    const Graph& graph;
+  };
+
+  namespace _graph_utils_bits {
+    
+    template <typename Graph, typename Enable = void>
+    struct FindUEdgeSelector {
+      typedef typename Graph::Node Node;
+      typedef typename Graph::UEdge UEdge;
+      static UEdge find(const Graph &g, Node u, Node v, UEdge e) {
+        bool b;
+        if (u != v) {
+          if (e == INVALID) {
+            g.firstInc(e, b, u);
+          } else {
+            b = g.source(e) == u;
+            g.nextInc(e, b);
+          }
+          while (e != INVALID && (b ? g.target(e) : g.source(e)) != v) {
+            g.nextInc(e, b);
+          }
+        } else {
+          if (e == INVALID) {
+            g.firstInc(e, b, u);
+          } else {
+            b = true;
+            g.nextInc(e, b);
+          }
+          while (e != INVALID && (!b || g.target(e) != v)) {
+            g.nextInc(e, b);
+          }
+        }
+        return e;
+      }
+    };
+
+    template <typename Graph>
+    struct FindUEdgeSelector<
+      Graph, 
+      typename enable_if<typename Graph::FindEdgeTag, void>::type> 
+    {
+      typedef typename Graph::Node Node;
+      typedef typename Graph::UEdge UEdge;
+      static UEdge find(const Graph &g, Node u, Node v, UEdge prev) {
+        return g.findUEdge(u, v, prev);
+      }
+    };    
+  }
+
+  /// \brief Finds an uedge between two nodes of a graph.
+  ///
+  /// Finds an uedge from node \c u to node \c v in graph \c g.
+  /// If the node \c u and node \c v is equal then each loop edge
+  /// will be enumerated.
+  ///
+  /// If \c prev is \ref INVALID (this is the default value), then
+  /// it finds the first edge from \c u to \c v. Otherwise it looks for
+  /// the next edge from \c u to \c v after \c prev.
+  /// \return The found edge or \ref INVALID if there is no such an edge.
+  ///
+  /// Thus you can iterate through each edge from \c u to \c v as it follows.
+  ///\code
+  /// for(UEdge e = findUEdge(g,u,v); e != INVALID; 
+  ///     e = findUEdge(g,u,v,e)) {
+  ///   ...
+  /// }
+  ///\endcode
+  ///
+  ///\sa ConEdgeIt
+
+  template <typename Graph>
+  inline typename Graph::UEdge 
+  findUEdge(const Graph &g, typename Graph::Node u, typename Graph::Node v,
+            typename Graph::UEdge p = INVALID) {
+    return _graph_utils_bits::FindUEdgeSelector<Graph>::find(g, u, v, p);
+  }
+
+  /// \brief Iterator for iterating on uedges connected the same nodes.
+  ///
+  /// Iterator for iterating on uedges connected the same nodes. It is 
+  /// higher level interface for the findUEdge() function. You can
+  /// use it the following way:
+  ///\code
+  /// for (ConUEdgeIt<Graph> it(g, src, trg); it != INVALID; ++it) {
+  ///   ...
+  /// }
+  ///\endcode
+  ///
+  ///\sa findUEdge()
+  ///
+  /// \author Balazs Dezso 
+  template <typename _Graph>
+  class ConUEdgeIt : public _Graph::UEdge {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::UEdge Parent;
+
+    typedef typename Graph::UEdge UEdge;
+    typedef typename Graph::Node Node;
+
+    /// \brief Constructor.
+    ///
+    /// Construct a new ConUEdgeIt iterating on the edges which
+    /// connects the \c u and \c v node.
+    ConUEdgeIt(const Graph& g, Node u, Node v) : graph(g) {
+      Parent::operator=(findUEdge(graph, u, v));
+    }
+
+    /// \brief Constructor.
+    ///
+    /// Construct a new ConUEdgeIt which continues the iterating from 
+    /// the \c e edge.
+    ConUEdgeIt(const Graph& g, UEdge e) : Parent(e), graph(g) {}
+    
+    /// \brief Increment operator.
+    ///
+    /// It increments the iterator and gives back the next edge.
+    ConUEdgeIt& operator++() {
+      Parent::operator=(findUEdge(graph, graph.source(*this), 
+				      graph.target(*this), *this));
+      return *this;
+    }
+  private:
+    const Graph& graph;
+  };
+
+  /// \brief Copy a map.
+  ///
+  /// This function copies the \c from map to the \c to map. It uses the
+  /// given iterator to iterate on the data structure and it uses the \c ref
+  /// mapping to convert the from's keys to the to's keys.
+  template <typename To, typename From, 
+	    typename ItemIt, typename Ref>	    
+  void copyMap(To& to, const From& from, 
+	       ItemIt it, const Ref& ref) {
+    for (; it != INVALID; ++it) {
+      to[ref[it]] = from[it];
+    }
+  }
+
+  /// \brief Copy the from map to the to map.
+  ///
+  /// Copy the \c from map to the \c to map. It uses the given iterator
+  /// to iterate on the data structure.
+  template <typename To, typename From, typename ItemIt>	    
+  void copyMap(To& to, const From& from, ItemIt it) {
+    for (; it != INVALID; ++it) {
+      to[it] = from[it];
+    }
+  }
+
+  namespace _graph_utils_bits {
+
+    template <typename Graph, typename Item, typename RefMap>
+    class MapCopyBase {
+    public:
+      virtual void copy(const Graph& from, const RefMap& refMap) = 0;
+      
+      virtual ~MapCopyBase() {}
+    };
+
+    template <typename Graph, typename Item, typename RefMap, 
+              typename ToMap, typename FromMap>
+    class MapCopy : public MapCopyBase<Graph, Item, RefMap> {
+    public:
+
+      MapCopy(ToMap& tmap, const FromMap& map) 
+        : _tmap(tmap), _map(map) {}
+      
+      virtual void copy(const Graph& graph, const RefMap& refMap) {
+        typedef typename ItemSetTraits<Graph, Item>::ItemIt ItemIt;
+        for (ItemIt it(graph); it != INVALID; ++it) {
+          _tmap.set(refMap[it], _map[it]);
+        }
+      }
+
+    private:
+      ToMap& _tmap;
+      const FromMap& _map;
+    };
+
+    template <typename Graph, typename Item, typename RefMap, typename It>
+    class ItemCopy : public MapCopyBase<Graph, Item, RefMap> {
+    public:
+
+      ItemCopy(It& it, const Item& item) : _it(it), _item(item) {}
+      
+      virtual void copy(const Graph&, const RefMap& refMap) {
+        _it = refMap[_item];
+      }
+
+    private:
+      It& _it;
+      Item _item;
+    };
+
+    template <typename Graph, typename Item, typename RefMap, typename Ref>
+    class RefCopy : public MapCopyBase<Graph, Item, RefMap> {
+    public:
+
+      RefCopy(Ref& map) : _map(map) {}
+      
+      virtual void copy(const Graph& graph, const RefMap& refMap) {
+        typedef typename ItemSetTraits<Graph, Item>::ItemIt ItemIt;
+        for (ItemIt it(graph); it != INVALID; ++it) {
+          _map.set(it, refMap[it]);
+        }
+      }
+
+    private:
+      Ref& _map;
+    };
+
+    template <typename Graph, typename Item, typename RefMap, 
+              typename CrossRef>
+    class CrossRefCopy : public MapCopyBase<Graph, Item, RefMap> {
+    public:
+
+      CrossRefCopy(CrossRef& cmap) : _cmap(cmap) {}
+      
+      virtual void copy(const Graph& graph, const RefMap& refMap) {
+        typedef typename ItemSetTraits<Graph, Item>::ItemIt ItemIt;
+        for (ItemIt it(graph); it != INVALID; ++it) {
+          _cmap.set(refMap[it], it);
+        }
+      }
+
+    private:
+      CrossRef& _cmap;
+    };
+
+    template <typename Graph, typename Enable = void>
+    struct GraphCopySelector {
+      template <typename From, typename NodeRefMap, typename EdgeRefMap>
+      static void copy(Graph &to, const From& from,
+                       NodeRefMap& nodeRefMap, EdgeRefMap& edgeRefMap) {
+        for (typename From::NodeIt it(from); it != INVALID; ++it) {
+          nodeRefMap[it] = to.addNode();
+        }
+        for (typename From::EdgeIt it(from); it != INVALID; ++it) {
+          edgeRefMap[it] = to.addEdge(nodeRefMap[from.source(it)], 
+                                          nodeRefMap[from.target(it)]);
+        }
+      }
+    };
+
+    template <typename Graph>
+    struct GraphCopySelector<
+      Graph, 
+      typename enable_if<typename Graph::BuildTag, void>::type> 
+    {
+      template <typename From, typename NodeRefMap, typename EdgeRefMap>
+      static void copy(Graph &to, const From& from,
+                       NodeRefMap& nodeRefMap, EdgeRefMap& edgeRefMap) {
+        to.build(from, nodeRefMap, edgeRefMap);
+      }
+    };
+
+    template <typename UGraph, typename Enable = void>
+    struct UGraphCopySelector {
+      template <typename From, typename NodeRefMap, typename UEdgeRefMap>
+      static void copy(UGraph &to, const From& from,
+                       NodeRefMap& nodeRefMap, UEdgeRefMap& uEdgeRefMap) {
+        for (typename From::NodeIt it(from); it != INVALID; ++it) {
+          nodeRefMap[it] = to.addNode();
+        }
+        for (typename From::UEdgeIt it(from); it != INVALID; ++it) {
+          uEdgeRefMap[it] = to.addEdge(nodeRefMap[from.source(it)], 
+				       nodeRefMap[from.target(it)]);
+        }
+      }
+    };
+
+    template <typename UGraph>
+    struct UGraphCopySelector<
+      UGraph, 
+      typename enable_if<typename UGraph::BuildTag, void>::type> 
+    {
+      template <typename From, typename NodeRefMap, typename UEdgeRefMap>
+      static void copy(UGraph &to, const From& from,
+                       NodeRefMap& nodeRefMap, UEdgeRefMap& uEdgeRefMap) {
+        to.build(from, nodeRefMap, uEdgeRefMap);
+      }
+    };
+
+    template <typename BpUGraph, typename Enable = void>
+    struct BpUGraphCopySelector {
+      template <typename From, typename ANodeRefMap, 
+                typename BNodeRefMap, typename UEdgeRefMap>
+      static void copy(BpUGraph &to, const From& from,
+                       ANodeRefMap& aNodeRefMap, BNodeRefMap& bNodeRefMap,
+                       UEdgeRefMap& uEdgeRefMap) {
+        for (typename From::ANodeIt it(from); it != INVALID; ++it) {
+          aNodeRefMap[it] = to.addANode();
+        }
+        for (typename From::BNodeIt it(from); it != INVALID; ++it) {
+          bNodeRefMap[it] = to.addBNode();
+        }
+        for (typename From::UEdgeIt it(from); it != INVALID; ++it) {
+          uEdgeRefMap[it] = to.addEdge(aNodeRefMap[from.aNode(it)], 
+                                           bNodeRefMap[from.bNode(it)]);
+        }
+      }
+    };
+
+    template <typename BpUGraph>
+    struct BpUGraphCopySelector<
+      BpUGraph, 
+      typename enable_if<typename BpUGraph::BuildTag, void>::type> 
+    {
+      template <typename From, typename ANodeRefMap, 
+                typename BNodeRefMap, typename UEdgeRefMap>
+      static void copy(BpUGraph &to, const From& from,
+                       ANodeRefMap& aNodeRefMap, BNodeRefMap& bNodeRefMap,
+                       UEdgeRefMap& uEdgeRefMap) {
+        to.build(from, aNodeRefMap, bNodeRefMap, uEdgeRefMap);
+      }
+    };
+    
+
+  }
+
+  /// \brief Class to copy a graph.
+  ///
+  /// Class to copy a graph to another graph (duplicate a graph). The
+  /// simplest way of using it is through the \c copyGraph() function.
+  template <typename To, typename From>
+  class GraphCopy {
+  private:
+
+    typedef typename From::Node Node;
+    typedef typename From::NodeIt NodeIt;
+    typedef typename From::Edge Edge;
+    typedef typename From::EdgeIt EdgeIt;
+
+    typedef typename To::Node TNode;
+    typedef typename To::Edge TEdge;
+
+    typedef typename From::template NodeMap<TNode> NodeRefMap;
+    typedef typename From::template EdgeMap<TEdge> EdgeRefMap;
+    
+    
+  public: 
+
+
+    /// \brief Constructor for the GraphCopy.
+    ///
+    /// It copies the content of the \c _from graph into the
+    /// \c _to graph.
+    GraphCopy(To& _to, const From& _from) 
+      : from(_from), to(_to) {}
+
+    /// \brief Destructor of the GraphCopy
+    ///
+    /// Destructor of the GraphCopy
+    ~GraphCopy() {
+      for (int i = 0; i < int(nodeMapCopies.size()); ++i) {
+        delete nodeMapCopies[i];
+      }
+      for (int i = 0; i < int(edgeMapCopies.size()); ++i) {
+        delete edgeMapCopies[i];
+      }
+
+    }
+
+    /// \brief Copies the node references into the given map.
+    ///
+    /// Copies the node references into the given map.
+    template <typename NodeRef>
+    GraphCopy& nodeRef(NodeRef& map) {
+      nodeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, Node, 
+                              NodeRefMap, NodeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the node cross references into the given map.
+    ///
+    ///  Copies the node cross references (reverse references) into
+    ///  the given map.
+    template <typename NodeCrossRef>
+    GraphCopy& nodeCrossRef(NodeCrossRef& map) {
+      nodeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, Node,
+                              NodeRefMap, NodeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's node type,
+    /// and the copied map's key type is the from graph's node
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    GraphCopy& nodeMap(ToMap& tmap, const FromMap& map) {
+      nodeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, Node, 
+                              NodeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+
+    /// \brief Make a copy of the given node.
+    ///
+    /// Make a copy of the given node.
+    GraphCopy& node(TNode& tnode, const Node& snode) {
+      nodeMapCopies.push_back(new _graph_utils_bits::ItemCopy<From, Node, 
+                              NodeRefMap, TNode>(tnode, snode));
+      return *this;
+    }
+
+    /// \brief Copies the edge references into the given map.
+    ///
+    /// Copies the edge references into the given map.
+    template <typename EdgeRef>
+    GraphCopy& edgeRef(EdgeRef& map) {
+      edgeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, Edge, 
+                              EdgeRefMap, EdgeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the edge cross references into the given map.
+    ///
+    ///  Copies the edge cross references (reverse references) into
+    ///  the given map.
+    template <typename EdgeCrossRef>
+    GraphCopy& edgeCrossRef(EdgeCrossRef& map) {
+      edgeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, Edge,
+                              EdgeRefMap, EdgeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's edge type,
+    /// and the copied map's key type is the from graph's edge
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    GraphCopy& edgeMap(ToMap& tmap, const FromMap& map) {
+      edgeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, Edge, 
+                              EdgeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+
+    /// \brief Make a copy of the given edge.
+    ///
+    /// Make a copy of the given edge.
+    GraphCopy& edge(TEdge& tedge, const Edge& sedge) {
+      edgeMapCopies.push_back(new _graph_utils_bits::ItemCopy<From, Edge, 
+                              EdgeRefMap, TEdge>(tedge, sedge));
+      return *this;
+    }
+
+    /// \brief Executes the copies.
+    ///
+    /// Executes the copies.
+    void run() {
+      NodeRefMap nodeRefMap(from);
+      EdgeRefMap edgeRefMap(from);
+      _graph_utils_bits::GraphCopySelector<To>::
+        copy(to, from, nodeRefMap, edgeRefMap);
+      for (int i = 0; i < int(nodeMapCopies.size()); ++i) {
+        nodeMapCopies[i]->copy(from, nodeRefMap);
+      }
+      for (int i = 0; i < int(edgeMapCopies.size()); ++i) {
+        edgeMapCopies[i]->copy(from, edgeRefMap);
+      }      
+    }
+
+  protected:
+
+
+    const From& from;
+    To& to;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, Node, NodeRefMap>* > 
+    nodeMapCopies;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, Edge, EdgeRefMap>* > 
+    edgeMapCopies;
+
+  };
+
+  /// \brief Copy a graph to another graph.
+  ///
+  /// Copy a graph to another graph.
+  /// The usage of the function:
+  /// 
+  ///\code
+  /// copyGraph(trg, src).nodeRef(nr).edgeCrossRef(ecr).run();
+  ///\endcode
+  /// 
+  /// After the copy the \c nr map will contain the mapping from the
+  /// nodes of the \c from graph to the nodes of the \c to graph and
+  /// \c ecr will contain the mapping from the edges of the \c to graph
+  /// to the edges of the \c from graph.
+  ///
+  /// \see GraphCopy 
+  template <typename To, typename From>
+  GraphCopy<To, From> copyGraph(To& to, const From& from) {
+    return GraphCopy<To, From>(to, from);
+  }
+
+  /// \brief Class to copy an undirected graph.
+  ///
+  /// Class to copy an undirected graph to another graph (duplicate a graph).
+  /// The simplest way of using it is through the \c copyUGraph() function.
+  template <typename To, typename From>
+  class UGraphCopy {
+  private:
+
+    typedef typename From::Node Node;
+    typedef typename From::NodeIt NodeIt;
+    typedef typename From::Edge Edge;
+    typedef typename From::EdgeIt EdgeIt;
+    typedef typename From::UEdge UEdge;
+    typedef typename From::UEdgeIt UEdgeIt;
+
+    typedef typename To::Node TNode;
+    typedef typename To::Edge TEdge;
+    typedef typename To::UEdge TUEdge;
+
+    typedef typename From::template NodeMap<TNode> NodeRefMap;
+    typedef typename From::template UEdgeMap<TUEdge> UEdgeRefMap;
+
+    struct EdgeRefMap {
+      EdgeRefMap(const To& _to, const From& _from,
+                 const UEdgeRefMap& _uedge_ref, const NodeRefMap& _node_ref) 
+        : to(_to), from(_from), 
+          uedge_ref(_uedge_ref), node_ref(_node_ref) {}
+
+      typedef typename From::Edge Key;
+      typedef typename To::Edge Value;
+
+      Value operator[](const Key& key) const {
+        bool forward = 
+          (from.direction(key) == 
+           (node_ref[from.source(static_cast<const UEdge&>(key))] == 
+            to.source(uedge_ref[static_cast<const UEdge&>(key)])));
+	return to.direct(uedge_ref[key], forward); 
+      }
+      
+      const To& to;
+      const From& from;
+      const UEdgeRefMap& uedge_ref;
+      const NodeRefMap& node_ref;
+    };
+
+    
+  public: 
+
+
+    /// \brief Constructor for the GraphCopy.
+    ///
+    /// It copies the content of the \c _from graph into the
+    /// \c _to graph.
+    UGraphCopy(To& _to, const From& _from) 
+      : from(_from), to(_to) {}
+
+    /// \brief Destructor of the GraphCopy
+    ///
+    /// Destructor of the GraphCopy
+    ~UGraphCopy() {
+      for (int i = 0; i < int(nodeMapCopies.size()); ++i) {
+        delete nodeMapCopies[i];
+      }
+      for (int i = 0; i < int(edgeMapCopies.size()); ++i) {
+        delete edgeMapCopies[i];
+      }
+      for (int i = 0; i < int(uEdgeMapCopies.size()); ++i) {
+        delete uEdgeMapCopies[i];
+      }
+
+    }
+
+    /// \brief Copies the node references into the given map.
+    ///
+    /// Copies the node references into the given map.
+    template <typename NodeRef>
+    UGraphCopy& nodeRef(NodeRef& map) {
+      nodeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, Node, 
+                              NodeRefMap, NodeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the node cross references into the given map.
+    ///
+    ///  Copies the node cross references (reverse references) into
+    ///  the given map.
+    template <typename NodeCrossRef>
+    UGraphCopy& nodeCrossRef(NodeCrossRef& map) {
+      nodeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, Node,
+                              NodeRefMap, NodeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's node type,
+    /// and the copied map's key type is the from graph's node
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    UGraphCopy& nodeMap(ToMap& tmap, const FromMap& map) {
+      nodeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, Node, 
+                              NodeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+
+    /// \brief Make a copy of the given node.
+    ///
+    /// Make a copy of the given node.
+    UGraphCopy& node(TNode& tnode, const Node& snode) {
+      nodeMapCopies.push_back(new _graph_utils_bits::ItemCopy<From, Node, 
+                              NodeRefMap, TNode>(tnode, snode));
+      return *this;
+    }
+
+    /// \brief Copies the edge references into the given map.
+    ///
+    /// Copies the edge references into the given map.
+    template <typename EdgeRef>
+    UGraphCopy& edgeRef(EdgeRef& map) {
+      edgeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, Edge, 
+                              EdgeRefMap, EdgeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the edge cross references into the given map.
+    ///
+    ///  Copies the edge cross references (reverse references) into
+    ///  the given map.
+    template <typename EdgeCrossRef>
+    UGraphCopy& edgeCrossRef(EdgeCrossRef& map) {
+      edgeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, Edge,
+                              EdgeRefMap, EdgeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's edge type,
+    /// and the copied map's key type is the from graph's edge
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    UGraphCopy& edgeMap(ToMap& tmap, const FromMap& map) {
+      edgeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, Edge, 
+                              EdgeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+
+    /// \brief Make a copy of the given edge.
+    ///
+    /// Make a copy of the given edge.
+    UGraphCopy& edge(TEdge& tedge, const Edge& sedge) {
+      edgeMapCopies.push_back(new _graph_utils_bits::ItemCopy<From, Edge, 
+                              EdgeRefMap, TEdge>(tedge, sedge));
+      return *this;
+    }
+
+    /// \brief Copies the undirected edge references into the given map.
+    ///
+    /// Copies the undirected edge references into the given map.
+    template <typename UEdgeRef>
+    UGraphCopy& uEdgeRef(UEdgeRef& map) {
+      uEdgeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, UEdge, 
+                               UEdgeRefMap, UEdgeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the undirected edge cross references into the given map.
+    ///
+    /// Copies the undirected edge cross references (reverse
+    /// references) into the given map.
+    template <typename UEdgeCrossRef>
+    UGraphCopy& uEdgeCrossRef(UEdgeCrossRef& map) {
+      uEdgeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, 
+                               UEdge, UEdgeRefMap, UEdgeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's undirected edge type,
+    /// and the copied map's key type is the from graph's undirected edge
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    UGraphCopy& uEdgeMap(ToMap& tmap, const FromMap& map) {
+      uEdgeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, UEdge, 
+                               UEdgeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+
+    /// \brief Make a copy of the given undirected edge.
+    ///
+    /// Make a copy of the given undirected edge.
+    UGraphCopy& uEdge(TUEdge& tuedge, const UEdge& suedge) {
+      uEdgeMapCopies.push_back(new _graph_utils_bits::ItemCopy<From, UEdge, 
+                               UEdgeRefMap, TUEdge>(tuedge, suedge));
+      return *this;
+    }
+
+    /// \brief Executes the copies.
+    ///
+    /// Executes the copies.
+    void run() {
+      NodeRefMap nodeRefMap(from);
+      UEdgeRefMap uEdgeRefMap(from);
+      EdgeRefMap edgeRefMap(to, from, uEdgeRefMap, nodeRefMap);
+      _graph_utils_bits::UGraphCopySelector<To>::
+        copy(to, from, nodeRefMap, uEdgeRefMap);
+      for (int i = 0; i < int(nodeMapCopies.size()); ++i) {
+        nodeMapCopies[i]->copy(from, nodeRefMap);
+      }
+      for (int i = 0; i < int(uEdgeMapCopies.size()); ++i) {
+        uEdgeMapCopies[i]->copy(from, uEdgeRefMap);
+      }
+      for (int i = 0; i < int(edgeMapCopies.size()); ++i) {
+        edgeMapCopies[i]->copy(from, edgeRefMap);
+      }
+    }
+
+  private:
+    
+    const From& from;
+    To& to;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, Node, NodeRefMap>* > 
+    nodeMapCopies;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, Edge, EdgeRefMap>* > 
+    edgeMapCopies;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, UEdge, UEdgeRefMap>* > 
+    uEdgeMapCopies;
+
+  };
+
+  /// \brief Copy an undirected graph to another graph.
+  ///
+  /// Copy an undirected graph to another graph.
+  /// The usage of the function:
+  /// 
+  ///\code
+  /// copyUGraph(trg, src).nodeRef(nr).edgeCrossRef(ecr).run();
+  ///\endcode
+  /// 
+  /// After the copy the \c nr map will contain the mapping from the
+  /// nodes of the \c from graph to the nodes of the \c to graph and
+  /// \c ecr will contain the mapping from the edges of the \c to graph
+  /// to the edges of the \c from graph.
+  ///
+  /// \see UGraphCopy 
+  template <typename To, typename From>
+  UGraphCopy<To, From> 
+  copyUGraph(To& to, const From& from) {
+    return UGraphCopy<To, From>(to, from);
+  }
+
+  /// \brief Class to copy a bipartite undirected graph.
+  ///
+  /// Class to copy a bipartite undirected graph to another graph
+  /// (duplicate a graph).  The simplest way of using it is through
+  /// the \c copyBpUGraph() function.
+  template <typename To, typename From>
+  class BpUGraphCopy {
+  private:
+
+    typedef typename From::Node Node;
+    typedef typename From::ANode ANode;
+    typedef typename From::BNode BNode;
+    typedef typename From::NodeIt NodeIt;
+    typedef typename From::Edge Edge;
+    typedef typename From::EdgeIt EdgeIt;
+    typedef typename From::UEdge UEdge;
+    typedef typename From::UEdgeIt UEdgeIt;
+
+    typedef typename To::Node TNode;
+    typedef typename To::Edge TEdge;
+    typedef typename To::UEdge TUEdge;
+
+    typedef typename From::template ANodeMap<TNode> ANodeRefMap;
+    typedef typename From::template BNodeMap<TNode> BNodeRefMap;
+    typedef typename From::template UEdgeMap<TUEdge> UEdgeRefMap;
+
+    struct NodeRefMap {
+      NodeRefMap(const From& _from, const ANodeRefMap& _anode_ref,
+                 const BNodeRefMap& _bnode_ref)
+        : from(_from), anode_ref(_anode_ref), bnode_ref(_bnode_ref) {}
+
+      typedef typename From::Node Key;
+      typedef typename To::Node Value;
+
+      Value operator[](const Key& key) const {
+	return from.aNode(key) ? anode_ref[key] : bnode_ref[key]; 
+      }
+      
+      const From& from;
+      const ANodeRefMap& anode_ref;
+      const BNodeRefMap& bnode_ref;
+    };
+
+    struct EdgeRefMap {
+      EdgeRefMap(const To& _to, const From& _from,
+                 const UEdgeRefMap& _uedge_ref, const NodeRefMap& _node_ref) 
+        : to(_to), from(_from), 
+          uedge_ref(_uedge_ref), node_ref(_node_ref) {}
+
+      typedef typename From::Edge Key;
+      typedef typename To::Edge Value;
+
+      Value operator[](const Key& key) const {
+        bool forward = 
+          (from.direction(key) == 
+           (node_ref[from.source(static_cast<const UEdge&>(key))] == 
+            to.source(uedge_ref[static_cast<const UEdge&>(key)])));
+	return to.direct(uedge_ref[key], forward); 
+      }
+      
+      const To& to;
+      const From& from;
+      const UEdgeRefMap& uedge_ref;
+      const NodeRefMap& node_ref;
+    };
+    
+  public: 
+
+
+    /// \brief Constructor for the GraphCopy.
+    ///
+    /// It copies the content of the \c _from graph into the
+    /// \c _to graph.
+    BpUGraphCopy(To& _to, const From& _from) 
+      : from(_from), to(_to) {}
+
+    /// \brief Destructor of the GraphCopy
+    ///
+    /// Destructor of the GraphCopy
+    ~BpUGraphCopy() {
+      for (int i = 0; i < int(aNodeMapCopies.size()); ++i) {
+        delete aNodeMapCopies[i];
+      }
+      for (int i = 0; i < int(bNodeMapCopies.size()); ++i) {
+        delete bNodeMapCopies[i];
+      }
+      for (int i = 0; i < int(nodeMapCopies.size()); ++i) {
+        delete nodeMapCopies[i];
+      }
+      for (int i = 0; i < int(edgeMapCopies.size()); ++i) {
+        delete edgeMapCopies[i];
+      }
+      for (int i = 0; i < int(uEdgeMapCopies.size()); ++i) {
+        delete uEdgeMapCopies[i];
+      }
+
+    }
+
+    /// \brief Copies the A-node references into the given map.
+    ///
+    /// Copies the A-node references into the given map.
+    template <typename ANodeRef>
+    BpUGraphCopy& aNodeRef(ANodeRef& map) {
+      aNodeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, ANode, 
+                               ANodeRefMap, ANodeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the A-node cross references into the given map.
+    ///
+    /// Copies the A-node cross references (reverse references) into
+    /// the given map.
+    template <typename ANodeCrossRef>
+    BpUGraphCopy& aNodeCrossRef(ANodeCrossRef& map) {
+      aNodeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, 
+                               ANode, ANodeRefMap, ANodeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given A-node map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's node type,
+    /// and the copied map's key type is the from graph's node
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    BpUGraphCopy& aNodeMap(ToMap& tmap, const FromMap& map) {
+      aNodeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, ANode, 
+                               ANodeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+
+    /// \brief Copies the B-node references into the given map.
+    ///
+    /// Copies the B-node references into the given map.
+    template <typename BNodeRef>
+    BpUGraphCopy& bNodeRef(BNodeRef& map) {
+      bNodeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, BNode, 
+                               BNodeRefMap, BNodeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the B-node cross references into the given map.
+    ///
+    ///  Copies the B-node cross references (reverse references) into
+    ///  the given map.
+    template <typename BNodeCrossRef>
+    BpUGraphCopy& bNodeCrossRef(BNodeCrossRef& map) {
+      bNodeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, 
+                              BNode, BNodeRefMap, BNodeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given B-node map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's node type,
+    /// and the copied map's key type is the from graph's node
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    BpUGraphCopy& bNodeMap(ToMap& tmap, const FromMap& map) {
+      bNodeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, BNode, 
+                               BNodeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+    /// \brief Copies the node references into the given map.
+    ///
+    /// Copies the node references into the given map.
+    template <typename NodeRef>
+    BpUGraphCopy& nodeRef(NodeRef& map) {
+      nodeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, Node, 
+                              NodeRefMap, NodeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the node cross references into the given map.
+    ///
+    ///  Copies the node cross references (reverse references) into
+    ///  the given map.
+    template <typename NodeCrossRef>
+    BpUGraphCopy& nodeCrossRef(NodeCrossRef& map) {
+      nodeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, Node,
+                              NodeRefMap, NodeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's node type,
+    /// and the copied map's key type is the from graph's node
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    BpUGraphCopy& nodeMap(ToMap& tmap, const FromMap& map) {
+      nodeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, Node, 
+                              NodeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+
+    /// \brief Make a copy of the given node.
+    ///
+    /// Make a copy of the given node.
+    BpUGraphCopy& node(TNode& tnode, const Node& snode) {
+      nodeMapCopies.push_back(new _graph_utils_bits::ItemCopy<From, Node, 
+                              NodeRefMap, TNode>(tnode, snode));
+      return *this;
+    }
+
+    /// \brief Copies the edge references into the given map.
+    ///
+    /// Copies the edge references into the given map.
+    template <typename EdgeRef>
+    BpUGraphCopy& edgeRef(EdgeRef& map) {
+      edgeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, Edge, 
+                              EdgeRefMap, EdgeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the edge cross references into the given map.
+    ///
+    ///  Copies the edge cross references (reverse references) into
+    ///  the given map.
+    template <typename EdgeCrossRef>
+    BpUGraphCopy& edgeCrossRef(EdgeCrossRef& map) {
+      edgeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, Edge,
+                              EdgeRefMap, EdgeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's edge type,
+    /// and the copied map's key type is the from graph's edge
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    BpUGraphCopy& edgeMap(ToMap& tmap, const FromMap& map) {
+      edgeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, Edge, 
+                              EdgeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+
+    /// \brief Make a copy of the given edge.
+    ///
+    /// Make a copy of the given edge.
+    BpUGraphCopy& edge(TEdge& tedge, const Edge& sedge) {
+      edgeMapCopies.push_back(new _graph_utils_bits::ItemCopy<From, Edge, 
+                              EdgeRefMap, TEdge>(tedge, sedge));
+      return *this;
+    }
+
+    /// \brief Copies the undirected edge references into the given map.
+    ///
+    /// Copies the undirected edge references into the given map.
+    template <typename UEdgeRef>
+    BpUGraphCopy& uEdgeRef(UEdgeRef& map) {
+      uEdgeMapCopies.push_back(new _graph_utils_bits::RefCopy<From, UEdge, 
+                               UEdgeRefMap, UEdgeRef>(map));
+      return *this;
+    }
+
+    /// \brief Copies the undirected edge cross references into the given map.
+    ///
+    /// Copies the undirected edge cross references (reverse
+    /// references) into the given map.
+    template <typename UEdgeCrossRef>
+    BpUGraphCopy& uEdgeCrossRef(UEdgeCrossRef& map) {
+      uEdgeMapCopies.push_back(new _graph_utils_bits::CrossRefCopy<From, 
+                               UEdge, UEdgeRefMap, UEdgeCrossRef>(map));
+      return *this;
+    }
+
+    /// \brief Make copy of the given map.
+    ///
+    /// Makes copy of the given map for the newly created graph. 
+    /// The new map's key type is the to graph's undirected edge type,
+    /// and the copied map's key type is the from graph's undirected edge
+    /// type.  
+    template <typename ToMap, typename FromMap>
+    BpUGraphCopy& uEdgeMap(ToMap& tmap, const FromMap& map) {
+      uEdgeMapCopies.push_back(new _graph_utils_bits::MapCopy<From, UEdge, 
+                               UEdgeRefMap, ToMap, FromMap>(tmap, map));
+      return *this;
+    }
+
+    /// \brief Make a copy of the given undirected edge.
+    ///
+    /// Make a copy of the given undirected edge.
+    BpUGraphCopy& uEdge(TUEdge& tuedge, const UEdge& suedge) {
+      uEdgeMapCopies.push_back(new _graph_utils_bits::ItemCopy<From, UEdge, 
+                               UEdgeRefMap, TUEdge>(tuedge, suedge));
+      return *this;
+    }
+
+    /// \brief Executes the copies.
+    ///
+    /// Executes the copies.
+    void run() {
+      ANodeRefMap aNodeRefMap(from);
+      BNodeRefMap bNodeRefMap(from);
+      NodeRefMap nodeRefMap(from, aNodeRefMap, bNodeRefMap);
+      UEdgeRefMap uEdgeRefMap(from);
+      EdgeRefMap edgeRefMap(to, from, uEdgeRefMap, nodeRefMap);
+      _graph_utils_bits::BpUGraphCopySelector<To>::
+        copy(to, from, aNodeRefMap, bNodeRefMap, uEdgeRefMap);
+      for (int i = 0; i < int(aNodeMapCopies.size()); ++i) {
+        aNodeMapCopies[i]->copy(from, aNodeRefMap);
+      }
+      for (int i = 0; i < int(bNodeMapCopies.size()); ++i) {
+        bNodeMapCopies[i]->copy(from, bNodeRefMap);
+      }
+      for (int i = 0; i < int(nodeMapCopies.size()); ++i) {
+        nodeMapCopies[i]->copy(from, nodeRefMap);
+      }
+      for (int i = 0; i < int(uEdgeMapCopies.size()); ++i) {
+        uEdgeMapCopies[i]->copy(from, uEdgeRefMap);
+      }
+      for (int i = 0; i < int(edgeMapCopies.size()); ++i) {
+        edgeMapCopies[i]->copy(from, edgeRefMap);
+      }
+    }
+
+  private:
+    
+    const From& from;
+    To& to;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, ANode, ANodeRefMap>* > 
+    aNodeMapCopies;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, BNode, BNodeRefMap>* > 
+    bNodeMapCopies;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, Node, NodeRefMap>* > 
+    nodeMapCopies;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, Edge, EdgeRefMap>* > 
+    edgeMapCopies;
+
+    std::vector<_graph_utils_bits::MapCopyBase<From, UEdge, UEdgeRefMap>* > 
+    uEdgeMapCopies;
+
+  };
+
+  /// \brief Copy a bipartite undirected graph to another graph.
+  ///
+  /// Copy a bipartite undirected graph to another graph.
+  /// The usage of the function:
+  /// 
+  ///\code
+  /// copyBpUGraph(trg, src).aNodeRef(anr).edgeCrossRef(ecr).run();
+  ///\endcode
+  /// 
+  /// After the copy the \c nr map will contain the mapping from the
+  /// nodes of the \c from graph to the nodes of the \c to graph and
+  /// \c ecr will contain the mapping from the edges of the \c to graph
+  /// to the edges of the \c from graph.
+  ///
+  /// \see BpUGraphCopy
+  template <typename To, typename From>
+  BpUGraphCopy<To, From> 
+  copyBpUGraph(To& to, const From& from) {
+    return BpUGraphCopy<To, From>(to, from);
+  }
+
+
+  /// @}
+
+  /// \addtogroup graph_maps
+  /// @{
+
+  /// Provides an immutable and unique id for each item in the graph.
+
+  /// The IdMap class provides a unique and immutable id for each item of the
+  /// same type (e.g. node) in the graph. This id is <ul><li>\b unique:
+  /// different items (nodes) get different ids <li>\b immutable: the id of an
+  /// item (node) does not change (even if you delete other nodes).  </ul>
+  /// Through this map you get access (i.e. can read) the inner id values of
+  /// the items stored in the graph. This map can be inverted with its member
+  /// class \c InverseMap.
+  ///
+  template <typename _Graph, typename _Item>
+  class IdMap {
+  public:
+    typedef _Graph Graph;
+    typedef int Value;
+    typedef _Item Item;
+    typedef _Item Key;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor of the map.
+    explicit IdMap(const Graph& _graph) : graph(&_graph) {}
+
+    /// \brief Gives back the \e id of the item.
+    ///
+    /// Gives back the immutable and unique \e id of the item.
+    int operator[](const Item& item) const { return graph->id(item);}
+
+    /// \brief Gives back the item by its id.
+    ///
+    /// Gives back the item by its id.
+    Item operator()(int id) { return graph->fromId(id, Item()); }
+
+  private:
+    const Graph* graph;
+
+  public:
+
+    /// \brief The class represents the inverse of its owner (IdMap).
+    ///
+    /// The class represents the inverse of its owner (IdMap).
+    /// \see inverse()
+    class InverseMap {
+    public:
+
+      /// \brief Constructor.
+      ///
+      /// Constructor for creating an id-to-item map.
+      explicit InverseMap(const Graph& _graph) : graph(&_graph) {}
+
+      /// \brief Constructor.
+      ///
+      /// Constructor for creating an id-to-item map.
+      explicit InverseMap(const IdMap& idMap) : graph(idMap.graph) {}
+
+      /// \brief Gives back the given item from its id.
+      ///
+      /// Gives back the given item from its id.
+      /// 
+      Item operator[](int id) const { return graph->fromId(id, Item());}
+
+    private:
+      const Graph* graph;
+    };
+
+    /// \brief Gives back the inverse of the map.
+    ///
+    /// Gives back the inverse of the IdMap.
+    InverseMap inverse() const { return InverseMap(*graph);} 
+
+  };
+
+  
+  /// \brief General invertable graph-map type.
+
+  /// This type provides simple invertable graph-maps. 
+  /// The InvertableMap wraps an arbitrary ReadWriteMap 
+  /// and if a key is set to a new value then store it
+  /// in the inverse map.
+  ///
+  /// The values of the map can be accessed
+  /// with stl compatible forward iterator.
+  ///
+  /// \param _Graph The graph type.
+  /// \param _Item The item type of the graph.
+  /// \param _Value The value type of the map.
+  ///
+  /// \see IterableValueMap
+  template <typename _Graph, typename _Item, typename _Value>
+  class InvertableMap : protected DefaultMap<_Graph, _Item, _Value> {
+  private:
+    
+    typedef DefaultMap<_Graph, _Item, _Value> Map;
+    typedef _Graph Graph;
+
+    typedef std::map<_Value, _Item> Container;
+    Container invMap;    
+
+  public:
+ 
+    /// The key type of InvertableMap (Node, Edge, UEdge).
+    typedef typename Map::Key Key;
+    /// The value type of the InvertableMap.
+    typedef typename Map::Value Value;
+
+
+
+    /// \brief Constructor.
+    ///
+    /// Construct a new InvertableMap for the graph.
+    ///
+    explicit InvertableMap(const Graph& graph) : Map(graph) {} 
+
+    /// \brief Forward iterator for values.
+    ///
+    /// This iterator is an stl compatible forward
+    /// iterator on the values of the map. The values can
+    /// be accessed in the [beginValue, endValue) range.
+    ///
+    class ValueIterator 
+      : public std::iterator<std::forward_iterator_tag, Value> {
+      friend class InvertableMap;
+    private:
+      ValueIterator(typename Container::const_iterator _it) 
+        : it(_it) {}
+    public:
+      
+      ValueIterator() {}
+
+      ValueIterator& operator++() { ++it; return *this; }
+      ValueIterator operator++(int) { 
+        ValueIterator tmp(*this); 
+        operator++();
+        return tmp; 
+      }
+
+      const Value& operator*() const { return it->first; }
+      const Value* operator->() const { return &(it->first); }
+
+      bool operator==(ValueIterator jt) const { return it == jt.it; }
+      bool operator!=(ValueIterator jt) const { return it != jt.it; }
+      
+    private:
+      typename Container::const_iterator it;
+    };
+
+    /// \brief Returns an iterator to the first value.
+    ///
+    /// Returns an stl compatible iterator to the 
+    /// first value of the map. The values of the
+    /// map can be accessed in the [beginValue, endValue)
+    /// range.
+    ValueIterator beginValue() const {
+      return ValueIterator(invMap.begin());
+    }
+
+    /// \brief Returns an iterator after the last value.
+    ///
+    /// Returns an stl compatible iterator after the 
+    /// last value of the map. The values of the
+    /// map can be accessed in the [beginValue, endValue)
+    /// range.
+    ValueIterator endValue() const {
+      return ValueIterator(invMap.end());
+    }
+    
+    /// \brief The setter function of the map.
+    ///
+    /// Sets the mapped value.
+    void set(const Key& key, const Value& val) {
+      Value oldval = Map::operator[](key);
+      typename Container::iterator it = invMap.find(oldval);
+      if (it != invMap.end() && it->second == key) {
+	invMap.erase(it);
+      }      
+      invMap.insert(make_pair(val, key));
+      Map::set(key, val);
+    }
+
+    /// \brief The getter function of the map.
+    ///
+    /// It gives back the value associated with the key.
+    typename MapTraits<Map>::ConstReturnValue 
+    operator[](const Key& key) const {
+      return Map::operator[](key);
+    }
+
+    /// \brief Gives back the item by its value.
+    ///
+    /// Gives back the item by its value.
+    Key operator()(const Value& key) const {
+      typename Container::const_iterator it = invMap.find(key);
+      return it != invMap.end() ? it->second : INVALID;
+    }
+
+  protected:
+
+    /// \brief Erase the key from the map.
+    ///
+    /// Erase the key to the map. It is called by the
+    /// \c AlterationNotifier.
+    virtual void erase(const Key& key) {
+      Value val = Map::operator[](key);
+      typename Container::iterator it = invMap.find(val);
+      if (it != invMap.end() && it->second == key) {
+	invMap.erase(it);
+      }
+      Map::erase(key);
+    }
+
+    /// \brief Erase more keys from the map.
+    ///
+    /// Erase more keys from the map. It is called by the
+    /// \c AlterationNotifier.
+    virtual void erase(const std::vector<Key>& keys) {
+      for (int i = 0; i < int(keys.size()); ++i) {
+	Value val = Map::operator[](keys[i]);
+	typename Container::iterator it = invMap.find(val);
+	if (it != invMap.end() && it->second == keys[i]) {
+	  invMap.erase(it);
+	}
+      }
+      Map::erase(keys);
+    }
+
+    /// \brief Clear the keys from the map and inverse map.
+    ///
+    /// Clear the keys from the map and inverse map. It is called by the
+    /// \c AlterationNotifier.
+    virtual void clear() {
+      invMap.clear();
+      Map::clear();
+    }
+
+  public:
+
+    /// \brief The inverse map type.
+    ///
+    /// The inverse of this map. The subscript operator of the map
+    /// gives back always the item what was last assigned to the value. 
+    class InverseMap {
+    public:
+      /// \brief Constructor of the InverseMap.
+      ///
+      /// Constructor of the InverseMap.
+      explicit InverseMap(const InvertableMap& _inverted) 
+        : inverted(_inverted) {}
+
+      /// The value type of the InverseMap.
+      typedef typename InvertableMap::Key Value;
+      /// The key type of the InverseMap.
+      typedef typename InvertableMap::Value Key; 
+
+      /// \brief Subscript operator. 
+      ///
+      /// Subscript operator. It gives back always the item 
+      /// what was last assigned to the value.
+      Value operator[](const Key& key) const {
+	return inverted(key);
+      }
+      
+    private:
+      const InvertableMap& inverted;
+    };
+
+    /// \brief It gives back the just readable inverse map.
+    ///
+    /// It gives back the just readable inverse map.
+    InverseMap inverse() const {
+      return InverseMap(*this);
+    } 
+
+
+    
+  };
+
+  /// \brief Provides a mutable, continuous and unique descriptor for each 
+  /// item in the graph.
+  ///
+  /// The DescriptorMap class provides a unique and continuous (but mutable)
+  /// descriptor (id) for each item of the same type (e.g. node) in the
+  /// graph. This id is <ul><li>\b unique: different items (nodes) get
+  /// different ids <li>\b continuous: the range of the ids is the set of
+  /// integers between 0 and \c n-1, where \c n is the number of the items of
+  /// this type (e.g. nodes) (so the id of a node can change if you delete an
+  /// other node, i.e. this id is mutable).  </ul> This map can be inverted
+  /// with its member class \c InverseMap.
+  ///
+  /// \param _Graph The graph class the \c DescriptorMap belongs to.
+  /// \param _Item The Item is the Key of the Map. It may be Node, Edge or 
+  /// UEdge.
+  template <typename _Graph, typename _Item>
+  class DescriptorMap : protected DefaultMap<_Graph, _Item, int> {
+
+    typedef _Item Item;
+    typedef DefaultMap<_Graph, _Item, int> Map;
+
+  public:
+    /// The graph class of DescriptorMap.
+    typedef _Graph Graph;
+
+    /// The key type of DescriptorMap (Node, Edge, UEdge).
+    typedef typename Map::Key Key;
+    /// The value type of DescriptorMap.
+    typedef typename Map::Value Value;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for descriptor map.
+    explicit DescriptorMap(const Graph& _graph) : Map(_graph) {
+      Item it;
+      const typename Map::Notifier* nf = Map::notifier(); 
+      for (nf->first(it); it != INVALID; nf->next(it)) {
+	Map::set(it, invMap.size());
+	invMap.push_back(it);	
+      }      
+    }
+
+  protected:
+
+    /// \brief Add a new key to the map.
+    ///
+    /// Add a new key to the map. It is called by the
+    /// \c AlterationNotifier.
+    virtual void add(const Item& item) {
+      Map::add(item);
+      Map::set(item, invMap.size());
+      invMap.push_back(item);
+    }
+
+    /// \brief Add more new keys to the map.
+    ///
+    /// Add more new keys to the map. It is called by the
+    /// \c AlterationNotifier.
+    virtual void add(const std::vector<Item>& items) {
+      Map::add(items);
+      for (int i = 0; i < int(items.size()); ++i) {
+	Map::set(items[i], invMap.size());
+	invMap.push_back(items[i]);
+      }
+    }
+
+    /// \brief Erase the key from the map.
+    ///
+    /// Erase the key from the map. It is called by the
+    /// \c AlterationNotifier.
+    virtual void erase(const Item& item) {
+      Map::set(invMap.back(), Map::operator[](item));
+      invMap[Map::operator[](item)] = invMap.back();
+      invMap.pop_back();
+      Map::erase(item);
+    }
+
+    /// \brief Erase more keys from the map.
+    ///
+    /// Erase more keys from the map. It is called by the
+    /// \c AlterationNotifier.
+    virtual void erase(const std::vector<Item>& items) {
+      for (int i = 0; i < int(items.size()); ++i) {
+	Map::set(invMap.back(), Map::operator[](items[i]));
+	invMap[Map::operator[](items[i])] = invMap.back();
+	invMap.pop_back();
+      }
+      Map::erase(items);
+    }
+
+    /// \brief Build the unique map.
+    ///
+    /// Build the unique map. It is called by the
+    /// \c AlterationNotifier.
+    virtual void build() {
+      Map::build();
+      Item it;
+      const typename Map::Notifier* nf = Map::notifier(); 
+      for (nf->first(it); it != INVALID; nf->next(it)) {
+	Map::set(it, invMap.size());
+	invMap.push_back(it);	
+      }      
+    }
+    
+    /// \brief Clear the keys from the map.
+    ///
+    /// Clear the keys from the map. It is called by the
+    /// \c AlterationNotifier.
+    virtual void clear() {
+      invMap.clear();
+      Map::clear();
+    }
+
+  public:
+
+    /// \brief Returns the maximal value plus one.
+    ///
+    /// Returns the maximal value plus one in the map.
+    unsigned int size() const {
+      return invMap.size();
+    }
+
+    /// \brief Swaps the position of the two items in the map.
+    ///
+    /// Swaps the position of the two items in the map.
+    void swap(const Item& p, const Item& q) {
+      int pi = Map::operator[](p);
+      int qi = Map::operator[](q);
+      Map::set(p, qi);
+      invMap[qi] = p;
+      Map::set(q, pi);
+      invMap[pi] = q;
+    }
+
+    /// \brief Gives back the \e descriptor of the item.
+    ///
+    /// Gives back the mutable and unique \e descriptor of the map.
+    int operator[](const Item& item) const {
+      return Map::operator[](item);
+    }
+
+    /// \brief Gives back the item by its descriptor.
+    ///
+    /// Gives back th item by its descriptor.
+    Item operator()(int id) const {
+      return invMap[id];
+    }
+    
+  private:
+
+    typedef std::vector<Item> Container;
+    Container invMap;
+
+  public:
+    /// \brief The inverse map type of DescriptorMap.
+    ///
+    /// The inverse map type of DescriptorMap.
+    class InverseMap {
+    public:
+      /// \brief Constructor of the InverseMap.
+      ///
+      /// Constructor of the InverseMap.
+      explicit InverseMap(const DescriptorMap& _inverted) 
+	: inverted(_inverted) {}
+
+
+      /// The value type of the InverseMap.
+      typedef typename DescriptorMap::Key Value;
+      /// The key type of the InverseMap.
+      typedef typename DescriptorMap::Value Key; 
+
+      /// \brief Subscript operator. 
+      ///
+      /// Subscript operator. It gives back the item 
+      /// that the descriptor belongs to currently.
+      Value operator[](const Key& key) const {
+	return inverted(key);
+      }
+
+      /// \brief Size of the map.
+      ///
+      /// Returns the size of the map.
+      unsigned int size() const {
+	return inverted.size();
+      }
+      
+    private:
+      const DescriptorMap& inverted;
+    };
+
+    /// \brief Gives back the inverse of the map.
+    ///
+    /// Gives back the inverse of the map.
+    const InverseMap inverse() const {
+      return InverseMap(*this);
+    }
+  };
+
+  /// \brief Returns the source of the given edge.
+  ///
+  /// The SourceMap gives back the source Node of the given edge. 
+  /// \see TargetMap
+  /// \author Balazs Dezso
+  template <typename Graph>
+  class SourceMap {
+  public:
+
+    typedef typename Graph::Node Value;
+    typedef typename Graph::Edge Key;
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    /// \param _graph The graph that the map belongs to.
+    explicit SourceMap(const Graph& _graph) : graph(_graph) {}
+
+    /// \brief The subscript operator.
+    ///
+    /// The subscript operator.
+    /// \param edge The edge 
+    /// \return The source of the edge 
+    Value operator[](const Key& edge) const {
+      return graph.source(edge);
+    }
+
+  private:
+    const Graph& graph;
+  };
+
+  /// \brief Returns a \ref SourceMap class.
+  ///
+  /// This function just returns an \ref SourceMap class.
+  /// \relates SourceMap
+  template <typename Graph>
+  inline SourceMap<Graph> sourceMap(const Graph& graph) {
+    return SourceMap<Graph>(graph);
+  } 
+
+  /// \brief Returns the target of the given edge.
+  ///
+  /// The TargetMap gives back the target Node of the given edge. 
+  /// \see SourceMap
+  /// \author Balazs Dezso
+  template <typename Graph>
+  class TargetMap {
+  public:
+
+    typedef typename Graph::Node Value;
+    typedef typename Graph::Edge Key;
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    /// \param _graph The graph that the map belongs to.
+    explicit TargetMap(const Graph& _graph) : graph(_graph) {}
+
+    /// \brief The subscript operator.
+    ///
+    /// The subscript operator.
+    /// \param e The edge 
+    /// \return The target of the edge 
+    Value operator[](const Key& e) const {
+      return graph.target(e);
+    }
+
+  private:
+    const Graph& graph;
+  };
+
+  /// \brief Returns a \ref TargetMap class.
+  ///
+  /// This function just returns a \ref TargetMap class.
+  /// \relates TargetMap
+  template <typename Graph>
+  inline TargetMap<Graph> targetMap(const Graph& graph) {
+    return TargetMap<Graph>(graph);
+  }
+
+  /// \brief Returns the "forward" directed edge view of an undirected edge.
+  ///
+  /// Returns the "forward" directed edge view of an undirected edge.
+  /// \see BackwardMap
+  /// \author Balazs Dezso
+  template <typename Graph>
+  class ForwardMap {
+  public:
+
+    typedef typename Graph::Edge Value;
+    typedef typename Graph::UEdge Key;
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    /// \param _graph The graph that the map belongs to.
+    explicit ForwardMap(const Graph& _graph) : graph(_graph) {}
+
+    /// \brief The subscript operator.
+    ///
+    /// The subscript operator.
+    /// \param key An undirected edge 
+    /// \return The "forward" directed edge view of undirected edge 
+    Value operator[](const Key& key) const {
+      return graph.direct(key, true);
+    }
+
+  private:
+    const Graph& graph;
+  };
+
+  /// \brief Returns a \ref ForwardMap class.
+  ///
+  /// This function just returns an \ref ForwardMap class.
+  /// \relates ForwardMap
+  template <typename Graph>
+  inline ForwardMap<Graph> forwardMap(const Graph& graph) {
+    return ForwardMap<Graph>(graph);
+  }
+
+  /// \brief Returns the "backward" directed edge view of an undirected edge.
+  ///
+  /// Returns the "backward" directed edge view of an undirected edge.
+  /// \see ForwardMap
+  /// \author Balazs Dezso
+  template <typename Graph>
+  class BackwardMap {
+  public:
+
+    typedef typename Graph::Edge Value;
+    typedef typename Graph::UEdge Key;
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    /// \param _graph The graph that the map belongs to.
+    explicit BackwardMap(const Graph& _graph) : graph(_graph) {}
+
+    /// \brief The subscript operator.
+    ///
+    /// The subscript operator.
+    /// \param key An undirected edge 
+    /// \return The "backward" directed edge view of undirected edge 
+    Value operator[](const Key& key) const {
+      return graph.direct(key, false);
+    }
+
+  private:
+    const Graph& graph;
+  };
+
+  /// \brief Returns a \ref BackwardMap class
+
+  /// This function just returns a \ref BackwardMap class.
+  /// \relates BackwardMap
+  template <typename Graph>
+  inline BackwardMap<Graph> backwardMap(const Graph& graph) {
+    return BackwardMap<Graph>(graph);
+  }
+
+  /// \brief Potential difference map
+  ///
+  /// If there is an potential map on the nodes then we
+  /// can get an edge map as we get the substraction of the
+  /// values of the target and source.
+  template <typename Graph, typename NodeMap>
+  class PotentialDifferenceMap {
+  public:
+    typedef typename Graph::Edge Key;
+    typedef typename NodeMap::Value Value;
+
+    /// \brief Constructor
+    ///
+    /// Contructor of the map
+    explicit PotentialDifferenceMap(const Graph& _graph, 
+                                    const NodeMap& _potential) 
+      : graph(_graph), potential(_potential) {}
+
+    /// \brief Const subscription operator
+    ///
+    /// Const subscription operator
+    Value operator[](const Key& edge) const {
+      return potential[graph.target(edge)] - potential[graph.source(edge)];
+    }
+
+  private:
+    const Graph& graph;
+    const NodeMap& potential;
+  };
+
+  /// \brief Returns a PotentialDifferenceMap.
+  ///
+  /// This function just returns a PotentialDifferenceMap.
+  /// \relates PotentialDifferenceMap
+  template <typename Graph, typename NodeMap>
+  PotentialDifferenceMap<Graph, NodeMap> 
+  potentialDifferenceMap(const Graph& graph, const NodeMap& potential) {
+    return PotentialDifferenceMap<Graph, NodeMap>(graph, potential);
+  }
+
+  /// \brief Map of the node in-degrees.
+  ///
+  /// This map returns the in-degree of a node. Once it is constructed,
+  /// the degrees are stored in a standard NodeMap, so each query is done
+  /// in constant time. On the other hand, the values are updated automatically
+  /// whenever the graph changes.
+  ///
+  /// \warning Besides addNode() and addEdge(), a graph structure may provide
+  /// alternative ways to modify the graph. The correct behavior of InDegMap
+  /// is not guarantied if these additional features are used. For example
+  /// the functions \ref ListGraph::changeSource() "changeSource()",
+  /// \ref ListGraph::changeTarget() "changeTarget()" and
+  /// \ref ListGraph::reverseEdge() "reverseEdge()"
+  /// of \ref ListGraph will \e not update the degree values correctly.
+  ///
+  /// \sa OutDegMap
+
+  template <typename _Graph>
+  class InDegMap  
+    : protected ItemSetTraits<_Graph, typename _Graph::Edge>
+      ::ItemNotifier::ObserverBase {
+
+  public:
+    
+    typedef _Graph Graph;
+    typedef int Value;
+    typedef typename Graph::Node Key;
+
+    typedef typename ItemSetTraits<_Graph, typename _Graph::Edge>
+    ::ItemNotifier::ObserverBase Parent;
+
+  private:
+
+    class AutoNodeMap : public DefaultMap<_Graph, Key, int> {
+    public:
+
+      typedef DefaultMap<_Graph, Key, int> Parent;
+      typedef typename Parent::Graph Graph;
+
+      AutoNodeMap(const Graph& graph) : Parent(graph, 0) {}
+      
+      virtual void add(const Key& key) {
+	Parent::add(key);
+	Parent::set(key, 0);
+      }
+
+      virtual void add(const std::vector<Key>& keys) {
+	Parent::add(keys);
+	for (int i = 0; i < int(keys.size()); ++i) {
+	  Parent::set(keys[i], 0);
+	}
+      }
+
+      virtual void build() {
+	Parent::build();
+	Key it;
+	typename Parent::Notifier* nf = Parent::notifier();
+	for (nf->first(it); it != INVALID; nf->next(it)) {
+	  Parent::set(it, 0);
+	}
+      }
+    };
+
+  public:
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for creating in-degree map.
+    explicit InDegMap(const Graph& _graph) : graph(_graph), deg(_graph) {
+      Parent::attach(graph.notifier(typename _Graph::Edge()));
+      
+      for(typename _Graph::NodeIt it(graph); it != INVALID; ++it) {
+	deg[it] = countInEdges(graph, it);
+      }
+    }
+    
+    /// Gives back the in-degree of a Node.
+    int operator[](const Key& key) const {
+      return deg[key];
+    }
+
+  protected:
+    
+    typedef typename Graph::Edge Edge;
+
+    virtual void add(const Edge& edge) {
+      ++deg[graph.target(edge)];
+    }
+
+    virtual void add(const std::vector<Edge>& edges) {
+      for (int i = 0; i < int(edges.size()); ++i) {
+        ++deg[graph.target(edges[i])];
+      }
+    }
+
+    virtual void erase(const Edge& edge) {
+      --deg[graph.target(edge)];
+    }
+
+    virtual void erase(const std::vector<Edge>& edges) {
+      for (int i = 0; i < int(edges.size()); ++i) {
+        --deg[graph.target(edges[i])];
+      }
+    }
+
+    virtual void build() {
+      for(typename _Graph::NodeIt it(graph); it != INVALID; ++it) {
+	deg[it] = countInEdges(graph, it);
+      }      
+    }
+
+    virtual void clear() {
+      for(typename _Graph::NodeIt it(graph); it != INVALID; ++it) {
+	deg[it] = 0;
+      }
+    }
+  private:
+    
+    const _Graph& graph;
+    AutoNodeMap deg;
+  };
+
+  /// \brief Map of the node out-degrees.
+  ///
+  /// This map returns the out-degree of a node. Once it is constructed,
+  /// the degrees are stored in a standard NodeMap, so each query is done
+  /// in constant time. On the other hand, the values are updated automatically
+  /// whenever the graph changes.
+  ///
+  /// \warning Besides addNode() and addEdge(), a graph structure may provide
+  /// alternative ways to modify the graph. The correct behavior of OutDegMap
+  /// is not guarantied if these additional features are used. For example
+  /// the functions \ref ListGraph::changeSource() "changeSource()",
+  /// \ref ListGraph::changeTarget() "changeTarget()" and
+  /// \ref ListGraph::reverseEdge() "reverseEdge()"
+  /// of \ref ListGraph will \e not update the degree values correctly.
+  ///
+  /// \sa InDegMap
+
+  template <typename _Graph>
+  class OutDegMap  
+    : protected ItemSetTraits<_Graph, typename _Graph::Edge>
+      ::ItemNotifier::ObserverBase {
+
+  public:
+
+    typedef typename ItemSetTraits<_Graph, typename _Graph::Edge>
+    ::ItemNotifier::ObserverBase Parent;
+    
+    typedef _Graph Graph;
+    typedef int Value;
+    typedef typename Graph::Node Key;
+
+  private:
+
+    class AutoNodeMap : public DefaultMap<_Graph, Key, int> {
+    public:
+
+      typedef DefaultMap<_Graph, Key, int> Parent;
+      typedef typename Parent::Graph Graph;
+
+      AutoNodeMap(const Graph& graph) : Parent(graph, 0) {}
+      
+      virtual void add(const Key& key) {
+	Parent::add(key);
+	Parent::set(key, 0);
+      }
+      virtual void add(const std::vector<Key>& keys) {
+	Parent::add(keys);
+	for (int i = 0; i < int(keys.size()); ++i) {
+	  Parent::set(keys[i], 0);
+	}
+      }
+      virtual void build() {
+	Parent::build();
+	Key it;
+	typename Parent::Notifier* nf = Parent::notifier();
+	for (nf->first(it); it != INVALID; nf->next(it)) {
+	  Parent::set(it, 0);
+	}
+      }
+    };
+
+  public:
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for creating out-degree map.
+    explicit OutDegMap(const Graph& _graph) : graph(_graph), deg(_graph) {
+      Parent::attach(graph.notifier(typename _Graph::Edge()));
+      
+      for(typename _Graph::NodeIt it(graph); it != INVALID; ++it) {
+	deg[it] = countOutEdges(graph, it);
+      }
+    }
+
+    /// Gives back the out-degree of a Node.
+    int operator[](const Key& key) const {
+      return deg[key];
+    }
+
+  protected:
+    
+    typedef typename Graph::Edge Edge;
+
+    virtual void add(const Edge& edge) {
+      ++deg[graph.source(edge)];
+    }
+
+    virtual void add(const std::vector<Edge>& edges) {
+      for (int i = 0; i < int(edges.size()); ++i) {
+        ++deg[graph.source(edges[i])];
+      }
+    }
+
+    virtual void erase(const Edge& edge) {
+      --deg[graph.source(edge)];
+    }
+
+    virtual void erase(const std::vector<Edge>& edges) {
+      for (int i = 0; i < int(edges.size()); ++i) {
+        --deg[graph.source(edges[i])];
+      }
+    }
+
+    virtual void build() {
+      for(typename _Graph::NodeIt it(graph); it != INVALID; ++it) {
+	deg[it] = countOutEdges(graph, it);
+      }      
+    }
+
+    virtual void clear() {
+      for(typename _Graph::NodeIt it(graph); it != INVALID; ++it) {
+	deg[it] = 0;
+      }
+    }
+  private:
+    
+    const _Graph& graph;
+    AutoNodeMap deg;
+  };
+
+
+  ///Dynamic edge look up between given endpoints.
+  
+  ///\ingroup gutils
+  ///Using this class, you can find an edge in a graph from a given
+  ///source to a given target in amortized time <em>O(log d)</em>,
+  ///where <em>d</em> is the out-degree of the source node.
+  ///
+  ///It is possible to find \e all parallel edges between two nodes with
+  ///the \c findFirst() and \c findNext() members.
+  ///
+  ///See the \ref EdgeLookUp and \ref AllEdgeLookUp classes if your
+  ///graph do not changed so frequently.
+  ///
+  ///This class uses a self-adjusting binary search tree, Sleator's
+  ///and Tarjan's Splay tree for guarantee the logarithmic amortized
+  ///time bound for edge lookups. This class also guarantees the
+  ///optimal time bound in a constant factor for any distribution of
+  ///queries.
+  ///
+  ///\param G The type of the underlying graph.  
+  ///
+  ///\sa EdgeLookUp  
+  ///\sa AllEdgeLookUp  
+  template<class G>
+  class DynEdgeLookUp 
+    : protected ItemSetTraits<G, typename G::Edge>::ItemNotifier::ObserverBase
+  {
+  public:
+    typedef typename ItemSetTraits<G, typename G::Edge>
+    ::ItemNotifier::ObserverBase Parent;
+
+    GRAPH_TYPEDEFS(typename G);
+    typedef G Graph;
+
+  protected:
+
+    class AutoNodeMap : public DefaultMap<G, Node, Edge> {
+    public:
+
+      typedef DefaultMap<G, Node, Edge> Parent;
+
+      AutoNodeMap(const G& graph) : Parent(graph, INVALID) {}
+      
+      virtual void add(const Node& node) {
+	Parent::add(node);
+	Parent::set(node, INVALID);
+      }
+
+      virtual void add(const std::vector<Node>& nodes) {
+	Parent::add(nodes);
+	for (int i = 0; i < int(nodes.size()); ++i) {
+	  Parent::set(nodes[i], INVALID);
+	}
+      }
+
+      virtual void build() {
+	Parent::build();
+	Node it;
+	typename Parent::Notifier* nf = Parent::notifier();
+	for (nf->first(it); it != INVALID; nf->next(it)) {
+	  Parent::set(it, INVALID);
+	}
+      }
+    };
+
+    const Graph &_g;
+    AutoNodeMap _head;
+    typename Graph::template EdgeMap<Edge> _parent;
+    typename Graph::template EdgeMap<Edge> _left;
+    typename Graph::template EdgeMap<Edge> _right;
+    
+    class EdgeLess {
+      const Graph &g;
+    public:
+      EdgeLess(const Graph &_g) : g(_g) {}
+      bool operator()(Edge a,Edge b) const 
+      {
+	return g.target(a)<g.target(b);
+      }
+    };
+    
+  public:
+    
+    ///Constructor
+
+    ///Constructor.
+    ///
+    ///It builds up the search database.
+    DynEdgeLookUp(const Graph &g) 
+      : _g(g),_head(g),_parent(g),_left(g),_right(g) 
+    { 
+      Parent::attach(_g.notifier(typename Graph::Edge()));
+      refresh(); 
+    }
+    
+  protected:
+
+    virtual void add(const Edge& edge) {
+      insert(edge);
+    }
+
+    virtual void add(const std::vector<Edge>& edges) {
+      for (int i = 0; i < int(edges.size()); ++i) {
+	insert(edges[i]);
+      }
+    }
+
+    virtual void erase(const Edge& edge) {
+      remove(edge);
+    }
+
+    virtual void erase(const std::vector<Edge>& edges) {
+      for (int i = 0; i < int(edges.size()); ++i) {
+	remove(edges[i]);
+      }     
+    }
+
+    virtual void build() {
+      refresh();
+    }
+
+    virtual void clear() {
+      for(NodeIt n(_g);n!=INVALID;++n) {
+	_head.set(n, INVALID);
+      }
+    }
+
+    void insert(Edge edge) {
+      Node s = _g.source(edge);
+      Node t = _g.target(edge);
+      _left.set(edge, INVALID);
+      _right.set(edge, INVALID);
+      
+      Edge e = _head[s];
+      if (e == INVALID) {
+	_head.set(s, edge);
+	_parent.set(edge, INVALID);
+	return;
+      }
+      while (true) {
+	if (t < _g.target(e)) {
+	  if (_left[e] == INVALID) {
+	    _left.set(e, edge);
+	    _parent.set(edge, e);
+	    splay(edge);
+	    return;
+	  } else {
+	    e = _left[e];
+	  }
+	} else {
+	  if (_right[e] == INVALID) {
+	    _right.set(e, edge);
+	    _parent.set(edge, e);
+	    splay(edge);
+	    return;
+	  } else {
+	    e = _right[e];
+	  }
+	}
+      }
+    }
+
+    void remove(Edge edge) {
+      if (_left[edge] == INVALID) {
+	if (_right[edge] != INVALID) {
+	  _parent.set(_right[edge], _parent[edge]);
+	}
+	if (_parent[edge] != INVALID) {
+	  if (_left[_parent[edge]] == edge) {
+	    _left.set(_parent[edge], _right[edge]);
+	  } else {
+	    _right.set(_parent[edge], _right[edge]);
+	  }
+	} else {
+	  _head.set(_g.source(edge), _right[edge]);
+	}
+      } else if (_right[edge] == INVALID) {
+	_parent.set(_left[edge], _parent[edge]);
+	if (_parent[edge] != INVALID) {
+	  if (_left[_parent[edge]] == edge) {
+	    _left.set(_parent[edge], _left[edge]);
+	  } else {
+	    _right.set(_parent[edge], _left[edge]);
+	  }
+	} else {
+	  _head.set(_g.source(edge), _left[edge]);
+	}
+      } else {
+	Edge e = _left[edge];
+	if (_right[e] != INVALID) {
+	  e = _right[e];	  
+	  while (_right[e] != INVALID) {
+	    e = _right[e];
+	  }
+	  Edge s = _parent[e];
+	  _right.set(_parent[e], _left[e]);
+	  if (_left[e] != INVALID) {
+	    _parent.set(_left[e], _parent[e]);
+	  }
+	  
+	  _left.set(e, _left[edge]);
+	  _parent.set(_left[edge], e);
+	  _right.set(e, _right[edge]);
+	  _parent.set(_right[edge], e);
+
+	  _parent.set(e, _parent[edge]);
+	  if (_parent[edge] != INVALID) {
+	    if (_left[_parent[edge]] == edge) {
+	      _left.set(_parent[edge], e);
+	    } else {
+	      _right.set(_parent[edge], e);
+	    }
+	  }
+	  splay(s);
+	} else {
+	  _right.set(e, _right[edge]);
+	  _parent.set(_right[edge], e);
+	  _parent.set(e, _parent[edge]);
+	  
+	  if (_parent[edge] != INVALID) {
+	    if (_left[_parent[edge]] == edge) {
+	      _left.set(_parent[edge], e);
+	    } else {
+	      _right.set(_parent[edge], e);
+	    }
+	  } else {
+	    _head.set(_g.source(edge), e);
+	  }
+	}
+      }
+    }
+
+    Edge refreshRec(std::vector<Edge> &v,int a,int b) 
+    {
+      int m=(a+b)/2;
+      Edge me=v[m];
+      if (a < m) {
+	Edge left = refreshRec(v,a,m-1);
+	_left.set(me, left);
+	_parent.set(left, me);
+      } else {
+	_left.set(me, INVALID);
+      }
+      if (m < b) {
+	Edge right = refreshRec(v,m+1,b);
+	_right.set(me, right);
+	_parent.set(right, me);
+      } else {
+	_right.set(me, INVALID);
+      }
+      return me;
+    }
+
+    void refresh() {
+      for(NodeIt n(_g);n!=INVALID;++n) {
+	std::vector<Edge> v;
+	for(OutEdgeIt e(_g,n);e!=INVALID;++e) v.push_back(e);
+	if(v.size()) {
+	  std::sort(v.begin(),v.end(),EdgeLess(_g));
+	  Edge head = refreshRec(v,0,v.size()-1);
+	  _head.set(n, head);
+	  _parent.set(head, INVALID);
+	}
+	else _head.set(n, INVALID);
+      }
+    }
+
+    void zig(Edge v) {        
+      Edge w = _parent[v];
+      _parent.set(v, _parent[w]);
+      _parent.set(w, v);
+      _left.set(w, _right[v]);
+      _right.set(v, w);
+      if (_parent[v] != INVALID) {
+	if (_right[_parent[v]] == w) {
+	  _right.set(_parent[v], v);
+	} else {
+	  _left.set(_parent[v], v);
+	}
+      }
+      if (_left[w] != INVALID){
+	_parent.set(_left[w], w);
+      }
+    }
+
+    void zag(Edge v) {        
+      Edge w = _parent[v];
+      _parent.set(v, _parent[w]);
+      _parent.set(w, v);
+      _right.set(w, _left[v]);
+      _left.set(v, w);
+      if (_parent[v] != INVALID){
+	if (_left[_parent[v]] == w) {
+	  _left.set(_parent[v], v);
+	} else {
+	  _right.set(_parent[v], v);
+	}
+      }
+      if (_right[w] != INVALID){
+	_parent.set(_right[w], w);
+      }
+    }
+
+    void splay(Edge v) {
+      while (_parent[v] != INVALID) {
+	if (v == _left[_parent[v]]) {
+	  if (_parent[_parent[v]] == INVALID) {
+	    zig(v);
+	  } else {
+	    if (_parent[v] == _left[_parent[_parent[v]]]) {
+	      zig(_parent[v]);
+	      zig(v);
+	    } else {
+	      zig(v);
+	      zag(v);
+	    }
+	  }
+	} else {
+	  if (_parent[_parent[v]] == INVALID) {
+	    zag(v);
+	  } else {
+	    if (_parent[v] == _left[_parent[_parent[v]]]) {
+	      zag(v);
+	      zig(v);
+	    } else {
+	      zag(_parent[v]);
+	      zag(v);
+	    }
+	  }
+	}
+      }
+      _head[_g.source(v)] = v;
+    }
+
+
+  public:
+    
+    ///Find an edge between two nodes.
+    
+    ///Find an edge between two nodes in time <em>O(</em>log<em>d)</em>, where
+    /// <em>d</em> is the number of outgoing edges of \c s.
+    ///\param s The source node
+    ///\param t The target node
+    ///\return An edge from \c s to \c t if there exists,
+    ///\ref INVALID otherwise.
+    Edge operator()(Node s, Node t) const
+    {
+      Edge e = _head[s];
+      if (e == INVALID) return INVALID;
+      while (true) {
+	if (_g.target(e) == t) {
+	  const_cast<DynEdgeLookUp&>(*this).splay(e);
+	  return e;
+	} else if (t < _g.target(e)) {
+	  if (_left[e] == INVALID) {
+	    const_cast<DynEdgeLookUp&>(*this).splay(e);
+	    return INVALID;
+	  } else {
+	    e = _left[e];
+	  }
+	} else  {
+	  if (_right[e] == INVALID) {
+	    const_cast<DynEdgeLookUp&>(*this).splay(e);
+	    return INVALID;
+	  } else {
+	    e = _right[e];
+	  }
+	}
+      }
+    }
+
+    ///Find the first edge between two nodes.
+    
+    ///Find the first edge between two nodes in time
+    /// <em>O(</em>log<em>d)</em>, where <em>d</em> is the number of
+    /// outgoing edges of \c s.  
+    ///\param s The source node 
+    ///\param t The target node
+    ///\return An edge from \c s to \c t if there exists, \ref INVALID
+    /// otherwise.
+    Edge findFirst(Node s, Node t) const
+    {
+      Edge e = _head[s];
+      Edge r = INVALID;
+      while (true) {
+	if (_g.target(e) < t) {
+	  if (_right[e] == INVALID) {
+	    const_cast<DynEdgeLookUp&>(*this).splay(e);
+	    return r;
+	  } else {
+	    e = _right[e];
+	  }
+	} else {
+	  if (_g.target(e) == t) {
+	    r = e;
+	  }
+	  if (_left[e] == INVALID) {
+	    const_cast<DynEdgeLookUp&>(*this).splay(e);
+	    return r;
+	  } else {
+	    e = _left[e];
+	  }
+	}
+      }
+    }
+
+    ///Find the next edge between two nodes.
+    
+    ///Find the next edge between two nodes in time
+    /// <em>O(</em>log<em>d)</em>, where <em>d</em> is the number of
+    /// outgoing edges of \c s.  
+    ///\param s The source node 
+    ///\param t The target node
+    ///\return An edge from \c s to \c t if there exists, \ref INVALID
+    /// otherwise.
+
+    ///\note If \c e is not the result of the previous \c findFirst()
+    ///operation then the amorized time bound can not be guaranteed.
+#ifdef DOXYGEN
+    Edge findNext(Node s, Node t, Edge e) const
+#else
+    Edge findNext(Node, Node t, Edge e) const
+#endif
+    {
+      if (_right[e] != INVALID) {
+	e = _right[e];
+	while (_left[e] != INVALID) {
+	  e = _left[e];
+	}
+	const_cast<DynEdgeLookUp&>(*this).splay(e);
+      } else {
+	while (_parent[e] != INVALID && _right[_parent[e]] ==  e) {
+	  e = _parent[e];
+	}
+	if (_parent[e] == INVALID) {
+	  return INVALID;
+	} else {
+	  e = _parent[e];
+	  const_cast<DynEdgeLookUp&>(*this).splay(e);
+	}
+      }
+      if (_g.target(e) == t) return e;
+      else return INVALID;    
+    }
+
+  };
+
+  ///Fast edge look up between given endpoints.
+  
+  ///\ingroup gutils
+  ///Using this class, you can find an edge in a graph from a given
+  ///source to a given target in time <em>O(log d)</em>,
+  ///where <em>d</em> is the out-degree of the source node.
+  ///
+  ///It is not possible to find \e all parallel edges between two nodes.
+  ///Use \ref AllEdgeLookUp for this purpose.
+  ///
+  ///\warning This class is static, so you should refresh() (or at least
+  ///refresh(Node)) this data structure
+  ///whenever the graph changes. This is a time consuming (superlinearly
+  ///proportional (<em>O(m</em>log<em>m)</em>) to the number of edges).
+  ///
+  ///\param G The type of the underlying graph.
+  ///
+  ///\sa DynEdgeLookUp
+  ///\sa AllEdgeLookUp  
+  template<class G>
+  class EdgeLookUp 
+  {
+  public:
+    GRAPH_TYPEDEFS(typename G);
+    typedef G Graph;
+
+  protected:
+    const Graph &_g;
+    typename Graph::template NodeMap<Edge> _head;
+    typename Graph::template EdgeMap<Edge> _left;
+    typename Graph::template EdgeMap<Edge> _right;
+    
+    class EdgeLess {
+      const Graph &g;
+    public:
+      EdgeLess(const Graph &_g) : g(_g) {}
+      bool operator()(Edge a,Edge b) const 
+      {
+	return g.target(a)<g.target(b);
+      }
+    };
+    
+  public:
+    
+    ///Constructor
+
+    ///Constructor.
+    ///
+    ///It builds up the search database, which remains valid until the graph
+    ///changes.
+    EdgeLookUp(const Graph &g) :_g(g),_head(g),_left(g),_right(g) {refresh();}
+    
+  private:
+    Edge refreshRec(std::vector<Edge> &v,int a,int b) 
+    {
+      int m=(a+b)/2;
+      Edge me=v[m];
+      _left[me] = a<m?refreshRec(v,a,m-1):INVALID;
+      _right[me] = m<b?refreshRec(v,m+1,b):INVALID;
+      return me;
+    }
+  public:
+    ///Refresh the data structure at a node.
+
+    ///Build up the search database of node \c n.
+    ///
+    ///It runs in time <em>O(d</em>log<em>d)</em>, where <em>d</em> is
+    ///the number of the outgoing edges of \c n.
+    void refresh(Node n) 
+    {
+      std::vector<Edge> v;
+      for(OutEdgeIt e(_g,n);e!=INVALID;++e) v.push_back(e);
+      if(v.size()) {
+	std::sort(v.begin(),v.end(),EdgeLess(_g));
+	_head[n]=refreshRec(v,0,v.size()-1);
+      }
+      else _head[n]=INVALID;
+    }
+    ///Refresh the full data structure.
+
+    ///Build up the full search database. In fact, it simply calls
+    ///\ref refresh(Node) "refresh(n)" for each node \c n.
+    ///
+    ///It runs in time <em>O(m</em>log<em>D)</em>, where <em>m</em> is
+    ///the number of the edges of \c n and <em>D</em> is the maximum
+    ///out-degree of the graph.
+
+    void refresh() 
+    {
+      for(NodeIt n(_g);n!=INVALID;++n) refresh(n);
+    }
+    
+    ///Find an edge between two nodes.
+    
+    ///Find an edge between two nodes in time <em>O(</em>log<em>d)</em>, where
+    /// <em>d</em> is the number of outgoing edges of \c s.
+    ///\param s The source node
+    ///\param t The target node
+    ///\return An edge from \c s to \c t if there exists,
+    ///\ref INVALID otherwise.
+    ///
+    ///\warning If you change the graph, refresh() must be called before using
+    ///this operator. If you change the outgoing edges of
+    ///a single node \c n, then
+    ///\ref refresh(Node) "refresh(n)" is enough.
+    ///
+    Edge operator()(Node s, Node t) const
+    {
+      Edge e;
+      for(e=_head[s];
+	  e!=INVALID&&_g.target(e)!=t;
+	  e = t < _g.target(e)?_left[e]:_right[e]) ;
+      return e;
+    }
+
+  };
+
+  ///Fast look up of all edges between given endpoints.
+  
+  ///\ingroup gutils
+  ///This class is the same as \ref EdgeLookUp, with the addition
+  ///that it makes it possible to find all edges between given endpoints.
+  ///
+  ///\warning This class is static, so you should refresh() (or at least
+  ///refresh(Node)) this data structure
+  ///whenever the graph changes. This is a time consuming (superlinearly
+  ///proportional (<em>O(m</em>log<em>m)</em>) to the number of edges).
+  ///
+  ///\param G The type of the underlying graph.
+  ///
+  ///\sa DynEdgeLookUp
+  ///\sa EdgeLookUp  
+  template<class G>
+  class AllEdgeLookUp : public EdgeLookUp<G>
+  {
+    using EdgeLookUp<G>::_g;
+    using EdgeLookUp<G>::_right;
+    using EdgeLookUp<G>::_left;
+    using EdgeLookUp<G>::_head;
+
+    GRAPH_TYPEDEFS(typename G);
+    typedef G Graph;
+    
+    typename Graph::template EdgeMap<Edge> _next;
+    
+    Edge refreshNext(Edge head,Edge next=INVALID)
+    {
+      if(head==INVALID) return next;
+      else {
+	next=refreshNext(_right[head],next);
+// 	_next[head]=next;
+	_next[head]=( next!=INVALID && _g.target(next)==_g.target(head))
+	  ? next : INVALID;
+	return refreshNext(_left[head],head);
+      }
+    }
+    
+    void refreshNext()
+    {
+      for(NodeIt n(_g);n!=INVALID;++n) refreshNext(_head[n]);
+    }
+    
+  public:
+    ///Constructor
+
+    ///Constructor.
+    ///
+    ///It builds up the search database, which remains valid until the graph
+    ///changes.
+    AllEdgeLookUp(const Graph &g) : EdgeLookUp<G>(g), _next(g) {refreshNext();}
+
+    ///Refresh the data structure at a node.
+
+    ///Build up the search database of node \c n.
+    ///
+    ///It runs in time <em>O(d</em>log<em>d)</em>, where <em>d</em> is
+    ///the number of the outgoing edges of \c n.
+    
+    void refresh(Node n) 
+    {
+      EdgeLookUp<G>::refresh(n);
+      refreshNext(_head[n]);
+    }
+    
+    ///Refresh the full data structure.
+
+    ///Build up the full search database. In fact, it simply calls
+    ///\ref refresh(Node) "refresh(n)" for each node \c n.
+    ///
+    ///It runs in time <em>O(m</em>log<em>D)</em>, where <em>m</em> is
+    ///the number of the edges of \c n and <em>D</em> is the maximum
+    ///out-degree of the graph.
+
+    void refresh() 
+    {
+      for(NodeIt n(_g);n!=INVALID;++n) refresh(_head[n]);
+    }
+    
+    ///Find an edge between two nodes.
+    
+    ///Find an edge between two nodes.
+    ///\param s The source node
+    ///\param t The target node
+    ///\param prev The previous edge between \c s and \c t. It it is INVALID or
+    ///not given, the operator finds the first appropriate edge.
+    ///\return An edge from \c s to \c t after \c prev or
+    ///\ref INVALID if there is no more.
+    ///
+    ///For example, you can count the number of edges from \c u to \c v in the
+    ///following way.
+    ///\code
+    ///AllEdgeLookUp<ListGraph> ae(g);
+    ///...
+    ///int n=0;
+    ///for(Edge e=ae(u,v);e!=INVALID;e=ae(u,v,e)) n++;
+    ///\endcode
+    ///
+    ///Finding the first edge take <em>O(</em>log<em>d)</em> time, where
+    /// <em>d</em> is the number of outgoing edges of \c s. Then, the
+    ///consecutive edges are found in constant time.
+    ///
+    ///\warning If you change the graph, refresh() must be called before using
+    ///this operator. If you change the outgoing edges of
+    ///a single node \c n, then
+    ///\ref refresh(Node) "refresh(n)" is enough.
+    ///
+#ifdef DOXYGEN
+    Edge operator()(Node s, Node t, Edge prev=INVALID) const {}
+#else
+    using EdgeLookUp<G>::operator() ;
+    Edge operator()(Node s, Node t, Edge prev) const
+    {
+      return prev==INVALID?(*this)(s,t):_next[prev];
+    }
+#endif
+      
+  };
+
+  /// @}
+
+} //END OF NAMESPACE LEMON
+
+#endif
Index: lemon/graph_writer.h
===================================================================
--- lemon/graph_writer.h	(revision 2553)
+++ lemon/graph_writer.h	(revision 2553)
@@ -0,0 +1,1016 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup lemon_io
+///\file
+///\brief Lemon Graph Format writer.
+///
+
+#ifndef LEMON_GRAPH_WRITER_H
+#define LEMON_GRAPH_WRITER_H
+
+#include <iostream>
+
+#include <lemon/error.h>
+#include <lemon/lemon_writer.h>
+
+namespace lemon {
+
+  /// \addtogroup lemon_io
+  /// @{
+
+  /// \brief The graph writer class.
+  ///
+  /// The \c GraphWriter class provides the graph output.  Before you
+  /// read this documentation it might be useful to read the general
+  /// description of \ref graph-io-page "Graph Input-Output".
+  ///
+  /// To write a graph you should first give writing commands to the
+  /// writer. You can declare write commands as \c NodeMap or \c
+  /// EdgeMap writing and labeled Node and Edge writing.
+  ///
+  ///\code
+  /// GraphWriter<ListGraph> writer(std::cout, graph);
+  ///\endcode
+  ///
+  /// The \c writeNodeMap() function declares a \c NodeMap writing
+  /// command in the \c GraphWriter. You should give as parameter the
+  /// name of the map and the map object. The NodeMap writing command
+  /// with name "label" should write a unique map because it is
+  /// regarded as label map (such a map is essential if the graph has
+  /// edges).
+  ///
+  ///\code
+  /// IdMap<ListGraph, Node> nodeLabelMap;
+  /// writer.writeNodeMap("label", nodeLabelMap);
+  ///
+  /// writer.writeNodeMap("coords", coords);
+  /// writer.writeNodeMap("color", colorMap);
+  ///\endcode
+  ///
+  /// With the \c writeEdgeMap() member function you can give an edge map
+  /// writing command similar to the NodeMaps.
+  ///
+  ///\code
+  /// DescriptorMap<ListGraph, Edge, ListGraph::EdgeMap<int> > 
+  ///   edgeDescMap(graph);
+  /// writer.writeEdgeMap("descriptor", edgeDescMap);
+  ///
+  /// writer.writeEdgeMap("weight", weightMap);
+  /// writer.writeEdgeMap("label", labelMap);
+  ///\endcode
+  ///
+  /// With \c writeNode() and \c writeEdge() functions you can 
+  /// point out Nodes and Edges in the graph. For example, you can 
+  /// write out the source and target of a maximum flow instance.
+  ///
+  ///\code
+  /// writer.writeNode("source", sourceNode);
+  /// writer.writeNode("target", targetNode);
+  ///
+  /// writer.writeEdge("observed", edge);
+  ///\endcode
+  ///
+  /// After you give all write commands you must call the \c run() member
+  /// function, which executes all the writing commands.
+  ///
+  ///\code
+  /// writer.run();
+  ///\endcode
+  ///
+  /// \see DefaultWriterTraits
+  /// \see QuotedStringWriter
+  /// \see IdMap
+  /// \see DescriptorMap
+  /// \see \ref GraphReader
+  /// \see \ref graph-io-page
+  /// \author Balazs Dezso
+  template <typename _Graph, typename _WriterTraits = DefaultWriterTraits> 
+  class GraphWriter {
+  public:
+    
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+
+    typedef _WriterTraits WriterTraits;
+
+    /// \brief Construct a new GraphWriter.
+    ///
+    /// This function constructs a new GraphWriter to write the given graph
+    /// to the given stream.
+    GraphWriter(std::ostream& _os, const Graph& _graph) 
+      : writer(new LemonWriter(_os)), own_writer(true), 
+	nodeset_writer(*writer, _graph, std::string()),
+	edgeset_writer(*writer, _graph, nodeset_writer, std::string()),
+	node_writer(*writer, nodeset_writer, std::string()),
+	edge_writer(*writer, edgeset_writer, std::string()),
+	attribute_writer(*writer, std::string()) {}
+
+    /// \brief Construct a new GraphWriter.
+    ///
+    /// This function constructs a new GraphWriter to write the given graph
+    /// to the given file.
+    GraphWriter(const std::string& _filename, const Graph& _graph) 
+      : writer(new LemonWriter(_filename)), own_writer(true), 
+	nodeset_writer(*writer, _graph, std::string()),
+	edgeset_writer(*writer, _graph, nodeset_writer, std::string()),
+	node_writer(*writer, nodeset_writer, std::string()),
+	edge_writer(*writer, edgeset_writer, std::string()),
+	attribute_writer(*writer, std::string()) {}
+
+    /// \brief Construct a new GraphWriter.
+    ///
+    /// This function constructs a new GraphWriter to write the given graph
+    /// to the given LemonReader.
+    GraphWriter(LemonWriter& _writer, const Graph& _graph)
+      : writer(_writer), own_writer(false), 
+	nodeset_writer(*writer, _graph, std::string()),
+	edgeset_writer(*writer, _graph, nodeset_writer, std::string()),
+	node_writer(*writer, nodeset_writer, std::string()),
+	edge_writer(*writer, edgeset_writer, std::string()),
+	attribute_writer(*writer, std::string()) {}
+
+    /// \brief Destruct the graph writer.
+    ///
+    /// This function destructs the graph writer.
+    ~GraphWriter() {
+      if (own_writer) 
+	delete writer;
+    }
+
+    /// \brief Issue a new node map writing command for the writer.
+    ///
+    /// This function issues a new <i> node map writing command</i> to the writer.
+    template <typename Map>
+    GraphWriter& writeNodeMap(std::string label, const Map& map) {
+      nodeset_writer.writeNodeMap(label, map);
+      return *this;
+    }
+
+
+    /// \brief Issue a new node map writing command for the writer.
+    ///
+    /// This function issues a new <i> node map writing command</i> to the writer.
+    template <typename ItemWriter, typename Map>
+    GraphWriter& writeNodeMap(std::string label, const Map& map, 
+			      const ItemWriter& iw = ItemWriter()) {
+      nodeset_writer.writeNodeMap(label, map, iw);
+      return *this;
+    }
+
+
+    /// \brief Issue a new edge map writing command for the writer.
+    ///
+   /// This function issues a new <i> edge map writing command</i> to the writer.
+    template <typename Map>
+    GraphWriter& writeEdgeMap(std::string label, const Map& map) { 
+      edgeset_writer.writeEdgeMap(label, map);
+      return *this;
+    }
+
+
+    /// \brief Issue a new edge map writing command for the writer.
+    ///
+   /// This function issues a new <i> edge map writing command</i> to the writer.
+    template <typename ItemWriter, typename Map>
+    GraphWriter& writeEdgeMap(std::string label, const Map& map,
+			      const ItemWriter& iw = ItemWriter()) {
+      edgeset_writer.writeEdgeMap(label, map, iw);
+      return *this;
+    }
+
+    /// \brief Issue a new labeled node writing command to the writer.
+    ///
+    /// This function issues a new <i> labeled node writing command</i> 
+    /// to the writer.
+    GraphWriter& writeNode(std::string label, const Node& node) {
+      node_writer.writeNode(label, node);
+      return *this;
+    }
+
+    /// \brief Issue a new labeled edge writing command to the writer.
+    ///
+    /// This function issues a new <i> labeled edge writing command</i> 
+    /// to the writer.
+    GraphWriter& writeEdge(std::string label, const Edge& edge) {
+      edge_writer.writeEdge(label, edge);
+    }
+
+    /// \brief Issue a new attribute writing command.
+    ///
+    /// This function issues a new <i> attribute writing command</i> 
+    /// to the writer.
+    template <typename Value>
+    GraphWriter& writeAttribute(std::string label, const Value& value) {
+      attribute_writer.writeAttribute(label, value);
+      return *this;
+    }
+    
+    /// \brief Issue a new attribute writing command.
+    ///
+    /// This function issues a new <i> attribute writing command</i> 
+    /// to the writer.
+    template <typename ItemWriter, typename Value>
+    GraphWriter& writeAttribute(std::string label, const Value& value, 
+			       const ItemWriter& iw = ItemWriter()) {
+      attribute_writer.writeAttribute(label, value, iw);
+      return *this;
+    }
+
+    /// \brief Conversion operator to LemonWriter.
+    ///
+    /// Conversion operator to LemonWriter. It makes possible
+    /// to access the encapsulated \e LemonWriter, this way
+    /// you can attach to this writer new instances of 
+    /// \e LemonWriter::SectionWriter. For more details see
+    /// the \ref rwbackground "Background of Reading and Writing".
+    operator LemonWriter&() {
+      return *writer;
+    }
+
+    /// \brief Executes the writing commands.
+    ///
+    /// Executes the writing commands.
+    void run() {
+      writer->run();
+    }
+
+    /// \brief Returns true if the writer can give back the labels by the items.
+    ///
+    /// Returns true if the writer can give back the the labels by the items.
+    bool isLabelWriter() const {
+      return nodeset_writer.isLabelWriter() && 
+        edgeset_writer.isLabelWriter();
+    }
+
+    /// \brief Write the label of the given node.
+    ///
+    /// It writes the label of the given node. If there was written a "label"
+    /// named node map then it will write the map value belonging to the node.
+    void writeLabel(std::ostream& os, const Node& item) const {
+      nodeset_writer.writeLabel(os, item);
+    } 
+
+    /// \brief Write the label of the given edge.
+    ///
+    /// It writes the label of the given edge. If there was written a "label"
+    /// named edge map then it will write the map value belonging to the edge.
+    void writeLabel(std::ostream& os, const Edge& item) const {
+      edgeset_writer.writeLabel(os, item);
+    } 
+
+    /// \brief Sorts the given node vector by label.
+    ///
+    /// Sorts the given node vector by label. If there was written an
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Node>& nodes) const {
+      nodeset_writer.sortByLabel(nodes);
+    }
+
+    /// \brief Sorts the given edge vector by label.
+    ///
+    /// Sorts the given edge vector by label. If there was written an
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Edge>& edges) const {
+      edgeset_writer.sortByLabel(edges);
+    }
+
+  private:
+
+    LemonWriter* writer;
+    bool own_writer;
+
+    NodeSetWriter<Graph, WriterTraits> nodeset_writer;
+    EdgeSetWriter<Graph, WriterTraits> edgeset_writer;
+
+    NodeWriter<Graph> node_writer;
+    EdgeWriter<Graph> edge_writer;
+    
+    AttributeWriter<WriterTraits> attribute_writer;
+  };
+
+
+  /// \brief The undirected graph writer class.
+  ///
+  /// The \c UGraphWriter class provides the ugraph output. To write 
+  /// a graph you should first give writing commands to the writer. You can 
+  /// declare write command as \c NodeMap, \c EdgeMap or \c UEdgeMap 
+  /// writing and labeled Node, Edge or UEdge writing.
+  ///
+  ///\code
+  /// UGraphWriter<ListUGraph> writer(std::cout, graph);
+  ///\endcode
+  ///
+  /// The \c writeNodeMap() function declares a \c NodeMap writing 
+  /// command in the \c UGraphWriter. You should give as parameter 
+  /// the name of the map and the map object. The NodeMap writing 
+  /// command with name "label" should write a unique map because it 
+  /// is regarded as label map.
+  ///
+  ///\code
+  /// IdMap<ListUGraph, Node> nodeLabelMap;
+  /// writer.writeNodeMap("label", nodeLabelMap);
+  ///
+  /// writer.writeNodeMap("coords", coords);
+  /// writer.writeNodeMap("color", colorMap);
+  ///\endcode
+  ///
+  /// With the \c writeUEdgeMap() member function you can give an 
+  /// undirected edge map writing command similar to the NodeMaps.
+  ///
+  ///\code
+  /// DescriptorMap<ListGraph, Edge, ListGraph::EdgeMap<int> > 
+  ///   edgeDescMap(graph);
+  /// writer.writeUEdgeMap("descriptor", edgeDescMap);
+  ///
+  /// writer.writeUEdgeMap("weight", weightMap);
+  /// writer.writeUEdgeMap("label", labelMap);
+  ///\endcode
+  /// 
+  /// The EdgeMap handling is just a syntactical sugar. It writes
+  /// two undirected edge map with '+' and '-' prefix in the name.
+  ///
+  ///\code
+  /// writer.writeEdgeMap("capacity", capacityMap);
+  ///\endcode
+  ///
+  ///
+  /// With \c writeNode() and \c writeUEdge() functions you can 
+  /// designate nodes and undirected edges in the graph. For example, you can 
+  /// write out the source and target of the graph.
+  ///
+  ///\code
+  /// writer.writeNode("source", sourceNode);
+  /// writer.writeNode("target", targetNode);
+  ///
+  /// writer.writeUEdge("observed", uEdge);
+  ///\endcode
+  ///
+  /// After you give all write commands you must call the \c run() member
+  /// function, which executes all the writing commands.
+  ///
+  ///\code
+  /// writer.run();
+  ///\endcode
+  ///
+  /// \see DefaultWriterTraits
+  /// \see QuotedStringWriter
+  /// \see IdMap
+  /// \see DescriptorMap
+  /// \see \ref GraphWriter
+  /// \see \ref graph-io-page
+  /// \author Balazs Dezso
+  template <typename _Graph, typename _WriterTraits = DefaultWriterTraits> 
+  class UGraphWriter {
+  public:
+    
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+
+    typedef _WriterTraits WriterTraits;
+
+    /// \brief Construct a new UGraphWriter.
+    ///
+    /// Construct a new UGraphWriter. It writes the given graph
+    /// to the given stream.
+    UGraphWriter(std::ostream& _os, const Graph& _graph) 
+      : writer(new LemonWriter(_os)), own_writer(true), 
+	nodeset_writer(*writer, _graph, std::string()),
+	uedgeset_writer(*writer, _graph, nodeset_writer, std::string()),
+	node_writer(*writer, nodeset_writer, std::string()),
+	uedge_writer(*writer, uedgeset_writer, std::string()),
+	attribute_writer(*writer, std::string()) {}
+
+    /// \brief Construct a new UGraphWriter.
+    ///
+    /// Construct a new UGraphWriter. It writes the given graph
+    /// to the given file.
+    UGraphWriter(const std::string& _filename, const Graph& _graph) 
+      : writer(new LemonWriter(_filename)), own_writer(true), 
+	nodeset_writer(*writer, _graph, std::string()),
+	uedgeset_writer(*writer, _graph, nodeset_writer, std::string()),
+	node_writer(*writer, nodeset_writer, std::string()),
+	uedge_writer(*writer, uedgeset_writer, std::string()),
+	attribute_writer(*writer, std::string()) {}
+
+    /// \brief Construct a new UGraphWriter.
+    ///
+    /// Construct a new UGraphWriter. It writes the given graph
+    /// to given LemonWriter.
+    UGraphWriter(LemonWriter& _writer, const Graph& _graph)
+      : writer(_writer), own_writer(false), 
+	nodeset_writer(*writer, _graph, std::string()),
+	uedgeset_writer(*writer, _graph, nodeset_writer, std::string()),
+	node_writer(*writer, nodeset_writer, std::string()),
+	uedge_writer(*writer, uedgeset_writer, std::string()),
+	attribute_writer(*writer, std::string()) {}
+
+    /// \brief Destruct the graph writer.
+    ///
+    /// Destruct the graph writer.
+    ~UGraphWriter() {
+      if (own_writer) 
+	delete writer;
+    }
+
+    /// \brief Issue a new node map writing command to the writer.
+    ///
+    /// This function issues a new <i> node map writing command</i> to
+    /// the writer.
+    template <typename Map>
+    UGraphWriter& writeNodeMap(std::string label, const Map& map) {
+      nodeset_writer.writeNodeMap(label, map);
+      return *this;
+    }
+
+    /// \brief Issue a new node map writing command to the writer.
+    ///
+    /// This function issues a new <i> node map writing command</i> to
+    /// the writer.
+    template <typename ItemWriter, typename Map>
+    UGraphWriter& writeNodeMap(std::string label, const Map& map, 
+			      const ItemWriter& iw = ItemWriter()) {
+      nodeset_writer.writeNodeMap(label, map, iw);
+      return *this;
+    }
+
+    /// \brief Issue a new edge map writing command to the writer.
+    ///
+    /// This function issues a new <i> edge map writing command</i> to
+    /// the writer.
+    template <typename Map>
+    UGraphWriter& writeEdgeMap(std::string label, const Map& map) { 
+      uedgeset_writer.writeEdgeMap(label, map);
+      return *this;
+    }
+
+    /// \brief Issue a new edge map writing command to the writer.
+    ///
+    /// This function issues a new <i> edge map writing command</i> to
+    /// the writer.
+    template <typename ItemWriter, typename Map>
+    UGraphWriter& writeEdgeMap(std::string label, const Map& map,
+				   const ItemWriter& iw = ItemWriter()) {
+      uedgeset_writer.writeEdgeMap(label, map, iw);
+      return *this;
+    }
+
+    /// \brief Issue a new undirected edge map writing command to the writer.
+    ///
+    /// This function issues a new <i> undirected edge map writing
+    /// command</i> to the writer.
+    template <typename Map>
+    UGraphWriter& writeUEdgeMap(std::string label, const Map& map) { 
+      uedgeset_writer.writeUEdgeMap(label, map);
+      return *this;
+    }
+
+    /// \brief Issue a new undirected edge map writing command to the writer.
+    ///
+    /// This function issues a new <i> undirected edge map writing
+    /// command</i> to the writer.
+   template <typename ItemWriter, typename Map>
+    UGraphWriter& writeUEdgeMap(std::string label, const Map& map,
+					const ItemWriter& iw = ItemWriter()) {
+      uedgeset_writer.writeUEdgeMap(label, map, iw);
+      return *this;
+    }
+
+    /// \brief Issue a new labeled node writer to the writer.
+    ///
+    /// This function issues a new <i> labeled node writing
+    /// command</i> to the writer.
+    UGraphWriter& writeNode(std::string label, const Node& node) {
+      node_writer.writeNode(label, node);
+      return *this;
+    }
+
+    /// \brief Issue a new labeled edge writer to the writer.
+    ///
+    /// This function issues a new <i> labeled edge writing
+    /// command</i> to the writer.
+    UGraphWriter& writeEdge(std::string label, const Edge& edge) {
+      uedge_writer.writeEdge(label, edge);
+    }
+
+    /// \brief Issue a new labeled undirected edge writing command to
+    /// the writer.
+    ///
+    /// Issue a new <i>labeled undirected edge writing command</i> to
+    /// the writer.
+    UGraphWriter& writeUEdge(std::string label, const UEdge& edge) {
+      uedge_writer.writeUEdge(label, edge);
+    }
+
+    /// \brief Issue a new attribute writing command.
+    ///
+    /// This function issues a new <i> attribute writing
+    /// command</i> to the writer.
+    template <typename Value>
+    UGraphWriter& writeAttribute(std::string label, const Value& value) {
+      attribute_writer.writeAttribute(label, value);
+      return *this;
+    }
+    
+    /// \brief Issue a new attribute writing command.
+    ///
+    /// This function issues a new <i> attribute writing
+    /// command</i> to the writer.
+    template <typename ItemWriter, typename Value>
+    UGraphWriter& writeAttribute(std::string label, const Value& value, 
+			       const ItemWriter& iw = ItemWriter()) {
+      attribute_writer.writeAttribute(label, value, iw);
+      return *this;
+    }
+
+    /// \brief Conversion operator to LemonWriter.
+    ///
+    /// Conversion operator to LemonWriter. It makes possible
+    /// to access the encapsulated \e LemonWriter, this way
+    /// you can attach to this writer new instances of 
+    /// \e LemonWriter::SectionWriter.
+    operator LemonWriter&() {
+      return *writer;
+    }
+
+    /// \brief Executes the writing commands.
+    ///
+    /// Executes the writing commands.
+    void run() {
+      writer->run();
+    }
+
+    /// \brief Returns true if the writer can give back the labels by the items.
+    ///
+    /// Returns true if the writer can give back the the labels by the items.
+    bool isLabelWriter() const {
+      return nodeset_writer.isLabelWriter() && 
+        uedgeset_writer.isLabelWriter();
+    }
+
+    /// \brief Write the label of the given node.
+    ///
+    /// It writes the label of the given node. If there was written a "label"
+    /// named node map then it will write the map value belonging to the node.
+    void writeLabel(std::ostream& os, const Node& item) const {
+      nodeset_writer.writeLabel(os, item);
+    } 
+
+    /// \brief Write the label of the given edge.
+    ///
+    /// It writes the label of the given edge. If there was written a "label"
+    /// named edge map then it will write the map value belonging to the edge.
+    void writeLabel(std::ostream& os, const Edge& item) const {
+      uedgeset_writer.writeLabel(os, item);
+    } 
+
+    /// \brief Write the label of the given undirected edge.
+    ///
+    /// It writes the label of the given undirected edge. If there was
+    /// written a "label" named edge map then it will write the map
+    /// value belonging to the edge.
+    void writeLabel(std::ostream& os, const UEdge& item) const {
+      uedgeset_writer.writeLabel(os, item);
+    } 
+
+    /// \brief Sorts the given node vector by label.
+    ///
+    /// Sorts the given node vector by label. If there was written an
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Node>& nodes) const {
+      nodeset_writer.sortByLabel(nodes);
+    }
+
+    /// \brief Sorts the given edge vector by label.
+    ///
+    /// Sorts the given edge vector by label. If there was written an
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Edge>& edges) const {
+      uedgeset_writer.sortByLabel(edges);
+    }
+
+    /// \brief Sorts the given undirected edge vector by label.
+    ///
+    /// Sorts the given undirected edge vector by label. If there was
+    /// written an "label" named map then the vector will be sorted by
+    /// the values of this map. Otherwise if the \c forceLabel
+    /// parameter was true it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<UEdge>& uedges) const {
+      uedgeset_writer.sortByLabel(uedges);
+    }
+
+  private:
+
+    LemonWriter* writer;
+    bool own_writer;
+
+    NodeSetWriter<Graph, WriterTraits> nodeset_writer;
+    UEdgeSetWriter<Graph, WriterTraits> uedgeset_writer;
+
+    NodeWriter<Graph> node_writer;
+    UEdgeWriter<Graph> uedge_writer;
+    
+    AttributeWriter<WriterTraits> attribute_writer;
+  };
+
+  /// \brief The bipartite graph writer class.
+  ///
+  /// The \c BpUGraphWriter class provides the ugraph output. To write 
+  /// a graph you should first give writing commands to the writer. You can 
+  /// declare write command as \c NodeMap, \c EdgeMap or \c UEdgeMap 
+  /// writing and labeled Node, Edge or UEdge writing.
+  ///
+  ///\code
+  /// BpUGraphWriter<ListUGraph> writer(std::cout, graph);
+  ///\endcode
+  ///
+  /// The \c writeNodeMap() function declares a \c NodeMap writing 
+  /// command in the \c BpUGraphWriter. You should give as parameter 
+  /// the name of the map and the map object. The NodeMap writing 
+  /// command with name "label" should write a unique map because it 
+  /// is regarded as label map.
+  ///
+  ///\code
+  /// IdMap<ListUGraph, Node> nodeLabelMap;
+  /// writer.writeNodeMap("label", nodeLabelMap);
+  ///
+  /// writer.writeNodeMap("coords", coords);
+  /// writer.writeNodeMap("color", colorMap);
+  ///\endcode
+  ///
+  /// With the \c writeUEdgeMap() member function you can give an 
+  /// undirected edge map writing command similar to the NodeMaps.
+  ///
+  ///\code
+  /// DescriptorMap<ListGraph, Edge, ListGraph::EdgeMap<int> > 
+  ///   edgeDescMap(graph);
+  /// writer.writeUEdgeMap("descriptor", edgeDescMap);
+  ///
+  /// writer.writeUEdgeMap("weight", weightMap);
+  /// writer.writeUEdgeMap("label", labelMap);
+  ///\endcode
+  /// 
+  /// The EdgeMap handling is just a syntactical sugar. It writes
+  /// two undirected edge map with '+' and '-' prefix in the name.
+  ///
+  ///\code
+  /// writer.writeEdgeMap("capacity", capacityMap);
+  ///\endcode
+  ///
+  ///
+  /// With \c writeNode() and \c writeUEdge() functions you can 
+  /// designate nodes and undirected edges in the graph. For example, you can 
+  /// write out the source and target of the graph.
+  ///
+  ///\code
+  /// writer.writeNode("source", sourceNode);
+  /// writer.writeNode("target", targetNode);
+  ///
+  /// writer.writeUEdge("observed", uEdge);
+  ///\endcode
+  ///
+  /// After you give all write commands you must call the \c run() member
+  /// function, which executes all the writing commands.
+  ///
+  ///\code
+  /// writer.run();
+  ///\endcode
+  ///
+  /// \see DefaultWriterTraits
+  /// \see QuotedStringWriter
+  /// \see IdMap
+  /// \see DescriptorMap
+  /// \see \ref GraphWriter
+  /// \see \ref graph-io-page
+  /// \author Balazs Dezso
+  template <typename _Graph, typename _WriterTraits = DefaultWriterTraits> 
+  class BpUGraphWriter {
+  public:
+    
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+
+    typedef _WriterTraits WriterTraits;
+
+    /// \brief Construct a new BpUGraphWriter.
+    ///
+    /// Construct a new BpUGraphWriter. It writes the given graph
+    /// to the given stream.
+    BpUGraphWriter(std::ostream& _os, const Graph& _graph) 
+      : writer(new LemonWriter(_os)), own_writer(true), 
+	nodeset_writer(*writer, _graph, std::string()),
+	uedgeset_writer(*writer, _graph, nodeset_writer, std::string()),
+	node_writer(*writer, nodeset_writer, std::string()),
+	uedge_writer(*writer, uedgeset_writer, std::string()),
+	attribute_writer(*writer, std::string()) {}
+
+    /// \brief Construct a new BpUGraphWriter.
+    ///
+    /// Construct a new BpUGraphWriter. It writes the given graph
+    /// to the given file.
+    BpUGraphWriter(const std::string& _filename, const Graph& _graph) 
+      : writer(new LemonWriter(_filename)), own_writer(true), 
+	nodeset_writer(*writer, _graph, std::string()),
+	uedgeset_writer(*writer, _graph, nodeset_writer, std::string()),
+	node_writer(*writer, nodeset_writer, std::string()),
+	uedge_writer(*writer, uedgeset_writer, std::string()),
+	attribute_writer(*writer, std::string()) {}
+
+    /// \brief Construct a new BpUGraphWriter.
+    ///
+    /// Construct a new BpUGraphWriter. It writes the given graph
+    /// to given LemonWriter.
+    BpUGraphWriter(LemonWriter& _writer, const Graph& _graph)
+      : writer(_writer), own_writer(false), 
+	nodeset_writer(*writer, _graph, std::string()),
+	uedgeset_writer(*writer, _graph, nodeset_writer, std::string()),
+	node_writer(*writer, nodeset_writer, std::string()),
+	uedge_writer(*writer, uedgeset_writer, std::string()),
+	attribute_writer(*writer, std::string()) {}
+
+    /// \brief Destruct the graph writer.
+    ///
+    /// Destruct the graph writer.
+    ~BpUGraphWriter() {
+      if (own_writer) 
+	delete writer;
+    }
+
+    /// \brief Issue a new node map writing command to the writer.
+    ///
+    /// This function issues a new <i> node map writing command</i> to
+    /// the writer.
+    template <typename Map>
+    BpUGraphWriter& writeNodeMap(std::string label, const Map& map) {
+      nodeset_writer.writeNodeMap(label, map);
+      return *this;
+    }
+
+    /// \brief Issue a new node map writing command to the writer.
+    ///
+    /// This function issues a new <i> node map writing command</i> to
+    /// the writer.
+    template <typename ItemWriter, typename Map>
+    BpUGraphWriter& writeNodeMap(std::string label, const Map& map, 
+			      const ItemWriter& iw = ItemWriter()) {
+      nodeset_writer.writeNodeMap(label, map, iw);
+      return *this;
+    }
+
+    /// \brief Issue a new A-node map writing command to the writer.
+    ///
+    /// This function issues a new <i> A-node map writing command</i> to
+    /// the writer.
+    template <typename Map>
+    BpUGraphWriter& writeANodeMap(std::string label, const Map& map) {
+      nodeset_writer.writeANodeMap(label, map);
+      return *this;
+    }
+
+    /// \brief Issue a new A-node map writing command to the writer.
+    ///
+    /// This function issues a new <i> A-node map writing command</i> to
+    /// the writer.
+    template <typename ItemWriter, typename Map>
+    BpUGraphWriter& writeANodeMap(std::string label, const Map& map, 
+			      const ItemWriter& iw = ItemWriter()) {
+      nodeset_writer.writeANodeMap(label, map, iw);
+      return *this;
+    }
+    /// \brief Issue a new B-node map writing command to the writer.
+    ///
+    /// This function issues a new <i> B-node map writing command</i> to
+    /// the writer.
+    template <typename Map>
+    BpUGraphWriter& writeBNodeMap(std::string label, const Map& map) {
+      nodeset_writer.writeBNodeMap(label, map);
+      return *this;
+    }
+
+    /// \brief Issue a new B-node map writing command to the writer.
+    ///
+    /// This function issues a new <i> B-node map writing command</i> to
+    /// the writer.
+    template <typename ItemWriter, typename Map>
+    BpUGraphWriter& writeBNodeMap(std::string label, const Map& map, 
+			      const ItemWriter& iw = ItemWriter()) {
+      nodeset_writer.writeBNodeMap(label, map, iw);
+      return *this;
+    }
+
+    /// \brief Issue a new edge map writing command to the writer.
+    ///
+    /// This function issues a new <i> edge map writing command</i> to
+    /// the writer.
+    template <typename Map>
+    BpUGraphWriter& writeEdgeMap(std::string label, const Map& map) { 
+      uedgeset_writer.writeEdgeMap(label, map);
+      return *this;
+    }
+
+    /// \brief Issue a new edge map writing command to the writer.
+    ///
+    /// This function issues a new <i> edge map writing command</i> to
+    /// the writer.
+    template <typename ItemWriter, typename Map>
+    BpUGraphWriter& writeEdgeMap(std::string label, const Map& map,
+				   const ItemWriter& iw = ItemWriter()) {
+      uedgeset_writer.writeEdgeMap(label, map, iw);
+      return *this;
+    }
+
+    /// \brief Issue a new undirected edge map writing command to the writer.
+    ///
+    /// This function issues a new <i> undirected edge map writing
+    /// command</i> to the writer.
+    template <typename Map>
+    BpUGraphWriter& writeUEdgeMap(std::string label, const Map& map) { 
+      uedgeset_writer.writeUEdgeMap(label, map);
+      return *this;
+    }
+
+    /// \brief Issue a new undirected edge map writing command to the writer.
+    ///
+    /// This function issues a new <i> undirected edge map writing
+    /// command</i> to the writer.
+   template <typename ItemWriter, typename Map>
+    BpUGraphWriter& writeUEdgeMap(std::string label, const Map& map,
+					const ItemWriter& iw = ItemWriter()) {
+      uedgeset_writer.writeUEdgeMap(label, map, iw);
+      return *this;
+    }
+
+    /// \brief Issue a new labeled node writer to the writer.
+    ///
+    /// This function issues a new <i> labeled node writing
+    /// command</i> to the writer.
+    BpUGraphWriter& writeNode(std::string label, const Node& node) {
+      node_writer.writeNode(label, node);
+      return *this;
+    }
+
+    /// \brief Issue a new labeled edge writer to the writer.
+    ///
+    /// This function issues a new <i> labeled edge writing
+    /// command</i> to the writer.
+    BpUGraphWriter& writeEdge(std::string label, const Edge& edge) {
+      uedge_writer.writeEdge(label, edge);
+    }
+
+    /// \brief Issue a new labeled undirected edge writing command to
+    /// the writer.
+    ///
+    /// Issue a new <i>labeled undirected edge writing command</i> to
+    /// the writer.
+    BpUGraphWriter& writeUEdge(std::string label, const UEdge& edge) {
+      uedge_writer.writeUEdge(label, edge);
+    }
+
+    /// \brief Issue a new attribute writing command.
+    ///
+    /// This function issues a new <i> attribute writing
+    /// command</i> to the writer.
+    template <typename Value>
+    BpUGraphWriter& writeAttribute(std::string label, const Value& value) {
+      attribute_writer.writeAttribute(label, value);
+      return *this;
+    }
+    
+    /// \brief Issue a new attribute writing command.
+    ///
+    /// This function issues a new <i> attribute writing
+    /// command</i> to the writer.
+    template <typename ItemWriter, typename Value>
+    BpUGraphWriter& writeAttribute(std::string label, const Value& value, 
+			       const ItemWriter& iw = ItemWriter()) {
+      attribute_writer.writeAttribute(label, value, iw);
+      return *this;
+    }
+
+    /// \brief Conversion operator to LemonWriter.
+    ///
+    /// Conversion operator to LemonWriter. It makes possible
+    /// to access the encapsulated \e LemonWriter, this way
+    /// you can attach to this writer new instances of 
+    /// \e LemonWriter::SectionWriter.
+    operator LemonWriter&() {
+      return *writer;
+    }
+
+    /// \brief Executes the writing commands.
+    ///
+    /// Executes the writing commands.
+    void run() {
+      writer->run();
+    }
+
+    /// \brief Returns true if the writer can give back the labels by the items.
+    ///
+    /// Returns true if the writer can give back the the labels by the items.
+    bool isLabelWriter() const {
+      return nodeset_writer.isLabelWriter() && 
+        uedgeset_writer.isLabelWriter();
+    }
+
+    /// \brief Write the label of the given node.
+    ///
+    /// It writes the label of the given node. If there was written a "label"
+    /// named node map then it will write the map value belonging to the node.
+    void writeLabel(std::ostream& os, const Node& item) const {
+      nodeset_writer.writeLabel(os, item);
+    } 
+
+    /// \brief Write the label of the given edge.
+    ///
+    /// It writes the label of the given edge. If there was written a "label"
+    /// named edge map then it will write the map value belonging to the edge.
+    void writeLabel(std::ostream& os, const Edge& item) const {
+      uedgeset_writer.writeLabel(os, item);
+    } 
+
+    /// \brief Write the label of the given undirected edge.
+    ///
+    /// It writes the label of the given undirected edge. If there was
+    /// written a "label" named edge map then it will write the map
+    /// value belonging to the edge.
+    void writeLabel(std::ostream& os, const UEdge& item) const {
+      uedgeset_writer.writeLabel(os, item);
+    } 
+
+    /// \brief Sorts the given node vector by label.
+    ///
+    /// Sorts the given node vector by label. If there was written an
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Node>& nodes) const {
+      nodeset_writer.sortByLabel(nodes);
+    }
+
+    /// \brief Sorts the given edge vector by label.
+    ///
+    /// Sorts the given edge vector by label. If there was written an
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Edge>& edges) const {
+      uedgeset_writer.sortByLabel(edges);
+    }
+
+    /// \brief Sorts the given undirected edge vector by label.
+    ///
+    /// Sorts the given undirected edge vector by label. If there was
+    /// written an "label" named map then the vector will be sorted by
+    /// the values of this map. Otherwise if the \c forceLabel
+    /// parameter was true it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<UEdge>& uedges) const {
+      uedgeset_writer.sortByLabel(uedges);
+    }
+
+  private:
+
+    LemonWriter* writer;
+    bool own_writer;
+
+    BpNodeSetWriter<Graph, WriterTraits> nodeset_writer;
+    UEdgeSetWriter<Graph, WriterTraits> uedgeset_writer;
+
+    NodeWriter<Graph> node_writer;
+    UEdgeWriter<Graph> uedge_writer;
+    
+    AttributeWriter<WriterTraits> attribute_writer;
+  };
+
+  /// @}
+
+}
+
+#endif
Index: lemon/grid_ugraph.h
===================================================================
--- lemon/grid_ugraph.h	(revision 2559)
+++ lemon/grid_ugraph.h	(revision 2559)
@@ -0,0 +1,496 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef GRID_UGRAPH_H
+#define GRID_UGRAPH_H
+
+#include <iostream>
+#include <lemon/bits/invalid.h>
+#include <lemon/bits/utility.h>
+
+#include <lemon/bits/base_extender.h>
+#include <lemon/bits/graph_extender.h>
+
+#include <lemon/dim2.h>
+
+///\ingroup graphs
+///\file
+///\brief GridUGraph class.
+
+namespace lemon {
+
+  class GridUGraphBase {
+
+  public:
+
+    typedef GridUGraphBase UGraph;
+
+    class Node;
+    class Edge;
+
+  public:
+
+    GridUGraphBase() {}
+
+  protected:
+
+    void construct(int w, int h) {
+      _height = h; _width = w;
+      _nodeNum = h * w; _edgeNum = 2 * _nodeNum - w - h;
+      _edgeLimit = _nodeNum - w;
+    }
+
+    Edge _down(Node n) const {
+      if (n.id < _nodeNum - _width) {
+	return Edge(n.id);
+      } else {
+	return INVALID;
+      }
+    }
+
+    Edge _up(Node n) const {
+      if (n.id >= _width) {
+	return Edge(n.id - _width);
+      } else {
+	return INVALID;
+      }
+    }
+
+    Edge _right(Node n) const {
+      if (n.id % _width < _width - 1) {
+	return _edgeLimit + n.id % _width + (n.id / _width) * (_width - 1);
+      } else {
+	return INVALID;
+      }
+    }
+
+    Edge _left(Node n) const {
+      if (n.id % _width > 0) {
+	return _edgeLimit + n.id % _width + (n.id / _width) * (_width - 1) - 1;
+      } else {
+	return INVALID;
+      }
+    }
+
+  public:
+
+    class IndexError : public RuntimeError {
+    public:
+      virtual const char* what() const throw() {
+        return "lemon::GridUGraph::IndexError";
+      }  
+    };
+
+    
+    Node operator()(int i, int j) const {
+      LEMON_ASSERT(0 <= i && i < width() && 0 <= j  && 
+                   j < height(), IndexError());
+      return Node(i + j * _width);
+    }
+
+    int row(Node n) const {
+      return n.id / _width;
+    }
+    
+    int col(Node n) const {
+      return n.id % _width;    
+    }
+
+    int width() const {
+      return _width;
+    }
+
+    int height() const {
+      return _height;
+    }
+
+    typedef True NodeNumTag;
+    typedef True EdgeNumTag;
+
+    int nodeNum() const { return _nodeNum; }
+    int edgeNum() const { return _edgeNum; }
+
+    int maxNodeId() const { return nodeNum() - 1; }
+    int maxEdgeId() const { return edgeNum() - 1; }
+
+    Node source(Edge e) const {
+      if (e.id < _edgeLimit) {
+	return e.id;
+      } else {
+	return (e.id - _edgeLimit) % (_width - 1) +
+	  (e.id - _edgeLimit) / (_width - 1) * _width;
+      }
+    }
+
+    Node target(Edge e) const {
+      if (e.id < _edgeLimit) {
+	return e.id + _width;
+      } else {
+	return (e.id - _edgeLimit) % (_width - 1) +
+	  (e.id - _edgeLimit) / (_width - 1) * _width + 1;
+      }
+    }
+
+    static int id(Node v) { return v.id; }
+    static int id(Edge e) { return e.id; }
+
+    static Node nodeFromId(int id) { return Node(id);}
+    
+    static Edge edgeFromId(int id) { return Edge(id);}
+
+    typedef True FindEdgeTag;
+
+    Edge findEdge(Node u, Node v, Edge prev = INVALID) const {
+      if (prev != INVALID) return INVALID;
+      if (v.id - u.id == _width) return Edge(u.id);
+      if (v.id - u.id == 1 && u.id % _width < _width - 1) {
+	return Edge(u.id / _width * (_width - 1) +
+		    u.id % _width + _edgeLimit);
+      }
+      return INVALID;
+    }
+    
+      
+    class Node {
+      friend class GridUGraphBase;
+
+    protected:
+      int id;
+      Node(int _id) { id = _id;}
+    public:
+      Node() {}
+      Node (Invalid) { id = -1; }
+      bool operator==(const Node node) const {return id == node.id;}
+      bool operator!=(const Node node) const {return id != node.id;}
+      bool operator<(const Node node) const {return id < node.id;}
+    };
+    
+
+
+    class Edge {
+      friend class GridUGraphBase;
+      
+    protected:
+      int id; 
+
+      Edge(int _id) : id(_id) {}
+
+    public:
+      Edge() { }
+      Edge (Invalid) { id = -1; }
+      bool operator==(const Edge edge) const {return id == edge.id;}
+      bool operator!=(const Edge edge) const {return id != edge.id;}
+      bool operator<(const Edge edge) const {return id < edge.id;}
+    };
+
+    void first(Node& node) const {
+      node.id = nodeNum() - 1;
+    }
+
+    static void next(Node& node) {
+      --node.id;
+    }
+
+    void first(Edge& edge) const {
+      edge.id = edgeNum() - 1;
+    }
+
+    static void next(Edge& edge) {
+      --edge.id;
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      if (node.id < _nodeNum - _width) {
+	edge.id = node.id;
+      } else if (node.id % _width < _width - 1) {
+	edge.id = _edgeLimit + node.id % _width +
+	  (node.id / _width) * (_width - 1);
+      } else {
+	edge.id = -1;
+      }
+    }
+
+    void nextOut(Edge& edge) const {
+      if (edge.id >= _edgeLimit) {
+	edge.id = -1;
+      } else if (edge.id % _width < _width - 1) {
+	edge.id = _edgeLimit + edge.id % _width +
+	  (edge.id / _width) * (_width - 1);
+      } else {
+	edge.id = -1;
+      }
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      if (node.id >= _width) {
+	edge.id = node.id - _width;
+      } else if (node.id % _width > 0) {
+	edge.id = _edgeLimit + node.id % _width +
+	  (node.id / _width) * (_width - 1) - 1;
+      } else {
+	edge.id = -1;
+      }
+    }
+    
+    void nextIn(Edge& edge) const {
+      if (edge.id >= _edgeLimit) {
+	edge.id = -1;
+      } else if (edge.id % _width > 0) {
+	edge.id = _edgeLimit + edge.id % _width +
+	  (edge.id / _width + 1) * (_width - 1) - 1;
+      } else {
+	edge.id = -1;
+      }
+    }
+
+  private:
+    int _width, _height;
+    int _nodeNum, _edgeNum;
+    int _edgeLimit;
+  };
+
+
+  typedef UGraphExtender<UndirGraphExtender<GridUGraphBase> > 
+  ExtendedGridUGraphBase;
+
+  /// \ingroup graphs
+  ///
+  /// \brief Grid graph class
+  ///
+  /// This class implements a special graph type. The nodes of the
+  /// graph can be indiced by two integer \c (i,j) value where \c i
+  /// is in the \c [0,width) range and j is in the [0, height) range.
+  /// Two nodes are connected in the graph if the indices differ only
+  /// on one position and only one is the difference. 
+  ///
+  /// \image html grid_ugraph.png
+  /// \image latex grid_ugraph.eps "Grid graph" width=\textwidth
+  ///
+  /// The graph can be indiced in the following way:
+  ///\code
+  /// GridUGraph graph(w, h);
+  /// GridUGraph::NodeMap<int> val(graph); 
+  /// for (int i = 0; i < graph.width(); ++i) {
+  ///   for (int j = 0; j < graph.height(); ++j) {
+  ///     val[graph(i, j)] = i + j;
+  ///   }
+  /// }
+  ///\endcode
+  ///
+  /// The graph type is fully conform to the \ref concepts::UGraph
+  /// "Undirected Graph" concept,  and it also has an
+  ///important extra feature that
+  ///its maps are real \ref concepts::ReferenceMap "reference map"s.
+  ///
+  ///
+  /// \author Balazs Dezso
+  class GridUGraph : public ExtendedGridUGraphBase {
+  public:
+
+    typedef ExtendedGridUGraphBase Parent;
+
+    /// \brief Map to get the indices of the nodes as dim2::Point<int>.
+    ///
+    /// Map to get the indices of the nodes as dim2::Point<int>.
+    class IndexMap {
+    public:
+      /// \brief The key type of the map
+      typedef GridUGraph::Node Key;
+      /// \brief The value type of the map
+      typedef dim2::Point<int> Value;
+
+      /// \brief Constructor
+      ///
+      /// Constructor
+      IndexMap(const GridUGraph& _graph) : graph(_graph) {}
+
+      /// \brief The subscript operator
+      ///
+      /// The subscript operator.
+      Value operator[](Key key) const {
+	return dim2::Point<int>(graph.row(key), graph.col(key));
+      }
+
+    private:
+      const GridUGraph& graph;
+    };
+
+    /// \brief Map to get the row of the nodes.
+    ///
+    /// Map to get the row of the nodes.
+    class RowMap {
+    public:
+      /// \brief The key type of the map
+      typedef GridUGraph::Node Key;
+      /// \brief The value type of the map
+      typedef int Value;
+
+      /// \brief Constructor
+      ///
+      /// Constructor
+      RowMap(const GridUGraph& _graph) : graph(_graph) {}
+
+      /// \brief The subscript operator
+      ///
+      /// The subscript operator.
+      Value operator[](Key key) const {
+	return graph.row(key);
+      }
+
+    private:
+      const GridUGraph& graph;
+    };
+
+    /// \brief Map to get the column of the nodes.
+    ///
+    /// Map to get the column of the nodes.
+    class ColMap {
+    public:
+      /// \brief The key type of the map
+      typedef GridUGraph::Node Key;
+      /// \brief The value type of the map
+      typedef int Value;
+
+      /// \brief Constructor
+      ///
+      /// Constructor
+      ColMap(const GridUGraph& _graph) : graph(_graph) {}
+
+      /// \brief The subscript operator
+      ///
+      /// The subscript operator.
+      Value operator[](Key key) const {
+	return graph.col(key);
+      }
+
+    private:
+      const GridUGraph& graph;
+    };
+
+    /// \brief Constructor
+    ///
+    /// 
+    GridUGraph(int n, int m) { construct(n, m); }
+
+    /// \brief Resize the graph
+    ///
+    void resize(int n, int m) {
+      Parent::notifier(Edge()).clear();
+      Parent::notifier(UEdge()).clear();
+      Parent::notifier(Node()).clear();
+      construct(n, m);
+      Parent::notifier(Node()).build();
+      Parent::notifier(UEdge()).build();
+      Parent::notifier(Edge()).build();
+    }
+    
+    /// \brief The node on the given position.
+    /// 
+    /// Gives back the node on the given position.
+    Node operator()(int i, int j) const {
+      return Parent::operator()(i, j);
+    }
+
+    /// \brief Gives back the row index of the node.
+    ///
+    /// Gives back the row index of the node.
+    int row(Node n) const {
+      return Parent::row(n);
+    }
+    
+    /// \brief Gives back the coloumn index of the node.
+    ///
+    /// Gives back the coloumn index of the node.
+    int col(Node n) const {
+      return Parent::col(n);
+    }
+
+    /// \brief Gives back the width of the graph.
+    ///
+    /// Gives back the width of the graph.
+    int width() const {
+      return Parent::width();
+    }
+
+    /// \brief Gives back the height of the graph.
+    ///
+    /// Gives back the height of the graph.
+    int height() const {
+      return Parent::height();
+    }
+
+    /// \brief Gives back the edge goes down from the node.
+    ///
+    /// Gives back the edge goes down from the node. If there is not
+    /// outgoing edge then it gives back INVALID.
+    Edge down(Node n) const {
+      UEdge ue = _down(n);
+      return ue != INVALID ? direct(ue, true) : INVALID;
+    }
+    
+    /// \brief Gives back the edge goes up from the node.
+    ///
+    /// Gives back the edge goes up from the node. If there is not
+    /// outgoing edge then it gives back INVALID.
+    Edge up(Node n) const {
+      UEdge ue = _up(n);
+      return ue != INVALID ? direct(ue, false) : INVALID;
+    }
+
+    /// \brief Gives back the edge goes right from the node.
+    ///
+    /// Gives back the edge goes right from the node. If there is not
+    /// outgoing edge then it gives back INVALID.
+    Edge right(Node n) const {
+      UEdge ue = _right(n);
+      return ue != INVALID ? direct(ue, true) : INVALID;
+    }
+
+    /// \brief Gives back the edge goes left from the node.
+    ///
+    /// Gives back the edge goes left from the node. If there is not
+    /// outgoing edge then it gives back INVALID.
+    Edge left(Node n) const {
+      UEdge ue = _left(n);
+      return ue != INVALID ? direct(ue, false) : INVALID;
+    }
+    
+  };
+
+  /// \brief Index map of the grid graph
+  ///
+  /// Just returns an IndexMap for the grid graph.
+  inline GridUGraph::IndexMap indexMap(const GridUGraph& graph) {
+    return GridUGraph::IndexMap(graph);
+  }
+
+  /// \brief Row map of the grid graph
+  ///
+  /// Just returns a RowMap for the grid graph.
+  inline GridUGraph::RowMap rowMap(const GridUGraph& graph) {
+    return GridUGraph::RowMap(graph);
+  }
+
+  /// \brief Column map of the grid graph
+  ///
+  /// Just returns a ColMap for the grid graph.
+  inline GridUGraph::ColMap colMap(const GridUGraph& graph) {
+    return GridUGraph::ColMap(graph);
+  }
+}
+#endif
Index: lemon/hao_orlin.h
===================================================================
--- lemon/hao_orlin.h	(revision 2624)
+++ lemon/hao_orlin.h	(revision 2624)
@@ -0,0 +1,987 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_HAO_ORLIN_H
+#define LEMON_HAO_ORLIN_H
+
+#include <vector>
+#include <list>
+#include <limits>
+
+#include <lemon/maps.h>
+#include <lemon/graph_utils.h>
+#include <lemon/tolerance.h>
+
+/// \file
+/// \ingroup min_cut
+/// \brief Implementation of the Hao-Orlin algorithm.
+///
+/// Implementation of the Hao-Orlin algorithm class for testing network 
+/// reliability.
+
+namespace lemon {
+
+  /// \ingroup min_cut
+  ///
+  /// \brief %Hao-Orlin algorithm to find a minimum cut in directed graphs.
+  ///
+  /// Hao-Orlin calculates a minimum cut in a directed graph
+  /// \f$D=(V,A)\f$. It takes a fixed node \f$ source \in V \f$ and
+  /// consists of two phases: in the first phase it determines a
+  /// minimum cut with \f$ source \f$ on the source-side (i.e. a set
+  /// \f$ X\subsetneq V \f$ with \f$ source \in X \f$ and minimal
+  /// out-degree) and in the second phase it determines a minimum cut
+  /// with \f$ source \f$ on the sink-side (i.e. a set 
+  /// \f$ X\subsetneq V \f$ with \f$ source \notin X \f$ and minimal
+  /// out-degree). Obviously, the smaller of these two cuts will be a
+  /// minimum cut of \f$ D \f$. The algorithm is a modified
+  /// push-relabel preflow algorithm and our implementation calculates
+  /// the minimum cut in \f$ O(n^2\sqrt{m}) \f$ time (we use the
+  /// highest-label rule), or in \f$O(nm)\f$ for unit capacities. The
+  /// purpose of such algorithm is testing network reliability. For an
+  /// undirected graph you can run just the first phase of the
+  /// algorithm or you can use the algorithm of Nagamochi and Ibaraki
+  /// which solves the undirected problem in 
+  /// \f$ O(nm + n^2 \log(n)) \f$ time: it is implemented in the
+  /// NagamochiIbaraki algorithm class.
+  ///
+  /// \param _Graph is the graph type of the algorithm.
+  /// \param _CapacityMap is an edge map of capacities which should
+  /// be any numreric type. The default type is _Graph::EdgeMap<int>.
+  /// \param _Tolerance is the handler of the inexact computation. The
+  /// default type for this is Tolerance<typename CapacityMap::Value>.
+  ///
+  /// \author Attila Bernath and Balazs Dezso
+#ifdef DOXYGEN
+  template <typename _Graph, typename _CapacityMap, typename _Tolerance>
+#else
+  template <typename _Graph,
+	    typename _CapacityMap = typename _Graph::template EdgeMap<int>,
+            typename _Tolerance = Tolerance<typename _CapacityMap::Value> >
+#endif
+  class HaoOrlin {
+  private:
+
+    typedef _Graph Graph;
+    typedef _CapacityMap CapacityMap;
+    typedef _Tolerance Tolerance;
+
+    typedef typename CapacityMap::Value Value;
+
+    GRAPH_TYPEDEFS(typename Graph);
+    
+    const Graph& _graph;
+    const CapacityMap* _capacity;
+
+    typedef typename Graph::template EdgeMap<Value> FlowMap;
+    FlowMap* _flow;
+
+    Node _source;
+
+    int _node_num;
+
+    // Bucketing structure
+    std::vector<Node> _first, _last;
+    typename Graph::template NodeMap<Node>* _next;
+    typename Graph::template NodeMap<Node>* _prev;    
+    typename Graph::template NodeMap<bool>* _active;
+    typename Graph::template NodeMap<int>* _bucket;
+    
+    std::vector<bool> _dormant;
+
+    std::list<std::list<int> > _sets;
+    std::list<int>::iterator _highest;
+    
+    typedef typename Graph::template NodeMap<Value> ExcessMap;
+    ExcessMap* _excess;
+
+    typedef typename Graph::template NodeMap<bool> SourceSetMap;
+    SourceSetMap* _source_set;
+
+    Value _min_cut;
+
+    typedef typename Graph::template NodeMap<bool> MinCutMap;
+    MinCutMap* _min_cut_map;
+
+    Tolerance _tolerance;
+
+  public: 
+
+    /// \brief Constructor
+    ///
+    /// Constructor of the algorithm class. 
+    HaoOrlin(const Graph& graph, const CapacityMap& capacity, 
+             const Tolerance& tolerance = Tolerance()) :
+      _graph(graph), _capacity(&capacity), _flow(0), _source(),
+      _node_num(), _first(), _last(), _next(0), _prev(0), 
+      _active(0), _bucket(0), _dormant(), _sets(), _highest(),
+      _excess(0), _source_set(0), _min_cut(), _min_cut_map(0), 
+      _tolerance(tolerance) {}
+
+    ~HaoOrlin() {
+      if (_min_cut_map) {
+        delete _min_cut_map;
+      } 
+      if (_source_set) {
+        delete _source_set;
+      }
+      if (_excess) {
+        delete _excess;
+      }
+      if (_next) {
+	delete _next;
+      }
+      if (_prev) {
+	delete _prev;
+      }
+      if (_active) {
+	delete _active;
+      }
+      if (_bucket) {
+	delete _bucket;
+      }
+      if (_flow) {
+        delete _flow;
+      }
+    }
+    
+  private:
+
+    void activate(const Node& i) {
+      _active->set(i, true);
+
+      int bucket = (*_bucket)[i];
+
+      if ((*_prev)[i] == INVALID || (*_active)[(*_prev)[i]]) return;	    
+      //unlace
+      _next->set((*_prev)[i], (*_next)[i]);
+      if ((*_next)[i] != INVALID) {
+	_prev->set((*_next)[i], (*_prev)[i]);
+      } else {
+	_last[bucket] = (*_prev)[i];
+      }
+      //lace
+      _next->set(i, _first[bucket]);
+      _prev->set(_first[bucket], i);
+      _prev->set(i, INVALID);
+      _first[bucket] = i;
+    }
+
+    void deactivate(const Node& i) {
+      _active->set(i, false);
+      int bucket = (*_bucket)[i];
+
+      if ((*_next)[i] == INVALID || !(*_active)[(*_next)[i]]) return;
+      
+      //unlace
+      _prev->set((*_next)[i], (*_prev)[i]);
+      if ((*_prev)[i] != INVALID) {
+	_next->set((*_prev)[i], (*_next)[i]);
+      } else {
+	_first[bucket] = (*_next)[i];
+      }
+      //lace
+      _prev->set(i, _last[bucket]);
+      _next->set(_last[bucket], i);
+      _next->set(i, INVALID);
+      _last[bucket] = i;
+    }
+
+    void addItem(const Node& i, int bucket) {
+      (*_bucket)[i] = bucket;
+      if (_last[bucket] != INVALID) {
+	_prev->set(i, _last[bucket]);
+	_next->set(_last[bucket], i);
+	_next->set(i, INVALID);
+	_last[bucket] = i;
+      } else {
+	_prev->set(i, INVALID);
+	_first[bucket] = i;
+	_next->set(i, INVALID);
+	_last[bucket] = i;
+      }
+    }
+    
+    void findMinCutOut() {
+
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	_excess->set(n, 0);
+      }
+
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+	_flow->set(e, 0);
+      }
+
+      int bucket_num = 1;
+      
+      {
+	typename Graph::template NodeMap<bool> reached(_graph, false);
+	
+	reached.set(_source, true);
+
+	bool first_set = true;
+
+	for (NodeIt t(_graph); t != INVALID; ++t) {
+	  if (reached[t]) continue;
+	  _sets.push_front(std::list<int>());
+	  _sets.front().push_front(bucket_num);
+	  _dormant[bucket_num] = !first_set;
+
+	  _bucket->set(t, bucket_num);
+	  _first[bucket_num] = _last[bucket_num] = t;
+	  _next->set(t, INVALID);
+	  _prev->set(t, INVALID);
+
+	  ++bucket_num;
+	  
+	  std::vector<Node> queue;
+	  queue.push_back(t);
+	  reached.set(t, true);
+	  
+	  while (!queue.empty()) {
+	    _sets.front().push_front(bucket_num);
+	    _dormant[bucket_num] = !first_set;
+	    _first[bucket_num] = _last[bucket_num] = INVALID;
+	    
+	    std::vector<Node> nqueue;
+	    for (int i = 0; i < int(queue.size()); ++i) {
+	      Node n = queue[i];
+	      for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+		Node u = _graph.source(e);
+		if (!reached[u] && _tolerance.positive((*_capacity)[e])) {
+		  reached.set(u, true);
+		  addItem(u, bucket_num);
+		  nqueue.push_back(u);
+		}
+	      }
+	    }
+	    queue.swap(nqueue);
+	    ++bucket_num;
+	  }
+	  _sets.front().pop_front();
+	  --bucket_num;
+	  first_set = false;
+	}
+
+	_bucket->set(_source, 0);
+	_dormant[0] = true;
+      }
+      _source_set->set(_source, true);	  
+	  
+      Node target = _last[_sets.back().back()];
+      {
+	for (OutEdgeIt e(_graph, _source); e != INVALID; ++e) {
+	  if (_tolerance.positive((*_capacity)[e])) {
+	    Node u = _graph.target(e);
+	    _flow->set(e, (*_capacity)[e]);
+	    _excess->set(u, (*_excess)[u] + (*_capacity)[e]);
+	    if (!(*_active)[u] && u != _source) {
+	      activate(u);	      
+	    }
+	  }
+	}
+
+	if ((*_active)[target]) {
+	  deactivate(target);
+	}
+	
+	_highest = _sets.back().begin();
+	while (_highest != _sets.back().end() && 
+	       !(*_active)[_first[*_highest]]) {
+	  ++_highest;
+	}
+      }
+
+      while (true) {
+	while (_highest != _sets.back().end()) {
+	  Node n = _first[*_highest];
+	  Value excess = (*_excess)[n];
+	  int next_bucket = _node_num;
+
+	  int under_bucket;
+	  if (++std::list<int>::iterator(_highest) == _sets.back().end()) {
+	    under_bucket = -1;
+	  } else {
+	    under_bucket = *(++std::list<int>::iterator(_highest));
+	  }
+
+	  for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node v = _graph.target(e);
+	    if (_dormant[(*_bucket)[v]]) continue;
+	    Value rem = (*_capacity)[e] - (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    if ((*_bucket)[v] == under_bucket) {
+	      if (!(*_active)[v] && v != target) {
+		activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] + excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;
+		goto no_more_push;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, (*_capacity)[e]);
+	      }
+	    } else if (next_bucket > (*_bucket)[v]) {
+	      next_bucket = (*_bucket)[v];
+	    }
+	  }
+
+	  for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node v = _graph.source(e);
+	    if (_dormant[(*_bucket)[v]]) continue;
+	    Value rem = (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    if ((*_bucket)[v] == under_bucket) {
+	      if (!(*_active)[v] && v != target) {
+		activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] - excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;
+		goto no_more_push;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, 0);
+	      }
+	    } else if (next_bucket > (*_bucket)[v]) {
+	      next_bucket = (*_bucket)[v];
+	    }
+	  }
+	  
+	no_more_push:
+	  
+	  _excess->set(n, excess);
+	  
+	  if (excess != 0) {
+	    if ((*_next)[n] == INVALID) {
+	      typename std::list<std::list<int> >::iterator new_set = 
+		_sets.insert(--_sets.end(), std::list<int>());
+	      new_set->splice(new_set->end(), _sets.back(), 
+			      _sets.back().begin(), ++_highest);
+	      for (std::list<int>::iterator it = new_set->begin();
+		   it != new_set->end(); ++it) {
+		_dormant[*it] = true;
+	      }
+	      while (_highest != _sets.back().end() && 
+		     !(*_active)[_first[*_highest]]) {
+		++_highest;
+	      }
+	    } else if (next_bucket == _node_num) {
+	      _first[(*_bucket)[n]] = (*_next)[n];
+	      _prev->set((*_next)[n], INVALID);
+	      
+	      std::list<std::list<int> >::iterator new_set = 
+		_sets.insert(--_sets.end(), std::list<int>());
+	      
+	      new_set->push_front(bucket_num);
+	      _bucket->set(n, bucket_num);
+	      _first[bucket_num] = _last[bucket_num] = n;
+	      _next->set(n, INVALID);
+	      _prev->set(n, INVALID);
+	      _dormant[bucket_num] = true;
+	      ++bucket_num;
+
+	      while (_highest != _sets.back().end() && 
+		     !(*_active)[_first[*_highest]]) {
+		++_highest;
+	      }
+	    } else {
+	      _first[*_highest] = (*_next)[n];
+	      _prev->set((*_next)[n], INVALID);
+	      
+	      while (next_bucket != *_highest) {
+		--_highest;
+	      }
+
+	      if (_highest == _sets.back().begin()) {
+		_sets.back().push_front(bucket_num);
+		_dormant[bucket_num] = false;
+		_first[bucket_num] = _last[bucket_num] = INVALID;
+		++bucket_num;
+	      }
+	      --_highest;
+
+	      _bucket->set(n, *_highest);
+	      _next->set(n, _first[*_highest]);
+	      if (_first[*_highest] != INVALID) {
+		_prev->set(_first[*_highest], n);
+	      } else {
+		_last[*_highest] = n;
+	      }
+	      _first[*_highest] = n;	      
+	    }
+	  } else {
+
+	    deactivate(n);
+	    if (!(*_active)[_first[*_highest]]) {
+	      ++_highest;
+	      if (_highest != _sets.back().end() && 
+		  !(*_active)[_first[*_highest]]) {
+		_highest = _sets.back().end();
+	      }
+	    }
+	  }
+	}
+
+	if ((*_excess)[target] < _min_cut) {
+	  _min_cut = (*_excess)[target];
+	  for (NodeIt i(_graph); i != INVALID; ++i) {
+	    _min_cut_map->set(i, true);
+	  }
+	  for (std::list<int>::iterator it = _sets.back().begin();
+	       it != _sets.back().end(); ++it) {
+	    Node n = _first[*it];
+	    while (n != INVALID) {
+	      _min_cut_map->set(n, false);
+	      n = (*_next)[n];
+	    }
+	  }
+	}
+
+	{
+	  Node new_target;
+	  if ((*_prev)[target] != INVALID || (*_next)[target] != INVALID) {
+	    if ((*_next)[target] == INVALID) {
+	      _last[(*_bucket)[target]] = (*_prev)[target];
+	      new_target = (*_prev)[target];
+	    } else {
+	      _prev->set((*_next)[target], (*_prev)[target]);
+	      new_target = (*_next)[target];
+	    }
+	    if ((*_prev)[target] == INVALID) {
+	      _first[(*_bucket)[target]] = (*_next)[target];
+	    } else {
+	      _next->set((*_prev)[target], (*_next)[target]);
+	    }
+	  } else {
+	    _sets.back().pop_back();
+	    if (_sets.back().empty()) {
+	      _sets.pop_back();
+	      if (_sets.empty())
+		break;
+	      for (std::list<int>::iterator it = _sets.back().begin();
+		   it != _sets.back().end(); ++it) {
+		_dormant[*it] = false;
+	      }
+	    }
+	    new_target = _last[_sets.back().back()];
+	  }
+
+	  _bucket->set(target, 0);
+
+	  _source_set->set(target, true);	  
+	  for (OutEdgeIt e(_graph, target); e != INVALID; ++e) {
+	    Value rem = (*_capacity)[e] - (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    Node v = _graph.target(e);
+	    if (!(*_active)[v] && !(*_source_set)[v]) {
+	      activate(v);
+	    }
+	    _excess->set(v, (*_excess)[v] + rem);
+	    _flow->set(e, (*_capacity)[e]);
+	  }
+	  
+	  for (InEdgeIt e(_graph, target); e != INVALID; ++e) {
+	    Value rem = (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    Node v = _graph.source(e);
+	    if (!(*_active)[v] && !(*_source_set)[v]) {
+	      activate(v);
+	    }
+	    _excess->set(v, (*_excess)[v] + rem);
+	    _flow->set(e, 0);
+	  }
+	  
+	  target = new_target;
+	  if ((*_active)[target]) {
+	    deactivate(target);
+	  }
+
+	  _highest = _sets.back().begin();
+	  while (_highest != _sets.back().end() && 
+		 !(*_active)[_first[*_highest]]) {
+	    ++_highest;
+	  }
+	}
+      }
+    }    
+
+    void findMinCutIn() {
+
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	_excess->set(n, 0);
+      }
+
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+	_flow->set(e, 0);
+      }
+
+      int bucket_num = 1;
+      
+      {
+	typename Graph::template NodeMap<bool> reached(_graph, false);
+	
+	reached.set(_source, true);
+
+	bool first_set = true;
+
+	for (NodeIt t(_graph); t != INVALID; ++t) {
+	  if (reached[t]) continue;
+	  _sets.push_front(std::list<int>());
+	  _sets.front().push_front(bucket_num);
+	  _dormant[bucket_num] = !first_set;
+
+	  _bucket->set(t, bucket_num);
+	  _first[bucket_num] = _last[bucket_num] = t;
+	  _next->set(t, INVALID);
+	  _prev->set(t, INVALID);
+
+	  ++bucket_num;
+	  
+	  std::vector<Node> queue;
+	  queue.push_back(t);
+	  reached.set(t, true);
+	  
+	  while (!queue.empty()) {
+	    _sets.front().push_front(bucket_num);
+	    _dormant[bucket_num] = !first_set;
+	    _first[bucket_num] = _last[bucket_num] = INVALID;
+	    
+	    std::vector<Node> nqueue;
+	    for (int i = 0; i < int(queue.size()); ++i) {
+	      Node n = queue[i];
+	      for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+		Node u = _graph.target(e);
+		if (!reached[u] && _tolerance.positive((*_capacity)[e])) {
+		  reached.set(u, true);
+		  addItem(u, bucket_num);
+		  nqueue.push_back(u);
+		}
+	      }
+	    }
+	    queue.swap(nqueue);
+	    ++bucket_num;
+	  }
+	  _sets.front().pop_front();
+	  --bucket_num;
+	  first_set = false;
+	}
+
+	_bucket->set(_source, 0);
+	_dormant[0] = true;
+      }
+      _source_set->set(_source, true);	  
+	  
+      Node target = _last[_sets.back().back()];
+      {
+	for (InEdgeIt e(_graph, _source); e != INVALID; ++e) {
+	  if (_tolerance.positive((*_capacity)[e])) {
+	    Node u = _graph.source(e);
+	    _flow->set(e, (*_capacity)[e]);
+	    _excess->set(u, (*_excess)[u] + (*_capacity)[e]);
+	    if (!(*_active)[u] && u != _source) {
+	      activate(u);
+	    }
+	  }
+	}
+	if ((*_active)[target]) {
+	  deactivate(target);
+	}
+	
+	_highest = _sets.back().begin();
+	while (_highest != _sets.back().end() && 
+	       !(*_active)[_first[*_highest]]) {
+	  ++_highest;
+	}
+      }
+
+
+      while (true) {
+	while (_highest != _sets.back().end()) {
+	  Node n = _first[*_highest];
+	  Value excess = (*_excess)[n];
+	  int next_bucket = _node_num;
+
+	  int under_bucket;
+	  if (++std::list<int>::iterator(_highest) == _sets.back().end()) {
+	    under_bucket = -1;
+	  } else {
+	    under_bucket = *(++std::list<int>::iterator(_highest));
+	  }
+
+	  for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node v = _graph.source(e);
+	    if (_dormant[(*_bucket)[v]]) continue;
+	    Value rem = (*_capacity)[e] - (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    if ((*_bucket)[v] == under_bucket) {
+	      if (!(*_active)[v] && v != target) {
+		activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] + excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;
+		goto no_more_push;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, (*_capacity)[e]);
+	      }
+	    } else if (next_bucket > (*_bucket)[v]) {
+	      next_bucket = (*_bucket)[v];
+	    }
+	  }
+
+	  for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node v = _graph.target(e);
+	    if (_dormant[(*_bucket)[v]]) continue;
+	    Value rem = (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    if ((*_bucket)[v] == under_bucket) {
+	      if (!(*_active)[v] && v != target) {
+		activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] - excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;
+		goto no_more_push;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, 0);
+	      }
+	    } else if (next_bucket > (*_bucket)[v]) {
+	      next_bucket = (*_bucket)[v];
+	    }
+	  }
+	  
+	no_more_push:
+	  
+	  _excess->set(n, excess);
+	  
+	  if (excess != 0) {
+	    if ((*_next)[n] == INVALID) {
+	      typename std::list<std::list<int> >::iterator new_set = 
+		_sets.insert(--_sets.end(), std::list<int>());
+	      new_set->splice(new_set->end(), _sets.back(), 
+			      _sets.back().begin(), ++_highest);
+	      for (std::list<int>::iterator it = new_set->begin();
+		   it != new_set->end(); ++it) {
+		_dormant[*it] = true;
+	      }
+	      while (_highest != _sets.back().end() && 
+		     !(*_active)[_first[*_highest]]) {
+		++_highest;
+	      }
+	    } else if (next_bucket == _node_num) {
+	      _first[(*_bucket)[n]] = (*_next)[n];
+	      _prev->set((*_next)[n], INVALID);
+	      
+	      std::list<std::list<int> >::iterator new_set = 
+		_sets.insert(--_sets.end(), std::list<int>());
+	      
+	      new_set->push_front(bucket_num);
+	      _bucket->set(n, bucket_num);
+	      _first[bucket_num] = _last[bucket_num] = n;
+	      _next->set(n, INVALID);
+	      _prev->set(n, INVALID);
+	      _dormant[bucket_num] = true;
+	      ++bucket_num;
+
+	      while (_highest != _sets.back().end() && 
+		     !(*_active)[_first[*_highest]]) {
+		++_highest;
+	      }
+	    } else {
+	      _first[*_highest] = (*_next)[n];
+	      _prev->set((*_next)[n], INVALID);
+
+	      while (next_bucket != *_highest) {
+		--_highest;
+	      }
+	      if (_highest == _sets.back().begin()) {
+		_sets.back().push_front(bucket_num);
+		_dormant[bucket_num] = false;
+		_first[bucket_num] = _last[bucket_num] = INVALID;
+		++bucket_num;
+	      }
+	      --_highest;
+
+	      _bucket->set(n, *_highest);
+	      _next->set(n, _first[*_highest]);
+	      if (_first[*_highest] != INVALID) {
+		_prev->set(_first[*_highest], n);
+	      } else {
+		_last[*_highest] = n;
+	      }
+	      _first[*_highest] = n;	      
+	    }
+	  } else {
+
+	    deactivate(n);
+	    if (!(*_active)[_first[*_highest]]) {
+	      ++_highest;
+	      if (_highest != _sets.back().end() && 
+		  !(*_active)[_first[*_highest]]) {
+		_highest = _sets.back().end();
+	      }
+	    }
+	  }
+	}
+
+	if ((*_excess)[target] < _min_cut) {
+	  _min_cut = (*_excess)[target];
+	  for (NodeIt i(_graph); i != INVALID; ++i) {
+	    _min_cut_map->set(i, false);
+	  }
+	  for (std::list<int>::iterator it = _sets.back().begin();
+	       it != _sets.back().end(); ++it) {
+	    Node n = _first[*it];
+	    while (n != INVALID) {
+	      _min_cut_map->set(n, true);
+	      n = (*_next)[n];
+	    }
+	  }
+	}
+
+	{
+	  Node new_target;
+	  if ((*_prev)[target] != INVALID || (*_next)[target] != INVALID) {
+	    if ((*_next)[target] == INVALID) {
+	      _last[(*_bucket)[target]] = (*_prev)[target];
+	      new_target = (*_prev)[target];
+	    } else {
+	      _prev->set((*_next)[target], (*_prev)[target]);
+	      new_target = (*_next)[target];
+	    }
+	    if ((*_prev)[target] == INVALID) {
+	      _first[(*_bucket)[target]] = (*_next)[target];
+	    } else {
+	      _next->set((*_prev)[target], (*_next)[target]);
+	    }
+	  } else {
+	    _sets.back().pop_back();
+	    if (_sets.back().empty()) {
+	      _sets.pop_back();
+	      if (_sets.empty())
+		break;
+	      for (std::list<int>::iterator it = _sets.back().begin();
+		   it != _sets.back().end(); ++it) {
+		_dormant[*it] = false;
+	      }
+	    }
+	    new_target = _last[_sets.back().back()];
+	  }
+
+	  _bucket->set(target, 0);
+
+	  _source_set->set(target, true);	  
+	  for (InEdgeIt e(_graph, target); e != INVALID; ++e) {
+	    Value rem = (*_capacity)[e] - (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    Node v = _graph.source(e);
+	    if (!(*_active)[v] && !(*_source_set)[v]) {
+	      activate(v);
+	    }
+	    _excess->set(v, (*_excess)[v] + rem);
+	    _flow->set(e, (*_capacity)[e]);
+	  }
+	  
+	  for (OutEdgeIt e(_graph, target); e != INVALID; ++e) {
+	    Value rem = (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    Node v = _graph.target(e);
+	    if (!(*_active)[v] && !(*_source_set)[v]) {
+	      activate(v);
+	    }
+	    _excess->set(v, (*_excess)[v] + rem);
+	    _flow->set(e, 0);
+	  }
+	  
+	  target = new_target;
+	  if ((*_active)[target]) {
+	    deactivate(target);
+	  }
+
+	  _highest = _sets.back().begin();
+	  while (_highest != _sets.back().end() && 
+		 !(*_active)[_first[*_highest]]) {
+	    ++_highest;
+	  }
+	}
+      }
+    }
+
+  public:
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run(...).
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init(), then the \ref calculateIn() or
+    /// \ref calculateIn() functions.
+
+    /// @{
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures. It creates
+    /// the maps, residual graph adaptors and some bucket structures
+    /// for the algorithm. 
+    void init() {
+      init(NodeIt(_graph));
+    }
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures. It creates
+    /// the maps, residual graph adaptor and some bucket structures
+    /// for the algorithm. Node \c source  is used as the push-relabel
+    /// algorithm's source.
+    void init(const Node& source) {
+      _source = source;
+      
+      _node_num = countNodes(_graph);
+      
+      _first.resize(_node_num + 1);
+      _last.resize(_node_num + 1);
+
+      _dormant.resize(_node_num + 1);
+
+      if (!_flow) {
+	_flow = new FlowMap(_graph);
+      }
+      if (!_next) {
+	_next = new typename Graph::template NodeMap<Node>(_graph);
+      }
+      if (!_prev) {
+	_prev = new typename Graph::template NodeMap<Node>(_graph);
+      }
+      if (!_active) {
+	_active = new typename Graph::template NodeMap<bool>(_graph);
+      }
+      if (!_bucket) {
+	_bucket = new typename Graph::template NodeMap<int>(_graph);
+      }
+      if (!_excess) {
+	_excess = new ExcessMap(_graph);
+      }
+      if (!_source_set) {
+	_source_set = new SourceSetMap(_graph);
+      }
+      if (!_min_cut_map) {
+	_min_cut_map = new MinCutMap(_graph);
+      }
+
+      _min_cut = std::numeric_limits<Value>::max();
+    }
+
+
+    /// \brief Calculates a minimum cut with \f$ source \f$ on the
+    /// source-side.
+    ///
+    /// Calculates a minimum cut with \f$ source \f$ on the
+    /// source-side (i.e. a set \f$ X\subsetneq V \f$ with \f$ source
+    /// \in X \f$ and minimal out-degree).
+    void calculateOut() {
+      findMinCutOut();
+    }
+
+    /// \brief Calculates a minimum cut with \f$ source \f$ on the
+    /// target-side.
+    ///
+    /// Calculates a minimum cut with \f$ source \f$ on the
+    /// target-side (i.e. a set \f$ X\subsetneq V \f$ with \f$ source
+    /// \in X \f$ and minimal out-degree).
+    void calculateIn() {
+      findMinCutIn();
+    }
+
+
+    /// \brief Runs the algorithm.
+    ///
+    /// Runs the algorithm. It finds nodes \c source and \c target
+    /// arbitrarily and then calls \ref init(), \ref calculateOut()
+    /// and \ref calculateIn().
+    void run() {
+      init();
+      calculateOut();
+      calculateIn();
+    }
+
+    /// \brief Runs the algorithm.
+    ///
+    /// Runs the algorithm. It uses the given \c source node, finds a
+    /// proper \c target and then calls the \ref init(), \ref
+    /// calculateOut() and \ref calculateIn().
+    void run(const Node& s) {
+      init(s);
+      calculateOut();
+      calculateIn();
+    }
+
+    /// @}
+    
+    /// \name Query Functions 
+    /// The result of the %HaoOrlin algorithm
+    /// can be obtained using these functions.
+    /// \n
+    /// Before using these functions, either \ref run(), \ref
+    /// calculateOut() or \ref calculateIn() must be called.
+    
+    /// @{
+
+    /// \brief Returns the value of the minimum value cut.
+    /// 
+    /// Returns the value of the minimum value cut.
+    Value minCut() const {
+      return _min_cut;
+    }
+
+
+    /// \brief Returns a minimum cut.
+    ///
+    /// Sets \c nodeMap to the characteristic vector of a minimum
+    /// value cut: it will give a nonempty set \f$ X\subsetneq V \f$
+    /// with minimal out-degree (i.e. \c nodeMap will be true exactly
+    /// for the nodes of \f$ X \f$).  \pre nodeMap should be a
+    /// bool-valued node-map.
+    template <typename NodeMap>
+    Value minCut(NodeMap& nodeMap) const {
+      for (NodeIt it(_graph); it != INVALID; ++it) {
+	nodeMap.set(it, (*_min_cut_map)[it]);
+      }
+      return minCut();
+    }
+
+    /// @}
+    
+  }; //class HaoOrlin 
+
+
+} //namespace lemon
+
+#endif //LEMON_HAO_ORLIN_H
Index: lemon/hypercube_graph.h
===================================================================
--- lemon/hypercube_graph.h	(revision 2553)
+++ lemon/hypercube_graph.h	(revision 2553)
@@ -0,0 +1,322 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef HYPERCUBE_GRAPH_H
+#define HYPERCUBE_GRAPH_H
+
+#include <iostream>
+#include <vector>
+#include <lemon/bits/invalid.h>
+#include <lemon/bits/utility.h>
+#include <lemon/error.h>
+
+#include <lemon/bits/base_extender.h>
+#include <lemon/bits/graph_extender.h>
+
+///\ingroup graphs
+///\file
+///\brief HyperCubeGraph class.
+
+namespace lemon {
+
+  class HyperCubeGraphBase {
+
+  public:
+
+    typedef HyperCubeGraphBase Graph;
+
+    class Node;
+    class Edge;
+
+  public:
+
+    HyperCubeGraphBase() {}
+
+  protected:
+
+    void construct(int dim) {
+      _dim = dim;
+      _nodeNum = 1 << dim;
+    }
+
+  public:
+    
+
+    typedef True NodeNumTag;
+    typedef True EdgeNumTag;
+
+    int nodeNum() const { return _nodeNum; }
+    int edgeNum() const { return _nodeNum * _dim; }
+
+    int maxNodeId() const { return nodeNum() - 1; }
+    int maxEdgeId() const { return edgeNum() - 1; }
+
+    Node source(Edge e) const {
+      return e.id / _dim;
+    }
+
+    Node target(Edge e) const {
+      return (e.id / _dim) ^ ( 1 << (e.id % _dim));
+    }
+
+    static int id(Node v) { return v.id; }
+    static int id(Edge e) { return e.id; }
+
+    static Node nodeFromId(int id) { return Node(id);}
+    
+    static Edge edgeFromId(int id) { return Edge(id);}
+
+    class Node {
+      friend class HyperCubeGraphBase;
+
+    protected:
+      int id;
+      Node(int _id) { id = _id;}
+    public:
+      Node() {}
+      Node (Invalid) { id = -1; }
+      bool operator==(const Node node) const {return id == node.id;}
+      bool operator!=(const Node node) const {return id != node.id;}
+      bool operator<(const Node node) const {return id < node.id;}
+    };
+    
+    class Edge {
+      friend class HyperCubeGraphBase;
+      
+    protected:
+      int id; 
+
+      Edge(int _id) : id(_id) {}
+
+    public:
+      Edge() { }
+      Edge (Invalid) { id = -1; }
+      bool operator==(const Edge edge) const {return id == edge.id;}
+      bool operator!=(const Edge edge) const {return id != edge.id;}
+      bool operator<(const Edge edge) const {return id < edge.id;}
+    };
+
+    void first(Node& node) const {
+      node.id = nodeNum() - 1;
+    }
+
+    static void next(Node& node) {
+      --node.id;
+    }
+
+    void first(Edge& edge) const {
+      edge.id = edgeNum() - 1;
+    }
+
+    static void next(Edge& edge) {
+      --edge.id;
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      edge.id = node.id * _dim;
+    }
+
+    void nextOut(Edge& edge) const {
+      ++edge.id;
+      if (edge.id % _dim == 0) edge.id = -1;
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      edge.id = (node.id ^ 1) * _dim;
+    }
+    
+    void nextIn(Edge& edge) const {
+      int cnt = edge.id % _dim;
+      if ((cnt + 1) % _dim == 0) {
+	edge.id = -1;
+      } else {
+	edge.id = ((edge.id / _dim) ^ ((1 << cnt) * 3)) * _dim + cnt + 1; 
+      }
+    }
+
+    int dimension() const {
+      return _dim;
+    }
+
+    bool projection(Node node, int n) const {
+      return static_cast<bool>(node.id & (1 << n));
+    }
+
+    int dimension(Edge edge) const {
+      return edge.id % _dim;
+    }
+
+    int index(Node node) const {
+      return node.id;
+    }
+
+    Node operator()(int ix) const {
+      return Node(ix);
+    }
+    
+  private:
+    int _dim, _nodeNum;
+  };
+
+
+  typedef GraphExtender<HyperCubeGraphBase> ExtendedHyperCubeGraphBase;
+
+  /// \ingroup graphs
+  ///
+  /// \brief HyperCube graph class
+  ///
+  /// This class implements a special graph type. The nodes of the
+  /// graph can be indiced with integers with at most \c dim binary length.
+  /// Two nodes are connected in the graph if the indices differ only
+  /// on one position in the binary form. 
+  ///
+  /// \note The type of the \c ids is chosen to \c int because efficiency
+  /// reasons. This way the maximal dimension of this implementation
+  /// is 26. 
+  ///
+  /// The graph type is fully conform to the \ref concepts::Graph
+  /// concept but it does not conform to the \ref concepts::UGraph.
+  ///
+  /// \author Balazs Dezso
+  class HyperCubeGraph : public ExtendedHyperCubeGraphBase {
+  public:
+
+    typedef ExtendedHyperCubeGraphBase Parent;
+
+    /// \brief Construct a graph with \c dim dimension.
+    ///
+    /// Construct a graph with \c dim dimension.
+    HyperCubeGraph(int dim) { construct(dim); }
+
+    /// \brief Gives back the number of the dimensions.
+    ///
+    /// Gives back the number of the dimensions.
+    int dimension() const {
+      return Parent::dimension();
+    }
+
+    /// \brief Returns true if the n'th bit of the node is one.
+    ///
+    /// Returns true if the n'th bit of the node is one. 
+    bool projection(Node node, int n) const {
+      return Parent::projection(node, n);
+    }
+
+    /// \brief The dimension id of the edge.
+    ///
+    /// It returns the dimension id of the edge. It can
+    /// be in the \f$ \{0, 1, \dots, dim-1\} \f$ intervall.
+    int dimension(Edge edge) const {
+      return Parent::dimension(edge);
+    }
+
+    /// \brief Gives back the index of the node.
+    ///
+    /// Gives back the index of the node. The lower bits of the
+    /// integer describes the node.
+    int index(Node node) const {
+      return Parent::index(node);
+    }
+
+    /// \brief Gives back the node by its index.
+    ///
+    /// Gives back the node by its index.
+    Node operator()(int ix) const {
+      return Parent::operator()(ix);
+    }
+
+    /// \brief Number of nodes.
+    int nodeNum() const { return Parent::nodeNum(); }
+    /// \brief Number of edges.
+    int edgeNum() const { return Parent::edgeNum(); }
+
+    /// \brief Linear combination map.
+    ///
+    /// It makes possible to give back a linear combination
+    /// for each node. This function works like the \c std::accumulate
+    /// so it accumulates the \c bf binary function with the \c fv
+    /// first value. The map accumulates only on that dimensions where
+    /// the node's index is one. The accumulated values should be
+    /// given by the \c begin and \c end iterators and this range's length
+    /// should be the dimension number of the graph.
+    /// 
+    ///\code
+    /// const int DIM = 3;
+    /// HyperCubeGraph graph(DIM);
+    /// dim2::Point<double> base[DIM];
+    /// for (int k = 0; k < DIM; ++k) {
+    ///   base[k].x = rnd();
+    ///   base[k].y = rnd();
+    /// } 
+    /// HyperCubeGraph::HyperMap<dim2::Point<double> > 
+    ///   pos(graph, base, base + DIM, dim2::Point<double>(0.0, 0.0));
+    ///\endcode
+    ///
+    /// \see HyperCubeGraph
+    template <typename T, typename BF = std::plus<T> >
+    class HyperMap {
+    public:
+
+      typedef Node Key;
+      typedef T Value;
+    
+      
+      /// \brief Constructor for HyperMap. 
+      ///
+      /// Construct a HyperMap for the given graph. The accumulated values 
+      /// should be given by the \c begin and \c end iterators and this 
+      /// range's length should be the dimension number of the graph.
+      ///
+      /// This function accumulates the \c bf binary function with 
+      /// the \c fv first value. The map accumulates only on that dimensions 
+      /// where the node's index is one.           
+      template <typename It>
+      HyperMap(const Graph& graph, It begin, It end, 
+		   T fv = 0.0, const BF& bf = BF()) 
+	: _graph(graph), _values(begin, end), _first_value(fv), _bin_func(bf) {
+	LEMON_ASSERT(_values.size() == graph.dimension(), 
+		     "Wrong size of dimension");
+      }
+
+      /// \brief Gives back the partial accumulated value.
+      ///
+      /// Gives back the partial accumulated value.
+      Value operator[](Key k) const {
+	Value val = _first_value;
+	int id = _graph.index(k); 
+	int n = 0;
+	while (id != 0) {
+	  if (id & 1) {
+	    val = _bin_func(val, _values[n]);
+	  }
+	  id >>= 1;
+	  ++n;
+	}
+	return val;
+      }
+      
+    private:
+      const Graph& _graph;
+      std::vector<T> _values;
+      T _first_value;
+      BF _bin_func;
+    };    
+  };
+}
+#endif
+
Index: lemon/iterable_maps.h
===================================================================
--- lemon/iterable_maps.h	(revision 2553)
+++ lemon/iterable_maps.h	(revision 2553)
@@ -0,0 +1,931 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_ITERABLE_MAPS_H
+#define LEMON_ITERABLE_MAPS_H
+
+#include <lemon/bits/traits.h>
+#include <lemon/bits/invalid.h>
+
+#include <lemon/bits/default_map.h>
+#include <lemon/bits/map_extender.h>
+
+#include <vector>
+#include <map>
+
+#include <iterator>
+#include <limits>
+
+///\ingroup maps
+///\file
+///\brief Maps that makes it possible to iterate through the keys having
+///a certain value
+///
+///
+
+
+namespace lemon {
+
+  ///\ingroup graph_maps
+  ///
+  /// \brief Dynamic iterable bool map.
+  ///
+  /// This class provides a special graph map type which can store
+  /// for each graph item(node, edge, etc.) a bool value. For both 
+  /// the true and the false it is possible to iterate on the keys which
+  /// mapped to the given value.
+  /// 
+  /// \param _Graph The graph type.
+  /// \param _Item One of the graph's item type, the key of the map.
+  template <typename _Graph, typename _Item>
+  class IterableBoolMap : protected DefaultMap<_Graph, _Item, int> {
+  private:
+    typedef _Graph Graph;
+    
+    typedef typename ItemSetTraits<Graph, _Item>::ItemIt KeyIt;
+    typedef DefaultMap<_Graph, _Item, int> Parent;
+    
+    std::vector<_Item> array;
+    int sep;
+
+    const Graph& graph;
+
+  public:
+
+    /// Indicates that the map if reference map.
+    typedef True ReferenceMapTag;
+
+    /// The key type
+    typedef _Item Key;
+    /// The value type
+    typedef bool Value;
+    /// The const reference type.    
+    typedef const Value& ConstReference;
+
+  private:
+
+    int position(const Key& key) const {
+      return Parent::operator[](key);
+    }
+
+  public:
+
+    /// \brief Refernce to the value of the map.
+    ///
+    /// This class is near to similar to the bool type. It can
+    /// be converted to bool and it has the same operators.
+    class Reference {
+      friend class IterableBoolMap;
+    private:
+      Reference(IterableBoolMap& map, const Key& key) 
+	: _key(key), _map(map) {} 
+    public:
+
+      Reference& operator=(const Reference& value) {
+	_map.set(_key, static_cast<bool>(value));
+ 	return *this;
+      }
+
+      operator bool() const { 
+	return static_cast<const IterableBoolMap&>(_map)[_key]; 
+      }
+
+      Reference& operator=(bool value) { 
+	_map.set(_key, value); 
+	return *this; 
+      }
+      Reference& operator&=(bool value) {
+	_map.set(_key, _map[_key] & value); 
+	return *this; 	
+      }
+      Reference& operator|=(bool value) {
+	_map.set(_key, _map[_key] | value); 
+	return *this; 	
+      }
+      Reference& operator^=(bool value) {
+	_map.set(_key, _map[_key] ^ value); 
+	return *this; 	
+      }
+    private:
+      Key _key;
+      IterableBoolMap& _map; 
+    };
+    
+    /// \brief Constructor of the Map with a default value.
+    ///
+    /// Constructor of the Map with a default value.
+    explicit IterableBoolMap(const Graph& _graph, bool def = false) 
+      : Parent(_graph), graph(_graph) {
+      for (KeyIt it(graph); it != INVALID; ++it) {
+        Parent::set(it, array.size());
+        array.push_back(it);
+      }
+      sep = (def ? array.size() : 0);
+    }
+
+    /// \brief Const subscript operator of the map.
+    ///
+    /// Const subscript operator of the map.
+    bool operator[](const Key& key) const {
+      return position(key) < sep;
+    }
+
+    /// \brief Subscript operator of the map.
+    ///
+    /// Subscript operator of the map.
+    Reference operator[](const Key& key) {
+      return Reference(*this, key);
+    }
+
+    /// \brief Set operation of the map.
+    ///
+    /// Set operation of the map.
+    void set(const Key& key, bool value) {
+      int pos = position(key);
+      if (value) {
+        if (pos < sep) return;
+        Key tmp = array[sep];
+        array[sep] = key;
+        Parent::set(key, sep);
+        array[pos] = tmp;
+        Parent::set(tmp, pos); 
+        ++sep;
+      } else {
+        if (pos >= sep) return;
+        --sep;
+        Key tmp = array[sep];
+        array[sep] = key;
+        Parent::set(key, sep);
+        array[pos] = tmp;
+        Parent::set(tmp, pos);
+      }
+    }
+
+    /// \brief Set all items.
+    ///
+    /// Set all items in the map.
+    /// \note Constant time operation.
+    void setAll(bool value) {
+      sep = (value ? array.size() : 0);      
+    }
+
+    /// \brief Returns the number of the keys mapped to true.
+    ///
+    /// Returns the number of the keys mapped to true.
+    int trueNum() const {
+      return sep;
+    } 
+    
+    /// \brief Returns the number of the keys mapped to false.
+    ///
+    /// Returns the number of the keys mapped to false.
+    int falseNum() const {
+      return array.size() - sep;
+    }
+
+    /// \brief Iterator for the keys mapped to true.
+    ///
+    /// Iterator for the keys mapped to true. It works
+    /// like a graph item iterator in the map, it can be converted
+    /// the key type of the map, incremented with \c ++ operator, and
+    /// if the iterator leave the last valid key it will be equal to 
+    /// \c INVALID.
+    class TrueIt : public Key {
+    public:
+      typedef Key Parent;
+      
+      /// \brief Creates an iterator.
+      ///
+      /// Creates an iterator. It iterates on the 
+      /// keys which mapped to true.
+      /// \param _map The IterableIntMap
+      explicit TrueIt(const IterableBoolMap& _map) 
+        : Parent(_map.sep > 0 ? _map.array[_map.sep - 1] : INVALID), 
+          map(&_map) {}
+
+      /// \brief Invalid constructor \& conversion.
+      ///
+      /// This constructor initializes the key to be invalid.
+      /// \sa Invalid for more details.
+      TrueIt(Invalid) : Parent(INVALID), map(0) {}
+
+      /// \brief Increment operator.
+      ///
+      /// Increment Operator.
+      TrueIt& operator++() {
+        int pos = map->position(*this);
+        Parent::operator=(pos > 0 ? map->array[pos - 1] : INVALID);
+        return *this;
+      }
+
+      
+    private:
+      const IterableBoolMap* map;
+    };
+
+    /// \brief Iterator for the keys mapped to false.
+    ///
+    /// Iterator for the keys mapped to false. It works
+    /// like a graph item iterator in the map, it can be converted
+    /// the key type of the map, incremented with \c ++ operator, and
+    /// if the iterator leave the last valid key it will be equal to 
+    /// \c INVALID.
+    class FalseIt : public Key {
+    public:
+      typedef Key Parent;
+      
+      /// \brief Creates an iterator.
+      ///
+      /// Creates an iterator. It iterates on the 
+      /// keys which mapped to false.
+      /// \param _map The IterableIntMap
+      explicit FalseIt(const IterableBoolMap& _map) 
+        : Parent(_map.sep < int(_map.array.size()) ? 
+                 _map.array.back() : INVALID), map(&_map) {}
+
+      /// \brief Invalid constructor \& conversion.
+      ///
+      /// This constructor initializes the key to be invalid.
+      /// \sa Invalid for more details.
+      FalseIt(Invalid) : Parent(INVALID), map(0) {}
+
+      /// \brief Increment operator.
+      ///
+      /// Increment Operator.
+      FalseIt& operator++() {
+        int pos = map->position(*this);
+        Parent::operator=(pos > map->sep ? map->array[pos - 1] : INVALID);
+        return *this;
+      }
+
+    private:
+      const IterableBoolMap* map;
+    };
+
+    /// \brief Iterator for the keys mapped to a given value.
+    ///
+    /// Iterator for the keys mapped to a given value. It works
+    /// like a graph item iterator in the map, it can be converted
+    /// the key type of the map, incremented with \c ++ operator, and
+    /// if the iterator leave the last valid key it will be equal to 
+    /// \c INVALID.
+    class ItemIt : public Key {
+    public:
+      typedef Key Parent;
+      
+      /// \brief Creates an iterator.
+      ///
+      /// Creates an iterator. It iterates on the 
+      /// keys which mapped to false.
+      /// \param _map The IterableIntMap
+      /// \param value Which elements should be iterated.
+      ItemIt(const IterableBoolMap& _map, bool value) 
+        : Parent(value ? (_map.sep > 0 ? _map.array[_map.sep - 1] : INVALID) :
+                 (_map.sep < int(_map.array.size()) ? 
+                  _map.array.back() : INVALID)), map(&_map) {}
+
+      /// \brief Invalid constructor \& conversion.
+      ///
+      /// This constructor initializes the key to be invalid.
+      /// \sa Invalid for more details.
+      ItemIt(Invalid) : Parent(INVALID), map(0) {}
+
+      /// \brief Increment operator.
+      ///
+      /// Increment Operator.
+      ItemIt& operator++() {
+        int pos = map->position(*this);
+        int sep = pos >= map->sep ? map->sep : 0;
+        Parent::operator=(pos > sep ? map->array[pos - 1] : INVALID);
+        return *this;
+      }
+
+    private:
+      const IterableBoolMap* map;
+    };
+
+  protected:
+    
+    virtual void add(const Key& key) {
+      Parent::add(key);
+      Parent::set(key, array.size());
+      array.push_back(key);
+    }
+
+    virtual void add(const std::vector<Key>& keys) {
+      Parent::add(keys);
+      for (int i = 0; i < int(keys.size()); ++i) {
+        Parent::set(keys[i], array.size());
+        array.push_back(keys[i]);
+      }
+    }
+
+    virtual void erase(const Key& key) {
+      int pos = position(key); 
+      if (pos < sep) {
+        --sep;
+        Parent::set(array[sep], pos);
+        array[pos] = array[sep];
+        Parent::set(array.back(), sep);
+        array[sep] = array.back();
+        array.pop_back();
+      } else {
+        Parent::set(array.back(), pos);
+        array[pos] = array.back();
+        array.pop_back();
+      }
+      Parent::erase(key);
+    }
+
+    virtual void erase(const std::vector<Key>& keys) {
+      for (int i = 0; i < int(keys.size()); ++i) {
+        int pos = position(keys[i]); 
+        if (pos < sep) {
+          --sep;
+          Parent::set(array[sep], pos);
+          array[pos] = array[sep];
+          Parent::set(array.back(), sep);
+          array[sep] = array.back();
+          array.pop_back();
+        } else {
+          Parent::set(array.back(), pos);
+          array[pos] = array.back();
+          array.pop_back();
+        }
+      }
+      Parent::erase(keys);
+    }    
+
+    virtual void build() {
+      Parent::build();
+      for (KeyIt it(graph); it != INVALID; ++it) {
+        Parent::set(it, array.size());
+        array.push_back(it);
+      }
+      sep = 0;      
+    }
+
+    virtual void clear() {
+      array.clear();
+      sep = 0;
+      Parent::clear();
+    }
+    
+  };
+  
+
+  namespace _iterable_maps_bits {
+    template <typename Item>
+    struct IterableIntMapNode {
+      IterableIntMapNode() : value(-1) {}
+      IterableIntMapNode(int _value) : value(_value) {}
+      Item prev, next;
+      int value;
+    };
+  }
+
+  ///\ingroup graph_maps
+  ///
+  /// \brief Dynamic iterable integer map.
+  ///
+  /// This class provides a special graph map type which can store
+  /// for each graph item(node, edge, etc.) an integer value. For each
+  /// non negative value it is possible to iterate on the keys which
+  /// mapped to the given value.
+  /// 
+  /// \param _Graph The graph type.
+  /// \param _Item One of the graph's item type, the key of the map.
+  template <typename _Graph, typename _Item>
+  class IterableIntMap 
+    : protected MapExtender<DefaultMap<_Graph, _Item, _iterable_maps_bits::
+                                       IterableIntMapNode<_Item> > >{
+  public:
+    typedef MapExtender<DefaultMap<_Graph, _Item, _iterable_maps_bits::
+                                   IterableIntMapNode<_Item> > > Parent;
+
+    /// The key type
+    typedef _Item Key;
+    /// The value type
+    typedef int Value;
+    /// The graph type
+    typedef _Graph Graph;
+
+    /// \brief Constructor of the Map.
+    ///
+    /// Constructor of the Map. It set all values -1.
+    explicit IterableIntMap(const Graph& graph) 
+      : Parent(graph) {}
+
+    /// \brief Constructor of the Map with a given value.
+    ///
+    /// Constructor of the Map with a given value.
+    explicit IterableIntMap(const Graph& graph, int value) 
+      : Parent(graph, _iterable_maps_bits::IterableIntMapNode<_Item>(value)) {
+      if (value >= 0) {
+	for (typename Parent::ItemIt it(*this); it != INVALID; ++it) {
+	  lace(it);
+	}
+      }
+    }
+
+  private:
+    
+    void unlace(const Key& key) {
+      typename Parent::Value& node = Parent::operator[](key);
+      if (node.value < 0) return;
+      if (node.prev != INVALID) {
+	Parent::operator[](node.prev).next = node.next;	
+      } else {
+	first[node.value] = node.next;
+      }
+      if (node.next != INVALID) {
+	Parent::operator[](node.next).prev = node.prev;
+      }
+      while (!first.empty() && first.back() == INVALID) {
+	first.pop_back();
+      }
+    }
+
+    void lace(const Key& key) {
+      typename Parent::Value& node = Parent::operator[](key);
+      if (node.value < 0) return;
+      if (node.value >= int(first.size())) {
+	first.resize(node.value + 1, INVALID);
+      } 
+      node.prev = INVALID;
+      node.next = first[node.value];
+      if (node.next != INVALID) {
+	Parent::operator[](node.next).prev = key;	
+      }
+      first[node.value] = key;
+    }
+
+  public:
+
+    /// Indicates that the map if reference map.
+    typedef True ReferenceMapTag;
+
+    /// \brief Refernce to the value of the map.
+    ///
+    /// This class is near to similar to the int type. It can
+    /// be converted to int and it has the same operators.
+    class Reference {
+      friend class IterableIntMap;
+    private:
+      Reference(IterableIntMap& map, const Key& key) 
+	: _key(key), _map(map) {} 
+    public:
+
+      Reference& operator=(const Reference& value) {
+	_map.set(_key, static_cast<const int&>(value));
+ 	return *this;
+      }
+
+      operator const int&() const { 
+	return static_cast<const IterableIntMap&>(_map)[_key]; 
+      }
+
+      Reference& operator=(int value) { 
+	_map.set(_key, value); 
+	return *this; 
+      }
+      Reference& operator++() {
+	_map.set(_key, _map[_key] + 1); 
+	return *this; 	
+      }
+      int operator++(int) {
+	int value = _map[_key];
+	_map.set(_key, value + 1); 
+	return value; 	
+      }
+      Reference& operator--() {
+	_map.set(_key, _map[_key] - 1); 
+	return *this; 	
+      }
+      int operator--(int) {
+	int value = _map[_key];
+	_map.set(_key, value - 1); 
+	return value; 	
+      }
+      Reference& operator+=(int value) { 
+	_map.set(_key, _map[_key] + value); 
+	return *this;
+      }
+      Reference& operator-=(int value) { 
+	_map.set(_key, _map[_key] - value); 
+	return *this;
+      }
+      Reference& operator*=(int value) { 
+	_map.set(_key, _map[_key] * value); 
+	return *this;
+      }
+      Reference& operator/=(int value) { 
+	_map.set(_key, _map[_key] / value); 
+	return *this;
+      }
+      Reference& operator%=(int value) { 
+	_map.set(_key, _map[_key] % value); 
+	return *this;
+      }
+      Reference& operator&=(int value) { 
+	_map.set(_key, _map[_key] & value); 
+	return *this;
+      }
+      Reference& operator|=(int value) { 
+	_map.set(_key, _map[_key] | value); 
+	return *this;
+      }
+      Reference& operator^=(int value) { 
+	_map.set(_key, _map[_key] ^ value); 
+	return *this;
+      }
+      Reference& operator<<=(int value) { 
+	_map.set(_key, _map[_key] << value); 
+	return *this;
+      }
+      Reference& operator>>=(int value) { 
+	_map.set(_key, _map[_key] >> value); 
+	return *this;
+      }
+
+    private:
+      Key _key;
+      IterableIntMap& _map; 
+    };
+
+    /// The const reference type.    
+    typedef const Value& ConstReference;
+
+    /// \brief Gives back the maximal value plus one.
+    ///
+    /// Gives back the maximal value plus one.
+    unsigned int size() const {
+      return first.size();
+    }
+    
+    /// \brief Set operation of the map.
+    ///
+    /// Set operation of the map.
+    void set(const Key& key, const Value& value) {
+      unlace(key);
+      Parent::operator[](key).value = value;
+      lace(key);
+    }
+
+    /// \brief Const subscript operator of the map.
+    ///
+    /// Const subscript operator of the map.
+    const Value& operator[](const Key& key) const {
+      return Parent::operator[](key).value;
+    }
+
+    /// \brief Subscript operator of the map.
+    ///
+    /// Subscript operator of the map.
+    Reference operator[](const Key& key) {
+      return Reference(*this, key);
+    }
+
+    /// \brief Iterator for the keys with the same value.
+    ///
+    /// Iterator for the keys with the same value. It works
+    /// like a graph item iterator in the map, it can be converted
+    /// the item type of the map, incremented with \c ++ operator, and
+    /// if the iterator leave the last valid item it will be equal to 
+    /// \c INVALID.
+    class ItemIt : public _Item {
+    public:
+      typedef _Item Parent;
+
+      /// \brief Invalid constructor \& conversion.
+      ///
+      /// This constructor initializes the item to be invalid.
+      /// \sa Invalid for more details.
+      ItemIt(Invalid) : Parent(INVALID), _map(0) {}
+
+      /// \brief Creates an iterator with a value.
+      ///
+      /// Creates an iterator with a value. It iterates on the 
+      /// keys which have the given value.
+      /// \param map The IterableIntMap
+      /// \param value The value
+      ItemIt(const IterableIntMap& map, int value) : _map(&map) {
+	if (value < 0 || value >= int(_map->first.size())) {	  
+	  Parent::operator=(INVALID);
+	} else {
+	  Parent::operator=(_map->first[value]);
+	}
+      } 
+
+      /// \brief Increment operator.
+      ///
+      /// Increment Operator.
+      ItemIt& operator++() {
+	Parent::operator=(_map->IterableIntMap::Parent::
+			  operator[](static_cast<Parent&>(*this)).next);
+	return *this;
+      }
+
+
+    private:
+      const IterableIntMap* _map;
+    };
+
+  protected:
+    
+    virtual void erase(const Key& key) {
+      unlace(key);
+      Parent::erase(key);
+    }
+
+    virtual void erase(const std::vector<Key>& keys) {
+      for (int i = 0; i < int(keys.size()); ++i) {
+        unlace(keys[i]);
+      }
+      Parent::erase(keys);
+    }
+
+    virtual void clear() {
+      first.clear();
+      Parent::clear();
+    }
+
+  private:
+    std::vector<_Item> first;
+  };
+
+  namespace _iterable_maps_bits {
+    template <typename Item, typename Value>
+    struct IterableValueMapNode {
+      IterableValueMapNode(Value _value = Value()) : value(_value) {}
+      Item prev, next;
+      Value value;
+    };
+  }
+
+  ///\ingroup graph_maps
+  ///
+  /// \brief Dynamic iterable map for comparable values.
+  ///
+  /// This class provides a special graph map type which can store
+  /// for each graph item(node, edge, etc.) a value. For each
+  /// value it is possible to iterate on the keys which mapped to the 
+  /// given value. The type stores for each value a linked list with
+  /// the items which mapped to the value, and the values are stored
+  /// in balanced binary tree. The values of the map can be accessed
+  /// with stl compatible forward iterator.
+  ///
+  /// This type is not reference map so it cannot be modified with
+  /// the subscription operator.
+  ///
+  /// \see InvertableMap
+  /// 
+  /// \param _Graph The graph type.
+  /// \param _Item One of the graph's item type, the key of the map.
+  /// \param _Value Any comparable value type.
+  template <typename _Graph, typename _Item, typename _Value>
+  class IterableValueMap 
+    : protected MapExtender<DefaultMap<_Graph, _Item, _iterable_maps_bits::
+                                       IterableValueMapNode<_Item, _Value> > >{
+  public:
+    typedef MapExtender<DefaultMap<_Graph, _Item, _iterable_maps_bits::
+                                   IterableValueMapNode<_Item, _Value> > >
+    Parent;
+
+    /// The key type
+    typedef _Item Key;
+    /// The value type
+    typedef _Value Value;
+    /// The graph type
+    typedef _Graph Graph;
+
+  public:
+
+    /// \brief Constructor of the Map with a given value.
+    ///
+    /// Constructor of the Map with a given value.
+    explicit IterableValueMap(const Graph& graph, 
+                              const Value& value = Value()) 
+      : Parent(graph, _iterable_maps_bits::
+               IterableValueMapNode<_Item, _Value>(value)) {
+      for (typename Parent::ItemIt it(*this); it != INVALID; ++it) {
+        lace(it);
+      }
+    }
+
+  protected:
+    
+    void unlace(const Key& key) {
+      typename Parent::Value& node = Parent::operator[](key);
+      if (node.prev != INVALID) {
+	Parent::operator[](node.prev).next = node.next;	
+      } else {
+        if (node.next != INVALID) {
+          first[node.value] = node.next;
+        } else {
+          first.erase(node.value);
+        }
+      }
+      if (node.next != INVALID) {
+	Parent::operator[](node.next).prev = node.prev;
+      }
+    }
+
+    void lace(const Key& key) {
+      typename Parent::Value& node = Parent::operator[](key);
+      typename std::map<Value, Key>::iterator it = first.find(node.value);
+      if (it == first.end()) {
+        node.prev = node.next = INVALID;
+        if (node.next != INVALID) {
+          Parent::operator[](node.next).prev = key;	
+        }
+        first.insert(make_pair(node.value, key));
+      } else {
+        node.prev = INVALID;
+        node.next = it->second;
+        if (node.next != INVALID) {
+          Parent::operator[](node.next).prev = key;	
+        }
+        it->second = key;
+      }
+    }
+
+  public:
+
+    /// \brief Forward iterator for values.
+    ///
+    /// This iterator is an stl compatible forward
+    /// iterator on the values of the map. The values can
+    /// be accessed in the [beginValue, endValue) range.
+    ///
+    class ValueIterator 
+      : public std::iterator<std::forward_iterator_tag, Value> {
+      friend class IterableValueMap;
+    private:
+      ValueIterator(typename std::map<Value, Key>::const_iterator _it) 
+        : it(_it) {}
+    public:
+      
+      ValueIterator() {}
+
+      ValueIterator& operator++() { ++it; return *this; }
+      ValueIterator operator++(int) { 
+        ValueIterator tmp(*this); 
+        operator++();
+        return tmp; 
+      }
+
+      const Value& operator*() const { return it->first; }
+      const Value* operator->() const { return &(it->first); }
+
+      bool operator==(ValueIterator jt) const { return it == jt.it; }
+      bool operator!=(ValueIterator jt) const { return it != jt.it; }
+      
+    private:
+      typename std::map<Value, Key>::const_iterator it;
+    };
+
+    /// \brief Returns an iterator to the first value.
+    ///
+    /// Returns an stl compatible iterator to the 
+    /// first value of the map. The values of the
+    /// map can be accessed in the [beginValue, endValue)
+    /// range.
+    ValueIterator beginValue() const {
+      return ValueIterator(first.begin());
+    }
+
+    /// \brief Returns an iterator after the last value.
+    ///
+    /// Returns an stl compatible iterator after the 
+    /// last value of the map. The values of the
+    /// map can be accessed in the [beginValue, endValue)
+    /// range.
+    ValueIterator endValue() const {
+      return ValueIterator(first.end());
+    }
+
+    /// \brief Set operation of the map.
+    ///
+    /// Set operation of the map.
+    void set(const Key& key, const Value& value) {
+      unlace(key);
+      Parent::operator[](key).value = value;
+      lace(key);
+    }
+
+    /// \brief Const subscript operator of the map.
+    ///
+    /// Const subscript operator of the map.
+    const Value& operator[](const Key& key) const {
+      return Parent::operator[](key).value;
+    }
+
+    /// \brief Iterator for the keys with the same value.
+    ///
+    /// Iterator for the keys with the same value. It works
+    /// like a graph item iterator in the map, it can be converted
+    /// the item type of the map, incremented with \c ++ operator, and
+    /// if the iterator leave the last valid item it will be equal to 
+    /// \c INVALID.
+    class ItemIt : public _Item {
+    public:
+      typedef _Item Parent;
+
+      /// \brief Invalid constructor \& conversion.
+      ///
+      /// This constructor initializes the item to be invalid.
+      /// \sa Invalid for more details.
+      ItemIt(Invalid) : Parent(INVALID), _map(0) {}
+
+      /// \brief Creates an iterator with a value.
+      ///
+      /// Creates an iterator with a value. It iterates on the 
+      /// keys which have the given value.
+      /// \param map The IterableValueMap
+      /// \param value The value
+      ItemIt(const IterableValueMap& map, const Value& value) : _map(&map) {
+        typename std::map<Value, Key>::const_iterator it = 
+          map.first.find(value); 
+	if (it == map.first.end()) {	  
+	  Parent::operator=(INVALID);
+	} else {
+	  Parent::operator=(it->second);
+	}
+      } 
+
+      /// \brief Increment operator.
+      ///
+      /// Increment Operator.
+      ItemIt& operator++() {
+	Parent::operator=(_map->IterableValueMap::Parent::
+			  operator[](static_cast<Parent&>(*this)).next);
+	return *this;
+      }
+
+
+    private:
+      const IterableValueMap* _map;
+    };
+
+  protected:
+    
+    virtual void add(const Key& key) {
+      Parent::add(key);
+      unlace(key);
+    }
+
+    virtual void add(const std::vector<Key>& keys) {
+      Parent::add(keys);
+      for (int i = 0; i < int(keys.size()); ++i) {
+        lace(keys[i]);
+      }
+    }
+
+    virtual void erase(const Key& key) {
+      unlace(key);
+      Parent::erase(key);
+    }
+
+    virtual void erase(const std::vector<Key>& keys) {
+      for (int i = 0; i < int(keys.size()); ++i) {
+        unlace(keys[i]);
+      }
+      Parent::erase(keys);
+    }
+
+    virtual void build() {
+      Parent::build();
+      for (typename Parent::ItemIt it(*this); it != INVALID; ++it) {
+        lace(it);
+      }
+    }
+
+    virtual void clear() {
+      first.clear();
+      Parent::clear();
+    }
+
+  private:
+    std::map<Value, Key> first;
+  };
+
+  /// @}
+}
+
+#endif
Index: lemon/johnson.h
===================================================================
--- lemon/johnson.h	(revision 2553)
+++ lemon/johnson.h	(revision 2553)
@@ -0,0 +1,709 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_JOHNSON_H
+#define LEMON_JOHNSON_H
+
+///\ingroup shortest_path
+/// \file
+/// \brief Johnson algorithm.
+///
+
+#include <lemon/list_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/dijkstra.h>
+#include <lemon/bellman_ford.h>
+#include <lemon/bits/path_dump.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+#include <lemon/matrix_maps.h>
+
+#include <limits>
+
+namespace lemon {
+
+  /// \brief Default OperationTraits for the Johnson algorithm class.
+  ///  
+  /// It defines all computational operations and constants which are
+  /// used in the Floyd-Warshall algorithm. The default implementation
+  /// is based on the numeric_limits class. If the numeric type does not
+  /// have infinity value then the maximum value is used as extremal
+  /// infinity value.
+  template <
+    typename Value, 
+    bool has_infinity = std::numeric_limits<Value>::has_infinity>
+  struct JohnsonDefaultOperationTraits {
+    /// \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 true only if the first value less than the second.
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+
+  template <typename Value>
+  struct JohnsonDefaultOperationTraits<Value, false> {
+    static Value zero() {
+      return static_cast<Value>(0);
+    }
+    static Value infinity() {
+      return std::numeric_limits<Value>::max();
+    }
+    static Value plus(const Value& left, const Value& right) {
+      if (left == infinity() || right == infinity()) return infinity();
+      return left + right;
+    }
+    static bool less(const Value& left, const Value& right) {
+      return left < right;
+    }
+  };
+  
+  /// \brief Default traits class of Johnson class.
+  ///
+  /// Default traits class of Johnson class.
+  /// \param _Graph Graph type.
+  /// \param _LegthMap Type of length map.
+  template<class _Graph, class _LengthMap>
+  struct JohnsonDefaultTraits {
+    /// The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge lengths.
+    ///
+    /// The type of the map that stores the edge lengths.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _LengthMap LengthMap;
+
+    // The type of the length of the edges.
+    typedef typename _LengthMap::Value Value;
+
+    /// \brief Operation traits for bellman-ford algorithm.
+    ///
+    /// It defines the infinity type on the given Value type
+    /// and the used operation.
+    /// \see JohnsonDefaultOperationTraits
+    typedef JohnsonDefaultOperationTraits<Value> OperationTraits;
+
+    /// The cross reference type used by heap.
+
+    /// The cross reference type used by heap.
+    /// Usually it is \c Graph::NodeMap<int>.
+    typedef typename Graph::template NodeMap<int> HeapCrossRef;
+
+    ///Instantiates a HeapCrossRef.
+
+    ///This function instantiates a \ref HeapCrossRef. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// HeapCrossRef.
+    static HeapCrossRef *createHeapCrossRef(const Graph& graph) {
+      return new HeapCrossRef(graph);
+    }
+    
+    ///The heap type used by Dijkstra algorithm.
+
+    ///The heap type used by Dijkstra algorithm.
+    ///
+    ///\sa BinHeap
+    ///\sa Dijkstra
+    typedef BinHeap<typename LengthMap::Value,
+		    HeapCrossRef, std::less<Value> > Heap;
+
+    ///Instantiates a Heap.
+
+    ///This function instantiates a \ref Heap. 
+    /// \param crossRef The cross reference for the heap.
+    static Heap *createHeap(HeapCrossRef& crossRef) {
+      return new Heap(crossRef);
+    }
+ 
+    /// \brief The type of the matrix map that stores the last edges of the 
+    /// shortest paths.
+    /// 
+    /// The type of the map that stores the last edges of the shortest paths.
+    /// It must be a matrix map with \c Graph::Edge value type.
+    ///
+    typedef DynamicMatrixMap<Graph, typename Graph::Node, 
+			     typename Graph::Edge> PredMap;
+
+    /// \brief Instantiates a PredMap.
+    /// 
+    /// This function instantiates a \ref PredMap. 
+    /// \param graph is the graph, to which we would like to define the PredMap.
+    /// \todo The graph alone may be insufficient for the initialization
+    static PredMap *createPredMap(const Graph& graph) {
+      return new PredMap(graph);
+    }
+
+    /// \brief The type of the matrix map that stores the dists of the nodes.
+    ///
+    /// The type of the matrix map that stores the dists of the nodes.
+    /// It must meet the \ref concepts::WriteMatrixMap "WriteMatrixMap" concept.
+    ///
+    typedef DynamicMatrixMap<Graph, typename Graph::Node, Value> DistMap;
+    
+    /// \brief Instantiates a DistMap.
+    ///
+    /// This function instantiates a \ref DistMap. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// \ref DistMap
+    static DistMap *createDistMap(const _Graph& graph) {
+      return new DistMap(graph);
+    }
+
+  };
+
+  /// \brief %Johnson algorithm class.
+  ///
+  /// \ingroup shortest_path
+  /// This class provides an efficient implementation of \c %Johnson 
+  /// algorithm. The edge lengths are passed to the algorithm using a
+  /// \ref concepts::ReadMap "ReadMap", so it is easy to change it to any 
+  /// kind of length.
+  ///
+  /// The algorithm solves the shortest path problem for each pair
+  /// of node when the edges can have negative length but the graph should
+  /// not contain cycles with negative sum of length. If we can assume
+  /// that all edge is non-negative in the graph then the dijkstra algorithm
+  /// should be used from each node.
+  ///
+  /// The complexity of this algorithm is \f$ O(n^2\log(n)+n\log(n)e) \f$ or
+  /// with fibonacci heap \f$ O(n^2\log(n)+ne) \f$. Usually the fibonacci heap
+  /// implementation is slower than either binary heap implementation or the 
+  /// Floyd-Warshall algorithm. 
+  ///
+  /// The type of the length is determined by the
+  /// \ref concepts::ReadMap::Value "Value" of the length map.
+  ///
+  /// \param _Graph The graph type the algorithm runs on. The default value
+  /// is \ref ListGraph. The value of _Graph is not used directly by
+  /// Johnson, it is only passed to \ref JohnsonDefaultTraits.
+  /// \param _LengthMap This read-only EdgeMap determines the lengths of the
+  /// edges. It is read once for each edge, so the map may involve in
+  /// relatively time consuming process to compute the edge length if
+  /// it is necessary. The default map type is \ref
+  /// concepts::Graph::EdgeMap "Graph::EdgeMap<int>".  The value
+  /// of _LengthMap is not used directly by Johnson, it is only passed 
+  /// to \ref JohnsonDefaultTraits.  \param _Traits Traits class to set
+  /// various data types used by the algorithm.  The default traits
+  /// class is \ref JohnsonDefaultTraits
+  /// "JohnsonDefaultTraits<_Graph,_LengthMap>".  See \ref
+  /// JohnsonDefaultTraits for the documentation of a Johnson traits
+  /// class.
+  ///
+  /// \author Balazs Dezso
+
+#ifdef DOXYGEN
+  template <typename _Graph, typename _LengthMap, typename _Traits>
+#else
+  template <typename _Graph=ListGraph,
+	    typename _LengthMap=typename _Graph::template EdgeMap<int>,
+	    typename _Traits=JohnsonDefaultTraits<_Graph,_LengthMap> >
+#endif
+  class Johnson {
+  public:
+    
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::Johnson::UninitializedParameter";
+      }
+    };
+
+    typedef _Traits Traits;
+    ///The type of the underlying graph.
+    typedef typename _Traits::Graph Graph;
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::EdgeIt EdgeIt;
+    
+    /// \brief The type of the length of the edges.
+    typedef typename _Traits::LengthMap::Value Value;
+    /// \brief The type of the map that stores the edge lengths.
+    typedef typename _Traits::LengthMap LengthMap;
+    /// \brief The type of the map that stores the last
+    /// edges of the shortest paths. The type of the PredMap
+    /// is a matrix map for Edges
+    typedef typename _Traits::PredMap PredMap;
+    /// \brief The type of the map that stores the dists of the nodes.
+    /// The type of the DistMap is a matrix map for Values
+    typedef typename _Traits::DistMap DistMap;
+    /// \brief The operation traits.
+    typedef typename _Traits::OperationTraits OperationTraits;
+    ///The cross reference type used for the current heap.
+    typedef typename _Traits::HeapCrossRef HeapCrossRef;
+    ///The heap type used by the dijkstra algorithm.
+    typedef typename _Traits::Heap Heap;
+  private:
+    /// Pointer to the underlying graph.
+    const Graph *graph;
+    /// Pointer to the length map
+    const LengthMap *length;
+    ///Pointer to the map of predecessors edges.
+    PredMap *_pred;
+    ///Indicates if \ref _pred is locally allocated (\c true) or not.
+    bool local_pred;
+    ///Pointer to the map of distances.
+    DistMap *_dist;
+    ///Indicates if \ref _dist is locally allocated (\c true) or not.
+    bool local_dist;
+    ///Pointer to the heap cross references.
+    HeapCrossRef *_heap_cross_ref;
+    ///Indicates if \ref _heap_cross_ref is locally allocated (\c true) or not.
+    bool local_heap_cross_ref;
+    ///Pointer to the heap.
+    Heap *_heap;
+    ///Indicates if \ref _heap is locally allocated (\c true) or not.
+    bool local_heap;
+
+    /// Creates the maps if necessary.
+    void create_maps() {
+      if(!_pred) {
+	local_pred = true;
+	_pred = Traits::createPredMap(*graph);
+      }
+      if(!_dist) {
+	local_dist = true;
+	_dist = Traits::createDistMap(*graph);
+      }
+      if (!_heap_cross_ref) {
+	local_heap_cross_ref = true;
+	_heap_cross_ref = Traits::createHeapCrossRef(*graph);
+      }
+      if (!_heap) {
+	local_heap = true;
+	_heap = Traits::createHeap(*_heap_cross_ref);
+      }
+    }
+
+  public :
+
+    /// \name Named template parameters
+
+    ///@{
+
+    template <class T>
+    struct DefPredMapTraits : public Traits {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph& graph) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting PredMap 
+    /// type
+    /// \ref named-templ-param "Named parameter" for setting PredMap type
+    ///
+    template <class T>
+    struct DefPredMap 
+      : public Johnson< Graph, LengthMap, DefPredMapTraits<T> > {
+      typedef Johnson< Graph, LengthMap, DefPredMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefDistMapTraits : public Traits {
+      typedef T DistMap;
+      static DistMap *createDistMap(const Graph& graph) {
+	throw UninitializedParameter();
+      }
+    };
+    /// \brief \ref named-templ-param "Named parameter" for setting DistMap 
+    /// type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting DistMap type
+    ///
+    template <class T>
+    struct DefDistMap 
+      : public Johnson< Graph, LengthMap, DefDistMapTraits<T> > {
+      typedef Johnson< Graph, LengthMap, DefDistMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefOperationTraitsTraits : public Traits {
+      typedef T OperationTraits;
+    };
+    
+    /// \brief \ref named-templ-param "Named parameter" for setting 
+    /// OperationTraits type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting 
+    /// OperationTraits type
+    template <class T>
+    struct DefOperationTraits
+      : public Johnson< Graph, LengthMap, DefOperationTraitsTraits<T> > {
+      typedef Johnson< Graph, LengthMap, DefOperationTraitsTraits<T> > Create;
+    };
+
+    template <class H, class CR>
+    struct DefHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const Graph &) {
+	throw UninitializedParameter();
+      }
+      static Heap *createHeap(HeapCrossRef &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting heap and 
+    ///cross reference type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting heap and cross 
+    ///reference type
+    ///
+    template <class H, class CR = typename Graph::template NodeMap<int> >
+    struct DefHeap
+      : public Johnson< Graph, LengthMap, DefHeapTraits<H, CR> > { 
+      typedef Johnson< Graph, LengthMap, DefHeapTraits<H, CR> > Create;
+    };
+
+    template <class H, class CR>
+    struct DefStandardHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const Graph &G) {
+	return new HeapCrossRef(G);
+      }
+      static Heap *createHeap(HeapCrossRef &R) 
+      {
+	return new Heap(R);
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///heap and cross reference type with automatic allocation
+    ///
+    ///\ref named-templ-param "Named parameter" for setting heap and cross 
+    ///reference type. It can allocate the heap and the cross reference 
+    ///object if the cross reference's constructor waits for the graph as 
+    ///parameter and the heap's constructor waits for the cross reference.
+    template <class H, class CR = typename Graph::template NodeMap<int> >
+    struct DefStandardHeap
+      : public Johnson< Graph, LengthMap, DefStandardHeapTraits<H, CR> > { 
+      typedef Johnson< Graph, LengthMap, DefStandardHeapTraits<H, CR> > 
+      Create;
+    };
+    
+    ///@}
+
+  protected:
+
+    Johnson() {}
+
+  public:      
+
+    typedef Johnson Create;
+    
+    /// \brief Constructor.
+    ///
+    /// \param _graph the graph the algorithm will run on.
+    /// \param _length the length map used by the algorithm.
+    Johnson(const Graph& _graph, const LengthMap& _length) :
+      graph(&_graph), length(&_length),
+      _pred(0), local_pred(false),
+      _dist(0), local_dist(false),
+      _heap_cross_ref(0), local_heap_cross_ref(false),
+      _heap(0), local_heap(false) {}
+    
+    ///Destructor.
+    ~Johnson() {
+      if (local_pred) delete _pred;
+      if (local_dist) delete _dist;
+      if (local_heap_cross_ref) delete _heap_cross_ref;
+      if (local_heap) delete _heap;
+    }
+
+    /// \brief Sets the length map.
+    ///
+    /// Sets the length map.
+    /// \return \c (*this)
+    Johnson &lengthMap(const LengthMap &m) {
+      length = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the predecessor edges.
+    ///
+    /// Sets the map storing the predecessor edges.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    Johnson &predMap(PredMap &m) {
+      if(local_pred) {
+	delete _pred;
+	local_pred=false;
+      }
+      _pred = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the distances calculated by the algorithm.
+    ///
+    /// Sets the map storing the distances calculated by the algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c (*this)
+    Johnson &distMap(DistMap &m) {
+      if(local_dist) {
+	delete _dist;
+	local_dist=false;
+      }
+      _dist = &m;
+      return *this;
+    }
+
+  public:    
+
+    ///\name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run(...).
+    /// \n
+    /// If you need more control on the execution,
+    /// Finally \ref start() will perform the actual path
+    /// computation.
+
+    ///@{
+
+    /// \brief Initializes the internal data structures.
+    /// 
+    /// Initializes the internal data structures.
+    void init() {
+      create_maps();
+    }
+
+    /// \brief Executes the algorithm with own potential map.
+    ///
+    /// This method runs the %Johnson algorithm in order to compute 
+    /// the shortest path to each node pairs. The potential map
+    /// can be given for this algorithm which usually calculated
+    /// by the Bellman-Ford algorithm. If the graph does not have
+    /// negative length edge then this start function can be used
+    /// with constMap<Node, int>(0) parameter to omit the running time of
+    /// the Bellman-Ford. 
+    /// The algorithm computes 
+    /// - The shortest path tree for each node.
+    /// - The distance between each node pairs.
+    template <typename PotentialMap>
+    void shiftedStart(const PotentialMap& potential) {      
+      typename Graph::template EdgeMap<Value> shiftlen(*graph);
+      for (EdgeIt it(*graph);  it != INVALID; ++it) {
+      	shiftlen[it] = (*length)[it] 
+	  + potential[graph->source(it)] 
+	  - potential[graph->target(it)];
+      }
+      
+      typename Dijkstra<Graph, typename Graph::template EdgeMap<Value> >::
+	template DefHeap<Heap, HeapCrossRef>::
+	Create dijkstra(*graph, shiftlen);
+
+      dijkstra.heap(*_heap, *_heap_cross_ref);
+      
+      for (NodeIt it(*graph); it != INVALID; ++it) {
+	dijkstra.run(it);
+	for (NodeIt jt(*graph); jt != INVALID; ++jt) {
+	  if (dijkstra.reached(jt)) {
+	    _dist->set(it, jt, dijkstra.dist(jt) + 
+		       potential[jt] - potential[it]);
+	    _pred->set(it, jt, dijkstra.predEdge(jt));
+	  } else {
+	    _dist->set(it, jt, OperationTraits::infinity());
+	    _pred->set(it, jt, INVALID);
+	  }
+	}
+      }
+    }
+
+    /// \brief Executes the algorithm.
+    ///
+    /// This method runs the %Johnson algorithm in order to compute 
+    /// the shortest path to each node pairs. The algorithm 
+    /// computes 
+    /// - The shortest path tree for each node.
+    /// - The distance between each node pairs.
+    void start() {
+
+      typedef typename BellmanFord<Graph, LengthMap>::
+      template DefOperationTraits<OperationTraits>::
+      template DefPredMap<NullMap<Node, Edge> >::
+      Create BellmanFordType;
+      
+      BellmanFordType bellmanford(*graph, *length);
+
+      NullMap<Node, Edge> pm;
+
+      bellmanford.predMap(pm);
+      
+      bellmanford.init(OperationTraits::zero());
+      bellmanford.start();
+
+      shiftedStart(bellmanford.distMap());
+    }
+
+    /// \brief Executes the algorithm and checks the negatvie cycles.
+    ///
+    /// This method runs the %Johnson algorithm in order to compute 
+    /// the shortest path to each node pairs. If the graph contains
+    /// negative cycle it gives back false. The algorithm 
+    /// computes 
+    /// - The shortest path tree for each node.
+    /// - The distance between each node pairs.
+    bool checkedStart() {
+      
+      typedef typename BellmanFord<Graph, LengthMap>::
+      template DefOperationTraits<OperationTraits>::
+      template DefPredMap<NullMap<Node, Edge> >::
+      Create BellmanFordType;
+
+      BellmanFordType bellmanford(*graph, *length);
+
+      NullMap<Node, Edge> pm;
+
+      bellmanford.predMap(pm);
+      
+      bellmanford.init(OperationTraits::zero());
+      if (!bellmanford.checkedStart()) return false;
+
+      shiftedStart(bellmanford.distMap());
+      return true;
+    }
+
+    
+    /// \brief Runs %Johnson algorithm.
+    ///    
+    /// This method runs the %Johnson algorithm from a each node
+    /// in order to compute the shortest path to each node pairs. 
+    /// The algorithm computes
+    /// - The shortest path tree for each node.
+    /// - The distance between each node pairs.
+    ///
+    /// \note d.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.start();
+    ///\endcode
+    void run() {
+      init();
+      start();
+    }
+    
+    ///@}
+
+    /// \name Query Functions
+    /// The result of the %Johnson algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    typedef PredMatrixMapPath<Graph, PredMap> Path;
+
+    ///Gives back the shortest path.
+    
+    ///Gives back the shortest path.
+    ///\pre The \c t should be reachable from the \c t.
+    Path path(Node s, Node t) 
+    {
+      return Path(*graph, *_pred, s, t);
+    }
+	  
+    /// \brief The distance between two nodes.
+    ///
+    /// Returns the distance between two nodes.
+    /// \pre \ref run() must be called before using this function.
+    /// \warning If node \c v in unreachable from the root the return value
+    /// of this funcion is undefined.
+    Value dist(Node source, Node target) const { 
+      return (*_dist)(source, target); 
+    }
+
+    /// \brief Returns the 'previous edge' of the shortest path tree.
+    ///
+    /// For the node \c node it returns the 'previous edge' of the shortest 
+    /// path tree to direction of the node \c root 
+    /// i.e. it returns the last edge of a shortest path from the node \c root 
+    /// to \c node. It is \ref INVALID if \c node is unreachable from the root
+    /// or if \c node=root. The shortest path tree used here is equal to the 
+    /// shortest path tree used in \ref predNode(). 
+    /// \pre \ref run() must be called before using this function.
+    Edge predEdge(Node root, Node node) const { 
+      return (*_pred)(root, node); 
+    }
+
+    /// \brief Returns the 'previous node' of the shortest path tree.
+    ///
+    /// For a node \c node it returns the 'previous node' of the shortest path 
+    /// tree to direction of the node \c root, i.e. it returns the last but 
+    /// one node from a shortest path from the \c root to \c node. It is 
+    /// INVALID if \c node is unreachable from the root or if \c node=root. 
+    /// The shortest path tree used here is equal to the 
+    /// shortest path tree used in \ref predEdge().  
+    /// \pre \ref run() must be called before using this function.
+    Node predNode(Node root, Node node) const { 
+      return (*_pred)(root, node) == INVALID ? 
+      INVALID : graph->source((*_pred)(root, node)); 
+    }
+    
+    /// \brief Returns a reference to the matrix node map of distances.
+    ///
+    /// Returns a reference to the matrix node map of distances. 
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const DistMap &distMap() const { return *_dist;}
+ 
+    /// \brief Returns a reference to the shortest path tree map.
+    ///
+    /// Returns a reference to the matrix node map of the edges of the
+    /// shortest path tree.
+    /// \pre \ref run() must be called before using this function.
+    const PredMap &predMap() const { return *_pred;}
+ 
+    /// \brief Checks if a node is reachable from the root.
+    ///
+    /// Returns \c true if \c v is reachable from the root.
+    /// \pre \ref run() must be called before using this function.
+    ///
+    bool connected(Node source, Node target) { 
+      return (*_dist)(source, target) != OperationTraits::infinity(); 
+    }
+    
+    ///@}
+  };
+ 
+} //END OF NAMESPACE LEMON
+
+#endif
Index: lemon/kruskal.h
===================================================================
--- lemon/kruskal.h	(revision 2554)
+++ lemon/kruskal.h	(revision 2554)
@@ -0,0 +1,676 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_KRUSKAL_H
+#define LEMON_KRUSKAL_H
+
+#include <algorithm>
+#include <vector>
+#include <lemon/unionfind.h>
+#include <lemon/graph_utils.h>
+#include <lemon/maps.h>
+
+#include <lemon/radix_sort.h>
+
+#include <lemon/bits/utility.h>
+#include <lemon/bits/traits.h>
+
+///\ingroup spantree
+///\file
+///\brief Kruskal's algorithm to compute a minimum cost tree
+///
+///Kruskal's algorithm to compute a minimum cost tree.
+///
+
+namespace lemon {
+
+  namespace _kruskal_bits {
+
+    template <typename Map, typename Comp>
+    struct MappedComp {
+
+      typedef typename Map::Key Key;
+
+      const Map& map;
+      Comp comp;
+
+      MappedComp(const Map& _map) 
+        : map(_map), comp() {}
+
+      bool operator()(const Key& left, const Key& right) {
+        return comp(map[left], map[right]);
+      }
+
+    };
+  
+  }
+
+  /// \brief Default traits class of Kruskal class.
+  ///
+  /// Default traits class of Kruskal class.
+  /// \param _UGraph Undirected graph type.
+  /// \param _CostMap Type of cost map.
+  template <typename _UGraph, typename _CostMap>
+  struct KruskalDefaultTraits{
+
+    /// \brief The graph type the algorithm runs on. 
+    typedef _UGraph UGraph;
+
+    /// \brief The type of the map that stores the edge costs.
+    ///
+    /// The type of the map that stores the edge costs.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _CostMap CostMap;
+
+    /// \brief The type of the cost of the edges.
+    typedef typename _CostMap::Value Value;
+
+    /// \brief The type of the map that stores whether an edge is in the
+    /// spanning tree or not.
+    ///
+    /// The type of the map that stores whether an edge is in the
+    /// spanning tree or not.
+    typedef typename _UGraph::template UEdgeMap<bool> TreeMap;
+
+    /// \brief Instantiates a TreeMap.
+    ///
+    /// This function instantiates a \ref TreeMap.
+    ///
+    /// The first parameter is the graph, to which
+    /// we would like to define the \ref TreeMap
+    static TreeMap *createTreeMap(const _UGraph& graph){
+      return new TreeMap(graph);
+    }
+
+    template <typename Iterator>
+    static void sort(Iterator begin, Iterator end, const CostMap& cost) {
+      _kruskal_bits::MappedComp<CostMap, std::less<Value> > comp(cost);
+      std::sort(begin, end, comp);
+    }
+
+  };
+
+  ///\ingroup spantree
+  ///
+  /// \brief Kruskal's algorithm to find a minimum cost tree of a graph.
+  ///
+  /// This class implements Kruskal's algorithm to find a minimum cost
+  /// spanning tree. The 
+  ///
+  /// \param _UGraph Undirected graph type.
+  /// \param _CostMap Type of cost map.
+  template <typename _UGraph, typename _CostMap,
+            typename _Traits = KruskalDefaultTraits<_UGraph, _CostMap> >
+  class Kruskal {
+  public:
+
+    typedef _Traits Traits;
+
+    typedef typename _Traits::UGraph UGraph;
+    typedef typename _Traits::CostMap CostMap;
+
+    typedef typename _Traits::TreeMap TreeMap;
+
+    typedef typename _Traits::Value Value;
+
+    template <typename Comp>
+    struct DefSortCompareTraits : public Traits {
+      template <typename Iterator>
+      static void sort(Iterator begin, Iterator end, const CostMap& cost) {
+        _kruskal_bits::MappedComp<CostMap, Comp> comp(cost, Comp());
+        std::sort(begin, end, comp);
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting the
+    /// comparator object of the standard sort
+    ///
+    /// \ref named-templ-param "Named parameter" for setting the
+    /// comparator object of the standard sort
+    template <typename Comp>
+    struct DefSortCompare
+      : public Kruskal<UGraph, CostMap, DefSortCompareTraits<Comp> > {
+      typedef Kruskal<UGraph, CostMap, DefSortCompareTraits<Comp> > Create;
+    };    
+
+    struct DefRadixSortTraits : public Traits {
+      template <typename Iterator>
+      static void sort(Iterator begin, Iterator end, const CostMap& cost) {
+        radixSort(begin, end, cost);
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting the
+    /// sort function to radix sort
+    ///
+    /// \brief \ref named-templ-param "Named parameter" for setting the
+    /// sort function to radix sort. The value type of the cost map should
+    /// be integral, of course. 
+    struct DefRadixSort
+      : public Kruskal<UGraph, CostMap, DefRadixSortTraits> {
+      typedef Kruskal<UGraph, CostMap, DefRadixSortTraits> Create;
+    };    
+
+    template <class TM>
+    struct DefTreeMapTraits : public Traits {
+      typedef TM TreeMap;
+      static TreeMap *createTreeMap(const UGraph &) {
+        throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// TreeMap
+    ///
+    /// \ref named-templ-param "Named parameter" for setting TreeMap
+    ///
+    template <class TM>
+    struct DefTreeMap
+      : public Kruskal< UGraph, CostMap, DefTreeMapTraits<TM> > {
+      typedef Kruskal< UGraph, CostMap, DefTreeMapTraits<TM> > Create;
+    };    
+    
+
+  private:
+
+    typedef typename UGraph::Node Node;
+    typedef typename UGraph::NodeIt NodeIt;
+
+    typedef typename UGraph::UEdge UEdge;
+    typedef typename UGraph::UEdgeIt UEdgeIt;
+
+    const UGraph& graph;
+    const CostMap& cost;
+    
+    std::vector<UEdge> edges;
+    
+    typedef typename UGraph::template NodeMap<int> UfIndex;
+    typedef UnionFind<UfIndex> Uf;
+    UfIndex *ufi;
+    Uf *uf;
+
+    int index;
+
+    void initStructures() {
+      if (!_tree) {
+        _tree = Traits::createTreeMap(graph);
+        local_tree = true;
+      }
+      if (!uf) {
+        ufi = new typename UGraph::template NodeMap<int>(graph);
+        uf = new UnionFind<typename UGraph::template NodeMap<int> >(*ufi);
+      }
+    }
+    
+    void initUnionFind() {
+      uf->clear();
+      for (NodeIt it(graph); it != INVALID; ++it) {
+        uf->insert(it);
+      }
+    }
+
+    bool local_tree;
+    TreeMap* _tree;
+
+  public:
+
+    /// \brief Constructor
+    ///
+    /// Constructor of the algorithm.
+    Kruskal(const UGraph& _graph, const CostMap& _cost) 
+      : graph(_graph), cost(_cost),
+        ufi(0), uf(0), local_tree(false), _tree(0) {}
+
+    /// \brief Destructor
+    ///
+    /// Destructor
+    ~Kruskal() {
+      if (local_tree) {
+        delete _tree;
+      }
+      if (uf) {
+        delete uf;
+        delete ufi;
+      }
+    }
+
+    /// \brief Sets the map storing the tree edges.
+    ///
+    /// Sets the map storing the tree edges.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return \c *this </tt>
+    Kruskal& treeMap(TreeMap &m){
+      if (local_tree) {
+	delete _tree;
+	local_tree = false;
+      }
+      _tree = &m;
+      return *this;
+    }
+
+    /// \brief Initialize the algorithm
+    ///
+    /// This member function initializes the unionfind data structure
+    /// and sorts the edges into ascending order
+    void init() {
+      initStructures();
+      initUnionFind();
+      for (UEdgeIt e(graph); e != INVALID; ++e) {
+        edges.push_back(e);
+        _tree->set(e, false);
+      }      
+      Traits::sort(edges.begin(), edges.end(), cost); 
+      index = 0;
+    }
+
+
+    /// \brief Initialize the algorithm
+    ///
+    /// This member function initializes the unionfind data structure
+    /// and sets the edge order to the given sequence. The given
+    /// sequence should be a valid STL range of undirected edges.
+    template <typename Iterator>
+    void initPresorted(Iterator begin, Iterator end) {
+      initStructures();
+      initUnionFind();
+      edges.clear();
+      std::copy(begin, end, std::back_inserter(edges));
+      index = 0;
+    }
+
+    /// \brief Initialize the algorithm
+    ///
+    /// This member function initializes the unionfind data structure
+    /// and sets the tree to empty. It does not change the order of
+    /// the edges, it uses the order of the previous running.
+    void reinit() {
+      initStructures();
+      initUnionFind();
+      for (UEdgeIt e(graph); e != INVALID; ++e) {
+        _tree->set(e, false);
+      }
+      index = 0;
+    }
+
+
+    /// \brief Executes the algorithm.
+    ///
+    /// Executes the algorithm.
+    ///
+    /// \pre init() must be called before using this function.
+    ///
+    /// This method runs the %Kruskal algorithm.
+    void start() {
+      while (index < int(edges.size())) {
+        if (uf->join(graph.target(edges[index]), graph.source(edges[index]))) {
+          _tree->set(edges[index], true);
+        }
+        ++index;
+      }
+    }
+
+    /// \brief Runs the prim algorithm until it find a new tree edge
+    ///
+    /// Runs the prim algorithm until it find a new tree edge. If it
+    /// does not next tree edge in the sequence it gives back \c INVALID.
+    UEdge findNextTreeEdge() {
+      while (index < int(edges.size())) {
+        if (uf->join(graph.target(edges[index]), graph.source(edges[index]))) {
+          _tree->set(edges[index], true);
+          return edges[index++];
+        }        
+        ++index;
+      }
+      return INVALID;
+    }
+      
+    /// \brief Processes the next edge in the sequence
+    ///
+    /// Processes the next edge in the sequence.
+    ///
+    /// \return The prcocessed edge.
+    ///
+    /// \warning The sequence must not be empty!
+    UEdge processNextEdge() {
+      UEdge edge = edges[index++];
+      processEdge(edge);
+      return edge;
+    }
+
+    /// \brief Processes an arbitrary edge
+    ///
+    /// Processes the next edge in the sequence.
+    ///
+    /// \return True when the edge is a tree edge.
+    bool processEdge(const UEdge& edge) {
+      if (uf->join(graph.target(edge), graph.source(edge))) {
+        _tree->set(edge, true);
+        return true;
+      } else {
+        return false;
+      }    
+    }
+
+    /// \brief Returns \c false if there are edge to be processed in
+    /// sequence
+    ///
+    /// Returns \c false if there are nodes to be processed in the
+    /// sequence
+    bool emptyQueue() {
+      return index == int(edges.size());
+    }
+
+    /// \brief Returns the next edge to be processed
+    ///
+    /// Returns the next edge to be processed
+    ///
+    UEdge nextEdge() const {
+      return edges[index];
+    }
+
+    /// \brief Runs %Kruskal algorithm.
+    ///
+    /// This method runs the %Kruskal algorithm in order to compute the
+    /// minimum spanning tree (or minimum spanning forest).  The
+    /// method also works on graphs that has more than one components.
+    /// In this case it computes the minimum spanning forest.
+    void run() {
+      init();
+      start();
+    }
+
+    /// \brief Returns a reference to the tree edges map
+    ///
+    /// Returns a reference to the TreeEdgeMap of the edges of the
+    /// minimum spanning tree. The value of the map is \c true only if
+    /// the edge is in the minimum spanning tree.
+    ///
+    const TreeMap &treeMap() const { return *_tree;}
+
+    /// \brief Returns the total cost of the tree
+    ///
+    /// Returns the total cost of the tree
+    Value treeValue() const {
+      Value value = 0;
+      for (UEdgeIt it(graph); it != INVALID; ++it) {
+        if ((*_tree)[it]) {
+          value += cost[it];
+        }
+      }
+      return value;
+    }
+
+    /// \brief Returns true when the given edge is tree edge
+    ///
+    /// Returns true when the given edge is tree edge
+    bool tree(UEdge e) const {
+      return (*_tree)[e];
+    }
+    
+    
+  };
+
+
+  namespace _kruskal_bits {
+
+    template <typename Graph, typename In, typename Out>
+    typename In::value_type::second_type
+    kruskal(const Graph& graph, const In& in, Out& out) {
+      typedef typename In::value_type::second_type Value;
+      typedef typename Graph::template NodeMap<int> IndexMap;
+      typedef typename Graph::Node Node;
+      
+      IndexMap index(graph);
+      UnionFind<IndexMap> uf(index);
+      for (typename Graph::NodeIt it(graph); it != INVALID; ++it) {
+        uf.insert(it);
+      }
+      
+      Value tree_value = 0;
+      for (typename In::const_iterator it = in.begin(); it != in.end(); ++it) {
+        if (uf.join(graph.target(it->first),graph.source(it->first))) {
+          out.set(it->first, true);
+          tree_value += it->second;
+        }
+        else {
+          out.set(it->first, false);
+        }
+      }
+      return tree_value;
+    }
+
+
+    template <typename Sequence>
+    struct PairComp {
+      typedef typename Sequence::value_type Value;
+      bool operator()(const Value& left, const Value& right) {
+	return left.second < right.second;
+      }
+    };
+
+    template <typename In, typename Enable = void>
+    struct SequenceInputIndicator {
+      static const bool value = false;
+    };
+
+    template <typename In>
+    struct SequenceInputIndicator<In, 
+      typename exists<typename In::value_type::first_type>::type> {
+      static const bool value = true;
+    };
+
+    template <typename In, typename Enable = void>
+    struct MapInputIndicator {
+      static const bool value = false;
+    };
+
+    template <typename In>
+    struct MapInputIndicator<In, 
+      typename exists<typename In::Value>::type> {
+      static const bool value = true;
+    };
+
+    template <typename In, typename Enable = void>
+    struct SequenceOutputIndicator {
+      static const bool value = false;
+    };
+ 
+    template <typename Out>
+    struct SequenceOutputIndicator<Out, 
+      typename exists<typename Out::value_type>::type> {
+      static const bool value = true;
+    };
+
+    template <typename Out, typename Enable = void>
+    struct MapOutputIndicator {
+      static const bool value = false;
+    };
+
+    template <typename Out>
+    struct MapOutputIndicator<Out, 
+      typename exists<typename Out::Value>::type> {
+      static const bool value = true;
+    };
+
+    template <typename In, typename InEnable = void>
+    struct KruskalValueSelector {};
+
+    template <typename In>
+    struct KruskalValueSelector<In,
+      typename enable_if<SequenceInputIndicator<In>, void>::type> 
+    {
+      typedef typename In::value_type::second_type Value;
+    };    
+
+    template <typename In>
+    struct KruskalValueSelector<In,
+      typename enable_if<MapInputIndicator<In>, void>::type> 
+    {
+      typedef typename In::Value Value;
+    };    
+    
+    template <typename Graph, typename In, typename Out,
+              typename InEnable = void>
+    struct KruskalInputSelector {};
+
+    template <typename Graph, typename In, typename Out,
+              typename InEnable = void>
+    struct KruskalOutputSelector {};
+    
+    template <typename Graph, typename In, typename Out>
+    struct KruskalInputSelector<Graph, In, Out,
+      typename enable_if<SequenceInputIndicator<In>, void>::type > 
+    {
+      typedef typename In::value_type::second_type Value;
+
+      static Value kruskal(const Graph& graph, const In& in, Out& out) {
+        return KruskalOutputSelector<Graph, In, Out>::
+          kruskal(graph, in, out);
+      }
+
+    };
+
+    template <typename Graph, typename In, typename Out>
+    struct KruskalInputSelector<Graph, In, Out,
+      typename enable_if<MapInputIndicator<In>, void>::type > 
+    {
+      typedef typename In::Value Value;
+      static Value kruskal(const Graph& graph, const In& in, Out& out) {
+        typedef typename In::Key MapEdge;
+        typedef typename In::Value Value;
+        typedef typename ItemSetTraits<Graph, MapEdge>::ItemIt MapEdgeIt;
+        typedef std::vector<std::pair<MapEdge, Value> > Sequence;
+        Sequence seq;
+        
+        for (MapEdgeIt it(graph); it != INVALID; ++it) {
+          seq.push_back(std::make_pair(it, in[it]));
+        }
+
+        std::sort(seq.begin(), seq.end(), PairComp<Sequence>());
+        return KruskalOutputSelector<Graph, Sequence, Out>::
+          kruskal(graph, seq, out);
+      }
+    };
+
+    template <typename Graph, typename In, typename Out>
+    struct KruskalOutputSelector<Graph, In, Out,
+      typename enable_if<SequenceOutputIndicator<Out>, void>::type > 
+    {
+      typedef typename In::value_type::second_type Value;
+
+      static Value kruskal(const Graph& graph, const In& in, Out& out) {
+        typedef StoreBoolMap<Out> Map;
+        Map map(out);
+        return _kruskal_bits::kruskal(graph, in, map);
+      }
+
+    };
+
+    template <typename Graph, typename In, typename Out>
+    struct KruskalOutputSelector<Graph, In, Out,
+      typename enable_if<MapOutputIndicator<Out>, void>::type > 
+    {
+      typedef typename In::value_type::second_type Value;
+
+      static Value kruskal(const Graph& graph, const In& in, Out& out) {
+        return _kruskal_bits::kruskal(graph, in, out);
+      }
+    };
+
+  }
+
+  /// \ingroup spantree
+  ///
+  /// \brief Kruskal's algorithm to find a minimum cost tree of a graph.
+  ///
+  /// This function runs Kruskal's algorithm to find a minimum cost tree.
+  /// Due to hard C++ hacking, it accepts various input and output types.
+  ///
+  /// \param g The graph the algorithm runs on.
+  /// It can be either \ref concepts::Graph "directed" or 
+  /// \ref concepts::UGraph "undirected".
+  /// If the graph is directed, the algorithm consider it to be 
+  /// undirected by disregarding the direction of the edges.
+  ///
+  /// \param in This object is used to describe the edge costs. It can be one
+  /// of the following choices.
+  /// - An STL compatible 'Forward Container' with
+  /// <tt>std::pair<GR::UEdge,X></tt> or
+  /// <tt>std::pair<GR::Edge,X></tt> as its <tt>value_type</tt>, where
+  /// \c X is the type of the costs. The pairs indicates the edges
+  /// along with the assigned cost. <em>They must be in a
+  /// cost-ascending order.</em>
+  /// - Any readable Edge map. The values of the map indicate the edge costs.
+  ///
+  /// \retval out Here we also have a choise.
+  /// - It can be a writable \c bool edge map.  After running the
+  /// algorithm this will contain the found minimum cost spanning
+  /// tree: the value of an edge will be set to \c true if it belongs
+  /// to the tree, otherwise it will be set to \c false. The value of
+  /// each edge will be set exactly once.
+  /// - It can also be an iteraror of an STL Container with
+  /// <tt>GR::UEdge</tt> or <tt>GR::Edge</tt> as its
+  /// <tt>value_type</tt>.  The algorithm copies the elements of the
+  /// found tree into this sequence.  For example, if we know that the
+  /// spanning tree of the graph \c g has say 53 edges, then we can
+  /// put its edges into an STL vector \c tree with a code like this.
+  ///\code
+  /// std::vector<Edge> tree(53);
+  /// kruskal(g,cost,tree.begin());
+  ///\endcode
+  /// Or if we don't know in advance the size of the tree, we can
+  /// write this.  
+  ///\code std::vector<Edge> tree;
+  /// kruskal(g,cost,std::back_inserter(tree)); 
+  ///\endcode
+  ///
+  /// \return The total cost of the found tree.
+  ///
+  /// \warning If kruskal runs on an be consistent of using the same
+  /// Edge type for input and output.
+  ///
+
+#ifdef DOXYGEN
+  template <class Graph, class In, class Out>
+  Value kruskal(GR const& g, const In& in, Out& out)
+#else 
+  template <class Graph, class In, class Out>
+  inline typename _kruskal_bits::KruskalValueSelector<In>::Value 
+  kruskal(const Graph& graph, const In& in, Out& out) 
+#endif
+  {
+    return _kruskal_bits::KruskalInputSelector<Graph, In, Out>::
+      kruskal(graph, in, out);
+  }
+
+ 
+  
+
+  template <class Graph, class In, class Out>
+  inline typename _kruskal_bits::KruskalValueSelector<In>::Value
+  kruskal(const Graph& graph, const In& in, const Out& out)
+  {
+    return _kruskal_bits::KruskalInputSelector<Graph, In, const Out>::
+      kruskal(graph, in, out);
+  }  
+
+} //namespace lemon
+
+#endif //LEMON_KRUSKAL_H
Index: lemon/lemon_reader.h
===================================================================
--- lemon/lemon_reader.h	(revision 2618)
+++ lemon/lemon_reader.h	(revision 2618)
@@ -0,0 +1,3511 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup lemon_io
+///\file
+///\brief Lemon Format reader.
+
+
+#ifndef LEMON_LEMON_READER_H
+#define LEMON_LEMON_READER_H
+
+
+#include <iostream>
+#include <fstream>
+#include <string>
+#include <vector>
+#include <algorithm>
+#include <map>
+#include <memory>
+
+#include <lemon/error.h>
+#include <lemon/graph_utils.h>
+#include <lemon/bits/utility.h>
+#include <lemon/bits/item_reader.h>
+
+#include <lemon/dim2.h>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+
+namespace lemon {
+
+  namespace _reader_bits {
+
+    template <typename T>
+    bool operator<(T, T) {
+      throw DataFormatError("Label is not comparable");
+    }
+
+    template <typename T>
+    struct Less {
+      bool operator()(const T& p, const T& q) const {
+	return p < q;
+      }
+    };
+    
+    template <typename Item>
+    class ItemLabelReader {
+    public:
+
+      bool isLabelReader() { return true; }
+
+      void readLabel(std::istream&, Item&) {}
+      
+      template <class _ItemLabelReader>
+      struct Constraints {
+	void constraints() {
+	  bool b = reader.isLabelReader();
+	  ignore_unused_variable_warning(b);
+	  Item item;
+	  reader.readLabel(is, item);
+	}
+	_ItemLabelReader& reader;
+	std::istream& is;
+      };
+
+    };
+
+    template <typename Item>
+    class ItemReader {
+    public:
+      void read(std::istream&, Item&) {}
+      
+      template <class _ItemReader>
+      struct Constraints {
+	void constraints() {
+	  Item item;
+	  reader.read(is, item);
+	}
+	_ItemReader& reader;
+	std::istream& is;
+      };
+
+    };
+
+    template <typename Map>
+    struct Ref { typedef Map& Type; };
+    template <typename Map>
+    struct Arg { typedef Map& Type; };
+
+    template <typename Graph, typename Map>
+    class ForwardComposeMap {
+    public:
+      typedef typename Graph::UEdge Key;
+      typedef typename Map::Value Value;
+
+      ForwardComposeMap(const Graph& _graph, typename Arg<Map>::Type _map) 
+	: graph(_graph), map(_map) {}
+      
+      void set(const Key& key, const Value& val) {
+	map.set(graph.direct(key, true), val);
+      }
+
+    private:
+      const Graph& graph;
+      typename Ref<Map>::Type map;
+    };
+
+    template <typename Graph, typename Map>
+    ForwardComposeMap<Graph, Map>
+    forwardComposeMap(const Graph& graph, const Map& map) {
+      return ForwardComposeMap<Graph, Map>(graph, map);
+    }
+
+    template <typename Graph, typename Map>
+    ForwardComposeMap<Graph, Map>
+    forwardComposeMap(const Graph& graph, Map& map) {
+      return ForwardComposeMap<Graph, Map>(graph, map);
+    }
+
+    template <typename Graph, typename Map>
+    class BackwardComposeMap {
+    public:
+      typedef typename Graph::UEdge Key;
+      typedef typename Map::Value Value;
+
+      BackwardComposeMap(const Graph& _graph, typename Arg<Map>::Type _map) 
+	: graph(_graph), map(_map) {}
+      
+      void set(const Key& key, const Value& val) {
+	map.set(graph.direct(key, false), val);
+      }
+
+    private:
+      const Graph& graph;
+      typename Ref<Map>::Type map;
+    };
+
+
+    template <typename Graph, typename Map>
+    BackwardComposeMap<Graph, Map>
+    backwardComposeMap(const Graph& graph, const Map& map) {
+      return BackwardComposeMap<Graph, Map>(graph, map);
+    }
+
+    template <typename Graph, typename Map>
+    BackwardComposeMap<Graph, Map>
+    backwardComposeMap(const Graph& graph, Map& map) {
+      return BackwardComposeMap<Graph, Map>(graph, map);
+    }
+
+    template <typename Graph, typename Map>
+    struct Ref<ForwardComposeMap<Graph, Map> > { 
+      typedef ForwardComposeMap<Graph, Map> Type;
+    };
+    template <typename Graph, typename Map>
+    struct Arg<ForwardComposeMap<Graph, Map> > { 
+      typedef const ForwardComposeMap<Graph, Map>& Type;
+    };
+
+    template <typename Graph, typename Map>
+    struct Ref<BackwardComposeMap<Graph, Map> > { 
+      typedef BackwardComposeMap<Graph, Map> Type; 
+    };
+    template <typename Graph, typename Map>
+    struct Arg<BackwardComposeMap<Graph, Map> > { 
+      typedef const BackwardComposeMap<Graph, Map>& Type; 
+    };
+
+    template <typename Map>
+    struct Ref<dim2::XMap<Map> > { 
+      typedef dim2::XMap<Map> Type;
+    };
+    template <typename Map>
+    struct Arg<dim2::XMap<Map> > { 
+      typedef const dim2::XMap<Map>& Type;
+    };
+
+    template <typename Map>
+    struct Ref<dim2::YMap<Map> > { 
+      typedef dim2::YMap<Map> Type;
+    };
+    template <typename Map>
+    struct Arg<dim2::YMap<Map> > { 
+      typedef const dim2::YMap<Map>& Type;
+    };
+
+
+    template <typename _Item>
+    class MapReaderBase;
+    
+    template <typename _Item>
+    class MapInverterBase : public MapReaderBase<_Item> {
+    public:
+      typedef _Item Item;
+      virtual void read(std::istream&, const Item&) = 0;
+      virtual Item read(std::istream&) const = 0;
+
+      virtual MapInverterBase<_Item>* getInverter() {
+	return this;
+      }
+    };
+
+    template <typename _Item, typename _Map, typename _Reader>
+    class MapReaderInverter : public MapInverterBase<_Item> {
+    public:
+      typedef _Item Item;
+      typedef _Reader Reader;
+      typedef typename Reader::Value Value;
+      typedef _Map Map;
+      typedef std::map<Value, Item, _reader_bits::Less<Value> > Inverse;
+
+      typename _reader_bits::Ref<Map>::Type map;
+      Reader reader;
+      Inverse inverse;
+
+      MapReaderInverter(typename _reader_bits::Arg<Map>::Type _map,
+			const Reader& _reader) 
+	: map(_map), reader(_reader) {}
+
+      virtual ~MapReaderInverter() {}
+
+      virtual void read(std::istream& is, const Item& item) {
+	Value value;
+	reader.read(is, value);
+	map.set(item, value);
+	typename Inverse::iterator it = inverse.find(value);
+	if (it == inverse.end()) {
+	  inverse.insert(std::make_pair(value, item));
+	} else {
+	  throw DataFormatError("Multiple label occurence");
+	}
+      }
+
+      virtual Item read(std::istream& is) const {
+	Value value;
+	reader.read(is, value);	
+	typename Inverse::const_iterator it = inverse.find(value);
+	if (it != inverse.end()) {
+	  return it->second;
+	} else {
+	  ErrorMessage msg;
+	  msg << "Invalid label error"; 
+	  throw DataFormatError(msg.message());
+	}
+      }      
+    };
+
+    template <typename _Item, typename _Reader>
+    class SkipReaderInverter : public MapInverterBase<_Item> {
+    public:
+      typedef _Item Item;
+      typedef _Reader Reader;
+      typedef typename Reader::Value Value;
+      typedef std::map<Value, Item, _reader_bits::Less<Value> > Inverse;
+
+      Reader reader;
+
+      SkipReaderInverter(const Reader& _reader) 
+	: reader(_reader) {}
+
+      virtual ~SkipReaderInverter() {}
+
+      virtual void read(std::istream& is, const Item& item) {
+	Value value;
+	reader.read(is, value);
+	typename Inverse::iterator it = inverse.find(value);
+	if (it == inverse.end()) {
+	  inverse.insert(std::make_pair(value, item));
+	} else {
+	  throw DataFormatError("Multiple label occurence error");
+	}
+      }
+
+      virtual Item read(std::istream& is) const {
+	Value value;
+	reader.read(is, value);
+	typename Inverse::const_iterator it = inverse.find(value);
+	if (it != inverse.end()) {
+	  return it->second;
+	} else {
+	  ErrorMessage msg;
+	  msg << "Invalid label error: " << value; 
+	  throw DataFormatError(msg.message());
+	}
+      }
+
+    private:
+      Inverse inverse;
+    };
+
+    template <typename _Item>    
+    class MapReaderBase {
+    public:
+      typedef _Item Item;
+
+      MapReaderBase() { _touched = false; }
+      
+      void touch(bool value = true) { _touched = value; }
+      bool touched() const { return _touched; }
+
+      virtual ~MapReaderBase() {}
+
+      virtual void read(std::istream& is, const Item& item) = 0;
+      virtual MapInverterBase<_Item>* getInverter() = 0;
+
+    private:      
+      bool _touched;
+
+    };
+
+    template <typename _Item, typename _Map, typename _Reader>
+    class MapReader : public MapReaderBase<_Item> {
+    public:
+      typedef _Map Map;
+      typedef _Reader Reader;
+      typedef typename Reader::Value Value;
+      typedef _Item Item;
+      
+      typename _reader_bits::Ref<Map>::Type map;
+      Reader reader;
+
+      MapReader(typename _reader_bits::Arg<Map>::Type _map, 
+		const Reader& _reader) 
+	: map(_map), reader(_reader) {}
+
+      virtual ~MapReader() {}
+
+      virtual void read(std::istream& is, const Item& item) {
+	Value value;
+	reader.read(is, value);
+	map.set(item, value);
+      }
+
+      virtual MapInverterBase<_Item>* getInverter() {
+	return new MapReaderInverter<Item, Map, Reader>(map, reader);
+      }
+    };
+
+
+    template <typename _Item, typename _Reader>
+    class SkipReader : public MapReaderBase<_Item> {
+    public:
+      typedef _Reader Reader;
+      typedef typename Reader::Value Value;
+      typedef _Item Item;
+
+      Reader reader;
+      SkipReader(const Reader& _reader) : reader(_reader) {}
+
+      virtual ~SkipReader() {}
+
+      virtual void read(std::istream& is, const Item&) {
+	Value value;
+	reader.read(is, value);
+      }      
+
+      virtual MapInverterBase<Item>* getInverter() {
+	return new SkipReaderInverter<Item, Reader>(reader);
+      }
+    };
+
+    template <typename _Item>
+    class LabelReaderBase {
+    public:
+      typedef _Item Item;
+      virtual ~LabelReaderBase() {}
+      virtual Item read(std::istream& is) const = 0;
+      virtual bool isLabelReader() const = 0;
+      virtual LabelReaderBase<_Item>* clone() const = 0;
+    };
+
+    template <typename _Item, typename _BoxedLabelReader>
+    class LabelReader : public LabelReaderBase<_Item> {
+    public:
+      typedef _Item Item;
+      typedef _BoxedLabelReader BoxedLabelReader;
+      
+      const BoxedLabelReader& labelReader;
+
+      LabelReader(const BoxedLabelReader& _labelReader) 
+	: labelReader(_labelReader) {}
+
+      virtual Item read(std::istream& is) const {
+	Item item;
+	labelReader.readLabel(is, item);
+	return item;
+      }
+
+      virtual bool isLabelReader() const {
+	return labelReader.isLabelReader();
+      }
+      
+      LabelReader<Item, BoxedLabelReader>* clone() const {
+	return new LabelReader<Item, BoxedLabelReader>(labelReader);
+      }
+    };
+
+    template <typename _Item>
+    class ItemStore {
+    public:
+
+      typedef _Item Item;
+
+      ItemStore(Item& _item) : item(&_item) { 
+	_touched = false; 
+      }
+      
+      void touch() { _touched = true; }
+      bool touched() const { return _touched; }
+
+      void read(const Item& _item) {
+	*item = _item;
+      }
+      
+    private:
+      Item* item;
+      bool _touched;
+    };
+
+    class ValueReaderBase {
+    public:
+      virtual void read(std::istream&) {};
+      ValueReaderBase() { _touched = false; }
+
+      void touch() { _touched = true; }
+      bool touched() const { return _touched; }
+
+      virtual ~ValueReaderBase() {}
+    private:
+      bool _touched;
+    };
+
+    template <typename _Value, typename _Reader>
+    class ValueReader : public ValueReaderBase {
+    public:
+      typedef _Value Value;
+      typedef _Reader Reader;
+
+      ValueReader(Value& _value, const Reader& _reader)
+ 	: value(_value), reader(_reader) {}
+
+      virtual void read(std::istream& is) {
+	reader.read(is, value);
+      }
+    private:
+      Value& value;
+      Reader reader;
+    };
+
+  }
+
+  /// \ingroup lemon_io
+  /// \brief Lemon Format reader class.
+  /// 
+  /// The Lemon Format contains several sections. We do not want to
+  /// determine what sections are in a lemon file we give only a framework
+  /// to read a section oriented format.
+  ///
+  /// In the Lemon Format each section starts with a line containing a
+  /// \c \@ character on the first not white space position. This line
+  /// is the header line of the section. Each of the next lines belong
+  /// to this section until a line starting with \c \@ character is
+  /// found. This line can start a new section or it can close the
+  /// file with the \c \@end line.  The file format ignores the empty
+  /// and comment lines. The line is comment line if it starts with a
+  /// \c # character.
+  ///
+  /// The framework provides an abstract LemonReader::SectionReader class
+  /// that defines the interface of a SectionReader. The SectionReader
+  /// has the \c header() member function that gets a header line string and
+  /// decides if it wants to process the next section. Several SectionReaders
+  /// can be attached to a LemonReader and the first attached that can
+  /// process the section will be used. Its \c read() member will be called
+  /// with a stream containing the section. From this stream the empty and
+  /// comment lines are filtered out.
+  ///
+  /// \relates GraphReader
+  /// \relates NodeSetReader
+  /// \relates EdgeSetReader
+  /// \relates NodesReader
+  /// \relates EdgesReader
+  /// \relates AttributeReader
+  class LemonReader {
+  private:
+    
+    class FilterStreamBuf : public std::streambuf {
+    public:
+
+      typedef std::streambuf Parent;
+      typedef Parent::char_type char_type;
+      FilterStreamBuf(std::istream& is, int& num) 
+	: _is(is), _base(0), _eptr(0), 
+	  _num(num), skip_state(after_endl) {}
+
+    protected:
+
+      enum skip_state_type {
+	no_skip,
+	after_endl,
+	comment_line
+      };
+
+      char_type small_buf[1];
+
+
+      std::istream& _is;
+
+      char_type* _base;
+      char_type* _eptr;
+
+      int& _num;
+
+      skip_state_type skip_state;
+
+
+      char_type* base() { return _base; }
+
+      char_type* eptr() { return _eptr; }
+
+      int_type blen() { return _eptr - _base; }
+
+      void setb(char_type* buf, int_type len) {
+	_base = buf;
+	_eptr = buf + len;
+      }
+  
+      virtual std::streambuf* setbuf(char *buf, std::streamsize len) {
+	if (base()) return 0;
+	if (buf != 0 && len >= int(sizeof(small_buf))) {
+	  setb(buf, len);
+	} else {
+	  setb(small_buf, sizeof(small_buf));
+	}
+	setg(0, 0, 0);
+	return this;
+      }
+
+      bool put_char(char c) {
+	switch (skip_state) {
+	case no_skip:
+	  switch (c) {
+	  case '\n': 
+	    skip_state = after_endl;
+	    return true;
+	  default:
+	    return true;
+	  }
+	case after_endl:
+	  switch (c) {
+	  case '@':
+	    return false;
+	  case '\n': 
+	    return false;
+	  case '#':
+	    skip_state = comment_line;
+	    return false;
+	  default:
+	    if (!isspace(c)) {
+	      skip_state = no_skip;
+	      return true;
+	    } else {
+	      return false;
+	    }
+	  }
+	  break;
+	case comment_line:
+	  switch (c) {
+	  case '\n': 
+	    skip_state = after_endl;
+	    return false;
+	  default:
+	    return false;
+	  }
+	}
+	return false;
+      }
+
+      virtual int_type underflow() {
+	char c;
+	if ((c = _is.peek()) != EOF) {
+	  if (c == '@') {
+	    return EOF;
+	  }
+	} else {
+	  return EOF;
+	}
+	char_type *ptr;
+	for (ptr = base(); ptr != eptr(); ++ptr) {
+	  if ((c = _is.get()) != EOF) {
+	    if (c == '\n') ++_num;
+	    if (put_char(c)) {
+	      *ptr = c;
+	    } else {
+	      if (skip_state == after_endl && c == '@') {
+		_is.putback(c);
+		break;
+	      }
+	      --ptr;
+	    }
+	  } else {
+	    break;
+	  }
+	}
+	setg(base(), base(), ptr);
+	return *base();
+      }
+
+      virtual int_type sync() {
+	return EOF;
+      }
+
+    public:
+
+      int line_num() const {
+	int r = _num;
+	for (char_type* p = gptr(); p != egptr(); ++p) {
+	  if (*p == '\n') --r;
+	}
+	return r;
+      }
+
+    };
+
+    static void skipPreSection(std::istream& is, int& line_num) {
+      enum skip_state_type { skip, after_endl };
+
+      skip_state_type skip_state = after_endl;
+      char c;
+      
+      while ((c = is.get()) != EOF) {
+	if (c == '\n') ++line_num;
+
+	switch (skip_state) {
+	case skip:
+	  if (c == '\n') skip_state = after_endl;
+	  break;
+	case after_endl:
+	  switch (c) {
+	  case '@':
+	    is.putback(c);
+	    return;
+	  case '\n':
+	    continue;
+	  default:
+	    if (!isspace(c)) {
+	      skip_state = skip;
+	    }
+	    break;
+	  }
+	}	
+      }
+    }
+
+  public:
+
+    /// \brief Abstract base class for reading a section.
+    ///
+    /// This class has an \c header() member function what get a 
+    /// header line string and decides if it want to process the next 
+    /// section. Several SectionReaders can be attached to an LemonReader 
+    /// and the first attached what can process the section will be used. 
+    /// Its \c read() member will called with a stream contains the section. 
+    /// From this stream the empty lines and comments are filtered out.
+    class SectionReader {
+      friend class LemonReader;
+    protected:
+      /// \brief Constructor for SectionReader.
+      ///
+      /// Constructor for SectionReader. It attach this reader to
+      /// the given LemonReader.
+      SectionReader(LemonReader& reader) {
+	reader.attach(*this);
+      }
+
+      virtual ~SectionReader() {}
+
+      /// \brief Gives back true when the SectionReader can process 
+      /// the section with the given header line.
+      ///
+      /// It gives back true when the SectionReader can process
+      /// the section with the given header line.
+      virtual bool header(const std::string& line) = 0;
+
+      /// \brief Reader function of the section.
+      ///
+      /// It reads the content of the section.
+      virtual void read(std::istream& is) = 0;
+
+      /// \brief The given section missing in the file.
+      ///
+      /// The given section missing in the file.
+      virtual void missing() {};
+    };
+
+    /// \brief Constructor for LemonReader.
+    ///
+    /// Constructor for LemonReader which reads from the given stream.
+    LemonReader(std::istream& _is) 
+      : is(&_is), own_is(false) {}
+
+    /// \brief Constructor for LemonReader.
+    ///
+    /// Constructor for LemonReader which reads from the given file.
+    LemonReader(const std::string& filename) 
+      : is(0), own_is(true) {
+      is = new std::ifstream(filename.c_str());
+      if (is->fail()) {
+	throw FileOpenError(filename);
+      }
+    }
+
+    /// \brief Desctructor for LemonReader.
+    ///
+    /// Desctructor for LemonReader.
+    ~LemonReader() {
+      if (own_is) {
+	delete is;
+      }
+    }
+
+  private:
+    LemonReader(const LemonReader&);
+    void operator=(const LemonReader&);
+
+    void attach(SectionReader& reader) {
+      readers.push_back(std::make_pair(&reader, false));
+    }
+
+  public:
+    /// \brief Executes the LemonReader.
+    /// 
+    /// It executes the LemonReader.
+    void run() {
+      int line_num = 0;
+      std::string line;
+      
+      SectionReaders::iterator it;
+      skipPreSection(*is, line_num);
+      while ((++line_num, getline(*is, line)) && line.find("@end") != 0) {
+	for (it = readers.begin(); it != readers.end(); ++it) {
+	  if (it->first->header(line)) {
+	    it->second = true;
+	    char buf[2048];
+	    FilterStreamBuf buffer(*is, line_num);
+	    try {
+	      buffer.pubsetbuf(buf, sizeof(buf));
+	      std::istream ss(&buffer);
+	      it->first->read(ss);
+	      skipPreSection(*is, line_num);
+	      break;
+	    } catch (DataFormatError& error) {
+	      error.line(buffer.line_num());
+	      throw;
+	    }	
+	  }
+	}
+      }
+      for (it = readers.begin(); it != readers.end(); ++it) {
+	if (!it->second) {
+	  try {
+	    it->first->missing();
+	  } catch (DataFormatError& error) {
+	    error.line(line_num);
+	    throw;
+	  }	
+	}
+      }
+    }
+
+
+  private:
+
+    std::istream* is;
+    bool own_is;
+
+    typedef std::vector<std::pair<SectionReader*, bool> > SectionReaders;
+    SectionReaders readers;
+
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading a graph's nodeset.
+  ///
+  /// The lemon format can store multiple graph nodesets with several
+  /// maps.  The nodeset section's header line is \c \@nodeset \c
+  /// nodeset_name, but the \c nodeset_name may be empty.
+  ///
+  /// The first line of the section contains the names of the maps separated
+  /// with white spaces. Each next lines describes a node in the nodeset, and
+  /// contains the mapped values for each map.
+  ///
+  /// If the nodeset contains an \c "label" named map then it will be regarded
+  /// as id map. This map should contain only unique values and when the 
+  /// \c readLabel() member will read a value from the given stream it will
+  /// give back that node which is mapped to this value.
+  ///
+  /// \relates LemonReader
+  template <typename _Graph, typename _Traits = DefaultReaderTraits>
+  class NodeSetReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Node Node;
+    typedef typename Traits::Skipper DefaultSkipper;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for NodeSetReader. It creates the NodeSetReader and
+    /// attach it into the given LemonReader. The nodeset reader will
+    /// add the read nodes to the given Graph. The reader will read
+    /// the section when the \c section_name and the \c _name are the same. 
+    NodeSetReader(LemonReader& _reader, 
+		  Graph& _graph, 
+		  const std::string& _name = std::string(),
+		  const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : Parent(_reader), graph(_graph), name(_name), skipper(_skipper) {} 
+
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for NodeSetReader.
+    virtual ~NodeSetReader() {
+      for (typename MapReaders::iterator it = readers.begin(); 
+	   it != readers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    NodeSetReader(const NodeSetReader&);
+    void operator=(const NodeSetReader&);
+  
+  public:
+
+    /// \brief Add a new node map reader command for the reader.
+    ///
+    /// Add a new node map reader command for the reader.
+    template <typename Map>
+    NodeSetReader& readNodeMap(std::string label, Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    NodeSetReader& readNodeMap(std::string label, const Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new node map reader command for the reader.
+    ///
+    /// Add a new node map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    NodeSetReader& readNodeMap(std::string label, Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    NodeSetReader& readNodeMap(std::string label, const Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    NodeSetReader& _readMap(std::string label, MapParameter map, 
+			    const ItemReader& ir = ItemReader()) {
+      checkConcept<concepts::WriteMap<Node, typename Map::Value>, Map>();
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for node map: " << label;
+	throw IoParameterError(msg.message());
+      }      
+      readers.insert(
+        make_pair(label, new _reader_bits::
+		  MapReader<Node, Map, ItemReader>(map, ir)));
+      return *this;
+    }
+
+  public:
+
+    /// \brief Add a new node map skipper command for the reader.
+    ///
+    /// Add a new node map skipper command for the reader.
+    template <typename ItemReader>
+    NodeSetReader& skipNodeMap(std::string label, 
+                               const ItemReader& ir = ItemReader()) {
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for node map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, new _reader_bits::
+			       SkipReader<Node, ItemReader>(ir)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line starts with \c \@nodeset,
+    /// and the header line's name and the nodeset's name are the same.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return command == "@nodeset" && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      std::vector<_reader_bits::MapReaderBase<Node>* > index;
+      std::string line;
+
+      {
+        getline(is, line);
+        std::istringstream ls(line);
+        std::string id;
+        while (ls >> id) {
+          typename MapReaders::iterator it = readers.find(id);
+          if (it != readers.end()) {
+            it->second->touch();
+            index.push_back(it->second);
+          } else {
+            index.push_back(&skipper);
+          }
+          if (id == "label") {
+            inverter.reset(index.back()->getInverter());
+            index.back() = inverter.get();
+          }
+        }
+      }
+      for (typename MapReaders::iterator it = readers.begin();
+	   it != readers.end(); ++it) {
+	if (!it->second->touched()) {
+	  ErrorMessage msg;
+	  msg << "Map not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}
+      }
+      while (getline(is, line)) {	
+	Node node = graph.addNode();
+	std::istringstream ls(line);
+	for (int i = 0; i < int(index.size()); ++i) {
+	  index[i]->read(ls, node);
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "NodeSet section not found in file: @nodeset " << name;
+      throw IoParameterError(msg.message());
+    }
+
+  public:
+
+    /// \brief Returns true if the nodeset can give back the node by its label.
+    ///
+    /// Returns true if the nodeset can give back the node by its label.
+    /// It is possible only if an "label" named map was read.
+    bool isLabelReader() const {
+      return inverter.get() != 0;
+    }
+
+    /// \brief Gives back the node by its label.
+    ///
+    /// It reads an id from the stream and gives back which node belongs to
+    /// it. It is possible only if there was read an "label" named map.
+    void readLabel(std::istream& is, Node& node) const {
+      node = inverter->read(is);
+    } 
+
+  private:
+
+    typedef std::map<std::string, _reader_bits::MapReaderBase<Node>*> MapReaders;
+    MapReaders readers;
+   
+    Graph& graph;   
+    std::string name;
+    _reader_bits::SkipReader<Node, DefaultSkipper> skipper;
+
+    std::auto_ptr<_reader_bits::MapInverterBase<Node> > inverter;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading a bipartite graph's nodeset.
+  ///
+  /// The lemon format can store multiple bipartite graph nodesets
+  /// with several maps. The bipartite graph nodeset section's header
+  /// line is \c \@bpnodeset \c bpnodeset_name, but the \c bpnodeset_name
+  /// may be empty.
+  ///
+  /// The first line of the section contains \c "&anodeset" and the
+  /// the names of the A-node maps and regular maps separated with
+  /// white spaces. Each next lines describes an A-node in the anodeset,
+  /// and contains the mapped values for each map. If one of the line
+  /// starts with \c "&bnodeset" then this line contains the names of
+  /// the B-node maps and the regular node maps. And the remaining lines
+  /// contains the mapped values to the B-nodes.
+  ///
+  /// If there is "label" named map then it should be defined in both
+  /// nodeset, and it will be regarded as id map. This map should
+  /// contain only unique values and when the \c readLabel() member
+  /// will read a value from the given stream it will give back that
+  /// node which is mapped to this value.
+  ///
+  /// \relates LemonReader
+  template <typename _Graph, typename _Traits = DefaultReaderTraits>
+  class BpNodeSetReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Node Node;
+    typedef typename Traits::Skipper DefaultSkipper;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for BpNodeSetReader. It creates the BpNodeSetReader and
+    /// attach it into the given LemonReader. The nodeset reader will
+    /// add the read nodes to the given Graph. The reader will read
+    /// the section when the \c section_name and the \c _name are the same. 
+    BpNodeSetReader(LemonReader& _reader, 
+		  Graph& _graph, 
+		  const std::string& _name = std::string(),
+		  const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : Parent(_reader), graph(_graph), name(_name), skipper(_skipper) {} 
+
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for BpNodeSetReader.
+    virtual ~BpNodeSetReader() {
+      for (typename MapReaders::iterator it = readers.begin(); 
+	   it != readers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    BpNodeSetReader(const BpNodeSetReader&);
+    void operator=(const BpNodeSetReader&);
+  
+  public:
+
+    /// \brief Add a new node map reader command for the reader.
+    ///
+    /// Add a new node map reader command for the reader.
+    template <typename Map>
+    BpNodeSetReader& readNodeMap(std::string label, Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    BpNodeSetReader& readNodeMap(std::string label, const Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new node map reader command for the reader.
+    ///
+    /// Add a new node map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    BpNodeSetReader& readNodeMap(std::string label, Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    BpNodeSetReader& readNodeMap(std::string label, const Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    BpNodeSetReader& _readMap(std::string label, MapParameter map, 
+			    const ItemReader& ir = ItemReader()) {
+      checkConcept<concepts::WriteMap<Node, typename Map::Value>, Map>();
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      if (areaders.find(label) != areaders.end() ||
+	  breaders.find(label) != breaders.end() ||
+	  readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for node map: " << label;
+	throw IoParameterError(msg.message());
+      }      
+      readers.insert(make_pair(label, new _reader_bits::
+		  MapReader<Node, Map, ItemReader>(map, ir)));
+      return *this;
+    }
+
+  public:
+
+    /// \brief Add a new A-node map reader command for the reader.
+    ///
+    /// Add a new A-node map reader command for the reader.
+    template <typename Map>
+    BpNodeSetReader& readANodeMap(std::string label, Map& map) {
+      return _readAMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    BpNodeSetReader& readANodeMap(std::string label, const Map& map) {
+      return _readAMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new A-node map reader command for the reader.
+    ///
+    /// Add a new A-node map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    BpNodeSetReader& readANodeMap(std::string label, Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readAMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    BpNodeSetReader& readANodeMap(std::string label, const Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readAMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    BpNodeSetReader& _readAMap(std::string label, MapParameter map, 
+			    const ItemReader& ir = ItemReader()) {
+      checkConcept<concepts::WriteMap<Node, typename Map::Value>, Map>();
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      if (label == "label") {
+	throw IoParameterError("Label cannot be A-node map");
+      }
+      if (areaders.find(label) != areaders.end() ||
+	  readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for A-node map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      areaders.insert(make_pair(label, new _reader_bits::
+				MapReader<Node, Map, ItemReader>(map, ir)));
+      return *this;
+    }
+
+  public:
+
+    /// \brief Add a new B-node map reader command for the reader.
+    ///
+    /// Add a new B-node map reader command for the reader.
+    template <typename Map>
+    BpNodeSetReader& readBNodeMap(std::string label, Map& map) {
+      return _readBMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    BpNodeSetReader& readBNodeMap(std::string label, const Map& map) {
+      return _readBMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new B-node map reader command for the reader.
+    ///
+    /// Add a new B-node map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    BpNodeSetReader& readBNodeMap(std::string label, Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readBMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    BpNodeSetReader& readBNodeMap(std::string label, const Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readBMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    BpNodeSetReader& _readBMap(std::string label, MapParameter map, 
+			    const ItemReader& ir = ItemReader()) {
+      checkConcept<concepts::WriteMap<Node, typename Map::Value>, Map>();
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      if (label == "label") {
+	throw IoParameterError("Label cannot be B-node map");
+      }
+      if (breaders.find(label) != breaders.end() ||
+	  readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for B-node map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      breaders.insert(make_pair(label, new _reader_bits::
+				MapReader<Node, Map, ItemReader>(map, ir)));
+      return *this;
+    }
+
+  public:
+
+    /// \brief Add a new node map skipper command for the reader.
+    ///
+    /// Add a new node map skipper command for the reader.
+    template <typename ItemReader>
+    BpNodeSetReader& skipNodeMap(std::string label, 
+				 const ItemReader& ir = ItemReader()) {
+      if (areaders.find(label) != areaders.end() ||
+	  breaders.find(label) != breaders.end() ||
+	  readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for node map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, new _reader_bits::
+			       SkipReader<Node, ItemReader>(ir)));
+      return *this;
+    }
+
+    /// \brief Add a new A-node map skipper command for the reader.
+    ///
+    /// Add a new A-node map skipper command for the reader.
+    template <typename ItemReader>
+    BpNodeSetReader& skipANodeMap(std::string label, 
+				  const ItemReader& ir = ItemReader()) {
+      if (label == "label") {
+	throw IoParameterError("Label cannot be A-node map");
+      }
+      if (areaders.find(label) != areaders.end() ||
+	  readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for A-node map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      areaders.insert(make_pair(label, new _reader_bits::
+				SkipReader<Node, ItemReader>(ir)));
+      return *this;
+    }
+
+    /// \brief Add a new B-node map skipper command for the reader.
+    ///
+    /// Add a new B-node map skipper command for the reader.
+    template <typename ItemReader>
+    BpNodeSetReader& skipBNodeMap(std::string label, 
+				  const ItemReader& ir = ItemReader()) {
+      if (label == "label") {
+	throw IoParameterError("Label cannot be B-node map");
+      }
+      if (breaders.find(label) != breaders.end() ||
+	  readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for B-node map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      breaders.insert(make_pair(label, new _reader_bits::
+				SkipReader<Node, ItemReader>(ir)));
+      return *this;
+    }
+
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line starts with \c \@nodeset,
+    /// and the header line's name and the nodeset's name are the same.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return command == "@bpnodeset" && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      std::string line;
+      {
+	std::vector<_reader_bits::MapReaderBase<Node>* > index;
+	{
+	  getline(is, line);
+	  std::istringstream ls(line);
+	  std::string id;
+	  ls >> id;
+	  if (id != "&anodeset") {
+	    throw IoParameterError("Cannot find &anodeset subsection");
+	  }
+	  while (ls >> id) {
+	    typename MapReaders::iterator it = readers.find(id);
+	    typename MapReaders::iterator ait = areaders.find(id);
+	    if (it != readers.end()) {
+	      it->second->touch();
+	      index.push_back(it->second);
+	    } else if (ait != areaders.end()) {
+	      ait->second->touch();
+	      index.push_back(ait->second);
+	    } else {
+	      index.push_back(&skipper);
+	    }
+	    if (id == "label") {
+	      inverter.reset(index.back()->getInverter());
+	      index.back() = inverter.get();
+	    }
+	  }
+	}
+	for (typename MapReaders::iterator it = areaders.begin();
+	     it != areaders.end(); ++it) {
+	  if (!it->second->touched()) {
+	    ErrorMessage msg;
+	    msg << "Map not found in file: " << it->first;
+	    throw IoParameterError(msg.message());
+	  }
+	}
+	for (typename MapReaders::iterator it = readers.begin();
+	     it != readers.end(); ++it) {
+	  if (!it->second->touched()) {
+	    ErrorMessage msg;
+	    msg << "Map not found in file: " << it->first;
+	    throw IoParameterError(msg.message());
+	  }
+	  it->second->touch(false);
+	}
+
+	while (getline(is, line)) {
+	  if (line[0] == '&') {
+	    std::istringstream ls(line);
+	    std::string id;
+	    ls >> id;
+	    if (id == "&bnodeset") break;
+	  }
+	  Node node = graph.addANode();
+	  std::istringstream ls(line);
+	  for (int i = 0; i < int(index.size()); ++i) {
+	    index[i]->read(ls, node);
+	  }
+	}
+      }
+
+      {
+	std::vector<_reader_bits::MapReaderBase<Node>* > index;
+	{
+	  std::istringstream ls(line);
+	  std::string id;
+	  ls >> id;
+	  if (id != "&bnodeset") {
+	    throw IoParameterError("Cannot find &bnodeset subsection");
+	  }
+	  while (ls >> id) {
+	    typename MapReaders::iterator it = readers.find(id);
+	    typename MapReaders::iterator bit = breaders.find(id);
+	    if (it != readers.end()) {
+	      it->second->touch();
+	      index.push_back(it->second);
+	    } else if (bit != breaders.end()) {
+	      bit->second->touch();
+	      index.push_back(bit->second);
+	    } else {
+	      index.push_back(&skipper);
+	    }
+	    if (id == "label" && inverter.get() != 0) {
+	      index.back() = inverter.get();
+	    }
+	  }
+	}
+	for (typename MapReaders::iterator it = breaders.begin();
+	     it != breaders.end(); ++it) {
+	  if (!it->second->touched()) {
+	    ErrorMessage msg;
+	    msg << "Map not found in file: " << it->first;
+	    throw IoParameterError(msg.message());
+	  }
+	}
+	for (typename MapReaders::iterator it = readers.begin();
+	     it != readers.end(); ++it) {
+	  if (!it->second->touched()) {
+	    ErrorMessage msg;
+	    msg << "Map not found in file: " << it->first;
+	    throw IoParameterError(msg.message());
+	  }
+	}
+	while (getline(is, line)) {	
+	  Node node = graph.addBNode();
+	  std::istringstream ls(line);
+	  for (int i = 0; i < int(index.size()); ++i) {
+	    index[i]->read(ls, node);
+	  }
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "BpNodeSet section not found in file: @bpnodeset " << name;
+      throw IoParameterError(msg.message());
+    }
+
+  public:
+
+    /// \brief Returns true if the nodeset can give back the node by its label.
+    ///
+    /// Returns true if the nodeset can give back the node by its label.
+    /// It is possible only if an "label" named map was read.
+    bool isLabelReader() const {
+      return inverter.get() != 0;
+    }
+
+    /// \brief Gives back the node by its label.
+    ///
+    /// It reads an id from the stream and gives back which node belongs to
+    /// it. It is possible only if there was read an "label" named map.
+    void readLabel(std::istream& is, Node& node) const {
+      node = inverter->read(is);
+    } 
+
+  private:
+
+    typedef std::map<std::string, _reader_bits::MapReaderBase<Node>*> 
+    MapReaders;
+    
+    MapReaders areaders, breaders, readers;
+   
+    Graph& graph;
+    std::string name;
+    _reader_bits::SkipReader<Node, DefaultSkipper> skipper;
+
+    std::auto_ptr<_reader_bits::MapInverterBase<Node> > inverter;
+  };
+
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading a graph's edgeset.
+  ///
+  /// The lemon format can store multiple graph edgesets with several maps.
+  /// The edgeset section's header line is \c \@edgeset \c edgeset_name, but the
+  /// \c edgeset_name may be empty.
+  ///
+  /// The first line of the section contains the names of the maps separated
+  /// with white spaces. Each next lines describes an edge in the edgeset. The
+  /// line contains the source and the target nodes' id and the mapped 
+  /// values for each map.
+  ///
+  /// If the edgeset contains an \c "label" named map then it will be regarded
+  /// as id map. This map should contain only unique values and when the 
+  /// \c readLabel() member will read a value from the given stream it will
+  /// give back that edge which is mapped to this value.
+  ///
+  /// The edgeset reader needs a node id reader to identify which nodes
+  /// have to be connected. If a NodeSetReader reads an "label" named map,
+  /// it will be able to resolve the nodes by ids.
+  ///
+  /// \relates LemonReader
+  template <typename _Graph, typename _Traits = DefaultReaderTraits>
+  class EdgeSetReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Traits::Skipper DefaultSkipper;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for EdgeSetReader. It creates the EdgeSetReader and
+    /// attach it into the given LemonReader. The edgeset reader will
+    /// add the read edges to the given Graph. It will use the given
+    /// node id reader to read the source and target nodes of the edges.
+    /// The reader will read the section only if the \c _name and the 
+    /// \c edgset_name are the same. 
+    template <typename NodeLabelReader>
+    EdgeSetReader(LemonReader& _reader, 
+		  Graph& _graph, 
+		  const NodeLabelReader& _nodeLabelReader, 
+		  const std::string& _name = std::string(),
+		  const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : Parent(_reader), graph(_graph), name(_name), skipper(_skipper) {
+      checkConcept<_reader_bits::ItemLabelReader<Node>, NodeLabelReader>();
+      nodeLabelReader.reset(new _reader_bits::
+			 LabelReader<Node, NodeLabelReader>(_nodeLabelReader));
+    }
+    /// \brief Destructor.
+    ///
+    /// Destructor for EdgeSetReader.
+    virtual ~EdgeSetReader() {
+      for (typename MapReaders::iterator it = readers.begin(); 
+	   it != readers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    EdgeSetReader(const EdgeSetReader&);
+    void operator=(const EdgeSetReader&);
+
+  public:
+
+    /// \brief Add a new edge map reader command for the reader.
+    ///
+    /// Add a new edge map reader command for the reader.
+    template <typename Map>
+    EdgeSetReader& readEdgeMap(std::string label, Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    EdgeSetReader& readEdgeMap(std::string label, const Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new edge map reader command for the reader.
+    ///
+    /// Add a new edge map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    EdgeSetReader& readEdgeMap(std::string label, Map& map, 
+                               const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    EdgeSetReader& readEdgeMap(std::string label, const Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    EdgeSetReader& _readMap(std::string label, MapParameter map, 
+			    const ItemReader& ir = ItemReader()) {
+      checkConcept<concepts::WriteMap<Edge, typename Map::Value>, Map>();
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for edge map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(
+	make_pair(label, new _reader_bits::
+		  MapReader<Edge, Map, ItemReader>(map, ir)));
+      return *this;
+    }
+
+  public:
+
+    /// \brief Add a new edge map skipper command for the reader.
+    ///
+    /// Add a new edge map skipper command for the reader.
+    template <typename ItemReader>
+    EdgeSetReader& skipEdgeMap(std::string label, 
+			       const ItemReader& ir = ItemReader()) {
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for edge map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, new _reader_bits::
+			       SkipReader<Edge, ItemReader>(ir)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line starts with \c \@edgeset,
+    /// and the header line's name and the edgeset's name are the same.
+    /// The sections with \@uedgeset head line could be read with this
+    /// section reader too.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return (command == "@edgeset" || command == "@uedgeset") && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      if (!nodeLabelReader->isLabelReader()) {
+	throw DataFormatError("Cannot find nodeset or label map");
+      }
+      std::vector<_reader_bits::MapReaderBase<Edge>* > index;
+      std::string line;
+
+      {
+        getline(is, line);
+        std::istringstream ls(line);	
+        std::string id;
+        while (ls >> id) {
+          typename MapReaders::iterator it = readers.find(id);
+          if (it != readers.end()) {
+            index.push_back(it->second);
+            it->second->touch();
+          } else {
+            index.push_back(&skipper);
+          }
+          if (id == "label") {
+            inverter.reset(index.back()->getInverter());
+            index.back() = inverter.get();
+          }
+        }
+      }
+      for (typename MapReaders::iterator it = readers.begin();
+	   it != readers.end(); ++it) {
+	if (!it->second->touched()) {
+	  ErrorMessage msg;
+	  msg << "Map not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}
+      }
+      while (getline(is, line)) {	
+	std::istringstream ls(line);
+	Node from = nodeLabelReader->read(ls);
+	Node to = nodeLabelReader->read(ls);
+	Edge edge = graph.addEdge(from, to);
+	for (int i = 0; i < int(index.size()); ++i) {
+	  index[i]->read(ls, edge);
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "EdgeSet section not found in file: @edgeset " << name;
+      throw IoParameterError(msg.message());
+    }
+
+  public:
+
+    /// \brief Returns true if the edgeset can give back the edge by its label.
+    ///
+    /// Returns true if the edgeset can give back the edge by its label.
+    /// It is possible only if an "label" named map was read.
+    bool isLabelReader() const {
+      return inverter.get() != 0;
+    }
+
+    /// \brief Gives back the edge by its label.
+    ///
+    /// It reads an id from the stream and gives back which edge belongs to
+    /// it. It is possible only if there was read an "label" named map.
+    void readLabel(std::istream& is, Edge& edge) const {
+      edge = inverter->read(is);
+    } 
+
+  private:
+
+    typedef std::map<std::string, _reader_bits::MapReaderBase<Edge>*> 
+    MapReaders;
+    
+    MapReaders readers;
+   
+    Graph& graph;   
+    std::string name;
+    _reader_bits::SkipReader<Edge, DefaultSkipper> skipper;
+
+    std::auto_ptr<_reader_bits::MapInverterBase<Edge> > inverter;
+    std::auto_ptr<_reader_bits::LabelReaderBase<Node> > nodeLabelReader;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading a undirected graph's edgeset.
+  ///
+  /// The lemon format can store multiple undirected edgesets with several 
+  /// maps. The undirected edgeset section's header line is \c \@uedgeset 
+  /// \c uedgeset_name, but the \c uedgeset_name may be empty.
+  ///
+  /// The first line of the section contains the names of the maps separated
+  /// with white spaces. Each next lines describes an edge in the edgeset. The
+  /// line contains the connected nodes' id and the mapped values for each map.
+  ///
+  /// The section can handle the directed as a syntactical sugar. Two
+  /// undirected edge map describes one directed edge map. This two maps
+  /// are the forward map and the backward map and the names of this map
+  /// is near the same just with a prefix \c '+' or \c '-' character 
+  /// difference.
+  ///
+  /// If the edgeset contains an \c "label" named map then it will be regarded
+  /// as id map. This map should contain only unique values and when the 
+  /// \c readLabel() member will read a value from the given stream it will
+  /// give back that uicted edge which is mapped to this value.
+  ///
+  /// The undirected edgeset reader needs a node id reader to identify which 
+  /// nodes have to be connected. If a NodeSetReader reads an "label" named 
+  /// map, it will be able to resolve the nodes by ids.
+  ///
+  /// \relates LemonReader
+  template <typename _Graph, typename _Traits = DefaultReaderTraits>
+  class UEdgeSetReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+    typedef typename Traits::Skipper DefaultSkipper;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for UEdgeSetReader. It creates the UEdgeSetReader 
+    /// and attach it into the given LemonReader. The undirected edgeset 
+    /// reader will add the read undirected edges to the given Graph. It 
+    /// will use the given node id reader to read the source and target 
+    /// nodes of the edges. The reader will read the section only if the 
+    /// \c _name and the \c uedgset_name are the same. 
+    template <typename NodeLabelReader>
+    UEdgeSetReader(LemonReader& _reader, 
+		       Graph& _graph, 
+		       const NodeLabelReader& _nodeLabelReader, 
+		       const std::string& _name = std::string(),
+		       const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : Parent(_reader), graph(_graph), name(_name), skipper(_skipper) {
+      checkConcept<_reader_bits::ItemLabelReader<Node>, NodeLabelReader>();
+      nodeLabelReader.reset(new _reader_bits::
+			 LabelReader<Node, NodeLabelReader>(_nodeLabelReader));
+    }
+    /// \brief Destructor.
+    ///
+    /// Destructor for UEdgeSetReader.
+    virtual ~UEdgeSetReader() {
+      for (typename MapReaders::iterator it = readers.begin(); 
+	   it != readers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    UEdgeSetReader(const UEdgeSetReader&);
+    void operator=(const UEdgeSetReader&);
+
+  public:
+
+    /// \brief Add a new undirected edge map reader command for the reader.
+    ///
+    /// Add a new edge undirected map reader command for the reader.
+    template <typename Map>
+    UEdgeSetReader& readUEdgeMap(std::string label, Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map, 
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    UEdgeSetReader& readUEdgeMap(std::string label, const Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map, 
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new undirected edge map reader command for the reader.
+    ///
+    /// Add a new edge undirected map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    UEdgeSetReader& readUEdgeMap(std::string label, Map& map, 
+                                 const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    UEdgeSetReader& readUEdgeMap(std::string label, const Map& map, 
+                                 const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type >
+	(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    UEdgeSetReader& _readMap(std::string label, MapParameter map,
+                             const ItemReader& ir = ItemReader()) {
+      checkConcept<concepts::WriteMap<UEdge, typename Map::Value>, Map>();
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for edge map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(
+	make_pair(label, new _reader_bits::
+		  MapReader<UEdge, Map, ItemReader>(map, ir)));
+      return *this;
+    }
+
+  public:
+
+    /// \brief Add a new undirected edge map skipper command for the reader.
+    ///
+    /// Add a new undirected edge map skipper command for the reader.
+    template <typename ItemReader>
+    UEdgeSetReader& skipUEdgeMap(std::string label, 
+                                 const ItemReader& ir = ItemReader()) {
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for node map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, new _reader_bits::
+			       SkipReader<UEdge, ItemReader>(ir)));
+      return *this;
+    }
+
+    /// \brief Add a new directed edge map reader command for the reader.
+    ///
+    /// Add a new directed edge map reader command for the reader.
+    template <typename Map>
+    UEdgeSetReader& readEdgeMap(std::string label, Map& map) {
+      return _readDirMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    UEdgeSetReader& readEdgeMap(std::string label, const Map& map) {
+      return _readDirMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new directed edge map reader command for the reader.
+    ///
+    /// Add a new directed edge map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    UEdgeSetReader& readEdgeMap(std::string label, Map& map, 
+				    const ItemReader& ir = ItemReader()) {
+      return _readDirMap<ItemReader, Map, 
+        typename _reader_bits::Arg<Map>::Type>(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    UEdgeSetReader& readEdgeMap(std::string label, const Map& map, 
+				    const ItemReader& ir = ItemReader()) {
+      return _readDirMap<ItemReader, Map, 
+        typename _reader_bits::Arg<Map>::Type>(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    UEdgeSetReader& _readDirMap(std::string label, MapParameter map,
+				    const ItemReader& ir = ItemReader()) { 
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      checkConcept<concepts::WriteMap<Edge, typename Map::Value>, Map>();
+      readUEdgeMap("+" + label, 
+                   _reader_bits::forwardComposeMap(graph, map), ir);
+      readUEdgeMap("-" + label, 
+                   _reader_bits::backwardComposeMap(graph, map), ir);
+      return *this;      
+    }
+
+  public:
+
+    /// \brief Add a new directed edge map skipper command for the reader.
+    ///
+    /// Add a new directed edge map skipper command for the reader.
+    template <typename ItemReader>
+    UEdgeSetReader& skipEdgeMap(std::string label, 
+                                const ItemReader& ir = ItemReader()) {
+      skipUEdgeMap("+" + label, ir);
+      skipUEdgeMap("-" + label, ir);
+      return *this;
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line starts with \c \@uedgeset,
+    /// and the header line's name and the edgeset's name are the same.
+    /// The sections with \@edgeset head line could be read with this
+    /// section reader too.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return (command == "@edgeset" || command == "@uedgeset") && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      if (!nodeLabelReader->isLabelReader()) {
+	throw DataFormatError("Cannot find nodeset or label map");
+      }
+      std::vector<_reader_bits::MapReaderBase<UEdge>* > index;
+      std::string line;
+
+      {
+        getline(is, line);
+        std::istringstream ls(line);	
+        std::string id;
+        while (ls >> id) {
+          typename MapReaders::iterator it = readers.find(id);
+          if (it != readers.end()) {
+            index.push_back(it->second);
+            it->second->touch();
+          } else {
+            index.push_back(&skipper);
+          }
+          if (id == "label") {
+            inverter.reset(index.back()->getInverter());
+            index.back() = inverter.get();
+          }
+        }
+        for (typename MapReaders::iterator it = readers.begin();
+             it != readers.end(); ++it) {
+          if (!it->second->touched()) {
+            ErrorMessage msg;
+            msg << "Map not found in file: " << it->first;
+            throw IoParameterError(msg.message());
+          }
+        }
+      }
+      while (getline(is, line)) {	
+	std::istringstream ls(line);
+	Node from = nodeLabelReader->read(ls);
+	Node to = nodeLabelReader->read(ls);
+	UEdge edge = graph.addEdge(from, to);
+	for (int i = 0; i < int(index.size()); ++i) {
+	  index[i]->read(ls, edge);
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "UEdgeSet section not found in file: @uedgeset " << name;
+      throw IoParameterError(msg.message());
+    }
+
+  public:
+
+    /// \brief Returns true if the edgeset can give back the edge by its label.
+    ///
+    /// Returns true if the edgeset can give back the undirected edge by its 
+    /// id. It is possible only if an "label" named map was read.
+    bool isLabelReader() const {
+      return inverter.get() != 0;
+    }
+
+    /// \brief Gives back the undirected edge by its label.
+    ///
+    /// It reads an id from the stream and gives back which undirected edge 
+    /// belongs to it. It is possible only if there was read an "label" named map.
+    void readLabel(std::istream& is, UEdge& uedge) const {
+      uedge = inverter->read(is);
+    } 
+
+    /// \brief Gives back the directed edge by its label.
+    ///
+    /// It reads an id from the stream and gives back which directed edge 
+    /// belongs to it. The directed edge id is the \c '+' or \c '-' character
+    /// and the undirected edge id. It is possible only if there was read 
+    /// an "label" named map.
+    void readLabel(std::istream& is, Edge& edge) const {
+      char c;
+      is >> c;
+      UEdge uedge = inverter->read(is);
+      if (c == '+') {
+	edge = graph.direct(uedge, true);
+      } else if (c == '-') {
+        edge = graph.direct(uedge, false);
+      } else {
+	throw DataFormatError("Wrong id format for edge "
+			      "in undirected edgeset");
+      }
+    } 
+
+  private:
+
+    typedef std::map<std::string, 
+		     _reader_bits::MapReaderBase<UEdge>*> MapReaders;
+    MapReaders readers;
+   
+    Graph& graph;   
+    std::string name;
+    _reader_bits::SkipReader<UEdge, DefaultSkipper> skipper;
+
+    std::auto_ptr<_reader_bits::MapInverterBase<UEdge> > inverter;
+    std::auto_ptr<_reader_bits::LabelReaderBase<Node> > nodeLabelReader;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading labeled nodes.
+  ///
+  /// The nodes section's header line is \c \@nodes \c nodes_name, but the
+  /// \c nodes_name may be empty.
+  ///
+  /// Each line in the section contains the name of the node 
+  /// and then the node id. 
+  ///
+  /// \relates LemonReader
+  template <typename _Graph>
+  class NodeReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+  public:
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor for NodeReader. It creates the NodeReader and
+    /// attach it into the given LemonReader. It will use the given
+    /// node id reader to give back the nodes. The reader will read the 
+    /// section only if the \c _name and the \c nodes_name are the same. 
+    template <typename _LabelReader>
+    NodeReader(LemonReader& _reader, const _LabelReader& _labelReader, 
+	       const std::string& _name = std::string()) 
+      : Parent(_reader), name(_name) {
+      checkConcept<_reader_bits::ItemLabelReader<Node>, _LabelReader>();
+      nodeLabelReader.reset(new _reader_bits::
+			 LabelReader<Node, _LabelReader>(_labelReader));
+    }
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for NodeReader.
+    virtual ~NodeReader() {}
+
+  private:
+    NodeReader(const NodeReader&);
+    void operator=(const NodeReader&);
+
+  public:
+
+    /// \brief Add a node reader command for the NodeReader.
+    ///
+    /// Add a node reader command for the NodeReader.
+    void readNode(std::string label, Node& item) {
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for node: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, _reader_bits::ItemStore<Node>(item)));
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line start with \c \@nodes,
+    /// and the header line's name and the reader's name are the same.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return command == "@nodes" && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      if (!nodeLabelReader->isLabelReader()) {
+	throw DataFormatError("Cannot find nodeset or label map");
+      }
+      std::string line;
+      while (getline(is, line)) {
+	std::istringstream ls(line);
+	std::string id;
+	ls >> id;
+	typename NodeReaders::iterator it = readers.find(id);
+	if (it != readers.end()) {
+	  it->second.read(nodeLabelReader->read(ls));
+	  it->second.touch();
+	}	
+      }
+      for (typename NodeReaders::iterator it = readers.begin();
+	   it != readers.end(); ++it) {
+	if (!it->second.touched()) {
+	  ErrorMessage msg;
+	  msg << "Node not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "Nodes section not found in file: @nodes " << name;
+      throw IoParameterError(msg.message());
+    }
+    
+  private:
+
+    std::string name;
+
+    typedef std::map<std::string, _reader_bits::ItemStore<Node> > NodeReaders;
+    NodeReaders readers;
+    std::auto_ptr<_reader_bits::LabelReaderBase<Node> > nodeLabelReader;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading labeled edges.
+  ///
+  /// The edges section's header line is \c \@edges \c edges_name, but the
+  /// \c edges_name may be empty.
+  ///
+  /// Each line in the section contains the name of the edge 
+  /// and then the edge id. 
+  ///
+  /// \relates LemonReader
+  template <typename _Graph>
+  class EdgeReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+  public:
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor for EdgeReader. It creates the EdgeReader and
+    /// attach it into the given LemonReader. It will use the given
+    /// edge id reader to give back the edges. The reader will read the 
+    /// section only if the \c _name and the \c edges_name are the same. 
+    template <typename _LabelReader>
+    EdgeReader(LemonReader& _reader, const _LabelReader& _labelReader, 
+	       const std::string& _name = std::string()) 
+      : Parent(_reader), name(_name) {
+      checkConcept<_reader_bits::ItemLabelReader<Edge>, _LabelReader>();
+      edgeLabelReader.reset(new _reader_bits::
+			 LabelReader<Edge, _LabelReader>(_labelReader));
+    }
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for EdgeReader.
+    virtual ~EdgeReader() {}
+  private:
+    EdgeReader(const EdgeReader&);
+    void operator=(const EdgeReader&);
+
+  public:
+
+    /// \brief Add an edge reader command for the EdgeReader.
+    ///
+    /// Add an edge reader command for the EdgeReader.
+    void readEdge(std::string label, Edge& item) {
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for edge: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, _reader_bits::ItemStore<Edge>(item)));
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line start with \c \@edges,
+    /// and the header line's name and the reader's name are the same.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return command == "@edges" && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      if (!edgeLabelReader->isLabelReader()) {
+	throw DataFormatError("Cannot find edgeset or label map");
+      }
+      std::string line;
+      while (getline(is, line)) {
+	std::istringstream ls(line);
+	std::string id;
+	ls >> id;
+	typename EdgeReaders::iterator it = readers.find(id);
+	if (it != readers.end()) {
+	  it->second.read(edgeLabelReader->read(ls));
+	  it->second.touch();
+	}	
+      }
+      for (typename EdgeReaders::iterator it = readers.begin();
+	   it != readers.end(); ++it) {
+	if (!it->second.touched()) {
+	  ErrorMessage msg;
+	  msg << "Edge not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "Edges section not found in file: @edges " << name;
+      throw IoParameterError(msg.message());
+    }
+    
+  private:
+
+    std::string name;
+
+    typedef std::map<std::string, _reader_bits::ItemStore<Edge> > EdgeReaders;
+    EdgeReaders readers;
+    std::auto_ptr<_reader_bits::LabelReaderBase<Edge> > edgeLabelReader;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading labeled undirected edges.
+  ///
+  /// The undirected edges section's header line is \c \@uedges 
+  /// \c uedges_name, but the \c uedges_name may be empty.
+  ///
+  /// Each line in the section contains the name of the undirected edge 
+  /// and then the undirected edge id. 
+  ///
+  /// \relates LemonReader
+  template <typename _Graph>
+  class UEdgeReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+  public:
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor for UEdgeReader. It creates the UEdgeReader and
+    /// attach it into the given LemonReader. It will use the given
+    /// undirected edge id reader to give back the edges. The reader will 
+    /// read the section only if the \c _name and the \c uedges_name are 
+    /// the same. 
+    template <typename _LabelReader>
+    UEdgeReader(LemonReader& _reader, const _LabelReader& _labelReader, 
+	       const std::string& _name = std::string()) 
+      : Parent(_reader), name(_name) {
+      checkConcept<_reader_bits::ItemLabelReader<UEdge>, _LabelReader>();
+      checkConcept<_reader_bits::ItemLabelReader<Edge>, _LabelReader>();
+      uedgeLabelReader.reset(new _reader_bits::
+			     LabelReader<UEdge, _LabelReader>(_labelReader));
+      edgeLabelReader.reset(new _reader_bits::
+			    LabelReader<Edge, _LabelReader>(_labelReader));
+    }
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for UEdgeReader.
+    virtual ~UEdgeReader() {}
+  private:
+    UEdgeReader(const UEdgeReader&);
+    void operator=(const UEdgeReader&);
+
+  public:
+
+    /// \brief Add an undirected edge reader command for the UEdgeReader.
+    ///
+    /// Add an undirected edge reader command for the UEdgeReader.
+    void readUEdge(std::string label, UEdge& item) {
+      if (uedgeReaders.find(label) != uedgeReaders.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for undirected edge: " << label;
+	throw IoParameterError(msg.message());
+      }
+      uedgeReaders.insert(make_pair(label, _reader_bits::
+					ItemStore<UEdge>(item)));
+    }
+
+    /// \brief Add an edge reader command for the UEdgeReader.
+    ///
+    /// Add an edge reader command for the UEdgeReader.
+    void readEdge(std::string label, Edge& item) {
+      if (edgeReaders.find(label) != edgeReaders.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for edge: " << label;
+	throw IoParameterError(msg.message());
+      }
+      edgeReaders.insert(make_pair(label, _reader_bits::ItemStore<Edge>(item)));
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line start with \c \@edges,
+    /// and the header line's name and the reader's name are the same.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return command == "@uedges" && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      if (!edgeLabelReader->isLabelReader()) {
+	throw DataFormatError("Cannot find undirected edgeset or label map");
+      }
+      if (!uedgeLabelReader->isLabelReader()) {
+	throw DataFormatError("Cannot find undirected edgeset or label map");
+      }
+      std::string line;
+      while (getline(is, line)) {
+	std::istringstream ls(line);
+	std::string id;
+	ls >> id;
+	{
+	  typename UEdgeReaders::iterator it = uedgeReaders.find(id);
+	  if (it != uedgeReaders.end()) {
+	    it->second.read(uedgeLabelReader->read(ls));
+	    it->second.touch();
+	    continue;
+	  }	
+	} {
+	  typename EdgeReaders::iterator it = edgeReaders.find(id);
+	  if (it != edgeReaders.end()) {
+	    it->second.read(edgeLabelReader->read(ls));
+	    it->second.touch();
+	    continue;
+	  }	
+	}
+      }
+      for (typename EdgeReaders::iterator it = edgeReaders.begin();
+	   it != edgeReaders.end(); ++it) {
+	if (!it->second.touched()) {
+	  ErrorMessage msg;
+	  msg << "Edge not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}
+      }
+      for (typename UEdgeReaders::iterator it = uedgeReaders.begin();
+	   it != uedgeReaders.end(); ++it) {
+	if (!it->second.touched()) {
+	  ErrorMessage msg;
+	  msg << "UEdge not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (edgeReaders.empty() && uedgeReaders.empty()) return;
+      ErrorMessage msg;
+      msg << "UEdges section not found in file: @uedges " << name;
+      throw IoParameterError(msg.message());
+    }
+    
+  private:
+
+    std::string name;
+
+    typedef std::map<std::string, 
+		     _reader_bits::ItemStore<UEdge> > UEdgeReaders;
+    UEdgeReaders uedgeReaders;
+    std::auto_ptr<_reader_bits::LabelReaderBase<UEdge> > uedgeLabelReader;
+
+    typedef std::map<std::string, _reader_bits::ItemStore<Edge> > EdgeReaders;
+    EdgeReaders edgeReaders;
+    std::auto_ptr<_reader_bits::LabelReaderBase<Edge> > edgeLabelReader;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for attributes.
+  ///
+  /// The lemon format can store multiple attribute set. Each set has
+  /// the header line \c \@attributes \c attributeset_name, but the 
+  /// attributeset_name may be empty.
+  ///
+  /// The attributeset section contains several lines. Each of them starts
+  /// with an attribute and then a the value for the id.
+  ///
+  /// \relates LemonReader
+  template <typename _Traits = DefaultReaderTraits>
+  class AttributeReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+    typedef _Traits Traits; 
+  public:
+    /// \brief Constructor.
+    ///
+    /// Constructor for AttributeReader. It creates the AttributeReader and
+    /// attach it into the given LemonReader. The reader process a section
+    /// only if the \c section_name and the \c _name are the same.
+    AttributeReader(LemonReader& _reader, 
+		    const std::string& _name = std::string()) 
+      : Parent(_reader), name(_name) {}
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for AttributeReader.
+    virtual ~AttributeReader() {
+      for (typename Readers::iterator it = readers.begin(); 
+	   it != readers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    AttributeReader(const AttributeReader&);
+    void operator=(AttributeReader&);
+
+  public:
+    /// \brief Add an attribute reader command for the reader.
+    ///
+    /// Add an attribute reader command for the reader.
+    template <typename Value>
+    AttributeReader& readAttribute(const std::string& label, Value& value) {
+      return readAttribute<typename Traits::template Reader<Value> >
+	(label, value);
+    }
+
+    /// \brief Add an attribute reader command for the reader.
+    ///
+    /// Add an attribute reader command for the reader.
+    template <typename ItemReader, typename Value>
+    AttributeReader& readAttribute(const std::string& label, Value& value,
+				   const ItemReader& ir = ItemReader()) {
+      checkConcept<_reader_bits::ItemReader<Value>, ItemReader>();
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for attribute: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, new _reader_bits::
+			       ValueReader<Value, ItemReader>(value, ir)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line start with \c \@attributes,
+    /// and the header line's id and the attributeset's id are the same.
+    bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return command == "@attributes" && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    void read(std::istream& is) {
+      std::string line;
+      while (getline(is, line)) {
+	std::istringstream ls(line);
+	std::string id;
+	ls >> id;
+	typename Readers::iterator it = readers.find(id);
+	if (it != readers.end()) {
+	  it->second->read(ls);
+ 	  it->second->touch();
+	}
+      }
+      for (typename Readers::iterator it = readers.begin();
+	   it != readers.end(); ++it) {
+	if (!it->second->touched()) {
+	  ErrorMessage msg;
+	  msg << "Attribute not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}	
+      }
+    }    
+    
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "Attribute section not found in file: @attributes " << name;
+      throw IoParameterError(msg.message());
+    }
+
+  private:
+    std::string name;
+
+    typedef std::map<std::string, _reader_bits::ValueReaderBase*> Readers;
+    Readers readers;  
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading extra node maps.
+  ///
+  /// The lemon format can store maps in the nodeset sections. This
+  /// class let you make distinict section to store maps.  The main
+  /// purpose of this class is a logical separation of some maps. The
+  /// other useful application could be to store paths in node maps.
+  ///
+  /// The first line of the section contains the names of the maps
+  /// separated with white spaces. Each next line describes an item
+  /// in the itemset, and contains in the first column the label of
+  /// the item and then the mapped values for each map.
+  ///
+  /// \relates LemonReader
+  template <typename _Graph, typename _Traits = DefaultReaderTraits>
+  class NodeMapReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef _Traits Traits;
+    typedef typename Traits::Skipper DefaultSkipper;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for NodeMapReader. It creates the NodeMapReader and
+    /// attach it into the given LemonReader. The reader will read
+    /// the section when the \c section_name and the \c _name are the same.
+    template <typename _LabelReader>
+    NodeMapReader(LemonReader& _reader, 
+		  const Graph& _graph, 
+		  const _LabelReader& _labelReader,
+		  const std::string& _name = std::string(),
+		  const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : Parent(_reader), graph(_graph), name(_name), skipper(_skipper) {
+      labelReader.reset(new _reader_bits::
+			LabelReader<Node, _LabelReader>(_labelReader));
+    } 
+
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for NodeMapReader.
+    virtual ~NodeMapReader() {
+      for (typename MapReaders::iterator it = readers.begin(); 
+	   it != readers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    NodeMapReader(const NodeMapReader&);
+    void operator=(const NodeMapReader&);
+  
+  public:
+
+    /// \brief Add a new node map reader command for the reader.
+    ///
+    /// Add a new node map reader command for the reader.
+    template <typename Map>
+    NodeMapReader& readNodeMap(std::string label, Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    NodeMapReader& readNodeMap(std::string label, const Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new node map reader command for the reader.
+    ///
+    /// Add a new node map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    NodeMapReader& readNodeMap(std::string label, Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    NodeMapReader& readNodeMap(std::string label, const Map& map, 
+			       const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    NodeMapReader& _readMap(std::string label, MapParameter map, 
+			   const ItemReader& ir = ItemReader()) {
+      checkConcept<concepts::WriteMap<Node, typename Map::Value>, Map>();
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for map: " << label;
+	throw IoParameterError(msg.message());
+      }      
+      readers.insert(
+	make_pair(label, new _reader_bits::
+		  MapReader<Node, Map, ItemReader>(map, ir)));
+      return *this;
+    }
+
+  public:
+
+    /// \brief Add a new node map skipper command for the reader.
+    ///
+    /// Add a new node map skipper command for the reader.
+    template <typename ItemReader>
+    NodeMapReader& skipNodeMap(std::string label, 
+			       const ItemReader& ir = ItemReader()) {
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, new _reader_bits::
+			       SkipReader<Node, ItemReader>(ir)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line starts with \c \@mapset,
+    /// and the header line's name and the mapset's name are the same.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return command == "@nodemaps" && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      std::vector<_reader_bits::MapReaderBase<Node>* > index;
+      std::string line;
+
+      {
+        getline(is, line);
+        std::istringstream ls(line);
+        std::string id;
+        while (ls >> id) {
+          typename MapReaders::iterator it = readers.find(id);
+          if (it != readers.end()) {
+            it->second->touch();
+            index.push_back(it->second);
+          } else {
+            index.push_back(&skipper);
+          }
+        }
+      }
+      for (typename MapReaders::iterator it = readers.begin();
+	   it != readers.end(); ++it) {
+	if (!it->second->touched()) {
+	  ErrorMessage msg;
+	  msg << "Map not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}
+      }
+      while (getline(is, line)) {	
+	std::istringstream ls(line);
+	Node node = labelReader->read(ls);
+	for (int i = 0; i < int(index.size()); ++i) {
+	  index[i]->read(ls, node);
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "NodeMap section not found in file: @nodemaps " << name;
+      throw IoParameterError(msg.message());
+    }
+
+  private:
+
+    typedef std::map<std::string, _reader_bits::MapReaderBase<Node>*> MapReaders;
+    MapReaders readers;
+   
+    const Graph& graph;   
+    std::string name;
+    _reader_bits::SkipReader<Node, DefaultSkipper> skipper;
+    std::auto_ptr<_reader_bits::LabelReaderBase<Node> > labelReader;
+
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading extra edge maps.
+  ///
+  /// The lemon format can store maps in the edgeset sections. This
+  /// class let you make distinict section to store maps.  The main
+  /// purpose of this class is a logical separation of some maps. The
+  /// other useful application could be to store paths in edge maps.
+  ///
+  /// The first line of the section contains the names of the maps
+  /// separated with white spaces. Each next line describes an item
+  /// in the itemset, and contains in the first column the label of
+  /// the item and then the mapped values for each map.
+  ///
+  /// \relates LemonReader
+  template <typename _Graph, typename _Traits = DefaultReaderTraits>
+  class EdgeMapReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+    typedef _Traits Traits;
+    typedef typename Traits::Skipper DefaultSkipper;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for EdgeMapReader. It creates the EdgeMapReader and
+    /// attach it into the given LemonReader. The reader will read
+    /// the section when the \c section_name and the \c _name are the same.
+    template <typename _LabelReader>
+    EdgeMapReader(LemonReader& _reader, 
+		   const Graph& _graph, 
+		   const _LabelReader& _labelReader,
+		   const std::string& _name = std::string(),
+		   const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : Parent(_reader), graph(_graph), name(_name), skipper(_skipper) {
+      labelReader.reset(new _reader_bits::
+			LabelReader<Edge, _LabelReader>(_labelReader));
+    } 
+
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for EdgeMapReader.
+    virtual ~EdgeMapReader() {
+      for (typename MapReaders::iterator it = readers.begin(); 
+	   it != readers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    EdgeMapReader(const EdgeMapReader&);
+    void operator=(const EdgeMapReader&);
+  
+  public:
+
+    /// \brief Add a new edge map reader command for the reader.
+    ///
+    /// Add a new edge map reader command for the reader.
+    template <typename Map>
+    EdgeMapReader& readEdgeMap(std::string label, Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    EdgeMapReader& readEdgeMap(std::string label, const Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new edge map reader command for the reader.
+    ///
+    /// Add a new edge map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    EdgeMapReader& readEdgeMap(std::string label, Map& map, 
+			  const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    EdgeMapReader& readEdgeMap(std::string label, const Map& map, 
+			  const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    EdgeMapReader& _readMap(std::string label, MapParameter map, 
+				const ItemReader& ir = ItemReader()) {
+      checkConcept<concepts::WriteMap<Edge, typename Map::Value>, Map>();
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for map: " << label;
+	throw IoParameterError(msg.message());
+      }      
+      readers.insert(
+	make_pair(label, new _reader_bits::
+		  MapReader<Edge, Map, ItemReader>(map, ir)));
+      return *this;
+    }
+
+  public:
+
+    /// \brief Add a new edge map skipper command for the reader.
+    ///
+    /// Add a new edge map skipper command for the reader.
+    template <typename ItemReader>
+    EdgeMapReader& skipEdgeMap(std::string label, 
+			  const ItemReader& ir = ItemReader()) {
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, new _reader_bits::
+			       SkipReader<Edge, ItemReader>(ir)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line starts with \c \@mapset,
+    /// and the header line's name and the mapset's name are the same.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return (command == "@edgemaps" || command == "@uedgemaps") && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      std::vector<_reader_bits::MapReaderBase<Edge>* > index;
+      std::string line;
+
+      {
+        getline(is, line);
+        std::istringstream ls(line);
+        std::string id;
+        while (ls >> id) {
+          typename MapReaders::iterator it = readers.find(id);
+          if (it != readers.end()) {
+            it->second->touch();
+            index.push_back(it->second);
+          } else {
+            index.push_back(&skipper);
+          }
+        }
+      }
+      for (typename MapReaders::iterator it = readers.begin();
+	   it != readers.end(); ++it) {
+	if (!it->second->touched()) {
+	  ErrorMessage msg;
+	  msg << "Map not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}
+      }
+      while (getline(is, line)) {	
+	std::istringstream ls(line);
+	Edge edge = labelReader->read(ls);
+	for (int i = 0; i < int(index.size()); ++i) {
+	  index[i]->read(ls, edge);
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "EdgeMap section not found in file: @edgemaps " << name;
+      throw IoParameterError(msg.message());
+    }
+
+  private:
+
+    typedef std::map<std::string, _reader_bits::MapReaderBase<Edge>*> MapReaders;
+    MapReaders readers;
+   
+    const Graph& graph;   
+    std::string name;
+    _reader_bits::SkipReader<Edge, DefaultSkipper> skipper;
+    std::auto_ptr<_reader_bits::LabelReaderBase<Edge> > labelReader;
+
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for reading extra undirected edge maps.
+  ///
+  /// The lemon format can store maps in the uedgeset sections. This
+  /// class let you make distinict section to store maps.  The main
+  /// purpose of this class is a logical separation of some maps. The
+  /// other useful application could be to store paths in undirected
+  /// edge maps.
+  ///
+  /// The first line of the section contains the names of the maps
+  /// separated with white spaces. Each next line describes an item
+  /// in the itemset, and contains in the first column the label of
+  /// the item and then the mapped values for each map.
+  ///
+  /// \relates LemonReader
+  template <typename _Graph, typename _Traits = DefaultReaderTraits>
+  class UEdgeMapReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+    typedef _Traits Traits;
+    typedef typename Traits::Skipper DefaultSkipper;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for UEdgeMapReader. It creates the UEdgeMapReader and
+    /// attach it into the given LemonReader. The reader will read
+    /// the section when the \c section_name and the \c _name are the same.
+    template <typename _LabelReader>
+    UEdgeMapReader(LemonReader& _reader, const Graph& _graph, 
+		   const _LabelReader& _labelReader,
+		   const std::string& _name = std::string(),
+		   const DefaultSkipper& _skipper = DefaultSkipper()) 
+      : Parent(_reader), graph(_graph), name(_name), skipper(_skipper) {
+      labelReader.reset(new _reader_bits::
+			LabelReader<UEdge, _LabelReader>(_labelReader));
+    } 
+
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for UEdgeMapReader.
+    virtual ~UEdgeMapReader() {
+      for (typename MapReaders::iterator it = readers.begin(); 
+	   it != readers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    UEdgeMapReader(const UEdgeMapReader&);
+    void operator=(const UEdgeMapReader&);
+  
+  public:
+
+    /// \brief Add a new undirected edge map reader command for the
+    /// reader.
+    ///
+    /// Add a new undirected edge map reader command for the reader.
+    template <typename Map>
+    UEdgeMapReader& readUEdgeMap(std::string label, Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    UEdgeMapReader& readUEdgeMap(std::string label, const Map& map) {
+      return _readMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new undirected edge map reader command for the
+    /// reader.
+    ///
+    /// Add a new undirected edge map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    UEdgeMapReader& readUEdgeMap(std::string label, Map& map, 
+			  const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    UEdgeMapReader& readUEdgeMap(std::string label, const Map& map, 
+			  const ItemReader& ir = ItemReader()) {
+      return _readMap<ItemReader, Map, typename _reader_bits::Arg<Map>::Type>
+	(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    UEdgeMapReader& _readMap(std::string label, MapParameter map, 
+				const ItemReader& ir = ItemReader()) {
+      checkConcept<concepts::WriteMap<Edge, typename Map::Value>, Map>();
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for map: " << label;
+	throw IoParameterError(msg.message());
+      }      
+      readers.insert(
+	make_pair(label, new _reader_bits::
+		  MapReader<UEdge, Map, ItemReader>(map, ir)));
+      return *this;
+    }
+
+  public:
+
+    /// \brief Add a new undirected edge map skipper command for the
+    /// reader.
+    ///
+    /// Add a new undirected edge map skipper command for the reader.
+    template <typename ItemReader>
+    UEdgeMapReader& skipUEdgeMap(std::string label, 
+			  const ItemReader& ir = ItemReader()) {
+      if (readers.find(label) != readers.end()) {
+	ErrorMessage msg;
+	msg << "Multiple read rule for map: " << label;
+	throw IoParameterError(msg.message());
+      }
+      readers.insert(make_pair(label, new _reader_bits::
+			       SkipReader<Edge, ItemReader>(ir)));
+      return *this;
+    }
+
+    /// \brief Add a new directed edge map reader command for the reader.
+    ///
+    /// Add a new directed edge map reader command for the reader.
+    template <typename Map>
+    UEdgeMapReader& readEdgeMap(std::string label, Map& map) {
+      return _readDirMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    template <typename Map>
+    UEdgeMapReader& readEdgeMap(std::string label, const Map& map) {
+      return _readDirMap<
+	typename Traits::template Reader<typename Map::Value>, Map,
+	typename _reader_bits::Arg<Map>::Type>(label, map);
+    }
+
+    /// \brief Add a new directed edge map reader command for the reader.
+    ///
+    /// Add a new directed edge map reader command for the reader.
+    template <typename ItemReader, typename Map>
+    UEdgeMapReader& readEdgeMap(std::string label, Map& map, 
+				    const ItemReader& ir = ItemReader()) {
+      return _readDirMap<ItemReader, Map, 
+        typename _reader_bits::Arg<Map>::Type>(label, map, ir);
+    }
+
+    template <typename ItemReader, typename Map>
+    UEdgeMapReader& readEdgeMap(std::string label, const Map& map, 
+				    const ItemReader& ir = ItemReader()) {
+      return _readDirMap<ItemReader, Map, 
+        typename _reader_bits::Arg<Map>::Type>(label, map, ir);
+    }
+
+  private:
+
+    template <typename ItemReader, typename Map, typename MapParameter>
+    UEdgeMapReader& _readDirMap(std::string label, MapParameter map,
+				    const ItemReader& ir = ItemReader()) { 
+      checkConcept<_reader_bits::ItemReader<typename Map::Value>, ItemReader>();
+      checkConcept<concepts::WriteMap<Edge, typename Map::Value>, Map>();
+      readUEdgeMap("+" + label, 
+                   _reader_bits::forwardComposeMap(graph, map), ir);
+      readUEdgeMap("-" + label, 
+                   _reader_bits::backwardComposeMap(graph, map), ir);
+      return *this;      
+    }
+
+  public:
+
+    /// \brief Add a new directed edge map skipper command for the reader.
+    ///
+    /// Add a new directed edge map skipper command for the reader.
+    template <typename ItemReader>
+    UEdgeMapReader& skipEdgeMap(std::string label, 
+                                const ItemReader& ir = ItemReader()) {
+      skipUEdgeMap("+" + label, ir);
+      skipUEdgeMap("-" + label, ir);
+      return *this;
+    }
+
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line starts with \c \@mapset,
+    /// and the header line's name and the mapset's name are the same.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return (command == "@edgemaps" || command == "@uedgemaps") && name == id;
+    }
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      std::vector<_reader_bits::MapReaderBase<UEdge>* > index;
+      std::string line;
+
+      {
+        getline(is, line);
+        std::istringstream ls(line);
+        std::string id;
+        while (ls >> id) {
+          typename MapReaders::iterator it = readers.find(id);
+          if (it != readers.end()) {
+            it->second->touch();
+            index.push_back(it->second);
+          } else {
+            index.push_back(&skipper);
+          }
+        }
+      }
+      for (typename MapReaders::iterator it = readers.begin();
+	   it != readers.end(); ++it) {
+	if (!it->second->touched()) {
+	  ErrorMessage msg;
+	  msg << "Map not found in file: " << it->first;
+	  throw IoParameterError(msg.message());
+	}
+      }
+      while (getline(is, line)) {	
+	std::istringstream ls(line);
+	UEdge uedge = labelReader->read(ls);
+	for (int i = 0; i < int(index.size()); ++i) {
+	  index[i]->read(ls, uedge);
+	}
+      }
+    }
+
+    virtual void missing() {
+      if (readers.empty()) return;
+      ErrorMessage msg;
+      msg << "UEdgeMap section not found in file: @uedgemaps " << name;
+      throw IoParameterError(msg.message());
+    }
+
+  private:
+
+    const Graph& graph;   
+    std::string name;
+
+    typedef std::map<std::string, 
+		     _reader_bits::MapReaderBase<UEdge>*> MapReaders;
+   
+    MapReaders readers;
+    _reader_bits::SkipReader<UEdge, DefaultSkipper> skipper;
+
+    std::auto_ptr<_reader_bits::LabelReaderBase<UEdge> > labelReader;
+
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionReader for retrieve what is in the file.
+  ///
+  /// SectionReader for retrieve what is in the file. If you want
+  /// to know which sections, maps and items are in the file
+  /// use the next code:
+  ///\code
+  /// LemonReader reader("input.lgf");
+  /// ContentReader content(reader);
+  /// reader.run();
+  ///\endcode
+  class ContentReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+  public:
+    /// \brief Constructor.
+    ///
+    /// Constructor for
+    ContentReader(LemonReader& _reader) : Parent(_reader) {}
+
+    /// \brief Desctructor.
+    ///
+    /// Desctructor.
+    virtual ~ContentReader() {}
+
+    /// \brief Gives back how many nodesets are in the file.
+    ///
+    /// Gives back how many nodesets are in the file.
+    int nodeSetNum() const {
+      return nodesets.size();
+    }
+
+    /// \brief Gives back the name of nodeset on the indiced position.
+    ///
+    /// Gives back the name of nodeset on the indiced position.
+    std::string nodeSetName(int index) const {
+      return nodesets[index].name;
+    }
+
+    /// \brief Gives back the map names of nodeset on the indiced position.
+    ///
+    /// Gives back the map names of nodeset on the indiced position.
+    const std::vector<std::string>& nodeSetMaps(int index) const {
+      return nodesets[index].items;
+    }
+
+    /// \brief Gives back how many edgesets are in the file.
+    ///
+    /// Gives back how many edgesets are in the file.
+    int edgeSetNum() const {
+      return edgesets.size();
+    }
+
+    /// \brief Gives back the name of edgeset on the indiced position.
+    ///
+    /// Gives back the name of edgeset on the indiced position.
+    std::string edgeSetName(int index) const {
+      return edgesets[index].name;
+    }
+
+    /// \brief Gives back the map names of edgeset on the indiced position.
+    ///
+    /// Gives back the map names of edgeset on the indiced position.
+    const std::vector<std::string>& edgeSetMaps(int index) const {
+      return edgesets[index].items;
+    }
+
+    /// \brief Gives back how many undirected edgesets are in the file.
+    ///
+    /// Gives back how many undirected edgesets are in the file.
+    int uEdgeSetNum() const {
+      return uedgesets.size();
+    }
+
+    /// \brief Gives back the name of undirected edgeset on the indiced 
+    /// position.
+    ///
+    /// Gives back the name of undirected edgeset on the indiced position.
+    std::string uEdgeSetName(int index) const {
+      return uedgesets[index].name;
+    }
+
+    /// \brief Gives back the map names of undirected edgeset on the indiced 
+    /// position.
+    ///
+    /// Gives back the map names of undirected edgeset on the indiced position.
+    const std::vector<std::string>& uEdgeSetMaps(int index) const {
+      return uedgesets[index].items;
+    }
+
+    /// \brief Gives back how many labeled nodes section are in the file.
+    ///
+    /// Gives back how many labeled nodes section are in the file.
+    int nodesNum() const {
+      return nodes.size();
+    }
+
+    /// \brief Gives back the name of labeled nodes section on the indiced 
+    /// position.
+    ///
+    /// Gives back the name of labeled nodes section on the indiced position.
+    std::string nodesName(int index) const {
+      return nodes[index].name;
+    }
+
+    /// \brief Gives back the names of the labeled nodes in the indiced 
+    /// section.
+    ///
+    /// Gives back the names of the labeled nodes in the indiced section.
+    const std::vector<std::string>& nodesItems(int index) const {
+      return nodes[index].items;
+    }
+
+    /// \brief Gives back how many labeled edges section are in the file.
+    ///
+    /// Gives back how many labeled edges section are in the file.
+    int edgesNum() const {
+      return edges.size();
+    }
+
+    /// \brief Gives back the name of labeled edges section on the indiced 
+    /// position.
+    ///
+    /// Gives back the name of labeled edges section on the indiced position.
+    std::string edgesName(int index) const {
+      return edges[index].name;
+    }
+
+    /// \brief Gives back the names of the labeled edges in the indiced 
+    /// section.
+    ///
+    /// Gives back the names of the labeled edges in the indiced section.
+    const std::vector<std::string>& edgesItems(int index) const {
+      return edges[index].items;
+    }
+ 
+    /// \brief Gives back how many labeled undirected edges section are 
+    /// in the file.
+    ///
+    /// Gives back how many labeled undirected edges section are in the file.
+    int uEdgesNum() const {
+      return uedges.size();
+    }
+
+    /// \brief Gives back the name of labeled undirected edges section 
+    /// on the indiced position.
+    ///
+    /// Gives back the name of labeled undirected edges section on the 
+    /// indiced position.
+    std::string uEdgesName(int index) const {
+      return uedges[index].name;
+    }
+
+    /// \brief Gives back the names of the labeled undirected edges in 
+    /// the indiced section.
+    ///
+    /// Gives back the names of the labeled undirected edges in the 
+    /// indiced section.
+    const std::vector<std::string>& uEdgesItems(int index) const {
+      return uedges[index].items;
+    }
+
+ 
+    /// \brief Gives back how many attributes section are in the file.
+    ///
+    /// Gives back how many attributes section are in the file.
+    int attributesNum() const {
+      return attributes.size();
+    }
+
+    /// \brief Gives back the name of attributes section on the indiced 
+    /// position.
+    ///
+    /// Gives back the name of attributes section on the indiced position.
+    std::string attributesName(int index) const {
+      return attributes[index].name;
+    }
+
+    /// \brief Gives back the names of the attributes in the indiced section.
+    ///
+    /// Gives back the names of the attributes in the indiced section.
+    const std::vector<std::string>& attributesItems(int index) const {
+      return attributes[index].items;
+    }
+
+    const std::vector<std::string>& otherSections() const {
+      return sections;
+    }
+
+  protected:
+    
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the section is common section.
+    bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command, name;
+      ls >> command >> name;
+      if (command == "@nodeset") {
+	current = command;
+	nodesets.push_back(SectionInfo(name));
+      } else if (command == "@edgeset") {
+	current = command;
+	edgesets.push_back(SectionInfo(name));
+      } else if (command == "@uedgeset") {
+	current = command;
+	uedgesets.push_back(SectionInfo(name));
+      } else if (command == "@nodes") {
+	current = command;
+	nodes.push_back(SectionInfo(name));
+      } else if (command == "@edges") {
+	current = command;
+	edges.push_back(SectionInfo(name));
+      } else if (command == "@uedges") {
+	current = command;
+	uedges.push_back(SectionInfo(name));
+      } else if (command == "@attributes") {
+	current = command;
+	attributes.push_back(SectionInfo(name));
+      } else {
+	sections.push_back(line);
+	return false;
+      }
+      return true;
+    }
+
+    /// \brief Retrieve the items from various sections.
+    ///
+    /// Retrieve the items from various sections.
+    void read(std::istream& is) {
+      if (current == "@nodeset") {
+	readMapNames(is, nodesets.back().items);
+      } else if (current == "@edgeset") {
+	readMapNames(is, edgesets.back().items);
+      } else if (current == "@uedgeset") {
+	readMapNames(is, uedgesets.back().items);
+      } else if (current == "@nodes") {
+	readItemNames(is, nodes.back().items);
+      } else if (current == "@edges") {
+	readItemNames(is, edges.back().items);
+      } else if (current == "@uedges") {
+	readItemNames(is, uedges.back().items);
+      } else if (current == "@attributes") {
+	readItemNames(is, attributes.back().items);
+      }
+    }    
+
+  private:
+
+    void readMapNames(std::istream& is, std::vector<std::string>& maps) {
+      std::string line, name;
+      std::getline(is, line);
+      std::istringstream ls(line);
+      while (ls >> name) {
+	maps.push_back(name);
+      }
+      while (getline(is, line)) { }
+    }
+
+    void readItemNames(std::istream& is, std::vector<std::string>& maps) {
+      std::string line, name;
+      while (std::getline(is, line)) {
+	std::istringstream ls(line);
+	ls >> name;
+	maps.push_back(name);
+      }
+    }
+
+    struct SectionInfo {
+      std::string name;
+      std::vector<std::string> items;
+
+      SectionInfo(const std::string& _name) : name(_name) {}
+    };
+
+    std::vector<SectionInfo> nodesets;
+    std::vector<SectionInfo> edgesets;
+    std::vector<SectionInfo> uedgesets;
+
+    std::vector<SectionInfo> nodes;
+    std::vector<SectionInfo> edges;
+    std::vector<SectionInfo> uedges;
+
+    std::vector<SectionInfo> attributes;
+
+    std::vector<std::string> sections;
+
+    std::string current;
+
+  };
+
+}
+#endif
Index: lemon/lemon_writer.h
===================================================================
--- lemon/lemon_writer.h	(revision 2553)
+++ lemon/lemon_writer.h	(revision 2553)
@@ -0,0 +1,2283 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup lemon_io
+///\file
+///\brief Lemon Format writer.
+
+#ifndef LEMON_LEMON_WRITER_H
+#define LEMON_LEMON_WRITER_H
+
+#include <iostream>
+#include <fstream>
+#include <string>
+#include <vector>
+#include <algorithm>
+#include <map>
+#include <memory>
+
+#include <lemon/error.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/graph_utils.h>
+#include <lemon/bits/item_writer.h>
+#include <lemon/bits/utility.h>
+#include <lemon/maps.h>
+#include <lemon/dim2.h>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+
+
+namespace lemon {
+
+  namespace _writer_bits {
+    
+    template <typename T>
+    bool operator<(T, T) {
+      throw DataFormatError("Label is not comparable");
+    }
+
+    template <typename T>
+    struct Less {
+      bool operator()(const T& p, const T& q) const {
+	return p < q;
+      }
+    };
+
+    template <typename Map>
+    struct ComposeLess {
+      ComposeLess(const Map& _map) : map(_map), less() {}
+
+      bool operator()(const typename Map::Key& p, 
+                      const typename Map::Key& q) const {
+	return less(map[p], map[q]);
+      }
+      const Map& map;
+      Less<typename Map::Value> less;
+    };
+
+    template <typename UGraph, typename Map>
+    struct UEdgeComposeLess {
+      UEdgeComposeLess(const UGraph& _ugraph, const Map& _map) 
+	: ugraph(_ugraph), map(_map), less() {}
+
+      bool operator()(const typename UGraph::Edge& p, 
+                      const typename UGraph::Edge& q) const {
+	return p != q ? less(map[p], map[q]) : 
+	  (!ugraph.direction(p) && ugraph.direction(q));
+      }
+
+      const UGraph& ugraph;
+      const Map& map;
+      Less<typename Map::Value> less;
+    };
+
+    template <typename Item>
+    class ItemLabelWriter {
+    public:
+
+      bool isLabelWriter() { return true; }
+
+      void writeLabel(std::ostream&, const Item&) {}
+      
+      template <class _ItemLabelWriter>
+      struct Constraints {
+	void constraints() {
+	  bool b = writer.isLabelWriter();
+	  ignore_unused_variable_warning(b);
+	  writer.writeLabel(os, item);
+	}
+	_ItemLabelWriter& writer;
+	std::ostream& os;
+	const Item& item;
+      };
+
+    };
+
+    template <typename Item>
+    class ItemWriter {
+    public:
+
+      void write(std::ostream&, const Item&) {}
+      
+      template <class _ItemWriter>
+      struct Constraints {
+	void constraints() {
+	  writer.write(os, item);
+	}
+	_ItemWriter& writer;
+	std::ostream& os;
+	const Item& item;
+      };
+
+    };
+
+    template <typename Map>
+    struct Ref { typedef const Map& Type; };
+
+    template <typename Graph, typename Map>
+    class ForwardComposeMap {
+    public:
+      typedef typename Graph::UEdge Key;
+      typedef typename Map::Value Value;
+
+      ForwardComposeMap(const Graph& _graph, const Map& _map) 
+	: graph(_graph), map(_map) {}
+      
+      Value operator[](const Key& key) const {
+	return map[graph.direct(key, true)];
+      }
+
+    private:
+      const Graph& graph;
+      typename Ref<Map>::Type map;
+    };
+
+    template <typename Graph, typename Map>
+    ForwardComposeMap<Graph, Map>
+    forwardComposeMap(const Graph& graph, const Map& map) {
+      return ForwardComposeMap<Graph, Map>(graph, map);
+    }
+
+    template <typename Graph, typename Map>
+    class BackwardComposeMap {
+    public:
+      typedef typename Graph::UEdge Key;
+      typedef typename Map::Value Value;
+
+      BackwardComposeMap(const Graph& _graph, const Map& _map) 
+	: graph(_graph), map(_map) {}
+      
+      Value operator[](const Key& key) const {
+	return map[graph.direct(key, false)];
+      }
+
+    private:
+      const Graph& graph;
+      typename Ref<Map>::Type map;
+    };
+
+    template <typename Graph, typename Map>
+    BackwardComposeMap<Graph, Map>
+    backwardComposeMap(const Graph& graph, const Map& map) {
+      return BackwardComposeMap<Graph, Map>(graph, map);
+    }
+
+    template <typename Graph, typename Map>
+    struct Ref<ForwardComposeMap<Graph, Map> > { 
+      typedef ForwardComposeMap<Graph, Map> Type;
+    };
+
+    template <typename Graph, typename Map>
+    struct Ref<BackwardComposeMap<Graph, Map> > { 
+      typedef BackwardComposeMap<Graph, Map> Type; 
+    };
+
+    template <typename Map>
+    struct Ref<dim2::XMap<Map> > { 
+      typedef dim2::XMap<Map> Type;
+    };
+    template <typename Map>
+    struct Ref<dim2::ConstXMap<Map> > { 
+      typedef dim2::ConstXMap<Map> Type;
+    };
+
+    template <typename Map>
+    struct Ref<dim2::YMap<Map> > { 
+      typedef dim2::YMap<Map> Type;
+    };
+    template <typename Map>
+    struct Ref<dim2::ConstYMap<Map> > { 
+      typedef dim2::ConstYMap<Map> Type;
+    };
+
+
+    template <typename _Item>    
+    class MapWriterBase {
+    public:
+      typedef _Item Item;
+
+      virtual ~MapWriterBase() {}
+
+      virtual void write(std::ostream& os, const Item& item) const = 0;
+      virtual void sort(std::vector<Item>&) const = 0;
+    };
+
+
+    template <typename _Item, typename _Map, typename _Writer>
+    class MapWriter : public MapWriterBase<_Item> {
+    public:
+      typedef _Map Map;
+      typedef _Writer Writer;
+      typedef typename Writer::Value Value;
+      typedef _Item Item;
+      
+      typename _writer_bits::Ref<Map>::Type map;
+      Writer writer;
+
+      MapWriter(const Map& _map, const Writer& _writer) 
+	: map(_map), writer(_writer) {}
+
+      virtual ~MapWriter() {}
+
+      virtual void write(std::ostream& os, const Item& item) const {
+	Value value = map[item];
+	writer.write(os, value);
+      }
+
+      virtual void sort(std::vector<Item>& items) const {
+        ComposeLess<Map> less(map);
+        std::sort(items.begin(), items.end(), less);
+      }
+
+    };
+
+    template <typename _UGraph>    
+    class UEdgeMapWriterBase {
+    public:
+      typedef typename _UGraph::Edge Edge;
+      typedef typename _UGraph::UEdge UEdge;
+
+      typedef UEdge Item;
+
+      virtual ~UEdgeMapWriterBase() {}
+
+      virtual void write(std::ostream& os, const Item& item) const = 0;
+      virtual void sort(const _UGraph&, std::vector<Edge>&) const = 0;
+      virtual void sort(std::vector<UEdge>&) const = 0;
+    };
+
+
+    template <typename _UGraph, typename _Map, typename _Writer>
+    class UEdgeMapWriter : public UEdgeMapWriterBase<_UGraph> {
+    public:
+      typedef _Map Map;
+      typedef _Writer Writer;
+      typedef typename Writer::Value Value;
+
+      typedef typename _UGraph::Edge Edge;
+      typedef typename _UGraph::UEdge UEdge;
+      typedef UEdge Item;
+      
+      typename _writer_bits::Ref<Map>::Type map;
+      Writer writer;
+
+      UEdgeMapWriter(const Map& _map, const Writer& _writer) 
+	: map(_map), writer(_writer) {}
+
+      virtual ~UEdgeMapWriter() {}
+
+      virtual void write(std::ostream& os, const Item& item) const {
+	Value value = map[item];
+	writer.write(os, value);
+      }
+
+      virtual void sort(const _UGraph& ugraph, std::vector<Edge>& items) const {
+        UEdgeComposeLess<_UGraph, Map> less(ugraph, map);
+        std::sort(items.begin(), items.end(), less);
+      }
+
+      virtual void sort(std::vector<UEdge>& items) const {
+        ComposeLess<Map> less(map);
+        std::sort(items.begin(), items.end(), less);
+      }
+
+    };
+
+
+    class ValueWriterBase {
+    public:
+      virtual ~ValueWriterBase() {}
+      virtual void write(std::ostream&) = 0;
+    };
+
+    template <typename _Value, typename _Writer>
+    class ValueWriter : public ValueWriterBase {
+    public:
+      typedef _Value Value;
+      typedef _Writer Writer;
+
+      ValueWriter(const Value& _value, const Writer& _writer)
+ 	: value(_value), writer(_writer) {}
+
+      virtual void write(std::ostream& os) {
+	writer.write(os, value);
+      }
+    private:
+      const Value& value;
+      Writer writer;
+    };
+    
+
+    template <typename _Item>
+    class LabelWriterBase {
+    public:
+      typedef _Item Item;
+      virtual ~LabelWriterBase() {}
+      virtual void write(std::ostream&, const Item&) const = 0;
+      virtual void sort(std::vector<Item>&) const = 0;
+      virtual bool isLabelWriter() const = 0;
+      virtual LabelWriterBase* clone() const = 0;
+    };
+
+    template <typename _Item, typename _BoxedLabelWriter>
+    class LabelWriter : public LabelWriterBase<_Item> {
+    public:
+      typedef _Item Item;
+      typedef _BoxedLabelWriter BoxedLabelWriter;
+
+      const BoxedLabelWriter& labelWriter;
+
+      LabelWriter(const BoxedLabelWriter& _labelWriter) 
+	: labelWriter(_labelWriter) {}
+
+      virtual void write(std::ostream& os, const Item& item) const {
+	labelWriter.writeLabel(os, item);
+      }
+      virtual void sort(std::vector<Item>& items) const {
+	labelWriter.sortByLabel(items);
+      }
+
+      virtual bool isLabelWriter() const {
+	return labelWriter.isLabelWriter();
+      }
+
+      virtual LabelWriter* clone() const {
+	return new LabelWriter(labelWriter);
+      }
+    };
+
+  }
+
+  /// \ingroup lemon_io
+  /// \brief Lemon Format writer class.
+  /// 
+  /// The Lemon Format contains several sections. We do not want to
+  /// determine what sections are in a lemon file we give only a framework
+  /// to write a section oriented format.
+  ///
+  /// In the Lemon Format each section starts with a line contains a \c \@
+  /// character on the first not white space position. This line is the
+  /// header line of the section. Each next lines belong to this section
+  /// while it does not starts with \c \@ character. This line can start a 
+  /// new section or if it can close the file with the \c \@end line.
+  /// The file format ignore the empty lines and it may contain comments
+  /// started with a \c # character to the end of the line. 
+  ///
+  /// The framework provides an abstract LemonWriter::SectionWriter class
+  /// what defines the interface of a SectionWriter. The SectionWriter
+  /// has the \c header() member function what gives back the header of the
+  /// section. After that it will be called the \c write() member which
+  /// should write the content of the section.
+  ///
+  /// \relates GraphWriter
+  /// \relates NodeSetWriter
+  /// \relates EdgeSetWriter
+  /// \relates NodesWriter
+  /// \relates EdgesWriter
+  /// \relates AttributeWriter
+  class LemonWriter {
+  public:
+
+    /// \brief Abstract base class for writing a section.
+    ///
+    /// This class has an \c header() member function what gives back
+    /// the header line of the section. The \c write() member should
+    /// write the content of the section to the stream.
+    class SectionWriter {
+      friend class LemonWriter;
+    protected:
+      /// \brief Constructor for SectionWriter.
+      ///
+      /// Constructor for SectionWriter. It attach this writer to
+      /// the given LemonWriter.
+      SectionWriter(LemonWriter& writer) {
+	writer.attach(*this);
+      }
+      
+      virtual ~SectionWriter() {}
+
+      /// \brief The header of section.
+      ///
+      /// It gives back the header of the section.
+      virtual std::string header() = 0;
+
+      /// \brief Writer function of the section.
+      ///
+      /// Write the content of the section.
+      virtual void write(std::ostream& os) = 0;
+      
+      /// \brief Gives back true when the section should be written.
+      ///
+      /// Gives back true when the section should be written.
+      virtual bool valid() { return true; }
+    };
+
+    /// \brief Constructor for LemonWriter.
+    ///
+    /// Constructor for LemonWriter which writes to the given stream.
+    LemonWriter(std::ostream& _os) 
+      : os(&_os), own_os(false) {}
+
+    /// \brief Constructor for LemonWriter.
+    ///
+    /// Constructor for LemonWriter which writes to the given file.
+    LemonWriter(const std::string& filename) 
+      : os(0), own_os(true) {
+      os = new std::ofstream(filename.c_str());
+    }
+
+    /// \brief Desctructor for LemonWriter.
+    ///
+    /// Desctructor for LemonWriter.
+    ~LemonWriter() {
+      if (own_os) {
+	delete os;
+      }
+    }
+
+  private:
+    LemonWriter(const LemonWriter&);
+    void operator=(const LemonWriter&);
+
+    void attach(SectionWriter& writer) {
+      writers.push_back(&writer);
+    }
+
+  public:
+
+    /// \brief Executes the LemonWriter.
+    /// 
+    /// It executes the LemonWriter.
+    void run() {
+      SectionWriters::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+        if ((*it)->valid()) {
+          *os << (*it)->header() << std::endl;
+          (*it)->write(*os);
+        }
+      }
+      *os << "@end" << std::endl;
+    }
+
+
+  private:
+
+    std::ostream* os;
+    bool own_os;
+
+    typedef std::vector<SectionWriter*> SectionWriters;
+    SectionWriters writers;
+
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing a graph's nodeset.
+  ///
+  /// The lemon format can store multiple graph nodesets with several maps.
+  /// The nodeset section's header line is \c \@nodeset \c nodeset_name, but 
+  /// the \c nodeset_name may be empty.
+  ///
+  /// The first line of the section contains the names of the maps separated
+  /// with white spaces. Each next lines describes a node in the nodeset, and
+  /// contains the mapped values for each map.
+  ///
+  /// If the nodeset contains an \c "label" named map then it will be regarded
+  /// as label map. This map should contain only unique values and when the 
+  /// \c writeLabel() member will be called with a node it will write it's 
+  /// label. Otherwise if the \c _forceLabelMap constructor parameter is true 
+  /// then the label map will be the id in the graph. In addition if the
+  /// the \c _forceSort is true then the writer will write the nodes
+  /// sorted by the labels.
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph, typename _Traits = DefaultWriterTraits>
+  class NodeSetWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Node Node;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for NodeSetWriter. It creates the NodeSetWriter and
+    /// attach it into the given LemonWriter. If the \c _forceLabelMap
+    /// parameter is true then the writer will write own label map when
+    /// the user does not give "label" named map. In addition if the
+    /// the \c _forceSort is true then the writer will write the edges
+    /// sorted by the labels.
+    NodeSetWriter(LemonWriter& _writer, const Graph& _graph, 
+		  const std::string& _name = std::string(), 
+		  bool _forceLabelMap = true, bool _forceSort = true) 
+      : Parent(_writer), labelMap(0), forceLabelMap(_forceLabelMap), 
+	forceSort(_forceSort), graph(_graph), name(_name) {}
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for NodeSetWriter.
+    virtual ~NodeSetWriter() {
+      typename MapWriters::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    NodeSetWriter(const NodeSetWriter&);
+    void operator=(const NodeSetWriter&);
+  
+  public:
+
+    /// \brief Add a new node map writer command for the writer.
+    ///
+    /// Add a new node map writer command for the writer.
+    template <typename Map>
+    NodeSetWriter& writeNodeMap(std::string label, const Map& map) {
+      return writeNodeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new node map writer command for the writer.
+    ///
+    /// Add a new node map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    NodeSetWriter& writeNodeMap(std::string label, const Map& map, 
+			    const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<Node, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>,ItemWriter>();
+      writers.push_back(
+	make_pair(label, new _writer_bits::
+		  MapWriter<Node, Map, ItemWriter>(map, iw)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@nodeset " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      for (int i = 0; i < int(writers.size()); ++i) {
+	if (writers[i].first == "label") {
+	  labelMap = writers[i].second;
+	  forceLabelMap = false;
+	  break;
+	}
+      }
+      std::vector<Node> items;
+      for (typename Graph::NodeIt it(graph); it != INVALID; ++it) {
+        items.push_back(it);
+      }
+      if (forceSort) {
+        if (labelMap) {
+          labelMap->sort(items);
+        } else {
+          typedef IdMap<Graph, Node> Map;
+          Map map(graph);
+          _writer_bits::ComposeLess<Map> less(map);
+          std::sort(items.begin(), items.end(), less);
+        }
+      }
+      if (forceLabelMap) {
+	os << "label\t";
+      }
+      for (int i = 0; i < int(writers.size()); ++i) {
+	os << writers[i].first << '\t';
+      }
+      os << std::endl;
+      for (typename std::vector<Node>::iterator it = items.begin();
+           it != items.end(); ++it) {
+	if (forceLabelMap) {
+	  os << graph.id(*it) << '\t';
+	}
+	for (int i = 0; i < int(writers.size()); ++i) {
+	  writers[i].second->write(os, *it);
+	  os << '\t';
+	}
+	os << std::endl;
+      }
+    }
+
+  public:
+
+    /// \brief Returns true if the nodeset can write the labels of the nodes.
+    ///
+    /// Returns true if the nodeset can write the labels of the nodes.
+    /// It is possible only if a "label" named map was written or the 
+    /// \c _forceLabelMap constructor parameter was true.
+    bool isLabelWriter() const {
+      return labelMap != 0 || forceLabelMap;
+    }
+
+    /// \brief Write the label of the given node.
+    ///
+    /// It writes the label of the given node. If there was written a "label"
+    /// named map then it will write the map value belongs to the node.
+    /// Otherwise if the \c forceLabel parameter was true it will write
+    /// its label in the graph. 
+    void writeLabel(std::ostream& os, const Node& item) const {
+      if (forceLabelMap) {
+	os << graph.id(item);
+      } else {
+	labelMap->write(os, item);
+      }
+    }
+
+    /// \brief Sorts the given node vector by label.
+    ///
+    /// Sorts the given node vector by label. If there was written an
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Node>& nodes) const {
+      if (labelMap) {
+	labelMap->sort(nodes);
+      } else {
+	typedef IdMap<Graph, Node> Map;
+	Map map(graph);
+	_writer_bits::ComposeLess<Map> less(map);
+	std::sort(nodes.begin(), nodes.end(), less);
+      }
+    }
+
+  private:
+
+    typedef std::vector<std::pair<std::string, _writer_bits::
+				  MapWriterBase<Node>*> > MapWriters;
+    MapWriters writers;
+
+    _writer_bits::MapWriterBase<Node>* labelMap;
+    bool forceLabelMap;
+    bool forceSort;
+   
+    const Graph& graph;   
+    std::string name;
+
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing a bipartite graph's nodeset.
+  ///
+  /// The lemon format can store multiple bipartite graph nodesets
+  /// with several maps.  The nodeset section's header line is \c
+  /// \@bpnodeset \c bpnodeset_name, but the \c bpnodeset_name may be empty.
+  ///
+  /// The first line of the section contains the names of the maps separated
+  /// with white spaces. Each next lines describes a node in the nodeset, and
+  /// contains the mapped values for each map.
+  ///
+  /// If the nodeset contains an \c "label" named map then it will be regarded
+  /// as label map. This map should contain only unique values and when the 
+  /// \c writeLabel() member will be called with a node it will write it's 
+  /// label. Otherwise if the \c _forceLabelMap constructor parameter is true 
+  /// then the label map will be the id in the graph. In addition if the
+  /// the \c _forceSort is true then the writer will write the edges
+  /// sorted by the labels.
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph, typename _Traits = DefaultWriterTraits>
+  class BpNodeSetWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Node Node;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for BpNodeSetWriter. It creates the BpNodeSetWriter and
+    /// attach it into the given LemonWriter. If the \c _forceLabelMap
+    /// parameter is true then the writer will write own label map when
+    /// the user does not give "label" named map. In addition if the
+    /// the \c _forceSort is true then the writer will write the nodes
+    /// sorted by the labels.
+    BpNodeSetWriter(LemonWriter& _writer, const Graph& _graph, 
+		  const std::string& _name = std::string(), 
+		  bool _forceLabelMap = true, bool _forceSort = true) 
+      : Parent(_writer), labelMap(0), forceLabelMap(_forceLabelMap), 
+	forceSort(_forceSort), graph(_graph), name(_name) {}
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for BpNodeSetWriter.
+    virtual ~BpNodeSetWriter() {
+      typename MapWriters::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    BpNodeSetWriter(const BpNodeSetWriter&);
+    void operator=(const BpNodeSetWriter&);
+  
+  public:
+
+    /// \brief Add a new A-node map writer command for the writer.
+    ///
+    /// Add a new A-node map writer command for the writer.
+    template <typename Map>
+    BpNodeSetWriter& writeANodeMap(std::string label, const Map& map) {
+      return writeANodeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new A-node map writer command for the writer.
+    ///
+    /// Add a new A-node map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    BpNodeSetWriter& writeANodeMap(std::string label, const Map& map, 
+				   const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<Node, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>,ItemWriter>();
+      if (label == "label") {
+	throw IoParameterError("Label cannot be A-node map");
+      }
+      awriters.push_back(make_pair(label, new _writer_bits::
+				   MapWriter<Node, Map, ItemWriter>(map, iw)));
+      return *this;
+    }
+
+    /// \brief Add a new B-node map writer command for the writer.
+    ///
+    /// Add a new B-node map writer command for the writer.
+    template <typename Map>
+    BpNodeSetWriter& writeBNodeMap(std::string label, const Map& map) {
+      return writeBNodeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new B-node map writer command for the writer.
+    ///
+    /// Add a new B-node map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    BpNodeSetWriter& writeBNodeMap(std::string label, const Map& map, 
+				   const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<Node, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>,ItemWriter>();
+      if (label == "label") {
+	throw IoParameterError("Label cannot be B-node map");
+      }
+      bwriters.push_back(make_pair(label, new _writer_bits::
+				   MapWriter<Node, Map, ItemWriter>(map, iw)));
+      return *this;
+    }
+
+    /// \brief Add a new node map writer command for the writer.
+    ///
+    /// Add a new node map writer command for the writer.
+    template <typename Map>
+    BpNodeSetWriter& writeNodeMap(std::string label, const Map& map) {
+      return writeNodeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new node map writer command for the writer.
+    ///
+    /// Add a new node map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    BpNodeSetWriter& writeNodeMap(std::string label, const Map& map, 
+				  const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<Node, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>,ItemWriter>();
+      writers.push_back(make_pair(label, new _writer_bits::
+				  MapWriter<Node, Map, ItemWriter>(map, iw)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@bpnodeset " + name;
+    }
+
+    /// \brief Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      for (int i = 0; i < int(writers.size()); ++i) {
+	if (writers[i].first == "label") {
+	  labelMap = writers[i].second;
+	  forceLabelMap = false;
+	  break;
+	}
+      }
+      {
+	os << "&anodeset ";
+	std::vector<Node> items;
+	for (typename Graph::ANodeIt it(graph); it != INVALID; ++it) {
+	  items.push_back(it);
+	}
+	if (forceSort) {
+	  if (labelMap) {
+	    labelMap->sort(items);
+	  } else {
+	    typedef IdMap<Graph, Node> Map;
+	    Map map(graph);
+	    _writer_bits::ComposeLess<Map> less(map);
+	    std::sort(items.begin(), items.end(), less);
+	  }
+	}
+	if (forceLabelMap) {
+	  os << "label\t";
+	}
+	for (int i = 0; i < int(writers.size()); ++i) {
+	  os << writers[i].first << '\t';
+	}
+	for (int i = 0; i < int(awriters.size()); ++i) {
+	  os << awriters[i].first << '\t';
+	}
+	os << std::endl;
+	for (typename std::vector<Node>::iterator it = items.begin();
+	     it != items.end(); ++it) {
+	  if (forceLabelMap) {
+	    os << graph.id(*it) << '\t';
+	  }
+	  for (int i = 0; i < int(writers.size()); ++i) {
+	    writers[i].second->write(os, *it);
+	    os << '\t';
+	  }
+	  for (int i = 0; i < int(awriters.size()); ++i) {
+	    awriters[i].second->write(os, *it);
+	    os << '\t';
+	  }
+	  os << std::endl;
+	}
+      }
+      {
+	os << "&bnodeset ";
+	std::vector<Node> items;
+	for (typename Graph::BNodeIt it(graph); it != INVALID; ++it) {
+	  items.push_back(it);
+	}
+	if (forceSort) {
+	  if (labelMap) {
+	    labelMap->sort(items);
+	  } else {
+	    typedef IdMap<Graph, Node> Map;
+	    Map map(graph);
+	    _writer_bits::ComposeLess<Map> less(map);
+	    std::sort(items.begin(), items.end(), less);
+	  }
+	}
+	if (forceLabelMap) {
+	  os << "label\t";
+	}
+	for (int i = 0; i < int(writers.size()); ++i) {
+	  os << writers[i].first << '\t';
+	}
+	for (int i = 0; i < int(bwriters.size()); ++i) {
+	  os << bwriters[i].first << '\t';
+	}
+	os << std::endl;
+	for (typename std::vector<Node>::iterator it = items.begin();
+	     it != items.end(); ++it) {
+	  if (forceLabelMap) {
+	    os << graph.id(*it) << '\t';
+	  }
+	  for (int i = 0; i < int(writers.size()); ++i) {
+	    writers[i].second->write(os, *it);
+	    os << '\t';
+	  }
+	  for (int i = 0; i < int(bwriters.size()); ++i) {
+	    bwriters[i].second->write(os, *it);
+	    os << '\t';
+	  }
+	  os << std::endl;
+	}
+      }
+    }
+
+  public:
+
+    /// \brief Returns true if the nodeset can write the labels of the nodes.
+    ///
+    /// Returns true if the nodeset can write the labels of the nodes.
+    /// It is possible only if a "label" named map was written or the 
+    /// \c _forceLabelMap constructor parameter was true.
+    bool isLabelWriter() const {
+      return labelMap != 0 || forceLabelMap;
+    }
+
+    /// \brief Write the label of the given node.
+    ///
+    /// It writes the label of the given node. If there was written a "label"
+    /// named map then it will write the map value belongs to the node.
+    /// Otherwise if the \c forceLabel parameter was true it will write
+    /// its label in the graph. 
+    void writeLabel(std::ostream& os, const Node& item) const {
+      if (forceLabelMap) {
+	os << graph.id(item);
+      } else {
+	labelMap->write(os, item);
+      }
+    }
+
+    /// \brief Sorts the given node vector by label.
+    ///
+    /// Sorts the given node vector by label. If there was written an
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Node>& nodes) const {
+      if (labelMap) {
+	labelMap->sort(nodes);
+      } else {
+	typedef IdMap<Graph, Node> Map;
+	Map map(graph);
+	_writer_bits::ComposeLess<Map> less(map);
+	std::sort(nodes.begin(), nodes.end(), less);
+      }
+    }
+
+  private:
+
+    typedef std::vector<std::pair<std::string, _writer_bits::
+				  MapWriterBase<Node>*> > MapWriters;
+    MapWriters awriters, bwriters, writers;
+    
+    _writer_bits::MapWriterBase<Node>* labelMap;
+    bool forceLabelMap;
+    bool forceSort;
+   
+    const Graph& graph;   
+    std::string name;
+
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing a graph's edgesets.
+  ///
+  /// The lemon format can store multiple graph edgesets with several maps. 
+  /// The edgeset section's header line is \c \@edgeset \c edgeset_name, but 
+  /// the \c edgeset_name may be empty.
+  ///
+  /// The first line of the section contains the names of the maps separated
+  /// with white spaces. Each next lines describes a edge in the edgeset. The
+  /// line contains the source and the target nodes' label and the mapped 
+  /// values for each map.
+  ///
+  /// If the edgeset contains an \c "label" named map then it will be regarded
+  /// as label map. This map should contain only unique values and when the 
+  /// \c writeLabel() member will be called with an edge it will write it's 
+  /// label. Otherwise if the \c _forceLabelMap constructor parameter is true 
+  /// then the label map will be the id in the graph. In addition if the
+  /// the \c _forceSort is true then the writer will write the edges
+  /// sorted by the labels.
+  ///
+  /// The edgeset writer needs a node label writer to identify which nodes
+  /// have to be connected. If a NodeSetWriter can write the nodes' label,
+  /// it will be able to use with this class.
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph, typename _Traits = DefaultWriterTraits>
+  class EdgeSetWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for EdgeSetWriter. It creates the EdgeSetWriter
+    /// and attach it into the given LemonWriter. It will write node
+    /// labels by the \c _nodeLabelWriter. If the \c _forceLabelMap
+    /// parameter is true then the writer will write own label map if
+    /// the user does not give "label" named map. In addition if the
+    /// the \c _forceSort is true then the writer will write the
+    /// edges sorted by the labels.
+    template <typename NodeLabelWriter>
+    EdgeSetWriter(LemonWriter& _writer, const Graph& _graph, 
+		  const NodeLabelWriter& _nodeLabelWriter, 
+		  const std::string& _name = std::string(),
+		  bool _forceLabelMap = true, bool _forceSort = true)
+      : Parent(_writer), labelMap(0), forceLabelMap(_forceLabelMap),
+	forceSort(_forceSort), graph(_graph), name(_name) {
+      checkConcept<_writer_bits::ItemLabelWriter<Node>, NodeLabelWriter>();
+      nodeLabelWriter.reset(new _writer_bits::
+			 LabelWriter<Node, NodeLabelWriter>(_nodeLabelWriter));
+    } 
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for EdgeSetWriter.
+    virtual ~EdgeSetWriter() {
+      typename MapWriters::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    EdgeSetWriter(const EdgeSetWriter&);
+    void operator=(const EdgeSetWriter&);
+
+  public:
+
+    /// \brief Add a new edge map writer command for the writer.
+    ///
+    /// Add a new edge map writer command for the writer.
+    template <typename Map>
+    EdgeSetWriter& writeEdgeMap(std::string label, const Map& map) {
+      return writeEdgeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new edge map writer command for the writer.
+    ///
+    /// Add a new edge map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    EdgeSetWriter& writeEdgeMap(std::string label, const Map& map, 
+			    const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<Edge, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>, ItemWriter>();
+      writers.push_back(
+	make_pair(label, new _writer_bits::
+		  MapWriter<Edge, Map, ItemWriter>(map, iw)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@edgeset " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      if (!nodeLabelWriter->isLabelWriter()) {
+	throw DataFormatError("Cannot find nodeset or label map");
+      }
+      for (int i = 0; i < int(writers.size()); ++i) {
+	if (writers[i].first == "label") {
+	  labelMap = writers[i].second;
+	  forceLabelMap = false;
+	  break;
+	}
+      }
+      std::vector<Edge> items;
+      for (typename Graph::EdgeIt it(graph); it != INVALID; ++it) {
+        items.push_back(it);
+      }
+      if (forceSort) {
+        if (labelMap) {
+          labelMap->sort(items);
+        } else {
+          typedef IdMap<Graph, Edge> Map;
+          Map map(graph);
+          _writer_bits::ComposeLess<Map> less(map);
+          std::sort(items.begin(), items.end(), less);
+        }
+      }
+      os << "\t\t";
+      if (forceLabelMap) {
+	os << "label\t";
+      }
+      for (int i = 0; i < int(writers.size()); ++i) {
+	os << writers[i].first << '\t';
+      }
+      os << std::endl;
+      for (typename std::vector<Edge>::iterator it = items.begin();
+           it != items.end(); ++it) {
+	nodeLabelWriter->write(os, graph.source(*it));
+	os << '\t';
+	nodeLabelWriter->write(os, graph.target(*it));
+	os << '\t';
+	if (forceLabelMap) {
+	  os << graph.id(*it) << '\t';
+	}
+	for (int i = 0; i < int(writers.size()); ++i) {
+	  writers[i].second->write(os, *it);
+	  os << '\t';
+	}
+	os << std::endl;
+      }
+    }
+
+  public:
+
+    /// \brief Returns true if the edgeset can write the labels of the edges.
+    ///
+    /// Returns true if the edgeset can write the labels of the edges.
+    /// It is possible only if a "label" named map was written or the 
+    /// \c _forceLabelMap constructor parameter was true.
+    bool isLabelWriter() const {
+      return forceLabelMap || labelMap != 0;
+    }
+
+    /// \brief Write the label of the given edge.
+    ///
+    /// It writes the label of the given edge. If there was written a "label"
+    /// named map then it will write the map value belongs to the edge.
+    /// Otherwise if the \c forceLabel parameter was true it will write
+    /// its label in the graph. 
+    void writeLabel(std::ostream& os, const Edge& item) const {
+      if (forceLabelMap) {
+	os << graph.id(item);
+      } else {
+	labelMap->write(os, item);
+      }
+    } 
+
+    /// \brief Sorts the given edge vector by label.
+    ///
+    /// Sorts the given edge vector by label. If there was written an
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Edge>& edges) const {
+      if (labelMap) {
+	labelMap->sort(edges);
+      } else {
+	typedef IdMap<Graph, Edge> Map;
+	Map map(graph);
+	_writer_bits::ComposeLess<Map> less(map);
+	std::sort(edges.begin(), edges.end(), less);
+      }
+    }
+
+  private:
+
+    typedef std::vector<std::pair<std::string, _writer_bits::
+				  MapWriterBase<Edge>*> > MapWriters;
+    MapWriters writers;
+
+    _writer_bits::MapWriterBase<Edge>* labelMap;
+    bool forceLabelMap;
+    bool forceSort;
+   
+    const Graph& graph;   
+    std::string name;
+
+    std::auto_ptr<_writer_bits::LabelWriterBase<Node> > nodeLabelWriter;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing a undirected edgeset.
+  ///
+  /// The lemon format can store multiple undirected edgesets with several 
+  /// maps. The undirected edgeset section's header line is \c \@uedgeset 
+  /// \c uedgeset_name, but the \c uedgeset_name may be empty.
+  ///
+  /// The first line of the section contains the names of the maps separated
+  /// with white spaces. Each next lines describes an undirected edge in the 
+  /// edgeset. The line contains the two connected nodes' label and the mapped 
+  /// values for each undirected map.
+  ///
+  /// The section can handle the directed as a syntactical sugar. Two
+  /// undirected edge map describes one directed edge map. This two maps
+  /// are the forward map and the backward map and the names of this map
+  /// is near the same just with a prefix \c '+' or \c '-' character 
+  /// difference.
+  ///
+  /// If the edgeset contains an \c "label" named map then it will be
+  /// regarded as label map. This map should contain only unique
+  /// values and when the \c writeLabel() member will be called with
+  /// an undirected edge it will write it's label. Otherwise if the \c
+  /// _forceLabelMap constructor parameter is true then the label map
+  /// will be the id in the graph.  In addition if the the \c
+  /// _forceSort is true then the writer will write the edges sorted
+  /// by the labels.
+  ///
+  /// The undirected edgeset writer needs a node label writer to identify 
+  /// which nodes have to be connected. If a NodeSetWriter can write the 
+  /// nodes' label, it will be able to use with this class.
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph, typename _Traits = DefaultWriterTraits>
+  class UEdgeSetWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for UEdgeSetWriter. It creates the UEdgeSetWriter
+    /// and attach it into the given LemonWriter. It will write node
+    /// labels by the \c _nodeLabelWriter. If the \c _forceLabelMap
+    /// parameter is true then the writer will write own label map if
+    /// the user does not give "label" named map. In addition if the
+    /// the \c _forceSort is true then the writer will write the
+    /// edges sorted by the labels.
+    template <typename NodeLabelWriter>
+    UEdgeSetWriter(LemonWriter& _writer, const Graph& _graph, 
+		       const NodeLabelWriter& _nodeLabelWriter, 
+		       const std::string& _name = std::string(),
+		       bool _forceLabelMap = true, bool _forceSort = true)
+      : Parent(_writer), labelMap(0), forceLabelMap(_forceLabelMap),
+	forceSort(_forceSort), graph(_graph), name(_name) {
+      checkConcept<_writer_bits::ItemLabelWriter<Node>, NodeLabelWriter>();
+      nodeLabelWriter.reset(new _writer_bits::
+	LabelWriter<Node, NodeLabelWriter>(_nodeLabelWriter));
+    } 
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for UEdgeSetWriter.
+    virtual ~UEdgeSetWriter() {
+      typename MapWriters::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    UEdgeSetWriter(const UEdgeSetWriter&);
+    void operator=(const UEdgeSetWriter&);
+
+  public:
+
+    /// \brief Add a new undirected edge map writer command for the writer.
+    ///
+    /// Add a new undirected map writer command for the writer.
+    template <typename Map>
+    UEdgeSetWriter& writeUEdgeMap(std::string label, const Map& map) {
+      return writeUEdgeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new undirected map writer command for the writer.
+    ///
+    /// Add a new undirected map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    UEdgeSetWriter& writeUEdgeMap(std::string label, const Map& map, 
+                                  const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<UEdge, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>, ItemWriter>();
+      writers.push_back(
+	make_pair(label, new _writer_bits::
+		  UEdgeMapWriter<Graph, Map, ItemWriter>(map, iw)));
+      return *this;
+    }
+
+    /// \brief Add a new directed edge map writer command for the writer.
+    ///
+    /// Add a new directed map writer command for the writer.
+    template <typename Map>
+    UEdgeSetWriter& writeEdgeMap(std::string label, const Map& map) {
+      return writeEdgeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new directed map writer command for the writer.
+    ///
+    /// Add a new directed map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    UEdgeSetWriter& writeEdgeMap(std::string label, const Map& map, 
+                                 const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<Edge, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>, ItemWriter>();
+      writeUEdgeMap("+" + label, 
+                    _writer_bits::forwardComposeMap(graph, map), iw);
+      writeUEdgeMap("-" + label, 
+                    _writer_bits::backwardComposeMap(graph, map), iw);
+      return *this;
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@uedgeset " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      if (!nodeLabelWriter->isLabelWriter()) {
+	throw DataFormatError("Cannot find nodeset or label map");
+      }
+      for (int i = 0; i < int(writers.size()); ++i) {
+	if (writers[i].first == "label") {
+	  labelMap = writers[i].second;
+	  forceLabelMap = false;
+	  break;
+	}
+      }
+      std::vector<UEdge> items;
+      for (typename Graph::UEdgeIt it(graph); it != INVALID; ++it) {
+        items.push_back(it);
+      }
+      if (forceSort) {
+        if (labelMap) {
+          labelMap->sort(items);
+        } else {
+          typedef IdMap<Graph, UEdge> Map;
+          Map map(graph);
+          _writer_bits::ComposeLess<Map> less(map);
+          std::sort(items.begin(), items.end(), less);
+        }
+      }
+      os << "\t\t";
+      if (forceLabelMap) {
+	os << "label\t";
+      }
+      for (int i = 0; i < int(writers.size()); ++i) {
+	os << writers[i].first << '\t';
+      }
+      os << std::endl;
+      for (typename std::vector<UEdge>::iterator it = items.begin();
+           it != items.end(); ++it) {
+	nodeLabelWriter->write(os, graph.source(*it));
+	os << '\t';
+	nodeLabelWriter->write(os, graph.target(*it));
+	os << '\t';
+	if (forceLabelMap) {
+	  os << graph.id(*it) << '\t';
+	}
+	for (int i = 0; i < int(writers.size()); ++i) {
+	  writers[i].second->write(os, *it);
+	  os << '\t';
+	}
+	os << std::endl;
+      }
+    }
+
+  public:
+
+    /// \brief Returns true if the undirected edgeset can write the labels of 
+    /// the edges.
+    ///
+    /// Returns true if the undirected edgeset can write the labels of the 
+    /// undirected edges. It is possible only if a "label" named map was 
+    /// written or the \c _forceLabelMap constructor parameter was true.
+    bool isLabelWriter() const {
+      return forceLabelMap || labelMap != 0;
+    }
+
+    /// \brief Write the label of the given undirected edge.
+    ///
+    /// It writes the label of the given undirected edge. If there was written 
+    /// a "label" named map then it will write the map value belongs to the 
+    /// undirected edge. Otherwise if the \c forceLabel parameter was true it 
+    /// will write its id in the graph. 
+    void writeLabel(std::ostream& os, const UEdge& item) const {
+      if (forceLabelMap) {
+	os << graph.id(item);
+      } else {
+	labelMap->write(os, item);
+      }
+    } 
+
+    /// \brief Write the label of the given edge.
+    ///
+    /// It writes the label of the given edge. If there was written 
+    /// a "label" named map then it will write the map value belongs to the 
+    /// edge. Otherwise if the \c forceLabel parameter was true it 
+    /// will write its id in the graph. If the edge is forward map
+    /// then its prefix character is \c '+' elsewhere \c '-'.
+    void writeLabel(std::ostream& os, const Edge& item) const {
+      if (graph.direction(item)) {
+	os << "+";
+      } else {
+	os << "-";
+      }
+      if (forceLabelMap) {
+	os << graph.id(static_cast<const UEdge&>(item));
+      } else {
+	labelMap->write(os, item);
+      }
+    } 
+
+    /// \brief Sorts the given undirected edge vector by label.
+    ///
+    /// Sorts the given undirected edge vector by label. If there was
+    /// written a "label" named map then the vector will be sorted by
+    /// the values of this map. Otherwise if the \c forceLabel
+    /// parameter was true it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<UEdge>& uedges) const {
+      if (labelMap) {
+	labelMap->sort(uedges);
+      } else {
+	typedef IdMap<Graph, UEdge> Map;
+	Map map(graph);
+	_writer_bits::ComposeLess<Map> less(map);
+	std::sort(uedges.begin(), uedges.end(), less);
+      }
+    }
+
+    /// \brief Sorts the given edge vector by label.
+    ///
+    /// Sorts the given edge vector by label. If there was written a
+    /// "label" named map then the vector will be sorted by the values
+    /// of this map. Otherwise if the \c forceLabel parameter was true
+    /// it will be sorted by its id in the graph.
+    void sortByLabel(std::vector<Edge>& edges) const {
+      if (labelMap) {
+	labelMap->sort(graph, edges);
+      } else {
+	typedef IdMap<Graph, Edge> Map;
+	Map map(graph);
+	_writer_bits::ComposeLess<Map> less(map);
+	std::sort(edges.begin(), edges.end(), less);
+      }
+    }
+
+  private:
+
+    typedef std::vector<std::pair<std::string, _writer_bits::
+				  UEdgeMapWriterBase<Graph>*> > MapWriters;
+    MapWriters writers;
+
+    _writer_bits::UEdgeMapWriterBase<Graph>* labelMap;
+    bool forceLabelMap;
+    bool forceSort;
+   
+    const Graph& graph;   
+    std::string name;
+
+    std::auto_ptr<_writer_bits::LabelWriterBase<Node> > nodeLabelWriter;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing named nodes.
+  ///
+  /// The nodes section's header line is \c \@nodes \c nodes_name, but the
+  /// \c nodes_name may be empty.
+  ///
+  /// Each line in the section contains the name of the node and 
+  /// then the node label. 
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph>
+  class NodeWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+  public:
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor for NodeWriter. It creates the NodeWriter and
+    /// attach it into the given LemonWriter. The given \c _LabelWriter
+    /// will write the nodes' label what can be a nodeset writer.
+    template <typename _LabelWriter>
+    NodeWriter(LemonWriter& _writer, const _LabelWriter& _labelWriter, 
+	       const std::string& _name = std::string()) 
+      : Parent(_writer), name(_name) {
+      checkConcept<_writer_bits::ItemLabelWriter<Node>, _LabelWriter>();
+      labelWriter.reset(new _writer_bits::LabelWriter<Node, _LabelWriter>
+                        (_labelWriter));
+    }
+
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for NodeWriter.
+    virtual ~NodeWriter() {}
+
+  private:
+    NodeWriter(const NodeWriter&);
+    void operator=(const NodeWriter&);
+
+  public:
+
+    /// \brief Add a node writer command for the NodeWriter.
+    ///
+    /// Add a node writer command for the NodeWriter.
+    void writeNode(std::string label, const Node& item) {
+      writers.push_back(make_pair(label, &item));
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@nodes " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      if (!labelWriter->isLabelWriter()) {
+	throw DataFormatError("Cannot find nodeset or label map");
+      }
+      for (int i = 0; i < int(writers.size()); ++i) {
+	os << writers[i].first << ' ';
+	labelWriter->write(os, *(writers[i].second));
+	os << std::endl;
+      }
+    }
+
+    /// \brief Gives back true when the section should be written.
+    ///
+    /// Gives back true when the section should be written.
+    virtual bool valid() { return !writers.empty(); }
+    
+  private:
+
+    std::string name;
+
+    typedef std::vector<std::pair<std::string, const Node*> > NodeWriters;
+    NodeWriters writers;
+    std::auto_ptr<_writer_bits::LabelWriterBase<Node> > labelWriter;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing named edges.
+  ///
+  /// The edges section's header line is \c \@edges \c edges_name, but the
+  /// \c edges_name may be empty.
+  ///
+  /// Each line in the section contains the name of the edge and 
+  /// then the edge label. 
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph>
+  class EdgeWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+  public:
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor for EdgeWriter. It creates the EdgeWriter and
+    /// attach it into the given LemonWriter. The given \c _LabelWriter
+    /// will write the edges' label what can be a edgeset writer.
+    template <typename _LabelWriter>
+    EdgeWriter(LemonWriter& _writer, const _LabelWriter& _labelWriter, 
+	       const std::string& _name = std::string()) 
+      : Parent(_writer), name(_name) {
+      checkConcept<_writer_bits::ItemLabelWriter<Edge>, _LabelWriter>();
+      labelWriter.reset(new _writer_bits::LabelWriter<Edge, _LabelWriter>(_labelWriter));
+    }
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for EdgeWriter.
+    virtual ~EdgeWriter() {}
+  private:
+    EdgeWriter(const EdgeWriter&);
+    void operator=(const EdgeWriter&);
+
+  public:
+
+    /// \brief Add an edge writer command for the EdgeWriter.
+    ///
+    /// Add an edge writer command for the EdgeWriter.
+    void writeEdge(std::string label, const Edge& item) {
+      writers.push_back(make_pair(label, &item));
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@edges " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      if (!labelWriter->isLabelWriter()) {
+	throw DataFormatError("Cannot find edgeset or label map");
+      }
+      for (int i = 0; i < int(writers.size()); ++i) {
+	os << writers[i].first << ' ';
+	labelWriter->write(os, *(writers[i].second));
+	os << std::endl;
+      }
+    }
+
+    /// \brief Gives back true when the section should be written.
+    ///
+    /// Gives back true when the section should be written.
+    virtual bool valid() { return !writers.empty(); }
+    
+  private:
+
+    std::string name;
+
+    typedef std::vector<std::pair<std::string, const Edge*> > EdgeWriters;
+    EdgeWriters writers;
+
+    std::auto_ptr<_writer_bits::LabelWriterBase<Edge> > labelWriter;
+  };
+
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing named undirected edges.
+  ///
+  /// The undirected edges section's header line is \c \@uedges 
+  /// \c uedges_name, but the \c uedges_name may be empty.
+  ///
+  /// Each line in the section contains the name of the undirected edge and 
+  /// then the undirected edge label. 
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph>
+  class UEdgeWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+    typedef _Graph Graph;
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+  public:
+    
+    /// \brief Constructor.
+    ///
+    /// Constructor for UEdgeWriter. It creates the UEdgeWriter and
+    /// attach it into the given LemonWriter. The given \c _LabelWriter
+    /// will write the undirected edges' label what can be an undirected 
+    /// edgeset writer.
+    template <typename _LabelWriter>
+    UEdgeWriter(LemonWriter& _writer, const _LabelWriter& _labelWriter, 
+	       const std::string& _name = std::string()) 
+      : Parent(_writer), name(_name) {
+      checkConcept<_writer_bits::ItemLabelWriter<Edge>, _LabelWriter>();
+      checkConcept<_writer_bits::ItemLabelWriter<UEdge>, _LabelWriter>();
+      uEdgeLabelWriter.reset(new _writer_bits::
+			      LabelWriter<UEdge, _LabelWriter>(_labelWriter));
+      edgeLabelWriter.reset(new _writer_bits::
+			 LabelWriter<Edge, _LabelWriter>(_labelWriter));
+    }
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for UEdgeWriter.
+    virtual ~UEdgeWriter() {}
+  private:
+    UEdgeWriter(const UEdgeWriter&);
+    void operator=(const UEdgeWriter&);
+
+  public:
+
+    /// \brief Add an edge writer command for the UEdgeWriter.
+    ///
+    /// Add an edge writer command for the UEdgeWriter.
+    void writeEdge(std::string label, const Edge& item) {
+      edgeWriters.push_back(make_pair(label, &item));
+    }
+
+    /// \brief Add an undirected edge writer command for the UEdgeWriter.
+    ///
+    /// Add an undirected edge writer command for the UEdgeWriter.
+    void writeUEdge(std::string label, const UEdge& item) {
+      uEdgeWriters.push_back(make_pair(label, &item));
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@uedges " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      if (!edgeLabelWriter->isLabelWriter()) {
+	throw DataFormatError("Cannot find undirected edgeset or label map");
+      }
+      if (!uEdgeLabelWriter->isLabelWriter()) {
+	throw DataFormatError("Cannot find undirected edgeset or label map");
+      }
+      for (int i = 0; i < int(uEdgeWriters.size()); ++i) {
+	os << uEdgeWriters[i].first << ' ';
+	uEdgeLabelWriter->write(os, *(uEdgeWriters[i].second));
+	os << std::endl;
+      }
+      for (int i = 0; i < int(edgeWriters.size()); ++i) {
+	os << edgeWriters[i].first << ' ';
+	edgeLabelWriter->write(os, *(edgeWriters[i].second));
+	os << std::endl;
+      }
+    }
+
+    /// \brief Gives back true when the section should be written.
+    ///
+    /// Gives back true when the section should be written.
+    virtual bool valid() { 
+      return !uEdgeWriters.empty() || !edgeWriters.empty(); 
+    }
+    
+  private:
+
+    std::string name;
+
+    typedef std::vector<std::pair<std::string, 
+				  const UEdge*> > UEdgeWriters;
+    UEdgeWriters uEdgeWriters;
+    std::auto_ptr<_writer_bits::LabelWriterBase<UEdge> > uEdgeLabelWriter;
+
+    typedef std::vector<std::pair<std::string, const Edge*> > EdgeWriters;
+    EdgeWriters edgeWriters;
+    std::auto_ptr<_writer_bits::LabelWriterBase<Edge> > edgeLabelWriter;
+
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing extra node maps.
+  ///
+  /// The lemon format can store maps in the nodeset. This class let
+  /// you make distinict section to store maps. The main purpose of
+  /// this class is a logical separation of some maps. The other
+  /// useful application could be to store paths in node maps.
+  ///
+  /// The first line of the section contains the names of the maps
+  /// separated with white spaces. Each next line describes an item
+  /// in the itemset, and contains in the first column the label of
+  /// the item and then the mapped values for each map.
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph, typename _Traits = DefaultWriterTraits>
+  class NodeMapWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Node Node;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for NodeMapWriter. It creates the NodeMapWriter and
+    /// attach it into the given LemonWriter. If the the
+    /// \c _forceSort is true then the writer will write the edges
+    /// sorted by the labels.
+    template <typename _LabelWriter>
+    NodeMapWriter(LemonWriter& _writer, const Graph& _graph,
+		 const _LabelWriter& _labelWriter,
+		 const std::string& _name = std::string(),
+		 bool _forceSort = true) 
+      : Parent(_writer), graph(_graph), name(_name), forceSort(_forceSort) {
+      checkConcept<_writer_bits::ItemLabelWriter<Node>, _LabelWriter>();
+      labelWriter.reset(new _writer_bits::LabelWriter<Node, 
+			_LabelWriter>(_labelWriter));
+    }
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for NodeMapWriter.
+    virtual ~NodeMapWriter() {
+      typename MapWriters::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    NodeMapWriter(const NodeMapWriter&);
+    void operator=(const NodeMapWriter&);
+  
+  public:
+
+    /// \brief Add a new node map writer command for the writer.
+    ///
+    /// Add a new node map writer command for the writer.
+    template <typename Map>
+    NodeMapWriter& writeNodeMap(std::string label, const Map& map) {
+      return writeNodeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new node map writer command for the writer.
+    ///
+    /// Add a new node map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    NodeMapWriter& writeNodeMap(std::string label, const Map& map, 
+			   const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<Node, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>,ItemWriter>();
+      writers.push_back(
+	make_pair(label, new _writer_bits::
+		  MapWriter<Node, Map, ItemWriter>(map, iw)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@nodemaps " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      std::vector<Node> nodes;
+      for (typename Graph::NodeIt it(graph); it != INVALID; ++it) {
+        nodes.push_back(it);
+      }
+      if (forceSort) {
+	labelWriter->sort(nodes);
+      }
+      os << '\t';
+      for (int i = 0; i < int(writers.size()); ++i) {
+	os << writers[i].first << '\t';
+      }
+      os << std::endl;
+      for (typename std::vector<Node>::iterator it = nodes.begin();
+           it != nodes.end(); ++it) {
+
+	labelWriter->write(os, *it); os << '\t';
+	for (int i = 0; i < int(writers.size()); ++i) {
+	  writers[i].second->write(os, *it);
+	  os << '\t';
+	}
+	os << std::endl;
+      }
+    }
+
+
+  private:
+
+    typedef std::vector<std::pair<std::string, _writer_bits::
+				  MapWriterBase<Node>*> > MapWriters;
+    MapWriters writers;
+
+    _writer_bits::MapWriterBase<Node>* labelMap;
+
+    const Graph& graph;   
+    std::string name;
+    bool forceSort;
+
+    std::auto_ptr<_writer_bits::LabelWriterBase<Node> > labelWriter;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing extra edge maps.
+  ///
+  /// The lemon format can store maps in the edgeset. This class let
+  /// you make distinict section to store maps. The main purpose of
+  /// this class is a logical separation of some maps. The other
+  /// useful application could be to store paths in edge maps.
+  ///
+  /// The first line of the section contains the names of the maps
+  /// separated with white spaces. Each next line describes an item
+  /// in the itemset, and contains in the first column the label of
+  /// the item and then the mapped values for each map.
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph, typename _Traits = DefaultWriterTraits>
+  class EdgeMapWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::Edge Edge;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for EdgeMapWriter. It creates the EdgeMapWriter and
+    /// attach it into the given LemonWriter. If the the
+    /// \c _forceSort is true then the writer will write the edges
+    /// sorted by the labels.
+    template <typename _LabelWriter>
+    EdgeMapWriter(LemonWriter& _writer, const Graph& _graph,
+		 const _LabelWriter& _labelWriter,
+		 const std::string& _name = std::string(),
+		 bool _forceSort = true) 
+      : Parent(_writer), graph(_graph), name(_name), forceSort(_forceSort) {
+      checkConcept<_writer_bits::ItemLabelWriter<Edge>, _LabelWriter>();
+      labelWriter.reset(new _writer_bits::LabelWriter<Edge, 
+			_LabelWriter>(_labelWriter));
+    }
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for EdgeMapWriter.
+    virtual ~EdgeMapWriter() {
+      typename MapWriters::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    EdgeMapWriter(const EdgeMapWriter&);
+    void operator=(const EdgeMapWriter&);
+  
+  public:
+
+    /// \brief Add a new edge map writer command for the writer.
+    ///
+    /// Add a new edge map writer command for the writer.
+    template <typename Map>
+    EdgeMapWriter& writeEdgeMap(std::string label, const Map& map) {
+      return writeEdgeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new edge map writer command for the writer.
+    ///
+    /// Add a new edge map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    EdgeMapWriter& writeEdgeMap(std::string label, const Map& map, 
+				const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<Edge, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>,ItemWriter>();
+      writers.push_back(
+	make_pair(label, new _writer_bits::
+		  MapWriter<Edge, Map, ItemWriter>(map, iw)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@edgemaps " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      std::vector<Edge> edges;
+      for (typename Graph::EdgeIt it(graph); it != INVALID; ++it) {
+        edges.push_back(it);
+      }
+      if (forceSort) {
+	labelWriter->sort(edges);
+      }
+      os << '\t';
+      for (int i = 0; i < int(writers.size()); ++i) {
+	os << writers[i].first << '\t';
+      }
+      os << std::endl;
+      for (typename std::vector<Edge>::iterator it = edges.begin();
+           it != edges.end(); ++it) {
+
+	labelWriter->write(os, *it); os << '\t';
+	for (int i = 0; i < int(writers.size()); ++i) {
+	  writers[i].second->write(os, *it);
+	  os << '\t';
+	}
+	os << std::endl;
+      }
+    }
+
+
+  private:
+
+    typedef std::vector<std::pair<std::string, _writer_bits::
+				  MapWriterBase<Edge>*> > MapWriters;
+    MapWriters writers;
+
+    _writer_bits::MapWriterBase<Edge>* labelMap;
+
+    const Graph& graph;   
+    std::string name;
+    bool forceSort;
+
+    std::auto_ptr<_writer_bits::LabelWriterBase<Edge> > labelWriter;
+  };
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for writing extra undirected edge maps.
+  ///
+  /// The lemon format can store maps in the uedgeset. This class let
+  /// you make distinict section to store maps. The main purpose of
+  /// this class is a logical separation of some maps. The other
+  /// useful application could be to store paths in undirected edge
+  /// maps.
+  ///
+  /// The first line of the section contains the names of the maps
+  /// separated with white spaces. Each next line describes an item
+  /// in the itemset, and contains in the first column the label of
+  /// the item and then the mapped values for each map.
+  ///
+  /// \relates LemonWriter
+  template <typename _Graph, typename _Traits = DefaultWriterTraits>
+  class UEdgeMapWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+  public:
+
+    typedef _Graph Graph;
+    typedef _Traits Traits;
+    typedef typename Graph::UEdge UEdge;
+    typedef typename Graph::Edge Edge;
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for UEdgeMapWriter. It creates the UEdgeMapWriter and
+    /// attach it into the given LemonWriter. If the the
+    /// \c _forceSort is true then the writer will write the uedges
+    /// sorted by the labels.
+    template <typename _LabelWriter>
+    UEdgeMapWriter(LemonWriter& _writer, const Graph& _graph,
+		 const _LabelWriter& _labelWriter,
+		 const std::string& _name = std::string(),
+		 bool _forceSort = true) 
+      : Parent(_writer), graph(_graph), name(_name), forceSort(_forceSort) {
+      checkConcept<_writer_bits::ItemLabelWriter<UEdge>, _LabelWriter>();
+      labelWriter.reset(new _writer_bits::LabelWriter<UEdge, 
+			    _LabelWriter>(_labelWriter));
+    }
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for UEdgeMapWriter.
+    virtual ~UEdgeMapWriter() {
+      typename MapWriters::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    UEdgeMapWriter(const UEdgeMapWriter&);
+    void operator=(const UEdgeMapWriter&);
+  
+  public:
+
+    /// \brief Add a new undirected edge map writer command for the writer.
+    ///
+    /// Add a new undirected edge map writer command for the writer.
+    template <typename Map>
+    UEdgeMapWriter& writeUEdgeMap(std::string label, const Map& map) {
+      return writeUEdgeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new undirected edge map writer command for the writer.
+    ///
+    /// Add a new undirected edge map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    UEdgeMapWriter& writeUEdgeMap(std::string label, const Map& map, 
+			   const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<UEdge, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>,ItemWriter>();
+      writers.push_back(
+	make_pair(label, new _writer_bits::
+		  MapWriter<UEdge, Map, ItemWriter>(map, iw)));
+      return *this;
+    }
+
+    /// \brief Add a new directed edge map writer command for the writer.
+    ///
+    /// Add a new directed map writer command for the writer.
+    template <typename Map>
+    UEdgeMapWriter& writeEdgeMap(std::string label, const Map& map) {
+      return writeEdgeMap<typename Traits::
+	template Writer<typename Map::Value>, Map>(label, map);
+    }
+
+    /// \brief Add a new directed map writer command for the writer.
+    ///
+    /// Add a new directed map writer command for the writer.
+    template <typename ItemWriter, typename Map>
+    UEdgeMapWriter& writeEdgeMap(std::string label, const Map& map, 
+                                 const ItemWriter& iw = ItemWriter()) {
+      checkConcept<concepts::ReadMap<Edge, typename Map::Value>, Map>();
+      checkConcept<_writer_bits::ItemWriter<typename Map::Value>, ItemWriter>();
+      writeUEdgeMap("+" + label, 
+                    _writer_bits::forwardComposeMap(graph, map), iw);
+      writeUEdgeMap("-" + label, 
+                    _writer_bits::backwardComposeMap(graph, map), iw);
+      return *this;
+    }
+
+  protected:
+
+    /// \brief The header of the section.
+    ///
+    /// It gives back the header of the section.
+    virtual std::string header() {
+      return "@uedgemaps " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    virtual void write(std::ostream& os) {
+      std::vector<UEdge> uedges;
+      for (typename Graph::UEdgeIt it(graph); it != INVALID; ++it) {
+        uedges.push_back(it);
+      }
+      if (forceSort) {
+	labelWriter->sort(uedges);
+      }
+      os << '\t';
+      for (int i = 0; i < int(writers.size()); ++i) {
+	os << writers[i].first << '\t';
+      }
+      os << std::endl;
+      for (typename std::vector<UEdge>::iterator it = uedges.begin();
+           it != uedges.end(); ++it) {
+
+	labelWriter->write(os, *it); os << '\t';
+	for (int i = 0; i < int(writers.size()); ++i) {
+	  writers[i].second->write(os, *it);
+	  os << '\t';
+	}
+	os << std::endl;
+      }
+    }
+
+
+  private:
+
+    typedef std::vector<std::pair<std::string, _writer_bits::
+				  MapWriterBase<UEdge>*> > MapWriters;
+    MapWriters writers;
+
+    _writer_bits::MapWriterBase<UEdge>* labelMap;
+
+    const Graph& graph;   
+    std::string name;
+    bool forceSort;
+
+    std::auto_ptr<_writer_bits::LabelWriterBase<UEdge> > labelWriter;
+  };
+
+
+  /// \ingroup section_io
+  /// \brief SectionWriter for attributes.
+  ///
+  /// The lemon format can store multiple attribute set. Each set has
+  /// the header line \c \@attributes \c attributes_name, but the 
+  /// attributeset_name may be empty.
+  ///
+  /// The attributeset section contains several lines. Each of them starts
+  /// with the name of attribute and then the value.
+  ///
+  /// \relates LemonWriter
+  template <typename _Traits = DefaultWriterTraits>
+  class AttributeWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+    typedef _Traits Traits; 
+  public:
+    /// \brief Constructor.
+    ///
+    /// Constructor for AttributeWriter. It creates the AttributeWriter and
+    /// attach it into the given LemonWriter.
+    AttributeWriter(LemonWriter& _writer, 
+		    const std::string& _name = std::string()) 
+      : Parent(_writer), name(_name) {}
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for AttributeWriter.
+    virtual ~AttributeWriter() {
+      typename Writers::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+	delete it->second;
+      }
+    }
+
+  private:
+    AttributeWriter(const AttributeWriter&);
+    void operator=(AttributeWriter&);
+
+  public:
+    /// \brief Add an attribute writer command for the writer.
+    ///
+    /// Add an attribute writer command for the writer.
+    template <typename Value>
+    AttributeWriter& writeAttribute(std::string label, 
+				    const Value& value) {
+      return 
+	writeAttribute<typename Traits::template Writer<Value> >(label, value);
+    }
+
+    /// \brief Add an attribute writer command for the writer.
+    ///
+    /// Add an attribute writer command for the writer.
+    template <typename ItemWriter, typename Value>
+    AttributeWriter& writeAttribute(std::string label, const Value& value,
+				    const ItemWriter& iw = ItemWriter()) {
+      checkConcept<_writer_bits::ItemWriter<Value>, ItemWriter>();
+      writers.push_back(make_pair(label, new _writer_bits::
+				  ValueWriter<Value, ItemWriter>(value, iw)));
+      return *this;
+    }
+
+  protected:
+
+    /// \brief The header of section.
+    ///
+    /// It gives back the header of the section.
+    std::string header() {
+      return "@attributes " + name;
+    }
+
+    /// \brief  Writer function of the section.
+    ///
+    /// Write the content of the section.
+    void write(std::ostream& os) {
+      typename Writers::iterator it;
+      for (it = writers.begin(); it != writers.end(); ++it) {
+	os << it->first << ' ';
+	it->second->write(os);
+	os << std::endl;
+      }
+    }    
+
+    /// \brief Gives back true when the section should be written.
+    ///
+    /// Gives back true when the section should be written.
+    virtual bool valid() { return !writers.empty(); }
+
+  private:
+    std::string name;
+
+    typedef std::vector<std::pair<std::string, 
+				  _writer_bits::ValueWriterBase*> > Writers;
+    Writers writers;  
+  };
+
+
+}
+#endif
Index: lemon/list_graph.h
===================================================================
--- lemon/list_graph.h	(revision 2618)
+++ lemon/list_graph.h	(revision 2618)
@@ -0,0 +1,2249 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_LIST_GRAPH_H
+#define LEMON_LIST_GRAPH_H
+
+///\ingroup graphs
+///\file
+///\brief ListGraph, ListUGraph classes.
+
+#include <lemon/bits/base_extender.h>
+#include <lemon/bits/graph_extender.h>
+
+#include <lemon/error.h>
+
+#include <vector>
+#include <list>
+
+namespace lemon {
+
+  class ListGraphBase {
+
+  protected:
+    struct NodeT {
+      int first_in, first_out;
+      int prev, next;
+    };
+ 
+    struct EdgeT {
+      int target, source;
+      int prev_in, prev_out;
+      int next_in, next_out;
+    };
+
+    std::vector<NodeT> nodes;
+
+    int first_node;
+
+    int first_free_node;
+
+    std::vector<EdgeT> edges;
+
+    int first_free_edge;
+    
+  public:
+    
+    typedef ListGraphBase Graph;
+    
+    class Node {
+      friend class ListGraphBase;
+    protected:
+
+      int id;
+      explicit Node(int pid) { id = pid;}
+
+    public:
+      Node() {}
+      Node (Invalid) { id = -1; }
+      bool operator==(const Node& node) const {return id == node.id;}
+      bool operator!=(const Node& node) const {return id != node.id;}
+      bool operator<(const Node& node) const {return id < node.id;}
+    };
+
+    class Edge {
+      friend class ListGraphBase;
+    protected:
+
+      int id;
+      explicit Edge(int pid) { id = pid;}
+
+    public:
+      Edge() {}
+      Edge (Invalid) { id = -1; }
+      bool operator==(const Edge& edge) const {return id == edge.id;}
+      bool operator!=(const Edge& edge) const {return id != edge.id;}
+      bool operator<(const Edge& edge) const {return id < edge.id;}
+    };
+
+
+
+    ListGraphBase()
+      : nodes(), first_node(-1),
+	first_free_node(-1), edges(), first_free_edge(-1) {}
+
+    
+    int maxNodeId() const { return nodes.size()-1; } 
+    int maxEdgeId() const { return edges.size()-1; }
+
+    Node source(Edge e) const { return Node(edges[e.id].source); }
+    Node target(Edge e) const { return Node(edges[e.id].target); }
+
+
+    void first(Node& node) const { 
+      node.id = first_node;
+    }
+
+    void next(Node& node) const {
+      node.id = nodes[node.id].next;
+    }
+
+
+    void first(Edge& e) const { 
+      int n;
+      for(n = first_node; 
+	  n!=-1 && nodes[n].first_in == -1; 
+	  n = nodes[n].next) { }
+      e.id = (n == -1) ? -1 : nodes[n].first_in;
+    }
+
+    void next(Edge& edge) const {
+      if (edges[edge.id].next_in != -1) {
+	edge.id = edges[edge.id].next_in;
+      } else {
+	int n;
+	for(n = nodes[edges[edge.id].target].next;
+	    n!=-1 && nodes[n].first_in == -1; 
+	    n = nodes[n].next) { }
+	edge.id = (n == -1) ? -1 : nodes[n].first_in;
+      }      
+    }
+
+    void firstOut(Edge &e, const Node& v) const {
+      e.id = nodes[v.id].first_out;
+    }
+    void nextOut(Edge &e) const {
+      e.id=edges[e.id].next_out;
+    }
+
+    void firstIn(Edge &e, const Node& v) const {
+      e.id = nodes[v.id].first_in;
+    }
+    void nextIn(Edge &e) const {
+      e.id=edges[e.id].next_in;
+    }
+
+    
+    static int id(Node v) { return v.id; }
+    static int id(Edge e) { return e.id; }
+
+    static Node nodeFromId(int id) { return Node(id);}
+    static Edge edgeFromId(int id) { return Edge(id);}
+
+    Node addNode() {     
+      int n;
+      
+      if(first_free_node==-1) {
+	n = nodes.size();
+	nodes.push_back(NodeT());
+      } else {
+	n = first_free_node;
+	first_free_node = nodes[n].next;
+      }
+      
+      nodes[n].next = first_node;
+      if(first_node != -1) nodes[first_node].prev = n;
+      first_node = n;
+      nodes[n].prev = -1;
+      
+      nodes[n].first_in = nodes[n].first_out = -1;
+      
+      return Node(n);
+    }
+    
+    Edge addEdge(Node u, Node v) {
+      int n;      
+
+      if (first_free_edge == -1) {
+	n = edges.size();
+	edges.push_back(EdgeT());
+      } else {
+	n = first_free_edge;
+	first_free_edge = edges[n].next_in;
+      }
+      
+      edges[n].source = u.id; 
+      edges[n].target = v.id;
+
+      edges[n].next_out = nodes[u.id].first_out;
+      if(nodes[u.id].first_out != -1) {
+	edges[nodes[u.id].first_out].prev_out = n;
+      }
+      
+      edges[n].next_in = nodes[v.id].first_in;
+      if(nodes[v.id].first_in != -1) {
+	edges[nodes[v.id].first_in].prev_in = n;
+      }
+      
+      edges[n].prev_in = edges[n].prev_out = -1;
+	
+      nodes[u.id].first_out = nodes[v.id].first_in = n;
+
+      return Edge(n);
+    }
+    
+    void erase(const Node& node) {
+      int n = node.id;
+      
+      if(nodes[n].next != -1) {
+	nodes[nodes[n].next].prev = nodes[n].prev;
+      }
+      
+      if(nodes[n].prev != -1) {
+	nodes[nodes[n].prev].next = nodes[n].next;
+      } else {
+	first_node = nodes[n].next;
+      }
+      
+      nodes[n].next = first_free_node;
+      first_free_node = n;
+
+    }
+    
+    void erase(const Edge& edge) {
+      int n = edge.id;
+      
+      if(edges[n].next_in!=-1) {
+	edges[edges[n].next_in].prev_in = edges[n].prev_in;
+      }
+
+      if(edges[n].prev_in!=-1) {
+	edges[edges[n].prev_in].next_in = edges[n].next_in;
+      } else {
+	nodes[edges[n].target].first_in = edges[n].next_in;
+      }
+
+      
+      if(edges[n].next_out!=-1) {
+	edges[edges[n].next_out].prev_out = edges[n].prev_out;
+      } 
+
+      if(edges[n].prev_out!=-1) {
+	edges[edges[n].prev_out].next_out = edges[n].next_out;
+      } else {
+	nodes[edges[n].source].first_out = edges[n].next_out;
+      }
+      
+      edges[n].next_in = first_free_edge;
+      first_free_edge = n;      
+
+    }
+
+    void clear() {
+      edges.clear();
+      nodes.clear();
+      first_node = first_free_node = first_free_edge = -1;
+    }
+
+  protected:
+    void changeTarget(Edge e, Node n) 
+    {
+      if(edges[e.id].next_in != -1)
+	edges[edges[e.id].next_in].prev_in = edges[e.id].prev_in;
+      if(edges[e.id].prev_in != -1)
+	edges[edges[e.id].prev_in].next_in = edges[e.id].next_in;
+      else nodes[edges[e.id].target].first_in = edges[e.id].next_in;
+      if (nodes[n.id].first_in != -1) {
+	edges[nodes[n.id].first_in].prev_in = e.id;
+      }
+      edges[e.id].target = n.id;
+      edges[e.id].prev_in = -1;
+      edges[e.id].next_in = nodes[n.id].first_in;
+      nodes[n.id].first_in = e.id;
+    }
+    void changeSource(Edge e, Node n) 
+    {
+      if(edges[e.id].next_out != -1)
+	edges[edges[e.id].next_out].prev_out = edges[e.id].prev_out;
+      if(edges[e.id].prev_out != -1)
+	edges[edges[e.id].prev_out].next_out = edges[e.id].next_out;
+      else nodes[edges[e.id].source].first_out = edges[e.id].next_out;
+      if (nodes[n.id].first_out != -1) {
+	edges[nodes[n.id].first_out].prev_out = e.id;
+      }
+      edges[e.id].source = n.id;
+      edges[e.id].prev_out = -1;
+      edges[e.id].next_out = nodes[n.id].first_out;
+      nodes[n.id].first_out = e.id;
+    }
+
+  };
+
+  typedef GraphExtender<ListGraphBase> ExtendedListGraphBase;
+
+  /// \addtogroup graphs
+  /// @{
+
+  ///A list graph class.
+
+  ///This is a simple and fast graph implementation.
+  ///
+  ///It conforms to the \ref concepts::Graph "Graph concept" and it
+  ///also provides several additional useful extra functionalities.
+  ///The most of the member functions and nested classes are
+  ///documented only in the concept class.
+  ///
+  ///An important extra feature of this graph implementation is that
+  ///its maps are real \ref concepts::ReferenceMap "reference map"s.
+  ///
+  ///\sa concepts::Graph.
+
+  class ListGraph : public ExtendedListGraphBase {
+  private:
+    ///ListGraph is \e not copy constructible. Use GraphCopy() instead.
+    
+    ///ListGraph is \e not copy constructible. Use GraphCopy() instead.
+    ///
+    ListGraph(const ListGraph &) :ExtendedListGraphBase() {};
+    ///\brief Assignment of ListGraph to another one is \e not allowed.
+    ///Use GraphCopy() instead.
+
+    ///Assignment of ListGraph to another one is \e not allowed.
+    ///Use GraphCopy() instead.
+    void operator=(const ListGraph &) {}
+  public:
+
+    typedef ExtendedListGraphBase Parent;
+
+    /// Constructor
+    
+    /// Constructor.
+    ///
+    ListGraph() {}
+
+    ///Add a new node to the graph.
+    
+    /// \return the new node.
+    ///
+    Node addNode() { return Parent::addNode(); }
+
+    ///Add a new edge to the graph.
+    
+    ///Add a new edge to the graph with source node \c s
+    ///and target node \c t.
+    ///\return the new edge.
+    Edge addEdge(const Node& s, const Node& t) { 
+      return Parent::addEdge(s, t); 
+    }
+
+    /// Changes the target of \c e to \c n
+
+    /// Changes the target of \c e to \c n
+    ///
+    ///\note The <tt>EdgeIt</tt>s and <tt>OutEdgeIt</tt>s referencing
+    ///the changed edge remain valid. However <tt>InEdgeIt</tt>s are
+    ///invalidated.
+    ///\warning This functionality cannot be used together with the Snapshot
+    ///feature.
+    void changeTarget(Edge e, Node n) { 
+      Parent::changeTarget(e,n); 
+    }
+    /// Changes the source of \c e to \c n
+
+    /// Changes the source of \c e to \c n
+    ///
+    ///\note The <tt>EdgeIt</tt>s and <tt>InEdgeIt</tt>s referencing
+    ///the changed edge remain valid. However <tt>OutEdgeIt</tt>s are
+    ///invalidated.
+    ///\warning This functionality cannot be used together with the Snapshot
+    ///feature.
+    void changeSource(Edge e, Node n) { 
+      Parent::changeSource(e,n);
+    }
+
+    /// Invert the direction of an edge.
+
+    ///\note The <tt>EdgeIt</tt>s referencing the changed edge remain
+    ///valid. However <tt>OutEdgeIt</tt>s and <tt>InEdgeIt</tt>s are
+    ///invalidated.
+    ///\warning This functionality cannot be used together with the Snapshot
+    ///feature.
+    void reverseEdge(Edge e) {
+      Node t=target(e);
+      changeTarget(e,source(e));
+      changeSource(e,t);
+    }
+
+    /// Using this it is possible to avoid the superfluous memory
+    /// allocation: if you know that the graph you want to build will
+    /// be very large (e.g. it will contain millions of nodes and/or edges)
+    /// then it is worth reserving space for this amount before starting
+    /// to build the graph.
+    /// \sa reserveEdge
+    void reserveNode(int n) { nodes.reserve(n); };
+
+    /// \brief Using this it is possible to avoid the superfluous memory
+    /// allocation.
+
+    /// Using this it is possible to avoid the superfluous memory
+    /// allocation: if you know that the graph you want to build will
+    /// be very large (e.g. it will contain millions of nodes and/or edges)
+    /// then it is worth reserving space for this amount before starting
+    /// to build the graph.
+    /// \sa reserveNode
+    void reserveEdge(int m) { edges.reserve(m); };
+
+    ///Contract two nodes.
+
+    ///This function contracts two nodes.
+    ///
+    ///Node \p b will be removed but instead of deleting
+    ///incident edges, they will be joined to \p a.
+    ///The last parameter \p r controls whether to remove loops. \c true
+    ///means that loops will be removed.
+    ///
+    ///\note The <tt>EdgeIt</tt>s
+    ///referencing a moved edge remain
+    ///valid. However <tt>InEdgeIt</tt>s and <tt>OutEdgeIt</tt>s
+    ///may be invalidated.
+    ///\warning This functionality cannot be used together with the Snapshot
+    ///feature.
+    void contract(Node a, Node b, bool r = true) 
+    {
+      for(OutEdgeIt e(*this,b);e!=INVALID;) {
+	OutEdgeIt f=e;
+	++f;
+	if(r && target(e)==a) erase(e);
+	else changeSource(e,a);
+	e=f;
+      }
+      for(InEdgeIt e(*this,b);e!=INVALID;) {
+	InEdgeIt f=e;
+	++f;
+	if(r && source(e)==a) erase(e);
+	else changeTarget(e,a);
+	e=f;
+      }
+      erase(b);
+    }
+
+    ///Split a node.
+
+    ///This function splits a node. First a new node is added to the graph,
+    ///then the source of each outgoing edge of \c n is moved to this new node.
+    ///If \c connect is \c true (this is the default value), then a new edge
+    ///from \c n to the newly created node is also added.
+    ///\return The newly created node.
+    ///
+    ///\note The <tt>EdgeIt</tt>s referencing a moved edge remain
+    ///valid. However <tt>InEdgeIt</tt>s and <tt>OutEdgeIt</tt>s may
+    ///be invalidated.  
+    ///
+    ///\warning This functionality cannot be used together with the
+    ///Snapshot feature.  \todo It could be implemented in a bit
+    ///faster way.
+    Node split(Node n, bool connect = true) {
+      Node b = addNode();
+      for(OutEdgeIt e(*this,n);e!=INVALID;) {
+ 	OutEdgeIt f=e;
+	++f;
+	changeSource(e,b);
+	e=f;
+      }
+      if (connect) addEdge(n,b);
+      return b;
+    }
+      
+    ///Split an edge.
+
+    ///This function splits an edge. First a new node \c b is added to
+    ///the graph, then the original edge is re-targeted to \c
+    ///b. Finally an edge from \c b to the original target is added.
+    ///\return The newly created node.  
+    ///\warning This functionality
+    ///cannot be used together with the Snapshot feature.
+    Node split(Edge e) {
+      Node b = addNode();
+      addEdge(b,target(e));
+      changeTarget(e,b);
+      return b;
+    }
+      
+    /// \brief Class to make a snapshot of the graph and restore
+    /// to it later.
+    ///
+    /// Class to make a snapshot of the graph and to restore it
+    /// later.
+    ///
+    /// The newly added nodes and edges can be removed using the
+    /// restore() function.
+    ///
+    /// \warning Edge and node deletions cannot be restored. This
+    /// events invalidate the snapshot. 
+    class Snapshot {
+    protected:
+
+      typedef Parent::NodeNotifier NodeNotifier;
+
+      class NodeObserverProxy : public NodeNotifier::ObserverBase {
+      public:
+
+        NodeObserverProxy(Snapshot& _snapshot)
+          : snapshot(_snapshot) {}
+
+        using NodeNotifier::ObserverBase::attach;
+        using NodeNotifier::ObserverBase::detach;
+        using NodeNotifier::ObserverBase::attached;
+        
+      protected:
+        
+        virtual void add(const Node& node) {
+          snapshot.addNode(node);
+        }
+        virtual void add(const std::vector<Node>& nodes) {
+          for (int i = nodes.size() - 1; i >= 0; ++i) {
+            snapshot.addNode(nodes[i]);
+          }
+        }
+        virtual void erase(const Node& node) {
+          snapshot.eraseNode(node);
+        }
+        virtual void erase(const std::vector<Node>& nodes) {
+          for (int i = 0; i < int(nodes.size()); ++i) {
+            snapshot.eraseNode(nodes[i]);
+          }
+        }
+        virtual void build() {
+          Node node;
+          std::vector<Node> nodes;
+          for (notifier()->first(node); node != INVALID; 
+               notifier()->next(node)) {
+            nodes.push_back(node);
+          }
+          for (int i = nodes.size() - 1; i >= 0; --i) {
+            snapshot.addNode(nodes[i]);
+          }
+        }
+        virtual void clear() {
+          Node node;
+          for (notifier()->first(node); node != INVALID; 
+               notifier()->next(node)) {
+            snapshot.eraseNode(node);
+          }
+        }
+
+        Snapshot& snapshot;
+      };
+
+      class EdgeObserverProxy : public EdgeNotifier::ObserverBase {
+      public:
+
+        EdgeObserverProxy(Snapshot& _snapshot)
+          : snapshot(_snapshot) {}
+
+        using EdgeNotifier::ObserverBase::attach;
+        using EdgeNotifier::ObserverBase::detach;
+        using EdgeNotifier::ObserverBase::attached;
+        
+      protected:
+
+        virtual void add(const Edge& edge) {
+          snapshot.addEdge(edge);
+        }
+        virtual void add(const std::vector<Edge>& edges) {
+          for (int i = edges.size() - 1; i >= 0; ++i) {
+            snapshot.addEdge(edges[i]);
+          }
+        }
+        virtual void erase(const Edge& edge) {
+          snapshot.eraseEdge(edge);
+        }
+        virtual void erase(const std::vector<Edge>& edges) {
+          for (int i = 0; i < int(edges.size()); ++i) {
+            snapshot.eraseEdge(edges[i]);
+          }
+        }
+        virtual void build() {
+          Edge edge;
+          std::vector<Edge> edges;
+          for (notifier()->first(edge); edge != INVALID; 
+               notifier()->next(edge)) {
+            edges.push_back(edge);
+          }
+          for (int i = edges.size() - 1; i >= 0; --i) {
+            snapshot.addEdge(edges[i]);
+          }
+        }
+        virtual void clear() {
+          Edge edge;
+          for (notifier()->first(edge); edge != INVALID; 
+               notifier()->next(edge)) {
+            snapshot.eraseEdge(edge);
+          }
+        }
+
+        Snapshot& snapshot;
+      };
+      
+      ListGraph *graph;
+
+      NodeObserverProxy node_observer_proxy;
+      EdgeObserverProxy edge_observer_proxy;
+
+      std::list<Node> added_nodes;
+      std::list<Edge> added_edges;
+
+
+      void addNode(const Node& node) {
+        added_nodes.push_front(node);        
+      }
+      void eraseNode(const Node& node) {
+        std::list<Node>::iterator it = 
+          std::find(added_nodes.begin(), added_nodes.end(), node);
+        if (it == added_nodes.end()) {
+          clear();
+          edge_observer_proxy.detach();
+          throw NodeNotifier::ImmediateDetach();
+        } else {
+          added_nodes.erase(it);
+        }
+      }
+
+      void addEdge(const Edge& edge) {
+        added_edges.push_front(edge);        
+      }
+      void eraseEdge(const Edge& edge) {
+        std::list<Edge>::iterator it = 
+          std::find(added_edges.begin(), added_edges.end(), edge);
+        if (it == added_edges.end()) {
+          clear();
+          node_observer_proxy.detach(); 
+          throw EdgeNotifier::ImmediateDetach();
+        } else {
+          added_edges.erase(it);
+        }        
+      }
+
+      void attach(ListGraph &_graph) {
+	graph = &_graph;
+	node_observer_proxy.attach(graph->notifier(Node()));
+        edge_observer_proxy.attach(graph->notifier(Edge()));
+      }
+            
+      void detach() {
+	node_observer_proxy.detach();
+	edge_observer_proxy.detach();
+      }
+
+      bool attached() const {
+        return node_observer_proxy.attached();
+      }
+
+      void clear() {
+        added_nodes.clear();
+        added_edges.clear();        
+      }
+
+    public:
+
+      /// \brief Default constructor.
+      ///
+      /// Default constructor.
+      /// To actually make a snapshot you must call save().
+      Snapshot() 
+        : graph(0), node_observer_proxy(*this), 
+          edge_observer_proxy(*this) {}
+      
+      /// \brief Constructor that immediately makes a snapshot.
+      ///      
+      /// This constructor immediately makes a snapshot of the graph.
+      /// \param _graph The graph we make a snapshot of.
+      Snapshot(ListGraph &_graph) 
+        : node_observer_proxy(*this), 
+          edge_observer_proxy(*this) {
+	attach(_graph);
+      }
+      
+      /// \brief Make a snapshot.
+      ///
+      /// Make a snapshot of the graph.
+      ///
+      /// This function can be called more than once. In case of a repeated
+      /// call, the previous snapshot gets lost.
+      /// \param _graph The graph we make the snapshot of.
+      void save(ListGraph &_graph) {
+        if (attached()) {
+          detach();
+          clear();
+        }
+        attach(_graph);
+      }
+      
+      /// \brief Undo the changes until the last snapshot.
+      // 
+      /// Undo the changes until the last snapshot created by save().
+      void restore() {
+	detach();
+	for(std::list<Edge>::iterator it = added_edges.begin(); 
+            it != added_edges.end(); ++it) {
+	  graph->erase(*it);
+	}
+	for(std::list<Node>::iterator it = added_nodes.begin(); 
+            it != added_nodes.end(); ++it) {
+	  graph->erase(*it);
+	}
+        clear();
+      }
+
+      /// \brief Gives back true when the snapshot is valid.
+      ///
+      /// Gives back true when the snapshot is valid.
+      bool valid() const {
+        return attached();
+      }
+    };
+    
+  };
+
+  ///@}
+
+  class ListUGraphBase {
+
+  protected:
+
+    struct NodeT {
+      int first_out;
+      int prev, next;
+    };
+ 
+    struct EdgeT {
+      int target;
+      int prev_out, next_out;
+    };
+
+    std::vector<NodeT> nodes;
+
+    int first_node;
+
+    int first_free_node;
+
+    std::vector<EdgeT> edges;
+
+    int first_free_edge;
+    
+  public:
+    
+    typedef ListUGraphBase Graph;
+
+    class Node;
+    class Edge;
+    class UEdge;
+    
+    class Node {
+      friend class ListUGraphBase;
+    protected:
+
+      int id;
+      explicit Node(int pid) { id = pid;}
+
+    public:
+      Node() {}
+      Node (Invalid) { id = -1; }
+      bool operator==(const Node& node) const {return id == node.id;}
+      bool operator!=(const Node& node) const {return id != node.id;}
+      bool operator<(const Node& node) const {return id < node.id;}
+    };
+
+    class UEdge {
+      friend class ListUGraphBase;
+    protected:
+
+      int id;
+      explicit UEdge(int pid) { id = pid;}
+
+    public:
+      UEdge() {}
+      UEdge (Invalid) { id = -1; }
+      bool operator==(const UEdge& edge) const {return id == edge.id;}
+      bool operator!=(const UEdge& edge) const {return id != edge.id;}
+      bool operator<(const UEdge& edge) const {return id < edge.id;}
+    };
+
+    class Edge {
+      friend class ListUGraphBase;
+    protected:
+
+      int id;
+      explicit Edge(int pid) { id = pid;}
+
+    public:
+      operator UEdge() const { return uEdgeFromId(id / 2); }
+
+      Edge() {}
+      Edge (Invalid) { id = -1; }
+      bool operator==(const Edge& edge) const {return id == edge.id;}
+      bool operator!=(const Edge& edge) const {return id != edge.id;}
+      bool operator<(const Edge& edge) const {return id < edge.id;}
+    };
+
+
+
+    ListUGraphBase()
+      : nodes(), first_node(-1),
+	first_free_node(-1), edges(), first_free_edge(-1) {}
+
+    
+    int maxNodeId() const { return nodes.size()-1; } 
+    int maxUEdgeId() const { return edges.size() / 2 - 1; }
+    int maxEdgeId() const { return edges.size()-1; }
+
+    Node source(Edge e) const { return Node(edges[e.id ^ 1].target); }
+    Node target(Edge e) const { return Node(edges[e.id].target); }
+
+    Node source(UEdge e) const { return Node(edges[2 * e.id].target); }
+    Node target(UEdge e) const { return Node(edges[2 * e.id + 1].target); }
+
+    static bool direction(Edge e) {
+      return (e.id & 1) == 1;
+    }
+
+    static Edge direct(UEdge e, bool d) {
+      return Edge(e.id * 2 + (d ? 1 : 0));
+    }
+
+    void first(Node& node) const { 
+      node.id = first_node;
+    }
+
+    void next(Node& node) const {
+      node.id = nodes[node.id].next;
+    }
+
+    void first(Edge& e) const { 
+      int n = first_node;
+      while (n != -1 && nodes[n].first_out == -1) {
+        n = nodes[n].next;
+      }
+      e.id = (n == -1) ? -1 : nodes[n].first_out;
+    }
+
+    void next(Edge& e) const {
+      if (edges[e.id].next_out != -1) {
+	e.id = edges[e.id].next_out;
+      } else {
+	int n = nodes[edges[e.id ^ 1].target].next;
+        while(n != -1 && nodes[n].first_out == -1) {
+          n = nodes[n].next;
+        }
+	e.id = (n == -1) ? -1 : nodes[n].first_out;
+      }      
+    }
+
+    void first(UEdge& e) const { 
+      int n = first_node;
+      while (n != -1) {
+        e.id = nodes[n].first_out;
+        while ((e.id & 1) != 1) {
+          e.id = edges[e.id].next_out;
+        }
+        if (e.id != -1) {
+          e.id /= 2;
+          return;
+        } 
+        n = nodes[n].next;
+      }
+      e.id = -1;
+    }
+
+    void next(UEdge& e) const {
+      int n = edges[e.id * 2].target;
+      e.id = edges[(e.id * 2) | 1].next_out;
+      while ((e.id & 1) != 1) {
+        e.id = edges[e.id].next_out;
+      }
+      if (e.id != -1) {
+        e.id /= 2;
+        return;
+      } 
+      n = nodes[n].next;
+      while (n != -1) {
+        e.id = nodes[n].first_out;
+        while ((e.id & 1) != 1) {
+          e.id = edges[e.id].next_out;
+        }
+        if (e.id != -1) {
+          e.id /= 2;
+          return;
+        } 
+        n = nodes[n].next;
+      }
+      e.id = -1;
+    }
+
+    void firstOut(Edge &e, const Node& v) const {
+      e.id = nodes[v.id].first_out;
+    }
+    void nextOut(Edge &e) const {
+      e.id = edges[e.id].next_out;
+    }
+
+    void firstIn(Edge &e, const Node& v) const {
+      e.id = ((nodes[v.id].first_out) ^ 1);
+      if (e.id == -2) e.id = -1;
+    }
+    void nextIn(Edge &e) const {
+      e.id = ((edges[e.id ^ 1].next_out) ^ 1);
+      if (e.id == -2) e.id = -1;
+    }
+
+    void firstInc(UEdge &e, bool& d, const Node& v) const {
+      int de = nodes[v.id].first_out;
+      if (de != -1 ) {
+        e.id = de / 2;
+        d = ((de & 1) == 1);
+      } else {
+        e.id = -1;
+        d = true;
+      }
+    }
+    void nextInc(UEdge &e, bool& d) const {
+      int de = (edges[(e.id * 2) | (d ? 1 : 0)].next_out);
+      if (de != -1 ) {
+        e.id = de / 2;
+        d = ((de & 1) == 1);
+      } else {
+        e.id = -1;
+        d = true;
+      }
+    }
+    
+    static int id(Node v) { return v.id; }
+    static int id(Edge e) { return e.id; }
+    static int id(UEdge e) { return e.id; }
+
+    static Node nodeFromId(int id) { return Node(id);}
+    static Edge edgeFromId(int id) { return Edge(id);}
+    static UEdge uEdgeFromId(int id) { return UEdge(id);}
+
+    Node addNode() {     
+      int n;
+      
+      if(first_free_node==-1) {
+	n = nodes.size();
+	nodes.push_back(NodeT());
+      } else {
+	n = first_free_node;
+	first_free_node = nodes[n].next;
+      }
+      
+      nodes[n].next = first_node;
+      if (first_node != -1) nodes[first_node].prev = n;
+      first_node = n;
+      nodes[n].prev = -1;
+      
+      nodes[n].first_out = -1;
+      
+      return Node(n);
+    }
+    
+    UEdge addEdge(Node u, Node v) {
+      int n;      
+
+      if (first_free_edge == -1) {
+	n = edges.size();
+	edges.push_back(EdgeT());
+	edges.push_back(EdgeT());
+      } else {
+	n = first_free_edge;
+	first_free_edge = edges[n].next_out;
+      }
+      
+      edges[n].target = u.id;
+      edges[n | 1].target = v.id;
+
+      edges[n].next_out = nodes[v.id].first_out;
+      if (nodes[v.id].first_out != -1) {
+	edges[nodes[v.id].first_out].prev_out = n;
+      }      
+      edges[n].prev_out = -1;
+      nodes[v.id].first_out = n;
+      
+      edges[n | 1].next_out = nodes[u.id].first_out;
+      if (nodes[u.id].first_out != -1) {
+	edges[nodes[u.id].first_out].prev_out = (n | 1);
+      }
+      edges[n | 1].prev_out = -1;      
+      nodes[u.id].first_out = (n | 1);
+
+      return UEdge(n / 2);
+    }
+    
+    void erase(const Node& node) {
+      int n = node.id;
+      
+      if(nodes[n].next != -1) {
+	nodes[nodes[n].next].prev = nodes[n].prev;
+      }
+      
+      if(nodes[n].prev != -1) {
+	nodes[nodes[n].prev].next = nodes[n].next;
+      } else {
+	first_node = nodes[n].next;
+      }
+      
+      nodes[n].next = first_free_node;
+      first_free_node = n;
+
+    }
+    
+    void erase(const UEdge& edge) {
+      int n = edge.id * 2;
+      
+      if (edges[n].next_out != -1) {
+	edges[edges[n].next_out].prev_out = edges[n].prev_out;
+      } 
+
+      if (edges[n].prev_out != -1) {
+	edges[edges[n].prev_out].next_out = edges[n].next_out;
+      } else {
+	nodes[edges[n | 1].target].first_out = edges[n].next_out;
+      }
+
+      if (edges[n | 1].next_out != -1) {
+	edges[edges[n | 1].next_out].prev_out = edges[n | 1].prev_out;
+      } 
+
+      if (edges[n | 1].prev_out != -1) {
+	edges[edges[n | 1].prev_out].next_out = edges[n | 1].next_out;
+      } else {
+	nodes[edges[n].target].first_out = edges[n | 1].next_out;
+      }
+      
+      edges[n].next_out = first_free_edge;
+      first_free_edge = n;      
+
+    }
+
+    void clear() {
+      edges.clear();
+      nodes.clear();
+      first_node = first_free_node = first_free_edge = -1;
+    }
+
+  protected:
+
+    void changeTarget(UEdge e, Node n) {
+      if(edges[2 * e.id].next_out != -1) {
+	edges[edges[2 * e.id].next_out].prev_out = edges[2 * e.id].prev_out;
+      }
+      if(edges[2 * e.id].prev_out != -1) {
+	edges[edges[2 * e.id].prev_out].next_out = 
+          edges[2 * e.id].next_out;
+      } else {
+        nodes[edges[(2 * e.id) | 1].target].first_out = 
+          edges[2 * e.id].next_out;
+      }
+
+      if (nodes[n.id].first_out != -1) {
+	edges[nodes[n.id].first_out].prev_out = 2 * e.id;
+      }
+      edges[(2 * e.id) | 1].target = n.id;
+      edges[2 * e.id].prev_out = -1;
+      edges[2 * e.id].next_out = nodes[n.id].first_out;
+      nodes[n.id].first_out = 2 * e.id;
+    }
+
+    void changeSource(UEdge e, Node n) {
+      if(edges[(2 * e.id) | 1].next_out != -1) {
+	edges[edges[(2 * e.id) | 1].next_out].prev_out = 
+          edges[(2 * e.id) | 1].prev_out;
+      }
+      if(edges[(2 * e.id) | 1].prev_out != -1) {
+	edges[edges[(2 * e.id) | 1].prev_out].next_out = 
+          edges[(2 * e.id) | 1].next_out;
+      } else {
+        nodes[edges[2 * e.id].target].first_out = 
+          edges[(2 * e.id) | 1].next_out;
+      }
+
+      if (nodes[n.id].first_out != -1) {
+	edges[nodes[n.id].first_out].prev_out = ((2 * e.id) | 1);
+      }
+      edges[2 * e.id].target = n.id;
+      edges[(2 * e.id) | 1].prev_out = -1;
+      edges[(2 * e.id) | 1].next_out = nodes[n.id].first_out;
+      nodes[n.id].first_out = ((2 * e.id) | 1);
+    }
+
+  };
+
+//   typedef UGraphExtender<UndirGraphExtender<ListGraphBase> > 
+//   ExtendedListUGraphBase;
+
+  typedef UGraphExtender<ListUGraphBase> ExtendedListUGraphBase;
+
+
+
+  /// \addtogroup graphs
+  /// @{
+
+  ///An undirected list graph class.
+
+  ///This is a simple and fast undirected graph implementation.
+  ///
+  ///An important extra feature of this graph implementation is that
+  ///its maps are real \ref concepts::ReferenceMap "reference map"s.
+  ///
+  ///It conforms to the
+  ///\ref concepts::UGraph "UGraph concept".
+  ///
+  ///\sa concepts::UGraph.
+  ///
+  class ListUGraph : public ExtendedListUGraphBase {
+  private:
+    ///ListUGraph is \e not copy constructible. Use UGraphCopy() instead.
+
+    ///ListUGraph is \e not copy constructible. Use UGraphCopy() instead.
+    ///
+    ListUGraph(const ListUGraph &) :ExtendedListUGraphBase()  {};
+    ///\brief Assignment of ListUGraph to another one is \e not allowed.
+    ///Use UGraphCopy() instead.
+
+    ///Assignment of ListUGraph to another one is \e not allowed.
+    ///Use UGraphCopy() instead.
+    void operator=(const ListUGraph &) {}
+  public:
+    /// Constructor
+    
+    /// Constructor.
+    ///
+    ListUGraph() {}
+
+    typedef ExtendedListUGraphBase Parent;
+
+    typedef Parent::OutEdgeIt IncEdgeIt;
+
+    /// \brief Add a new node to the graph.
+    ///
+    /// \return the new node.
+    ///
+    Node addNode() { return Parent::addNode(); }
+
+    /// \brief Add a new edge to the graph.
+    ///
+    /// Add a new edge to the graph with source node \c s
+    /// and target node \c t.
+    /// \return the new undirected edge.
+    UEdge addEdge(const Node& s, const Node& t) { 
+      return Parent::addEdge(s, t); 
+    }
+    /// \brief Changes the source of \c e to \c n
+    ///
+    /// Changes the source of \c e to \c n
+    ///
+    ///\note The <tt>EdgeIt</tt>s and <tt>InEdgeIt</tt>s
+    ///referencing the changed edge remain
+    ///valid. However <tt>OutEdgeIt</tt>s are invalidated.
+    void changeSource(UEdge e, Node n) { 
+      Parent::changeSource(e,n); 
+    }    
+    /// \brief Changes the target of \c e to \c n
+    ///
+    /// Changes the target of \c e to \c n
+    ///
+    /// \note The <tt>EdgeIt</tt>s referencing the changed edge remain
+    /// valid. However the other iterators may be invalidated.
+    void changeTarget(UEdge e, Node n) { 
+      Parent::changeTarget(e,n); 
+    }
+    /// \brief Changes the source of \c e to \c n
+    ///
+    /// Changes the source of \c e to \c n. It changes the proper
+    /// node of the represented undirected edge.
+    ///
+    ///\note The <tt>EdgeIt</tt>s and <tt>InEdgeIt</tt>s
+    ///referencing the changed edge remain
+    ///valid. However <tt>OutEdgeIt</tt>s are invalidated.
+    void changeSource(Edge e, Node n) { 
+      if (Parent::direction(e)) {
+        Parent::changeSource(e,n);
+      } else {
+        Parent::changeTarget(e,n);
+      } 
+    }
+    /// \brief Changes the target of \c e to \c n
+    ///
+    /// Changes the target of \c e to \c n. It changes the proper
+    /// node of the represented undirected edge.
+    ///
+    ///\note The <tt>EdgeIt</tt>s and <tt>OutEdgeIt</tt>s
+    ///referencing the changed edge remain
+    ///valid. However <tt>InEdgeIt</tt>s are invalidated.
+    void changeTarget(Edge e, Node n) { 
+      if (Parent::direction(e)) {
+        Parent::changeTarget(e,n);
+      } else {
+        Parent::changeSource(e,n);
+      } 
+    }
+    /// \brief Contract two nodes.
+    ///
+    /// This function contracts two nodes.
+    ///
+    /// Node \p b will be removed but instead of deleting
+    /// its neighboring edges, they will be joined to \p a.
+    /// The last parameter \p r controls whether to remove loops. \c true
+    /// means that loops will be removed.
+    ///
+    /// \note The <tt>EdgeIt</tt>s referencing a moved edge remain
+    /// valid.
+    void contract(Node a, Node b, bool r = true) {
+      for(IncEdgeIt e(*this, b); e!=INVALID;) {
+	IncEdgeIt f = e; ++f;
+	if (r && runningNode(e) == a) {
+	  erase(e);
+	} else if (source(e) == b) {
+	  changeSource(e, a);
+	} else {
+	  changeTarget(e, a);
+	}
+	e = f;
+      }
+      erase(b);
+    }
+
+
+    /// \brief Class to make a snapshot of the graph and restore
+    /// to it later.
+    ///
+    /// Class to make a snapshot of the graph and to restore it
+    /// later.
+    ///
+    /// The newly added nodes and undirected edges can be removed
+    /// using the restore() function.
+    ///
+    /// \warning Edge and node deletions cannot be restored. This
+    /// events invalidate the snapshot. 
+    class Snapshot {
+    protected:
+
+      typedef Parent::NodeNotifier NodeNotifier;
+
+      class NodeObserverProxy : public NodeNotifier::ObserverBase {
+      public:
+
+        NodeObserverProxy(Snapshot& _snapshot)
+          : snapshot(_snapshot) {}
+
+        using NodeNotifier::ObserverBase::attach;
+        using NodeNotifier::ObserverBase::detach;
+        using NodeNotifier::ObserverBase::attached;
+        
+      protected:
+        
+        virtual void add(const Node& node) {
+          snapshot.addNode(node);
+        }
+        virtual void add(const std::vector<Node>& nodes) {
+          for (int i = nodes.size() - 1; i >= 0; ++i) {
+            snapshot.addNode(nodes[i]);
+          }
+        }
+        virtual void erase(const Node& node) {
+          snapshot.eraseNode(node);
+        }
+        virtual void erase(const std::vector<Node>& nodes) {
+          for (int i = 0; i < int(nodes.size()); ++i) {
+            snapshot.eraseNode(nodes[i]);
+          }
+        }
+        virtual void build() {
+          Node node;
+          std::vector<Node> nodes;
+          for (notifier()->first(node); node != INVALID; 
+               notifier()->next(node)) {
+            nodes.push_back(node);
+          }
+          for (int i = nodes.size() - 1; i >= 0; --i) {
+            snapshot.addNode(nodes[i]);
+          }
+        }
+        virtual void clear() {
+          Node node;
+          for (notifier()->first(node); node != INVALID; 
+               notifier()->next(node)) {
+            snapshot.eraseNode(node);
+          }
+        }
+
+        Snapshot& snapshot;
+      };
+
+      class UEdgeObserverProxy : public UEdgeNotifier::ObserverBase {
+      public:
+
+        UEdgeObserverProxy(Snapshot& _snapshot)
+          : snapshot(_snapshot) {}
+
+        using UEdgeNotifier::ObserverBase::attach;
+        using UEdgeNotifier::ObserverBase::detach;
+        using UEdgeNotifier::ObserverBase::attached;
+        
+      protected:
+
+        virtual void add(const UEdge& edge) {
+          snapshot.addUEdge(edge);
+        }
+        virtual void add(const std::vector<UEdge>& edges) {
+          for (int i = edges.size() - 1; i >= 0; ++i) {
+            snapshot.addUEdge(edges[i]);
+          }
+        }
+        virtual void erase(const UEdge& edge) {
+          snapshot.eraseUEdge(edge);
+        }
+        virtual void erase(const std::vector<UEdge>& edges) {
+          for (int i = 0; i < int(edges.size()); ++i) {
+            snapshot.eraseUEdge(edges[i]);
+          }
+        }
+        virtual void build() {
+          UEdge edge;
+          std::vector<UEdge> edges;
+          for (notifier()->first(edge); edge != INVALID; 
+               notifier()->next(edge)) {
+            edges.push_back(edge);
+          }
+          for (int i = edges.size() - 1; i >= 0; --i) {
+            snapshot.addUEdge(edges[i]);
+          }
+        }
+        virtual void clear() {
+          UEdge edge;
+          for (notifier()->first(edge); edge != INVALID; 
+               notifier()->next(edge)) {
+            snapshot.eraseUEdge(edge);
+          }
+        }
+
+        Snapshot& snapshot;
+      };
+      
+      ListUGraph *graph;
+
+      NodeObserverProxy node_observer_proxy;
+      UEdgeObserverProxy edge_observer_proxy;
+
+      std::list<Node> added_nodes;
+      std::list<UEdge> added_edges;
+
+
+      void addNode(const Node& node) {
+        added_nodes.push_front(node);        
+      }
+      void eraseNode(const Node& node) {
+        std::list<Node>::iterator it = 
+          std::find(added_nodes.begin(), added_nodes.end(), node);
+        if (it == added_nodes.end()) {
+          clear();
+          edge_observer_proxy.detach();
+          throw NodeNotifier::ImmediateDetach();
+        } else {
+          added_nodes.erase(it);
+        }
+      }
+
+      void addUEdge(const UEdge& edge) {
+        added_edges.push_front(edge);        
+      }
+      void eraseUEdge(const UEdge& edge) {
+        std::list<UEdge>::iterator it = 
+          std::find(added_edges.begin(), added_edges.end(), edge);
+        if (it == added_edges.end()) {
+          clear();
+          node_observer_proxy.detach();
+          throw UEdgeNotifier::ImmediateDetach();
+        } else {
+          added_edges.erase(it);
+        }        
+      }
+
+      void attach(ListUGraph &_graph) {
+	graph = &_graph;
+	node_observer_proxy.attach(graph->notifier(Node()));
+        edge_observer_proxy.attach(graph->notifier(UEdge()));
+      }
+            
+      void detach() {
+	node_observer_proxy.detach();
+	edge_observer_proxy.detach();
+      }
+
+      bool attached() const {
+        return node_observer_proxy.attached();
+      }
+
+      void clear() {
+        added_nodes.clear();
+        added_edges.clear();        
+      }
+
+    public:
+
+      /// \brief Default constructor.
+      ///
+      /// Default constructor.
+      /// To actually make a snapshot you must call save().
+      Snapshot() 
+        : graph(0), node_observer_proxy(*this), 
+          edge_observer_proxy(*this) {}
+      
+      /// \brief Constructor that immediately makes a snapshot.
+      ///      
+      /// This constructor immediately makes a snapshot of the graph.
+      /// \param _graph The graph we make a snapshot of.
+      Snapshot(ListUGraph &_graph) 
+        : node_observer_proxy(*this), 
+          edge_observer_proxy(*this) {
+	attach(_graph);
+      }
+      
+      /// \brief Make a snapshot.
+      ///
+      /// Make a snapshot of the graph.
+      ///
+      /// This function can be called more than once. In case of a repeated
+      /// call, the previous snapshot gets lost.
+      /// \param _graph The graph we make the snapshot of.
+      void save(ListUGraph &_graph) {
+        if (attached()) {
+          detach();
+          clear();
+        }
+        attach(_graph);
+      }
+      
+      /// \brief Undo the changes until the last snapshot.
+      // 
+      /// Undo the changes until the last snapshot created by save().
+      void restore() {
+	detach();
+	for(std::list<UEdge>::iterator it = added_edges.begin(); 
+            it != added_edges.end(); ++it) {
+	  graph->erase(*it);
+	}
+	for(std::list<Node>::iterator it = added_nodes.begin(); 
+            it != added_nodes.end(); ++it) {
+	  graph->erase(*it);
+	}
+        clear();
+      }
+
+      /// \brief Gives back true when the snapshot is valid.
+      ///
+      /// Gives back true when the snapshot is valid.
+      bool valid() const {
+        return attached();
+      }
+    };
+  };
+
+
+  class ListBpUGraphBase {
+  public:
+
+    class NodeSetError : public LogicError {
+    public:
+      virtual const char* what() const throw() { 
+	return "lemon::ListBpUGraph::NodeSetError";
+      }
+    };
+
+  protected:
+
+    struct NodeT {
+      int first_edge, prev, next;
+    };
+
+    struct UEdgeT {
+      int aNode, prev_out, next_out;
+      int bNode, prev_in, next_in;
+    };
+
+    std::vector<NodeT> aNodes;
+    std::vector<NodeT> bNodes;
+
+    std::vector<UEdgeT> edges;
+
+    int first_anode;
+    int first_free_anode;
+
+    int first_bnode;
+    int first_free_bnode;
+
+    int first_free_edge;
+
+  public:
+  
+    class Node {
+      friend class ListBpUGraphBase;
+    protected:
+      int id;
+
+      explicit Node(int _id) : id(_id) {}
+    public:
+      Node() {}
+      Node(Invalid) { id = -1; }
+      bool operator==(const Node i) const {return id==i.id;}
+      bool operator!=(const Node i) const {return id!=i.id;}
+      bool operator<(const Node i) const {return id<i.id;}
+    };
+
+    class UEdge {
+      friend class ListBpUGraphBase;
+    protected:
+      int id;
+
+      explicit UEdge(int _id) { id = _id;}
+    public:
+      UEdge() {}
+      UEdge (Invalid) { id = -1; }
+      bool operator==(const UEdge i) const {return id==i.id;}
+      bool operator!=(const UEdge i) const {return id!=i.id;}
+      bool operator<(const UEdge i) const {return id<i.id;}
+    };
+
+    ListBpUGraphBase()
+      : first_anode(-1), first_free_anode(-1),
+        first_bnode(-1), first_free_bnode(-1),
+        first_free_edge(-1) {}
+
+    void firstANode(Node& node) const {
+      node.id = first_anode != -1 ? (first_anode << 1) : -1;
+    }
+    void nextANode(Node& node) const {
+      node.id = aNodes[node.id >> 1].next;
+    }
+
+    void firstBNode(Node& node) const {
+      node.id = first_bnode != -1 ? (first_bnode << 1) + 1 : -1;
+    }
+    void nextBNode(Node& node) const {
+      node.id = bNodes[node.id >> 1].next;
+    }
+
+    void first(Node& node) const {
+      if (first_anode != -1) {
+        node.id = (first_anode << 1);
+      } else if (first_bnode != -1) {
+        node.id = (first_bnode << 1) + 1;
+      } else {
+        node.id = -1;
+      }
+    }
+    void next(Node& node) const {
+      if (aNode(node)) {
+        node.id = aNodes[node.id >> 1].next;
+        if (node.id == -1) {
+          if (first_bnode != -1) {
+            node.id = (first_bnode << 1) + 1;
+          }
+        }
+      } else {
+        node.id = bNodes[node.id >> 1].next;
+      }
+    }
+  
+    void first(UEdge& edge) const {
+      int aid = first_anode;
+      while (aid != -1 && aNodes[aid].first_edge == -1) {
+        aid = aNodes[aid].next != -1 ? 
+          aNodes[aid].next >> 1 : -1;
+      }
+      if (aid != -1) {
+        edge.id = aNodes[aid].first_edge;
+      } else {
+        edge.id = -1;
+      }
+    }
+    void next(UEdge& edge) const {
+      int aid = edges[edge.id].aNode >> 1;
+      edge.id = edges[edge.id].next_out;
+      if (edge.id == -1) {
+        aid = aNodes[aid].next != -1 ? 
+          aNodes[aid].next >> 1 : -1;
+        while (aid != -1 && aNodes[aid].first_edge == -1) {
+          aid = aNodes[aid].next != -1 ? 
+          aNodes[aid].next >> 1 : -1;
+        }
+        if (aid != -1) {
+          edge.id = aNodes[aid].first_edge;
+        } else {
+          edge.id = -1;
+        }
+      }
+    }
+
+    void firstFromANode(UEdge& edge, const Node& node) const {
+      LEMON_ASSERT((node.id & 1) == 0, NodeSetError());
+      edge.id = aNodes[node.id >> 1].first_edge;
+    }
+    void nextFromANode(UEdge& edge) const {
+      edge.id = edges[edge.id].next_out;
+    }
+
+    void firstFromBNode(UEdge& edge, const Node& node) const {
+      LEMON_ASSERT((node.id & 1) == 1, NodeSetError());
+      edge.id = bNodes[node.id >> 1].first_edge;
+    }
+    void nextFromBNode(UEdge& edge) const {
+      edge.id = edges[edge.id].next_in;
+    }
+
+    static int id(const Node& node) {
+      return node.id;
+    }
+    static Node nodeFromId(int id) {
+      return Node(id);
+    }
+    int maxNodeId() const {
+      return aNodes.size() > bNodes.size() ?
+	aNodes.size() * 2 - 2 : bNodes.size() * 2 - 1;
+    }
+  
+    static int id(const UEdge& edge) {
+      return edge.id;
+    }
+    static UEdge uEdgeFromId(int id) {
+      return UEdge(id);
+    }
+    int maxUEdgeId() const {
+      return edges.size();
+    }
+  
+    static int aNodeId(const Node& node) {
+      return node.id >> 1;
+    }
+    static Node nodeFromANodeId(int id) {
+      return Node(id << 1);
+    }
+    int maxANodeId() const {
+      return aNodes.size();
+    }
+
+    static int bNodeId(const Node& node) {
+      return node.id >> 1;
+    }
+    static Node nodeFromBNodeId(int id) {
+      return Node((id << 1) + 1);
+    }
+    int maxBNodeId() const {
+      return bNodes.size();
+    }
+
+    Node aNode(const UEdge& edge) const {
+      return Node(edges[edge.id].aNode);
+    }
+    Node bNode(const UEdge& edge) const {
+      return Node(edges[edge.id].bNode);
+    }
+
+    static bool aNode(const Node& node) {
+      return (node.id & 1) == 0;
+    }
+
+    static bool bNode(const Node& node) {
+      return (node.id & 1) == 1;
+    }
+
+    Node addANode() {
+      int aid;
+      if (first_free_anode == -1) {
+        aid = aNodes.size();
+        aNodes.push_back(NodeT());
+      } else {
+        aid = first_free_anode;
+        first_free_anode = aNodes[first_free_anode].next;
+      }
+      if (first_anode != -1) {
+        aNodes[aid].next = first_anode << 1;
+        aNodes[first_anode].prev = aid << 1;
+      } else {
+        aNodes[aid].next = -1;
+      }
+      aNodes[aid].prev = -1;
+      first_anode = aid;
+      aNodes[aid].first_edge = -1;
+      return Node(aid << 1);
+    }
+
+    Node addBNode() {
+      int bid;
+      if (first_free_bnode == -1) {
+        bid = bNodes.size();
+        bNodes.push_back(NodeT());
+      } else {
+        bid = first_free_bnode;
+        first_free_bnode = bNodes[first_free_bnode].next;
+      }
+      if (first_bnode != -1) {
+        bNodes[bid].next = (first_bnode << 1) + 1;
+        bNodes[first_bnode].prev = (bid << 1) + 1;
+      } else {
+        bNodes[bid].next = -1;
+      }
+      bNodes[bid].prev = -1;
+      first_bnode = bid;
+      bNodes[bid].first_edge = -1;
+      return Node((bid << 1) + 1);
+    }
+
+    UEdge addEdge(const Node& source, const Node& target) {
+      LEMON_ASSERT(((source.id ^ target.id) & 1) == 1, NodeSetError());
+      int edgeId;
+      if (first_free_edge != -1) {
+        edgeId = first_free_edge;
+        first_free_edge = edges[edgeId].next_out;
+      } else {
+        edgeId = edges.size();
+        edges.push_back(UEdgeT());
+      }
+      if ((source.id & 1) == 0) {
+	edges[edgeId].aNode = source.id;
+	edges[edgeId].bNode = target.id;
+      } else {
+	edges[edgeId].aNode = target.id;
+	edges[edgeId].bNode = source.id;
+      }
+      edges[edgeId].next_out = aNodes[edges[edgeId].aNode >> 1].first_edge;
+      edges[edgeId].prev_out = -1;
+      if (aNodes[edges[edgeId].aNode >> 1].first_edge != -1) {
+        edges[aNodes[edges[edgeId].aNode >> 1].first_edge].prev_out = edgeId;
+      }
+      aNodes[edges[edgeId].aNode >> 1].first_edge = edgeId;
+      edges[edgeId].next_in = bNodes[edges[edgeId].bNode >> 1].first_edge;
+      edges[edgeId].prev_in = -1;
+      if (bNodes[edges[edgeId].bNode >> 1].first_edge != -1) {
+        edges[bNodes[edges[edgeId].bNode >> 1].first_edge].prev_in = edgeId;
+      }
+      bNodes[edges[edgeId].bNode >> 1].first_edge = edgeId;
+      return UEdge(edgeId);
+    }
+
+    void erase(const Node& node) {
+      if (aNode(node)) {
+        int aid = node.id >> 1;
+        if (aNodes[aid].prev != -1) {
+          aNodes[aNodes[aid].prev >> 1].next = aNodes[aid].next;
+        } else {
+          first_anode = 
+            aNodes[aid].next != -1 ? aNodes[aid].next >> 1 : -1;
+        }
+        if (aNodes[aid].next != -1) {
+          aNodes[aNodes[aid].next >> 1].prev = aNodes[aid].prev;
+        }
+        aNodes[aid].next = first_free_anode;
+        first_free_anode = aid;
+      } else {
+        int bid = node.id >> 1;
+        if (bNodes[bid].prev != -1) {
+          bNodes[bNodes[bid].prev >> 1].next = bNodes[bid].next;
+        } else {
+          first_bnode = 
+            bNodes[bid].next != -1 ? bNodes[bid].next >> 1 : -1;
+        }
+        if (bNodes[bid].next != -1) {
+          bNodes[bNodes[bid].next >> 1].prev = bNodes[bid].prev;
+        }
+        bNodes[bid].next = first_free_bnode;
+        first_free_bnode = bid;
+      }
+    }
+
+    void erase(const UEdge& edge) {
+
+      if (edges[edge.id].prev_out != -1) {
+        edges[edges[edge.id].prev_out].next_out = edges[edge.id].next_out;
+      } else {
+        aNodes[edges[edge.id].aNode >> 1].first_edge = edges[edge.id].next_out;
+      }
+      if (edges[edge.id].next_out != -1) {
+        edges[edges[edge.id].next_out].prev_out = edges[edge.id].prev_out;
+      }
+
+      if (edges[edge.id].prev_in != -1) {
+        edges[edges[edge.id].prev_in].next_in = edges[edge.id].next_in;
+      } else {
+        bNodes[edges[edge.id].bNode >> 1].first_edge = edges[edge.id].next_in;
+      }
+      if (edges[edge.id].next_in != -1) {
+        edges[edges[edge.id].next_in].prev_in = edges[edge.id].prev_in;
+      }
+
+      edges[edge.id].next_out = first_free_edge;
+      first_free_edge = edge.id;
+    }
+ 
+    void clear() {
+      aNodes.clear();
+      bNodes.clear();
+      edges.clear();
+      first_anode = -1;
+      first_free_anode = -1;
+      first_bnode = -1;
+      first_free_bnode = -1;
+      first_free_edge = -1;
+    }
+
+    void changeANode(const UEdge& edge, const Node& node) {
+      LEMON_ASSERT((node.id & 1) == 0, NodeSetError());
+      if (edges[edge.id].prev_out != -1) {
+        edges[edges[edge.id].prev_out].next_out = edges[edge.id].next_out;
+      } else {
+        aNodes[edges[edge.id].aNode >> 1].first_edge = edges[edge.id].next_out;
+      }
+      if (edges[edge.id].next_out != -1) {
+        edges[edges[edge.id].next_out].prev_out = edges[edge.id].prev_out;  
+      }
+      if (aNodes[node.id >> 1].first_edge != -1) {
+        edges[aNodes[node.id >> 1].first_edge].prev_out = edge.id;
+      }
+      edges[edge.id].prev_out = -1;
+      edges[edge.id].next_out = aNodes[node.id >> 1].first_edge;
+      aNodes[node.id >> 1].first_edge = edge.id;
+      edges[edge.id].aNode = node.id;
+    } 
+
+    void changeBNode(const UEdge& edge, const Node& node) {
+      LEMON_ASSERT((node.id & 1) == 1, NodeSetError());
+      if (edges[edge.id].prev_in != -1) {
+        edges[edges[edge.id].prev_in].next_in = edges[edge.id].next_in;
+      } else {
+        bNodes[edges[edge.id].bNode >> 1].first_edge = edges[edge.id].next_in;
+      }
+      if (edges[edge.id].next_in != -1) {
+        edges[edges[edge.id].next_in].prev_in = edges[edge.id].prev_in;  
+      }
+      if (bNodes[node.id >> 1].first_edge != -1) {
+        edges[bNodes[node.id >> 1].first_edge].prev_in = edge.id;
+      }
+      edges[edge.id].prev_in = -1;
+      edges[edge.id].next_in = bNodes[node.id >> 1].first_edge;
+      bNodes[node.id >> 1].first_edge = edge.id;
+      edges[edge.id].bNode = node.id;
+    } 
+
+  };
+
+
+  typedef BpUGraphExtender<BidirBpUGraphExtender<ListBpUGraphBase> > 
+  ExtendedListBpUGraphBase;
+
+  /// \ingroup graphs
+  ///
+  /// \brief A smart bipartite undirected graph class.
+  ///
+  /// This is a bipartite undirected graph implementation.
+  /// It is conforms to the \ref concepts::BpUGraph "BpUGraph concept".
+  ///
+  ///An important extra feature of this graph implementation is that
+  ///its maps are real \ref concepts::ReferenceMap "reference map"s.
+  ///
+  /// \sa concepts::BpUGraph.
+  ///
+  class ListBpUGraph : public ExtendedListBpUGraphBase {
+    /// \brief ListBpUGraph is \e not copy constructible.
+    ///
+    ///ListBpUGraph is \e not copy constructible.
+    ListBpUGraph(const ListBpUGraph &) :ExtendedListBpUGraphBase()  {};
+    /// \brief Assignment of ListBpUGraph to another one is \e not
+    /// allowed.
+    ///
+    /// Assignment of ListBpUGraph to another one is \e not allowed.
+    void operator=(const ListBpUGraph &) {}
+  public:
+    /// \brief Constructor
+    ///    
+    /// Constructor.
+    ///
+    ListBpUGraph() {}
+
+    typedef ExtendedListBpUGraphBase Parent;
+    /// \brief Add a new ANode to the graph.
+    ///
+    /// \return the new node.
+    ///
+    Node addANode() { return Parent::addANode(); }
+
+    /// \brief Add a new BNode to the graph.
+    ///
+    /// \return the new node.
+    ///
+    Node addBNode() { return Parent::addBNode(); }
+
+    /// \brief Add a new edge to the graph.
+    ///
+    /// Add a new edge to the graph with an ANode and a BNode.
+    /// \return the new undirected edge.
+    UEdge addEdge(const Node& s, const Node& t) { 
+      return Parent::addEdge(s, t); 
+    }
+
+    /// \brief Changes the ANode of \c e to \c n
+    ///
+    /// Changes the ANode of \c e to \c n
+    ///
+    ///\note The <tt>EdgeIt</tt>s and <tt>InEdgeIt</tt>s referencing
+    ///the changed edge remain valid. However <tt>OutEdgeIt</tt>s are
+    ///invalidated.
+    void changeANode(UEdge e, Node n) { 
+      Parent::changeANode(e,n); 
+    }
+
+    /// \brief Changes the BNode of \c e to \c n
+    ///
+    /// Changes the BNode of \c e to \c n
+    ///
+    /// \note The <tt>EdgeIt</tt>s and <tt>OutEdgeIt</tt>s
+    /// referencing the changed edge remain
+    /// valid. However <tt>InEdgeIt</tt>s are invalidated.
+    void changeBNode(UEdge e, Node n) { 
+      Parent::changeBNode(e,n); 
+    }
+
+    /// \brief Changes the source(ANode) of \c e to \c n
+    ///
+    /// Changes the source(ANode) of \c e to \c n
+    ///
+    ///\note The <tt>EdgeIt</tt>s and <tt>InEdgeIt</tt>s referencing
+    ///the changed edge remain valid. However <tt>OutEdgeIt</tt>s are
+    ///invalidated.
+    void changeSource(UEdge e, Node n) { 
+      Parent::changeANode(e,n); 
+    }
+
+    /// \brief Changes the target(BNode) of \c e to \c n
+    ///
+    /// Changes the target(BNode) of \c e to \c n
+    ///
+    /// \note The <tt>EdgeIt</tt>s and <tt>OutEdgeIt</tt>s
+    /// referencing the changed edge remain
+    /// valid. However <tt>InEdgeIt</tt>s are invalidated.
+    void changeTarget(UEdge e, Node n) { 
+      Parent::changeBNode(e,n); 
+    }
+
+    /// \brief Changes the source of \c e to \c n
+    ///
+    /// Changes the source of \c e to \c n. It changes the proper
+    /// node of the represented undirected edge.
+    ///
+    ///\note The <tt>EdgeIt</tt>s and <tt>InEdgeIt</tt>s
+    ///referencing the changed edge remain
+    ///valid. However <tt>OutEdgeIt</tt>s are invalidated.
+    void changeSource(Edge e, Node n) { 
+      if (Parent::direction(e)) {
+        Parent::changeANode(e,n);
+      } else {
+        Parent::changeBNode(e,n);
+      } 
+    }
+    /// \brief Changes the target of \c e to \c n
+    ///
+    /// Changes the target of \c e to \c n. It changes the proper
+    /// node of the represented undirected edge.
+    ///
+    ///\note The <tt>EdgeIt</tt>s and <tt>OutEdgeIt</tt>s
+    ///referencing the changed edge remain
+    ///valid. However <tt>InEdgeIt</tt>s are invalidated.
+    void changeTarget(Edge e, Node n) { 
+      if (Parent::direction(e)) {
+        Parent::changeBNode(e,n);
+      } else {
+        Parent::changeANode(e,n);
+      } 
+    }
+    /// \brief Contract two nodes.
+    ///
+    /// This function contracts two nodes.
+    ///
+    /// Node \p b will be removed but instead of deleting its
+    /// neighboring edges, they will be joined to \p a.  The two nodes
+    /// should be from the same nodeset, of course.
+    ///
+    /// \note The <tt>EdgeIt</tt>s referencing a moved edge remain
+    /// valid.
+    void contract(const Node& a, const Node& b) {
+      LEMON_ASSERT(Parent::aNode(a) == Parent::aNode(b), NodeSetError());
+      if (Parent::aNode(a)) {
+        for (IncEdgeIt e(*this, b); e!=INVALID;) {
+          IncEdgeIt f = e; ++f;
+          changeSource(e, a);
+          e = f;
+        }
+      } else {
+        for (IncEdgeIt e(*this, b); e!=INVALID;) {
+          IncEdgeIt f = e; ++f;
+          changeTarget(e, a);
+          e = f;
+        }
+      }
+      erase(b);
+    }
+
+    /// \brief Class to make a snapshot of the graph and restore
+    /// to it later.
+    ///
+    /// Class to make a snapshot of the graph and to restore it
+    /// later.
+    ///
+    /// The newly added nodes and undirected edges can be removed
+    /// using the restore() function.
+    ///
+    /// \warning Edge and node deletions cannot be restored. This
+    /// events invalidate the snapshot. 
+    class Snapshot {
+    protected:
+
+      typedef Parent::NodeNotifier NodeNotifier;
+
+      class NodeObserverProxy : public NodeNotifier::ObserverBase {
+      public:
+
+        NodeObserverProxy(Snapshot& _snapshot)
+          : snapshot(_snapshot) {}
+
+        using NodeNotifier::ObserverBase::attach;
+        using NodeNotifier::ObserverBase::detach;
+        using NodeNotifier::ObserverBase::attached;
+        
+      protected:
+        
+        virtual void add(const Node& node) {
+          snapshot.addNode(node);
+        }
+        virtual void add(const std::vector<Node>& nodes) {
+          for (int i = nodes.size() - 1; i >= 0; ++i) {
+            snapshot.addNode(nodes[i]);
+          }
+        }
+        virtual void erase(const Node& node) {
+          snapshot.eraseNode(node);
+        }
+        virtual void erase(const std::vector<Node>& nodes) {
+          for (int i = 0; i < int(nodes.size()); ++i) {
+            snapshot.eraseNode(nodes[i]);
+          }
+        }
+        virtual void build() {
+          Node node;
+          std::vector<Node> nodes;
+          for (notifier()->first(node); node != INVALID; 
+               notifier()->next(node)) {
+            nodes.push_back(node);
+          }
+          for (int i = nodes.size() - 1; i >= 0; --i) {
+            snapshot.addNode(nodes[i]);
+          }
+        }
+        virtual void clear() {
+          Node node;
+          for (notifier()->first(node); node != INVALID; 
+               notifier()->next(node)) {
+            snapshot.eraseNode(node);
+          }
+        }
+
+        Snapshot& snapshot;
+      };
+
+      class UEdgeObserverProxy : public UEdgeNotifier::ObserverBase {
+      public:
+
+        UEdgeObserverProxy(Snapshot& _snapshot)
+          : snapshot(_snapshot) {}
+
+        using UEdgeNotifier::ObserverBase::attach;
+        using UEdgeNotifier::ObserverBase::detach;
+        using UEdgeNotifier::ObserverBase::attached;
+        
+      protected:
+
+        virtual void add(const UEdge& edge) {
+          snapshot.addUEdge(edge);
+        }
+        virtual void add(const std::vector<UEdge>& edges) {
+          for (int i = edges.size() - 1; i >= 0; ++i) {
+            snapshot.addUEdge(edges[i]);
+          }
+        }
+        virtual void erase(const UEdge& edge) {
+          snapshot.eraseUEdge(edge);
+        }
+        virtual void erase(const std::vector<UEdge>& edges) {
+          for (int i = 0; i < int(edges.size()); ++i) {
+            snapshot.eraseUEdge(edges[i]);
+          }
+        }
+        virtual void build() {
+          UEdge edge;
+          std::vector<UEdge> edges;
+          for (notifier()->first(edge); edge != INVALID; 
+               notifier()->next(edge)) {
+            edges.push_back(edge);
+          }
+          for (int i = edges.size() - 1; i >= 0; --i) {
+            snapshot.addUEdge(edges[i]);
+          }
+        }
+        virtual void clear() {
+          UEdge edge;
+          for (notifier()->first(edge); edge != INVALID; 
+               notifier()->next(edge)) {
+            snapshot.eraseUEdge(edge);
+          }
+        }
+
+        Snapshot& snapshot;
+      };
+      
+      ListBpUGraph *graph;
+
+      NodeObserverProxy node_observer_proxy;
+      UEdgeObserverProxy edge_observer_proxy;
+
+      std::list<Node> added_nodes;
+      std::list<UEdge> added_edges;
+
+
+      void addNode(const Node& node) {
+        added_nodes.push_front(node);        
+      }
+      void eraseNode(const Node& node) {
+        std::list<Node>::iterator it = 
+          std::find(added_nodes.begin(), added_nodes.end(), node);
+        if (it == added_nodes.end()) {
+          clear();
+          edge_observer_proxy.detach();
+          throw NodeNotifier::ImmediateDetach();
+        } else {
+          added_nodes.erase(it);
+        }
+      }
+
+      void addUEdge(const UEdge& edge) {
+        added_edges.push_front(edge);        
+      }
+      void eraseUEdge(const UEdge& edge) {
+        std::list<UEdge>::iterator it = 
+          std::find(added_edges.begin(), added_edges.end(), edge);
+        if (it == added_edges.end()) {
+          clear();
+          node_observer_proxy.detach();
+          throw UEdgeNotifier::ImmediateDetach();
+        } else {
+          added_edges.erase(it);
+        }        
+      }
+
+      void attach(ListBpUGraph &_graph) {
+	graph = &_graph;
+	node_observer_proxy.attach(graph->notifier(Node()));
+        edge_observer_proxy.attach(graph->notifier(UEdge()));
+      }
+            
+      void detach() {
+	node_observer_proxy.detach();
+	edge_observer_proxy.detach();
+      }
+
+      bool attached() const {
+        return node_observer_proxy.attached();
+      }
+
+      void clear() {
+        added_nodes.clear();
+        added_edges.clear();        
+      }
+
+    public:
+
+      /// \brief Default constructor.
+      ///
+      /// Default constructor.
+      /// To actually make a snapshot you must call save().
+      Snapshot() 
+        : graph(0), node_observer_proxy(*this), 
+          edge_observer_proxy(*this) {}
+      
+      /// \brief Constructor that immediately makes a snapshot.
+      ///      
+      /// This constructor immediately makes a snapshot of the graph.
+      /// \param _graph The graph we make a snapshot of.
+      Snapshot(ListBpUGraph &_graph) 
+        : node_observer_proxy(*this), 
+          edge_observer_proxy(*this) {
+	attach(_graph);
+      }
+      
+      /// \brief Make a snapshot.
+      ///
+      /// Make a snapshot of the graph.
+      ///
+      /// This function can be called more than once. In case of a repeated
+      /// call, the previous snapshot gets lost.
+      /// \param _graph The graph we make the snapshot of.
+      void save(ListBpUGraph &_graph) {
+        if (attached()) {
+          detach();
+          clear();
+        }
+        attach(_graph);
+      }
+      
+      /// \brief Undo the changes until the last snapshot.
+      // 
+      /// Undo the changes until the last snapshot created by save().
+      void restore() {
+	detach();
+	for(std::list<UEdge>::iterator it = added_edges.begin(); 
+            it != added_edges.end(); ++it) {
+	  graph->erase(*it);
+	}
+	for(std::list<Node>::iterator it = added_nodes.begin(); 
+            it != added_nodes.end(); ++it) {
+	  graph->erase(*it);
+	}
+        clear();
+      }
+
+      /// \brief Gives back true when the snapshot is valid.
+      ///
+      /// Gives back true when the snapshot is valid.
+      bool valid() const {
+        return attached();
+      }
+    };
+  };
+
+  
+  /// @}  
+} //namespace lemon
+  
+
+#endif
Index: lemon/lp.h
===================================================================
--- lemon/lp.h	(revision 2553)
+++ lemon/lp.h	(revision 2553)
@@ -0,0 +1,90 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_LP_H
+#define LEMON_LP_H
+
+#include<lemon/config.h>
+
+
+#ifdef HAVE_GLPK
+#include <lemon/lp_glpk.h>
+#include <lemon/mip_glpk.h>
+#elif HAVE_CPLEX
+#include <lemon/lp_cplex.h>
+#include <lemon/mip_cplex.h>
+#elif HAVE_SOPLEX
+#include <lemon/lp_soplex.h>
+#endif
+
+///\file
+///\brief Defines a default LP solver
+///\ingroup lp_group
+namespace lemon {
+
+#ifdef DOXYGEN
+  ///The default LP solver identifier
+
+  ///The default LP solver identifier.
+  ///\ingroup lp_group
+  ///
+  ///Currently, the possible values are \c GLPK or \c CPLEX
+#define DEFAULT_LP SOLVER
+  ///The default LP solver
+
+  ///The default LP solver.
+  ///\ingroup lp_group
+  ///
+  ///Currently, it is either \c LpGlpk or \c LpCplex
+  typedef LpGlpk Lp;
+  ///The default LP solver identifier string
+
+  ///The default LP solver identifier string.
+  ///\ingroup lp_group
+  ///
+  ///Currently, the possible values are "GLPK" or "CPLEX"
+  const char default_solver_name[]="SOLVER";  
+
+  ///The default ILP solver.
+
+  ///The default ILP solver.
+  ///\ingroup lp_group
+  ///
+  ///Currently, it is either \c LpGlpk or \c LpCplex
+  typedef MipGlpk Mip;
+#else
+#ifdef HAVE_GLPK
+#define DEFAULT_LP GLPK
+  typedef LpGlpk Lp;
+  typedef MipGlpk Mip;
+  const char default_solver_name[]="GLPK";
+#elif HAVE_CPLEX
+#define DEFAULT_LP CPLEX
+  typedef LpCplex Lp;
+  typedef MipCplex Mip;
+  const char default_solver_name[]="CPLEX";
+#elif HAVE_SOPLEX
+#define DEFAULT_LP SOPLEX
+  typedef LpSoplex Lp;
+  const char default_solver_name[]="SOPLEX";
+#endif
+#endif
+ 
+} //namespace lemon
+
+#endif //LEMON_LP_H
Index: lemon/lp_base.cc
===================================================================
--- lemon/lp_base.cc	(revision 2553)
+++ lemon/lp_base.cc	(revision 2553)
@@ -0,0 +1,35 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\file
+///\brief The implementation of the LP solver interface.
+
+#include <lemon/lp_base.h>
+namespace lemon {
+  
+  const LpSolverBase::Value
+  LpSolverBase::INF = std::numeric_limits<Value>::infinity();
+  const LpSolverBase::Value
+  LpSolverBase::NaN = std::numeric_limits<Value>::quiet_NaN();
+
+//   const LpSolverBase::Constr::Value
+//   LpSolverBase::Constr::INF = std::numeric_limits<Value>::infinity();
+//   const LpSolverBase::Constr::Value
+//   LpSolverBase::Constr::NaN = std::numeric_limits<Value>::quiet_NaN();
+  
+} //namespace lemon
Index: lemon/lp_base.h
===================================================================
--- lemon/lp_base.h	(revision 2618)
+++ lemon/lp_base.h	(revision 2618)
@@ -0,0 +1,1711 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_LP_BASE_H
+#define LEMON_LP_BASE_H
+
+#include<iostream>
+#include<vector>
+#include<map>
+#include<limits>
+#include<lemon/math.h>
+
+#include<lemon/error.h>
+#include<lemon/bits/invalid.h>
+#include<lemon/bits/utility.h>
+#include<lemon/bits/lp_id.h>
+
+///\file
+///\brief The interface of the LP solver interface.
+///\ingroup lp_group
+namespace lemon {
+
+  /// Function to decide whether a floating point value is finite or not.
+
+  /// Retruns true if the argument is not infinity, minus infinity or NaN.
+  /// It does the same as the isfinite() function defined by C99.
+  template <typename T>
+  bool isFinite(T value)
+  {
+    typedef std::numeric_limits<T> Lim;
+    if ((Lim::has_infinity && (value == Lim::infinity() || value ==
+			       -Lim::infinity())) ||
+        ((Lim::has_quiet_NaN || Lim::has_signaling_NaN) && value != value))
+    {
+      return false;
+    }
+    return true;
+  }
+
+  ///Common base class for LP solvers
+  
+  ///\todo Much more docs
+  ///\ingroup lp_group
+  class LpSolverBase {
+
+  protected:
+
+    _lp_bits::LpId rows;
+    _lp_bits::LpId cols;
+    
+  public:
+    
+    ///Possible outcomes of an LP solving procedure
+    enum SolveExitStatus {
+      ///This means that the problem has been successfully solved: either
+      ///an optimal solution has been found or infeasibility/unboundedness
+      ///has been proved.
+      SOLVED = 0,
+      ///Any other case (including the case when some user specified
+      ///limit has been exceeded)
+      UNSOLVED = 1
+    };
+      
+      ///\e
+    enum SolutionStatus {
+      ///Feasible solution hasn't been found (but may exist).
+
+      ///\todo NOTFOUND might be a better name.
+      ///
+      UNDEFINED = 0,
+      ///The problem has no feasible solution
+      INFEASIBLE = 1,
+      ///Feasible solution found
+      FEASIBLE = 2,
+      ///Optimal solution exists and found
+      OPTIMAL = 3,
+      ///The cost function is unbounded
+
+      ///\todo Give a feasible solution and an infinite ray (and the
+      ///corresponding bases)
+      INFINITE = 4
+    };
+
+    ///\e The type of the investigated LP problem
+    enum ProblemTypes {
+      ///Primal-dual feasible
+      PRIMAL_DUAL_FEASIBLE = 0,
+      ///Primal feasible dual infeasible
+      PRIMAL_FEASIBLE_DUAL_INFEASIBLE = 1,
+      ///Primal infeasible dual feasible
+      PRIMAL_INFEASIBLE_DUAL_FEASIBLE = 2,
+      ///Primal-dual infeasible
+      PRIMAL_DUAL_INFEASIBLE = 3,
+      ///Could not determine so far
+      UNKNOWN = 4
+    };
+
+    ///The floating point type used by the solver
+    typedef double Value;
+    ///The infinity constant
+    static const Value INF;
+    ///The not a number constant
+    static const Value NaN;
+
+    static inline bool isNaN(const Value& v) { return v!=v; }
+    
+    friend class Col;
+    friend class ColIt;
+    friend class Row;
+    
+    ///Refer to a column of the LP.
+
+    ///This type is used to refer to a column of the LP.
+    ///
+    ///Its value remains valid and correct even after the addition or erase of
+    ///other columns.
+    ///
+    ///\todo Document what can one do with a Col (INVALID, comparing,
+    ///it is similar to Node/Edge)
+    class Col {
+    protected:
+      int id;
+      friend class LpSolverBase;
+      friend class MipSolverBase;
+      explicit Col(int _id) : id(_id) {}
+    public:
+      typedef Value ExprValue;
+      typedef True LpSolverCol;
+      Col() {}
+      Col(const Invalid&) : id(-1) {}
+      bool operator< (Col c) const  {return id< c.id;}
+      bool operator> (Col c) const  {return id> c.id;}
+      bool operator==(Col c) const  {return id==c.id;}
+      bool operator!=(Col c) const  {return id!=c.id;}
+    };
+
+    class ColIt : public Col {
+      const LpSolverBase *_lp;
+    public:
+      ColIt() {}
+      ColIt(const LpSolverBase &lp) : _lp(&lp)
+      {
+        _lp->cols.firstFix(id);
+      }
+      ColIt(const Invalid&) : Col(INVALID) {}
+      ColIt &operator++() 
+      {
+        _lp->cols.nextFix(id);
+	return *this;
+      }
+    };
+
+    static int id(const Col& col) { return col.id; }
+ 
+      
+    ///Refer to a row of the LP.
+
+    ///This type is used to refer to a row of the LP.
+    ///
+    ///Its value remains valid and correct even after the addition or erase of
+    ///other rows.
+    ///
+    ///\todo Document what can one do with a Row (INVALID, comparing,
+    ///it is similar to Node/Edge)
+    class Row {
+    protected:
+      int id;
+      friend class LpSolverBase;
+      explicit Row(int _id) : id(_id) {}
+    public:
+      typedef Value ExprValue;
+      typedef True LpSolverRow;
+      Row() {}
+      Row(const Invalid&) : id(-1) {}
+
+      bool operator< (Row c) const  {return id< c.id;}
+      bool operator> (Row c) const  {return id> c.id;}
+      bool operator==(Row c) const  {return id==c.id;}
+      bool operator!=(Row c) const  {return id!=c.id;} 
+    };
+
+    class RowIt : public Row {
+      const LpSolverBase *_lp;
+    public:
+      RowIt() {}
+      RowIt(const LpSolverBase &lp) : _lp(&lp)
+      {
+        _lp->rows.firstFix(id);
+      }
+      RowIt(const Invalid&) : Row(INVALID) {}
+      RowIt &operator++() 
+      {
+        _lp->rows.nextFix(id);
+	return *this;
+      }
+    };
+
+    static int id(const Row& row) { return row.id; }
+
+  protected:
+
+    int _lpId(const Col& c) const {
+      return cols.floatingId(id(c));
+    }
+
+    int _lpId(const Row& r) const {
+      return rows.floatingId(id(r));
+    }
+
+    Col _item(int i, Col) const {
+      return Col(cols.fixId(i));
+    }
+
+    Row _item(int i, Row) const {
+      return Row(rows.fixId(i));
+    }
+
+
+  public:
+    
+    ///Linear expression of variables and a constant component
+    
+    ///This data structure stores a linear expression of the variables
+    ///(\ref Col "Col"s) and also has a constant component.
+    ///
+    ///There are several ways to access and modify the contents of this
+    ///container.
+    ///- Its it fully compatible with \c std::map<Col,double>, so for expamle
+    ///if \c e is an Expr and \c v and \c w are of type \ref Col, then you can
+    ///read and modify the coefficients like
+    ///these.
+    ///\code
+    ///e[v]=5;
+    ///e[v]+=12;
+    ///e.erase(v);
+    ///\endcode
+    ///or you can also iterate through its elements.
+    ///\code
+    ///double s=0;
+    ///for(LpSolverBase::Expr::iterator i=e.begin();i!=e.end();++i)
+    ///  s+=i->second;
+    ///\endcode
+    ///(This code computes the sum of all coefficients).
+    ///- Numbers (<tt>double</tt>'s)
+    ///and variables (\ref Col "Col"s) directly convert to an
+    ///\ref Expr and the usual linear operations are defined, so  
+    ///\code
+    ///v+w
+    ///2*v-3.12*(v-w/2)+2
+    ///v*2.1+(3*v+(v*12+w+6)*3)/2
+    ///\endcode
+    ///are valid \ref Expr "Expr"essions.
+    ///The usual assignment operations are also defined.
+    ///\code
+    ///e=v+w;
+    ///e+=2*v-3.12*(v-w/2)+2;
+    ///e*=3.4;
+    ///e/=5;
+    ///\endcode
+    ///- The constant member can be set and read by \ref constComp()
+    ///\code
+    ///e.constComp()=12;
+    ///double c=e.constComp();
+    ///\endcode
+    ///
+    ///\note \ref clear() not only sets all coefficients to 0 but also
+    ///clears the constant components.
+    ///
+    ///\sa Constr
+    ///
+    class Expr : public std::map<Col,Value>
+    {
+    public:
+      typedef LpSolverBase::Col Key; 
+      typedef LpSolverBase::Value Value;
+      
+    protected:
+      typedef std::map<Col,Value> Base;
+      
+      Value const_comp;
+    public:
+      typedef True IsLinExpression;
+      ///\e
+      Expr() : Base(), const_comp(0) { }
+      ///\e
+      Expr(const Key &v) : const_comp(0) {
+	Base::insert(std::make_pair(v, 1));
+      }
+      ///\e
+      Expr(const Value &v) : const_comp(v) {}
+      ///\e
+      void set(const Key &v,const Value &c) {
+	Base::insert(std::make_pair(v, c));
+      }
+      ///\e
+      Value &constComp() { return const_comp; }
+      ///\e
+      const Value &constComp() const { return const_comp; }
+      
+      ///Removes the components with zero coefficient.
+      void simplify() {
+	for (Base::iterator i=Base::begin(); i!=Base::end();) {
+	  Base::iterator j=i;
+	  ++j;
+	  if ((*i).second==0) Base::erase(i);
+	  i=j;
+	}
+      }
+
+      void simplify() const {
+        const_cast<Expr*>(this)->simplify();
+      }
+
+      ///Removes the coefficients closer to zero than \c tolerance.
+      void simplify(double &tolerance) {
+	for (Base::iterator i=Base::begin(); i!=Base::end();) {
+	  Base::iterator j=i;
+	  ++j;
+	  if (std::fabs((*i).second)<tolerance) Base::erase(i);
+	  i=j;
+	}
+      }
+
+      ///Sets all coefficients and the constant component to 0.
+      void clear() {
+	Base::clear();
+	const_comp=0;
+      }
+
+      ///\e
+      Expr &operator+=(const Expr &e) {
+	for (Base::const_iterator j=e.begin(); j!=e.end(); ++j)
+	  (*this)[j->first]+=j->second;
+	const_comp+=e.const_comp;
+	return *this;
+      }
+      ///\e
+      Expr &operator-=(const Expr &e) {
+	for (Base::const_iterator j=e.begin(); j!=e.end(); ++j)
+	  (*this)[j->first]-=j->second;
+	const_comp-=e.const_comp;
+	return *this;
+      }
+      ///\e
+      Expr &operator*=(const Value &c) {
+	for (Base::iterator j=Base::begin(); j!=Base::end(); ++j)
+	  j->second*=c;
+	const_comp*=c;
+	return *this;
+      }
+      ///\e
+      Expr &operator/=(const Value &c) {
+	for (Base::iterator j=Base::begin(); j!=Base::end(); ++j)
+	  j->second/=c;
+	const_comp/=c;
+	return *this;
+      }
+
+    };
+    
+    ///Linear constraint
+
+    ///This data stucture represents a linear constraint in the LP.
+    ///Basically it is a linear expression with a lower or an upper bound
+    ///(or both). These parts of the constraint can be obtained by the member
+    ///functions \ref expr(), \ref lowerBound() and \ref upperBound(),
+    ///respectively.
+    ///There are two ways to construct a constraint.
+    ///- You can set the linear expression and the bounds directly
+    ///  by the functions above.
+    ///- The operators <tt>\<=</tt>, <tt>==</tt> and  <tt>\>=</tt>
+    ///  are defined between expressions, or even between constraints whenever
+    ///  it makes sense. Therefore if \c e and \c f are linear expressions and
+    ///  \c s and \c t are numbers, then the followings are valid expressions
+    ///  and thus they can be used directly e.g. in \ref addRow() whenever
+    ///  it makes sense.
+    ///\code
+    ///  e<=s
+    ///  e<=f
+    ///  e==f
+    ///  s<=e<=t
+    ///  e>=t
+    ///\endcode
+    ///\warning The validity of a constraint is checked only at run time, so
+    ///e.g. \ref addRow(<tt>x[1]\<=x[2]<=5</tt>) will compile, but will throw a
+    ///\ref LogicError exception.
+    class Constr
+    {
+    public:
+      typedef LpSolverBase::Expr Expr;
+      typedef Expr::Key Key;
+      typedef Expr::Value Value;
+      
+    protected:
+      Expr _expr;
+      Value _lb,_ub;
+    public:
+      ///\e
+      Constr() : _expr(), _lb(NaN), _ub(NaN) {}
+      ///\e
+      Constr(Value lb,const Expr &e,Value ub) :
+	_expr(e), _lb(lb), _ub(ub) {}
+      ///\e
+      Constr(const Expr &e,Value ub) : 
+	_expr(e), _lb(NaN), _ub(ub) {}
+      ///\e
+      Constr(Value lb,const Expr &e) :
+	_expr(e), _lb(lb), _ub(NaN) {}
+      ///\e
+      Constr(const Expr &e) : 
+	_expr(e), _lb(NaN), _ub(NaN) {}
+      ///\e
+      void clear() 
+      {
+	_expr.clear();
+	_lb=_ub=NaN;
+      }
+
+      ///Reference to the linear expression 
+      Expr &expr() { return _expr; }
+      ///Cont reference to the linear expression 
+      const Expr &expr() const { return _expr; }
+      ///Reference to the lower bound.
+
+      ///\return
+      ///- \ref INF "INF": the constraint is lower unbounded.
+      ///- \ref NaN "NaN": lower bound has not been set.
+      ///- finite number: the lower bound
+      Value &lowerBound() { return _lb; }
+      ///The const version of \ref lowerBound()
+      const Value &lowerBound() const { return _lb; }
+      ///Reference to the upper bound.
+
+      ///\return
+      ///- \ref INF "INF": the constraint is upper unbounded.
+      ///- \ref NaN "NaN": upper bound has not been set.
+      ///- finite number: the upper bound
+      Value &upperBound() { return _ub; }
+      ///The const version of \ref upperBound()
+      const Value &upperBound() const { return _ub; }
+      ///Is the constraint lower bounded?
+      bool lowerBounded() const { 
+	return isFinite(_lb);
+      }
+      ///Is the constraint upper bounded?
+      bool upperBounded() const {
+	return isFinite(_ub);
+      }
+
+    };
+    
+    ///Linear expression of rows
+    
+    ///This data structure represents a column of the matrix,
+    ///thas is it strores a linear expression of the dual variables
+    ///(\ref Row "Row"s).
+    ///
+    ///There are several ways to access and modify the contents of this
+    ///container.
+    ///- Its it fully compatible with \c std::map<Row,double>, so for expamle
+    ///if \c e is an DualExpr and \c v
+    ///and \c w are of type \ref Row, then you can
+    ///read and modify the coefficients like
+    ///these.
+    ///\code
+    ///e[v]=5;
+    ///e[v]+=12;
+    ///e.erase(v);
+    ///\endcode
+    ///or you can also iterate through its elements.
+    ///\code
+    ///double s=0;
+    ///for(LpSolverBase::DualExpr::iterator i=e.begin();i!=e.end();++i)
+    ///  s+=i->second;
+    ///\endcode
+    ///(This code computes the sum of all coefficients).
+    ///- Numbers (<tt>double</tt>'s)
+    ///and variables (\ref Row "Row"s) directly convert to an
+    ///\ref DualExpr and the usual linear operations are defined, so
+    ///\code
+    ///v+w
+    ///2*v-3.12*(v-w/2)
+    ///v*2.1+(3*v+(v*12+w)*3)/2
+    ///\endcode
+    ///are valid \ref DualExpr "DualExpr"essions.
+    ///The usual assignment operations are also defined.
+    ///\code
+    ///e=v+w;
+    ///e+=2*v-3.12*(v-w/2);
+    ///e*=3.4;
+    ///e/=5;
+    ///\endcode
+    ///
+    ///\sa Expr
+    ///
+    class DualExpr : public std::map<Row,Value>
+    {
+    public:
+      typedef LpSolverBase::Row Key; 
+      typedef LpSolverBase::Value Value;
+      
+    protected:
+      typedef std::map<Row,Value> Base;
+      
+    public:
+      typedef True IsLinExpression;
+      ///\e
+      DualExpr() : Base() { }
+      ///\e
+      DualExpr(const Key &v) {
+	Base::insert(std::make_pair(v, 1));
+      }
+      ///\e
+      void set(const Key &v,const Value &c) {
+	Base::insert(std::make_pair(v, c));
+      }
+      
+      ///Removes the components with zero coefficient.
+      void simplify() {
+	for (Base::iterator i=Base::begin(); i!=Base::end();) {
+	  Base::iterator j=i;
+	  ++j;
+	  if ((*i).second==0) Base::erase(i);
+	  i=j;
+	}
+      }
+
+      void simplify() const {
+        const_cast<DualExpr*>(this)->simplify();
+      }
+
+      ///Removes the coefficients closer to zero than \c tolerance.
+      void simplify(double &tolerance) {
+	for (Base::iterator i=Base::begin(); i!=Base::end();) {
+	  Base::iterator j=i;
+	  ++j;
+	  if (std::fabs((*i).second)<tolerance) Base::erase(i);
+	  i=j;
+	}
+      }
+
+      ///Sets all coefficients to 0.
+      void clear() {
+	Base::clear();
+      }
+
+      ///\e
+      DualExpr &operator+=(const DualExpr &e) {
+	for (Base::const_iterator j=e.begin(); j!=e.end(); ++j)
+	  (*this)[j->first]+=j->second;
+	return *this;
+      }
+      ///\e
+      DualExpr &operator-=(const DualExpr &e) {
+	for (Base::const_iterator j=e.begin(); j!=e.end(); ++j)
+	  (*this)[j->first]-=j->second;
+	return *this;
+      }
+      ///\e
+      DualExpr &operator*=(const Value &c) {
+	for (Base::iterator j=Base::begin(); j!=Base::end(); ++j)
+	  j->second*=c;
+	return *this;
+      }
+      ///\e
+      DualExpr &operator/=(const Value &c) {
+	for (Base::iterator j=Base::begin(); j!=Base::end(); ++j)
+	  j->second/=c;
+	return *this;
+      }
+    };
+    
+
+  private:
+
+    template <typename _Expr>
+    class MappedOutputIterator {
+    public:
+
+      typedef std::insert_iterator<_Expr> Base;
+
+      typedef std::output_iterator_tag iterator_category;
+      typedef void difference_type;
+      typedef void value_type;
+      typedef void reference;
+      typedef void pointer;
+      
+      MappedOutputIterator(const Base& _base, const LpSolverBase& _lp) 
+        : base(_base), lp(_lp) {}
+
+      MappedOutputIterator& operator*() {
+        return *this;
+      }
+
+      MappedOutputIterator& operator=(const std::pair<int, Value>& value) {
+        *base = std::make_pair(lp._item(value.first, typename _Expr::Key()), 
+                               value.second);
+        return *this;
+      }
+
+      MappedOutputIterator& operator++() {
+        ++base;
+        return *this;
+      }
+
+      MappedOutputIterator operator++(int) {
+        MappedOutputIterator tmp(*this);
+        ++base;
+        return tmp;
+      }
+
+      bool operator==(const MappedOutputIterator& it) const {
+        return base == it.base;
+      }
+
+      bool operator!=(const MappedOutputIterator& it) const {
+        return base != it.base;
+      }
+
+    private:
+      Base base;
+      const LpSolverBase& lp;
+    };
+
+    template <typename Expr>
+    class MappedInputIterator {
+    public:
+
+      typedef typename Expr::const_iterator Base;
+
+      typedef typename Base::iterator_category iterator_category;
+      typedef typename Base::difference_type difference_type;
+      typedef const std::pair<int, Value> value_type;
+      typedef value_type reference;
+      class pointer {
+      public:
+        pointer(value_type& _value) : value(_value) {}
+        value_type* operator->() { return &value; }
+      private:
+        value_type value;
+      };
+
+      MappedInputIterator(const Base& _base, const LpSolverBase& _lp) 
+        : base(_base), lp(_lp) {}
+
+      reference operator*() {
+        return std::make_pair(lp._lpId(base->first), base->second);
+      }
+
+      pointer operator->() {
+        return pointer(operator*());
+      }
+
+      MappedInputIterator& operator++() {
+        ++base;
+        return *this;
+      }
+
+      MappedInputIterator operator++(int) {
+        MappedInputIterator tmp(*this);
+        ++base;
+        return tmp;
+      }
+
+      bool operator==(const MappedInputIterator& it) const {
+        return base == it.base;
+      }
+
+      bool operator!=(const MappedInputIterator& it) const {
+        return base != it.base;
+      }
+
+    private:
+      Base base;
+      const LpSolverBase& lp;
+    };
+
+  protected:
+
+    /// STL compatible iterator for lp col
+    typedef MappedInputIterator<Expr> ConstRowIterator;
+    /// STL compatible iterator for lp row
+    typedef MappedInputIterator<DualExpr> ConstColIterator;
+
+    /// STL compatible iterator for lp col
+    typedef MappedOutputIterator<Expr> RowIterator;
+    /// STL compatible iterator for lp row
+    typedef MappedOutputIterator<DualExpr> ColIterator;
+
+    //Abstract virtual functions
+    virtual LpSolverBase* _newLp() = 0;
+    virtual LpSolverBase* _copyLp(){
+      LpSolverBase* newlp = _newLp();
+
+      std::map<Col, Col> ref;
+      for (LpSolverBase::ColIt it(*this); it != INVALID; ++it) {
+	Col ccol = newlp->addCol();
+	ref[it] = ccol;
+	newlp->colName(ccol, colName(it));
+	newlp->colLowerBound(ccol, colLowerBound(it));
+	newlp->colUpperBound(ccol, colUpperBound(it));
+      }
+
+      for (LpSolverBase::RowIt it(*this); it != INVALID; ++it) {
+	Expr e = row(it), ce;
+	for (Expr::iterator jt = e.begin(); jt != e.end(); ++jt) {
+	  ce[ref[jt->first]] = jt->second;
+	}
+	ce += e.constComp();
+	Row r = newlp->addRow(ce);
+
+        double lower, upper;
+        getRowBounds(it, lower, upper);
+	newlp->rowBounds(r, lower, upper);
+      }
+
+      return newlp;
+    };
+
+    virtual int _addCol() = 0;
+    virtual int _addRow() = 0; 
+
+    virtual void _eraseCol(int col) = 0;
+    virtual void _eraseRow(int row) = 0;
+
+    virtual void _getColName(int col, std::string & name) const = 0;
+    virtual void _setColName(int col, const std::string & name) = 0;
+    virtual int _colByName(const std::string& name) const = 0;
+
+    virtual void _setRowCoeffs(int i, ConstRowIterator b, 
+                               ConstRowIterator e) = 0;
+    virtual void _getRowCoeffs(int i, RowIterator b) const = 0;
+    virtual void _setColCoeffs(int i, ConstColIterator b, 
+                               ConstColIterator e) = 0;
+    virtual void _getColCoeffs(int i, ColIterator b) const = 0;
+    virtual void _setCoeff(int row, int col, Value value) = 0;
+    virtual Value _getCoeff(int row, int col) const = 0;
+    virtual void _setColLowerBound(int i, Value value) = 0;
+    virtual Value _getColLowerBound(int i) const = 0;
+    virtual void _setColUpperBound(int i, Value value) = 0;
+    virtual Value _getColUpperBound(int i) const = 0;
+    virtual void _setRowBounds(int i, Value lower, Value upper) = 0;
+    virtual void _getRowBounds(int i, Value &lower, Value &upper) const = 0;
+
+    virtual void _setObjCoeff(int i, Value obj_coef) = 0;
+    virtual Value _getObjCoeff(int i) const = 0;
+    virtual void _clearObj()=0;
+
+    virtual SolveExitStatus _solve() = 0;
+    virtual Value _getPrimal(int i) const = 0;
+    virtual Value _getDual(int i) const = 0;
+    virtual Value _getPrimalValue() const = 0;
+    virtual bool _isBasicCol(int i) const = 0;
+    virtual SolutionStatus _getPrimalStatus() const = 0;
+    virtual SolutionStatus _getDualStatus() const = 0;
+    virtual ProblemTypes _getProblemType() const = 0;
+
+    virtual void _setMax() = 0;
+    virtual void _setMin() = 0;
+    
+
+    virtual bool _isMax() const = 0;
+
+    //Own protected stuff
+    
+    //Constant component of the objective function
+    Value obj_const_comp;
+        
+  public:
+
+    ///\e
+    LpSolverBase() : obj_const_comp(0) {}
+
+    ///\e
+    virtual ~LpSolverBase() {}
+
+    ///Creates a new LP problem
+    LpSolverBase* newLp() {return _newLp();}
+    ///Makes a copy of the LP problem
+    LpSolverBase* copyLp() {return _copyLp();}
+    
+    ///\name Build up and modify the LP
+
+    ///@{
+
+    ///Add a new empty column (i.e a new variable) to the LP
+    Col addCol() { Col c; _addCol(); c.id = cols.addId(); return c;}
+
+    ///\brief Adds several new columns
+    ///(i.e a variables) at once
+    ///
+    ///This magic function takes a container as its argument
+    ///and fills its elements
+    ///with new columns (i.e. variables)
+    ///\param t can be
+    ///- a standard STL compatible iterable container with
+    ///\ref Col as its \c values_type
+    ///like
+    ///\code
+    ///std::vector<LpSolverBase::Col>
+    ///std::list<LpSolverBase::Col>
+    ///\endcode
+    ///- a standard STL compatible iterable container with
+    ///\ref Col as its \c mapped_type
+    ///like
+    ///\code
+    ///std::map<AnyType,LpSolverBase::Col>
+    ///\endcode
+    ///- an iterable lemon \ref concepts::WriteMap "write map" like 
+    ///\code
+    ///ListGraph::NodeMap<LpSolverBase::Col>
+    ///ListGraph::EdgeMap<LpSolverBase::Col>
+    ///\endcode
+    ///\return The number of the created column.
+#ifdef DOXYGEN
+    template<class T>
+    int addColSet(T &t) { return 0;} 
+#else
+    template<class T>
+    typename enable_if<typename T::value_type::LpSolverCol,int>::type
+    addColSet(T &t,dummy<0> = 0) {
+      int s=0;
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {*i=addCol();s++;}
+      return s;
+    }
+    template<class T>
+    typename enable_if<typename T::value_type::second_type::LpSolverCol,
+		       int>::type
+    addColSet(T &t,dummy<1> = 1) { 
+      int s=0;
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {
+	i->second=addCol();
+	s++;
+      }
+      return s;
+    }
+    template<class T>
+    typename enable_if<typename T::MapIt::Value::LpSolverCol,
+		       int>::type
+    addColSet(T &t,dummy<2> = 2) { 
+      int s=0;
+      for(typename T::MapIt i(t); i!=INVALID; ++i)
+	{
+	  i.set(addCol());
+	  s++;
+	}
+      return s;
+    }
+#endif
+
+    ///Set a column (i.e a dual constraint) of the LP
+
+    ///\param c is the column to be modified
+    ///\param e is a dual linear expression (see \ref DualExpr)
+    ///a better one.
+    void col(Col c,const DualExpr &e) {
+      e.simplify();
+      _setColCoeffs(_lpId(c), ConstColIterator(e.begin(), *this), 
+                    ConstColIterator(e.end(), *this));
+    }
+
+    ///Get a column (i.e a dual constraint) of the LP
+
+    ///\param r is the column to get
+    ///\return the dual expression associated to the column
+    DualExpr col(Col c) const {
+      DualExpr e;
+      _getColCoeffs(_lpId(c), ColIterator(std::inserter(e, e.end()), *this));
+      return e;
+    }
+
+    ///Add a new column to the LP
+
+    ///\param e is a dual linear expression (see \ref DualExpr)
+    ///\param obj is the corresponding component of the objective
+    ///function. It is 0 by default.
+    ///\return The created column.
+    Col addCol(const DualExpr &e, Value o = 0) {
+      Col c=addCol();
+      col(c,e);
+      objCoeff(c,o);
+      return c;
+    }
+
+    ///Add a new empty row (i.e a new constraint) to the LP
+
+    ///This function adds a new empty row (i.e a new constraint) to the LP.
+    ///\return The created row
+    Row addRow() { Row r; _addRow(); r.id = rows.addId(); return r;}
+
+    ///\brief Add several new rows
+    ///(i.e a constraints) at once
+    ///
+    ///This magic function takes a container as its argument
+    ///and fills its elements
+    ///with new row (i.e. variables)
+    ///\param t can be
+    ///- a standard STL compatible iterable container with
+    ///\ref Row as its \c values_type
+    ///like
+    ///\code
+    ///std::vector<LpSolverBase::Row>
+    ///std::list<LpSolverBase::Row>
+    ///\endcode
+    ///- a standard STL compatible iterable container with
+    ///\ref Row as its \c mapped_type
+    ///like
+    ///\code
+    ///std::map<AnyType,LpSolverBase::Row>
+    ///\endcode
+    ///- an iterable lemon \ref concepts::WriteMap "write map" like 
+    ///\code
+    ///ListGraph::NodeMap<LpSolverBase::Row>
+    ///ListGraph::EdgeMap<LpSolverBase::Row>
+    ///\endcode
+    ///\return The number of rows created.
+#ifdef DOXYGEN
+    template<class T>
+    int addRowSet(T &t) { return 0;} 
+#else
+    template<class T>
+    typename enable_if<typename T::value_type::LpSolverRow,int>::type
+    addRowSet(T &t,dummy<0> = 0) {
+      int s=0;
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {*i=addRow();s++;}
+      return s;
+    }
+    template<class T>
+    typename enable_if<typename T::value_type::second_type::LpSolverRow,
+		       int>::type
+    addRowSet(T &t,dummy<1> = 1) { 
+      int s=0;
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {
+	i->second=addRow();
+	s++;
+      }
+      return s;
+    }
+    template<class T>
+    typename enable_if<typename T::MapIt::Value::LpSolverRow,
+		       int>::type
+    addRowSet(T &t,dummy<2> = 2) { 
+      int s=0;
+      for(typename T::MapIt i(t); i!=INVALID; ++i)
+	{
+	  i.set(addRow());
+	  s++;
+	}
+      return s;
+    }
+#endif
+
+    ///Set a row (i.e a constraint) of the LP
+
+    ///\param r is the row to be modified
+    ///\param l is lower bound (-\ref INF means no bound)
+    ///\param e is a linear expression (see \ref Expr)
+    ///\param u is the upper bound (\ref INF means no bound)
+    ///\bug This is a temporary function. The interface will change to
+    ///a better one.
+    ///\todo Option to control whether a constraint with a single variable is
+    ///added or not.
+    void row(Row r, Value l, const Expr &e, Value u) {
+      e.simplify();
+      _setRowCoeffs(_lpId(r), ConstRowIterator(e.begin(), *this),
+                    ConstRowIterator(e.end(), *this));
+      _setRowBounds(_lpId(r),l-e.constComp(),u-e.constComp());
+    }
+
+    ///Set a row (i.e a constraint) of the LP
+
+    ///\param r is the row to be modified
+    ///\param c is a linear expression (see \ref Constr)
+    void row(Row r, const Constr &c) {
+      row(r, c.lowerBounded()?c.lowerBound():-INF,
+          c.expr(), c.upperBounded()?c.upperBound():INF);
+    }
+
+    
+    ///Get a row (i.e a constraint) of the LP
+
+    ///\param r is the row to get
+    ///\return the expression associated to the row
+    Expr row(Row r) const {
+      Expr e;
+      _getRowCoeffs(_lpId(r), RowIterator(std::inserter(e, e.end()), *this));
+      return e;
+    }
+
+    ///Add a new row (i.e a new constraint) to the LP
+
+    ///\param l is the lower bound (-\ref INF means no bound)
+    ///\param e is a linear expression (see \ref Expr)
+    ///\param u is the upper bound (\ref INF means no bound)
+    ///\return The created row.
+    ///\bug This is a temporary function. The interface will change to
+    ///a better one.
+    Row addRow(Value l,const Expr &e, Value u) {
+      Row r=addRow();
+      row(r,l,e,u);
+      return r;
+    }
+
+    ///Add a new row (i.e a new constraint) to the LP
+
+    ///\param c is a linear expression (see \ref Constr)
+    ///\return The created row.
+    Row addRow(const Constr &c) {
+      Row r=addRow();
+      row(r,c);
+      return r;
+    }
+    ///Erase a coloumn (i.e a variable) from the LP
+
+    ///\param c is the coloumn to be deleted
+    ///\todo Please check this
+    void eraseCol(Col c) {
+      _eraseCol(_lpId(c));
+      cols.eraseId(c.id);
+    }
+    ///Erase a  row (i.e a constraint) from the LP
+
+    ///\param r is the row to be deleted
+    ///\todo Please check this
+    void eraseRow(Row r) {
+      _eraseRow(_lpId(r));
+      rows.eraseId(r.id);
+    }
+
+    /// Get the name of a column
+    
+    ///\param c is the coresponding coloumn 
+    ///\return The name of the colunm
+    std::string colName(Col c) const {
+      std::string name;
+      _getColName(_lpId(c), name);
+      return name;
+    }
+    
+    /// Set the name of a column
+    
+    ///\param c is the coresponding coloumn 
+    ///\param name The name to be given
+    void colName(Col c, const std::string& name) {
+      _setColName(_lpId(c), name);
+    }
+
+    /// Get the column by its name
+    
+    ///\param name The name of the column
+    ///\return the proper column or \c INVALID
+    Col colByName(const std::string& name) const {
+      int k = _colByName(name);
+      return k != -1 ? Col(cols.fixId(k)) : Col(INVALID);
+    }
+    
+    /// Set an element of the coefficient matrix of the LP
+
+    ///\param r is the row of the element to be modified
+    ///\param c is the coloumn of the element to be modified
+    ///\param val is the new value of the coefficient
+
+    void coeff(Row r, Col c, Value val) {
+      _setCoeff(_lpId(r),_lpId(c), val);
+    }
+
+    /// Get an element of the coefficient matrix of the LP
+
+    ///\param r is the row of the element in question
+    ///\param c is the coloumn of the element in question
+    ///\return the corresponding coefficient
+
+    Value coeff(Row r, Col c) const {
+      return _getCoeff(_lpId(r),_lpId(c));
+    }
+
+    /// Set the lower bound of a column (i.e a variable)
+
+    /// The lower bound of a variable (column) has to be given by an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value or -\ref INF.
+    void colLowerBound(Col c, Value value) {
+      _setColLowerBound(_lpId(c),value);
+    }
+
+    /// Get the lower bound of a column (i.e a variable)
+
+    /// This function returns the lower bound for column (variable) \t c
+    /// (this might be -\ref INF as well).  
+    ///\return The lower bound for coloumn \t c
+    Value colLowerBound(Col c) const {
+      return _getColLowerBound(_lpId(c));
+    }
+    
+    ///\brief Set the lower bound of  several columns
+    ///(i.e a variables) at once
+    ///
+    ///This magic function takes a container as its argument
+    ///and applies the function on all of its elements.
+    /// The lower bound of a variable (column) has to be given by an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value or -\ref INF.
+#ifdef DOXYGEN
+    template<class T>
+    void colLowerBound(T &t, Value value) { return 0;} 
+#else
+    template<class T>
+    typename enable_if<typename T::value_type::LpSolverCol,void>::type
+    colLowerBound(T &t, Value value,dummy<0> = 0) {
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {
+	colLowerBound(*i, value);
+      }
+    }
+    template<class T>
+    typename enable_if<typename T::value_type::second_type::LpSolverCol,
+		       void>::type
+    colLowerBound(T &t, Value value,dummy<1> = 1) { 
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {
+	colLowerBound(i->second, value);
+      }
+    }
+    template<class T>
+    typename enable_if<typename T::MapIt::Value::LpSolverCol,
+		       void>::type
+    colLowerBound(T &t, Value value,dummy<2> = 2) { 
+      for(typename T::MapIt i(t); i!=INVALID; ++i){
+	colLowerBound(*i, value);
+      }
+    }
+#endif
+    
+    /// Set the upper bound of a column (i.e a variable)
+
+    /// The upper bound of a variable (column) has to be given by an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value or \ref INF.
+    void colUpperBound(Col c, Value value) {
+      _setColUpperBound(_lpId(c),value);
+    };
+
+    /// Get the upper bound of a column (i.e a variable)
+
+    /// This function returns the upper bound for column (variable) \t c
+    /// (this might be \ref INF as well).  
+    ///\return The upper bound for coloumn \t c
+    Value colUpperBound(Col c) const {
+      return _getColUpperBound(_lpId(c));
+    }
+
+    ///\brief Set the upper bound of  several columns
+    ///(i.e a variables) at once
+    ///
+    ///This magic function takes a container as its argument
+    ///and applies the function on all of its elements.
+    /// The upper bound of a variable (column) has to be given by an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value or \ref INF.
+#ifdef DOXYGEN
+    template<class T>
+    void colUpperBound(T &t, Value value) { return 0;} 
+#else
+    template<class T>
+    typename enable_if<typename T::value_type::LpSolverCol,void>::type
+    colUpperBound(T &t, Value value,dummy<0> = 0) {
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {
+	colUpperBound(*i, value);
+      }
+    }
+    template<class T>
+    typename enable_if<typename T::value_type::second_type::LpSolverCol,
+		       void>::type
+    colUpperBound(T &t, Value value,dummy<1> = 1) { 
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {
+	colUpperBound(i->second, value);
+      }
+    }
+    template<class T>
+    typename enable_if<typename T::MapIt::Value::LpSolverCol,
+		       void>::type
+    colUpperBound(T &t, Value value,dummy<2> = 2) { 
+      for(typename T::MapIt i(t); i!=INVALID; ++i){
+	colUpperBound(*i, value);
+      }
+    }
+#endif
+
+    /// Set the lower and the upper bounds of a column (i.e a variable)
+
+    /// The lower and the upper bounds of
+    /// a variable (column) have to be given by an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value, -\ref INF or \ref INF.
+    void colBounds(Col c, Value lower, Value upper) {
+      _setColLowerBound(_lpId(c),lower);
+      _setColUpperBound(_lpId(c),upper);
+    }
+    
+    ///\brief Set the lower and the upper bound of several columns
+    ///(i.e a variables) at once
+    ///
+    ///This magic function takes a container as its argument
+    ///and applies the function on all of its elements.
+    /// The lower and the upper bounds of
+    /// a variable (column) have to be given by an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value, -\ref INF or \ref INF.
+#ifdef DOXYGEN
+    template<class T>
+    void colBounds(T &t, Value lower, Value upper) { return 0;} 
+#else
+    template<class T>
+    typename enable_if<typename T::value_type::LpSolverCol,void>::type
+    colBounds(T &t, Value lower, Value upper,dummy<0> = 0) {
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {
+	colBounds(*i, lower, upper);
+      }
+    }
+    template<class T>
+    typename enable_if<typename T::value_type::second_type::LpSolverCol,
+		       void>::type
+    colBounds(T &t, Value lower, Value upper,dummy<1> = 1) { 
+      for(typename T::iterator i=t.begin();i!=t.end();++i) {
+	colBounds(i->second, lower, upper);
+      }
+    }
+    template<class T>
+    typename enable_if<typename T::MapIt::Value::LpSolverCol,
+		       void>::type
+    colBounds(T &t, Value lower, Value upper,dummy<2> = 2) { 
+      for(typename T::MapIt i(t); i!=INVALID; ++i){
+	colBounds(*i, lower, upper);
+      }
+    }
+#endif
+    
+
+    /// Set the lower and the upper bounds of a row (i.e a constraint)
+
+    /// The lower and the upper bound of a constraint (row) have to be
+    /// given by an extended number of type Value, i.e. a finite
+    /// number of type Value, -\ref INF or \ref INF. There is no
+    /// separate function for the lower and the upper bound because
+    /// that would have been hard to implement for CPLEX.
+    void rowBounds(Row c, Value lower, Value upper) {
+      _setRowBounds(_lpId(c),lower, upper);
+    }
+    
+    /// Get the lower and the upper bounds of a row (i.e a constraint)
+
+    /// The lower and the upper bound of
+    /// a constraint (row) are  
+    /// extended numbers of type Value, i.e.  finite numbers of type 
+    /// Value, -\ref INF or \ref INF. 
+    /// \todo There is no separate function for the 
+    /// lower and the upper bound because we had problems with the 
+    /// implementation of the setting functions for CPLEX:  
+    /// check out whether this can be done for these functions.
+    void getRowBounds(Row c, Value &lower, Value &upper) const {
+      _getRowBounds(_lpId(c),lower, upper);
+    }
+
+    ///Set an element of the objective function
+    void objCoeff(Col c, Value v) {_setObjCoeff(_lpId(c),v); };
+
+    ///Get an element of the objective function
+    Value objCoeff(Col c) const { return _getObjCoeff(_lpId(c)); };
+
+    ///Set the objective function
+
+    ///\param e is a linear expression of type \ref Expr.
+    void obj(Expr e) {
+      _clearObj();
+      for (Expr::iterator i=e.begin(); i!=e.end(); ++i)
+	objCoeff((*i).first,(*i).second);
+      obj_const_comp=e.constComp();
+    }
+
+    ///Get the objective function
+
+    ///\return the objective function as a linear expression of type \ref Expr.
+    Expr obj() const {
+      Expr e;
+      for (ColIt it(*this); it != INVALID; ++it) {
+        double c = objCoeff(it);
+        if (c != 0.0) {
+          e.insert(std::make_pair(it, c));
+        }
+      }
+      return e;
+    }
+    
+
+    ///Maximize
+    void max() { _setMax(); }
+    ///Minimize
+    void min() { _setMin(); }
+
+    ///Query function: is this a maximization problem?
+    bool isMax() const {return _isMax(); }
+
+    ///Query function: is this a minimization problem?
+    bool isMin() const {return !isMax(); }
+    
+    ///@}
+
+
+    ///\name Solve the LP
+
+    ///@{
+
+    ///\e Solve the LP problem at hand
+    ///
+    ///\return The result of the optimization procedure. Possible 
+    ///values and their meanings can be found in the documentation of 
+    ///\ref SolveExitStatus.
+    ///
+    ///\todo Which method is used to solve the problem
+    SolveExitStatus solve() { return _solve(); }
+    
+    ///@}
+    
+    ///\name Obtain the solution
+
+    ///@{
+
+    /// The status of the primal problem (the original LP problem)
+    SolutionStatus primalStatus() const {
+      return _getPrimalStatus();
+    }
+
+    /// The status of the dual (of the original LP) problem 
+    SolutionStatus dualStatus() const {
+      return _getDualStatus();
+    }
+
+    ///The type of the original LP problem
+    ProblemTypes problemType() const {
+      return _getProblemType();
+    }
+
+    ///\e
+    Value primal(Col c) const { return _getPrimal(_lpId(c)); }
+    ///\e
+    Value primal(const Expr& e) const {
+      double res = e.constComp();
+      for (std::map<Col, double>::const_iterator it = e.begin();
+	   it != e.end(); ++it) {
+	res += _getPrimal(_lpId(it->first)) * it->second;
+      }
+      return res; 
+    }
+
+    ///\e
+    Value dual(Row r) const { return _getDual(_lpId(r)); }
+    ///\e
+    Value dual(const DualExpr& e) const {
+      double res = 0.0;
+      for (std::map<Row, double>::const_iterator it = e.begin();
+	   it != e.end(); ++it) {
+	res += _getPrimal(_lpId(it->first)) * it->second;
+      }
+      return res; 
+    }
+
+    ///\e
+    bool isBasicCol(Col c) const { return _isBasicCol(_lpId(c)); }
+
+    ///\e
+
+    ///\return
+    ///- \ref INF or -\ref INF means either infeasibility or unboundedness
+    /// of the primal problem, depending on whether we minimize or maximize.
+    ///- \ref NaN if no primal solution is found.
+    ///- The (finite) objective value if an optimal solution is found.
+    Value primalValue() const { return _getPrimalValue()+obj_const_comp;}
+    ///@}
+    
+  };  
+
+
+  /// \ingroup lp_group
+  ///
+  /// \brief Common base class for MIP solvers
+  /// \todo Much more docs
+  class MipSolverBase : virtual public LpSolverBase{
+  public:
+
+    ///Possible variable (coloumn) types (e.g. real, integer, binary etc.)
+    enum ColTypes {
+      ///Continuous variable
+      REAL = 0,
+      ///Integer variable
+
+      ///Unfortunately, cplex 7.5 somewhere writes something like
+      ///#define INTEGER 'I'
+      INT = 1
+      ///\todo No support for other types yet.
+    };
+
+    ///Sets the type of the given coloumn to the given type
+    ///
+    ///Sets the type of the given coloumn to the given type.
+    void colType(Col c, ColTypes col_type) {
+      _colType(_lpId(c),col_type);
+    }
+
+    ///Gives back the type of the column.
+    ///
+    ///Gives back the type of the column.
+    ColTypes colType(Col c) const {
+      return _colType(_lpId(c));
+    }
+
+    ///Sets the type of the given Col to integer or remove that property.
+    ///
+    ///Sets the type of the given Col to integer or remove that property.
+    void integer(Col c, bool enable) {
+      if (enable)
+	colType(c,INT);
+      else
+	colType(c,REAL);
+    }
+
+    ///Gives back whether the type of the column is integer or not.
+    ///
+    ///Gives back the type of the column.
+    ///\return true if the column has integer type and false if not.
+    bool integer(Col c) const {
+      return (colType(c)==INT);
+    }
+
+    /// The status of the MIP problem
+    SolutionStatus mipStatus() const {
+      return _getMipStatus();
+    }
+
+  protected:
+
+    virtual ColTypes _colType(int col) const = 0;
+    virtual void _colType(int col, ColTypes col_type) = 0;
+    virtual SolutionStatus _getMipStatus() const = 0;
+
+  };
+  
+  ///\relates LpSolverBase::Expr
+  ///
+  inline LpSolverBase::Expr operator+(const LpSolverBase::Expr &a,
+				      const LpSolverBase::Expr &b) 
+  {
+    LpSolverBase::Expr tmp(a);
+    tmp+=b;
+    return tmp;
+  }
+  ///\e
+  
+  ///\relates LpSolverBase::Expr
+  ///
+  inline LpSolverBase::Expr operator-(const LpSolverBase::Expr &a,
+				      const LpSolverBase::Expr &b) 
+  {
+    LpSolverBase::Expr tmp(a);
+    tmp-=b;
+    return tmp;
+  }
+  ///\e
+  
+  ///\relates LpSolverBase::Expr
+  ///
+  inline LpSolverBase::Expr operator*(const LpSolverBase::Expr &a,
+				      const LpSolverBase::Value &b) 
+  {
+    LpSolverBase::Expr tmp(a);
+    tmp*=b;
+    return tmp;
+  }
+  
+  ///\e
+  
+  ///\relates LpSolverBase::Expr
+  ///
+  inline LpSolverBase::Expr operator*(const LpSolverBase::Value &a,
+				      const LpSolverBase::Expr &b) 
+  {
+    LpSolverBase::Expr tmp(b);
+    tmp*=a;
+    return tmp;
+  }
+  ///\e
+  
+  ///\relates LpSolverBase::Expr
+  ///
+  inline LpSolverBase::Expr operator/(const LpSolverBase::Expr &a,
+				      const LpSolverBase::Value &b) 
+  {
+    LpSolverBase::Expr tmp(a);
+    tmp/=b;
+    return tmp;
+  }
+  
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator<=(const LpSolverBase::Expr &e,
+					 const LpSolverBase::Expr &f) 
+  {
+    return LpSolverBase::Constr(-LpSolverBase::INF,e-f,0);
+  }
+
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator<=(const LpSolverBase::Value &e,
+					 const LpSolverBase::Expr &f) 
+  {
+    return LpSolverBase::Constr(e,f);
+  }
+
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator<=(const LpSolverBase::Expr &e,
+					 const LpSolverBase::Value &f) 
+  {
+    return LpSolverBase::Constr(-LpSolverBase::INF,e,f);
+  }
+
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator>=(const LpSolverBase::Expr &e,
+					 const LpSolverBase::Expr &f) 
+  {
+    return LpSolverBase::Constr(-LpSolverBase::INF,f-e,0);
+  }
+
+
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator>=(const LpSolverBase::Value &e,
+					 const LpSolverBase::Expr &f) 
+  {
+    return LpSolverBase::Constr(f,e);
+  }
+
+
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator>=(const LpSolverBase::Expr &e,
+					 const LpSolverBase::Value &f) 
+  {
+    return LpSolverBase::Constr(f,e,LpSolverBase::INF);
+  }
+
+  ///\e
+
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator==(const LpSolverBase::Expr &e,
+					 const LpSolverBase::Value &f) 
+  {
+    return LpSolverBase::Constr(f,e,f);
+  }
+
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator==(const LpSolverBase::Expr &e,
+					 const LpSolverBase::Expr &f) 
+  {
+    return LpSolverBase::Constr(0,e-f,0);
+  }
+
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator<=(const LpSolverBase::Value &n,
+					 const LpSolverBase::Constr&c) 
+  {
+    LpSolverBase::Constr tmp(c);
+    ///\todo Create an own exception type.
+    if(!LpSolverBase::isNaN(tmp.lowerBound())) throw LogicError();
+    else tmp.lowerBound()=n;
+    return tmp;
+  }
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator<=(const LpSolverBase::Constr& c,
+					 const LpSolverBase::Value &n)
+  {
+    LpSolverBase::Constr tmp(c);
+    ///\todo Create an own exception type.
+    if(!LpSolverBase::isNaN(tmp.upperBound())) throw LogicError();
+    else tmp.upperBound()=n;
+    return tmp;
+  }
+
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator>=(const LpSolverBase::Value &n,
+					 const LpSolverBase::Constr&c) 
+  {
+    LpSolverBase::Constr tmp(c);
+    ///\todo Create an own exception type.
+    if(!LpSolverBase::isNaN(tmp.upperBound())) throw LogicError();
+    else tmp.upperBound()=n;
+    return tmp;
+  }
+  ///\e
+  
+  ///\relates LpSolverBase::Constr
+  ///
+  inline LpSolverBase::Constr operator>=(const LpSolverBase::Constr& c,
+					 const LpSolverBase::Value &n)
+  {
+    LpSolverBase::Constr tmp(c);
+    ///\todo Create an own exception type.
+    if(!LpSolverBase::isNaN(tmp.lowerBound())) throw LogicError();
+    else tmp.lowerBound()=n;
+    return tmp;
+  }
+
+  ///\e
+  
+  ///\relates LpSolverBase::DualExpr
+  ///
+  inline LpSolverBase::DualExpr operator+(const LpSolverBase::DualExpr &a,
+                                          const LpSolverBase::DualExpr &b) 
+  {
+    LpSolverBase::DualExpr tmp(a);
+    tmp+=b;
+    return tmp;
+  }
+  ///\e
+  
+  ///\relates LpSolverBase::DualExpr
+  ///
+  inline LpSolverBase::DualExpr operator-(const LpSolverBase::DualExpr &a,
+                                          const LpSolverBase::DualExpr &b) 
+  {
+    LpSolverBase::DualExpr tmp(a);
+    tmp-=b;
+    return tmp;
+  }
+  ///\e
+  
+  ///\relates LpSolverBase::DualExpr
+  ///
+  inline LpSolverBase::DualExpr operator*(const LpSolverBase::DualExpr &a,
+                                          const LpSolverBase::Value &b) 
+  {
+    LpSolverBase::DualExpr tmp(a);
+    tmp*=b;
+    return tmp;
+  }
+  
+  ///\e
+  
+  ///\relates LpSolverBase::DualExpr
+  ///
+  inline LpSolverBase::DualExpr operator*(const LpSolverBase::Value &a,
+                                          const LpSolverBase::DualExpr &b) 
+  {
+    LpSolverBase::DualExpr tmp(b);
+    tmp*=a;
+    return tmp;
+  }
+  ///\e
+  
+  ///\relates LpSolverBase::DualExpr
+  ///
+  inline LpSolverBase::DualExpr operator/(const LpSolverBase::DualExpr &a,
+                                          const LpSolverBase::Value &b) 
+  {
+    LpSolverBase::DualExpr tmp(a);
+    tmp/=b;
+    return tmp;
+  }
+  
+
+} //namespace lemon
+
+#endif //LEMON_LP_BASE_H
Index: lemon/lp_cplex.cc
===================================================================
--- lemon/lp_cplex.cc	(revision 2605)
+++ lemon/lp_cplex.cc	(revision 2605)
@@ -0,0 +1,687 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <vector>
+#include<lemon/lp_cplex.h>
+
+///\file
+///\brief Implementation of the LEMON-CPLEX lp solver interface.
+namespace lemon {
+  
+  LpCplex::LpCplex() {
+    //    env = CPXopenCPLEXdevelop(&status);     
+    env = CPXopenCPLEX(&status);     
+    lp = CPXcreateprob(env, &status, "LP problem");
+  }
+
+  LpCplex::LpCplex(const LpCplex& cplex) : LpSolverBase() {
+    env = CPXopenCPLEX(&status);     
+    lp = CPXcloneprob(env, cplex.lp, &status);
+    rows = cplex.rows;
+    cols = cplex.cols;
+  }
+  
+  LpCplex::~LpCplex() {
+    CPXfreeprob(env,&lp);
+    CPXcloseCPLEX(&env);
+  }
+  
+  LpSolverBase* LpCplex::_newLp() 
+  {
+    //The first approach opens a new environment
+    return new LpCplex();
+  }
+
+  LpSolverBase* LpCplex::_copyLp() {
+    return new LpCplex(*this);
+  }
+
+  int LpCplex::_addCol()
+  {
+    int i = CPXgetnumcols(env, lp);
+    Value lb[1],ub[1];
+    lb[0]=-INF;
+    ub[0]=INF;
+    status = CPXnewcols(env, lp, 1, NULL, lb, ub, NULL, NULL);
+    return i;
+  }
+
+  
+  int LpCplex::_addRow() 
+  {
+    //We want a row that is not constrained
+    char sense[1];
+    sense[0]='L';//<= constraint
+    Value rhs[1];
+    rhs[0]=INF;
+    int i = CPXgetnumrows(env, lp);
+    status = CPXnewrows(env, lp, 1, rhs, sense, NULL, NULL);
+    return i;
+  }
+
+
+  void LpCplex::_eraseCol(int i) {
+    CPXdelcols(env, lp, i, i);
+  }
+  
+  void LpCplex::_eraseRow(int i) {
+    CPXdelrows(env, lp, i, i);
+  }
+  
+  void LpCplex::_getColName(int col, std::string &name) const
+  {
+    ///\bug Untested
+    int storespace;
+    CPXgetcolname(env, lp, 0, 0, 0, &storespace, col, col);
+    if (storespace == 0) {
+      name.clear();
+      return;
+    }
+    
+    storespace *= -1;
+    std::vector<char> buf(storespace);
+    char *names[1];
+    int dontcare;
+    ///\bug return code unchecked for error
+    CPXgetcolname(env, lp, names, &*buf.begin(), storespace, &dontcare, col, col);
+    name = names[0];
+  }
+  
+  void LpCplex::_setColName(int col, const std::string &name)
+  {
+    ///\bug Untested
+    char *names[1];
+    names[0] = const_cast<char*>(name.c_str());
+    ///\bug return code unchecked for error
+    CPXchgcolname(env, lp, 1, &col, names);    
+  }
+
+  int LpCplex::_colByName(const std::string& name) const
+  {
+    int index;
+    if (CPXgetcolindex(env, lp, 
+                       const_cast<char*>(name.c_str()), &index) == 0) {
+      return index;
+    }
+    return -1; 
+  }
+  
+  ///\warning Data at index 0 is ignored in the arrays.
+  void LpCplex::_setRowCoeffs(int i, ConstRowIterator b, ConstRowIterator e)
+  {
+    std::vector<int> indices;
+    std::vector<int> rowlist;
+    std::vector<Value> values;
+
+    for(ConstRowIterator it=b; it!=e; ++it) {
+      indices.push_back(it->first);
+      values.push_back(it->second);
+      rowlist.push_back(i);
+    }
+
+    status = CPXchgcoeflist(env, lp, values.size(), 
+			    &rowlist[0], &indices[0], &values[0]); 
+  }
+
+  void LpCplex::_getRowCoeffs(int i, RowIterator b) const {
+    int tmp1, tmp2, tmp3, length;
+    CPXgetrows(env, lp, &tmp1, &tmp2, 0, 0, 0, &length, i, i);
+    
+    length = -length;
+    std::vector<int> indices(length);
+    std::vector<double> values(length);
+
+    CPXgetrows(env, lp, &tmp1, &tmp2, &indices[0], &values[0], 
+	       length, &tmp3, i, i);
+    
+    for (int i = 0; i < length; ++i) {
+      *b = std::make_pair(indices[i], values[i]);
+      ++b;
+    }
+    
+    /// \todo implement
+  }
+  
+  void LpCplex::_setColCoeffs(int i, ConstColIterator b, ConstColIterator e)
+  {
+    std::vector<int> indices;
+    std::vector<int> collist;
+    std::vector<Value> values;
+
+    for(ConstColIterator it=b; it!=e; ++it) {
+      indices.push_back(it->first);
+      values.push_back(it->second);
+      collist.push_back(i);
+    }
+
+    status = CPXchgcoeflist(env, lp, values.size(), 
+			    &indices[0], &collist[0], &values[0]); 
+  }
+
+  void LpCplex::_getColCoeffs(int i, ColIterator b) const {
+
+    int tmp1, tmp2, tmp3, length;
+    CPXgetcols(env, lp, &tmp1, &tmp2, 0, 0, 0, &length, i, i);
+    
+    length = -length;
+    std::vector<int> indices(length);
+    std::vector<double> values(length);
+
+    CPXgetcols(env, lp, &tmp1, &tmp2, &indices[0], &values[0], 
+	       length, &tmp3, i, i);
+    
+    for (int i = 0; i < length; ++i) {
+      *b = std::make_pair(indices[i], values[i]);
+      ++b;
+    }
+    
+  }
+  
+  void LpCplex::_setCoeff(int row, int col, Value value) 
+  {
+    CPXchgcoef(env, lp, row, col, value);
+  }
+
+  LpCplex::Value LpCplex::_getCoeff(int row, int col) const
+  {
+    LpCplex::Value value;
+    CPXgetcoef(env, lp, row, col, &value);
+    return value;
+  }
+
+  void LpCplex::_setColLowerBound(int i, Value value)
+  {
+    int indices[1];
+    indices[0]=i;
+    char lu[1];
+    lu[0]='L';
+    Value bd[1];
+    bd[0]=value;
+    status = CPXchgbds(env, lp, 1, indices, lu, bd);
+ 
+  }
+
+  LpCplex::Value LpCplex::_getColLowerBound(int i) const
+  {
+    LpCplex::Value x;
+    CPXgetlb (env, lp, &x, i, i);
+    if (x <= -CPX_INFBOUND) x = -INF;
+    return x;
+  }
+  
+  void LpCplex::_setColUpperBound(int i, Value value)
+  {
+    int indices[1];
+    indices[0]=i;
+    char lu[1];
+    lu[0]='U';
+    Value bd[1];
+    bd[0]=value;
+    status = CPXchgbds(env, lp, 1, indices, lu, bd);
+  }
+
+  LpCplex::Value LpCplex::_getColUpperBound(int i) const
+  {
+    LpCplex::Value x;
+    CPXgetub (env, lp, &x, i, i);
+    if (x >= CPX_INFBOUND) x = INF;
+    return x;
+  }
+
+  //This will be easier to implement
+  void LpCplex::_setRowBounds(int i, Value lb, Value ub)
+  {
+    //Bad parameter
+    if (lb==INF || ub==-INF) {
+      //FIXME error
+    }
+    
+    int cnt=1;
+    int indices[1];
+    indices[0]=i;
+    char sense[1];
+
+    if (lb==-INF){
+      sense[0]='L';
+      CPXchgsense(env, lp, cnt, indices, sense);
+      CPXchgcoef(env, lp, i, -1, ub);
+      
+    }
+    else{
+      if (ub==INF){
+	sense[0]='G';
+	CPXchgsense(env, lp, cnt, indices, sense);
+	CPXchgcoef(env, lp, i, -1, lb);
+      }
+      else{
+	if (lb == ub){
+	  sense[0]='E';
+	  CPXchgsense(env, lp, cnt, indices, sense);
+	  CPXchgcoef(env, lp, i, -1, lb);
+	}
+	else{
+	  sense[0]='R';
+	  CPXchgsense(env, lp, cnt, indices, sense);
+	  CPXchgcoef(env, lp, i, -1, lb);
+	  CPXchgcoef(env, lp, i, -2, ub-lb);	  
+	}
+      }
+    }
+  }
+
+//   void LpCplex::_setRowLowerBound(int i, Value value)
+//   {
+//     //Not implemented, obsolete
+//   }
+  
+//   void LpCplex::_setRowUpperBound(int i, Value value)
+//   {
+//     //Not implemented, obsolete
+// //     //TODO Ezt kell meg megirni
+// //     //type of the problem
+// //     char sense[1];
+// //     status = CPXgetsense(env, lp, sense, i, i);
+// //     Value rhs[1];
+// //     status = CPXgetrhs(env, lp, rhs, i, i);
+
+// //     switch (sense[0]) {
+// //     case 'L'://<= constraint
+// //       break;
+// //     case 'E'://= constraint
+// //       break;
+// //     case 'G'://>= constraint
+// //       break;
+// //     case 'R'://ranged constraint
+// //       break;
+// //     default: ;
+// //       //FIXME error
+// //     }
+
+// //     status = CPXchgcoef(env, lp, i, -2, value_rng);
+//   }
+  
+  void LpCplex::_getRowBounds(int i, Value &lb, Value &ub) const
+  {
+    char sense;
+    CPXgetsense(env, lp, &sense,i,i);
+    lb=-INF;
+    ub=INF;
+    switch (sense)
+      {
+      case 'L':
+	CPXgetcoef(env, lp, i, -1, &ub);
+	break;
+      case 'G':
+	CPXgetcoef(env, lp, i, -1, &lb);
+	break;
+      case 'E':
+	CPXgetcoef(env, lp, i, -1, &lb);
+	ub=lb;
+	break;
+      case 'R':
+	CPXgetcoef(env, lp, i, -1, &lb);
+	Value x;
+	CPXgetcoef(env, lp, i, -2, &x);
+	ub=lb+x;
+	break;
+      }
+  }
+
+  void LpCplex::_setObjCoeff(int i, Value obj_coef)
+  {
+    CPXchgcoef(env, lp, -1, i, obj_coef);
+  }
+
+  LpCplex::Value LpCplex::_getObjCoeff(int i) const
+  {
+    Value x;
+    CPXgetcoef(env, lp, -1, i, &x);
+    return x;
+  }
+
+  void LpCplex::_clearObj()
+  {
+    for (int i=0;i< CPXgetnumcols(env, lp);++i){
+      CPXchgcoef(env, lp, -1, i, 0);
+    }
+    
+  }
+  // The routine returns zero unless an error occurred during the
+  // optimization. Examples of errors include exhausting available
+  // memory (CPXERR_NO_MEMORY) or encountering invalid data in the
+  // CPLEX problem object (CPXERR_NO_PROBLEM). Exceeding a
+  // user-specified CPLEX limit, or proving the model infeasible or
+  // unbounded, are not considered errors. Note that a zero return
+  // value does not necessarily mean that a solution exists. Use query
+  // routines CPXsolninfo, CPXgetstat, and CPXsolution to obtain
+  // further information about the status of the optimization.
+  LpCplex::SolveExitStatus LpCplex::_solve()
+  {
+    //CPX_PARAM_LPMETHOD 
+    status = CPXlpopt(env, lp);
+    //status = CPXprimopt(env, lp);
+#if CPX_VERSION >= 800
+    if (status)
+    {
+      return UNSOLVED;
+    }
+    else
+    {
+      switch (CPXgetstat(env, lp))
+      {
+        case CPX_STAT_OPTIMAL:
+        case CPX_STAT_INFEASIBLE:
+        case CPX_STAT_UNBOUNDED:
+          return SOLVED;
+        default:
+          return UNSOLVED;
+      }
+    }
+#else
+    if (status == 0){
+      //We want to exclude some cases
+      switch (CPXgetstat(env, lp)){
+      case CPX_OBJ_LIM:
+      case CPX_IT_LIM_FEAS:
+      case CPX_IT_LIM_INFEAS:               
+      case CPX_TIME_LIM_FEAS:
+      case CPX_TIME_LIM_INFEAS:
+	return UNSOLVED;
+      default:
+	return SOLVED; 
+      }
+    }
+    else{
+      return UNSOLVED;
+    }
+#endif
+  }
+
+  LpCplex::Value LpCplex::_getPrimal(int i) const
+  {
+    Value x;
+    CPXgetx(env, lp, &x, i, i);
+    return x;
+  }
+
+  LpCplex::Value LpCplex::_getDual(int i) const
+  {
+    Value y;
+    CPXgetpi(env, lp, &y, i, i);
+    return y;
+  }
+  
+  LpCplex::Value LpCplex::_getPrimalValue() const
+  {
+    Value objval;
+    //method = CPXgetmethod (env, lp);
+    //printf("CPXgetprobtype %d \n",CPXgetprobtype(env,lp));
+    CPXgetobjval(env, lp, &objval);
+    //printf("Objective value: %g \n",objval);
+    return objval;
+  }
+  bool LpCplex::_isBasicCol(int i) const
+  {
+    std::vector<int> cstat(CPXgetnumcols(env, lp));
+    CPXgetbase(env, lp, &*cstat.begin(), NULL);
+    return (cstat[i]==CPX_BASIC);
+  }  
+
+//7.5-os cplex statusai (Vigyazat: a 9.0-asei masok!)
+// This table lists the statuses, returned by the CPXgetstat() routine, for solutions to LP problems or mixed integer problems. If no solution exists, the return value is zero.
+
+// For Simplex, Barrier  
+// 1  	CPX_OPTIMAL  
+// 	 Optimal solution found  
+// 2  	CPX_INFEASIBLE  
+// 	 Problem infeasible  
+// 3    CPX_UNBOUNDED  
+// 	 Problem unbounded  
+// 4  	CPX_OBJ_LIM  
+// 	 Objective limit exceeded in Phase II  
+// 5  	CPX_IT_LIM_FEAS  
+// 	 Iteration limit exceeded in Phase II  
+// 6  	CPX_IT_LIM_INFEAS  
+// 	 Iteration limit exceeded in Phase I  
+// 7  	CPX_TIME_LIM_FEAS  
+// 	 Time limit exceeded in Phase II  
+// 8  	CPX_TIME_LIM_INFEAS  
+// 	 Time limit exceeded in Phase I  
+// 9  	CPX_NUM_BEST_FEAS  
+// 	 Problem non-optimal, singularities in Phase II  
+// 10 	CPX_NUM_BEST_INFEAS  
+// 	 Problem non-optimal, singularities in Phase I  
+// 11 	CPX_OPTIMAL_INFEAS  
+// 	 Optimal solution found, unscaled infeasibilities  
+// 12 	CPX_ABORT_FEAS  
+// 	 Aborted in Phase II  
+// 13 	CPX_ABORT_INFEAS  
+// 	 Aborted in Phase I  
+// 14  	CPX_ABORT_DUAL_INFEAS  
+// 	 Aborted in barrier, dual infeasible  
+// 15  	CPX_ABORT_PRIM_INFEAS  
+// 	 Aborted in barrier, primal infeasible  
+// 16  	CPX_ABORT_PRIM_DUAL_INFEAS  
+// 	 Aborted in barrier, primal and dual infeasible  
+// 17  	CPX_ABORT_PRIM_DUAL_FEAS  
+// 	 Aborted in barrier, primal and dual feasible  
+// 18  	CPX_ABORT_CROSSOVER  
+// 	 Aborted in crossover  
+// 19  	CPX_INForUNBD  
+// 	 Infeasible or unbounded  
+// 20   CPX_PIVOT
+//       User pivot used
+//
+//     Ezeket hova tegyem:
+// ??case CPX_ABORT_DUAL_INFEAS           
+// ??case CPX_ABORT_CROSSOVER             
+// ??case CPX_INForUNBD                   
+// ??case CPX_PIVOT              
+         
+//Some more interesting stuff:
+
+// CPX_PARAM_LPMETHOD  1062  int  LPMETHOD
+// 0 Automatic 
+// 1 Primal Simplex 
+// 2 Dual Simplex 
+// 3 Network Simplex 
+// 4 Standard Barrier 
+// Default: 0 
+// Description: Method for linear optimization. 
+// Determines which algorithm is used when CPXlpopt() (or "optimize" in the Interactive Optimizer) is called. Currently the behavior of the "Automatic" setting is that CPLEX simply invokes the dual simplex method, but this capability may be expanded in the future so that CPLEX chooses the method based on problem characteristics 
+#if CPX_VERSION < 900
+  void statusSwitch(CPXENVptr env,int& stat){
+    int lpmethod;
+    CPXgetintparam (env,CPX_PARAM_LPMETHOD,&lpmethod);
+    if (lpmethod==2){
+      if (stat==CPX_UNBOUNDED){
+	stat=CPX_INFEASIBLE;
+      }
+      else{
+	if (stat==CPX_INFEASIBLE)
+	  stat=CPX_UNBOUNDED;
+      }
+    }
+  }
+#else
+  void statusSwitch(CPXENVptr,int&){}
+#endif
+
+  LpCplex::SolutionStatus LpCplex::_getPrimalStatus() const
+  {
+    //Unboundedness not treated well: the following is from cplex 9.0 doc
+    // About Unboundedness
+
+    // The treatment of models that are unbounded involves a few
+    // subtleties. Specifically, a declaration of unboundedness means that
+    // ILOG CPLEX has determined that the model has an unbounded
+    // ray. Given any feasible solution x with objective z, a multiple of
+    // the unbounded ray can be added to x to give a feasible solution
+    // with objective z-1 (or z+1 for maximization models). Thus, if a
+    // feasible solution exists, then the optimal objective is
+    // unbounded. Note that ILOG CPLEX has not necessarily concluded that
+    // a feasible solution exists. Users can call the routine CPXsolninfo
+    // to determine whether ILOG CPLEX has also concluded that the model
+    // has a feasible solution.
+
+    int stat = CPXgetstat(env, lp);
+#if CPX_VERSION >= 800
+    switch (stat)
+    {
+      case CPX_STAT_OPTIMAL:
+        return OPTIMAL;
+      case CPX_STAT_UNBOUNDED:
+        return INFINITE;
+      case CPX_STAT_INFEASIBLE:
+        return INFEASIBLE;
+      default:
+        return UNDEFINED;
+    }
+#else
+    statusSwitch(env,stat);
+    //CPXgetstat(env, lp);
+    //printf("A primal status: %d, CPX_OPTIMAL=%d \n",stat,CPX_OPTIMAL);
+    switch (stat) {
+    case 0:
+      return UNDEFINED; //Undefined
+    case CPX_OPTIMAL://Optimal
+      return OPTIMAL;
+    case CPX_UNBOUNDED://Unbounded
+      return INFEASIBLE;//In case of dual simplex
+      //return INFINITE;
+    case CPX_INFEASIBLE://Infeasible 
+ //    case CPX_IT_LIM_INFEAS:
+//     case CPX_TIME_LIM_INFEAS:
+//     case CPX_NUM_BEST_INFEAS:             
+//     case CPX_OPTIMAL_INFEAS:              
+//     case CPX_ABORT_INFEAS:                
+//     case CPX_ABORT_PRIM_INFEAS:           
+//     case CPX_ABORT_PRIM_DUAL_INFEAS:      
+      return INFINITE;//In case of dual simplex
+      //return INFEASIBLE;
+//     case CPX_OBJ_LIM:                    
+//     case CPX_IT_LIM_FEAS:             
+//     case CPX_TIME_LIM_FEAS:                
+//     case CPX_NUM_BEST_FEAS:                
+//     case CPX_ABORT_FEAS:                  
+//     case CPX_ABORT_PRIM_DUAL_FEAS:        
+//       return FEASIBLE;
+    default:
+      return UNDEFINED; //Everything else comes here
+      //FIXME error
+    }
+#endif
+  }
+
+//9.0-as cplex verzio statusai
+// CPX_STAT_ABORT_DUAL_OBJ_LIM
+// CPX_STAT_ABORT_IT_LIM
+// CPX_STAT_ABORT_OBJ_LIM
+// CPX_STAT_ABORT_PRIM_OBJ_LIM
+// CPX_STAT_ABORT_TIME_LIM
+// CPX_STAT_ABORT_USER
+// CPX_STAT_FEASIBLE_RELAXED
+// CPX_STAT_INFEASIBLE
+// CPX_STAT_INForUNBD
+// CPX_STAT_NUM_BEST
+// CPX_STAT_OPTIMAL
+// CPX_STAT_OPTIMAL_FACE_UNBOUNDED
+// CPX_STAT_OPTIMAL_INFEAS
+// CPX_STAT_OPTIMAL_RELAXED
+// CPX_STAT_UNBOUNDED
+
+  LpCplex::SolutionStatus LpCplex::_getDualStatus() const
+  {
+    int stat = CPXgetstat(env, lp);
+#if CPX_VERSION >= 800
+    switch (stat)
+    {
+      case CPX_STAT_OPTIMAL:
+        return OPTIMAL;
+      case CPX_STAT_UNBOUNDED:
+        return INFEASIBLE;
+      default:
+        return UNDEFINED;
+    }
+#else
+    statusSwitch(env,stat);
+    switch (stat) {
+    case 0:
+      return UNDEFINED; //Undefined
+    case CPX_OPTIMAL://Optimal
+      return OPTIMAL;
+    case CPX_UNBOUNDED:
+     return INFEASIBLE;
+    default:
+      return UNDEFINED; //Everything else comes here
+      //FIXME error
+    }
+#endif
+  }
+
+  LpCplex::ProblemTypes LpCplex::_getProblemType() const
+  {
+    int stat = CPXgetstat(env, lp);
+#if CPX_VERSION >= 800
+    switch (stat)
+    {
+      case CPX_STAT_OPTIMAL:
+	return PRIMAL_DUAL_FEASIBLE;
+      case CPX_STAT_UNBOUNDED:
+ 	return PRIMAL_FEASIBLE_DUAL_INFEASIBLE;
+      default:
+        return UNKNOWN;
+    }
+#else
+    switch (stat) {
+    case CPX_OPTIMAL://Optimal
+	return PRIMAL_DUAL_FEASIBLE;
+    case CPX_UNBOUNDED:
+ 	return PRIMAL_FEASIBLE_DUAL_INFEASIBLE;
+// 	return PRIMAL_INFEASIBLE_DUAL_FEASIBLE;
+// 	return PRIMAL_DUAL_INFEASIBLE;
+
+//Seems to be that this is all we can say for sure
+    default:
+	//In all other cases
+	return UNKNOWN;
+      //FIXME error
+    }
+#endif
+  }
+
+  void LpCplex::_setMax()
+  {
+    CPXchgobjsen(env, lp, CPX_MAX);
+   }
+  void LpCplex::_setMin()
+  {
+    CPXchgobjsen(env, lp, CPX_MIN);
+   }
+
+  bool LpCplex::_isMax() const
+  {
+    if (CPXgetobjsen(env, lp)==CPX_MAX)
+      return true;
+    else
+      return false;
+  }
+  
+} //namespace lemon
+
Index: lemon/lp_cplex.h
===================================================================
--- lemon/lp_cplex.h	(revision 2605)
+++ lemon/lp_cplex.h	(revision 2605)
@@ -0,0 +1,114 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_LP_CPLEX_H
+#define LEMON_LP_CPLEX_H
+
+///\file
+///\brief Header of the LEMON-CPLEX lp solver interface.
+
+#include <lemon/lp_base.h>
+
+extern "C" {
+#include <ilcplex/cplex.h>
+}
+
+namespace lemon {
+
+
+  /// \brief Interface for the CPLEX solver
+  /// 
+  /// This class implements an interface for the CPLEX LP solver.
+  class LpCplex :virtual public LpSolverBase {
+
+  public:
+
+    typedef LpSolverBase Parent;
+    
+    /// \e
+    int status;
+    CPXENVptr env;
+    CPXLPptr lp;
+
+
+    /// \e
+    LpCplex();
+    /// \e
+    LpCplex(const LpCplex&);
+    /// \e
+    ~LpCplex();
+
+  protected:
+    virtual LpSolverBase* _newLp();
+    virtual LpSolverBase* _copyLp();
+
+
+    virtual int _addCol();
+    virtual int _addRow();
+    virtual void _eraseCol(int i);
+    virtual void _eraseRow(int i);
+    virtual void _getColName(int col, std::string & name) const;
+    virtual void _setColName(int col, const std::string & name);
+    virtual int _colByName(const std::string& name) const;
+    virtual void _setRowCoeffs(int i, ConstRowIterator b, ConstRowIterator e);
+    virtual void _getRowCoeffs(int i, RowIterator b) const;
+    virtual void _setColCoeffs(int i, ConstColIterator b, ConstColIterator e);
+    virtual void _getColCoeffs(int i, ColIterator b) const;
+    virtual void _setCoeff(int row, int col, Value value);
+    virtual Value _getCoeff(int row, int col) const;
+
+    virtual void _setColLowerBound(int i, Value value);
+    virtual Value _getColLowerBound(int i) const;
+    virtual void _setColUpperBound(int i, Value value);
+    virtual Value _getColUpperBound(int i) const;
+
+//     virtual void _setRowLowerBound(int i, Value value);
+//     virtual void _setRowUpperBound(int i, Value value);
+    virtual void _setRowBounds(int i, Value lower, Value upper);
+    virtual void _getRowBounds(int i, Value &lb, Value &ub) const;
+    virtual void _setObjCoeff(int i, Value obj_coef);
+    virtual Value _getObjCoeff(int i) const;
+    virtual void _clearObj();
+
+    
+    virtual SolveExitStatus _solve();
+    virtual Value _getPrimal(int i) const;
+    virtual Value _getDual(int i) const;
+    virtual Value _getPrimalValue() const;
+    virtual bool _isBasicCol(int i) const;
+    
+    virtual SolutionStatus _getPrimalStatus() const;
+    virtual SolutionStatus _getDualStatus() const;
+    virtual ProblemTypes _getProblemType() const;
+
+    
+    virtual void _setMax();
+    virtual void _setMin();
+
+    virtual bool _isMax() const;
+
+  public:
+
+    CPXENVptr cplexEnv() { return env; } 
+    CPXLPptr cplexLp() { return lp; }
+
+  };
+} //END OF NAMESPACE LEMON
+
+#endif //LEMON_LP_CPLEX_H
+
Index: lemon/lp_glpk.cc
===================================================================
--- lemon/lp_glpk.cc	(revision 2622)
+++ lemon/lp_glpk.cc	(revision 2622)
@@ -0,0 +1,643 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\file
+///\brief Implementation of the LEMON-GLPK lp solver interface.
+
+#include <lemon/lp_glpk.h>
+//#include <iostream>
+
+#if GLP_MAJOR_VERSION > 4 || (GLP_MAJOR_VERSION == 4 && GLP_MINOR_VERSION > 15)
+#define LEMON_glp(func) (glp_##func)
+#define LEMON_lpx(func) (lpx_##func)
+
+#define LEMON_GLP(def) (GLP_##def)
+#define LEMON_LPX(def) (LPX_##def)
+
+#else
+
+#define LEMON_glp(func) (lpx_##func)
+#define LEMON_lpx(func) (lpx_##func)
+
+#define LEMON_GLP(def) (LPX_##def)
+#define LEMON_LPX(def) (LPX_##def)
+
+#endif
+
+namespace lemon {
+
+  LpGlpk::LpGlpk() : Parent() {
+    solved = false;
+    rows = _lp_bits::LpId(1);
+    cols = _lp_bits::LpId(1);
+    lp = LEMON_glp(create_prob)();
+    LEMON_glp(create_index)(lp);
+    LEMON_lpx(set_int_parm)(lp, LEMON_LPX(K_DUAL), 1);
+    messageLevel(0);
+  }
+  
+  LpGlpk::LpGlpk(const LpGlpk &glp) : Parent() {
+    solved = false;
+    rows = _lp_bits::LpId(1);
+    cols = _lp_bits::LpId(1);
+    lp = LEMON_glp(create_prob)();
+    LEMON_glp(create_index)(lp);
+    ///\todo control function for this:
+    LEMON_lpx(set_int_parm)(lp, LEMON_LPX(K_DUAL), 1);
+    messageLevel(0);
+    //Coefficient matrix, row bounds
+    LEMON_glp(add_rows)(lp, LEMON_glp(get_num_rows)(glp.lp));
+    LEMON_glp(add_cols)(lp, LEMON_glp(get_num_cols)(glp.lp));
+    int len;
+    std::vector<int> ind(1+LEMON_glp(get_num_cols)(glp.lp));
+    std::vector<Value> val(1+LEMON_glp(get_num_cols)(glp.lp));
+    for (int i=1;i<=LEMON_glp(get_num_rows)(glp.lp);++i)
+      {
+	len=LEMON_glp(get_mat_row)(glp.lp,i,&*ind.begin(),&*val.begin());
+	LEMON_glp(set_mat_row)(lp, i,len,&*ind.begin(),&*val.begin());
+	LEMON_glp(set_row_bnds)(lp,i,
+				LEMON_glp(get_row_type)(glp.lp,i),
+				LEMON_glp(get_row_lb)(glp.lp,i),
+				LEMON_glp(get_row_ub)(glp.lp,i));
+      }
+
+    //Objective function, coloumn bounds
+    LEMON_glp(set_obj_dir)(lp, LEMON_glp(get_obj_dir)(glp.lp));
+    //Objectif function's constant term treated separately
+    LEMON_glp(set_obj_coef)(lp,0,LEMON_glp(get_obj_coef)(glp.lp,0));
+    for (int i=1;i<=LEMON_glp(get_num_cols)(glp.lp);++i)
+      {
+	LEMON_glp(set_obj_coef)(lp,i,
+				LEMON_glp(get_obj_coef)(glp.lp,i));
+	LEMON_glp(set_col_bnds)(lp,i,
+				LEMON_glp(get_col_type)(glp.lp,i),
+				LEMON_glp(get_col_lb)(glp.lp,i),
+				LEMON_glp(get_col_ub)(glp.lp,i));
+      }
+    rows = glp.rows;
+    cols = glp.cols;
+  }
+  
+  LpGlpk::~LpGlpk() {
+    LEMON_glp(delete_prob)(lp);
+  }
+  
+  int LpGlpk::_addCol() { 
+    int i=LEMON_glp(add_cols)(lp, 1);
+    LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(FR), 0.0, 0.0);
+    solved = false;
+    return i;
+  }
+
+  ///\e
+
+
+  LpSolverBase* LpGlpk::_newLp()
+  {
+    LpGlpk* newlp = new LpGlpk;
+    return newlp;
+  }
+  
+  ///\e
+
+  LpSolverBase* LpGlpk::_copyLp()
+  {
+    LpGlpk *newlp = new LpGlpk(*this);
+    return newlp;
+  }
+
+  int LpGlpk::_addRow() { 
+    int i=LEMON_glp(add_rows)(lp, 1);
+    solved = false;
+    return i;
+  }
+
+  
+  void LpGlpk::_eraseCol(int i) {
+    int ca[2];
+    ca[1]=i;
+    LEMON_glp(del_cols)(lp, 1, ca);
+    solved = false;
+  }
+  
+  void LpGlpk::_eraseRow(int i) {
+    int ra[2];
+    ra[1]=i;
+    LEMON_glp(del_rows)(lp, 1, ra);
+    solved = false;
+  }
+
+  void LpGlpk::_getColName(int c, std::string & name) const
+  {
+    
+    const char *n = LEMON_glp(get_col_name)(lp,c);
+    name = n?n:"";
+  }
+  
+  
+  void LpGlpk::_setColName(int c, const std::string & name)
+  {
+    LEMON_glp(set_col_name)(lp,c,const_cast<char*>(name.c_str()));
+
+  }
+
+  int LpGlpk::_colByName(const std::string& name) const
+  {
+    int k = LEMON_glp(find_col)(lp, const_cast<char*>(name.c_str()));
+    return k > 0 ? k : -1; 
+  }
+
+  
+  void LpGlpk::_setRowCoeffs(int i, ConstRowIterator b, ConstRowIterator e) 
+  {
+    std::vector<int> indices;
+    std::vector<Value> values;
+
+    indices.push_back(0);
+    values.push_back(0);
+
+    for(ConstRowIterator it=b; it!=e; ++it) {
+      indices.push_back(it->first);
+      values.push_back(it->second);
+    }
+
+    LEMON_glp(set_mat_row)(lp, i, values.size() - 1, 
+				&indices[0], &values[0]);
+
+    solved = false;
+  }
+
+  void LpGlpk::_getRowCoeffs(int ix, RowIterator b) const
+  {
+    int length = LEMON_glp(get_mat_row)(lp, ix, 0, 0);
+    
+    std::vector<int> indices(length + 1);
+    std::vector<Value> values(length + 1);
+    
+    LEMON_glp(get_mat_row)(lp, ix, &indices[0], &values[0]);
+    
+    for (int i = 1; i <= length; ++i) {
+      *b = std::make_pair(indices[i], values[i]);
+      ++b;
+    }
+  }
+  
+  void LpGlpk::_setColCoeffs(int ix, ConstColIterator b, ConstColIterator e) {
+
+    std::vector<int> indices;
+    std::vector<Value> values;
+
+    indices.push_back(0);
+    values.push_back(0);
+
+    for(ConstColIterator it=b; it!=e; ++it) {
+      indices.push_back(it->first);
+      values.push_back(it->second);
+    }
+    
+    LEMON_glp(set_mat_col)(lp, ix, values.size() - 1, 
+				&indices[0], &values[0]);
+
+    solved = false;
+  }
+
+  void LpGlpk::_getColCoeffs(int ix, ColIterator b) const
+  {
+    int length = LEMON_glp(get_mat_col)(lp, ix, 0, 0);
+    
+    std::vector<int> indices(length + 1);
+    std::vector<Value> values(length + 1);
+    
+    LEMON_glp(get_mat_col)(lp, ix, &indices[0], &values[0]);
+    
+    for (int i = 1; i <= length; ++i) {
+      *b = std::make_pair(indices[i], values[i]);
+      ++b;
+    }
+  }
+
+  void LpGlpk::_setCoeff(int ix, int jx, Value value) 
+  {
+
+    if (LEMON_glp(get_num_cols)(lp) < LEMON_glp(get_num_rows)(lp)) {
+
+      int length=LEMON_glp(get_mat_row)(lp, ix, 0, 0);
+      
+      std::vector<int> indices(length + 2);
+      std::vector<Value> values(length + 2);
+      
+      LEMON_glp(get_mat_row)(lp, ix, &indices[0], &values[0]);
+      
+      //The following code does not suppose that the elements of the
+      //array indices are sorted
+      bool found=false;
+      for (int i = 1; i <= length; ++i) {
+        if (indices[i]==jx){
+          found=true;
+          values[i]=value;
+          break;
+        }
+      }
+      if (!found){
+        ++length;
+        indices[length]=jx;
+        values[length]=value;
+      }
+    
+      LEMON_glp(set_mat_row)(lp, ix, length, &indices[0], &values[0]);
+
+    } else {
+
+      int length=LEMON_glp(get_mat_col)(lp, jx, 0, 0);
+      
+      std::vector<int> indices(length + 2);
+      std::vector<Value> values(length + 2);
+      
+      LEMON_glp(get_mat_col)(lp, jx, &indices[0], &values[0]);
+      
+      //The following code does not suppose that the elements of the
+      //array indices are sorted
+      bool found=false;
+      for (int i = 1; i <= length; ++i) {
+        if (indices[i]==ix){
+          found=true;
+          values[i]=value;
+          break;
+        }
+      }
+      if (!found){
+        ++length;
+        indices[length]=ix;
+        values[length]=value;
+      }
+    
+      LEMON_glp(set_mat_col)(lp, jx, length, &indices[0], &values[0]);
+    }
+
+    solved = false;
+  }
+
+  LpGlpk::Value LpGlpk::_getCoeff(int ix, int jx) const
+  {
+
+    int length=LEMON_glp(get_mat_row)(lp, ix, 0, 0);
+    
+    std::vector<int> indices(length + 1);
+    std::vector<Value> values(length + 1);
+    
+    LEMON_glp(get_mat_row)(lp, ix, &indices[0], &values[0]);
+    
+    //The following code does not suppose that the elements of the
+    //array indices are sorted
+    for (int i = 1; i <= length; ++i) {
+      if (indices[i]==jx){
+	return values[i];
+      }
+    }
+    return 0;
+
+  }
+
+
+  void LpGlpk::_setColLowerBound(int i, Value lo)
+  {
+    if (lo==INF) {
+      //FIXME error
+    }
+    int b=LEMON_glp(get_col_type)(lp, i);
+    double up=LEMON_glp(get_col_ub)(lp, i);	
+    if (lo==-INF) {
+      switch (b) {
+      case LEMON_GLP(FR):
+      case LEMON_GLP(LO):
+	LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(FR), lo, up);
+	break;
+      case LEMON_GLP(UP):
+	break;
+      case LEMON_GLP(DB):
+      case LEMON_GLP(FX):
+	LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(UP), lo, up);
+	break;
+      default: ;
+	//FIXME error
+      }
+    } else {
+      switch (b) {
+      case LEMON_GLP(FR):
+      case LEMON_GLP(LO):
+	LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(LO), lo, up);
+	break;
+      case LEMON_GLP(UP):	  
+      case LEMON_GLP(DB):
+      case LEMON_GLP(FX):
+	if (lo==up) 
+	  LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(FX), lo, up);
+	else 
+	  LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(DB), lo, up);
+	break;
+      default: ;
+	//FIXME error
+      }
+    }
+
+    solved = false;
+  }
+
+  LpGlpk::Value LpGlpk::_getColLowerBound(int i) const
+  {
+    int b=LEMON_glp(get_col_type)(lp, i);
+      switch (b) {
+      case LEMON_GLP(LO):
+      case LEMON_GLP(DB):
+      case LEMON_GLP(FX):
+	return LEMON_glp(get_col_lb)(lp, i);	
+      default: ;
+	return -INF;
+      }
+  }
+  
+  void LpGlpk::_setColUpperBound(int i, Value up)
+  {
+    if (up==-INF) {
+      //FIXME error
+    }
+    int b=LEMON_glp(get_col_type)(lp, i);
+    double lo=LEMON_glp(get_col_lb)(lp, i);
+    if (up==INF) {
+      switch (b) {
+      case LEMON_GLP(FR):
+      case LEMON_GLP(LO):
+	break;
+      case LEMON_GLP(UP):
+	LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(FR), lo, up);
+	break;
+      case LEMON_GLP(DB):
+      case LEMON_GLP(FX):
+	LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(LO), lo, up);
+	break;
+      default: ;
+	//FIXME error
+      }
+    } else {
+      switch (b) {
+      case LEMON_GLP(FR):
+	LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(UP), lo, up);
+	break;
+      case LEMON_GLP(UP):
+	LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(UP), lo, up);
+	break;
+      case LEMON_GLP(LO):
+      case LEMON_GLP(DB):
+      case LEMON_GLP(FX):
+	if (lo==up) 
+	  LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(FX), lo, up);
+	else 
+	  LEMON_glp(set_col_bnds)(lp, i, LEMON_GLP(DB), lo, up);
+	break;
+      default: ;
+	//FIXME error
+      }
+    }
+
+    solved = false;
+  }
+
+  LpGlpk::Value LpGlpk::_getColUpperBound(int i) const
+  {
+    int b=LEMON_glp(get_col_type)(lp, i);
+      switch (b) {
+      case LEMON_GLP(UP):
+      case LEMON_GLP(DB):
+      case LEMON_GLP(FX):
+	return LEMON_glp(get_col_ub)(lp, i);	
+      default: ;
+	return INF;
+      }
+  }
+  
+  void LpGlpk::_setRowBounds(int i, Value lb, Value ub)
+  {
+    //Bad parameter
+    if (lb==INF || ub==-INF) {
+      //FIXME error
+    }
+
+    if (lb == -INF){
+      if (ub == INF){
+	LEMON_glp(set_row_bnds)(lp, i, LEMON_GLP(FR), lb, ub);
+      }
+      else{
+	LEMON_glp(set_row_bnds)(lp, i, LEMON_GLP(UP), lb, ub);
+      }
+    }
+    else{
+      if (ub==INF){
+	LEMON_glp(set_row_bnds)(lp, i, LEMON_GLP(LO), lb, ub);
+
+      }
+      else{
+	if (lb == ub){
+	  LEMON_glp(set_row_bnds)(lp, i, LEMON_GLP(FX), lb, ub);
+	}
+	else{
+	  LEMON_glp(set_row_bnds)(lp, i, LEMON_GLP(DB), lb, ub);
+	}
+      }
+    }
+
+    solved = false;
+  }
+
+  void LpGlpk::_getRowBounds(int i, Value &lb, Value &ub) const
+  {
+
+    int b=LEMON_glp(get_row_type)(lp, i);
+    switch (b) {
+    case LEMON_GLP(FR):
+    case LEMON_GLP(UP):
+      lb = -INF;
+	break;
+    default: 
+      lb=LEMON_glp(get_row_lb)(lp, i);
+    }
+
+    switch (b) {
+    case LEMON_GLP(FR):
+    case LEMON_GLP(LO):
+      ub = INF;
+	break;
+    default: 
+      ub=LEMON_glp(get_row_ub)(lp, i);
+    }
+    
+  }
+  
+  void LpGlpk::_setObjCoeff(int i, Value obj_coef)
+  {
+    //i=0 means the constant term (shift)
+    LEMON_glp(set_obj_coef)(lp, i, obj_coef);
+
+    solved = false;
+  }
+
+  LpGlpk::Value LpGlpk::_getObjCoeff(int i) const {
+    //i=0 means the constant term (shift)
+    return LEMON_glp(get_obj_coef)(lp, i);
+  }
+
+  void LpGlpk::_clearObj()
+  {
+    for (int i=0;i<=LEMON_glp(get_num_cols)(lp);++i){
+      LEMON_glp(set_obj_coef)(lp, i, 0);
+    }
+
+    solved = false;
+  }
+
+  LpGlpk::SolveExitStatus LpGlpk::_solve()
+  {
+    // A way to check the problem to be solved
+    //LEMON_glp(write_cpxlp(lp,"naittvan.cpx");    
+
+    LEMON_lpx(std_basis)(lp);
+    int i =  LEMON_lpx(simplex)(lp);
+    
+    switch (i) {
+    case LEMON_LPX(E_OK): 
+      solved = true;
+      return SOLVED;
+    default:
+      return UNSOLVED;
+    }
+  }
+
+  LpGlpk::Value LpGlpk::_getPrimal(int i) const
+  {
+    return LEMON_glp(get_col_prim)(lp,i);
+  }
+
+  LpGlpk::Value LpGlpk::_getDual(int i) const
+  {
+    return LEMON_glp(get_row_dual)(lp,i);
+  }
+  
+  LpGlpk::Value LpGlpk::_getPrimalValue() const
+  {
+    return LEMON_glp(get_obj_val)(lp);
+  }
+  bool LpGlpk::_isBasicCol(int i) const
+  {
+    return (LEMON_glp(get_col_stat)(lp, i)==LEMON_GLP(BS));
+  }
+  
+ 
+  LpGlpk::SolutionStatus LpGlpk::_getPrimalStatus() const
+  {
+    if (!solved) return UNDEFINED;
+    int stat=  LEMON_lpx(get_status)(lp);
+    switch (stat) {
+    case LEMON_LPX(UNDEF)://Undefined (no solve has been run yet)
+      return UNDEFINED;
+    case LEMON_LPX(NOFEAS)://There is no feasible solution (primal, I guess)
+    case LEMON_LPX(INFEAS)://Infeasible 
+      return INFEASIBLE;
+    case LEMON_LPX(UNBND)://Unbounded
+      return INFINITE;
+    case LEMON_LPX(FEAS)://Feasible
+      return FEASIBLE;
+    case LEMON_LPX(OPT)://Feasible
+      return OPTIMAL;
+    default:
+      return UNDEFINED; //to avoid gcc warning
+      //FIXME error
+    }
+  }
+
+  LpGlpk::SolutionStatus LpGlpk::_getDualStatus() const
+  {
+    if (!solved) return UNDEFINED;
+    switch (LEMON_lpx(get_dual_stat)(lp)) {
+    case LEMON_LPX(D_UNDEF)://Undefined (no solve has been run yet)
+      return UNDEFINED;
+    case LEMON_LPX(D_NOFEAS)://There is no dual feasible solution 
+//    case LEMON_LPX(D_INFEAS://Infeasible 
+      return INFEASIBLE;
+    case LEMON_LPX(D_FEAS)://Feasible    
+      switch (LEMON_lpx(get_status)(lp)) {
+      case LEMON_LPX(NOFEAS):
+	return INFINITE;
+      case LEMON_LPX(OPT):
+	return OPTIMAL;
+      default:
+	return FEASIBLE;
+      }
+    default:
+      return UNDEFINED; //to avoid gcc warning
+      //FIXME error
+    }
+  }
+
+  LpGlpk::ProblemTypes LpGlpk::_getProblemType() const
+  {
+    if (!solved) return UNKNOWN;
+      //int stat=  LEMON_glp(get_status(lp);
+    int statp=  LEMON_lpx(get_prim_stat)(lp);
+    int statd=  LEMON_lpx(get_dual_stat)(lp);
+    if (statp==LEMON_LPX(P_FEAS) && statd==LEMON_LPX(D_FEAS))
+	return PRIMAL_DUAL_FEASIBLE;
+    if (statp==LEMON_LPX(P_FEAS) && statd==LEMON_LPX(D_NOFEAS))
+	return PRIMAL_FEASIBLE_DUAL_INFEASIBLE;
+    if (statp==LEMON_LPX(P_NOFEAS) && statd==LEMON_LPX(D_FEAS))
+	return PRIMAL_INFEASIBLE_DUAL_FEASIBLE;
+    if (statp==LEMON_LPX(P_NOFEAS) && statd==LEMON_LPX(D_NOFEAS))
+	return PRIMAL_DUAL_INFEASIBLE;
+    //In all other cases
+    return UNKNOWN;
+  }
+
+  void LpGlpk::_setMax()
+  {
+    solved = false;
+    LEMON_glp(set_obj_dir)(lp, LEMON_GLP(MAX));
+  }
+
+  void LpGlpk::_setMin()
+  {
+    solved = false;
+    LEMON_glp(set_obj_dir)(lp, LEMON_GLP(MIN));
+  }
+
+  bool LpGlpk::_isMax() const
+  {
+    return (LEMON_glp(get_obj_dir)(lp)==LEMON_GLP(MAX));
+  }
+
+ 
+
+  void LpGlpk::messageLevel(int m)
+  {
+    LEMON_lpx(set_int_parm)(lp, LEMON_LPX(K_MSGLEV), m);
+  }
+
+  void LpGlpk::presolver(bool b)
+  {
+    LEMON_lpx(set_int_parm)(lp, LEMON_LPX(K_PRESOL), b);
+  }
+
+ 
+} //END OF NAMESPACE LEMON
Index: lemon/lp_glpk.h
===================================================================
--- lemon/lp_glpk.h	(revision 2605)
+++ lemon/lp_glpk.h	(revision 2605)
@@ -0,0 +1,133 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_LP_GLPK_H
+#define LEMON_LP_GLPK_H
+
+///\file
+///\brief Header of the LEMON-GLPK lp solver interface.
+///\ingroup lp_group
+
+#include <lemon/lp_base.h>
+extern "C" {
+#include <glpk.h>
+}
+
+namespace lemon {
+
+
+  /// \brief Interface for the GLPK LP solver
+  /// 
+  /// This class implements an interface for the GLPK LP solver.
+  ///\ingroup lp_group
+  class LpGlpk : virtual public LpSolverBase {
+  protected:
+    LPX* lp;
+    bool solved;
+    
+  public:
+    
+    typedef LpSolverBase Parent;
+    
+    LpGlpk();
+    LpGlpk(const LpGlpk &);
+    ~LpGlpk();
+    
+  protected:
+    virtual LpSolverBase* _newLp();
+    virtual LpSolverBase* _copyLp();
+
+    virtual int _addCol();
+    virtual int _addRow();
+    virtual void _eraseCol(int i);
+    virtual void _eraseRow(int i);
+    virtual void _getColName(int col, std::string & name) const;
+    virtual void _setColName(int col, const std::string & name);
+    virtual int _colByName(const std::string& name) const;
+    virtual void _setRowCoeffs(int i, ConstRowIterator b, ConstRowIterator e);
+    virtual void _getRowCoeffs(int i, RowIterator b) const;
+    virtual void _setColCoeffs(int i, ConstColIterator b, ConstColIterator e);
+    virtual void _getColCoeffs(int i, ColIterator b) const;
+    virtual void _setCoeff(int row, int col, Value value);
+    virtual Value _getCoeff(int row, int col) const;
+
+    virtual void _setColLowerBound(int i, Value value);
+    virtual Value _getColLowerBound(int i) const;
+    virtual void _setColUpperBound(int i, Value value);
+    virtual Value _getColUpperBound(int i) const;
+
+    virtual void _setRowBounds(int i, Value lower, Value upper);
+    virtual void _getRowBounds(int i, Value &lb, Value &ub) const;
+    virtual void _setObjCoeff(int i, Value obj_coef);
+    virtual Value _getObjCoeff(int i) const;
+    virtual void _clearObj();
+
+    ///\e
+    
+    ///\todo It should be clarified
+    ///
+    virtual SolveExitStatus _solve();
+    virtual Value _getPrimal(int i) const;
+    virtual Value _getDual(int i) const;
+    virtual Value _getPrimalValue() const;
+    virtual bool _isBasicCol(int i) const;
+    ///\e
+    
+    ///\todo It should be clarified
+    ///
+    virtual SolutionStatus _getPrimalStatus() const;
+    virtual SolutionStatus _getDualStatus() const;
+    virtual ProblemTypes _getProblemType() const;
+
+    virtual void _setMax();
+    virtual void _setMin();
+
+    virtual bool _isMax() const;
+
+  public:
+    ///Set the verbosity of the messages
+
+    ///Set the verbosity of the messages
+    ///
+    ///\param m is the level of the messages output by the solver routines.
+    ///The possible values are:
+    ///- 0 --- no output (default value)
+    ///- 1 --- error messages only
+    ///- 2 --- normal output
+    ///- 3 --- full output (includes informational messages)
+    void messageLevel(int m);
+    ///Turns on or off the presolver
+
+    ///Turns on (\c b is \c true) or off (\c b is \c false) the presolver
+    ///
+    ///The presolver is off by default.
+    void presolver(bool b);
+
+    ///Pointer to the underlying GLPK data structure.
+    LPX *lpx() {return lp;}
+
+    ///Returns the constraint identifier understood by GLPK.
+    int lpxRow(Row r) { return _lpId(r); }
+
+    ///Returns the variable identifier understood by GLPK.
+    int lpxCol(Col c) { return _lpId(c); }
+  };
+} //END OF NAMESPACE LEMON
+
+#endif //LEMON_LP_GLPK_H
+
Index: lemon/lp_skeleton.cc
===================================================================
--- lemon/lp_skeleton.cc	(revision 2605)
+++ lemon/lp_skeleton.cc	(revision 2605)
@@ -0,0 +1,187 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/lp_skeleton.h>
+
+///\file
+///\brief A skeleton file to implement LP solver interfaces
+namespace lemon {
+  
+  LpSolverBase* LpSkeleton::_newLp()
+  {
+    LpSolverBase *tmp=0;
+    return tmp;
+  }
+  
+  LpSolverBase* LpSkeleton::_copyLp()
+  {
+    LpSolverBase *tmp=0;
+    return tmp;
+  }
+
+  int LpSkeleton::_addCol()
+  {
+    return ++col_num;
+  }
+  
+  int LpSkeleton::_addRow() 
+  {
+    return ++row_num;
+  }
+  
+  void LpSkeleton::_eraseCol(int ) {
+  }
+  
+  void LpSkeleton::_eraseRow(int) {
+  }
+
+  void LpSkeleton::_getColName(int, std::string &) const {
+  }
+  
+  
+  void LpSkeleton::_setColName(int, const std::string &) {
+  }
+
+  int LpSkeleton::_colByName(const std::string&) const { return -1; }
+  
+  
+  void LpSkeleton::_setRowCoeffs(int, ConstRowIterator, ConstRowIterator) {
+  }
+
+  void LpSkeleton::_getRowCoeffs(int, RowIterator) const {
+  }
+  
+  void LpSkeleton::_setColCoeffs(int, ConstColIterator, ConstColIterator) {
+  }
+
+  void LpSkeleton::_getColCoeffs(int, ColIterator) const {
+  }
+
+  void LpSkeleton::_setCoeff(int, int, Value )
+  {
+  }
+
+  LpSkeleton::Value LpSkeleton::_getCoeff(int, int) const
+  {
+    return 0;
+  }
+
+
+  void LpSkeleton::_setColLowerBound(int, Value)
+  {
+  }
+  
+  LpSkeleton::Value LpSkeleton::_getColLowerBound(int) const
+  {
+    return 0;
+  }
+  
+  void LpSkeleton::_setColUpperBound(int, Value)
+  {
+  }
+
+  LpSkeleton::Value LpSkeleton::_getColUpperBound(int) const
+  {
+    return 0;
+  }
+  
+//   void LpSkeleton::_setRowLowerBound(int, Value)
+//   {
+//   }
+  
+//   void LpSkeleton::_setRowUpperBound(int, Value)
+//   {
+//   }
+
+  void LpSkeleton::_setRowBounds(int, Value, Value)
+  {
+  }
+
+  void LpSkeleton::_getRowBounds(int, Value&, Value&) const
+  {
+  }
+  
+  void LpSkeleton::_setObjCoeff(int, Value)
+  {
+  }
+
+  LpSkeleton::Value LpSkeleton::_getObjCoeff(int) const
+  {
+    return 0;
+  }
+
+  void LpSkeleton::_setMax()
+  {
+  }
+
+  void LpSkeleton::_setMin()
+  {
+  }
+
+  bool LpSkeleton::_isMax() const
+  {
+    return true;
+  }
+
+
+  void LpSkeleton::_clearObj()
+  {
+  }
+  
+  LpSkeleton::SolveExitStatus LpSkeleton::_solve()
+  {
+    return SOLVED;
+  }
+
+  LpSkeleton::Value LpSkeleton::_getPrimal(int) const
+  {
+    return 0;
+  }
+  
+  LpSkeleton::Value LpSkeleton::_getDual(int) const
+  {
+    return 0;
+  }
+  
+  LpSkeleton::Value LpSkeleton::_getPrimalValue() const
+  {
+    return 0;
+  }
+  
+  LpSkeleton::SolutionStatus LpSkeleton::_getPrimalStatus() const
+  {
+    return UNDEFINED;
+  }
+
+  LpSkeleton::SolutionStatus LpSkeleton::_getDualStatus() const
+  {
+    return UNDEFINED;
+  }
+
+  LpSkeleton::ProblemTypes LpSkeleton::_getProblemType() const
+  {
+    return UNKNOWN;
+  }
+
+  bool LpSkeleton::_isBasicCol(int) const
+  {
+    return true;
+  }
+
+} //namespace lemon
+
Index: lemon/lp_skeleton.h
===================================================================
--- lemon/lp_skeleton.h	(revision 2605)
+++ lemon/lp_skeleton.h	(revision 2605)
@@ -0,0 +1,183 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_LP_SKELETON
+#define LEMON_LP_SKELETON
+
+#include <lemon/lp_base.h>
+
+///\file
+///\brief A skeleton file to implement LP solver interfaces
+namespace lemon {
+
+  ///A skeleton class to implement LP solver interfaces
+  class LpSkeleton :public LpSolverBase {
+    int col_num,row_num;
+    
+  protected:
+
+    ///\e
+    virtual LpSolverBase* _newLp();
+    ///\e
+    virtual LpSolverBase* _copyLp();
+    /// \e
+    virtual int _addCol();
+    /// \e
+    virtual int _addRow();
+    /// \e
+    virtual void _eraseCol(int i);
+    /// \e
+    virtual void _eraseRow(int i);
+    /// \e
+    virtual void _getColName(int col, std::string & name) const;
+    /// \e
+    virtual void _setColName(int col, const std::string & name);
+    /// \e
+    virtual int _colByName(const std::string& name) const;
+
+    /// \e
+    virtual void _setRowCoeffs(int i, ConstRowIterator b, ConstRowIterator e);
+    /// \e
+    virtual void _getRowCoeffs(int i, RowIterator b) const;
+    /// \e
+    virtual void _setColCoeffs(int i, ConstColIterator b, ConstColIterator e);
+    /// \e
+    virtual void _getColCoeffs(int i, ColIterator b) const;
+    
+    /// Set one element of the coefficient matrix
+    virtual void _setCoeff(int row, int col, Value value);
+
+    /// Get one element of the coefficient matrix
+    virtual Value _getCoeff(int row, int col) const;
+
+    /// The lower bound of a variable (column) have to be given by an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value or -\ref INF.
+    virtual void _setColLowerBound(int i, Value value);
+    /// \e
+
+    /// The lower bound of a variable (column) is an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value or -\ref INF.
+    virtual Value _getColLowerBound(int i) const;
+
+    /// The upper bound of a variable (column) have to be given by an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value or \ref INF.
+    virtual void _setColUpperBound(int i, Value value);
+    /// \e
+
+    /// The upper bound of a variable (column) is an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value or \ref INF.
+    virtual Value _getColUpperBound(int i) const;
+
+//     /// The lower bound of a linear expression (row) have to be given by an 
+//     /// extended number of type Value, i.e. a finite number of type 
+//     /// Value or -\ref INF.
+//     virtual void _setRowLowerBound(int i, Value value);
+//     /// \e
+
+//     /// The upper bound of a linear expression (row) have to be given by an 
+//     /// extended number of type Value, i.e. a finite number of type 
+//     /// Value or \ref INF.
+//     virtual void _setRowUpperBound(int i, Value value);
+
+    /// The lower and upper bound of a linear expression (row) have to be 
+    /// given by an 
+    /// extended number of type Value, i.e. a finite number of type 
+    /// Value or +/-\ref INF.
+    virtual void _setRowBounds(int i, Value lb, Value ub);
+    /// \e
+
+
+    /// The lower and the upper bound of
+    /// a constraint (row) are  
+    /// extended numbers of type Value, i.e.  finite numbers of type 
+    /// Value, -\ref INF or \ref INF. 
+    virtual void _getRowBounds(int i, Value &lb, Value &ub) const;
+    /// \e
+
+
+    /// \e
+    virtual void _clearObj();
+    /// \e
+    virtual void _setObjCoeff(int i, Value obj_coef);
+
+    /// \e
+    virtual Value _getObjCoeff(int i) const;
+
+    ///\e
+    
+    ///\bug Wrong interface
+    ///
+    virtual SolveExitStatus _solve();
+
+    ///\e
+
+    ///\bug Wrong interface
+    ///
+    virtual Value _getPrimal(int i) const;
+
+    ///\e
+
+    ///\bug Wrong interface
+    ///
+    virtual Value _getDual(int i) const;
+
+    ///\e
+
+    ///\bug Wrong interface
+    ///
+    virtual Value _getPrimalValue() const;
+
+    ///\e
+
+    ///\bug Wrong interface
+    ///
+    virtual SolutionStatus _getPrimalStatus() const;
+
+    ////e
+    virtual SolutionStatus _getDualStatus() const;
+
+
+    ///\e
+    virtual ProblemTypes _getProblemType() const;
+
+    ///\e
+    virtual void _setMax();
+    ///\e
+    virtual void _setMin();
+
+    ///\e
+    virtual bool _isMax() const;
+
+
+
+    ///\e
+    virtual bool _isBasicCol(int i) const;
+
+    
+
+  public:
+    LpSkeleton() : LpSolverBase(), col_num(0), row_num(0) {}
+  };  
+
+} //namespace lemon
+
+#endif // LEMON_LP_SKELETON
Index: lemon/lp_soplex.cc
===================================================================
--- lemon/lp_soplex.cc	(revision 2605)
+++ lemon/lp_soplex.cc	(revision 2605)
@@ -0,0 +1,316 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<iostream>
+#include<lemon/lp_soplex.h>
+
+#include <soplex/soplex.h>
+
+
+///\file
+///\brief Implementation of the LEMON-SOPLEX lp solver interface.
+namespace lemon {
+  
+  LpSoplex::LpSoplex() : LpSolverBase() {
+    rows.setIdHandler(relocateIdHandler);
+    cols.setIdHandler(relocateIdHandler);
+    soplex = new soplex::SoPlex;
+    solved = false;
+  }
+  
+  LpSoplex::~LpSoplex() {
+    delete soplex;
+  }
+
+  LpSoplex::LpSoplex(const LpSoplex& lp) : LpSolverBase() {
+    rows = lp.rows;
+    rows.setIdHandler(relocateIdHandler);
+
+    cols = lp.cols;
+    cols.setIdHandler(relocateIdHandler);
+
+    soplex = new soplex::SoPlex;
+    (*static_cast<soplex::SPxLP*>(soplex)) = *(lp.soplex);
+
+    colNames = lp.colNames;
+    invColNames = lp.invColNames;
+
+    primal_value = lp.primal_value;
+    dual_value = lp.dual_value;
+
+  }
+  
+  LpSolverBase* LpSoplex::_newLp() {
+    LpSoplex* newlp = new LpSoplex();
+    return newlp;
+  }
+
+  LpSolverBase* LpSoplex::_copyLp() {
+    LpSoplex* newlp = new LpSoplex(*this);
+    return newlp;
+  }
+
+  int LpSoplex::_addCol() {
+    soplex::LPCol c;
+    c.setLower(-soplex::infinity);
+    c.setUpper(soplex::infinity);
+    soplex->addCol(c);
+
+    colNames.push_back(std::string());
+    primal_value.push_back(0.0);
+    solved = false;
+
+    return soplex->nCols() - 1;
+  }
+
+  int LpSoplex::_addRow() {
+    soplex::LPRow r;
+    r.setLhs(-soplex::infinity);
+    r.setRhs(soplex::infinity);
+    soplex->addRow(r);
+
+    dual_value.push_back(0.0);
+    solved = false;
+
+    return soplex->nRows() - 1;
+  }
+
+
+  void LpSoplex::_eraseCol(int i) {
+    soplex->removeCol(i);
+    invColNames.erase(colNames[i]);
+    colNames[i] = colNames.back();
+    invColNames[colNames.back()] = i;
+    colNames.pop_back();
+    primal_value[i] = primal_value.back();
+    primal_value.pop_back();
+    solved = false;
+  }
+  
+  void LpSoplex::_eraseRow(int i) {
+    soplex->removeRow(i);
+    dual_value[i] = dual_value.back();
+    dual_value.pop_back();
+    solved = false;
+  }
+  
+  void LpSoplex::_getColName(int c, std::string &name) const {
+    name = colNames[c]; 
+  }
+  
+  void LpSoplex::_setColName(int c, const std::string &name) {
+    invColNames.erase(colNames[c]);
+    colNames[c] = name; 
+    if (!name.empty()) {
+      invColNames.insert(std::make_pair(name, c));
+    }
+  }
+
+  int LpSoplex::_colByName(const std::string& name) const {
+    std::map<std::string, int>::const_iterator it =
+      invColNames.find(name);
+    if (it != invColNames.end()) {
+      return it->second;
+    } else {
+      return -1;
+    }
+  }
+  
+
+  void LpSoplex::_setRowCoeffs(int i, ConstRowIterator b, ConstRowIterator e) {
+    for (int j = 0; j < soplex->nCols(); ++j) {
+      soplex->changeElement(i, j, 0.0);
+    }
+    for(ConstRowIterator it = b; it != e; ++it) {
+      soplex->changeElement(i, it->first, it->second);
+    }
+    solved = false;
+  }
+
+  void LpSoplex::_getRowCoeffs(int i, RowIterator b) const {
+    const soplex::SVector& vec = soplex->rowVector(i);
+    for (int k = 0; k < vec.size(); ++k) {
+      *b = std::make_pair(vec.index(k), vec.value(k));
+      ++b;
+    }
+  }
+  
+  void LpSoplex::_setColCoeffs(int j, ConstColIterator b, ConstColIterator e) {
+    for (int i = 0; i < soplex->nRows(); ++i) {
+      soplex->changeElement(i, j, 0.0);
+    }
+    for(ConstColIterator it = b; it != e; ++it) {
+      soplex->changeElement(it->first, j, it->second);
+    }
+    solved = false;
+  }
+
+  void LpSoplex::_getColCoeffs(int i, ColIterator b) const {
+    const soplex::SVector& vec = soplex->colVector(i);
+    for (int k = 0; k < vec.size(); ++k) {
+      *b = std::make_pair(vec.index(k), vec.value(k));
+      ++b;
+    }
+  }
+  
+  void LpSoplex::_setCoeff(int i, int j, Value value) {
+    soplex->changeElement(i, j, value);
+    solved = false;
+  }
+
+  LpSoplex::Value LpSoplex::_getCoeff(int i, int j) const {
+    return soplex->rowVector(i)[j];
+  }
+
+  void LpSoplex::_setColLowerBound(int i, Value value) {
+    soplex->changeLower(i, value != -INF ? value : -soplex::infinity); 
+    solved = false;
+  }
+  
+  LpSoplex::Value LpSoplex::_getColLowerBound(int i) const {
+    double value = soplex->lower(i);
+    return value != -soplex::infinity ? value : -INF;
+  }
+
+  void LpSoplex::_setColUpperBound(int i, Value value) {
+    soplex->changeUpper(i, value != INF ? value : soplex::infinity); 
+    solved = false;
+  }
+
+  LpSoplex::Value LpSoplex::_getColUpperBound(int i) const {
+    double value = soplex->upper(i);
+    return value != soplex::infinity ? value : INF;
+  }
+
+  void LpSoplex::_setRowBounds(int i, Value lb, Value ub) {
+    soplex->changeRange(i, lb != -INF ? lb : -soplex::infinity,
+                        ub != INF ? ub : soplex::infinity);
+    solved = false;
+  }
+  void LpSoplex::_getRowBounds(int i, Value &lower, Value &upper) const {
+    lower = soplex->lhs(i);
+    if (lower == -soplex::infinity) lower = -INF;
+    upper = soplex->rhs(i);
+    if (upper == -soplex::infinity) upper = INF;
+  }
+
+  void LpSoplex::_setObjCoeff(int i, Value obj_coef) {
+    soplex->changeObj(i, obj_coef);
+    solved = false;
+  }
+
+  LpSoplex::Value LpSoplex::_getObjCoeff(int i) const {
+    return soplex->obj(i);
+  }
+
+  void LpSoplex::_clearObj() {
+    for (int i = 0; i < soplex->nCols(); ++i) {
+      soplex->changeObj(i, 0.0);
+    }
+    solved = false;
+  }
+
+  LpSoplex::SolveExitStatus LpSoplex::_solve() {
+    soplex::SPxSolver::Status status = soplex->solve();
+
+    soplex::Vector pv(primal_value.size(), &primal_value[0]);
+    soplex->getPrimal(pv);
+
+    soplex::Vector dv(dual_value.size(), &dual_value[0]);
+    soplex->getDual(dv);
+
+    switch (status) {
+    case soplex::SPxSolver::OPTIMAL:
+    case soplex::SPxSolver::INFEASIBLE:
+    case soplex::SPxSolver::UNBOUNDED:
+      solved = true;
+      return SOLVED;
+    default:
+      return UNSOLVED;
+    }
+  }
+
+  LpSoplex::Value LpSoplex::_getPrimal(int i) const {
+    return primal_value[i];
+  }
+
+  LpSoplex::Value LpSoplex::_getDual(int i) const {
+    return dual_value[i];
+  }
+  
+  LpSoplex::Value LpSoplex::_getPrimalValue() const {
+    return soplex->objValue();
+  }
+
+  bool LpSoplex::_isBasicCol(int i) const {
+    return soplex->getBasisColStatus(i) == soplex::SPxSolver::BASIC;
+  }  
+
+  LpSoplex::SolutionStatus LpSoplex::_getPrimalStatus() const {
+    if (!solved) return UNDEFINED;
+    switch (soplex->status()) {
+    case soplex::SPxSolver::OPTIMAL:
+      return OPTIMAL;
+    case soplex::SPxSolver::UNBOUNDED:
+      return INFINITE;
+    case soplex::SPxSolver::INFEASIBLE:
+      return INFEASIBLE;
+    default:
+      return UNDEFINED;
+    }
+  }
+
+  LpSoplex::SolutionStatus LpSoplex::_getDualStatus() const {
+    if (!solved) return UNDEFINED;
+    switch (soplex->status()) {
+    case soplex::SPxSolver::OPTIMAL:
+      return OPTIMAL;
+    case soplex::SPxSolver::UNBOUNDED:
+      return INFEASIBLE;
+    default:
+      return UNDEFINED;
+    }
+  }
+
+  LpSoplex::ProblemTypes LpSoplex::_getProblemType() const {
+    if (!solved) return UNKNOWN;
+    switch (soplex->status()) {
+    case soplex::SPxSolver::OPTIMAL:
+      return PRIMAL_DUAL_FEASIBLE;
+    case soplex::SPxSolver::UNBOUNDED:
+      return PRIMAL_FEASIBLE_DUAL_INFEASIBLE;
+    default:
+      return UNKNOWN;
+    }
+  }
+
+  void LpSoplex::_setMax() {
+    soplex->changeSense(soplex::SPxSolver::MAXIMIZE);
+    solved = false;
+  }
+  void LpSoplex::_setMin() {
+    soplex->changeSense(soplex::SPxSolver::MINIMIZE);
+    solved = false;
+  }
+  bool LpSoplex::_isMax() const {
+    return soplex->spxSense() == soplex::SPxSolver::MAXIMIZE;
+  }
+
+  
+} //namespace lemon
+
Index: lemon/lp_soplex.h
===================================================================
--- lemon/lp_soplex.h	(revision 2605)
+++ lemon/lp_soplex.h	(revision 2605)
@@ -0,0 +1,120 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_LP_SOPLEX_H
+#define LEMON_LP_SOPLEX_H
+
+///\file
+///\brief Header of the LEMON-SOPLEX lp solver interface.
+
+#include <vector>
+#include <string>
+
+#include <lemon/lp_base.h>
+
+// Forward declaration
+namespace soplex {
+  class SoPlex;
+}
+
+namespace lemon {
+
+  /// \ingroup lp_group
+  ///
+  /// \brief Interface for the SOPLEX solver
+  /// 
+  /// This class implements an interface for the SoPlex LP solver.
+  /// The SoPlex library is an object oriented lp solver library
+  /// developed at the Konrad-Zuse-Zentrum für Informationstechnik
+  /// Berlin (ZIB). You can find detailed information about it at the
+  /// <tt>http://soplex.zib.de</tt> address.
+  class LpSoplex :virtual public LpSolverBase {
+  protected:
+
+    _lp_bits::RelocateIdHandler relocateIdHandler;
+
+    soplex::SoPlex* soplex;
+    bool solved;
+
+    std::vector<std::string> colNames;
+    std::map<std::string, int> invColNames;
+
+    std::vector<Value> primal_value;
+    std::vector<Value> dual_value;
+
+
+  public:
+
+    typedef LpSolverBase Parent;
+    
+
+    /// \e
+    LpSoplex();
+    /// \e
+    LpSoplex(const LpSoplex&);
+    /// \e
+    ~LpSoplex();
+
+  protected:
+
+    virtual LpSolverBase* _newLp();
+    virtual LpSolverBase* _copyLp();
+
+    virtual int _addCol();
+    virtual int _addRow();
+    virtual void _eraseCol(int i);
+    virtual void _eraseRow(int i);
+    virtual void _getColName(int col, std::string & name) const;
+    virtual void _setColName(int col, const std::string & name);
+    virtual int _colByName(const std::string& name) const;
+    virtual void _setRowCoeffs(int i, ConstRowIterator b, ConstRowIterator e);
+    virtual void _getRowCoeffs(int i, RowIterator b) const;
+    virtual void _setColCoeffs(int i, ConstColIterator b, ConstColIterator e);
+    virtual void _getColCoeffs(int i, ColIterator b) const;
+    virtual void _setCoeff(int row, int col, Value value);
+    virtual Value _getCoeff(int row, int col) const;
+    virtual void _setColLowerBound(int i, Value value);
+    virtual Value _getColLowerBound(int i) const;
+    virtual void _setColUpperBound(int i, Value value);
+    virtual Value _getColUpperBound(int i) const;
+    virtual void _setRowBounds(int i, Value lower, Value upper);
+    virtual void _getRowBounds(int i, Value &lower, Value &upper) const;
+    virtual void _setObjCoeff(int i, Value obj_coef);
+    virtual Value _getObjCoeff(int i) const;
+    virtual void _clearObj();
+    
+    virtual SolveExitStatus _solve();
+    virtual Value _getPrimal(int i) const;
+    virtual Value _getDual(int i) const;
+    virtual Value _getPrimalValue() const;
+    virtual bool _isBasicCol(int i) const;
+    
+    virtual SolutionStatus _getPrimalStatus() const;
+    virtual SolutionStatus _getDualStatus() const;
+    virtual ProblemTypes _getProblemType() const;
+
+    
+    virtual void _setMax();
+    virtual void _setMin();
+    virtual bool _isMax() const;
+
+  };
+} //END OF NAMESPACE LEMON
+
+#endif //LEMON_LP_SOPLEX_H
+
Index: lemon/lp_utils.cc
===================================================================
--- lemon/lp_utils.cc	(revision 2578)
+++ lemon/lp_utils.cc	(revision 2578)
@@ -0,0 +1,35 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/lp_utils.h>
+
+namespace lemon {
+
+  LpResultMap lpResultMap(const LpSolverBase& lp) {
+    return LpResultMap(lp);
+  }
+
+  LpColNameMap lpColNameMap(const LpSolverBase& lp) {
+    return LpColNameMap(lp);
+  }
+
+  LpColNameWriteMap lpColNameMap(LpSolverBase& lp) {
+    return LpColNameWriteMap(lp);
+  }
+
+}
Index: lemon/lp_utils.h
===================================================================
--- lemon/lp_utils.h	(revision 2578)
+++ lemon/lp_utils.h	(revision 2578)
@@ -0,0 +1,971 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_LP_UTILS_H
+#define LEMON_LP_UTILS_H
+
+#include <lemon/lp_base.h>
+
+#include <lemon/lemon_reader.h>
+#include <lemon/lemon_writer.h>
+
+#include <map>
+#include <set>
+
+
+namespace lemon {
+
+  /// \ingroup lp_utils
+  ///
+  /// \brief The map for the result of the lp variables.
+  ///
+  /// The map for the result of the lp variables.
+  class LpResultMap {
+  public:
+    typedef LpSolverBase::Col Key;
+    typedef LpSolverBase::Value Value;
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    LpResultMap(const LpSolverBase& _lp) : lp(_lp) {}
+    LpSolverBase::Value operator[](const LpSolverBase::Col col) const {
+      return lp.primal(col);
+    }
+  private:
+    const LpSolverBase& lp;
+  };
+
+  /// \ingroup lp_utils
+  ///
+  /// \brief Returns an \ref LpResultMap class
+  ///
+  /// This function just returns an \ref LpResultMap class.
+  /// \relates LpResultMap
+  LpResultMap lpResultMap(const LpSolverBase& lp);
+
+  /// \ingroup lp_utils
+  ///
+  /// \brief The map for the name of the lp variables.
+  ///
+  /// The map for the name of the lp variables.
+  class LpColNameMap {
+  public:
+    typedef LpSolverBase::Col Key;
+    typedef std::string Value;
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    LpColNameMap(const LpSolverBase& _lp) : lp(_lp) {}
+    std::string operator[](const LpSolverBase::Col col) const {
+      return lp.colName(col);
+    }
+  private:
+    const LpSolverBase& lp;
+  };
+
+  /// \ingroup lp_utils
+  ///
+  /// \brief Writeable map for the name of the lp variables.
+  ///
+  /// Writeable map for the name of the lp variables.
+  class LpColNameWriteMap {
+  public:
+    typedef LpSolverBase::Col Key;
+    typedef std::string Value;
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    LpColNameWriteMap(LpSolverBase& _lp) : lp(_lp) {}
+    std::string operator[](const LpSolverBase::Col col) const {
+      return lp.colName(col);
+    }
+    void set(const LpSolverBase::Col col, const std::string& name) {
+      lp.colName(col, name);
+    }
+  private:
+    LpSolverBase& lp;
+  };
+
+  /// \ingroup lp_utils
+  ///
+  /// \brief Returns an \ref LpColNameMap class
+  ///
+  /// This function just returns an \ref LpColNameMap class.
+  /// \relates LpColNameMap
+  LpColNameMap lpColNameMap(const LpSolverBase& lp);
+
+  LpColNameWriteMap lpColNameMap(LpSolverBase& lp);
+
+  /// \ingroup lp_utils
+  ///
+  /// \brief Lp variable item reader for Lemon IO
+  ///
+  /// This class is an Lp variable item reader for Lemon IO. It makes
+  /// possible to store lp variables in lemon file. The usage of this
+  /// class is very simple:
+  ///
+  ///\code
+  /// Graph graph;
+  /// Lp lp;
+  /// Graph::EdgeMap<Lp::Col> var(graph); 
+  ///
+  /// GraphReader<Graph> reader(cin, graph);
+  /// reader.readEdgeMap("lpvar", var, LpColReader(lp));
+  /// reader.run();
+  ///\endcode
+  ///
+  /// If there is already a variable with the same name in the lp then
+  /// it will be used for the return value. If there is no such variable
+  /// then it will be constructed. The file could contain \c '-' as value
+  /// which means that no lp variable associated to the current item and
+  /// in this case INVALID will be returned.
+  class LpColReader {
+  public:
+
+    /// \brief The value type of reader.
+    ///
+    /// The value type of reader.
+    typedef LpSolverBase::Col Value;
+
+    /// \brief Constructor for the reader.
+    ///
+    /// Constructor for the reader.
+    LpColReader(LpSolverBase& _lp) : lp(_lp) {}
+
+    /// \brief Reads an lp variable from the given stream.
+    ///
+    /// Reads an lp variable string from the given stream.
+    void read(std::istream& is, LpSolverBase::Col& col) const {
+      char x;
+      is >> std::ws;
+      if (!is.get(x))
+        throw DataFormatError("Wrong Lp Column format!");
+      if (varFirstChar(x)) {
+        std::string var;
+        var += x;
+        
+        while (is.get(x) && varChar(x)) {
+          var += x;
+        }
+        if (!is) {
+          is.clear();
+        } else {
+          is.putback(x);
+        }
+        col = lp.colByName(var);
+        if (col == INVALID) {
+          col = lp.addCol();
+          lp.colName(col, var);
+        }
+      } else if (x == '-') {
+        col = INVALID;
+        is >> std::ws;
+      } else {
+        std::cerr << x << std::endl;
+        throw DataFormatError("Wrong Lp Column format");
+      }
+    }
+
+  private:
+
+    static bool varFirstChar(char c) {
+      return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z');
+    }
+
+    static bool varChar(char c) {
+      return (c >= '0' && c <= '9') || 
+        (c >= 'a' && c <= 'z') || 
+        (c >= 'A' && c <= 'Z') ||
+        c == '[' || c == ']';
+    }
+    
+    LpSolverBase& lp;
+
+  };
+
+  /// \ingroup lp_utils
+  ///
+  /// \brief Lp variable item writer for Lemon IO
+  ///
+  /// This class is an Lp variable item writer for Lemon IO. It makes
+  /// possible to store lp variables in lemon file. The usage of this
+  /// class is very simple:
+  ///
+  ///\code
+  /// Graph graph;
+  /// Lp lp;
+  /// Graph::EdgeMap<Lp::Col> var(graph); 
+  ///
+  /// GraphWriter<Graph> writer(cin, graph);
+  /// writer.writeEdgeMap("lpvar", var, LpColWriter(lp));
+  /// writer.run();
+  ///\endcode
+  ///
+  /// If there is no name associated to the current item then the name
+  /// will automatically constructed. If the value is INVALID then it
+  /// will write an \c '-' value to the file.
+  class LpColWriter {
+  public:
+
+    /// \brief The value type of writer.
+    ///
+    /// The value type of writer.
+    typedef LpSolverBase::Col Value;
+
+    /// \brief Constructor for the writer.
+    ///
+    /// Constructor for the writer.
+    LpColWriter(const LpSolverBase& _lp) : lp(_lp), num(0) {}
+
+    /// \brief Writes an lp variable to the given stream.
+    ///
+    /// Writes an lp variable to the given stream.
+    void write(std::ostream& os, const LpSolverBase::Col& col) const {
+      if (col != INVALID) {
+        std::string name = lp.colName(col);
+        if (name.empty()) {
+          std::ostringstream ls;
+          ls << "x" << num;
+          ++num;
+          while (lp.colByName(ls.str()) != INVALID) {
+            ls.str(std::string());
+            ls << "x" << num;
+            ++num;
+          }
+          const_cast<LpSolverBase&>(lp).colName(col, ls.str());
+          os << ls.str();
+        } else {
+          os << name;
+        }
+      } else {
+        os << "-";
+      }
+    }
+
+  private:
+
+    const LpSolverBase& lp;
+    mutable int num;
+
+  };
+
+  /// \ingroup lp_utils
+  ///
+  /// \brief Lp section reader for lemon IO
+  ///
+  /// This section reader provides an easy way to read an Lp problem
+  /// from a file. The lemon lp section format contains three parts.
+  ///
+  ///\code
+  /// @lp
+  /// constraints
+  ///   7 == x1 - 1 * x2
+  ///   2 * x1 + x3 / 2 <= 7
+  ///   x2 + -3 * x3 >= 8
+  ///   3 <= x2 - 2 * x1 <= 8
+  /// bounds
+  ///   x1 >= 3
+  ///   2 <= x2 <= 5
+  ///   0 <= x3 <= 8
+  /// objective
+  ///   min x1 + 2 * x2 - x3
+  ///\endcode
+  ///
+  /// The first part gives the constraints to the lp. The constraints
+  /// could be equality, lower bound, upper bound or range for an
+  /// expression or equality, less or more for two expressions.
+  ///
+  /// The second part gives the bounds for the variables. The bounds
+  /// could be the same as for the single expression so equality,
+  /// lower bound, upper bound or range.
+  ///
+  /// The third part is the objective function, it should start with
+  /// \c min or \c max and then a valid linear expression.
+  ///
+  /// The reader constructs automatically the variable for a name if
+  /// there is not already a variable with the same name.
+  ///
+  /// The basic way to read an LP problem is made by the next code:
+  ///\code
+  /// Lp lp;
+  ///
+  /// LemonReader reader(filename_or_istream);
+  /// LpReader lpreader(reader, lp);
+  /// 
+  /// reader.run();
+  ///\endcode
+  ///
+  /// Of course instead of \c LemonReader you can give a \c
+  /// GraphReader to the LpReader constructor. Also useful that you
+  /// can mix lp problems and graphs in the same file.
+  class LpReader : public LemonReader::SectionReader {
+    typedef LemonReader::SectionReader Parent;
+  public:
+
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for LpReader. It creates the LpReader and attachs
+    /// it into the given LemonReader. The lp reader will add
+    /// variables, constraints and objective function to the
+    /// given lp solver.
+    LpReader(LemonReader& _reader, LpSolverBase& _lp, 
+             const std::string& _name = std::string())
+      : Parent(_reader), lp(_lp), name(_name) {} 
+
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for LpReader.
+    virtual ~LpReader() {}
+
+  private:
+    LpReader(const LpReader&);
+    void operator=(const LpReader&);
+  
+  protected:
+
+    /// \brief Gives back true when the SectionReader can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back true when the header line starts with \c \@lp,
+    /// and the header line's name and the nodeset's name are the same.
+    virtual bool header(const std::string& line) {
+      std::istringstream ls(line);
+      std::string command;
+      std::string id;
+      ls >> command >> id;
+      return command == "@lp" && name == id;
+    }
+
+  private:
+
+    enum Part {
+      CONSTRAINTS, BOUNDS, OBJECTIVE
+    };
+
+    enum Relation {
+      LE, EQ, GE
+    };
+
+    std::istream& readConstraint(std::istream& is) {
+      LpSolverBase::Constr c;
+      char x;
+      LpSolverBase::Expr e1, e2;
+      Relation op1;
+      is >> std::ws;
+      readExpression(is, e1);
+      is >> std::ws;
+      readRelation(is, op1);
+      is >> std::ws;
+      readExpression(is, e2);
+      is >> std::ws;
+      if (!is.get(x)) {
+        if (op1 == LE) {
+          if (e1.size() == 0) {
+            c = e2 >= e1;
+          } else {
+            c = e1 <= e2;
+          }
+          c = e1 <= e2;
+        } else if (op1 == GE) {
+          if (e1.size() == 0) {
+            c = e2 <= e1;
+          } else {
+            c = e1 >= e2;
+          }
+        } else {
+          if (e1.size() == 0) {
+            c = e2 == e1;
+          } else {
+            c = e1 == e2;
+          }
+        }
+      } else {
+        is.putback(x);
+        LpSolverBase::Expr e3;
+        Relation op2;
+        readRelation(is, op2);
+        is >> std::ws;
+        readExpression(is, e3);
+        if (!e1.empty() || !e3.empty()) {
+          throw DataFormatError("Wrong range format");
+        }
+        if (op2 != op1 || op1 == EQ) {
+          throw DataFormatError("Wrong range format");
+        }
+        if (op1 == LE) {
+          c = e1.constComp() <= e2 <= e3.constComp();
+        } else {
+          c = e1.constComp() >= e2 >= e3.constComp();
+        }
+        is >> std::ws;
+        if (is.get(x)) {
+          throw DataFormatError("Wrong variable bounds format");
+        }
+      }
+      lp.addRow(c);
+      return is;
+    }
+
+    std::istream& readObjective(std::istream& is) {
+      is >> std::ws;
+      std::string sense;
+      is >> sense;
+      if (sense != "min" && sense != "max") {
+        throw DataFormatError("Wrong objective function format");
+      }
+      LpSolverBase::Expr expr;
+      is >> std::ws;
+      readExpression(is, expr);
+      lp.obj(expr);
+      if (sense == "min") {
+        lp.min();
+      } else {
+        lp.max();
+      }
+      return is;
+    }
+
+    std::istream& readBounds(std::istream& is) {
+      LpSolverBase::Col c;
+      char x;
+      is >> std::ws;
+      if (!is.get(x)) {
+        throw DataFormatError("Wrong variable bounds format");
+      }
+      if (varFirstChar(x)) {
+        is.putback(x);
+        readCol(is, c);
+        is >> std::ws;
+        Relation op1;
+        readRelation(is, op1);
+        double v;
+        readNum(is, v);
+        if (op1 == EQ) {
+          lp.colLowerBound(c, v);
+          lp.colUpperBound(c, v);
+        } else if (op1 == LE) {
+          lp.colUpperBound(c, v);
+        } else {
+          lp.colLowerBound(c, v);
+        }
+        is >> std::ws;
+        if (is.get(x)) {
+          throw DataFormatError("Wrong variable bounds format");
+        }
+      } else {
+        is.putback(x);
+        double v;
+        readNum(is, v);
+        is >> std::ws;
+        Relation op1;
+        readRelation(is, op1);
+        is >> std::ws;
+        readCol(is, c);
+        is >> std::ws;
+        if (is.get(x)) {
+          is.putback(x);
+          is >> std::ws;
+          Relation op2;
+          readRelation(is, op2);
+          double w;
+          is >> std::ws;
+          readNum(is, w);
+          if (op2 != op1 || op1 == EQ) {
+            throw DataFormatError("Wrong range format");
+          }
+          if (op1 == LE) {
+            lp.colLowerBound(c, v);
+            lp.colUpperBound(c, w);
+          } else {
+            lp.colLowerBound(c, w);
+            lp.colUpperBound(c, v);
+          }
+          is >> std::ws;
+          if (is.get(x)) {
+            throw DataFormatError("Wrong variable bounds format");
+          }
+        } else {
+          if (op1 == EQ) {
+            lp.colLowerBound(c, v);
+            lp.colUpperBound(c, v);
+          } else if (op1 == LE) {
+            lp.colLowerBound(c, v);
+          } else {
+            lp.colUpperBound(c, v);
+          }
+        }
+      }
+      return is;
+    }
+
+    std::istream& readExpression(std::istream& is, LpSolverBase::Expr& e) {
+      LpSolverBase::Col c;
+      double d;
+      char x;
+      readElement(is, c, d);
+      if (c != INVALID) {
+        e += d * c;
+      } else {
+        e += d;
+      }
+      is >> std::ws;
+      while (is.get(x) && (x == '+' || x == '-')) {
+        is >> std::ws;
+        readElement(is, c, d);
+        if (c != INVALID) {
+          e += (x == '+' ? d : -d) * c;
+        } else {
+          e += (x == '+' ? d : -d);
+        }
+        is >> std::ws;
+      }
+      if (!is) {
+        is.clear();
+      } else {
+        is.putback(x);
+      }
+      return is;
+    }
+
+    std::istream& readElement(std::istream& is, 
+                              LpSolverBase::Col& c, double& d) { 
+      d = 1.0;
+      c = INVALID;
+      char x, y;
+      if (!is.get(x)) throw DataFormatError("Cannot find lp element");
+      if (x == '+' || x == '-') {
+        is >> std::ws;
+        d *= x == '-' ? -1 : 1;
+        while (is.get(x) && (x == '+' || x == '-')) {
+          d *= x == '-' ? -1 : 1;
+          is >> std::ws;
+        }
+        if (!is) throw DataFormatError("Cannot find lp element");
+      }
+      if (numFirstChar(x)) {
+        is.putback(x);
+        double e;
+        readNum(is, e);
+        d *= e;
+      } else if (varFirstChar(x)) {
+        is.putback(x);
+        LpSolverBase::Col f;
+        readCol(is, f);
+        c = f;
+      } else {
+        throw DataFormatError("Invalid expression format");          
+      }
+      is >> std::ws;
+      while (is.get(y) && (y == '*' || y == '/')) {
+        is >> std::ws;
+        if (!is.get(x)) throw DataFormatError("Cannot find lp element");
+        if (x == '+' || x == '-') {
+          is >> std::ws;
+          d *= x == '-' ? -1 : 1;
+          while (is.get(x) && (x == '+' || x == '-')) {
+            d *= x == '-' ? -1 : 1;
+            is >> std::ws;
+          }
+          if (!is) throw DataFormatError("Cannot find lp element");
+        }
+        if (numFirstChar(x)) {
+          is.putback(x);
+          double e;
+          readNum(is, e);
+          if (y == '*') {
+            d *= e;
+          } else {
+            d /= e;
+          }
+        } else if (varFirstChar(x)) {
+          is.putback(x);
+          LpSolverBase::Col f;
+          readCol(is, f);
+          if (y == '*') {
+            if (c == INVALID) {
+              c = f;
+            } else {
+              throw DataFormatError("Quadratic element in expression");
+            }
+          } else {
+            throw DataFormatError("Division by variable");
+          }
+        } else {
+          throw DataFormatError("Invalid expression format");          
+        }
+        is >> std::ws;
+      }
+      if (!is) {
+        is.clear();
+      } else {
+        is.putback(y);
+      }
+      return is;
+    }
+
+    std::istream& readCol(std::istream& is, LpSolverBase::Col& c) {
+      char x;
+      std::string var;
+      while (is.get(x) && varChar(x)) {
+        var += x;
+      }
+      if (!is) {
+        is.clear();
+      } else {
+        is.putback(x);
+      }
+      c = lp.colByName(var);
+      if (c == INVALID) {
+        c = lp.addCol();
+        lp.colName(c, var);
+      }
+      return is;
+    }
+
+    std::istream& readNum(std::istream& is, double& d) {
+      is >> d;
+      if (!is) throw DataFormatError("Wrong number format");
+      return is;
+    }
+
+    std::istream& readRelation(std::istream& is, Relation& op) {
+      char x, y;
+      if (!is.get(x) || !(x == '<' || x == '=' || x == '>')) {
+        throw DataFormatError("Wrong relation operator");
+      }
+      if (!is.get(y) || y != '=') {
+        throw DataFormatError("Wrong relation operator");
+      }
+      switch (x) {
+      case '<': op = LE; 
+        break;
+      case '=': op = EQ; 
+        break;
+      case '>': op = GE; 
+        break;
+      }
+      return is;
+    }
+
+    static bool relationFirstChar(char c) {
+      return c == '<' || c == '=' || c == '>';
+    }
+
+    static bool varFirstChar(char c) {
+      return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z');
+    }
+
+    static bool numFirstChar(char c) {
+      return (c >= '0' && c <= '9') || c == '.';
+    }
+    
+    static bool varChar(char c) {
+      return (c >= '0' && c <= '9') || 
+        (c >= 'a' && c <= 'z') || 
+        (c >= 'A' && c <= 'Z') ||
+        c == '[' || c == ']';
+    }
+    
+  protected:
+
+    /// \brief Reader function of the section.
+    ///
+    /// It reads the content of the section.
+    virtual void read(std::istream& is) {
+      std::string line;
+      Part part = CONSTRAINTS;
+      while (getline(is, line)) {
+        std::istringstream ls(line);
+        std::string type;
+        ls >> type;
+        if (type == "constraints") {
+          part = CONSTRAINTS;
+          ls >> std::ws;
+          char x;
+          if (ls.get(x))
+            throw DataFormatError("Wrong Lp format");
+        } else if (type == "bounds") {
+          part = BOUNDS;
+          ls >> std::ws;
+          char x;
+          if (ls.get(x))
+            throw DataFormatError("Wrong Lp format");
+        } else if (type == "objective") {
+          part = OBJECTIVE;
+          ls >> std::ws;
+          char x;
+          if (ls.get(x))
+            throw DataFormatError("Wrong Lp format");
+        } else {
+          ls.str(line);
+          switch (part) {
+          case CONSTRAINTS:
+            readConstraint(ls);
+            break;
+          case BOUNDS:
+            readBounds(ls);
+            break;
+          case OBJECTIVE:
+            readObjective(ls);
+            break;
+          }
+        }
+      }
+    }
+      
+    virtual void missing() {
+      ErrorMessage msg;
+      msg << "Lp section not found in file: @lp " << name;
+      throw IoParameterError(msg.message());
+    }
+
+  private:
+
+      
+    LpSolverBase& lp;
+    std::string name;
+  };
+
+
+  /// \ingroup lp_utils
+  ///
+  /// \brief Lp section writer for lemon IO
+  ///
+  /// This section reader provides an easy way to write an Lp problem
+  /// to a file. The lemon lp section format contains three parts.
+  ///
+  ///\code
+  /// @lp
+  /// constraints
+  ///   7 == x1 - 1 * x2
+  ///   2 * x1 + x3 / 2 <= 7
+  ///   x2 + -3 * x3 >= 8
+  ///   3 <= x2 - 2 * x1 <= 8
+  /// bounds
+  ///   x1 >= 3
+  ///   2 <= x2 <= 5
+  ///   0 <= x3 <= 8
+  /// objective
+  ///   min x1 + 2 * x2 - x3
+  ///\endcode
+  ///
+  /// The first part gives the constraints to the lp. The constraints
+  /// could be equality, lower bound, upper bound or range for an
+  /// expression or equality, less or more for two expressions.
+  ///
+  /// The second part gives the bounds for the variables. The bounds
+  /// could be the same as for the single expression so equality,
+  /// lower bound, upper bound or range.
+  ///
+  /// The third part is the objective function, it should start with
+  /// \c min or \c max and then a valid linear expression.
+  ///
+  /// If an LP variable does not have name in the writer, then it will
+  /// automatically created in the writer. This make a slight change
+  /// in the \c const variable.
+  ///
+  /// The basic way to write an LP problem is made by the next code:
+  ///\code
+  /// Lp lp;
+  ///
+  /// LemonWriter writer(filename_or_ostream);
+  /// LpWriter lpwriter(writer, lp);
+  /// 
+  /// writer.run();
+  ///\endcode
+  ///
+  /// Of course instead of \c LemonWriter you can give a \c
+  /// GraphWriter to the LpWriter constructor. Also useful that you
+  /// can mix lp problems and graphs in the same file.
+  class LpWriter : public LemonWriter::SectionWriter {
+    typedef LemonWriter::SectionWriter Parent;
+  public:
+
+
+    /// \brief Constructor.
+    ///
+    /// Constructor for LpWriter. It creates the LpWriter and attach
+    /// it into the given LemonWriter.
+    LpWriter(LemonWriter& _writer, const LpSolverBase& _lp, 
+             const std::string& _name = std::string())
+      : Parent(_writer), lp(_lp), name(_name) {} 
+
+
+    /// \brief Destructor.
+    ///
+    /// Destructor for LpWriter.
+    virtual ~LpWriter() {}
+
+  private:
+    LpWriter(const LpWriter&);
+    void operator=(const LpWriter&);
+  
+  protected:
+
+    /// \brief Gives back true when the SectionWriter can process 
+    /// the section with the given header line.
+    ///
+    /// It gives back the header line of the \c \@lp section.
+    virtual std::string header() {
+      std::ostringstream ls;
+      ls << "@lp " << name;
+      return ls.str();
+    }
+
+  private:
+
+    void createCols() {
+      int num = 0;
+
+      for (LpSolverBase::ColIt it(lp); it != INVALID; ++it) {
+        std::string name = lp.colName(it);
+        if (name.empty()) {
+          std::ostringstream ls;
+          ls << "x" << num;
+          ++num;
+          while (lp.colByName(ls.str()) != INVALID) {
+            ls.str(std::string());
+            ls << "x" << num;
+            ++num;
+          }
+          const_cast<LpSolverBase&>(lp).colName(it, ls.str());
+        }
+      }
+    }
+    
+    void writeExpression(std::ostream& os, const LpSolverBase::Expr& e) {
+      bool first = true;
+      for (LpSolverBase::Expr::const_iterator jt = e.begin(); 
+           jt != e.end(); ++jt) {
+        if (jt->second < 0.0) {
+          os << "- ";
+          if (jt->second != -1.0) {
+            os << -jt->second << " * ";
+          }
+        } else if (jt->second > 0.0) {
+          if (!first) {
+            os << "+ ";
+          }
+          if (jt->second != 1.0) {
+            os << jt->second << " * ";
+          }          
+        }
+        first = false;
+        os << lp.colName(jt->first) << " ";
+      }
+      if (e.constComp() < 0.0) {
+        os << "- " << -e.constComp() << " ";
+      } else if (e.constComp() > 0.0) {
+        if (!first) {
+          os << "+ ";
+        }
+        os << e.constComp() << " ";
+      }
+      if (e.begin() == e.end() && e.constComp() == 0.0) {
+        os << "0 ";
+      }
+    }
+
+  protected:
+
+    /// \brief Writer function of the section.
+    ///
+    /// It writes the content of the section.
+    virtual void write(std::ostream& os) {
+      createCols();
+
+      os << "constraints" << std::endl;
+      
+      for (LpSolverBase::RowIt it(lp); it != INVALID; ++it) {
+        double lower, upper;
+        lp.getRowBounds(it, lower, upper);
+        if (lower == -LpSolverBase::INF && upper == LpSolverBase::INF) 
+          continue;
+        os << "   ";
+        
+        if (lower != upper) {
+          if (lower != -LpSolverBase::INF) {
+            os << lower << " <= ";
+          }
+          
+          writeExpression(os, lp.row(it));
+          
+          if (upper != LpSolverBase::INF) {
+            os << "<= " << upper << " ";
+          }
+        } else {
+
+          writeExpression(os, lp.row(it));
+          os << "== " << upper << " ";
+          
+        }
+
+        os << std::endl;
+      }
+
+      os << "bounds" << std::endl;
+      
+      for (LpSolverBase::ColIt it(lp); it != INVALID; ++it) {
+        double lower = lp.colLowerBound(it);
+        double upper = lp.colUpperBound(it);
+        if (lower == -LpSolverBase::INF && upper == LpSolverBase::INF) 
+          continue;
+        os << "   ";
+
+        if (lower != upper) {
+          if (lower != -LpSolverBase::INF) {
+            os << lower << " <= ";
+          }
+          
+          os << lp.colName(it) << " ";
+          
+          if (upper != LpSolverBase::INF) {
+            os << "<= " << upper << " ";
+          }
+        } else {
+          os << lp.colName(it) << " == " << upper << " ";
+        }
+        os << std::endl;
+      }
+
+      os << "objective" << std::endl;
+      os << "   ";
+      if (lp.isMin()) {
+        os << "min ";
+      } else {
+        os << "max ";
+      }
+      writeExpression(os, lp.obj());
+      os << std::endl;
+    }
+      
+
+  private:
+
+    const LpSolverBase& lp;
+    std::string name;
+  };
+
+}
+
+#endif
Index: lemon/map_iterator.h
===================================================================
--- lemon/map_iterator.h	(revision 2553)
+++ lemon/map_iterator.h	(revision 2553)
@@ -0,0 +1,147 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MAP_ITERATOR_H
+#define LEMON_MAP_ITERATOR_H
+
+#include <lemon/bits/traits.h>
+#include <lemon/bits/utility.h>
+
+/// \ingroup gutils
+/// \file
+/// \brief Iterators on the maps.
+
+namespace lemon {
+
+  /// \ingroup gutils
+  ///
+  /// \brief Iterator for maps with possibility of changing values.
+  ///
+  /// Iterator for maps with possibility of changing values.
+  template <typename Graph, typename Item, typename Map>
+  class MapIt : public ItemSetTraits<Graph, Item>::ItemIt {
+  public:
+      
+    typedef typename ItemSetTraits<Graph, Item>::ItemIt Parent;
+    
+    typedef typename Map::Value Value;
+    
+    /// \brief Creates an iterator
+    ///
+    /// Creates an iterator for the map, which iterates on the
+    /// given graph item set.
+    MapIt(const Graph& _graph, Map& _map) : Parent(_graph), map(_map) {}
+
+    /// \brief Gives back the map's value on the current position.
+    ///
+    /// Gives back the map's value on the current position.
+    typename MapTraits<Map>::ConstReturnValue operator*() const {
+      return map[*this];
+    }
+
+    /// \brief Gives back a reference to the map's value.
+    ///
+    /// Gives back a reference to the map's value on the current position.
+    typename MapTraits<Map>::ReturnValue operator*() {
+      return map[*this];
+    }
+    
+    /// \brief Sets the value on the current position
+    ///
+    /// Sets the value on the current position.
+    void set(const Value& value) {
+      map.set(*this, value);
+    }
+    
+  protected:
+    Map& map;
+      
+  };
+
+  /// \ingroup gutils
+  ///
+  /// \brief Iterator for maps with possibility of getting values.
+  ///
+  /// Iterator for maps with possibility of getting values.
+  template <typename Graph, typename Item, typename Map>
+  class ConstMapIt : public ItemSetTraits<Graph, Item>::ItemIt {
+  public:
+    
+    typedef typename ItemSetTraits<Graph, Item>::ItemIt Parent;
+
+    typedef typename Map::Value Value;
+    
+    /// \brief Creates an iterator
+    ///
+    /// Creates an iterator for the map, which iterates on the
+    /// given graph item set.
+    ConstMapIt(const Graph& _graph, const Map& _map) 
+      : Parent(_graph), map(_map) {}
+    
+    /// \brief Gives back the map's value on the current position.
+    ///
+    /// Gives back the map's value on the current position.
+    typename MapTraits<Map>::ConstReturnValue operator*() const {
+      return map[*this];
+    }
+    
+  protected:
+    const Map& map;
+  };
+
+
+  /// \ingroup gutils
+  ///
+  /// \brief Iterator for maps which filters items by the values.
+  ///
+  /// Iterator for maps which gives back only that items which mapped
+  /// to an given value.
+  template <typename Graph, typename Item, typename Map>
+  class FilterMapIt 
+    : public ItemSetTraits<Graph, Item>::ItemIt {
+  public:
+    
+    typedef typename ItemSetTraits<Graph, Item>::ItemIt Parent;
+
+    typedef typename Map::Value Value;
+    
+    /// \brief Creates an iterator
+    ///
+    /// Creates an iterator for the map, which iterates on the
+    /// given graph item set and filters all items which mapped value
+    /// is not equal to the \c _value.
+    FilterMapIt(const Graph& _graph, const Map& _map, const Value& _value) 
+      : Parent(_graph), map(_map), value(_value) {}
+    
+    /// \brief Increment operator
+    ///
+    /// Skips items which has not mapped to the given value.
+    FilterMapIt& operator++() {
+      Parent::operator++();
+      while (*this != INVALID && map[*this] != value) Parent::operator++();
+    }
+    
+  protected:
+    const Map& map;
+    Value value;
+  };
+
+  
+}
+
+#endif
Index: lemon/maps.h
===================================================================
--- lemon/maps.h	(revision 2564)
+++ lemon/maps.h	(revision 2564)
@@ -0,0 +1,1633 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MAPS_H
+#define LEMON_MAPS_H
+
+#include <iterator>
+#include <functional>
+#include <vector>
+
+#include <lemon/bits/utility.h>
+#include <lemon/bits/traits.h>
+
+///\file
+///\ingroup maps
+///\brief Miscellaneous property maps
+///
+#include <map>
+
+namespace lemon {
+
+  /// \addtogroup maps
+  /// @{
+
+  /// Base class of maps.
+
+  /// Base class of maps.
+  /// It provides the necessary <tt>typedef</tt>s required by the map concept.
+  template<typename K, typename T>
+  class MapBase {
+  public:
+    /// The key type of the map.
+    typedef K Key;
+    /// The value type of the map. (The type of objects associated with the keys).
+    typedef T Value;
+  };
+
+  /// Null map. (a.k.a. DoNothingMap)
+
+  /// This map can be used if you have to provide a map only for
+  /// its type definitions, or if you have to provide a writable map, 
+  /// but data written to it is not required (i.e. it will be sent to 
+  /// <tt>/dev/null</tt>).
+  template<typename K, typename T>
+  class NullMap : public MapBase<K, T> {
+  public:
+    typedef MapBase<K, T> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+    
+    /// Gives back a default constructed element.
+    T operator[](const K&) const { return T(); }
+    /// Absorbs the value.
+    void set(const K&, const T&) {}
+  };
+
+  ///Returns a \c NullMap class
+
+  ///This function just returns a \c NullMap class.
+  ///\relates NullMap
+  template <typename K, typename V> 
+  NullMap<K, V> nullMap() {
+    return NullMap<K, V>();
+  }
+
+
+  /// Constant map.
+
+  /// This is a \ref concepts::ReadMap "readable" map which assigns a 
+  /// specified value to each key.
+  /// In other aspects it is equivalent to \c NullMap.
+  template<typename K, typename T>
+  class ConstMap : public MapBase<K, T> {
+  private:
+    T v;
+  public:
+
+    typedef MapBase<K, T> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    /// Default constructor
+
+    /// Default constructor.
+    /// The value of the map will be uninitialized. 
+    /// (More exactly it will be default constructed.)
+    ConstMap() {}
+    
+    /// Constructor with specified initial value
+
+    /// Constructor with specified initial value.
+    /// \param _v is the initial value of the map.
+    ConstMap(const T &_v) : v(_v) {}
+    
+    ///\e
+    T operator[](const K&) const { return v; }
+
+    ///\e
+    void setAll(const T &t) {
+      v = t;
+    }    
+
+    template<typename T1>
+    struct rebind {
+      typedef ConstMap<K, T1> other;
+    };
+
+    template<typename T1>
+    ConstMap(const ConstMap<K, T1> &, const T &_v) : v(_v) {}
+  };
+
+  ///Returns a \c ConstMap class
+
+  ///This function just returns a \c ConstMap class.
+  ///\relates ConstMap
+  template<typename K, typename V> 
+  inline ConstMap<K, V> constMap(const V &v) {
+    return ConstMap<K, V>(v);
+  }
+
+
+  template<typename T, T v>
+  struct Const { };
+
+  /// Constant map with inlined constant value.
+
+  /// This is a \ref concepts::ReadMap "readable" map which assigns a 
+  /// specified value to each key.
+  /// In other aspects it is equivalent to \c NullMap.
+  template<typename K, typename V, V v>
+  class ConstMap<K, Const<V, v> > : public MapBase<K, V> {
+  public:
+    typedef MapBase<K, V> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ConstMap() { }
+    ///\e
+    V operator[](const K&) const { return v; }
+    ///\e
+    void set(const K&, const V&) { }
+  };
+
+  ///Returns a \c ConstMap class with inlined value
+
+  ///This function just returns a \c ConstMap class with inlined value.
+  ///\relates ConstMap
+  template<typename K, typename V, V v> 
+  inline ConstMap<K, Const<V, v> > constMap() {
+    return ConstMap<K, Const<V, v> >();
+  }
+
+  ///Map based on \c std::map
+
+  ///This is essentially a wrapper for \c std::map with addition that
+  ///you can specify a default value different from \c Value() .
+  ///It meets the \ref concepts::ReferenceMap "ReferenceMap" concept.
+  template <typename K, typename T, typename Compare = std::less<K> >
+  class StdMap : public MapBase<K, T> {
+    template <typename K1, typename T1, typename C1>
+    friend class StdMap;
+  public:
+
+    typedef MapBase<K, T> Parent;
+    ///Key type
+    typedef typename Parent::Key Key;
+    ///Value type
+    typedef typename Parent::Value Value;
+    ///Reference Type
+    typedef T& Reference;
+    ///Const reference type
+    typedef const T& ConstReference;
+
+    typedef True ReferenceMapTag;
+
+  private:
+    
+    typedef std::map<K, T, Compare> Map;
+    Value _value;
+    Map _map;
+
+  public:
+
+    /// Constructor with specified default value
+    StdMap(const T& value = T()) : _value(value) {}
+    /// \brief Constructs the map from an appropriate \c std::map, and 
+    /// explicitly specifies a default value.
+    template <typename T1, typename Comp1>
+    StdMap(const std::map<Key, T1, Comp1> &map, const T& value = T()) 
+      : _map(map.begin(), map.end()), _value(value) {}
+    
+    /// \brief Constructs a map from an other \ref StdMap.
+    template<typename T1, typename Comp1>
+    StdMap(const StdMap<Key, T1, Comp1> &c) 
+      : _map(c._map.begin(), c._map.end()), _value(c._value) {}
+
+  private:
+
+    StdMap& operator=(const StdMap&);
+
+  public:
+
+    ///\e
+    Reference operator[](const Key &k) {
+      typename Map::iterator it = _map.lower_bound(k);
+      if (it != _map.end() && !_map.key_comp()(k, it->first))
+	return it->second;
+      else
+	return _map.insert(it, std::make_pair(k, _value))->second;
+    }
+
+    /// \e 
+    ConstReference operator[](const Key &k) const {
+      typename Map::const_iterator it = _map.find(k);
+      if (it != _map.end())
+	return it->second;
+      else
+	return _value;
+    }
+
+    /// \e 
+    void set(const Key &k, const T &t) {
+      typename Map::iterator it = _map.lower_bound(k);
+      if (it != _map.end() && !_map.key_comp()(k, it->first))
+	it->second = t;
+      else
+	_map.insert(it, std::make_pair(k, t));
+    }
+
+    /// \e
+    void setAll(const T &t) {
+      _value = t;
+      _map.clear();
+    }    
+
+    template <typename T1, typename C1 = std::less<T1> >
+    struct rebind {
+      typedef StdMap<Key, T1, C1> other;
+    };
+  };
+
+  ///Returns a \c StdMap class
+
+  ///This function just returns a \c StdMap class with specified 
+  ///default value.
+  ///\relates StdMap
+  template<typename K, typename V, typename Compare> 
+  inline StdMap<K, V, Compare> stdMap(const V& value = V()) {
+    return StdMap<K, V, Compare>(value);
+  }
+  
+  template<typename K, typename V> 
+  inline StdMap<K, V, std::less<K> > stdMap(const V& value = V()) {
+    return StdMap<K, V, std::less<K> >(value);
+  }
+  
+  ///Returns a \c StdMap class created from an appropriate \c std::map
+
+  ///This function just returns a \c StdMap class created from an 
+  ///appropriate \c std::map.
+  ///\relates StdMap
+  template<typename K, typename V, typename Compare> 
+  inline StdMap<K, V, Compare> stdMap( const std::map<K, V, Compare> &map, 
+                                       const V& value = V() ) {
+    return StdMap<K, V, Compare>(map, value);
+  }
+
+  /// \brief Map for storing values for keys from the range <tt>[0..size-1]</tt>
+  ///
+  /// This map has the <tt>[0..size-1]</tt> keyset and the values
+  /// are stored in a \c std::vector<T>  container. It can be used with
+  /// some data structures, for example \c UnionFind, \c BinHeap, when 
+  /// the used items are small integer numbers.
+  template <typename T>
+  class IntegerMap : public MapBase<int, T> {
+
+    template <typename T1>
+    friend class IntegerMap;
+
+  public:
+
+    typedef MapBase<int, T> Parent;
+    ///\e
+    typedef typename Parent::Key Key;
+    ///\e
+    typedef typename Parent::Value Value;
+    ///\e
+    typedef T& Reference;
+    ///\e
+    typedef const T& ConstReference;
+
+    typedef True ReferenceMapTag;
+
+  private:
+    
+    typedef std::vector<T> Vector;
+    Vector _vector;
+
+  public:
+
+    /// Constructor with specified default value
+    IntegerMap(int size = 0, const T& value = T()) : _vector(size, value) {}
+
+    /// \brief Constructs the map from an appropriate \c std::vector.
+    template <typename T1>
+    IntegerMap(const std::vector<T1>& vector) 
+      : _vector(vector.begin(), vector.end()) {}
+    
+    /// \brief Constructs a map from an other \ref IntegerMap.
+    template <typename T1>
+    IntegerMap(const IntegerMap<T1> &c) 
+      : _vector(c._vector.begin(), c._vector.end()) {}
+
+    /// \brief Resize the container
+    void resize(int size, const T& value = T()) {
+      _vector.resize(size, value);
+    }
+
+  private:
+
+    IntegerMap& operator=(const IntegerMap&);
+
+  public:
+
+    ///\e
+    Reference operator[](Key k) {
+      return _vector[k];
+    }
+
+    /// \e 
+    ConstReference operator[](Key k) const {
+      return _vector[k];
+    }
+
+    /// \e 
+    void set(const Key &k, const T& t) {
+      _vector[k] = t;
+    }
+
+  };
+
+  ///Returns an \c IntegerMap class
+
+  ///This function just returns an \c IntegerMap class.
+  ///\relates IntegerMap
+  template<typename T>
+  inline IntegerMap<T> integerMap(int size = 0, const T& value = T()) {
+    return IntegerMap<T>(size, value);
+  }
+
+  /// @}
+
+  /// \addtogroup map_adaptors
+  /// @{
+
+  /// \brief Identity map.
+  ///
+  /// This map gives back the given key as value without any
+  /// modification. 
+  template <typename T>
+  class IdentityMap : public MapBase<T, T> {
+  public:
+    typedef MapBase<T, T> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    /// \e
+    const T& operator[](const T& t) const {
+      return t;
+    }
+  };
+
+  ///Returns an \c IdentityMap class
+
+  ///This function just returns an \c IdentityMap class.
+  ///\relates IdentityMap
+  template<typename T>
+  inline IdentityMap<T> identityMap() {
+    return IdentityMap<T>();
+  }
+  
+
+  ///\brief Convert the \c Value of a map to another type using
+  ///the default conversion.
+  ///
+  ///This \ref concepts::ReadMap "read only map"
+  ///converts the \c Value of a map to type \c T.
+  ///Its \c Key is inherited from \c M.
+  template <typename M, typename T> 
+  class ConvertMap : public MapBase<typename M::Key, T> {
+    const M& m;
+  public:
+    typedef MapBase<typename M::Key, T> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+
+    ///Constructor
+    ///\param _m is the underlying map
+    ConvertMap(const M &_m) : m(_m) {};
+
+    ///\e
+    Value operator[](const Key& k) const {return m[k];}
+  };
+  
+  ///Returns a \c ConvertMap class
+
+  ///This function just returns a \c ConvertMap class.
+  ///\relates ConvertMap
+  template<typename T, typename M>
+  inline ConvertMap<M, T> convertMap(const M &m) {
+    return ConvertMap<M, T>(m);
+  }
+
+  ///Simple wrapping of a map
+
+  ///This \ref concepts::ReadMap "read only map" returns the simple
+  ///wrapping of the given map. Sometimes the reference maps cannot be
+  ///combined with simple read maps. This map adaptor wraps the given
+  ///map to simple read map.
+  ///
+  ///\sa SimpleWriteMap
+  ///
+  /// \todo Revise the misleading name 
+  template<typename M> 
+  class SimpleMap : public MapBase<typename M::Key, typename M::Value> {
+    const M& m;
+
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    SimpleMap(const M &_m) : m(_m) {};
+    ///\e
+    Value operator[](Key k) const {return m[k];}
+  };
+
+  ///Returns a \c SimpleMap class
+
+  ///This function just returns a \c SimpleMap class.
+  ///\relates SimpleMap
+  template<typename M>
+  inline SimpleMap<M> simpleMap(const M &m) {
+    return SimpleMap<M>(m);
+  }
+
+  ///Simple writable wrapping of a map
+
+  ///This \ref concepts::ReadWriteMap "read-write map" returns the simple
+  ///wrapping of the given map. Sometimes the reference maps cannot be
+  ///combined with simple read-write maps. This map adaptor wraps the
+  ///given map to simple read-write map.
+  ///
+  ///\sa SimpleMap
+  ///
+  /// \todo Revise the misleading name
+  template<typename M> 
+  class SimpleWriteMap : public MapBase<typename M::Key, typename M::Value> {
+    M& m;
+
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    SimpleWriteMap(M &_m) : m(_m) {};
+    ///\e
+    Value operator[](Key k) const {return m[k];}
+    ///\e
+    void set(Key k, const Value& c) { m.set(k, c); }
+  };
+
+  ///Returns a \c SimpleWriteMap class
+
+  ///This function just returns a \c SimpleWriteMap class.
+  ///\relates SimpleWriteMap
+  template<typename M>
+  inline SimpleWriteMap<M> simpleWriteMap(M &m) {
+    return SimpleWriteMap<M>(m);
+  }
+
+  ///Sum of two maps
+
+  ///This \ref concepts::ReadMap "read only map" returns the sum of the two
+  ///given maps.
+  ///Its \c Key and \c Value are inherited from \c M1.
+  ///The \c Key and \c Value of \c M2 must be convertible to those of \c M1.
+  template<typename M1, typename M2> 
+  class AddMap : public MapBase<typename M1::Key, typename M1::Value> {
+    const M1& m1;
+    const M2& m2;
+
+  public:
+    typedef MapBase<typename M1::Key, typename M1::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    AddMap(const M1 &_m1,const M2 &_m2) : m1(_m1), m2(_m2) {};
+    ///\e
+    Value operator[](Key k) const {return m1[k]+m2[k];}
+  };
+  
+  ///Returns an \c AddMap class
+
+  ///This function just returns an \c AddMap class.
+  ///\todo How to call these type of functions?
+  ///
+  ///\relates AddMap
+  template<typename M1, typename M2> 
+  inline AddMap<M1, M2> addMap(const M1 &m1,const M2 &m2) {
+    return AddMap<M1, M2>(m1,m2);
+  }
+
+  ///Shift a map with a constant.
+
+  ///This \ref concepts::ReadMap "read only map" returns the sum of the
+  ///given map and a constant value.
+  ///Its \c Key and \c Value is inherited from \c M.
+  ///
+  ///Actually,
+  ///\code
+  ///  ShiftMap<X> sh(x,v);
+  ///\endcode
+  ///is equivalent to
+  ///\code
+  ///  ConstMap<X::Key, X::Value> c_tmp(v);
+  ///  AddMap<X, ConstMap<X::Key, X::Value> > sh(x,v);
+  ///\endcode
+  ///
+  ///\sa ShiftWriteMap
+  template<typename M, typename C = typename M::Value> 
+  class ShiftMap : public MapBase<typename M::Key, typename M::Value> {
+    const M& m;
+    C v;
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+
+    ///Constructor
+    ///\param _m is the undelying map
+    ///\param _v is the shift value
+    ShiftMap(const M &_m, const C &_v ) : m(_m), v(_v) {};
+    ///\e
+    Value operator[](Key k) const {return m[k] + v;}
+  };
+
+  ///Shift a map with a constant (ReadWrite version).
+
+  ///This \ref concepts::ReadWriteMap "read-write map" returns the sum of the
+  ///given map and a constant value. It makes also possible to write the map.
+  ///Its \c Key and \c Value are inherited from \c M.
+  ///
+  ///\sa ShiftMap
+  template<typename M, typename C = typename M::Value> 
+  class ShiftWriteMap : public MapBase<typename M::Key, typename M::Value> {
+    M& m;
+    C v;
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+
+    ///Constructor
+    ///\param _m is the undelying map
+    ///\param _v is the shift value
+    ShiftWriteMap(M &_m, const C &_v ) : m(_m), v(_v) {};
+    /// \e
+    Value operator[](Key k) const {return m[k] + v;}
+    /// \e
+    void set(Key k, const Value& c) { m.set(k, c - v); }
+  };
+  
+  ///Returns a \c ShiftMap class
+
+  ///This function just returns an \c ShiftMap class.
+  ///\relates ShiftMap
+  template<typename M, typename C> 
+  inline ShiftMap<M, C> shiftMap(const M &m,const C &v) {
+    return ShiftMap<M, C>(m,v);
+  }
+
+  ///Returns a \c ShiftWriteMap class
+
+  ///This function just returns a \c ShiftWriteMap class.
+  ///\relates ShiftWriteMap
+  template<typename M, typename C> 
+  inline ShiftWriteMap<M, C> shiftMap(M &m,const C &v) {
+    return ShiftWriteMap<M, C>(m,v);
+  }
+
+  ///Difference of two maps
+
+  ///This \ref concepts::ReadMap "read only map" returns the difference
+  ///of the values of the two given maps.
+  ///Its \c Key and \c Value are inherited from \c M1.
+  ///The \c Key and \c Value of \c M2 must be convertible to those of \c M1.
+
+  template<typename M1, typename M2> 
+  class SubMap : public MapBase<typename M1::Key, typename M1::Value> {
+    const M1& m1;
+    const M2& m2;
+  public:
+    typedef MapBase<typename M1::Key, typename M1::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    SubMap(const M1 &_m1,const M2 &_m2) : m1(_m1), m2(_m2) {};
+    /// \e
+    Value operator[](Key k) const {return m1[k]-m2[k];}
+  };
+  
+  ///Returns a \c SubMap class
+
+  ///This function just returns a \c SubMap class.
+  ///
+  ///\relates SubMap
+  template<typename M1, typename M2> 
+  inline SubMap<M1, M2> subMap(const M1 &m1, const M2 &m2) {
+    return SubMap<M1, M2>(m1, m2);
+  }
+
+  ///Product of two maps
+
+  ///This \ref concepts::ReadMap "read only map" returns the product of the
+  ///values of the two given maps.
+  ///Its \c Key and \c Value are inherited from \c M1.
+  ///The \c Key and \c Value of \c M2 must be convertible to those of \c M1.
+  template<typename M1, typename M2> 
+  class MulMap : public MapBase<typename M1::Key, typename M1::Value> {
+    const M1& m1;
+    const M2& m2;
+  public:
+    typedef MapBase<typename M1::Key, typename M1::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    MulMap(const M1 &_m1,const M2 &_m2) : m1(_m1), m2(_m2) {};
+    /// \e
+    Value operator[](Key k) const {return m1[k]*m2[k];}
+  };
+  
+  ///Returns a \c MulMap class
+
+  ///This function just returns a \c MulMap class.
+  ///\relates MulMap
+  template<typename M1, typename M2> 
+  inline MulMap<M1, M2> mulMap(const M1 &m1,const M2 &m2) {
+    return MulMap<M1, M2>(m1,m2);
+  }
+ 
+  ///Scales a map with a constant.
+
+  ///This \ref concepts::ReadMap "read only map" returns the value of the
+  ///given map multiplied from the left side with a constant value.
+  ///Its \c Key and \c Value are inherited from \c M.
+  ///
+  ///Actually,
+  ///\code
+  ///  ScaleMap<X> sc(x,v);
+  ///\endcode
+  ///is equivalent to
+  ///\code
+  ///  ConstMap<X::Key, X::Value> c_tmp(v);
+  ///  MulMap<X, ConstMap<X::Key, X::Value> > sc(x,v);
+  ///\endcode
+  ///
+  ///\sa ScaleWriteMap
+  template<typename M, typename C = typename M::Value> 
+  class ScaleMap : public MapBase<typename M::Key, typename M::Value> {
+    const M& m;
+    C v;
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+
+    ///Constructor
+    ///\param _m is the undelying map
+    ///\param _v is the scaling value
+    ScaleMap(const M &_m, const C &_v ) : m(_m), v(_v) {};
+    /// \e
+    Value operator[](Key k) const {return v * m[k];}
+  };
+
+  ///Scales a map with a constant (ReadWrite version).
+
+  ///This \ref concepts::ReadWriteMap "read-write map" returns the value of the
+  ///given map multiplied from the left side with a constant value. It can
+  ///also be used as write map if the \c / operator is defined between
+  ///\c Value and \c C and the given multiplier is not zero.
+  ///Its \c Key and \c Value are inherited from \c M.
+  ///
+  ///\sa ScaleMap
+  template<typename M, typename C = typename M::Value> 
+  class ScaleWriteMap : public MapBase<typename M::Key, typename M::Value> {
+    M& m;
+    C v;
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+
+    ///Constructor
+    ///\param _m is the undelying map
+    ///\param _v is the scaling value
+    ScaleWriteMap(M &_m, const C &_v ) : m(_m), v(_v) {};
+    /// \e
+    Value operator[](Key k) const {return v * m[k];}
+    /// \e
+    void set(Key k, const Value& c) { m.set(k, c / v);}
+  };
+  
+  ///Returns a \c ScaleMap class
+
+  ///This function just returns a \c ScaleMap class.
+  ///\relates ScaleMap
+  template<typename M, typename C> 
+  inline ScaleMap<M, C> scaleMap(const M &m,const C &v) {
+    return ScaleMap<M, C>(m,v);
+  }
+
+  ///Returns a \c ScaleWriteMap class
+
+  ///This function just returns a \c ScaleWriteMap class.
+  ///\relates ScaleWriteMap
+  template<typename M, typename C> 
+  inline ScaleWriteMap<M, C> scaleMap(M &m,const C &v) {
+    return ScaleWriteMap<M, C>(m,v);
+  }
+
+  ///Quotient of two maps
+
+  ///This \ref concepts::ReadMap "read only map" returns the quotient of the
+  ///values of the two given maps.
+  ///Its \c Key and \c Value are inherited from \c M1.
+  ///The \c Key and \c Value of \c M2 must be convertible to those of \c M1.
+  template<typename M1, typename M2> 
+  class DivMap : public MapBase<typename M1::Key, typename M1::Value> {
+    const M1& m1;
+    const M2& m2;
+  public:
+    typedef MapBase<typename M1::Key, typename M1::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    DivMap(const M1 &_m1,const M2 &_m2) : m1(_m1), m2(_m2) {};
+    /// \e
+    Value operator[](Key k) const {return m1[k]/m2[k];}
+  };
+  
+  ///Returns a \c DivMap class
+
+  ///This function just returns a \c DivMap class.
+  ///\relates DivMap
+  template<typename M1, typename M2> 
+  inline DivMap<M1, M2> divMap(const M1 &m1,const M2 &m2) {
+    return DivMap<M1, M2>(m1,m2);
+  }
+  
+  ///Composition of two maps
+
+  ///This \ref concepts::ReadMap "read only map" returns the composition of
+  ///two given maps.
+  ///That is to say, if \c m1 is of type \c M1 and \c m2 is of \c M2,
+  ///then for
+  ///\code
+  ///  ComposeMap<M1, M2> cm(m1,m2);
+  ///\endcode
+  /// <tt>cm[x]</tt> will be equal to <tt>m1[m2[x]]</tt>.
+  ///
+  ///Its \c Key is inherited from \c M2 and its \c Value is from \c M1.
+  ///\c M2::Value must be convertible to \c M1::Key.
+  ///
+  ///\sa CombineMap
+  ///
+  ///\todo Check the requirements.
+  template <typename M1, typename M2> 
+  class ComposeMap : public MapBase<typename M2::Key, typename M1::Value> {
+    const M1& m1;
+    const M2& m2;
+  public:
+    typedef MapBase<typename M2::Key, typename M1::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    ComposeMap(const M1 &_m1,const M2 &_m2) : m1(_m1), m2(_m2) {};
+    
+    typename MapTraits<M1>::ConstReturnValue
+    /// \e
+    operator[](Key k) const {return m1[m2[k]];}
+  };
+  ///Returns a \c ComposeMap class
+
+  ///This function just returns a \c ComposeMap class.
+  ///
+  ///\relates ComposeMap
+  template <typename M1, typename M2> 
+  inline ComposeMap<M1, M2> composeMap(const M1 &m1,const M2 &m2) {
+    return ComposeMap<M1, M2>(m1,m2);
+  }
+  
+  ///Combine of two maps using an STL (binary) functor.
+
+  ///Combine of two maps using an STL (binary) functor.
+  ///
+  ///This \ref concepts::ReadMap "read only map" takes two maps and a
+  ///binary functor and returns the composition of the two
+  ///given maps unsing the functor. 
+  ///That is to say, if \c m1 and \c m2 is of type \c M1 and \c M2
+  ///and \c f is of \c F, then for
+  ///\code
+  ///  CombineMap<M1, M2,F,V> cm(m1,m2,f);
+  ///\endcode
+  /// <tt>cm[x]</tt> will be equal to <tt>f(m1[x],m2[x])</tt>
+  ///
+  ///Its \c Key is inherited from \c M1 and its \c Value is \c V.
+  ///\c M2::Value and \c M1::Value must be convertible to the corresponding
+  ///input parameter of \c F and the return type of \c F must be convertible
+  ///to \c V.
+  ///
+  ///\sa ComposeMap
+  ///
+  ///\todo Check the requirements.
+  template<typename M1, typename M2, typename F,
+	   typename V = typename F::result_type> 
+  class CombineMap : public MapBase<typename M1::Key, V> {
+    const M1& m1;
+    const M2& m2;
+    F f;
+  public:
+    typedef MapBase<typename M1::Key, V> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    CombineMap(const M1 &_m1,const M2 &_m2,const F &_f = F())
+      : m1(_m1), m2(_m2), f(_f) {};
+    /// \e
+    Value operator[](Key k) const {return f(m1[k],m2[k]);}
+  };
+  
+  ///Returns a \c CombineMap class
+
+  ///This function just returns a \c CombineMap class.
+  ///
+  ///For example if \c m1 and \c m2 are both \c double valued maps, then 
+  ///\code
+  ///combineMap(m1,m2,std::plus<double>())
+  ///\endcode
+  ///is equivalent to
+  ///\code
+  ///addMap(m1,m2)
+  ///\endcode
+  ///
+  ///This function is specialized for adaptable binary function
+  ///classes and C++ functions.
+  ///
+  ///\relates CombineMap
+  template<typename M1, typename M2, typename F, typename V> 
+  inline CombineMap<M1, M2, F, V> 
+  combineMap(const M1& m1,const M2& m2, const F& f) {
+    return CombineMap<M1, M2, F, V>(m1,m2,f);
+  }
+
+  template<typename M1, typename M2, typename F> 
+  inline CombineMap<M1, M2, F, typename F::result_type> 
+  combineMap(const M1& m1, const M2& m2, const F& f) {
+    return combineMap<M1, M2, F, typename F::result_type>(m1,m2,f);
+  }
+
+  template<typename M1, typename M2, typename K1, typename K2, typename V> 
+  inline CombineMap<M1, M2, V (*)(K1, K2), V> 
+  combineMap(const M1 &m1, const M2 &m2, V (*f)(K1, K2)) {
+    return combineMap<M1, M2, V (*)(K1, K2), V>(m1,m2,f);
+  }
+
+  ///Negative value of a map
+
+  ///This \ref concepts::ReadMap "read only map" returns the negative
+  ///value of the value returned by the given map.
+  ///Its \c Key and \c Value are inherited from \c M.
+  ///The unary \c - operator must be defined for \c Value, of course.
+  ///
+  ///\sa NegWriteMap
+  template<typename M> 
+  class NegMap : public MapBase<typename M::Key, typename M::Value> {
+    const M& m;
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    NegMap(const M &_m) : m(_m) {};
+    /// \e
+    Value operator[](Key k) const {return -m[k];}
+  };
+  
+  ///Negative value of a map (ReadWrite version)
+
+  ///This \ref concepts::ReadWriteMap "read-write map" returns the negative
+  ///value of the value returned by the given map.
+  ///Its \c Key and \c Value are inherited from \c M.
+  ///The unary \c - operator must be defined for \c Value, of course.
+  ///
+  /// \sa NegMap
+  template<typename M> 
+  class NegWriteMap : public MapBase<typename M::Key, typename M::Value> {
+    M& m;
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    NegWriteMap(M &_m) : m(_m) {};
+    /// \e
+    Value operator[](Key k) const {return -m[k];}
+    /// \e
+    void set(Key k, const Value& v) { m.set(k, -v); }
+  };
+
+  ///Returns a \c NegMap class
+
+  ///This function just returns a \c NegMap class.
+  ///\relates NegMap
+  template <typename M> 
+  inline NegMap<M> negMap(const M &m) {
+    return NegMap<M>(m);
+  }
+
+  ///Returns a \c NegWriteMap class
+
+  ///This function just returns a \c NegWriteMap class.
+  ///\relates NegWriteMap
+  template <typename M> 
+  inline NegWriteMap<M> negMap(M &m) {
+    return NegWriteMap<M>(m);
+  }
+
+  ///Absolute value of a map
+
+  ///This \ref concepts::ReadMap "read only map" returns the absolute value
+  ///of the value returned by the given map.
+  ///Its \c Key and \c Value are inherited from \c M. 
+  ///\c Value must be comparable to \c 0 and the unary \c -
+  ///operator must be defined for it, of course.
+  ///
+  ///\bug We need a unified way to handle the situation below:
+  ///\code
+  ///  struct _UnConvertible {};
+  ///  template<class A> inline A t_abs(A a) {return _UnConvertible();}
+  ///  template<> inline int t_abs<>(int n) {return abs(n);}
+  ///  template<> inline long int t_abs<>(long int n) {return labs(n);}
+  ///  template<> inline long long int t_abs<>(long long int n) {return ::llabs(n);}
+  ///  template<> inline float t_abs<>(float n) {return fabsf(n);}
+  ///  template<> inline double t_abs<>(double n) {return fabs(n);}
+  ///  template<> inline long double t_abs<>(long double n) {return fabsl(n);}
+  ///\endcode
+  
+
+  template<typename M> 
+  class AbsMap : public MapBase<typename M::Key, typename M::Value> {
+    const M& m;
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    AbsMap(const M &_m) : m(_m) {};
+    /// \e
+    Value operator[](Key k) const {
+      Value tmp = m[k]; 
+      return tmp >= 0 ? tmp : -tmp;
+    }
+
+  };
+  
+  ///Returns an \c AbsMap class
+
+  ///This function just returns an \c AbsMap class.
+  ///\relates AbsMap
+  template<typename M> 
+  inline AbsMap<M> absMap(const M &m) {
+    return AbsMap<M>(m);
+  }
+
+  ///Converts an STL style functor to a map
+
+  ///This \ref concepts::ReadMap "read only map" returns the value
+  ///of a given functor.
+  ///
+  ///Template parameters \c K and \c V will become its
+  ///\c Key and \c Value. 
+  ///In most cases they have to be given explicitly because a 
+  ///functor typically does not provide \c argument_type and 
+  ///\c result_type typedefs.
+  ///
+  ///Parameter \c F is the type of the used functor.
+  ///
+  ///\sa MapFunctor
+  template<typename F, 
+	   typename K = typename F::argument_type, 
+	   typename V = typename F::result_type> 
+  class FunctorMap : public MapBase<K, V> {
+    F f;
+  public:
+    typedef MapBase<K, V> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    FunctorMap(const F &_f = F()) : f(_f) {}
+    /// \e
+    Value operator[](Key k) const { return f(k);}
+  };
+  
+  ///Returns a \c FunctorMap class
+
+  ///This function just returns a \c FunctorMap class.
+  ///
+  ///This function is specialized for adaptable binary function
+  ///classes and C++ functions.
+  ///
+  ///\relates FunctorMap
+  template<typename K, typename V, typename F> inline 
+  FunctorMap<F, K, V> functorMap(const F &f) {
+    return FunctorMap<F, K, V>(f);
+  }
+
+  template <typename F> inline 
+  FunctorMap<F, typename F::argument_type, typename F::result_type> 
+  functorMap(const F &f) {
+    return FunctorMap<F, typename F::argument_type, 
+      typename F::result_type>(f);
+  }
+
+  template <typename K, typename V> inline 
+  FunctorMap<V (*)(K), K, V> functorMap(V (*f)(K)) {
+    return FunctorMap<V (*)(K), K, V>(f);
+  }
+
+
+  ///Converts a map to an STL style (unary) functor
+
+  ///This class Converts a map to an STL style (unary) functor.
+  ///That is it provides an <tt>operator()</tt> to read its values.
+  ///
+  ///For the sake of convenience it also works as
+  ///a ususal \ref concepts::ReadMap "readable map",
+  ///i.e. <tt>operator[]</tt> and the \c Key and \c Value typedefs also exist.
+  ///
+  ///\sa FunctorMap
+  template <typename M> 
+  class MapFunctor : public MapBase<typename M::Key, typename M::Value> {
+    const M& m;
+  public:
+    typedef MapBase<typename M::Key, typename M::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    typedef typename M::Key argument_type;
+    typedef typename M::Value result_type;
+
+    ///Constructor
+    MapFunctor(const M &_m) : m(_m) {};
+    ///\e
+    Value operator()(Key k) const {return m[k];}
+    ///\e
+    Value operator[](Key k) const {return m[k];}
+  };
+  
+  ///Returns a \c MapFunctor class
+
+  ///This function just returns a \c MapFunctor class.
+  ///\relates MapFunctor
+  template<typename M> 
+  inline MapFunctor<M> mapFunctor(const M &m) {
+    return MapFunctor<M>(m);
+  }
+
+  ///Just readable version of \ref ForkWriteMap
+
+  ///This map has two \ref concepts::ReadMap "readable map"
+  ///parameters and each read request will be passed just to the
+  ///first map. This class is the just readable map type of \c ForkWriteMap.
+  ///
+  ///The \c Key and \c Value are inherited from \c M1.
+  ///The \c Key and \c Value of \c M2 must be convertible from those of \c M1.
+  ///
+  ///\sa ForkWriteMap
+
+  template<typename  M1, typename M2> 
+  class ForkMap : public MapBase<typename M1::Key, typename M1::Value> {
+    const M1& m1;
+    const M2& m2;
+  public:
+    typedef MapBase<typename M1::Key, typename M1::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    ForkMap(const M1 &_m1, const M2 &_m2) : m1(_m1), m2(_m2) {};
+    /// \e
+    Value operator[](Key k) const {return m1[k];}
+  };
+
+
+  ///Applies all map setting operations to two maps
+
+  ///This map has two \ref concepts::WriteMap "writable map"
+  ///parameters and each write request will be passed to both of them.
+  ///If \c M1 is also \ref concepts::ReadMap "readable",
+  ///then the read operations will return the
+  ///corresponding values of \c M1.
+  ///
+  ///The \c Key and \c Value are inherited from \c M1.
+  ///The \c Key and \c Value of \c M2 must be convertible from those of \c M1.
+  ///
+  ///\sa ForkMap
+  template<typename  M1, typename M2> 
+  class ForkWriteMap : public MapBase<typename M1::Key, typename M1::Value> {
+    M1& m1;
+    M2& m2;
+  public:
+    typedef MapBase<typename M1::Key, typename M1::Value> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    ///Constructor
+    ForkWriteMap(M1 &_m1, M2 &_m2) : m1(_m1), m2(_m2) {};
+    ///\e
+    Value operator[](Key k) const {return m1[k];}
+    ///\e
+    void set(Key k, const Value &v) {m1.set(k,v); m2.set(k,v);}
+  };
+  
+  ///Returns a \c ForkMap class
+
+  ///This function just returns a \c ForkMap class.
+  ///\relates ForkMap
+  template <typename M1, typename M2> 
+  inline ForkMap<M1, M2> forkMap(const M1 &m1, const M2 &m2) {
+    return ForkMap<M1, M2>(m1,m2);
+  }
+
+  ///Returns a \c ForkWriteMap class
+
+  ///This function just returns a \c ForkWriteMap class.
+  ///\relates ForkWriteMap
+  template <typename M1, typename M2> 
+  inline ForkWriteMap<M1, M2> forkMap(M1 &m1, M2 &m2) {
+    return ForkWriteMap<M1, M2>(m1,m2);
+  }
+
+
+  
+  /* ************* BOOL MAPS ******************* */
+  
+  ///Logical 'not' of a map
+  
+  ///This bool \ref concepts::ReadMap "read only map" returns the 
+  ///logical negation of the value returned by the given map.
+  ///Its \c Key is inherited from \c M, its \c Value is \c bool.
+  ///
+  ///\sa NotWriteMap
+  template <typename M> 
+  class NotMap : public MapBase<typename M::Key, bool> {
+    const M& m;
+  public:
+    typedef MapBase<typename M::Key, bool> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    /// Constructor
+    NotMap(const M &_m) : m(_m) {};
+    ///\e
+    Value operator[](Key k) const {return !m[k];}
+  };
+
+  ///Logical 'not' of a map (ReadWrie version)
+  
+  ///This bool \ref concepts::ReadWriteMap "read-write map" returns the 
+  ///logical negation of the value returned by the given map. When it is set,
+  ///the opposite value is set to the original map.
+  ///Its \c Key is inherited from \c M, its \c Value is \c bool.
+  ///
+  ///\sa NotMap
+  template <typename M> 
+  class NotWriteMap : public MapBase<typename M::Key, bool> {
+    M& m;
+  public:
+    typedef MapBase<typename M::Key, bool> Parent;
+    typedef typename Parent::Key Key;
+    typedef typename Parent::Value Value;
+
+    /// Constructor
+    NotWriteMap(M &_m) : m(_m) {};
+    ///\e
+    Value operator[](Key k) const {return !m[k];}
+    ///\e
+    void set(Key k, bool v) { m.set(k, !v); }
+  };
+  
+  ///Returns a \c NotMap class
+  
+  ///This function just returns a \c NotMap class.
+  ///\relates NotMap
+  template <typename M> 
+  inline NotMap<M> notMap(const M &m) {
+    return NotMap<M>(m);
+  }
+  
+  ///Returns a \c NotWriteMap class
+  
+  ///This function just returns a \c NotWriteMap class.
+  ///\relates NotWriteMap
+  template <typename M> 
+  inline NotWriteMap<M> notMap(M &m) {
+    return NotWriteMap<M>(m);
+  }
+
+  namespace _maps_bits {
+
+    template <typename Value>
+    struct Identity {
+      typedef Value argument_type;
+      typedef Value result_type;
+      Value operator()(const Value& val) const {
+	return val;
+      }
+    };
+
+    template <typename _Iterator, typename Enable = void>
+    struct IteratorTraits {
+      typedef typename std::iterator_traits<_Iterator>::value_type Value;
+    };
+
+    template <typename _Iterator>
+    struct IteratorTraits<_Iterator,
+      typename exists<typename _Iterator::container_type>::type> 
+    {
+      typedef typename _Iterator::container_type::value_type Value;
+    };
+
+  }
+  
+
+  /// \brief Writable bool map for logging each \c true assigned element
+  ///
+  /// A \ref concepts::ReadWriteMap "read-write" bool map for logging 
+  /// each \c true assigned element, i.e it copies all the keys set 
+  /// to \c true to the given iterator.
+  ///
+  /// \note The container of the iterator should contain space 
+  /// for each element.
+  ///
+  /// The following example shows how you can write the edges found by 
+  /// the \ref Prim algorithm directly to the standard output.
+  ///\code
+  /// typedef IdMap<UGraph, UEdge> UEdgeIdMap;
+  /// UEdgeIdMap uedgeId(ugraph);
+  ///
+  /// typedef MapFunctor<UEdgeIdMap> UEdgeIdFunctor;
+  /// UEdgeIdFunctor uedgeIdFunctor(uedgeId);
+  ///
+  /// StoreBoolMap<ostream_iterator<int>, UEdgeIdFunctor> 
+  ///   writerMap(ostream_iterator<int>(cout, " "), uedgeIdFunctor);
+  ///
+  /// prim(ugraph, cost, writerMap);
+  ///\endcode
+  ///
+  ///\sa BackInserterBoolMap 
+  ///\sa FrontInserterBoolMap 
+  ///\sa InserterBoolMap 
+  template <typename _Iterator, 
+            typename _Functor =
+            _maps_bits::Identity<typename _maps_bits::
+                                 IteratorTraits<_Iterator>::Value> >
+  class StoreBoolMap {
+  public:
+    typedef _Iterator Iterator;
+
+    typedef typename _Functor::argument_type Key;
+    typedef bool Value;
+
+    typedef _Functor Functor;
+
+    /// Constructor
+    StoreBoolMap(Iterator it, const Functor& functor = Functor()) 
+      : _begin(it), _end(it), _functor(functor) {}
+
+    /// Gives back the given iterator set for the first key
+    Iterator begin() const {
+      return _begin;
+    }
+ 
+    /// Gives back the the 'after the last' iterator
+    Iterator end() const {
+      return _end;
+    }
+
+    /// The \c set function of the map
+    void set(const Key& key, Value value) const {
+      if (value) {
+	*_end++ = _functor(key);
+      }
+    }
+    
+  private:
+    Iterator _begin;
+    mutable Iterator _end;
+    Functor _functor;
+  };
+
+  /// \brief Writable bool map for logging each \c true assigned element in 
+  /// a back insertable container.
+  ///
+  /// Writable bool map for logging each \c true assigned element by pushing
+  /// them into a back insertable container.
+  /// It can be used to retrieve the items into a standard
+  /// container. The next example shows how you can store the
+  /// edges found by the Prim algorithm in a vector.
+  ///
+  ///\code
+  /// vector<UEdge> span_tree_uedges;
+  /// BackInserterBoolMap<vector<UEdge> > inserter_map(span_tree_uedges);
+  /// prim(ugraph, cost, inserter_map);
+  ///\endcode
+  ///
+  ///\sa StoreBoolMap
+  ///\sa FrontInserterBoolMap
+  ///\sa InserterBoolMap
+  template <typename Container,
+            typename Functor =
+            _maps_bits::Identity<typename Container::value_type> >
+  class BackInserterBoolMap {
+  public:
+    typedef typename Functor::argument_type Key;
+    typedef bool Value;
+
+    /// Constructor
+    BackInserterBoolMap(Container& _container, 
+                        const Functor& _functor = Functor()) 
+      : container(_container), functor(_functor) {}
+
+    /// The \c set function of the map
+    void set(const Key& key, Value value) {
+      if (value) {
+	container.push_back(functor(key));
+      }
+    }
+    
+  private:
+    Container& container;
+    Functor functor;
+  };
+
+  /// \brief Writable bool map for logging each \c true assigned element in 
+  /// a front insertable container.
+  ///
+  /// Writable bool map for logging each \c true assigned element by pushing
+  /// them into a front insertable container.
+  /// It can be used to retrieve the items into a standard
+  /// container. For example see \ref BackInserterBoolMap.
+  ///
+  ///\sa BackInserterBoolMap
+  ///\sa InserterBoolMap
+  template <typename Container,
+            typename Functor =
+            _maps_bits::Identity<typename Container::value_type> >
+  class FrontInserterBoolMap {
+  public:
+    typedef typename Functor::argument_type Key;
+    typedef bool Value;
+
+    /// Constructor
+    FrontInserterBoolMap(Container& _container,
+                         const Functor& _functor = Functor()) 
+      : container(_container), functor(_functor) {}
+
+    /// The \c set function of the map
+    void set(const Key& key, Value value) {
+      if (value) {
+	container.push_front(functor(key));
+      }
+    }
+    
+  private:
+    Container& container;    
+    Functor functor;
+  };
+
+  /// \brief Writable bool map for storing each \c true assigned element in 
+  /// an insertable container.
+  ///
+  /// Writable bool map for storing each \c true assigned element in an 
+  /// insertable container. It will insert all the keys set to \c true into
+  /// the container.
+  ///
+  /// For example, if you want to store the cut arcs of the strongly
+  /// connected components in a set you can use the next code:
+  ///
+  ///\code
+  /// set<Edge> cut_edges;
+  /// InserterBoolMap<set<Edge> > inserter_map(cut_edges);
+  /// stronglyConnectedCutEdges(graph, cost, inserter_map);
+  ///\endcode
+  ///
+  ///\sa BackInserterBoolMap
+  ///\sa FrontInserterBoolMap
+  template <typename Container,
+            typename Functor =
+            _maps_bits::Identity<typename Container::value_type> >
+  class InserterBoolMap {
+  public:
+    typedef typename Container::value_type Key;
+    typedef bool Value;
+
+    /// Constructor with specified iterator
+    
+    /// Constructor with specified iterator.
+    /// \param _container The container for storing the elements.
+    /// \param _it The elements will be inserted before this iterator.
+    /// \param _functor The functor that is used when an element is stored.
+    InserterBoolMap(Container& _container, typename Container::iterator _it,
+                    const Functor& _functor = Functor()) 
+      : container(_container), it(_it), functor(_functor) {}
+
+    /// Constructor
+
+    /// Constructor without specified iterator.
+    /// The elements will be inserted before <tt>_container.end()</tt>.
+    /// \param _container The container for storing the elements.
+    /// \param _functor The functor that is used when an element is stored.
+    InserterBoolMap(Container& _container, const Functor& _functor = Functor())
+      : container(_container), it(_container.end()), functor(_functor) {}
+
+    /// The \c set function of the map
+    void set(const Key& key, Value value) {
+      if (value) {
+	it = container.insert(it, functor(key));
+        ++it;
+      }
+    }
+    
+  private:
+    Container& container;
+    typename Container::iterator it;
+    Functor functor;
+  };
+
+  /// \brief Writable bool map for filling each \c true assigned element with a 
+  /// given value.
+  ///
+  /// Writable bool map for filling each \c true assigned element with a 
+  /// given value. The value can set the container.
+  ///
+  /// The following code finds the connected components of a graph
+  /// and stores it in the \c comp map:
+  ///\code
+  /// typedef UGraph::NodeMap<int> ComponentMap;
+  /// ComponentMap comp(ugraph);
+  /// typedef FillBoolMap<UGraph::NodeMap<int> > ComponentFillerMap;
+  /// ComponentFillerMap filler(comp, 0);
+  ///
+  /// Dfs<UGraph>::DefProcessedMap<ComponentFillerMap>::Create dfs(ugraph);
+  /// dfs.processedMap(filler);
+  /// dfs.init();
+  /// for (NodeIt it(ugraph); it != INVALID; ++it) {
+  ///   if (!dfs.reached(it)) {
+  ///     dfs.addSource(it);
+  ///     dfs.start();
+  ///     ++filler.fillValue();
+  ///   }
+  /// }
+  ///\endcode
+  template <typename Map>
+  class FillBoolMap {
+  public:
+    typedef typename Map::Key Key;
+    typedef bool Value;
+
+    /// Constructor
+    FillBoolMap(Map& _map, const typename Map::Value& _fill) 
+      : map(_map), fill(_fill) {}
+
+    /// Constructor
+    FillBoolMap(Map& _map) 
+      : map(_map), fill() {}
+
+    /// Gives back the current fill value
+    const typename Map::Value& fillValue() const {
+      return fill;
+    } 
+
+    /// Gives back the current fill value
+    typename Map::Value& fillValue() {
+      return fill;
+    } 
+
+    /// Sets the current fill value
+    void fillValue(const typename Map::Value& _fill) {
+      fill = _fill;
+    } 
+
+    /// The \c set function of the map
+    void set(const Key& key, Value value) {
+      if (value) {
+	map.set(key, fill);
+      }
+    }
+    
+  private:
+    Map& map;
+    typename Map::Value fill;
+  };
+
+
+  /// \brief Writable bool map for storing the sequence number of 
+  /// \c true assignments.  
+  ///
+  /// Writable bool map that stores for each \c true assigned elements  
+  /// the sequence number of this setting.
+  /// It makes it easy to calculate the leaving
+  /// order of the nodes in the \c Dfs algorithm.
+  ///
+  ///\code
+  /// typedef Graph::NodeMap<int> OrderMap;
+  /// OrderMap order(graph);
+  /// typedef SettingOrderBoolMap<OrderMap> OrderSetterMap;
+  /// OrderSetterMap setter(order);
+  /// Dfs<Graph>::DefProcessedMap<OrderSetterMap>::Create dfs(graph);
+  /// dfs.processedMap(setter);
+  /// dfs.init();
+  /// for (NodeIt it(graph); it != INVALID; ++it) {
+  ///   if (!dfs.reached(it)) {
+  ///     dfs.addSource(it);
+  ///     dfs.start();
+  ///   }
+  /// }
+  ///\endcode
+  ///
+  /// The storing of the discovering order is more difficult because the
+  /// ReachedMap should be readable in the dfs algorithm but the setting
+  /// order map is not readable. Thus we must use the fork map:
+  ///
+  ///\code
+  /// typedef Graph::NodeMap<int> OrderMap;
+  /// OrderMap order(graph);
+  /// typedef SettingOrderBoolMap<OrderMap> OrderSetterMap;
+  /// OrderSetterMap setter(order);
+  /// typedef Graph::NodeMap<bool> StoreMap;
+  /// StoreMap store(graph);
+  ///
+  /// typedef ForkWriteMap<StoreMap, OrderSetterMap> ReachedMap;
+  /// ReachedMap reached(store, setter);
+  ///
+  /// Dfs<Graph>::DefReachedMap<ReachedMap>::Create dfs(graph);
+  /// dfs.reachedMap(reached);
+  /// dfs.init();
+  /// for (NodeIt it(graph); it != INVALID; ++it) {
+  ///   if (!dfs.reached(it)) {
+  ///     dfs.addSource(it);
+  ///     dfs.start();
+  ///   }
+  /// }
+  ///\endcode
+  template <typename Map>
+  class SettingOrderBoolMap {
+  public:
+    typedef typename Map::Key Key;
+    typedef bool Value;
+
+    /// Constructor
+    SettingOrderBoolMap(Map& _map) 
+      : map(_map), counter(0) {}
+
+    /// Number of set operations.
+    int num() const {
+      return counter;
+    }
+
+    /// The \c set function of the map
+    void set(const Key& key, Value value) {
+      if (value) {
+	map.set(key, counter++);
+      }
+    }
+    
+  private:
+    Map& map;
+    int counter;
+  };
+
+  /// @}
+}
+
+#endif // LEMON_MAPS_H
Index: lemon/math.h
===================================================================
--- lemon/math.h	(revision 2568)
+++ lemon/math.h	(revision 2568)
@@ -0,0 +1,63 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MATH_H
+#define LEMON_MATH_H
+
+///\ingroup misc
+///\file
+///\brief Some extensions to the standard \c cmath library.
+///
+///Some extensions to the standard \c cmath library.
+///
+///This file includes the standard math library (cmath).
+
+#include<cmath>
+
+namespace lemon {
+
+  /// \addtogroup misc
+  /// @{
+  
+  /// The Euler constant
+  const long double E       = 2.7182818284590452353602874713526625L;
+  /// log_2(e)
+  const long double LOG2E   = 1.4426950408889634073599246810018921L;
+  /// log_10(e)
+  const long double LOG10E  = 0.4342944819032518276511289189166051L;
+  /// ln(2)
+  const long double LN2     = 0.6931471805599453094172321214581766L;
+  /// ln(10)
+  const long double LN10    = 2.3025850929940456840179914546843642L;
+  /// pi
+  const long double PI      = 3.1415926535897932384626433832795029L;
+  /// pi/2
+  const long double PI_2    = 1.5707963267948966192313216916397514L;
+  /// pi/4
+  const long double PI_4    = 0.7853981633974483096156608458198757L;
+  /// sqrt(2)
+  const long double SQRT2   = 1.4142135623730950488016887242096981L;
+  /// 1/sqrt(2)
+  const long double SQRT1_2 = 0.7071067811865475244008443621048490L;
+  
+
+  /// @}
+
+} //namespace lemon
+
+#endif //LEMON_TOLERANCE_H
Index: lemon/matrix_maps.h
===================================================================
--- lemon/matrix_maps.h	(revision 2553)
+++ lemon/matrix_maps.h	(revision 2553)
@@ -0,0 +1,1084 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MATRIX_MAPS_H
+#define LEMON_MATRIX_MAPS_H
+
+
+#include <vector>
+#include <lemon/bits/utility.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/maps.h>
+
+#include <lemon/concepts/matrix_maps.h>
+
+/// \file
+/// \ingroup matrices
+/// \brief Maps indexed with pairs of items.
+///
+/// \todo This file has the same name as the concept file in concepts/,
+///  and this is not easily detectable in docs...
+namespace lemon {
+
+  /// \brief Map for the coloumn view of the matrix
+  ///
+  /// \ingroup matrices
+  /// Map for the coloumn view of the matrix.
+  ///
+  template <typename _MatrixMap>
+  class MatrixRowMap : public MatrixMapTraits<_MatrixMap> {
+  public:
+    typedef _MatrixMap MatrixMap;
+    typedef typename MatrixMap::SecondKey Key;
+    typedef typename MatrixMap::Value Value;
+
+
+    /// \brief Constructor of the row map
+    ///
+    /// Constructor of the row map.
+    MatrixRowMap(MatrixMap& _matrix, typename MatrixMap::FirstKey _row) 
+      : matrix(_matrix), row(_row) {}
+
+    /// \brief Subscription operator
+    ///
+    /// Subscription operator.
+    typename MatrixMapTraits<MatrixMap>::ReturnValue
+    operator[](Key col) {
+      return matrix(row, col);
+    }
+
+    /// \brief Setter function
+    ///
+    /// Setter function.
+    void set(Key col, const Value& val) {
+      matrix.set(row, col, val);
+    }
+      
+    /// \brief Subscription operator
+    ///
+    /// Subscription operator.
+    typename MatrixMapTraits<MatrixMap>::ConstReturnValue
+    operator[](Key col) const {
+      return matrix(row, col);
+    }
+
+  private:
+    MatrixMap& matrix;
+    typename MatrixMap::FirstKey row;
+  };
+
+  /// \brief Map for the row view of the matrix
+  ///
+  /// \ingroup matrices
+  /// Map for the row view of the matrix.
+  ///
+  template <typename _MatrixMap>
+  class ConstMatrixRowMap : public MatrixMapTraits<_MatrixMap> {
+  public:
+    typedef _MatrixMap MatrixMap;
+    typedef typename MatrixMap::SecondKey Key;
+    typedef typename MatrixMap::Value Value;
+
+
+    /// \brief Constructor of the row map
+    ///
+    /// Constructor of the row map.
+    ConstMatrixRowMap(const MatrixMap& _matrix, 
+		      typename MatrixMap::FirstKey _row) 
+      : matrix(_matrix), row(_row) {}
+
+    /// \brief Subscription operator
+    ///
+    /// Subscription operator.
+    typename MatrixMapTraits<MatrixMap>::ConstReturnValue
+    operator[](Key col) const {
+      return matrix(row, col);
+    }
+
+  private:
+    const MatrixMap& matrix;
+    typename MatrixMap::FirstKey row;
+  };
+
+  /// \ingroup matrices
+  ///
+  /// \brief Gives back a row view of the matrix map
+  ///
+  /// Gives back a row view of the matrix map.
+  ///
+  /// \sa MatrixRowMap
+  /// \sa ConstMatrixRowMap
+  template <typename MatrixMap>
+  MatrixRowMap<MatrixMap> matrixRowMap(MatrixMap& matrixMap,
+				       typename MatrixMap::FirstKey row) {
+    return MatrixRowMap<MatrixMap>(matrixMap, row);
+  }
+
+  template <typename MatrixMap>
+  ConstMatrixRowMap<MatrixMap>
+  matrixRowMap(const MatrixMap& matrixMap, typename MatrixMap::FirstKey row) {
+    return ConstMatrixRowMap<MatrixMap>(matrixMap, row);
+  }
+
+  /// \brief Map for the column view of the matrix
+  ///
+  /// \ingroup matrices
+  /// Map for the column view of the matrix.
+  ///
+  template <typename _MatrixMap>
+  class MatrixColMap : public MatrixMapTraits<_MatrixMap> {
+  public:
+    typedef _MatrixMap MatrixMap;
+    typedef typename MatrixMap::FirstKey Key;
+    typedef typename MatrixMap::Value Value;
+
+    /// \brief Constructor of the column map
+    ///
+    /// Constructor of the column map.
+    MatrixColMap(MatrixMap& _matrix, typename MatrixMap::SecondKey _col) 
+      : matrix(_matrix), col(_col) {}
+
+    /// \brief Subscription operator
+    ///
+    /// Subscription operator.
+    typename MatrixMapTraits<MatrixMap>::ReturnValue
+    operator[](Key row) {
+      return matrix(row, col);
+    }
+
+    /// \brief Setter function
+    ///
+    /// Setter function.
+    void set(Key row, const Value& val) {
+      matrix.set(row, col, val);
+    }
+      
+    /// \brief Subscription operator
+    ///
+    /// Subscription operator.
+    typename MatrixMapTraits<MatrixMap>::ConstReturnValue
+    operator[](Key row) const {
+      return matrix(row, col);
+    }
+
+  private:
+    MatrixMap& matrix;
+    typename MatrixMap::SecondKey col;
+  };
+
+  /// \brief Map for the column view of the matrix
+  ///
+  /// \ingroup matrices
+  /// Map for the column view of the matrix.
+  ///
+  template <typename _MatrixMap>
+  class ConstMatrixColMap : public MatrixMapTraits<_MatrixMap> {
+  public:
+    typedef _MatrixMap MatrixMap;
+    typedef typename MatrixMap::FirstKey Key;
+    typedef typename MatrixMap::Value Value;
+
+    /// \brief Constructor of the column map
+    ///
+    /// Constructor of the column map.
+    ConstMatrixColMap(const MatrixMap& _matrix, 
+		      typename MatrixMap::SecondKey _col) 
+      : matrix(_matrix), col(_col) {}
+
+    /// \brief Subscription operator
+    ///
+    /// Subscription operator.
+    typename MatrixMapTraits<MatrixMap>::ConstReturnValue
+    operator[](Key row) const {
+      return matrix(row, col);
+    }
+
+  private:
+    const MatrixMap& matrix;
+    typename MatrixMap::SecondKey col;
+  };
+
+  /// \ingroup matrices
+  ///
+  /// \brief Gives back a column view of the matrix map
+  ///
+  /// Gives back a column view of the matrix map.
+  ///
+  /// \sa MatrixColMap
+  /// \sa ConstMatrixColMap
+  template <typename MatrixMap>
+  MatrixColMap<MatrixMap> matrixColMap(MatrixMap& matrixMap,
+				       typename MatrixMap::SecondKey col) {
+    return MatrixColMap<MatrixMap>(matrixMap, col);
+  }
+
+  template <typename MatrixMap>
+  ConstMatrixColMap<MatrixMap> 
+  matrixColMap(const MatrixMap& matrixMap, typename MatrixMap::SecondKey col) {
+    return ConstMatrixColMap<MatrixMap>(matrixMap, col);
+  }
+
+  /// \brief Container for store values for each ordered pair of graph items
+  ///
+  /// \ingroup matrices
+  /// This data structure can strore for each pair of the same item
+  /// type a value. It increase the size of the container when the 
+  /// associated graph modified, so it updated automaticly whenever
+  /// it is needed.
+  template <typename _Graph, typename _Item, typename _Value>
+  class DynamicMatrixMap 
+    : protected ItemSetTraits<_Graph, _Item>::ItemNotifier::ObserverBase {
+  public:
+    typedef typename ItemSetTraits<_Graph, _Item>::ItemNotifier::ObserverBase 
+    Parent;
+
+    typedef _Graph Graph;
+    typedef _Item Key;
+
+    typedef _Item FirstKey;
+    typedef _Item SecondKey;
+    typedef _Value Value;
+
+    typedef True ReferenceMapTag;
+
+  private:
+		
+    typedef std::vector<Value> Container;
+
+  public:
+
+    typedef typename Container::reference Reference;
+    typedef typename Container::const_reference ConstReference;
+
+    /// \brief Creates an item matrix for the given graph
+    ///
+    /// Creates an item matrix for the given graph.
+    DynamicMatrixMap(const Graph& _graph) 
+      : values(size(_graph.maxId(Key()) + 1)) {
+      Parent::attach(_graph.notifier(Key()));
+    }
+
+    /// \brief Creates an item matrix for the given graph
+    ///
+    /// Creates an item matrix for the given graph and assigns for each
+    /// pairs of keys the given parameter.
+    DynamicMatrixMap(const Graph& _graph, const Value& _val) 
+      : values(size(_graph.maxId(Key()) + 1), _val) {
+      Parent::attach(_graph.notifier(Key()));
+    }
+
+    ///\brief The assignement operator.
+    ///
+    ///It allow to assign a map to an other.
+    DynamicMatrixMap& operator=(const DynamicMatrixMap& _cmap){
+      return operator=<DynamicMatrixMap>(_cmap);
+    }
+      
+    ///\brief Template assignement operator.
+    ///
+    ///It copy the element of the given map to its own container.  The
+    ///type of the two map shall be the same.
+    template <typename CMap>
+    DynamicMatrixMap& operator=(const CMap& _cmap){
+      checkConcept<concepts::ReadMatrixMap<FirstKey, SecondKey, Value>, CMap>();
+      typename Parent::Notifier* notifier = Parent::notifier();
+      Key first, second;
+      for(notifier->first(first); first != INVALID; 
+          notifier->next(first)){
+        for(notifier->first(second); second != INVALID; 
+            notifier->next(second)){
+          set(first, second, _cmap(first, second));
+        }
+      }
+      return *this;
+    }
+
+    /// \brief Gives back the value assigned to the \c first - \c second
+    /// ordered pair.
+    ///
+    /// Gives back the value assigned to the \c first - \c second ordered pair.
+    ConstReference operator()(const Key& first, const Key& second) const {
+      return values[index(Parent::notifier()->id(first), 
+                          Parent::notifier()->id(second))];
+    }
+    
+    /// \brief Gives back the value assigned to the \c first - \c second
+    /// ordered pair.
+    ///
+    /// Gives back the value assigned to the \c first - \c second ordered pair.
+    Reference operator()(const Key& first, const Key& second) {
+      return values[index(Parent::notifier()->id(first), 
+                          Parent::notifier()->id(second))];
+    }
+
+    /// \brief Setter function for the matrix map.
+    ///
+    /// Setter function for the matrix map.
+    void set(const Key& first, const Key& second, const Value& val) {
+      values[index(Parent::notifier()->id(first), 
+                   Parent::notifier()->id(second))] = val;
+    }
+
+  protected:
+
+    static int index(int i, int j) {
+      if (i < j) {
+	return j * j + i;
+      } else {
+	return i * i + i + j;
+      }
+    }
+
+    static int size(int s) {
+      return s * s;
+    }
+
+    virtual void add(const Key& key) {
+      if (size(Parent::notifier()->id(key) + 1) >= int(values.size())) {
+	values.resize(size(Parent::notifier()->id(key) + 1));	
+      }
+    }
+
+    virtual void add(const std::vector<Key>& keys) {
+      int new_size = 0;
+      for (int i = 0; i < int(keys.size()); ++i) {
+        if (size(Parent::notifier()->id(keys[i]) + 1) >= new_size) {
+          new_size = size(Parent::notifier()->id(keys[i]) + 1);	
+        }
+      }
+      if (new_size > int(values.size())) {
+        values.resize(new_size);
+      }
+    }
+
+    virtual void erase(const Key&) {}
+
+    virtual void erase(const std::vector<Key>&) {}
+
+    virtual void build() {
+      values.resize(size(Parent::notifier()->maxId() + 1));
+    }
+
+    virtual void clear() {
+      values.clear();
+    }   
+    
+  private:
+    std::vector<Value> values;
+  };
+
+  /// \brief Container for store values for each unordered pair of graph items
+  ///
+  /// \ingroup matrices
+  /// This data structure can strore for each pair of the same item
+  /// type a value. It increase the size of the container when the 
+  /// associated graph modified, so it updated automaticly whenever
+  /// it is needed. 
+  template <typename _Graph, typename _Item, typename _Value>
+  class DynamicSymMatrixMap 
+    : protected ItemSetTraits<_Graph, _Item>::ItemNotifier::ObserverBase {
+  public:
+    typedef typename ItemSetTraits<_Graph, _Item>::ItemNotifier::ObserverBase 
+    Parent;
+
+    typedef _Graph Graph;
+    typedef _Item Key;
+
+    typedef _Item FirstKey;
+    typedef _Item SecondKey;
+    typedef _Value Value;
+
+    typedef True ReferenceMapTag;
+
+  private:
+		
+    typedef std::vector<Value> Container;
+
+  public:
+
+    typedef typename Container::reference Reference;
+    typedef typename Container::const_reference ConstReference;
+
+    /// \brief Creates an item matrix for the given graph
+    ///
+    /// Creates an item matrix for the given graph.
+    DynamicSymMatrixMap(const Graph& _graph) 
+      : values(size(_graph.maxId(Key()) + 1)) {
+      Parent::attach(_graph.notifier(Key()));
+    }
+
+    /// \brief Creates an item matrix for the given graph
+    ///
+    /// Creates an item matrix for the given graph and assigns for each
+    /// pairs of keys the given parameter.
+    DynamicSymMatrixMap(const Graph& _graph, const Value& _val) 
+      : values(size(_graph.maxId(Key()) + 1), _val) {
+      Parent::attach(_graph.notifier(Key()));
+    }
+
+
+    ///\brief The assignement operator.
+    ///
+    ///It allow to assign a map to an other.
+    ///
+    DynamicSymMatrixMap& operator=(const DynamicSymMatrixMap& _cmap){
+      return operator=<DynamicSymMatrixMap>(_cmap);
+    }
+      
+    ///\brief Template assignement operator.
+    ///
+    ///It copy the element of the given map to its own container.  The
+    ///type of the two map shall be the same.
+    template <typename CMap>
+    DynamicSymMatrixMap& operator=(const CMap& _cmap){
+      checkConcept<concepts::ReadMatrixMap<FirstKey, SecondKey, Value>, CMap>();
+      typename Parent::Notifier* notifier = Parent::notifier();
+      Key first, second;
+      for(notifier->first(first); first != INVALID; 
+          notifier->next(first)){
+        for(notifier->first(second); second != first; 
+            notifier->next(second)){
+          set(first, second, _cmap(first, second));
+        }
+        set(first, first, _cmap(first, first));        
+      }
+      return *this;
+    }
+
+    /// \brief Gives back the value assigned to the \c first - \c second
+    /// unordered pair.
+    ///
+    /// Gives back the value assigned to the \c first - \c second unordered 
+    /// pair.
+    ConstReference operator()(const Key& first, const Key& second) const {
+      return values[index(Parent::notifier()->id(first), 
+                          Parent::notifier()->id(second))];
+    }
+    
+    /// \brief Gives back the value assigned to the \c first - \c second
+    /// unordered pair.
+    ///
+    /// Gives back the value assigned to the \c first - \c second unordered 
+    /// pair.
+    Reference operator()(const Key& first, const Key& second) {
+      return values[index(Parent::notifier()->id(first), 
+                          Parent::notifier()->id(second))];
+    }
+
+    /// \brief Setter function for the matrix map.
+    ///
+    /// Setter function for the matrix map.
+    ///
+    void set(const Key& first, const Key& second, const Value& val) {
+      values[index(Parent::notifier()->id(first), 
+                   Parent::notifier()->id(second))] = val;
+    }
+
+  protected:
+
+    static int index(int i, int j) {
+      if (i < j) {
+	return j * (j + 1) / 2 + i;
+      } else {
+	return i * (i + 1) / 2 + j;
+      }
+    }
+
+    static int size(int s) {
+      return s * (s + 1) / 2;
+    }
+
+    virtual void add(const Key& key) {
+      if (size(Parent::notifier()->id(key) + 1) >= int(values.size())) {
+	values.resize(size(Parent::notifier()->id(key) + 1));	
+      }
+    }
+
+    virtual void add(const std::vector<Key>& keys) {
+      int new_size = 0;
+      for (int i = 0; i < int(keys.size()); ++i) {
+        if (size(Parent::notifier()->id(keys[i]) + 1) >= new_size) {
+          new_size = size(Parent::notifier()->id(keys[i]) + 1);	
+        }
+      }
+      if (new_size > int(values.size())) {
+        values.resize(new_size);
+      }
+    }
+
+    virtual void erase(const Key&) {}
+
+    virtual void erase(const std::vector<Key>&) {}
+
+    virtual void build() {
+      values.resize(size(Parent::notifier()->maxId() + 1));
+    }
+
+    virtual void clear() {
+      values.clear();
+    }   
+    
+  private:
+    std::vector<Value> values;
+  };
+  
+  ///\brief Dynamic Asymmetric Matrix Map.
+  ///
+  ///\ingroup matrices
+  ///Dynamic Asymmetric Matrix Map.  Container for store values for each
+  ///ordered pair of containers items.  This data structure can store
+  ///data with different key types from different container types. It
+  ///increases the size of the container if the linked containers
+  ///content change, so it is updated automaticly whenever it is
+  ///needed.
+  ///
+  ///This map meet with the concepts::ReferenceMatrixMap<typename K1,
+  ///typename K2, typename V, typename R, typename CR> called as
+  ///"ReferenceMatrixMap".
+  ///
+  ///\warning Do not use this map type when the two item sets are
+  ///equal or based on the same item set.
+  ///
+  ///\param _FirstContainer the desired type of first container. It is
+  ///ususally a Graph type, but can be any type with alteration
+  ///property.
+  ///  
+  ///\param _FirstContainerItem the nested type of the
+  ///FirstContainer. It is usually a graph item as Node, Edge,
+  ///etc. This type will be the FirstKey type.
+  ///
+  ///\param _SecondContainer the desired type of the second
+  ///container. It is usualy a Graph type, but can be any type with
+  ///alteration property.
+  ///
+  ///\param _SecondContainerItem the nested type of the
+  ///SecondContainer. It is usually a graph item such as Node, Edge,
+  ///UEdge, etc. This type will be the SecondKey type.
+  ///
+  ///\param _Value the type of the strored values in the container.
+  ///
+  /// \author Janos Nagy
+  template <typename _FirstContainer, typename _FirstContainerItem, 
+            typename _SecondContainer, typename _SecondContainerItem, 
+            typename _Value>
+  class DynamicAsymMatrixMap{
+  public:
+
+    ///The first key type.
+    typedef _FirstContainerItem FirstKey;
+      
+    ///The second key type.
+    typedef _SecondContainerItem SecondKey;
+      
+    ///The value type of the map.
+    typedef _Value Value;
+      
+    ///Indicates it is a reference map.
+    typedef True ReferenceMapTag;
+    
+  protected:
+      
+    ///\brief Proxy class for the first key type.
+    ///
+    ///The proxy class belongs to the FirstKey type. It is necessary because
+    ///if one want use the same conatainer types and same nested types but on
+    ///other instances of containers than due to the type equiality of nested
+    ///types it requires a proxy mechanism. 
+    class FirstKeyProxy 
+      : protected 
+    ItemSetTraits<_FirstContainer,_FirstContainerItem>::
+    ItemNotifier::ObserverBase 
+    {
+        
+    public:
+
+      friend class DynamicAsymMatrixMap;
+          
+      ///Constructor.
+      FirstKeyProxy(DynamicAsymMatrixMap& _map) : _owner(_map) { }
+    protected:
+
+      ///\brief Add a new FirstKey to the map.
+      ///
+      ///It adds a new FirstKey to the map. It is called by the
+      ///observer notifier and it is ovverride the add() virtual
+      ///member function in the observer base. It will call the
+      ///maps addFirstKey() function.
+      virtual void add(const FirstKey& _firstKey){
+        _owner.addFirstKey(_firstKey);
+      }
+          
+      ///\brief Add more new FirstKey to the map.
+      ///
+      ///It adds more new FirstKey to the map. It is called by the
+      ///observer notifier and it is ovverride the add() virtual
+      ///member function in the observer base. It will call the
+      ///map's addFirstKeys() function.
+      virtual void add(const std::vector<FirstKey>& _firstKeys){
+        _owner.addFirstKeys(_firstKeys);
+      }
+          
+      ///\brief Erase a FirstKey from the map.
+      ///
+      ///Erase a FirstKey from the map. It called by the observer
+      ///notifier and it overrides the erase() virtual member
+      ///function of the observer base. It will call the map's
+      ///eraseFirstKey() function.
+      virtual void erase(const FirstKey& _firstKey){
+        _owner.eraseFirstKey(_firstKey);
+      }
+          
+      ///\brief Erase more FirstKey from the map.
+      ///
+      ///Erase more FirstKey from the map. It called by the
+      ///observer notifier and it overrides the erase() virtual
+      ///member function of the observer base. It will call the
+      ///map's eraseFirstKeys() function.
+      virtual void erase(const std::vector<FirstKey>& _firstKeys){
+        _owner.eraseFirstKeys(_firstKeys);
+      }
+          
+      ///\brief Builds the map.
+      ///
+      ///It buildes the map. It called by the observer notifier
+      ///and it overrides the build() virtual member function of
+      ///the observer base.  It will call the map's build()
+      ///function.
+      virtual void build() {
+        _owner.build();
+        //_owner.buildFirst();
+      }
+          
+      ///\brief Clear the map.
+      ///
+      ///It erases all items from the map. It called by the
+      ///observer notifier and it overrides the clear() virtual
+      ///memeber function of the observer base. It will call the
+      ///map's clear() function.
+      virtual void clear() {
+        _owner.clear();
+        //_owner.clearFirst();
+      }
+    private:
+          
+      ///The map type for it is linked.
+      DynamicAsymMatrixMap& _owner;
+    };//END OF FIRSTKEYPROXY
+      
+      ///\brief Proxy class for the second key type.
+      ///
+      ///The proxy class belongs to the SecondKey type. It is
+      ///necessary because if one want use the same conatainer types
+      ///and same nested types but on other instances of containers
+      ///than due to the type equiality of nested types it requires a
+      ///proxy mechanism.
+    class SecondKeyProxy
+      : protected 
+    ItemSetTraits<_SecondContainer, _SecondContainerItem>::
+    ItemNotifier::ObserverBase {
+        
+    public:
+
+      friend class DynamicAsymMatrixMap;
+      ///Constructor.
+      SecondKeyProxy(DynamicAsymMatrixMap& _map) : _owner(_map) { }
+
+    protected:
+          
+      ///\brief Add a new SecondKey to the map.
+      ///
+      ///It adds a new SecondKey to the map. It is called by the
+      ///observer notifier and it is ovverride the add() virtual
+      ///member function in the observer base. It will call the
+      ///maps addSecondKey() function.
+      virtual void add(const SecondKey& _secondKey){
+        _owner.addSecondKey(_secondKey);
+      }
+    
+      ///\brief Add more new SecondKey to the map.
+      ///
+      ///It adds more new SecondKey to the map. It is called by
+      ///the observer notifier and it is ovverride the add()
+      ///virtual member function in the observer base. It will
+      ///call the maps addSecondKeys() function.
+      virtual void add(const std::vector<SecondKey>& _secondKeys){
+        _owner.addSecondKeys(_secondKeys);
+      }
+          
+      ///\brief Erase a SecondKey from the map.
+      ///
+      ///Erase a SecondKey from the map. It called by the observer
+      ///notifier and it overrides the erase() virtual member
+      ///function of the observer base. It will call the map's
+      ///eraseSecondKey() function.
+      virtual void erase(const SecondKey& _secondKey){
+        _owner.eraseSecondKey(_secondKey);
+      }
+          
+      ///\brief Erase more SecondKeys from the map.
+      ///
+      ///Erase more SecondKey from the map. It called by the
+      ///observer notifier and it overrides the erase() virtual
+      ///member function of the observer base. It will call the
+      ///map's eraseSecondKeys() function.
+      virtual void erase(const std::vector<SecondKey>& _secondKeys){
+        _owner.eraseSecondKeys(_secondKeys);
+      }
+          
+      ///\brief Builds the map.
+      ///
+      ///It buildes the map. It called by the observer notifier
+      ///and it overrides the build() virtual member function of
+      ///the observer base.  It will call the map's build()
+      ///function.
+      virtual void build() {
+        _owner.build();
+      }
+          
+      ///\brief Clear the map.
+      ///
+      ///It erases all items from the map. It called by the
+      ///observer notifier and it overrides the clear() virtual
+      ///memeber function of the observer base. It will call the
+      ///map's clear() function.
+      virtual void clear() {
+        _owner.clear();
+        //_owner.clearFirst();
+      }
+    private:
+          
+      ///The type of map for which it is attached.
+      DynamicAsymMatrixMap& _owner;
+    };//END OF SECONDKEYPROXY
+      
+  private:
+    
+    /// \e
+    typedef std::vector<Value> Container;
+      
+    ///The type of constainer which stores the values of the map.
+    typedef std::vector<Container> DContainer;
+
+    ///The std:vector type which contains the data
+    DContainer values;
+      
+    ///Member for the first proxy class
+    FirstKeyProxy _first_key_proxy;
+      
+    ///Member for the second proxy class
+    SecondKeyProxy _second_key_proxy;
+
+  public:
+    
+    ///The refernce type of the map.
+    typedef typename Container::reference Reference;
+      
+    ///The const reference type of the constainer.
+    typedef typename Container::const_reference ConstReference;
+
+    ///\brief Constructor what create the map for the two containers type.
+    ///
+    ///Creates the matrix map and initialize the values with Value()
+    DynamicAsymMatrixMap(const _FirstContainer& _firstContainer, 
+                  const _SecondContainer& _secondContainer)
+      : values(DContainer(_firstContainer.maxId(FirstKey())+1,
+                          Container(_secondContainer.maxId(SecondKey())+1))),
+        _first_key_proxy(*this),
+        _second_key_proxy(*this)
+    {
+      _first_key_proxy.attach(_firstContainer.notifier(FirstKey()));
+      _second_key_proxy.attach(_secondContainer.notifier(SecondKey()));
+    }
+
+    ///\brief Constructor what create the map for the two containers type.
+    ///
+    ///Creates the matrix map and initialize the values with the given _value
+    DynamicAsymMatrixMap(const _FirstContainer& _firstContainer, 
+                  const _SecondContainer& _secondContainer, 
+                  const Value& _value)
+      : values(DContainer(_firstContainer.maxId(FirstKey())+1,
+                          Container(_secondContainer.maxId(SecondKey())+1,
+                                    _value))),
+        _first_key_proxy(*this),
+        _second_key_proxy(*this)
+    {
+      _first_key_proxy.attach(_firstContainer.notifier(FirstKey()));
+      _second_key_proxy.attach(_secondContainer.notifier(SecondKey()));
+    }
+      
+    ///\brief Copy constructor.
+    ///
+    ///The copy constructor of the map.
+    DynamicAsymMatrixMap(const DynamicAsymMatrixMap& _copy) 
+      : _first_key_proxy(*this), _second_key_proxy(*this) {
+      if(_copy._first_key_proxy.attached() && 
+         _copy._second_key_proxy.attached()){
+        _first_key_proxy.attach(*_copy._first_key_proxy.notifier());
+        _second_key_proxy.attach(*_copy._second_key_proxy.notifier());
+        values = _copy.values;
+      }
+    }
+      
+    ///\brief Destructor
+    ///
+    ///Destructor what detach() from the attached objects.  May this
+    ///function is not necessary because the destructor of
+    ///ObserverBase do the same.
+    ~DynamicAsymMatrixMap() {
+      if(_first_key_proxy.attached()){
+        _first_key_proxy.detach();
+      }
+      if(_second_key_proxy.attached()){
+        _second_key_proxy.detach();
+      }
+    }
+      
+    ///\brief Gives back the value assigned to the \c first - \c
+    ///second ordered pair.
+    ///
+    ///Gives back the value assigned to the \c first - \c second
+    ///ordered pair.
+    Reference operator()(const FirstKey& _first, const SecondKey& _second) {
+      return values[_first_key_proxy.notifier()->id(_first)]
+        [_second_key_proxy.notifier()->id(_second)];
+    }
+
+    ///\brief Gives back the value assigned to the \c first - \c
+    ///second ordered pair.
+    ///
+    ///Gives back the value assigned to the \c first - \c second
+    ///ordered pair.
+    ConstReference operator()(const FirstKey& _first, 
+                              const SecondKey& _second) const {
+      return values[_first_key_proxy.notifier()->id(_first)]
+        [_second_key_proxy.notifier()->id(_second)];
+    }
+
+    ///\brief Setter function for this matrix map.
+    ///
+    ///Setter function for this matrix map.
+    void set(const FirstKey& first, const SecondKey& second, 
+             const Value& value){
+      values[_first_key_proxy.notifier()->id(first)]
+        [_second_key_proxy.notifier()->id(second)] = value;
+    }
+
+    ///\brief The assignement operator.
+    ///
+    ///It allow to assign a map to an other. It
+    DynamicAsymMatrixMap& operator=(const DynamicAsymMatrixMap& _cmap){
+      return operator=<DynamicAsymMatrixMap>(_cmap);
+    }
+      
+    ///\brief Template assignement operator.
+    ///
+    ///It copy the element of the given map to its own container.  The
+    ///type of the two map shall be the same.
+    template <typename CMap>
+    DynamicAsymMatrixMap& operator=(const CMap& _cdmap){
+      checkConcept<concepts::ReadMatrixMap<FirstKey, SecondKey, Value>, CMap>();
+      const typename FirstKeyProxy::Notifier* notifierFirstKey = 
+        _first_key_proxy.notifier();
+      const typename SecondKeyProxy::Notifier* notifierSecondKey = 
+        _second_key_proxy.notifier();
+      FirstKey itemFirst;
+      SecondKey itemSecond;
+      for(notifierFirstKey->first(itemFirst); itemFirst != INVALID; 
+          notifierFirstKey->next(itemFirst)){
+        for(notifierSecondKey->first(itemSecond); itemSecond != INVALID; 
+            notifierSecondKey->next(itemSecond)){
+          set(itemFirst, itemSecond, _cdmap(itemFirst,itemSecond));
+        }
+      }
+      return *this;
+    }
+      
+  protected:
+    
+    ///\brief Add a new FirstKey to the map.
+    ///
+    ///It adds a new FirstKey to the map. It is called by the observer
+    ///class belongs to the FirstKey type.
+    void addFirstKey(const FirstKey& firstKey) {
+      int size = int(values.size());
+      if( _first_key_proxy.notifier()->id(firstKey)+1 >= size ){
+        values.resize(_first_key_proxy.notifier()->id(firstKey)+1);
+        if( int(values[0].size()) != 0 ){
+          int innersize = int(values[0].size());
+          for(int i = size; i < int(values.size());++i){
+            (values[i]).resize(innersize);
+          }
+        }else if(_second_key_proxy.notifier()->maxId() >= 0){
+          int innersize = _second_key_proxy.notifier()->maxId();
+          for(int i = 0; i < int(values.size()); ++i){
+            values[0].resize(innersize);
+          }
+        }
+      }
+    }
+
+    ///\brief Adds more new FirstKeys to the map.
+    ///
+    ///It adds more new FirstKeys to the map. It called by the
+    ///observer class belongs to the FirstKey type.
+    void addFirstKeys(const std::vector<FirstKey>& firstKeys){
+      int max = values.size() - 1;
+      for(int i = 0; i < int(firstKeys.size()); ++i){
+        int id = _first_key_proxy.notifier()->id(firstKeys[i]);
+        if(max < id){
+          max = id;
+        }
+      }
+      int size = int(values.size());
+      if(max >= size){
+        values.resize(max + 1);
+        if( int(values[0].size()) != 0){
+          int innersize = int(values[0].size());
+          for(int i = size; i < (max + 1); ++i){
+            values[i].resize(innersize);
+          }
+        }else if(_second_key_proxy.notifier()->maxId() >= 0){
+          int innersize = _second_key_proxy.notifier()->maxId();
+          for(int i = 0; i < int(values.size()); ++i){
+            values[i].resize(innersize);
+          }
+        }
+      }
+    }
+
+    ///\brief Add a new SecondKey to the map.
+    ///
+    ///It adds a new SecondKey to the map. It is called by the
+    ///observer class belongs to the SecondKey type.
+    void addSecondKey(const SecondKey& secondKey) {
+      if(values.size() == 0){
+        return;
+      }
+      int id = _second_key_proxy.notifier()->id(secondKey);
+      if(id >= int(values[0].size())){
+        for(int i = 0; i < int(values.size());++i){
+          values[i].resize(id+1);
+        }
+      }
+    }
+        
+    ///\brief Adds more new SecondKeys to the map.
+    ///
+    ///It adds more new SecondKeys to the map. It called by the
+    ///observer class belongs to the SecondKey type.
+    void addSecondKeys(const std::vector<SecondKey>& secondKeys){
+      if(values.size() == 0){
+        return;
+      }
+      int max = values[0].size();
+      for(int i = 0; i < int(secondKeys.size()); ++i){
+        int id = _second_key_proxy.notifier()->id(secondKeys[i]);
+        if(max < id){
+          max = id;
+        }
+      }
+      if(max > int(values[0].size())){
+        for(int i = 0; i < int(values.size()); ++i){
+          values[i].resize(max + 1);
+        }
+      }
+    }
+    
+    ///\brief Erase a FirstKey from the map.
+    ///
+    ///Erase a FirstKey from the map. It called by the observer
+    ///class belongs to the FirstKey type.
+    void eraseFirstKey(const FirstKey& first) {
+      int id = _first_key_proxy.notifier()->id(first);
+      for(int i = 0; i < int(values[id].size()); ++i){
+        values[id][i] = Value();
+      }
+    }
+        
+    ///\brief Erase more FirstKey from the map.
+    ///
+    ///Erase more FirstKey from the map. It called by the observer
+    ///class belongs to the FirstKey type.
+    void eraseFirstKeys(const std::vector<FirstKey>& firstKeys) {
+      for(int j = 0; j < int(firstKeys.size()); ++j){
+        int id = _first_key_proxy.notifier()->id(firstKeys[j]);
+        for(int i = 0; i < int(values[id].size()); ++i){
+          values[id][i] = Value();
+        }
+      }
+    }
+
+    ///\brief Erase a SecondKey from the map.
+    ///
+    ///Erase a SecondKey from the map. It called by the observer class
+    ///belongs to the SecondKey type.
+    void eraseSecondKey(const SecondKey& second) {
+      if(values.size() == 0){
+        return;
+      }
+      int id = _second_key_proxy.notifier()->id(second);
+      for(int i = 0; i < int(values.size()); ++i){
+        values[i][id] = Value();
+      }
+    }
+        
+    ///\brief Erase more SecondKey from the map.
+    ///
+    ///Erase more SecondKey from the map. It called by the observer
+    ///class belongs to the SecondKey type.
+    void eraseSecondKeys(const std::vector<SecondKey>& secondKeys) {
+      if(values.size() == 0){
+        return;
+      }
+      for(int j = 0; j < int(secondKeys.size()); ++j){
+        int id = _second_key_proxy.notifier()->id(secondKeys[j]);
+        for(int i = 0; i < int(values.size()); ++i){
+          values[i][id] = Value();
+        }
+      }
+    }
+
+    ///\brief Builds the map.
+    ///
+    ///It buildes the map. It is called by the observer class belongs
+    ///to the FirstKey or SecondKey type.
+    void build() {
+      values.resize(_first_key_proxy.notifier()->maxId());
+      for(int i = 0; i< int(values.size()); ++i){
+        values[i].resize(_second_key_proxy.notifier()->maxId());
+      }
+    }
+    
+    ///\brief Clear the map.
+    ///
+    ///It erases all items from the map. It is called by the observer class
+    ///belongs to the FirstKey or SecondKey type.
+    void clear() {
+      for(int i = 0; i < int(values.size()); ++i) {
+        values[i].clear();
+      }
+      values.clear();
+    }
+ 
+  };
+
+
+
+}
+
+#endif
Index: lemon/max_matching.h
===================================================================
--- lemon/max_matching.h	(revision 2612)
+++ lemon/max_matching.h	(revision 2612)
@@ -0,0 +1,3122 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MAX_MATCHING_H
+#define LEMON_MAX_MATCHING_H
+
+#include <vector>
+#include <queue>
+#include <set>
+
+#include <lemon/bits/invalid.h>
+#include <lemon/unionfind.h>
+#include <lemon/graph_utils.h>
+#include <lemon/bin_heap.h>
+
+///\ingroup matching
+///\file
+///\brief Maximum matching algorithms in undirected graph.
+
+namespace lemon {
+
+  ///\ingroup matching
+  ///
+  ///\brief Edmonds' alternating forest maximum matching algorithm.
+  ///
+  ///This class provides Edmonds' alternating forest matching
+  ///algorithm. The starting matching (if any) can be passed to the
+  ///algorithm using some of init functions.
+  ///
+  ///The dual side of a matching is a map of the nodes to
+  ///MaxMatching::DecompType, having values \c D, \c A and \c C
+  ///showing the Gallai-Edmonds decomposition of the graph. The nodes
+  ///in \c D induce a graph with factor-critical components, the nodes
+  ///in \c A form the barrier, and the nodes in \c C induce a graph
+  ///having a perfect matching. This decomposition can be attained by
+  ///calling \c decomposition() after running the algorithm.
+  ///
+  ///\param Graph The undirected graph type the algorithm runs on.
+  ///
+  ///\author Jacint Szabo  
+  template <typename Graph>
+  class MaxMatching {
+
+  protected:
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+    typedef typename Graph::UEdgeIt UEdgeIt;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::IncEdgeIt IncEdgeIt;
+
+    typedef typename Graph::template NodeMap<int> UFECrossRef;
+    typedef UnionFindEnum<UFECrossRef> UFE;
+    typedef std::vector<Node> NV;
+
+    typedef typename Graph::template NodeMap<int> EFECrossRef;
+    typedef ExtendFindEnum<EFECrossRef> EFE;
+
+  public:
+    
+    ///\brief Indicates the Gallai-Edmonds decomposition of the graph.
+    ///
+    ///Indicates the Gallai-Edmonds decomposition of the graph, which
+    ///shows an upper bound on the size of a maximum matching. The
+    ///nodes with DecompType \c D induce a graph with factor-critical
+    ///components, the nodes in \c A form the canonical barrier, and the
+    ///nodes in \c C induce a graph having a perfect matching. 
+    enum DecompType {
+      D=0,
+      A=1,
+      C=2
+    }; 
+
+  protected:
+
+    static const int HEUR_density=2;
+    const Graph& g;
+    typename Graph::template NodeMap<Node> _mate;
+    typename Graph::template NodeMap<DecompType> position;
+     
+  public:
+    
+    MaxMatching(const Graph& _g) 
+      : g(_g), _mate(_g), position(_g) {}
+
+    ///\brief Sets the actual matching to the empty matching.
+    ///
+    ///Sets the actual matching to the empty matching.  
+    ///
+    void init() {
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	_mate.set(v,INVALID);      
+	position.set(v,C);
+      }
+    }
+
+    ///\brief Finds a greedy matching for initial matching.
+    ///
+    ///For initial matchig it finds a maximal greedy matching.
+    void greedyInit() {
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	_mate.set(v,INVALID);      
+	position.set(v,C);
+      }
+      for(NodeIt v(g); v!=INVALID; ++v)
+	if ( _mate[v]==INVALID ) {
+	  for( IncEdgeIt e(g,v); e!=INVALID ; ++e ) {
+	    Node y=g.runningNode(e);
+	    if ( _mate[y]==INVALID && y!=v ) {
+	      _mate.set(v,y);
+	      _mate.set(y,v);
+	      break;
+	    }
+	  }
+	} 
+    }
+
+    ///\brief Initialize the matching from each nodes' mate.
+    ///
+    ///Initialize the matching from a \c Node valued \c Node map. This
+    ///map must be \e symmetric, i.e. if \c map[u]==v then \c
+    ///map[v]==u must hold, and \c uv will be an edge of the initial
+    ///matching.
+    template <typename MateMap>
+    void mateMapInit(MateMap& map) {
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	_mate.set(v,map[v]);
+	position.set(v,C);
+      } 
+    }
+
+    ///\brief Initialize the matching from a node map with the
+    ///incident matching edges.
+    ///
+    ///Initialize the matching from an \c UEdge valued \c Node map. \c
+    ///map[v] must be an \c UEdge incident to \c v. This map must have
+    ///the property that if \c g.oppositeNode(u,map[u])==v then \c \c
+    ///g.oppositeNode(v,map[v])==u holds, and now some edge joining \c
+    ///u to \c v will be an edge of the matching.
+    template<typename MatchingMap>
+    void matchingMapInit(MatchingMap& map) {
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	position.set(v,C);
+	UEdge e=map[v];
+	if ( e!=INVALID )
+	  _mate.set(v,g.oppositeNode(v,e));
+	else 
+	  _mate.set(v,INVALID);
+      } 
+    } 
+
+    ///\brief Initialize the matching from the map containing the
+    ///undirected matching edges.
+    ///
+    ///Initialize the matching from a \c bool valued \c UEdge map. This
+    ///map must have the property that there are no two incident edges
+    ///\c e, \c f with \c map[e]==map[f]==true. The edges \c e with \c
+    ///map[e]==true form the matching.
+    template <typename MatchingMap>
+    void matchingInit(MatchingMap& map) {
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	_mate.set(v,INVALID);      
+	position.set(v,C);
+      }
+      for(UEdgeIt e(g); e!=INVALID; ++e) {
+	if ( map[e] ) {
+	  Node u=g.source(e);	  
+	  Node v=g.target(e);
+	  _mate.set(u,v);
+	  _mate.set(v,u);
+	} 
+      } 
+    }
+
+
+    ///\brief Runs Edmonds' algorithm.
+    ///
+    ///Runs Edmonds' algorithm for sparse graphs (number of edges <
+    ///2*number of nodes), and a heuristical Edmonds' algorithm with a
+    ///heuristic of postponing shrinks for dense graphs. 
+    void run() {
+      if (countUEdges(g) < HEUR_density * countNodes(g)) {
+	greedyInit();
+	startSparse();
+      } else {
+	init();
+	startDense();
+      }
+    }
+
+
+    ///\brief Starts Edmonds' algorithm.
+    /// 
+    ///If runs the original Edmonds' algorithm.  
+    void startSparse() {
+            
+      typename Graph::template NodeMap<Node> ear(g,INVALID); 
+      //undefined for the base nodes of the blossoms (i.e. for the
+      //representative elements of UFE blossom) and for the nodes in C 
+      
+      UFECrossRef blossom_base(g);
+      UFE blossom(blossom_base);
+      NV rep(countNodes(g));
+
+      EFECrossRef tree_base(g);
+      EFE tree(tree_base);
+
+      //If these UFE's would be members of the class then also
+      //blossom_base and tree_base should be a member.
+      
+      //We build only one tree and the other vertices uncovered by the
+      //matching belong to C. (They can be considered as singleton
+      //trees.) If this tree can be augmented or no more
+      //grow/augmentation/shrink is possible then we return to this
+      //"for" cycle.
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	if (position[v]==C && _mate[v]==INVALID) {
+	  rep[blossom.insert(v)] = v;
+	  tree.insert(v); 
+	  position.set(v,D);
+	  normShrink(v, ear, blossom, rep, tree);
+	}
+      }
+    }
+
+    ///\brief Starts Edmonds' algorithm.
+    /// 
+    ///It runs Edmonds' algorithm with a heuristic of postponing
+    ///shrinks, giving a faster algorithm for dense graphs.
+    void startDense() {
+            
+      typename Graph::template NodeMap<Node> ear(g,INVALID); 
+      //undefined for the base nodes of the blossoms (i.e. for the
+      //representative elements of UFE blossom) and for the nodes in C 
+      
+      UFECrossRef blossom_base(g);
+      UFE blossom(blossom_base);
+      NV rep(countNodes(g));
+
+      EFECrossRef tree_base(g);
+      EFE tree(tree_base);
+
+      //If these UFE's would be members of the class then also
+      //blossom_base and tree_base should be a member.
+      
+      //We build only one tree and the other vertices uncovered by the
+      //matching belong to C. (They can be considered as singleton
+      //trees.) If this tree can be augmented or no more
+      //grow/augmentation/shrink is possible then we return to this
+      //"for" cycle.
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	if ( position[v]==C && _mate[v]==INVALID ) {
+	  rep[blossom.insert(v)] = v;
+	  tree.insert(v); 
+	  position.set(v,D);
+	  lateShrink(v, ear, blossom, rep, tree);
+	}
+      }
+    }
+
+
+
+    ///\brief Returns the size of the actual matching stored.
+    ///
+    ///Returns the size of the actual matching stored. After \ref
+    ///run() it returns the size of a maximum matching in the graph.
+    int size() const {
+      int s=0;
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	if ( _mate[v]!=INVALID ) {
+	  ++s;
+	}
+      }
+      return s/2;
+    }
+
+
+    ///\brief Returns the mate of a node in the actual matching.
+    ///
+    ///Returns the mate of a \c node in the actual matching. 
+    ///Returns INVALID if the \c node is not covered by the actual matching. 
+    Node mate(const Node& node) const {
+      return _mate[node];
+    } 
+
+    ///\brief Returns the matching edge incident to the given node.
+    ///
+    ///Returns the matching edge of a \c node in the actual matching. 
+    ///Returns INVALID if the \c node is not covered by the actual matching. 
+    UEdge matchingEdge(const Node& node) const {
+      if (_mate[node] == INVALID) return INVALID;
+      Node n = node < _mate[node] ? node : _mate[node];
+      for (IncEdgeIt e(g, n); e != INVALID; ++e) {
+	if (g.oppositeNode(n, e) == _mate[n]) {
+	  return e;
+	}
+      }
+      return INVALID;
+    } 
+
+    /// \brief Returns the class of the node in the Edmonds-Gallai
+    /// decomposition.
+    ///
+    /// Returns the class of the node in the Edmonds-Gallai
+    /// decomposition.
+    DecompType decomposition(const Node& n) {
+      return position[n] == A;
+    }
+
+    /// \brief Returns true when the node is in the barrier.
+    ///
+    /// Returns true when the node is in the barrier.
+    bool barrier(const Node& n) {
+      return position[n] == A;
+    }
+    
+    ///\brief Gives back the matching in a \c Node of mates.
+    ///
+    ///Writes the stored matching to a \c Node valued \c Node map. The
+    ///resulting map will be \e symmetric, i.e. if \c map[u]==v then \c
+    ///map[v]==u will hold, and now \c uv is an edge of the matching.
+    template <typename MateMap>
+    void mateMap(MateMap& map) const {
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	map.set(v,_mate[v]);   
+      } 
+    } 
+    
+    ///\brief Gives back the matching in an \c UEdge valued \c Node
+    ///map.
+    ///
+    ///Writes the stored matching to an \c UEdge valued \c Node
+    ///map. \c map[v] will be an \c UEdge incident to \c v. This
+    ///map will have the property that if \c g.oppositeNode(u,map[u])
+    ///== v then \c map[u]==map[v] holds, and now this edge is an edge
+    ///of the matching.
+    template <typename MatchingMap>
+    void matchingMap(MatchingMap& map)  const {
+      typename Graph::template NodeMap<bool> todo(g,true); 
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	if (_mate[v]!=INVALID && v < _mate[v]) {
+	  Node u=_mate[v];
+	  for(IncEdgeIt e(g,v); e!=INVALID; ++e) {
+	    if ( g.runningNode(e) == u ) {
+	      map.set(u,e);
+	      map.set(v,e);
+	      todo.set(u,false);
+	      todo.set(v,false);
+	      break;
+	    }
+	  }
+	}
+      } 
+    }
+
+
+    ///\brief Gives back the matching in a \c bool valued \c UEdge
+    ///map.
+    ///
+    ///Writes the matching stored to a \c bool valued \c Edge
+    ///map. This map will have the property that there are no two
+    ///incident edges \c e, \c f with \c map[e]==map[f]==true. The
+    ///edges \c e with \c map[e]==true form the matching.
+    template<typename MatchingMap>
+    void matching(MatchingMap& map) const {
+      for(UEdgeIt e(g); e!=INVALID; ++e) map.set(e,false);
+
+      typename Graph::template NodeMap<bool> todo(g,true); 
+      for(NodeIt v(g); v!=INVALID; ++v) {
+	if ( todo[v] && _mate[v]!=INVALID ) {
+	  Node u=_mate[v];
+	  for(IncEdgeIt e(g,v); e!=INVALID; ++e) {
+	    if ( g.runningNode(e) == u ) {
+	      map.set(e,true);
+	      todo.set(u,false);
+	      todo.set(v,false);
+	      break;
+	    }
+	  }
+	}
+      } 
+    }
+
+
+    ///\brief Returns the canonical decomposition of the graph after running
+    ///the algorithm.
+    ///
+    ///After calling any run methods of the class, it writes the
+    ///Gallai-Edmonds canonical decomposition of the graph. \c map
+    ///must be a node map of \ref DecompType 's.
+    template <typename DecompositionMap>
+    void decomposition(DecompositionMap& map) const {
+      for(NodeIt v(g); v!=INVALID; ++v) map.set(v,position[v]);
+    }
+
+    ///\brief Returns a barrier on the nodes.
+    ///
+    ///After calling any run methods of the class, it writes a
+    ///canonical barrier on the nodes. The odd component number of the
+    ///remaining graph minus the barrier size is a lower bound for the
+    ///uncovered nodes in the graph. The \c map must be a node map of
+    ///bools.
+    template <typename BarrierMap>
+    void barrier(BarrierMap& barrier) {
+      for(NodeIt v(g); v!=INVALID; ++v) barrier.set(v,position[v] == A);    
+    }
+
+  private: 
+
+ 
+    void lateShrink(Node v, typename Graph::template NodeMap<Node>& ear,  
+		    UFE& blossom, NV& rep, EFE& tree) {
+      //We have one tree which we grow, and also shrink but only if it
+      //cannot be postponed. If we augment then we return to the "for"
+      //cycle of runEdmonds().
+
+      std::queue<Node> Q;   //queue of the totally unscanned nodes
+      Q.push(v);  
+      std::queue<Node> R;   
+      //queue of the nodes which must be scanned for a possible shrink
+      
+      while ( !Q.empty() ) {
+	Node x=Q.front();
+	Q.pop();
+	for( IncEdgeIt e(g,x); e!= INVALID; ++e ) {
+	  Node y=g.runningNode(e);
+	  //growOrAugment grows if y is covered by the matching and
+	  //augments if not. In this latter case it returns 1.
+	  if (position[y]==C && 
+	      growOrAugment(y, x, ear, blossom, rep, tree, Q)) return;
+	}
+	R.push(x);
+      }
+      
+      while ( !R.empty() ) {
+	Node x=R.front();
+	R.pop();
+	
+	for( IncEdgeIt e(g,x); e!=INVALID ; ++e ) {
+	  Node y=g.runningNode(e);
+
+	  if ( position[y] == D && blossom.find(x) != blossom.find(y) )  
+	    //Recall that we have only one tree.
+	    shrink( x, y, ear, blossom, rep, tree, Q);	
+	
+	  while ( !Q.empty() ) {
+	    Node z=Q.front();
+	    Q.pop();
+	    for( IncEdgeIt f(g,z); f!= INVALID; ++f ) {
+	      Node w=g.runningNode(f);
+	      //growOrAugment grows if y is covered by the matching and
+	      //augments if not. In this latter case it returns 1.
+	      if (position[w]==C && 
+		  growOrAugment(w, z, ear, blossom, rep, tree, Q)) return;
+	    }
+	    R.push(z);
+	  }
+	} //for e
+      } // while ( !R.empty() )
+    }
+
+    void normShrink(Node v, typename Graph::template NodeMap<Node>& ear,  
+		    UFE& blossom, NV& rep, EFE& tree) {
+      //We have one tree, which we grow and shrink. If we augment then we
+      //return to the "for" cycle of runEdmonds().
+    
+      std::queue<Node> Q;   //queue of the unscanned nodes
+      Q.push(v);  
+      while ( !Q.empty() ) {
+
+	Node x=Q.front();
+	Q.pop();
+	
+	for( IncEdgeIt e(g,x); e!=INVALID; ++e ) {
+	  Node y=g.runningNode(e);
+	      
+	  switch ( position[y] ) {
+	  case D:          //x and y must be in the same tree
+	    if ( blossom.find(x) != blossom.find(y))
+	      //x and y are in the same tree
+	      shrink(x, y, ear, blossom, rep, tree, Q);
+	    break;
+	  case C:
+	    //growOrAugment grows if y is covered by the matching and
+	    //augments if not. In this latter case it returns 1.
+	    if (growOrAugment(y, x, ear, blossom, rep, tree, Q)) return;
+	    break;
+	  default: break;
+	  }
+	}
+      }
+    }
+
+    void shrink(Node x,Node y, typename Graph::template NodeMap<Node>& ear,  
+		UFE& blossom, NV& rep, EFE& tree,std::queue<Node>& Q) {
+      //x and y are the two adjacent vertices in two blossoms.
+   
+      typename Graph::template NodeMap<bool> path(g,false);
+    
+      Node b=rep[blossom.find(x)];
+      path.set(b,true);
+      b=_mate[b];
+      while ( b!=INVALID ) { 
+	b=rep[blossom.find(ear[b])];
+	path.set(b,true);
+	b=_mate[b];
+      } //we go until the root through bases of blossoms and odd vertices
+    
+      Node top=y;
+      Node middle=rep[blossom.find(top)];
+      Node bottom=x;
+      while ( !path[middle] )
+	shrinkStep(top, middle, bottom, ear, blossom, rep, tree, Q);
+      //Until we arrive to a node on the path, we update blossom, tree
+      //and the positions of the odd nodes.
+    
+      Node base=middle;
+      top=x;
+      middle=rep[blossom.find(top)];
+      bottom=y;
+      Node blossom_base=rep[blossom.find(base)];
+      while ( middle!=blossom_base )
+	shrinkStep(top, middle, bottom, ear, blossom, rep, tree, Q);
+      //Until we arrive to a node on the path, we update blossom, tree
+      //and the positions of the odd nodes.
+    
+      rep[blossom.find(base)] = base;
+    }
+
+    void shrinkStep(Node& top, Node& middle, Node& bottom,
+		    typename Graph::template NodeMap<Node>& ear,  
+		    UFE& blossom, NV& rep, EFE& tree, std::queue<Node>& Q) {
+      //We traverse a blossom and update everything.
+    
+      ear.set(top,bottom);
+      Node t=top;
+      while ( t!=middle ) {
+	Node u=_mate[t];
+	t=ear[u];
+	ear.set(t,u);
+      } 
+      bottom=_mate[middle];
+      position.set(bottom,D);
+      Q.push(bottom);
+      top=ear[bottom];		
+      Node oldmiddle=middle;
+      middle=rep[blossom.find(top)];
+      tree.erase(bottom);
+      tree.erase(oldmiddle);
+      blossom.insert(bottom);
+      blossom.join(bottom, oldmiddle);
+      blossom.join(top, oldmiddle);
+    }
+
+
+
+    bool growOrAugment(Node& y, Node& x, typename Graph::template 
+		       NodeMap<Node>& ear, UFE& blossom, NV& rep, EFE& tree, 
+		       std::queue<Node>& Q) {
+      //x is in a blossom in the tree, y is outside. If y is covered by
+      //the matching we grow, otherwise we augment. In this case we
+      //return 1.
+    
+      if ( _mate[y]!=INVALID ) {       //grow
+	ear.set(y,x);
+	Node w=_mate[y];
+	rep[blossom.insert(w)] = w;
+	position.set(y,A);
+	position.set(w,D);
+	int t = tree.find(rep[blossom.find(x)]);
+	tree.insert(y,t);  
+	tree.insert(w,t);  
+	Q.push(w);
+      } else {                      //augment 
+	augment(x, ear, blossom, rep, tree);
+	_mate.set(x,y);
+	_mate.set(y,x);
+	return true;
+      }
+      return false;
+    }
+
+    void augment(Node x, typename Graph::template NodeMap<Node>& ear,  
+		 UFE& blossom, NV& rep, EFE& tree) {
+      Node v=_mate[x];
+      while ( v!=INVALID ) {
+	
+	Node u=ear[v];
+	_mate.set(v,u);
+	Node tmp=v;
+	v=_mate[u];
+	_mate.set(u,tmp);
+      }
+      int y = tree.find(rep[blossom.find(x)]);
+      for (typename EFE::ItemIt tit(tree, y); tit != INVALID; ++tit) {   
+	if ( position[tit] == D ) {
+	  int b = blossom.find(tit);
+	  for (typename UFE::ItemIt bit(blossom, b); bit != INVALID; ++bit) { 
+	    position.set(bit, C);
+	  }
+	  blossom.eraseClass(b);
+	} else position.set(tit, C);
+      }
+      tree.eraseClass(y);
+
+    }
+
+  };
+
+  /// \ingroup matching
+  ///
+  /// \brief Weighted matching in general undirected graphs
+  ///
+  /// This class provides an efficient implementation of Edmond's
+  /// maximum weighted matching algorithm. The implementation is based
+  /// on extensive use of priority queues and provides
+  /// \f$O(nm\log(n))\f$ time complexity.
+  ///
+  /// The maximum weighted matching problem is to find undirected
+  /// edges in the graph with maximum overall weight and no two of
+  /// them shares their endpoints. The problem can be formulated with
+  /// the next linear program: 
+  /// \f[ \sum_{e \in \delta(u)}x_e \le 1 \quad \forall u\in V\f]
+  ///\f[ \sum_{e \in \gamma(B)}x_e \le \frac{\vert B \vert - 1}{2} \quad \forall B\in\mathcal{O}\f] 
+  /// \f[x_e \ge 0\quad \forall e\in E\f]
+  /// \f[\max \sum_{e\in E}x_ew_e\f]
+  /// where \f$\delta(X)\f$ is the set of edges incident to a node in
+  /// \f$X\f$, \f$\gamma(X)\f$ is the set of edges with both endpoints in
+  /// \f$X\f$ and \f$\mathcal{O}\f$ is the set of odd cardinality subsets of
+  /// the nodes.
+  ///
+  /// The algorithm calculates an optimal matching and a proof of the
+  /// optimality. The solution of the dual problem can be used to check
+  /// the result of the algorithm. The dual linear problem is the next:
+  /// \f[ y_u + y_v + \sum_{B \in \mathcal{O}, uv \in \gamma(B)}z_B \ge w_{uv} \quad \forall uv\in E\f]
+  /// \f[y_u \ge 0 \quad \forall u \in V\f]
+  /// \f[z_B \ge 0 \quad \forall B \in \mathcal{O}\f]
+  /// \f[\min \sum_{u \in V}y_u + \sum_{B \in \mathcal{O}}\frac{\vert B \vert - 1}{2}z_B\f]
+  ///
+  /// The algorithm can be executed with \c run() or the \c init() and
+  /// then the \c start() member functions. After it the matching can
+  /// be asked with \c matching() or mate() functions. The dual
+  /// solution can be get with \c nodeValue(), \c blossomNum() and \c
+  /// blossomValue() members and \ref MaxWeightedMatching::BlossomIt
+  /// "BlossomIt" nested class which is able to iterate on the nodes
+  /// of a blossom. If the value type is integral then the dual
+  /// solution is multiplied by \ref MaxWeightedMatching::dualScale "4".
+  ///
+  /// \author Balazs Dezso
+  template <typename _UGraph, 
+	    typename _WeightMap = typename _UGraph::template UEdgeMap<int> >
+  class MaxWeightedMatching {
+  public:
+
+    typedef _UGraph UGraph;
+    typedef _WeightMap WeightMap;
+    typedef typename WeightMap::Value Value;
+
+    /// \brief Scaling factor for dual solution
+    ///
+    /// Scaling factor for dual solution, it is equal to 4 or 1
+    /// according to the value type.
+    static const int dualScale = 
+      std::numeric_limits<Value>::is_integer ? 4 : 1;
+
+    typedef typename UGraph::template NodeMap<typename UGraph::Edge> 
+    MatchingMap;
+    
+  private:
+
+    UGRAPH_TYPEDEFS(typename UGraph);
+
+    typedef typename UGraph::template NodeMap<Value> NodePotential;
+    typedef std::vector<Node> BlossomNodeList;
+
+    struct BlossomVariable {
+      int begin, end;
+      Value value;
+      
+      BlossomVariable(int _begin, int _end, Value _value)
+        : begin(_begin), end(_end), value(_value) {}
+
+    };
+
+    typedef std::vector<BlossomVariable> BlossomPotential;
+
+    const UGraph& _ugraph;
+    const WeightMap& _weight;
+
+    MatchingMap* _matching;
+
+    NodePotential* _node_potential;
+
+    BlossomPotential _blossom_potential;
+    BlossomNodeList _blossom_node_list;
+
+    int _node_num;
+    int _blossom_num;
+
+    typedef typename UGraph::template NodeMap<int> NodeIntMap;
+    typedef typename UGraph::template EdgeMap<int> EdgeIntMap;
+    typedef typename UGraph::template UEdgeMap<int> UEdgeIntMap;
+    typedef IntegerMap<int> IntIntMap;
+
+    enum Status {
+      EVEN = -1, MATCHED = 0, ODD = 1, UNMATCHED = -2
+    };
+
+    typedef HeapUnionFind<Value, NodeIntMap> BlossomSet;
+    struct BlossomData {
+      int tree;
+      Status status;
+      Edge pred, next;
+      Value pot, offset;
+      Node base;
+    };
+
+    NodeIntMap *_blossom_index;
+    BlossomSet *_blossom_set;
+    IntegerMap<BlossomData>* _blossom_data;
+
+    NodeIntMap *_node_index;
+    EdgeIntMap *_node_heap_index;
+
+    struct NodeData {
+      
+      NodeData(EdgeIntMap& node_heap_index) 
+	: heap(node_heap_index) {}
+      
+      int blossom;
+      Value pot;
+      BinHeap<Value, EdgeIntMap> heap;
+      std::map<int, Edge> heap_index;
+      
+      int tree;
+    };
+
+    IntegerMap<NodeData>* _node_data;
+
+    typedef ExtendFindEnum<IntIntMap> TreeSet;
+
+    IntIntMap *_tree_set_index;
+    TreeSet *_tree_set;
+
+    NodeIntMap *_delta1_index;
+    BinHeap<Value, NodeIntMap> *_delta1;
+
+    IntIntMap *_delta2_index;
+    BinHeap<Value, IntIntMap> *_delta2;
+    
+    UEdgeIntMap *_delta3_index;
+    BinHeap<Value, UEdgeIntMap> *_delta3;
+
+    IntIntMap *_delta4_index;
+    BinHeap<Value, IntIntMap> *_delta4;
+
+    Value _delta_sum;
+
+    void createStructures() {
+      _node_num = countNodes(_ugraph); 
+      _blossom_num = _node_num * 3 / 2;
+
+      if (!_matching) {
+	_matching = new MatchingMap(_ugraph);
+      }
+      if (!_node_potential) {
+	_node_potential = new NodePotential(_ugraph);
+      }
+      if (!_blossom_set) {
+	_blossom_index = new NodeIntMap(_ugraph);
+	_blossom_set = new BlossomSet(*_blossom_index);
+	_blossom_data = new IntegerMap<BlossomData>(_blossom_num);
+      }
+
+      if (!_node_index) {
+	_node_index = new NodeIntMap(_ugraph);
+	_node_heap_index = new EdgeIntMap(_ugraph);
+	_node_data = new IntegerMap<NodeData>(_node_num, 
+					      NodeData(*_node_heap_index));
+      }
+
+      if (!_tree_set) {
+	_tree_set_index = new IntIntMap(_blossom_num);
+	_tree_set = new TreeSet(*_tree_set_index);
+      }
+      if (!_delta1) {
+	_delta1_index = new NodeIntMap(_ugraph);
+	_delta1 = new BinHeap<Value, NodeIntMap>(*_delta1_index);
+      }
+      if (!_delta2) {
+	_delta2_index = new IntIntMap(_blossom_num);
+	_delta2 = new BinHeap<Value, IntIntMap>(*_delta2_index);
+      }
+      if (!_delta3) {
+	_delta3_index = new UEdgeIntMap(_ugraph);
+	_delta3 = new BinHeap<Value, UEdgeIntMap>(*_delta3_index);
+      }
+      if (!_delta4) {
+	_delta4_index = new IntIntMap(_blossom_num);
+	_delta4 = new BinHeap<Value, IntIntMap>(*_delta4_index);
+      }
+    }
+
+    void destroyStructures() {
+      _node_num = countNodes(_ugraph); 
+      _blossom_num = _node_num * 3 / 2;
+
+      if (_matching) {
+	delete _matching;
+      }
+      if (_node_potential) {
+	delete _node_potential;
+      }
+      if (_blossom_set) {
+	delete _blossom_index;
+	delete _blossom_set;
+	delete _blossom_data;
+      }
+
+      if (_node_index) {
+	delete _node_index;
+	delete _node_heap_index;
+	delete _node_data;			      
+      }
+
+      if (_tree_set) {
+	delete _tree_set_index;
+	delete _tree_set;
+      }
+      if (_delta1) {
+	delete _delta1_index;
+	delete _delta1;
+      }
+      if (_delta2) {
+	delete _delta2_index;
+	delete _delta2;
+      }
+      if (_delta3) {
+	delete _delta3_index;
+	delete _delta3;
+      }
+      if (_delta4) {
+	delete _delta4_index;
+	delete _delta4;
+      }
+    }
+
+    void matchedToEven(int blossom, int tree) {
+      if (_delta2->state(blossom) == _delta2->IN_HEAP) {
+	_delta2->erase(blossom);
+      }
+
+      if (!_blossom_set->trivial(blossom)) {
+	(*_blossom_data)[blossom].pot -= 
+	  2 * (_delta_sum - (*_blossom_data)[blossom].offset);
+      }
+
+      for (typename BlossomSet::ItemIt n(*_blossom_set, blossom); 
+	   n != INVALID; ++n) {
+
+	_blossom_set->increase(n, std::numeric_limits<Value>::max());
+	int ni = (*_node_index)[n];
+
+	(*_node_data)[ni].heap.clear();
+	(*_node_data)[ni].heap_index.clear();
+
+	(*_node_data)[ni].pot += _delta_sum - (*_blossom_data)[blossom].offset;
+
+	_delta1->push(n, (*_node_data)[ni].pot);
+
+	for (InEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node v = _ugraph.source(e);
+	  int vb = _blossom_set->find(v);
+	  int vi = (*_node_index)[v];
+
+	  Value rw = (*_node_data)[ni].pot + (*_node_data)[vi].pot - 
+	    dualScale * _weight[e];
+
+	  if ((*_blossom_data)[vb].status == EVEN) {
+	    if (_delta3->state(e) != _delta3->IN_HEAP && blossom != vb) {
+	      _delta3->push(e, rw / 2);
+	    }
+	  } else if ((*_blossom_data)[vb].status == UNMATCHED) {
+	    if (_delta3->state(e) != _delta3->IN_HEAP) {
+	      _delta3->push(e, rw);
+	    }	    
+	  } else {
+	    typename std::map<int, Edge>::iterator it = 
+	      (*_node_data)[vi].heap_index.find(tree);	  
+
+	    if (it != (*_node_data)[vi].heap_index.end()) {
+	      if ((*_node_data)[vi].heap[it->second] > rw) {
+		(*_node_data)[vi].heap.replace(it->second, e);
+		(*_node_data)[vi].heap.decrease(e, rw);
+		it->second = e;
+	      }
+	    } else {
+	      (*_node_data)[vi].heap.push(e, rw);
+	      (*_node_data)[vi].heap_index.insert(std::make_pair(tree, e));
+	    }
+
+	    if ((*_blossom_set)[v] > (*_node_data)[vi].heap.prio()) {
+	      _blossom_set->decrease(v, (*_node_data)[vi].heap.prio());
+
+	      if ((*_blossom_data)[vb].status == MATCHED) {
+		if (_delta2->state(vb) != _delta2->IN_HEAP) {
+		  _delta2->push(vb, _blossom_set->classPrio(vb) -
+			       (*_blossom_data)[vb].offset);
+		} else if ((*_delta2)[vb] > _blossom_set->classPrio(vb) -
+			   (*_blossom_data)[vb].offset){
+		  _delta2->decrease(vb, _blossom_set->classPrio(vb) -
+				   (*_blossom_data)[vb].offset);
+		}
+	      }
+	    }
+	  }
+	}
+      }
+      (*_blossom_data)[blossom].offset = 0;
+    }
+
+    void matchedToOdd(int blossom) {
+      if (_delta2->state(blossom) == _delta2->IN_HEAP) {
+	_delta2->erase(blossom);
+      }
+      (*_blossom_data)[blossom].offset += _delta_sum;
+      if (!_blossom_set->trivial(blossom)) {
+	_delta4->push(blossom, (*_blossom_data)[blossom].pot / 2 + 
+		     (*_blossom_data)[blossom].offset);
+      }
+    }
+
+    void evenToMatched(int blossom, int tree) {
+      if (!_blossom_set->trivial(blossom)) {
+	(*_blossom_data)[blossom].pot += 2 * _delta_sum;
+      }
+
+      for (typename BlossomSet::ItemIt n(*_blossom_set, blossom);
+	   n != INVALID; ++n) {
+	int ni = (*_node_index)[n];
+	(*_node_data)[ni].pot -= _delta_sum;
+
+	_delta1->erase(n);
+
+	for (InEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node v = _ugraph.source(e);
+	  int vb = _blossom_set->find(v);
+	  int vi = (*_node_index)[v];
+
+	  Value rw = (*_node_data)[ni].pot + (*_node_data)[vi].pot - 
+	    dualScale * _weight[e];
+
+	  if (vb == blossom) {
+	    if (_delta3->state(e) == _delta3->IN_HEAP) {
+	      _delta3->erase(e);
+	    }
+	  } else if ((*_blossom_data)[vb].status == EVEN) {
+
+	    if (_delta3->state(e) == _delta3->IN_HEAP) {
+	      _delta3->erase(e);
+	    }
+
+	    int vt = _tree_set->find(vb);
+	    
+	    if (vt != tree) {
+
+	      Edge r = _ugraph.oppositeEdge(e);
+
+	      typename std::map<int, Edge>::iterator it = 
+		(*_node_data)[ni].heap_index.find(vt);	  
+
+	      if (it != (*_node_data)[ni].heap_index.end()) {
+		if ((*_node_data)[ni].heap[it->second] > rw) {
+		  (*_node_data)[ni].heap.replace(it->second, r);
+		  (*_node_data)[ni].heap.decrease(r, rw);
+		  it->second = r;
+		}
+	      } else {
+		(*_node_data)[ni].heap.push(r, rw);
+		(*_node_data)[ni].heap_index.insert(std::make_pair(vt, r));
+	      }
+	      
+	      if ((*_blossom_set)[n] > (*_node_data)[ni].heap.prio()) {
+		_blossom_set->decrease(n, (*_node_data)[ni].heap.prio());
+		
+		if (_delta2->state(blossom) != _delta2->IN_HEAP) {
+		  _delta2->push(blossom, _blossom_set->classPrio(blossom) - 
+			       (*_blossom_data)[blossom].offset);
+		} else if ((*_delta2)[blossom] > 
+			   _blossom_set->classPrio(blossom) - 
+			   (*_blossom_data)[blossom].offset){
+		  _delta2->decrease(blossom, _blossom_set->classPrio(blossom) -
+				   (*_blossom_data)[blossom].offset);
+		}
+	      }
+	    }
+	    
+	  } else if ((*_blossom_data)[vb].status == UNMATCHED) {
+	    if (_delta3->state(e) == _delta3->IN_HEAP) {
+	      _delta3->erase(e);
+	    }
+	  } else {
+	  
+	    typename std::map<int, Edge>::iterator it = 
+	      (*_node_data)[vi].heap_index.find(tree);
+
+	    if (it != (*_node_data)[vi].heap_index.end()) {
+	      (*_node_data)[vi].heap.erase(it->second);
+	      (*_node_data)[vi].heap_index.erase(it);
+	      if ((*_node_data)[vi].heap.empty()) {
+		_blossom_set->increase(v, std::numeric_limits<Value>::max());
+	      } else if ((*_blossom_set)[v] < (*_node_data)[vi].heap.prio()) {
+		_blossom_set->increase(v, (*_node_data)[vi].heap.prio());
+	      }
+	      
+	      if ((*_blossom_data)[vb].status == MATCHED) {
+		if (_blossom_set->classPrio(vb) == 
+		    std::numeric_limits<Value>::max()) {
+		  _delta2->erase(vb);
+		} else if ((*_delta2)[vb] < _blossom_set->classPrio(vb) -
+			   (*_blossom_data)[vb].offset) {
+		  _delta2->increase(vb, _blossom_set->classPrio(vb) -
+				   (*_blossom_data)[vb].offset);
+		}
+	      }	
+	    }	
+	  }
+	}
+      }
+    }
+
+    void oddToMatched(int blossom) {
+      (*_blossom_data)[blossom].offset -= _delta_sum;
+
+      if (_blossom_set->classPrio(blossom) != 
+	  std::numeric_limits<Value>::max()) {
+	_delta2->push(blossom, _blossom_set->classPrio(blossom) - 
+		       (*_blossom_data)[blossom].offset);
+      }
+
+      if (!_blossom_set->trivial(blossom)) {
+	_delta4->erase(blossom);
+      }
+    }
+
+    void oddToEven(int blossom, int tree) {
+      if (!_blossom_set->trivial(blossom)) {
+	_delta4->erase(blossom);
+	(*_blossom_data)[blossom].pot -= 
+	  2 * (2 * _delta_sum - (*_blossom_data)[blossom].offset);
+      }
+
+      for (typename BlossomSet::ItemIt n(*_blossom_set, blossom); 
+	   n != INVALID; ++n) {
+	int ni = (*_node_index)[n];
+
+	_blossom_set->increase(n, std::numeric_limits<Value>::max());
+
+	(*_node_data)[ni].heap.clear();
+	(*_node_data)[ni].heap_index.clear();
+	(*_node_data)[ni].pot += 
+	  2 * _delta_sum - (*_blossom_data)[blossom].offset;
+
+	_delta1->push(n, (*_node_data)[ni].pot);
+
+	for (InEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node v = _ugraph.source(e);
+	  int vb = _blossom_set->find(v);
+	  int vi = (*_node_index)[v];
+
+	  Value rw = (*_node_data)[ni].pot + (*_node_data)[vi].pot - 
+	    dualScale * _weight[e];
+
+	  if ((*_blossom_data)[vb].status == EVEN) {
+	    if (_delta3->state(e) != _delta3->IN_HEAP && blossom != vb) {
+	      _delta3->push(e, rw / 2);
+	    }
+	  } else if ((*_blossom_data)[vb].status == UNMATCHED) {
+	    if (_delta3->state(e) != _delta3->IN_HEAP) {
+	      _delta3->push(e, rw);
+	    }
+	  } else {
+	  
+	    typename std::map<int, Edge>::iterator it = 
+	      (*_node_data)[vi].heap_index.find(tree);	  
+
+	    if (it != (*_node_data)[vi].heap_index.end()) {
+	      if ((*_node_data)[vi].heap[it->second] > rw) {
+		(*_node_data)[vi].heap.replace(it->second, e);
+		(*_node_data)[vi].heap.decrease(e, rw);
+		it->second = e;
+	      }
+	    } else {
+	      (*_node_data)[vi].heap.push(e, rw);
+	      (*_node_data)[vi].heap_index.insert(std::make_pair(tree, e));
+	    }
+
+	    if ((*_blossom_set)[v] > (*_node_data)[vi].heap.prio()) {
+	      _blossom_set->decrease(v, (*_node_data)[vi].heap.prio());
+
+	      if ((*_blossom_data)[vb].status == MATCHED) {
+		if (_delta2->state(vb) != _delta2->IN_HEAP) {
+		  _delta2->push(vb, _blossom_set->classPrio(vb) - 
+			       (*_blossom_data)[vb].offset);
+		} else if ((*_delta2)[vb] > _blossom_set->classPrio(vb) - 
+			   (*_blossom_data)[vb].offset) {
+		  _delta2->decrease(vb, _blossom_set->classPrio(vb) -
+				   (*_blossom_data)[vb].offset);
+		}
+	      }
+	    }
+	  }
+	}
+      }
+      (*_blossom_data)[blossom].offset = 0;
+    }
+
+
+    void matchedToUnmatched(int blossom) {
+      if (_delta2->state(blossom) == _delta2->IN_HEAP) {
+	_delta2->erase(blossom);
+      }
+
+      for (typename BlossomSet::ItemIt n(*_blossom_set, blossom); 
+	   n != INVALID; ++n) {
+	int ni = (*_node_index)[n];
+
+	_blossom_set->increase(n, std::numeric_limits<Value>::max());
+
+	(*_node_data)[ni].heap.clear();
+	(*_node_data)[ni].heap_index.clear();
+
+	for (OutEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node v = _ugraph.target(e);
+	  int vb = _blossom_set->find(v);
+	  int vi = (*_node_index)[v];
+
+	  Value rw = (*_node_data)[ni].pot + (*_node_data)[vi].pot - 
+	    dualScale * _weight[e];
+
+	  if ((*_blossom_data)[vb].status == EVEN) {
+	    if (_delta3->state(e) != _delta3->IN_HEAP) {
+	      _delta3->push(e, rw);
+	    }
+	  }
+	}
+      }
+    }
+
+    void unmatchedToMatched(int blossom) {
+      for (typename BlossomSet::ItemIt n(*_blossom_set, blossom);
+	   n != INVALID; ++n) {
+	int ni = (*_node_index)[n];
+
+	for (InEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node v = _ugraph.source(e);
+	  int vb = _blossom_set->find(v);
+	  int vi = (*_node_index)[v];
+
+	  Value rw = (*_node_data)[ni].pot + (*_node_data)[vi].pot - 
+	    dualScale * _weight[e];
+
+	  if (vb == blossom) {
+	    if (_delta3->state(e) == _delta3->IN_HEAP) {
+	      _delta3->erase(e);
+	    }
+	  } else if ((*_blossom_data)[vb].status == EVEN) {
+
+	    if (_delta3->state(e) == _delta3->IN_HEAP) {
+	      _delta3->erase(e);
+	    }
+
+	    int vt = _tree_set->find(vb);
+	    
+	    Edge r = _ugraph.oppositeEdge(e);
+	    
+	    typename std::map<int, Edge>::iterator it = 
+	      (*_node_data)[ni].heap_index.find(vt);	  
+	    
+	    if (it != (*_node_data)[ni].heap_index.end()) {
+	      if ((*_node_data)[ni].heap[it->second] > rw) {
+		(*_node_data)[ni].heap.replace(it->second, r);
+		(*_node_data)[ni].heap.decrease(r, rw);
+		it->second = r;
+	      }
+	    } else {
+	      (*_node_data)[ni].heap.push(r, rw);
+	      (*_node_data)[ni].heap_index.insert(std::make_pair(vt, r));
+	    }
+	      
+	    if ((*_blossom_set)[n] > (*_node_data)[ni].heap.prio()) {
+	      _blossom_set->decrease(n, (*_node_data)[ni].heap.prio());
+	      
+	      if (_delta2->state(blossom) != _delta2->IN_HEAP) {
+		_delta2->push(blossom, _blossom_set->classPrio(blossom) - 
+			     (*_blossom_data)[blossom].offset);
+	      } else if ((*_delta2)[blossom] > _blossom_set->classPrio(blossom)-
+			 (*_blossom_data)[blossom].offset){
+		_delta2->decrease(blossom, _blossom_set->classPrio(blossom) -
+				 (*_blossom_data)[blossom].offset);
+	      }
+	    }
+	    
+	  } else if ((*_blossom_data)[vb].status == UNMATCHED) {
+	    if (_delta3->state(e) == _delta3->IN_HEAP) {
+	      _delta3->erase(e);
+	    }
+	  }
+	}
+      }
+    }
+
+    void alternatePath(int even, int tree) {
+      int odd;
+
+      evenToMatched(even, tree);
+      (*_blossom_data)[even].status = MATCHED;
+
+      while ((*_blossom_data)[even].pred != INVALID) {
+	odd = _blossom_set->find(_ugraph.target((*_blossom_data)[even].pred));
+	(*_blossom_data)[odd].status = MATCHED;
+	oddToMatched(odd);
+	(*_blossom_data)[odd].next = (*_blossom_data)[odd].pred;
+      
+	even = _blossom_set->find(_ugraph.target((*_blossom_data)[odd].pred));
+	(*_blossom_data)[even].status = MATCHED;
+	evenToMatched(even, tree);
+	(*_blossom_data)[even].next = 
+	  _ugraph.oppositeEdge((*_blossom_data)[odd].pred);
+      }
+      
+    }
+
+    void destroyTree(int tree) {
+      for (TreeSet::ItemIt b(*_tree_set, tree); b != INVALID; ++b) {
+	if ((*_blossom_data)[b].status == EVEN) {
+	  (*_blossom_data)[b].status = MATCHED;
+	  evenToMatched(b, tree);
+	} else if ((*_blossom_data)[b].status == ODD) {
+	  (*_blossom_data)[b].status = MATCHED;
+	  oddToMatched(b);
+	}
+      }
+      _tree_set->eraseClass(tree);
+    }
+    
+
+    void unmatchNode(const Node& node) {
+      int blossom = _blossom_set->find(node);
+      int tree = _tree_set->find(blossom);
+
+      alternatePath(blossom, tree);
+      destroyTree(tree);
+
+      (*_blossom_data)[blossom].status = UNMATCHED;
+      (*_blossom_data)[blossom].base = node;
+      matchedToUnmatched(blossom);
+    }
+
+
+    void augmentOnEdge(const UEdge& edge) {
+      
+      int left = _blossom_set->find(_ugraph.source(edge));
+      int right = _blossom_set->find(_ugraph.target(edge));
+
+      if ((*_blossom_data)[left].status == EVEN) {
+	int left_tree = _tree_set->find(left);
+	alternatePath(left, left_tree);
+	destroyTree(left_tree);
+      } else {
+	(*_blossom_data)[left].status = MATCHED;
+	unmatchedToMatched(left);
+      }
+
+      if ((*_blossom_data)[right].status == EVEN) {
+	int right_tree = _tree_set->find(right);
+	alternatePath(right, right_tree);
+	destroyTree(right_tree);
+      } else {
+	(*_blossom_data)[right].status = MATCHED;
+	unmatchedToMatched(right);
+      }
+
+      (*_blossom_data)[left].next = _ugraph.direct(edge, true);
+      (*_blossom_data)[right].next = _ugraph.direct(edge, false);
+    }
+
+    void extendOnEdge(const Edge& edge) {
+      int base = _blossom_set->find(_ugraph.target(edge));
+      int tree = _tree_set->find(base);
+      
+      int odd = _blossom_set->find(_ugraph.source(edge));
+      _tree_set->insert(odd, tree);
+      (*_blossom_data)[odd].status = ODD;
+      matchedToOdd(odd);
+      (*_blossom_data)[odd].pred = edge;
+
+      int even = _blossom_set->find(_ugraph.target((*_blossom_data)[odd].next));
+      (*_blossom_data)[even].pred = (*_blossom_data)[even].next;
+      _tree_set->insert(even, tree);
+      (*_blossom_data)[even].status = EVEN;
+      matchedToEven(even, tree);
+    }
+    
+    void shrinkOnEdge(const UEdge& uedge, int tree) {
+      int nca = -1;
+      std::vector<int> left_path, right_path;
+
+      {
+	std::set<int> left_set, right_set;
+	int left = _blossom_set->find(_ugraph.source(uedge));
+	left_path.push_back(left);
+	left_set.insert(left);
+
+	int right = _blossom_set->find(_ugraph.target(uedge));
+	right_path.push_back(right);
+	right_set.insert(right);
+
+	while (true) {
+
+	  if ((*_blossom_data)[left].pred == INVALID) break;
+
+	  left = 
+	    _blossom_set->find(_ugraph.target((*_blossom_data)[left].pred));
+	  left_path.push_back(left);
+	  left = 
+	    _blossom_set->find(_ugraph.target((*_blossom_data)[left].pred));
+	  left_path.push_back(left);
+
+	  left_set.insert(left);
+
+	  if (right_set.find(left) != right_set.end()) {
+	    nca = left;
+	    break;
+	  }
+
+	  if ((*_blossom_data)[right].pred == INVALID) break;
+
+	  right = 
+	    _blossom_set->find(_ugraph.target((*_blossom_data)[right].pred));
+	  right_path.push_back(right);
+	  right = 
+	    _blossom_set->find(_ugraph.target((*_blossom_data)[right].pred));
+	  right_path.push_back(right);
+
+	  right_set.insert(right);
+ 
+	  if (left_set.find(right) != left_set.end()) {
+	    nca = right;
+	    break;
+	  }
+
+	}
+
+	if (nca == -1) {
+	  if ((*_blossom_data)[left].pred == INVALID) {
+	    nca = right;
+	    while (left_set.find(nca) == left_set.end()) {
+	      nca = 
+		_blossom_set->find(_ugraph.target((*_blossom_data)[nca].pred));
+	      right_path.push_back(nca);
+	      nca = 
+		_blossom_set->find(_ugraph.target((*_blossom_data)[nca].pred));
+	      right_path.push_back(nca);
+	    }
+	  } else {
+	    nca = left;
+	    while (right_set.find(nca) == right_set.end()) {
+	      nca = 
+		_blossom_set->find(_ugraph.target((*_blossom_data)[nca].pred));
+	      left_path.push_back(nca);
+	      nca = 
+		_blossom_set->find(_ugraph.target((*_blossom_data)[nca].pred));
+	      left_path.push_back(nca);
+	    }
+	  }
+	}
+      }
+
+      std::vector<int> subblossoms;
+      Edge prev;
+
+      prev = _ugraph.direct(uedge, true);
+      for (int i = 0; left_path[i] != nca; i += 2) {
+	subblossoms.push_back(left_path[i]);
+	(*_blossom_data)[left_path[i]].next = prev;
+	_tree_set->erase(left_path[i]);
+
+	subblossoms.push_back(left_path[i + 1]);
+	(*_blossom_data)[left_path[i + 1]].status = EVEN;
+	oddToEven(left_path[i + 1], tree);
+	_tree_set->erase(left_path[i + 1]);
+	prev = _ugraph.oppositeEdge((*_blossom_data)[left_path[i + 1]].pred);
+      }
+
+      int k = 0;
+      while (right_path[k] != nca) ++k;
+
+      subblossoms.push_back(nca);
+      (*_blossom_data)[nca].next = prev;
+      
+      for (int i = k - 2; i >= 0; i -= 2) {
+	subblossoms.push_back(right_path[i + 1]);
+	(*_blossom_data)[right_path[i + 1]].status = EVEN;
+	oddToEven(right_path[i + 1], tree);
+	_tree_set->erase(right_path[i + 1]);
+
+	(*_blossom_data)[right_path[i + 1]].next = 
+	  (*_blossom_data)[right_path[i + 1]].pred;
+
+	subblossoms.push_back(right_path[i]);
+	_tree_set->erase(right_path[i]);
+      }
+
+      int surface = 
+	_blossom_set->join(subblossoms.begin(), subblossoms.end());
+
+      for (int i = 0; i < int(subblossoms.size()); ++i) {
+	if (!_blossom_set->trivial(subblossoms[i])) {
+	  (*_blossom_data)[subblossoms[i]].pot += 2 * _delta_sum;
+	}
+	(*_blossom_data)[subblossoms[i]].status = MATCHED;
+      }
+
+      (*_blossom_data)[surface].pot = -2 * _delta_sum;
+      (*_blossom_data)[surface].offset = 0;
+      (*_blossom_data)[surface].status = EVEN;
+      (*_blossom_data)[surface].pred = (*_blossom_data)[nca].pred;
+      (*_blossom_data)[surface].next = (*_blossom_data)[nca].pred;
+
+      _tree_set->insert(surface, tree);
+      _tree_set->erase(nca);
+    }
+
+    void splitBlossom(int blossom) {
+      Edge next = (*_blossom_data)[blossom].next; 
+      Edge pred = (*_blossom_data)[blossom].pred;
+
+      int tree = _tree_set->find(blossom);
+
+      (*_blossom_data)[blossom].status = MATCHED;
+      oddToMatched(blossom);
+      if (_delta2->state(blossom) == _delta2->IN_HEAP) {
+	_delta2->erase(blossom);
+      }
+
+      std::vector<int> subblossoms;
+      _blossom_set->split(blossom, std::back_inserter(subblossoms));
+
+      Value offset = (*_blossom_data)[blossom].offset;
+      int b = _blossom_set->find(_ugraph.source(pred));
+      int d = _blossom_set->find(_ugraph.source(next));
+      
+      int ib = -1, id = -1;
+      for (int i = 0; i < int(subblossoms.size()); ++i) {
+	if (subblossoms[i] == b) ib = i;
+	if (subblossoms[i] == d) id = i;
+
+	(*_blossom_data)[subblossoms[i]].offset = offset;
+	if (!_blossom_set->trivial(subblossoms[i])) {
+	  (*_blossom_data)[subblossoms[i]].pot -= 2 * offset;
+	}
+	if (_blossom_set->classPrio(subblossoms[i]) != 
+	    std::numeric_limits<Value>::max()) {
+	  _delta2->push(subblossoms[i], 
+			_blossom_set->classPrio(subblossoms[i]) - 
+			(*_blossom_data)[subblossoms[i]].offset);
+	}
+      }
+      
+      if (id > ib ? ((id - ib) % 2 == 0) : ((ib - id) % 2 == 1)) {
+	for (int i = (id + 1) % subblossoms.size(); 
+	     i != ib; i = (i + 2) % subblossoms.size()) {
+	  int sb = subblossoms[i];
+	  int tb = subblossoms[(i + 1) % subblossoms.size()];
+	  (*_blossom_data)[sb].next = 
+	    _ugraph.oppositeEdge((*_blossom_data)[tb].next);
+	}
+
+	for (int i = ib; i != id; i = (i + 2) % subblossoms.size()) {
+	  int sb = subblossoms[i];
+	  int tb = subblossoms[(i + 1) % subblossoms.size()];
+	  int ub = subblossoms[(i + 2) % subblossoms.size()];
+
+	  (*_blossom_data)[sb].status = ODD;
+	  matchedToOdd(sb);
+	  _tree_set->insert(sb, tree);
+	  (*_blossom_data)[sb].pred = pred;
+	  (*_blossom_data)[sb].next = 
+			   _ugraph.oppositeEdge((*_blossom_data)[tb].next);
+	  
+	  pred = (*_blossom_data)[ub].next;
+      
+	  (*_blossom_data)[tb].status = EVEN;
+	  matchedToEven(tb, tree);
+	  _tree_set->insert(tb, tree);
+	  (*_blossom_data)[tb].pred = (*_blossom_data)[tb].next;
+	}
+      
+	(*_blossom_data)[subblossoms[id]].status = ODD;
+	matchedToOdd(subblossoms[id]);
+	_tree_set->insert(subblossoms[id], tree);
+	(*_blossom_data)[subblossoms[id]].next = next;
+	(*_blossom_data)[subblossoms[id]].pred = pred;
+      
+      } else {
+
+	for (int i = (ib + 1) % subblossoms.size(); 
+	     i != id; i = (i + 2) % subblossoms.size()) {
+	  int sb = subblossoms[i];
+	  int tb = subblossoms[(i + 1) % subblossoms.size()];
+	  (*_blossom_data)[sb].next = 
+	    _ugraph.oppositeEdge((*_blossom_data)[tb].next);
+	}	
+
+	for (int i = id; i != ib; i = (i + 2) % subblossoms.size()) {
+	  int sb = subblossoms[i];
+	  int tb = subblossoms[(i + 1) % subblossoms.size()];
+	  int ub = subblossoms[(i + 2) % subblossoms.size()];
+
+	  (*_blossom_data)[sb].status = ODD;
+	  matchedToOdd(sb);
+	  _tree_set->insert(sb, tree);
+	  (*_blossom_data)[sb].next = next; 
+	  (*_blossom_data)[sb].pred =
+	    _ugraph.oppositeEdge((*_blossom_data)[tb].next);
+
+	  (*_blossom_data)[tb].status = EVEN;
+	  matchedToEven(tb, tree);
+	  _tree_set->insert(tb, tree);
+	  (*_blossom_data)[tb].pred =
+	    (*_blossom_data)[tb].next = 
+	    _ugraph.oppositeEdge((*_blossom_data)[ub].next);
+	  next = (*_blossom_data)[ub].next;
+	}
+
+	(*_blossom_data)[subblossoms[ib]].status = ODD;
+	matchedToOdd(subblossoms[ib]);
+	_tree_set->insert(subblossoms[ib], tree);
+	(*_blossom_data)[subblossoms[ib]].next = next;
+	(*_blossom_data)[subblossoms[ib]].pred = pred;
+      }
+      _tree_set->erase(blossom);
+    }
+
+    void extractBlossom(int blossom, const Node& base, const Edge& matching) {
+      if (_blossom_set->trivial(blossom)) {
+	int bi = (*_node_index)[base];
+	Value pot = (*_node_data)[bi].pot;
+
+	_matching->set(base, matching);
+	_blossom_node_list.push_back(base);
+	_node_potential->set(base, pot);
+      } else {
+
+	Value pot = (*_blossom_data)[blossom].pot;
+	int bn = _blossom_node_list.size();
+	
+	std::vector<int> subblossoms;
+	_blossom_set->split(blossom, std::back_inserter(subblossoms));
+	int b = _blossom_set->find(base);
+	int ib = -1;
+	for (int i = 0; i < int(subblossoms.size()); ++i) {
+	  if (subblossoms[i] == b) { ib = i; break; }
+	}
+	
+	for (int i = 1; i < int(subblossoms.size()); i += 2) {
+	  int sb = subblossoms[(ib + i) % subblossoms.size()];
+	  int tb = subblossoms[(ib + i + 1) % subblossoms.size()];
+	  
+	  Edge m = (*_blossom_data)[tb].next;
+	  extractBlossom(sb, _ugraph.target(m), _ugraph.oppositeEdge(m));
+	  extractBlossom(tb, _ugraph.source(m), m);
+	}
+	extractBlossom(subblossoms[ib], base, matching);      
+	
+	int en = _blossom_node_list.size();
+	
+	_blossom_potential.push_back(BlossomVariable(bn, en, pot));
+      }
+    }
+
+    void extractMatching() {
+      std::vector<int> blossoms;
+      for (typename BlossomSet::ClassIt c(*_blossom_set); c != INVALID; ++c) {
+	blossoms.push_back(c);
+      }
+
+      for (int i = 0; i < int(blossoms.size()); ++i) {
+	if ((*_blossom_data)[blossoms[i]].status == MATCHED) {
+
+	  Value offset = (*_blossom_data)[blossoms[i]].offset;
+	  (*_blossom_data)[blossoms[i]].pot += 2 * offset;
+	  for (typename BlossomSet::ItemIt n(*_blossom_set, blossoms[i]); 
+	       n != INVALID; ++n) {
+	    (*_node_data)[(*_node_index)[n]].pot -= offset;
+	  }
+
+	  Edge matching = (*_blossom_data)[blossoms[i]].next;
+	  Node base = _ugraph.source(matching);
+	  extractBlossom(blossoms[i], base, matching);
+	} else {
+	  Node base = (*_blossom_data)[blossoms[i]].base;	  
+	  extractBlossom(blossoms[i], base, INVALID);
+	}
+      }
+    }
+    
+  public:
+
+    /// \brief Constructor
+    ///
+    /// Constructor.
+    MaxWeightedMatching(const UGraph& ugraph, const WeightMap& weight)
+      : _ugraph(ugraph), _weight(weight), _matching(0),
+	_node_potential(0), _blossom_potential(), _blossom_node_list(),
+	_node_num(0), _blossom_num(0),
+
+	_blossom_index(0), _blossom_set(0), _blossom_data(0),
+	_node_index(0), _node_heap_index(0), _node_data(0),
+	_tree_set_index(0), _tree_set(0),
+
+	_delta1_index(0), _delta1(0),
+	_delta2_index(0), _delta2(0),
+	_delta3_index(0), _delta3(0), 
+	_delta4_index(0), _delta4(0),
+
+	_delta_sum() {}
+
+    ~MaxWeightedMatching() {
+      destroyStructures();
+    }
+
+    /// \name Execution control 
+    /// The simplest way to execute the algorithm is to use the member
+    /// \c run() member function.
+
+    ///@{
+
+    /// \brief Initialize the algorithm
+    ///
+    /// Initialize the algorithm
+    void init() {
+      createStructures();
+
+      for (EdgeIt e(_ugraph); e != INVALID; ++e) {
+	_node_heap_index->set(e, BinHeap<Value, EdgeIntMap>::PRE_HEAP);
+      }
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	_delta1_index->set(n, _delta1->PRE_HEAP);
+      }
+      for (UEdgeIt e(_ugraph); e != INVALID; ++e) {
+	_delta3_index->set(e, _delta3->PRE_HEAP);
+      }
+      for (int i = 0; i < _blossom_num; ++i) {
+	_delta2_index->set(i, _delta2->PRE_HEAP);
+	_delta4_index->set(i, _delta4->PRE_HEAP);
+      }
+
+      int index = 0;
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	Value max = 0;
+	for (OutEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  if (_ugraph.target(e) == n) continue;
+	  if ((dualScale * _weight[e]) / 2 > max) {
+	    max = (dualScale * _weight[e]) / 2;
+	  }
+	}
+	_node_index->set(n, index);
+	(*_node_data)[index].pot = max;
+	_delta1->push(n, max);
+	int blossom = 
+	  _blossom_set->insert(n, std::numeric_limits<Value>::max());
+
+	_tree_set->insert(blossom);
+
+	(*_blossom_data)[blossom].status = EVEN;
+	(*_blossom_data)[blossom].pred = INVALID;
+	(*_blossom_data)[blossom].next = INVALID;
+	(*_blossom_data)[blossom].pot = 0;
+	(*_blossom_data)[blossom].offset = 0;
+	++index;
+      }
+      for (UEdgeIt e(_ugraph); e != INVALID; ++e) {
+	int si = (*_node_index)[_ugraph.source(e)];
+	int ti = (*_node_index)[_ugraph.target(e)];
+	if (_ugraph.source(e) != _ugraph.target(e)) {
+	  _delta3->push(e, ((*_node_data)[si].pot + (*_node_data)[ti].pot - 
+			    dualScale * _weight[e]) / 2);
+	}
+      }
+    }
+
+    /// \brief Starts the algorithm
+    ///
+    /// Starts the algorithm
+    void start() {
+      enum OpType {
+	D1, D2, D3, D4
+      };
+
+      int unmatched = _node_num;
+      while (unmatched > 0) {
+	Value d1 = !_delta1->empty() ? 
+	  _delta1->prio() : std::numeric_limits<Value>::max();
+
+	Value d2 = !_delta2->empty() ? 
+	  _delta2->prio() : std::numeric_limits<Value>::max();
+
+	Value d3 = !_delta3->empty() ? 
+	  _delta3->prio() : std::numeric_limits<Value>::max();
+
+	Value d4 = !_delta4->empty() ? 
+	  _delta4->prio() : std::numeric_limits<Value>::max();
+
+	_delta_sum = d1; OpType ot = D1;
+	if (d2 < _delta_sum) { _delta_sum = d2; ot = D2; }
+	if (d3 < _delta_sum) { _delta_sum = d3; ot = D3; }
+	if (d4 < _delta_sum) { _delta_sum = d4; ot = D4; }
+
+	
+	switch (ot) {
+	case D1:
+	  {
+	    Node n = _delta1->top();
+	    unmatchNode(n);
+	    --unmatched;
+	  }
+	  break;
+	case D2:
+	  {
+	    int blossom = _delta2->top();
+	    Node n = _blossom_set->classTop(blossom);
+	    Edge e = (*_node_data)[(*_node_index)[n]].heap.top();
+	    extendOnEdge(e);
+	  }
+	  break;
+	case D3:
+	  {
+	    UEdge e = _delta3->top();
+	    
+	    int left_blossom = _blossom_set->find(_ugraph.source(e));
+	    int right_blossom = _blossom_set->find(_ugraph.target(e));
+	  
+	    if (left_blossom == right_blossom) {
+	      _delta3->pop();
+	    } else {
+	      int left_tree;
+	      if ((*_blossom_data)[left_blossom].status == EVEN) {
+		left_tree = _tree_set->find(left_blossom);
+	      } else {
+		left_tree = -1;
+		++unmatched;
+	      }
+	      int right_tree;
+	      if ((*_blossom_data)[right_blossom].status == EVEN) {
+		right_tree = _tree_set->find(right_blossom);
+	      } else {
+		right_tree = -1;
+		++unmatched;
+	      }
+	    
+	      if (left_tree == right_tree) {
+		shrinkOnEdge(e, left_tree);
+	      } else {
+		augmentOnEdge(e);
+		unmatched -= 2;
+	      }
+	    }
+	  } break;
+	case D4:
+	  splitBlossom(_delta4->top());
+	  break;
+	}
+      }
+      extractMatching();
+    }
+
+    /// \brief Runs %MaxWeightedMatching algorithm.
+    ///
+    /// This method runs the %MaxWeightedMatching algorithm.
+    ///
+    /// \note mwm.run() is just a shortcut of the following code.
+    /// \code
+    ///   mwm.init();
+    ///   mwm.start();
+    /// \endcode
+    void run() {
+      init();
+      start();
+    }
+
+    /// @}
+
+    /// \name Primal solution
+    /// Functions for get the primal solution, ie. the matching.
+    
+    /// @{
+
+    /// \brief Returns the matching value.
+    ///
+    /// Returns the matching value.
+    Value matchingValue() const {
+      Value sum = 0;
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	if ((*_matching)[n] != INVALID) {
+	  sum += _weight[(*_matching)[n]];
+	}
+      }
+      return sum /= 2;
+    }
+
+    /// \brief Returns true when the edge is in the matching.
+    ///
+    /// Returns true when the edge is in the matching.
+    bool matching(const UEdge& edge) const {
+      return (*_matching)[_ugraph.source(edge)] == _ugraph.direct(edge, true);
+    }
+
+    /// \brief Returns the incident matching edge.
+    ///
+    /// Returns the incident matching edge from given node. If the
+    /// node is not matched then it gives back \c INVALID.
+    Edge matching(const Node& node) const {
+      return (*_matching)[node];
+    }
+
+    /// \brief Returns the mate of the node.
+    ///
+    /// Returns the adjancent node in a mathcing edge. If the node is
+    /// not matched then it gives back \c INVALID.
+    Node mate(const Node& node) const {
+      return (*_matching)[node] != INVALID ?
+	_ugraph.target((*_matching)[node]) : INVALID;
+    }
+
+    /// @}
+
+    /// \name Dual solution
+    /// Functions for get the dual solution.
+    
+    /// @{
+
+    /// \brief Returns the value of the dual solution.
+    ///
+    /// Returns the value of the dual solution. It should be equal to
+    /// the primal value scaled by \ref dualScale "dual scale".
+    Value dualValue() const {
+      Value sum = 0;
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	sum += nodeValue(n);
+      }
+      for (int i = 0; i < blossomNum(); ++i) {
+        sum += blossomValue(i) * (blossomSize(i) / 2);
+      }
+      return sum;
+    }
+
+    /// \brief Returns the value of the node.
+    ///
+    /// Returns the the value of the node.
+    Value nodeValue(const Node& n) const {
+      return (*_node_potential)[n];
+    }
+
+    /// \brief Returns the number of the blossoms in the basis.
+    ///
+    /// Returns the number of the blossoms in the basis.
+    /// \see BlossomIt
+    int blossomNum() const {
+      return _blossom_potential.size();
+    }
+
+
+    /// \brief Returns the number of the nodes in the blossom.
+    ///
+    /// Returns the number of the nodes in the blossom.
+    int blossomSize(int k) const {
+      return _blossom_potential[k].end - _blossom_potential[k].begin;
+    }
+
+    /// \brief Returns the value of the blossom.
+    ///
+    /// Returns the the value of the blossom.
+    /// \see BlossomIt
+    Value blossomValue(int k) const {
+      return _blossom_potential[k].value;
+    }
+
+    /// \brief Lemon iterator for get the items of the blossom.
+    ///
+    /// Lemon iterator for get the nodes of the blossom. This class
+    /// provides a common style lemon iterator which gives back a
+    /// subset of the nodes.
+    class BlossomIt {
+    public:
+
+      /// \brief Constructor.
+      ///
+      /// Constructor for get the nodes of the variable. 
+      BlossomIt(const MaxWeightedMatching& algorithm, int variable) 
+        : _algorithm(&algorithm)
+      {
+        _index = _algorithm->_blossom_potential[variable].begin;
+        _last = _algorithm->_blossom_potential[variable].end;
+      }
+
+      /// \brief Invalid constructor.
+      ///
+      /// Invalid constructor.
+      BlossomIt(Invalid) : _index(-1) {}
+
+      /// \brief Conversion to node.
+      ///
+      /// Conversion to node.
+      operator Node() const { 
+        return _algorithm ? _algorithm->_blossom_node_list[_index] : INVALID;
+      }
+
+      /// \brief Increment operator.
+      ///
+      /// Increment operator.
+      BlossomIt& operator++() {
+        ++_index;
+        if (_index == _last) {
+          _index = -1;
+        }
+        return *this; 
+      }
+
+      bool operator==(const BlossomIt& it) const { 
+        return _index == it._index; 
+      }
+      bool operator!=(const BlossomIt& it) const { 
+        return _index != it._index;
+      }
+
+    private:
+      const MaxWeightedMatching* _algorithm;
+      int _last;
+      int _index;
+    };
+
+    /// @}
+    
+  };
+
+  /// \ingroup matching
+  ///
+  /// \brief Weighted perfect matching in general undirected graphs
+  ///
+  /// This class provides an efficient implementation of Edmond's
+  /// maximum weighted perfecr matching algorithm. The implementation
+  /// is based on extensive use of priority queues and provides
+  /// \f$O(nm\log(n))\f$ time complexity.
+  ///
+  /// The maximum weighted matching problem is to find undirected
+  /// edges in the graph with maximum overall weight and no two of
+  /// them shares their endpoints and covers all nodes. The problem
+  /// can be formulated with the next linear program:
+  /// \f[ \sum_{e \in \delta(u)}x_e = 1 \quad \forall u\in V\f]
+  ///\f[ \sum_{e \in \gamma(B)}x_e \le \frac{\vert B \vert - 1}{2} \quad \forall B\in\mathcal{O}\f] 
+  /// \f[x_e \ge 0\quad \forall e\in E\f]
+  /// \f[\max \sum_{e\in E}x_ew_e\f]
+  /// where \f$\delta(X)\f$ is the set of edges incident to a node in
+  /// \f$X\f$, \f$\gamma(X)\f$ is the set of edges with both endpoints in
+  /// \f$X\f$ and \f$\mathcal{O}\f$ is the set of odd cardinality subsets of
+  /// the nodes.
+  ///
+  /// The algorithm calculates an optimal matching and a proof of the
+  /// optimality. The solution of the dual problem can be used to check
+  /// the result of the algorithm. The dual linear problem is the next:
+  /// \f[ y_u + y_v + \sum_{B \in \mathcal{O}, uv \in \gamma(B)}z_B \ge w_{uv} \quad \forall uv\in E\f]
+  /// \f[z_B \ge 0 \quad \forall B \in \mathcal{O}\f]
+  /// \f[\min \sum_{u \in V}y_u + \sum_{B \in \mathcal{O}}\frac{\vert B \vert - 1}{2}z_B\f]
+  ///
+  /// The algorithm can be executed with \c run() or the \c init() and
+  /// then the \c start() member functions. After it the matching can
+  /// be asked with \c matching() or mate() functions. The dual
+  /// solution can be get with \c nodeValue(), \c blossomNum() and \c
+  /// blossomValue() members and \ref MaxWeightedMatching::BlossomIt
+  /// "BlossomIt" nested class which is able to iterate on the nodes
+  /// of a blossom. If the value type is integral then the dual
+  /// solution is multiplied by \ref MaxWeightedMatching::dualScale "4".
+  ///
+  /// \author Balazs Dezso
+  template <typename _UGraph, 
+	    typename _WeightMap = typename _UGraph::template UEdgeMap<int> >
+  class MaxWeightedPerfectMatching {
+  public:
+
+    typedef _UGraph UGraph;
+    typedef _WeightMap WeightMap;
+    typedef typename WeightMap::Value Value;
+
+    /// \brief Scaling factor for dual solution
+    ///
+    /// Scaling factor for dual solution, it is equal to 4 or 1
+    /// according to the value type.
+    static const int dualScale = 
+      std::numeric_limits<Value>::is_integer ? 4 : 1;
+
+    typedef typename UGraph::template NodeMap<typename UGraph::Edge> 
+    MatchingMap;
+    
+  private:
+
+    UGRAPH_TYPEDEFS(typename UGraph);
+
+    typedef typename UGraph::template NodeMap<Value> NodePotential;
+    typedef std::vector<Node> BlossomNodeList;
+
+    struct BlossomVariable {
+      int begin, end;
+      Value value;
+      
+      BlossomVariable(int _begin, int _end, Value _value)
+        : begin(_begin), end(_end), value(_value) {}
+
+    };
+
+    typedef std::vector<BlossomVariable> BlossomPotential;
+
+    const UGraph& _ugraph;
+    const WeightMap& _weight;
+
+    MatchingMap* _matching;
+
+    NodePotential* _node_potential;
+
+    BlossomPotential _blossom_potential;
+    BlossomNodeList _blossom_node_list;
+
+    int _node_num;
+    int _blossom_num;
+
+    typedef typename UGraph::template NodeMap<int> NodeIntMap;
+    typedef typename UGraph::template EdgeMap<int> EdgeIntMap;
+    typedef typename UGraph::template UEdgeMap<int> UEdgeIntMap;
+    typedef IntegerMap<int> IntIntMap;
+
+    enum Status {
+      EVEN = -1, MATCHED = 0, ODD = 1
+    };
+
+    typedef HeapUnionFind<Value, NodeIntMap> BlossomSet;
+    struct BlossomData {
+      int tree;
+      Status status;
+      Edge pred, next;
+      Value pot, offset;
+    };
+
+    NodeIntMap *_blossom_index;
+    BlossomSet *_blossom_set;
+    IntegerMap<BlossomData>* _blossom_data;
+
+    NodeIntMap *_node_index;
+    EdgeIntMap *_node_heap_index;
+
+    struct NodeData {
+      
+      NodeData(EdgeIntMap& node_heap_index) 
+	: heap(node_heap_index) {}
+      
+      int blossom;
+      Value pot;
+      BinHeap<Value, EdgeIntMap> heap;
+      std::map<int, Edge> heap_index;
+      
+      int tree;
+    };
+
+    IntegerMap<NodeData>* _node_data;
+
+    typedef ExtendFindEnum<IntIntMap> TreeSet;
+
+    IntIntMap *_tree_set_index;
+    TreeSet *_tree_set;
+
+    IntIntMap *_delta2_index;
+    BinHeap<Value, IntIntMap> *_delta2;
+    
+    UEdgeIntMap *_delta3_index;
+    BinHeap<Value, UEdgeIntMap> *_delta3;
+
+    IntIntMap *_delta4_index;
+    BinHeap<Value, IntIntMap> *_delta4;
+
+    Value _delta_sum;
+
+    void createStructures() {
+      _node_num = countNodes(_ugraph); 
+      _blossom_num = _node_num * 3 / 2;
+
+      if (!_matching) {
+	_matching = new MatchingMap(_ugraph);
+      }
+      if (!_node_potential) {
+	_node_potential = new NodePotential(_ugraph);
+      }
+      if (!_blossom_set) {
+	_blossom_index = new NodeIntMap(_ugraph);
+	_blossom_set = new BlossomSet(*_blossom_index);
+	_blossom_data = new IntegerMap<BlossomData>(_blossom_num);
+      }
+
+      if (!_node_index) {
+	_node_index = new NodeIntMap(_ugraph);
+	_node_heap_index = new EdgeIntMap(_ugraph);
+	_node_data = new IntegerMap<NodeData>(_node_num, 
+					      NodeData(*_node_heap_index));
+      }
+
+      if (!_tree_set) {
+	_tree_set_index = new IntIntMap(_blossom_num);
+	_tree_set = new TreeSet(*_tree_set_index);
+      }
+      if (!_delta2) {
+	_delta2_index = new IntIntMap(_blossom_num);
+	_delta2 = new BinHeap<Value, IntIntMap>(*_delta2_index);
+      }
+      if (!_delta3) {
+	_delta3_index = new UEdgeIntMap(_ugraph);
+	_delta3 = new BinHeap<Value, UEdgeIntMap>(*_delta3_index);
+      }
+      if (!_delta4) {
+	_delta4_index = new IntIntMap(_blossom_num);
+	_delta4 = new BinHeap<Value, IntIntMap>(*_delta4_index);
+      }
+    }
+
+    void destroyStructures() {
+      _node_num = countNodes(_ugraph); 
+      _blossom_num = _node_num * 3 / 2;
+
+      if (_matching) {
+	delete _matching;
+      }
+      if (_node_potential) {
+	delete _node_potential;
+      }
+      if (_blossom_set) {
+	delete _blossom_index;
+	delete _blossom_set;
+	delete _blossom_data;
+      }
+
+      if (_node_index) {
+	delete _node_index;
+	delete _node_heap_index;
+	delete _node_data;			      
+      }
+
+      if (_tree_set) {
+	delete _tree_set_index;
+	delete _tree_set;
+      }
+      if (_delta2) {
+	delete _delta2_index;
+	delete _delta2;
+      }
+      if (_delta3) {
+	delete _delta3_index;
+	delete _delta3;
+      }
+      if (_delta4) {
+	delete _delta4_index;
+	delete _delta4;
+      }
+    }
+
+    void matchedToEven(int blossom, int tree) {
+      if (_delta2->state(blossom) == _delta2->IN_HEAP) {
+	_delta2->erase(blossom);
+      }
+
+      if (!_blossom_set->trivial(blossom)) {
+	(*_blossom_data)[blossom].pot -= 
+	  2 * (_delta_sum - (*_blossom_data)[blossom].offset);
+      }
+
+      for (typename BlossomSet::ItemIt n(*_blossom_set, blossom); 
+	   n != INVALID; ++n) {
+
+	_blossom_set->increase(n, std::numeric_limits<Value>::max());
+	int ni = (*_node_index)[n];
+
+	(*_node_data)[ni].heap.clear();
+	(*_node_data)[ni].heap_index.clear();
+
+	(*_node_data)[ni].pot += _delta_sum - (*_blossom_data)[blossom].offset;
+
+	for (InEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node v = _ugraph.source(e);
+	  int vb = _blossom_set->find(v);
+	  int vi = (*_node_index)[v];
+
+	  Value rw = (*_node_data)[ni].pot + (*_node_data)[vi].pot - 
+	    dualScale * _weight[e];
+
+	  if ((*_blossom_data)[vb].status == EVEN) {
+	    if (_delta3->state(e) != _delta3->IN_HEAP && blossom != vb) {
+	      _delta3->push(e, rw / 2);
+	    }
+	  } else {
+	    typename std::map<int, Edge>::iterator it = 
+	      (*_node_data)[vi].heap_index.find(tree);	  
+
+	    if (it != (*_node_data)[vi].heap_index.end()) {
+	      if ((*_node_data)[vi].heap[it->second] > rw) {
+		(*_node_data)[vi].heap.replace(it->second, e);
+		(*_node_data)[vi].heap.decrease(e, rw);
+		it->second = e;
+	      }
+	    } else {
+	      (*_node_data)[vi].heap.push(e, rw);
+	      (*_node_data)[vi].heap_index.insert(std::make_pair(tree, e));
+	    }
+
+	    if ((*_blossom_set)[v] > (*_node_data)[vi].heap.prio()) {
+	      _blossom_set->decrease(v, (*_node_data)[vi].heap.prio());
+
+	      if ((*_blossom_data)[vb].status == MATCHED) {
+		if (_delta2->state(vb) != _delta2->IN_HEAP) {
+		  _delta2->push(vb, _blossom_set->classPrio(vb) -
+			       (*_blossom_data)[vb].offset);
+		} else if ((*_delta2)[vb] > _blossom_set->classPrio(vb) -
+			   (*_blossom_data)[vb].offset){
+		  _delta2->decrease(vb, _blossom_set->classPrio(vb) -
+				   (*_blossom_data)[vb].offset);
+		}
+	      }
+	    }
+	  }
+	}
+      }
+      (*_blossom_data)[blossom].offset = 0;
+    }
+
+    void matchedToOdd(int blossom) {
+      if (_delta2->state(blossom) == _delta2->IN_HEAP) {
+	_delta2->erase(blossom);
+      }
+      (*_blossom_data)[blossom].offset += _delta_sum;
+      if (!_blossom_set->trivial(blossom)) {
+	_delta4->push(blossom, (*_blossom_data)[blossom].pot / 2 + 
+		     (*_blossom_data)[blossom].offset);
+      }
+    }
+
+    void evenToMatched(int blossom, int tree) {
+      if (!_blossom_set->trivial(blossom)) {
+	(*_blossom_data)[blossom].pot += 2 * _delta_sum;
+      }
+
+      for (typename BlossomSet::ItemIt n(*_blossom_set, blossom);
+	   n != INVALID; ++n) {
+	int ni = (*_node_index)[n];
+	(*_node_data)[ni].pot -= _delta_sum;
+
+	for (InEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node v = _ugraph.source(e);
+	  int vb = _blossom_set->find(v);
+	  int vi = (*_node_index)[v];
+
+	  Value rw = (*_node_data)[ni].pot + (*_node_data)[vi].pot - 
+	    dualScale * _weight[e];
+
+	  if (vb == blossom) {
+	    if (_delta3->state(e) == _delta3->IN_HEAP) {
+	      _delta3->erase(e);
+	    }
+	  } else if ((*_blossom_data)[vb].status == EVEN) {
+
+	    if (_delta3->state(e) == _delta3->IN_HEAP) {
+	      _delta3->erase(e);
+	    }
+
+	    int vt = _tree_set->find(vb);
+	    
+	    if (vt != tree) {
+
+	      Edge r = _ugraph.oppositeEdge(e);
+
+	      typename std::map<int, Edge>::iterator it = 
+		(*_node_data)[ni].heap_index.find(vt);	  
+
+	      if (it != (*_node_data)[ni].heap_index.end()) {
+		if ((*_node_data)[ni].heap[it->second] > rw) {
+		  (*_node_data)[ni].heap.replace(it->second, r);
+		  (*_node_data)[ni].heap.decrease(r, rw);
+		  it->second = r;
+		}
+	      } else {
+		(*_node_data)[ni].heap.push(r, rw);
+		(*_node_data)[ni].heap_index.insert(std::make_pair(vt, r));
+	      }
+	      
+	      if ((*_blossom_set)[n] > (*_node_data)[ni].heap.prio()) {
+		_blossom_set->decrease(n, (*_node_data)[ni].heap.prio());
+		
+		if (_delta2->state(blossom) != _delta2->IN_HEAP) {
+		  _delta2->push(blossom, _blossom_set->classPrio(blossom) - 
+			       (*_blossom_data)[blossom].offset);
+		} else if ((*_delta2)[blossom] > 
+			   _blossom_set->classPrio(blossom) - 
+			   (*_blossom_data)[blossom].offset){
+		  _delta2->decrease(blossom, _blossom_set->classPrio(blossom) -
+				   (*_blossom_data)[blossom].offset);
+		}
+	      }
+	    }
+	  } else {
+	  
+	    typename std::map<int, Edge>::iterator it = 
+	      (*_node_data)[vi].heap_index.find(tree);
+
+	    if (it != (*_node_data)[vi].heap_index.end()) {
+	      (*_node_data)[vi].heap.erase(it->second);
+	      (*_node_data)[vi].heap_index.erase(it);
+	      if ((*_node_data)[vi].heap.empty()) {
+		_blossom_set->increase(v, std::numeric_limits<Value>::max());
+	      } else if ((*_blossom_set)[v] < (*_node_data)[vi].heap.prio()) {
+		_blossom_set->increase(v, (*_node_data)[vi].heap.prio());
+	      }
+	      
+	      if ((*_blossom_data)[vb].status == MATCHED) {
+		if (_blossom_set->classPrio(vb) == 
+		    std::numeric_limits<Value>::max()) {
+		  _delta2->erase(vb);
+		} else if ((*_delta2)[vb] < _blossom_set->classPrio(vb) -
+			   (*_blossom_data)[vb].offset) {
+		  _delta2->increase(vb, _blossom_set->classPrio(vb) -
+				   (*_blossom_data)[vb].offset);
+		}
+	      }	
+	    }	
+	  }
+	}
+      }
+    }
+
+    void oddToMatched(int blossom) {
+      (*_blossom_data)[blossom].offset -= _delta_sum;
+
+      if (_blossom_set->classPrio(blossom) != 
+	  std::numeric_limits<Value>::max()) {
+	_delta2->push(blossom, _blossom_set->classPrio(blossom) - 
+		       (*_blossom_data)[blossom].offset);
+      }
+
+      if (!_blossom_set->trivial(blossom)) {
+	_delta4->erase(blossom);
+      }
+    }
+
+    void oddToEven(int blossom, int tree) {
+      if (!_blossom_set->trivial(blossom)) {
+	_delta4->erase(blossom);
+	(*_blossom_data)[blossom].pot -= 
+	  2 * (2 * _delta_sum - (*_blossom_data)[blossom].offset);
+      }
+
+      for (typename BlossomSet::ItemIt n(*_blossom_set, blossom); 
+	   n != INVALID; ++n) {
+	int ni = (*_node_index)[n];
+
+	_blossom_set->increase(n, std::numeric_limits<Value>::max());
+
+	(*_node_data)[ni].heap.clear();
+	(*_node_data)[ni].heap_index.clear();
+	(*_node_data)[ni].pot += 
+	  2 * _delta_sum - (*_blossom_data)[blossom].offset;
+
+	for (InEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node v = _ugraph.source(e);
+	  int vb = _blossom_set->find(v);
+	  int vi = (*_node_index)[v];
+
+	  Value rw = (*_node_data)[ni].pot + (*_node_data)[vi].pot - 
+	    dualScale * _weight[e];
+
+	  if ((*_blossom_data)[vb].status == EVEN) {
+	    if (_delta3->state(e) != _delta3->IN_HEAP && blossom != vb) {
+	      _delta3->push(e, rw / 2);
+	    }
+	  } else {
+	  
+	    typename std::map<int, Edge>::iterator it = 
+	      (*_node_data)[vi].heap_index.find(tree);	  
+
+	    if (it != (*_node_data)[vi].heap_index.end()) {
+	      if ((*_node_data)[vi].heap[it->second] > rw) {
+		(*_node_data)[vi].heap.replace(it->second, e);
+		(*_node_data)[vi].heap.decrease(e, rw);
+		it->second = e;
+	      }
+	    } else {
+	      (*_node_data)[vi].heap.push(e, rw);
+	      (*_node_data)[vi].heap_index.insert(std::make_pair(tree, e));
+	    }
+
+	    if ((*_blossom_set)[v] > (*_node_data)[vi].heap.prio()) {
+	      _blossom_set->decrease(v, (*_node_data)[vi].heap.prio());
+
+	      if ((*_blossom_data)[vb].status == MATCHED) {
+		if (_delta2->state(vb) != _delta2->IN_HEAP) {
+		  _delta2->push(vb, _blossom_set->classPrio(vb) - 
+			       (*_blossom_data)[vb].offset);
+		} else if ((*_delta2)[vb] > _blossom_set->classPrio(vb) - 
+			   (*_blossom_data)[vb].offset) {
+		  _delta2->decrease(vb, _blossom_set->classPrio(vb) -
+				   (*_blossom_data)[vb].offset);
+		}
+	      }
+	    }
+	  }
+	}
+      }
+      (*_blossom_data)[blossom].offset = 0;
+    }
+    
+    void alternatePath(int even, int tree) {
+      int odd;
+
+      evenToMatched(even, tree);
+      (*_blossom_data)[even].status = MATCHED;
+
+      while ((*_blossom_data)[even].pred != INVALID) {
+	odd = _blossom_set->find(_ugraph.target((*_blossom_data)[even].pred));
+	(*_blossom_data)[odd].status = MATCHED;
+	oddToMatched(odd);
+	(*_blossom_data)[odd].next = (*_blossom_data)[odd].pred;
+      
+	even = _blossom_set->find(_ugraph.target((*_blossom_data)[odd].pred));
+	(*_blossom_data)[even].status = MATCHED;
+	evenToMatched(even, tree);
+	(*_blossom_data)[even].next = 
+	  _ugraph.oppositeEdge((*_blossom_data)[odd].pred);
+      }
+      
+    }
+
+    void destroyTree(int tree) {
+      for (TreeSet::ItemIt b(*_tree_set, tree); b != INVALID; ++b) {
+	if ((*_blossom_data)[b].status == EVEN) {
+	  (*_blossom_data)[b].status = MATCHED;
+	  evenToMatched(b, tree);
+	} else if ((*_blossom_data)[b].status == ODD) {
+	  (*_blossom_data)[b].status = MATCHED;
+	  oddToMatched(b);
+	}
+      }
+      _tree_set->eraseClass(tree);
+    }
+
+    void augmentOnEdge(const UEdge& edge) {
+      
+      int left = _blossom_set->find(_ugraph.source(edge));
+      int right = _blossom_set->find(_ugraph.target(edge));
+
+      int left_tree = _tree_set->find(left);
+      alternatePath(left, left_tree);
+      destroyTree(left_tree);
+
+      int right_tree = _tree_set->find(right);
+      alternatePath(right, right_tree);
+      destroyTree(right_tree);
+
+      (*_blossom_data)[left].next = _ugraph.direct(edge, true);
+      (*_blossom_data)[right].next = _ugraph.direct(edge, false);
+    }
+
+    void extendOnEdge(const Edge& edge) {
+      int base = _blossom_set->find(_ugraph.target(edge));
+      int tree = _tree_set->find(base);
+      
+      int odd = _blossom_set->find(_ugraph.source(edge));
+      _tree_set->insert(odd, tree);
+      (*_blossom_data)[odd].status = ODD;
+      matchedToOdd(odd);
+      (*_blossom_data)[odd].pred = edge;
+
+      int even = _blossom_set->find(_ugraph.target((*_blossom_data)[odd].next));
+      (*_blossom_data)[even].pred = (*_blossom_data)[even].next;
+      _tree_set->insert(even, tree);
+      (*_blossom_data)[even].status = EVEN;
+      matchedToEven(even, tree);
+    }
+    
+    void shrinkOnEdge(const UEdge& uedge, int tree) {
+      int nca = -1;
+      std::vector<int> left_path, right_path;
+
+      {
+	std::set<int> left_set, right_set;
+	int left = _blossom_set->find(_ugraph.source(uedge));
+	left_path.push_back(left);
+	left_set.insert(left);
+
+	int right = _blossom_set->find(_ugraph.target(uedge));
+	right_path.push_back(right);
+	right_set.insert(right);
+
+	while (true) {
+
+	  if ((*_blossom_data)[left].pred == INVALID) break;
+
+	  left = 
+	    _blossom_set->find(_ugraph.target((*_blossom_data)[left].pred));
+	  left_path.push_back(left);
+	  left = 
+	    _blossom_set->find(_ugraph.target((*_blossom_data)[left].pred));
+	  left_path.push_back(left);
+
+	  left_set.insert(left);
+
+	  if (right_set.find(left) != right_set.end()) {
+	    nca = left;
+	    break;
+	  }
+
+	  if ((*_blossom_data)[right].pred == INVALID) break;
+
+	  right = 
+	    _blossom_set->find(_ugraph.target((*_blossom_data)[right].pred));
+	  right_path.push_back(right);
+	  right = 
+	    _blossom_set->find(_ugraph.target((*_blossom_data)[right].pred));
+	  right_path.push_back(right);
+
+	  right_set.insert(right);
+ 
+	  if (left_set.find(right) != left_set.end()) {
+	    nca = right;
+	    break;
+	  }
+
+	}
+
+	if (nca == -1) {
+	  if ((*_blossom_data)[left].pred == INVALID) {
+	    nca = right;
+	    while (left_set.find(nca) == left_set.end()) {
+	      nca = 
+		_blossom_set->find(_ugraph.target((*_blossom_data)[nca].pred));
+	      right_path.push_back(nca);
+	      nca = 
+		_blossom_set->find(_ugraph.target((*_blossom_data)[nca].pred));
+	      right_path.push_back(nca);
+	    }
+	  } else {
+	    nca = left;
+	    while (right_set.find(nca) == right_set.end()) {
+	      nca = 
+		_blossom_set->find(_ugraph.target((*_blossom_data)[nca].pred));
+	      left_path.push_back(nca);
+	      nca = 
+		_blossom_set->find(_ugraph.target((*_blossom_data)[nca].pred));
+	      left_path.push_back(nca);
+	    }
+	  }
+	}
+      }
+
+      std::vector<int> subblossoms;
+      Edge prev;
+
+      prev = _ugraph.direct(uedge, true);
+      for (int i = 0; left_path[i] != nca; i += 2) {
+	subblossoms.push_back(left_path[i]);
+	(*_blossom_data)[left_path[i]].next = prev;
+	_tree_set->erase(left_path[i]);
+
+	subblossoms.push_back(left_path[i + 1]);
+	(*_blossom_data)[left_path[i + 1]].status = EVEN;
+	oddToEven(left_path[i + 1], tree);
+	_tree_set->erase(left_path[i + 1]);
+	prev = _ugraph.oppositeEdge((*_blossom_data)[left_path[i + 1]].pred);
+      }
+
+      int k = 0;
+      while (right_path[k] != nca) ++k;
+
+      subblossoms.push_back(nca);
+      (*_blossom_data)[nca].next = prev;
+      
+      for (int i = k - 2; i >= 0; i -= 2) {
+	subblossoms.push_back(right_path[i + 1]);
+	(*_blossom_data)[right_path[i + 1]].status = EVEN;
+	oddToEven(right_path[i + 1], tree);
+	_tree_set->erase(right_path[i + 1]);
+
+	(*_blossom_data)[right_path[i + 1]].next = 
+	  (*_blossom_data)[right_path[i + 1]].pred;
+
+	subblossoms.push_back(right_path[i]);
+	_tree_set->erase(right_path[i]);
+      }
+
+      int surface = 
+	_blossom_set->join(subblossoms.begin(), subblossoms.end());
+
+      for (int i = 0; i < int(subblossoms.size()); ++i) {
+	if (!_blossom_set->trivial(subblossoms[i])) {
+	  (*_blossom_data)[subblossoms[i]].pot += 2 * _delta_sum;
+	}
+	(*_blossom_data)[subblossoms[i]].status = MATCHED;
+      }
+
+      (*_blossom_data)[surface].pot = -2 * _delta_sum;
+      (*_blossom_data)[surface].offset = 0;
+      (*_blossom_data)[surface].status = EVEN;
+      (*_blossom_data)[surface].pred = (*_blossom_data)[nca].pred;
+      (*_blossom_data)[surface].next = (*_blossom_data)[nca].pred;
+
+      _tree_set->insert(surface, tree);
+      _tree_set->erase(nca);
+    }
+
+    void splitBlossom(int blossom) {
+      Edge next = (*_blossom_data)[blossom].next; 
+      Edge pred = (*_blossom_data)[blossom].pred;
+
+      int tree = _tree_set->find(blossom);
+
+      (*_blossom_data)[blossom].status = MATCHED;
+      oddToMatched(blossom);
+      if (_delta2->state(blossom) == _delta2->IN_HEAP) {
+	_delta2->erase(blossom);
+      }
+
+      std::vector<int> subblossoms;
+      _blossom_set->split(blossom, std::back_inserter(subblossoms));
+
+      Value offset = (*_blossom_data)[blossom].offset;
+      int b = _blossom_set->find(_ugraph.source(pred));
+      int d = _blossom_set->find(_ugraph.source(next));
+      
+      int ib = -1, id = -1;
+      for (int i = 0; i < int(subblossoms.size()); ++i) {
+	if (subblossoms[i] == b) ib = i;
+	if (subblossoms[i] == d) id = i;
+
+	(*_blossom_data)[subblossoms[i]].offset = offset;
+	if (!_blossom_set->trivial(subblossoms[i])) {
+	  (*_blossom_data)[subblossoms[i]].pot -= 2 * offset;
+	}
+	if (_blossom_set->classPrio(subblossoms[i]) != 
+	    std::numeric_limits<Value>::max()) {
+	  _delta2->push(subblossoms[i], 
+			_blossom_set->classPrio(subblossoms[i]) - 
+			(*_blossom_data)[subblossoms[i]].offset);
+	}
+      }
+      
+      if (id > ib ? ((id - ib) % 2 == 0) : ((ib - id) % 2 == 1)) {
+	for (int i = (id + 1) % subblossoms.size(); 
+	     i != ib; i = (i + 2) % subblossoms.size()) {
+	  int sb = subblossoms[i];
+	  int tb = subblossoms[(i + 1) % subblossoms.size()];
+	  (*_blossom_data)[sb].next = 
+	    _ugraph.oppositeEdge((*_blossom_data)[tb].next);
+	}
+
+	for (int i = ib; i != id; i = (i + 2) % subblossoms.size()) {
+	  int sb = subblossoms[i];
+	  int tb = subblossoms[(i + 1) % subblossoms.size()];
+	  int ub = subblossoms[(i + 2) % subblossoms.size()];
+
+	  (*_blossom_data)[sb].status = ODD;
+	  matchedToOdd(sb);
+	  _tree_set->insert(sb, tree);
+	  (*_blossom_data)[sb].pred = pred;
+	  (*_blossom_data)[sb].next = 
+			   _ugraph.oppositeEdge((*_blossom_data)[tb].next);
+	  
+	  pred = (*_blossom_data)[ub].next;
+      
+	  (*_blossom_data)[tb].status = EVEN;
+	  matchedToEven(tb, tree);
+	  _tree_set->insert(tb, tree);
+	  (*_blossom_data)[tb].pred = (*_blossom_data)[tb].next;
+	}
+      
+	(*_blossom_data)[subblossoms[id]].status = ODD;
+	matchedToOdd(subblossoms[id]);
+	_tree_set->insert(subblossoms[id], tree);
+	(*_blossom_data)[subblossoms[id]].next = next;
+	(*_blossom_data)[subblossoms[id]].pred = pred;
+      
+      } else {
+
+	for (int i = (ib + 1) % subblossoms.size(); 
+	     i != id; i = (i + 2) % subblossoms.size()) {
+	  int sb = subblossoms[i];
+	  int tb = subblossoms[(i + 1) % subblossoms.size()];
+	  (*_blossom_data)[sb].next = 
+	    _ugraph.oppositeEdge((*_blossom_data)[tb].next);
+	}	
+
+	for (int i = id; i != ib; i = (i + 2) % subblossoms.size()) {
+	  int sb = subblossoms[i];
+	  int tb = subblossoms[(i + 1) % subblossoms.size()];
+	  int ub = subblossoms[(i + 2) % subblossoms.size()];
+
+	  (*_blossom_data)[sb].status = ODD;
+	  matchedToOdd(sb);
+	  _tree_set->insert(sb, tree);
+	  (*_blossom_data)[sb].next = next; 
+	  (*_blossom_data)[sb].pred =
+	    _ugraph.oppositeEdge((*_blossom_data)[tb].next);
+
+	  (*_blossom_data)[tb].status = EVEN;
+	  matchedToEven(tb, tree);
+	  _tree_set->insert(tb, tree);
+	  (*_blossom_data)[tb].pred =
+	    (*_blossom_data)[tb].next = 
+	    _ugraph.oppositeEdge((*_blossom_data)[ub].next);
+	  next = (*_blossom_data)[ub].next;
+	}
+
+	(*_blossom_data)[subblossoms[ib]].status = ODD;
+	matchedToOdd(subblossoms[ib]);
+	_tree_set->insert(subblossoms[ib], tree);
+	(*_blossom_data)[subblossoms[ib]].next = next;
+	(*_blossom_data)[subblossoms[ib]].pred = pred;
+      }
+      _tree_set->erase(blossom);
+    }
+
+    void extractBlossom(int blossom, const Node& base, const Edge& matching) {
+      if (_blossom_set->trivial(blossom)) {
+	int bi = (*_node_index)[base];
+	Value pot = (*_node_data)[bi].pot;
+
+	_matching->set(base, matching);
+	_blossom_node_list.push_back(base);
+	_node_potential->set(base, pot);
+      } else {
+
+	Value pot = (*_blossom_data)[blossom].pot;
+	int bn = _blossom_node_list.size();
+	
+	std::vector<int> subblossoms;
+	_blossom_set->split(blossom, std::back_inserter(subblossoms));
+	int b = _blossom_set->find(base);
+	int ib = -1;
+	for (int i = 0; i < int(subblossoms.size()); ++i) {
+	  if (subblossoms[i] == b) { ib = i; break; }
+	}
+	
+	for (int i = 1; i < int(subblossoms.size()); i += 2) {
+	  int sb = subblossoms[(ib + i) % subblossoms.size()];
+	  int tb = subblossoms[(ib + i + 1) % subblossoms.size()];
+	  
+	  Edge m = (*_blossom_data)[tb].next;
+	  extractBlossom(sb, _ugraph.target(m), _ugraph.oppositeEdge(m));
+	  extractBlossom(tb, _ugraph.source(m), m);
+	}
+	extractBlossom(subblossoms[ib], base, matching);      
+	
+	int en = _blossom_node_list.size();
+	
+	_blossom_potential.push_back(BlossomVariable(bn, en, pot));
+      }
+    }
+
+    void extractMatching() {
+      std::vector<int> blossoms;
+      for (typename BlossomSet::ClassIt c(*_blossom_set); c != INVALID; ++c) {
+	blossoms.push_back(c);
+      }
+
+      for (int i = 0; i < int(blossoms.size()); ++i) {
+
+	Value offset = (*_blossom_data)[blossoms[i]].offset;
+	(*_blossom_data)[blossoms[i]].pot += 2 * offset;
+	for (typename BlossomSet::ItemIt n(*_blossom_set, blossoms[i]); 
+	     n != INVALID; ++n) {
+	  (*_node_data)[(*_node_index)[n]].pot -= offset;
+	}
+	
+	Edge matching = (*_blossom_data)[blossoms[i]].next;
+	Node base = _ugraph.source(matching);
+	extractBlossom(blossoms[i], base, matching);
+      }
+    }
+    
+  public:
+
+    /// \brief Constructor
+    ///
+    /// Constructor.
+    MaxWeightedPerfectMatching(const UGraph& ugraph, const WeightMap& weight)
+      : _ugraph(ugraph), _weight(weight), _matching(0),
+	_node_potential(0), _blossom_potential(), _blossom_node_list(),
+	_node_num(0), _blossom_num(0),
+
+	_blossom_index(0), _blossom_set(0), _blossom_data(0),
+	_node_index(0), _node_heap_index(0), _node_data(0),
+	_tree_set_index(0), _tree_set(0),
+
+	_delta2_index(0), _delta2(0),
+	_delta3_index(0), _delta3(0), 
+	_delta4_index(0), _delta4(0),
+
+	_delta_sum() {}
+
+    ~MaxWeightedPerfectMatching() {
+      destroyStructures();
+    }
+
+    /// \name Execution control 
+    /// The simplest way to execute the algorithm is to use the member
+    /// \c run() member function.
+
+    ///@{
+
+    /// \brief Initialize the algorithm
+    ///
+    /// Initialize the algorithm
+    void init() {
+      createStructures();
+
+      for (EdgeIt e(_ugraph); e != INVALID; ++e) {
+	_node_heap_index->set(e, BinHeap<Value, EdgeIntMap>::PRE_HEAP);
+      }
+      for (UEdgeIt e(_ugraph); e != INVALID; ++e) {
+	_delta3_index->set(e, _delta3->PRE_HEAP);
+      }
+      for (int i = 0; i < _blossom_num; ++i) {
+	_delta2_index->set(i, _delta2->PRE_HEAP);
+	_delta4_index->set(i, _delta4->PRE_HEAP);
+      }
+
+      int index = 0;
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	Value max = - std::numeric_limits<Value>::max();
+	for (OutEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  if (_ugraph.target(e) == n) continue;
+	  if ((dualScale * _weight[e]) / 2 > max) {
+	    max = (dualScale * _weight[e]) / 2;
+	  }
+	}
+	_node_index->set(n, index);
+	(*_node_data)[index].pot = max;
+	int blossom = 
+	  _blossom_set->insert(n, std::numeric_limits<Value>::max());
+
+	_tree_set->insert(blossom);
+
+	(*_blossom_data)[blossom].status = EVEN;
+	(*_blossom_data)[blossom].pred = INVALID;
+	(*_blossom_data)[blossom].next = INVALID;
+	(*_blossom_data)[blossom].pot = 0;
+	(*_blossom_data)[blossom].offset = 0;
+	++index;
+      }
+      for (UEdgeIt e(_ugraph); e != INVALID; ++e) {
+	int si = (*_node_index)[_ugraph.source(e)];
+	int ti = (*_node_index)[_ugraph.target(e)];
+	if (_ugraph.source(e) != _ugraph.target(e)) {
+	  _delta3->push(e, ((*_node_data)[si].pot + (*_node_data)[ti].pot - 
+			    dualScale * _weight[e]) / 2);
+	}
+      }
+    }
+
+    /// \brief Starts the algorithm
+    ///
+    /// Starts the algorithm
+    bool start() {
+      enum OpType {
+	D2, D3, D4
+      };
+
+      int unmatched = _node_num;
+      while (unmatched > 0) {
+	Value d2 = !_delta2->empty() ? 
+	  _delta2->prio() : std::numeric_limits<Value>::max();
+
+	Value d3 = !_delta3->empty() ? 
+	  _delta3->prio() : std::numeric_limits<Value>::max();
+
+	Value d4 = !_delta4->empty() ? 
+	  _delta4->prio() : std::numeric_limits<Value>::max();
+
+	_delta_sum = d2; OpType ot = D2;
+	if (d3 < _delta_sum) { _delta_sum = d3; ot = D3; }
+	if (d4 < _delta_sum) { _delta_sum = d4; ot = D4; }
+
+	if (_delta_sum == std::numeric_limits<Value>::max()) {
+	  return false;
+	}
+	
+	switch (ot) {
+	case D2:
+	  {
+	    int blossom = _delta2->top();
+	    Node n = _blossom_set->classTop(blossom);
+	    Edge e = (*_node_data)[(*_node_index)[n]].heap.top();
+	    extendOnEdge(e);
+	  }
+	  break;
+	case D3:
+	  {
+	    UEdge e = _delta3->top();
+	    
+	    int left_blossom = _blossom_set->find(_ugraph.source(e));
+	    int right_blossom = _blossom_set->find(_ugraph.target(e));
+	  
+	    if (left_blossom == right_blossom) {
+	      _delta3->pop();
+	    } else {
+	      int left_tree = _tree_set->find(left_blossom);
+	      int right_tree = _tree_set->find(right_blossom);
+	    
+	      if (left_tree == right_tree) {
+		shrinkOnEdge(e, left_tree);
+	      } else {
+		augmentOnEdge(e);
+		unmatched -= 2;
+	      }
+	    }
+	  } break;
+	case D4:
+	  splitBlossom(_delta4->top());
+	  break;
+	}
+      }
+      extractMatching();
+      return true;
+    }
+
+    /// \brief Runs %MaxWeightedPerfectMatching algorithm.
+    ///
+    /// This method runs the %MaxWeightedPerfectMatching algorithm.
+    ///
+    /// \note mwm.run() is just a shortcut of the following code.
+    /// \code
+    ///   mwm.init();
+    ///   mwm.start();
+    /// \endcode
+    bool run() {
+      init();
+      return start();
+    }
+
+    /// @}
+
+    /// \name Primal solution
+    /// Functions for get the primal solution, ie. the matching.
+    
+    /// @{
+
+    /// \brief Returns the matching value.
+    ///
+    /// Returns the matching value.
+    Value matchingValue() const {
+      Value sum = 0;
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	if ((*_matching)[n] != INVALID) {
+	  sum += _weight[(*_matching)[n]];
+	}
+      }
+      return sum /= 2;
+    }
+
+    /// \brief Returns true when the edge is in the matching.
+    ///
+    /// Returns true when the edge is in the matching.
+    bool matching(const UEdge& edge) const {
+      return (*_matching)[_ugraph.source(edge)] == _ugraph.direct(edge, true);
+    }
+
+    /// \brief Returns the incident matching edge.
+    ///
+    /// Returns the incident matching edge from given node.
+    Edge matching(const Node& node) const {
+      return (*_matching)[node];
+    }
+
+    /// \brief Returns the mate of the node.
+    ///
+    /// Returns the adjancent node in a mathcing edge.
+    Node mate(const Node& node) const {
+      return _ugraph.target((*_matching)[node]);
+    }
+
+    /// @}
+
+    /// \name Dual solution
+    /// Functions for get the dual solution.
+    
+    /// @{
+
+    /// \brief Returns the value of the dual solution.
+    ///
+    /// Returns the value of the dual solution. It should be equal to
+    /// the primal value scaled by \ref dualScale "dual scale".
+    Value dualValue() const {
+      Value sum = 0;
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	sum += nodeValue(n);
+      }
+      for (int i = 0; i < blossomNum(); ++i) {
+        sum += blossomValue(i) * (blossomSize(i) / 2);
+      }
+      return sum;
+    }
+
+    /// \brief Returns the value of the node.
+    ///
+    /// Returns the the value of the node.
+    Value nodeValue(const Node& n) const {
+      return (*_node_potential)[n];
+    }
+
+    /// \brief Returns the number of the blossoms in the basis.
+    ///
+    /// Returns the number of the blossoms in the basis.
+    /// \see BlossomIt
+    int blossomNum() const {
+      return _blossom_potential.size();
+    }
+
+
+    /// \brief Returns the number of the nodes in the blossom.
+    ///
+    /// Returns the number of the nodes in the blossom.
+    int blossomSize(int k) const {
+      return _blossom_potential[k].end - _blossom_potential[k].begin;
+    }
+
+    /// \brief Returns the value of the blossom.
+    ///
+    /// Returns the the value of the blossom.
+    /// \see BlossomIt
+    Value blossomValue(int k) const {
+      return _blossom_potential[k].value;
+    }
+
+    /// \brief Lemon iterator for get the items of the blossom.
+    ///
+    /// Lemon iterator for get the nodes of the blossom. This class
+    /// provides a common style lemon iterator which gives back a
+    /// subset of the nodes.
+    class BlossomIt {
+    public:
+
+      /// \brief Constructor.
+      ///
+      /// Constructor for get the nodes of the variable. 
+      BlossomIt(const MaxWeightedPerfectMatching& algorithm, int variable) 
+        : _algorithm(&algorithm)
+      {
+        _index = _algorithm->_blossom_potential[variable].begin;
+        _last = _algorithm->_blossom_potential[variable].end;
+      }
+
+      /// \brief Invalid constructor.
+      ///
+      /// Invalid constructor.
+      BlossomIt(Invalid) : _index(-1) {}
+
+      /// \brief Conversion to node.
+      ///
+      /// Conversion to node.
+      operator Node() const { 
+        return _algorithm ? _algorithm->_blossom_node_list[_index] : INVALID;
+      }
+
+      /// \brief Increment operator.
+      ///
+      /// Increment operator.
+      BlossomIt& operator++() {
+        ++_index;
+        if (_index == _last) {
+          _index = -1;
+        }
+        return *this; 
+      }
+
+      bool operator==(const BlossomIt& it) const { 
+        return _index == it._index; 
+      }
+      bool operator!=(const BlossomIt& it) const { 
+        return _index != it._index;
+      }
+
+    private:
+      const MaxWeightedPerfectMatching* _algorithm;
+      int _last;
+      int _index;
+    };
+
+    /// @}
+    
+  };
+
+  
+} //END OF NAMESPACE LEMON
+
+#endif //LEMON_MAX_MATCHING_H
Index: lemon/min_cost_arborescence.h
===================================================================
--- lemon/min_cost_arborescence.h	(revision 2624)
+++ lemon/min_cost_arborescence.h	(revision 2624)
@@ -0,0 +1,814 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MIN_COST_ARBORESCENCE_H
+#define LEMON_MIN_COST_ARBORESCENCE_H
+
+///\ingroup spantree
+///\file
+///\brief Minimum Cost Arborescence algorithm.
+
+#include <vector>
+
+#include <lemon/list_graph.h>
+#include <lemon/bin_heap.h>
+
+namespace lemon {
+
+
+  /// \brief Default traits class of MinCostArborescence class.
+  /// 
+  /// Default traits class of MinCostArborescence class.
+  /// \param _Graph Graph type.
+  /// \param _CostMap Type of cost map.
+  template <class _Graph, class _CostMap>
+  struct MinCostArborescenceDefaultTraits{
+
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge costs.
+    ///
+    /// The type of the map that stores the edge costs.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _CostMap CostMap;
+
+    /// \brief The value type of the costs.
+    ///
+    /// The value type of the costs.
+    typedef typename CostMap::Value Value;
+
+    /// \brief The type of the map that stores which edges are 
+    /// in the arborescence.
+    ///
+    /// The type of the map that stores which edges are in the arborescence.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    /// Initially it will be set to false on each edge. After it
+    /// will set all arborescence edges once.
+    typedef typename Graph::template EdgeMap<bool> ArborescenceMap; 
+
+    /// \brief Instantiates a ArborescenceMap.
+    ///
+    /// This function instantiates a \ref ArborescenceMap. 
+    /// \param _graph is the graph, to which we would like to define the 
+    /// ArborescenceMap.
+    static ArborescenceMap *createArborescenceMap(const Graph &_graph){
+      return new ArborescenceMap(_graph);
+    }
+
+    /// \brief The type of the PredMap
+    ///
+    /// The type of the PredMap. It is a node map with an edge value type.
+    typedef typename Graph::template NodeMap<typename Graph::Edge> PredMap;
+
+    /// \brief Instantiates a PredMap.
+    ///
+    /// This function instantiates a \ref PredMap. 
+    /// \param _graph is the graph, to which we would like to define the 
+    /// PredMap.
+    static PredMap *createPredMap(const Graph &_graph){
+      return new PredMap(_graph);
+    }
+    
+  };
+
+  /// \ingroup spantree
+  ///
+  /// \brief %MinCostArborescence algorithm class.
+  ///
+  /// This class provides an efficient implementation of 
+  /// %MinCostArborescence algorithm. The arborescence is a tree 
+  /// which is directed from a given source node of the graph. One or
+  /// more sources should be given for the algorithm and it will calculate
+  /// the minimum cost subgraph which are union of arborescences with the
+  /// given sources and spans all the nodes which are reachable from the
+  /// sources. The time complexity of the algorithm is \f$ O(n^2+e) \f$.
+  ///
+  /// The algorithm provides also an optimal dual solution to arborescence
+  /// that way the optimality of the solution can be proofed easily.
+  ///
+  /// \param _Graph The graph type the algorithm runs on. The default value
+  /// is \ref ListGraph. The value of _Graph is not used directly by
+  /// MinCostArborescence, it is only passed to 
+  /// \ref MinCostArborescenceDefaultTraits.
+  /// \param _CostMap This read-only EdgeMap determines the costs of the
+  /// edges. It is read once for each edge, so the map may involve in
+  /// relatively time consuming process to compute the edge cost if
+  /// it is necessary. The default map type is \ref
+  /// concepts::Graph::EdgeMap "Graph::EdgeMap<int>".  The value
+  /// of _CostMap is not used directly by MinCostArborescence, 
+  /// it is only passed to \ref MinCostArborescenceDefaultTraits.  
+  /// \param _Traits Traits class to set various data types used 
+  /// by the algorithm.  The default traits class is 
+  /// \ref MinCostArborescenceDefaultTraits
+  /// "MinCostArborescenceDefaultTraits<_Graph,_CostMap>".  See \ref
+  /// MinCostArborescenceDefaultTraits for the documentation of a 
+  /// MinCostArborescence traits class.
+  ///
+  /// \author Balazs Dezso
+#ifndef DOXYGEN
+  template <typename _Graph = ListGraph, 
+            typename _CostMap = typename _Graph::template EdgeMap<int>,
+            typename _Traits = 
+            MinCostArborescenceDefaultTraits<_Graph, _CostMap> >
+#else 
+  template <typename _Graph, typename _CostMap, typedef _Traits>
+#endif
+  class MinCostArborescence {
+  public:
+
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.    
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::MinCostArborescence::UninitializedParameter";
+      }
+    };
+
+    /// The traits.
+    typedef _Traits Traits;
+    /// The type of the underlying graph.
+    typedef typename Traits::Graph Graph;
+    /// The type of the map that stores the edge costs.
+    typedef typename Traits::CostMap CostMap;
+    ///The type of the costs of the edges.
+    typedef typename Traits::Value Value;
+    ///The type of the predecessor map.
+    typedef typename Traits::PredMap PredMap;
+    ///The type of the map that stores which edges are in the arborescence.
+    typedef typename Traits::ArborescenceMap ArborescenceMap;
+
+  protected:
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::EdgeIt EdgeIt;
+    typedef typename Graph::InEdgeIt InEdgeIt;
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+
+    struct CostEdge {
+
+      Edge edge;
+      Value value;
+
+      CostEdge() {}
+      CostEdge(Edge _edge, Value _value) : edge(_edge), value(_value) {}
+
+    };
+
+    const Graph *graph;
+    const CostMap *cost;
+
+    PredMap *_pred;
+    bool local_pred;
+
+    ArborescenceMap *_arborescence;
+    bool local_arborescence;
+
+    typedef typename Graph::template EdgeMap<int> EdgeOrder;
+    EdgeOrder *_edge_order;
+    
+    typedef typename Graph::template NodeMap<int> NodeOrder;
+    NodeOrder *_node_order;
+
+    typedef typename Graph::template NodeMap<CostEdge> CostEdgeMap;
+    CostEdgeMap *_cost_edges; 
+
+    struct StackLevel {
+
+      std::vector<CostEdge> edges;
+      int node_level;
+
+    };
+
+    std::vector<StackLevel> level_stack;    
+    std::vector<Node> queue;
+
+    typedef std::vector<typename Graph::Node> DualNodeList;
+
+    DualNodeList _dual_node_list;
+
+    struct DualVariable {
+      int begin, end;
+      Value value;
+      
+      DualVariable(int _begin, int _end, Value _value)
+        : begin(_begin), end(_end), value(_value) {}
+
+    };
+
+    typedef std::vector<DualVariable> DualVariables;
+
+    DualVariables _dual_variables;
+
+    typedef typename Graph::template NodeMap<int> HeapCrossRef;
+    
+    HeapCrossRef *_heap_cross_ref;
+
+    typedef BinHeap<int, HeapCrossRef> Heap;
+
+    Heap *_heap;
+
+  public:
+
+    /// \name Named template parameters
+
+    /// @{
+
+    template <class T>
+    struct DefArborescenceMapTraits : public Traits {
+      typedef T ArborescenceMap;
+      static ArborescenceMap *createArborescenceMap(const Graph &)
+      {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for 
+    /// setting ArborescenceMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting 
+    /// ArborescenceMap type
+    template <class T>
+    struct DefArborescenceMap 
+      : public MinCostArborescence<Graph, CostMap,
+                                   DefArborescenceMapTraits<T> > {
+      typedef MinCostArborescence<Graph, CostMap, 
+                                   DefArborescenceMapTraits<T> > Create;
+    };
+
+    template <class T>
+    struct DefPredMapTraits : public Traits {
+      typedef T PredMap;
+      static PredMap *createPredMap(const Graph &)
+      {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for 
+    /// setting PredMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting 
+    /// PredMap type
+    template <class T>
+    struct DefPredMap 
+      : public MinCostArborescence<Graph, CostMap, DefPredMapTraits<T> > {
+      typedef MinCostArborescence<Graph, CostMap, DefPredMapTraits<T> > Create;
+    };
+    
+    /// @}
+
+    /// \brief Constructor.
+    ///
+    /// \param _graph The graph the algorithm will run on.
+    /// \param _cost The cost map used by the algorithm.
+    MinCostArborescence(const Graph& _graph, const CostMap& _cost) 
+      : graph(&_graph), cost(&_cost), _pred(0), local_pred(false),
+        _arborescence(0), local_arborescence(false), 
+        _edge_order(0), _node_order(0), _cost_edges(0), 
+        _heap_cross_ref(0), _heap(0) {}
+
+    /// \brief Destructor.
+    ~MinCostArborescence() {
+      destroyStructures();
+    }
+
+    /// \brief Sets the arborescence map.
+    /// 
+    /// Sets the arborescence map.
+    /// \return \c (*this)
+    MinCostArborescence& arborescenceMap(ArborescenceMap& m) {
+      if (local_arborescence) {
+        delete _arborescence;
+      }
+      local_arborescence = false;
+      _arborescence = &m;
+      return *this;
+    }
+
+    /// \brief Sets the arborescence map.
+    /// 
+    /// Sets the arborescence map.
+    /// \return \c (*this)
+    MinCostArborescence& predMap(PredMap& m) {
+      if (local_pred) {
+        delete _pred;
+      }
+      local_pred = false;
+      _pred = &m;
+      return *this;
+    }
+
+    /// \name Query Functions
+    /// The result of the %MinCostArborescence algorithm can be obtained 
+    /// using these functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    /// @{
+
+    /// \brief Returns a reference to the arborescence map.
+    ///
+    /// Returns a reference to the arborescence map.
+    const ArborescenceMap& arborescenceMap() const {
+      return *_arborescence;
+    }
+
+    /// \brief Returns true if the edge is in the arborescence.
+    ///
+    /// Returns true if the edge is in the arborescence.
+    /// \param edge The edge of the graph.
+    /// \pre \ref run() must be called before using this function.
+    bool arborescence(Edge edge) const {
+      return (*_pred)[graph->target(edge)] == edge;
+    }
+
+    /// \brief Returns a reference to the pred map.
+    ///
+    /// Returns a reference to the pred map.
+    const PredMap& predMap() const {
+      return *_pred;
+    }
+
+    /// \brief Returns the predecessor edge of the given node.
+    ///
+    /// Returns the predecessor edge of the given node.
+    bool pred(Node node) const {
+      return (*_pred)[node];
+    }
+ 
+    /// \brief Returns the cost of the arborescence.
+    ///
+    /// Returns the cost of the arborescence.
+    Value arborescenceValue() const {
+      Value sum = 0;
+      for (EdgeIt it(*graph); it != INVALID; ++it) {
+        if (arborescence(it)) {
+          sum += (*cost)[it];
+        }
+      }
+      return sum;
+    }
+
+    /// \brief Indicates that a node is reachable from the sources.
+    ///
+    /// Indicates that a node is reachable from the sources.
+    bool reached(Node node) const {
+      return (*_node_order)[node] != -3;
+    }
+
+    /// \brief Indicates that a node is processed.
+    ///
+    /// Indicates that a node is processed. The arborescence path exists 
+    /// from the source to the given node.
+    bool processed(Node node) const {
+      return (*_node_order)[node] == -1;
+    }
+
+    /// \brief Returns the number of the dual variables in basis.
+    ///
+    /// Returns the number of the dual variables in basis.
+    int dualSize() const {
+      return _dual_variables.size();
+    }
+
+    /// \brief Returns the value of the dual solution.
+    ///
+    /// Returns the value of the dual solution. It should be
+    /// equal to the arborescence value.
+    Value dualValue() const {
+      Value sum = 0;
+      for (int i = 0; i < int(_dual_variables.size()); ++i) {
+        sum += _dual_variables[i].value;
+      }
+      return sum;
+    }
+
+    /// \brief Returns the number of the nodes in the dual variable.
+    ///
+    /// Returns the number of the nodes in the dual variable.
+    int dualSize(int k) const {
+      return _dual_variables[k].end - _dual_variables[k].begin;
+    }
+
+    /// \brief Returns the value of the dual variable.
+    ///
+    /// Returns the the value of the dual variable.
+    const Value& dualValue(int k) const {
+      return _dual_variables[k].value;
+    }
+
+    /// \brief Lemon iterator for get a dual variable.
+    ///
+    /// Lemon iterator for get a dual variable. This class provides
+    /// a common style lemon iterator which gives back a subset of
+    /// the nodes.
+    class DualIt {
+    public:
+
+      /// \brief Constructor.
+      ///
+      /// Constructor for get the nodeset of the variable. 
+      DualIt(const MinCostArborescence& algorithm, int variable) 
+        : _algorithm(&algorithm), _variable(variable) 
+      {
+        _index = _algorithm->_dual_variables[_variable].begin;
+      }
+
+      /// \brief Invalid constructor.
+      ///
+      /// Invalid constructor.
+      DualIt(Invalid) : _algorithm(0) {}
+
+      /// \brief Conversion to node.
+      ///
+      /// Conversion to node.
+      operator Node() const { 
+        return _algorithm ? _algorithm->_dual_node_list[_index] : INVALID;
+      }
+
+      /// \brief Increment operator.
+      ///
+      /// Increment operator.
+      DualIt& operator++() {
+        ++_index;
+        if (_algorithm->_dual_variables[_variable].end == _index) {
+          _algorithm = 0;
+        }
+        return *this; 
+      }
+
+      bool operator==(const DualIt& it) const { 
+        return static_cast<Node>(*this) == static_cast<Node>(it); 
+      }
+      bool operator!=(const DualIt& it) const { 
+        return static_cast<Node>(*this) != static_cast<Node>(it); 
+      }
+      bool operator<(const DualIt& it) const { 
+        return static_cast<Node>(*this) < static_cast<Node>(it); 
+      }
+      
+    private:
+      const MinCostArborescence* _algorithm;
+      int _variable;
+      int _index;
+    };
+
+    /// @}
+    
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run(...). \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init(), then you can add several 
+    /// source nodes with \ref addSource().
+    /// Finally \ref start() will perform the arborescence
+    /// computation.
+
+    ///@{
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    ///
+    void init() {
+      initStructures();
+      _heap->clear();
+      for (NodeIt it(*graph); it != INVALID; ++it) {
+        (*_cost_edges)[it].edge = INVALID;
+        _node_order->set(it, -3); 
+        _heap_cross_ref->set(it, Heap::PRE_HEAP);
+        _pred->set(it, INVALID);
+      }
+      for (EdgeIt it(*graph); it != INVALID; ++it) {
+        _arborescence->set(it, false);
+        _edge_order->set(it, -1);
+      }
+      _dual_node_list.clear();
+      _dual_variables.clear();
+    }
+
+    /// \brief Adds a new source node.
+    ///
+    /// Adds a new source node to the algorithm.
+    void addSource(Node source) {
+      std::vector<Node> nodes;
+      nodes.push_back(source);
+      while (!nodes.empty()) {
+        Node node = nodes.back();
+        nodes.pop_back();
+        for (OutEdgeIt it(*graph, node); it != INVALID; ++it) {
+          Node target = graph->target(it);
+          if ((*_node_order)[target] == -3) {
+            (*_node_order)[target] = -2;
+            nodes.push_back(target);
+            queue.push_back(target);
+          }
+        }
+      }
+      (*_node_order)[source] = -1;
+    }
+
+    /// \brief Processes the next node in the priority queue.
+    ///
+    /// Processes the next node in the priority queue.
+    ///
+    /// \return The processed node.
+    ///
+    /// \warning The queue must not be empty!
+    Node processNextNode() {
+      Node node = queue.back();
+      queue.pop_back();
+      if ((*_node_order)[node] == -2) {
+        Edge edge = prepare(node);
+        Node source = graph->source(edge);
+        while ((*_node_order)[source] != -1) {
+          if ((*_node_order)[source] >= 0) {
+            edge = contract(source);
+          } else {
+            edge = prepare(source);
+          }
+          source = graph->source(edge);
+        }
+        finalize(edge);
+        level_stack.clear();        
+      }
+      return node;
+    }
+
+    /// \brief Returns the number of the nodes to be processed.
+    ///
+    /// Returns the number of the nodes to be processed.
+    int queueSize() const {
+      return queue.size();
+    }
+
+    /// \brief Returns \c false if there are nodes to be processed.
+    ///
+    /// Returns \c false if there are nodes to be processed.
+    bool emptyQueue() const {
+      return queue.empty();
+    }
+
+    /// \brief Executes the algorithm.
+    ///
+    /// Executes the algorithm.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    ///
+    ///\note mca.start() is just a shortcut of the following code.
+    ///\code
+    ///while (!mca.emptyQueue()) {
+    ///  mca.processNextNode();
+    ///}
+    ///\endcode
+    void start() {
+      while (!emptyQueue()) {
+        processNextNode();
+      }
+    }
+
+    /// \brief Runs %MinCostArborescence algorithm from node \c s.
+    /// 
+    /// This method runs the %MinCostArborescence algorithm from 
+    /// a root node \c s.
+    ///
+    ///\note mca.run(s) is just a shortcut of the following code.
+    ///\code
+    ///mca.init();
+    ///mca.addSource(s);
+    ///mca.start();
+    ///\endcode
+    void run(Node node) {
+      init();
+      addSource(node);
+      start();
+    }
+
+    ///@}
+
+  protected:
+
+    void initStructures() {
+      if (!_pred) {
+        local_pred = true;
+        _pred = Traits::createPredMap(*graph);
+      }
+      if (!_arborescence) {
+        local_arborescence = true;
+        _arborescence = Traits::createArborescenceMap(*graph);
+      }
+      if (!_edge_order) {
+        _edge_order = new EdgeOrder(*graph);
+      }
+      if (!_node_order) {
+        _node_order = new NodeOrder(*graph);
+      }
+      if (!_cost_edges) {
+        _cost_edges = new CostEdgeMap(*graph);
+      }
+      if (!_heap_cross_ref) {
+        _heap_cross_ref = new HeapCrossRef(*graph, -1);
+      }
+      if (!_heap) {
+        _heap = new Heap(*_heap_cross_ref);
+      }
+    }
+
+    void destroyStructures() {
+      if (local_arborescence) {
+        delete _arborescence;
+      }
+      if (local_pred) {
+        delete _pred;
+      }
+      if (_edge_order) {
+        delete _edge_order;
+      }
+      if (_node_order) {
+        delete _node_order;
+      }
+      if (_cost_edges) {
+        delete _cost_edges;
+      }
+      if (_heap) {
+        delete _heap;
+      }
+      if (_heap_cross_ref) {
+        delete _heap_cross_ref;
+      }
+    }
+
+    Edge prepare(Node node) {
+      std::vector<Node> nodes;
+      (*_node_order)[node] = _dual_node_list.size();
+      StackLevel level;
+      level.node_level = _dual_node_list.size();
+      _dual_node_list.push_back(node);
+      for (InEdgeIt it(*graph, node); it != INVALID; ++it) {
+        Edge edge = it;
+        Node source = graph->source(edge);
+        Value value = (*cost)[it];
+        if (source == node || (*_node_order)[source] == -3) continue;
+        if ((*_cost_edges)[source].edge == INVALID) {
+          (*_cost_edges)[source].edge = edge;
+          (*_cost_edges)[source].value = value;
+          nodes.push_back(source);
+        } else {
+          if ((*_cost_edges)[source].value > value) {
+            (*_cost_edges)[source].edge = edge;
+            (*_cost_edges)[source].value = value;
+          }
+        }      
+      }
+      CostEdge minimum = (*_cost_edges)[nodes[0]]; 
+      for (int i = 1; i < int(nodes.size()); ++i) {
+        if ((*_cost_edges)[nodes[i]].value < minimum.value) {
+          minimum = (*_cost_edges)[nodes[i]];
+        }
+      }
+      _edge_order->set(minimum.edge, _dual_variables.size());
+      DualVariable var(_dual_node_list.size() - 1, 
+                       _dual_node_list.size(), minimum.value);
+      _dual_variables.push_back(var);
+      for (int i = 0; i < int(nodes.size()); ++i) {
+        (*_cost_edges)[nodes[i]].value -= minimum.value;
+        level.edges.push_back((*_cost_edges)[nodes[i]]);
+        (*_cost_edges)[nodes[i]].edge = INVALID;
+      }
+      level_stack.push_back(level);
+      return minimum.edge;
+    }
+  
+    Edge contract(Node node) {
+      int node_bottom = bottom(node);
+      std::vector<Node> nodes;
+      while (!level_stack.empty() && 
+             level_stack.back().node_level >= node_bottom) {
+        for (int i = 0; i < int(level_stack.back().edges.size()); ++i) {
+          Edge edge = level_stack.back().edges[i].edge;
+          Node source = graph->source(edge);
+          Value value = level_stack.back().edges[i].value;
+          if ((*_node_order)[source] >= node_bottom) continue;
+          if ((*_cost_edges)[source].edge == INVALID) {
+            (*_cost_edges)[source].edge = edge;
+            (*_cost_edges)[source].value = value;
+            nodes.push_back(source);
+          } else {
+            if ((*_cost_edges)[source].value > value) {
+              (*_cost_edges)[source].edge = edge;
+              (*_cost_edges)[source].value = value;
+            }
+          }
+        }
+        level_stack.pop_back();
+      }
+      CostEdge minimum = (*_cost_edges)[nodes[0]]; 
+      for (int i = 1; i < int(nodes.size()); ++i) {
+        if ((*_cost_edges)[nodes[i]].value < minimum.value) {
+          minimum = (*_cost_edges)[nodes[i]];
+        }
+      }
+      _edge_order->set(minimum.edge, _dual_variables.size());
+      DualVariable var(node_bottom, _dual_node_list.size(), minimum.value);
+      _dual_variables.push_back(var);
+      StackLevel level;
+      level.node_level = node_bottom;
+      for (int i = 0; i < int(nodes.size()); ++i) {
+        (*_cost_edges)[nodes[i]].value -= minimum.value;
+        level.edges.push_back((*_cost_edges)[nodes[i]]);
+        (*_cost_edges)[nodes[i]].edge = INVALID;
+      }
+      level_stack.push_back(level);
+      return minimum.edge;
+    }
+
+    int bottom(Node node) {
+      int k = level_stack.size() - 1;
+      while (level_stack[k].node_level > (*_node_order)[node]) {
+        --k;
+      }
+      return level_stack[k].node_level;
+    }
+
+    void finalize(Edge edge) {
+      Node node = graph->target(edge);
+      _heap->push(node, (*_edge_order)[edge]);
+      _pred->set(node, edge);
+      while (!_heap->empty()) {
+        Node source = _heap->top();
+        _heap->pop();
+        _node_order->set(source, -1);
+        for (OutEdgeIt it(*graph, source); it != INVALID; ++it) {
+          if ((*_edge_order)[it] < 0) continue;
+          Node target = graph->target(it);
+          switch(_heap->state(target)) {
+          case Heap::PRE_HEAP:
+            _heap->push(target, (*_edge_order)[it]); 
+            _pred->set(target, it);
+            break;
+          case Heap::IN_HEAP:
+            if ((*_edge_order)[it] < (*_heap)[target]) {
+              _heap->decrease(target, (*_edge_order)[it]); 
+              _pred->set(target, it);
+            }
+            break;
+          case Heap::POST_HEAP:
+            break;
+          }
+        }
+        _arborescence->set((*_pred)[source], true);
+      }
+    }
+
+  };
+
+  /// \ingroup spantree
+  ///
+  /// \brief Function type interface for MinCostArborescence algorithm.
+  ///
+  /// Function type interface for MinCostArborescence algorithm.
+  /// \param graph The Graph that the algorithm runs on.
+  /// \param cost The CostMap of the edges.
+  /// \param source The source of the arborescence.
+  /// \retval arborescence The bool EdgeMap which stores the arborescence.
+  /// \return The cost of the arborescence. 
+  ///
+  /// \sa MinCostArborescence
+  template <typename Graph, typename CostMap, typename ArborescenceMap>
+  typename CostMap::Value minCostArborescence(const Graph& graph, 
+                                              const CostMap& cost,
+                                              typename Graph::Node source,
+                                              ArborescenceMap& arborescence) {
+    typename MinCostArborescence<Graph, CostMap>
+      ::template DefArborescenceMap<ArborescenceMap>
+      ::Create mca(graph, cost);
+    mca.arborescenceMap(arborescence);
+    mca.run(source);
+    return mca.arborescenceValue();
+  }
+
+}
+
+#endif
Index: lemon/min_cost_flow.h
===================================================================
--- lemon/min_cost_flow.h	(revision 2620)
+++ lemon/min_cost_flow.h	(revision 2620)
@@ -0,0 +1,121 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MIN_COST_FLOW_H
+#define LEMON_MIN_COST_FLOW_H
+
+/// \ingroup min_cost_flow
+///
+/// \file
+/// \brief An efficient algorithm for finding a minimum cost flow.
+
+#include <lemon/network_simplex.h>
+
+namespace lemon {
+
+  /// \addtogroup min_cost_flow
+  /// @{
+
+  /// \brief An efficient algorithm for finding a minimum cost flow.
+  ///
+  /// \ref MinCostFlow provides an efficient algorithm for finding
+  /// a minimum cost flow.
+  ///
+  /// This class is just an alias for \ref NetworkSimplex,
+  /// which is the most efficient algorithm for the minimum cost
+  /// flow problem in LEMON according to our benchmark tests.
+  /// For the detailed documentation of this class see
+  /// \ref NetworkSimplex.
+  ///
+  /// There are four implementations for the minimum cost flow problem,
+  /// which can be used exactly the same way.
+  /// - \ref CapacityScaling
+  /// - \ref CostScaling
+  /// - \ref CycleCanceling
+  /// - \ref NetworkSimplex
+  ///
+  /// \tparam Graph The directed graph type the algorithm runs on.
+  /// \tparam LowerMap The type of the lower bound map.
+  /// \tparam CapacityMap The type of the capacity (upper bound) map.
+  /// \tparam CostMap The type of the cost (length) map.
+  /// \tparam SupplyMap The type of the supply map.
+  ///
+  /// \warning
+  /// - Edge capacities and costs should be \e non-negative \e integers.
+  /// - Supply values should be \e signed \e integers.
+  /// - The value types of the maps should be convertible to each other.
+  /// - \c CostMap::Value must be signed type.
+  ///
+  /// \author Peter Kovacs
+  template < typename Graph,
+             typename LowerMap = typename Graph::template EdgeMap<int>,
+             typename CapacityMap = typename Graph::template EdgeMap<int>,
+             typename CostMap = typename Graph::template EdgeMap<int>,
+             typename SupplyMap = typename Graph::template NodeMap<int> >
+  class MinCostFlow :
+    public NetworkSimplex< Graph, LowerMap, CapacityMap,
+                           CostMap, SupplyMap >
+  {
+    typedef NetworkSimplex< Graph, LowerMap, CapacityMap,
+                            CostMap, SupplyMap > MinCostFlowImpl;
+    typedef typename Graph::Node Node;
+    typedef typename SupplyMap::Value Supply;
+
+  public:
+
+    /// General constructor (with lower bounds).
+    MinCostFlow( const Graph &graph,
+                 const LowerMap &lower,
+                 const CapacityMap &capacity,
+                 const CostMap &cost,
+                 const SupplyMap &supply ) :
+      MinCostFlowImpl(graph, lower, capacity, cost, supply) {}
+
+    /// General constructor of the class (without lower bounds).
+    MinCostFlow( const Graph &graph,
+                 const CapacityMap &capacity,
+                 const CostMap &cost,
+                 const SupplyMap &supply ) :
+      MinCostFlowImpl(graph, capacity, cost, supply) {}
+
+    /// Simple constructor (with lower bounds).
+    MinCostFlow( const Graph &graph,
+                 const LowerMap &lower,
+                 const CapacityMap &capacity,
+                 const CostMap &cost,
+                 Node s, Node t,
+                 Supply flow_value ) :
+      MinCostFlowImpl( graph, lower, capacity, cost,
+                       s, t, flow_value ) {}
+
+    /// Simple constructor (without lower bounds).
+    MinCostFlow( const Graph &graph,
+                 const CapacityMap &capacity,
+                 const CostMap &cost,
+                 Node s, Node t,
+                 Supply flow_value ) :
+      MinCostFlowImpl( graph, capacity, cost,
+                       s, t, flow_value ) {}
+
+  }; //class MinCostFlow
+
+  ///@}
+
+} //namespace lemon
+
+#endif //LEMON_MIN_COST_FLOW_H
Index: lemon/min_cost_max_flow.h
===================================================================
--- lemon/min_cost_max_flow.h	(revision 2620)
+++ lemon/min_cost_max_flow.h	(revision 2620)
@@ -0,0 +1,253 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MIN_COST_MAX_FLOW_H
+#define LEMON_MIN_COST_MAX_FLOW_H
+
+/// \ingroup min_cost_flow
+///
+/// \file
+/// \brief An efficient algorithm for finding a minimum cost maximum flow.
+
+#include <lemon/preflow.h>
+#include <lemon/network_simplex.h>
+#include <lemon/maps.h>
+
+namespace lemon {
+
+  /// \addtogroup min_cost_flow
+  /// @{
+
+  /// \brief An efficient algorithm for finding a minimum cost
+  /// maximum flow.
+  ///
+  /// \ref MinCostMaxFlow implements an efficient algorithm for
+  /// finding a maximum flow having minimal total cost from a given
+  /// source node to a given target node in a directed graph.
+  ///
+  /// \ref MinCostMaxFlow uses \ref Preflow for finding the maximum
+  /// flow value and \ref NetworkSimplex for finding a minimum cost
+  /// flow of that value.
+  /// According to our benchmark tests \ref Preflow is generally the
+  /// most efficient algorithm for the maximum flow problem and
+  /// \ref NetworkSimplex is the most efficient for the minimum cost
+  /// flow problem in LEMON.
+  ///
+  /// \tparam Graph The directed graph type the algorithm runs on.
+  /// \tparam CapacityMap The type of the capacity (upper bound) map.
+  /// \tparam CostMap The type of the cost (length) map.
+  ///
+  /// \warning
+  /// - Edge capacities and costs should be \e non-negative \e integers.
+  /// - \c CapacityMap::Value must be convertible to \c CostMap::Value.
+  /// - \c CostMap::Value must be signed type.
+  ///
+  /// \author Peter Kovacs
+  template < typename Graph,
+             typename CapacityMap = typename Graph::template EdgeMap<int>,
+             typename CostMap = typename Graph::template EdgeMap<int> >
+  class MinCostMaxFlow
+  {
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename CapacityMap::Value Capacity;
+    typedef typename CostMap::Value Cost;
+    typedef typename Graph::template NodeMap<Cost> SupplyMap;
+
+    typedef Preflow<Graph, CapacityMap> MaxFlowImpl;
+    typedef NetworkSimplex< Graph, CapacityMap, CapacityMap,
+                            CostMap, SupplyMap > MinCostFlowImpl;
+
+  public:
+
+    /// The type of the flow map.
+    typedef typename Graph::template EdgeMap<Capacity> FlowMap;
+    /// The type of the potential map.
+    typedef typename Graph::template NodeMap<Cost> PotentialMap;
+
+  private:
+
+    // The directed graph the algorithm runs on
+    const Graph &_graph;
+    // The capacity map
+    const CapacityMap &_capacity;
+    // The cost map
+    const CostMap &_cost;
+
+    // Edge map of the found flow
+    FlowMap *_flow;
+    bool _local_flow;
+    // Node map of the current potentials
+    PotentialMap *_potential;
+    bool _local_potential;
+
+    // The source node
+    Node _source;
+    // The target node
+    Node _target;
+
+  public:
+
+    /// \brief Constructor.
+    ///
+    /// Constructor.
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    MinCostMaxFlow( const Graph &graph,
+                    const CapacityMap &capacity,
+                    const CostMap &cost,
+                    Node s, Node t ) :
+      _graph(graph), _capacity(capacity), _cost(cost), _flow(0),
+      _local_flow(false), _potential(0), _local_potential(false),
+      _source(s), _target(t) {}
+
+    /// Destructor.
+    ~MinCostMaxFlow() {
+      if (_local_flow) delete _flow;
+      if (_local_potential) delete _potential;
+    }
+
+    /// \brief Set the flow map.
+    ///
+    /// Set the flow map.
+    ///
+    /// \return \c (*this)
+    MinCostMaxFlow& flowMap(FlowMap &map) {
+      if (_local_flow) {
+        delete _flow;
+        _local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Set the potential map.
+    ///
+    /// Set the potential map.
+    ///
+    /// \return \c (*this)
+    MinCostMaxFlow& potentialMap(PotentialMap &map) {
+      if (_local_potential) {
+        delete _potential;
+        _local_potential = false;
+      }
+      _potential = &map;
+      return *this;
+    }
+
+    /// \name Execution control
+
+    /// @{
+
+    /// \brief Run the algorithm.
+    ///
+    /// Run the algorithm.
+    void run() {
+      // Initializing maps
+      if (!_flow) {
+        _flow = new FlowMap(_graph);
+        _local_flow = true;
+      }
+      if (!_potential) {
+        _potential = new PotentialMap(_graph);
+        _local_potential = true;
+      }
+      // Running Preflow
+      MaxFlowImpl preflow(_graph, _capacity, _source, _target);
+      preflow.flowMap(*_flow).runMinCut();
+      // Running NetworkSimplex
+      MinCostFlowImpl mcf( _graph, _capacity, _cost,
+                           _source, _target, preflow.flowValue() );
+      mcf.flowMap(*_flow).potentialMap(*_potential).run();
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The results of the algorithm can be obtained using these
+    /// functions.\n
+    /// \ref lemon::MinCostMaxFlow::run() "run()" must be called before
+    /// using them.
+
+    /// @{
+
+    /// \brief Return a const reference to the edge map storing the
+    /// found flow.
+    ///
+    /// Return a const reference to the edge map storing the found flow.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const FlowMap& flowMap() const {
+      return *_flow;
+    }
+
+    /// \brief Return a const reference to the node map storing the
+    /// found potentials (the dual solution).
+    ///
+    /// Return a const reference to the node map storing the found
+    /// potentials (the dual solution).
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const PotentialMap& potentialMap() const {
+      return *_potential;
+    }
+
+    /// \brief Return the flow on the given edge.
+    ///
+    /// Return the flow on the given edge.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Capacity flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// \brief Return the potential of the given node.
+    ///
+    /// Return the potential of the given node.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost potential(const Node& node) const {
+      return (*_potential)[node];
+    }
+
+    /// \brief Return the total cost of the found flow.
+    ///
+    /// Return the total cost of the found flow. The complexity of the
+    /// function is \f$ O(e) \f$.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost totalCost() const {
+      Cost c = 0;
+      for (EdgeIt e(_graph); e != INVALID; ++e)
+        c += (*_flow)[e] * _cost[e];
+      return c;
+    }
+
+    /// @}
+
+  }; //class MinCostMaxFlow
+
+  ///@}
+
+} //namespace lemon
+
+#endif //LEMON_MIN_COST_MAX_FLOW_H
Index: lemon/min_mean_cycle.h
===================================================================
--- lemon/min_mean_cycle.h	(revision 2620)
+++ lemon/min_mean_cycle.h	(revision 2620)
@@ -0,0 +1,459 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MIN_MEAN_CYCLE_H
+#define LEMON_MIN_MEAN_CYCLE_H
+
+/// \ingroup shortest_path
+///
+/// \file
+/// \brief Howard's algorithm for finding a minimum mean directed cycle.
+
+#include <vector>
+#include <lemon/graph_utils.h>
+#include <lemon/path.h>
+#include <lemon/tolerance.h>
+#include <lemon/topology.h>
+
+namespace lemon {
+
+  /// \addtogroup shortest_path
+  /// @{
+
+  /// \brief Implementation of Howard's algorithm for finding a minimum
+  /// mean directed cycle.
+  ///
+  /// \ref MinMeanCycle implements Howard's algorithm for finding a
+  /// minimum mean directed cycle.
+  ///
+  /// \tparam Graph The directed graph type the algorithm runs on.
+  /// \tparam LengthMap The type of the length (cost) map.
+  ///
+  /// \warning \c LengthMap::Value must be convertible to \c double.
+  ///
+  /// \author Peter Kovacs
+
+  template < typename Graph,
+             typename LengthMap = typename Graph::template EdgeMap<int> >
+  class MinMeanCycle
+  {
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename LengthMap::Value Length;
+    typedef lemon::Path<Graph> Path;
+
+  private:
+
+    // The directed graph the algorithm runs on
+    const Graph &_graph;
+    // The length of the edges
+    const LengthMap &_length;
+
+    // The total length of the found cycle
+    Length _cycle_length;
+    // The number of edges on the found cycle
+    int _cycle_size;
+    // The found cycle
+    Path *_cycle_path;
+
+    bool _local_path;
+    bool _cycle_found;
+    Node _cycle_node;
+
+    typename Graph::template NodeMap<bool> _reached;
+    typename Graph::template NodeMap<double> _dist;
+    typename Graph::template NodeMap<Edge> _policy;
+
+    typename Graph::template NodeMap<int> _component;
+    int _component_num;
+
+    std::vector<Node> _nodes;
+    std::vector<Edge> _edges;
+    Tolerance<double> _tolerance;
+
+  public:
+
+    /// \brief The constructor of the class.
+    ///
+    /// The constructor of the class.
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param length The length (cost) of the edges.
+    MinMeanCycle( const Graph &graph,
+                  const LengthMap &length ) :
+      _graph(graph), _length(length), _cycle_length(0), _cycle_size(-1),
+      _cycle_path(NULL), _local_path(false), _reached(graph),
+      _dist(graph), _policy(graph), _component(graph)
+    {}
+
+    /// The destructor of the class.
+    ~MinMeanCycle() {
+      if (_local_path) delete _cycle_path;
+    }
+
+    /// \brief Sets the \ref Path "path" structure for storing the found
+    /// cycle.
+    ///
+    /// Sets an external \ref Path "path" structure for storing the
+    /// found cycle.
+    ///
+    /// If you don't call this function before calling \ref run() or
+    /// \ref init(), it will allocate a local \ref Path "path"
+    /// structure.
+    /// The destuctor deallocates this automatically allocated map,
+    /// of course.
+    ///
+    /// \note The algorithm calls only the \ref lemon::Path::addBack()
+    /// "addBack()" function of the given \ref Path "path" structure.
+    ///
+    /// \return <tt>(*this)</tt>
+    ///
+    /// \sa cycle()
+    MinMeanCycle& cyclePath(Path &path) {
+      if (_local_path) {
+        delete _cycle_path;
+        _local_path = false;
+      }
+      _cycle_path = &path;
+      return *this;
+    }
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to call the run()
+    /// function.
+    /// \n
+    /// If you only need the minimum mean value, you may call init()
+    /// and findMinMean().
+    /// \n
+    /// If you would like to run the algorithm again (e.g. the
+    /// underlaying graph and/or the edge costs were modified), you may
+    /// not create a new instance of the class, rather call reset(),
+    /// findMinMean(), and findCycle() instead.
+
+    /// @{
+
+    /// \brief Runs the algorithm.
+    ///
+    /// Runs the algorithm.
+    ///
+    /// \return Returns \c true if a directed cycle exists in the graph.
+    ///
+    /// \note Apart from the return value, <tt>mmc.run()</tt> is just a
+    /// shortcut of the following code.
+    /// \code
+    ///   mmc.init();
+    ///   mmc.findMinMean();
+    ///   mmc.findCycle();
+    /// \endcode
+    bool run() {
+      init();
+      return findMinMean() && findCycle();
+    }
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    ///
+    /// \sa reset()
+    void init() {
+      _tolerance.epsilon(1e-6);
+      if (!_cycle_path) {
+        _local_path = true;
+        _cycle_path = new Path;
+      }
+      _cycle_found = false;
+      _component_num = stronglyConnectedComponents(_graph, _component);
+    }
+
+    /// \brief Resets the internal data structures.
+    ///
+    /// Resets the internal data structures so that \ref findMinMean()
+    /// and \ref findCycle() can be called again (e.g. when the
+    /// underlaying graph has been modified).
+    ///
+    /// \sa init()
+    void reset() {
+      if (_cycle_path) _cycle_path->clear();
+      _cycle_found = false;
+      _component_num = stronglyConnectedComponents(_graph, _component);
+    }
+
+    /// \brief Finds the minimum cycle mean length in the graph.
+    ///
+    /// Computes all the required data and finds the minimum cycle mean
+    /// length in the graph.
+    ///
+    /// \return Returns \c true if a directed cycle exists in the graph.
+    ///
+    /// \pre \ref init() must be called before using this function.
+    bool findMinMean() {
+      // Finding the minimum mean cycle in the components
+      for (int comp = 0; comp < _component_num; ++comp) {
+        if (!initCurrentComponent(comp)) continue;
+        while (true) {
+          if (!findPolicyCycles()) break;
+          contractPolicyGraph(comp);
+          if (!computeNodeDistances(comp)) break;
+        }
+      }
+      return _cycle_found;
+    }
+
+    /// \brief Finds a critical (minimum mean) directed cycle.
+    ///
+    /// Finds a critical (minimum mean) directed cycle using the data
+    /// computed in the \ref findMinMean() function.
+    ///
+    /// \return Returns \c true if a directed cycle exists in the graph.
+    ///
+    /// \pre \ref init() and \ref findMinMean() must be called before
+    /// using this function.
+    bool findCycle() {
+      if (!_cycle_found) return false;
+      _cycle_path->addBack(_policy[_cycle_node]);
+      for ( Node v = _cycle_node;
+            (v = _graph.target(_policy[v])) != _cycle_node; ) {
+        _cycle_path->addBack(_policy[v]);
+      }
+      return true;
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the algorithm can be obtained using these
+    /// functions.
+    /// \n The algorithm should be executed before using them.
+
+    /// @{
+
+    /// \brief Returns the total length of the found cycle.
+    ///
+    /// Returns the total length of the found cycle.
+    ///
+    /// \pre \ref run() or \ref findMinMean() must be called before
+    /// using this function.
+    Length cycleLength() const {
+      return _cycle_length;
+    }
+
+    /// \brief Returns the number of edges on the found cycle.
+    ///
+    /// Returns the number of edges on the found cycle.
+    ///
+    /// \pre \ref run() or \ref findMinMean() must be called before
+    /// using this function.
+    int cycleEdgeNum() const {
+      return _cycle_size;
+    }
+
+    /// \brief Returns the mean length of the found cycle.
+    ///
+    /// Returns the mean length of the found cycle.
+    ///
+    /// \pre \ref run() or \ref findMinMean() must be called before
+    /// using this function.
+    ///
+    /// \note <tt>mmc.cycleMean()</tt> is just a shortcut of the
+    /// following code.
+    /// \code
+    ///   return double(mmc.cycleLength()) / mmc.cycleEdgeNum();
+    /// \endcode
+    double cycleMean() const {
+      return double(_cycle_length) / _cycle_size;
+    }
+
+    /// \brief Returns a const reference to the \ref Path "path"
+    /// structure storing the found cycle.
+    ///
+    /// Returns a const reference to the \ref Path "path"
+    /// structure storing the found cycle.
+    ///
+    /// \pre \ref run() or \ref findCycle() must be called before using
+    /// this function.
+    ///
+    /// \sa cyclePath()
+    const Path& cycle() const {
+      return *_cycle_path;
+    }
+
+    ///@}
+
+  private:
+
+    // Initializes the internal data structures for the current strongly
+    // connected component and creating the policy graph.
+    // The policy graph can be represented by the _policy map because
+    // the out degree of every node is 1.
+    bool initCurrentComponent(int comp) {
+      // Finding the nodes of the current component
+      _nodes.clear();
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+        if (_component[n] == comp) _nodes.push_back(n);
+      }
+      if (_nodes.size() <= 1) return false;
+      // Finding the edges of the current component
+      _edges.clear();
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+        if ( _component[_graph.source(e)] == comp &&
+             _component[_graph.target(e)] == comp )
+          _edges.push_back(e);
+      }
+      // Initializing _reached, _dist, _policy maps
+      for (int i = 0; i < int(_nodes.size()); ++i) {
+        _reached[_nodes[i]] = false;
+        _policy[_nodes[i]] = INVALID;
+      }
+      Node u; Edge e;
+      for (int j = 0; j < int(_edges.size()); ++j) {
+        e = _edges[j];
+        u = _graph.source(e);
+        if (!_reached[u] || _length[e] < _dist[u]) {
+          _dist[u] = _length[e];
+          _policy[u] = e;
+          _reached[u] = true;
+        }
+      }
+      return true;
+    }
+
+    // Finds all cycles in the policy graph.
+    // Sets _cycle_found to true if a cycle is found and sets
+    // _cycle_length, _cycle_size, _cycle_node to represent the minimum
+    // mean cycle in the policy graph.
+    bool findPolicyCycles() {
+      typename Graph::template NodeMap<int> level(_graph, -1);
+      bool curr_cycle_found = false;
+      Length clength;
+      int csize;
+      int path_cnt = 0;
+      Node u, v;
+      // Searching for cycles
+      for (int i = 0; i < int(_nodes.size()); ++i) {
+        if (level[_nodes[i]] < 0) {
+          u = _nodes[i];
+          level[u] = path_cnt;
+          while (level[u = _graph.target(_policy[u])] < 0)
+            level[u] = path_cnt;
+          if (level[u] == path_cnt) {
+            // A cycle is found
+            curr_cycle_found = true;
+            clength = _length[_policy[u]];
+            csize = 1;
+            for (v = u; (v = _graph.target(_policy[v])) != u; ) {
+              clength += _length[_policy[v]];
+              ++csize;
+            }
+            if ( !_cycle_found ||
+                 clength * _cycle_size < _cycle_length * csize ) {
+              _cycle_found = true;
+              _cycle_length = clength;
+              _cycle_size = csize;
+              _cycle_node = u;
+            }
+          }
+          ++path_cnt;
+        }
+      }
+      return curr_cycle_found;
+    }
+
+    // Contracts the policy graph to be connected by cutting all cycles
+    // except for the main cycle (i.e. the minimum mean cycle).
+    void contractPolicyGraph(int comp) {
+      // Finding the component of the main cycle using
+      // reverse BFS search
+      typename Graph::template NodeMap<int> found(_graph, false);
+      std::deque<Node> queue;
+      queue.push_back(_cycle_node);
+      found[_cycle_node] = true;
+      Node u, v;
+      while (!queue.empty()) {
+        v = queue.front(); queue.pop_front();
+        for (InEdgeIt e(_graph, v); e != INVALID; ++e) {
+          u = _graph.source(e);
+          if (_component[u] == comp && !found[u] && _policy[u] == e) {
+            found[u] = true;
+            queue.push_back(u);
+          }
+        }
+      }
+      // Connecting all other nodes to this component using
+      // reverse BFS search
+      queue.clear();
+      for (int i = 0; i < int(_nodes.size()); ++i)
+        if (found[_nodes[i]]) queue.push_back(_nodes[i]);
+      int found_cnt = queue.size();
+      while (found_cnt < int(_nodes.size()) && !queue.empty()) {
+        v = queue.front(); queue.pop_front();
+        for (InEdgeIt e(_graph, v); e != INVALID; ++e) {
+          u = _graph.source(e);
+          if (_component[u] == comp && !found[u]) {
+            found[u] = true;
+            ++found_cnt;
+            _policy[u] = e;
+            queue.push_back(u);
+          }
+        }
+      }
+    }
+
+    // Computes node distances in the policy graph and updates the
+    // policy graph if the node distances can be improved.
+    bool computeNodeDistances(int comp) {
+      // Computing node distances using reverse BFS search
+      double cycle_mean = double(_cycle_length) / _cycle_size;
+      typename Graph::template NodeMap<int> found(_graph, false);
+      std::deque<Node> queue;
+      queue.push_back(_cycle_node);
+      found[_cycle_node] = true;
+      _dist[_cycle_node] = 0;
+      Node u, v;
+      while (!queue.empty()) {
+        v = queue.front(); queue.pop_front();
+        for (InEdgeIt e(_graph, v); e != INVALID; ++e) {
+          u = _graph.source(e);
+          if (_component[u] == comp && !found[u] && _policy[u] == e) {
+            found[u] = true;
+            _dist[u] = _dist[v] + _length[e] - cycle_mean;
+            queue.push_back(u);
+          }
+        }
+      }
+      // Improving node distances
+      bool improved = false;
+      for (int j = 0; j < int(_edges.size()); ++j) {
+        Edge e = _edges[j];
+        u = _graph.source(e); v = _graph.target(e);
+        double delta = _dist[v] + _length[e] - cycle_mean;
+        if (_tolerance.less(delta, _dist[u])) {
+          improved = true;
+          _dist[u] = delta;
+          _policy[u] = e;
+        }
+      }
+      return improved;
+    }
+
+  }; //class MinMeanCycle
+
+  ///@}
+
+} //namespace lemon
+
+#endif //LEMON_MIN_MEAN_CYCLE_H
Index: lemon/mip_cplex.cc
===================================================================
--- lemon/mip_cplex.cc	(revision 2553)
+++ lemon/mip_cplex.cc	(revision 2553)
@@ -0,0 +1,137 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\file
+///\brief Implementation of the LEMON-CPLEX mip solver interface.
+
+#include <lemon/mip_cplex.h>
+
+namespace lemon {
+  
+  MipCplex::MipCplex() {
+    //This is unnecessary: setting integrality constraints on
+    //variables will set this, too 
+
+    ///\todo The constant CPXPROB_MIP is
+    ///called CPXPROB_MILP in later versions
+#if CPX_VERSION < 800
+    CPXchgprobtype( env,  lp, CPXPROB_MIP);
+#else
+    CPXchgprobtype( env,  lp, CPXPROB_MILP);
+#endif
+
+  }
+
+  void MipCplex::_colType(int i, MipCplex::ColTypes col_type){
+
+    // Note If a variable is to be changed to binary, a call to CPXchgbds
+    // should also be made to change the bounds to 0 and 1.
+
+    int indices[1];
+    indices[0]=i;
+    char ctype[1];
+    switch (col_type){
+      case INT:
+	ctype[0]=CPX_INTEGER;//'I'
+	break;
+      case REAL:
+	ctype[0]=CPX_CONTINUOUS	;//'C'
+	break;
+    default:;
+        //FIXME problem
+    }
+    CPXchgctype (env, lp, 1, indices, ctype);
+  }
+  
+  MipCplex::ColTypes MipCplex::_colType(int i) const {
+    
+    char ctype[1];
+    CPXgetctype (env, lp, ctype, i, i);
+    switch (ctype[0]){
+
+    case CPX_INTEGER:
+      return INT;
+    case CPX_CONTINUOUS:
+      return REAL;
+    default:
+      return REAL;//Error!
+    }
+
+  }
+  
+  LpCplex::SolveExitStatus MipCplex::_solve(){
+
+    status = CPXmipopt (env, lp);
+    if (status==0)
+      return SOLVED;
+    else
+      return UNSOLVED;
+
+  }
+
+
+  LpCplex::SolutionStatus MipCplex::_getMipStatus() const {
+
+    int stat = CPXgetstat(env, lp);
+
+    //Fortunately, MIP statuses did not change for cplex 8.0
+    switch (stat)
+    {
+      case CPXMIP_OPTIMAL:
+        // Optimal integer solution has been found.
+      case CPXMIP_OPTIMAL_TOL:
+        // Optimal soluton with the tolerance defined by epgap or epagap has 
+        // been found.
+        return OPTIMAL;
+	//This also exists in later issues
+	//    case CPXMIP_UNBOUNDED:
+        //return INFINITE;
+      case CPXMIP_INFEASIBLE:
+        return INFEASIBLE;
+      default:
+        return UNDEFINED;
+    }
+    //Unboundedness not treated well: the following is from cplex 9.0 doc
+    // About Unboundedness
+
+    // The treatment of models that are unbounded involves a few
+    // subtleties. Specifically, a declaration of unboundedness means that
+    // ILOG CPLEX has determined that the model has an unbounded
+    // ray. Given any feasible solution x with objective z, a multiple of
+    // the unbounded ray can be added to x to give a feasible solution
+    // with objective z-1 (or z+1 for maximization models). Thus, if a
+    // feasible solution exists, then the optimal objective is
+    // unbounded. Note that ILOG CPLEX has not necessarily concluded that
+    // a feasible solution exists. Users can call the routine CPXsolninfo
+    // to determine whether ILOG CPLEX has also concluded that the model
+    // has a feasible solution.
+      
+  }  
+
+  MipCplex::Value MipCplex::_getPrimal(int i) const {
+    Value x;
+    CPXgetmipx(env, lp, &x, i, i);
+    return x;
+  }
+  
+  MipCplex::Value MipCplex::_getPrimalValue() const {
+    Value objval;
+    CPXgetmipobjval(env, lp, &objval);
+    return objval;
+  }
+} //END OF NAMESPACE LEMON
Index: lemon/mip_cplex.h
===================================================================
--- lemon/mip_cplex.h	(revision 2553)
+++ lemon/mip_cplex.h	(revision 2553)
@@ -0,0 +1,61 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MIP_CPLEX_H
+#define LEMON_MIP_CPLEX_H
+
+///\file
+///\brief Header of the LEMON-CPLEX mip solver interface.
+///\ingroup lp_group
+
+
+#include <lemon/lp_cplex.h>
+
+namespace lemon {
+
+  /// \brief Interface for the CPLEX MIP solver
+  /// 
+  /// This class implements an interface for the CPLEX MIP solver.
+  ///\ingroup lp_group
+  class MipCplex : public MipSolverBase, public LpCplex{
+    
+  public:
+  
+    typedef MipSolverBase ParentMip;
+    typedef LpCplex ParentLp;
+    
+    MipCplex();
+    //~MipCplex();
+    
+    
+
+    
+  protected:
+  
+    virtual ColTypes _colType(int col) const;
+    virtual void _colType(int col, ColTypes col_type);
+    
+    virtual LpCplex::SolveExitStatus _solve();
+    virtual LpCplex::SolutionStatus _getMipStatus() const;
+    virtual ParentLp::Value _getPrimal(int i) const;
+    virtual ParentLp::Value _getPrimalValue() const;
+  };
+
+} //END OF NAMESPACE LEMON
+
+#endif // END OF LEMON_MIP_CPLEX_H
Index: lemon/mip_glpk.cc
===================================================================
--- lemon/mip_glpk.cc	(revision 2553)
+++ lemon/mip_glpk.cc	(revision 2553)
@@ -0,0 +1,149 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\file
+///\brief Implementation of the LEMON-GLPK mip solver interface.
+
+#include <lemon/mip_glpk.h>
+
+#if GLP_MAJOR_VERSION > 4 || (GLP_MAJOR_VERSION == 4 && GLP_MINOR_VERSION > 15)
+#define LEMON_glp(func) (glp_##func)
+#define LEMON_lpx(func) (lpx_##func)
+
+#define LEMON_GLP(def) (GLP_##def)
+#define LEMON_LPX(def) (LPX_##def)
+
+#else
+
+#define LEMON_glp(func) (lpx_##func)
+#define LEMON_lpx(func) (lpx_##func)
+
+#define LEMON_GLP(def) (LPX_##def)
+#define LEMON_LPX(def) (LPX_##def)
+
+#endif
+
+namespace lemon {
+  
+  MipGlpk::MipGlpk() {
+#if !(GLP_MAJOR_VERSION > 4 || (GLP_MAJOR_VERSION == 4 && GLP_MINOR_VERSION > 15))
+    LEMON_lpx(set_class)(lp,LEMON_GLP(MIP));
+#endif
+  }
+
+  void MipGlpk::_colType(int i, MipGlpk::ColTypes col_type){
+    switch (col_type){
+      case INT:
+	LEMON_glp(set_col_kind)(lp,i,LEMON_GLP(IV));
+	break;
+      case REAL:
+	LEMON_glp(set_col_kind)(lp,i,LEMON_GLP(CV));
+	break;
+    default:;
+        //FIXME problem
+    }
+  }
+  
+  MipGlpk::ColTypes MipGlpk::_colType(int i) const {
+    switch (LEMON_glp(get_col_kind)(lp,i)){
+    case LEMON_GLP(IV):
+      return INT;//Or binary
+    case LEMON_GLP(CV):
+      return REAL;
+    default:
+      return REAL;//Error!
+    }
+    
+  }
+  
+  LpGlpk::SolveExitStatus MipGlpk::_solve() {
+    int result = LEMON_lpx(simplex)(lp);
+
+    // hack: mip does not contain integer variable 
+#if GLP_MAJOR_VERSION == 4 && GLP_MINOR_VERSION == 16
+    int tmp = -1;
+    if (LEMON_glp(get_num_int(lp)) == 0) {
+      tmp = LEMON_lpx(add_cols)(lp, 1);
+      LEMON_glp(set_col_bnds)(lp, tmp, LEMON_GLP(FX), 0.0, 0.0);
+      LEMON_glp(set_col_kind)(lp, tmp, LEMON_GLP(IV));
+    }
+#endif
+
+    if (LEMON_lpx(get_status)(lp)==LEMON_LPX(OPT)) {
+      //Maybe we could try the routine lpx_intopt(lp), a revised
+      //version of lpx_integer
+
+      result = LEMON_lpx(integer)(lp);
+      switch (result){
+      case LEMON_LPX(E_OK):
+	solved = true;
+	break;
+      default:
+	solved = false;
+      }  
+    } else {
+      solved = false;
+    }
+#if GLP_MAJOR_VERSION == 4 && GLP_MINOR_VERSION == 16
+    if (tmp != -1) {
+      int tmpa[2];
+      tmpa[1] = tmp;
+      LEMON_lpx(del_cols)(lp, 1, tmpa);
+    }
+#endif
+    return solved ? SOLVED : UNSOLVED;
+  }
+
+
+  LpGlpk::SolutionStatus MipGlpk::_getMipStatus() const {
+
+    if (LEMON_lpx(get_status)(lp)==LEMON_LPX(OPT)){
+      //Meg kell nezni: ha az LP is infinite, akkor ez is, ha az is
+      //infeasible, akkor ez is, de ez lehet maskepp is infeasible.
+      int stat= LEMON_lpx(mip_status)(lp);
+      
+      switch (stat) {
+      case LEMON_LPX(I_UNDEF)://Undefined (no solve has been run yet)
+	return UNDEFINED;
+      case LEMON_LPX(I_NOFEAS)://There is no feasible integral solution
+	return INFEASIBLE;
+	//     case LEMON_LPX(UNBND)://Unbounded
+	//       return INFINITE;
+      case LEMON_LPX(I_FEAS)://Feasible
+	return FEASIBLE;
+      case LEMON_LPX(I_OPT)://Feasible
+	return OPTIMAL;
+      default:
+	return UNDEFINED; //to avoid gcc warning
+      //FIXME error
+      }
+    }
+    else 
+      return UNDEFINED; //Maybe we could refine this: what does the LP
+			//relaxation look like
+      
+  }  
+
+  MipGlpk::Value MipGlpk::_getPrimal(int i) const {
+    return LEMON_glp(mip_col_val)(lp,i);
+  }
+  
+  MipGlpk::Value MipGlpk::_getPrimalValue() const {
+    return LEMON_glp(mip_obj_val)(lp);
+  }
+} //END OF NAMESPACE LEMON
Index: lemon/mip_glpk.h
===================================================================
--- lemon/mip_glpk.h	(revision 2553)
+++ lemon/mip_glpk.h	(revision 2553)
@@ -0,0 +1,59 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_MIP_GLPK_H
+#define LEMON_MIP_GLPK_H
+
+///\file
+///\brief Header of the LEMON-GLPK mip solver interface.
+///\ingroup lp_group
+
+
+#include <lemon/lp_glpk.h>
+
+namespace lemon {
+  /// \brief Interface for the GLPK MIP solver
+  /// 
+  /// This class implements an interface for the GLPK MIP solver.
+  ///\ingroup lp_group
+  class MipGlpk : public MipSolverBase, public LpGlpk{
+  
+  public:
+  
+    typedef MipSolverBase ParentMip;
+    typedef LpGlpk ParentLp;
+    
+    MipGlpk();
+    //~MipGlpk();
+    
+    
+    
+  protected:
+  
+    virtual ColTypes _colType(int col) const;
+    virtual void _colType(int col, ColTypes col_type);
+    
+    virtual LpGlpk::SolveExitStatus _solve();
+    virtual LpGlpk::SolutionStatus _getMipStatus() const;
+    virtual ParentLp::Value _getPrimal(int i) const;
+    virtual ParentLp::Value _getPrimalValue() const;
+  };
+
+} //END OF NAMESPACE LEMON
+
+#endif // END OF LEMON_MIP_GLPK_H
Index: lemon/nagamochi_ibaraki.h
===================================================================
--- lemon/nagamochi_ibaraki.h	(revision 2595)
+++ lemon/nagamochi_ibaraki.h	(revision 2595)
@@ -0,0 +1,1553 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_NAGAMOCHI_IBARAKI_H
+#define LEMON_NAGAMOCHI_IBARAKI_H
+
+
+/// \ingroup min_cut
+/// \file 
+/// \brief Maximum cardinality search and minimum cut in undirected
+/// graphs.
+
+#include <lemon/list_graph.h>
+#include <lemon/bin_heap.h>
+#include <lemon/bucket_heap.h>
+
+#include <lemon/unionfind.h>
+#include <lemon/topology.h>
+
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+
+#include <functional>
+
+#include <lemon/graph_writer.h>
+#include <lemon/time_measure.h>
+
+namespace lemon {
+
+  namespace _min_cut_bits {
+
+    template <typename CapacityMap>
+    struct HeapSelector {
+      template <typename Value, typename Ref>
+      struct Selector {
+        typedef BinHeap<Value, Ref, std::greater<Value> > Heap;
+      };
+    };
+
+    template <typename CapacityKey>
+    struct HeapSelector<ConstMap<CapacityKey, Const<int, 1> > > {
+      template <typename Value, typename Ref>
+      struct Selector {
+        typedef BucketHeap<Ref, false > Heap;
+      };
+    };
+
+  }
+
+  /// \brief Default traits class of MaxCardinalitySearch class.
+  ///
+  /// Default traits class of MaxCardinalitySearch class.
+  /// \param Graph Graph type.
+  /// \param CapacityMap Type of length map.
+  template <typename _Graph, typename _CapacityMap>
+  struct MaxCardinalitySearchDefaultTraits {
+    /// The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge capacities.
+    ///
+    /// The type of the map that stores the edge capacities.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _CapacityMap CapacityMap;
+
+    /// \brief The type of the capacity of the edges.
+    typedef typename CapacityMap::Value Value;
+
+    /// \brief The cross reference type used by heap.
+    ///
+    /// The cross reference type used by heap.
+    /// Usually it is \c Graph::NodeMap<int>.
+    typedef typename Graph::template NodeMap<int> HeapCrossRef;
+
+    /// \brief Instantiates a HeapCrossRef.
+    ///
+    /// This function instantiates a \ref HeapCrossRef. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// HeapCrossRef.
+    static HeapCrossRef *createHeapCrossRef(const Graph &graph) {
+      return new HeapCrossRef(graph);
+    }
+    
+    /// \brief The heap type used by MaxCardinalitySearch algorithm.
+    ///
+    /// The heap type used by MaxCardinalitySearch algorithm. It should
+    /// maximalize the priorities. The default heap type is
+    /// the \ref BinHeap, but it is specialized when the
+    /// CapacityMap is ConstMap<Graph::Node, Const<int, 1> >
+    /// to BucketHeap.
+    ///
+    /// \sa MaxCardinalitySearch
+    typedef typename _min_cut_bits
+    ::HeapSelector<CapacityMap>
+    ::template Selector<Value, HeapCrossRef>
+    ::Heap Heap;
+
+    /// \brief Instantiates a Heap.
+    ///
+    /// This function instantiates a \ref Heap. 
+    /// \param crossref The cross reference of the heap.
+    static Heap *createHeap(HeapCrossRef& crossref) {
+      return new Heap(crossref);
+    }
+
+    /// \brief The type of the map that stores whether a nodes is processed.
+    ///
+    /// The type of the map that stores whether a nodes is processed.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    /// By default it is a NullMap.
+    typedef NullMap<typename Graph::Node, bool> ProcessedMap;
+
+    /// \brief Instantiates a ProcessedMap.
+    ///
+    /// This function instantiates a \ref ProcessedMap. 
+    /// \param graph is the graph, to which
+    /// we would like to define the \ref ProcessedMap
+#ifdef DOXYGEN
+    static ProcessedMap *createProcessedMap(const Graph &graph)
+#else
+    static ProcessedMap *createProcessedMap(const Graph &)
+#endif
+    {
+      return new ProcessedMap();
+    }
+
+    /// \brief The type of the map that stores the cardinalties of the nodes.
+    /// 
+    /// The type of the map that stores the cardinalities of the nodes.
+    /// It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    typedef typename Graph::template NodeMap<Value> CardinalityMap;
+
+    /// \brief Instantiates a CardinalityMap.
+    ///
+    /// This function instantiates a \ref CardinalityMap. 
+    /// \param graph is the graph, to which we would like to define the \ref 
+    /// CardinalityMap
+    static CardinalityMap *createCardinalityMap(const Graph &graph) {
+      return new CardinalityMap(graph);
+    }
+
+
+  };
+  
+  /// \ingroup search
+  ///
+  /// \brief Maximum Cardinality Search algorithm class.
+  ///
+  /// This class provides an efficient implementation of Maximum Cardinality 
+  /// Search algorithm. The maximum cardinality search chooses first time any 
+  /// node of the graph. Then every time it chooses the node which is connected
+  /// to the processed nodes at most in the sum of capacities on the out 
+  /// edges. If there is a cut in the graph the algorithm should choose
+  /// again any unprocessed node of the graph. Each node cardinality is
+  /// the sum of capacities on the out edges to the nodes which are processed
+  /// before the given node.
+  ///
+  /// The edge capacities are passed to the algorithm using a
+  /// \ref concepts::ReadMap "ReadMap", so it is easy to change it to any 
+  /// kind of capacity.
+  ///
+  /// The type of the capacity is determined by the \ref 
+  /// concepts::ReadMap::Value "Value" of the capacity map.
+  ///
+  /// It is also possible to change the underlying priority heap.
+  ///
+  ///
+  /// \param _Graph The graph type the algorithm runs on. The default value
+  /// is \ref ListGraph. The value of Graph is not used directly by
+  /// the search algorithm, it is only passed to 
+  /// \ref MaxCardinalitySearchDefaultTraits.
+  /// \param _CapacityMap This read-only EdgeMap determines the capacities of 
+  /// the edges. It is read once for each edge, so the map may involve in
+  /// relatively time consuming process to compute the edge capacity if
+  /// it is necessary. The default map type is \ref
+  /// concepts::Graph::EdgeMap "Graph::EdgeMap<int>".  The value
+  /// of CapacityMap is not used directly by search algorithm, it is only 
+  /// passed to \ref MaxCardinalitySearchDefaultTraits.  
+  /// \param _Traits Traits class to set various data types used by the 
+  /// algorithm.  The default traits class is 
+  /// \ref MaxCardinalitySearchDefaultTraits 
+  /// "MaxCardinalitySearchDefaultTraits<_Graph, _CapacityMap>".  
+  /// See \ref MaxCardinalitySearchDefaultTraits 
+  /// for the documentation of a MaxCardinalitySearch traits class.
+  ///
+  /// \author Balazs Dezso
+
+#ifdef DOXYGEN
+  template <typename _Graph, typename _CapacityMap, typename _Traits>
+#else
+  template <typename _Graph = ListUGraph,
+	    typename _CapacityMap = typename _Graph::template EdgeMap<int>,
+	    typename _Traits = 
+            MaxCardinalitySearchDefaultTraits<_Graph, _CapacityMap> >
+#endif
+  class MaxCardinalitySearch {
+  public:
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::MaxCardinalitySearch::UninitializedParameter";
+      }
+    };
+
+    typedef _Traits Traits;
+    ///The type of the underlying graph.
+    typedef typename Traits::Graph Graph;
+    
+    ///The type of the capacity of the edges.
+    typedef typename Traits::CapacityMap::Value Value;
+    ///The type of the map that stores the edge capacities.
+    typedef typename Traits::CapacityMap CapacityMap;
+    ///The type of the map indicating if a node is processed.
+    typedef typename Traits::ProcessedMap ProcessedMap;
+    ///The type of the map that stores the cardinalities of the nodes.
+    typedef typename Traits::CardinalityMap CardinalityMap;
+    ///The cross reference type used for the current heap.
+    typedef typename Traits::HeapCrossRef HeapCrossRef;
+    ///The heap type used by the algorithm. It maximize the priorities.
+    typedef typename Traits::Heap Heap;
+  private:
+    /// Pointer to the underlying graph.
+    const Graph *_graph;
+    /// Pointer to the capacity map
+    const CapacityMap *_capacity;
+    ///Pointer to the map of cardinality.
+    CardinalityMap *_cardinality;
+    ///Indicates if \ref _cardinality is locally allocated (\c true) or not.
+    bool local_cardinality;
+    ///Pointer to the map of processed status of the nodes.
+    ProcessedMap *_processed;
+    ///Indicates if \ref _processed is locally allocated (\c true) or not.
+    bool local_processed;
+    ///Pointer to the heap cross references.
+    HeapCrossRef *_heap_cross_ref;
+    ///Indicates if \ref _heap_cross_ref is locally allocated (\c true) or not.
+    bool local_heap_cross_ref;
+    ///Pointer to the heap.
+    Heap *_heap;
+    ///Indicates if \ref _heap is locally allocated (\c true) or not.
+    bool local_heap;
+
+  public :
+
+    typedef MaxCardinalitySearch Create;
+ 
+    ///\name Named template parameters
+
+    ///@{
+
+    template <class T>
+    struct DefCardinalityMapTraits : public Traits {
+      typedef T CardinalityMap;
+      static CardinalityMap *createCardinalityMap(const Graph &) 
+      {
+	throw UninitializedParameter();
+      }
+    };
+    /// \brief \ref named-templ-param "Named parameter" for setting 
+    /// CardinalityMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting CardinalityMap 
+    /// type
+    template <class T>
+    struct DefCardinalityMap 
+      : public MaxCardinalitySearch<Graph, CapacityMap, 
+                                    DefCardinalityMapTraits<T> > { 
+      typedef MaxCardinalitySearch<Graph, CapacityMap, 
+                                   DefCardinalityMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefProcessedMapTraits : public Traits {
+      typedef T ProcessedMap;
+      static ProcessedMap *createProcessedMap(const Graph &) {
+	throw UninitializedParameter();
+      }
+    };
+    /// \brief \ref named-templ-param "Named parameter" for setting 
+    /// ProcessedMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting ProcessedMap type
+    ///
+    template <class T>
+    struct DefProcessedMap 
+      : public MaxCardinalitySearch<Graph, CapacityMap, 
+                                    DefProcessedMapTraits<T> > { 
+      typedef MaxCardinalitySearch<Graph, CapacityMap, 
+                                   DefProcessedMapTraits<T> > Create;
+    };
+    
+    template <class H, class CR>
+    struct DefHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const Graph &) {
+	throw UninitializedParameter();
+      }
+      static Heap *createHeap(HeapCrossRef &) {
+	throw UninitializedParameter();
+      }
+    };
+    /// \brief \ref named-templ-param "Named parameter" for setting heap 
+    /// and cross reference type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting heap and cross 
+    /// reference type
+    template <class H, class CR = typename Graph::template NodeMap<int> >
+    struct DefHeap
+      : public MaxCardinalitySearch<Graph, CapacityMap, 
+                                    DefHeapTraits<H, CR> > { 
+      typedef MaxCardinalitySearch< Graph, CapacityMap, 
+                                    DefHeapTraits<H, CR> > Create;
+    };
+
+    template <class H, class CR>
+    struct DefStandardHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const Graph &graph) {
+	return new HeapCrossRef(graph);
+      }
+      static Heap *createHeap(HeapCrossRef &crossref) {
+	return new Heap(crossref);
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting heap and 
+    /// cross reference type with automatic allocation
+    ///
+    /// \ref named-templ-param "Named parameter" for setting heap and cross 
+    /// reference type. It can allocate the heap and the cross reference 
+    /// object if the cross reference's constructor waits for the graph as 
+    /// parameter and the heap's constructor waits for the cross reference.
+    template <class H, class CR = typename Graph::template NodeMap<int> >
+    struct DefStandardHeap
+      : public MaxCardinalitySearch<Graph, CapacityMap, 
+                                    DefStandardHeapTraits<H, CR> > { 
+      typedef MaxCardinalitySearch<Graph, CapacityMap, 
+                                   DefStandardHeapTraits<H, CR> > 
+      Create;
+    };
+    
+    ///@}
+
+
+  protected:
+
+    MaxCardinalitySearch() {}
+
+  public:      
+    
+    /// \brief Constructor.
+    ///
+    ///\param graph the graph the algorithm will run on.
+    ///\param capacity the capacity map used by the algorithm.
+    MaxCardinalitySearch(const Graph& graph, const CapacityMap& capacity) :
+      _graph(&graph), _capacity(&capacity),
+      _cardinality(0), local_cardinality(false),
+      _processed(0), local_processed(false),
+      _heap_cross_ref(0), local_heap_cross_ref(false),
+      _heap(0), local_heap(false)
+    { }
+    
+    /// \brief Destructor.
+    ~MaxCardinalitySearch() {
+      if(local_cardinality) delete _cardinality;
+      if(local_processed) delete _processed;
+      if(local_heap_cross_ref) delete _heap_cross_ref;
+      if(local_heap) delete _heap;
+    }
+
+    /// \brief Sets the capacity map.
+    ///
+    /// Sets the capacity map.
+    /// \return <tt> (*this) </tt>
+    MaxCardinalitySearch &capacityMap(const CapacityMap &m) {
+      _capacity = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the cardinalities calculated by the 
+    /// algorithm.
+    ///
+    /// Sets the map storing the cardinalities calculated by the algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return <tt> (*this) </tt>
+    MaxCardinalitySearch &cardinalityMap(CardinalityMap &m) {
+      if(local_cardinality) {
+	delete _cardinality;
+	local_cardinality=false;
+      }
+      _cardinality = &m;
+      return *this;
+    }
+
+    /// \brief Sets the map storing the processed nodes.
+    ///
+    /// Sets the map storing the processed nodes.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return <tt> (*this) </tt>
+    MaxCardinalitySearch &processedMap(ProcessedMap &m) 
+    {
+      if(local_processed) {
+	delete _processed;
+	local_processed=false;
+      }
+      _processed = &m;
+      return *this;
+    }
+
+    /// \brief Sets the heap and the cross reference used by algorithm.
+    ///
+    /// Sets the heap and the cross reference used by algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated map, of course.
+    /// \return <tt> (*this) </tt>
+    MaxCardinalitySearch &heap(Heap& hp, HeapCrossRef &cr) {
+      if(local_heap_cross_ref) {
+	delete _heap_cross_ref;
+	local_heap_cross_ref = false;
+      }
+      _heap_cross_ref = &cr;
+      if(local_heap) {
+	delete _heap;
+	local_heap = false;
+      }
+      _heap = &hp;
+      return *this;
+    }
+
+  private:
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::InEdgeIt InEdgeIt;
+
+    void create_maps() {
+      if(!_cardinality) {
+	local_cardinality = true;
+	_cardinality = Traits::createCardinalityMap(*_graph);
+      }
+      if(!_processed) {
+	local_processed = true;
+	_processed = Traits::createProcessedMap(*_graph);
+      }
+      if (!_heap_cross_ref) {
+	local_heap_cross_ref = true;
+	_heap_cross_ref = Traits::createHeapCrossRef(*_graph);
+      }
+      if (!_heap) {
+	local_heap = true;
+	_heap = Traits::createHeap(*_heap_cross_ref);
+      }
+    }
+    
+    void finalizeNodeData(Node node, Value capacity) {
+      _processed->set(node, true);
+      _cardinality->set(node, capacity);
+    }
+
+  public:
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run(...).
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init(), then you can add several source nodes
+    /// with \ref addSource().
+    /// Finally \ref start() will perform the actual path
+    /// computation.
+
+    ///@{
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    void init() {
+      create_maps();
+      _heap->clear();
+      for (NodeIt it(*_graph) ; it != INVALID ; ++it) {
+	_processed->set(it, false);
+	_heap_cross_ref->set(it, Heap::PRE_HEAP);
+      }
+    }
+    
+    /// \brief Adds a new source node.
+    /// 
+    /// Adds a new source node to the priority heap.
+    ///
+    /// It checks if the node has not yet been added to the heap.
+    void addSource(Node source, Value capacity = 0) {
+      if(_heap->state(source) == Heap::PRE_HEAP) {
+	_heap->push(source, capacity);
+      } 
+    }
+    
+    /// \brief Processes the next node in the priority heap
+    ///
+    /// Processes the next node in the priority heap.
+    ///
+    /// \return The processed node.
+    ///
+    /// \warning The priority heap must not be empty!
+    Node processNextNode() {
+      Node node = _heap->top(); 
+      finalizeNodeData(node, _heap->prio());
+      _heap->pop();
+      
+      for (InEdgeIt it(*_graph, node); it != INVALID; ++it) {
+	Node source = _graph->source(it); 
+	switch (_heap->state(source)) {
+	case Heap::PRE_HEAP:
+	  _heap->push(source, (*_capacity)[it]); 
+	  break;
+	case Heap::IN_HEAP:
+	  _heap->decrease(source, (*_heap)[source] + (*_capacity)[it]); 
+	  break;
+	case Heap::POST_HEAP:
+	  break;
+	}
+      }
+      return node;
+    }
+
+    /// \brief Next node to be processed.
+    ///
+    /// Next node to be processed.
+    ///
+    /// \return The next node to be processed or INVALID if the 
+    /// priority heap is empty.
+    Node nextNode() { 
+      return _heap->empty() ? _heap->top() : INVALID;
+    }
+ 
+    /// \brief Returns \c false if there are nodes
+    /// to be processed in the priority heap
+    ///
+    /// Returns \c false if there are nodes
+    /// to be processed in the priority heap
+    bool emptyQueue() { return _heap->empty(); }
+    /// \brief Returns the number of the nodes to be processed 
+    /// in the priority heap
+    ///
+    /// Returns the number of the nodes to be processed in the priority heap
+    int queueSize() { return _heap->size(); }
+    
+    /// \brief Executes the algorithm.
+    ///
+    /// Executes the algorithm.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    ///
+    /// This method runs the Maximum Cardinality Search algorithm from the 
+    /// source node(s).
+    void start() {
+      while ( !_heap->empty() ) processNextNode();
+    }
+    
+    /// \brief Executes the algorithm until \c dest is reached.
+    ///
+    /// Executes the algorithm until \c dest is reached.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    ///
+    /// This method runs the %MaxCardinalitySearch algorithm from the source 
+    /// nodes.
+    void start(Node dest) {
+      while ( !_heap->empty() && _heap->top()!=dest ) processNextNode();
+      if ( !_heap->empty() ) finalizeNodeData(_heap->top(), _heap->prio());
+    }
+    
+    /// \brief Executes the algorithm until a condition is met.
+    ///
+    /// Executes the algorithm until a condition is met.
+    ///
+    /// \pre init() must be called and at least one node should be added
+    /// with addSource() before using this function.
+    ///
+    /// \param nm must be a bool (or convertible) node map. The algorithm
+    /// will stop when it reaches a node \c v with <tt>nm[v]==true</tt>.
+    template <typename NodeBoolMap>
+    void start(const NodeBoolMap &nm) {
+      while ( !_heap->empty() && !nm[_heap->top()] ) processNextNode();
+      if ( !_heap->empty() ) finalizeNodeData(_heap->top(),_heap->prio());
+    }
+    
+    /// \brief Runs the maximal cardinality search algorithm from node \c s.
+    ///
+    /// This method runs the %MaxCardinalitySearch algorithm from a root 
+    /// node \c s.
+    ///
+    ///\note d.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  d.addSource(s);
+    ///  d.start();
+    ///\endcode
+    void run(Node s) {
+      init();
+      addSource(s);
+      start();
+    }
+
+    /// \brief Runs the maximal cardinality search algorithm for the 
+    /// whole graph.
+    ///
+    /// This method runs the %MaxCardinalitySearch algorithm from all 
+    /// unprocessed node of the graph.
+    ///
+    ///\note d.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  d.init();
+    ///  for (NodeIt it(graph); it != INVALID; ++it) {
+    ///    if (!d.reached(it)) {
+    ///      d.addSource(s);
+    ///      d.start();
+    ///    }
+    ///  }
+    ///\endcode
+    void run() {
+      init();
+      for (NodeIt it(*_graph); it != INVALID; ++it) {
+        if (!reached(it)) {
+          addSource(it);
+          start();
+        }
+      }
+    }
+    
+    ///@}
+
+    /// \name Query Functions
+    /// The result of the maximum cardinality search algorithm can be 
+    /// obtained using these functions.
+    /// \n
+    /// Before the use of these functions, either run() or start() must be 
+    /// called.
+    
+    ///@{
+
+    /// \brief The cardinality of a node.
+    ///
+    /// Returns the cardinality of a node.
+    /// \pre \ref run() must be called before using this function.
+    /// \warning If node \c v in unreachable from the root the return value
+    /// of this funcion is undefined.
+    Value cardinality(Node node) const { return (*_cardinality)[node]; }
+
+    /// \brief The current cardinality of a node.
+    ///
+    /// Returns the current cardinality of a node.
+    /// \pre the given node should be reached but not processed
+    Value currentCardinality(Node node) const { return (*_heap)[node]; }
+
+    /// \brief Returns a reference to the NodeMap of cardinalities.
+    ///
+    /// Returns a reference to the NodeMap of cardinalities. \pre \ref run() 
+    /// must be called before using this function.
+    const CardinalityMap &cardinalityMap() const { return *_cardinality;}
+ 
+    /// \brief Checks if a node is reachable from the root.
+    ///
+    /// Returns \c true if \c v is reachable from the root.
+    /// \warning The source nodes are inditated as unreached.
+    /// \pre \ref run() must be called before using this function.
+    bool reached(Node v) { return (*_heap_cross_ref)[v] != Heap::PRE_HEAP; }
+
+    /// \brief Checks if a node is processed.
+    ///
+    /// Returns \c true if \c v is processed, i.e. the shortest
+    /// path to \c v has already found.
+    /// \pre \ref run() must be called before using this function.
+    bool processed(Node v) { return (*_heap_cross_ref)[v] == Heap::POST_HEAP; }
+    
+    ///@}
+  };
+
+  /// \brief Default traits class of NagamochiIbaraki class.
+  ///
+  /// Default traits class of NagamochiIbaraki class.
+  /// \param Graph Graph type.
+  /// \param CapacityMap Type of length map.
+  template <typename _Graph, typename _CapacityMap>
+  struct NagamochiIbarakiDefaultTraits {
+    /// \brief The type of the capacity of the edges.
+    typedef typename _CapacityMap::Value Value;
+
+    /// The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// The AuxGraph type which is an Graph
+    typedef ListUGraph AuxGraph;
+
+    /// \brief Instantiates a AuxGraph.
+    ///
+    /// This function instantiates a \ref AuxGraph. 
+    static AuxGraph *createAuxGraph() {
+      return new AuxGraph();
+    }
+
+    /// \brief The type of the map that stores the edge capacities.
+    ///
+    /// The type of the map that stores the edge capacities.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _CapacityMap CapacityMap;
+
+    /// \brief Instantiates a CapacityMap.
+    ///
+    /// This function instantiates a \ref CapacityMap.
+#ifdef DOXYGEN
+    static CapacityMap *createCapacityMap(const Graph& graph) 
+#else
+    static CapacityMap *createCapacityMap(const Graph&)
+#endif
+    {
+      throw UninitializedParameter();
+    }
+
+    /// \brief The CutValueMap type
+    ///
+    /// The type of the map that stores the cut value of a node.
+    typedef AuxGraph::NodeMap<Value> AuxCutValueMap;
+
+    /// \brief Instantiates a AuxCutValueMap.
+    ///
+    /// This function instantiates a \ref AuxCutValueMap. 
+    static AuxCutValueMap *createAuxCutValueMap(const AuxGraph& graph) {
+      return new AuxCutValueMap(graph);
+    }
+
+    /// \brief The AuxCapacityMap type
+    ///
+    /// The type of the map that stores the auxiliary edge capacities.
+    typedef AuxGraph::UEdgeMap<Value> AuxCapacityMap;
+
+    /// \brief Instantiates a AuxCapacityMap.
+    ///
+    /// This function instantiates a \ref AuxCapacityMap. 
+    static AuxCapacityMap *createAuxCapacityMap(const AuxGraph& graph) {
+      return new AuxCapacityMap(graph);
+    }
+
+    /// \brief The cross reference type used by heap.
+    ///
+    /// The cross reference type used by heap.
+    /// Usually it is \c Graph::NodeMap<int>.
+    typedef AuxGraph::NodeMap<int> HeapCrossRef;
+
+    /// \brief Instantiates a HeapCrossRef.
+    ///
+    /// This function instantiates a \ref HeapCrossRef. 
+    /// \param graph is the graph, to which we would like to define the 
+    /// HeapCrossRef.
+    static HeapCrossRef *createHeapCrossRef(const AuxGraph &graph) {
+      return new HeapCrossRef(graph);
+    }
+    
+    /// \brief The heap type used by NagamochiIbaraki algorithm.
+    ///
+    /// The heap type used by NagamochiIbaraki algorithm. It should
+    /// maximalize the priorities and the heap's key type is
+    /// the aux graph's node.
+    ///
+    /// \sa BinHeap
+    /// \sa NagamochiIbaraki
+    typedef typename _min_cut_bits
+    ::HeapSelector<CapacityMap>
+    ::template Selector<Value, HeapCrossRef>
+    ::Heap Heap;
+    
+    /// \brief Instantiates a Heap.
+    ///
+    /// This function instantiates a \ref Heap. 
+    /// \param crossref The cross reference of the heap.
+    static Heap *createHeap(HeapCrossRef& crossref) {
+      return new Heap(crossref);
+    }
+
+    /// \brief Map from the AuxGraph's node type to the Graph's node type.
+    ///
+    /// Map from the AuxGraph's node type to the Graph's node type.
+    typedef typename AuxGraph
+    ::template NodeMap<typename Graph::Node> NodeRefMap;
+
+    /// \brief Instantiates a NodeRefMap.
+    ///
+    /// This function instantiates a \ref NodeRefMap. 
+    static NodeRefMap *createNodeRefMap(const AuxGraph& graph) {
+      return new NodeRefMap(graph);
+    }
+
+    /// \brief Map from the Graph's node type to the Graph's node type.
+    ///
+    /// Map from the Graph's node type to the Graph's node type.
+    typedef typename Graph
+    ::template NodeMap<typename Graph::Node> ListRefMap;
+
+    /// \brief Instantiates a ListRefMap.
+    ///
+    /// This function instantiates a \ref ListRefMap. 
+    static ListRefMap *createListRefMap(const Graph& graph) {
+      return new ListRefMap(graph);
+    }
+    
+
+  };
+
+  /// \ingroup min_cut
+  ///
+  /// \brief Calculates the minimum cut in an undirected graph.
+  ///
+  /// Calculates the minimum cut in an undirected graph with the
+  /// Nagamochi-Ibaraki algorithm. The algorithm separates the graph's
+  /// nodes into two partitions with the minimum sum of edge capacities
+  /// between the two partitions. The algorithm can be used to test
+  /// the network reliability specifically to test how many links have
+  /// to be destroyed in the network to split it at least two
+  /// distinict subnetwork.
+  ///
+  /// The complexity of the algorithm is \f$ O(ne\log(n)) \f$ but with
+  /// Fibonacci heap it can be decreased to \f$ O(ne+n^2\log(n)) \f$.
+  /// When unit capacity minimum cut is computed then it uses
+  /// BucketHeap which results \f$ O(ne) \f$ time complexity.
+  ///
+  /// \warning The value type of the capacity map should be able to hold
+  /// any cut value of the graph, otherwise the result can overflow.
+#ifdef DOXYGEN
+  template <typename _Graph, typename _CapacityMap, typename _Traits>
+#else
+  template <typename _Graph = ListUGraph, 
+	    typename _CapacityMap = typename _Graph::template UEdgeMap<int>, 
+	    typename _Traits 
+            = NagamochiIbarakiDefaultTraits<_Graph, _CapacityMap> >
+#endif
+  class NagamochiIbaraki {
+  public:
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::NagamochiIbaraki::UninitializedParameter";
+      }
+    };
+
+
+  private:
+
+    typedef _Traits Traits;
+    /// The type of the underlying graph.
+    typedef typename Traits::Graph Graph;
+    
+    /// The type of the capacity of the edges.
+    typedef typename Traits::CapacityMap::Value Value;
+    /// The type of the map that stores the edge capacities.
+    typedef typename Traits::CapacityMap CapacityMap;
+    /// The type of the aux graph
+    typedef typename Traits::AuxGraph AuxGraph;
+    /// The type of the aux capacity map
+    typedef typename Traits::AuxCapacityMap AuxCapacityMap;
+    /// The type of the aux cut value map
+    typedef typename Traits::AuxCutValueMap AuxCutValueMap;
+    /// The cross reference type used for the current heap.
+    typedef typename Traits::HeapCrossRef HeapCrossRef;
+    /// The heap type used by the max cardinality algorithm.
+    typedef typename Traits::Heap Heap;
+    /// The node refrefernces between the original and aux graph type.
+    typedef typename Traits::NodeRefMap NodeRefMap;
+    /// The list node refrefernces in the original graph type.
+    typedef typename Traits::ListRefMap ListRefMap;
+
+  public:
+
+    ///\name Named template parameters
+
+    ///@{
+
+    struct DefUnitCapacityTraits : public Traits {
+      typedef ConstMap<typename Graph::UEdge, Const<int, 1> > CapacityMap;
+      static CapacityMap *createCapacityMap(const Graph&) {
+	return new CapacityMap();
+      }
+    };
+    /// \brief \ref named-templ-param "Named parameter" for setting  
+    /// the capacity type to constMap<UEdge, int, 1>()
+    ///
+    /// \ref named-templ-param "Named parameter" for setting 
+    /// the capacity type to constMap<UEdge, int, 1>()
+    struct DefUnitCapacity
+      : public NagamochiIbaraki<Graph, CapacityMap, 
+                                DefUnitCapacityTraits> { 
+      typedef NagamochiIbaraki<Graph, CapacityMap, 
+                               DefUnitCapacityTraits> Create;
+    };
+
+
+    template <class H, class CR>
+    struct DefHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const AuxGraph &) {
+	throw UninitializedParameter();
+      }
+      static Heap *createHeap(HeapCrossRef &) {
+	throw UninitializedParameter();
+      }
+    };
+    /// \brief \ref named-templ-param "Named parameter" for setting heap 
+    /// and cross reference type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting heap and cross 
+    /// reference type
+    template <class H, class CR = typename Graph::template NodeMap<int> >
+    struct DefHeap
+      : public NagamochiIbaraki<Graph, CapacityMap, 
+                                DefHeapTraits<H, CR> > { 
+      typedef NagamochiIbaraki< Graph, CapacityMap, 
+                                DefHeapTraits<H, CR> > Create;
+    };
+
+    template <class H, class CR>
+    struct DefStandardHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const AuxGraph &graph) {
+	return new HeapCrossRef(graph);
+      }
+      static Heap *createHeap(HeapCrossRef &crossref) {
+	return new Heap(crossref);
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting heap and 
+    /// cross reference type with automatic allocation
+    ///
+    /// \ref named-templ-param "Named parameter" for setting heap and cross 
+    /// reference type. It can allocate the heap and the cross reference 
+    /// object if the cross reference's constructor waits for the graph as 
+    /// parameter and the heap's constructor waits for the cross reference.
+    template <class H, class CR = typename Graph::template NodeMap<int> >
+    struct DefStandardHeap
+      : public NagamochiIbaraki<Graph, CapacityMap, 
+                                DefStandardHeapTraits<H, CR> > { 
+      typedef NagamochiIbaraki<Graph, CapacityMap, 
+                               DefStandardHeapTraits<H, CR> > 
+      Create;
+    };
+
+    ///@}
+
+
+  private:
+    /// Pointer to the underlying graph.
+    const Graph *_graph;
+    /// Pointer to the capacity map
+    const CapacityMap *_capacity;
+    /// \brief Indicates if \ref _capacity is locally allocated 
+    /// (\c true) or not.
+    bool local_capacity;
+
+    /// Pointer to the aux graph.
+    AuxGraph *_aux_graph;
+    /// \brief Indicates if \ref _aux_graph is locally allocated 
+    /// (\c true) or not.
+    bool local_aux_graph;
+    /// Pointer to the aux capacity map
+    AuxCapacityMap *_aux_capacity;
+    /// \brief Indicates if \ref _aux_capacity is locally allocated 
+    /// (\c true) or not.
+    bool local_aux_capacity;
+    /// Pointer to the aux cut value map
+    AuxCutValueMap *_aux_cut_value;
+    /// \brief Indicates if \ref _aux_cut_value is locally allocated 
+    /// (\c true) or not.
+    bool local_aux_cut_value;
+    /// Pointer to the heap cross references.
+    HeapCrossRef *_heap_cross_ref;
+    /// \brief Indicates if \ref _heap_cross_ref is locally allocated 
+    /// (\c true) or not.
+    bool local_heap_cross_ref;
+    /// Pointer to the heap.
+    Heap *_heap;
+    /// Indicates if \ref _heap is locally allocated (\c true) or not.
+    bool local_heap;
+
+    /// The min cut value.
+    Value _min_cut;
+    /// The number of the nodes of the aux graph.
+    int _node_num;
+    /// The first and last node of the min cut in the next list.
+    std::vector<typename Graph::Node> _cut;
+
+    /// \brief The first and last element in the list associated
+    /// to the aux graph node.
+    NodeRefMap *_first, *_last;
+    /// \brief The next node in the node lists.
+    ListRefMap *_next;
+    
+    void createStructures() {
+      if (!_capacity) {
+        local_capacity = true;
+        _capacity = Traits::createCapacityMap(*_graph);
+      }
+      if(!_aux_graph) {
+	local_aux_graph = true;
+	_aux_graph = Traits::createAuxGraph();
+      }
+      if(!_aux_capacity) {
+	local_aux_capacity = true;
+	_aux_capacity = Traits::createAuxCapacityMap(*_aux_graph);
+      }
+      if(!_aux_cut_value) {
+	local_aux_cut_value = true;
+	_aux_cut_value = Traits::createAuxCutValueMap(*_aux_graph);
+      }
+
+      _first = Traits::createNodeRefMap(*_aux_graph);
+      _last = Traits::createNodeRefMap(*_aux_graph);
+
+      _next = Traits::createListRefMap(*_graph);
+
+      if (!_heap_cross_ref) {
+	local_heap_cross_ref = true;
+	_heap_cross_ref = Traits::createHeapCrossRef(*_aux_graph);
+      }
+      if (!_heap) {
+	local_heap = true;
+	_heap = Traits::createHeap(*_heap_cross_ref);
+      }
+    }
+
+    void createAuxGraph() {
+      typename Graph::template NodeMap<typename AuxGraph::Node> ref(*_graph);
+
+      for (typename Graph::NodeIt n(*_graph); n != INVALID; ++n) {
+        _next->set(n, INVALID);
+        typename AuxGraph::Node node = _aux_graph->addNode();
+        _first->set(node, n);
+        _last->set(node, n);
+        ref.set(n, node);
+      }
+
+      typename AuxGraph::template NodeMap<typename AuxGraph::UEdge> 
+      edges(*_aux_graph, INVALID);
+
+      for (typename Graph::NodeIt n(*_graph); n != INVALID; ++n) {
+        for (typename Graph::IncEdgeIt e(*_graph, n); e != INVALID; ++e) {
+          typename Graph::Node tn = _graph->runningNode(e);
+          if (n < tn || n == tn) continue;
+          if (edges[ref[tn]] != INVALID) {
+            Value value = 
+              (*_aux_capacity)[edges[ref[tn]]] + (*_capacity)[e];
+            _aux_capacity->set(edges[ref[tn]], value);
+          } else {
+            edges.set(ref[tn], _aux_graph->addEdge(ref[n], ref[tn]));
+            Value value = (*_capacity)[e];
+            _aux_capacity->set(edges[ref[tn]], value);            
+          }
+        }
+        for (typename Graph::IncEdgeIt e(*_graph, n); e != INVALID; ++e) {
+          typename Graph::Node tn = _graph->runningNode(e);
+          edges.set(ref[tn], INVALID);
+        }
+      }
+
+      _cut.resize(1, INVALID);
+      _min_cut = std::numeric_limits<Value>::max();
+      for (typename AuxGraph::NodeIt n(*_aux_graph); n != INVALID; ++n) {
+        Value value = 0;
+        for (typename AuxGraph::IncEdgeIt e(*_aux_graph, n); 
+             e != INVALID; ++e) {
+          value += (*_aux_capacity)[e];
+        }
+        if (_min_cut > value) {
+          _min_cut = value;
+          _cut[0] = (*_first)[n];
+        } 
+        (*_aux_cut_value)[n] = value;
+      }
+    }
+    
+
+  public :
+
+    typedef NagamochiIbaraki Create;
+
+
+    /// \brief Constructor.
+    ///
+    ///\param graph the graph the algorithm will run on.
+    ///\param capacity the capacity map used by the algorithm.
+    NagamochiIbaraki(const Graph& graph, const CapacityMap& capacity) 
+      : _graph(&graph), 
+        _capacity(&capacity), local_capacity(false),
+        _aux_graph(0), local_aux_graph(false),
+        _aux_capacity(0), local_aux_capacity(false),
+        _aux_cut_value(0), local_aux_cut_value(false),
+        _heap_cross_ref(0), local_heap_cross_ref(false),
+        _heap(0), local_heap(false),
+        _first(0), _last(0), _next(0) {}
+
+    /// \brief Constructor.
+    ///
+    /// This constructor can be used only when the Traits class
+    /// defines how can we instantiate a local capacity map.
+    /// If the DefUnitCapacity used the algorithm automatically
+    /// construct the capacity map.
+    ///
+    ///\param graph the graph the algorithm will run on.
+    NagamochiIbaraki(const Graph& graph) 
+      : _graph(&graph), 
+        _capacity(0), local_capacity(false),
+        _aux_graph(0), local_aux_graph(false),
+        _aux_capacity(0), local_aux_capacity(false),
+        _aux_cut_value(0), local_aux_cut_value(false),
+        _heap_cross_ref(0), local_heap_cross_ref(false),
+        _heap(0), local_heap(false),
+        _first(0), _last(0), _next(0) {}
+
+    /// \brief Destructor.
+    ///
+    /// Destructor.
+    ~NagamochiIbaraki() {
+      if (local_heap) delete _heap;
+      if (local_heap_cross_ref) delete _heap_cross_ref;
+      if (_first) delete _first;
+      if (_last) delete _last;
+      if (_next) delete _next;
+      if (local_aux_capacity) delete _aux_capacity;
+      if (local_aux_cut_value) delete _aux_cut_value;
+      if (local_aux_graph) delete _aux_graph;
+      if (local_capacity) delete _capacity;
+    }
+
+    /// \brief Sets the heap and the cross reference used by algorithm.
+    ///
+    /// Sets the heap and the cross reference used by algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated heap and cross reference, of course.
+    /// \return <tt> (*this) </tt>
+    NagamochiIbaraki &heap(Heap& hp, HeapCrossRef &cr)
+    {
+      if (local_heap_cross_ref) {
+	delete _heap_cross_ref;
+	local_heap_cross_ref=false;
+      }
+      _heap_cross_ref = &cr;
+      if (local_heap) {
+	delete _heap;
+	local_heap=false;
+      }
+      _heap = &hp;
+      return *this;
+    }
+
+    /// \brief Sets the aux graph.
+    ///
+    /// Sets the aux graph used by algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated graph, of course.
+    /// \return <tt> (*this) </tt>
+    NagamochiIbaraki &auxGraph(AuxGraph& aux_graph)
+    {
+      if(local_aux_graph) {
+	delete _aux_graph;
+	local_aux_graph=false;
+      }
+      _aux_graph = &aux_graph;
+      return *this;
+    }
+
+    /// \brief Sets the aux capacity map.
+    ///
+    /// Sets the aux capacity map used by algorithm.
+    /// If you don't use this function before calling \ref run(),
+    /// it will allocate one. The destuctor deallocates this
+    /// automatically allocated graph, of course.
+    /// \return <tt> (*this) </tt>
+    NagamochiIbaraki &auxCapacityMap(AuxCapacityMap& aux_capacity_map)
+    {
+      if(local_aux_capacity) {
+	delete _aux_capacity;
+	local_aux_capacity=false;
+      }
+      _aux_capacity = &aux_capacity_map;
+      return *this;
+    }
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use
+    /// one of the member functions called \c run().
+    /// \n
+    /// If you need more control on the execution,
+    /// first you must call \ref init() and then call the start()
+    /// or proper times the processNextPhase() member functions.
+
+    ///@{
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    void init() {
+      _node_num = countNodes(*_graph);
+      createStructures();
+      createAuxGraph();
+    }
+
+  private:
+
+    struct EdgeInfo {
+      typename AuxGraph::Node source, target;
+      Value capacity;
+    };
+    
+    struct EdgeInfoLess {
+      bool operator()(const EdgeInfo& left, const EdgeInfo& right) const {
+        return (left.source < right.source) || 
+          (left.source == right.source && left.target < right.target);
+      }
+    };
+
+  public:
+
+
+    /// \brief Processes the next phase
+    ///
+    /// Processes the next phase in the algorithm. The function should
+    /// be called at most countNodes(graph) - 1 times to get surely
+    /// the min cut in the graph.
+    ///
+    ///\return %True when the algorithm finished.
+    bool processNextPhase() {
+      if (_node_num <= 1) return true;
+
+      typedef typename AuxGraph::Node Node;
+      typedef typename AuxGraph::NodeIt NodeIt;
+      typedef typename AuxGraph::UEdge UEdge;
+      typedef typename AuxGraph::UEdgeIt UEdgeIt;
+      typedef typename AuxGraph::IncEdgeIt IncEdgeIt;
+      
+      typename AuxGraph::template UEdgeMap<Value> _edge_cut(*_aux_graph);
+
+
+      for (NodeIt n(*_aux_graph); n != INVALID; ++n) {
+        _heap_cross_ref->set(n, Heap::PRE_HEAP);
+      }
+
+      std::vector<Node> nodes;
+      nodes.reserve(_node_num);
+      int sep = 0;
+
+      Value alpha = 0;
+      Value emc = std::numeric_limits<Value>::max();
+
+      _heap->push(typename AuxGraph::NodeIt(*_aux_graph), 0);
+      while (!_heap->empty()) {
+        Node node = _heap->top();
+        Value value = _heap->prio();
+        
+        _heap->pop();
+        for (typename AuxGraph::IncEdgeIt e(*_aux_graph, node); 
+             e != INVALID; ++e) {
+          Node tn = _aux_graph->runningNode(e);
+          switch (_heap->state(tn)) {
+          case Heap::PRE_HEAP:
+            _heap->push(tn, (*_aux_capacity)[e]);
+            _edge_cut[e] = (*_heap)[tn];
+            break;
+          case Heap::IN_HEAP:
+            _heap->decrease(tn, (*_aux_capacity)[e] + (*_heap)[tn]);
+            _edge_cut[e] = (*_heap)[tn];
+            break;
+          case Heap::POST_HEAP:
+            break;
+          }
+        }
+
+        alpha += (*_aux_cut_value)[node];
+        alpha -= 2 * value;
+
+        nodes.push_back(node);
+        if (!_heap->empty()) {
+          if (alpha < emc) {
+            emc = alpha;
+            sep = nodes.size();
+          }
+        }
+      }
+
+      if (int(nodes.size()) < _node_num) {
+        _cut.clear();
+        for (int i = 0; i < int(nodes.size()); ++i) {
+          typename Graph::Node n = (*_first)[nodes[i]];
+          while (n != INVALID) {
+            _cut.push_back(n);
+            n = (*_next)[n];
+          }
+        }
+	_aux_graph->clear();
+        _node_num = 1;
+        _min_cut = 0;
+        return true;
+      }
+
+      if (emc < _min_cut) {
+        _cut.clear();
+        for (int i = 0; i < sep; ++i) {
+          typename Graph::Node n = (*_first)[nodes[i]];
+          while (n != INVALID) {
+            _cut.push_back(n);
+            n = (*_next)[n];
+          }
+        }
+        _min_cut = emc;
+      }
+
+      typedef typename AuxGraph::template NodeMap<int> UfeCr;
+      UfeCr ufecr(*_aux_graph);
+      typedef UnionFindEnum<UfeCr> Ufe; 
+      Ufe ufe(ufecr);
+
+      for (typename AuxGraph::NodeIt n(*_aux_graph); n != INVALID; ++n) {
+        ufe.insert(n);
+      }
+
+      for (typename AuxGraph::UEdgeIt e(*_aux_graph); e != INVALID; ++e) {
+        if (_edge_cut[e] >= emc) {
+          ufe.join(_aux_graph->source(e), _aux_graph->target(e));
+        }
+      }
+
+      typedef typename Ufe::ClassIt UfeCIt;
+      if (ufe.size(UfeCIt(ufe)) == _node_num) {
+        _aux_graph->clear();
+        _node_num = 1;
+        return true;
+      }
+      
+      std::vector<typename AuxGraph::Node> remnodes;
+
+      typename AuxGraph::template NodeMap<UEdge> edges(*_aux_graph, INVALID);
+      for (typename Ufe::ClassIt c(ufe); c != INVALID; ++c) {
+        if (ufe.size(c) == 1) continue;
+	Node cn = ufe.item(c);
+        for (typename Ufe::ItemIt r(ufe, c); r != INVALID; ++r) {
+          if (static_cast<Node>(r) == static_cast<Node>(cn)) continue;
+          _next->set((*_last)[cn], (*_first)[r]);
+          _last->set(cn, (*_last)[r]);
+          remnodes.push_back(r);
+          --_node_num;
+        }
+      }
+
+      std::vector<EdgeInfo> addedges;
+      std::vector<UEdge> remedges;
+
+      for (typename AuxGraph::UEdgeIt e(*_aux_graph);
+           e != INVALID; ++e) {
+	int sc = ufe.find(_aux_graph->source(e));
+	int tc = ufe.find(_aux_graph->target(e));
+        if ((ufe.size(sc) == 1 && ufe.size(tc) == 1)) {
+          continue;
+        }
+        if (sc == tc) {
+          remedges.push_back(e);
+          continue;
+        }
+        Node sn = ufe.item(sc);
+        Node tn = ufe.item(tc);
+
+        EdgeInfo info;
+        if (sn < tn) {
+          info.source = sn;
+          info.target = tn;
+        } else {
+          info.source = tn;
+          info.target = sn;
+        }
+        info.capacity = (*_aux_capacity)[e];
+        addedges.push_back(info);
+        remedges.push_back(e);
+      }
+
+      for (int i = 0; i < int(remedges.size()); ++i) {
+        _aux_graph->erase(remedges[i]);
+      }
+
+      sort(addedges.begin(), addedges.end(), EdgeInfoLess());
+
+      {
+        int i = 0;
+        while (i < int(addedges.size())) {
+          Node sn = addedges[i].source;
+          Node tn = addedges[i].target;
+          Value ec = addedges[i].capacity;
+          ++i;
+          while (i < int(addedges.size()) && 
+                 sn == addedges[i].source && tn == addedges[i].target) {
+            ec += addedges[i].capacity;
+            ++i;
+          }
+          typename AuxGraph::UEdge ne = _aux_graph->addEdge(sn, tn);
+          (*_aux_capacity)[ne] = ec;
+        }
+      }
+
+      for (typename Ufe::ClassIt c(ufe); c != INVALID; ++c) {
+        if (ufe.size(c) == 1) continue;
+	Node cn = ufe.item(c);
+        Value cutvalue = 0;
+        for (typename AuxGraph::IncEdgeIt e(*_aux_graph, cn);
+             e != INVALID; ++e) {
+          cutvalue += (*_aux_capacity)[e];
+        }
+        
+        (*_aux_cut_value)[cn] = cutvalue;
+        
+      }
+
+      for (int i = 0; i < int(remnodes.size()); ++i) {
+        _aux_graph->erase(remnodes[i]);
+      }
+
+      return _node_num == 1;
+    }
+
+    /// \brief Executes the algorithm.
+    ///
+    /// Executes the algorithm.
+    ///
+    /// \pre init() must be called
+    void start() {
+      while (!processNextPhase());
+    }
+
+
+    /// \brief Runs %NagamochiIbaraki algorithm.
+    ///
+    /// This method runs the %Min cut algorithm
+    ///
+    /// \note mc.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  mc.init();
+    ///  mc.start();
+    ///\endcode
+    void run() {
+      init();
+      start();
+    }
+
+    ///@}
+
+    /// \name Query Functions 
+    ///
+    /// The result of the %NagamochiIbaraki
+    /// algorithm can be obtained using these functions.\n 
+    /// Before the use of these functions, either run() or start()
+    /// must be called.
+    
+    ///@{
+
+    /// \brief Returns the min cut value.
+    ///
+    /// Returns the min cut value if the algorithm finished.
+    /// After the first processNextPhase() it is a value of a
+    /// valid cut in the graph.
+    Value minCut() const {
+      return _min_cut;
+    }
+
+    /// \brief Returns a min cut in a NodeMap.
+    ///
+    /// It sets the nodes of one of the two partitions to true in
+    /// the given BoolNodeMap. The map contains a valid cut if the
+    /// map have been set false previously. 
+    template <typename NodeMap>
+    Value quickMinCut(NodeMap& nodeMap) const { 
+      for (int i = 0; i < int(_cut.size()); ++i) {
+        nodeMap.set(_cut[i], true);
+      }
+      return minCut();
+    }
+
+    /// \brief Returns a min cut in a NodeMap.
+    ///
+    /// It sets the nodes of one of the two partitions to true and
+    /// the other partition to false. The function first set all of the
+    /// nodes to false and after it call the quickMinCut() member.
+    template <typename NodeMap>
+    Value minCut(NodeMap& nodeMap) const { 
+      for (typename Graph::NodeIt it(*_graph); it != INVALID; ++it) {
+        nodeMap.set(it, false);      
+      }
+      quickMinCut(nodeMap);
+      return minCut();
+    }
+
+    /// \brief Returns a min cut in an EdgeMap.
+    ///
+    /// If an undirected edge is in a min cut then it will be
+    /// set to true and the others will be set to false in the given map.
+    template <typename EdgeMap>
+    Value cutEdges(EdgeMap& edgeMap) const {
+      typename Graph::template NodeMap<bool> cut(*_graph, false);
+      quickMinCut(cut);
+      for (typename Graph::EdgeIt it(*_graph); it != INVALID; ++it) {
+        edgeMap.set(it, cut[_graph->source(it)] ^ cut[_graph->target(it)]);
+      }
+      return minCut();
+    }
+
+    ///@}
+
+  private:
+
+
+  };
+}
+
+#endif
Index: lemon/nauty_reader.h
===================================================================
--- lemon/nauty_reader.h	(revision 2610)
+++ lemon/nauty_reader.h	(revision 2610)
@@ -0,0 +1,122 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_NAUTY_READER_H
+#define LEMON_NAUTY_READER_H
+
+#include <vector>
+#include <iostream>
+#include <string>
+
+
+/// \ingroup io_group
+///
+/// @defgroup nauty_group NAUTY format
+///
+/// \brief Read \e Nauty format
+///
+/// Tool to read graphs from \e Nauty format data
+
+/// \ingroup nauty_group
+/// \file
+/// \brief Nauty file reader.
+namespace lemon {
+
+  /// \ingroup nauty_group
+  ///
+  /// \brief Nauty file reader
+  ///
+  /// The \e geng program is in the \e gtools suite of the nauty
+  /// package. This tool can generate all non-isomorphic undirected
+  /// graphs with given node number from several classes (for example,
+  /// general, connected, biconnected, triangle-free, 4-cycle-free,
+  /// bipartite and graphs with given edge number and degree
+  /// constraints). This function reads a \e nauty \e graph6 \e format
+  /// line from the given stream and builds it in the given graph.
+  ///
+  /// The site of nauty package: http://cs.anu.edu.au/~bdm/nauty/
+  ///
+  /// For example, the number of all non-isomorphic connected graphs
+  /// can be computed with next code:
+  ///\code
+  /// int num = 0;
+  /// SmartUGraph ugraph;
+  /// while(readNauty(std::cin, ugraph)) {
+  ///   PlanarityChecking<SmartUGraph> pc(ugraph);
+  ///   if (pc.run()) ++num;
+  /// }
+  /// std::cout << "Number of planar graphs: " << num << std::endl;
+  ///\endcode
+  ///
+  /// The nauty files are quite huge, therefore instead of the direct
+  /// file generation the pipelining is recommended. The execution of
+  /// this program:
+  ///\code 
+  /// ./geng -c 10 | ./num_of_pg 
+  ///\endcode
+  template <typename UGraph>
+  std::istream& readNauty(std::istream& is, UGraph& ugraph) {
+    ugraph.clear();
+
+    std::string line;
+    if (getline(is, line)) {
+      int index = 0;
+    
+      int n;
+
+      if (line[index] == '>') {
+	index += 10; 
+      }
+
+      char c = line[index++]; c -= 63;
+      if (c != 63) {
+	n = int(c);
+      } else {
+	c = line[index++]; c -= 63;
+	n = (int(c) << 12);
+	c = line[index++]; c -= 63;
+	n |= (int(c) << 6);
+	c = line[index++]; c -= 63;
+	n |= int(c);      
+      }
+
+      std::vector<typename UGraph::Node> nodes;
+      for (int i = 0; i < n; ++i) {
+	nodes.push_back(ugraph.addNode());
+      }
+
+      int bit = -1;
+      for (int j = 0; j < n; ++j) {
+	for (int i = 0; i < j; ++i) {
+	  if (bit == -1) {
+	    c = line[index++]; c -= 63;
+	    bit = 5;
+	  }
+	  bool b = (c & (1 << (bit--))) != 0;
+
+	  if (b) {
+	    ugraph.addEdge(nodes[i], nodes[j]);
+	  }
+	}
+      }
+    }
+    return is;
+  }
+}
+
+#endif
Index: lemon/network_simplex.h
===================================================================
--- lemon/network_simplex.h	(revision 2638)
+++ lemon/network_simplex.h	(revision 2638)
@@ -0,0 +1,1275 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_NETWORK_SIMPLEX_H
+#define LEMON_NETWORK_SIMPLEX_H
+
+/// \ingroup min_cost_flow
+///
+/// \file
+/// \brief Network simplex algorithm for finding a minimum cost flow.
+
+#include <vector>
+#include <limits>
+#include <algorithm>
+
+#include <lemon/graph_utils.h>
+#include <lemon/math.h>
+
+namespace lemon {
+
+  /// \addtogroup min_cost_flow
+  /// @{
+
+  /// \brief Implementation of the primal network simplex algorithm
+  /// for finding a minimum cost flow.
+  ///
+  /// \ref NetworkSimplex implements the primal network simplex algorithm
+  /// for finding a minimum cost flow.
+  ///
+  /// \tparam Graph The directed graph type the algorithm runs on.
+  /// \tparam LowerMap The type of the lower bound map.
+  /// \tparam CapacityMap The type of the capacity (upper bound) map.
+  /// \tparam CostMap The type of the cost (length) map.
+  /// \tparam SupplyMap The type of the supply map.
+  ///
+  /// \warning
+  /// - Edge capacities and costs should be \e non-negative \e integers.
+  /// - Supply values should be \e signed \e integers.
+  /// - The value types of the maps should be convertible to each other.
+  /// - \c CostMap::Value must be signed type.
+  ///
+  /// \note \ref NetworkSimplex provides five different pivot rule
+  /// implementations that significantly affect the efficiency of the
+  /// algorithm.
+  /// By default "Block Search" pivot rule is used, which proved to be
+  /// by far the most efficient according to our benchmark tests.
+  /// However another pivot rule can be selected using \ref run()
+  /// function with the proper parameter.
+  ///
+  /// \author Peter Kovacs
+  template < typename Graph,
+             typename LowerMap = typename Graph::template EdgeMap<int>,
+             typename CapacityMap = typename Graph::template EdgeMap<int>,
+             typename CostMap = typename Graph::template EdgeMap<int>,
+             typename SupplyMap = typename Graph::template NodeMap<int> >
+  class NetworkSimplex
+  {
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename CapacityMap::Value Capacity;
+    typedef typename CostMap::Value Cost;
+    typedef typename SupplyMap::Value Supply;
+
+    typedef std::vector<Edge> EdgeVector;
+    typedef std::vector<Node> NodeVector;
+    typedef std::vector<int> IntVector;
+    typedef std::vector<bool> BoolVector;
+    typedef std::vector<Capacity> CapacityVector;
+    typedef std::vector<Cost> CostVector;
+    typedef std::vector<Supply> SupplyVector;
+
+    typedef typename Graph::template NodeMap<int> IntNodeMap;
+
+  public:
+
+    /// The type of the flow map.
+    typedef typename Graph::template EdgeMap<Capacity> FlowMap;
+    /// The type of the potential map.
+    typedef typename Graph::template NodeMap<Cost> PotentialMap;
+
+  public:
+
+    /// Enum type to select the pivot rule used by \ref run().
+    enum PivotRuleEnum {
+      FIRST_ELIGIBLE_PIVOT,
+      BEST_ELIGIBLE_PIVOT,
+      BLOCK_SEARCH_PIVOT,
+      CANDIDATE_LIST_PIVOT,
+      ALTERING_LIST_PIVOT
+    };
+
+  private:
+
+    /// \brief Implementation of the "First Eligible" pivot rule for the
+    /// \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// This class implements the "First Eligible" pivot rule
+    /// for the \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// For more information see \ref NetworkSimplex::run().
+    class FirstEligiblePivotRule
+    {
+    private:
+
+      // References to the NetworkSimplex class
+      const EdgeVector &_edge;
+      const IntVector  &_source;
+      const IntVector  &_target;
+      const CostVector &_cost;
+      const IntVector  &_state;
+      const CostVector &_pi;
+      int &_in_edge;
+      int _edge_num;
+
+      // Pivot rule data
+      int _next_edge;
+
+    public:
+
+      /// Constructor
+      FirstEligiblePivotRule(NetworkSimplex &ns) :
+        _edge(ns._edge), _source(ns._source), _target(ns._target),
+        _cost(ns._cost), _state(ns._state), _pi(ns._pi),
+        _in_edge(ns._in_edge), _edge_num(ns._edge_num), _next_edge(0)
+      {}
+
+      /// Find next entering edge
+      bool findEnteringEdge() {
+        Cost c;
+        for (int e = _next_edge; e < _edge_num; ++e) {
+          c = _state[e] * (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (c < 0) {
+            _in_edge = e;
+            _next_edge = e + 1;
+            return true;
+          }
+        }
+        for (int e = 0; e < _next_edge; ++e) {
+          c = _state[e] * (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (c < 0) {
+            _in_edge = e;
+            _next_edge = e + 1;
+            return true;
+          }
+        }
+        return false;
+      }
+
+    }; //class FirstEligiblePivotRule
+
+
+    /// \brief Implementation of the "Best Eligible" pivot rule for the
+    /// \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// This class implements the "Best Eligible" pivot rule
+    /// for the \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// For more information see \ref NetworkSimplex::run().
+    class BestEligiblePivotRule
+    {
+    private:
+
+      // References to the NetworkSimplex class
+      const EdgeVector &_edge;
+      const IntVector  &_source;
+      const IntVector  &_target;
+      const CostVector &_cost;
+      const IntVector  &_state;
+      const CostVector &_pi;
+      int &_in_edge;
+      int _edge_num;
+
+    public:
+
+      /// Constructor
+      BestEligiblePivotRule(NetworkSimplex &ns) :
+        _edge(ns._edge), _source(ns._source), _target(ns._target),
+        _cost(ns._cost), _state(ns._state), _pi(ns._pi),
+        _in_edge(ns._in_edge), _edge_num(ns._edge_num)
+      {}
+
+      /// Find next entering edge
+      bool findEnteringEdge() {
+        Cost c, min = 0;
+        for (int e = 0; e < _edge_num; ++e) {
+          c = _state[e] * (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (c < min) {
+            min = c;
+            _in_edge = e;
+          }
+        }
+        return min < 0;
+      }
+
+    }; //class BestEligiblePivotRule
+
+
+    /// \brief Implementation of the "Block Search" pivot rule for the
+    /// \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// This class implements the "Block Search" pivot rule
+    /// for the \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// For more information see \ref NetworkSimplex::run().
+    class BlockSearchPivotRule
+    {
+    private:
+
+      // References to the NetworkSimplex class
+      const EdgeVector &_edge;
+      const IntVector  &_source;
+      const IntVector  &_target;
+      const CostVector &_cost;
+      const IntVector  &_state;
+      const CostVector &_pi;
+      int &_in_edge;
+      int _edge_num;
+
+      // Pivot rule data
+      int _block_size;
+      int _next_edge;
+
+    public:
+
+      /// Constructor
+      BlockSearchPivotRule(NetworkSimplex &ns) :
+        _edge(ns._edge), _source(ns._source), _target(ns._target),
+        _cost(ns._cost), _state(ns._state), _pi(ns._pi),
+        _in_edge(ns._in_edge), _edge_num(ns._edge_num), _next_edge(0)
+      {
+        // The main parameters of the pivot rule
+        const double BLOCK_SIZE_FACTOR = 0.5;
+        const int MIN_BLOCK_SIZE = 10;
+
+        _block_size = std::max( int(BLOCK_SIZE_FACTOR * sqrt(_edge_num)),
+                                MIN_BLOCK_SIZE );
+      }
+
+      /// Find next entering edge
+      bool findEnteringEdge() {
+        Cost c, min = 0;
+        int cnt = _block_size;
+        int e;
+        for (e = _next_edge; e < _edge_num; ++e) {
+          c = _state[e] * (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (c < min) {
+            min = c;
+            _in_edge = e;
+          }
+          if (--cnt == 0) {
+            if (min < 0) goto search_end;
+            cnt = _block_size;
+          }
+        }
+        for (e = 0; e < _next_edge; ++e) {
+          c = _state[e] * (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (c < min) {
+            min = c;
+            _in_edge = e;
+          }
+          if (--cnt == 0) {
+            if (min < 0) goto search_end;
+            cnt = _block_size;
+          }
+        }
+        if (min >= 0) return false;
+
+      search_end:
+        _next_edge = e;
+        return true;
+      }
+
+    }; //class BlockSearchPivotRule
+
+
+    /// \brief Implementation of the "Candidate List" pivot rule for the
+    /// \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// This class implements the "Candidate List" pivot rule
+    /// for the \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// For more information see \ref NetworkSimplex::run().
+    class CandidateListPivotRule
+    {
+    private:
+
+      // References to the NetworkSimplex class
+      const EdgeVector &_edge;
+      const IntVector  &_source;
+      const IntVector  &_target;
+      const CostVector &_cost;
+      const IntVector  &_state;
+      const CostVector &_pi;
+      int &_in_edge;
+      int _edge_num;
+
+      // Pivot rule data
+      IntVector _candidates;
+      int _list_length, _minor_limit;
+      int _curr_length, _minor_count;
+      int _next_edge;
+
+    public:
+
+      /// Constructor
+      CandidateListPivotRule(NetworkSimplex &ns) :
+        _edge(ns._edge), _source(ns._source), _target(ns._target),
+        _cost(ns._cost), _state(ns._state), _pi(ns._pi),
+        _in_edge(ns._in_edge), _edge_num(ns._edge_num), _next_edge(0)
+      {
+        // The main parameters of the pivot rule
+        const double LIST_LENGTH_FACTOR = 0.25;
+        const int MIN_LIST_LENGTH = 10;
+        const double MINOR_LIMIT_FACTOR = 0.1;
+        const int MIN_MINOR_LIMIT = 3;
+
+        _list_length = std::max( int(LIST_LENGTH_FACTOR * sqrt(_edge_num)),
+                                 MIN_LIST_LENGTH );
+        _minor_limit = std::max( int(MINOR_LIMIT_FACTOR * _list_length),
+                                 MIN_MINOR_LIMIT );
+        _curr_length = _minor_count = 0;
+        _candidates.resize(_list_length);
+      }
+
+      /// Find next entering edge
+      bool findEnteringEdge() {
+        Cost min, c;
+        int e;
+        if (_curr_length > 0 && _minor_count < _minor_limit) {
+          // Minor iteration: select the best eligible edge from the
+          // current candidate list
+          ++_minor_count;
+          min = 0;
+          for (int i = 0; i < _curr_length; ++i) {
+            e = _candidates[i];
+            c = _state[e] * (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+            if (c < min) {
+              min = c;
+              _in_edge = e;
+            }
+            else if (c >= 0) {
+              _candidates[i--] = _candidates[--_curr_length];
+            }
+          }
+          if (min < 0) return true;
+        }
+
+        // Major iteration: build a new candidate list
+        min = 0;
+        _curr_length = 0;
+        for (e = _next_edge; e < _edge_num; ++e) {
+          c = _state[e] * (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (c < 0) {
+            _candidates[_curr_length++] = e;
+            if (c < min) {
+              min = c;
+              _in_edge = e;
+            }
+            if (_curr_length == _list_length) goto search_end;
+          }
+        }
+        for (e = 0; e < _next_edge; ++e) {
+          c = _state[e] * (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (c < 0) {
+            _candidates[_curr_length++] = e;
+            if (c < min) {
+              min = c;
+              _in_edge = e;
+            }
+            if (_curr_length == _list_length) goto search_end;
+          }
+        }
+        if (_curr_length == 0) return false;
+      
+      search_end:        
+        _minor_count = 1;
+        _next_edge = e;
+        return true;
+      }
+
+    }; //class CandidateListPivotRule
+
+
+    /// \brief Implementation of the "Altering Candidate List" pivot rule
+    /// for the \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// This class implements the "Altering Candidate List" pivot rule
+    /// for the \ref NetworkSimplex "network simplex" algorithm.
+    ///
+    /// For more information see \ref NetworkSimplex::run().
+    class AlteringListPivotRule
+    {
+    private:
+
+      // References to the NetworkSimplex class
+      const EdgeVector &_edge;
+      const IntVector  &_source;
+      const IntVector  &_target;
+      const CostVector &_cost;
+      const IntVector  &_state;
+      const CostVector &_pi;
+      int &_in_edge;
+      int _edge_num;
+
+      int _block_size, _head_length, _curr_length;
+      int _next_edge;
+      IntVector _candidates;
+      CostVector _cand_cost;
+
+      // Functor class to compare edges during sort of the candidate list
+      class SortFunc
+      {
+      private:
+        const CostVector &_map;
+      public:
+        SortFunc(const CostVector &map) : _map(map) {}
+        bool operator()(int left, int right) {
+          return _map[left] > _map[right];
+        }
+      };
+
+      SortFunc _sort_func;
+
+    public:
+
+      /// Constructor
+      AlteringListPivotRule(NetworkSimplex &ns) :
+        _edge(ns._edge), _source(ns._source), _target(ns._target),
+        _cost(ns._cost), _state(ns._state), _pi(ns._pi),
+        _in_edge(ns._in_edge), _edge_num(ns._edge_num),
+         _next_edge(0), _cand_cost(ns._edge_num),_sort_func(_cand_cost)
+      {
+        // The main parameters of the pivot rule
+        const double BLOCK_SIZE_FACTOR = 1.0;
+        const int MIN_BLOCK_SIZE = 10;
+        const double HEAD_LENGTH_FACTOR = 0.1;
+        const int MIN_HEAD_LENGTH = 3;
+
+        _block_size = std::max( int(BLOCK_SIZE_FACTOR * sqrt(_edge_num)),
+                                MIN_BLOCK_SIZE );
+        _head_length = std::max( int(HEAD_LENGTH_FACTOR * _block_size),
+                                 MIN_HEAD_LENGTH );
+        _candidates.resize(_head_length + _block_size);
+        _curr_length = 0;
+      }
+
+      /// Find next entering edge
+      bool findEnteringEdge() {
+        // Check the current candidate list
+        int e;
+        for (int i = 0; i < _curr_length; ++i) {
+          e = _candidates[i];
+          _cand_cost[e] = _state[e] * 
+            (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (_cand_cost[e] >= 0) {
+            _candidates[i--] = _candidates[--_curr_length];
+          }
+        }
+
+        // Extend the list
+        int cnt = _block_size;
+        int limit = _head_length;
+        
+        for (e = _next_edge; e < _edge_num; ++e) {
+          _cand_cost[e] = _state[e] *
+            (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (_cand_cost[e] < 0) {
+            _candidates[_curr_length++] = e;
+          }
+          if (--cnt == 0) {
+            if (_curr_length > limit) goto search_end;
+            limit = 0;
+            cnt = _block_size;
+          }
+        }
+        for (e = 0; e < _next_edge; ++e) {
+          _cand_cost[e] = _state[e] *
+            (_cost[e] + _pi[_source[e]] - _pi[_target[e]]);
+          if (_cand_cost[e] < 0) {
+            _candidates[_curr_length++] = e;
+          }
+          if (--cnt == 0) {
+            if (_curr_length > limit) goto search_end;
+            limit = 0;
+            cnt = _block_size;
+          }
+        }
+        if (_curr_length == 0) return false;
+        
+      search_end:
+
+        // Make heap of the candidate list (approximating a partial sort)
+        make_heap( _candidates.begin(), _candidates.begin() + _curr_length,
+                   _sort_func );
+
+        // Pop the first element of the heap
+        _in_edge = _candidates[0];
+        _next_edge = e;
+        pop_heap( _candidates.begin(), _candidates.begin() + _curr_length,
+                  _sort_func );
+        _curr_length = std::min(_head_length, _curr_length - 1);
+        return true;
+      }
+
+    }; //class AlteringListPivotRule
+
+  private:
+
+    // State constants for edges
+    enum EdgeStateEnum {
+      STATE_UPPER = -1,
+      STATE_TREE  =  0,
+      STATE_LOWER =  1
+    };
+
+  private:
+
+    // The original graph
+    const Graph &_orig_graph;
+    // The original lower bound map
+    const LowerMap *_orig_lower;
+    // The original capacity map
+    const CapacityMap &_orig_cap;
+    // The original cost map
+    const CostMap &_orig_cost;
+    // The original supply map
+    const SupplyMap *_orig_supply;
+    // The source node (if no supply map was given)
+    Node _orig_source;
+    // The target node (if no supply map was given)
+    Node _orig_target;
+    // The flow value (if no supply map was given)
+    Capacity _orig_flow_value;
+
+    // The flow result map
+    FlowMap *_flow_result;
+    // The potential result map
+    PotentialMap *_potential_result;
+    // Indicate if the flow result map is local
+    bool _local_flow;
+    // Indicate if the potential result map is local
+    bool _local_potential;
+
+    // The edge references
+    EdgeVector _edge;
+    // The node references
+    NodeVector _node;
+    // The node ids
+    IntNodeMap _node_id;
+    // The source nodes of the edges
+    IntVector _source;
+    // The target nodess of the edges
+    IntVector _target;
+
+    // The (modified) capacity vector
+    CapacityVector _cap;
+    // The cost vector
+    CostVector _cost;
+    // The (modified) supply vector
+    CostVector _supply;
+    // The current flow vector
+    CapacityVector _flow;
+    // The current potential vector
+    CostVector _pi;
+
+    // The number of nodes in the original graph
+    int _node_num;
+    // The number of edges in the original graph
+    int _edge_num;
+
+    // The parent vector of the spanning tree structure
+    IntVector _parent;
+    // The pred_edge vector of the spanning tree structure
+    IntVector _pred;
+    // The thread vector of the spanning tree structure
+    IntVector _thread;
+
+    IntVector _rev_thread;
+    IntVector _succ_num;
+    IntVector _last_succ;
+
+    IntVector _dirty_revs;
+    
+    // The forward vector of the spanning tree structure
+    BoolVector _forward;
+    // The state vector
+    IntVector _state;
+    // The root node
+    int _root;
+
+    // The entering edge of the current pivot iteration
+    int _in_edge;
+
+    // Temporary nodes used in the current pivot iteration
+    int join, u_in, v_in, u_out, v_out;
+    int right, first, second, last;
+    int stem, par_stem, new_stem;
+
+    // The maximum augment amount along the found cycle in the current
+    // pivot iteration
+    Capacity delta;
+
+  public:
+
+    /// \brief General constructor (with lower bounds).
+    ///
+    /// General constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    NetworkSimplex( const Graph &graph,
+                    const LowerMap &lower,
+                    const CapacityMap &capacity,
+                    const CostMap &cost,
+                    const SupplyMap &supply ) :
+      _orig_graph(graph), _orig_lower(&lower), _orig_cap(capacity),
+      _orig_cost(cost), _orig_supply(&supply),
+      _flow_result(NULL), _potential_result(NULL),
+      _local_flow(false), _local_potential(false),
+      _node_id(graph)
+    {}
+
+    /// \brief General constructor (without lower bounds).
+    ///
+    /// General constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param supply The supply values of the nodes (signed).
+    NetworkSimplex( const Graph &graph,
+                    const CapacityMap &capacity,
+                    const CostMap &cost,
+                    const SupplyMap &supply ) :
+      _orig_graph(graph), _orig_lower(NULL), _orig_cap(capacity),
+      _orig_cost(cost), _orig_supply(&supply),
+      _flow_result(NULL), _potential_result(NULL),
+      _local_flow(false), _local_potential(false),
+      _node_id(graph)
+    {}
+
+    /// \brief Simple constructor (with lower bounds).
+    ///
+    /// Simple constructor (with lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param lower The lower bounds of the edges.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    NetworkSimplex( const Graph &graph,
+                    const LowerMap &lower,
+                    const CapacityMap &capacity,
+                    const CostMap &cost,
+                    Node s, Node t,
+                    Capacity flow_value ) :
+      _orig_graph(graph), _orig_lower(&lower), _orig_cap(capacity),
+      _orig_cost(cost), _orig_supply(NULL),
+      _orig_source(s), _orig_target(t), _orig_flow_value(flow_value),
+      _flow_result(NULL), _potential_result(NULL),
+      _local_flow(false), _local_potential(false),
+      _node_id(graph)
+    {}
+
+    /// \brief Simple constructor (without lower bounds).
+    ///
+    /// Simple constructor (without lower bounds).
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param capacity The capacities (upper bounds) of the edges.
+    /// \param cost The cost (length) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    /// \param flow_value The required amount of flow from node \c s
+    /// to node \c t (i.e. the supply of \c s and the demand of \c t).
+    NetworkSimplex( const Graph &graph,
+                    const CapacityMap &capacity,
+                    const CostMap &cost,
+                    Node s, Node t,
+                    Capacity flow_value ) :
+      _orig_graph(graph), _orig_lower(NULL), _orig_cap(capacity),
+      _orig_cost(cost), _orig_supply(NULL),
+      _orig_source(s), _orig_target(t), _orig_flow_value(flow_value),
+      _flow_result(NULL), _potential_result(NULL),
+      _local_flow(false), _local_potential(false),
+      _node_id(graph)
+    {}
+
+    /// Destructor.
+    ~NetworkSimplex() {
+      if (_local_flow) delete _flow_result;
+      if (_local_potential) delete _potential_result;
+    }
+
+    /// \brief Set the flow map.
+    ///
+    /// Set the flow map.
+    ///
+    /// \return \c (*this)
+    NetworkSimplex& flowMap(FlowMap &map) {
+      if (_local_flow) {
+        delete _flow_result;
+        _local_flow = false;
+      }
+      _flow_result = &map;
+      return *this;
+    }
+
+    /// \brief Set the potential map.
+    ///
+    /// Set the potential map.
+    ///
+    /// \return \c (*this)
+    NetworkSimplex& potentialMap(PotentialMap &map) {
+      if (_local_potential) {
+        delete _potential_result;
+        _local_potential = false;
+      }
+      _potential_result = &map;
+      return *this;
+    }
+
+    /// \name Execution control
+
+    /// @{
+
+    /// \brief Runs the algorithm.
+    ///
+    /// Runs the algorithm.
+    ///
+    /// \param pivot_rule The pivot rule that is used during the
+    /// algorithm.
+    ///
+    /// The available pivot rules:
+    ///
+    /// - FIRST_ELIGIBLE_PIVOT The next eligible edge is selected in
+    /// a wraparound fashion in every iteration
+    /// (\ref FirstEligiblePivotRule).
+    ///
+    /// - BEST_ELIGIBLE_PIVOT The best eligible edge is selected in
+    /// every iteration (\ref BestEligiblePivotRule).
+    ///
+    /// - BLOCK_SEARCH_PIVOT A specified number of edges are examined in
+    /// every iteration in a wraparound fashion and the best eligible
+    /// edge is selected from this block (\ref BlockSearchPivotRule).
+    ///
+    /// - CANDIDATE_LIST_PIVOT In a major iteration a candidate list is
+    /// built from eligible edges in a wraparound fashion and in the
+    /// following minor iterations the best eligible edge is selected
+    /// from this list (\ref CandidateListPivotRule).
+    ///
+    /// - ALTERING_LIST_PIVOT It is a modified version of the
+    /// "Candidate List" pivot rule. It keeps only the several best
+    /// eligible edges from the former candidate list and extends this
+    /// list in every iteration (\ref AlteringListPivotRule).
+    ///
+    /// According to our comprehensive benchmark tests the "Block Search"
+    /// pivot rule proved to be the fastest and the most robust on
+    /// various test inputs. Thus it is the default option.
+    ///
+    /// \return \c true if a feasible flow can be found.
+    bool run(PivotRuleEnum pivot_rule = BLOCK_SEARCH_PIVOT) {
+      return init() && start(pivot_rule);
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The results of the algorithm can be obtained using these
+    /// functions.\n
+    /// \ref lemon::NetworkSimplex::run() "run()" must be called before
+    /// using them.
+
+    /// @{
+
+    /// \brief Return a const reference to the edge map storing the
+    /// found flow.
+    ///
+    /// Return a const reference to the edge map storing the found flow.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const FlowMap& flowMap() const {
+      return *_flow_result;
+    }
+
+    /// \brief Return a const reference to the node map storing the
+    /// found potentials (the dual solution).
+    ///
+    /// Return a const reference to the node map storing the found
+    /// potentials (the dual solution).
+    ///
+    /// \pre \ref run() must be called before using this function.
+    const PotentialMap& potentialMap() const {
+      return *_potential_result;
+    }
+
+    /// \brief Return the flow on the given edge.
+    ///
+    /// Return the flow on the given edge.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Capacity flow(const typename Graph::Edge& edge) const {
+      return (*_flow_result)[edge];
+    }
+
+    /// \brief Return the potential of the given node.
+    ///
+    /// Return the potential of the given node.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost potential(const typename Graph::Node& node) const {
+      return (*_potential_result)[node];
+    }
+
+    /// \brief Return the total cost of the found flow.
+    ///
+    /// Return the total cost of the found flow. The complexity of the
+    /// function is \f$ O(e) \f$.
+    ///
+    /// \pre \ref run() must be called before using this function.
+    Cost totalCost() const {
+      Cost c = 0;
+      for (EdgeIt e(_orig_graph); e != INVALID; ++e)
+        c += (*_flow_result)[e] * _orig_cost[e];
+      return c;
+    }
+
+    /// @}
+
+  private:
+
+    // Initialize internal data structures
+    bool init() {
+      // Initialize result maps
+      if (!_flow_result) {
+        _flow_result = new FlowMap(_orig_graph);
+        _local_flow = true;
+      }
+      if (!_potential_result) {
+        _potential_result = new PotentialMap(_orig_graph);
+        _local_potential = true;
+      }
+      
+      // Initialize vectors
+      _node_num = countNodes(_orig_graph);
+      _edge_num = countEdges(_orig_graph);
+      int all_node_num = _node_num + 1;
+      int all_edge_num = _edge_num + _node_num;
+      
+      _edge.resize(_edge_num);
+      _node.reserve(_node_num);
+      _source.resize(all_edge_num);
+      _target.resize(all_edge_num);
+      
+      _cap.resize(all_edge_num);
+      _cost.resize(all_edge_num);
+      _supply.resize(all_node_num);
+      _flow.resize(all_edge_num, 0);
+      _pi.resize(all_node_num, 0);
+      
+      _parent.resize(all_node_num);
+      _pred.resize(all_node_num);
+      _forward.resize(all_node_num);
+      _thread.resize(all_node_num);
+      _rev_thread.resize(all_node_num);
+      _succ_num.resize(all_node_num);
+      _last_succ.resize(all_node_num);
+      _state.resize(all_edge_num, STATE_LOWER);
+      
+      // Initialize node related data
+      bool valid_supply = true;
+      if (_orig_supply) {
+        Supply sum = 0;
+        int i = 0;
+        for (NodeIt n(_orig_graph); n != INVALID; ++n, ++i) {
+          _node.push_back(n);
+          _node_id[n] = i;
+          _supply[i] = (*_orig_supply)[n];
+          sum += _supply[i];
+        }
+        valid_supply = (sum == 0);
+      } else {
+        int i = 0;
+        for (NodeIt n(_orig_graph); n != INVALID; ++n, ++i) {
+          _node.push_back(n);
+          _node_id[n] = i;
+          _supply[i] = 0;
+        }
+        _supply[_node_id[_orig_source]] =  _orig_flow_value;
+        _supply[_node_id[_orig_target]] = -_orig_flow_value;
+      }
+      if (!valid_supply) return false;
+      
+      // Set data for the artificial root node
+      _root = _node_num;
+      _parent[_root] = -1;
+      _pred[_root] = -1;
+      _thread[_root] = 0;
+      _rev_thread[0] = _root;
+      _succ_num[_root] = all_node_num;
+      _last_succ[_root] = _root - 1;
+      _supply[_root] = 0;
+      _pi[_root] = 0;
+      
+      // Store the edges
+      int i = 0;
+      for (EdgeIt e(_orig_graph); e != INVALID; ++e) {
+        _edge[i++] = e;
+      }
+
+      // Initialize edge maps
+      for (int i = 0; i != _edge_num; ++i) {
+        Edge e = _edge[i];
+        _source[i] = _node_id[_orig_graph.source(e)];
+        _target[i] = _node_id[_orig_graph.target(e)];
+        _cost[i] = _orig_cost[e];
+        _cap[i] = _orig_cap[e];
+      }
+
+      // Remove non-zero lower bounds
+      if (_orig_lower) {
+        for (int i = 0; i != _edge_num; ++i) {
+          Capacity c = (*_orig_lower)[_edge[i]];
+          if (c != 0) {
+            _cap[i] -= c;
+            _supply[_source[i]] -= c;
+            _supply[_target[i]] += c;
+          }
+        }
+      }
+
+      // Add artificial edges and initialize the spanning tree data structure
+      Cost max_cost = std::numeric_limits<Cost>::max() / 2 + 1;
+      Capacity max_cap = std::numeric_limits<Capacity>::max();
+      for (int u = 0, e = _edge_num; u != _node_num; ++u, ++e) {
+        _parent[u] = _root;
+        _pred[u] = e;
+        _thread[u] = u + 1;
+        _rev_thread[u + 1] = u;
+        _succ_num[u] = 1;
+        _last_succ[u] = u;
+        _cap[e] = max_cap;
+        _state[e] = STATE_TREE;
+        if (_supply[u] >= 0) {
+          _forward[u] = true;
+          _pi[u] = 0;
+          _source[e] = u;
+          _target[e] = _root;
+          _flow[e] = _supply[u];
+          _cost[e] = 0;
+        }
+        else {
+          _forward[u] = false;
+          _pi[u] = max_cost;
+          _source[e] = _root;
+          _target[e] = u;
+          _flow[e] = -_supply[u];
+          _cost[e] = max_cost;
+        }
+      }
+
+      return true;
+    }
+
+    // Find the join node
+    void findJoinNode() {
+      int u = _source[_in_edge];
+      int v = _target[_in_edge];
+      while (u != v) {
+        if (_succ_num[u] < _succ_num[v]) {
+          u = _parent[u];
+        } else {
+          v = _parent[v];
+        }
+      }
+      join = u;
+    }
+
+    // Find the leaving edge of the cycle and returns true if the
+    // leaving edge is not the same as the entering edge
+    bool findLeavingEdge() {
+      // Initialize first and second nodes according to the direction
+      // of the cycle
+      if (_state[_in_edge] == STATE_LOWER) {
+        first  = _source[_in_edge];
+        second = _target[_in_edge];
+      } else {
+        first  = _target[_in_edge];
+        second = _source[_in_edge];
+      }
+      delta = _cap[_in_edge];
+      int result = 0;
+      Capacity d;
+      int e;
+
+      // Search the cycle along the path form the first node to the root
+      for (int u = first; u != join; u = _parent[u]) {
+        e = _pred[u];
+        d = _forward[u] ? _flow[e] : _cap[e] - _flow[e];
+        if (d < delta) {
+          delta = d;
+          u_out = u;
+          result = 1;
+        }
+      }
+      // Search the cycle along the path form the second node to the root
+      for (int u = second; u != join; u = _parent[u]) {
+        e = _pred[u];
+        d = _forward[u] ? _cap[e] - _flow[e] : _flow[e];
+        if (d <= delta) {
+          delta = d;
+          u_out = u;
+          result = 2;
+        }
+      }
+
+      if (result == 1) {
+        u_in = first;
+        v_in = second;
+      } else {
+        u_in = second;
+        v_in = first;
+      }
+      return result != 0;
+    }
+
+    // Change _flow and _state vectors
+    void changeFlow(bool change) {
+      // Augment along the cycle
+      if (delta > 0) {
+        Capacity val = _state[_in_edge] * delta;
+        _flow[_in_edge] += val;
+        for (int u = _source[_in_edge]; u != join; u = _parent[u]) {
+          _flow[_pred[u]] += _forward[u] ? -val : val;
+        }
+        for (int u = _target[_in_edge]; u != join; u = _parent[u]) {
+          _flow[_pred[u]] += _forward[u] ? val : -val;
+        }
+      }
+      // Update the state of the entering and leaving edges
+      if (change) {
+        _state[_in_edge] = STATE_TREE;
+        _state[_pred[u_out]] =
+          (_flow[_pred[u_out]] == 0) ? STATE_LOWER : STATE_UPPER;
+      } else {
+        _state[_in_edge] = -_state[_in_edge];
+      }
+    }
+    
+    // Update the tree structure
+    void updateTreeStructure() {
+      int u, w;
+      int old_rev_thread = _rev_thread[u_out];
+      int old_succ_num = _succ_num[u_out];
+      int old_last_succ = _last_succ[u_out];
+      v_out = _parent[u_out];
+
+      u = _last_succ[u_in];  // the last successor of u_in
+      right = _thread[u];    // the node after it
+      
+      // Handle the case when old_rev_thread equals to v_in 
+      // (it also means that join and v_out coincide)
+      if (old_rev_thread == v_in) {
+        last = _thread[_last_succ[u_out]];
+      } else {
+        last = _thread[v_in];
+      }
+
+      // Update _thread and _parent along the stem nodes (i.e. the nodes 
+      // between u_in and u_out, whose parent have to be changed)
+      _thread[v_in] = stem = u_in;
+      _dirty_revs.clear();
+      _dirty_revs.push_back(v_in);
+      par_stem = v_in;
+      while (stem != u_out) {
+        // Insert the next stem node into the thread list
+        new_stem = _parent[stem];
+        _thread[u] = new_stem;
+        _dirty_revs.push_back(u);
+        
+        // Remove the subtree of stem from the thread list
+        w = _rev_thread[stem];
+        _thread[w] = right;
+        _rev_thread[right] = w;
+
+        // Change the parent node and shift stem nodes
+        _parent[stem] = par_stem;        
+        par_stem = stem;
+        stem = new_stem;
+
+        // Update u and right nodes
+        u = _last_succ[stem] == _last_succ[par_stem] ?
+          _rev_thread[par_stem] : _last_succ[stem];
+        right = _thread[u];
+      }
+      _parent[u_out] = par_stem;
+      _last_succ[u_out] = u;
+      _thread[u] = last;
+      _rev_thread[last] = u;
+
+      // Remove the subtree of u_out from the thread list except for 
+      // the case when old_rev_thread equals to v_in 
+      // (it also means that join and v_out coincide)
+      if (old_rev_thread != v_in) {
+        _thread[old_rev_thread] = right;
+        _rev_thread[right] = old_rev_thread;
+      }
+      
+      // Update _rev_thread using the new _thread values
+      for (int i = 0; i < int(_dirty_revs.size()); ++i) {
+        u = _dirty_revs[i];
+        _rev_thread[_thread[u]] = u;
+      }
+      
+      // Update _last_succ for the stem nodes from u_out to u_in
+      for (u = u_out; u != u_in; u = _parent[u]) {
+        _last_succ[_parent[u]] = _last_succ[u];      
+      }
+
+      // Set limits for updating _last_succ form v_in and v_out
+      // towards the root
+      int up_limit_in = -1;
+      int up_limit_out = -1;
+      if (_last_succ[join] == v_in) {
+        up_limit_out = join;
+      } else {
+        up_limit_in = join;
+      }
+
+      // Update _last_succ from v_in towards the root
+      for (u = v_in; u != up_limit_in && _last_succ[u] == v_in; 
+           u = _parent[u]) {
+        _last_succ[u] = _last_succ[u_out];
+      }
+      // Update _last_succ from v_out towards the root
+      if (join != old_rev_thread && v_in != old_rev_thread) {
+        for (u = v_out; u != up_limit_out && _last_succ[u] == old_last_succ; 
+             u = _parent[u]) {
+          _last_succ[u] = old_rev_thread;
+        }
+      } else {
+        for (u = v_out; u != up_limit_out && _last_succ[u] == old_last_succ;
+             u = _parent[u]) {
+          _last_succ[u] = _last_succ[u_out];
+        }
+      }
+
+      // Update _pred and _forward for the stem nodes from u_out to u_in
+      u = u_out;
+      while (u != u_in) {
+        w = _parent[u];
+        _pred[u] = _pred[w];
+        _forward[u] = !_forward[w];
+        u = w;
+      }
+      _pred[u_in] = _in_edge;
+      _forward[u_in] = (u_in == _source[_in_edge]);
+      
+      // Update _succ_num from v_in to join
+      for (u = v_in; u != join; u = _parent[u]) {
+        _succ_num[u] += old_succ_num;
+      }
+      // Update _succ_num from v_out to join
+      for (u = v_out; u != join; u = _parent[u]) {
+        _succ_num[u] -= old_succ_num;
+      }
+      // Update _succ_num for the stem nodes from u_out to u_in
+      int tmp = 0;
+      u = u_out;
+      while (u != u_in) {
+        w = _parent[u];
+        tmp = _succ_num[u] - _succ_num[w] + tmp;
+        _succ_num[u] = tmp;
+        u = w;
+      }
+      _succ_num[u_in] = old_succ_num;
+    }
+
+    // Update potentials
+    void updatePotential() {
+      Cost sigma = _forward[u_in] ?
+        _pi[v_in] - _pi[u_in] - _cost[_pred[u_in]] :
+        _pi[v_in] - _pi[u_in] + _cost[_pred[u_in]];
+      // Update in the lower subtree (which has been moved)
+      int end = _thread[_last_succ[u_in]];
+      for (int u = u_in; u != end; u = _thread[u]) {
+        _pi[u] += sigma;
+      }
+    }
+
+    // Execute the algorithm
+    bool start(PivotRuleEnum pivot_rule) {
+      // Select the pivot rule implementation
+      switch (pivot_rule) {
+        case FIRST_ELIGIBLE_PIVOT:
+          return start<FirstEligiblePivotRule>();
+        case BEST_ELIGIBLE_PIVOT:
+          return start<BestEligiblePivotRule>();
+        case BLOCK_SEARCH_PIVOT:
+          return start<BlockSearchPivotRule>();
+        case CANDIDATE_LIST_PIVOT:
+          return start<CandidateListPivotRule>();
+        case ALTERING_LIST_PIVOT:
+          return start<AlteringListPivotRule>();
+      }
+      return false;
+    }
+
+    template<class PivotRuleImplementation>
+    bool start() {
+      PivotRuleImplementation pivot(*this);
+      
+      // Execute the network simplex algorithm
+      while (pivot.findEnteringEdge()) {
+        findJoinNode();
+        bool change = findLeavingEdge();
+        changeFlow(change);
+        if (change) {
+          updateTreeStructure();
+          updatePotential();
+        }
+      }
+      
+      // Check if the flow amount equals zero on all the artificial edges
+      for (int e = _edge_num; e != _edge_num + _node_num; ++e) {
+        if (_flow[e] > 0) return false;
+      }
+
+      // Copy flow values to _flow_result
+      if (_orig_lower) {
+        for (int i = 0; i != _edge_num; ++i) {
+          Edge e = _edge[i];
+          (*_flow_result)[e] = (*_orig_lower)[e] + _flow[i];
+        }
+      } else {
+        for (int i = 0; i != _edge_num; ++i) {
+          (*_flow_result)[_edge[i]] = _flow[i];
+        }
+      }
+      // Copy potential values to _potential_result
+      for (int i = 0; i != _node_num; ++i) {
+        (*_potential_result)[_node[i]] = _pi[i];
+      }
+      
+      return true;
+    }
+
+  }; //class NetworkSimplex
+
+  ///@}
+
+} //namespace lemon
+
+#endif //LEMON_NETWORK_SIMPLEX_H
Index: lemon/path.h
===================================================================
--- lemon/path.h	(revision 2553)
+++ lemon/path.h	(revision 2553)
@@ -0,0 +1,903 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup paths
+///\file
+///\brief Classes for representing paths in graphs.
+///
+
+#ifndef LEMON_PATH_H
+#define LEMON_PATH_H
+
+#include <vector>
+#include <algorithm>
+
+#include <lemon/path_utils.h>
+#include <lemon/error.h>
+#include <lemon/bits/invalid.h>
+
+namespace lemon {
+
+  /// \addtogroup paths
+  /// @{
+
+
+  /// \brief A structure for representing directed paths in a graph.
+  ///
+  /// A structure for representing directed path in a graph.
+  /// \param Graph The graph type in which the path is.
+  ///
+  /// In a sense, the path can be treated as a list of edges. The
+  /// lemon path type stores just this list. As a consequence it
+  /// cannot enumerate the nodes in the path and the zero length paths
+  /// cannot store the source.
+  ///
+  /// This implementation is a back and front insertable and erasable
+  /// path type. It can be indexed in O(1) time. The front and back
+  /// insertion and erasure is amortized O(1) time. The
+  /// impelementation is based on two opposite organized vectors.
+  template <typename _Graph>
+  class Path {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+
+    /// \brief Default constructor
+    ///
+    /// Default constructor
+    Path() {}
+
+    /// \brief Template copy constructor
+    ///
+    /// This path can be initialized with any other path type. It just
+    /// makes a copy of the given path.
+    template <typename CPath>
+    Path(const CPath& cpath) {
+      copyPath(*this, cpath);
+    }
+
+    /// \brief Template copy assignment
+    ///
+    /// This path can be initialized with any other path type. It just
+    /// makes a copy of the given path.
+    template <typename CPath>
+    Path& operator=(const CPath& cpath) {
+      copyPath(*this, cpath);
+      return *this;
+    }
+
+    /// \brief Lemon style iterator for path edges
+    ///
+    /// This class is used to iterate on the edges of the paths.
+    class EdgeIt {
+      friend class Path;
+    public:
+      /// \brief Default constructor
+      EdgeIt() {}
+      /// \brief Invalid constructor
+      EdgeIt(Invalid) : path(0), idx(-1) {}
+      /// \brief Initializate the constructor to the first edge of path
+      EdgeIt(const Path &_path) 
+        : path(&_path), idx(_path.empty() ? -1 : 0) {}
+
+    private:
+
+      EdgeIt(const Path &_path, int _idx) 
+        : path(&_path), idx(_idx) {}
+
+    public:
+
+      /// \brief Conversion to Edge
+      operator const Edge&() const {
+        return path->nth(idx);
+      }
+
+      /// \brief Next edge
+      EdgeIt& operator++() { 
+        ++idx;
+        if (idx >= path->length()) idx = -1; 
+        return *this; 
+      }
+
+      /// \brief Comparison operator
+      bool operator==(const EdgeIt& e) const { return idx==e.idx; }
+      /// \brief Comparison operator
+      bool operator!=(const EdgeIt& e) const { return idx!=e.idx; }
+      /// \brief Comparison operator
+      bool operator<(const EdgeIt& e) const { return idx<e.idx; }
+
+    private:
+      const Path *path;
+      int idx;
+    };
+
+    /// \brief Length of the path.
+    int length() const { return head.size() + tail.size(); }
+    /// \brief Returns whether the path is empty.
+    bool empty() const { return head.empty() && tail.empty(); }
+
+    /// \brief Resets the path to an empty path.
+    void clear() { head.clear(); tail.clear(); }
+
+    /// \brief Gives back the nth edge.
+    ///
+    /// \pre n is in the [0..length() - 1] range
+    const Edge& nth(int n) const {
+      return n < int(head.size()) ? *(head.rbegin() + n) :
+        *(tail.begin() + (n - head.size()));
+    }
+
+    /// \brief Initializes edge iterator to point to the nth edge
+    ///
+    /// \pre n is in the [0..length() - 1] range
+    EdgeIt nthIt(int n) const {
+      return EdgeIt(*this, n);
+    }
+
+    /// \brief Gives back the first edge of the path
+    const Edge& front() const {
+      return head.empty() ? tail.front() : head.back();
+    }
+
+    /// \brief Add a new edge before the current path
+    void addFront(const Edge& edge) {
+      head.push_back(edge);
+    }
+
+    /// \brief Erase the first edge of the path
+    void eraseFront() {
+      if (!head.empty()) {
+        head.pop_back();
+      } else {
+        head.clear();
+        int halfsize = tail.size() / 2;
+        head.resize(halfsize);
+        std::copy(tail.begin() + 1, tail.begin() + halfsize + 1,
+                  head.rbegin());
+        std::copy(tail.begin() + halfsize + 1, tail.end(), tail.begin());
+        tail.resize(tail.size() - halfsize - 1);
+      }
+    }
+
+    /// \brief Gives back the last edge of the path
+    const Edge& back() const {
+      return tail.empty() ? head.front() : tail.back();
+    }
+
+    /// \brief Add a new edge behind the current path
+    void addBack(const Edge& edge) {
+      tail.push_back(edge);
+    }
+
+    /// \brief Erase the last edge of the path
+    void eraseBack() {
+      if (!tail.empty()) {
+        tail.pop_back();
+      } else {
+        int halfsize = head.size() / 2;
+        tail.resize(halfsize);
+        std::copy(head.begin() + 1, head.begin() + halfsize + 1,
+                  tail.rbegin());
+        std::copy(head.begin() + halfsize + 1, head.end(), head.begin());
+        head.resize(head.size() - halfsize - 1);
+      }
+    }
+
+
+
+    typedef True BuildTag;
+
+    template <typename CPath>
+    void build(const CPath& path) {
+      int len = path.length();
+      tail.reserve(len);
+      for (typename CPath::EdgeIt it(path); it != INVALID; ++it) {
+        tail.push_back(it);
+      }
+    }
+
+    template <typename CPath>
+    void buildRev(const CPath& path) {
+      int len = path.length();
+      head.reserve(len);
+      for (typename CPath::RevEdgeIt it(path); it != INVALID; ++it) {
+        head.push_back(it);
+      }
+    }
+
+  protected:
+    typedef std::vector<Edge> Container;
+    Container head, tail;
+
+  };
+
+  /// \brief A structure for representing directed paths in a graph.
+  ///
+  /// A structure for representing directed path in a graph.
+  /// \param Graph The graph type in which the path is.
+  ///
+  /// In a sense, the path can be treated as a list of edges. The
+  /// lemon path type stores just this list. As a consequence it
+  /// cannot enumerate the nodes in the path and the zero length paths
+  /// cannot store the source.
+  ///
+  /// This implementation is a just back insertable and erasable path
+  /// type. It can be indexed in O(1) time. The back insertion and
+  /// erasure is amortized O(1) time. This implementation is faster
+  /// then the \c Path type because it use just one vector for the
+  /// edges.
+  template <typename _Graph>
+  class SimplePath {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+
+    /// \brief Default constructor
+    ///
+    /// Default constructor
+    SimplePath() {}
+
+    /// \brief Template copy constructor
+    ///
+    /// This path can be initialized with any other path type. It just
+    /// makes a copy of the given path.
+    template <typename CPath>
+    SimplePath(const CPath& cpath) {
+      copyPath(*this, cpath);
+    }
+
+    /// \brief Template copy assignment
+    ///
+    /// This path can be initialized with any other path type. It just
+    /// makes a copy of the given path.
+    template <typename CPath>
+    SimplePath& operator=(const CPath& cpath) {
+      copyPath(*this, cpath);
+      return *this;
+    }
+
+    /// \brief Iterator class to iterate on the edges of the paths
+    ///
+    /// This class is used to iterate on the edges of the paths
+    ///
+    /// Of course it converts to Graph::Edge
+    class EdgeIt {
+      friend class SimplePath;
+    public:
+      /// Default constructor
+      EdgeIt() {}
+      /// Invalid constructor
+      EdgeIt(Invalid) : path(0), idx(-1) {}
+      /// \brief Initializate the constructor to the first edge of path
+      EdgeIt(const SimplePath &_path) 
+        : path(&_path), idx(_path.empty() ? -1 : 0) {}
+
+    private:
+
+      /// Constructor with starting point
+      EdgeIt(const SimplePath &_path, int _idx) 
+        : idx(_idx), path(&_path) {}
+
+    public:
+
+      ///Conversion to Graph::Edge
+      operator const Edge&() const {
+        return path->nth(idx);
+      }
+
+      /// Next edge
+      EdgeIt& operator++() { 
+        ++idx;
+        if (idx >= path->length()) idx = -1; 
+        return *this; 
+      }
+
+      /// Comparison operator
+      bool operator==(const EdgeIt& e) const { return idx==e.idx; }
+      /// Comparison operator
+      bool operator!=(const EdgeIt& e) const { return idx!=e.idx; }
+      /// Comparison operator
+      bool operator<(const EdgeIt& e) const { return idx<e.idx; }
+
+    private:
+      const SimplePath *path;
+      int idx;
+    };
+
+    /// \brief Length of the path.
+    int length() const { return data.size(); }
+    /// \brief Returns whether the path is empty.
+    bool empty() const { return data.empty(); }
+
+    /// \brief Resets the path to an empty path.
+    void clear() { data.clear(); }
+
+    /// \brief Gives back the nth edge.
+    ///
+    /// \pre n is in the [0..length() - 1] range
+    const Edge& nth(int n) const {
+      return data[n];
+    }
+
+    /// \brief  Initializes edge iterator to point to the nth edge.
+    EdgeIt nthIt(int n) const {
+      return EdgeIt(*this, n);
+    }
+
+    /// \brief Gives back the first edge of the path.
+    const Edge& front() const {
+      return data.front();
+    }
+
+    /// \brief Gives back the last edge of the path.
+    const Edge& back() const {
+      return data.back();
+    }
+
+    /// \brief Add a new edge behind the current path.
+    void addBack(const Edge& edge) {
+      data.push_back(edge);
+    }
+
+    /// \brief Erase the last edge of the path
+    void eraseBack() {
+      data.pop_back();
+    }
+
+    typedef True BuildTag;
+
+    template <typename CPath>
+    void build(const CPath& path) {
+      int len = path.length();
+      data.resize(len);
+      int index = 0;
+      for (typename CPath::EdgeIt it(path); it != INVALID; ++it) {
+        data[index] = it;;
+        ++index;
+      }
+    }
+
+    template <typename CPath>
+    void buildRev(const CPath& path) {
+      int len = path.length();
+      data.resize(len);
+      int index = len;
+      for (typename CPath::RevEdgeIt it(path); it != INVALID; ++it) {
+        --index;
+        data[index] = it;;
+      }
+    }
+
+  protected:
+    typedef std::vector<Edge> Container;
+    Container data;
+
+  };
+
+  /// \brief A structure for representing directed paths in a graph.
+  ///
+  /// A structure for representing directed path in a graph.
+  /// \param Graph The graph type in which the path is.
+  ///
+  /// In a sense, the path can be treated as a list of edges. The
+  /// lemon path type stores just this list. As a consequence it
+  /// cannot enumerate the nodes in the path and the zero length paths
+  /// cannot store the source.
+  ///
+  /// This implementation is a back and front insertable and erasable
+  /// path type. It can be indexed in O(k) time, where k is the rank
+  /// of the edge in the path. The length can be computed in O(n)
+  /// time. The front and back insertion and erasure is O(1) time
+  /// and it can be splited and spliced in O(1) time.
+  template <typename _Graph>
+  class ListPath {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+
+  protected:
+
+    // the std::list<> is incompatible 
+    // hard to create invalid iterator
+    struct Node {
+      Edge edge;
+      Node *next, *prev;
+    };
+
+    Node *first, *last;
+
+    std::allocator<Node> alloc;
+
+  public:
+ 
+    /// \brief Default constructor
+    ///
+    /// Default constructor
+    ListPath() : first(0), last(0) {}
+
+    /// \brief Template copy constructor
+    ///
+    /// This path can be initialized with any other path type. It just
+    /// makes a copy of the given path.
+    template <typename CPath>
+    ListPath(const CPath& cpath) : first(0), last(0) {
+      copyPath(*this, cpath);
+    }
+
+    /// \brief Destructor of the path
+    ///
+    /// Destructor of the path
+    ~ListPath() {
+      clear();
+    }
+
+    /// \brief Template copy assignment
+    ///
+    /// This path can be initialized with any other path type. It just
+    /// makes a copy of the given path.
+    template <typename CPath>
+    ListPath& operator=(const CPath& cpath) {
+      copyPath(*this, cpath);
+      return *this;
+    }
+
+    /// \brief Iterator class to iterate on the edges of the paths
+    ///
+    /// This class is used to iterate on the edges of the paths
+    ///
+    /// Of course it converts to Graph::Edge
+    class EdgeIt {
+      friend class ListPath;
+    public:
+      /// Default constructor
+      EdgeIt() {}
+      /// Invalid constructor
+      EdgeIt(Invalid) : path(0), node(0) {}
+      /// \brief Initializate the constructor to the first edge of path
+      EdgeIt(const ListPath &_path) 
+        : path(&_path), node(_path.first) {}
+
+    protected:
+
+      EdgeIt(const ListPath &_path, Node *_node) 
+        : path(&_path), node(_node) {}
+
+
+    public:
+
+      ///Conversion to Graph::Edge
+      operator const Edge&() const {
+        return node->edge;
+      }
+
+      /// Next edge
+      EdgeIt& operator++() { 
+        node = node->next;
+        return *this; 
+      }
+
+      /// Comparison operator
+      bool operator==(const EdgeIt& e) const { return node==e.node; }
+      /// Comparison operator
+      bool operator!=(const EdgeIt& e) const { return node!=e.node; }
+      /// Comparison operator
+      bool operator<(const EdgeIt& e) const { return node<e.node; }
+
+    private:
+      const ListPath *path;
+      Node *node;
+    };
+
+    /// \brief Gives back the nth edge.
+    ///
+    /// Gives back the nth edge in O(n) time.
+    /// \pre n is in the [0..length() - 1] range
+    const Edge& nth(int n) const {
+      Node *node = first;
+      for (int i = 0; i < n; ++i) {
+        node = node->next;
+      }
+      return node->edge;
+    }
+
+    /// \brief Initializes edge iterator to point to the nth edge.
+    EdgeIt nthIt(int n) const {
+      Node *node = first;
+      for (int i = 0; i < n; ++i) {
+        node = node->next;
+      }
+      return EdgeIt(*this, node);
+    }
+
+    /// \brief Length of the path.
+    int length() const {
+      int len = 0;
+      Node *node = first;
+      while (node != 0) {
+        node = node->next;
+        ++len;
+      }
+      return len;
+    }
+
+    /// \brief Returns whether the path is empty.
+    bool empty() const { return first == 0; }
+
+    /// \brief Resets the path to an empty path.
+    void clear() {
+      while (first != 0) {
+        last = first->next;
+        alloc.destroy(first);
+        alloc.deallocate(first, 1);
+        first = last;
+      }
+    }
+
+    /// \brief Gives back the first edge of the path
+    const Edge& front() const {
+      return first->edge;
+    }
+
+    /// \brief Add a new edge before the current path
+    void addFront(const Edge& edge) {
+      Node *node = alloc.allocate(1);
+      alloc.construct(node, Node());
+      node->prev = 0;
+      node->next = first;
+      node->edge = edge;
+      if (first) {
+        first->prev = node;
+        first = node;
+      } else {
+        first = last = node;
+      }
+    }
+
+    /// \brief Erase the first edge of the path
+    void eraseFront() {
+      Node *node = first;
+      first = first->next;
+      if (first) {
+        first->prev = 0;
+      } else {
+        last = 0;
+      }
+      alloc.destroy(node);
+      alloc.deallocate(node, 1);
+    }
+
+    /// \brief Gives back the last edge of the path.
+    const Edge& back() const {
+      return last->edge;
+    }
+
+    /// \brief Add a new edge behind the current path.
+    void addBack(const Edge& edge) {
+      Node *node = alloc.allocate(1);
+      alloc.construct(node, Node());
+      node->next = 0;
+      node->prev = last;
+      node->edge = edge;
+      if (last) {
+        last->next = node;
+        last = node;
+      } else {
+        last = first = node;
+      }
+    }
+
+    /// \brief Erase the last edge of the path
+    void eraseBack() {
+      Node *node = last;
+      last = last->prev;
+      if (last) {
+        last->next = 0;
+      } else {
+        first = 0;
+      }
+      alloc.destroy(node);
+      alloc.deallocate(node, 1);
+    }
+
+    /// \brief Splicing the given path to the current path.
+    ///
+    /// It splices the \c tpath to the back of the current path and \c
+    /// tpath becomes empty. The time complexity of this function is
+    /// O(1).
+    void spliceBack(ListPath& tpath) {
+      if (first) {
+        if (tpath.first) {
+          last->next = tpath.first;
+          tpath.first->prev = last;
+          last = tpath.last;
+        }
+      } else {
+        first = tpath.first;
+        last = tpath.last;
+      }
+      tpath.first = tpath.last = 0;
+    }
+
+    /// \brief Splicing the given path to the current path.
+    ///
+    /// It splices the \c tpath before the current path and \c tpath
+    /// becomes empty. The time complexity of this function
+    /// is O(1).
+    void spliceFront(ListPath& tpath) {
+      if (first) {
+        if (tpath.first) {
+          first->prev = tpath.last;
+          tpath.last->next = first;
+          first = tpath.first;
+        }
+      } else {
+        first = tpath.first;
+        last = tpath.last;
+      }
+      tpath.first = tpath.last = 0;
+    }
+
+    /// \brief Splicing the given path into the current path.
+    ///
+    /// It splices the \c tpath into the current path before the
+    /// position of \c it iterator and \c tpath becomes empty. The
+    /// time complexity of this function is O(1). If the \c it is \c
+    /// INVALID then it will splice behind the current path.
+    void splice(EdgeIt it, ListPath& tpath) {
+      if (it.node) {
+        if (tpath.first) {
+          tpath.first->prev = it.node->prev;
+          if (it.node->prev) {
+            it.node->prev->next = tpath.first;
+          } else {
+            first = tpath.first;
+          }
+          it.node->prev = tpath.last;
+          tpath.last->next = it.node;
+        }
+      } else {
+        if (first) {
+          if (tpath.first) {
+            last->next = tpath.first;
+            tpath.first->prev = last;
+            last = tpath.last;
+          }
+        } else {
+          first = tpath.first;
+          last = tpath.last;
+        }
+      }
+      tpath.first = tpath.last = 0;
+    }
+
+    /// \brief Spliting the current path.
+    ///
+    /// It splits the current path into two parts. The part before \c
+    /// it iterator will remain in the current path and the part from
+    /// the it will put into the \c tpath. If the \c tpath had edges
+    /// before the operation they will be removed first.  The time
+    /// complexity of this function is O(1) plus the clearing of \c
+    /// tpath. If the \c it is \c INVALID then it just clears \c
+    /// tpath.
+    void split(EdgeIt it, ListPath& tpath) {
+      tpath.clear();
+      if (it.node) {
+        tpath.first = it.node;
+        tpath.last = last;
+        if (it.node->prev) {
+          last = it.node->prev;
+          last->next = 0;
+        } else {
+          first = last = 0;
+        }
+        it.node->prev = 0;
+      }
+    }
+
+
+    typedef True BuildTag;
+
+    template <typename CPath>
+    void build(const CPath& path) {
+      for (typename CPath::EdgeIt it(path); it != INVALID; ++it) {
+        addBack(it);
+      }
+    }
+
+    template <typename CPath>
+    void buildRev(const CPath& path) {
+      for (typename CPath::RevEdgeIt it(path); it != INVALID; ++it) {
+        addFront(it);
+      }
+    }
+
+  };
+
+  /// \brief A structure for representing directed paths in a graph.
+  ///
+  /// A structure for representing directed path in a graph.
+  /// \param Graph The graph type in which the path is.
+  ///
+  /// In a sense, the path can be treated as a list of edges. The
+  /// lemon path type stores just this list. As a consequence it
+  /// cannot enumerate the nodes in the path and the zero length paths
+  /// cannot store the source.
+  ///
+  /// This implementation is completly static, so it cannot be
+  /// modified exclude the assign an other path. It is intented to be
+  /// used when you want to store a large number of paths because it is
+  /// the most memory efficient path type in the lemon.
+  template <typename _Graph>
+  class StaticPath {
+  public:
+
+    typedef _Graph Graph;
+    typedef typename Graph::Edge Edge;
+
+    /// \brief Default constructor
+    ///
+    /// Default constructor
+    StaticPath() : len(0), edges(0) {}
+    
+    /// \brief Template copy constructor
+    ///
+    /// This path can be initialized with any other path type. It just
+    /// makes a copy of the given path.
+    template <typename CPath>
+    StaticPath(const CPath& cpath) : edges(0) {
+      copyPath(*this, cpath);
+    }
+
+    /// \brief Destructor of the path
+    ///
+    /// Destructor of the path
+    ~StaticPath() {
+      if (edges) delete[] edges;
+    }
+
+    /// \brief Template copy assignment
+    ///
+    /// This path can be initialized with any other path type. It just
+    /// makes a copy of the given path.
+    template <typename CPath>
+    StaticPath& operator=(const CPath& cpath) {
+      copyPath(*this, cpath);
+      return *this;
+    }
+
+    /// \brief Iterator class to iterate on the edges of the paths
+    ///
+    /// This class is used to iterate on the edges of the paths
+    ///
+    /// Of course it converts to Graph::Edge
+    class EdgeIt {
+      friend class StaticPath;
+    public:
+      /// Default constructor
+      EdgeIt() {}
+      /// Invalid constructor
+      EdgeIt(Invalid) : path(0), idx(-1) {}
+      /// Initializate the constructor to the first edge of path
+      EdgeIt(const StaticPath &_path) 
+        : path(&_path), idx(_path.empty() ? -1 : 0) {}
+
+    private:
+
+      /// Constructor with starting point
+      EdgeIt(const StaticPath &_path, int _idx) 
+        : idx(_idx), path(&_path) {}
+
+    public:
+
+      ///Conversion to Graph::Edge
+      operator const Edge&() const {
+        return path->nth(idx);
+      }
+
+      /// Next edge
+      EdgeIt& operator++() { 
+        ++idx;
+        if (idx >= path->length()) idx = -1; 
+        return *this; 
+      }
+
+      /// Comparison operator
+      bool operator==(const EdgeIt& e) const { return idx==e.idx; }
+      /// Comparison operator
+      bool operator!=(const EdgeIt& e) const { return idx!=e.idx; }
+      /// Comparison operator
+      bool operator<(const EdgeIt& e) const { return idx<e.idx; }
+
+    private:
+      const StaticPath *path;
+      int idx;
+    };
+
+    /// \brief Gives back the nth edge.
+    ///
+    /// \pre n is in the [0..length() - 1] range
+    const Edge& nth(int n) const {
+      return edges[n];
+    }
+
+    /// \brief Initializes edge iterator to point to the nth edge.
+    EdgeIt nthIt(int n) const {
+      return EdgeIt(*this, n);
+    }
+
+    /// \brief Gives back the length of the path.
+    int length() const { return len; }
+
+    /// \brief Returns true when the path is empty.
+    int empty() const { return len == 0; }
+
+    /// \break Erase all edge in the graph.
+    void clear() {
+      len = 0;
+      if (edges) delete[] edges;
+      edges = 0;
+    }
+
+    /// \brief Gives back the first edge of the path.
+    const Edge& front() const {
+      return edges[0];
+    }
+
+    /// \brief Gives back the last edge of the path.
+    const Edge& back() const {
+      return edges[len - 1];
+    }
+
+
+    typedef True BuildTag;
+
+    template <typename CPath>
+    void build(const CPath& path) {
+      len = path.length();
+      edges = new Edge[len];
+      int index = 0;
+      for (typename CPath::EdgeIt it(path); it != INVALID; ++it) {
+        edges[index] = it;
+        ++index;
+      }
+    }
+
+    template <typename CPath>
+    void buildRev(const CPath& path) {
+      len = path.length();
+      edges = new Edge[len];
+      int index = len;
+      for (typename CPath::RevEdgeIt it(path); it != INVALID; ++it) {
+        --index;
+        edges[index] = it;
+      }
+    }
+
+  private:
+    int len;
+    Edge* edges;
+  };
+
+  ///@}
+
+} // namespace lemon
+
+#endif // LEMON_PATH_H
Index: lemon/path_utils.h
===================================================================
--- lemon/path_utils.h	(revision 2553)
+++ lemon/path_utils.h	(revision 2553)
@@ -0,0 +1,394 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup paths
+///\file
+///\brief Classes for representing paths in graphs.
+///
+
+#ifndef LEMON_PATH_UTILS_H
+#define LEMON_PATH_UTILS_H
+
+#include <lemon/concepts/path.h>
+#include <lemon/lemon_reader.h>
+#include <lemon/lemon_writer.h>
+
+namespace lemon {
+
+  namespace _path_bits {
+
+    template <typename Path, typename Enable = void>
+    struct RevTagIndicator {
+      static const bool value = false;
+    };
+
+    template <typename Graph>
+    struct RevTagIndicator<
+      Graph, 
+      typename enable_if<typename Graph::RevTag, void>::type
+    > {
+      static const bool value = true;
+    };
+
+    template <typename Target, typename Source,
+              typename BuildEnable = void, typename RevEnable = void>
+    struct PathCopySelector {
+      static void copy(Target& target, const Source& source) {
+        target.clear();
+        for (typename Source::EdgeIt it(source); it != INVALID; ++it) {
+          target.addBack(it);
+        }
+      }
+    };
+
+    template <typename Target, typename Source, typename BuildEnable>
+    struct PathCopySelector<
+      Target, Source, BuildEnable, 
+      typename enable_if<typename Source::RevPathTag, void>::type> {
+      static void copy(Target& target, const Source& source) {
+        target.clear();
+        for (typename Source::RevEdgeIt it(source); it != INVALID; ++it) {
+          target.addFront(it);
+        }
+      }
+    };
+
+    template <typename Target, typename Source, typename RevEnable>
+    struct PathCopySelector<
+      Target, Source, 
+      typename enable_if<typename Target::BuildTag, void>::type, RevEnable> {
+      static void copy(Target& target, const Source& source) {
+        target.clear();
+        target.build(source);
+      }
+    };
+
+    template <typename Target, typename Source>
+    struct PathCopySelector<
+      Target, Source, 
+      typename enable_if<typename Target::BuildTag, void>::type,
+      typename enable_if<typename Source::RevPathTag, void>::type> {
+      static void copy(Target& target, const Source& source) {
+        target.clear();
+        target.buildRev(source);
+      }
+    };
+
+  }
+
+
+  /// \brief Make of copy of a path.
+  ///
+  ///  Make of copy of a path.
+  template <typename Target, typename Source>
+  void copyPath(Target& target, const Source& source) {
+    checkConcept<concepts::PathDumper<typename Source::Graph>, Source>();
+    _path_bits::PathCopySelector<Target, Source>::copy(target, source);
+  }
+
+  /// \brief Checks the path's consistency.
+  ///
+  /// Checks that each edge's target is the next's source. 
+  /// 
+  template <typename Graph, typename Path>
+  bool checkPath(const Graph& graph, const Path& path) {
+    typename Path::EdgeIt it(path);
+    if (it == INVALID) return true;
+    typename Graph::Node node = graph.target(it);
+    ++it;
+    while (it != INVALID) {
+      if (graph.source(it) != node) return false;
+      node = graph.target(it);
+      ++it;
+    }
+    return true;
+  }
+
+  /// \brief Gives back the source of the path
+  ///
+  /// Gives back the source of the path.
+  template <typename Graph, typename Path>
+  typename Graph::Node pathSource(const Graph& graph, const Path& path) {
+    return graph.source(path.front());
+  }
+
+  /// \brief Gives back the target of the path
+  ///
+  /// Gives back the target of the path.
+  template <typename Graph, typename Path>
+  typename Graph::Node pathTarget(const Graph& graph, const Path& path) {
+    return graph.target(path.back());
+  }
+
+  /// \brief Class which helps to iterate the nodes of a path
+  ///
+  /// In a sense, the path can be treated as a list of edges. The
+  /// lemon path type stores just this list. As a consequence it
+  /// cannot enumerate the nodes in the path and the zero length paths
+  /// cannot store the node.
+  ///
+  /// This class implements the node iterator of a path structure. To
+  /// provide this feature, the underlying graph should be given to
+  /// the constructor of the iterator.
+  template <typename Path>
+  class PathNodeIt {
+  private:
+    const typename Path::Graph *_graph;
+    typename Path::EdgeIt _it;
+    typename Path::Graph::Node _nd;
+
+  public:
+
+    typedef typename Path::Graph Graph;
+    typedef typename Graph::Node Node;
+    
+    /// Default constructor
+    PathNodeIt() {}
+    /// Invalid constructor
+    PathNodeIt(Invalid) 
+      : _graph(0), _it(INVALID), _nd(INVALID) {}
+    /// Constructor
+    PathNodeIt(const Graph& graph, const Path& path) 
+      : _graph(&graph), _it(path) {
+      _nd = (_it != INVALID ? _graph->source(_it) : INVALID);
+    }
+    /// Constructor
+    PathNodeIt(const Graph& graph, const Path& path, const Node& src) 
+      : _graph(&graph), _it(path), _nd(src) {}
+
+    ///Conversion to Graph::Node
+    operator Node() const {
+      return _nd;
+    }
+
+    /// Next node
+    PathNodeIt& operator++() {
+      if (_it == INVALID) _nd = INVALID;
+      else {
+	_nd = _graph->target(_it);
+	++_it;
+      }
+      return *this;
+    }
+
+    /// Comparison operator
+    bool operator==(const PathNodeIt& n) const { 
+      return _it == n._it && _nd == n._nd; 
+    }
+    /// Comparison operator
+    bool operator!=(const PathNodeIt& n) const { 
+      return _it != n._it || _nd != n._nd; 
+    }
+    /// Comparison operator
+    bool operator<(const PathNodeIt& n) const { 
+      return (_it < n._it && _nd != INVALID);
+    }
+    
+  };
+
+  /// \brief Item writer for paths
+  ///
+  /// This class can write paths into files. You can store paths in
+  /// distinict mapset or in attributes section.
+  ///
+  ///\code
+  /// GraphWriter<SmartGraph> gw(std::cout, g);
+  /// NodeMapWriter<SmartGraph> nmw(gw, g, gw);
+  ///
+  /// SmartGraph::NodeMap<Path<SmartGraph> > pnm(g);
+  /// for (SmartGraph::NodeIt n(g); n != INVALID; ++n) {
+  ///   pnm[n] = bfs.path(n);
+  /// }
+  /// nmw.writeNodeMap("pnm", pnm, PathWriter<Path<SmartGraph> >(gw));
+  ///
+  /// gw.run();
+  ///\endcode
+  ///
+  /// \warning Do not use this class to write node or edge map values
+  /// into usual nodesets or edgesets. You will not be able to read
+  /// back your paths. Rather use NodeMapWriter, EdgeSetWriter or
+  /// UEdgeSetWriter to dump paths from maps to lemon file.
+  template <typename Path>
+  class PathWriter {
+  private:
+
+    typedef typename Path::Edge Edge;
+    std::auto_ptr<_writer_bits::LabelWriterBase<Edge> > edgeLabelWriter;
+
+  public:
+
+    typedef Path Value;
+
+    PathWriter(const PathWriter& pw) {
+      edgeLabelWriter.reset(pw.edgeLabelWriter->clone());
+    }
+
+    /// \brief Constructor
+    ///
+    /// The paramter shold be an edge label writer which could
+    /// be a GraphWriter or an EdgeSetWriter. 
+    template <typename EdgeLabelWriter>
+    explicit PathWriter(const EdgeLabelWriter& _edgeLabelWriter) {
+      edgeLabelWriter.reset(new _writer_bits::
+	LabelWriter<Edge, EdgeLabelWriter>(_edgeLabelWriter));
+    }
+
+    /// \brief Writer function
+    ///
+    /// Writes the path to the current stream. The representation
+    /// is the edge labels beetween parentheses.
+    void write(std::ostream& os, const Value& value) const {
+      if (!edgeLabelWriter->isLabelWriter()) {
+	throw DataFormatError("Cannot find edgeset or label map");
+      }
+      os << '(' << ' ';
+      for (typename Path::EdgeIt e(value); e != INVALID; ++e) {
+	edgeLabelWriter->write(os, e);
+	os << ' ';
+      }
+      os << ')';
+    }
+    
+  };
+
+  namespace _path_bits {
+
+    template <typename _Graph>
+    class PathProxy {
+    public:
+      typedef False RevPathTag;
+
+      typedef _Graph Graph;
+      typedef typename Graph::Edge Edge;
+
+      PathProxy(const std::vector<Edge>& edges)
+	: _edges(edges) {}
+
+      int length() const {
+	return _edges.size();
+      }
+
+      bool empty() const {
+	return _edges.size() == 0;
+      }
+
+      class EdgeIt {
+      public:
+	EdgeIt() {}
+	EdgeIt(const PathProxy& path) 
+	  : _path(&path), _index(0) {}
+	
+	operator const Edge() const {
+	  return _path->_edges[_index];
+	}
+
+	EdgeIt& operator++() {
+	  ++_index;
+	  return *this;
+	}
+
+	bool operator==(Invalid) const { 
+	  return int(_path->_edges.size()) == _index; 
+	}
+	bool operator!=(Invalid) const { 
+	  return int(_path->_edges.size()) != _index; 
+	}
+
+      private:
+	const PathProxy* _path;
+	int _index;
+      };
+      
+    private:
+      const std::vector<Edge>& _edges;
+      
+    };
+
+  }
+
+  /// \brief Item reader for paths 
+  ///
+  /// This class can read paths from files. You can store paths in
+  /// distinict mapset or in attributes section.
+  ///
+  ///\code
+  /// GraphReader<SmartGraph> gr(std::cout, g);
+  /// NodeMapReader<SmartGraph> nmr(gr, g, gr);
+  ///
+  /// SmartGraph::NodeMap<Path<SmartGraph> > pnm(g);
+  /// nmr.readNodeMap("pnm", pnm, PathReader<Path<SmartGraph> >(gr));
+  ///
+  /// gr.run();
+  ///\endcode
+  ///
+  /// \warning Do not use this class to read node or edge map values
+  /// from nodesets or edgesets. The edges are not surely constructed
+  /// when the edge list should be read. Rather use NodeMapReader,
+  /// EdgeSetReader or UEdgeSetReader to read distinict map sets from file.
+  template <typename Path>
+  class PathReader {
+  private:
+
+    typedef typename Path::Edge Edge;
+    std::auto_ptr<_reader_bits::LabelReaderBase<Edge> > edgeLabelReader;
+
+  public:
+
+    typedef Path Value;
+
+    PathReader(const PathReader& pw) {
+      edgeLabelReader.reset(pw.edgeLabelReader->clone());
+    }
+
+    /// \brief Constructor
+    ///
+    /// The paramter shold be an edge label reader which could
+    /// be a GraphReader or an EdgeSetReader. 
+    template <typename EdgeLabelReader>
+    explicit PathReader(const EdgeLabelReader& _edgeLabelReader) {
+      edgeLabelReader.reset(new _reader_bits::
+	LabelReader<Edge, EdgeLabelReader>(_edgeLabelReader));
+    }
+
+
+    /// \brief Reader function
+    ///
+    /// Reads the path from the current stream. The representation
+    /// is the edge labels beetween parentheses.
+    void read(std::istream& is, Value& value) const {
+      if (!edgeLabelReader->isLabelReader()) {
+	throw DataFormatError("Cannot find edgeset or label map");
+      }
+      char c;
+      if (!(is >> c) || c != '(') 
+	throw DataFormatError("PathReader format error");
+      std::vector<typename Path::Edge> v;
+      while (is >> c && c != ')') {
+	is.putback(c);
+	Edge edge = edgeLabelReader->read(is);
+	v.push_back(edge);
+      }
+      if (!is) throw DataFormatError("PathReader format error");
+      copyPath(value, _path_bits::PathProxy<typename Path::Edge>(v));
+    }
+    
+  };
+  
+}
+
+#endif
Index: lemon/planarity.h
===================================================================
--- lemon/planarity.h	(revision 2598)
+++ lemon/planarity.h	(revision 2598)
@@ -0,0 +1,2740 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_PLANARITY_H
+#define LEMON_PLANARITY_H
+
+/// \ingroup planar
+/// \file
+/// \brief Planarity checking, embedding, drawing and coloring
+
+#include <vector>
+#include <list>
+
+#include <lemon/dfs.h>
+#include <lemon/bfs.h>
+#include <lemon/radix_sort.h>
+#include <lemon/maps.h>
+#include <lemon/path.h>
+#include <lemon/iterable_maps.h>
+#include <lemon/edge_set.h>
+#include <lemon/bucket_heap.h>
+#include <lemon/ugraph_adaptor.h>
+#include <lemon/color.h>
+
+
+namespace lemon {
+
+  namespace _planarity_bits {
+
+    template <typename UGraph>
+    struct PlanarityVisitor : DfsVisitor<UGraph> {
+
+      typedef typename UGraph::Node Node;
+      typedef typename UGraph::Edge Edge;
+
+      typedef typename UGraph::template NodeMap<Edge> PredMap;
+
+      typedef typename UGraph::template UEdgeMap<bool> TreeMap;
+
+      typedef typename UGraph::template NodeMap<int> OrderMap;
+      typedef std::vector<Node> OrderList;
+
+      typedef typename UGraph::template NodeMap<int> LowMap;
+      typedef typename UGraph::template NodeMap<int> AncestorMap;
+
+      PlanarityVisitor(const UGraph& ugraph,
+		       PredMap& pred_map, TreeMap& tree_map,
+		       OrderMap& order_map, OrderList& order_list,
+		       AncestorMap& ancestor_map, LowMap& low_map)
+	: _ugraph(ugraph), _pred_map(pred_map), _tree_map(tree_map),
+	  _order_map(order_map), _order_list(order_list),
+	  _ancestor_map(ancestor_map), _low_map(low_map) {}
+      
+      void reach(const Node& node) {
+	_order_map[node] = _order_list.size();
+	_low_map[node] = _order_list.size();
+	_ancestor_map[node] = _order_list.size();
+	_order_list.push_back(node);
+      }
+
+      void discover(const Edge& edge) {
+	Node source = _ugraph.source(edge);
+	Node target = _ugraph.target(edge);
+
+	_tree_map[edge] = true;
+	_pred_map[target] = edge;
+      }
+
+      void examine(const Edge& edge) {
+	Node source = _ugraph.source(edge);
+	Node target = _ugraph.target(edge);
+	
+	if (_order_map[target] < _order_map[source] && !_tree_map[edge]) {
+	  if (_low_map[source] > _order_map[target]) {
+	    _low_map[source] = _order_map[target];
+	  }
+	  if (_ancestor_map[source] > _order_map[target]) {
+	    _ancestor_map[source] = _order_map[target];
+	  }
+	}
+      }
+
+      void backtrack(const Edge& edge) {
+	Node source = _ugraph.source(edge);
+	Node target = _ugraph.target(edge);
+
+	if (_low_map[source] > _low_map[target]) {
+	  _low_map[source] = _low_map[target];
+	}
+      }
+
+      const UGraph& _ugraph;
+      PredMap& _pred_map;
+      TreeMap& _tree_map;
+      OrderMap& _order_map;
+      OrderList& _order_list;
+      AncestorMap& _ancestor_map;
+      LowMap& _low_map;
+    };
+
+    template <typename UGraph, bool embedding = true>
+    struct NodeDataNode {
+      int prev, next;
+      int visited;
+      typename UGraph::Edge first;
+      bool inverted;
+    };
+
+    template <typename UGraph>
+    struct NodeDataNode<UGraph, false> {
+      int prev, next;
+      int visited;
+    };
+
+    template <typename UGraph>
+    struct ChildListNode {
+      typedef typename UGraph::Node Node;
+      Node first;
+      Node prev, next;
+    };
+
+    template <typename UGraph>
+    struct EdgeListNode {
+      typename UGraph::Edge prev, next;
+    };
+
+  }
+
+  /// \ingroup planar
+  ///
+  /// \brief Planarity checking of an undirected simple graph
+  ///
+  /// This class implements the Boyer-Myrvold algorithm for planarity
+  /// checking of an undirected graph. This class is a simplified
+  /// version of the PlanarEmbedding algorithm class, and it does
+  /// provide neither embedding nor kuratowski subdivisons.
+  template <typename UGraph>
+  class PlanarityChecking {
+  private:
+    
+    UGRAPH_TYPEDEFS(typename UGraph);
+      
+    const UGraph& _ugraph;
+
+  private:
+
+    typedef typename UGraph::template NodeMap<Edge> PredMap;
+    
+    typedef typename UGraph::template UEdgeMap<bool> TreeMap;
+
+    typedef typename UGraph::template NodeMap<int> OrderMap;
+    typedef std::vector<Node> OrderList;
+
+    typedef typename UGraph::template NodeMap<int> LowMap;
+    typedef typename UGraph::template NodeMap<int> AncestorMap;
+
+    typedef _planarity_bits::NodeDataNode<UGraph> NodeDataNode;
+    typedef std::vector<NodeDataNode> NodeData;
+    
+    typedef _planarity_bits::ChildListNode<UGraph> ChildListNode;
+    typedef typename UGraph::template NodeMap<ChildListNode> ChildLists;
+
+    typedef typename UGraph::template NodeMap<std::list<int> > MergeRoots;
+ 
+    typedef typename UGraph::template NodeMap<bool> EmbedEdge;
+
+  public:
+
+    /// \brief Constructor
+    ///
+    /// \warining The graph should be simple, i.e. parallel and loop edge
+    /// free.
+    PlanarityChecking(const UGraph& ugraph) : _ugraph(ugraph) {}
+
+    /// \brief Runs the algorithm.
+    ///
+    /// Runs the algorithm.  
+    /// \return %True when the graph is planar.
+    bool run() {
+      typedef _planarity_bits::PlanarityVisitor<UGraph> Visitor;
+
+      PredMap pred_map(_ugraph, INVALID);
+      TreeMap tree_map(_ugraph, false);
+
+      OrderMap order_map(_ugraph, -1);
+      OrderList order_list;
+
+      AncestorMap ancestor_map(_ugraph, -1);
+      LowMap low_map(_ugraph, -1);
+
+      Visitor visitor(_ugraph, pred_map, tree_map,
+		      order_map, order_list, ancestor_map, low_map);
+      DfsVisit<UGraph, Visitor> visit(_ugraph, visitor);
+      visit.run();
+
+      ChildLists child_lists(_ugraph);
+      createChildLists(tree_map, order_map, low_map, child_lists);
+
+      NodeData node_data(2 * order_list.size());
+      
+      EmbedEdge embed_edge(_ugraph, false);
+
+      MergeRoots merge_roots(_ugraph);
+      
+      for (int i = order_list.size() - 1; i >= 0; --i) {
+
+	Node node = order_list[i];
+
+	Node source = node;
+	for (OutEdgeIt e(_ugraph, node); e != INVALID; ++e) {
+	  Node target = _ugraph.target(e);
+	  
+	  if (order_map[source] < order_map[target] && tree_map[e]) {
+	    initFace(target, node_data, order_map, order_list);
+	  }
+	}
+	
+	for (OutEdgeIt e(_ugraph, node); e != INVALID; ++e) {
+	  Node target = _ugraph.target(e);
+	  
+	  if (order_map[source] < order_map[target] && !tree_map[e]) {
+	    embed_edge[target] = true;
+	    walkUp(target, source, i, pred_map, low_map,
+		   order_map, order_list, node_data, merge_roots);
+	  }
+	}
+
+	for (typename MergeRoots::Value::iterator it = 
+	       merge_roots[node].begin(); it != merge_roots[node].end(); ++it) {
+	  int rn = *it;
+	  walkDown(rn, i, node_data, order_list, child_lists, 
+		   ancestor_map, low_map, embed_edge, merge_roots);
+	}
+	merge_roots[node].clear();
+	
+	for (OutEdgeIt e(_ugraph, node); e != INVALID; ++e) {
+	  Node target = _ugraph.target(e);
+	  
+	  if (order_map[source] < order_map[target] && !tree_map[e]) {
+	    if (embed_edge[target]) {
+	      return false;
+	    }
+	  }
+	}
+      }
+
+      return true;
+    }
+    
+  private:
+
+    void createChildLists(const TreeMap& tree_map, const OrderMap& order_map,
+			  const LowMap& low_map, ChildLists& child_lists) {
+
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	Node source = n;
+	
+	std::vector<Node> targets;  
+	for (OutEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node target = _ugraph.target(e);
+
+	  if (order_map[source] < order_map[target] && tree_map[e]) {
+	    targets.push_back(target);
+	  }
+	}	
+
+	if (targets.size() == 0) {
+	  child_lists[source].first = INVALID;
+	} else if (targets.size() == 1) {
+	  child_lists[source].first = targets[0];
+	  child_lists[targets[0]].prev = INVALID;
+	  child_lists[targets[0]].next = INVALID;
+	} else {
+	  radixSort(targets.begin(), targets.end(), mapFunctor(low_map));
+	  for (int i = 1; i < int(targets.size()); ++i) {
+	    child_lists[targets[i]].prev = targets[i - 1];
+	    child_lists[targets[i - 1]].next = targets[i];
+	  }
+	  child_lists[targets.back()].next = INVALID; 
+	  child_lists[targets.front()].prev = INVALID;
+	  child_lists[source].first = targets.front();
+	}
+      }
+    }
+
+    void walkUp(const Node& node, Node root, int rorder,
+		const PredMap& pred_map, const LowMap& low_map,
+		const OrderMap& order_map, const OrderList& order_list,
+		NodeData& node_data, MergeRoots& merge_roots) {
+
+      int na, nb;
+      bool da, db;
+      
+      na = nb = order_map[node];
+      da = true; db = false;
+      
+      while (true) {
+	
+	if (node_data[na].visited == rorder) break;
+	if (node_data[nb].visited == rorder) break;
+
+	node_data[na].visited = rorder;
+	node_data[nb].visited = rorder;
+
+	int rn = -1;
+
+	if (na >= int(order_list.size())) {
+	  rn = na;
+	} else if (nb >= int(order_list.size())) {
+	  rn = nb;
+	}
+
+	if (rn == -1) {
+	  int nn;
+	  
+	  nn = da ? node_data[na].prev : node_data[na].next;
+	  da = node_data[nn].prev != na;
+	  na = nn;
+	  
+	  nn = db ? node_data[nb].prev : node_data[nb].next;
+	  db = node_data[nn].prev != nb;
+	  nb = nn;
+
+	} else {
+
+	  Node rep = order_list[rn - order_list.size()];
+	  Node parent = _ugraph.source(pred_map[rep]);
+
+	  if (low_map[rep] < rorder) {
+	    merge_roots[parent].push_back(rn);
+	  } else {
+	    merge_roots[parent].push_front(rn);
+	  }
+	  
+	  if (parent != root) {  
+	    na = nb = order_map[parent];
+	    da = true; db = false;
+	  } else {
+	    break;
+	  }
+	}	
+      }
+    }
+
+    void walkDown(int rn, int rorder, NodeData& node_data,
+		  OrderList& order_list, ChildLists& child_lists,
+		  AncestorMap& ancestor_map, LowMap& low_map,
+		  EmbedEdge& embed_edge, MergeRoots& merge_roots) {
+
+      std::vector<std::pair<int, bool> > merge_stack;
+
+      for (int di = 0; di < 2; ++di) {
+	bool rd = di == 0;
+	int pn = rn;
+	int n = rd ? node_data[rn].next : node_data[rn].prev;
+	
+	while (n != rn) {
+	  
+	  Node node = order_list[n];
+	  
+	  if (embed_edge[node]) {
+
+	    // Merging components on the critical path
+	    while (!merge_stack.empty()) {
+
+	      // Component root
+	      int cn = merge_stack.back().first;
+	      bool cd = merge_stack.back().second;
+	      merge_stack.pop_back();
+
+	      // Parent of component
+	      int dn = merge_stack.back().first;
+	      bool dd = merge_stack.back().second;
+	      merge_stack.pop_back();
+
+	      Node parent = order_list[dn];
+
+	      // Erasing from merge_roots
+	      merge_roots[parent].pop_front();
+	      
+	      Node child = order_list[cn - order_list.size()];
+
+	      // Erasing from child_lists
+	      if (child_lists[child].prev != INVALID) {
+		child_lists[child_lists[child].prev].next =
+		  child_lists[child].next;
+	      } else {
+		child_lists[parent].first = child_lists[child].next;
+	      }
+	      
+	      if (child_lists[child].next != INVALID) {
+		child_lists[child_lists[child].next].prev =
+		  child_lists[child].prev;
+	      }
+	      
+	      // Merging external faces
+	      {
+		int en = cn;
+		cn = cd ? node_data[cn].prev : node_data[cn].next;
+		cd = node_data[cn].next == en;
+
+	      }
+
+	      if (cd) node_data[cn].next = dn; else node_data[cn].prev = dn;
+	      if (dd) node_data[dn].prev = cn; else node_data[dn].next = cn;
+
+	    }
+
+	    bool d = pn == node_data[n].prev;
+
+	    if (node_data[n].prev == node_data[n].next && 
+		node_data[n].inverted) {
+	      d = !d;
+	    }
+
+	    // Embedding edge into external face
+	    if (rd) node_data[rn].next = n; else node_data[rn].prev = n;
+	    if (d) node_data[n].prev = rn; else node_data[n].next = rn;
+	    pn = rn;
+
+	    embed_edge[order_list[n]] = false;
+	  }
+
+	  if (!merge_roots[node].empty()) {
+
+	    bool d = pn == node_data[n].prev;
+
+	    merge_stack.push_back(std::make_pair(n, d));
+
+	    int rn = merge_roots[node].front();
+	    
+	    int xn = node_data[rn].next;
+	    Node xnode = order_list[xn];
+	    
+	    int yn = node_data[rn].prev;
+	    Node ynode = order_list[yn];
+	    
+	    bool rd;
+	    if (!external(xnode, rorder, child_lists, ancestor_map, low_map)) {
+	      rd = true;
+	    } else if (!external(ynode, rorder, child_lists, 
+				 ancestor_map, low_map)) {
+	      rd = false;
+	    } else if (pertinent(xnode, embed_edge, merge_roots)) {
+	      rd = true;
+	    } else {
+	      rd = false;
+	    }
+	    
+	    merge_stack.push_back(std::make_pair(rn, rd));
+	    
+	    pn = rn;
+	    n = rd ? xn : yn;	      
+	    	    
+	  } else if (!external(node, rorder, child_lists,
+			       ancestor_map, low_map)) {
+	    int nn = (node_data[n].next != pn ? 
+		      node_data[n].next : node_data[n].prev);
+
+	    bool nd = n == node_data[nn].prev;
+
+	    if (nd) node_data[nn].prev = pn;
+	    else node_data[nn].next = pn; 
+
+	    if (n == node_data[pn].prev) node_data[pn].prev = nn;
+	    else node_data[pn].next = nn;
+
+	    node_data[nn].inverted = 
+	      (node_data[nn].prev == node_data[nn].next && nd != rd);
+
+	    n = nn;
+	  }
+	  else break;
+	  
+	}
+
+	if (!merge_stack.empty() || n == rn) {
+	  break;
+	}
+      }
+    }
+
+    void initFace(const Node& node, NodeData& node_data, 
+		  const OrderMap& order_map, const OrderList& order_list) {
+      int n = order_map[node];
+      int rn = n + order_list.size();
+      
+      node_data[n].next = node_data[n].prev = rn;
+      node_data[rn].next = node_data[rn].prev = n;
+      
+      node_data[n].visited = order_list.size();
+      node_data[rn].visited = order_list.size();
+      
+    }
+
+    bool external(const Node& node, int rorder,
+		  ChildLists& child_lists, AncestorMap& ancestor_map, 
+		  LowMap& low_map) {
+      Node child = child_lists[node].first;
+
+      if (child != INVALID) {
+	if (low_map[child] < rorder) return true;
+      }
+
+      if (ancestor_map[node] < rorder) return true;
+
+      return false;
+    }
+
+    bool pertinent(const Node& node, const EmbedEdge& embed_edge,
+		   const MergeRoots& merge_roots) {
+      return !merge_roots[node].empty() || embed_edge[node];
+    }
+
+  };
+
+  /// \ingroup planar
+  ///
+  /// \brief Planar embedding of an undirected simple graph
+  ///
+  /// This class implements the Boyer-Myrvold algorithm for planar
+  /// embedding of an undirected graph. The planar embeding is an
+  /// ordering of the outgoing edges in each node, which is a possible
+  /// configuration to draw the graph in the plane. If there is not
+  /// such ordering then the graph contains a \f$ K_5 \f$ (full graph
+  /// with 5 nodes) or an \f$ K_{3,3} \f$ (complete bipartite graph on
+  /// 3 ANode and 3 BNode) subdivision.
+  ///
+  /// The current implementation calculates an embedding or an
+  /// Kuratowski subdivision if the graph is not planar. The running
+  /// time of the algorithm is \f$ O(n) \f$.
+  template <typename UGraph>
+  class PlanarEmbedding {
+  private:
+    
+    UGRAPH_TYPEDEFS(typename UGraph);
+      
+    const UGraph& _ugraph;
+    typename UGraph::template EdgeMap<Edge> _embedding;
+
+    typename UGraph::template UEdgeMap<bool> _kuratowski;
+
+  private:
+
+    typedef typename UGraph::template NodeMap<Edge> PredMap;
+    
+    typedef typename UGraph::template UEdgeMap<bool> TreeMap;
+
+    typedef typename UGraph::template NodeMap<int> OrderMap;
+    typedef std::vector<Node> OrderList;
+
+    typedef typename UGraph::template NodeMap<int> LowMap;
+    typedef typename UGraph::template NodeMap<int> AncestorMap;
+
+    typedef _planarity_bits::NodeDataNode<UGraph> NodeDataNode;
+    typedef std::vector<NodeDataNode> NodeData;
+    
+    typedef _planarity_bits::ChildListNode<UGraph> ChildListNode;
+    typedef typename UGraph::template NodeMap<ChildListNode> ChildLists;
+
+    typedef typename UGraph::template NodeMap<std::list<int> > MergeRoots;
+ 
+    typedef typename UGraph::template NodeMap<Edge> EmbedEdge;
+
+    typedef _planarity_bits::EdgeListNode<UGraph> EdgeListNode;
+    typedef typename UGraph::template EdgeMap<EdgeListNode> EdgeLists;
+
+    typedef typename UGraph::template NodeMap<bool> FlipMap;
+
+    typedef typename UGraph::template NodeMap<int> TypeMap;
+
+    enum IsolatorNodeType {
+      HIGHX = 6, LOWX = 7,
+      HIGHY = 8, LOWY = 9,
+      ROOT = 10, PERTINENT = 11,
+      INTERNAL = 12
+    };
+
+  public:
+
+    /// \brief The map for store of embedding
+    typedef typename UGraph::template EdgeMap<Edge> EmbeddingMap;
+
+    /// \brief Constructor
+    ///
+    /// \warining The graph should be simple, i.e. parallel and loop edge
+    /// free.
+    PlanarEmbedding(const UGraph& ugraph)
+      : _ugraph(ugraph), _embedding(_ugraph), _kuratowski(ugraph, false) {}
+
+    /// \brief Runs the algorithm.
+    ///
+    /// Runs the algorithm.  
+    /// \param kuratowski If the parameter is false, then the
+    /// algorithm does not calculate the isolate Kuratowski
+    /// subdivisions.
+    ///\return %True when the graph is planar.
+    bool run(bool kuratowski = true) {
+      typedef _planarity_bits::PlanarityVisitor<UGraph> Visitor;
+
+      PredMap pred_map(_ugraph, INVALID);
+      TreeMap tree_map(_ugraph, false);
+
+      OrderMap order_map(_ugraph, -1);
+      OrderList order_list;
+
+      AncestorMap ancestor_map(_ugraph, -1);
+      LowMap low_map(_ugraph, -1);
+
+      Visitor visitor(_ugraph, pred_map, tree_map,
+		      order_map, order_list, ancestor_map, low_map);
+      DfsVisit<UGraph, Visitor> visit(_ugraph, visitor);
+      visit.run();
+
+      ChildLists child_lists(_ugraph);
+      createChildLists(tree_map, order_map, low_map, child_lists);
+
+      NodeData node_data(2 * order_list.size());
+      
+      EmbedEdge embed_edge(_ugraph, INVALID);
+
+      MergeRoots merge_roots(_ugraph);
+
+      EdgeLists edge_lists(_ugraph);
+
+      FlipMap flip_map(_ugraph, false);
+
+      for (int i = order_list.size() - 1; i >= 0; --i) {
+
+	Node node = order_list[i];
+
+	node_data[i].first = INVALID;
+	
+	Node source = node;
+	for (OutEdgeIt e(_ugraph, node); e != INVALID; ++e) {
+	  Node target = _ugraph.target(e);
+	  
+	  if (order_map[source] < order_map[target] && tree_map[e]) {
+	    initFace(target, edge_lists, node_data,
+		      pred_map, order_map, order_list);
+	  }
+	}
+	
+	for (OutEdgeIt e(_ugraph, node); e != INVALID; ++e) {
+	  Node target = _ugraph.target(e);
+	  
+	  if (order_map[source] < order_map[target] && !tree_map[e]) {
+	    embed_edge[target] = e;
+	    walkUp(target, source, i, pred_map, low_map,
+		   order_map, order_list, node_data, merge_roots);
+	  }
+	}
+
+	for (typename MergeRoots::Value::iterator it = 
+	       merge_roots[node].begin(); it != merge_roots[node].end(); ++it) {
+	  int rn = *it;
+	  walkDown(rn, i, node_data, edge_lists, flip_map, order_list, 
+		   child_lists, ancestor_map, low_map, embed_edge, merge_roots);
+	}
+	merge_roots[node].clear();
+	
+	for (OutEdgeIt e(_ugraph, node); e != INVALID; ++e) {
+	  Node target = _ugraph.target(e);
+	  
+	  if (order_map[source] < order_map[target] && !tree_map[e]) {
+	    if (embed_edge[target] != INVALID) {
+	      if (kuratowski) {
+		isolateKuratowski(e, node_data, edge_lists, flip_map,
+				  order_map, order_list, pred_map, child_lists,
+				  ancestor_map, low_map, 
+				  embed_edge, merge_roots);
+	      }
+	      return false;
+	    }
+	  }
+	}
+      }
+
+      for (int i = 0; i < int(order_list.size()); ++i) {
+
+	mergeRemainingFaces(order_list[i], node_data, order_list, order_map,
+			    child_lists, edge_lists);
+	storeEmbedding(order_list[i], node_data, order_map, pred_map,
+		       edge_lists, flip_map);
+      }
+
+      return true;
+    }
+
+    /// \brief Gives back the successor of an edge
+    ///
+    /// Gives back the successor of an edge. This function makes
+    /// possible to query the cyclic order of the outgoing edges from
+    /// a node.
+    Edge next(const Edge& edge) const {
+      return _embedding[edge];
+    }
+
+    /// \brief Gives back the calculated embedding map
+    ///
+    /// The returned map contains the successor of each edge in the
+    /// graph.
+    const EmbeddingMap& embedding() const {
+      return _embedding;
+    }
+
+    /// \brief Gives back true when the undirected edge is in the
+    /// kuratowski subdivision
+    ///
+    /// Gives back true when the undirected edge is in the kuratowski
+    /// subdivision
+    bool kuratowski(const UEdge& uedge) {
+      return _kuratowski[uedge];
+    }
+
+  private:
+
+    void createChildLists(const TreeMap& tree_map, const OrderMap& order_map,
+			  const LowMap& low_map, ChildLists& child_lists) {
+
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	Node source = n;
+	
+	std::vector<Node> targets;  
+	for (OutEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node target = _ugraph.target(e);
+
+	  if (order_map[source] < order_map[target] && tree_map[e]) {
+	    targets.push_back(target);
+	  }
+	}	
+
+	if (targets.size() == 0) {
+	  child_lists[source].first = INVALID;
+	} else if (targets.size() == 1) {
+	  child_lists[source].first = targets[0];
+	  child_lists[targets[0]].prev = INVALID;
+	  child_lists[targets[0]].next = INVALID;
+	} else {
+	  radixSort(targets.begin(), targets.end(), mapFunctor(low_map));
+	  for (int i = 1; i < int(targets.size()); ++i) {
+	    child_lists[targets[i]].prev = targets[i - 1];
+	    child_lists[targets[i - 1]].next = targets[i];
+	  }
+	  child_lists[targets.back()].next = INVALID; 
+	  child_lists[targets.front()].prev = INVALID;
+	  child_lists[source].first = targets.front();
+	}
+      }
+    }
+
+    void walkUp(const Node& node, Node root, int rorder,
+		const PredMap& pred_map, const LowMap& low_map,
+		const OrderMap& order_map, const OrderList& order_list,
+		NodeData& node_data, MergeRoots& merge_roots) {
+
+      int na, nb;
+      bool da, db;
+      
+      na = nb = order_map[node];
+      da = true; db = false;
+      
+      while (true) {
+	
+	if (node_data[na].visited == rorder) break;
+	if (node_data[nb].visited == rorder) break;
+
+	node_data[na].visited = rorder;
+	node_data[nb].visited = rorder;
+
+	int rn = -1;
+
+	if (na >= int(order_list.size())) {
+	  rn = na;
+	} else if (nb >= int(order_list.size())) {
+	  rn = nb;
+	}
+
+	if (rn == -1) {
+	  int nn;
+	  
+	  nn = da ? node_data[na].prev : node_data[na].next;
+	  da = node_data[nn].prev != na;
+	  na = nn;
+	  
+	  nn = db ? node_data[nb].prev : node_data[nb].next;
+	  db = node_data[nn].prev != nb;
+	  nb = nn;
+
+	} else {
+
+	  Node rep = order_list[rn - order_list.size()];
+	  Node parent = _ugraph.source(pred_map[rep]);
+
+	  if (low_map[rep] < rorder) {
+	    merge_roots[parent].push_back(rn);
+	  } else {
+	    merge_roots[parent].push_front(rn);
+	  }
+	  
+	  if (parent != root) {  
+	    na = nb = order_map[parent];
+	    da = true; db = false;
+	  } else {
+	    break;
+	  }
+	}	
+      }
+    }
+
+    void walkDown(int rn, int rorder, NodeData& node_data,
+		  EdgeLists& edge_lists, FlipMap& flip_map, 
+		  OrderList& order_list, ChildLists& child_lists,
+		  AncestorMap& ancestor_map, LowMap& low_map,
+		  EmbedEdge& embed_edge, MergeRoots& merge_roots) {
+
+      std::vector<std::pair<int, bool> > merge_stack;
+
+      for (int di = 0; di < 2; ++di) {
+	bool rd = di == 0;
+	int pn = rn;
+	int n = rd ? node_data[rn].next : node_data[rn].prev;
+	
+	while (n != rn) {
+	  
+	  Node node = order_list[n];
+	  
+	  if (embed_edge[node] != INVALID) {
+
+	    // Merging components on the critical path
+	    while (!merge_stack.empty()) {
+
+	      // Component root
+	      int cn = merge_stack.back().first;
+	      bool cd = merge_stack.back().second;
+	      merge_stack.pop_back();
+
+	      // Parent of component
+	      int dn = merge_stack.back().first;
+	      bool dd = merge_stack.back().second;
+	      merge_stack.pop_back();
+
+	      Node parent = order_list[dn];
+
+	      // Erasing from merge_roots
+	      merge_roots[parent].pop_front();
+	      
+	      Node child = order_list[cn - order_list.size()];
+
+	      // Erasing from child_lists
+	      if (child_lists[child].prev != INVALID) {
+		child_lists[child_lists[child].prev].next =
+		  child_lists[child].next;
+	      } else {
+		child_lists[parent].first = child_lists[child].next;
+	      }
+	      
+	      if (child_lists[child].next != INVALID) {
+		child_lists[child_lists[child].next].prev =
+		  child_lists[child].prev;
+	      }
+
+	      // Merging edges + flipping
+	      Edge de = node_data[dn].first;
+	      Edge ce = node_data[cn].first;
+
+	      flip_map[order_list[cn - order_list.size()]] = cd != dd;
+	      if (cd != dd) {
+		std::swap(edge_lists[ce].prev, edge_lists[ce].next);
+		ce = edge_lists[ce].prev;
+		std::swap(edge_lists[ce].prev, edge_lists[ce].next);
+	      }
+
+	      {
+		Edge dne = edge_lists[de].next; 
+		Edge cne = edge_lists[ce].next; 
+
+		edge_lists[de].next = cne;
+		edge_lists[ce].next = dne;
+	      
+		edge_lists[dne].prev = ce;
+		edge_lists[cne].prev = de;
+	      }
+	      	      
+	      if (dd) {
+		node_data[dn].first = ce;
+	      }
+	      
+	      // Merging external faces
+	      {
+		int en = cn;
+		cn = cd ? node_data[cn].prev : node_data[cn].next;
+		cd = node_data[cn].next == en;
+
+ 		if (node_data[cn].prev == node_data[cn].next && 
+		    node_data[cn].inverted) {
+ 		  cd = !cd;
+ 		}
+	      }
+
+	      if (cd) node_data[cn].next = dn; else node_data[cn].prev = dn;
+	      if (dd) node_data[dn].prev = cn; else node_data[dn].next = cn;
+
+	    }
+
+	    bool d = pn == node_data[n].prev;
+
+	    if (node_data[n].prev == node_data[n].next && 
+		node_data[n].inverted) {
+	      d = !d;
+	    }
+
+	    // Add new edge
+	    {
+	      Edge edge = embed_edge[node];
+	      Edge re = node_data[rn].first;
+
+	      edge_lists[edge_lists[re].next].prev = edge;
+	      edge_lists[edge].next = edge_lists[re].next;
+	      edge_lists[edge].prev = re;
+	      edge_lists[re].next = edge;
+
+	      if (!rd) {
+		node_data[rn].first = edge;
+	      }
+
+	      Edge rev = _ugraph.oppositeEdge(edge);
+	      Edge e = node_data[n].first;
+
+	      edge_lists[edge_lists[e].next].prev = rev;
+	      edge_lists[rev].next = edge_lists[e].next;
+	      edge_lists[rev].prev = e;
+	      edge_lists[e].next = rev;
+
+	      if (d) {
+		node_data[n].first = rev;
+	      }
+	      
+	    }
+
+	    // Embedding edge into external face
+	    if (rd) node_data[rn].next = n; else node_data[rn].prev = n;
+	    if (d) node_data[n].prev = rn; else node_data[n].next = rn;
+	    pn = rn;
+
+	    embed_edge[order_list[n]] = INVALID;
+	  }
+
+	  if (!merge_roots[node].empty()) {
+
+	    bool d = pn == node_data[n].prev;
+	    if (node_data[n].prev == node_data[n].next && 
+		node_data[n].inverted) {
+	      d = !d;
+	    }
+
+	    merge_stack.push_back(std::make_pair(n, d));
+
+	    int rn = merge_roots[node].front();
+	    
+	    int xn = node_data[rn].next;
+	    Node xnode = order_list[xn];
+	    
+	    int yn = node_data[rn].prev;
+	    Node ynode = order_list[yn];
+	    
+	    bool rd;
+	    if (!external(xnode, rorder, child_lists, ancestor_map, low_map)) {
+	      rd = true;
+	    } else if (!external(ynode, rorder, child_lists, 
+				 ancestor_map, low_map)) {
+	      rd = false;
+	    } else if (pertinent(xnode, embed_edge, merge_roots)) {
+	      rd = true;
+	    } else {
+	      rd = false;
+	    }
+	    
+	    merge_stack.push_back(std::make_pair(rn, rd));
+	    
+	    pn = rn;
+	    n = rd ? xn : yn;	      
+	    	    
+	  } else if (!external(node, rorder, child_lists,
+			       ancestor_map, low_map)) {
+	    int nn = (node_data[n].next != pn ? 
+		      node_data[n].next : node_data[n].prev);
+
+	    bool nd = n == node_data[nn].prev;
+
+	    if (nd) node_data[nn].prev = pn;
+	    else node_data[nn].next = pn; 
+
+	    if (n == node_data[pn].prev) node_data[pn].prev = nn;
+	    else node_data[pn].next = nn;
+
+	    node_data[nn].inverted = 
+	      (node_data[nn].prev == node_data[nn].next && nd != rd);
+
+	    n = nn;
+	  }
+	  else break;
+	  
+	}
+
+	if (!merge_stack.empty() || n == rn) {
+	  break;
+	}
+      }
+    }
+
+    void initFace(const Node& node, EdgeLists& edge_lists,
+		   NodeData& node_data, const PredMap& pred_map,
+		   const OrderMap& order_map, const OrderList& order_list) {
+      int n = order_map[node];
+      int rn = n + order_list.size();
+      
+      node_data[n].next = node_data[n].prev = rn;
+      node_data[rn].next = node_data[rn].prev = n;
+      
+      node_data[n].visited = order_list.size();
+      node_data[rn].visited = order_list.size();
+
+      node_data[n].inverted = false;
+      node_data[rn].inverted = false;
+
+      Edge edge = pred_map[node];
+      Edge rev = _ugraph.oppositeEdge(edge);
+
+      node_data[rn].first = edge;
+      node_data[n].first = rev;
+
+      edge_lists[edge].prev = edge;
+      edge_lists[edge].next = edge;
+
+      edge_lists[rev].prev = rev;
+      edge_lists[rev].next = rev;
+
+    }
+
+    void mergeRemainingFaces(const Node& node, NodeData& node_data,
+			     OrderList& order_list, OrderMap& order_map,
+			     ChildLists& child_lists, EdgeLists& edge_lists) {
+      while (child_lists[node].first != INVALID) {
+	int dd = order_map[node];
+	Node child = child_lists[node].first; 
+	int cd = order_map[child] + order_list.size();
+	child_lists[node].first = child_lists[child].next;
+
+	Edge de = node_data[dd].first;
+	Edge ce = node_data[cd].first;
+
+	if (de != INVALID) {
+	  Edge dne = edge_lists[de].next; 
+	  Edge cne = edge_lists[ce].next; 
+	  
+	  edge_lists[de].next = cne;
+	  edge_lists[ce].next = dne;
+	  
+	  edge_lists[dne].prev = ce;
+	  edge_lists[cne].prev = de;
+	}
+	
+	node_data[dd].first = ce;
+
+      }
+    }
+
+    void storeEmbedding(const Node& node, NodeData& node_data,
+			OrderMap& order_map, PredMap& pred_map,
+			EdgeLists& edge_lists, FlipMap& flip_map) {
+
+      if (node_data[order_map[node]].first == INVALID) return;
+
+      if (pred_map[node] != INVALID) {
+	Node source = _ugraph.source(pred_map[node]);
+	flip_map[node] = flip_map[node] != flip_map[source];
+      }
+      
+      Edge first = node_data[order_map[node]].first;
+      Edge prev = first;
+
+      Edge edge = flip_map[node] ?
+	edge_lists[prev].prev : edge_lists[prev].next;
+
+      _embedding[prev] = edge;
+      
+      while (edge != first) {
+	Edge next = edge_lists[edge].prev == prev ?
+	  edge_lists[edge].next : edge_lists[edge].prev;
+	prev = edge; edge = next;
+	_embedding[prev] = edge;
+      }
+    }
+
+
+    bool external(const Node& node, int rorder,
+		  ChildLists& child_lists, AncestorMap& ancestor_map, 
+		  LowMap& low_map) {
+      Node child = child_lists[node].first;
+
+      if (child != INVALID) {
+	if (low_map[child] < rorder) return true;
+      }
+
+      if (ancestor_map[node] < rorder) return true;
+
+      return false;
+    }
+
+    bool pertinent(const Node& node, const EmbedEdge& embed_edge,
+		   const MergeRoots& merge_roots) {
+      return !merge_roots[node].empty() || embed_edge[node] != INVALID;
+    }
+
+    int lowPoint(const Node& node, OrderMap& order_map, ChildLists& child_lists,
+		 AncestorMap& ancestor_map, LowMap& low_map) {
+      int low_point;
+
+      Node child = child_lists[node].first;
+
+      if (child != INVALID) {
+	low_point = low_map[child];
+      } else {
+	low_point = order_map[node];
+      }
+
+      if (low_point > ancestor_map[node]) {
+	low_point = ancestor_map[node];
+      }
+
+      return low_point;
+    }
+
+    int findComponentRoot(Node root, Node node, ChildLists& child_lists, 
+			  OrderMap& order_map, OrderList& order_list) {
+
+      int order = order_map[root];
+      int norder = order_map[node];
+
+      Node child = child_lists[root].first;
+      while (child != INVALID) {
+	int corder = order_map[child];
+	if (corder > order && corder < norder) {
+	  order = corder;
+	}
+	child = child_lists[child].next;
+      }
+      return order + order_list.size();
+    }
+
+    Node findPertinent(Node node, OrderMap& order_map, NodeData& node_data,
+		       EmbedEdge& embed_edge, MergeRoots& merge_roots) {
+      Node wnode =_ugraph.target(node_data[order_map[node]].first);
+      while (!pertinent(wnode, embed_edge, merge_roots)) {
+	wnode = _ugraph.target(node_data[order_map[wnode]].first);
+      }
+      return wnode;
+    }
+
+
+    Node findExternal(Node node, int rorder, OrderMap& order_map, 
+		      ChildLists& child_lists, AncestorMap& ancestor_map,
+		      LowMap& low_map, NodeData& node_data) {
+      Node wnode =_ugraph.target(node_data[order_map[node]].first);
+      while (!external(wnode, rorder, child_lists, ancestor_map, low_map)) {
+	wnode = _ugraph.target(node_data[order_map[wnode]].first);
+      }
+      return wnode;
+    }
+
+    void markCommonPath(Node node, int rorder, Node& wnode, Node& znode, 
+			OrderList& order_list, OrderMap& order_map, 
+			NodeData& node_data, EdgeLists& edge_lists, 
+			EmbedEdge& embed_edge, MergeRoots& merge_roots, 
+			ChildLists& child_lists, AncestorMap& ancestor_map, 
+			LowMap& low_map) {
+      
+      Node cnode = node;
+      Node pred = INVALID;
+      
+      while (true) {
+
+	bool pert = pertinent(cnode, embed_edge, merge_roots);
+	bool ext = external(cnode, rorder, child_lists, ancestor_map, low_map);
+
+	if (pert && ext) {
+	  if (!merge_roots[cnode].empty()) {
+	    int cn = merge_roots[cnode].back();
+	    
+	    if (low_map[order_list[cn - order_list.size()]] < rorder) {
+	      Edge edge = node_data[cn].first;
+	      _kuratowski.set(edge, true);
+	      
+	      pred = cnode;
+	      cnode = _ugraph.target(edge);
+	    
+	      continue;
+	    }
+	  }
+	  wnode = znode = cnode;
+	  return;
+
+	} else if (pert) {
+	  wnode = cnode;
+	  
+	  while (!external(cnode, rorder, child_lists, ancestor_map, low_map)) {
+	    Edge edge = node_data[order_map[cnode]].first;
+	  
+	    if (_ugraph.target(edge) == pred) {
+	      edge = edge_lists[edge].next;
+	    }
+	    _kuratowski.set(edge, true);
+	    
+	    Node next = _ugraph.target(edge);
+	    pred = cnode; cnode = next;
+	  }
+	  
+	  znode = cnode;
+	  return;
+
+	} else if (ext) {
+	  znode = cnode;
+	  
+	  while (!pertinent(cnode, embed_edge, merge_roots)) {
+	    Edge edge = node_data[order_map[cnode]].first;
+	  
+	    if (_ugraph.target(edge) == pred) {
+	      edge = edge_lists[edge].next;
+	    }
+	    _kuratowski.set(edge, true);
+	    
+	    Node next = _ugraph.target(edge);
+	    pred = cnode; cnode = next;
+	  }
+	  
+	  wnode = cnode;
+	  return;
+	  
+	} else {
+	  Edge edge = node_data[order_map[cnode]].first;
+	  
+	  if (_ugraph.target(edge) == pred) {
+	    edge = edge_lists[edge].next;
+	  }
+	  _kuratowski.set(edge, true);
+
+	  Node next = _ugraph.target(edge);
+	  pred = cnode; cnode = next;
+	}
+	
+      }
+
+    }
+
+    void orientComponent(Node root, int rn, OrderMap& order_map,
+			 PredMap& pred_map, NodeData& node_data, 
+			 EdgeLists& edge_lists, FlipMap& flip_map, 
+			 TypeMap& type_map) {
+      node_data[order_map[root]].first = node_data[rn].first;
+      type_map[root] = 1;
+
+      std::vector<Node> st, qu;
+
+      st.push_back(root);
+      while (!st.empty()) {
+	Node node = st.back();
+	st.pop_back();
+	qu.push_back(node);
+	
+	Edge edge = node_data[order_map[node]].first;
+	
+	if (type_map[_ugraph.target(edge)] == 0) {
+	  st.push_back(_ugraph.target(edge));
+	  type_map[_ugraph.target(edge)] = 1;
+	} 
+	
+	Edge last = edge, pred = edge;
+	edge = edge_lists[edge].next;
+	while (edge != last) {
+
+	  if (type_map[_ugraph.target(edge)] == 0) {
+	    st.push_back(_ugraph.target(edge));
+	    type_map[_ugraph.target(edge)] = 1;
+	  } 
+	  
+	  Edge next = edge_lists[edge].next != pred ? 
+	    edge_lists[edge].next : edge_lists[edge].prev;
+	  pred = edge; edge = next;
+	}
+
+      }
+
+      type_map[root] = 2;
+      flip_map[root] = false;
+
+      for (int i = 1; i < int(qu.size()); ++i) {
+
+	Node node = qu[i];
+
+	while (type_map[node] != 2) {
+	  st.push_back(node);
+	  type_map[node] = 2;
+	  node = _ugraph.source(pred_map[node]);
+	}
+
+	bool flip = flip_map[node];
+
+	while (!st.empty()) {
+	  node = st.back();
+	  st.pop_back();
+	  
+	  flip_map[node] = flip != flip_map[node];
+	  flip = flip_map[node];
+
+	  if (flip) {
+	    Edge edge = node_data[order_map[node]].first;
+	    std::swap(edge_lists[edge].prev, edge_lists[edge].next);
+	    edge = edge_lists[edge].prev;
+	    std::swap(edge_lists[edge].prev, edge_lists[edge].next);
+	    node_data[order_map[node]].first = edge;
+	  }
+	}
+      }
+
+      for (int i = 0; i < int(qu.size()); ++i) {
+
+	Edge edge = node_data[order_map[qu[i]]].first;
+	Edge last = edge, pred = edge;
+
+	edge = edge_lists[edge].next;
+	while (edge != last) {
+
+	  if (edge_lists[edge].next == pred) {
+	    std::swap(edge_lists[edge].next, edge_lists[edge].prev);
+	  } 
+	  pred = edge; edge = edge_lists[edge].next;
+	}
+	
+      }
+    }
+
+    void setFaceFlags(Node root, Node wnode, Node ynode, Node xnode,
+		      OrderMap& order_map, NodeData& node_data, 
+		      TypeMap& type_map) {
+      Node node = _ugraph.target(node_data[order_map[root]].first);
+
+      while (node != ynode) {
+	type_map[node] = HIGHY;
+	node = _ugraph.target(node_data[order_map[node]].first);
+      }
+
+      while (node != wnode) {
+	type_map[node] = LOWY;
+	node = _ugraph.target(node_data[order_map[node]].first);
+      }
+      
+      node = _ugraph.target(node_data[order_map[wnode]].first);
+      
+      while (node != xnode) {
+	type_map[node] = LOWX;
+	node = _ugraph.target(node_data[order_map[node]].first);
+      }
+      type_map[node] = LOWX;
+
+      node = _ugraph.target(node_data[order_map[xnode]].first);
+      while (node != root) {
+	type_map[node] = HIGHX;
+	node = _ugraph.target(node_data[order_map[node]].first);
+      }
+
+      type_map[wnode] = PERTINENT;
+      type_map[root] = ROOT;
+    }
+
+    void findInternalPath(std::vector<Edge>& ipath,
+			  Node wnode, Node root, TypeMap& type_map, 
+			  OrderMap& order_map, NodeData& node_data, 
+			  EdgeLists& edge_lists) {
+      std::vector<Edge> st;
+
+      Node node = wnode;
+      
+      while (node != root) {
+	Edge edge = edge_lists[node_data[order_map[node]].first].next;
+	st.push_back(edge);
+	node = _ugraph.target(edge);
+      }
+      
+      while (true) {
+	Edge edge = st.back();
+	if (type_map[_ugraph.target(edge)] == LOWX ||
+	    type_map[_ugraph.target(edge)] == HIGHX) {
+	  break;
+	}
+	if (type_map[_ugraph.target(edge)] == 2) {
+	  type_map[_ugraph.target(edge)] = 3;
+	  
+	  edge = edge_lists[_ugraph.oppositeEdge(edge)].next;
+	  st.push_back(edge);
+	} else {
+	  st.pop_back();
+	  edge = edge_lists[edge].next;
+	  
+	  while (_ugraph.oppositeEdge(edge) == st.back()) {
+	    edge = st.back();
+	    st.pop_back();
+	    edge = edge_lists[edge].next;
+	  }
+	  st.push_back(edge);
+	}
+      }
+      
+      for (int i = 0; i < int(st.size()); ++i) {
+	if (type_map[_ugraph.target(st[i])] != LOWY &&
+	    type_map[_ugraph.target(st[i])] != HIGHY) {
+	  for (; i < int(st.size()); ++i) {
+	    ipath.push_back(st[i]);
+	  }
+	}
+      }
+    }
+
+    void setInternalFlags(std::vector<Edge>& ipath, TypeMap& type_map) {
+      for (int i = 1; i < int(ipath.size()); ++i) {
+	type_map[_ugraph.source(ipath[i])] = INTERNAL;
+      }
+    }
+
+    void findPilePath(std::vector<Edge>& ppath,
+		      Node root, TypeMap& type_map, OrderMap& order_map, 
+		      NodeData& node_data, EdgeLists& edge_lists) {
+      std::vector<Edge> st;
+
+      st.push_back(_ugraph.oppositeEdge(node_data[order_map[root]].first));
+      st.push_back(node_data[order_map[root]].first);
+      
+      while (st.size() > 1) {
+	Edge edge = st.back();
+	if (type_map[_ugraph.target(edge)] == INTERNAL) {
+	  break;
+	}
+	if (type_map[_ugraph.target(edge)] == 3) {
+	  type_map[_ugraph.target(edge)] = 4;
+	  
+	  edge = edge_lists[_ugraph.oppositeEdge(edge)].next;
+	  st.push_back(edge);
+	} else {
+	  st.pop_back();
+	  edge = edge_lists[edge].next;
+	  
+	  while (!st.empty() && _ugraph.oppositeEdge(edge) == st.back()) {
+	    edge = st.back();
+	    st.pop_back();
+	    edge = edge_lists[edge].next;
+	  }
+	  st.push_back(edge);
+	}
+      }
+      
+      for (int i = 1; i < int(st.size()); ++i) {
+	ppath.push_back(st[i]);
+      }
+    }
+
+
+    int markExternalPath(Node node, OrderMap& order_map,
+			 ChildLists& child_lists, PredMap& pred_map,
+			 AncestorMap& ancestor_map, LowMap& low_map) {
+      int lp = lowPoint(node, order_map, child_lists,
+			ancestor_map, low_map);
+      
+      if (ancestor_map[node] != lp) {
+	node = child_lists[node].first;
+	_kuratowski[pred_map[node]] = true;
+
+	while (ancestor_map[node] != lp) {
+	  for (OutEdgeIt e(_ugraph, node); e != INVALID; ++e) {
+	    Node tnode = _ugraph.target(e); 
+	    if (order_map[tnode] > order_map[node] && low_map[tnode] == lp) {
+	      node = tnode;
+	      _kuratowski[e] = true;
+	      break;
+	    }
+	  }
+	}
+      }
+
+      for (OutEdgeIt e(_ugraph, node); e != INVALID; ++e) {
+	if (order_map[_ugraph.target(e)] == lp) {
+	  _kuratowski[e] = true;
+	  break;
+	}
+      }
+      
+      return lp;
+    }
+
+    void markPertinentPath(Node node, OrderMap& order_map, 
+			   NodeData& node_data, EdgeLists& edge_lists,
+			   EmbedEdge& embed_edge, MergeRoots& merge_roots) {
+      while (embed_edge[node] == INVALID) {
+	int n = merge_roots[node].front();
+	Edge edge = node_data[n].first;
+
+	_kuratowski.set(edge, true);
+	
+	Node pred = node;
+	node = _ugraph.target(edge);
+	while (!pertinent(node, embed_edge, merge_roots)) {
+	  edge = node_data[order_map[node]].first;
+	  if (_ugraph.target(edge) == pred) {
+	    edge = edge_lists[edge].next;
+	  }
+	  _kuratowski.set(edge, true);
+	  pred = node;
+	  node = _ugraph.target(edge);
+	}
+      }
+      _kuratowski.set(embed_edge[node], true);
+    } 
+
+    void markPredPath(Node node, Node snode, PredMap& pred_map) {
+      while (node != snode) {
+	_kuratowski.set(pred_map[node], true);
+	node = _ugraph.source(pred_map[node]);
+      }
+    }
+
+    void markFacePath(Node ynode, Node xnode, 
+		      OrderMap& order_map, NodeData& node_data) {
+      Edge edge = node_data[order_map[ynode]].first;
+      Node node = _ugraph.target(edge);
+      _kuratowski.set(edge, true);
+	
+      while (node != xnode) {
+	edge = node_data[order_map[node]].first;
+	_kuratowski.set(edge, true);
+	node = _ugraph.target(edge);
+      }
+    }
+
+    void markInternalPath(std::vector<Edge>& path) {
+      for (int i = 0; i < int(path.size()); ++i) {
+	_kuratowski.set(path[i], true);
+      }
+    }
+
+    void markPilePath(std::vector<Edge>& path) {
+      for (int i = 0; i < int(path.size()); ++i) {
+	_kuratowski.set(path[i], true);
+      }
+    }
+
+    void isolateKuratowski(Edge edge, NodeData& node_data, 
+			   EdgeLists& edge_lists, FlipMap& flip_map,
+			   OrderMap& order_map, OrderList& order_list, 
+			   PredMap& pred_map, ChildLists& child_lists,
+			   AncestorMap& ancestor_map, LowMap& low_map, 
+			   EmbedEdge& embed_edge, MergeRoots& merge_roots) {
+
+      Node root = _ugraph.source(edge);
+      Node enode = _ugraph.target(edge);
+
+      int rorder = order_map[root];
+
+      TypeMap type_map(_ugraph, 0);
+
+      int rn = findComponentRoot(root, enode, child_lists, 
+				 order_map, order_list);
+
+      Node xnode = order_list[node_data[rn].next];
+      Node ynode = order_list[node_data[rn].prev];
+
+      // Minor-A
+      {
+	while (!merge_roots[xnode].empty() || !merge_roots[ynode].empty()) {
+	  
+	  if (!merge_roots[xnode].empty()) {
+	    root = xnode;
+	    rn = merge_roots[xnode].front();
+	  } else {
+	    root = ynode;
+	    rn = merge_roots[ynode].front();
+	  }
+	  
+	  xnode = order_list[node_data[rn].next];
+	  ynode = order_list[node_data[rn].prev];
+	}
+	
+	if (root != _ugraph.source(edge)) {
+	  orientComponent(root, rn, order_map, pred_map, 
+			  node_data, edge_lists, flip_map, type_map);
+	  markFacePath(root, root, order_map, node_data);
+	  int xlp = markExternalPath(xnode, order_map, child_lists, 
+				     pred_map, ancestor_map, low_map);
+	  int ylp = markExternalPath(ynode, order_map, child_lists, 
+				     pred_map, ancestor_map, low_map);
+	  markPredPath(root, order_list[xlp < ylp ? xlp : ylp], pred_map);
+	  Node lwnode = findPertinent(ynode, order_map, node_data,
+				     embed_edge, merge_roots);
+	  
+	  markPertinentPath(lwnode, order_map, node_data, edge_lists,
+			    embed_edge, merge_roots);
+	  
+	  return;
+	}
+      }
+      
+      orientComponent(root, rn, order_map, pred_map, 
+		      node_data, edge_lists, flip_map, type_map);
+
+      Node wnode = findPertinent(ynode, order_map, node_data,
+				 embed_edge, merge_roots);
+      setFaceFlags(root, wnode, ynode, xnode, order_map, node_data, type_map);
+
+      
+      //Minor-B
+      if (!merge_roots[wnode].empty()) {
+	int cn = merge_roots[wnode].back();
+	Node rep = order_list[cn - order_list.size()];
+	if (low_map[rep] < rorder) {
+	  markFacePath(root, root, order_map, node_data);
+	  int xlp = markExternalPath(xnode, order_map, child_lists, 
+				     pred_map, ancestor_map, low_map);
+	  int ylp = markExternalPath(ynode, order_map, child_lists, 
+				     pred_map, ancestor_map, low_map);
+
+	  Node lwnode, lznode;
+	  markCommonPath(wnode, rorder, lwnode, lznode, order_list, 
+			 order_map, node_data, edge_lists, embed_edge, 
+			 merge_roots, child_lists, ancestor_map, low_map);
+	  	  
+	  markPertinentPath(lwnode, order_map, node_data, edge_lists,
+			    embed_edge, merge_roots);
+	  int zlp = markExternalPath(lznode, order_map, child_lists, 
+				     pred_map, ancestor_map, low_map);
+
+	  int minlp = xlp < ylp ? xlp : ylp;
+	  if (zlp < minlp) minlp = zlp;
+
+	  int maxlp = xlp > ylp ? xlp : ylp;
+	  if (zlp > maxlp) maxlp = zlp;
+	  
+	  markPredPath(order_list[maxlp], order_list[minlp], pred_map);
+	  
+	  return;
+	}
+      }
+
+      Node pxnode, pynode;
+      std::vector<Edge> ipath;
+      findInternalPath(ipath, wnode, root, type_map, order_map,
+		       node_data, edge_lists);
+      setInternalFlags(ipath, type_map);
+      pynode = _ugraph.source(ipath.front());
+      pxnode = _ugraph.target(ipath.back());
+
+      wnode = findPertinent(pynode, order_map, node_data,
+			    embed_edge, merge_roots);
+      
+      // Minor-C
+      {
+	if (type_map[_ugraph.source(ipath.front())] == HIGHY) {
+	  if (type_map[_ugraph.target(ipath.back())] == HIGHX) {
+	    markFacePath(xnode, pxnode, order_map, node_data);
+	  }
+	  markFacePath(root, xnode, order_map, node_data);
+	  markPertinentPath(wnode, order_map, node_data, edge_lists,
+			    embed_edge, merge_roots);
+	  markInternalPath(ipath);
+	  int xlp = markExternalPath(xnode, order_map, child_lists, 
+				     pred_map, ancestor_map, low_map);
+	  int ylp = markExternalPath(ynode, order_map, child_lists, 
+				     pred_map, ancestor_map, low_map);
+	  markPredPath(root, order_list[xlp < ylp ? xlp : ylp], pred_map);
+	  return;
+	}
+
+	if (type_map[_ugraph.target(ipath.back())] == HIGHX) {
+	  markFacePath(ynode, root, order_map, node_data);
+	  markPertinentPath(wnode, order_map, node_data, edge_lists,
+			    embed_edge, merge_roots);
+	  markInternalPath(ipath);
+	  int xlp = markExternalPath(xnode, order_map, child_lists, 
+				     pred_map, ancestor_map, low_map);
+	  int ylp = markExternalPath(ynode, order_map, child_lists, 
+				     pred_map, ancestor_map, low_map);
+	  markPredPath(root, order_list[xlp < ylp ? xlp : ylp], pred_map);
+	  return;
+	}
+      }
+
+      std::vector<Edge> ppath;
+      findPilePath(ppath, root, type_map, order_map, node_data, edge_lists);
+      
+      // Minor-D
+      if (!ppath.empty()) {
+	markFacePath(ynode, xnode, order_map, node_data);
+	markPertinentPath(wnode, order_map, node_data, edge_lists,
+			  embed_edge, merge_roots);
+	markPilePath(ppath);
+	markInternalPath(ipath);
+	int xlp = markExternalPath(xnode, order_map, child_lists, 
+				   pred_map, ancestor_map, low_map);
+	int ylp = markExternalPath(ynode, order_map, child_lists, 
+				   pred_map, ancestor_map, low_map);
+	markPredPath(root, order_list[xlp < ylp ? xlp : ylp], pred_map);
+	return;
+      }
+
+      // Minor-E*
+      {
+
+	if (!external(wnode, rorder, child_lists, ancestor_map, low_map)) {
+	  Node znode = findExternal(pynode, rorder, order_map, 
+				    child_lists, ancestor_map,
+				    low_map, node_data);
+	  
+	  if (type_map[znode] == LOWY) {
+	    markFacePath(root, xnode, order_map, node_data);
+	    markPertinentPath(wnode, order_map, node_data, edge_lists,
+			      embed_edge, merge_roots);
+	    markInternalPath(ipath);
+	    int xlp = markExternalPath(xnode, order_map, child_lists, 
+				       pred_map, ancestor_map, low_map);
+	    int zlp = markExternalPath(znode, order_map, child_lists, 
+				       pred_map, ancestor_map, low_map);
+	    markPredPath(root, order_list[xlp < zlp ? xlp : zlp], pred_map);
+	  } else {
+	    markFacePath(ynode, root, order_map, node_data);
+	    markPertinentPath(wnode, order_map, node_data, edge_lists,
+			      embed_edge, merge_roots);
+	    markInternalPath(ipath);
+	    int ylp = markExternalPath(ynode, order_map, child_lists, 
+				       pred_map, ancestor_map, low_map);
+	    int zlp = markExternalPath(znode, order_map, child_lists, 
+				       pred_map, ancestor_map, low_map);
+	    markPredPath(root, order_list[ylp < zlp ? ylp : zlp], pred_map);
+	  }
+	  return;
+	}
+
+	int xlp = markExternalPath(xnode, order_map, child_lists, 
+				   pred_map, ancestor_map, low_map);
+	int ylp = markExternalPath(ynode, order_map, child_lists, 
+				   pred_map, ancestor_map, low_map);
+	int wlp = markExternalPath(wnode, order_map, child_lists, 
+				   pred_map, ancestor_map, low_map);
+
+	if (wlp > xlp && wlp > ylp) {
+	  markFacePath(root, root, order_map, node_data);
+	  markPredPath(root, order_list[xlp < ylp ? xlp : ylp], pred_map);
+	  return;
+	}
+
+	markInternalPath(ipath);
+	markPertinentPath(wnode, order_map, node_data, edge_lists,
+			  embed_edge, merge_roots);
+
+	if (xlp > ylp && xlp > wlp) {
+	  markFacePath(root, pynode, order_map, node_data);
+	  markFacePath(wnode, xnode, order_map, node_data);
+	  markPredPath(root, order_list[ylp < wlp ? ylp : wlp], pred_map);
+	  return;
+	}
+
+	if (ylp > xlp && ylp > wlp) {
+	  markFacePath(pxnode, root, order_map, node_data);
+	  markFacePath(ynode, wnode, order_map, node_data);
+	  markPredPath(root, order_list[xlp < wlp ? xlp : wlp], pred_map);
+	  return;
+	}
+
+	if (pynode != ynode) {
+	  markFacePath(pxnode, wnode, order_map, node_data);
+
+	  int minlp = xlp < ylp ? xlp : ylp;
+	  if (wlp < minlp) minlp = wlp;
+
+	  int maxlp = xlp > ylp ? xlp : ylp;
+	  if (wlp > maxlp) maxlp = wlp;
+	  
+	  markPredPath(order_list[maxlp], order_list[minlp], pred_map);
+	  return;
+	}
+
+	if (pxnode != xnode) {
+	  markFacePath(wnode, pynode, order_map, node_data);
+
+	  int minlp = xlp < ylp ? xlp : ylp;
+	  if (wlp < minlp) minlp = wlp;
+
+	  int maxlp = xlp > ylp ? xlp : ylp;
+	  if (wlp > maxlp) maxlp = wlp;
+	  
+	  markPredPath(order_list[maxlp], order_list[minlp], pred_map);
+	  return;
+	}
+
+	markFacePath(root, root, order_map, node_data);
+	int minlp = xlp < ylp ? xlp : ylp;
+	if (wlp < minlp) minlp = wlp;
+	markPredPath(root, order_list[minlp], pred_map);
+	return;
+      }
+      
+    }
+
+  };
+
+  namespace _planarity_bits {
+
+    template <typename UGraph, typename EmbeddingMap>
+    void makeConnected(UGraph& ugraph, EmbeddingMap& embedding) {
+      DfsVisitor<UGraph> null_visitor;
+      DfsVisit<UGraph, DfsVisitor<UGraph> > dfs(ugraph, null_visitor);
+      dfs.init();
+
+      typename UGraph::Node u = INVALID;
+      for (typename UGraph::NodeIt n(ugraph); n != INVALID; ++n) {
+	if (!dfs.reached(n)) {
+	  dfs.addSource(n);
+	  dfs.start();
+	  if (u == INVALID) {
+	    u = n;
+	  } else {
+	    typename UGraph::Node v = n;
+	    
+	    typename UGraph::Edge ue = typename UGraph::OutEdgeIt(ugraph, u);
+	    typename UGraph::Edge ve = typename UGraph::OutEdgeIt(ugraph, v);
+
+	    typename UGraph::Edge e = ugraph.direct(ugraph.addEdge(u, v), true);
+	    
+	    if (ue != INVALID) {
+	      embedding[e] = embedding[ue];
+	      embedding[ue] = e;
+	    } else {
+	      embedding[e] = e;
+	    }
+
+	    if (ve != INVALID) {
+	      embedding[ugraph.oppositeEdge(e)] = embedding[ve];
+	      embedding[ve] = ugraph.oppositeEdge(e);
+	    } else {
+	      embedding[ugraph.oppositeEdge(e)] = ugraph.oppositeEdge(e);
+	    }
+	  }
+	}
+      }
+    }
+
+    template <typename UGraph, typename EmbeddingMap>
+    void makeBiNodeConnected(UGraph& ugraph, EmbeddingMap& embedding) {
+      typename UGraph::template EdgeMap<bool> processed(ugraph);
+
+      std::vector<typename UGraph::Edge> edges;
+      for (typename UGraph::EdgeIt e(ugraph); e != INVALID; ++e) {
+	edges.push_back(e);
+      }
+
+      IterableBoolMap<UGraph, typename UGraph::Node> visited(ugraph, false);
+      
+      for (int i = 0; i < int(edges.size()); ++i) {
+	typename UGraph::Edge pp = edges[i];
+	if (processed[pp]) continue;
+
+	typename UGraph::Edge e = embedding[ugraph.oppositeEdge(pp)];
+	processed[e] = true;
+	visited.set(ugraph.source(e), true);
+	
+	typename UGraph::Edge p = e, l = e;
+	e = embedding[ugraph.oppositeEdge(e)];
+	
+	while (e != l) {
+	  processed[e] = true;
+
+	  if (visited[ugraph.source(e)]) {
+	    
+	    typename UGraph::Edge n = 
+	      ugraph.direct(ugraph.addEdge(ugraph.source(p), 
+					   ugraph.target(e)), true);
+	    embedding[n] = p;
+	    embedding[ugraph.oppositeEdge(pp)] = n;
+
+	    embedding[ugraph.oppositeEdge(n)] = 
+	      embedding[ugraph.oppositeEdge(e)];
+	    embedding[ugraph.oppositeEdge(e)] = 
+	      ugraph.oppositeEdge(n);
+	    
+	    p = n;
+	    e = embedding[ugraph.oppositeEdge(n)];
+	  } else {
+	    visited.set(ugraph.source(e), true);
+	    pp = p;
+	    p = e;
+	    e = embedding[ugraph.oppositeEdge(e)];
+	  }
+	}
+	visited.setAll(false);
+      }
+    }
+    
+    
+    template <typename UGraph, typename EmbeddingMap>
+    void makeMaxPlanar(UGraph& ugraph, EmbeddingMap& embedding) {
+      
+      typename UGraph::template NodeMap<int> degree(ugraph);
+
+      for (typename UGraph::NodeIt n(ugraph); n != INVALID; ++n) {
+	degree[n] = countIncEdges(ugraph, n);
+      }
+
+      typename UGraph::template EdgeMap<bool> processed(ugraph);
+      IterableBoolMap<UGraph, typename UGraph::Node> visited(ugraph, false);
+
+      std::vector<typename UGraph::Edge> edges;
+      for (typename UGraph::EdgeIt e(ugraph); e != INVALID; ++e) {
+	edges.push_back(e);
+      }
+
+      for (int i = 0; i < int(edges.size()); ++i) {
+	typename UGraph::Edge e = edges[i];
+
+	if (processed[e]) continue;
+	processed[e] = true;
+
+	typename UGraph::Edge mine = e;
+	int mind = degree[ugraph.source(e)];
+
+	int face_size = 1;	
+
+	typename UGraph::Edge l = e;
+	e = embedding[ugraph.oppositeEdge(e)];
+	while (l != e) {
+	  processed[e] = true;
+
+	  ++face_size;
+
+	  if (degree[ugraph.source(e)] < mind) {
+	    mine = e;
+	    mind = degree[ugraph.source(e)];
+	  }
+	  
+	  e = embedding[ugraph.oppositeEdge(e)];	  
+	}
+	
+	if (face_size < 4) {
+	  continue;
+	}
+
+	typename UGraph::Node s = ugraph.source(mine);
+	for (typename UGraph::OutEdgeIt e(ugraph, s); e != INVALID; ++e) {
+	  visited.set(ugraph.target(e), true); 
+	}
+
+	typename UGraph::Edge oppe = INVALID;
+
+	e = embedding[ugraph.oppositeEdge(mine)];
+	e = embedding[ugraph.oppositeEdge(e)];
+	while (ugraph.target(e) != s) {
+	  if (visited[ugraph.source(e)]) {
+	    oppe = e;
+	    break;
+	  }
+	  e = embedding[ugraph.oppositeEdge(e)];
+	}
+	visited.setAll(false);
+	
+	if (oppe == INVALID) {
+
+	  e = embedding[ugraph.oppositeEdge(mine)];
+	  typename UGraph::Edge pn = mine, p = e;
+
+	  e = embedding[ugraph.oppositeEdge(e)];
+	  while (ugraph.target(e) != s) {
+	    typename UGraph::Edge n = 
+	      ugraph.direct(ugraph.addEdge(s, ugraph.source(e)), true);
+
+	    embedding[n] = pn;
+	    embedding[ugraph.oppositeEdge(n)] = e;
+	    embedding[ugraph.oppositeEdge(p)] = ugraph.oppositeEdge(n);
+
+	    pn = n;
+	    
+	    p = e;
+	    e = embedding[ugraph.oppositeEdge(e)];
+	  }
+
+	  embedding[ugraph.oppositeEdge(e)] = pn;
+
+	} else {
+
+	  mine = embedding[ugraph.oppositeEdge(mine)];
+	  s = ugraph.source(mine);
+	  oppe = embedding[ugraph.oppositeEdge(oppe)];
+	  typename UGraph::Node t = ugraph.source(oppe);
+	  
+	  typename UGraph::Edge ce = ugraph.direct(ugraph.addEdge(s, t), true);
+	  embedding[ce] = mine;
+	  embedding[ugraph.oppositeEdge(ce)] = oppe;
+
+	  typename UGraph::Edge pn = ce, p = oppe;	  
+	  e = embedding[ugraph.oppositeEdge(oppe)];
+	  while (ugraph.target(e) != s) {
+	    typename UGraph::Edge n = 
+	      ugraph.direct(ugraph.addEdge(s, ugraph.source(e)), true);
+
+	    embedding[n] = pn;
+	    embedding[ugraph.oppositeEdge(n)] = e;
+	    embedding[ugraph.oppositeEdge(p)] = ugraph.oppositeEdge(n);
+
+	    pn = n;
+	    
+	    p = e;
+	    e = embedding[ugraph.oppositeEdge(e)];
+	    
+	  }
+	  embedding[ugraph.oppositeEdge(e)] = pn;
+
+	  pn = ugraph.oppositeEdge(ce), p = mine;	  
+	  e = embedding[ugraph.oppositeEdge(mine)];
+	  while (ugraph.target(e) != t) {
+	    typename UGraph::Edge n = 
+	      ugraph.direct(ugraph.addEdge(t, ugraph.source(e)), true);
+
+	    embedding[n] = pn;
+	    embedding[ugraph.oppositeEdge(n)] = e;
+	    embedding[ugraph.oppositeEdge(p)] = ugraph.oppositeEdge(n);
+
+	    pn = n;
+	    
+	    p = e;
+	    e = embedding[ugraph.oppositeEdge(e)];
+	    
+	  }
+	  embedding[ugraph.oppositeEdge(e)] = pn;
+	}
+      }
+    }
+
+  }
+
+  /// \ingroup planar
+  ///
+  /// \brief Schnyder's planar drawing algorithms
+  ///
+  /// The planar drawing algorithm calculates location for each node
+  /// in the plane, which coordinates satisfies that if each edge is
+  /// represented with a straight line then the edges will not
+  /// intersect each other.
+  ///
+  /// Scnyder's algorithm embeds the graph on \c (n-2,n-2) size grid,
+  /// ie. each node will be located in the \c [0,n-2]x[0,n-2] square.
+  /// The time complexity of the algorithm is O(n).
+  template <typename UGraph>
+  class PlanarDrawing {
+  public:
+
+    UGRAPH_TYPEDEFS(typename UGraph);
+
+    /// \brief The point type for store coordinates
+    typedef dim2::Point<int> Point;
+    /// \brief The map type for store coordinates
+    typedef typename UGraph::template NodeMap<Point> PointMap;
+
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    /// \pre The ugraph should be simple, ie. loop and parallel edge free. 
+    PlanarDrawing(const UGraph& ugraph)
+      : _ugraph(ugraph), _point_map(ugraph) {}
+
+  private:
+
+    template <typename AuxUGraph, typename AuxEmbeddingMap>
+    void drawing(const AuxUGraph& ugraph, 
+		 const AuxEmbeddingMap& next, 
+		 PointMap& point_map) {
+      UGRAPH_TYPEDEFS(typename AuxUGraph);
+
+      typename AuxUGraph::template EdgeMap<Edge> prev(ugraph);
+
+      for (NodeIt n(ugraph); n != INVALID; ++n) {
+	Edge e = OutEdgeIt(ugraph, n);
+	
+	Edge p = e, l = e;
+	
+	e = next[e];
+	while (e != l) {
+	  prev[e] = p;
+	  p = e;
+	  e = next[e];
+	}
+	prev[e] = p;
+      }
+
+      Node anode, bnode, cnode;
+
+      {
+	Edge e = EdgeIt(ugraph);
+	anode = ugraph.source(e);
+	bnode = ugraph.target(e);
+	cnode = ugraph.target(next[ugraph.oppositeEdge(e)]);
+      }
+      
+      IterableBoolMap<AuxUGraph, Node> proper(ugraph, false);
+      typename AuxUGraph::template NodeMap<int> conn(ugraph, -1);
+
+      conn[anode] = conn[bnode] = -2;      
+      {
+	for (OutEdgeIt e(ugraph, anode); e != INVALID; ++e) {
+	  Node m = ugraph.target(e);
+	  if (conn[m] == -1) {
+	    conn[m] = 1;
+	  }
+	}
+	conn[cnode] = 2;
+
+	for (OutEdgeIt e(ugraph, bnode); e != INVALID; ++e) {
+	  Node m = ugraph.target(e);
+	  if (conn[m] == -1) {
+	    conn[m] = 1;
+	  } else if (conn[m] != -2) {
+	    conn[m] += 1;	    
+	    Edge pe = ugraph.oppositeEdge(e);
+	    if (conn[ugraph.target(next[pe])] == -2) {
+	      conn[m] -= 1;
+	    }
+	    if (conn[ugraph.target(prev[pe])] == -2) {
+	      conn[m] -= 1;
+	    }
+
+	    proper.set(m, conn[m] == 1);
+	  }
+	}
+      }
+      
+
+      typename AuxUGraph::template EdgeMap<int> angle(ugraph, -1);
+
+      while (proper.trueNum() != 0) {
+	Node n = typename IterableBoolMap<AuxUGraph, Node>::TrueIt(proper);
+	proper.set(n, false);
+	conn[n] = -2;
+
+	for (OutEdgeIt e(ugraph, n); e != INVALID; ++e) {
+	  Node m = ugraph.target(e);
+	  if (conn[m] == -1) {
+	    conn[m] = 1;
+	  } else if (conn[m] != -2) {
+	    conn[m] += 1;	    
+	    Edge pe = ugraph.oppositeEdge(e);
+	    if (conn[ugraph.target(next[pe])] == -2) {
+	      conn[m] -= 1;
+	    }
+	    if (conn[ugraph.target(prev[pe])] == -2) {
+	      conn[m] -= 1;
+	    }
+
+	    proper.set(m, conn[m] == 1);
+	  }
+	}
+
+	{
+	  Edge e = OutEdgeIt(ugraph, n);
+	  Edge p = e, l = e;
+	  
+	  e = next[e];
+	  while (e != l) {
+	    
+	    if (conn[ugraph.target(e)] == -2 && conn[ugraph.target(p)] == -2) {
+	      Edge f = e;
+	      angle[f] = 0;
+	      f = next[ugraph.oppositeEdge(f)];
+	      angle[f] = 1;
+	      f = next[ugraph.oppositeEdge(f)];
+	      angle[f] = 2;
+	    }
+	    
+	    p = e;
+	    e = next[e];
+	  }
+	  
+	  if (conn[ugraph.target(e)] == -2 && conn[ugraph.target(p)] == -2) {
+	    Edge f = e;
+	    angle[f] = 0;
+	    f = next[ugraph.oppositeEdge(f)];
+	    angle[f] = 1;
+	    f = next[ugraph.oppositeEdge(f)];
+	    angle[f] = 2;
+	  }
+	}
+      }
+
+      typename AuxUGraph::template NodeMap<Node> apred(ugraph, INVALID);
+      typename AuxUGraph::template NodeMap<Node> bpred(ugraph, INVALID);
+      typename AuxUGraph::template NodeMap<Node> cpred(ugraph, INVALID);
+
+      typename AuxUGraph::template NodeMap<int> apredid(ugraph, -1);
+      typename AuxUGraph::template NodeMap<int> bpredid(ugraph, -1);
+      typename AuxUGraph::template NodeMap<int> cpredid(ugraph, -1);
+
+      for (EdgeIt e(ugraph); e != INVALID; ++e) {
+	if (angle[e] == angle[next[e]]) {
+	  switch (angle[e]) {
+	  case 2:
+	    apred[ugraph.target(e)] = ugraph.source(e);
+	    apredid[ugraph.target(e)] = ugraph.id(ugraph.source(e));
+	    break;
+	  case 1:
+	    bpred[ugraph.target(e)] = ugraph.source(e);
+	    bpredid[ugraph.target(e)] = ugraph.id(ugraph.source(e));
+	    break;
+	  case 0:
+	    cpred[ugraph.target(e)] = ugraph.source(e);
+	    cpredid[ugraph.target(e)] = ugraph.id(ugraph.source(e));
+	    break;
+	  }
+	}
+      }
+
+      cpred[anode] = INVALID;
+      cpred[bnode] = INVALID;
+
+      std::vector<Node> aorder, border, corder; 
+
+      {
+	typename AuxUGraph::template NodeMap<bool> processed(ugraph, false);
+	std::vector<Node> st;
+	for (NodeIt n(ugraph); n != INVALID; ++n) {
+	  if (!processed[n] && n != bnode && n != cnode) {
+	    st.push_back(n);
+	    processed[n] = true;
+	    Node m = apred[n];
+	    while (m != INVALID && !processed[m]) {
+	      st.push_back(m);
+	      processed[m] = true;
+	      m = apred[m];
+	    }
+	    while (!st.empty()) {
+	      aorder.push_back(st.back());
+	      st.pop_back();
+	    }
+	  }
+	}
+      }
+
+      {
+	typename AuxUGraph::template NodeMap<bool> processed(ugraph, false);
+	std::vector<Node> st;
+	for (NodeIt n(ugraph); n != INVALID; ++n) {
+	  if (!processed[n] && n != cnode && n != anode) {
+	    st.push_back(n);
+	    processed[n] = true;
+	    Node m = bpred[n];
+	    while (m != INVALID && !processed[m]) {
+	      st.push_back(m);
+	      processed[m] = true;
+	      m = bpred[m];
+	    }
+	    while (!st.empty()) {
+	      border.push_back(st.back());
+	      st.pop_back();
+	    }
+	  }
+	}
+      }
+
+      {
+	typename AuxUGraph::template NodeMap<bool> processed(ugraph, false);
+	std::vector<Node> st;
+	for (NodeIt n(ugraph); n != INVALID; ++n) {
+	  if (!processed[n] && n != anode && n != bnode) {
+	    st.push_back(n);
+	    processed[n] = true;
+	    Node m = cpred[n];
+	    while (m != INVALID && !processed[m]) {
+	      st.push_back(m);
+	      processed[m] = true;
+	      m = cpred[m];
+	    }
+	    while (!st.empty()) {
+	      corder.push_back(st.back());
+	      st.pop_back();
+	    }
+	  }
+	}
+      }
+
+      typename AuxUGraph::template NodeMap<int> atree(ugraph, 0);
+      for (int i = aorder.size() - 1; i >= 0; --i) {
+	Node n = aorder[i];
+	atree[n] = 1;
+	for (OutEdgeIt e(ugraph, n); e != INVALID; ++e) {
+	  if (apred[ugraph.target(e)] == n) {
+	    atree[n] += atree[ugraph.target(e)];
+	  }
+	} 
+      }
+
+      typename AuxUGraph::template NodeMap<int> btree(ugraph, 0);
+      for (int i = border.size() - 1; i >= 0; --i) {
+	Node n = border[i];
+	btree[n] = 1;
+	for (OutEdgeIt e(ugraph, n); e != INVALID; ++e) {
+	  if (bpred[ugraph.target(e)] == n) {
+	    btree[n] += btree[ugraph.target(e)];
+	  }
+	} 
+      }
+      
+      typename AuxUGraph::template NodeMap<int> apath(ugraph, 0);
+      apath[bnode] = apath[cnode] = 1;
+      typename AuxUGraph::template NodeMap<int> apath_btree(ugraph, 0);
+      apath_btree[bnode] = btree[bnode];
+      for (int i = 1; i < int(aorder.size()); ++i) {
+	Node n = aorder[i];
+	apath[n] = apath[apred[n]] + 1;
+	apath_btree[n] = btree[n] + apath_btree[apred[n]];
+      }
+
+      typename AuxUGraph::template NodeMap<int> bpath_atree(ugraph, 0);
+      bpath_atree[anode] = atree[anode];
+      for (int i = 1; i < int(border.size()); ++i) {
+	Node n = border[i];
+	bpath_atree[n] = atree[n] + bpath_atree[bpred[n]];
+      }
+
+      typename AuxUGraph::template NodeMap<int> cpath(ugraph, 0);
+      cpath[anode] = cpath[bnode] = 1;
+      typename AuxUGraph::template NodeMap<int> cpath_atree(ugraph, 0);
+      cpath_atree[anode] = atree[anode];
+      typename AuxUGraph::template NodeMap<int> cpath_btree(ugraph, 0);
+      cpath_btree[bnode] = btree[bnode];
+      for (int i = 1; i < int(corder.size()); ++i) {
+	Node n = corder[i];
+	cpath[n] = cpath[cpred[n]] + 1;
+	cpath_atree[n] = atree[n] + cpath_atree[cpred[n]];
+	cpath_btree[n] = btree[n] + cpath_btree[cpred[n]];
+      }
+
+      typename AuxUGraph::template NodeMap<int> third(ugraph);
+      for (NodeIt n(ugraph); n != INVALID; ++n) {
+	point_map[n].x = 
+	  bpath_atree[n] + cpath_atree[n] - atree[n] - cpath[n] + 1;
+	point_map[n].y = 
+	  cpath_btree[n] + apath_btree[n] - btree[n] - apath[n] + 1;
+      }
+      
+    }
+
+  public:
+
+    /// \brief Calculates the node locations
+    ///
+    /// This function calculates the node locations.
+    bool run() {
+      PlanarEmbedding<UGraph> pe(_ugraph);
+      if (!pe.run()) return false;
+      
+      run(pe);
+      return true;
+    }
+
+    /// \brief Calculates the node locations according to a
+    /// combinatorical embedding
+    ///
+    /// This function calculates the node locations. The \c embedding
+    /// parameter should contain a valid combinatorical embedding, ie.
+    /// a valid cyclic order of the edges.
+    template <typename EmbeddingMap>
+    void run(const EmbeddingMap& embedding) {
+      typedef SmartUEdgeSet<UGraph> AuxUGraph; 
+
+      if (3 * countNodes(_ugraph) - 6 == countUEdges(_ugraph)) {
+	drawing(_ugraph, embedding, _point_map);
+	return;
+      }
+
+      AuxUGraph aux_ugraph(_ugraph);
+      typename AuxUGraph::template EdgeMap<typename AuxUGraph::Edge> 
+	aux_embedding(aux_ugraph);
+
+      {
+
+	typename UGraph::template UEdgeMap<typename AuxUGraph::UEdge> 
+	  ref(_ugraph);
+	
+	for (UEdgeIt e(_ugraph); e != INVALID; ++e) {
+	  ref[e] = aux_ugraph.addEdge(_ugraph.source(e), _ugraph.target(e));
+	}
+
+	for (UEdgeIt e(_ugraph); e != INVALID; ++e) {
+	  Edge ee = embedding[_ugraph.direct(e, true)];
+	  aux_embedding[aux_ugraph.direct(ref[e], true)] = 
+	    aux_ugraph.direct(ref[ee], _ugraph.direction(ee));
+	  ee = embedding[_ugraph.direct(e, false)];
+	  aux_embedding[aux_ugraph.direct(ref[e], false)] = 
+	    aux_ugraph.direct(ref[ee], _ugraph.direction(ee));
+	}
+      }
+      _planarity_bits::makeConnected(aux_ugraph, aux_embedding);
+      _planarity_bits::makeBiNodeConnected(aux_ugraph, aux_embedding);
+      _planarity_bits::makeMaxPlanar(aux_ugraph, aux_embedding);
+      drawing(aux_ugraph, aux_embedding, _point_map);
+    }
+
+    /// \brief The coordinate of the given node
+    ///
+    /// The coordinate of the given node.
+    Point operator[](const Node& node) {
+      return _point_map[node];
+    }
+
+    /// \brief Returns the grid embedding in a \e NodeMap.
+    ///
+    /// Returns the grid embedding in a \e NodeMap of \c dim2::Point<int> .
+    const PointMap& coords() const {
+      return _point_map;
+    }
+
+  private:
+    
+    const UGraph& _ugraph;
+    PointMap _point_map;
+    
+  };
+
+  namespace _planarity_bits {
+
+    template <typename ColorMap>
+    class KempeFilter {
+    public:
+      typedef typename ColorMap::Key Key;
+      typedef bool Value;
+
+      KempeFilter(const ColorMap& color_map, 
+		  const typename ColorMap::Value& first,
+		  const typename ColorMap::Value& second)
+	: _color_map(color_map), _first(first), _second(second) {}
+
+      Value operator[](const Key& key) const {
+	return _color_map[key] == _first || _color_map[key] == _second;
+      }
+
+    private:
+      const ColorMap& _color_map;
+      typename ColorMap::Value _first, _second;
+    };
+  }
+
+  /// \ingroup planar
+  ///
+  /// \brief Coloring planar graphs
+  ///
+  /// The graph coloring problem is the coloring of the graph nodes
+  /// such way that there are not adjacent nodes with the same
+  /// color. The planar graphs can be always colored with four colors,
+  /// it is proved by Appel and Haken and their proofs provide a
+  /// quadratic time algorithm for four coloring, but it could not be
+  /// used to implement efficient algorithm. The five and six coloring
+  /// can be made in linear time, but in this class the five coloring
+  /// has quadratic worst case time complexity. The two coloring (if
+  /// possible) is solvable with a graph search algorithm and it is
+  /// implemented in \ref bipartitePartitions() function in Lemon. To
+  /// decide whether the planar graph is three colorable is
+  /// NP-complete.
+  ///
+  /// This class contains member functions for calculate colorings
+  /// with five and six colors. The six coloring algorithm is a simple
+  /// greedy coloring on the backward minimum outgoing order of nodes.
+  /// This order can be computed such way, that in each phase the node
+  /// with least outgoing edges to unprocessed nodes is choosen. This
+  /// order guarantees that at the time of coloring of a node it has
+  /// at most five already colored adjacents. The five coloring
+  /// algorithm works in the same way, but if the greedy approach
+  /// fails to color with five color, ie. the node has five already
+  /// different colored neighbours, it swaps the colors in one
+  /// connected two colored set with the Kempe recoloring method.
+  template <typename UGraph>
+  class PlanarColoring {
+  public:
+
+    UGRAPH_TYPEDEFS(typename UGraph);
+
+    /// \brief The map type for store color indexes
+    typedef typename UGraph::template NodeMap<int> IndexMap;
+    /// \brief The map type for store colors
+    typedef ComposeMap<Palette, IndexMap> ColorMap;
+
+    /// \brief Constructor
+    ///
+    /// Constructor
+    /// \pre The ugraph should be simple, ie. loop and parallel edge free. 
+    PlanarColoring(const UGraph& ugraph)
+      : _ugraph(ugraph), _color_map(ugraph), _palette(0) {
+      _palette.add(Color(1,0,0));
+      _palette.add(Color(0,1,0));
+      _palette.add(Color(0,0,1));
+      _palette.add(Color(1,1,0));
+      _palette.add(Color(1,0,1));
+      _palette.add(Color(0,1,1));
+    }
+
+    /// \brief Returns the \e NodeMap of color indexes
+    ///
+    /// Returns the \e NodeMap of color indexes. The values are in the
+    /// range \c [0..4] or \c [0..5] according to the five coloring or 
+    /// six coloring.
+    IndexMap colorIndexMap() const {
+      return _color_map;
+    }
+
+    /// \brief Returns the \e NodeMap of colors
+    ///
+    /// Returns the \e NodeMap of colors. The values are five or six
+    /// distinct \ref lemon::Color "colors".
+    ColorMap colorMap() const {
+      return composeMap(_palette, _color_map);
+    }
+
+    /// \brief Returns the color index of the node
+    ///
+    /// Returns the color index of the node. The values are in the
+    /// range \c [0..4] or \c [0..5] according to the five coloring or
+    /// six coloring.
+    int colorIndex(const Node& node) const {
+      return _color_map[node];
+    }
+
+    /// \brief Returns the color of the node
+    ///
+    /// Returns the color of the node. The values are five or six
+    /// distinct \ref lemon::Color "colors".
+    Color color(const Node& node) const {
+      return _palette[_color_map[node]];
+    }
+    
+
+    /// \brief Calculates a coloring with at most six colors
+    ///
+    /// This function calculates a coloring with at most six colors. The time
+    /// complexity of this variant is linear in the size of the graph.
+    /// \return %True when the algorithm could color the graph with six color.
+    /// If the algorithm fails, then the graph could not be planar.
+    bool runSixColoring() {
+      
+      typename UGraph::template NodeMap<int> heap_index(_ugraph, -1);
+      BucketHeap<typename UGraph::template NodeMap<int> > heap(heap_index);
+      
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	_color_map[n] = -2;
+	heap.push(n, countOutEdges(_ugraph, n));
+      }
+      
+      std::vector<Node> order;
+      
+      while (!heap.empty()) {
+	Node n = heap.top();
+	heap.pop();
+	_color_map[n] = -1;
+	order.push_back(n);
+	for (OutEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node t = _ugraph.runningNode(e); 
+	  if (_color_map[t] == -2) {
+	    heap.decrease(t, heap[t] - 1);
+	  }
+	}
+      }
+
+      for (int i = order.size() - 1; i >= 0; --i) {
+	std::vector<bool> forbidden(6, false);
+	for (OutEdgeIt e(_ugraph, order[i]); e != INVALID; ++e) {
+	  Node t = _ugraph.runningNode(e); 
+	  if (_color_map[t] != -1) {
+	    forbidden[_color_map[t]] = true;
+	  }
+	}
+       	for (int k = 0; k < 6; ++k) {
+	  if (!forbidden[k]) {
+	    _color_map[order[i]] = k;
+	    break;
+	  }
+	}
+	if (_color_map[order[i]] == -1) {
+	  return false;
+	}
+      }
+      return true;
+    }
+
+  private:
+
+    bool recolor(const Node& u, const Node& v) {
+      int ucolor = _color_map[u];
+      int vcolor = _color_map[v];
+      typedef _planarity_bits::KempeFilter<IndexMap> KempeFilter;
+      KempeFilter filter(_color_map, ucolor, vcolor);
+
+      typedef NodeSubUGraphAdaptor<const UGraph, const KempeFilter> KempeUGraph;
+      KempeUGraph kempe_ugraph(_ugraph, filter);
+      
+      std::vector<Node> comp;
+      Bfs<KempeUGraph> bfs(kempe_ugraph);
+      bfs.init();
+      bfs.addSource(u);
+      while (!bfs.emptyQueue()) {
+	Node n = bfs.nextNode();
+	if (n == v) return false;
+	comp.push_back(n);
+	bfs.processNextNode();
+      }
+
+      int scolor = ucolor + vcolor;
+      for (int i = 0; i < static_cast<int>(comp.size()); ++i) {
+	_color_map[comp[i]] = scolor - _color_map[comp[i]]; 
+      }
+
+      return true;
+    }
+
+    template <typename EmbeddingMap>
+    void kempeRecoloring(const Node& node, const EmbeddingMap& embedding) {
+      std::vector<Node> nodes;
+      nodes.reserve(4);
+
+      for (Edge e = OutEdgeIt(_ugraph, node); e != INVALID; e = embedding[e]) {
+	Node t = _ugraph.target(e); 
+	if (_color_map[t] != -1) {
+	  nodes.push_back(t);
+	  if (nodes.size() == 4) break;
+	}
+      }
+      
+      int color = _color_map[nodes[0]];
+      if (recolor(nodes[0], nodes[2])) {
+	_color_map[node] = color;
+      } else {
+	color = _color_map[nodes[1]];
+	recolor(nodes[1], nodes[3]);
+	_color_map[node] = color;
+      }
+    }
+
+  public:
+
+    /// \brief Calculates a coloring with at most five colors
+    ///
+    /// This function calculates a coloring with at most five
+    /// colors. The worst case time complexity of this variant is
+    /// quadratic in the size of the graph.
+    template <typename EmbeddingMap>
+    void runFiveColoring(const EmbeddingMap& embedding) {
+      
+      typename UGraph::template NodeMap<int> heap_index(_ugraph, -1);
+      BucketHeap<typename UGraph::template NodeMap<int> > heap(heap_index);
+      
+      for (NodeIt n(_ugraph); n != INVALID; ++n) {
+	_color_map[n] = -2;
+	heap.push(n, countOutEdges(_ugraph, n));
+      }
+      
+      std::vector<Node> order;
+      
+      while (!heap.empty()) {
+	Node n = heap.top();
+	heap.pop();
+	_color_map[n] = -1;
+	order.push_back(n);
+	for (OutEdgeIt e(_ugraph, n); e != INVALID; ++e) {
+	  Node t = _ugraph.runningNode(e); 
+	  if (_color_map[t] == -2) {
+	    heap.decrease(t, heap[t] - 1);
+	  }
+	}
+      }
+
+      for (int i = order.size() - 1; i >= 0; --i) {
+	std::vector<bool> forbidden(5, false);
+	for (OutEdgeIt e(_ugraph, order[i]); e != INVALID; ++e) {
+	  Node t = _ugraph.runningNode(e); 
+	  if (_color_map[t] != -1) {
+	    forbidden[_color_map[t]] = true;
+	  }
+	}
+	for (int k = 0; k < 5; ++k) {
+	  if (!forbidden[k]) {
+	    _color_map[order[i]] = k;
+	    break;
+	  }
+	}
+	if (_color_map[order[i]] == -1) {
+	  kempeRecoloring(order[i], embedding);
+	}
+      }
+    }
+
+    /// \brief Calculates a coloring with at most five colors
+    ///
+    /// This function calculates a coloring with at most five
+    /// colors. The worst case time complexity of this variant is
+    /// quadratic in the size of the graph, but it most cases it does
+    /// not have to use Kempe recoloring method, in this case it is
+    /// equivalent with the runSixColoring() algorithm.
+    /// \return %True when the graph is planar.
+    bool runFiveColoring() {
+      PlanarEmbedding<UGraph> pe(_ugraph);
+      if (!pe.run()) return false;
+      
+      runFiveColoring(pe.embeddingMap());
+      return true;
+    }
+
+  private:
+    
+    const UGraph& _ugraph;
+    IndexMap _color_map;
+    Palette _palette;
+  };
+
+}
+
+#endif
Index: lemon/polynomial.h
===================================================================
--- lemon/polynomial.h	(revision 2553)
+++ lemon/polynomial.h	(revision 2553)
@@ -0,0 +1,349 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_BEZIER_H
+#define LEMON_BEZIER_H
+
+///\ingroup misc
+///\file
+///\brief A simple class implementing polynomials.
+///
+///\author Alpar Juttner
+
+#include<vector>
+
+namespace lemon {
+
+  /// \addtogroup misc
+  /// @{
+
+  ///Simple polinomial class
+
+  ///This class implements a polynomial where the coefficients are of
+  ///type \c T.
+  ///
+  ///The coefficients are stored in an std::vector.
+  template<class T>
+  class Polynomial
+  {
+    std::vector<T> _coeff;
+  public:
+    ///Construct a polynomial of degree \c d.
+    explicit Polynomial(int d=0) : _coeff(d+1) {}
+    ///\e
+    template<class U> Polynomial(const U &u) : _coeff(1,u) {}
+    ///\e
+    template<class U> Polynomial(const Polynomial<U> &u) : _coeff(u.deg()+1)
+    {
+      for(int i=0;i<int(_coeff.size());i++) _coeff[i]=u[i];
+    }
+    ///Query the degree of the polynomial.
+    
+    ///Query the degree of the polynomial.
+    ///\warning This number differs from real degree of the polinomial if
+    ///the coefficient of highest degree is 0.
+    int deg() const { return _coeff.size()-1; }
+    ///Set the degree of the polynomial.
+
+    ///Set the degree of the polynomial. In fact it resizes the
+    ///coefficient vector.
+    void deg(int d) { _coeff.resize(d+1);}
+
+    ///Returns (as a reference) the coefficient of degree \c d.
+    typename std::vector<T>::reference operator[](int d) { return _coeff[d]; }
+    ///Returns (as a const reference) the coefficient of degree \c d.
+    typename std::vector<T>::const_reference
+    operator[](int d) const {return _coeff[d];}
+    
+    ///Substitute the value u into the polinomial.
+
+    ///Substitute the value u into the polinomial.
+    ///The calculation will be done using type \c R.
+    ///The following examples shows the usage of the template parameter \c R.
+    ///\code
+    ///  Polynomial<dim2::Point<double> > line(1);
+    ///  line[0]=dim2::Point<double>(12,25);
+    ///  line[1]=dim2::Point<double>(2,7);
+    ///  ...
+    ///  dim2::Point<double> d = line.subst<dim2::Point<double> >(23.2);
+    ///\endcode
+    ///
+    ///\code
+    ///  Polynomial<double> p;
+    ///  Polynomial<double> q;
+    ///  ...
+    ///  Polynomial<double> s = p.subst<Polynomial<double> >(q);
+    ///\endcode
+    template<class R,class U>
+    R subst(const U &u) const
+    {
+      typename std::vector<T>::const_reverse_iterator i=_coeff.rbegin();
+      R v=*i;
+      for(++i;i!=_coeff.rend();++i) v=v*u+*i;
+      return v;
+    }
+    ///Substitute the value u into the polinomial.
+
+    ///Substitute the value u into the polinomial.
+    ///The calculation will be done using type \c T
+    ///(i.e. using the type of the coefficients.)
+    template<class U>
+    T operator()(const U &u) const 
+    {
+      return subst<T>(u);
+    }
+    
+    ///Derivate the polynomial (in place)
+    Polynomial &derivateMyself()
+    {
+      for(int i=1;i<int(_coeff.size());i++) _coeff[i-1]=i*_coeff[i];
+      _coeff.pop_back();
+      return *this;
+    }
+    
+    ///Return the derivate of the polynomial
+    Polynomial derivate() const
+    {
+      Polynomial tmp(deg()-1);
+      for(int i=1;i<int(_coeff.size());i++) tmp[i-1]=i*_coeff[i];
+      return tmp;
+    }
+
+    ///Integrate the polynomial (in place)
+    Polynomial &integrateMyself()
+    {
+      _coeff.push_back(T());
+      for(int i=_coeff.size()-1;i>0;i--) _coeff[i]=_coeff[i-1]/i;
+      _coeff[0]=0;
+      return *this;
+    }
+    
+    ///Return the integrate of the polynomial
+    Polynomial integrate() const
+    {
+      Polynomial tmp(deg()+1);
+      tmp[0]=0;
+      for(int i=0;i<int(_coeff.size());i++) tmp[i+1]=_coeff[i]/(i+1);
+      return tmp;
+    }
+
+    ///\e
+    template<class U>
+    Polynomial &operator+=(const Polynomial<U> &p)
+    {
+      if(p.deg()>deg()) _coeff.resize(p.deg()+1);
+      for(int i=0;i<=int(std::min(deg(),p.deg()));i++)
+	_coeff[i]+=p[i];
+      return *this;
+    }
+    ///\e
+    template<class U>
+    Polynomial &operator-=(const Polynomial<U> &p)
+    {
+      if(p.deg()>deg()) _coeff.resize(p.deg()+1);
+      for(int i=0;i<=std::min(deg(),p.deg());i++) _coeff[i]-=p[i];
+      return *this;
+    }
+    ///\e
+    template<class U>
+    Polynomial &operator+=(const U &u)
+    {
+      _coeff[0]+=u;
+      return *this;
+    }
+    ///\e
+    template<class U>
+    Polynomial &operator-=(const U &u)
+    {
+      _coeff[0]+=u;
+      return *this;
+    }
+    ///\e
+    template<class U>
+    Polynomial &operator*=(const U &u)
+    {
+      for(typename std::vector<T>::iterator i=_coeff.begin();i!=_coeff.end();++i)
+	*i*=u;
+      return *this;
+    }
+    ///\e
+    template<class U>
+    Polynomial &operator/=(const U &u)
+    {
+      for(typename std::vector<T>::iterator i=_coeff.begin();i!=_coeff.end();++i)
+	*i/=u;
+      return *this;
+    }
+
+  };
+  
+  ///Equality comparison
+
+  ///\relates Polynomial
+  ///\warning Two polynomials are defined to be unequal if their degrees differ,
+  ///even if the non-zero coefficients are the same.
+  template<class U,class V>
+  bool operator==(const Polynomial<U> &u,const Polynomial<V> &v)
+  {
+    if(u.deg()!=v.deg()) return false;
+    for(int i=0;i<=u.deg();i++) if(u[i]!=v[i]) return false;
+    return true;
+  }
+
+  ///Non-equality comparison
+
+  ///\relates Polynomial
+  ///\warning Two polynomials are defined to be unequal if their degrees differ,
+  ///even if the non-zero coefficients are the same.
+  template<class U,class V>
+  bool operator!=(const Polynomial<U> &u,const Polynomial<V> &v)
+  {
+    return !(u==v);
+  }
+
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator+(const Polynomial<U> &u,const Polynomial<V> &v)
+  {
+    Polynomial<U> tmp=u;
+    tmp+=v;
+    return tmp;
+  }
+
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator-(const Polynomial<U> &u,const Polynomial<V> &v)
+  {
+    Polynomial<U> tmp=u;
+    tmp-=v;
+    return tmp;
+  }
+
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator*(const Polynomial<U> &u,const Polynomial<V> &v)
+  {
+    Polynomial<U> tmp(u.deg()+v.deg());
+    for(int i=0;i<=v.deg();i++)
+      for(int j=0;j<=u.deg();j++)
+	tmp[i+j]+=v[i]*u[j];
+    return tmp;
+  }
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator+(const Polynomial<U> &u,const V &v)
+  {
+    Polynomial<U> tmp=u;
+    tmp+=v;
+    return tmp;
+  }
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator+(const V &v,const Polynomial<U> &u)
+  {
+    Polynomial<U> tmp=u;
+    tmp+=v;
+    return tmp;
+  }
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator-(const Polynomial<U> &u,const V &v)
+  {
+    Polynomial<U> tmp=u;
+    tmp-=v;
+    return tmp;
+  }
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U>
+  Polynomial<U> operator-(const Polynomial<U> &u)
+  {
+    Polynomial<U> tmp(u.deg());
+    for(int i=0;i<=u.deg();i++) tmp[i]=-u[i];
+    return tmp;
+  }
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator-(const V &v,const Polynomial<U> &u)
+  {
+    Polynomial<U> tmp=-u;
+    tmp+=v;
+    return tmp;
+  }
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator*(const Polynomial<U> &u,const V &v)
+  {
+    Polynomial<U> tmp=u;
+    tmp*=v;
+    return tmp;
+  }
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator*(const V &v,const Polynomial<U> &u)
+  {
+    Polynomial<U> tmp=u;
+    tmp*=v;
+    return tmp;
+  }
+  ///\e
+
+  ///\relates Polynomial
+  ///
+  template<class U,class V>
+  Polynomial<U> operator/(const Polynomial<U> &u,const V &v)
+  {
+    Polynomial<U> tmp=u;
+    tmp/=v;
+    return tmp;
+  }
+    
+  /// @}
+
+} //END OF NAMESPACE LEMON
+
+#endif // LEMON_POLYNOMIAL_H
Index: lemon/pr_bipartite_matching.h
===================================================================
--- lemon/pr_bipartite_matching.h	(revision 2580)
+++ lemon/pr_bipartite_matching.h	(revision 2580)
@@ -0,0 +1,614 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_PR_BIPARTITE_MATCHING
+#define LEMON_PR_BIPARTITE_MATCHING
+
+#include <lemon/graph_utils.h>
+#include <lemon/iterable_maps.h>
+#include <iostream>
+#include <queue>
+#include <lemon/elevator.h>
+
+///\ingroup matching
+///\file
+///\brief Push-prelabel maximum matching algorithms in bipartite graphs.
+///
+namespace lemon {
+
+  ///Max cardinality matching algorithm based on push-relabel principle
+
+  ///\ingroup matching
+  ///Bipartite Max Cardinality Matching algorithm. This class uses the
+  ///push-relabel principle which in several cases has better runtime
+  ///performance than the augmenting path solutions.
+  ///
+  ///\author Alpar Juttner
+  template<class Graph>
+  class PrBipartiteMatching {
+    typedef typename Graph::Node Node;
+    typedef typename Graph::ANodeIt ANodeIt;
+    typedef typename Graph::BNodeIt BNodeIt;
+    typedef typename Graph::UEdge UEdge;
+    typedef typename Graph::UEdgeIt UEdgeIt;
+    typedef typename Graph::IncEdgeIt IncEdgeIt;
+    
+    const Graph &_g;
+    int _node_num;
+    int _matching_size;
+    int _empty_level;
+    
+    typename Graph::template ANodeMap<typename Graph::UEdge> _matching;
+    Elevator<Graph,typename Graph::BNode> _levels;
+    typename Graph::template BNodeMap<int> _cov;
+
+  public:
+
+    /// Constructor
+
+    /// Constructor
+    ///
+    PrBipartiteMatching(const Graph &g) :
+      _g(g),
+      _node_num(countBNodes(g)),
+      _matching(g),
+      _levels(g,_node_num),
+      _cov(g,0)
+    {
+    }
+    
+    /// \name Execution control 
+    /// The simplest way to execute the algorithm is to use one of the
+    /// member functions called \c run(). \n
+    /// If you need more control on the execution, first
+    /// you must call \ref init() and then one variant of the start()
+    /// member. 
+
+    /// @{
+
+    ///Initialize the data structures
+
+    ///This function constructs a prematching first, which is a
+    ///regular matching on the A-side of the graph, but on the B-side
+    ///each node could cover more matching edges. After that, the
+    ///B-nodes which multiple matched, will be pushed into the lowest
+    ///level of the Elevator. The remaning B-nodes will be pushed to
+    ///the consequent levels respect to a Bfs on following graph: the
+    ///nodes are the B-nodes of the original bipartite graph and two
+    ///nodes are adjacent if a node can pass over a matching edge to
+    ///an other node. The source of the Bfs are the lowest level
+    ///nodes. Last, the reached B-nodes without covered matching edge
+    ///becomes active.
+    void init() {
+      _matching_size=0;
+      _empty_level=_node_num;
+      for(ANodeIt n(_g);n!=INVALID;++n)
+	if((_matching[n]=IncEdgeIt(_g,n))!=INVALID)
+	  ++_cov[_g.bNode(_matching[n])];
+
+      std::queue<Node> q;
+      _levels.initStart();
+      for(BNodeIt n(_g);n!=INVALID;++n)
+	if(_cov[n]>1) {
+	  _levels.initAddItem(n);
+	  q.push(n);
+	}
+      int hlev=0;
+      while(!q.empty()) {
+	Node n=q.front();
+	q.pop();
+	int nlev=_levels[n]+1;
+	for(IncEdgeIt e(_g,n);e!=INVALID;++e) {
+	  Node m=_g.runningNode(e);
+	  if(e==_matching[m]) {
+	    for(IncEdgeIt f(_g,m);f!=INVALID;++f) {
+	      Node r=_g.runningNode(f);
+	      if(_levels[r]>nlev) {
+		for(;nlev>hlev;hlev++)
+		  _levels.initNewLevel();
+		_levels.initAddItem(r);
+		q.push(r);
+	      }
+	    }
+	  }
+	}
+      }
+      _levels.initFinish();
+      for(BNodeIt n(_g);n!=INVALID;++n)
+	if(_cov[n]<1&&_levels[n]<_node_num)
+	  _levels.activate(n);
+    }
+
+    ///Start the main phase of the algorithm
+    
+    ///This algorithm calculates the maximum matching with the
+    ///push-relabel principle. This function should be called just
+    ///after the init() function which already set the initial
+    ///prematching, the level function on the B-nodes and the active,
+    ///ie. unmatched B-nodes.
+    ///
+    ///The algorithm always takes highest active B-node, and it try to
+    ///find a B-node which is eligible to pass over one of it's
+    ///matching edge. This condition holds when the B-node is one
+    ///level lower, and the opposite node of it's matching edge is
+    ///adjacent to the highest active node. In this case the current
+    ///node steals the matching edge and becomes inactive. If there is
+    ///not eligible node then the highest active node should be lift
+    ///to the next proper level.
+    ///
+    ///The nodes should not lift higher than the number of the
+    ///B-nodes, if a node reach this level it remains unmatched. If
+    ///during the execution one level becomes empty the nodes above it
+    ///can be deactivated and lift to the highest level.
+    void start() {
+      Node act;
+      Node bact=INVALID;
+      Node last_activated=INVALID;
+      while((act=_levels.highestActive())!=INVALID) {
+	last_activated=INVALID;
+	int actlevel=_levels[act];
+	
+	UEdge bedge=INVALID;
+	int nlevel=_node_num;
+	{
+	  int nnlevel;
+	  for(IncEdgeIt tbedge(_g,act);
+	      tbedge!=INVALID && nlevel>=actlevel;
+	      ++tbedge)
+	    if((nnlevel=_levels[_g.bNode(_matching[_g.runningNode(tbedge)])])<
+	       nlevel)
+	      {
+		nlevel=nnlevel;
+		bedge=tbedge;
+	      }
+	}
+	if(nlevel<_node_num) {
+	  if(nlevel>=actlevel)
+	    _levels.liftHighestActive(nlevel+1);
+	  bact=_g.bNode(_matching[_g.aNode(bedge)]);
+	  if(--_cov[bact]<1) {
+	    _levels.activate(bact);
+	    last_activated=bact;
+	  }
+	  _matching[_g.aNode(bedge)]=bedge;
+	  _cov[act]=1;
+	  _levels.deactivate(act);
+	}
+	else {
+	  _levels.liftHighestActiveToTop();
+	}
+
+	if(_levels.emptyLevel(actlevel))
+	  _levels.liftToTop(actlevel);
+      }
+      
+      for(ANodeIt n(_g);n!=INVALID;++n) {
+	if (_matching[n]==INVALID)continue;
+	if (_cov[_g.bNode(_matching[n])]>1) {
+	  _cov[_g.bNode(_matching[n])]--;
+	  _matching[n]=INVALID;
+	} else {
+	  ++_matching_size;
+	}
+      }
+    }
+
+    ///Start the algorithm to find a perfect matching
+
+    ///This function is close to identical to the simple start()
+    ///member function but it calculates just perfect matching.
+    ///However, the perfect property is only checked on the B-side of
+    ///the graph
+    ///
+    ///The main difference between the two function is the handling of
+    ///the empty levels. The simple start() function let the nodes
+    ///above the empty levels unmatched while this variant if it find
+    ///an empty level immediately terminates and gives back false
+    ///return value.
+    bool startPerfect() {
+      Node act;
+      Node bact=INVALID;
+      Node last_activated=INVALID;
+      while((act=_levels.highestActive())!=INVALID) {
+	last_activated=INVALID;
+	int actlevel=_levels[act];
+	
+	UEdge bedge=INVALID;
+	int nlevel=_node_num;
+	{
+	  int nnlevel;
+	  for(IncEdgeIt tbedge(_g,act);
+	      tbedge!=INVALID && nlevel>=actlevel;
+	      ++tbedge)
+	    if((nnlevel=_levels[_g.bNode(_matching[_g.runningNode(tbedge)])])<
+	       nlevel)
+	      {
+		nlevel=nnlevel;
+		bedge=tbedge;
+	      }
+	}
+	if(nlevel<_node_num) {
+	  if(nlevel>=actlevel)
+	    _levels.liftHighestActive(nlevel+1);
+	  bact=_g.bNode(_matching[_g.aNode(bedge)]);
+	  if(--_cov[bact]<1) {
+	    _levels.activate(bact);
+	    last_activated=bact;
+	  }
+	  _matching[_g.aNode(bedge)]=bedge;
+	  _cov[act]=1;
+	  _levels.deactivate(act);
+	}
+	else {
+	  _levels.liftHighestActiveToTop();
+	}
+
+	if(_levels.emptyLevel(actlevel))
+	  _empty_level=actlevel;
+	  return false;
+      }
+      _matching_size = _node_num;
+      return true;
+    }
+  
+    ///Runs the algorithm
+    
+    ///Just a shortcut for the next code:
+    ///\code
+    /// init();
+    /// start();
+    ///\endcode
+    void run() {
+      init();
+      start();
+    }
+    
+    ///Runs the algorithm to find a perfect matching
+    
+    ///Just a shortcut for the next code:
+    ///\code
+    /// init();
+    /// startPerfect();
+    ///\endcode
+    ///
+    ///\note If the two nodesets of the graph have different size then
+    ///this algorithm checks the perfect property on the B-side.
+    bool runPerfect() {
+      init();
+      return startPerfect();
+    }
+
+    ///Runs the algorithm to find a perfect matching
+    
+    ///Just a shortcut for the next code:
+    ///\code
+    /// init();
+    /// startPerfect();
+    ///\endcode
+    ///
+    ///\note It checks that the size of the two nodesets are equal.
+    bool checkedRunPerfect() {
+      if (countANodes(_g) != _node_num) return false;
+      init();
+      return startPerfect();
+    }
+
+    ///@}
+
+    /// \name Query Functions
+    /// The result of the %Matching algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    ///@{
+
+    ///Set true all matching uedge in the map.
+
+    ///Set true all matching uedge in the map. It does not change the
+    ///value mapped to the other uedges.
+    ///\return The number of the matching edges.
+    template <typename MatchingMap>
+    int quickMatching(MatchingMap& mm) const {
+      for (ANodeIt n(_g);n!=INVALID;++n) {
+        if (_matching[n]!=INVALID) mm.set(_matching[n],true);
+      }
+      return _matching_size;
+    }
+
+    ///Set true all matching uedge in the map and the others to false.
+
+    ///Set true all matching uedge in the map and the others to false.
+    ///\return The number of the matching edges.
+    template<class MatchingMap>
+    int matching(MatchingMap& mm) const {
+      for (UEdgeIt e(_g);e!=INVALID;++e) {
+        mm.set(e,e==_matching[_g.aNode(e)]);
+      }
+      return _matching_size;
+    }
+
+    ///Gives back the matching in an ANodeMap.
+
+    ///Gives back the matching in an ANodeMap. The parameter should
+    ///be a write ANodeMap of UEdge values.
+    ///\return The number of the matching edges.
+    template<class MatchingMap>
+    int aMatching(MatchingMap& mm) const {
+      for (ANodeIt n(_g);n!=INVALID;++n) {
+        mm.set(n,_matching[n]);
+      }
+      return _matching_size;
+    }
+
+    ///Gives back the matching in a BNodeMap.
+
+    ///Gives back the matching in a BNodeMap. The parameter should
+    ///be a write BNodeMap of UEdge values.
+    ///\return The number of the matching edges.
+    template<class MatchingMap>
+    int bMatching(MatchingMap& mm) const {
+      for (BNodeIt n(_g);n!=INVALID;++n) {
+        mm.set(n,INVALID);
+      }
+      for (ANodeIt n(_g);n!=INVALID;++n) {
+        if (_matching[n]!=INVALID)
+	  mm.set(_g.bNode(_matching[n]),_matching[n]);
+      }
+      return _matching_size;
+    }
+
+
+    ///Returns true if the given uedge is in the matching.
+
+    ///It returns true if the given uedge is in the matching.
+    ///
+    bool matchingEdge(const UEdge& e) const {
+      return _matching[_g.aNode(e)]==e;
+    }
+
+    ///Returns the matching edge from the node.
+
+    ///Returns the matching edge from the node. If there is not such
+    ///edge it gives back \c INVALID.  
+    ///\note If the parameter node is a B-node then the running time is
+    ///propotional to the degree of the node.
+    UEdge matchingEdge(const Node& n) const {
+      if (_g.aNode(n)) {
+        return _matching[n];
+      } else {
+	for (IncEdgeIt e(_g,n);e!=INVALID;++e)
+	  if (e==_matching[_g.aNode(e)]) return e;
+	return INVALID;
+      }
+    }
+
+    ///Gives back the number of the matching edges.
+
+    ///Gives back the number of the matching edges.
+    int matchingSize() const {
+      return _matching_size;
+    }
+
+    ///Gives back a barrier on the A-nodes
+    
+    ///The barrier is s subset of the nodes on the same side of the
+    ///graph. If we tried to find a perfect matching and it failed
+    ///then the barrier size will be greater than its neighbours. If
+    ///the maximum matching searched then the barrier size minus its
+    ///neighbours will be exactly the unmatched nodes on the A-side.
+    ///\retval bar A WriteMap on the ANodes with bool value.
+    template<class BarrierMap>
+    void aBarrier(BarrierMap &bar) const 
+    {
+      for(ANodeIt n(_g);n!=INVALID;++n)
+	bar.set(n,_matching[n]==INVALID ||
+	  _levels[_g.bNode(_matching[n])]<_empty_level);  
+    }  
+
+    ///Gives back a barrier on the B-nodes
+    
+    ///The barrier is s subset of the nodes on the same side of the
+    ///graph. If we tried to find a perfect matching and it failed
+    ///then the barrier size will be greater than its neighbours. If
+    ///the maximum matching searched then the barrier size minus its
+    ///neighbours will be exactly the unmatched nodes on the B-side.
+    ///\retval bar A WriteMap on the BNodes with bool value.
+    template<class BarrierMap>
+    void bBarrier(BarrierMap &bar) const
+    {
+      for(BNodeIt n(_g);n!=INVALID;++n) bar.set(n,_levels[n]>=_empty_level);  
+    }
+
+    ///Returns a minimum covering of the nodes.
+
+    ///The minimum covering set problem is the dual solution of the
+    ///maximum bipartite matching. It provides a solution for this
+    ///problem what is proof of the optimality of the matching.
+    ///\param covering NodeMap of bool values, the nodes of the cover
+    ///set will set true while the others false.  
+    ///\return The size of the cover set.
+    ///\note This function can be called just after the algorithm have
+    ///already found a matching. 
+    template<class CoverMap>
+    int coverSet(CoverMap& covering) const {
+      int ret=0;
+      for(BNodeIt n(_g);n!=INVALID;++n) {
+	if (_levels[n]<_empty_level) { covering.set(n,true); ++ret; }
+	else covering.set(n,false);
+      }
+      for(ANodeIt n(_g);n!=INVALID;++n) {
+	if (_matching[n]!=INVALID &&
+	    _levels[_g.bNode(_matching[n])]>=_empty_level) 
+	  { covering.set(n,true); ++ret; }
+	else covering.set(n,false);
+      }
+      return ret;
+    }
+
+
+    /// @}
+    
+  };
+  
+  
+  ///Maximum cardinality of the matchings in a bipartite graph
+
+  ///\ingroup matching
+  ///This function finds the maximum cardinality of the matchings
+  ///in a bipartite graph \c g.
+  ///\param g An undirected bipartite graph.
+  ///\return The cardinality of the maximum matching.
+  ///
+  ///\note The the implementation is based
+  ///on the push-relabel principle.
+  template<class Graph>
+  int prBipartiteMatching(const Graph &g)
+  {
+    PrBipartiteMatching<Graph> bpm(g);
+    bpm.run();
+    return bpm.matchingSize();
+  }
+
+  ///Maximum cardinality matching in a bipartite graph
+
+  ///\ingroup matching
+  ///This function finds a maximum cardinality matching
+  ///in a bipartite graph \c g.
+  ///\param g An undirected bipartite graph.
+  ///\retval matching A write ANodeMap of value type \c UEdge.
+  /// The found edges will be returned in this map,
+  /// i.e. for an \c ANode \c n the edge <tt>matching[n]</tt> is the one
+  /// that covers the node \c n.
+  ///\return The cardinality of the maximum matching.
+  ///
+  ///\note The the implementation is based
+  ///on the push-relabel principle.
+  template<class Graph,class MT>
+  int prBipartiteMatching(const Graph &g,MT &matching) 
+  {
+    PrBipartiteMatching<Graph> bpm(g);
+    bpm.run();
+    bpm.aMatching(matching);
+    return bpm.matchingSize();
+  }
+
+  ///Maximum cardinality matching in a bipartite graph
+
+  ///\ingroup matching
+  ///This function finds a maximum cardinality matching
+  ///in a bipartite graph \c g.
+  ///\param g An undirected bipartite graph.
+  ///\retval matching A write ANodeMap of value type \c UEdge.
+  /// The found edges will be returned in this map,
+  /// i.e. for an \c ANode \c n the edge <tt>matching[n]</tt> is the one
+  /// that covers the node \c n.
+  ///\retval barrier A \c bool WriteMap on the BNodes. The map will be set
+  /// exactly once for each BNode. The nodes with \c true value represent
+  /// a barrier \e B, i.e. the cardinality of \e B minus the number of its
+  /// neighbor is equal to the number of the <tt>BNode</tt>s minus the
+  /// cardinality of the maximum matching.
+  ///\return The cardinality of the maximum matching.
+  ///
+  ///\note The the implementation is based
+  ///on the push-relabel principle.
+  template<class Graph,class MT, class GT>
+  int prBipartiteMatching(const Graph &g,MT &matching,GT &barrier) 
+  {
+    PrBipartiteMatching<Graph> bpm(g);
+    bpm.run();
+    bpm.aMatching(matching);
+    bpm.bBarrier(barrier);
+    return bpm.matchingSize();
+  }  
+
+  ///Perfect matching in a bipartite graph
+
+  ///\ingroup matching
+  ///This function checks whether the bipartite graph \c g
+  ///has a perfect matching.
+  ///\param g An undirected bipartite graph.
+  ///\return \c true iff \c g has a perfect matching.
+  ///
+  ///\note The the implementation is based
+  ///on the push-relabel principle.
+  template<class Graph>
+  bool prPerfectBipartiteMatching(const Graph &g)
+  {
+    PrBipartiteMatching<Graph> bpm(g);
+    bpm.run();
+    return bpm.checkedRunPerfect();
+  }
+
+  ///Perfect matching in a bipartite graph
+
+  ///\ingroup matching
+  ///This function finds a perfect matching in a bipartite graph \c g.
+  ///\param g An undirected bipartite graph.
+  ///\retval matching A write ANodeMap of value type \c UEdge.
+  /// The found edges will be returned in this map,
+  /// i.e. for an \c ANode \c n the edge <tt>matching[n]</tt> is the one
+  /// that covers the node \c n.
+  /// The values are unchanged if the graph
+  /// has no perfect matching.
+  ///\return \c true iff \c g has a perfect matching.
+  ///
+  ///\note The the implementation is based
+  ///on the push-relabel principle.
+  template<class Graph,class MT>
+  bool prPerfectBipartiteMatching(const Graph &g,MT &matching) 
+  {
+    PrBipartiteMatching<Graph> bpm(g);
+    bool ret = bpm.checkedRunPerfect();
+    if (ret) bpm.aMatching(matching);
+    return ret;
+  }
+
+  ///Perfect matching in a bipartite graph
+
+  ///\ingroup matching
+  ///This function finds a perfect matching in a bipartite graph \c g.
+  ///\param g An undirected bipartite graph.
+  ///\retval matching A write ANodeMap of value type \c UEdge.
+  /// The found edges will be returned in this map,
+  /// i.e. for an \c ANode \c n the edge <tt>matching[n]</tt> is the one
+  /// that covers the node \c n.
+  /// The values are unchanged if the graph
+  /// has no perfect matching.
+  ///\retval barrier A \c bool WriteMap on the BNodes. The map will only
+  /// be set if \c g has no perfect matching. In this case it is set 
+  /// exactly once for each BNode. The nodes with \c true value represent
+  /// a barrier, i.e. a subset \e B a of BNodes with the property that
+  /// the cardinality of \e B is greater than the number of its neighbors.
+  ///\return \c true iff \c g has a perfect matching.
+  ///
+  ///\note The the implementation is based
+  ///on the push-relabel principle.
+  template<class Graph,class MT, class GT>
+  bool prPerfectBipartiteMatching(const Graph &g,MT &matching,GT &barrier) 
+  {
+    PrBipartiteMatching<Graph> bpm(g);
+    bool ret=bpm.checkedRunPerfect();
+    if(ret)
+      bpm.aMatching(matching);
+    else
+      bpm.bBarrier(barrier);
+    return ret;
+  }  
+}
+
+#endif
Index: lemon/preflow.h
===================================================================
--- lemon/preflow.h	(revision 2618)
+++ lemon/preflow.h	(revision 2618)
@@ -0,0 +1,926 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_PREFLOW_H
+#define LEMON_PREFLOW_H
+
+#include <lemon/error.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/tolerance.h>
+#include <lemon/maps.h>
+#include <lemon/graph_utils.h>
+#include <lemon/elevator.h>
+
+/// \file
+/// \ingroup max_flow
+/// \brief Implementation of the preflow algorithm.
+
+namespace lemon { 
+  
+  /// \brief Default traits class of Preflow class.
+  ///
+  /// Default traits class of Preflow class.
+  /// \param _Graph Graph type.
+  /// \param _CapacityMap Type of capacity map.
+  template <typename _Graph, typename _CapacityMap>
+  struct PreflowDefaultTraits {
+
+    /// \brief The graph type the algorithm runs on. 
+    typedef _Graph Graph;
+
+    /// \brief The type of the map that stores the edge capacities.
+    ///
+    /// The type of the map that stores the edge capacities.
+    /// It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef _CapacityMap CapacityMap;
+
+    /// \brief The type of the length of the edges.
+    typedef typename CapacityMap::Value Value;
+
+    /// \brief The map type that stores the flow values.
+    ///
+    /// The map type that stores the flow values. 
+    /// It must meet the \ref concepts::ReadWriteMap "ReadWriteMap" concept.
+    typedef typename Graph::template EdgeMap<Value> FlowMap;
+
+    /// \brief Instantiates a FlowMap.
+    ///
+    /// This function instantiates a \ref FlowMap. 
+    /// \param graph The graph, to which we would like to define the flow map.
+    static FlowMap* createFlowMap(const Graph& graph) {
+      return new FlowMap(graph);
+    }
+
+    /// \brief The eleavator type used by Preflow algorithm.
+    /// 
+    /// The elevator type used by Preflow algorithm.
+    ///
+    /// \sa Elevator
+    /// \sa LinkedElevator
+    typedef LinkedElevator<Graph, typename Graph::Node> Elevator;
+    
+    /// \brief Instantiates an Elevator.
+    ///
+    /// This function instantiates a \ref Elevator. 
+    /// \param graph The graph, to which we would like to define the elevator.
+    /// \param max_level The maximum level of the elevator.
+    static Elevator* createElevator(const Graph& graph, int max_level) {
+      return new Elevator(graph, max_level);
+    }
+
+    /// \brief The tolerance used by the algorithm
+    ///
+    /// The tolerance used by the algorithm to handle inexact computation.
+    typedef lemon::Tolerance<Value> Tolerance;
+
+  };
+  
+
+  /// \ingroup max_flow
+  ///
+  /// \brief %Preflow algorithms class.
+  ///
+  /// This class provides an implementation of the Goldberg's \e
+  /// preflow \e algorithm producing a flow of maximum value in a
+  /// directed graph. The preflow algorithms are the fastest known max
+  /// flow algorithms. The current implementation use a mixture of the
+  /// \e "highest label" and the \e "bound decrease" heuristics.
+  /// The worst case time complexity of the algorithm is \f$O(n^2\sqrt{e})\f$.
+  ///
+  /// The algorithm consists from two phases. After the first phase
+  /// the maximal flow value and the minimum cut can be obtained. The
+  /// second phase constructs the feasible maximum flow on each edge.
+  ///
+  /// \param _Graph The directed graph type the algorithm runs on.
+  /// \param _CapacityMap The flow map type.
+  /// \param _Traits Traits class to set various data types used by
+  /// the algorithm.  The default traits class is \ref
+  /// PreflowDefaultTraits.  See \ref PreflowDefaultTraits for the
+  /// documentation of a %Preflow traits class. 
+  ///
+  ///\author Jacint Szabo and Balazs Dezso
+#ifdef DOXYGEN
+  template <typename _Graph, typename _CapacityMap, typename _Traits>
+#else
+  template <typename _Graph, 
+	    typename _CapacityMap = typename _Graph::template EdgeMap<int>,
+	    typename _Traits = PreflowDefaultTraits<_Graph, _CapacityMap> >
+#endif
+  class Preflow {
+  public:
+    
+    typedef _Traits Traits;
+    typedef typename Traits::Graph Graph;
+    typedef typename Traits::CapacityMap CapacityMap;
+    typedef typename Traits::Value Value; 
+
+    typedef typename Traits::FlowMap FlowMap;
+    typedef typename Traits::Elevator Elevator;
+    typedef typename Traits::Tolerance Tolerance;
+
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::Preflow::UninitializedParameter";
+      }
+    };
+
+  private:
+
+    GRAPH_TYPEDEFS(typename Graph);
+
+    const Graph& _graph;
+    const CapacityMap* _capacity;
+
+    int _node_num;
+
+    Node _source, _target;
+
+    FlowMap* _flow;
+    bool _local_flow;
+
+    Elevator* _level;
+    bool _local_level;
+
+    typedef typename Graph::template NodeMap<Value> ExcessMap;
+    ExcessMap* _excess;
+
+    Tolerance _tolerance;
+
+    bool _phase;
+
+
+    void createStructures() {
+      _node_num = countNodes(_graph);
+
+      if (!_flow) {
+	_flow = Traits::createFlowMap(_graph);
+	_local_flow = true;
+      }
+      if (!_level) {
+	_level = Traits::createElevator(_graph, _node_num);
+	_local_level = true;
+      }
+      if (!_excess) {
+	_excess = new ExcessMap(_graph);
+      }
+    }
+
+    void destroyStructures() {
+      if (_local_flow) {
+	delete _flow;
+      }
+      if (_local_level) {
+	delete _level;
+      }
+      if (_excess) {
+	delete _excess;
+      }
+    }
+
+  public:
+
+    typedef Preflow Create;
+
+    ///\name Named template parameters
+
+    ///@{
+
+    template <typename _FlowMap>
+    struct DefFlowMapTraits : public Traits {
+      typedef _FlowMap FlowMap;
+      static FlowMap *createFlowMap(const Graph&) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// FlowMap type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting FlowMap
+    /// type
+    template <typename _FlowMap>
+    struct DefFlowMap 
+      : public Preflow<Graph, CapacityMap, DefFlowMapTraits<_FlowMap> > {
+      typedef Preflow<Graph, CapacityMap, DefFlowMapTraits<_FlowMap> > Create;
+    };
+
+    template <typename _Elevator>
+    struct DefElevatorTraits : public Traits {
+      typedef _Elevator Elevator;
+      static Elevator *createElevator(const Graph&, int) {
+	throw UninitializedParameter();
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// Elevator type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting Elevator
+    /// type
+    template <typename _Elevator>
+    struct DefElevator 
+      : public Preflow<Graph, CapacityMap, DefElevatorTraits<_Elevator> > {
+      typedef Preflow<Graph, CapacityMap, DefElevatorTraits<_Elevator> > Create;
+    };
+
+    template <typename _Elevator>
+    struct DefStandardElevatorTraits : public Traits {
+      typedef _Elevator Elevator;
+      static Elevator *createElevator(const Graph& graph, int max_level) {
+	return new Elevator(graph, max_level);
+      }
+    };
+
+    /// \brief \ref named-templ-param "Named parameter" for setting
+    /// Elevator type
+    ///
+    /// \ref named-templ-param "Named parameter" for setting Elevator
+    /// type. The Elevator should be standard constructor interface, ie.
+    /// the graph and the maximum level should be passed to it.
+    template <typename _Elevator>
+    struct DefStandardElevator 
+      : public Preflow<Graph, CapacityMap, 
+		       DefStandardElevatorTraits<_Elevator> > {
+      typedef Preflow<Graph, CapacityMap, 
+		      DefStandardElevatorTraits<_Elevator> > Create;
+    };    
+
+    /// @}
+
+  protected:
+    
+    Preflow() {}
+
+  public:
+
+
+    /// \brief The constructor of the class.
+    ///
+    /// The constructor of the class. 
+    /// \param graph The directed graph the algorithm runs on. 
+    /// \param capacity The capacity of the edges. 
+    /// \param source The source node.
+    /// \param target The target node.
+    Preflow(const Graph& graph, const CapacityMap& capacity, 
+	       Node source, Node target) 
+      : _graph(graph), _capacity(&capacity), 
+	_node_num(0), _source(source), _target(target), 
+	_flow(0), _local_flow(false),
+	_level(0), _local_level(false),
+	_excess(0), _tolerance(), _phase() {}
+
+    /// \brief Destrcutor.
+    ///
+    /// Destructor.
+    ~Preflow() {
+      destroyStructures();
+    }
+
+    /// \brief Sets the capacity map.
+    ///
+    /// Sets the capacity map.
+    /// \return \c (*this)
+    Preflow& capacityMap(const CapacityMap& map) {
+      _capacity = &map;
+      return *this;
+    }
+
+    /// \brief Sets the flow map.
+    ///
+    /// Sets the flow map.
+    /// \return \c (*this)
+    Preflow& flowMap(FlowMap& map) {
+      if (_local_flow) {
+	delete _flow;
+	_local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Returns the flow map.
+    ///
+    /// \return The flow map.
+    const FlowMap& flowMap() {
+      return *_flow;
+    }
+
+    /// \brief Sets the elevator.
+    ///
+    /// Sets the elevator.
+    /// \return \c (*this)
+    Preflow& elevator(Elevator& elevator) {
+      if (_local_level) {
+	delete _level;
+	_local_level = false;
+      }
+      _level = &elevator;
+      return *this;
+    }
+
+    /// \brief Returns the elevator.
+    ///
+    /// \return The elevator.
+    const Elevator& elevator() {
+      return *_level;
+    }
+
+    /// \brief Sets the source node.
+    ///
+    /// Sets the source node.
+    /// \return \c (*this)
+    Preflow& source(const Node& node) {
+      _source = node;
+      return *this;
+    }
+
+    /// \brief Sets the target node.
+    ///
+    /// Sets the target node.
+    /// \return \c (*this)
+    Preflow& target(const Node& node) {
+      _target = node;
+      return *this;
+    }
+ 
+    /// \brief Sets the tolerance used by algorithm.
+    ///
+    /// Sets the tolerance used by algorithm.
+    Preflow& tolerance(const Tolerance& tolerance) const {
+      _tolerance = tolerance;
+      return *this;
+    } 
+
+    /// \brief Returns the tolerance used by algorithm.
+    ///
+    /// Returns the tolerance used by algorithm.
+    const Tolerance& tolerance() const {
+      return tolerance;
+    } 
+
+    /// \name Execution control The simplest way to execute the
+    /// algorithm is to use one of the member functions called \c
+    /// run().  
+    /// \n
+    /// If you need more control on initial solution or
+    /// execution then you have to call one \ref init() function and then
+    /// the startFirstPhase() and if you need the startSecondPhase().  
+    
+    ///@{
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    ///
+    void init() {
+      createStructures();
+
+      _phase = true;
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	_excess->set(n, 0);
+      }
+
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+	_flow->set(e, 0);
+      }
+
+      typename Graph::template NodeMap<bool> reached(_graph, false);
+
+      _level->initStart();
+      _level->initAddItem(_target);
+
+      std::vector<Node> queue;
+      reached.set(_source, true);
+
+      queue.push_back(_target);
+      reached.set(_target, true);
+      while (!queue.empty()) {
+	_level->initNewLevel();
+	std::vector<Node> nqueue;
+	for (int i = 0; i < int(queue.size()); ++i) {
+	  Node n = queue[i];
+	  for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node u = _graph.source(e);
+	    if (!reached[u] && _tolerance.positive((*_capacity)[e])) {
+	      reached.set(u, true);
+	      _level->initAddItem(u);
+	      nqueue.push_back(u);
+	    }
+	  }
+	}
+	queue.swap(nqueue);
+      }
+      _level->initFinish();
+
+      for (OutEdgeIt e(_graph, _source); e != INVALID; ++e) {
+	if (_tolerance.positive((*_capacity)[e])) {
+	  Node u = _graph.target(e);
+	  if ((*_level)[u] == _level->maxLevel()) continue;
+	  _flow->set(e, (*_capacity)[e]);
+	  _excess->set(u, (*_excess)[u] + (*_capacity)[e]);
+	  if (u != _target && !_level->active(u)) {
+	    _level->activate(u);
+	  }
+	}
+      }
+    }
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures and sets the initial
+    /// flow to the given \c flowMap. The \c flowMap should contain a
+    /// flow or at least a preflow, ie. in each node excluding the
+    /// target the incoming flow should greater or equal to the
+    /// outgoing flow.
+    /// \return %False when the given \c flowMap is not a preflow. 
+    template <typename FlowMap>
+    bool flowInit(const FlowMap& flowMap) {
+      createStructures();
+
+      for (EdgeIt e(_graph); e != INVALID; ++e) {
+	_flow->set(e, flowMap[e]);
+      }
+
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	Value excess = 0;
+	for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  excess += (*_flow)[e];
+	}
+	for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  excess -= (*_flow)[e];
+	}
+	if (excess < 0 && n != _source) return false;
+	_excess->set(n, excess);
+      }
+
+      typename Graph::template NodeMap<bool> reached(_graph, false);
+
+      _level->initStart();
+      _level->initAddItem(_target);
+
+      std::vector<Node> queue;
+      reached.set(_source, true);
+
+      queue.push_back(_target);
+      reached.set(_target, true);
+      while (!queue.empty()) {
+	_level->initNewLevel();
+	std::vector<Node> nqueue;
+	for (int i = 0; i < int(queue.size()); ++i) {
+	  Node n = queue[i];
+	  for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node u = _graph.source(e);
+	    if (!reached[u] && 
+		_tolerance.positive((*_capacity)[e] - (*_flow)[e])) {
+	      reached.set(u, true);
+	      _level->initAddItem(u);
+	      nqueue.push_back(u);
+	    }
+	  }
+	  for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node v = _graph.target(e);
+	    if (!reached[v] && _tolerance.positive((*_flow)[e])) {
+	      reached.set(v, true);
+	      _level->initAddItem(v);
+	      nqueue.push_back(v);
+	    }
+	  }
+	}
+	queue.swap(nqueue);
+      }
+      _level->initFinish();
+
+      for (OutEdgeIt e(_graph, _source); e != INVALID; ++e) {
+	Value rem = (*_capacity)[e] - (*_flow)[e]; 
+	if (_tolerance.positive(rem)) {
+	  Node u = _graph.target(e);
+	  if ((*_level)[u] == _level->maxLevel()) continue;
+	  _flow->set(e, (*_capacity)[e]);
+	  _excess->set(u, (*_excess)[u] + rem);
+	  if (u != _target && !_level->active(u)) {
+	    _level->activate(u);
+	  }
+	}
+      }
+      for (InEdgeIt e(_graph, _source); e != INVALID; ++e) {
+	Value rem = (*_flow)[e]; 
+	if (_tolerance.positive(rem)) {
+	  Node v = _graph.source(e);
+	  if ((*_level)[v] == _level->maxLevel()) continue;
+	  _flow->set(e, 0);
+	  _excess->set(v, (*_excess)[v] + rem);
+	  if (v != _target && !_level->active(v)) {
+	    _level->activate(v);
+	  }
+	}
+      }
+      return true;
+    }
+
+    /// \brief Starts the first phase of the preflow algorithm.
+    ///
+    /// The preflow algorithm consists of two phases, this method runs
+    /// the first phase. After the first phase the maximum flow value
+    /// and a minimum value cut can already be computed, although a
+    /// maximum flow is not yet obtained. So after calling this method
+    /// \ref flowValue() returns the value of a maximum flow and \ref
+    /// minCut() returns a minimum cut.     
+    /// \pre One of the \ref init() functions should be called. 
+    void startFirstPhase() {
+      _phase = true;
+
+      Node n = _level->highestActive();
+      int level = _level->highestActiveLevel();
+      while (n != INVALID) {
+	int num = _node_num;
+
+	while (num > 0 && n != INVALID) {
+	  Value excess = (*_excess)[n];
+	  int new_level = _level->maxLevel();
+
+	  for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Value rem = (*_capacity)[e] - (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    Node v = _graph.target(e);
+	    if ((*_level)[v] < level) {
+	      if (!_level->active(v) && v != _target) {
+		_level->activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] + excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;
+		goto no_more_push_1;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, (*_capacity)[e]);
+	      }
+	    } else if (new_level > (*_level)[v]) {
+	      new_level = (*_level)[v];
+	    }
+	  }
+
+	  for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Value rem = (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    Node v = _graph.source(e);
+	    if ((*_level)[v] < level) {
+	      if (!_level->active(v) && v != _target) {
+		_level->activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] - excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;
+		goto no_more_push_1;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, 0);
+	      }
+	    } else if (new_level > (*_level)[v]) {
+	      new_level = (*_level)[v];
+	    }
+	  }
+
+	no_more_push_1:
+
+	  _excess->set(n, excess);
+
+	  if (excess != 0) {
+	    if (new_level + 1 < _level->maxLevel()) {
+	      _level->liftHighestActive(new_level + 1);
+	    } else {
+	      _level->liftHighestActiveToTop();
+	    }
+	    if (_level->emptyLevel(level)) {
+	      _level->liftToTop(level);
+	    }
+	  } else {
+	    _level->deactivate(n);
+	  }
+	  
+	  n = _level->highestActive();
+	  level = _level->highestActiveLevel();
+	  --num;
+	}
+	
+	num = _node_num * 20;
+	while (num > 0 && n != INVALID) {
+	  Value excess = (*_excess)[n];
+	  int new_level = _level->maxLevel();
+
+	  for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Value rem = (*_capacity)[e] - (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    Node v = _graph.target(e);
+	    if ((*_level)[v] < level) {
+	      if (!_level->active(v) && v != _target) {
+		_level->activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] + excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;
+		goto no_more_push_2;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, (*_capacity)[e]);
+	      }
+	    } else if (new_level > (*_level)[v]) {
+	      new_level = (*_level)[v];
+	    }
+	  }
+
+	  for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Value rem = (*_flow)[e];
+	    if (!_tolerance.positive(rem)) continue;
+	    Node v = _graph.source(e);
+	    if ((*_level)[v] < level) {
+	      if (!_level->active(v) && v != _target) {
+		_level->activate(v);
+	      }
+	      if (!_tolerance.less(rem, excess)) {
+		_flow->set(e, (*_flow)[e] - excess);
+		_excess->set(v, (*_excess)[v] + excess);
+		excess = 0;
+		goto no_more_push_2;
+	      } else {
+		excess -= rem;
+		_excess->set(v, (*_excess)[v] + rem);
+		_flow->set(e, 0);
+	      }
+	    } else if (new_level > (*_level)[v]) {
+	      new_level = (*_level)[v];
+	    }
+	  }
+
+	no_more_push_2:
+
+	  _excess->set(n, excess);
+
+	  if (excess != 0) {
+	    if (new_level + 1 < _level->maxLevel()) {
+	      _level->liftActiveOn(level, new_level + 1);
+	    } else {
+	      _level->liftActiveToTop(level);
+	    }
+	    if (_level->emptyLevel(level)) {
+	      _level->liftToTop(level);
+	    }
+	  } else {
+	    _level->deactivate(n);
+	  }
+
+	  while (level >= 0 && _level->activeFree(level)) {
+	    --level;
+	  }
+	  if (level == -1) {
+	    n = _level->highestActive();
+	    level = _level->highestActiveLevel();
+	  } else {
+	    n = _level->activeOn(level);
+	  }
+	  --num;
+	}
+      }
+    }
+
+    /// \brief Starts the second phase of the preflow algorithm.
+    ///
+    /// The preflow algorithm consists of two phases, this method runs
+    /// the second phase. After calling \ref init() and \ref
+    /// startFirstPhase() and then \ref startSecondPhase(), \ref
+    /// flowMap() return a maximum flow, \ref flowValue() returns the
+    /// value of a maximum flow, \ref minCut() returns a minimum cut
+    /// \pre The \ref init() and startFirstPhase() functions should be
+    /// called before.
+    void startSecondPhase() {
+      _phase = false;
+
+      typename Graph::template NodeMap<bool> reached(_graph);
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	reached.set(n, (*_level)[n] < _level->maxLevel());
+      }
+
+      _level->initStart();
+      _level->initAddItem(_source);
+ 
+      std::vector<Node> queue;
+      queue.push_back(_source);
+      reached.set(_source, true);
+
+      while (!queue.empty()) {
+	_level->initNewLevel();
+	std::vector<Node> nqueue;
+	for (int i = 0; i < int(queue.size()); ++i) {
+	  Node n = queue[i];
+	  for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node v = _graph.target(e);
+	    if (!reached[v] && _tolerance.positive((*_flow)[e])) {
+	      reached.set(v, true);
+	      _level->initAddItem(v);
+	      nqueue.push_back(v);
+	    }
+	  }
+	  for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	    Node u = _graph.source(e);
+	    if (!reached[u] && 
+		_tolerance.positive((*_capacity)[e] - (*_flow)[e])) {
+	      reached.set(u, true);
+	      _level->initAddItem(u);
+	      nqueue.push_back(u);
+	    }
+	  }
+	}
+	queue.swap(nqueue);
+      }
+      _level->initFinish();
+
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	if (!reached[n]) {
+	  _level->markToBottom(n);
+	} else if ((*_excess)[n] > 0 && _target != n) {
+	  _level->activate(n);
+	}
+      }
+
+      Node n;
+      while ((n = _level->highestActive()) != INVALID) {
+	Value excess = (*_excess)[n];
+	int level = _level->highestActiveLevel();
+	int new_level = _level->maxLevel();
+
+	for (OutEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Value rem = (*_capacity)[e] - (*_flow)[e];
+	  if (!_tolerance.positive(rem)) continue;
+	  Node v = _graph.target(e);
+	  if ((*_level)[v] < level) {
+	    if (!_level->active(v) && v != _source) {
+	      _level->activate(v);
+	    }
+	    if (!_tolerance.less(rem, excess)) {
+	      _flow->set(e, (*_flow)[e] + excess);
+	      _excess->set(v, (*_excess)[v] + excess);
+	      excess = 0;
+	      goto no_more_push;
+	    } else {
+	      excess -= rem;
+	      _excess->set(v, (*_excess)[v] + rem);
+	      _flow->set(e, (*_capacity)[e]);
+	    }
+	  } else if (new_level > (*_level)[v]) {
+	    new_level = (*_level)[v];
+	  }
+	}
+
+	for (InEdgeIt e(_graph, n); e != INVALID; ++e) {
+	  Value rem = (*_flow)[e];
+	  if (!_tolerance.positive(rem)) continue;
+	  Node v = _graph.source(e);
+	  if ((*_level)[v] < level) {
+	    if (!_level->active(v) && v != _source) {
+	      _level->activate(v);
+	    }
+	    if (!_tolerance.less(rem, excess)) {
+	      _flow->set(e, (*_flow)[e] - excess);
+	      _excess->set(v, (*_excess)[v] + excess);
+	      excess = 0;
+	      goto no_more_push;
+	    } else {
+	      excess -= rem;
+	      _excess->set(v, (*_excess)[v] + rem);
+	      _flow->set(e, 0);
+	    }
+	  } else if (new_level > (*_level)[v]) {
+	    new_level = (*_level)[v];
+	  }
+	}
+
+      no_more_push:
+
+	_excess->set(n, excess);
+      
+	if (excess != 0) {
+	  if (new_level + 1 < _level->maxLevel()) {
+	    _level->liftHighestActive(new_level + 1);
+	  } else {
+	    // Calculation error 
+	    _level->liftHighestActiveToTop();
+	  }
+	  if (_level->emptyLevel(level)) {
+	    // Calculation error 
+	    _level->liftToTop(level);
+	  }
+	} else {
+	  _level->deactivate(n);
+	}
+
+      }
+    }
+
+    /// \brief Runs the preflow algorithm.  
+    ///
+    /// Runs the preflow algorithm.
+    /// \note pf.run() is just a shortcut of the following code.
+    /// \code
+    ///   pf.init();
+    ///   pf.startFirstPhase();
+    ///   pf.startSecondPhase();
+    /// \endcode
+    void run() {
+      init();
+      startFirstPhase();
+      startSecondPhase();
+    }
+
+    /// \brief Runs the preflow algorithm to compute the minimum cut.  
+    ///
+    /// Runs the preflow algorithm to compute the minimum cut.
+    /// \note pf.runMinCut() is just a shortcut of the following code.
+    /// \code
+    ///   pf.init();
+    ///   pf.startFirstPhase();
+    /// \endcode
+    void runMinCut() {
+      init();
+      startFirstPhase();
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the %Preflow algorithm can be obtained using these
+    /// functions.\n
+    /// Before the use of these functions,
+    /// either run() or start() must be called.
+    
+    ///@{
+
+    /// \brief Returns the value of the maximum flow.
+    ///
+    /// Returns the value of the maximum flow by returning the excess
+    /// of the target node \c t. This value equals to the value of
+    /// the maximum flow already after the first phase.
+    Value flowValue() const {
+      return (*_excess)[_target];
+    }
+
+    /// \brief Returns true when the node is on the source side of minimum cut.
+    ///
+    /// Returns true when the node is on the source side of minimum
+    /// cut. This method can be called both after running \ref
+    /// startFirstPhase() and \ref startSecondPhase().
+    bool minCut(const Node& node) const {
+      return ((*_level)[node] == _level->maxLevel()) == _phase;
+    }
+ 
+    /// \brief Returns a minimum value cut.
+    ///
+    /// Sets the \c cutMap to the characteristic vector of a minimum value
+    /// cut. This method can be called both after running \ref
+    /// startFirstPhase() and \ref startSecondPhase(). The result after second
+    /// phase could be changed slightly if inexact computation is used.
+    /// \pre The \c cutMap should be a bool-valued node-map.
+    template <typename CutMap>
+    void minCutMap(CutMap& cutMap) const {
+      for (NodeIt n(_graph); n != INVALID; ++n) {
+	cutMap.set(n, minCut(n));
+      }
+    }
+
+    /// \brief Returns the flow on the edge.
+    ///
+    /// Sets the \c flowMap to the flow on the edges. This method can
+    /// be called after the second phase of algorithm.
+    Value flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+    
+    /// @}    
+  };
+}
+
+#endif
Index: lemon/prim.h
===================================================================
--- lemon/prim.h	(revision 2553)
+++ lemon/prim.h	(revision 2553)
@@ -0,0 +1,840 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_PRIM_H
+#define LEMON_PRIM_H
+
+///\ingroup spantree
+///\file
+///\brief Prim algorithm to compute minimum spanning tree.
+
+#include <lemon/list_graph.h>
+#include <lemon/bin_heap.h>
+#include <lemon/bits/invalid.h>
+#include <lemon/error.h>
+#include <lemon/maps.h>
+#include <lemon/bits/traits.h>
+
+#include <lemon/concepts/ugraph.h>
+
+namespace lemon {
+
+  ///Default traits class of Prim class.
+
+  ///Default traits class of Prim class.
+  ///\param GR Graph type.
+  ///\param CM Type of cost map.
+  template<class GR, class CM>
+  struct PrimDefaultTraits{
+    ///The graph type the algorithm runs on. 
+    typedef GR UGraph;
+    ///The type of the map that stores the edge costs.
+
+    ///The type of the map that stores the edge costs.
+    ///It must meet the \ref concepts::ReadMap "ReadMap" concept.
+    typedef CM CostMap;
+    //The type of the cost of the edges.
+    typedef typename CM::Value Value;
+    /// The cross reference type used by heap.
+
+    /// The cross reference type used by heap.
+    /// Usually it is \c UGraph::NodeMap<int>.
+    typedef typename UGraph::template NodeMap<int> HeapCrossRef;
+    ///Instantiates a HeapCrossRef.
+
+    ///This function instantiates a \ref HeapCrossRef. 
+    /// \param _graph is the graph, to which we would like to define the 
+    /// HeapCrossRef.
+    static HeapCrossRef *createHeapCrossRef(const GR &_graph){
+      return new HeapCrossRef(_graph);
+    }
+    
+    ///The heap type used by Prim algorithm.
+
+    ///The heap type used by Prim algorithm.
+    ///
+    ///\sa BinHeap
+    ///\sa Prim
+    typedef BinHeap<typename CM::Value,
+		    HeapCrossRef, std::less<Value> > Heap;
+
+    static Heap *createHeap(HeapCrossRef& _ref){
+      return new Heap(_ref);
+    }
+
+    ///\brief The type of the map that stores the last
+    ///edges of the minimum spanning tree.
+    /// 
+    ///The type of the map that stores the last
+    ///edges of the minimum spanning tree.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///
+    typedef typename UGraph::template NodeMap<typename GR::UEdge> PredMap;
+    ///Instantiates a PredMap.
+ 
+    ///This function instantiates a \ref PredMap. 
+    ///\param _graph is the graph, to which we would like to define the PredMap.
+    static PredMap *createPredMap(const GR &_graph){
+      return new PredMap(_graph);
+    }
+
+    ///The type of the map that stores whether an edge is in the
+    ///spanning tree or not.
+
+    ///The type of the map that stores whether an edge is in the
+    ///spanning tree or not.
+    ///By default it is a NullMap.
+    typedef NullMap<typename UGraph::UEdge,bool> TreeMap;
+    ///Instantiates a TreeMap.
+
+    ///This function instantiates a \ref TreeMap.
+    ///
+    ///The first parameter is the graph, to which
+    ///we would like to define the \ref TreeMap
+    static TreeMap *createTreeMap(const GR &){
+      return new TreeMap();
+    }
+
+    ///The type of the map that stores whether a nodes is processed.
+ 
+    ///The type of the map that stores whether a nodes is processed.
+    ///It must meet the \ref concepts::WriteMap "WriteMap" concept.
+    ///By default it is a NodeMap<bool>.
+    typedef NullMap<typename UGraph::Node,bool> ProcessedMap;
+    ///Instantiates a ProcessedMap.
+ 
+    ///This function instantiates a \ref ProcessedMap. 
+    ///\param _graph is the graph, to which
+    ///we would like to define the \ref ProcessedMap
+#ifdef DOXYGEN
+    static ProcessedMap *createProcessedMap(const GR &_graph)
+#else
+    static ProcessedMap *createProcessedMap(const GR &)
+#endif
+    {
+      return new ProcessedMap();
+    }
+  };
+  
+  ///%Prim algorithm class to find a minimum spanning tree.
+  
+  /// \ingroup spantree
+  ///This class provides an efficient implementation of %Prim algorithm.
+  ///
+  ///The running time is \f$ O(e\log(n)) \f$ where e is the number of edges and
+  ///n is the number of nodes in the graph.
+  ///
+  ///The edge costs are passed to the algorithm using a
+  ///\ref concepts::ReadMap "ReadMap",
+  ///so it is easy to change it to any kind of cost.
+  ///
+  ///The type of the cost is determined by the
+  ///\ref concepts::ReadMap::Value "Value" of the cost map.
+  ///
+  ///It is also possible to change the underlying priority heap.
+  ///
+  ///\param GR The graph type the algorithm runs on. The default value
+  ///is \ref ListUGraph. The value of GR is not used directly by
+  ///Prim, it is only passed to \ref PrimDefaultTraits.
+  ///
+  ///\param CM This read-only UEdgeMap determines the costs of the
+  ///edges. It is read once for each edge, so the map may involve in
+  ///relatively time consuming process to compute the edge cost if
+  ///it is necessary. The default map type is \ref
+  ///concepts::UGraph::UEdgeMap "UGraph::UEdgeMap<int>".  The value
+  ///of CM is not used directly by Prim, it is only passed to \ref
+  ///PrimDefaultTraits.
+  ///
+  ///\param TR Traits class to set
+  ///various data types used by the algorithm.  The default traits
+  ///class is \ref PrimDefaultTraits
+  ///"PrimDefaultTraits<GR,CM>".  See \ref
+  ///PrimDefaultTraits for the documentation of a Prim traits
+  ///class.
+  ///
+  ///\author Balazs Attila Mihaly
+
+#ifdef DOXYGEN
+  template <typename GR,
+	    typename CM,
+	    typename TR>
+#else
+  template <typename GR=ListUGraph,
+	    typename CM=typename GR::template UEdgeMap<int>,
+	    typename TR=PrimDefaultTraits<GR,CM> >
+#endif
+  class Prim {
+  public:
+    
+    /// \brief \ref Exception for uninitialized parameters.
+    ///
+    /// This error represents problems in the initialization
+    /// of the parameters of the algorithms.
+    class UninitializedParameter : public lemon::UninitializedParameter {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::Prim::UninitializedParameter";
+      }
+    };
+
+    typedef TR Traits;
+    ///The type of the underlying graph.
+    typedef typename TR::UGraph UGraph;
+    ///\e
+    typedef typename UGraph::Node Node;
+    ///\e
+    typedef typename UGraph::NodeIt NodeIt;
+    ///\e
+    typedef typename UGraph::UEdge UEdge;
+    ///\e
+    typedef typename UGraph::IncEdgeIt IncEdgeIt;
+    
+    ///The type of the cost of the edges.
+    typedef typename TR::CostMap::Value Value;
+    ///The type of the map that stores the edge costs.
+    typedef typename TR::CostMap CostMap;
+    ///\brief The type of the map that stores the last
+    ///predecessor edges of the spanning tree.
+    typedef typename TR::PredMap PredMap;
+    ///Edges of the spanning tree.
+    typedef typename TR::TreeMap TreeMap;
+    ///The type of the map indicating if a node is processed.
+    typedef typename TR::ProcessedMap ProcessedMap;
+    ///The cross reference type used for the current heap.
+    typedef typename TR::HeapCrossRef HeapCrossRef;
+    ///The heap type used by the prim algorithm.
+    typedef typename TR::Heap Heap;
+  private:
+    /// Pointer to the underlying graph.
+    const UGraph *graph;
+    /// Pointer to the cost map
+    const CostMap *cost;
+    ///Pointer to the map of predecessors edges.
+    PredMap *_pred;
+    ///Indicates if \ref _pred is locally allocated (\c true) or not.
+    bool local_pred;
+    ///Pointer to the map of tree edges.
+    TreeMap *_tree;
+    ///Indicates if \ref _tree is locally allocated (\c true) or not.
+    bool local_tree;
+    ///Pointer to the map of processed status of the nodes.
+    ProcessedMap *_processed;
+    ///Indicates if \ref _processed is locally allocated (\c true) or not.
+    bool local_processed;
+    ///Pointer to the heap cross references.
+    HeapCrossRef *_heap_cross_ref;
+    ///Indicates if \ref _heap_cross_ref is locally allocated (\c true) or not.
+    bool local_heap_cross_ref;
+    ///Pointer to the heap.
+    Heap *_heap;
+    ///Indicates if \ref _heap is locally allocated (\c true) or not.
+    bool local_heap;
+
+    ///Creates the maps if necessary.
+    void create_maps(){
+      if(!_pred) {
+	local_pred = true;
+	_pred = Traits::createPredMap(*graph);
+      }
+      if(!_tree) {
+	local_tree = true;
+	_tree = Traits::createTreeMap(*graph);
+      }
+      if(!_processed) {
+	local_processed = true;
+	_processed = Traits::createProcessedMap(*graph);
+      }
+      if (!_heap_cross_ref) {
+	local_heap_cross_ref = true;
+	_heap_cross_ref = Traits::createHeapCrossRef(*graph);
+      }
+      if (!_heap) {
+	local_heap = true;
+	_heap = Traits::createHeap(*_heap_cross_ref);
+      }
+    }
+    
+  public :
+
+    typedef Prim Create;
+ 
+    ///\name Named template parameters
+
+    ///@{
+
+    template <class T>
+    struct DefPredMapTraits : public Traits {
+      typedef T PredMap;
+      static PredMap *createPredMap(const UGraph &_graph){
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting PredMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting PredMap type
+    ///
+    template <class T>
+    struct DefPredMap 
+      : public Prim< UGraph, CostMap, DefPredMapTraits<T> > {
+      typedef Prim< UGraph, CostMap, DefPredMapTraits<T> > Create;
+    };
+    
+    template <class T>
+    struct DefProcessedMapTraits : public Traits {
+      typedef T ProcessedMap;
+      static ProcessedMap *createProcessedMap(const UGraph &_graph){
+	throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///ProcessedMap type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting ProcessedMap type
+    ///
+    template <class T>
+    struct DefProcessedMap 
+      : public Prim< UGraph, CostMap, DefProcessedMapTraits<T> > { 
+      typedef Prim< UGraph, CostMap, DefProcessedMapTraits<T> > Create;
+    };
+    
+    struct DefGraphProcessedMapTraits : public Traits {
+      typedef typename UGraph::template NodeMap<bool> ProcessedMap;
+      static ProcessedMap *createProcessedMap(const UGraph &_graph){
+	return new ProcessedMap(_graph);
+      }
+    };
+
+
+    template <class H, class CR>
+    struct DefHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const UGraph &) {
+	throw UninitializedParameter();
+      }
+      static Heap *createHeap(HeapCrossRef &){
+	return UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///heap and cross reference type
+    ///
+    ///\ref named-templ-param "Named parameter" for setting heap and cross 
+    ///reference type
+    ///
+    template <class H, class CR = typename UGraph::template NodeMap<int> >
+    struct DefHeap
+      : public Prim< UGraph, CostMap, DefHeapTraits<H, CR> > {
+      typedef Prim< UGraph, CostMap, DefHeapTraits<H, CR> > Create;
+    };
+
+    template <class H, class CR>
+    struct DefStandardHeapTraits : public Traits {
+      typedef CR HeapCrossRef;
+      typedef H Heap;
+      static HeapCrossRef *createHeapCrossRef(const UGraph &_graph) {
+	return new HeapCrossRef(_graph);
+      }
+      static Heap *createHeap(HeapCrossRef &ref){
+	return new Heap(ref);
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///heap and cross reference type with automatic allocation
+    ///
+    ///\ref named-templ-param "Named parameter" for setting heap and cross 
+    ///reference type. It can allocate the heap and the cross reference 
+    ///object if the cross reference's constructor waits for the graph as 
+    ///parameter and the heap's constructor waits for the cross reference.
+    template <class H, class CR = typename UGraph::template NodeMap<int> >
+    struct DefStandardHeap
+      : public Prim< UGraph, CostMap, DefStandardHeapTraits<H, CR> > { 
+      typedef Prim< UGraph, CostMap, DefStandardHeapTraits<H, CR> > 
+      Create;
+    };
+
+    template <class TM>
+    struct DefTreeMapTraits : public Traits {
+      typedef TM TreeMap;
+      static TreeMap *createTreeMap(const UGraph &) {
+        throw UninitializedParameter();
+      }
+    };
+    ///\brief \ref named-templ-param "Named parameter" for setting
+    ///TreeMap
+    ///
+    ///\ref named-templ-param "Named parameter" for setting TreeMap
+    ///
+    template <class TM>
+    struct DefTreeMap
+      : public Prim< UGraph, CostMap, DefTreeMapTraits<TM> > {
+      typedef Prim< UGraph, CostMap, DefTreeMapTraits<TM> > Create;
+    };    
+
+    struct DefGraphTreeMapTraits : public Traits {
+      typedef typename UGraph::template NodeMap<bool> TreeMap;
+      static TreeMap *createTreeMap(const UGraph &_graph){
+	return new TreeMap(_graph);
+      }
+    };
+
+    ///@}
+
+
+  protected:
+
+    Prim() {}
+
+  public:      
+    
+    ///Constructor.
+    ///
+    ///\param _graph the graph the algorithm will run on.
+    ///\param _cost the cost map used by the algorithm.
+    Prim(const UGraph& _graph, const CostMap& _cost) :
+      graph(&_graph), cost(&_cost),
+      _pred(0), local_pred(false),
+      _tree(0), local_tree(false),
+      _processed(0), local_processed(false),
+      _heap_cross_ref(0), local_heap_cross_ref(false),
+      _heap(0), local_heap(false)
+    {
+      checkConcept<concepts::UGraph, UGraph>();
+    }
+    
+    ///Destructor.
+    ~Prim(){
+      if(local_pred) delete _pred;
+      if(local_tree) delete _tree;
+      if(local_processed) delete _processed;
+      if(local_heap_cross_ref) delete _heap_cross_ref;
+      if(local_heap) delete _heap;
+    }
+
+    ///\brief Sets the cost map.
+    ///
+    ///Sets the cost map.
+    ///\return <tt> (*this) </tt>
+    Prim &costMap(const CostMap &m){
+      cost = &m;
+      return *this;
+    }
+
+    ///\brief Sets the map storing the predecessor edges.
+    ///
+    ///Sets the map storing the predecessor edges.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Prim &predMap(PredMap &m){
+      if(local_pred) {
+	delete _pred;
+	local_pred=false;
+      }
+      _pred = &m;
+      return *this;
+    }
+
+    ///\brief Sets the map storing the tree edges.
+    ///
+    ///Sets the map storing the tree edges.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///By default this is a NullMap.
+    ///\return <tt> (*this) </tt>
+    Prim &treeMap(TreeMap &m){
+      if(local_tree) {
+	delete _tree;
+	local_tree=false;
+      }
+      _tree = &m;
+      return *this;
+    }
+
+    ///\brief Sets the heap and the cross reference used by algorithm.
+    ///
+    ///Sets the heap and the cross reference used by algorithm.
+    ///If you don't use this function before calling \ref run(),
+    ///it will allocate one. The destuctor deallocates this
+    ///automatically allocated map, of course.
+    ///\return <tt> (*this) </tt>
+    Prim &heap(Heap& heap, HeapCrossRef &crossRef){
+      if(local_heap_cross_ref) {
+	delete _heap_cross_ref;
+	local_heap_cross_ref=false;
+      }
+      _heap_cross_ref = &crossRef;
+      if(local_heap) {
+	delete _heap;
+	local_heap=false;
+      }
+      _heap = &heap;
+      return *this;
+    }
+
+  public:
+    ///\name Execution control
+    ///The simplest way to execute the algorithm is to use
+    ///one of the member functions called \c run(...).
+    ///\n
+    ///If you need more control on the execution,
+    ///first you must call \ref init(), then you can add several source nodes
+    ///with \ref addSource().
+    ///Finally \ref start() will perform the actual path
+    ///computation.
+
+    ///@{
+
+    ///\brief Initializes the internal data structures.
+    ///
+    ///Initializes the internal data structures.
+    ///
+    void init(){
+      create_maps();
+      _heap->clear();
+      for ( NodeIt u(*graph) ; u!=INVALID ; ++u ) {
+	_pred->set(u,INVALID);
+	_processed->set(u,false);
+	_heap_cross_ref->set(u,Heap::PRE_HEAP);
+      }
+    }
+    
+    ///\brief Adds a new source node.
+    ///
+    ///Adds a new source node to the priority heap.
+    ///
+    ///It checks if the node has already been added to the heap and
+    ///it is pushed to the heap only if it was not in the heap.
+    void addSource(Node s){
+      if(_heap->state(s) != Heap::IN_HEAP) {
+	_heap->push(s,Value());
+      }
+    }
+    ///\brief Processes the next node in the priority heap
+    ///
+    ///Processes the next node in the priority heap.
+    ///
+    ///\return The processed node.
+    ///
+    ///\warning The priority heap must not be empty!
+    Node processNextNode(){
+      Node v=_heap->top(); 
+      _heap->pop();
+      _processed->set(v,true);
+      
+      for(IncEdgeIt e(*graph,v); e!=INVALID; ++e) {
+	Node w=graph->oppositeNode(v,e);
+	switch(_heap->state(w)) {
+	case Heap::PRE_HEAP:
+	  _heap->push(w,(*cost)[e]);
+	  _pred->set(w,e);
+	  break;
+	case Heap::IN_HEAP:
+	  if ( (*cost)[e] < (*_heap)[w] ) {
+	    _heap->decrease(w,(*cost)[e]); 
+	    _pred->set(w,e);
+	  }
+	  break;
+	case Heap::POST_HEAP:
+	  break;
+	}
+      }
+      if ((*_pred)[v]!=INVALID)_tree->set((*_pred)[v],true);
+      return v;
+    }
+
+    ///\brief Next node to be processed.
+    ///
+    ///Next node to be processed.
+    ///
+    ///\return The next node to be processed or INVALID if the priority heap
+    /// is empty.
+    Node nextNode(){ 
+      return _heap->empty()?_heap->top():INVALID;
+    }
+ 
+    ///\brief Returns \c false if there are nodes to be processed in
+    ///the priority heap
+    ///
+    ///Returns \c false if there are nodes
+    ///to be processed in the priority heap
+    bool emptyQueue() { return _heap->empty(); }
+
+    ///\brief Returns the number of the nodes to be processed in the
+    ///priority heap
+    ///
+    ///Returns the number of the nodes to be processed in the priority heap
+    ///
+    int queueSize() { return _heap->size(); }
+    
+    ///\brief Executes the algorithm.
+    ///
+    ///Executes the algorithm.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///This method runs the %Prim algorithm from the node(s)
+    ///in order to compute the
+    ///minimum spanning tree.
+    ///
+    void start(){
+      while ( !_heap->empty() ) processNextNode();
+    }
+    
+    ///\brief Executes the algorithm until a condition is met.
+    ///
+    ///Executes the algorithm until a condition is met.
+    ///
+    ///\pre init() must be called and at least one node should be added
+    ///with addSource() before using this function.
+    ///
+    ///\param nm must be a bool (or convertible) node map. The algorithm
+    ///will stop when it reaches a node \c v with <tt>nm[v]==true</tt>.
+    template<class NodeBoolMap>
+    void start(const NodeBoolMap &nm){
+      while ( !_heap->empty() && !nm[_heap->top()] ) processNextNode();
+      if ( !_heap->empty() ) _processed->set(_heap->top(),true);
+    }
+    
+    ///\brief Runs %Prim algorithm.
+    ///
+    ///This method runs the %Prim algorithm
+    ///in order to compute the
+    ///minimum spanning tree (or minimum spanning forest).
+    ///The method also works on graphs that has more than one components.
+    ///In this case it computes the minimum spanning forest.
+    void run() {
+      init();
+      for(NodeIt it(*graph);it!=INVALID;++it){
+	if(!processed(it)){
+	  addSource(it);
+	  start();
+	}
+      }
+    }
+
+    ///\brief Runs %Prim algorithm from node \c s.
+    ///
+    ///This method runs the %Prim algorithm from node \c s
+    ///in order to
+    ///compute the
+    ///minimun spanning tree
+    ///
+    ///\note p.run(s) is just a shortcut of the following code.
+    ///\code
+    ///  p.init();
+    ///  p.addSource(s);
+    ///  p.start();
+    ///\endcode
+    ///\note If the graph has more than one components, the method
+    ///will compute the minimun spanning tree for only one component.
+    ///
+    ///See \ref run() if you want to compute the minimal spanning forest.
+    void run(Node s){
+      init();
+      addSource(s);
+      start();
+    }
+    
+    ///@}
+
+    ///\name Query Functions
+    ///The result of the %Prim algorithm can be obtained using these
+    ///functions.\n
+    ///Before the use of these functions,
+    ///either run() or start() must be called.
+    
+    ///@{
+
+    ///\brief Returns the 'previous edge' of the minimum spanning tree.
+
+    ///For a node \c v it returns the 'previous edge' of the minimum
+    ///spanning tree, i.e. it returns the edge from where \c v was
+    ///reached. For a source node or an unreachable node it is \ref
+    ///INVALID.  The minimum spanning tree used here is equal to the
+    ///minimum spanning tree used in \ref predNode().  
+    ///\pre \ref run() or \ref start() must be called before using
+    ///this function.
+    UEdge predEdge(Node v) const { return (*_pred)[v]; }
+
+    ///\brief Returns the 'previous node' of the minimum spanning
+    ///tree.
+    ///
+    ///For a node \c v it returns the 'previous node' of the minimum
+    ///spanning tree, i.e. it returns the node from where \c v was
+    ///reached. For a source node or an unreachable node it is \ref
+    ///INVALID.  //The minimum spanning tree used here is equal to the
+    ///minimum spanning tree used in \ref predEdge().  
+    ///\pre \ref run() or \ref start() must be called before using
+    ///this function.
+    Node predNode(Node v) const { return (*_pred)[v]==INVALID ? INVALID:
+				  graph->source((*_pred)[v]); }
+    
+    ///\brief Returns a reference to the NodeMap of the edges of the
+    ///minimum spanning tree.
+    ///
+    ///Returns a reference to the NodeMap of the edges of the minimum
+    ///spanning tree.
+    ///\pre \ref run() or \ref start() must be called before using
+    ///this function.
+    const PredMap &predMap() const { return *_pred;}
+ 
+    ///\brief Returns a reference to the tree edges map.
+
+    ///Returns a reference to the TreeEdgeMap of the edges of the
+    ///minimum spanning tree. The value of the map is \c true only if
+    ///the edge is in the minimum spanning tree.
+    ///
+    ///\warning By default, the TreeEdgeMap is a NullMap.
+    ///
+    ///If it is not set before the execution of the algorithm, use the
+    ///\ref treeMap(TreeMap&) function (after the execution) to set an
+    ///UEdgeMap with the edges of the minimum spanning tree in O(n)
+    ///time where n is the number of nodes in the graph.
+    ///\pre \ref run() or \ref start() must be called before using
+    ///this function.
+    const TreeMap &treeMap() const { return *_tree;}
+ 
+    ///\brief Sets the tree edges map.
+    ///
+    ///Sets the TreeMap of the edges of the minimum spanning tree.
+    ///The map values belonging to the edges of the minimum
+    ///spanning tree are set to \c tree_edge_value or \c true by default,
+    ///the other map values remain untouched.
+    ///
+    ///\pre \ref run() or \ref start() must be called before using
+    ///this function.
+
+    template<class TreeMap>
+    void quickTreeEdges(TreeMap& tree) const {
+      for(NodeIt i(*graph);i!=INVALID;++i){
+        if((*_pred)[i]!=INVALID) tree.set((*_pred)[i],true);
+      }
+    }
+
+    ///\brief Sets the tree edges map.
+    ///
+    ///Sets the TreeMap of the edges of the minimum spanning tree.
+    ///The map values belonging to the edges of the minimum
+    ///spanning tree are set to \c tree_edge_value or \c true by default while
+    ///the edge values not belonging to the minimum spanning tree are set to
+    ///\c tree_default_value or \c false by default.
+    ///
+    ///\pre \ref run() or \ref start() must be called before using
+    ///this function.
+    template <class TreeMap>
+    void treeEdges(TreeMap& tree) const {
+      typedef typename ItemSetTraits<UGraph,UEdge>::ItemIt TreeMapIt;
+      for(TreeMapIt i(*graph); i != INVALID; ++i) {
+	tree.set(i,false);
+      }
+      for(NodeIt i(*graph); i != INVALID; ++i){
+        if((*_pred)[i] != INVALID) tree.set((*_pred)[i],true);
+      }
+    }
+
+    ///\brief Checks if a node is reachable from the starting node.
+    ///
+    ///Returns \c true if \c v is reachable from the starting node.
+    ///\warning The source nodes are inditated as unreached.
+    ///\pre \ref run() or \ref start() must be called before using
+    ///this function.
+    ///
+    bool reached(Node v) { return (*_heap_cross_ref)[v] != Heap::PRE_HEAP; }
+
+    ///\brief Checks if a node is processed.
+    ///
+    ///Returns \c true if \c v is processed, i.e. \c v is already
+    ///connencted to the minimum spanning tree.  \pre \ref run() or
+    ///\ref start() must be called before using this function.
+    bool processed(Node v) { return (*_heap_cross_ref)[v] == Heap::POST_HEAP; }
+    
+
+    ///\brief Checks if an edge is in the spanning tree or not.
+    ///
+    ///Checks if an edge is in the spanning tree or not.
+    ///\param e is the edge that will be checked
+    ///\return \c true if e is in the spanning tree, \c false otherwise
+    bool tree(UEdge e){
+      return (*_pred)[*graph.source(e)]==e || (*_pred)[*graph.target(e)]==e;
+    }
+
+    ///\brief Returns the value of the total cost of the spanning tree.
+    ///
+    /// Returns the value of the total cost of the spanning tree.
+    Value treeValue() const {
+      Value value = 0;
+      for(NodeIt i(*graph); i!= INVALID; ++i){
+        if ((*_pred)[i] != INVALID) value += (*cost)[(*_pred)[i]];
+      }
+      return value;
+    }
+    ///@}
+  };
+
+
+  /// \ingroup spantree
+  ///
+  /// \brief Function type interface for Prim algorithm.
+  ///
+  /// Function type interface for Prim algorithm.
+  /// \param graph the UGraph that the algorithm runs on
+  /// \param cost the CostMap of the edges
+  /// \retval tree the EdgeMap that contains whether an edge is in 
+  /// the spanning tree or not
+  /// \return The total cost of the spanning tree
+  ///
+  ///\sa Prim
+  template<class Graph,class CostMap,class TreeMap>
+  typename CostMap::Value prim(const Graph& graph, 
+                               const CostMap& cost,
+                               TreeMap& tree){
+    typename Prim<Graph,CostMap>::
+      template DefTreeMap<TreeMap>::
+      Create prm(graph,cost);
+    prm.treeMap(tree);
+    prm.run();
+    return prm.treeValue();
+  }
+
+  /// \ingroup spantree
+  ///
+  /// \brief Function type interface for Prim algorithm.
+  ///
+  /// Function type interface for Prim algorithm.
+  /// \param graph the UGraph that the algorithm runs on
+  /// \param cost the CostMap of the edges
+  /// the spanning tree or not
+  /// \return The total cost of the spanning tree
+  ///
+  ///\sa Prim
+  template<class Graph,class CostMap,class TreeMap>
+  typename CostMap::Value prim(const Graph& graph, 
+                               const CostMap& cost){
+    typename Prim<Graph,CostMap>::
+      Create prm(graph,cost);
+    prm.run();
+    return prm.treeValue();
+  }
+
+} //END OF NAMESPACE LEMON
+
+#endif
Index: lemon/radix_heap.h
===================================================================
--- lemon/radix_heap.h	(revision 2553)
+++ lemon/radix_heap.h	(revision 2553)
@@ -0,0 +1,436 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_RADIX_HEAP_H
+#define LEMON_RADIX_HEAP_H
+
+///\ingroup auxdat
+///\file
+///\brief Radix Heap implementation.
+
+#include <vector>
+#include <lemon/error.h>
+
+namespace lemon {
+
+
+  /// \ingroup auxdata
+  ///
+  /// \brief A Radix Heap implementation.
+  ///
+  /// This class implements the \e radix \e heap data structure. A \e heap
+  /// is a data structure for storing items with specified values called \e
+  /// priorities in such a way that finding the item with minimum priority is
+  /// efficient. This heap type can store only items with \e int priority.
+  /// In a heap one can change the priority of an item, add or erase an 
+  /// item, but the priority cannot be decreased under the last removed 
+  /// item's priority.
+  ///
+  /// \param _ItemIntMap A read and writable Item int map, used internally
+  /// to handle the cross references.
+  ///
+  /// \see BinHeap
+  /// \see Dijkstra
+  /// \author Balazs Dezso
+
+  template <typename _ItemIntMap>
+  class RadixHeap {
+
+  public:
+    typedef typename _ItemIntMap::Key Item;
+    typedef int Prio;
+    typedef _ItemIntMap ItemIntMap;
+
+    /// \brief Exception thrown by RadixHeap.
+    ///  
+    /// This Exception is thrown when a smaller priority
+    /// is inserted into the \e RadixHeap then the last time erased.
+    /// \see RadixHeap
+    /// \author Balazs Dezso
+    
+    class UnderFlowPriorityError : public RuntimeError {
+    public:
+      virtual const char* what() const throw() {
+	return "lemon::RadixHeap::UnderFlowPriorityError";
+      }  
+    };
+
+    /// \brief Type to represent the items states.
+    ///
+    /// Each Item element have a state associated to it. It may be "in heap",
+    /// "pre heap" or "post heap". The latter two are indifferent from the
+    /// heap's point of view, but may be useful to the user.
+    ///
+    /// The ItemIntMap \e should be initialized in such way that it maps
+    /// PRE_HEAP (-1) to any element to be put in the heap...
+    enum State {
+      IN_HEAP = 0,
+      PRE_HEAP = -1,
+      POST_HEAP = -2
+    };
+
+  private:
+    
+    struct RadixItem {
+      int prev, next, box;
+      Item item;
+      int prio;
+      RadixItem(Item _item, int _prio) : item(_item), prio(_prio) {}
+    };
+
+    struct RadixBox {
+      int first;
+      int min, size;
+      RadixBox(int _min, int _size) : first(-1), min(_min), size(_size) {}
+    };
+
+    std::vector<RadixItem> data;
+    std::vector<RadixBox> boxes;
+
+    ItemIntMap &iim;
+
+
+  public:
+    /// \brief The constructor.
+    ///
+    /// The constructor.
+    ///
+    /// \param _iim It should be given to the constructor, since it is used
+    /// internally to handle the cross references. The value of the map
+    /// should be PRE_HEAP (-1) for each element.
+    ///
+    /// \param minimal The initial minimal value of the heap.
+    /// \param capacity It determines the initial capacity of the heap. 
+    RadixHeap(ItemIntMap &_iim, int minimal = 0, int capacity = 0) 
+      : iim(_iim) {
+      boxes.push_back(RadixBox(minimal, 1));
+      boxes.push_back(RadixBox(minimal + 1, 1));
+      while (lower(boxes.size() - 1, capacity + minimal - 1)) {
+	extend();
+      }
+    }
+
+    /// The number of items stored in the heap.
+    ///
+    /// \brief Returns the number of items stored in the heap.
+    int size() const { return data.size(); }
+    /// \brief Checks if the heap stores no items.
+    ///
+    /// Returns \c true if and only if the heap stores no items.
+    bool empty() const { return data.empty(); }
+
+    /// \brief Make empty this heap.
+    /// 
+    /// Make empty this heap. It does not change the cross reference
+    /// map.  If you want to reuse a heap what is not surely empty you
+    /// should first clear the heap and after that you should set the
+    /// cross reference map for each item to \c PRE_HEAP.
+    void clear(int minimal = 0, int capacity = 0) { 
+      data.clear(); boxes.clear(); 
+      boxes.push_back(RadixBox(minimal, 1));
+      boxes.push_back(RadixBox(minimal + 1, 1));
+      while (lower(boxes.size() - 1, capacity + minimal - 1)) {
+	extend();
+      }
+    }
+
+  private:
+
+    bool upper(int box, Prio pr) {
+      return pr < boxes[box].min;
+    }
+
+    bool lower(int box, Prio pr) {
+      return pr >= boxes[box].min + boxes[box].size;
+    }
+
+    /// \brief Remove item from the box list.
+    void remove(int index) {
+      if (data[index].prev >= 0) {
+	data[data[index].prev].next = data[index].next;
+      } else {
+	boxes[data[index].box].first = data[index].next;
+      }
+      if (data[index].next >= 0) {
+	data[data[index].next].prev = data[index].prev;
+      }
+    }
+
+    /// \brief Insert item into the box list.
+    void insert(int box, int index) {
+      if (boxes[box].first == -1) {
+	boxes[box].first = index;
+	data[index].next = data[index].prev = -1;
+      } else {
+	data[index].next = boxes[box].first;
+	data[boxes[box].first].prev = index;
+	data[index].prev = -1;
+	boxes[box].first = index;
+      }
+      data[index].box = box;
+    }
+
+    /// \brief Add a new box to the box list.
+    void extend() {
+      int min = boxes.back().min + boxes.back().size;
+      int bs = 2 * boxes.back().size;
+      boxes.push_back(RadixBox(min, bs));
+    }
+
+    /// \brief Move an item up into the proper box.
+    void bubble_up(int index) {
+      if (!lower(data[index].box, data[index].prio)) return;
+      remove(index);
+      int box = findUp(data[index].box, data[index].prio);
+      insert(box, index);      
+    }
+
+    /// \brief Find up the proper box for the item with the given prio.
+    int findUp(int start, int pr) {
+      while (lower(start, pr)) {
+	if (++start == int(boxes.size())) {
+	  extend();
+	}
+      }
+      return start;
+    }
+
+    /// \brief Move an item down into the proper box.
+    void bubble_down(int index) {
+      if (!upper(data[index].box, data[index].prio)) return;
+      remove(index);
+      int box = findDown(data[index].box, data[index].prio);
+      insert(box, index);
+    }
+
+    /// \brief Find up the proper box for the item with the given prio.
+    int findDown(int start, int pr) {
+      while (upper(start, pr)) {
+	if (--start < 0) throw UnderFlowPriorityError();
+      }
+      return start;
+    }
+
+    /// \brief Find the first not empty box.
+    int findFirst() {
+      int first = 0;
+      while (boxes[first].first == -1) ++first;
+      return first;
+    }
+
+    /// \brief Gives back the minimal prio of the box.
+    int minValue(int box) {
+      int min = data[boxes[box].first].prio;
+      for (int k = boxes[box].first; k != -1; k = data[k].next) {
+	if (data[k].prio < min) min = data[k].prio;
+      }
+      return min;
+    }
+
+    /// \brief Rearrange the items of the heap and makes the 
+    /// first box not empty.
+    void moveDown() {
+      int box = findFirst();
+      if (box == 0) return;
+      int min = minValue(box);
+      for (int i = 0; i <= box; ++i) {
+	boxes[i].min = min;
+	min += boxes[i].size;
+      }
+      int curr = boxes[box].first, next;
+      while (curr != -1) {
+	next = data[curr].next;
+	bubble_down(curr);
+	curr = next;
+      }      
+    }
+
+    void relocate_last(int index) {
+      if (index != int(data.size()) - 1) {
+	data[index] = data.back();
+	if (data[index].prev != -1) {
+	  data[data[index].prev].next = index;
+	} else {
+	  boxes[data[index].box].first = index;
+	}
+	if (data[index].next != -1) {
+	  data[data[index].next].prev = index;
+	}
+	iim[data[index].item] = index;
+      }
+      data.pop_back();
+    }
+
+  public:
+
+    /// \brief Insert an item into the heap with the given priority.
+    ///    
+    /// Adds \c i to the heap with priority \c p. 
+    /// \param i The item to insert.
+    /// \param p The priority of the item.
+    void push(const Item &i, const Prio &p) {
+      int n = data.size();
+      iim.set(i, n);
+      data.push_back(RadixItem(i, p));
+      while (lower(boxes.size() - 1, p)) {
+	extend();
+      }
+      int box = findDown(boxes.size() - 1, p);
+      insert(box, n);
+    }
+
+    /// \brief Returns the item with minimum priority.
+    ///
+    /// This method returns the item with minimum priority.  
+    /// \pre The heap must be nonempty.  
+    Item top() const {
+      const_cast<RadixHeap<ItemIntMap>&>(*this).moveDown();
+      return data[boxes[0].first].item;
+    }
+
+    /// \brief Returns the minimum priority.
+    ///
+    /// It returns the minimum priority.
+    /// \pre The heap must be nonempty.
+    Prio prio() const {
+      const_cast<RadixHeap<ItemIntMap>&>(*this).moveDown();
+      return data[boxes[0].first].prio;
+     }
+
+    /// \brief Deletes the item with minimum priority.
+    ///
+    /// This method deletes the item with minimum priority.
+    /// \pre The heap must be non-empty.  
+    void pop() {
+      moveDown();
+      int index = boxes[0].first;
+      iim[data[index].item] = POST_HEAP;
+      remove(index);
+      relocate_last(index);
+    }
+
+    /// \brief Deletes \c i from the heap.
+    ///
+    /// This method deletes item \c i from the heap, if \c i was
+    /// already stored in the heap.
+    /// \param i The item to erase. 
+    void erase(const Item &i) {
+      int index = iim[i];
+      iim[i] = POST_HEAP;
+      remove(index);
+      relocate_last(index);
+   }
+
+    /// \brief Returns the priority of \c i.
+    ///
+    /// This function returns the priority of item \c i.  
+    /// \pre \c i must be in the heap.
+    /// \param i The item.
+    Prio operator[](const Item &i) const {
+      int idx = iim[i];
+      return data[idx].prio;
+    }
+
+    /// \brief \c i gets to the heap with priority \c p independently 
+    /// if \c i was already there.
+    ///
+    /// This method calls \ref push(\c i, \c p) if \c i is not stored
+    /// in the heap and sets the priority of \c i to \c p otherwise.
+    /// It may throw an \e UnderFlowPriorityException. 
+    /// \param i The item.
+    /// \param p The priority.
+    void set(const Item &i, const Prio &p) {
+      int idx = iim[i];
+      if( idx < 0 ) {
+	push(i, p);
+      }
+      else if( p >= data[idx].prio ) {
+	data[idx].prio = p;
+	bubble_up(idx);
+      } else {
+	data[idx].prio = p;
+	bubble_down(idx);
+      }
+    }
+
+
+    /// \brief Decreases the priority of \c i to \c p.
+    ///
+    /// This method decreases the priority of item \c i to \c p.
+    /// \pre \c i must be stored in the heap with priority at least \c p, and
+    /// \c should be greater or equal to the last removed item's priority.
+    /// \param i The item.
+    /// \param p The priority.
+    void decrease(const Item &i, const Prio &p) {
+      int idx = iim[i];
+      data[idx].prio = p;
+      bubble_down(idx);
+    }
+
+    /// \brief Increases the priority of \c i to \c p.
+    ///
+    /// This method sets the priority of item \c i to \c p. 
+    /// \pre \c i must be stored in the heap with priority at most \c p
+    /// \param i The item.
+    /// \param p The priority.
+    void increase(const Item &i, const Prio &p) {
+      int idx = iim[i];
+      data[idx].prio = p;
+      bubble_up(idx);
+    }
+
+    /// \brief Returns if \c item is in, has already been in, or has 
+    /// never been in the heap.
+    ///
+    /// This method returns PRE_HEAP if \c item has never been in the
+    /// heap, IN_HEAP if it is in the heap at the moment, and POST_HEAP
+    /// otherwise. In the latter case it is possible that \c item will
+    /// get back to the heap again.
+    /// \param i The item.
+    State state(const Item &i) const {
+      int s = iim[i];
+      if( s >= 0 ) s = 0;
+      return State(s);
+    }
+
+    /// \brief Sets the state of the \c item in the heap.
+    ///
+    /// Sets the state of the \c item in the heap. It can be used to
+    /// manually clear the heap when it is important to achive the
+    /// better time complexity.
+    /// \param i The item.
+    /// \param st The state. It should not be \c IN_HEAP. 
+    void state(const Item& i, State st) {
+      switch (st) {
+      case POST_HEAP:
+      case PRE_HEAP:
+        if (state(i) == IN_HEAP) {
+          erase(i);
+        }
+        iim[i] = st;
+        break;
+      case IN_HEAP:
+        break;
+      }
+    }
+
+  }; // class RadixHeap
+
+} // namespace lemon
+
+#endif // LEMON_RADIX_HEAP_H
Index: lemon/radix_sort.h
===================================================================
--- lemon/radix_sort.h	(revision 2553)
+++ lemon/radix_sort.h	(revision 2553)
@@ -0,0 +1,485 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef RADIX_SORT_H
+#define RADIX_SORT_H
+
+/// \ingroup auxalg
+/// \file
+/// \brief Radix sort
+///
+
+#include <vector>
+#include <limits>
+#include <iterator>
+#include <algorithm>
+
+#include <lemon/error.h>
+
+namespace lemon {
+
+  namespace _radix_sort_bits {
+
+    template <typename Value>
+    struct Identity {
+      const Value& operator()(const Value& val) {
+	return val;
+      }
+    };
+
+  }
+
+  template <typename Value, typename Iterator, typename Functor>
+  Iterator radixSortPartition(Iterator first, Iterator last, 
+			      Functor functor, Value mask) {
+    while (first != last && !(functor(*first) & mask)) {
+      ++first;
+    }
+    if (first == last) {
+      return first;
+    }
+    --last;
+    while (first != last && (functor(*last) & mask)) {
+      --last;
+    }
+    if (first == last) {
+      return first;
+    }
+    std::iter_swap(first, last);
+    ++first;
+    if (!(first < last)) {
+      return first;
+    }
+    while (true) {
+      while (!(functor(*first) & mask)) {
+	++first;
+      }
+      --last;
+      while (functor(*last) & mask) {
+	--last;
+      }
+      if (!(first < last)) {
+	return first;
+      }
+      std::iter_swap(first, last);
+      ++first;
+    }
+  }
+
+  template <typename Iterator, typename Functor>
+  Iterator radixSortSignPartition(Iterator first, Iterator last, 
+				  Functor functor) {
+    while (first != last && functor(*first) < 0) {
+      ++first;
+    }
+    if (first == last) {
+      return first;
+    }
+    --last;
+    while (first != last && functor(*last) >= 0) {
+      --last;
+    }
+    if (first == last) {
+      return first;
+    }
+    std::iter_swap(first, last);
+    ++first;
+    if (!(first < last)) {
+      return first;
+    }
+    while (true) {
+      while (functor(*first) < 0) {
+	++first;
+      }
+      --last;
+      while (functor(*last) >= 0) {
+	--last;
+      }
+      if (!(first < last)) {
+	return first;
+      }
+      std::iter_swap(first, last);
+      ++first;
+    }
+  }
+
+  template <typename Value, typename Iterator, typename Functor>
+  void radixIntroSort(Iterator first, Iterator last, 
+		      Functor functor, Value mask) {
+    while (mask != 0 && last - first > 1) {
+      Iterator cut = radixSortPartition(first, last, functor, mask);
+      mask >>= 1;
+      radixIntroSort(first, cut, functor, mask);
+      first = cut;
+    }
+  }
+
+  template <typename Value, typename Iterator, typename Functor>
+  void radixSignedSort(Iterator first, Iterator last, Functor functor) {
+    Iterator cut = radixSortSignPartition(first, last, functor);
+
+    Value mask;
+    int max_digit;
+    Iterator it;
+
+    mask = ~0; max_digit = 0;
+    for (it = first; it != cut; ++it) {
+      while ((mask & functor(*it)) != mask) {
+	++max_digit;
+	mask <<= 1;
+      }
+    }
+    radixIntroSort(first, cut, functor, 1 << max_digit);
+
+    mask = 0; max_digit = 0;
+    for (it = cut; it != last; ++it) {
+      while ((mask | functor(*it)) != mask) {
+	++max_digit;
+	mask <<= 1; mask |= 1;
+      }
+    }
+    radixIntroSort(cut, last, functor, 1 << max_digit);
+  }
+
+  template <typename Value, typename Iterator, typename Functor>
+  void radixUnsignedSort(Iterator first, Iterator last, Functor functor) {
+
+    Value mask = 0;
+    int max_digit = 0;
+
+    Iterator it;
+    for (it = first; it != last; ++it) {
+      while ((mask | functor(*it)) != mask) {
+	++max_digit;
+	mask <<= 1; mask |= 1;
+      }
+    }
+    radixIntroSort(first, last, functor, 1 << max_digit);
+  }
+
+  namespace _radix_sort_bits {
+
+    template <typename Value, 
+	      bool sign = std::numeric_limits<Value>::is_signed >
+    struct RadixSortSelector {
+      template <typename Iterator, typename Functor>
+      static void sort(Iterator first, Iterator last, Functor functor) {
+	radixSignedSort<Value>(first, last, functor);
+      }
+    };
+
+    template <typename Value>
+    struct RadixSortSelector<Value, false> {
+      template <typename Iterator, typename Functor>
+      static void sort(Iterator first, Iterator last, Functor functor) {
+	radixUnsignedSort<Value>(first, last, functor);
+      }
+    };
+
+  }
+
+  /// \ingroup auxalg
+  ///
+  /// \brief Sorts the stl compatible range into ascending order.
+  ///
+  /// The \c radixSort sorts the stl compatible range into ascending order.
+  /// The radix sort algorithm can sort the items which mapped to an
+  /// integer by the adaptable unary function \c functor and the order
+  /// will be ascending by these mapped values. As function specialization
+  /// there is possible to use a normal function as the functor object
+  /// or if the functor is not given it will use an identity function instead.
+  ///
+  /// This implemented radix sort is a special quick sort which pivot value
+  /// is choosen to partite the items on the next bit. This way, let be
+  /// \c c the maximal capacity and \c n the number of the items in
+  /// the container, the time complexity of the algorithm 
+  /// \f$ O(\log(c)n) \f$ and the additional space complexity is 
+  /// \f$ O(\log(c)) \f$.
+  ///
+  /// \param first The begin of the given range.
+  /// \param last The end of the given range.
+  /// \param functor An adaptible unary function or a normal function which
+  /// maps the items to any integer type which can be wheter signed or 
+  /// unsigned.
+  template <typename Iterator, typename Functor>
+  void radixSort(Iterator first, Iterator last, Functor functor) {
+    using namespace _radix_sort_bits;
+    typedef typename Functor::result_type Value;
+    RadixSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator, typename Value, typename Key>
+  void radixSort(Iterator first, Iterator last, Value (*functor)(Key)) {
+    using namespace _radix_sort_bits;
+    RadixSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator, typename Value, typename Key>
+  void radixSort(Iterator first, Iterator last, Value& (*functor)(Key)) {
+    using namespace _radix_sort_bits;
+    RadixSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator, typename Value, typename Key>
+  void radixSort(Iterator first, Iterator last, Value (*functor)(Key&)) {
+    using namespace _radix_sort_bits;
+    RadixSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator, typename Value, typename Key>
+  void radixSort(Iterator first, Iterator last, Value& (*functor)(Key&)) {
+    using namespace _radix_sort_bits;
+    RadixSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator>
+  void radixSort(Iterator first, Iterator last) {
+    using namespace _radix_sort_bits;
+    typedef typename std::iterator_traits<Iterator>::value_type Value;
+    RadixSortSelector<Value>::sort(first, last, Identity<Value>());
+  }
+
+  template <typename Value>
+  unsigned char valueByte(Value value, int byte) {
+    return value >> (std::numeric_limits<unsigned char>::digits * byte);
+  }
+
+  template <typename Functor, typename Key>
+  void counterIntroSort(Key *first, Key *last, Key *target, 
+		       int byte, Functor functor) {
+    const int size = 
+      unsigned(std::numeric_limits<unsigned char>::max()) + 1;
+    std::vector<int> counter(size);
+    for (int i = 0; i < size; ++i) {
+      counter[i] = 0;
+    }
+    Key *it = first;
+    while (first != last) {
+      ++counter[valueByte(functor(*first), byte)]; 
+      ++first;
+    }
+    int prev, num = 0;
+    for (int i = 0; i < size; ++i) {
+      prev = num;
+      num += counter[i];
+      counter[i] = prev;
+    }
+    while (it != last) {
+      target[counter[valueByte(functor(*it), byte)]++] = *it;
+      ++it;
+    }
+  }
+
+  template <typename Functor, typename Key>
+  void signedCounterIntroSort(Key *first, Key *last, Key *target, 
+			     int byte, Functor functor) {
+    const int size = 
+      unsigned(std::numeric_limits<unsigned char>::max()) + 1;
+    std::vector<int> counter(size);
+    for (int i = 0; i < size; ++i) {
+      counter[i] = 0;
+    }
+    Key *it = first;
+    while (first != last) {
+      counter[valueByte(functor(*first), byte)]++;
+      ++first;
+    }
+    int prev, num = 0;
+    for (int i = size / 2; i < size; ++i) {
+      prev = num;
+      num += counter[i];
+      counter[i] = prev;
+    }
+    for (int i = 0; i < size / 2; ++i) {
+      prev = num;
+      num += counter[i];
+      counter[i] = prev;
+    }
+    while (it != last) {
+      target[counter[valueByte(functor(*it), byte)]++] = *it;
+      ++it;
+    }
+  }
+
+  
+  template <typename Value, typename Iterator, typename Functor>
+  void counterSignedSort(Iterator first, Iterator last, Functor functor) {
+    if (first == last) return;
+    typedef typename std::iterator_traits<Iterator>::value_type Key;
+    typedef std::allocator<Key> Allocator;
+    Allocator allocator;
+
+    int length = std::distance(first, last);
+    Key* buffer = allocator.allocate(2 * length);
+    try {
+      bool dir = true;
+      std::copy(first, last, buffer);
+      for (int i = 0; i < int(sizeof(Value)) - 1; ++i) {
+	if (dir) {
+	  counterIntroSort(buffer, buffer + length, buffer + length, 
+			   i, functor);
+	} else {
+	  counterIntroSort(buffer + length, buffer + 2 * length, buffer, 
+			   i, functor);
+	}
+	dir = !dir;
+      }
+      if (dir) {
+	signedCounterIntroSort(buffer, buffer + length, buffer + length, 
+			       sizeof(Value) - 1, functor);
+	std::copy(buffer + length, buffer + 2 * length, first);
+      }	else {
+	signedCounterIntroSort(buffer + length, buffer + 2 * length, buffer, 
+			       sizeof(Value) - 1, functor);
+	std::copy(buffer, buffer + length, first);
+      }
+    } catch (...) {
+      allocator.deallocate(buffer, 2 * length);
+      throw;
+    }
+    allocator.deallocate(buffer, 2 * length);
+  }
+
+  template <typename Value, typename Iterator, typename Functor>
+  void counterUnsignedSort(Iterator first, Iterator last, Functor functor) {
+    if (first == last) return;
+    typedef typename std::iterator_traits<Iterator>::value_type Key;
+    typedef std::allocator<Key> Allocator;
+    Allocator allocator;
+
+    int length = std::distance(first, last);
+    Key *buffer = allocator.allocate(2 * length);
+    try {
+      bool dir = true;
+      std::copy(first, last, buffer);
+      for (int i = 0; i < int(sizeof(Value)); ++i) {
+	if (dir) {
+	  counterIntroSort(buffer, buffer + length, 
+                           buffer + length, i, functor);
+	} else {
+	  counterIntroSort(buffer + length, buffer + 2 * length, 
+                           buffer, i, functor);
+	}
+	dir = !dir;
+      }
+      if (dir) {
+	std::copy(buffer, buffer + length, first);
+      }	else {
+	std::copy(buffer + length, buffer + 2 * length, first);
+      }
+    } catch (...) {
+      allocator.deallocate(buffer, 2 * length);
+      throw;
+    }
+    allocator.deallocate(buffer, 2 * length);
+  }
+
+  namespace _radix_sort_bits {
+
+    template <typename Value, 
+	      bool sign = std::numeric_limits<Value>::is_signed >
+    struct CounterSortSelector {
+      template <typename Iterator, typename Functor>
+      static void sort(Iterator first, Iterator last, Functor functor) {
+	counterSignedSort<Value>(first, last, functor);
+      }
+    };
+
+    template <typename Value>
+    struct CounterSortSelector<Value, false> {
+      template <typename Iterator, typename Functor>
+      static void sort(Iterator first, Iterator last, Functor functor) {
+	counterUnsignedSort<Value>(first, last, functor);
+      }
+    };
+
+  }
+
+  /// \ingroup auxalg
+  ///
+  /// \brief Sorts stable the stl compatible range into ascending order.
+  ///
+  /// The \c counterSort sorts the stl compatible range into ascending order.
+  /// The counter sort algorithm can sort the items which mapped to an
+  /// integer by the adaptable unary function \c functor and the order
+  /// will be ascending by these mapped values. As function specialization
+  /// there is possible to use a normal function as the functor object
+  /// or if the functor is not given it will use an identity function instead.
+  ///
+  /// This implemented counter sort use a radix forward sort on the bytes of
+  /// the integer. The algorithm can sort the items on a given byte. 
+  /// First time it counts how many times occurs a byte value in the container.
+  /// By the occurence number it is possible to copy the container
+  /// in the right order in \c O(n) time. The algorithm sorts the container
+  /// by each bytes in forward direction which sorts the container by the
+  /// whole value. This way, let be \c c the maximal capacity of the integer 
+  /// type and \c n the number of the items in
+  /// the container, the time complexity of the algorithm \f$ O(\log(c)n) \f$
+  /// and the additional space complexity is \f$ O(n) \f$.
+  ///
+  /// This sorting algorithm is stable so the order of two equal element
+  /// stay in the same order.
+  ///
+  /// \param first The begin of the given range.
+  /// \param last The end of the given range.
+  /// \param functor An adaptible unary function or a normal function which
+  /// maps the items to any integer type which can be wheter signed or 
+  /// unsigned.
+  template <typename Iterator, typename Functor>
+  void counterSort(Iterator first, Iterator last, Functor functor) {
+    using namespace _radix_sort_bits;
+    typedef typename Functor::result_type Value;
+    CounterSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator, typename Value, typename Key>
+  void counterSort(Iterator first, Iterator last, Value (*functor)(Key)) {
+    using namespace _radix_sort_bits;
+    CounterSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator, typename Value, typename Key>
+  void counterSort(Iterator first, Iterator last, Value& (*functor)(Key)) {
+    using namespace _radix_sort_bits;
+    CounterSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator, typename Value, typename Key>
+  void counterSort(Iterator first, Iterator last, Value (*functor)(Key&)) {
+    using namespace _radix_sort_bits;
+    CounterSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator, typename Value, typename Key>
+  void counterSort(Iterator first, Iterator last, Value& (*functor)(Key&)) {
+    using namespace _radix_sort_bits;
+    CounterSortSelector<Value>::sort(first, last, functor);
+  }
+
+  template <typename Iterator>
+  void counterSort(Iterator first, Iterator last) {
+    using namespace _radix_sort_bits;
+    typedef typename std::iterator_traits<Iterator>::value_type Value;
+    CounterSortSelector<Value>::sort(first, last, Identity<Value>());
+  }
+
+}
+
+
+
+#endif
Index: lemon/random.cc
===================================================================
--- lemon/random.cc	(revision 2553)
+++ lemon/random.cc	(revision 2553)
@@ -0,0 +1,29 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\file
+///\brief Instantiation of the Random class.
+
+#include <lemon/random.h>
+
+namespace lemon {
+  /// \brief Global random number generator instance
+  ///
+  /// A global mersenne twister random number generator instance
+  Random rnd;
+}
Index: lemon/random.h
===================================================================
--- lemon/random.h	(revision 2618)
+++ lemon/random.h	(revision 2618)
@@ -0,0 +1,874 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+/*
+ * This file contains the reimplemented version of the Mersenne Twister
+ * Generator of Matsumoto and Nishimura.
+ *
+ * See the appropriate copyright notice below.
+ * 
+ * Copyright (C) 1997 - 2002, Makoto Matsumoto and Takuji Nishimura,
+ * All rights reserved.                          
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * 3. The names of its contributors may not be used to endorse or promote 
+ *    products derived from this software without specific prior written 
+ *    permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
+ * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
+ * OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ *
+ * Any feedback is very welcome.
+ * http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/emt.html
+ * email: m-mat @ math.sci.hiroshima-u.ac.jp (remove space)
+ */
+
+#ifndef LEMON_RANDOM_H
+#define LEMON_RANDOM_H
+
+#include <algorithm>
+#include <iterator>
+#include <vector>
+
+#include <ctime>
+#include <limits>
+
+#include <lemon/math.h>
+#include <lemon/dim2.h>
+///\ingroup misc
+///\file
+///\brief Mersenne Twister random number generator
+///
+///\author Balazs Dezso
+
+namespace lemon {
+
+  namespace _random_bits {
+    
+    template <typename _Word, int _bits = std::numeric_limits<_Word>::digits>
+    struct RandomTraits {};
+
+    template <typename _Word>
+    struct RandomTraits<_Word, 32> {
+
+      typedef _Word Word;
+      static const int bits = 32;
+
+      static const int length = 624;
+      static const int shift = 397;
+      
+      static const Word mul = 0x6c078965u;
+      static const Word arrayInit = 0x012BD6AAu;
+      static const Word arrayMul1 = 0x0019660Du;
+      static const Word arrayMul2 = 0x5D588B65u;
+
+      static const Word mask = 0x9908B0DFu;
+      static const Word loMask = (1u << 31) - 1;
+      static const Word hiMask = ~loMask;
+
+
+      static Word tempering(Word rnd) {
+        rnd ^= (rnd >> 11);
+        rnd ^= (rnd << 7) & 0x9D2C5680u;
+        rnd ^= (rnd << 15) & 0xEFC60000u;
+        rnd ^= (rnd >> 18);
+        return rnd;
+      }
+
+    };
+
+    template <typename _Word>
+    struct RandomTraits<_Word, 64> {
+
+      typedef _Word Word;
+      static const int bits = 64;
+
+      static const int length = 312;
+      static const int shift = 156;
+
+      static const Word mul = Word(0x5851F42Du) << 32 | Word(0x4C957F2Du);
+      static const Word arrayInit = Word(0x00000000u) << 32 |Word(0x012BD6AAu);
+      static const Word arrayMul1 = Word(0x369DEA0Fu) << 32 |Word(0x31A53F85u);
+      static const Word arrayMul2 = Word(0x27BB2EE6u) << 32 |Word(0x87B0B0FDu);
+
+      static const Word mask = Word(0xB5026F5Au) << 32 | Word(0xA96619E9u);
+      static const Word loMask = (Word(1u) << 31) - 1;
+      static const Word hiMask = ~loMask;
+
+      static Word tempering(Word rnd) {
+        rnd ^= (rnd >> 29) & (Word(0x55555555u) << 32 | Word(0x55555555u));
+        rnd ^= (rnd << 17) & (Word(0x71D67FFFu) << 32 | Word(0xEDA60000u));
+        rnd ^= (rnd << 37) & (Word(0xFFF7EEE0u) << 32 | Word(0x00000000u));
+        rnd ^= (rnd >> 43);
+        return rnd;
+      }
+
+    };
+
+    template <typename _Word>
+    class RandomCore {
+    public:
+
+      typedef _Word Word;
+
+    private:
+
+      static const int bits = RandomTraits<Word>::bits;
+
+      static const int length = RandomTraits<Word>::length;
+      static const int shift = RandomTraits<Word>::shift;
+
+    public:
+
+      void initState() {
+        static const Word seedArray[4] = {
+          0x12345u, 0x23456u, 0x34567u, 0x45678u
+        };
+    
+        initState(seedArray, seedArray + 4);
+      }
+
+      void initState(Word seed) {
+
+        static const Word mul = RandomTraits<Word>::mul;
+
+        current = state; 
+
+        Word *curr = state + length - 1;
+        curr[0] = seed; --curr;
+        for (int i = 1; i < length; ++i) {
+          curr[0] = (mul * ( curr[1] ^ (curr[1] >> (bits - 2)) ) + i);
+          --curr;
+        }
+      }
+
+      template <typename Iterator>
+      void initState(Iterator begin, Iterator end) {
+
+        static const Word init = RandomTraits<Word>::arrayInit;
+        static const Word mul1 = RandomTraits<Word>::arrayMul1;
+        static const Word mul2 = RandomTraits<Word>::arrayMul2;
+
+
+        Word *curr = state + length - 1; --curr;
+        Iterator it = begin; int cnt = 0;
+        int num;
+
+        initState(init);
+
+        num = length > end - begin ? length : end - begin;
+        while (num--) {
+          curr[0] = (curr[0] ^ ((curr[1] ^ (curr[1] >> (bits - 2))) * mul1)) 
+            + *it + cnt;
+          ++it; ++cnt;
+          if (it == end) {
+            it = begin; cnt = 0;
+          }
+          if (curr == state) {
+            curr = state + length - 1; curr[0] = state[0];
+          }
+          --curr;
+        }
+
+        num = length - 1; cnt = length - (curr - state) - 1;
+        while (num--) {
+          curr[0] = (curr[0] ^ ((curr[1] ^ (curr[1] >> (bits - 2))) * mul2))
+            - cnt;
+          --curr; ++cnt;
+          if (curr == state) {
+            curr = state + length - 1; curr[0] = state[0]; --curr;
+            cnt = 1;
+          }
+        }
+        
+        state[length - 1] = Word(1) << (bits - 1);
+      }
+      
+      void copyState(const RandomCore& other) {
+        std::copy(other.state, other.state + length, state);
+        current = state + (other.current - other.state);
+      }
+
+      Word operator()() {
+        if (current == state) fillState();
+        --current;
+        Word rnd = *current;
+        return RandomTraits<Word>::tempering(rnd);
+      }
+
+    private:
+
+  
+      void fillState() {
+        static const Word mask[2] = { 0x0ul, RandomTraits<Word>::mask };
+        static const Word loMask = RandomTraits<Word>::loMask;
+        static const Word hiMask = RandomTraits<Word>::hiMask;
+
+        current = state + length; 
+
+        register Word *curr = state + length - 1;
+        register long num;
+      
+        num = length - shift;
+        while (num--) {
+          curr[0] = (((curr[0] & hiMask) | (curr[-1] & loMask)) >> 1) ^
+            curr[- shift] ^ mask[curr[-1] & 1ul];
+          --curr;
+        }
+        num = shift - 1;
+        while (num--) {
+          curr[0] = (((curr[0] & hiMask) | (curr[-1] & loMask)) >> 1) ^
+            curr[length - shift] ^ mask[curr[-1] & 1ul];
+          --curr;
+        }
+        state[0] = (((state[0] & hiMask) | (curr[length - 1] & loMask)) >> 1) ^
+          curr[length - shift] ^ mask[int(curr[length - 1] & 1ul)];
+
+      }
+
+  
+      Word *current;
+      Word state[length];
+      
+    };
+
+
+    template <typename Result, 
+              int shift = (std::numeric_limits<Result>::digits + 1) / 2>
+    struct Masker {
+      static Result mask(const Result& result) {
+        return Masker<Result, (shift + 1) / 2>::
+          mask(static_cast<Result>(result | (result >> shift)));
+      }
+    };
+    
+    template <typename Result>
+    struct Masker<Result, 1> {
+      static Result mask(const Result& result) {
+        return static_cast<Result>(result | (result >> 1));
+      }
+    };
+
+    template <typename Result, typename Word, 
+              int rest = std::numeric_limits<Result>::digits, int shift = 0, 
+              bool last = rest <= std::numeric_limits<Word>::digits>
+    struct IntConversion {
+      static const int bits = std::numeric_limits<Word>::digits;
+    
+      static Result convert(RandomCore<Word>& rnd) {
+        return static_cast<Result>(rnd() >> (bits - rest)) << shift;
+      }
+      
+    }; 
+
+    template <typename Result, typename Word, int rest, int shift> 
+    struct IntConversion<Result, Word, rest, shift, false> {
+      static const int bits = std::numeric_limits<Word>::digits;
+
+      static Result convert(RandomCore<Word>& rnd) {
+        return (static_cast<Result>(rnd()) << shift) | 
+          IntConversion<Result, Word, rest - bits, shift + bits>::convert(rnd);
+      }
+    };
+
+
+    template <typename Result, typename Word,
+              bool one_word = (std::numeric_limits<Word>::digits < 
+			       std::numeric_limits<Result>::digits) >
+    struct Mapping {
+      static Result map(RandomCore<Word>& rnd, const Result& bound) {
+        Word max = Word(bound - 1);
+        Result mask = Masker<Result>::mask(bound - 1);
+        Result num;
+        do {
+          num = IntConversion<Result, Word>::convert(rnd) & mask; 
+        } while (num > max);
+        return num;
+      }
+    };
+
+    template <typename Result, typename Word>
+    struct Mapping<Result, Word, false> {
+      static Result map(RandomCore<Word>& rnd, const Result& bound) {
+        Word max = Word(bound - 1);
+        Word mask = Masker<Word, (std::numeric_limits<Result>::digits + 1) / 2>
+          ::mask(max);
+        Word num;
+        do {
+          num = rnd() & mask;
+        } while (num > max);
+        return num;
+      }
+    };
+
+    template <typename Result, int exp, bool pos = (exp >= 0)>
+    struct ShiftMultiplier {
+      static const Result multiplier() {
+        Result res = ShiftMultiplier<Result, exp / 2>::multiplier();
+        res *= res;
+        if ((exp & 1) == 1) res *= static_cast<Result>(2.0);
+        return res; 
+      }
+    };
+
+    template <typename Result, int exp>
+    struct ShiftMultiplier<Result, exp, false> {
+      static const Result multiplier() {
+        Result res = ShiftMultiplier<Result, exp / 2>::multiplier();
+        res *= res;
+        if ((exp & 1) == 1) res *= static_cast<Result>(0.5);
+        return res; 
+      }
+    };
+
+    template <typename Result>
+    struct ShiftMultiplier<Result, 0, true> {
+      static const Result multiplier() {
+        return static_cast<Result>(1.0); 
+      }
+    };
+
+    template <typename Result>
+    struct ShiftMultiplier<Result, -20, true> {
+      static const Result multiplier() {
+        return static_cast<Result>(1.0/1048576.0); 
+      }
+    };
+    
+    template <typename Result>
+    struct ShiftMultiplier<Result, -32, true> {
+      static const Result multiplier() {
+        return static_cast<Result>(1.0/424967296.0); 
+      }
+    };
+
+    template <typename Result>
+    struct ShiftMultiplier<Result, -53, true> {
+      static const Result multiplier() {
+        return static_cast<Result>(1.0/9007199254740992.0); 
+      }
+    };
+
+    template <typename Result>
+    struct ShiftMultiplier<Result, -64, true> {
+      static const Result multiplier() {
+        return static_cast<Result>(1.0/18446744073709551616.0); 
+      }
+    };
+
+    template <typename Result, int exp>
+    struct Shifting {
+      static Result shift(const Result& result) {
+        return result * ShiftMultiplier<Result, exp>::multiplier();
+      }
+    };
+
+    template <typename Result, typename Word,
+              int rest = std::numeric_limits<Result>::digits, int shift = 0, 
+              bool last = rest <= std::numeric_limits<Word>::digits>
+    struct RealConversion{ 
+      static const int bits = std::numeric_limits<Word>::digits;
+
+      static Result convert(RandomCore<Word>& rnd) {
+        return Shifting<Result, - shift - rest>::
+          shift(static_cast<Result>(rnd() >> (bits - rest)));
+      }
+    };
+
+    template <typename Result, typename Word, int rest, int shift>
+    struct RealConversion<Result, Word, rest, shift, false> { 
+      static const int bits = std::numeric_limits<Word>::digits;
+
+      static Result convert(RandomCore<Word>& rnd) {
+        return Shifting<Result, - shift - bits>::
+          shift(static_cast<Result>(rnd())) +
+          RealConversion<Result, Word, rest-bits, shift + bits>::
+          convert(rnd);
+      }
+    };
+
+    template <typename Result, typename Word>
+    struct Initializer {
+
+      template <typename Iterator>
+      static void init(RandomCore<Word>& rnd, Iterator begin, Iterator end) {
+        std::vector<Word> ws;
+        for (Iterator it = begin; it != end; ++it) {
+          ws.push_back(Word(*it));
+        }
+        rnd.initState(ws.begin(), ws.end());
+      }
+
+      static void init(RandomCore<Word>& rnd, Result seed) {
+        rnd.initState(seed);
+      }
+    };
+
+    template <typename Word>
+    struct BoolConversion {
+      static bool convert(RandomCore<Word>& rnd) {
+        return (rnd() & 1) == 1;
+      }
+    };
+
+    template <typename Word>
+    struct BoolProducer {
+      Word buffer;
+      int num;
+      
+      BoolProducer() : num(0) {}
+
+      bool convert(RandomCore<Word>& rnd) {
+        if (num == 0) {
+          buffer = rnd();
+          num = RandomTraits<Word>::bits;
+        }
+        bool r = (buffer & 1);
+        buffer >>= 1;
+        --num;
+        return r;
+      }
+    };
+
+  }
+
+  /// \ingroup misc
+  ///
+  /// \brief Mersenne Twister random number generator
+  ///
+  /// The Mersenne Twister is a twisted generalized feedback
+  /// shift-register generator of Matsumoto and Nishimura. The period
+  /// of this generator is \f$ 2^{19937} - 1 \f$ and it is
+  /// equi-distributed in 623 dimensions for 32-bit numbers. The time
+  /// performance of this generator is comparable to the commonly used
+  /// generators.
+  ///
+  /// This implementation is specialized for both 32-bit and 64-bit
+  /// architectures. The generators differ sligthly in the
+  /// initialization and generation phase so they produce two
+  /// completly different sequences.
+  ///
+  /// The generator gives back random numbers of serveral types. To
+  /// get a random number from a range of a floating point type you
+  /// can use one form of the \c operator() or the \c real() member
+  /// function. If you want to get random number from the {0, 1, ...,
+  /// n-1} integer range use the \c operator[] or the \c integer()
+  /// method. And to get random number from the whole range of an
+  /// integer type you can use the argumentless \c integer() or \c
+  /// uinteger() functions. After all you can get random bool with
+  /// equal chance of true and false or given probability of true
+  /// result with the \c boolean() member functions.
+  ///
+  ///\code
+  /// // The commented code is identical to the other
+  /// double a = rnd();                     // [0.0, 1.0)
+  /// // double a = rnd.real();             // [0.0, 1.0)
+  /// double b = rnd(100.0);                // [0.0, 100.0)
+  /// // double b = rnd.real(100.0);        // [0.0, 100.0)
+  /// double c = rnd(1.0, 2.0);             // [1.0, 2.0)
+  /// // double c = rnd.real(1.0, 2.0);     // [1.0, 2.0)
+  /// int d = rnd[100000];                  // 0..99999
+  /// // int d = rnd.integer(100000);       // 0..99999
+  /// int e = rnd[6] + 1;                   // 1..6
+  /// // int e = rnd.integer(1, 1 + 6);     // 1..6
+  /// int b = rnd.uinteger<int>();          // 0 .. 2^31 - 1
+  /// int c = rnd.integer<int>();           // - 2^31 .. 2^31 - 1
+  /// bool g = rnd.boolean();               // P(g = true) = 0.5
+  /// bool h = rnd.boolean(0.8);            // P(h = true) = 0.8
+  ///\endcode
+  ///
+  /// The lemon provides a global instance of the random number
+  /// generator which name is \ref lemon::rnd "rnd". Usually it is a
+  /// good programming convenience to use this global generator to get
+  /// random numbers.
+  ///
+  /// \author Balazs Dezso
+  class Random {
+  private:
+
+    // architecture word
+    typedef unsigned long Word;
+    
+    _random_bits::RandomCore<Word> core;
+    _random_bits::BoolProducer<Word> bool_producer;
+    
+
+  public:
+
+    /// \brief Constructor
+    ///
+    /// Constructor with constant seeding.
+    Random() { core.initState(); }
+
+    /// \brief Constructor
+    ///
+    /// Constructor with seed. The current number type will be converted
+    /// to the architecture word type.
+    template <typename Number>
+    Random(Number seed) { 
+      _random_bits::Initializer<Number, Word>::init(core, seed);
+    }
+
+    /// \brief Constructor
+    ///
+    /// Constructor with array seeding. The given range should contain
+    /// any number type and the numbers will be converted to the
+    /// architecture word type.
+    template <typename Iterator>
+    Random(Iterator begin, Iterator end) { 
+      typedef typename std::iterator_traits<Iterator>::value_type Number;
+      _random_bits::Initializer<Number, Word>::init(core, begin, end);
+    }
+
+    /// \brief Copy constructor
+    ///
+    /// Copy constructor. The generated sequence will be identical to
+    /// the other sequence. It can be used to save the current state
+    /// of the generator and later use it to generate the same
+    /// sequence.
+    Random(const Random& other) {
+      core.copyState(other.core);
+    }
+
+    /// \brief Assign operator
+    ///
+    /// Assign operator. The generated sequence will be identical to
+    /// the other sequence. It can be used to save the current state
+    /// of the generator and later use it to generate the same
+    /// sequence.
+    Random& operator=(const Random& other) {
+      if (&other != this) {
+        core.copyState(other.core);
+      }
+      return *this;
+    }
+
+    /// \brief Seeding random sequence
+    ///
+    /// Seeding the random sequence. The current number type will be
+    /// converted to the architecture word type.
+    template <typename Number>
+    void seed(Number seed) { 
+      _random_bits::Initializer<Number, Word>::init(core, seed);
+    }
+
+    /// \brief Seeding random sequence
+    ///
+    /// Seeding the random sequence. The given range should contain
+    /// any number type and the numbers will be converted to the
+    /// architecture word type.
+    template <typename Iterator>
+    void seed(Iterator begin, Iterator end) { 
+      typedef typename std::iterator_traits<Iterator>::value_type Number;
+      _random_bits::Initializer<Number, Word>::init(core, begin, end);
+    }
+
+    /// \brief Returns a random real number from the range [0, 1)
+    ///
+    /// It returns a random real number from the range [0, 1). The
+    /// default Number type is double.
+    template <typename Number>
+    Number real() {
+      return _random_bits::RealConversion<Number, Word>::convert(core);
+    }
+
+    double real() {
+      return real<double>();
+    }
+
+    /// \brief Returns a random real number the range [0, b)
+    ///
+    /// It returns a random real number from the range [0, b).
+    template <typename Number>
+    Number real(Number b) { 
+      return real<Number>() * b; 
+    }
+
+    /// \brief Returns a random real number from the range [a, b)
+    ///
+    /// It returns a random real number from the range [a, b).
+    template <typename Number>
+    Number real(Number a, Number b) { 
+      return real<Number>() * (b - a) + a; 
+    }
+
+    /// \brief Returns a random real number from the range [0, 1)
+    ///
+    /// It returns a random double from the range [0, 1).
+    double operator()() {
+      return real<double>();
+    }
+
+    /// \brief Returns a random real number from the range [0, b)
+    ///
+    /// It returns a random real number from the range [0, b).
+    template <typename Number>
+    Number operator()(Number b) { 
+      return real<Number>() * b; 
+    }
+
+    /// \brief Returns a random real number from the range [a, b)
+    ///
+    /// It returns a random real number from the range [a, b).
+    template <typename Number>
+    Number operator()(Number a, Number b) { 
+      return real<Number>() * (b - a) + a; 
+    }
+
+    /// \brief Returns a random integer from a range
+    ///
+    /// It returns a random integer from the range {0, 1, ..., b - 1}.
+    template <typename Number>
+    Number integer(Number b) {
+      return _random_bits::Mapping<Number, Word>::map(core, b);
+    }
+
+    /// \brief Returns a random integer from a range
+    ///
+    /// It returns a random integer from the range {a, a + 1, ..., b - 1}.
+    template <typename Number>
+    Number integer(Number a, Number b) {
+      return _random_bits::Mapping<Number, Word>::map(core, b - a) + a;
+    }
+
+    /// \brief Returns a random integer from a range
+    ///
+    /// It returns a random integer from the range {0, 1, ..., b - 1}.
+    template <typename Number>
+    Number operator[](Number b) {
+      return _random_bits::Mapping<Number, Word>::map(core, b);
+    }
+
+    /// \brief Returns a random non-negative integer
+    ///
+    /// It returns a random non-negative integer uniformly from the
+    /// whole range of the current \c Number type.  The default result
+    /// type of this function is unsigned int.
+    template <typename Number>
+    Number uinteger() {
+      return _random_bits::IntConversion<Number, Word>::convert(core);
+    }
+
+    unsigned int uinteger() {
+      return uinteger<unsigned int>();
+    }
+
+    /// \brief Returns a random integer
+    ///
+    /// It returns a random integer uniformly from the whole range of
+    /// the current \c Number type. The default result type of this
+    /// function is int.
+    template <typename Number>
+    Number integer() {
+      static const int nb = std::numeric_limits<Number>::digits + 
+        (std::numeric_limits<Number>::is_signed ? 1 : 0);
+      return _random_bits::IntConversion<Number, Word, nb>::convert(core);
+    }
+
+    int integer() {
+      return integer<int>();
+    }
+    
+    /// \brief Returns a random bool
+    ///
+    /// It returns a random bool. The generator holds a buffer for
+    /// random bits. Every time when it become empty the generator makes
+    /// a new random word and fill the buffer up.
+    bool boolean() {
+      return bool_producer.convert(core);
+    }
+
+    ///\name Nonuniform distributions
+    ///
+    
+    ///@{
+    
+    /// \brief Returns a random bool
+    ///
+    /// It returns a random bool with given probability of true result
+    bool boolean(double p) {
+      return operator()() < p;
+    }
+
+    /// Standard Gauss distribution
+
+    /// Standard Gauss distribution.
+    /// \note The Cartesian form of the Box-Muller
+    /// transformation is used to generate a random normal distribution.
+    /// \todo Consider using the "ziggurat" method instead.
+    double gauss() 
+    {
+      double V1,V2,S;
+      do {
+	V1=2*real<double>()-1;
+	V2=2*real<double>()-1;
+	S=V1*V1+V2*V2;
+      } while(S>=1);
+      return std::sqrt(-2*std::log(S)/S)*V1;
+    }
+    /// Gauss distribution with given standard deviation and mean 0
+
+    /// \sa gauss()
+    ///
+    double gauss(double std_dev) 
+    {
+      return gauss()*std_dev;
+    }
+    /// Gauss distribution with given mean and standard deviation
+
+    /// \sa gauss()
+    ///
+    double gauss(double mean,double std_dev)
+    {
+      return gauss()*std_dev+mean;
+    }
+
+    /// Exponential distribution with given mean
+
+    /// This function generates an exponential distribution random number
+    /// with mean <tt>1/lambda</tt>.
+    ///
+    double exponential(double lambda=1.0)
+    {
+      return -std::log(real<double>())/lambda;
+    }
+
+    double gamma(int k) 
+    {
+      double s = 0;
+      for(int i=0;i<k;i++) s-=std::log(1.0-real<double>());
+      return s;
+    }
+    
+    /// Gamma distribution with given shape and scale parameter
+
+    /// This function generates a gamma distribution random number.
+    /// 
+    ///\param k shape parameter (<tt>k>0</tt>)
+    ///\param theta scale parameter
+    ///
+    double gamma(double k,double theta=1.0)
+    {
+      double xi,nu;
+      const double delta = k-std::floor(k);
+      const double v0=E/(E-delta);
+      do {
+	double V0=1.0-real<double>();
+	double V1=1.0-real<double>();
+	double V2=1.0-real<double>();
+	if(V2<=v0) 
+	  {
+	    xi=std::pow(V1,1.0/delta);
+	    nu=V0*std::pow(xi,delta-1.0);
+	  }
+	else 
+	  {
+	    xi=1.0-std::log(V1);
+	    nu=V0*std::exp(-xi);
+	  }
+      } while(nu>std::pow(xi,delta-1.0)*std::exp(-xi));
+      return theta*(xi+gamma(int(std::floor(k))));
+    }
+    
+      
+    ///@}
+    
+    ///\name Two dimensional distributions
+    ///
+
+    ///@{
+    
+    /// Uniform distribution on the full unit circle.
+    dim2::Point<double> disc() 
+    {
+      double V1,V2;
+      do {
+	V1=2*real<double>()-1;
+	V2=2*real<double>()-1;
+	
+      } while(V1*V1+V2*V2>=1);
+      return dim2::Point<double>(V1,V2);
+    }
+    /// A kind of two dimensional Gauss distribution
+
+    /// This function provides a turning symmetric two-dimensional distribution.
+    /// Both coordinates are of standard normal distribution, but they are not
+    /// independent.
+    ///
+    /// \note The coordinates are the two random variables provided by
+    /// the Box-Muller method.
+    dim2::Point<double> gauss2()
+    {
+      double V1,V2,S;
+      do {
+	V1=2*real<double>()-1;
+	V2=2*real<double>()-1;
+	S=V1*V1+V2*V2;
+      } while(S>=1);
+      double W=std::sqrt(-2*std::log(S)/S);
+      return dim2::Point<double>(W*V1,W*V2);
+    }
+    /// A kind of two dimensional exponential distribution
+
+    /// This function provides a turning symmetric two-dimensional distribution.
+    /// The x-coordinate is of conditionally exponential distribution
+    /// with the condition that x is positive and y=0. If x is negative and 
+    /// y=0 then, -x is of exponential distribution. The same is true for the
+    /// y-coordinate.
+    dim2::Point<double> exponential2() 
+    {
+      double V1,V2,S;
+      do {
+	V1=2*real<double>()-1;
+	V2=2*real<double>()-1;
+	S=V1*V1+V2*V2;
+      } while(S>=1);
+      double W=-std::log(S)/S;
+      return dim2::Point<double>(W*V1,W*V2);
+    }
+
+    ///@}    
+  };
+
+
+  extern Random rnd;
+
+}
+
+#endif
Index: lemon/refptr.h
===================================================================
--- lemon/refptr.h	(revision 2553)
+++ lemon/refptr.h	(revision 2553)
@@ -0,0 +1,172 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_REFPTR_H
+#define LEMON_REFPTR_H
+
+///\ingroup misc
+///\file
+///\brief A reference counted pointer implementation.
+///
+///\todo Undocumented
+
+
+namespace lemon {
+
+  
+  ///Reference counted pointer
+
+  ///This is a simple implementation of a reference counted pointer.
+  ///
+  ///\warning Current implementation is far from being thread-safe.
+  template<class T>
+  class RefPtr 
+  {
+    mutable RefPtr *prev, *next;
+    T *ref;
+
+    void lock() {}
+    void unlock() {}
+    
+    void attach(RefPtr &r) 
+    {
+      if(r.ref) {
+	prev=&r; next=r.next; ref=r.ref;
+	r.next=this;
+      }
+    }
+    void attach(const T *p) 
+    {
+      prev=0; next=0; ref=p;
+    }
+    void release() 
+    {
+      if(ref) {
+	bool fr=true;
+	if(prev) { fr=false; prev->next=next; }
+	if(next) { fr=false; next->prev=prev; }
+	if(fr) delete ref;
+	ref=0;
+      }
+    }
+  
+  public:
+    ///\e
+    RefPtr() : ref(0) {}
+
+    ///\e
+    RefPtr(const RefPtr &r) {
+      lock();
+      attach(const_cast<RefPtr&>(r));
+      unlock();
+    }
+
+    ///\e
+    RefPtr(T *p) : prev(0), next(0), ref(p) {}
+
+    ///\e
+    ~RefPtr() {
+      lock();
+      release();
+      unlock();
+    }
+
+    ///\e
+    const RefPtr &operator=(const RefPtr &r) { 
+      if(ref!=r.ref) {
+	lock();
+	release(); attach(const_cast<RefPtr&>(r));
+	unlock();
+      }
+      return *this;
+    }
+  
+    ///\e
+    const RefPtr &operator=(const T* &p) { 
+      if(ref!=p) { lock(); release(); attach(p); unlock(); }
+      return *this;
+    }
+  
+    ///\e
+    void swap(RefPtr &r) {
+      RefPtr *p;
+      T *tp;
+      lock();
+      p=prev; prev=r.prev; r.prev=p;
+      p=next; next=r.next; r.next=p;
+      tp=ref; ref=r.ref; r.ref=tp;
+      unlock();
+    }
+
+    ///\e
+    void clear() { lock(); release(); unlock(); }
+
+    ///\e
+    T * operator->() { return ref; }
+    ///\e
+    const T * operator->() const { return ref; }
+    ///\e
+    operator T *() { return ref; }
+    ///\e
+    operator const T *() const { return ref; }
+    
+    ///\e
+    bool operator<(const RefPtr &r) const { return this->ref < r.ref; }
+    ///\e
+    bool operator<=(const RefPtr &r) const { return this->ref <= r.ref; }
+    ///\e
+    bool operator==(const RefPtr &r) const { return this->ref == r.ref; }
+    ///\e
+    bool operator>=(const RefPtr &r) const { return this->ref >= r.ref; }
+    ///\e
+    bool operator>(const RefPtr &r) const { return this->ref > r.ref; }
+    ///\e
+    bool operator!=(const RefPtr &r) const { return this->ref != r.ref; }
+    
+    ///\e
+    operator bool() const { return ref; }
+
+    ///\e
+    const RefPtr &borrow(const T* &p) { 
+      lock();
+      if(ref==p) {
+	if(prev) prev->next=next;
+	if(next) next->prev=prev;
+      }
+      else release();
+      ref=p;
+      next=prev=this;
+      unlock();
+      return *this;
+    }
+    
+    ///\e
+    const RefPtr &borrow() { 
+      lock();
+      if(prev) prev->next=next;
+      if(next) next->prev=prev;
+      next=prev=this;
+      unlock();
+      return *this;
+    }
+    
+  };  //END OF CLASS REFPTR
+  
+} //END OF NAMESPACE LEMON
+
+#endif
Index: lemon/simann.h
===================================================================
--- lemon/simann.h	(revision 2569)
+++ lemon/simann.h	(revision 2569)
@@ -0,0 +1,379 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_SIMANN_H
+#define LEMON_SIMANN_H
+
+/// \ingroup experimental
+/// \file
+/// \brief Simulated annealing framework.
+///
+/// \todo A test and some demo should be added
+/// \todo Doc should be improved
+/// \author Akos Ladanyi
+
+#include <cstdlib>
+#include <lemon/math.h>
+#include <limits>
+#include <lemon/time_measure.h>
+#include <lemon/random.h>
+
+namespace lemon {
+
+  class SimAnnBase;
+
+  /// \brief A base class for controllers.
+  class ControllerBase {
+  public:
+    friend class SimAnnBase;
+    /// \brief Pointer to the simulated annealing base class.
+    SimAnnBase *simann;
+    /// \brief Initializes the controller.
+    virtual void init() {}
+    /// \brief This is called by the simulated annealing class when a
+    /// neighbouring state gets accepted.
+    virtual void acceptEvent() {}
+    /// \brief This is called by the simulated annealing class when the
+    /// accepted neighbouring state's cost is less than the best found one's.
+    virtual void improveEvent() {}
+    /// \brief This is called by the simulated annealing class when a
+    /// neighbouring state gets rejected.
+    virtual void rejectEvent() {}
+    /// \brief Decides whether to continue the annealing process or not.
+    virtual bool next() = 0;
+    /// \brief Decides whether to accept the current solution or not.
+    virtual bool accept() = 0;
+    /// \brief Destructor.
+    virtual ~ControllerBase() {}
+  };
+
+  /// \brief Skeleton of an entity class.
+  class EntityBase {
+  public:
+    /// \brief Makes a minor change to the entity.
+    /// \return the new cost
+    virtual double mutate() = 0;
+    /// \brief Restores the entity to its previous state i.e. reverts the
+    /// effects of the last mutate().
+    virtual void revert() = 0;
+    /// \brief Makes a copy of the entity.
+    virtual EntityBase* clone() = 0;
+    /// \brief Makes a major change to the entity.
+    virtual void randomize() = 0;
+    /// \brief Destructor.
+    virtual ~EntityBase() {}
+  };
+
+  /// \brief Simulated annealing abstract base class.
+  ///
+  /// Can be used to derive a custom simulated annealing class if \ref SimAnn
+  /// doesn't fit your needs.
+  class SimAnnBase {
+  private:
+    /// \brief Pointer to the controller.
+    ControllerBase *controller;
+    /// \brief Cost of the current solution.
+    double curr_cost;
+    /// \brief Cost of the best solution.
+    double best_cost;
+    /// \brief Cost of the previous solution.
+    double prev_cost;
+    /// \brief Cost of the solution preceding the previous one.
+    double prev_prev_cost;
+    /// \brief Number of iterations.
+    long iter;
+    /// \brief Number of iterations which did not improve the solution since
+    /// the last improvement.
+    long last_impr;
+  protected:
+    /// \brief Step to a neighbouring state.
+    virtual double mutate() = 0;
+    /// \brief Reverts the last mutate().
+    virtual void revert() = 0;
+    /// \brief Saves the current solution as the best one.
+    virtual void saveAsBest() = 0;
+    /// \brief Does initializations before each run.
+    virtual void init() {
+      controller->init();
+      curr_cost = prev_cost = prev_prev_cost = best_cost =
+        std::numeric_limits<double>::infinity();
+      iter = last_impr = 0;
+    }
+  public:
+    /// \brief Sets the controller class to use.
+    void setController(ControllerBase &_controller) {
+      controller = &_controller;
+      controller->simann = this;
+    }
+    /// \brief Returns the cost of the current solution.
+    double getCurrCost() const { return curr_cost; }
+    /// \brief Returns the cost of the previous solution.
+    double getPrevCost() const { return prev_cost; }
+    /// \brief Returns the cost of the best solution.
+    double getBestCost() const { return best_cost; }
+    /// \brief Returns the number of iterations done.
+    long getIter() const { return iter; }
+    /// \brief Returns the ordinal number of the last iteration when the
+    /// solution was improved.
+    long getLastImpr() const { return last_impr; }
+    /// \brief Performs one iteration.
+    bool step() {
+      iter++;
+      prev_prev_cost = prev_cost;
+      prev_cost = curr_cost;
+      curr_cost = mutate();
+      if (controller->accept()) {
+        controller->acceptEvent();
+        last_impr = iter;
+        if (curr_cost < best_cost) {
+          best_cost = curr_cost;
+          saveAsBest();
+          controller->improveEvent();
+        }
+      }
+      else {
+        revert();
+        curr_cost = prev_cost;
+        prev_cost = prev_prev_cost;
+        controller->rejectEvent();
+      }
+      return controller->next();
+    }
+    /// \brief Performs a given number of iterations.
+    /// \param n the number of iterations
+    bool step(int n) {
+      for(; n > 0 && step(); --n) ;
+      return !n;
+    }
+    /// \brief Starts the annealing process.
+    void run() {
+      init();
+      do { } while (step());
+    }
+    /// \brief Destructor.
+    virtual ~SimAnnBase() {}
+  };
+
+  /// \ingroup metah
+  ///
+  /// \brief Simulated annealing class.
+  class SimAnn : public SimAnnBase {
+  private:
+    /// \brief Pointer to the current entity.
+    EntityBase *curr_ent;
+    /// \brief Pointer to the best entity.
+    EntityBase *best_ent;
+    /// \brief Does initializations before each run.
+    void init() {
+      SimAnnBase::init();
+      if (best_ent) delete best_ent;
+      best_ent = NULL;
+      curr_ent->randomize();
+    }
+  public:
+    /// \brief Constructor.
+    SimAnn() : curr_ent(NULL), best_ent(NULL) {}
+    /// \brief Destructor.
+    virtual ~SimAnn() {
+      if (best_ent) delete best_ent;
+    }
+    /// \brief Step to a neighbouring state.
+    double mutate() {
+      return curr_ent->mutate();
+    }
+    /// \brief Reverts the last mutate().
+    void revert() {
+      curr_ent->revert();
+    }
+    /// \brief Saves the current solution as the best one.
+    void saveAsBest() { 
+      if (best_ent) delete best_ent;
+      best_ent = curr_ent->clone();
+    }
+    /// \brief Sets the current entity.
+    void setEntity(EntityBase &_ent) {
+      curr_ent = &_ent;
+    }
+    /// \brief Returns a copy of the best found entity.
+    EntityBase* getBestEntity() { return best_ent->clone(); }
+  };
+
+  /// \brief A simple controller for the simulated annealing class.
+  ///
+  /// This controller starts from a given initial temperature and evenly
+  /// decreases it.
+  class SimpleController : public ControllerBase {
+  private:
+    /// \brief Maximum number of iterations.
+    long max_iter;
+    /// \brief Maximum number of iterations which do not improve the
+    /// solution.
+    long max_no_impr;
+    /// \brief Temperature.
+    double temp;
+    /// \brief Annealing factor.
+    double ann_fact;
+    /// \brief Constructor.
+    /// \param _max_iter maximum number of iterations
+    /// \param _max_no_impr maximum number of consecutive iterations which do
+    ///        not yield a better solution
+    /// \param _temp initial temperature
+    /// \param _ann_fact annealing factor
+  public:
+    SimpleController(long _max_iter = 500000, long _max_no_impr = 20000,
+    double _temp = 1000.0, double _ann_fact = 0.9999) : max_iter(_max_iter),
+      max_no_impr(_max_no_impr), temp(_temp), ann_fact(_ann_fact)
+    {
+    }
+    /// \brief This is called when a neighbouring state gets accepted.
+    void acceptEvent() {}
+    /// \brief This is called when the accepted neighbouring state's cost is
+    /// less than the best found one's.
+    void improveEvent() {}
+    /// \brief This is called when a neighbouring state gets rejected.
+    void rejectEvent() {}
+    /// \brief Decides whether to continue the annealing process or not. Also
+    /// decreases the temperature.
+    bool next() {
+      temp *= ann_fact;
+      bool quit = (simann->getIter() > max_iter) ||
+        (simann->getIter() - simann->getLastImpr() > max_no_impr);
+      return !quit;
+    }
+    /// \brief Decides whether to accept the current solution or not.
+    bool accept() {
+      double cost_diff = simann->getCurrCost() - simann->getPrevCost();
+      return (rnd() <= exp(-(cost_diff / temp)));
+    }
+    /// \brief Destructor.
+    virtual ~SimpleController() {}
+  };
+
+  /// \brief A controller with preset running time for the simulated annealing
+  /// class.
+  ///
+  /// With this controller you can set the running time of the annealing
+  /// process in advance. It works the following way: the controller measures
+  /// a kind of divergence. The divergence is the difference of the average
+  /// cost of the recently found solutions the cost of the best found one. In
+  /// case this divergence is greater than a given threshold, then we decrease
+  /// the annealing factor, that is we cool the system faster. In case the
+  /// divergence is lower than the threshold, then we increase the temperature.
+  /// The threshold is a function of the elapsed time which reaches zero at the
+  /// desired end time.
+  class AdvancedController : public ControllerBase {
+  private:
+    /// \brief Timer class to measure the elapsed time.
+    Timer timer;
+    /// \brief Calculates the threshold value.
+    /// \param time the elapsed time in seconds
+    virtual double threshold(double time) {
+      return (-1.0) * start_threshold / end_time * time + start_threshold;
+    }
+    /// \brief Parameter used to calculate the running average.
+    double alpha;
+    /// \brief Parameter used to decrease the annealing factor.
+    double beta;
+    /// \brief Parameter used to increase the temperature.
+    double gamma;
+    /// \brief The time at the end of the algorithm.
+    double end_time;
+    /// \brief The time at the start of the algorithm.
+    double start_time;
+    /// \brief Starting threshold.
+    double start_threshold;
+    /// \brief Average cost of recent solutions.
+    double avg_cost;
+    /// \brief Temperature.
+    double temp;
+    /// \brief Annealing factor.
+    double ann_fact;
+    /// \brief Initial annealing factor.
+    double init_ann_fact;
+    /// \brief True when the annealing process has been started.
+    bool start;
+  public:
+    /// \brief Constructor.
+    /// \param _end_time running time in seconds
+    /// \param _alpha parameter used to calculate the running average
+    /// \param _beta parameter used to decrease the annealing factor
+    /// \param _gamma parameter used to increase the temperature
+    /// \param _ann_fact initial annealing factor
+    AdvancedController(double _end_time, double _alpha = 0.2,
+    double _beta = 0.9, double _gamma = 1.6, double _ann_fact = 0.9999) :
+    alpha(_alpha), beta(_beta), gamma(_gamma), end_time(_end_time),
+    ann_fact(_ann_fact), init_ann_fact(_ann_fact), start(false)
+    {
+    }
+    /// \brief Does initializations before each run.
+    void init() {
+      avg_cost = simann->getCurrCost();
+    }
+    /// \brief This is called when a neighbouring state gets accepted.
+    void acceptEvent() {
+      avg_cost = alpha * simann->getCurrCost() + (1.0 - alpha) * avg_cost;
+      if (!start) {
+        static int cnt = 0;
+        cnt++;
+        if (cnt >= 100) {
+          // calculate starting threshold and starting temperature
+          start_threshold = 5.0 * fabs(simann->getBestCost() - avg_cost);
+          temp = 10000.0;
+          start = true;
+          timer.restart();
+        }
+      }
+    }
+    /// \brief Decides whether to continue the annealing process or not.
+    bool next() {
+      if (!start) {
+        return true;
+      }
+      else {
+        double elapsed_time = timer.realTime();
+        if (fabs(avg_cost - simann->getBestCost()) > threshold(elapsed_time)) {
+          // decrease the annealing factor
+          ann_fact *= beta;
+        }
+        else {
+          // increase the temperature
+          temp *= gamma;
+          // reset the annealing factor
+          ann_fact = init_ann_fact;
+        }
+        temp *= ann_fact;
+        return elapsed_time < end_time;
+      }
+    }
+    /// \brief Decides whether to accept the current solution or not.
+    bool accept() {
+      if (!start) {
+        return true;
+      }
+      else {
+        double cost_diff = simann->getCurrCost() - simann->getPrevCost();
+        return (rnd() <= exp(-(cost_diff / temp)));
+      }
+    }
+    /// \brief Destructor.
+    virtual ~AdvancedController() {}
+  };
+
+}
+
+#endif
Index: lemon/smart_graph.h
===================================================================
--- lemon/smart_graph.h	(revision 2553)
+++ lemon/smart_graph.h	(revision 2553)
@@ -0,0 +1,1158 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_SMART_GRAPH_H
+#define LEMON_SMART_GRAPH_H
+
+///\ingroup graphs
+///\file
+///\brief SmartGraph and SmartUGraph classes.
+
+#include <vector>
+
+#include <lemon/bits/invalid.h>
+
+#include <lemon/bits/base_extender.h>
+#include <lemon/bits/graph_extender.h>
+
+#include <lemon/bits/utility.h>
+#include <lemon/error.h>
+
+#include <lemon/bits/graph_extender.h>
+
+namespace lemon {
+
+  class SmartGraph;
+  ///Base of SmartGraph
+
+  ///Base of SmartGraph
+  ///
+  class SmartGraphBase {
+  protected:
+
+    struct NodeT 
+    {
+      int first_in, first_out;      
+      NodeT() {}
+    };
+    struct EdgeT 
+    {
+      int target, source, next_in, next_out;      
+      EdgeT() {}  
+    };
+
+    std::vector<NodeT> nodes;
+
+    std::vector<EdgeT> edges;
+    
+    
+  public:
+
+    typedef SmartGraphBase Graph;
+
+    class Node;
+    class Edge;
+
+    
+  public:
+
+    SmartGraphBase() : nodes(), edges() { }
+    SmartGraphBase(const SmartGraphBase &_g) 
+      : nodes(_g.nodes), edges(_g.edges) { }
+    
+    typedef True NodeNumTag;
+    typedef True EdgeNumTag;
+
+    int nodeNum() const { return nodes.size(); }
+    int edgeNum() const { return edges.size(); }
+
+    int maxNodeId() const { return nodes.size()-1; }
+    int maxEdgeId() const { return edges.size()-1; }
+
+    Node addNode() {
+      int n = nodes.size();     
+      nodes.push_back(NodeT());
+      nodes[n].first_in = -1;
+      nodes[n].first_out = -1;
+      return Node(n);
+    }
+    
+    Edge addEdge(Node u, Node v) {
+      int n = edges.size(); 
+      edges.push_back(EdgeT());
+      edges[n].source = u.id; 
+      edges[n].target = v.id;
+      edges[n].next_out = nodes[u.id].first_out;
+      edges[n].next_in = nodes[v.id].first_in;
+      nodes[u.id].first_out = nodes[v.id].first_in = n;
+
+      return Edge(n);
+    }
+
+    void clear() {
+      edges.clear();
+      nodes.clear();
+    }
+
+    Node source(Edge e) const { return Node(edges[e.id].source); }
+    Node target(Edge e) const { return Node(edges[e.id].target); }
+
+    static int id(Node v) { return v.id; }
+    static int id(Edge e) { return e.id; }
+
+    static Node nodeFromId(int id) { return Node(id);}
+    static Edge edgeFromId(int id) { return Edge(id);}
+
+    class Node {
+      friend class SmartGraphBase;
+      friend class SmartGraph;
+
+    protected:
+      int id;
+      explicit Node(int _id) : id(_id) {}
+    public:
+      Node() {}
+      Node (Invalid) : id(-1) {}
+      bool operator==(const Node i) const {return id == i.id;}
+      bool operator!=(const Node i) const {return id != i.id;}
+      bool operator<(const Node i) const {return id < i.id;}
+    };
+    
+
+    class Edge {
+      friend class SmartGraphBase;
+      friend class SmartGraph;
+
+    protected:
+      int id;
+      explicit Edge(int _id) : id(_id) {}
+    public:
+      Edge() { }
+      Edge (Invalid) : id(-1) {}
+      bool operator==(const Edge i) const {return id == i.id;}
+      bool operator!=(const Edge i) const {return id != i.id;}
+      bool operator<(const Edge i) const {return id < i.id;}
+    };
+
+    void first(Node& node) const {
+      node.id = nodes.size() - 1;
+    }
+
+    static void next(Node& node) {
+      --node.id;
+    }
+
+    void first(Edge& edge) const {
+      edge.id = edges.size() - 1;
+    }
+
+    static void next(Edge& edge) {
+      --edge.id;
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      edge.id = nodes[node.id].first_out;
+    }
+
+    void nextOut(Edge& edge) const {
+      edge.id = edges[edge.id].next_out;
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      edge.id = nodes[node.id].first_in;
+    }
+    
+    void nextIn(Edge& edge) const {
+      edge.id = edges[edge.id].next_in;
+    }
+
+  };
+
+  typedef GraphExtender<SmartGraphBase> ExtendedSmartGraphBase;
+
+  ///\ingroup graphs
+  ///
+  ///\brief A smart graph class.
+  ///
+  ///This is a simple and fast graph implementation.
+  ///It is also quite memory efficient, but at the price
+  ///that <b> it does support only limited (only stack-like)
+  ///node and edge deletions</b>.
+  ///It conforms to 
+  ///the \ref concepts::Graph "Graph concept" with an
+  ///important extra feature that
+  ///its maps are real \ref concepts::ReferenceMap "reference map"s.
+  ///
+  ///\sa concepts::Graph.
+  ///
+  ///\author Alpar Juttner
+  class SmartGraph : public ExtendedSmartGraphBase {
+  public:
+
+    typedef ExtendedSmartGraphBase Parent;
+
+  private:
+
+    ///SmartGraph is \e not copy constructible. Use GraphCopy() instead.
+
+    ///SmartGraph is \e not copy constructible. Use GraphCopy() instead.
+    ///
+    SmartGraph(const SmartGraph &) : ExtendedSmartGraphBase() {};
+    ///\brief Assignment of SmartGraph to another one is \e not allowed.
+    ///Use GraphCopy() instead.
+
+    ///Assignment of SmartGraph to another one is \e not allowed.
+    ///Use GraphCopy() instead.
+    void operator=(const SmartGraph &) {}
+
+  public:
+    
+    /// Constructor
+    
+    /// Constructor.
+    ///
+    SmartGraph() {};
+    
+    ///Add a new node to the graph.
+    
+    /// \return the new node.
+    ///
+    Node addNode() { return Parent::addNode(); }
+    
+    ///Add a new edge to the graph.
+    
+    ///Add a new edge to the graph with source node \c s
+    ///and target node \c t.
+    ///\return the new edge.
+    Edge addEdge(const Node& s, const Node& t) { 
+      return Parent::addEdge(s, t); 
+    }
+
+    /// \brief Using this it is possible to avoid the superfluous memory
+    /// allocation.
+
+    /// Using this it is possible to avoid the superfluous memory
+    /// allocation: if you know that the graph you want to build will
+    /// be very large (e.g. it will contain millions of nodes and/or edges)
+    /// then it is worth reserving space for this amount before starting
+    /// to build the graph.
+    /// \sa reserveEdge
+    void reserveNode(int n) { nodes.reserve(n); };
+
+    /// \brief Using this it is possible to avoid the superfluous memory
+    /// allocation.
+
+    /// Using this it is possible to avoid the superfluous memory
+    /// allocation: if you know that the graph you want to build will
+    /// be very large (e.g. it will contain millions of nodes and/or edges)
+    /// then it is worth reserving space for this amount before starting
+    /// to build the graph.
+    /// \sa reserveNode
+    void reserveEdge(int m) { edges.reserve(m); };
+
+    ///Clear the graph.
+    
+    ///Erase all the nodes and edges from the graph.
+    ///
+    void clear() {
+      Parent::clear();
+    }
+
+    ///Split a node.
+    
+    ///This function splits a node. First a new node is added to the graph,
+    ///then the source of each outgoing edge of \c n is moved to this new node.
+    ///If \c connect is \c true (this is the default value), then a new edge
+    ///from \c n to the newly created node is also added.
+    ///\return The newly created node.
+    ///
+    ///\note The <tt>Edge</tt>s
+    ///referencing a moved edge remain
+    ///valid. However <tt>InEdge</tt>'s and <tt>OutEdge</tt>'s
+    ///may be invalidated.
+    ///\warning This functionality cannot be used together with the Snapshot
+    ///feature.
+    ///\todo It could be implemented in a bit faster way.
+    Node split(Node n, bool connect = true)
+    {
+      Node b = addNode();
+      nodes[b.id].first_out=nodes[n.id].first_out;
+      nodes[n.id].first_out=-1;
+      for(int i=nodes[b.id].first_out;i!=-1;i++) edges[i].source=b.id;
+      if(connect) addEdge(n,b);
+      return b;
+    }
+
+  public:
+    
+    class Snapshot;
+
+  protected:
+
+    void restoreSnapshot(const Snapshot &s)
+    {
+      while(s.edge_num<edges.size()) {
+        Edge edge = edgeFromId(edges.size()-1);
+	Parent::notifier(Edge()).erase(edge);
+	nodes[edges.back().source].first_out=edges.back().next_out;
+	nodes[edges.back().target].first_in=edges.back().next_in;
+	edges.pop_back();
+      }
+      while(s.node_num<nodes.size()) {
+        Node node = nodeFromId(nodes.size()-1);
+	Parent::notifier(Node()).erase(node);
+	nodes.pop_back();
+      }
+    }    
+
+  public:
+
+    ///Class to make a snapshot of the graph and to restrore to it later.
+
+    ///Class to make a snapshot of the graph and to restrore to it later.
+    ///
+    ///The newly added nodes and edges can be removed using the
+    ///restore() function.
+    ///\note After you restore a state, you cannot restore
+    ///a later state, in other word you cannot add again the edges deleted
+    ///by restore() using another one Snapshot instance.
+    ///
+    ///\warning If you do not use correctly the snapshot that can cause
+    ///either broken program, invalid state of the graph, valid but
+    ///not the restored graph or no change. Because the runtime performance
+    ///the validity of the snapshot is not stored.
+    class Snapshot 
+    {
+      SmartGraph *g;
+    protected:
+      friend class SmartGraph;
+      unsigned int node_num;
+      unsigned int edge_num;
+    public:
+      ///Default constructor.
+      
+      ///Default constructor.
+      ///To actually make a snapshot you must call save().
+      ///
+      Snapshot() : g(0) {}
+      ///Constructor that immediately makes a snapshot
+      
+      ///This constructor immediately makes a snapshot of the graph.
+      ///\param _g The graph we make a snapshot of.
+      Snapshot(SmartGraph &_g) :g(&_g) {
+	node_num=g->nodes.size();
+	edge_num=g->edges.size();
+      }
+
+      ///Make a snapshot.
+
+      ///Make a snapshot of the graph.
+      ///
+      ///This function can be called more than once. In case of a repeated
+      ///call, the previous snapshot gets lost.
+      ///\param _g The graph we make the snapshot of.
+      void save(SmartGraph &_g) 
+      {
+	g=&_g;
+	node_num=g->nodes.size();
+	edge_num=g->edges.size();
+      }
+
+      ///Undo the changes until a snapshot.
+      
+      ///Undo the changes until a snapshot created by save().
+      ///
+      ///\note After you restored a state, you cannot restore
+      ///a later state, in other word you cannot add again the edges deleted
+      ///by restore().
+      void restore()
+      {
+	g->restoreSnapshot(*this);
+      }
+    };
+  };
+
+
+  class SmartUGraphBase {
+
+  protected:
+
+    struct NodeT {
+      int first_out;
+    };
+ 
+    struct EdgeT {
+      int target;
+      int next_out;
+    };
+
+    std::vector<NodeT> nodes;
+    std::vector<EdgeT> edges;
+
+    int first_free_edge;
+    
+  public:
+    
+    typedef SmartUGraphBase Graph;
+
+    class Node;
+    class Edge;
+    class UEdge;
+    
+    class Node {
+      friend class SmartUGraphBase;
+    protected:
+
+      int id;
+      explicit Node(int pid) { id = pid;}
+
+    public:
+      Node() {}
+      Node (Invalid) { id = -1; }
+      bool operator==(const Node& node) const {return id == node.id;}
+      bool operator!=(const Node& node) const {return id != node.id;}
+      bool operator<(const Node& node) const {return id < node.id;}
+    };
+
+    class UEdge {
+      friend class SmartUGraphBase;
+    protected:
+
+      int id;
+      explicit UEdge(int pid) { id = pid;}
+
+    public:
+      UEdge() {}
+      UEdge (Invalid) { id = -1; }
+      bool operator==(const UEdge& edge) const {return id == edge.id;}
+      bool operator!=(const UEdge& edge) const {return id != edge.id;}
+      bool operator<(const UEdge& edge) const {return id < edge.id;}
+    };
+
+    class Edge {
+      friend class SmartUGraphBase;
+    protected:
+
+      int id;
+      explicit Edge(int pid) { id = pid;}
+
+    public:
+      operator UEdge() const { return uEdgeFromId(id / 2); }
+
+      Edge() {}
+      Edge (Invalid) { id = -1; }
+      bool operator==(const Edge& edge) const {return id == edge.id;}
+      bool operator!=(const Edge& edge) const {return id != edge.id;}
+      bool operator<(const Edge& edge) const {return id < edge.id;}
+    };
+
+
+
+    SmartUGraphBase()
+      : nodes(), edges() {}
+
+    
+    int maxNodeId() const { return nodes.size()-1; } 
+    int maxUEdgeId() const { return edges.size() / 2 - 1; }
+    int maxEdgeId() const { return edges.size()-1; }
+
+    Node source(Edge e) const { return Node(edges[e.id ^ 1].target); }
+    Node target(Edge e) const { return Node(edges[e.id].target); }
+
+    Node source(UEdge e) const { return Node(edges[2 * e.id].target); }
+    Node target(UEdge e) const { return Node(edges[2 * e.id + 1].target); }
+
+    static bool direction(Edge e) {
+      return (e.id & 1) == 1;
+    }
+
+    static Edge direct(UEdge e, bool d) {
+      return Edge(e.id * 2 + (d ? 1 : 0));
+    }
+
+    void first(Node& node) const { 
+      node.id = nodes.size() - 1;
+    }
+
+    void next(Node& node) const {
+      --node.id;
+    }
+
+    void first(Edge& edge) const { 
+      edge.id = edges.size() - 1;
+    }
+
+    void next(Edge& edge) const {
+      --edge.id;
+    }
+
+    void first(UEdge& edge) const { 
+      edge.id = edges.size() / 2 - 1;
+    }
+
+    void next(UEdge& edge) const {
+      --edge.id;
+    }
+
+    void firstOut(Edge &edge, const Node& v) const {
+      edge.id = nodes[v.id].first_out;
+    }
+    void nextOut(Edge &edge) const {
+      edge.id = edges[edge.id].next_out;
+    }
+
+    void firstIn(Edge &edge, const Node& v) const {
+      edge.id = ((nodes[v.id].first_out) ^ 1);
+      if (edge.id == -2) edge.id = -1;
+    }
+    void nextIn(Edge &edge) const {
+      edge.id = ((edges[edge.id ^ 1].next_out) ^ 1);
+      if (edge.id == -2) edge.id = -1;
+    }
+
+    void firstInc(UEdge &edge, bool& d, const Node& v) const {
+      int de = nodes[v.id].first_out;
+      if (de != -1) {
+        edge.id = de / 2;
+        d = ((de & 1) == 1);
+      } else {
+        edge.id = -1;
+        d = true;
+      }
+    }
+    void nextInc(UEdge &edge, bool& d) const {
+      int de = (edges[(edge.id * 2) | (d ? 1 : 0)].next_out);
+      if (de != -1) {
+        edge.id = de / 2;
+        d = ((de & 1) == 1);
+      } else {
+        edge.id = -1;
+        d = true;      
+      }
+    }
+    
+    static int id(Node v) { return v.id; }
+    static int id(Edge e) { return e.id; }
+    static int id(UEdge e) { return e.id; }
+
+    static Node nodeFromId(int id) { return Node(id);}
+    static Edge edgeFromId(int id) { return Edge(id);}
+    static UEdge uEdgeFromId(int id) { return UEdge(id);}
+
+    Node addNode() {     
+      int n = nodes.size();
+      nodes.push_back(NodeT());
+      nodes[n].first_out = -1;
+      
+      return Node(n);
+    }
+    
+    UEdge addEdge(Node u, Node v) {
+      int n = edges.size();
+      edges.push_back(EdgeT());
+      edges.push_back(EdgeT());
+      
+      edges[n].target = u.id;
+      edges[n | 1].target = v.id;
+
+      edges[n].next_out = nodes[v.id].first_out;
+      nodes[v.id].first_out = n;
+
+      edges[n | 1].next_out = nodes[u.id].first_out;	
+      nodes[u.id].first_out = (n | 1);
+
+      return UEdge(n / 2);
+    }
+    
+    void clear() {
+      edges.clear();
+      nodes.clear();
+    }
+
+  };
+
+  typedef UGraphExtender<SmartUGraphBase> ExtendedSmartUGraphBase;
+
+  /// \ingroup graphs
+  ///
+  /// \brief A smart undirected graph class.
+  ///
+  /// This is a simple and fast undirected graph implementation.
+  /// It is also quite memory efficient, but at the price
+  /// that <b> it does support only limited (only stack-like)
+  /// node and edge deletions</b>.
+  /// Except from this it conforms to 
+  /// the \ref concepts::UGraph "UGraph concept".
+  ///
+  ///It also has an
+  ///important extra feature that
+  ///its maps are real \ref concepts::ReferenceMap "reference map"s.
+  ///
+  /// \sa concepts::UGraph.
+  ///
+  class SmartUGraph : public ExtendedSmartUGraphBase {
+  private:
+
+    ///SmartUGraph is \e not copy constructible. Use UGraphCopy() instead.
+
+    ///SmartUGraph is \e not copy constructible. Use UGraphCopy() instead.
+    ///
+    SmartUGraph(const SmartUGraph &) : ExtendedSmartUGraphBase() {};
+
+    ///\brief Assignment of SmartUGraph to another one is \e not allowed.
+    ///Use UGraphCopy() instead.
+
+    ///Assignment of SmartUGraph to another one is \e not allowed.
+    ///Use UGraphCopy() instead.
+    void operator=(const SmartUGraph &) {}
+
+  public:
+
+    typedef ExtendedSmartUGraphBase Parent;
+    typedef Parent::OutEdgeIt IncEdgeIt;
+
+    /// Constructor
+    
+    /// Constructor.
+    ///
+    SmartUGraph() {}
+
+    ///Add a new node to the graph.
+    
+    /// \return the new node.
+    ///
+    Node addNode() { return Parent::addNode(); }
+    
+    ///Add a new undirected edge to the graph.
+    
+    ///Add a new undirected edge to the graph with node \c s
+    ///and \c t.
+    ///\return the new undirected edge.
+    UEdge addEdge(const Node& s, const Node& t) { 
+      return Parent::addEdge(s, t); 
+    }
+
+    ///Clear the graph.
+    
+    ///Erase all the nodes and edges from the graph.
+    ///
+    void clear() {
+      Parent::clear();
+    }
+
+  public:
+    
+    class Snapshot;
+
+  protected:
+
+    void saveSnapshot(Snapshot &s)
+    {
+      s.graph = this;
+      s.node_num = nodes.size();
+      s.edge_num = edges.size();
+    }
+
+    void restoreSnapshot(const Snapshot &s)
+    {
+      while(s.edge_num<edges.size()) {
+        int n=edges.size()-1;
+        UEdge edge=uEdgeFromId(n/2);
+	Parent::notifier(UEdge()).erase(edge);
+        std::vector<Edge> dir;
+        dir.push_back(edgeFromId(n));
+        dir.push_back(edgeFromId(n-1));
+	Parent::notifier(Edge()).erase(dir);
+	nodes[edges[n].target].first_out=edges[n].next_out;
+	nodes[edges[n-1].target].first_out=edges[n-1].next_out;
+	edges.pop_back();
+	edges.pop_back();
+      }
+      while(s.node_num<nodes.size()) {
+        int n=nodes.size()-1;
+        Node node = nodeFromId(n);
+	Parent::notifier(Node()).erase(node);
+	nodes.pop_back();
+      }
+    }    
+
+  public:
+
+    ///Class to make a snapshot of the graph and to restrore to it later.
+
+    ///Class to make a snapshot of the graph and to restrore to it later.
+    ///
+    ///The newly added nodes and edges can be removed using the
+    ///restore() function.
+    ///
+    ///\note After you restore a state, you cannot restore
+    ///a later state, in other word you cannot add again the edges deleted
+    ///by restore() using another one Snapshot instance.
+    ///
+    ///\warning If you do not use correctly the snapshot that can cause
+    ///either broken program, invalid state of the graph, valid but
+    ///not the restored graph or no change. Because the runtime performance
+    ///the validity of the snapshot is not stored.
+    class Snapshot 
+    {
+      SmartUGraph *graph;
+    protected:
+      friend class SmartUGraph;
+      unsigned int node_num;
+      unsigned int edge_num;
+    public:
+      ///Default constructor.
+      
+      ///Default constructor.
+      ///To actually make a snapshot you must call save().
+      ///
+      Snapshot() : graph(0) {}
+      ///Constructor that immediately makes a snapshot
+      
+      ///This constructor immediately makes a snapshot of the graph.
+      ///\param g The graph we make a snapshot of.
+      Snapshot(SmartUGraph &g) {
+        g.saveSnapshot(*this);
+      }
+
+      ///Make a snapshot.
+
+      ///Make a snapshot of the graph.
+      ///
+      ///This function can be called more than once. In case of a repeated
+      ///call, the previous snapshot gets lost.
+      ///\param g The graph we make the snapshot of.
+      void save(SmartUGraph &g) 
+      {
+        g.saveSnapshot(*this);
+      }
+
+      ///Undo the changes until a snapshot.
+      
+      ///Undo the changes until a snapshot created by save().
+      ///
+      ///\note After you restored a state, you cannot restore
+      ///a later state, in other word you cannot add again the edges deleted
+      ///by restore().
+      void restore()
+      {
+        graph->restoreSnapshot(*this);
+      }
+    };
+  };
+
+
+  class SmartBpUGraphBase {
+  public:
+
+    class NodeSetError : public LogicError {
+    public:
+      virtual const char* what() const throw() { 
+	return "lemon::SmartBpUGraph::NodeSetError";
+      }
+    };
+
+  protected:
+
+    struct NodeT {
+      int first;
+      NodeT() {}
+      NodeT(int _first) : first(_first) {}
+    };
+
+    struct UEdgeT {
+      int aNode, next_out;
+      int bNode, next_in;
+    };
+
+    std::vector<NodeT> aNodes;
+    std::vector<NodeT> bNodes;
+
+    std::vector<UEdgeT> edges;
+
+  public:
+  
+    class Node {
+      friend class SmartBpUGraphBase;
+    protected:
+      int id;
+
+      explicit Node(int _id) : id(_id) {}
+    public:
+      Node() {}
+      Node(Invalid) : id(-1) {}
+      bool operator==(const Node i) const {return id==i.id;}
+      bool operator!=(const Node i) const {return id!=i.id;}
+      bool operator<(const Node i) const {return id<i.id;}
+    };
+
+    class UEdge {
+      friend class SmartBpUGraphBase;
+    protected:
+      int id;
+
+      UEdge(int _id) : id(_id) {}
+    public:
+      UEdge() {}
+      UEdge(Invalid) : id(-1) {}
+      bool operator==(const UEdge i) const {return id==i.id;}
+      bool operator!=(const UEdge i) const {return id!=i.id;}
+      bool operator<(const UEdge i) const {return id<i.id;}
+    };
+
+    void firstANode(Node& node) const {
+      node.id = 2 * aNodes.size() - 2;
+      if (node.id < 0) node.id = -1; 
+    }
+    void nextANode(Node& node) const {
+      node.id -= 2;
+      if (node.id < 0) node.id = -1; 
+    }
+
+    void firstBNode(Node& node) const {
+      node.id = 2 * bNodes.size() - 1;
+    }
+    void nextBNode(Node& node) const {
+      node.id -= 2;
+    }
+
+    void first(Node& node) const {
+      if (aNodes.size() > 0) {
+	node.id = 2 * aNodes.size() - 2;
+      } else {
+	node.id = 2 * bNodes.size() - 1;
+      }
+    }
+    void next(Node& node) const {
+      node.id -= 2;
+      if (node.id == -2) {
+	node.id = 2 * bNodes.size() - 1;
+      }
+    }
+  
+    void first(UEdge& edge) const {
+      edge.id = edges.size() - 1;
+    }
+    void next(UEdge& edge) const {
+      --edge.id;
+    }
+
+    void firstFromANode(UEdge& edge, const Node& node) const {
+      LEMON_ASSERT((node.id & 1) == 0, NodeSetError());
+      edge.id = aNodes[node.id >> 1].first;
+    }
+    void nextFromANode(UEdge& edge) const {
+      edge.id = edges[edge.id].next_out;
+    }
+
+    void firstFromBNode(UEdge& edge, const Node& node) const {
+      LEMON_ASSERT((node.id & 1) == 1, NodeSetError());
+      edge.id = bNodes[node.id >> 1].first;
+    }
+    void nextFromBNode(UEdge& edge) const {
+      edge.id = edges[edge.id].next_in;
+    }
+
+    static int id(const Node& node) {
+      return node.id;
+    }
+    static Node nodeFromId(int id) {
+      return Node(id);
+    }
+    int maxNodeId() const {
+      return aNodes.size() > bNodes.size() ?
+	aNodes.size() * 2 - 2 : bNodes.size() * 2 - 1;
+    }
+  
+    static int id(const UEdge& edge) {
+      return edge.id;
+    }
+    static UEdge uEdgeFromId(int id) {
+      return UEdge(id);
+    }
+    int maxUEdgeId() const {
+      return edges.size();
+    }
+  
+    static int aNodeId(const Node& node) {
+      return node.id >> 1;
+    }
+    static Node nodeFromANodeId(int id) {
+      return Node(id << 1);
+    }
+    int maxANodeId() const {
+      return aNodes.size();
+    }
+
+    static int bNodeId(const Node& node) {
+      return node.id >> 1;
+    }
+    static Node nodeFromBNodeId(int id) {
+      return Node((id << 1) + 1);
+    }
+    int maxBNodeId() const {
+      return bNodes.size();
+    }
+
+    Node aNode(const UEdge& edge) const {
+      return Node(edges[edge.id].aNode);
+    }
+    Node bNode(const UEdge& edge) const {
+      return Node(edges[edge.id].bNode);
+    }
+
+    static bool aNode(const Node& node) {
+      return (node.id & 1) == 0;
+    }
+
+    static bool bNode(const Node& node) {
+      return (node.id & 1) == 1;
+    }
+
+    Node addANode() {
+      NodeT nodeT;
+      nodeT.first = -1;
+      aNodes.push_back(nodeT);
+      return Node(aNodes.size() * 2 - 2);
+    }
+
+    Node addBNode() {
+      NodeT nodeT;
+      nodeT.first = -1;
+      bNodes.push_back(nodeT);
+      return Node(bNodes.size() * 2 - 1);
+    }
+
+    UEdge addEdge(const Node& source, const Node& target) {
+      LEMON_ASSERT(((source.id ^ target.id) & 1) == 1, NodeSetError());
+      UEdgeT edgeT;
+      if ((source.id & 1) == 0) {
+	edgeT.aNode = source.id;
+	edgeT.bNode = target.id;
+      } else {
+	edgeT.aNode = target.id;
+	edgeT.bNode = source.id;
+      }
+      edgeT.next_out = aNodes[edgeT.aNode >> 1].first;
+      aNodes[edgeT.aNode >> 1].first = edges.size();
+      edgeT.next_in = bNodes[edgeT.bNode >> 1].first;
+      bNodes[edgeT.bNode >> 1].first = edges.size();
+      edges.push_back(edgeT);
+      return UEdge(edges.size() - 1);
+    }
+
+    void clear() {
+      aNodes.clear();
+      bNodes.clear();
+      edges.clear();
+    }
+
+    typedef True NodeNumTag;
+    int nodeNum() const { return aNodes.size() + bNodes.size(); }
+    int aNodeNum() const { return aNodes.size(); }
+    int bNodeNum() const { return bNodes.size(); }
+
+    typedef True EdgeNumTag;
+    int uEdgeNum() const { return edges.size(); }
+
+  };
+
+
+  typedef BpUGraphExtender<BidirBpUGraphExtender<SmartBpUGraphBase> >
+  ExtendedSmartBpUGraphBase;
+
+  /// \ingroup graphs
+  ///
+  /// \brief A smart bipartite undirected graph class.
+  ///
+  /// This is a simple and fast bipartite undirected graph implementation.
+  /// It is also quite memory efficient, but at the price
+  /// that <b> it does not support node and edge deletions</b>.
+  /// Except from this it conforms to 
+  /// the \ref concepts::BpUGraph "BpUGraph concept".
+  ///
+  ///It also has an
+  ///important extra feature that
+  ///its maps are real \ref concepts::ReferenceMap "reference map"s.
+  ///
+  /// \sa concepts::BpUGraph.
+  ///
+  class SmartBpUGraph : public ExtendedSmartBpUGraphBase {
+  private:
+
+    /// \brief SmartBpUGraph is \e not copy constructible.
+    ///
+    ///SmartBpUGraph is \e not copy constructible.
+    SmartBpUGraph(const SmartBpUGraph &) : ExtendedSmartBpUGraphBase() {};
+
+    /// \brief Assignment of SmartBpUGraph to another one is \e not
+    /// allowed.
+    ///
+    /// Assignment of SmartBpUGraph to another one is \e not allowed.
+    void operator=(const SmartBpUGraph &) {}
+
+  public:
+
+    typedef ExtendedSmartBpUGraphBase Parent;
+
+    ///Constructor
+    
+    ///Constructor.
+    ///
+    SmartBpUGraph() : ExtendedSmartBpUGraphBase() {}
+
+    ///Add a new ANode to the graph.
+    
+    /// \return the new node.
+    ///
+    Node addANode() { return Parent::addANode(); }
+
+    ///Add a new BNode to the graph.
+    
+    /// \return the new node.
+    ///
+    Node addBNode() { return Parent::addBNode(); }
+    
+    ///Add a new undirected edge to the graph.
+    
+    ///Add a new undirected edge to the graph with node \c s
+    ///and \c t.
+    ///\return the new undirected edge.
+    UEdge addEdge(const Node& s, const Node& t) { 
+      return Parent::addEdge(s, t); 
+    }
+
+    ///Clear the graph.
+    
+    ///Erase all the nodes and edges from the graph.
+    ///
+    void clear() {
+      Parent::clear();
+    }
+    
+  public:
+
+    class Snapshot;
+
+  protected:
+    
+    void restoreSnapshot(const Snapshot &s)
+    {
+      while(s.edge_num<edges.size()) {
+        UEdge edge = uEdgeFromId(edges.size()-1);
+	Parent::notifier(UEdge()).erase(edge);
+        std::vector<Edge> dir;
+        dir.push_back(Parent::direct(edge, true));
+        dir.push_back(Parent::direct(edge, false));
+	Parent::notifier(Edge()).erase(dir);
+	aNodes[edges.back().aNode >> 1].first=edges.back().next_out;
+	bNodes[edges.back().bNode >> 1].first=edges.back().next_in;
+	edges.pop_back();
+      }
+      while(s.anode_num<aNodes.size()) {
+        Node node = nodeFromANodeId(aNodes.size() - 1);
+	Parent::notifier(ANode()).erase(node);
+	Parent::notifier(Node()).erase(node);
+	aNodes.pop_back();
+      }
+      while(s.bnode_num<bNodes.size()) {
+        Node node = nodeFromBNodeId(bNodes.size() - 1);
+	Parent::notifier(BNode()).erase(node);
+	Parent::notifier(Node()).erase(node);
+	bNodes.pop_back();
+      }
+    }    
+
+  public:
+
+    ///Class to make a snapshot of the graph and to restrore to it later.
+
+    ///Class to make a snapshot of the graph and to restrore to it later.
+    ///
+    ///The newly added nodes and edges can be removed using the
+    ///restore() function.
+    ///
+    ///\note After you restore a state, you cannot restore
+    ///a later state, in other word you cannot add again the edges deleted
+    ///by restore() using another one Snapshot instance.
+    ///
+    ///\warning If you do not use correctly the snapshot that can cause
+    ///either broken program, invalid state of the graph, valid but
+    ///not the restored graph or no change. Because the runtime performance
+    ///the validity of the snapshot is not stored.
+    class Snapshot 
+    {
+      SmartBpUGraph *g;
+    protected:
+      friend class SmartBpUGraph;
+      unsigned int anode_num;
+      unsigned int bnode_num;
+      unsigned int edge_num;
+    public:
+      ///Default constructor.
+      
+      ///Default constructor.
+      ///To actually make a snapshot you must call save().
+      ///
+      Snapshot() : g(0) {}
+
+      ///Constructor that immediately makes a snapshot
+      
+      ///This constructor immediately makes a snapshot of the graph.
+      ///\param _g The graph we make a snapshot of.
+      Snapshot(SmartBpUGraph &_g) : g(&_g) {
+	anode_num=g->aNodes.size();
+	bnode_num=g->bNodes.size();
+	edge_num=g->edges.size();
+      }
+
+      ///Make a snapshot.
+
+      ///Make a snapshot of the graph.
+      ///
+      ///This function can be called more than once. In case of a repeated
+      ///call, the previous snapshot gets lost.
+      ///\param _g The graph we make the snapshot of.
+      void save(SmartBpUGraph &_g) 
+      {
+	g=&_g;
+	anode_num=g->aNodes.size();
+	bnode_num=g->bNodes.size();
+	edge_num=g->edges.size();
+      }
+
+      ///Undo the changes until a snapshot.
+      
+      ///Undo the changes until a snapshot created by save().
+      ///
+      ///\note After you restored a state, you cannot restore
+      ///a later state, in other word you cannot add again the edges deleted
+      ///by restore().
+      void restore()
+      {
+	g->restoreSnapshot(*this);
+      }
+    };
+  };
+
+  
+  /// @}  
+} //namespace lemon
+
+
+#endif //LEMON_SMART_GRAPH_H
Index: lemon/static_graph.h
===================================================================
--- lemon/static_graph.h	(revision 2553)
+++ lemon/static_graph.h	(revision 2553)
@@ -0,0 +1,262 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_STATIC_GRAPH_H
+#define LEMON_STATIC_GRAPH_H
+
+#include <lemon/bits/graph_extender.h>
+#include <lemon/graph_utils.h>
+
+namespace lemon {
+
+  class StaticGraphBase {
+  public:
+
+    StaticGraphBase() 
+      : node_num(-1), edge_num(0), 
+        node_first_out(0), node_first_in(0),
+        edge_source(0), edge_target(0), 
+        edge_next_in(0), edge_next_out(0) {}
+    
+    ~StaticGraphBase() {
+      if (node_num != -1) {
+        delete[] node_first_out;
+        delete[] node_first_in;
+        delete[] edge_source;
+        delete[] edge_target;
+        delete[] edge_next_out;
+        delete[] edge_next_in;
+      }
+    }
+
+    class Node {
+      friend class StaticGraphBase;
+    protected:
+      int id;
+      Node(int _id) : id(_id) {}
+    public:
+      Node() {}
+      Node (Invalid) : id(-1) {}
+      bool operator==(const Node& node) const {return id == node.id;}
+      bool operator!=(const Node& node) const {return id != node.id;}
+      bool operator<(const Node& node) const {return id < node.id;}
+    };
+
+    class Edge {
+      friend class StaticGraphBase;      
+    protected:
+      int id;
+      Edge(int _id) : id(_id) {}
+    public:
+      Edge() { }
+      Edge (Invalid) { id = -1; }
+      bool operator==(const Edge& edge) const {return id == edge.id;}
+      bool operator!=(const Edge& edge) const {return id != edge.id;}
+      bool operator<(const Edge& edge) const {return id < edge.id;}
+    };
+
+    Node source(const Edge& e) const { return Node(edge_source[e.id]); }
+    Node target(const Edge& e) const { return Node(edge_target[e.id]); }
+
+    void first(Node& n) const { n.id = node_num - 1; }
+    void next(Node& n) const { --n.id; }
+
+    void first(Edge& n) const { n.id = edge_num - 1; }
+    void next(Edge& n) const { --n.id; }
+
+    void firstOut(Edge& e, const Node& n) const { 
+      e.id = node_first_out[n.id] != node_first_out[n.id + 1] ? 
+        node_first_out[n.id] : -1;
+    }
+    void nextOut(Edge& e) const { e.id = edge_next_out[e.id]; }
+
+    void firstIn(Edge& e, const Node& n) const { e.id = node_first_in[n.id]; }
+    void nextIn(Edge& e) const { e.id = edge_next_in[e.id]; }
+    
+
+    int id(const Node& n) const { return n.id; }
+    Node nodeFromId(int id) const { return Node(id); }
+    int maxNodeId() const { return node_num - 1; }
+
+    int id(const Edge& e) const { return e.id; }
+    Edge edgeFromId(int id) const { return Edge(id); }
+    int maxEdgeId() const { return edge_num - 1; }
+
+    typedef True NodeNumTag;
+    int nodeNum() const { return node_num; }
+    typedef True EdgeNumTag;
+    int edgeNum() const { return edge_num; }
+
+  private:
+
+    template <typename Graph, typename NodeRefMap>
+    class EdgeLess {
+    public:
+      typedef typename Graph::Edge Edge;
+
+      EdgeLess(const Graph &_graph, const NodeRefMap& _nodeRef) 
+        : graph(_graph), nodeRef(_nodeRef) {}
+      
+      bool operator()(const Edge& left, const Edge& right) const {
+	return nodeRef[graph.target(left)] < nodeRef[graph.target(right)];
+      }
+    private:
+      const Graph& graph;
+      const NodeRefMap& nodeRef;
+    };
+    
+  public:
+
+    typedef True BuildTag;
+    
+    template <typename Graph, typename NodeRefMap, typename EdgeRefMap>
+    void build(const Graph& graph, NodeRefMap& nodeRef, EdgeRefMap& edgeRef) {
+
+      if (node_num != -1) {
+        delete[] node_first_out;
+        delete[] node_first_in;
+        delete[] edge_source;
+        delete[] edge_target;
+        delete[] edge_next_out;
+        delete[] edge_next_in;
+      }
+
+      typedef typename Graph::Node GNode;
+      typedef typename Graph::Edge GEdge;
+
+      node_num = countNodes(graph);
+      edge_num = countEdges(graph);
+
+      node_first_out = new int[node_num + 1];
+      node_first_in = new int[node_num];
+
+      edge_source = new int[edge_num];
+      edge_target = new int[edge_num];
+      edge_next_out = new int[edge_num];
+      edge_next_in = new int[edge_num];
+
+      int node_index = 0;
+      for (typename Graph::NodeIt n(graph); n != INVALID; ++n) {
+        nodeRef[n] = Node(node_index);
+        node_first_in[node_index] = -1;
+        ++node_index;
+      }
+
+      EdgeLess<Graph, NodeRefMap> edgeLess(graph, nodeRef);
+
+      int edge_index = 0;
+      for (typename Graph::NodeIt n(graph); n != INVALID; ++n) {
+        int source = nodeRef[n].id;
+        std::vector<GEdge> edges;
+        for (typename Graph::OutEdgeIt e(graph, n); e != INVALID; ++e) {
+          edges.push_back(e);
+        }
+        if (!edges.empty()) {
+          node_first_out[source] = edge_index;
+          std::sort(edges.begin(), edges.end(), edgeLess);
+          for (typename std::vector<GEdge>::iterator it = edges.begin();
+               it != edges.end(); ++it) {
+            int target = nodeRef[graph.target(*it)].id;
+            edgeRef[*it] = Edge(edge_index);
+            edge_source[edge_index] = source; 
+            edge_target[edge_index] = target;
+            edge_next_in[edge_index] = node_first_in[target];
+            node_first_in[target] = edge_index;
+            edge_next_out[edge_index] = edge_index + 1;
+            ++edge_index;
+          }
+          edge_next_out[edge_index - 1] = -1;
+        } else {
+          node_first_out[source] = edge_index;
+        }
+      }
+      node_first_out[node_num] = edge_num;
+    }
+
+  protected:
+
+    void fastFirstOut(Edge& e, const Node& n) const {
+      e.id = node_first_out[n.id];
+    }
+
+    static void fastNextOut(Edge& e) {
+      ++e.id;
+    }
+    void fastLastOut(Edge& e, const Node& n) const {
+      e.id = node_first_out[n.id + 1];
+    }
+    
+  private:
+    int node_num;
+    int edge_num;
+    int *node_first_out;
+    int *node_first_in;
+    int *edge_source;
+    int *edge_target;
+    int *edge_next_in;
+    int *edge_next_out;
+  };
+
+  typedef GraphExtender<StaticGraphBase> ExtendedStaticGraphBase;
+
+
+  class StaticGraph : public ExtendedStaticGraphBase {
+  public:
+
+    typedef ExtendedStaticGraphBase Parent;
+
+  protected:
+
+    using Parent::fastFirstOut;
+    using Parent::fastNextOut;
+    using Parent::fastLastOut;
+    
+  public:
+    
+    class OutEdgeIt : public Edge {
+    public:
+
+      OutEdgeIt() { }
+
+      OutEdgeIt(Invalid i) : Edge(i) { }
+
+      OutEdgeIt(const StaticGraph& graph, const Node& node) {
+	graph.fastFirstOut(*this, node);
+	graph.fastLastOut(last, node);
+        if (last == *this) *this = INVALID;
+      }
+
+      OutEdgeIt(const StaticGraph& graph, const Edge& edge) : Edge(edge) {
+        graph.fastLastOut(last, graph.source(edge));
+      }
+
+      OutEdgeIt& operator++() { 
+        StaticGraph::fastNextOut(*this);
+        if (last == *this) *this = INVALID;
+        return *this; 
+      }
+
+    private:
+      Edge last;
+    };
+    
+  };
+
+}
+
+#endif
Index: lemon/steiner.h
===================================================================
--- lemon/steiner.h	(revision 2553)
+++ lemon/steiner.h	(revision 2553)
@@ -0,0 +1,305 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_STEINER_H
+#define LEMON_STEINER_H
+
+///\ingroup approx
+///\file
+///\brief Algorithm for the 2-approximation of Steiner Tree problem.
+///
+
+#include <lemon/smart_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/error.h>
+
+#include <lemon/ugraph_adaptor.h>
+#include <lemon/maps.h>
+
+#include <lemon/dijkstra.h>
+#include <lemon/prim.h>
+
+
+namespace lemon {
+
+  /// \ingroup approx
+  
+  /// \brief Algorithm for the 2-approximation of Steiner Tree problem
+  ///
+  /// The Steiner-tree problem is the next: Given a connected
+  /// undirected graph, a cost function on the edges and a subset of
+  /// the nodes. Construct a tree with minimum cost which covers the
+  /// given subset of the nodes. The problem is NP-hard moreover
+  /// it is APX-complete too.
+  ///
+  /// Mehlhorn's approximation algorithm is implemented in this class,
+  /// which gives a 2-approximation for the Steiner-tree problem. The
+  /// algorithm's time complexity is O(nlog(n)+e).
+  template <typename UGraph,
+            typename CostMap = typename UGraph:: template UEdgeMap<double> >
+  class SteinerTree {
+  public:
+    
+    UGRAPH_TYPEDEFS(typename UGraph);
+
+    typedef typename CostMap::Value Value;
+    
+  private:
+
+    class CompMap {
+    public:
+      typedef Node Key;
+      typedef Edge Value;
+
+    private:
+      const UGraph& _graph;
+      typename UGraph::template NodeMap<int> _comp;
+
+    public:
+      CompMap(const UGraph& graph) : _graph(graph), _comp(graph) {}
+
+      void set(const Node& node, const Edge& edge) {
+        if (edge != INVALID) {
+          _comp.set(node, _comp[_graph.source(edge)]);
+        } else {
+          _comp.set(node, -1);
+        }
+      }
+
+      int comp(const Node& node) const { return _comp[node]; }
+      void comp(const Node& node, int value) { _comp.set(node, value); }
+    };
+
+    typedef typename UGraph::template NodeMap<Edge> PredMap;
+
+    typedef ForkWriteMap<PredMap, CompMap> ForkedMap;
+
+
+    struct External {
+      int source, target;
+      UEdge uedge;
+      Value value;
+
+      External(int s, int t, const UEdge& e, const Value& v)
+        : source(s), target(t), uedge(e), value(v) {}
+    };
+
+    struct ExternalLess {
+      bool operator()(const External& left, const External& right) const {
+        return (left.source < right.source) || 
+          (left.source == right.source && left.target < right.target);
+      }
+    };
+
+
+    typedef typename UGraph::template NodeMap<bool> FilterMap;
+
+    typedef typename UGraph::template UEdgeMap<bool> TreeMap;
+
+    const UGraph& _graph;
+    const CostMap& _cost;
+
+    typename Dijkstra<UGraph, CostMap>::
+    template DefPredMap<ForkedMap>::Create _dijkstra;
+
+    PredMap* _pred;
+    CompMap* _comp;
+    ForkedMap* _forked;
+
+    int _terminal_num;
+
+    FilterMap *_filter;
+    TreeMap *_tree;
+
+    Value _value;
+
+  public:
+
+    /// \brief Constructor
+    
+    /// Constructor
+    ///
+    SteinerTree(const UGraph &graph, const CostMap &cost)
+      : _graph(graph), _cost(cost), _dijkstra(graph, _cost), 
+        _pred(0), _comp(0), _forked(0), _filter(0), _tree(0) {}
+
+    /// \brief Initializes the internal data structures.
+    ///
+    /// Initializes the internal data structures.
+    void init() {
+      if (!_pred) _pred = new PredMap(_graph);
+      if (!_comp) _comp = new CompMap(_graph);
+      if (!_forked) _forked = new ForkedMap(*_pred, *_comp);
+      if (!_filter) _filter = new FilterMap(_graph);
+      if (!_tree) _tree = new TreeMap(_graph);
+      _dijkstra.predMap(*_forked);
+      _dijkstra.init();
+      _terminal_num = 0;
+      for (NodeIt it(_graph); it != INVALID; ++it) {
+        _filter->set(it, false);
+      }
+    }
+
+    /// \brief Adds a new terminal node.
+    ///
+    /// Adds a new terminal node to the Steiner-tree problem.
+    void addTerminal(const Node& node) {
+      if (!_dijkstra.reached(node)) {
+        _dijkstra.addSource(node);
+        _comp->comp(node, _terminal_num);
+        ++_terminal_num;
+      }
+    }
+    
+    /// \brief Executes the algorithm.
+    ///
+    /// Executes the algorithm.
+    ///
+    /// \pre init() must be called and at least some nodes should be
+    /// added with addTerminal() before using this function.
+    ///
+    /// This method constructs an approximation of the Steiner-Tree.
+    void start() {
+      _dijkstra.start();
+      
+      std::vector<External> externals;
+      for (UEdgeIt it(_graph); it != INVALID; ++it) {
+        Node s = _graph.source(it);
+        Node t = _graph.target(it);
+        if (_comp->comp(s) == _comp->comp(t)) continue;
+
+        Value cost = _dijkstra.dist(s) + _dijkstra.dist(t) + _cost[it];
+
+        if (_comp->comp(s) < _comp->comp(t)) {
+          externals.push_back(External(_comp->comp(s), _comp->comp(t), 
+                                       it, cost));
+        } else {
+          externals.push_back(External(_comp->comp(t), _comp->comp(s), 
+                                       it, cost));
+        }
+      }
+      std::sort(externals.begin(), externals.end(), ExternalLess());
+
+      SmartUGraph aux_graph;
+      std::vector<SmartUGraph::Node> aux_nodes;
+
+      for (int i = 0; i < _terminal_num; ++i) {
+        aux_nodes.push_back(aux_graph.addNode());
+      }
+
+      SmartUGraph::UEdgeMap<Value> aux_cost(aux_graph);
+      SmartUGraph::UEdgeMap<UEdge> cross(aux_graph);
+      {
+        int i = 0;
+        while (i < int(externals.size())) {
+          int sn = externals[i].source;
+          int tn = externals[i].target;
+          Value ev = externals[i].value;
+          UEdge ee = externals[i].uedge;
+          ++i;
+          while (i < int(externals.size()) && 
+                 sn == externals[i].source && tn == externals[i].target) {
+            if (externals[i].value < ev) {
+              ev = externals[i].value;
+              ee = externals[i].uedge;
+            }
+            ++i;
+          }
+          SmartUGraph::UEdge ne = 
+            aux_graph.addEdge(aux_nodes[sn], aux_nodes[tn]);
+          aux_cost.set(ne, ev);
+          cross.set(ne, ee);
+        }
+      }
+
+      std::vector<SmartUGraph::UEdge> aux_tree_edges;
+      BackInserterBoolMap<std::vector<SmartUGraph::UEdge> >
+        aux_tree_map(aux_tree_edges);
+      prim(aux_graph, aux_cost, aux_tree_map);
+
+      for (std::vector<SmartUGraph::UEdge>::iterator 
+             it = aux_tree_edges.begin(); it != aux_tree_edges.end(); ++it) {
+        Node node;
+        node = _graph.source(cross[*it]);
+        while (node != INVALID && !(*_filter)[node]) {
+          _filter->set(node, true);
+          node = (*_pred)[node] != INVALID ? 
+            _graph.source((*_pred)[node]) : INVALID;
+        }
+        node = _graph.target(cross[*it]);
+        while (node != INVALID && !(*_filter)[node]) {
+          _filter->set(node, true);
+          node = (*_pred)[node] != INVALID ? 
+            _graph.source((*_pred)[node]) : INVALID;
+        }
+      }
+
+      _value = prim(nodeSubUGraphAdaptor(_graph, *_filter), _cost, *_tree);
+            
+    }
+
+    /// \brief Checks if an edge is in the Steiner-tree or not.
+    ///
+    /// Checks if an edge is in the Steiner-tree or not.
+    /// \param e is the edge that will be checked
+    /// \return \c true if e is in the Steiner-tree, \c false otherwise
+    bool tree(UEdge e){
+      return (*_tree)[e];
+    }
+
+    /// \brief Checks if the node is in the Steiner-tree or not.
+    ///
+    /// Checks if a node is in the Steiner-tree or not.
+    /// \param n is the node that will be checked
+    /// \return \c true if n is in the Steiner-tree, \c false otherwise
+    bool tree(Node n){
+      return (*_filter)[n];
+    }
+
+    /// \brief Checks if the node is a Steiner-node.
+    ///
+    /// Checks if the node is a Steiner-node (i.e. a tree node but
+    /// not terminal).
+    /// \param n is the node that will be checked
+    /// \return \c true if n is a Steiner-node, \c false otherwise
+    bool steiner(Node n){
+      return (*_filter)[n] && (*_pred)[n] != INVALID;
+    }
+
+    /// \brief Checks if the node is a terminal.
+    ///
+    /// Checks if the node is a terminal.
+    /// \param n is the node that will be checked
+    /// \return \c true if n is a terminal, \c false otherwise
+    bool terminal(Node n){
+      return _dijkstra.reached(n) && (*_pred)[n] == INVALID;
+    }
+    
+    /// \brief The total cost of the tree
+    ///
+    /// The total cost of the constructed tree. The calculated value does
+    /// not exceed the double of the optimal value.
+    Value treeValue() const {
+      return _value;
+    }
+    
+  };
+
+} //END OF NAMESPACE LEMON
+
+#endif
Index: lemon/sub_graph.h
===================================================================
--- lemon/sub_graph.h	(revision 2553)
+++ lemon/sub_graph.h	(revision 2553)
@@ -0,0 +1,824 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_SUB_GRAPH_H
+#define LEMON_SUB_GRAPH_H
+
+#include <lemon/graph_adaptor.h>
+#include <lemon/bits/graph_adaptor_extender.h>
+#include <lemon/bits/default_map.h>
+
+/// \ingroup semi_adaptors
+/// \file
+/// \brief Subgraphs.
+///
+/// Graphs with filtered edge and node set.
+
+namespace lemon {
+
+  /// \brief Base for the SubGraph.
+  ///
+  /// Base for the SubGraph.
+  template <typename _Graph>
+  class SubGraphBase : public GraphAdaptorBase<const _Graph> {
+  public:
+    typedef _Graph Graph;
+    typedef SubGraphBase<_Graph> SubGraph;
+    typedef GraphAdaptorBase<const _Graph> Parent;
+    typedef Parent Base;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+
+  protected:
+
+    class NodesImpl;
+    class EdgesImpl;
+
+    SubGraphBase() {}
+
+    void construct(const Graph& _graph, NodesImpl& _nodes, EdgesImpl& _edges) {
+      Parent::setGraph(_graph);
+      nodes = &_nodes;
+      edges = &_edges;
+      firstNode = INVALID;
+
+      Node node;
+      Parent::first(node);
+      while (node != INVALID) {
+	(*nodes)[node].prev = node;
+	(*nodes)[node].firstIn = INVALID;
+	(*nodes)[node].firstOut = INVALID;
+	Parent::next(node);
+      }
+
+      Edge edge;
+      Parent::first(edge);
+      while (edge != INVALID) {
+	(*edges)[edge].prevOut = edge;
+	Parent::next(edge);
+      }
+    }
+
+  public:
+
+    void first(Node& node) const {
+      node = firstNode;
+    }
+    void next(Node& node) const {
+      node = (*nodes)[node].next;
+    }
+
+    void first(Edge& edge) const {
+      Node node = firstNode;
+      while (node != INVALID && (*nodes)[node].firstOut == INVALID) {
+	node = (*nodes)[node].next;
+      }
+      if (node == INVALID) {
+	edge = INVALID;
+      } else {
+	edge = (*nodes)[node].firstOut;
+      }
+    }
+    void next(Edge& edge) const {
+      if ((*edges)[edge].nextOut != INVALID) {
+	edge = (*edges)[edge].nextOut;
+      } else {
+	Node node = (*nodes)[source(edge)].next;
+	while (node != INVALID && (*nodes)[node].firstOut == INVALID) {
+	  node = (*nodes)[node].next;
+	}
+	if (node == INVALID) {
+	  edge = INVALID;
+	} else {
+	  edge = (*nodes)[node].firstOut;
+	}
+      }
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      edge = (*nodes)[node].firstOut;
+    }
+    void nextOut(Edge& edge) const {
+      edge = (*edges)[edge].nextOut;
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      edge = (*nodes)[node].firstIn;
+    }
+    void nextIn(Edge& edge) const {
+      edge = (*edges)[edge].nextIn;
+    }
+
+    /// \brief Returns true when the given node is hidden.
+    ///
+    /// Returns true when the given node is hidden.
+    bool hidden(const Node& node) const {
+      return (*nodes)[node].prev == node;
+    }
+
+    /// \brief Hide the given node in the sub-graph.
+    ///
+    /// Hide the given node in the sub graph. It just lace out from
+    /// the linked lists the given node. If there are incoming or outgoing
+    /// edges into or from this node then all of these will be hidden.
+    void hide(const Node& node) {
+      if (hidden(node)) return;
+      Edge edge;
+      firstOut(edge, node);
+      while (edge != INVALID) {
+	hide(edge);
+	firstOut(edge, node);
+      }
+
+      firstOut(edge, node);
+      while (edge != INVALID) {
+	hide(edge);
+	firstOut(edge, node);
+      }
+      if ((*nodes)[node].prev != INVALID) {
+	(*nodes)[(*nodes)[node].prev].next = (*nodes)[node].next;
+      } else {
+	firstNode = (*nodes)[node].next;
+      }
+      if ((*nodes)[node].next != INVALID) {
+	(*nodes)[(*nodes)[node].next].prev = (*nodes)[node].prev;
+      }
+      (*nodes)[node].prev = node;
+      (*nodes)[node].firstIn = INVALID;
+      (*nodes)[node].firstOut = INVALID;
+    }
+
+    /// \brief Unhide the given node in the sub-graph.
+    ///
+    /// Unhide the given node in the sub graph. It just lace in the given
+    /// node into the linked lists.
+    void unHide(const Node& node) {
+      if (!hidden(node)) return;
+      (*nodes)[node].next = firstNode;
+      (*nodes)[node].prev = INVALID;
+      if ((*nodes)[node].next != INVALID) {
+	(*nodes)[(*nodes)[node].next].prev = node;
+      }
+      firstNode = node;
+    }
+
+    /// \brief Returns true when the given edge is hidden.
+    ///
+    /// Returns true when the given edge is hidden.
+    bool hidden(const Edge& edge) const {
+      return (*edges)[edge].prevOut == edge;
+    }
+
+    /// \brief Hide the given edge in the sub-graph.
+    ///
+    /// Hide the given edge in the sub graph. It just lace out from
+    /// the linked lists the given edge.
+    void hide(const Edge& edge) {
+      if (hidden(edge)) return;
+      if ((*edges)[edge].prevOut == edge) return;
+      if ((*edges)[edge].prevOut != INVALID) {
+	(*edges)[(*edges)[edge].prevOut].nextOut = (*edges)[edge].nextOut;
+      } else {
+	(*nodes)[source(edge)].firstOut = (*edges)[edge].nextOut;
+      }
+      if ((*edges)[edge].nextOut != INVALID) {
+	(*edges)[(*edges)[edge].nextOut].prevOut = (*edges)[edge].prevOut;
+      }
+
+      if ((*edges)[edge].prevIn != INVALID) {
+	(*edges)[(*edges)[edge].prevIn].nextIn = (*edges)[edge].nextIn;
+      } else {
+	(*nodes)[target(edge)].firstIn = (*edges)[edge].nextIn;
+      }
+      if ((*edges)[edge].nextIn != INVALID) {
+	(*edges)[(*edges)[edge].nextIn].prevIn = (*edges)[edge].prevIn;
+      }
+      (*edges)[edge].next = edge;
+    }
+
+    /// \brief Unhide the given edge in the sub-graph.
+    ///
+    /// Unhide the given edge in the sub graph. It just lace in the given
+    /// edge into the linked lists. If the source or the target of the
+    /// node is hidden then it will unhide it.
+    void unHide(const Edge& edge) {
+      if (!hidden(edge)) return;
+
+      Node node;
+
+      node = Parent::source(edge);
+      unHide(node);
+      (*edges)[edge].nextOut = (*nodes)[node].firstOut;
+      (*edges)[edge].prevOut = INVALID;
+      if ((*edges)[edge].nextOut != INVALID) {
+	(*edges)[(*edges)[edge].nextOut].prevOut = edge;
+      }
+      (*nodes)[node].firstOut = edge;
+
+      node = Parent::target(edge);
+      unHide(node);
+      (*edges)[edge].nextIn = (*nodes)[node].firstIn;
+      (*edges)[edge].prevIn = INVALID;
+      if ((*edges)[edge].nextIn != INVALID) {
+	(*edges)[(*edges)[edge].nextIn].prevIn = edge;
+      }
+      (*nodes)[node].firstIn = edge;      
+    }
+    
+    typedef False NodeNumTag;
+    typedef False EdgeNumTag;
+
+  protected:
+    struct NodeT {
+      Node prev, next;
+      Edge firstIn, firstOut;
+    };
+    class NodesImpl : public DefaultMap<Graph, Node, NodeT> {
+      friend class SubGraphBase;
+    public:
+      typedef DefaultMap<Graph, Node, NodeT> Parent;
+
+      NodesImpl(SubGraph& _adaptor, const Graph& _graph) 
+	: Parent(_graph), adaptor(_adaptor) {}
+
+      virtual ~NodesImpl() {}
+
+      virtual void build() {
+	Parent::build();
+	Node node;
+	adaptor.Base::first(node);
+	while (node != INVALID) {
+	  Parent::operator[](node).prev = node;
+	  Parent::operator[](node).firstIn = INVALID;
+	  Parent::operator[](node).firstOut = INVALID;
+	  adaptor.Base::next(node);
+	}
+      }
+
+      virtual void clear() {
+	adaptor.firstNode = INVALID;
+	Parent::clear();
+      }
+
+      virtual void add(const Node& node) {
+	Parent::add(node);
+	Parent::operator[](node).prev = node;
+	Parent::operator[](node).firstIn = INVALID;
+	Parent::operator[](node).firstOut = INVALID;
+      }
+
+      virtual void add(const std::vector<Node>& nodes) {
+	Parent::add(nodes);
+	for (int i = 0; i < (int)nodes.size(); ++i) {
+	  Parent::operator[](nodes[i]).prev = nodes[i];
+	  Parent::operator[](nodes[i]).firstIn = INVALID;
+	  Parent::operator[](nodes[i]).firstOut = INVALID;
+	}
+      } 
+
+      virtual void erase(const Node& node) {
+	adaptor.hide(node);
+	Parent::erase(node);
+      }
+
+      virtual void erase(const std::vector<Node>& nodes) {
+	for (int i = 0; i < (int)nodes.size(); ++i) {
+	  adaptor.hide(nodes[i]);
+	}
+	Parent::erase(nodes);
+      }
+
+    private:
+      SubGraph& adaptor;
+    };
+
+    struct EdgeT {
+      Edge prevOut, nextOut;
+      Edge prevIn, nextIn;
+    };
+    class EdgesImpl : public DefaultMap<Graph, Edge, EdgeT> {
+      friend class SubGraphBase;
+    public:
+      typedef DefaultMap<Graph, Edge, EdgeT> Parent;
+
+      EdgesImpl(SubGraph& _adaptor, const Graph& _graph) 
+	: Parent(_graph), adaptor(_adaptor) {}
+
+      virtual ~EdgesImpl() {}
+
+      virtual void build() {
+	Parent::build();
+	Edge edge;
+	adaptor.Base::first(edge);
+	while (edge != INVALID) {
+	  Parent::operator[](edge).prevOut = edge;
+	  adaptor.Base::next(edge);
+	}
+      }
+
+      virtual void clear() {
+	Node node;
+	adaptor.first(node);
+	while (node != INVALID) {
+	  (*adaptor.nodes).firstIn = INVALID;
+	  (*adaptor.nodes).firstOut = INVALID;
+	  adaptor.next(node);
+	}
+	Parent::clear();
+      }
+
+      virtual void add(const Edge& edge) {
+	Parent::add(edge);
+	Parent::operator[](edge).prevOut = edge;
+      }
+
+      virtual void add(const std::vector<Edge>& edges) {
+	Parent::add(edges);
+	for (int i = 0; i < (int)edges.size(); ++i) {
+	  Parent::operator[](edges[i]).prevOut = edges[i];
+	}
+      }
+
+      virtual void erase(const Edge& edge) {
+	adaptor.hide(edge);
+	Parent::erase(edge);
+      }
+
+      virtual void erase(const std::vector<Edge>& edges) {
+	for (int i = 0; i < (int)edges.size(); ++i) {
+	  adaptor.hide(edges[i]);
+	}
+	Parent::erase(edges);
+      }
+
+    private:
+      SubGraph& adaptor;
+    };
+
+    NodesImpl* nodes;
+    EdgesImpl* edges;
+    Node firstNode;
+  };
+
+  /// \ingroup semi_adaptors
+  ///
+  /// \brief Graph which uses a subset of another graph's nodes and edges.
+  ///
+  /// Graph which uses a subset of another graph's nodes and edges. This class
+  /// is an alternative to the SubGraphAdaptor which is created for the
+  /// same reason. The main difference between the two class that it
+  /// makes linked lists on the unhidden nodes and edges what cause that
+  /// on sparse subgraphs the algorithms can be more efficient and some times
+  /// provide better time complexity. On other way this implemetation is
+  /// less efficient in most case when the subgraph filters out only
+  /// a few nodes or edges.
+  /// 
+  /// \see SubGraphAdaptor
+  /// \see EdgeSubGraphBase
+  template <typename Graph>
+  class SubGraph 
+    : public GraphAdaptorExtender< SubGraphBase<Graph> > {
+  public:
+    typedef GraphAdaptorExtender< SubGraphBase<Graph> > Parent;
+  public:
+    /// \brief Constructor for sub-graph.
+    ///
+    /// Constructor for sub-graph. Initially all the edges and nodes
+    /// are hidden in the graph.
+    SubGraph(const Graph& _graph) 
+      : Parent(), nodes(*this, _graph), edges(*this, _graph) { 
+      Parent::construct(_graph, nodes, edges);
+    }
+  private:
+    typename Parent::NodesImpl nodes;
+    typename Parent::EdgesImpl edges;
+  };
+
+  /// \brief Base for the EdgeSubGraph.
+  ///
+  /// Base for the EdgeSubGraph.
+  template <typename _Graph>
+  class EdgeSubGraphBase : public GraphAdaptorBase<const _Graph> {
+  public:
+    typedef _Graph Graph;
+    typedef EdgeSubGraphBase<_Graph> SubGraph;
+    typedef GraphAdaptorBase<const _Graph> Parent;
+    typedef Parent Base;
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+
+
+  protected:
+
+    class NodesImpl;
+    class EdgesImpl;
+
+    EdgeSubGraphBase() {}
+
+    void construct(const Graph& _graph, NodesImpl& _nodes, EdgesImpl& _edges) {
+      Parent::setGraph(_graph);
+      nodes = &_nodes;
+      edges = &_edges;
+
+      Node node;
+      Parent::first(node);
+      while (node != INVALID) {
+	(*nodes)[node].firstIn = INVALID;
+	(*nodes)[node].firstOut = INVALID;
+	Parent::next(node);
+      }
+
+      Edge edge;
+      Parent::first(edge);
+      while (edge != INVALID) {
+	(*edges)[edge].prevOut = edge;
+	Parent::next(edge);
+      }
+    }
+
+  public:
+
+    void first(Node& node) const {
+      Parent::first(node);
+    }
+    void next(Node& node) const {
+      Parent::next(node);
+    }
+
+    void first(Edge& edge) const {
+      Node node;
+      Parent::first(node);
+      while (node != INVALID && (*nodes)[node].firstOut == INVALID) {
+	Parent::next(node);
+      }
+      if (node == INVALID) {
+	edge = INVALID;
+      } else {
+	edge = (*nodes)[node].firstOut;
+      }
+    }
+    void next(Edge& edge) const {
+      if ((*edges)[edge].nextOut != INVALID) {
+	edge = (*edges)[edge].nextOut;
+      } else {
+	Node node = source(edge);
+	Parent::next(node);
+	while (node != INVALID && (*nodes)[node].firstOut == INVALID) {
+	  Parent::next(node);
+	}
+	if (node == INVALID) {
+	  edge = INVALID;
+	} else {
+	  edge = (*nodes)[node].firstOut;
+	}
+      }
+    }
+
+    void firstOut(Edge& edge, const Node& node) const {
+      edge = (*nodes)[node].firstOut;
+    }
+    void nextOut(Edge& edge) const {
+      edge = (*edges)[edge].nextOut;
+    }
+
+    void firstIn(Edge& edge, const Node& node) const {
+      edge = (*nodes)[node].firstIn;
+    }
+    void nextIn(Edge& edge) const {
+      edge = (*edges)[edge].nextIn;
+    }
+
+    /// \brief Returns true when the given edge is hidden.
+    ///
+    /// Returns true when the given edge is hidden.
+    bool hidden(const Edge& edge) const {
+      return (*edges)[edge].prevOut == edge;
+    }
+
+    /// \brief Hide the given edge in the sub-graph.
+    ///
+    /// Hide the given edge in the sub graph. It just lace out from
+    /// the linked lists the given edge.
+    void hide(const Edge& edge) {
+      if (hidden(edge)) return;
+      if ((*edges)[edge].prevOut != INVALID) {
+	(*edges)[(*edges)[edge].prevOut].nextOut = (*edges)[edge].nextOut;
+      } else {
+	(*nodes)[source(edge)].firstOut = (*edges)[edge].nextOut;
+      }
+      if ((*edges)[edge].nextOut != INVALID) {
+	(*edges)[(*edges)[edge].nextOut].prevOut = (*edges)[edge].prevOut;
+      }
+
+      if ((*edges)[edge].prevIn != INVALID) {
+	(*edges)[(*edges)[edge].prevIn].nextIn = (*edges)[edge].nextIn;
+      } else {
+	(*nodes)[target(edge)].firstIn = (*edges)[edge].nextIn;
+      }
+      if ((*edges)[edge].nextIn != INVALID) {
+	(*edges)[(*edges)[edge].nextIn].prevIn = (*edges)[edge].prevIn;
+      }
+      (*edges)[edge].prevOut = edge;
+    }
+
+    /// \brief Unhide the given edge in the sub-graph.
+    ///
+    /// Unhide the given edge in the sub graph. It just lace in the given
+    /// edge into the linked lists.
+    void unHide(const Edge& edge) {
+      if (!hidden(edge)) return;
+      Node node;
+
+      node = Parent::source(edge);
+      (*edges)[edge].nextOut = (*nodes)[node].firstOut;
+      (*edges)[edge].prevOut = INVALID;
+      if ((*edges)[edge].nextOut != INVALID) {
+	(*edges)[(*edges)[edge].nextOut].prevOut = edge;
+      }
+      (*nodes)[node].firstOut = edge;
+
+      node = Parent::target(edge);
+      (*edges)[edge].nextIn = (*nodes)[node].firstIn;
+      (*edges)[edge].prevIn = INVALID;
+      if ((*edges)[edge].nextIn != INVALID) {
+	(*edges)[(*edges)[edge].nextIn].prevIn = edge;
+      }
+      (*nodes)[node].firstIn = edge;      
+    }
+    
+  protected:
+    struct NodeT {
+      Edge firstIn, firstOut;
+    };
+    class NodesImpl : public DefaultMap<Graph, Node, NodeT> {
+      friend class EdgeSubGraphBase;
+    public:
+      typedef DefaultMap<Graph, Node, NodeT> Parent;
+
+      NodesImpl(SubGraph& _adaptor, const Graph& _graph) 
+	: Parent(_graph), adaptor(_adaptor) {}
+
+      virtual ~NodesImpl() {}
+
+      virtual void build() {
+	Parent::build();
+	Node node;
+	adaptor.Base::first(node);
+	while (node != INVALID) {
+	  Parent::operator[](node).firstIn = INVALID;
+	  Parent::operator[](node).firstOut = INVALID;
+	  adaptor.Base::next(node);
+	}
+      }
+
+      virtual void add(const Node& node) {
+	Parent::add(node);
+	Parent::operator[](node).firstIn = INVALID;
+	Parent::operator[](node).firstOut = INVALID;
+      }
+
+      virtual void add(const std::vector<Node>& nodes) {
+        Parent::add(nodes);
+        for (int i = 0; i < (int)nodes.size(); ++i) {
+          Parent::operator[](nodes[i]).firstIn = INVALID;
+          Parent::operator[](nodes[i]).firstOut = INVALID;
+        }
+      }
+
+    private:
+      SubGraph& adaptor;
+    };
+
+    struct EdgeT {
+      Edge prevOut, nextOut;
+      Edge prevIn, nextIn;
+    };
+    class EdgesImpl : public DefaultMap<Graph, Edge, EdgeT> {
+      friend class EdgeSubGraphBase;
+    public:
+      typedef DefaultMap<Graph, Edge, EdgeT> Parent;
+
+      EdgesImpl(SubGraph& _adaptor, const Graph& _graph) 
+	: Parent(_graph), adaptor(_adaptor) {}
+
+      virtual ~EdgesImpl() {}
+
+      virtual void build() {
+	Parent::build();
+	Edge edge;
+	adaptor.Base::first(edge);
+	while (edge != INVALID) {
+	  Parent::operator[](edge).prevOut = edge;
+	  adaptor.Base::next(edge);
+	}
+      }
+
+      virtual void clear() {
+	Node node;
+	adaptor.Base::first(node);
+	while (node != INVALID) {
+	  (*adaptor.nodes)[node].firstIn = INVALID;
+	  (*adaptor.nodes)[node].firstOut = INVALID;
+	  adaptor.Base::next(node);
+	}
+	Parent::clear();
+      }
+
+      virtual void add(const Edge& edge) {
+	Parent::add(edge);
+	Parent::operator[](edge).prevOut = edge;
+      }
+
+      virtual void add(const std::vector<Edge>& edges) {
+	Parent::add(edges);
+	for (int i = 0; i < (int)edges.size(); ++i) {
+	  Parent::operator[](edges[i]).prevOut = edges[i];
+	}
+      }
+
+      virtual void erase(const Edge& edge) {
+	adaptor.hide(edge);
+	Parent::erase(edge);
+      }
+
+      virtual void erase(const std::vector<Edge>& edges) {
+	for (int i = 0; i < (int)edges.size(); ++i) {
+	  adaptor.hide(edges[i]);
+	}
+	Parent::erase(edges);
+      }
+
+    private:
+      SubGraph& adaptor;
+    };
+
+    NodesImpl* nodes;
+    EdgesImpl* edges;
+  };
+
+  /// \ingroup semi_adaptors
+  ///
+  /// \brief Graph which uses a subset of another graph's edges.
+  ///
+  /// Graph which uses a subset of another graph's edges. This class
+  /// is an alternative to the EdgeSubGraphAdaptor which is created for the
+  /// same reason. The main difference between the two class that it
+  /// makes linked lists on the unhidden edges what cause that
+  /// on sparse subgraphs the algorithms can be more efficient and some times
+  /// provide better time complexity. On other way this implemetation is
+  /// less efficient in most case when the subgraph filters out only
+  /// a few edges.
+  /// 
+  /// \see EdgeSubGraphAdaptor
+  /// \see EdgeSubGraphBase
+  template <typename Graph>
+  class EdgeSubGraph 
+    : public GraphAdaptorExtender< EdgeSubGraphBase<Graph> > {
+  public:
+    typedef GraphAdaptorExtender< EdgeSubGraphBase<Graph> > Parent;
+  public:
+    /// \brief Constructor for sub-graph.
+    ///
+    /// Constructor for sub-graph. Initially all the edges are hidden in the 
+    /// graph.
+    EdgeSubGraph(const Graph& _graph) 
+      : Parent(), nodes(*this, _graph), edges(*this, _graph) { 
+      Parent::construct(_graph, nodes, edges);
+    }
+  private:
+    typename Parent::NodesImpl nodes;
+    typename Parent::EdgesImpl edges;
+  };
+
+
+//   template<typename Graph, typename Number, 
+// 	   typename CapacityMap, typename FlowMap>
+//   class ResGraph
+//     : public IterableGraphExtender<EdgeSubGraphBase<
+//     UGraphAdaptor<Graph> > > {
+//   public:
+//     typedef IterableGraphExtender<EdgeSubGraphBase<
+//       UGraphAdaptor<Graph> > > Parent;
+
+//   protected:
+//     UGraphAdaptor<Graph> u;
+
+//     const CapacityMap* capacity;
+//     FlowMap* flow;
+
+//     typename Parent::NodesImpl nodes;
+//     typename Parent::EdgesImpl edges;
+
+//     void setCapacityMap(const CapacityMap& _capacity) {
+//       capacity=&_capacity;
+//     }
+
+//     void setFlowMap(FlowMap& _flow) {
+//       flow=&_flow;
+//     }
+
+//   public:
+
+//     typedef typename UGraphAdaptor<Graph>::Node Node;
+//     typedef typename UGraphAdaptor<Graph>::Edge Edge;
+//     typedef typename UGraphAdaptor<Graph>::UEdge UEdge;
+
+//     ResGraphAdaptor(Graph& _graph, 
+// 		    const CapacityMap& _capacity, FlowMap& _flow) 
+//       : Parent(), u(_graph), capacity(&_capacity), flow(&_flow),
+// 	nodes(*this, _graph), edges(*this, _graph) {
+//       Parent::construct(u, nodes, edges);
+//       setFlowMap(_flow);
+//       setCapacityMap(_capacity);
+//       typename Graph::Edge edge; 
+//       for (_graph.first(edge); edge != INVALID; _graph.next(edge)) {
+// 	if ((*flow)[edge] != (*capacity)[edge]) {
+// 	  Parent::unHide(direct(edge, true));
+// 	}
+// 	if ((*flow)[edge] != 0) {
+// 	  Parent::unHide(direct(edge, false));
+// 	}
+//       }
+//     }
+
+//     void augment(const Edge& e, Number a) {
+//       if (direction(e)) {
+// 	flow->set(e, (*flow)[e]+a);
+//       } else { 
+// 	flow->set(e, (*flow)[e]-a);
+//       }
+//       if ((*flow)[e] == (*capacity)[e]) {
+// 	Parent::hide(e);
+//       } else {
+// 	Parent::unHide(e);
+//       }
+//       if ((*flow)[e] == 0) {
+// 	Parent::hide(oppositeEdge(e));
+//       } else {
+// 	Parent::unHide(oppositeEdge(e));
+//       }
+//     }
+
+//     Number resCap(const Edge& e) {
+//       if (direction(e)) { 
+// 	return (*capacity)[e]-(*flow)[e]; 
+//       } else { 
+// 	return (*flow)[e];
+//       }
+//     }
+    
+//     bool direction(const Edge& edge) const {
+//       return Parent::getGraph().direction(edge);
+//     }
+
+//     Edge direct(const UEdge& edge, bool direction) const {
+//       return Parent::getGraph().direct(edge, direction);
+//     }
+
+//     Edge direct(const UEdge& edge, const Node& node) const {
+//       return Parent::getGraph().direct(edge, node);
+//     }
+
+//     Edge oppositeEdge(const Edge& edge) const {
+//       return Parent::getGraph().oppositeEdge(edge);
+//     }
+
+//     /// \brief Residual capacity map.
+//     ///
+//     /// In generic residual graphs the residual capacity can be obtained 
+//     /// as a map. 
+//     class ResCap {
+//     protected:
+//       const ResGraphAdaptor* res_graph;
+//     public:
+//       typedef Number Value;
+//       typedef Edge Key;
+//       ResCap(const ResGraphAdaptor& _res_graph) 
+// 	: res_graph(&_res_graph) {}
+//       Number operator[](const Edge& e) const {
+// 	return res_graph->resCap(e);
+//       }
+//     };
+//   };
+
+}
+
+#endif
Index: lemon/suurballe.h
===================================================================
--- lemon/suurballe.h	(revision 2586)
+++ lemon/suurballe.h	(revision 2586)
@@ -0,0 +1,498 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_SUURBALLE_H
+#define LEMON_SUURBALLE_H
+
+///\ingroup shortest_path
+///\file
+///\brief An algorithm for finding edge-disjoint paths between two
+/// nodes having minimum total length.
+
+#include <vector>
+#include <lemon/bin_heap.h>
+#include <lemon/path.h>
+
+namespace lemon {
+
+  /// \addtogroup shortest_path
+  /// @{
+
+  /// \brief Implementation of an algorithm for finding edge-disjoint
+  /// paths between two nodes having minimum total length.
+  ///
+  /// \ref lemon::Suurballe "Suurballe" implements an algorithm for
+  /// finding edge-disjoint paths having minimum total length (cost)
+  /// from a given source node to a given target node in a directed
+  /// graph.
+  ///
+  /// In fact, this implementation is the specialization of the
+  /// \ref CapacityScaling "successive shortest path" algorithm.
+  ///
+  /// \tparam Graph The directed graph type the algorithm runs on.
+  /// \tparam LengthMap The type of the length (cost) map.
+  ///
+  /// \warning Length values should be \e non-negative \e integers.
+  ///
+  /// \note For finding node-disjoint paths this algorithm can be used
+  /// with \ref SplitGraphAdaptor.
+  ///
+  /// \author Attila Bernath and Peter Kovacs
+  
+  template < typename Graph, 
+             typename LengthMap = typename Graph::template EdgeMap<int> >
+  class Suurballe
+  {
+    GRAPH_TYPEDEFS(typename Graph);
+
+    typedef typename LengthMap::Value Length;
+    typedef ConstMap<Edge, int> ConstEdgeMap;
+    typedef typename Graph::template NodeMap<Edge> PredMap;
+
+  public:
+
+    /// The type of the flow map.
+    typedef typename Graph::template EdgeMap<int> FlowMap;
+    /// The type of the potential map.
+    typedef typename Graph::template NodeMap<Length> PotentialMap;
+    /// The type of the path structures.
+    typedef SimplePath<Graph> Path;
+
+  private:
+  
+    /// \brief Special implementation of the \ref Dijkstra algorithm
+    /// for finding shortest paths in the residual network.
+    ///
+    /// \ref ResidualDijkstra is a special implementation of the
+    /// \ref Dijkstra algorithm for finding shortest paths in the
+    /// residual network of the graph with respect to the reduced edge
+    /// lengths and modifying the node potentials according to the
+    /// distance of the nodes.
+    class ResidualDijkstra
+    {
+      typedef typename Graph::template NodeMap<int> HeapCrossRef;
+      typedef BinHeap<Length, HeapCrossRef> Heap;
+
+    private:
+
+      // The directed graph the algorithm runs on
+      const Graph &_graph;
+
+      // The main maps
+      const FlowMap &_flow;
+      const LengthMap &_length;
+      PotentialMap &_potential;
+
+      // The distance map
+      PotentialMap _dist;
+      // The pred edge map
+      PredMap &_pred;
+      // The processed (i.e. permanently labeled) nodes
+      std::vector<Node> _proc_nodes;
+      
+      Node _s;
+      Node _t;
+
+    public:
+
+      /// Constructor.
+      ResidualDijkstra( const Graph &graph,
+                        const FlowMap &flow,
+                        const LengthMap &length,
+                        PotentialMap &potential,
+                        PredMap &pred,
+                        Node s, Node t ) :
+        _graph(graph), _flow(flow), _length(length), _potential(potential),
+        _dist(graph), _pred(pred), _s(s), _t(t) {}
+
+      /// \brief Runs the algorithm. Returns \c true if a path is found
+      /// from the source node to the target node.
+      bool run() {
+        HeapCrossRef heap_cross_ref(_graph, Heap::PRE_HEAP);
+        Heap heap(heap_cross_ref);
+        heap.push(_s, 0);
+        _pred[_s] = INVALID;
+        _proc_nodes.clear();
+
+        // Processing nodes
+        while (!heap.empty() && heap.top() != _t) {
+          Node u = heap.top(), v;
+          Length d = heap.prio() + _potential[u], nd;
+          _dist[u] = heap.prio();
+          heap.pop();
+          _proc_nodes.push_back(u);
+
+          // Traversing outgoing edges
+          for (OutEdgeIt e(_graph, u); e != INVALID; ++e) {
+            if (_flow[e] == 0) {
+              v = _graph.target(e);
+              switch(heap.state(v)) {
+              case Heap::PRE_HEAP:
+                heap.push(v, d + _length[e] - _potential[v]);
+                _pred[v] = e;
+                break;
+              case Heap::IN_HEAP:
+                nd = d + _length[e] - _potential[v];
+                if (nd < heap[v]) {
+                  heap.decrease(v, nd);
+                  _pred[v] = e;
+                }
+                break;
+              case Heap::POST_HEAP:
+                break;
+              }
+            }
+          }
+
+          // Traversing incoming edges
+          for (InEdgeIt e(_graph, u); e != INVALID; ++e) {
+            if (_flow[e] == 1) {
+              v = _graph.source(e);
+              switch(heap.state(v)) {
+              case Heap::PRE_HEAP:
+                heap.push(v, d - _length[e] - _potential[v]);
+                _pred[v] = e;
+                break;
+              case Heap::IN_HEAP:
+                nd = d - _length[e] - _potential[v];
+                if (nd < heap[v]) {
+                  heap.decrease(v, nd);
+                  _pred[v] = e;
+                }
+                break;
+              case Heap::POST_HEAP:
+                break;
+              }
+            }
+          }
+        }
+        if (heap.empty()) return false;
+
+        // Updating potentials of processed nodes
+        Length t_dist = heap.prio();
+        for (int i = 0; i < int(_proc_nodes.size()); ++i)
+          _potential[_proc_nodes[i]] += _dist[_proc_nodes[i]] - t_dist;
+        return true;
+      }
+
+    }; //class ResidualDijkstra
+
+  private:
+
+    // The directed graph the algorithm runs on
+    const Graph &_graph;
+    // The length map
+    const LengthMap &_length;
+    
+    // Edge map of the current flow
+    FlowMap *_flow;
+    bool _local_flow;
+    // Node map of the current potentials
+    PotentialMap *_potential;
+    bool _local_potential;
+
+    // The source node
+    Node _source;
+    // The target node
+    Node _target;
+
+    // Container to store the found paths
+    std::vector< SimplePath<Graph> > paths;
+    int _path_num;
+
+    // The pred edge map
+    PredMap _pred;
+    // Implementation of the Dijkstra algorithm for finding augmenting
+    // shortest paths in the residual network
+    ResidualDijkstra *_dijkstra;
+
+  public:
+
+    /// \brief Constructor.
+    ///
+    /// Constructor.
+    ///
+    /// \param graph The directed graph the algorithm runs on.
+    /// \param length The length (cost) values of the edges.
+    /// \param s The source node.
+    /// \param t The target node.
+    Suurballe( const Graph &graph,
+               const LengthMap &length,
+               Node s, Node t ) :
+      _graph(graph), _length(length), _flow(0), _local_flow(false),
+      _potential(0), _local_potential(false), _source(s), _target(t),
+      _pred(graph) {}
+
+    /// Destructor.
+    ~Suurballe() {
+      if (_local_flow) delete _flow;
+      if (_local_potential) delete _potential;
+      delete _dijkstra;
+    }
+
+    /// \brief Sets the flow map.
+    ///
+    /// Sets the flow map.
+    ///
+    /// The found flow contains only 0 and 1 values. It is the union of
+    /// the found edge-disjoint paths.
+    ///
+    /// \return \c (*this)
+    Suurballe& flowMap(FlowMap &map) {
+      if (_local_flow) {
+        delete _flow;
+        _local_flow = false;
+      }
+      _flow = &map;
+      return *this;
+    }
+
+    /// \brief Sets the potential map.
+    ///
+    /// Sets the potential map.
+    ///
+    /// The potentials provide the dual solution of the underlying 
+    /// minimum cost flow problem.
+    ///
+    /// \return \c (*this)
+    Suurballe& potentialMap(PotentialMap &map) {
+      if (_local_potential) {
+        delete _potential;
+        _local_potential = false;
+      }
+      _potential = &map;
+      return *this;
+    }
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to call the run()
+    /// function.
+    /// \n
+    /// If you only need the flow that is the union of the found
+    /// edge-disjoint paths, you may call init() and findFlow().
+
+    /// @{
+
+    /// \brief Runs the algorithm.
+    ///
+    /// Runs the algorithm.
+    ///
+    /// \param k The number of paths to be found.
+    ///
+    /// \return \c k if there are at least \c k edge-disjoint paths
+    /// from \c s to \c t. Otherwise it returns the number of
+    /// edge-disjoint paths found.
+    ///
+    /// \note Apart from the return value, <tt>s.run(k)</tt> is just a
+    /// shortcut of the following code.
+    /// \code
+    ///   s.init();
+    ///   s.findFlow(k);
+    ///   s.findPaths();
+    /// \endcode
+    int run(int k = 2) {
+      init();
+      findFlow(k);
+      findPaths();
+      return _path_num;
+    }
+
+    /// \brief Initializes the algorithm.
+    ///
+    /// Initializes the algorithm.
+    void init() {
+      // Initializing maps
+      if (!_flow) {
+        _flow = new FlowMap(_graph);
+        _local_flow = true;
+      }
+      if (!_potential) {
+        _potential = new PotentialMap(_graph);
+        _local_potential = true;
+      }
+      for (EdgeIt e(_graph); e != INVALID; ++e) (*_flow)[e] = 0;
+      for (NodeIt n(_graph); n != INVALID; ++n) (*_potential)[n] = 0;
+
+      _dijkstra = new ResidualDijkstra( _graph, *_flow, _length, 
+                                        *_potential, _pred,
+                                        _source, _target );
+    }
+
+    /// \brief Executes the successive shortest path algorithm to find
+    /// an optimal flow.
+    ///
+    /// Executes the successive shortest path algorithm to find a
+    /// minimum cost flow, which is the union of \c k or less
+    /// edge-disjoint paths.
+    ///
+    /// \return \c k if there are at least \c k edge-disjoint paths
+    /// from \c s to \c t. Otherwise it returns the number of
+    /// edge-disjoint paths found.
+    ///
+    /// \pre \ref init() must be called before using this function.
+    int findFlow(int k = 2) {
+      // Finding shortest paths
+      _path_num = 0;
+      while (_path_num < k) {
+        // Running Dijkstra
+        if (!_dijkstra->run()) break;
+        ++_path_num;
+
+        // Setting the flow along the found shortest path
+        Node u = _target;
+        Edge e;
+        while ((e = _pred[u]) != INVALID) {
+          if (u == _graph.target(e)) {
+            (*_flow)[e] = 1;
+            u = _graph.source(e);
+          } else {
+            (*_flow)[e] = 0;
+            u = _graph.target(e);
+          }
+        }
+      }
+      return _path_num;
+    }
+    
+    /// \brief Computes the paths from the flow.
+    ///
+    /// Computes the paths from the flow.
+    ///
+    /// \pre \ref init() and \ref findFlow() must be called before using
+    /// this function.
+    void findPaths() {
+      // Creating the residual flow map (the union of the paths not
+      // found so far)
+      FlowMap res_flow(*_flow);
+
+      paths.clear();
+      paths.resize(_path_num);
+      for (int i = 0; i < _path_num; ++i) {
+        Node n = _source;
+        while (n != _target) {
+          OutEdgeIt e(_graph, n);
+          for ( ; res_flow[e] == 0; ++e) ;
+          n = _graph.target(e);
+          paths[i].addBack(e);
+          res_flow[e] = 0;
+        }
+      }
+    }
+
+    /// @}
+
+    /// \name Query Functions
+    /// The result of the algorithm can be obtained using these
+    /// functions.
+    /// \n The algorithm should be executed before using them.
+
+    /// @{
+
+    /// \brief Returns a const reference to the edge map storing the
+    /// found flow.
+    ///
+    /// Returns a const reference to the edge map storing the flow that
+    /// is the union of the found edge-disjoint paths.
+    ///
+    /// \pre \ref run() or findFlow() must be called before using this
+    /// function.
+    const FlowMap& flowMap() const {
+      return *_flow;
+    }
+
+    /// \brief Returns a const reference to the node map storing the
+    /// found potentials (the dual solution).
+    ///
+    /// Returns a const reference to the node map storing the found
+    /// potentials that provide the dual solution of the underlying 
+    /// minimum cost flow problem.
+    ///
+    /// \pre \ref run() or findFlow() must be called before using this
+    /// function.
+    const PotentialMap& potentialMap() const {
+      return *_potential;
+    }
+
+    /// \brief Returns the flow on the given edge.
+    ///
+    /// Returns the flow on the given edge.
+    /// It is \c 1 if the edge is involved in one of the found paths,
+    /// otherwise it is \c 0.
+    ///
+    /// \pre \ref run() or findFlow() must be called before using this
+    /// function.
+    int flow(const Edge& edge) const {
+      return (*_flow)[edge];
+    }
+
+    /// \brief Returns the potential of the given node.
+    ///
+    /// Returns the potential of the given node.
+    ///
+    /// \pre \ref run() or findFlow() must be called before using this
+    /// function.
+    Length potential(const Node& node) const {
+      return (*_potential)[node];
+    }
+
+    /// \brief Returns the total length (cost) of the found paths (flow).
+    ///
+    /// Returns the total length (cost) of the found paths (flow).
+    /// The complexity of the function is \f$ O(e) \f$.
+    ///
+    /// \pre \ref run() or findFlow() must be called before using this
+    /// function.
+    Length totalLength() const {
+      Length c = 0;
+      for (EdgeIt e(_graph); e != INVALID; ++e)
+        c += (*_flow)[e] * _length[e];
+      return c;
+    }
+
+    /// \brief Returns the number of the found paths.
+    ///
+    /// Returns the number of the found paths.
+    ///
+    /// \pre \ref run() or findFlow() must be called before using this
+    /// function.
+    int pathNum() const {
+      return _path_num;
+    }
+
+    /// \brief Returns a const reference to the specified path.
+    ///
+    /// Returns a const reference to the specified path.
+    ///
+    /// \param i The function returns the \c i-th path.
+    /// \c i must be between \c 0 and <tt>%pathNum()-1</tt>.
+    ///
+    /// \pre \ref run() or findPaths() must be called before using this
+    /// function.
+    Path path(int i) const {
+      return paths[i];
+    }
+
+    /// @}
+
+  }; //class Suurballe
+
+  ///@}
+
+} //namespace lemon
+
+#endif //LEMON_SUURBALLE_H
Index: lemon/tabu_search.h
===================================================================
--- lemon/tabu_search.h	(revision 2553)
+++ lemon/tabu_search.h	(revision 2553)
@@ -0,0 +1,531 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_TABU_SEARCH_H
+#define LEMON_TABU_SEARCH_H
+
+/// \ingroup metah
+/// \file
+/// \brief TabuSearch algorithm.
+///
+/// \author Szabadkai Mark
+
+#include <lemon/bits/utility.h>
+#include <lemon/error.h>
+#include <lemon/time_measure.h>
+#include <functional>
+#include <deque>
+
+
+namespace lemon {
+
+  /// \brief Default Traits for TabuSearch class.
+  /// 
+  /// This template defines the needed types for the \ref TabuSearch class.
+  /// Is main purpos is to simplify the main class's template interface,
+  /// but it provides the EdgeIt type, passing to the concrete graph wheter
+  /// it is directed or undirected.
+#ifdef DOXYGEN
+  template< typename GRAPH, typename VALUE, 
+            typename HEIGHTMAP, typename BETTER, bool UNDIR >
+#else
+  template< typename GRAPH, typename VALUE,
+            typename HEIGHTMAP = typename GRAPH::template NodeMap<VALUE>,
+            typename BETTER = std::less<VALUE>,
+            bool UNDIR = UndirectedTagIndicator<GRAPH>::value >
+#endif
+  struct TabuSearchDefaultTraits {
+    typedef  VALUE  Value; 
+    typedef  BETTER  Better;
+
+    typedef  GRAPH  Graph;
+    typedef  typename GRAPH::Node  Node;
+    typedef  HEIGHTMAP  HeightMap;
+
+    typedef  typename GRAPH::IncEdgeIt  EdgeIt;
+  };
+
+  template< typename GRAPH, typename VALUE, 
+            typename HEIGHTMAP, typename BETTER >
+  struct TabuSearchDefaultTraits< GRAPH, VALUE, HEIGHTMAP, BETTER, false > {
+    typedef  VALUE  Value;
+    typedef  BETTER  Better;
+
+    typedef  GRAPH  Graph;
+    typedef  typename GRAPH::Node  Node;
+    typedef  HEIGHTMAP  HeightMap;
+
+    typedef  typename GRAPH::OutEdgeIt  EdgeIt;
+  };
+
+
+
+  /// \brief Policy hierarchy to controll the search algorithm.
+  ///
+  /// The fallowing template hierarchy offers a clean interface to define own
+  /// policies, and combine existing ones.
+  template< typename TS >
+  struct TabuSearchPolicyConcept {
+    void  target( TS *ts ) {}
+
+    void  reset()  {}
+    bool  onStep() { return false; }
+    bool  onStick() { return false; }
+    bool  onImprove( const typename TS::Value &best ) { return false; }
+  };
+
+  template< typename TS >
+  struct YesPolicy {
+    void  target( TS *ts ) {}
+
+    void  reset()  {}
+    bool  onStep() { return true; }
+    bool  onStick() { return true; }
+    bool  onImprove( const typename TS::Value &best ) { return true; }
+  };
+
+  template< typename TS >
+  struct NoPolicy : public TabuSearchPolicyConcept<TS> {};
+
+  /// \brief Some basic methode, how tow Policies can be combined
+  struct PolicyAndCombination {
+    static bool  evaluate( const bool r1, const bool r2 ) {
+      return r1 && r2;
+    }
+  };
+
+  struct PolicyOrCombination {
+    static bool  evaluate( const bool r1, const bool r2 ) {
+      return r1 || r2;
+    }
+  };
+
+  /// \brief CombinePolicies
+  ///
+  /// It combines tow policies using the given combination methode (mainly
+  /// some of the basic logical methodes) to create a new one.
+#ifdef DOXYGEN
+  template< template<typename> class CP1, template<typename> class CP2, 
+            typename COMBINATION >
+#else
+  template< template<typename> class CP1, template<typename> class CP2,
+            typename COMBINATION = PolicyAndCombination >
+#endif
+  struct CombinePolicies {
+    template< typename TS >
+    struct Policy {
+      typedef CP1<TS>  Policy1;
+      typedef CP2<TS>  Policy2;
+      
+      Policy1  policy1;
+      Policy2  policy2;
+
+      inline Policy() : policy1(), policy2() {}
+      inline Policy( const Policy1 &cp1, const Policy2 &cp2 ) 
+        : policy1(cp1), policy2(cp2) {}
+
+      void  target( TS *ts ) {
+        policy1.target(ts), policy2.target(ts);
+      };
+
+      void  reset() {
+        policy1.reset(), policy2.reset();
+      }
+
+      bool  onStep() {
+        return cmb.evaluate( policy1.onStep(), policy2.onStep() );
+      }
+
+      bool  onStick() {
+        return cmb.evaluate( policy1.onStick(), policy2.onStick() );
+      }
+
+      bool  onImprove( const typename TS::Value &best ) {
+        return cmb.evaluate( policy1.onImprove(best), 
+                             policy2.onImprove(best) );
+      }
+
+    private:
+      COMBINATION cmb;
+    };
+  };
+
+
+  /// \brief IterationPolicy limits the number of iterations and the
+  /// number of iterations without improvement
+  template< typename TS >
+  struct IterationPolicy {
+    IterationPolicy() : _it_lim(100000), _noimpr_it_lim(5000) {}
+    IterationPolicy( const long int itl, const long int noimpritl )
+      : _it_lim(itl), _noimpr_it_lim(noimpritl)
+    {}
+
+    void  target( TS *ts ) {}
+
+    void  reset() {
+      _it = _noimpr_it = 0;
+    }
+
+    bool  onStep() {
+      ++_it; ++_noimpr_it;
+      return (_it <= _it_lim) && (_noimpr_it <= _noimpr_it_lim);
+    }
+		
+    bool  onStick() {
+      return false;
+    }
+
+    bool  onImprove( const typename TS::Value &best ) {
+      _noimpr_it = 0;
+      return true;
+    }
+
+    long int  iterationLimit() const {
+      return _it_lim;
+    }
+
+    void  iterationLimit( const long int itl ) {
+      _it_lim = itl;
+    }
+
+    long int  noImprovementIterationLimit() const {
+      return _noimpr_it_lim;
+    }
+
+    void  noImprovementIterationLimit( const long int noimpritl ) {
+      _noimpr_it_lim = noimpritl;
+    }
+
+  private:
+    long int  _it_lim, _noimpr_it_lim;
+    long int  _it, _noimpr_it;
+  };
+
+  /// \brief HeightPolicy stops the search when a given height is reached or
+  /// exceeds
+  template< typename TS >
+  struct HeightPolicy {
+    typedef typename TS::Value  Value;
+
+    HeightPolicy() : _height_lim(), _found(false) {}
+    HeightPolicy( const Value &hl ) : _height_lim(hl), _found(false) {}
+
+    void  target( TS *ts ) {}
+
+    void  reset() {
+      _found = false;
+    }
+
+    bool  onStep() {
+      return !_found;
+    }
+
+    bool  onStick() {
+      return false;
+    }
+
+    bool  onImprove( const Value &best ) {
+      typename TS::Better  better;
+      _found = better(best, _height_lim) || (best == _height_lim);
+      return !_found;
+    }
+
+    Value  heightLimi() const {
+      return _height_lim;
+    }
+
+    void  heightLimi( const Value &hl ) {
+      _height_lim = hl;
+    }
+
+  private:
+    Value  _height_lim;
+    bool  _found;
+  };
+
+  /// \brief TimePolicy limits the time for searching.
+  template< typename TS >
+  struct TimePolicy {
+    TimePolicy() : _time_lim(60.0), _timeisup(false) {}
+    TimePolicy( const double tl ) : _time_lim(tl), _timeisup(false) {}
+
+    void  target( TS *ts ) {}
+
+    void  reset() {
+      _timeisup = false;
+      _t.reset();
+    }
+
+    bool  onStep() {
+      update();
+      return !_timeisup;
+    }
+
+    bool  onStick() {
+      return false;
+    }
+
+    bool  onImprove( const typename TS::Value &best ) {
+      update();
+      return !_timeisup;
+    }
+
+    double timeLimit() const {
+      return _time_lim;
+    }
+
+    void  setTimeLimit( const double tl ) {
+      _time_lim = tl;
+      update();
+    }
+
+  private:
+    lemon::Timer  _t;
+    double  _time_lim;
+    bool  _timeisup;
+
+    inline void  update() {
+      _timeisup = _t.realTime() > _time_lim;
+    }
+  };
+
+
+
+  /// \ingroup metah
+  ///
+  /// \brief TabuSearch main class
+  ///
+  /// This class offers the implementation of tabu-search algorithm. The
+  /// tabu-serach is a local-search. It starts from a specified point of the
+  /// problem's graph representation, and in every step it goes to the localy
+  /// best next Node except those in tabu set. The maximum size of this tabu
+  /// set defines how many Node will be remembered. The best Node ever found
+  /// will also stored, so we wont lose it, even is the search continues.
+  /// The class can be used on any kind of Graph and with any kind of Value
+  /// with a total-settlement on it.
+  ///
+  /// \param _Graph The graph type the algorithm runs on.
+  /// \param _Value The values' type associated to the nodes.
+  /// \param _Policy Controlls the search. Determinates when to stop, or how
+  /// manage stuck search. Default value is \ref IterationPolicy .
+  /// \param _Traits Collection of needed types. Default value is
+  /// \ref TabuSearchDefaultTraits .
+  ///
+  /// \author Szabadkai Mark
+#ifdef DOXYGEN
+  template< typename GRAPH, typename VALUE, template<typename> class POLICY, typename TRAITS >
+#else
+  template< typename GRAPH, typename VALUE,
+            template<typename> class POLICY = IterationPolicy,
+            typename TRAITS = TabuSearchDefaultTraits<GRAPH, VALUE> >
+#endif
+  class TabuSearch
+  {
+  public:
+
+    /// \brief Thrown by setting the size of the tabu-set and the given size
+    /// is less than 2.
+    class BadParameterError : public lemon::LogicError {
+    public:
+      virtual const char* what() const throw() {
+        return "lemon::TabuSearch::BadParameterError";
+      }
+    };
+
+    ///Public types
+    typedef  TabuSearch<GRAPH,VALUE,POLICY,TRAITS>  SelfType;
+
+    typedef  typename TRAITS::Graph  Graph;
+    typedef  typename TRAITS::Node  Node;
+    typedef  typename TRAITS::Value  Value;
+    typedef  typename TRAITS::HeightMap  HeightMap;
+    typedef  typename TRAITS::Better  Better;
+    typedef  typename std::deque< Node >::const_iterator  TabuIterator;
+
+    typedef  POLICY<SelfType>  Policy;
+
+  protected:
+    typedef  typename TRAITS::EdgeIt  EdgeIt;
+
+    const Graph  &gr;
+    const HeightMap  &height;
+    /// The tabu set. Teh current node is the first
+    std::deque< Node >  tabu;
+    /// Maximal tabu size
+    unsigned int  mts;
+    /// The best Node found
+    Node  b;
+
+    Better  better;
+    Policy  pol;
+
+  public:
+    /// \brief Constructor
+    ///
+    /// \param graph the graph the algorithm will run on.
+    /// \param hm the height map used by the algorithm.
+    /// \param tabusz the maximal size of the tabu set. Default value is 3
+    /// \param p the Policy controlling the search.
+    TabuSearch( const Graph &graph, const HeightMap &hm, 
+                const int tabusz = 3, Policy p = Policy() )
+      : gr(graph), height(hm), mts(tabusz), pol(p)
+    {
+      pol.target(this);
+    }
+
+    /// \brief Destructor
+    ~TabuSearch() {
+      pol.target(NULL);
+    }
+
+    /// Set/Get the size of the tabu set
+    void  tabuSize( const unsigned int size )
+    {
+      if( size < 2 )
+      throw BadParameterError( "Tabu size must be at least 2!" );
+      mts = size;
+      while( mts < tabu.size() )
+      tabu.pop_back();
+    }
+
+    unsigned int  tabuSize() const {
+      return mts;
+    }
+
+    /// Set/Get Policy
+    void  policy( Policy p ) {
+      pol.target(NULL);
+      pol = p;
+      pol.target(this);
+    }
+		
+    Policy& policy()  {
+      return pol;
+    }
+
+    /// \name Execution control
+    /// The simplest way to execute the algorithm is to use the member
+    /// functions called \c run( 'startnode' ).
+    ///@{
+
+    /// \brief Initializes the internal data.
+    ///
+    /// \param startn The start node where the search begins.
+    void  init( const Node startn ) {
+      tabu.clear();
+      tabu.push_front( startn );
+      b = startn;
+      pol.reset();
+    }
+
+    /// \brief Does one iteration
+    ///
+    /// If the Policy allows it searches for the best next node, then steps
+    /// onto it.
+    /// \return %False if one Policy condition wants to stop the search.
+    bool  step()
+    {
+      ///Request premmision from ControllPolicy
+      if( !pol.onStep() )
+      return false;
+	
+      ///Find the best next potential node
+      Node n; bool found = false;
+      for( EdgeIt e(gr,tabu[0]); e != INVALID; ++e )
+      {
+        Node m = (gr.source(e) == tabu[0]) ? gr.target(e) : gr.source(e);
+        bool wrong = false;
+        for( int i = 1; i != (signed int)tabu.size(); ++i )
+          if( m == tabu[i] ) {
+            wrong = true;
+            break;
+          }
+        if( wrong )
+          continue;
+
+        if( !found ) {
+          n = m;
+          found = true;
+        } else
+          if( better(height[m], height[n]) ) {
+            n = m;
+          }
+      }
+
+      ///Handle stuck search
+      if( !found ) {
+        return pol.onStick();
+      }
+
+      ///Move on...
+      tabu.push_front(n);
+      while( mts < tabu.size() ) {
+        tabu.pop_back();
+      }
+      if( better(height[n], height[b]) ) {
+        b = n;
+        if( !pol.onImprove(height[b]) )
+        return false;
+      }
+
+      return true;
+    }
+
+    /// \brief Runs a search while the Policy stops it.
+    ///
+    /// \param startn The start node where the search begins.
+    inline void  run( const Node startn ) {
+      std::cin.unsetf( std::ios_base::skipws );
+      char c;
+      init( startn );
+      while( step() )
+      std::cin >> c;
+      std::cin.setf( std::ios_base::skipws );
+    }
+
+    ///@}
+
+    /// \name Query Functions
+    /// The result of the TabuSearch algorithm can be obtained using these
+    /// functions.\n
+    ///@{
+
+    /// \brief The node, the search is standing on.
+    inline Node  current() const {
+      return tabu[0];
+    }
+
+    /// \brief The best node found until now.
+    inline Node  best() const {
+      return b;
+    }
+
+    /// \brief Beginning to iterate on the current tabu set.
+    inline TabuIterator  tabu_begin() const {
+      return tabu.begin();
+    }
+
+    /// \brief Ending to iterate on the current tabu set.
+    inline TabuIterator  tabu_end() const {
+      return tabu.end();
+    }
+
+    ///@}
+  };
+}
+#endif
Index: lemon/time_measure.h
===================================================================
--- lemon/time_measure.h	(revision 2553)
+++ lemon/time_measure.h	(revision 2553)
@@ -0,0 +1,546 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_TIME_MEASURE_H
+#define LEMON_TIME_MEASURE_H
+
+///\ingroup timecount
+///\file
+///\brief Tools for measuring cpu usage
+
+
+#ifdef WIN32
+#include <lemon/bits/mingw32_time.h>
+#else
+#include <sys/times.h>
+#endif
+
+#include <sys/time.h>
+#include <fstream>
+#include <iostream>
+#include <unistd.h>
+
+namespace lemon {
+
+  /// \addtogroup timecount
+  /// @{
+
+  /// A class to store (cpu)time instances.
+
+  /// This class stores five time values.
+  /// - a real time
+  /// - a user cpu time
+  /// - a system cpu time
+  /// - a user cpu time of children
+  /// - a system cpu time of children
+  ///
+  /// TimeStamp's can be added to or substracted from each other and
+  /// they can be pushed to a stream.
+  ///
+  /// In most cases, perhaps the \ref Timer or the \ref TimeReport
+  /// class is what you want to use instead.
+  ///
+  ///\author Alpar Juttner
+
+  class TimeStamp
+  {
+    struct rtms 
+    {
+      double tms_utime;
+      double tms_stime;
+      double tms_cutime;
+      double tms_cstime;
+      rtms() {}
+      rtms(tms ts) : tms_utime(ts.tms_utime), tms_stime(ts.tms_stime),
+		     tms_cutime(ts.tms_cutime), tms_cstime(ts.tms_cstime) {}
+    };
+    rtms ts;
+    double real_time;
+  
+    rtms &getTms() {return ts;}
+    const rtms &getTms() const {return ts;}
+
+    void _reset() { 
+      ts.tms_utime = ts.tms_stime = ts.tms_cutime = ts.tms_cstime = 0; 
+      real_time = 0;
+    }
+
+  public:
+
+    ///Read the current time values of the process
+    void stamp()
+    {
+      timeval tv;
+      tms _ts;
+      times(&_ts);
+      gettimeofday(&tv, 0);real_time=tv.tv_sec+double(tv.tv_usec)/1e6;
+      ts=_ts;
+    }
+  
+    /// Constructor initializing with zero
+    TimeStamp()
+    { _reset(); }
+    ///Constructor initializing with the current time values of the process
+    TimeStamp(void *) { stamp();}
+  
+    ///Set every time value to zero
+    TimeStamp &reset() {_reset();return *this;}
+
+    ///\e
+    TimeStamp &operator+=(const TimeStamp &b)
+    {
+      ts.tms_utime+=b.ts.tms_utime;
+      ts.tms_stime+=b.ts.tms_stime;
+      ts.tms_cutime+=b.ts.tms_cutime;
+      ts.tms_cstime+=b.ts.tms_cstime;
+      real_time+=b.real_time;
+      return *this;
+    }
+    ///\e
+    TimeStamp operator+(const TimeStamp &b) const
+    {
+      TimeStamp t(*this);
+      return t+=b;
+    }
+    ///\e
+    TimeStamp &operator-=(const TimeStamp &b)
+    {
+      ts.tms_utime-=b.ts.tms_utime;
+      ts.tms_stime-=b.ts.tms_stime;
+      ts.tms_cutime-=b.ts.tms_cutime;
+      ts.tms_cstime-=b.ts.tms_cstime;
+      real_time-=b.real_time;
+      return *this;
+    }
+    ///\e
+    TimeStamp operator-(const TimeStamp &b) const
+    {
+      TimeStamp t(*this);
+      return t-=b;
+    }
+    ///\e
+    TimeStamp &operator*=(double b)
+    {
+      ts.tms_utime*=b;
+      ts.tms_stime*=b;
+      ts.tms_cutime*=b;
+      ts.tms_cstime*=b;
+      real_time*=b;
+      return *this;
+    }
+    ///\e
+    TimeStamp operator*(double b) const
+    {
+      TimeStamp t(*this);
+      return t*=b;
+    }
+    friend TimeStamp operator*(double b,const TimeStamp &t);
+    ///\e
+    TimeStamp &operator/=(double b)
+    {
+      ts.tms_utime/=b;
+      ts.tms_stime/=b;
+      ts.tms_cutime/=b;
+      ts.tms_cstime/=b;
+      real_time/=b;
+      return *this;
+    }
+    ///\e
+    TimeStamp operator/(double b) const
+    {
+      TimeStamp t(*this);
+      return t/=b;
+    }
+    ///The time ellapsed since the last call of stamp()
+    TimeStamp ellapsed() const
+    {
+      TimeStamp t(NULL);
+      return t-*this;
+    }
+  
+    friend std::ostream& operator<<(std::ostream& os,const TimeStamp &t);
+  
+    ///Gives back the user time of the process
+    double userTime() const
+    {
+      return double(ts.tms_utime)/sysconf(_SC_CLK_TCK);
+    }
+    ///Gives back the system time of the process
+    double systemTime() const
+    {
+      return double(ts.tms_stime)/sysconf(_SC_CLK_TCK);
+    }
+    ///Gives back the user time of the process' children
+    double cUserTime() const
+    {
+      return double(ts.tms_cutime)/sysconf(_SC_CLK_TCK);
+    }
+    ///Gives back the user time of the process' children
+    double cSystemTime() const
+    {
+      return double(ts.tms_cstime)/sysconf(_SC_CLK_TCK);
+    }
+    ///Gives back the real time
+    double realTime() const {return real_time;}
+  };
+
+  TimeStamp operator*(double b,const TimeStamp &t) 
+  {
+    return t*b;
+  }
+  
+  ///Prints the time counters
+
+  ///Prints the time counters in the following form:
+  ///
+  /// <tt>u: XX.XXs s: XX.XXs cu: XX.XXs cs: XX.XXs real: XX.XXs</tt>
+  ///
+  /// where the values are the
+  /// \li \c u: user cpu time,
+  /// \li \c s: system cpu time,
+  /// \li \c cu: user cpu time of children,
+  /// \li \c cs: system cpu time of children,
+  /// \li \c real: real time.
+  /// \relates TimeStamp
+  inline std::ostream& operator<<(std::ostream& os,const TimeStamp &t)
+  {
+    long cls = sysconf(_SC_CLK_TCK);
+    os << "u: " << double(t.getTms().tms_utime)/cls <<
+      "s, s: " << double(t.getTms().tms_stime)/cls <<
+      "s, cu: " << double(t.getTms().tms_cutime)/cls <<
+      "s, cs: " << double(t.getTms().tms_cstime)/cls <<
+      "s, real: " << t.realTime() << "s";
+    return os;
+  }
+
+  ///Class for measuring the cpu time and real time usage of the process
+
+  ///Class for measuring the cpu time and real time usage of the process.
+  ///It is quite easy-to-use, here is a short example.
+  ///\code
+  /// #include<lemon/time_measure.h>
+  /// #include<iostream>
+  ///
+  /// int main()
+  /// {
+  ///
+  ///   ...
+  ///
+  ///   Timer t;
+  ///   doSomething();
+  ///   std::cout << t << '\n';
+  ///   t.restart();
+  ///   doSomethingElse();
+  ///   std::cout << t << '\n';
+  ///
+  ///   ...
+  ///
+  /// }
+  ///\endcode
+  ///
+  ///The \ref Timer can also be \ref stop() "stopped" and
+  ///\ref start() "started" again, so it is possible to compute collected
+  ///running times.
+  ///
+  ///\warning Depending on the operation system and its actual configuration
+  ///the time counters have a certain (10ms on a typical Linux system)
+  ///granularity.
+  ///Therefore this tool is not appropriate to measure very short times.
+  ///Also, if you start and stop the timer very frequently, it could lead to
+  ///distorted results.
+  ///
+  ///\note If you want to measure the running time of the execution of a certain
+  ///function, consider the usage of \ref TimeReport instead.
+  ///
+  ///\todo This shouldn't be Unix (Linux) specific.
+  ///\sa TimeReport
+  ///
+  ///\author Alpar Juttner
+  class Timer
+  {
+    int _running; //Timer is running iff _running>0; (_running>=0 always holds)
+    TimeStamp start_time; //This is the relativ start-time if the timer
+                          //is _running, the collected _running time otherwise.
+    
+    void _reset() {if(_running) start_time.stamp(); else start_time.reset();}
+  
+  public: 
+    ///Constructor.
+
+    ///\param run indicates whether or not the timer starts immediately.
+    ///
+    Timer(bool run=true) :_running(run) {_reset();}
+
+    ///\name Control the state of the timer
+    ///Basically a Timer can be either running or stopped,
+    ///but it provides a bit finer control on the execution.
+    ///The \ref Timer also counts the number of \ref start()
+    ///executions, and is stops only after the same amount (or more)
+    ///\ref stop() "stop()"s. This can be useful e.g. to compute the running time
+    ///of recursive functions.
+    ///
+
+    ///@{
+
+    ///Reset and stop the time counters
+
+    ///This function resets and stops the time counters
+    ///\sa restart()
+    void reset()
+    {
+      _running=0;
+      _reset();
+    }
+
+    ///Start the time counters
+    
+    ///This function starts the time counters.
+    ///
+    ///If the timer is started more than ones, it will remain running
+    ///until the same amount of \ref stop() is called.
+    ///\sa stop()
+    void start() 
+    {
+      if(_running) _running++;
+      else {
+	_running=1;
+	TimeStamp t;
+	t.stamp();
+	start_time=t-start_time;
+      }
+    }
+
+    
+    ///Stop the time counters
+
+    ///This function stops the time counters. If start() was executed more than
+    ///once, then the same number of stop() execution is necessary the really
+    ///stop the timer.
+    /// 
+    ///\sa halt()
+    ///\sa start()
+    ///\sa restart()
+    ///\sa reset()
+
+    void stop() 
+    {
+      if(_running && !--_running) {
+	TimeStamp t;
+	t.stamp();
+	start_time=t-start_time;
+      }
+    }
+
+    ///Halt (i.e stop immediately) the time counters
+
+    ///This function stops immediately the time counters, i.e. <tt>t.stop()</tt>
+    ///is a faster
+    ///equivalent of the following.
+    ///\code
+    ///  while(t.running()) t.stop()
+    ///\endcode
+    ///
+    ///
+    ///\sa stop()
+    ///\sa restart()
+    ///\sa reset()
+
+    void halt() 
+    {
+      if(_running) {
+	_running=0;
+	TimeStamp t;
+	t.stamp();
+	start_time=t-start_time;
+      }
+    }
+
+    ///Returns the running state of the timer
+
+    ///This function returns the number of stop() exections that is
+    ///necessary to really stop the timer.
+    ///For example the timer
+    ///is running if and only if the return value is \c true
+    ///(i.e. greater than
+    ///zero).
+    int running()  { return _running; }
+    
+    
+    ///Restart the time counters
+
+    ///This function is a shorthand for
+    ///a reset() and a start() calls.
+    ///
+    void restart() 
+    {
+      reset();
+      start();
+    }
+    
+    ///@}
+
+    ///\name Query Functions for the ellapsed time
+
+    ///@{
+
+    ///Gives back the ellapsed user time of the process
+    double userTime() const
+    {
+      return operator TimeStamp().userTime();
+    }
+    ///Gives back the ellapsed system time of the process
+    double systemTime() const
+    {
+      return operator TimeStamp().systemTime();
+    }
+    ///Gives back the ellapsed user time of the process' children
+    double cUserTime() const
+    {
+      return operator TimeStamp().cUserTime();
+    }
+    ///Gives back the ellapsed user time of the process' children
+    double cSystemTime() const
+    {
+      return operator TimeStamp().cSystemTime();
+    }
+    ///Gives back the ellapsed real time
+    double realTime() const
+    {
+      return operator TimeStamp().realTime();
+    }
+    ///Computes the ellapsed time
+
+    ///This conversion computes the ellapsed time, therefore you can print
+    ///the ellapsed time like this.
+    ///\code
+    ///  Timer t;
+    ///  doSomething();
+    ///  std::cout << t << '\n';
+    ///\endcode
+    operator TimeStamp () const
+    {
+      TimeStamp t;
+      t.stamp();
+      return _running?t-start_time:start_time;
+    }
+
+
+    ///@}
+  };
+
+  ///Same as \ref Timer but prints a report on destruction.
+
+  ///Same as \ref Timer but prints a report on destruction.
+  ///This example shows its usage.
+  ///\code
+  ///  void myAlg(ListGraph &g,int n)
+  ///  {
+  ///    TimeReport tr("Running time of myAlg: ");
+  ///    ... //Here comes the algorithm
+  ///  }
+  ///\endcode
+  ///
+  ///\sa Timer
+  ///\sa NoTimeReport
+  ///\todo There is no test case for this
+  class TimeReport : public Timer 
+  {
+    std::string _title;
+    std::ostream &_os;
+  public:
+    ///\e
+
+    ///\param title This text will be printed before the ellapsed time.
+    ///\param os The stream to print the report to.
+    ///\param run Sets whether the timer should start immediately.
+
+    TimeReport(std::string title,std::ostream &os=std::cerr,bool run=true) 
+      : Timer(run), _title(title), _os(os){}
+    ///\e Prints the ellapsed time on destruction.
+    ~TimeReport() 
+    {
+      _os << _title << *this << std::endl;
+    }
+  };
+      
+  ///'Do nothing' version of \ref TimeReport
+
+  ///\sa TimeReport
+  ///
+  class NoTimeReport
+  {
+  public:
+    ///\e
+    NoTimeReport(std::string,std::ostream &,bool) {}
+    ///\e
+    NoTimeReport(std::string,std::ostream &) {}
+    ///\e
+    NoTimeReport(std::string) {}
+    ///\e Do nothing.
+    ~NoTimeReport() {}
+
+    operator TimeStamp () const { return TimeStamp(); }
+    void reset() {}
+    void start() {}
+    void stop() {}
+    void halt() {} 
+    int running() { return 0; }
+    void restart() {}
+    double userTime() const { return 0; }
+    double systemTime() const { return 0; }
+    double cUserTime() const { return 0; }
+    double cSystemTime() const { return 0; }
+    double realTime() const { return 0; }
+  };
+      
+  ///Tool to measure the running time more exactly.
+  
+  ///This function calls \c f several times and returns the average
+  ///running time. The number of the executions will be choosen in such a way
+  ///that the full real running time will be roughly between \c min_time
+  ///and <tt>2*min_time</tt>.
+  ///\param f the function object to be measured.
+  ///\param min_time the minimum total running time.
+  ///\retval num if it is not \c NULL, then the actual
+  ///        number of execution of \c f will be written into <tt>*num</tt>.
+  ///\retval full_time if it is not \c NULL, then the actual
+  ///        total running time will be written into <tt>*full_time</tt>.
+  ///\return The average running time of \c f.
+  
+  template<class F>
+  TimeStamp runningTimeTest(F f,double min_time=10,unsigned int *num = NULL,
+                            TimeStamp *full_time=NULL)
+  {
+    TimeStamp full;
+    unsigned int total=0;
+    Timer t;
+    for(unsigned int tn=1;tn <= 1U<<31 && full.realTime()<=min_time; tn*=2) {
+      for(;total<tn;total++) f();
+      full=t;
+    }
+    if(num) *num=total;
+    if(full_time) *full_time=full;
+    return full/total;
+  }
+  
+  /// @}  
+
+
+} //namespace lemon
+
+#endif //LEMON_TIME_MEASURE_H
Index: lemon/tolerance.h
===================================================================
--- lemon/tolerance.h	(revision 2655)
+++ lemon/tolerance.h	(revision 2553)
@@ -3,5 +3,5 @@
  * This file is a part of LEMON, a generic C++ optimization library
  *
- * Copyright (C) 2003-2006
+ * Copyright (C) 2003-2008
  * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
  * (Egervary Research Group on Combinatorial Optimization, EGRES).
@@ -306,6 +306,73 @@
     static Value zero() {return 0;}
   };
-
-#ifndef __STRICT_ANSI__
+  
+
+  ///Long integer specialization of \ref Tolerance.
+
+  ///Long integer specialization of \ref Tolerance.
+  ///\sa Tolerance
+  template<>
+  class Tolerance<long int>
+  {
+  public:
+    ///\e
+    typedef long int Value;
+
+    ///\name Comparisons
+    ///See \ref Tolerance for more details.
+
+    ///@{
+
+    ///Returns \c true if \c a is \e surely strictly less than \c b
+    static bool less(Value a,Value b) { return a<b;}
+    ///Returns \c true if \c a is \e surely different from \c b
+    static bool different(Value a,Value b) { return a!=b; }
+    ///Returns \c true if \c a is \e surely positive
+    static bool positive(Value a) { return 0<a; }
+    ///Returns \c true if \c a is \e surely negative
+    static bool negative(Value a) { return 0>a; }
+    ///Returns \c true if \c a is \e surely non-zero
+    static bool nonZero(Value a) { return a!=0;};
+
+    ///@}
+
+    ///Returns zero
+    static Value zero() {return 0;}
+  };
+
+  ///Unsigned long integer specialization of \ref Tolerance.
+
+  ///Unsigned long integer specialization of \ref Tolerance.
+  ///\sa Tolerance
+  template<>
+  class Tolerance<unsigned long int>
+  {
+  public:
+    ///\e
+    typedef unsigned long int Value;
+
+    ///\name Comparisons
+    ///See \ref Tolerance for more details.
+
+    ///@{
+
+    ///Returns \c true if \c a is \e surely strictly less than \c b
+    static bool less(Value a,Value b) { return a<b;}
+    ///Returns \c true if \c a is \e surely different from \c b
+    static bool different(Value a,Value b) { return a!=b; }
+    ///Returns \c true if \c a is \e surely positive
+    static bool positive(Value a) { return 0<a; }
+    ///Returns \c true if \c a is \e surely negative
+    static bool negative(Value) { return false; }
+    ///Returns \c true if \c a is \e surely non-zero
+    static bool nonZero(Value a) { return a!=0;};
+
+    ///@}
+
+    ///Returns zero
+    static Value zero() {return 0;}
+  };
+
+#if defined __GNUC__ && !defined __STRICT_ANSI__
 
   ///Long long integer specialization of \ref Tolerance.
Index: lemon/topology.h
===================================================================
--- lemon/topology.h	(revision 2553)
+++ lemon/topology.h	(revision 2553)
@@ -0,0 +1,1590 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_TOPOLOGY_H
+#define LEMON_TOPOLOGY_H
+
+#include <lemon/dfs.h>
+#include <lemon/bfs.h>
+#include <lemon/graph_utils.h>
+#include <lemon/graph_adaptor.h>
+#include <lemon/maps.h>
+
+#include <lemon/concepts/graph.h>
+#include <lemon/concepts/ugraph.h>
+#include <lemon/concept_check.h>
+
+#include <lemon/bin_heap.h>
+#include <lemon/bucket_heap.h>
+
+#include <stack>
+#include <functional>
+
+/// \ingroup graph_prop
+/// \file
+/// \brief Topology related algorithms
+///
+/// Topology related algorithms
+
+namespace lemon {
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Check that the given undirected graph is connected.
+  ///
+  /// Check that the given undirected graph connected.
+  /// \param graph The undirected graph.
+  /// \return %True when there is path between any two nodes in the graph.
+  /// \note By definition, the empty graph is connected.
+  template <typename UGraph>
+  bool connected(const UGraph& graph) {
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::NodeIt NodeIt;
+    if (NodeIt(graph) == INVALID) return true;
+    Dfs<UGraph> dfs(graph);
+    dfs.run(NodeIt(graph));
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	return false;
+      }
+    }
+    return true;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Count the number of connected components of an undirected graph
+  ///
+  /// Count the number of connected components of an undirected graph
+  ///
+  /// \param graph The graph. It should be undirected.
+  /// \return The number of components
+  /// \note By definition, the empty graph consists
+  /// of zero connected components.
+  template <typename UGraph>
+  int countConnectedComponents(const UGraph &graph) {
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::Node Node;
+    typedef typename UGraph::Edge Edge;
+
+    typedef NullMap<Node, Edge> PredMap;
+    typedef NullMap<Node, int> DistMap;
+
+    int compNum = 0;
+    typename Bfs<UGraph>::
+      template DefPredMap<PredMap>::
+      template DefDistMap<DistMap>::
+      Create bfs(graph);
+
+    PredMap predMap;
+    bfs.predMap(predMap);
+
+    DistMap distMap;
+    bfs.distMap(distMap);
+
+    bfs.init();
+    for(typename UGraph::NodeIt n(graph); n != INVALID; ++n) {
+      if (!bfs.reached(n)) {
+	bfs.addSource(n);
+	bfs.start();
+	++compNum;
+      }
+    }
+    return compNum;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Find the connected components of an undirected graph
+  ///
+  /// Find the connected components of an undirected graph.
+  ///
+  /// \image html connected_components.png
+  /// \image latex connected_components.eps "Connected components" width=\textwidth
+  ///
+  /// \param graph The graph. It should be undirected.
+  /// \retval compMap A writable node map. The values will be set from 0 to
+  /// the number of the connected components minus one. Each values of the map
+  /// will be set exactly once, the values of a certain component will be
+  /// set continuously.
+  /// \return The number of components
+  ///
+  template <class UGraph, class NodeMap>
+  int connectedComponents(const UGraph &graph, NodeMap &compMap) {
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::Node Node;
+    typedef typename UGraph::Edge Edge;
+    checkConcept<concepts::WriteMap<Node, int>, NodeMap>();
+
+    typedef NullMap<Node, Edge> PredMap;
+    typedef NullMap<Node, int> DistMap;
+
+    int compNum = 0;
+    typename Bfs<UGraph>::
+      template DefPredMap<PredMap>::
+      template DefDistMap<DistMap>::
+      Create bfs(graph);
+
+    PredMap predMap;
+    bfs.predMap(predMap);
+
+    DistMap distMap;
+    bfs.distMap(distMap);
+    
+    bfs.init();
+    for(typename UGraph::NodeIt n(graph); n != INVALID; ++n) {
+      if(!bfs.reached(n)) {
+	bfs.addSource(n);
+	while (!bfs.emptyQueue()) {
+	  compMap.set(bfs.nextNode(), compNum);
+	  bfs.processNextNode();
+	}
+	++compNum;
+      }
+    }
+    return compNum;
+  }
+
+  namespace _topology_bits {
+
+    template <typename Graph, typename Iterator >
+    struct LeaveOrderVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      LeaveOrderVisitor(Iterator it) : _it(it) {}
+
+      void leave(const Node& node) {
+	*(_it++) = node;
+      }
+
+    private:
+      Iterator _it;
+    };
+
+    template <typename Graph, typename Map>
+    struct FillMapVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      typedef typename Map::Value Value;
+
+      FillMapVisitor(Map& map, Value& value) 
+	: _map(map), _value(value) {}
+
+      void reach(const Node& node) {
+	_map.set(node, _value);
+      }
+    private:
+      Map& _map;
+      Value& _value;
+    };
+
+    template <typename Graph, typename EdgeMap>
+    struct StronglyConnectedCutEdgesVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge Edge;
+
+      StronglyConnectedCutEdgesVisitor(const Graph& graph, EdgeMap& cutMap, 
+				       int& cutNum) 
+	: _graph(graph), _cutMap(cutMap), _cutNum(cutNum), 
+	  _compMap(graph), _num(0) {
+      }
+
+      void stop(const Node&) {
+	++_num;
+      }
+
+      void reach(const Node& node) {
+	_compMap.set(node, _num);
+      }
+
+      void examine(const Edge& edge) {
+ 	if (_compMap[_graph.source(edge)] != _compMap[_graph.target(edge)]) {
+ 	  _cutMap.set(edge, true);
+ 	  ++_cutNum;
+ 	}
+      }
+    private:
+      const Graph& _graph;
+      EdgeMap& _cutMap;
+      int& _cutNum;
+
+      typename Graph::template NodeMap<int> _compMap;
+      int _num;
+    };
+
+  }
+
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Check that the given directed graph is strongly connected.
+  ///
+  /// Check that the given directed graph is strongly connected. The
+  /// graph is strongly connected when any two nodes of the graph are
+  /// connected with directed paths in both direction.
+  /// \return %False when the graph is not strongly connected.
+  /// \see connected
+  ///
+  /// \note By definition, the empty graph is strongly connected.
+  template <typename Graph>
+  bool stronglyConnected(const Graph& graph) {
+    checkConcept<concepts::Graph, Graph>();
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+
+    if (NodeIt(graph) == INVALID) return true;
+
+    using namespace _topology_bits;
+
+    typedef DfsVisitor<Graph> Visitor;
+    Visitor visitor;
+
+    DfsVisit<Graph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    dfs.addSource(NodeIt(graph));
+    dfs.start();
+
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	return false;
+      }
+    }
+
+    typedef RevGraphAdaptor<const Graph> RGraph;
+    RGraph rgraph(graph);
+
+    typedef DfsVisitor<Graph> RVisitor;
+    RVisitor rvisitor;
+
+    DfsVisit<RGraph, RVisitor> rdfs(rgraph, rvisitor);
+    rdfs.init();    
+    rdfs.addSource(NodeIt(graph));
+    rdfs.start();
+
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!rdfs.reached(it)) {
+	return false;
+      }
+    }
+
+    return true;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Count the strongly connected components of a directed graph
+  ///
+  /// Count the strongly connected components of a directed graph.
+  /// The strongly connected components are the classes of an
+  /// equivalence relation on the nodes of the graph. Two nodes are in
+  /// the same class if they are connected with directed paths in both
+  /// direction. 
+  ///
+  /// \param graph The graph.
+  /// \return The number of components
+  /// \note By definition, the empty graph has zero
+  /// strongly connected components.
+  template <typename Graph>
+  int countStronglyConnectedComponents(const Graph& graph) {
+    checkConcept<concepts::Graph, Graph>();
+
+    using namespace _topology_bits;
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::EdgeIt EdgeIt;
+    
+    typedef std::vector<Node> Container;
+    typedef typename Container::iterator Iterator;
+
+    Container nodes(countNodes(graph));
+    typedef LeaveOrderVisitor<Graph, Iterator> Visitor;
+    Visitor visitor(nodes.begin());
+      
+    DfsVisit<Graph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }
+
+    typedef typename Container::reverse_iterator RIterator;
+    typedef RevGraphAdaptor<const Graph> RGraph;
+
+    RGraph rgraph(graph);
+
+    typedef DfsVisitor<Graph> RVisitor;
+    RVisitor rvisitor;
+
+    DfsVisit<RGraph, RVisitor> rdfs(rgraph, rvisitor);
+
+    int compNum = 0;
+
+    rdfs.init();
+    for (RIterator it = nodes.rbegin(); it != nodes.rend(); ++it) {
+      if (!rdfs.reached(*it)) {
+	rdfs.addSource(*it);
+	rdfs.start();
+	++compNum;
+      }
+    }
+    return compNum;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Find the strongly connected components of a directed graph
+  ///
+  /// Find the strongly connected components of a directed graph.  The
+  /// strongly connected components are the classes of an equivalence
+  /// relation on the nodes of the graph. Two nodes are in
+  /// relationship when there are directed paths between them in both
+  /// direction. In addition, the numbering of components will satisfy
+  /// that there is no edge going from a higher numbered component to
+  /// a lower.
+  ///
+  /// \image html strongly_connected_components.png
+  /// \image latex strongly_connected_components.eps "Strongly connected components" width=\textwidth
+  ///
+  /// \param graph The graph.
+  /// \retval compMap A writable node map. The values will be set from 0 to
+  /// the number of the strongly connected components minus one. Each value 
+  /// of the map will be set exactly once, the values of a certain component 
+  /// will be set continuously.
+  /// \return The number of components
+  ///
+  template <typename Graph, typename NodeMap>
+  int stronglyConnectedComponents(const Graph& graph, NodeMap& compMap) {
+    checkConcept<concepts::Graph, Graph>();
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    checkConcept<concepts::WriteMap<Node, int>, NodeMap>();
+
+    using namespace _topology_bits;
+    
+    typedef std::vector<Node> Container;
+    typedef typename Container::iterator Iterator;
+
+    Container nodes(countNodes(graph));
+    typedef LeaveOrderVisitor<Graph, Iterator> Visitor;
+    Visitor visitor(nodes.begin());
+      
+    DfsVisit<Graph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }
+
+    typedef typename Container::reverse_iterator RIterator;
+    typedef RevGraphAdaptor<const Graph> RGraph;
+
+    RGraph rgraph(graph);
+
+    int compNum = 0;
+
+    typedef FillMapVisitor<RGraph, NodeMap> RVisitor;
+    RVisitor rvisitor(compMap, compNum);
+
+    DfsVisit<RGraph, RVisitor> rdfs(rgraph, rvisitor);
+
+    rdfs.init();
+    for (RIterator it = nodes.rbegin(); it != nodes.rend(); ++it) {
+      if (!rdfs.reached(*it)) {
+	rdfs.addSource(*it);
+	rdfs.start();
+	++compNum;
+      }
+    }
+    return compNum;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Find the cut edges of the strongly connected components.
+  ///
+  /// Find the cut edges of the strongly connected components.
+  /// The strongly connected components are the classes of an equivalence
+  /// relation on the nodes of the graph. Two nodes are in relationship
+  /// when there are directed paths between them in both direction.
+  /// The strongly connected components are separated by the cut edges.
+  ///
+  /// \param graph The graph.
+  /// \retval cutMap A writable node map. The values will be set true when the
+  /// edge is a cut edge.
+  ///
+  /// \return The number of cut edges
+  template <typename Graph, typename EdgeMap>
+  int stronglyConnectedCutEdges(const Graph& graph, EdgeMap& cutMap) {
+    checkConcept<concepts::Graph, Graph>();
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::NodeIt NodeIt;
+    checkConcept<concepts::WriteMap<Edge, bool>, EdgeMap>();
+
+    using namespace _topology_bits;
+    
+    typedef std::vector<Node> Container;
+    typedef typename Container::iterator Iterator;
+
+    Container nodes(countNodes(graph));
+    typedef LeaveOrderVisitor<Graph, Iterator> Visitor;
+    Visitor visitor(nodes.begin());
+      
+    DfsVisit<Graph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }
+
+    typedef typename Container::reverse_iterator RIterator;
+    typedef RevGraphAdaptor<const Graph> RGraph;
+
+    RGraph rgraph(graph);
+
+    int cutNum = 0;
+
+    typedef StronglyConnectedCutEdgesVisitor<RGraph, EdgeMap> RVisitor;
+    RVisitor rvisitor(rgraph, cutMap, cutNum);
+
+    DfsVisit<RGraph, RVisitor> rdfs(rgraph, rvisitor);
+
+    rdfs.init();
+    for (RIterator it = nodes.rbegin(); it != nodes.rend(); ++it) {
+      if (!rdfs.reached(*it)) {
+	rdfs.addSource(*it);
+	rdfs.start();
+      }
+    }
+    return cutNum;
+  }
+
+  namespace _topology_bits {
+    
+    template <typename Graph>
+    class CountBiNodeConnectedComponentsVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge Edge;
+      typedef typename Graph::UEdge UEdge;
+
+      CountBiNodeConnectedComponentsVisitor(const Graph& graph, int &compNum) 
+	: _graph(graph), _compNum(compNum), 
+	  _numMap(graph), _retMap(graph), _predMap(graph), _num(0) {}
+
+      void start(const Node& node) {
+	_predMap.set(node, INVALID);
+      }
+      
+      void reach(const Node& node) {
+	_numMap.set(node, _num);
+	_retMap.set(node, _num);
+	++_num;
+      }
+
+      void discover(const Edge& edge) {
+	_predMap.set(_graph.target(edge), _graph.source(edge));
+      }
+
+      void examine(const Edge& edge) {
+	if (_graph.source(edge) == _graph.target(edge) && 
+	    _graph.direction(edge)) {
+	  ++_compNum;
+	  return;
+	}
+	if (_predMap[_graph.source(edge)] == _graph.target(edge)) {
+	  return;
+	}
+	if (_retMap[_graph.source(edge)] > _numMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _numMap[_graph.target(edge)]);
+	}
+      }
+
+      void backtrack(const Edge& edge) {
+	if (_retMap[_graph.source(edge)] > _retMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _retMap[_graph.target(edge)]);
+	}  
+	if (_numMap[_graph.source(edge)] <= _retMap[_graph.target(edge)]) {
+	  ++_compNum;
+	}
+      }
+      
+    private:
+      const Graph& _graph;
+      int& _compNum; 
+
+      typename Graph::template NodeMap<int> _numMap;
+      typename Graph::template NodeMap<int> _retMap;
+      typename Graph::template NodeMap<Node> _predMap;
+      int _num;
+    };
+
+    template <typename Graph, typename EdgeMap>
+    class BiNodeConnectedComponentsVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge Edge;
+      typedef typename Graph::UEdge UEdge;
+
+      BiNodeConnectedComponentsVisitor(const Graph& graph, 
+				       EdgeMap& compMap, int &compNum) 
+	: _graph(graph), _compMap(compMap), _compNum(compNum), 
+	  _numMap(graph), _retMap(graph), _predMap(graph), _num(0) {}
+
+      void start(const Node& node) {
+	_predMap.set(node, INVALID);
+      }
+      
+      void reach(const Node& node) {
+	_numMap.set(node, _num);
+	_retMap.set(node, _num);
+	++_num;
+      }
+
+      void discover(const Edge& edge) {
+	Node target = _graph.target(edge);
+	_predMap.set(target, edge);
+	_edgeStack.push(edge);
+      }
+
+      void examine(const Edge& edge) {
+	Node source = _graph.source(edge);
+	Node target = _graph.target(edge);
+	if (source == target && _graph.direction(edge)) {
+	  _compMap.set(edge, _compNum);
+	  ++_compNum;
+	  return;
+	}
+	if (_numMap[target] < _numMap[source]) {
+	  if (_predMap[source] != _graph.oppositeEdge(edge)) {
+	    _edgeStack.push(edge);
+	  }
+	}
+	if (_predMap[source] != INVALID && 
+	    target == _graph.source(_predMap[source])) {
+	  return;
+	}
+	if (_retMap[source] > _numMap[target]) {
+	  _retMap.set(source, _numMap[target]);
+	}
+      }
+
+      void backtrack(const Edge& edge) {
+	Node source = _graph.source(edge);
+	Node target = _graph.target(edge);
+	if (_retMap[source] > _retMap[target]) {
+	  _retMap.set(source, _retMap[target]);
+	}  
+	if (_numMap[source] <= _retMap[target]) {
+	  while (_edgeStack.top() != edge) {
+	    _compMap.set(_edgeStack.top(), _compNum);
+	    _edgeStack.pop();
+	  }
+	  _compMap.set(edge, _compNum);
+	  _edgeStack.pop();
+	  ++_compNum;
+	}
+      }
+      
+    private:
+      const Graph& _graph;
+      EdgeMap& _compMap;
+      int& _compNum; 
+
+      typename Graph::template NodeMap<int> _numMap;
+      typename Graph::template NodeMap<int> _retMap;
+      typename Graph::template NodeMap<Edge> _predMap;
+      std::stack<UEdge> _edgeStack;
+      int _num;
+    };
+
+
+    template <typename Graph, typename NodeMap>
+    class BiNodeConnectedCutNodesVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge Edge;
+      typedef typename Graph::UEdge UEdge;
+
+      BiNodeConnectedCutNodesVisitor(const Graph& graph, NodeMap& cutMap,
+				     int& cutNum) 
+	: _graph(graph), _cutMap(cutMap), _cutNum(cutNum),
+	  _numMap(graph), _retMap(graph), _predMap(graph), _num(0) {}
+
+      void start(const Node& node) {
+	_predMap.set(node, INVALID);
+	rootCut = false;
+      }
+      
+      void reach(const Node& node) {
+	_numMap.set(node, _num);
+	_retMap.set(node, _num);
+	++_num;
+      }
+
+      void discover(const Edge& edge) {
+	_predMap.set(_graph.target(edge), _graph.source(edge));
+      }
+
+      void examine(const Edge& edge) {
+	if (_graph.source(edge) == _graph.target(edge) && 
+	    _graph.direction(edge)) {
+	  if (!_cutMap[_graph.source(edge)]) {
+	    _cutMap.set(_graph.source(edge), true);
+	    ++_cutNum;
+	  }
+	  return;
+	}
+	if (_predMap[_graph.source(edge)] == _graph.target(edge)) return;
+	if (_retMap[_graph.source(edge)] > _numMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _numMap[_graph.target(edge)]);
+	}
+      }
+
+      void backtrack(const Edge& edge) {
+	if (_retMap[_graph.source(edge)] > _retMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _retMap[_graph.target(edge)]);
+	}  
+	if (_numMap[_graph.source(edge)] <= _retMap[_graph.target(edge)]) {
+	  if (_predMap[_graph.source(edge)] != INVALID) {
+	    if (!_cutMap[_graph.source(edge)]) {
+	      _cutMap.set(_graph.source(edge), true);
+	      ++_cutNum;
+	    }
+	  } else if (rootCut) {
+	    if (!_cutMap[_graph.source(edge)]) {
+	      _cutMap.set(_graph.source(edge), true);
+	      ++_cutNum;
+	    }
+	  } else {
+	    rootCut = true;
+	  }
+	}
+      }
+      
+    private:
+      const Graph& _graph;
+      NodeMap& _cutMap;
+      int& _cutNum; 
+
+      typename Graph::template NodeMap<int> _numMap;
+      typename Graph::template NodeMap<int> _retMap;
+      typename Graph::template NodeMap<Node> _predMap;
+      std::stack<UEdge> _edgeStack;
+      int _num;
+      bool rootCut;
+    };
+
+  }
+
+  template <typename UGraph>
+  int countBiNodeConnectedComponents(const UGraph& graph);
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Checks the graph is bi-node-connected.
+  ///
+  /// This function checks that the undirected graph is bi-node-connected  
+  /// graph. The graph is bi-node-connected if any two undirected edge is 
+  /// on same circle.
+  ///
+  /// \param graph The graph.
+  /// \return %True when the graph bi-node-connected.
+  template <typename UGraph>
+  bool biNodeConnected(const UGraph& graph) {
+    return countBiNodeConnectedComponents(graph) == 1;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Count the biconnected components.
+  ///
+  /// This function finds the bi-node-connected components in an undirected 
+  /// graph. The biconnected components are the classes of an equivalence 
+  /// relation on the undirected edges. Two undirected edge is in relationship
+  /// when they are on same circle.
+  ///
+  /// \param graph The graph.
+  /// \return The number of components.
+  template <typename UGraph>
+  int countBiNodeConnectedComponents(const UGraph& graph) {
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::NodeIt NodeIt;
+
+    using namespace _topology_bits;
+
+    typedef CountBiNodeConnectedComponentsVisitor<UGraph> Visitor;
+
+    int compNum = 0;
+    Visitor visitor(graph, compNum);
+
+    DfsVisit<UGraph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }
+    return compNum;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Find the bi-node-connected components.
+  ///
+  /// This function finds the bi-node-connected components in an undirected 
+  /// graph. The bi-node-connected components are the classes of an equivalence
+  /// relation on the undirected edges. Two undirected edge are in relationship
+  /// when they are on same circle.
+  ///
+  /// \image html node_biconnected_components.png
+  /// \image latex node_biconnected_components.eps "bi-node-connected components" width=\textwidth
+  ///
+  /// \param graph The graph.
+  /// \retval compMap A writable uedge map. The values will be set from 0
+  /// to the number of the biconnected components minus one. Each values 
+  /// of the map will be set exactly once, the values of a certain component 
+  /// will be set continuously.
+  /// \return The number of components.
+  ///
+  template <typename UGraph, typename UEdgeMap>
+  int biNodeConnectedComponents(const UGraph& graph, 
+				UEdgeMap& compMap) {
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::NodeIt NodeIt;
+    typedef typename UGraph::UEdge UEdge;
+    checkConcept<concepts::WriteMap<UEdge, int>, UEdgeMap>();
+
+    using namespace _topology_bits;
+
+    typedef BiNodeConnectedComponentsVisitor<UGraph, UEdgeMap> Visitor;
+    
+    int compNum = 0;
+    Visitor visitor(graph, compMap, compNum);
+
+    DfsVisit<UGraph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }
+    return compNum;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Find the bi-node-connected cut nodes.
+  ///
+  /// This function finds the bi-node-connected cut nodes in an undirected 
+  /// graph. The bi-node-connected components are the classes of an equivalence
+  /// relation on the undirected edges. Two undirected edges are in 
+  /// relationship when they are on same circle. The biconnected components 
+  /// are separted by nodes which are the cut nodes of the components.
+  ///
+  /// \param graph The graph.
+  /// \retval cutMap A writable edge map. The values will be set true when
+  /// the node separate two or more components.
+  /// \return The number of the cut nodes.
+  template <typename UGraph, typename NodeMap>
+  int biNodeConnectedCutNodes(const UGraph& graph, NodeMap& cutMap) {
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::Node Node;
+    typedef typename UGraph::NodeIt NodeIt;
+    checkConcept<concepts::WriteMap<Node, bool>, NodeMap>();
+
+    using namespace _topology_bits;
+
+    typedef BiNodeConnectedCutNodesVisitor<UGraph, NodeMap> Visitor;
+    
+    int cutNum = 0;
+    Visitor visitor(graph, cutMap, cutNum);
+
+    DfsVisit<UGraph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }
+    return cutNum;
+  }
+
+  namespace _topology_bits {
+    
+    template <typename Graph>
+    class CountBiEdgeConnectedComponentsVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge Edge;
+      typedef typename Graph::UEdge UEdge;
+
+      CountBiEdgeConnectedComponentsVisitor(const Graph& graph, int &compNum) 
+	: _graph(graph), _compNum(compNum), 
+	  _numMap(graph), _retMap(graph), _predMap(graph), _num(0) {}
+
+      void start(const Node& node) {
+	_predMap.set(node, INVALID);
+      }
+      
+      void reach(const Node& node) {
+	_numMap.set(node, _num);
+	_retMap.set(node, _num);
+	++_num;
+      }
+      
+      void leave(const Node& node) {
+	if (_numMap[node] <= _retMap[node]) {
+	  ++_compNum;
+	}	
+      }
+
+      void discover(const Edge& edge) {
+	_predMap.set(_graph.target(edge), edge);
+      }
+
+      void examine(const Edge& edge) {
+	if (_predMap[_graph.source(edge)] == _graph.oppositeEdge(edge)) {
+	  return;
+	}
+	if (_retMap[_graph.source(edge)] > _retMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _retMap[_graph.target(edge)]);
+	}
+      }
+
+      void backtrack(const Edge& edge) {
+	if (_retMap[_graph.source(edge)] > _retMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _retMap[_graph.target(edge)]);
+	}  
+      }
+      
+    private:
+      const Graph& _graph;
+      int& _compNum; 
+
+      typename Graph::template NodeMap<int> _numMap;
+      typename Graph::template NodeMap<int> _retMap;
+      typename Graph::template NodeMap<Edge> _predMap;
+      int _num;
+    };
+
+    template <typename Graph, typename NodeMap>
+    class BiEdgeConnectedComponentsVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge Edge;
+      typedef typename Graph::UEdge UEdge;
+
+      BiEdgeConnectedComponentsVisitor(const Graph& graph, 
+				       NodeMap& compMap, int &compNum) 
+	: _graph(graph), _compMap(compMap), _compNum(compNum), 
+	  _numMap(graph), _retMap(graph), _predMap(graph), _num(0) {}
+
+      void start(const Node& node) {
+	_predMap.set(node, INVALID);
+      }
+      
+      void reach(const Node& node) {
+	_numMap.set(node, _num);
+	_retMap.set(node, _num);
+	_nodeStack.push(node);
+	++_num;
+      }
+      
+      void leave(const Node& node) {
+	if (_numMap[node] <= _retMap[node]) {
+	  while (_nodeStack.top() != node) {
+	    _compMap.set(_nodeStack.top(), _compNum);
+	    _nodeStack.pop();
+	  }
+	  _compMap.set(node, _compNum);
+	  _nodeStack.pop();
+	  ++_compNum;
+	}	
+      }
+
+      void discover(const Edge& edge) {
+	_predMap.set(_graph.target(edge), edge);
+      }
+
+      void examine(const Edge& edge) {
+	if (_predMap[_graph.source(edge)] == _graph.oppositeEdge(edge)) {
+	  return;
+	}
+	if (_retMap[_graph.source(edge)] > _retMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _retMap[_graph.target(edge)]);
+	}
+      }
+
+      void backtrack(const Edge& edge) {
+	if (_retMap[_graph.source(edge)] > _retMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _retMap[_graph.target(edge)]);
+	}  
+      }
+      
+    private:
+      const Graph& _graph;
+      NodeMap& _compMap;
+      int& _compNum; 
+
+      typename Graph::template NodeMap<int> _numMap;
+      typename Graph::template NodeMap<int> _retMap;
+      typename Graph::template NodeMap<Edge> _predMap;
+      std::stack<Node> _nodeStack;
+      int _num;
+    };
+
+
+    template <typename Graph, typename EdgeMap>
+    class BiEdgeConnectedCutEdgesVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge Edge;
+      typedef typename Graph::UEdge UEdge;
+
+      BiEdgeConnectedCutEdgesVisitor(const Graph& graph, 
+				     EdgeMap& cutMap, int &cutNum) 
+	: _graph(graph), _cutMap(cutMap), _cutNum(cutNum), 
+	  _numMap(graph), _retMap(graph), _predMap(graph), _num(0) {}
+
+      void start(const Node& node) {
+	_predMap[node] = INVALID;
+      }
+      
+      void reach(const Node& node) {
+	_numMap.set(node, _num);
+	_retMap.set(node, _num);
+	++_num;
+      }
+      
+      void leave(const Node& node) {
+	if (_numMap[node] <= _retMap[node]) {
+	  if (_predMap[node] != INVALID) {
+	    _cutMap.set(_predMap[node], true);
+	    ++_cutNum;
+	  }
+	}	
+      }
+
+      void discover(const Edge& edge) {
+	_predMap.set(_graph.target(edge), edge);
+      }
+
+      void examine(const Edge& edge) {
+	if (_predMap[_graph.source(edge)] == _graph.oppositeEdge(edge)) {
+	  return;
+	}
+	if (_retMap[_graph.source(edge)] > _retMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _retMap[_graph.target(edge)]);
+	}
+      }
+
+      void backtrack(const Edge& edge) {
+	if (_retMap[_graph.source(edge)] > _retMap[_graph.target(edge)]) {
+	  _retMap.set(_graph.source(edge), _retMap[_graph.target(edge)]);
+	}  
+      }
+      
+    private:
+      const Graph& _graph;
+      EdgeMap& _cutMap;
+      int& _cutNum; 
+
+      typename Graph::template NodeMap<int> _numMap;
+      typename Graph::template NodeMap<int> _retMap;
+      typename Graph::template NodeMap<Edge> _predMap;
+      int _num;
+    };
+  }
+
+  template <typename UGraph>
+  int countBiEdgeConnectedComponents(const UGraph& graph);
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Checks that the graph is bi-edge-connected.
+  ///
+  /// This function checks that the graph is bi-edge-connected. The undirected
+  /// graph is bi-edge-connected when any two nodes are connected with two
+  /// edge-disjoint paths.
+  ///
+  /// \param graph The undirected graph.
+  /// \return The number of components.
+  template <typename UGraph>
+  bool biEdgeConnected(const UGraph& graph) { 
+    return countBiEdgeConnectedComponents(graph) == 1;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Count the bi-edge-connected components.
+  ///
+  /// This function count the bi-edge-connected components in an undirected 
+  /// graph. The bi-edge-connected components are the classes of an equivalence
+  /// relation on the nodes. Two nodes are in relationship when they are  
+  /// connected with at least two edge-disjoint paths.
+  ///
+  /// \param graph The undirected graph.
+  /// \return The number of components.
+  template <typename UGraph>
+  int countBiEdgeConnectedComponents(const UGraph& graph) { 
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::NodeIt NodeIt;
+
+    using namespace _topology_bits;
+
+    typedef CountBiEdgeConnectedComponentsVisitor<UGraph> Visitor;
+    
+    int compNum = 0;
+    Visitor visitor(graph, compNum);
+
+    DfsVisit<UGraph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }
+    return compNum;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Find the bi-edge-connected components.
+  ///
+  /// This function finds the bi-edge-connected components in an undirected 
+  /// graph. The bi-edge-connected components are the classes of an equivalence
+  /// relation on the nodes. Two nodes are in relationship when they are  
+  /// connected at least two edge-disjoint paths.
+  ///
+  /// \image html edge_biconnected_components.png
+  /// \image latex edge_biconnected_components.eps "bi-edge-connected components" width=\textwidth
+  ///
+  /// \param graph The graph.
+  /// \retval compMap A writable node map. The values will be set from 0 to
+  /// the number of the biconnected components minus one. Each values 
+  /// of the map will be set exactly once, the values of a certain component 
+  /// will be set continuously.
+  /// \return The number of components.
+  ///
+  template <typename UGraph, typename NodeMap>
+  int biEdgeConnectedComponents(const UGraph& graph, NodeMap& compMap) { 
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::NodeIt NodeIt;
+    typedef typename UGraph::Node Node;
+    checkConcept<concepts::WriteMap<Node, int>, NodeMap>();
+
+    using namespace _topology_bits;
+
+    typedef BiEdgeConnectedComponentsVisitor<UGraph, NodeMap> Visitor;
+    
+    int compNum = 0;
+    Visitor visitor(graph, compMap, compNum);
+
+    DfsVisit<UGraph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }
+    return compNum;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Find the bi-edge-connected cut edges.
+  ///
+  /// This function finds the bi-edge-connected components in an undirected 
+  /// graph. The bi-edge-connected components are the classes of an equivalence
+  /// relation on the nodes. Two nodes are in relationship when they are 
+  /// connected with at least two edge-disjoint paths. The bi-edge-connected 
+  /// components are separted by edges which are the cut edges of the 
+  /// components.
+  ///
+  /// \param graph The graph.
+  /// \retval cutMap A writable node map. The values will be set true when the
+  /// edge is a cut edge.
+  /// \return The number of cut edges.
+  template <typename UGraph, typename UEdgeMap>
+  int biEdgeConnectedCutEdges(const UGraph& graph, UEdgeMap& cutMap) { 
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::NodeIt NodeIt;
+    typedef typename UGraph::UEdge UEdge;
+    checkConcept<concepts::WriteMap<UEdge, bool>, UEdgeMap>();
+
+    using namespace _topology_bits;
+
+    typedef BiEdgeConnectedCutEdgesVisitor<UGraph, UEdgeMap> Visitor;
+    
+    int cutNum = 0;
+    Visitor visitor(graph, cutMap, cutNum);
+
+    DfsVisit<UGraph, Visitor> dfs(graph, visitor);
+    dfs.init();
+    
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }
+    return cutNum;
+  }
+
+
+  namespace _topology_bits {
+    
+    template <typename Graph, typename IntNodeMap>
+    class TopologicalSortVisitor : public DfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Node Node;
+      typedef typename Graph::Edge edge;
+
+      TopologicalSortVisitor(IntNodeMap& order, int num) 
+	: _order(order), _num(num) {}
+      
+      void leave(const Node& node) {
+	_order.set(node, --_num);
+      }
+
+    private:
+      IntNodeMap& _order;
+      int _num;
+    };
+    
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Sort the nodes of a DAG into topolgical order.
+  ///
+  /// Sort the nodes of a DAG into topolgical order.
+  ///
+  /// \param graph The graph. It should be directed and acyclic.
+  /// \retval order A writable node map. The values will be set from 0 to
+  /// the number of the nodes in the graph minus one. Each values of the map
+  /// will be set exactly once, the values  will be set descending order.
+  ///
+  /// \see checkedTopologicalSort
+  /// \see dag
+  template <typename Graph, typename NodeMap>
+  void topologicalSort(const Graph& graph, NodeMap& order) {
+    using namespace _topology_bits;
+
+    checkConcept<concepts::Graph, Graph>();
+    checkConcept<concepts::WriteMap<typename Graph::Node, int>, NodeMap>();
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+
+    TopologicalSortVisitor<Graph, NodeMap> 
+      visitor(order, countNodes(graph)); 
+
+    DfsVisit<Graph, TopologicalSortVisitor<Graph, NodeMap> >
+      dfs(graph, visitor);
+
+    dfs.init();
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	dfs.start();
+      }
+    }    
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Sort the nodes of a DAG into topolgical order.
+  ///
+  /// Sort the nodes of a DAG into topolgical order. It also checks
+  /// that the given graph is DAG.
+  ///
+  /// \param graph The graph. It should be directed and acyclic.
+  /// \retval order A readable - writable node map. The values will be set 
+  /// from 0 to the number of the nodes in the graph minus one. Each values 
+  /// of the map will be set exactly once, the values will be set descending 
+  /// order.
+  /// \return %False when the graph is not DAG.
+  ///
+  /// \see topologicalSort
+  /// \see dag
+  template <typename Graph, typename NodeMap>
+  bool checkedTopologicalSort(const Graph& graph, NodeMap& order) {
+    using namespace _topology_bits;
+
+    checkConcept<concepts::Graph, Graph>();
+    checkConcept<concepts::ReadWriteMap<typename Graph::Node, int>, NodeMap>();
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+
+    order = constMap<Node, int, -1>();
+
+    TopologicalSortVisitor<Graph, NodeMap> 
+      visitor(order, countNodes(graph)); 
+
+    DfsVisit<Graph, TopologicalSortVisitor<Graph, NodeMap> >
+      dfs(graph, visitor);
+
+    dfs.init();
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	while (!dfs.emptyQueue()) {
+ 	  Edge edge = dfs.nextEdge();
+ 	  Node target = graph.target(edge);
+ 	  if (dfs.reached(target) && order[target] == -1) {
+ 	    return false;
+ 	  }
+ 	  dfs.processNextEdge();
+ 	}
+      }
+    }
+    return true;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Check that the given directed graph is a DAG.
+  ///
+  /// Check that the given directed graph is a DAG. The DAG is
+  /// an Directed Acyclic Graph.
+  /// \return %False when the graph is not DAG.
+  /// \see acyclic
+  template <typename Graph>
+  bool dag(const Graph& graph) {
+
+    checkConcept<concepts::Graph, Graph>();
+
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+
+    typedef typename Graph::template NodeMap<bool> ProcessedMap;
+
+    typename Dfs<Graph>::template DefProcessedMap<ProcessedMap>::
+      Create dfs(graph);
+
+    ProcessedMap processed(graph);
+    dfs.processedMap(processed);
+
+    dfs.init();
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	while (!dfs.emptyQueue()) {
+	  Edge edge = dfs.nextEdge();
+	  Node target = graph.target(edge);
+	  if (dfs.reached(target) && !processed[target]) {
+	    return false;
+	  }
+	  dfs.processNextEdge();
+	}
+      }
+    }    
+    return true;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Check that the given undirected graph is acyclic.
+  ///
+  /// Check that the given undirected graph acyclic.
+  /// \param graph The undirected graph.
+  /// \return %True when there is no circle in the graph.
+  /// \see dag
+  template <typename UGraph>
+  bool acyclic(const UGraph& graph) {
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::Node Node;
+    typedef typename UGraph::NodeIt NodeIt;
+    typedef typename UGraph::Edge Edge;
+    Dfs<UGraph> dfs(graph);
+    dfs.init();
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	dfs.addSource(it);
+	while (!dfs.emptyQueue()) {
+	  Edge edge = dfs.nextEdge();
+	  Node source = graph.source(edge);
+	  Node target = graph.target(edge);
+	  if (dfs.reached(target) && 
+	      dfs.predEdge(source) != graph.oppositeEdge(edge)) {
+	    return false;
+	  }
+	  dfs.processNextEdge();
+	}
+      }
+    }
+    return true;
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Check that the given undirected graph is tree.
+  ///
+  /// Check that the given undirected graph is tree.
+  /// \param graph The undirected graph.
+  /// \return %True when the graph is acyclic and connected.
+  template <typename UGraph>
+  bool tree(const UGraph& graph) {
+    checkConcept<concepts::UGraph, UGraph>();
+    typedef typename UGraph::Node Node;
+    typedef typename UGraph::NodeIt NodeIt;
+    typedef typename UGraph::Edge Edge;
+    Dfs<UGraph> dfs(graph);
+    dfs.init();
+    dfs.addSource(NodeIt(graph));
+    while (!dfs.emptyQueue()) {
+      Edge edge = dfs.nextEdge();
+      Node source = graph.source(edge);
+      Node target = graph.target(edge);
+      if (dfs.reached(target) && 
+	  dfs.predEdge(source) != graph.oppositeEdge(edge)) {
+	return false;
+      }
+      dfs.processNextEdge();
+    }
+    for (NodeIt it(graph); it != INVALID; ++it) {
+      if (!dfs.reached(it)) {
+	return false;
+      }
+    }    
+    return true;
+  }
+
+  namespace _topology_bits {
+
+    template <typename Graph>
+    class BipartiteVisitor : public BfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Edge Edge;
+      typedef typename Graph::Node Node;
+
+      BipartiteVisitor(const Graph& graph, bool& bipartite) 
+        : _graph(graph), _part(graph), _bipartite(bipartite) {}
+      
+      void start(const Node& node) {
+        _part[node] = true;
+      }
+      void discover(const Edge& edge) {
+        _part.set(_graph.target(edge), !_part[_graph.source(edge)]);
+      }
+      void examine(const Edge& edge) {
+        _bipartite = _bipartite && 
+          _part[_graph.target(edge)] != _part[_graph.source(edge)];
+      }
+
+    private:
+
+      const Graph& _graph;
+      typename Graph::template NodeMap<bool> _part;
+      bool& _bipartite;
+    };
+
+    template <typename Graph, typename PartMap>
+    class BipartitePartitionsVisitor : public BfsVisitor<Graph> {
+    public:
+      typedef typename Graph::Edge Edge;
+      typedef typename Graph::Node Node;
+
+      BipartitePartitionsVisitor(const Graph& graph, 
+                                 PartMap& part, bool& bipartite) 
+        : _graph(graph), _part(part), _bipartite(bipartite) {}
+      
+      void start(const Node& node) {
+        _part.set(node, true);
+      }
+      void discover(const Edge& edge) {
+        _part.set(_graph.target(edge), !_part[_graph.source(edge)]);
+      }
+      void examine(const Edge& edge) {
+        _bipartite = _bipartite && 
+          _part[_graph.target(edge)] != _part[_graph.source(edge)];
+      }
+
+    private:
+
+      const Graph& _graph;
+      PartMap& _part;
+      bool& _bipartite;
+    };
+  }
+
+  /// \ingroup graph_prop
+  ///
+  /// \brief Check if the given undirected graph is bipartite or not
+  ///
+  /// The function checks if the given undirected \c graph graph is bipartite 
+  /// or not. The \ref Bfs algorithm is used to calculate the result.
+  /// \param graph The undirected graph.
+  /// \return %True if \c graph is bipartite, %false otherwise.
+  /// \sa bipartitePartitions
+  ///
+  /// \author Balazs Attila Mihaly  
+  template<typename UGraph>
+  inline bool bipartite(const UGraph &graph){
+    using namespace _topology_bits;
+
+    checkConcept<concepts::UGraph, UGraph>();
+    
+    typedef typename UGraph::NodeIt NodeIt;
+    typedef typename UGraph::EdgeIt EdgeIt;
+    
+    bool bipartite = true;
+
+    BipartiteVisitor<UGraph> 
+      visitor(graph, bipartite);
+    BfsVisit<UGraph, BipartiteVisitor<UGraph> > 
+      bfs(graph, visitor);
+    bfs.init();
+    for(NodeIt it(graph); it != INVALID; ++it) {
+      if(!bfs.reached(it)){
+	bfs.addSource(it);
+        while (!bfs.emptyQueue()) {
+          bfs.processNextNode();
+          if (!bipartite) return false;
+        }
+      }
+    }
+    return true;
+  }
+  
+  /// \ingroup graph_prop
+  ///
+  /// \brief Check if the given undirected graph is bipartite or not
+  ///
+  /// The function checks if the given undirected graph is bipartite 
+  /// or not. The  \ref  Bfs  algorithm  is   used  to  calculate the result. 
+  /// During the execution, the \c partMap will be set as the two 
+  /// partitions of the graph.
+  /// \param graph The undirected graph.
+  /// \retval partMap A writable bool map of nodes. It will be set as the
+  /// two partitions of the graph. 
+  /// \return %True if \c graph is bipartite, %false otherwise.
+  ///
+  /// \author Balazs Attila Mihaly  
+  ///
+  /// \image html bipartite_partitions.png
+  /// \image latex bipartite_partitions.eps "Bipartite partititions" width=\textwidth
+  template<typename UGraph, typename NodeMap>
+  inline bool bipartitePartitions(const UGraph &graph, NodeMap &partMap){
+    using namespace _topology_bits;
+
+    checkConcept<concepts::UGraph, UGraph>();
+    
+    typedef typename UGraph::Node Node;
+    typedef typename UGraph::NodeIt NodeIt;
+    typedef typename UGraph::EdgeIt EdgeIt;
+
+    bool bipartite = true;
+
+    BipartitePartitionsVisitor<UGraph, NodeMap> 
+      visitor(graph, partMap, bipartite);
+    BfsVisit<UGraph, BipartitePartitionsVisitor<UGraph, NodeMap> > 
+      bfs(graph, visitor);
+    bfs.init();
+    for(NodeIt it(graph); it != INVALID; ++it) {
+      if(!bfs.reached(it)){
+	bfs.addSource(it);
+        while (!bfs.emptyQueue()) {
+          bfs.processNextNode();
+          if (!bipartite) return false;
+        }
+      }
+    }
+    return true;
+  }
+
+  /// \brief Returns true when there is not loop edge in the graph.
+  ///
+  /// Returns true when there is not loop edge in the graph.
+  template <typename Graph>
+  bool loopFree(const Graph& graph) {
+    for (typename Graph::EdgeIt it(graph); it != INVALID; ++it) {
+      if (graph.source(it) == graph.target(it)) return false;
+    }
+    return true;
+  }
+
+  /// \brief Returns true when there is not parallel edges in the graph.
+  ///
+  /// Returns true when there is not parallel edges in the graph.
+  template <typename Graph>
+  bool parallelFree(const Graph& graph) {
+    typename Graph::template NodeMap<bool> reached(graph, false);
+    for (typename Graph::NodeIt n(graph); n != INVALID; ++n) {
+      for (typename Graph::OutEdgeIt e(graph, n); e != INVALID; ++e) {
+        if (reached[graph.target(e)]) return false;
+        reached.set(graph.target(e), true);
+      }
+      for (typename Graph::OutEdgeIt e(graph, n); e != INVALID; ++e) {
+        reached.set(graph.target(e), false);
+      }
+    }
+    return true;
+  }
+
+  /// \brief Returns true when there is not loop edge and parallel
+  /// edges in the graph.
+  ///
+  /// Returns true when there is not loop edge and parallel edges in
+  /// the graph.
+  template <typename Graph>
+  bool simpleGraph(const Graph& graph) {
+    typename Graph::template NodeMap<bool> reached(graph, false);
+    for (typename Graph::NodeIt n(graph); n != INVALID; ++n) {
+      reached.set(n, true);
+      for (typename Graph::OutEdgeIt e(graph, n); e != INVALID; ++e) {
+        if (reached[graph.target(e)]) return false;
+        reached.set(graph.target(e), true);
+      }
+      for (typename Graph::OutEdgeIt e(graph, n); e != INVALID; ++e) {
+        reached.set(graph.target(e), false);
+      }
+      reached.set(n, false);
+    }
+    return true;
+  }
+   
+} //namespace lemon
+
+#endif //LEMON_TOPOLOGY_H
Index: lemon/ugraph_adaptor.h
===================================================================
--- lemon/ugraph_adaptor.h	(revision 2617)
+++ lemon/ugraph_adaptor.h	(revision 2617)
@@ -0,0 +1,1180 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_UGRAPH_ADAPTOR_H
+#define LEMON_UGRAPH_ADAPTOR_H
+
+///\ingroup graph_adaptors
+///\file
+///\brief Several graph adaptors.
+///
+///This file contains several useful ugraph adaptor functions.
+///
+///\author Balazs Dezso
+
+#include <lemon/bits/invalid.h>
+#include <lemon/maps.h>
+
+#include <lemon/bits/graph_adaptor_extender.h>
+
+#include <lemon/bits/traits.h>
+
+#include <iostream>
+
+namespace lemon {
+
+  /// \brief Base type for the Graph Adaptors
+  ///
+  /// This is the base type for most of LEMON graph adaptors. 
+  /// This class implements a trivial graph adaptor i.e. it only wraps the 
+  /// functions and types of the graph. The purpose of this class is to 
+  /// make easier implementing graph adaptors. E.g. if an adaptor is 
+  /// considered which differs from the wrapped graph only in some of its 
+  /// functions or types, then it can be derived from GraphAdaptor, and only 
+  /// the differences should be implemented.
+  ///
+  /// \author Balazs Dezso 
+  template<typename _UGraph>
+  class UGraphAdaptorBase {
+  public:
+    typedef _UGraph Graph;
+    typedef Graph ParentGraph;
+
+  protected:
+    Graph* graph;
+
+    UGraphAdaptorBase() : graph(0) {}
+
+    void setGraph(Graph& _graph) { graph=&_graph; }
+
+  public:
+    UGraphAdaptorBase(Graph& _graph) : graph(&_graph) {}
+ 
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::UEdge UEdge;
+   
+    void first(Node& i) const { graph->first(i); }
+    void first(Edge& i) const { graph->first(i); }
+    void first(UEdge& i) const { graph->first(i); }
+    void firstIn(Edge& i, const Node& n) const { graph->firstIn(i, n); }
+    void firstOut(Edge& i, const Node& n ) const { graph->firstOut(i, n); }
+    void firstInc(UEdge &i, bool &d, const Node &n) const {
+      graph->firstInc(i, d, n);
+    }
+
+    void next(Node& i) const { graph->next(i); }
+    void next(Edge& i) const { graph->next(i); }
+    void next(UEdge& i) const { graph->next(i); }
+    void nextIn(Edge& i) const { graph->nextIn(i); }
+    void nextOut(Edge& i) const { graph->nextOut(i); }
+    void nextInc(UEdge &i, bool &d) const { graph->nextInc(i, d); }
+
+    Node source(const UEdge& e) const { return graph->source(e); }
+    Node target(const UEdge& e) const { return graph->target(e); }
+
+    Node source(const Edge& e) const { return graph->source(e); }
+    Node target(const Edge& e) const { return graph->target(e); }
+
+    typedef NodeNumTagIndicator<Graph> NodeNumTag;
+    int nodeNum() const { return graph->nodeNum(); }
+    
+    typedef EdgeNumTagIndicator<Graph> EdgeNumTag;
+    int edgeNum() const { return graph->edgeNum(); }
+    int uEdgeNum() const { return graph->uEdgeNum(); }
+
+    typedef FindEdgeTagIndicator<Graph> FindEdgeTag;
+    Edge findEdge(const Node& u, const Node& v, 
+		  const Edge& prev = INVALID) {
+      return graph->findEdge(u, v, prev);
+    }
+    UEdge findUEdge(const Node& u, const Node& v, 
+                    const UEdge& prev = INVALID) {
+      return graph->findUEdge(u, v, prev);
+    }
+  
+    Node addNode() const { return graph->addNode(); }
+    UEdge addEdge(const Node& u, const Node& v) const { 
+      return graph->addEdge(u, v); 
+    }
+
+    void erase(const Node& i) const { graph->erase(i); }
+    void erase(const UEdge& i) const { graph->erase(i); }
+  
+    void clear() const { graph->clear(); }
+    
+    bool direction(const Edge& e) const { return graph->direction(e); }
+    Edge direct(const UEdge& e, bool d) const { return graph->direct(e, d); }
+
+    int id(const Node& v) const { return graph->id(v); }
+    int id(const Edge& e) const { return graph->id(e); }
+    int id(const UEdge& e) const { return graph->id(e); }
+
+    Node nodeFromId(int ix) const {
+      return graph->nodeFromId(ix);
+    }
+
+    Edge edgeFromId(int ix) const {
+      return graph->edgeFromId(ix);
+    }
+
+    UEdge uEdgeFromId(int ix) const {
+      return graph->uEdgeFromId(ix);
+    }
+
+    int maxNodeId() const {
+      return graph->maxNodeId();
+    }
+
+    int maxEdgeId() const {
+      return graph->maxEdgeId();
+    }
+
+    int maxUEdgeId() const {
+      return graph->maxEdgeId();
+    }
+
+    typedef typename ItemSetTraits<Graph, Node>::ItemNotifier NodeNotifier;
+
+    NodeNotifier& notifier(Node) const {
+      return graph->notifier(Node());
+    } 
+
+    typedef typename ItemSetTraits<Graph, Edge>::ItemNotifier EdgeNotifier;
+
+    EdgeNotifier& notifier(Edge) const {
+      return graph->notifier(Edge());
+    } 
+
+    typedef typename ItemSetTraits<Graph, UEdge>::ItemNotifier UEdgeNotifier;
+
+    UEdgeNotifier& notifier(UEdge) const {
+      return graph->notifier(UEdge());
+    } 
+
+    template <typename _Value>
+    class NodeMap : public Graph::template NodeMap<_Value> {
+    public:
+      typedef typename Graph::template NodeMap<_Value> Parent;
+      explicit NodeMap(const UGraphAdaptorBase<Graph>& ga) 
+	: Parent(*ga.graph) {}
+      NodeMap(const UGraphAdaptorBase<Graph>& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      NodeMap& operator=(const NodeMap& cmap) {
+	return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+
+    };
+
+    template <typename _Value>
+    class EdgeMap : public Graph::template EdgeMap<_Value> {
+    public:
+      typedef typename Graph::template EdgeMap<_Value> Parent;
+      explicit EdgeMap(const UGraphAdaptorBase<Graph>& ga) 
+	: Parent(*ga.graph) {}
+      EdgeMap(const UGraphAdaptorBase<Graph>& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class UEdgeMap : public Graph::template UEdgeMap<_Value> {
+    public:
+      typedef typename Graph::template UEdgeMap<_Value> Parent;
+      explicit UEdgeMap(const UGraphAdaptorBase<Graph>& ga) 
+	: Parent(*ga.graph) {}
+      UEdgeMap(const UGraphAdaptorBase<Graph>& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      UEdgeMap& operator=(const UEdgeMap& cmap) {
+	return operator=<UEdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      UEdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+    };
+
+  };
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief Trivial undirected graph adaptor
+  ///
+  /// This class is an adaptor which does not change the adapted undirected
+  /// graph. It can be used only to test the undirected graph adaptors.
+  template <typename _UGraph>
+  class UGraphAdaptor 
+    : public UGraphAdaptorExtender< UGraphAdaptorBase<_UGraph> > { 
+  public:
+    typedef _UGraph Graph;
+    typedef UGraphAdaptorExtender<UGraphAdaptorBase<_UGraph> > Parent;
+  protected:
+    UGraphAdaptor() : Parent() {}
+
+  public:
+    explicit UGraphAdaptor(Graph& _graph) { setGraph(_graph); }
+  };
+
+  template <typename _UGraph, typename NodeFilterMap, 
+	    typename UEdgeFilterMap, bool checked = true>
+  class SubUGraphAdaptorBase : public UGraphAdaptorBase<_UGraph> {
+  public:
+    typedef _UGraph Graph;
+    typedef SubUGraphAdaptorBase Adaptor;
+    typedef UGraphAdaptorBase<_UGraph> Parent;
+  protected:
+
+    NodeFilterMap* node_filter_map;
+    UEdgeFilterMap* uedge_filter_map;
+
+    SubUGraphAdaptorBase() 
+      : Parent(), node_filter_map(0), uedge_filter_map(0) { }
+
+    void setNodeFilterMap(NodeFilterMap& _node_filter_map) {
+      node_filter_map=&_node_filter_map;
+    }
+    void setUEdgeFilterMap(UEdgeFilterMap& _uedge_filter_map) {
+      uedge_filter_map=&_uedge_filter_map;
+    }
+
+  public:
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+    typedef typename Parent::UEdge UEdge;
+
+    void first(Node& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && !(*node_filter_map)[i]) Parent::next(i); 
+    }
+
+    void first(Edge& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)]
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::next(i); 
+    }
+
+    void first(UEdge& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)]
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::next(i); 
+    }
+
+    void firstIn(Edge& i, const Node& n) const { 
+      Parent::firstIn(i, n); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)])) Parent::nextIn(i); 
+    }
+
+    void firstOut(Edge& i, const Node& n) const { 
+      Parent::firstOut(i, n); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::nextOut(i); 
+    }
+
+    void firstInc(UEdge& i, bool& d, const Node& n) const { 
+      Parent::firstInc(i, d, n); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i] 
+            || !(*node_filter_map)[Parent::source(i)]
+            || !(*node_filter_map)[Parent::target(i)])) Parent::nextInc(i, d); 
+    }
+
+    void next(Node& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && !(*node_filter_map)[i]) Parent::next(i); 
+    }
+
+    void next(Edge& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)]
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::next(i); 
+    }
+
+    void next(UEdge& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)]
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::next(i); 
+    }
+
+    void nextIn(Edge& i) const { 
+      Parent::nextIn(i); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::source(i)])) Parent::nextIn(i); 
+    }
+
+    void nextOut(Edge& i) const { 
+      Parent::nextOut(i); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i] 
+	     || !(*node_filter_map)[Parent::target(i)])) Parent::nextOut(i); 
+    }
+
+    void nextInc(UEdge& i, bool& d) const { 
+      Parent::nextInc(i, d); 
+      while (i!=INVALID && (!(*uedge_filter_map)[i]
+            || !(*node_filter_map)[Parent::source(i)]
+            || !(*node_filter_map)[Parent::target(i)])) Parent::nextInc(i, d); 
+    }
+
+    /// \brief Hide the given node in the graph.
+    ///
+    /// This function hides \c n in the graph, i.e. the iteration 
+    /// jumps over it. This is done by simply setting the value of \c n  
+    /// to be false in the corresponding node-map.
+    void hide(const Node& n) const { node_filter_map->set(n, false); }
+
+    /// \brief Hide the given undirected edge in the graph.
+    ///
+    /// This function hides \c e in the graph, i.e. the iteration 
+    /// jumps over it. This is done by simply setting the value of \c e  
+    /// to be false in the corresponding uedge-map.
+    void hide(const UEdge& e) const { uedge_filter_map->set(e, false); }
+
+    /// \brief Unhide the given node in the graph.
+    ///
+    /// The value of \c n is set to be true in the node-map which stores 
+    /// hide information. If \c n was hidden previuosly, then it is shown 
+    /// again
+     void unHide(const Node& n) const { node_filter_map->set(n, true); }
+
+    /// \brief Hide the given undirected edge in the graph.
+    ///
+    /// The value of \c e is set to be true in the uedge-map which stores 
+    /// hide information. If \c e was hidden previuosly, then it is shown 
+    /// again
+    void unHide(const UEdge& e) const { uedge_filter_map->set(e, true); }
+
+    /// \brief Returns true if \c n is hidden.
+    ///
+    /// Returns true if \c n is hidden.
+    bool hidden(const Node& n) const { return !(*node_filter_map)[n]; }
+
+    /// \brief Returns true if \c e is hidden.
+    ///
+    /// Returns true if \c e is hidden.
+    bool hidden(const UEdge& e) const { return !(*uedge_filter_map)[e]; }
+
+    typedef False NodeNumTag;
+    typedef False EdgeNumTag;
+
+    typedef FindEdgeTagIndicator<Graph> FindEdgeTag;
+    Edge findEdge(const Node& u, const Node& v, 
+		  const Edge& prev = INVALID) {
+      if (!(*node_filter_map)[u] || !(*node_filter_map)[v]) {
+        return INVALID;
+      }
+      Edge edge = Parent::findEdge(u, v, prev);
+      while (edge != INVALID && !(*uedge_filter_map)[edge]) {
+        edge = Parent::findEdge(u, v, edge);
+      }
+      return edge;
+    }
+    UEdge findUEdge(const Node& u, const Node& v, 
+		  const UEdge& prev = INVALID) {
+      if (!(*node_filter_map)[u] || !(*node_filter_map)[v]) {
+        return INVALID;
+      }
+      UEdge uedge = Parent::findUEdge(u, v, prev);
+      while (uedge != INVALID && !(*uedge_filter_map)[uedge]) {
+        uedge = Parent::findUEdge(u, v, uedge);
+      }
+      return uedge;
+    }
+
+    template <typename _Value>
+    class NodeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template NodeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template NodeMap<_Value> > Parent;
+    
+      NodeMap(const Graph& g) 
+	: Parent(g) {}
+      NodeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      NodeMap& operator=(const NodeMap& cmap) {
+	return operator=<NodeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class EdgeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template EdgeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template EdgeMap<_Value> > Parent;
+    
+      EdgeMap(const Graph& g) 
+	: Parent(g) {}
+      EdgeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class UEdgeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template UEdgeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template UEdgeMap<_Value> > Parent;
+    
+      UEdgeMap(const Graph& g) 
+	: Parent(g) {}
+      UEdgeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      UEdgeMap& operator=(const UEdgeMap& cmap) {
+	return operator=<UEdgeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      UEdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+  };
+
+  template <typename _UGraph, typename NodeFilterMap, typename UEdgeFilterMap>
+  class SubUGraphAdaptorBase<_UGraph, NodeFilterMap, UEdgeFilterMap, false> 
+    : public UGraphAdaptorBase<_UGraph> {
+  public:
+    typedef _UGraph Graph;
+    typedef SubUGraphAdaptorBase Adaptor;
+    typedef UGraphAdaptorBase<_UGraph> Parent;
+  protected:
+    NodeFilterMap* node_filter_map;
+    UEdgeFilterMap* uedge_filter_map;
+    SubUGraphAdaptorBase() : Parent(), 
+			    node_filter_map(0), uedge_filter_map(0) { }
+
+    void setNodeFilterMap(NodeFilterMap& _node_filter_map) {
+      node_filter_map=&_node_filter_map;
+    }
+    void setUEdgeFilterMap(UEdgeFilterMap& _uedge_filter_map) {
+      uedge_filter_map=&_uedge_filter_map;
+    }
+
+  public:
+
+    typedef typename Parent::Node Node;
+    typedef typename Parent::Edge Edge;
+    typedef typename Parent::UEdge UEdge;
+
+    void first(Node& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && !(*node_filter_map)[i]) Parent::next(i); 
+    }
+
+    void first(Edge& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::next(i); 
+    }
+
+    void first(UEdge& i) const { 
+      Parent::first(i); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::next(i); 
+    }
+
+    void firstIn(Edge& i, const Node& n) const { 
+      Parent::firstIn(i, n); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::nextIn(i); 
+    }
+
+    void firstOut(Edge& i, const Node& n) const { 
+      Parent::firstOut(i, n); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::nextOut(i); 
+    }
+
+    void firstInc(UEdge& i, bool& d, const Node& n) const { 
+      Parent::firstInc(i, d, n); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::nextInc(i, d); 
+    }
+
+    void next(Node& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && !(*node_filter_map)[i]) Parent::next(i); 
+    }
+    void next(Edge& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::next(i); 
+    }
+    void next(UEdge& i) const { 
+      Parent::next(i); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::next(i); 
+    }
+    void nextIn(Edge& i) const { 
+      Parent::nextIn(i); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::nextIn(i); 
+    }
+
+    void nextOut(Edge& i) const { 
+      Parent::nextOut(i); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::nextOut(i); 
+    }
+    void nextInc(UEdge& i, bool& d) const { 
+      Parent::nextInc(i, d); 
+      while (i!=INVALID && !(*uedge_filter_map)[i]) Parent::nextInc(i, d); 
+    }
+
+    /// \brief Hide the given node in the graph.
+    ///
+    /// This function hides \c n in the graph, i.e. the iteration 
+    /// jumps over it. This is done by simply setting the value of \c n  
+    /// to be false in the corresponding node-map.
+    void hide(const Node& n) const { node_filter_map->set(n, false); }
+
+    /// \brief Hide the given undirected edge in the graph.
+    ///
+    /// This function hides \c e in the graph, i.e. the iteration 
+    /// jumps over it. This is done by simply setting the value of \c e  
+    /// to be false in the corresponding uedge-map.
+    void hide(const UEdge& e) const { uedge_filter_map->set(e, false); }
+
+    /// \brief Unhide the given node in the graph.
+    ///
+    /// The value of \c n is set to be true in the node-map which stores 
+    /// hide information. If \c n was hidden previuosly, then it is shown 
+    /// again
+     void unHide(const Node& n) const { node_filter_map->set(n, true); }
+
+    /// \brief Hide the given undirected edge in the graph.
+    ///
+    /// The value of \c e is set to be true in the uedge-map which stores 
+    /// hide information. If \c e was hidden previuosly, then it is shown 
+    /// again
+    void unHide(const UEdge& e) const { uedge_filter_map->set(e, true); }
+
+    /// \brief Returns true if \c n is hidden.
+    ///
+    /// Returns true if \c n is hidden.
+    bool hidden(const Node& n) const { return !(*node_filter_map)[n]; }
+
+    /// \brief Returns true if \c e is hidden.
+    ///
+    /// Returns true if \c e is hidden.
+    bool hidden(const UEdge& e) const { return !(*uedge_filter_map)[e]; }
+
+    typedef False NodeNumTag;
+    typedef False EdgeNumTag;
+
+    typedef FindEdgeTagIndicator<Graph> FindEdgeTag;
+    Edge findEdge(const Node& u, const Node& v, 
+		  const Edge& prev = INVALID) {
+      Edge edge = Parent::findEdge(u, v, prev);
+      while (edge != INVALID && !(*uedge_filter_map)[edge]) {
+        edge = Parent::findEdge(u, v, edge);
+      }
+      return edge;
+    }
+    UEdge findUEdge(const Node& u, const Node& v, 
+		  const UEdge& prev = INVALID) {
+      UEdge uedge = Parent::findUEdge(u, v, prev);
+      while (uedge != INVALID && !(*uedge_filter_map)[uedge]) {
+        uedge = Parent::findUEdge(u, v, uedge);
+      }
+      return uedge;
+    }
+
+    template <typename _Value>
+    class NodeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template NodeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template NodeMap<_Value> > Parent;
+    
+      NodeMap(const Graph& g) 
+	: Parent(g) {}
+      NodeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      NodeMap& operator=(const NodeMap& cmap) {
+	return operator=<NodeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class EdgeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template EdgeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template EdgeMap<_Value> > Parent;
+    
+      EdgeMap(const Graph& g) 
+	: Parent(g) {}
+      EdgeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      EdgeMap& operator=(const EdgeMap& cmap) {
+	return operator=<EdgeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+
+    template <typename _Value>
+    class UEdgeMap 
+      : public SubMapExtender<Adaptor, 
+                              typename Parent::template UEdgeMap<_Value> > 
+    {
+    public:
+      typedef Adaptor Graph;
+      typedef SubMapExtender<Adaptor, typename Parent::
+                             template UEdgeMap<_Value> > Parent;
+    
+      UEdgeMap(const Graph& g) 
+	: Parent(g) {}
+      UEdgeMap(const Graph& g, const _Value& v) 
+	: Parent(g, v) {}
+    
+      UEdgeMap& operator=(const UEdgeMap& cmap) {
+	return operator=<UEdgeMap>(cmap);
+      }
+    
+      template <typename CMap>
+      UEdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+	return *this;
+      }
+    };
+  };
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief A graph adaptor for hiding nodes and edges from an undirected 
+  /// graph.
+  /// 
+  /// SubUGraphAdaptor shows the undirected graph with filtered node-set and 
+  /// edge-set. If the \c checked parameter is true then it filters the edgeset
+  /// to do not get invalid edges without source or target.
+  /// 
+  /// If the \c checked template parameter is false then we have to note that 
+  /// the node-iterator cares only the filter on the node-set, and the 
+  /// edge-iterator cares only the filter on the edge-set.
+  /// This way the edge-map
+  /// should filter all edges which's source or target is filtered by the 
+  /// node-filter.
+  ///
+  template<typename _UGraph, typename NodeFilterMap, 
+	   typename UEdgeFilterMap, bool checked = true>
+  class SubUGraphAdaptor : 
+    public UGraphAdaptorExtender<
+    SubUGraphAdaptorBase<_UGraph, NodeFilterMap, UEdgeFilterMap, checked> > {
+  public:
+    typedef _UGraph Graph;
+    typedef UGraphAdaptorExtender<
+      SubUGraphAdaptorBase<_UGraph, NodeFilterMap, UEdgeFilterMap> > Parent;
+  protected:
+    SubUGraphAdaptor() { }
+  public:
+    SubUGraphAdaptor(Graph& _graph, NodeFilterMap& _node_filter_map, 
+		    UEdgeFilterMap& _uedge_filter_map) { 
+      setGraph(_graph);
+      setNodeFilterMap(_node_filter_map);
+      setUEdgeFilterMap(_uedge_filter_map);
+    }
+  };
+
+  template<typename UGraph, typename NodeFilterMap, typename EdgeFilterMap>
+  SubUGraphAdaptor<const UGraph, NodeFilterMap, EdgeFilterMap>
+  subUGraphAdaptor(const UGraph& graph, 
+                   NodeFilterMap& nfm, EdgeFilterMap& efm) {
+    return SubUGraphAdaptor<const UGraph, NodeFilterMap, EdgeFilterMap>
+      (graph, nfm, efm);
+  }
+
+  template<typename UGraph, typename NodeFilterMap, typename EdgeFilterMap>
+  SubUGraphAdaptor<const UGraph, const NodeFilterMap, EdgeFilterMap>
+  subUGraphAdaptor(const UGraph& graph, 
+                   NodeFilterMap& nfm, EdgeFilterMap& efm) {
+    return SubUGraphAdaptor<const UGraph, const NodeFilterMap, EdgeFilterMap>
+      (graph, nfm, efm);
+  }
+
+  template<typename UGraph, typename NodeFilterMap, typename EdgeFilterMap>
+  SubUGraphAdaptor<const UGraph, NodeFilterMap, const EdgeFilterMap>
+  subUGraphAdaptor(const UGraph& graph, 
+                   NodeFilterMap& nfm, EdgeFilterMap& efm) {
+    return SubUGraphAdaptor<const UGraph, NodeFilterMap, const EdgeFilterMap>
+      (graph, nfm, efm);
+  }
+
+  template<typename UGraph, typename NodeFilterMap, typename EdgeFilterMap>
+  SubUGraphAdaptor<const UGraph, const NodeFilterMap, const EdgeFilterMap>
+  subUGraphAdaptor(const UGraph& graph, 
+                   NodeFilterMap& nfm, EdgeFilterMap& efm) {
+    return SubUGraphAdaptor<const UGraph, const NodeFilterMap, 
+      const EdgeFilterMap>(graph, nfm, efm);
+  }
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief An adaptor for hiding nodes from an undirected graph.
+  ///
+  /// An adaptor for hiding nodes from an undirected graph.  This
+  /// adaptor specializes SubUGraphAdaptor in the way that only the
+  /// node-set can be filtered. In usual case the checked parameter is
+  /// true, we get the induced subgraph. But if the checked parameter
+  /// is false then we can filter only isolated nodes.
+  template<typename _UGraph, typename NodeFilterMap, bool checked = true>
+  class NodeSubUGraphAdaptor : 
+    public SubUGraphAdaptor<_UGraph, NodeFilterMap, 
+                            ConstMap<typename _UGraph::UEdge, bool>, checked> {
+  public:
+    typedef SubUGraphAdaptor<_UGraph, NodeFilterMap, 
+                             ConstMap<typename _UGraph::UEdge, bool> > Parent;
+    typedef _UGraph Graph;
+  protected:
+    ConstMap<typename _UGraph::UEdge, bool> const_true_map;
+
+    NodeSubUGraphAdaptor() : const_true_map(true) {
+      Parent::setUEdgeFilterMap(const_true_map);
+    }
+
+  public:
+    NodeSubUGraphAdaptor(Graph& _graph, NodeFilterMap& _node_filter_map) : 
+      Parent(), const_true_map(true) { 
+      Parent::setGraph(_graph);
+      Parent::setNodeFilterMap(_node_filter_map);
+      Parent::setUEdgeFilterMap(const_true_map);
+    }
+  };
+
+  template<typename UGraph, typename NodeFilterMap>
+  NodeSubUGraphAdaptor<const UGraph, NodeFilterMap>
+  nodeSubUGraphAdaptor(const UGraph& graph, NodeFilterMap& nfm) {
+    return NodeSubUGraphAdaptor<const UGraph, NodeFilterMap>(graph, nfm);
+  }
+
+  template<typename UGraph, typename NodeFilterMap>
+  NodeSubUGraphAdaptor<const UGraph, const NodeFilterMap>
+  nodeSubUGraphAdaptor(const UGraph& graph, const NodeFilterMap& nfm) {
+    return NodeSubUGraphAdaptor<const UGraph, const NodeFilterMap>(graph, nfm);
+  }
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief An adaptor for hiding undirected edges from an undirected graph.
+  ///
+  /// \warning Graph adaptors are in even more experimental state
+  /// than the other parts of the lib. Use them at you own risk.
+  ///
+  /// An adaptor for hiding undirected edges from an undirected graph.
+  /// This adaptor specializes SubUGraphAdaptor in the way that
+  /// only the edge-set 
+  /// can be filtered.
+  template<typename _UGraph, typename UEdgeFilterMap>
+  class EdgeSubUGraphAdaptor : 
+    public SubUGraphAdaptor<_UGraph, ConstMap<typename _UGraph::Node,bool>, 
+                            UEdgeFilterMap, false> {
+  public:
+    typedef SubUGraphAdaptor<_UGraph, ConstMap<typename _UGraph::Node,bool>, 
+                             UEdgeFilterMap, false> Parent;
+    typedef _UGraph Graph;
+  protected:
+    ConstMap<typename Graph::Node, bool> const_true_map;
+
+    EdgeSubUGraphAdaptor() : const_true_map(true) {
+      Parent::setNodeFilterMap(const_true_map);
+    }
+
+  public:
+
+    EdgeSubUGraphAdaptor(Graph& _graph, UEdgeFilterMap& _uedge_filter_map) : 
+      Parent(), const_true_map(true) { 
+      Parent::setGraph(_graph);
+      Parent::setNodeFilterMap(const_true_map);
+      Parent::setUEdgeFilterMap(_uedge_filter_map);
+    }
+
+  };
+
+  template<typename UGraph, typename EdgeFilterMap>
+  EdgeSubUGraphAdaptor<const UGraph, EdgeFilterMap>
+  edgeSubUGraphAdaptor(const UGraph& graph, EdgeFilterMap& efm) {
+    return EdgeSubUGraphAdaptor<const UGraph, EdgeFilterMap>(graph, efm);
+  }
+
+  template<typename UGraph, typename EdgeFilterMap>
+  EdgeSubUGraphAdaptor<const UGraph, const EdgeFilterMap>
+  edgeSubUGraphAdaptor(const UGraph& graph, const EdgeFilterMap& efm) {
+    return EdgeSubUGraphAdaptor<const UGraph, const EdgeFilterMap>(graph, efm);
+  }
+
+  /// \brief Base of direct undirected graph adaptor
+  ///
+  /// Base class of the direct undirected graph adaptor. All public member
+  /// of this class can be used with the DirUGraphAdaptor too.
+  /// \sa DirUGraphAdaptor
+  template <typename _UGraph, typename _DirectionMap>
+  class DirUGraphAdaptorBase {
+  public:
+    
+    typedef _UGraph Graph;
+    typedef _DirectionMap DirectionMap;
+
+    typedef typename _UGraph::Node Node;
+    typedef typename _UGraph::UEdge Edge;
+   
+    /// \brief Reverse edge
+    /// 
+    /// It reverse the given edge. It simply negate the direction in the map.
+    void reverseEdge(const Edge& edge) {
+      direction->set(edge, !(*direction)[edge]);
+    }
+
+    void first(Node& i) const { graph->first(i); }
+    void first(Edge& i) const { graph->first(i); }
+    void firstIn(Edge& i, const Node& n) const {
+      bool d;
+      graph->firstInc(i, d, n);
+      while (i != INVALID && d == (*direction)[i]) graph->nextInc(i, d);
+    }
+    void firstOut(Edge& i, const Node& n ) const { 
+      bool d;
+      graph->firstInc(i, d, n);
+      while (i != INVALID && d != (*direction)[i]) graph->nextInc(i, d);
+    }
+
+    void next(Node& i) const { graph->next(i); }
+    void next(Edge& i) const { graph->next(i); }
+    void nextIn(Edge& i) const {
+      bool d = !(*direction)[i];
+      graph->nextInc(i, d);
+      while (i != INVALID && d == (*direction)[i]) graph->nextInc(i, d);
+    }
+    void nextOut(Edge& i) const {
+      bool d = (*direction)[i];
+      graph->nextInc(i, d);
+      while (i != INVALID && d != (*direction)[i]) graph->nextInc(i, d);
+    }
+
+    Node source(const Edge& e) const { 
+      return (*direction)[e] ? graph->source(e) : graph->target(e); 
+    }
+    Node target(const Edge& e) const { 
+      return (*direction)[e] ? graph->target(e) : graph->source(e); 
+    }
+
+    typedef NodeNumTagIndicator<Graph> NodeNumTag;
+    int nodeNum() const { return graph->nodeNum(); }
+    
+    typedef EdgeNumTagIndicator<Graph> EdgeNumTag;
+    int edgeNum() const { return graph->uEdgeNum(); }
+
+    typedef FindEdgeTagIndicator<Graph> FindEdgeTag;
+    Edge findEdge(const Node& u, const Node& v, 
+		  const Edge& prev = INVALID) {
+      Edge edge = prev;
+      bool d = edge == INVALID ? true : (*direction)[edge];
+      if (d) {
+        edge = graph->findUEdge(u, v, edge);
+        while (edge != INVALID && !(*direction)[edge]) {
+          graph->findUEdge(u, v, edge);
+        }
+        if (edge != INVALID) return edge;
+      }
+      graph->findUEdge(v, u, edge);
+      while (edge != INVALID && (*direction)[edge]) {
+        graph->findUEdge(u, v, edge);
+      }
+      return edge;
+    }
+  
+    Node addNode() const { 
+      return Node(graph->addNode()); 
+    }
+
+    Edge addEdge(const Node& u, const Node& v) const {
+      Edge edge = graph->addEdge(u, v);
+      direction->set(edge, graph->source(edge) == u);
+      return edge; 
+    }
+
+    void erase(const Node& i) const { graph->erase(i); }
+    void erase(const Edge& i) const { graph->erase(i); }
+  
+    void clear() const { graph->clear(); }
+    
+    int id(const Node& v) const { return graph->id(v); }
+    int id(const Edge& e) const { return graph->id(e); }
+
+    int maxNodeId() const {
+      return graph->maxNodeId();
+    }
+
+    int maxEdgeId() const {
+      return graph->maxEdgeId();
+    }
+
+    typedef typename ItemSetTraits<Graph, Node>::ItemNotifier NodeNotifier;
+
+    NodeNotifier& notifier(Node) const {
+      return graph->notifier(Node());
+    } 
+
+    typedef typename ItemSetTraits<Graph, Edge>::ItemNotifier EdgeNotifier;
+
+    EdgeNotifier& notifier(Edge) const {
+      return graph->notifier(Edge());
+    } 
+
+    template <typename _Value>
+    class NodeMap : public _UGraph::template NodeMap<_Value> {
+    public:
+
+      typedef typename _UGraph::template NodeMap<_Value> Parent;
+
+      explicit NodeMap(const DirUGraphAdaptorBase& ga) 
+	: Parent(*ga.graph) {}
+
+      NodeMap(const DirUGraphAdaptorBase& ga, const _Value& value)
+	: Parent(*ga.graph, value) {}
+
+      NodeMap& operator=(const NodeMap& cmap) {
+        return operator=<NodeMap>(cmap);
+      }
+
+      template <typename CMap>
+      NodeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+
+    };
+
+    template <typename _Value>
+    class EdgeMap : public _UGraph::template UEdgeMap<_Value> {
+    public:
+
+      typedef typename _UGraph::template UEdgeMap<_Value> Parent;
+
+      explicit EdgeMap(const DirUGraphAdaptorBase& ga) 
+	: Parent(*ga.graph) { }
+
+      EdgeMap(const DirUGraphAdaptorBase& ga, const _Value& value)
+	: Parent(*ga.graph, value) { }
+
+      EdgeMap& operator=(const EdgeMap& cmap) {
+        return operator=<EdgeMap>(cmap);
+      }
+
+      template <typename CMap>
+      EdgeMap& operator=(const CMap& cmap) {
+        Parent::operator=(cmap);
+        return *this;
+      }
+    };
+
+    
+
+  protected:
+    Graph* graph;
+    DirectionMap* direction;
+
+    void setDirectionMap(DirectionMap& _direction) {
+      direction = &_direction;
+    }
+
+    void setGraph(Graph& _graph) {
+      graph = &_graph;
+    }
+
+  };
+
+
+  /// \ingroup graph_adaptors
+  ///
+  /// \brief A directed graph is made from an undirected graph by an adaptor
+  ///
+  /// This adaptor gives a direction for each uedge in the undirected
+  /// graph. The direction of the edges stored in the
+  /// DirectionMap. This map is a bool map on the undirected edges. If
+  /// the uedge is mapped to true then the direction of the directed
+  /// edge will be the same as the default direction of the uedge. The
+  /// edges can be easily reverted by the \ref
+  /// DirUGraphAdaptorBase::reverseEdge "reverseEdge()" member in the
+  /// adaptor.
+  ///
+  /// It can be used to solve orientation problems on directed graphs.
+  /// By example how can we orient an undirected graph to get the minimum
+  /// number of strongly connected components. If we orient the edges with
+  /// the dfs algorithm out from the source then we will get such an 
+  /// orientation. 
+  ///
+  /// We use the \ref DfsVisitor "visitor" interface of the 
+  /// \ref DfsVisit "dfs" algorithm:
+  ///\code
+  /// template <typename DirMap>
+  /// class OrientVisitor : public DfsVisitor<UGraph> {
+  /// public:
+  ///
+  ///   OrientVisitor(const UGraph& ugraph, DirMap& dirMap)
+  ///     : _ugraph(ugraph), _dirMap(dirMap), _processed(ugraph, false) {}
+  ///
+  ///   void discover(const Edge& edge) {
+  ///     _processed.set(edge, true);
+  ///     _dirMap.set(edge, _ugraph.direction(edge));
+  ///   }
+  ///
+  ///   void examine(const Edge& edge) {
+  ///     if (_processed[edge]) return;
+  ///     _processed.set(edge, true);
+  ///     _dirMap.set(edge, _ugraph.direction(edge));
+  ///   }  
+  /// 
+  /// private:
+  ///   const UGraph& _ugraph;  
+  ///   DirMap& _dirMap;
+  ///   UGraph::UEdgeMap<bool> _processed;
+  /// };
+  ///\endcode
+  ///
+  /// And now we can use the orientation:
+  ///\code
+  /// UGraph::UEdgeMap<bool> dmap(ugraph);
+  ///
+  /// typedef OrientVisitor<UGraph::UEdgeMap<bool> > Visitor;
+  /// Visitor visitor(ugraph, dmap);
+  ///
+  /// DfsVisit<UGraph, Visitor> dfs(ugraph, visitor);
+  ///
+  /// dfs.run();
+  ///
+  /// typedef DirUGraphAdaptor<UGraph> DGraph;
+  /// DGraph dgraph(ugraph, dmap);
+  ///
+  /// LEMON_ASSERT(countStronglyConnectedComponents(dgraph) == 
+  ///              countBiEdgeConnectedComponents(ugraph), "Wrong Orientation");
+  ///\endcode
+  ///
+  /// The number of the bi-connected components is a lower bound for
+  /// the number of the strongly connected components in the directed
+  /// graph because if we contract the bi-connected components to
+  /// nodes we will get a tree therefore we cannot orient edges in
+  /// both direction between bi-connected components. In the other way
+  /// the algorithm will orient one component to be strongly
+  /// connected. The two relations proof that the assertion will
+  /// be always true and the found solution is optimal.
+  ///
+  /// \sa DirUGraphAdaptorBase
+  /// \sa dirUGraphAdaptor
+  template<typename _Graph, 
+           typename DirectionMap = typename _Graph::template UEdgeMap<bool> > 
+  class DirUGraphAdaptor : 
+    public GraphAdaptorExtender<
+    DirUGraphAdaptorBase<_Graph, DirectionMap> > {
+  public:
+    typedef _Graph Graph;
+    typedef GraphAdaptorExtender<
+      DirUGraphAdaptorBase<_Graph, DirectionMap> > Parent;
+  protected:
+    DirUGraphAdaptor() { }
+  public:
+    
+    /// \brief Constructor of the adaptor
+    ///
+    /// Constructor of the adaptor
+    DirUGraphAdaptor(_Graph& _graph, DirectionMap& _direction_map) { 
+      setGraph(_graph);
+      setDirectionMap(_direction_map);
+    }
+  };
+
+  /// \brief Just gives back a DirUGraphAdaptor
+  ///
+  /// Just gives back a DirUGraphAdaptor
+  template<typename UGraph, typename DirectionMap>
+  DirUGraphAdaptor<const UGraph, DirectionMap>
+  dirUGraphAdaptor(const UGraph& graph, DirectionMap& dm) {
+    return DirUGraphAdaptor<const UGraph, DirectionMap>(graph, dm);
+  }
+
+  template<typename UGraph, typename DirectionMap>
+  DirUGraphAdaptor<const UGraph, const DirectionMap>
+  dirUGraphAdaptor(const UGraph& graph, const DirectionMap& dm) {
+    return DirUGraphAdaptor<const UGraph, const DirectionMap>(graph, dm);
+  }
+
+}
+
+#endif
Index: lemon/unionfind.h
===================================================================
--- lemon/unionfind.h	(revision 2632)
+++ lemon/unionfind.h	(revision 2632)
@@ -0,0 +1,1814 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_UNION_FIND_H
+#define LEMON_UNION_FIND_H
+
+//!\ingroup auxdat
+//!\file
+//!\brief Union-Find data structures.
+//!
+
+#include <vector>
+#include <list>
+#include <utility>
+#include <algorithm>
+#include <functional>
+
+#include <lemon/bits/invalid.h>
+
+namespace lemon {
+
+  /// \ingroup auxdat
+  ///
+  /// \brief A \e Union-Find data structure implementation
+  ///
+  /// The class implements the \e Union-Find data structure. 
+  /// The union operation uses rank heuristic, while
+  /// the find operation uses path compression.
+  /// This is a very simple but efficient implementation, providing 
+  /// only four methods: join (union), find, insert and size.
+  /// For more features see the \ref UnionFindEnum class.
+  ///
+  /// It is primarily used in Kruskal algorithm for finding minimal
+  /// cost spanning tree in a graph.
+  /// \sa kruskal()
+  ///
+  /// \pre You need to add all the elements by the \ref insert()
+  /// method.  
+  template <typename _ItemIntMap>
+  class UnionFind {
+  public:
+
+    typedef _ItemIntMap ItemIntMap;
+    typedef typename ItemIntMap::Key Item;
+
+  private:
+    // If the items vector stores negative value for an item then
+    // that item is root item and it has -items[it] component size.
+    // Else the items[it] contains the index of the parent.
+    std::vector<int> items;
+    ItemIntMap& index;
+
+    bool rep(int idx) const {
+      return items[idx] < 0;
+    }
+
+    int repIndex(int idx) const {
+      int k = idx;
+      while (!rep(k)) {
+        k = items[k] ;
+      }
+      while (idx != k) {
+        int next = items[idx];
+        const_cast<int&>(items[idx]) = k;
+        idx = next;
+      }
+      return k;
+    }
+
+  public:
+
+    /// \brief Constructor
+    ///
+    /// Constructor of the UnionFind class. You should give an item to
+    /// integer map which will be used from the data structure. If you
+    /// modify directly this map that may cause segmentation fault,
+    /// invalid data structure, or infinite loop when you use again
+    /// the union-find.
+    UnionFind(ItemIntMap& m) : index(m) {}
+
+    /// \brief Returns the index of the element's component.
+    ///
+    /// The method returns the index of the element's component.
+    /// This is an integer between zero and the number of inserted elements.
+    ///
+    int find(const Item& a) {
+      return repIndex(index[a]);
+    }
+
+    /// \brief Clears the union-find data structure
+    ///
+    /// Erase each item from the data structure.
+    void clear() {
+      items.clear();
+    }
+
+    /// \brief Inserts a new element into the structure.
+    ///
+    /// This method inserts a new element into the data structure. 
+    ///
+    /// The method returns the index of the new component.
+    int insert(const Item& a) {
+      int n = items.size();
+      items.push_back(-1);
+      index.set(a,n);
+      return n;
+    }
+
+    /// \brief Joining the components of element \e a and element \e b.
+    ///
+    /// This is the \e union operation of the Union-Find structure. 
+    /// Joins the component of element \e a and component of
+    /// element \e b. If \e a and \e b are in the same component then
+    /// it returns false otherwise it returns true.
+    bool join(const Item& a, const Item& b) {
+      int ka = repIndex(index[a]);
+      int kb = repIndex(index[b]);
+
+      if ( ka == kb ) 
+	return false;
+
+      if (items[ka] < items[kb]) {
+	items[ka] += items[kb];
+	items[kb] = ka;
+      } else {
+	items[kb] += items[ka];
+	items[ka] = kb;
+      }
+      return true;
+    }
+
+    /// \brief Returns the size of the component of element \e a.
+    ///
+    /// Returns the size of the component of element \e a.
+    int size(const Item& a) {
+      int k = repIndex(index[a]);
+      return - items[k];
+    }
+
+  };
+
+  /// \ingroup auxdat
+  ///
+  /// \brief A \e Union-Find data structure implementation which
+  /// is able to enumerate the components.
+  ///
+  /// The class implements a \e Union-Find data structure
+  /// which is able to enumerate the components and the items in
+  /// a component. If you don't need this feature then perhaps it's
+  /// better to use the \ref UnionFind class which is more efficient.
+  ///
+  /// The union operation uses rank heuristic, while
+  /// the find operation uses path compression.
+  ///
+  /// \pre You need to add all the elements by the \ref insert()
+  /// method.
+  ///
+  template <typename _ItemIntMap>
+  class UnionFindEnum {
+  public:
+    
+    typedef _ItemIntMap ItemIntMap;
+    typedef typename ItemIntMap::Key Item;
+
+  private:
+    
+    ItemIntMap& index;
+
+    // If the parent stores negative value for an item then that item
+    // is root item and it has ~(items[it].parent) component id.  Else
+    // the items[it].parent contains the index of the parent.
+    //
+    // The \c next and \c prev provides the double-linked
+    // cyclic list of one component's items.
+    struct ItemT {
+      int parent;
+      Item item;
+
+      int next, prev;
+    };
+
+    std::vector<ItemT> items;
+    int firstFreeItem;
+
+    struct ClassT {
+      int size;
+      int firstItem;
+      int next, prev;
+    };
+    
+    std::vector<ClassT> classes;
+    int firstClass, firstFreeClass;
+
+    int newClass() {
+      if (firstFreeClass == -1) {
+	int cdx = classes.size();
+	classes.push_back(ClassT());
+	return cdx;
+      } else {
+	int cdx = firstFreeClass;
+	firstFreeClass = classes[firstFreeClass].next;
+	return cdx;
+      }
+    }
+
+    int newItem() {
+      if (firstFreeItem == -1) {
+	int idx = items.size();
+	items.push_back(ItemT());
+	return idx;
+      } else {
+	int idx = firstFreeItem;
+	firstFreeItem = items[firstFreeItem].next;
+	return idx;
+      }
+    }
+
+
+    bool rep(int idx) const {
+      return items[idx].parent < 0;
+    }
+
+    int repIndex(int idx) const {
+      int k = idx;
+      while (!rep(k)) {
+        k = items[k].parent;
+      }
+      while (idx != k) {
+        int next = items[idx].parent;
+        const_cast<int&>(items[idx].parent) = k;
+        idx = next;
+      }
+      return k;
+    }
+
+    int classIndex(int idx) const {
+      return ~(items[repIndex(idx)].parent);
+    }
+
+    void singletonItem(int idx) {
+      items[idx].next = idx;
+      items[idx].prev = idx;
+    }
+
+    void laceItem(int idx, int rdx) {
+      items[idx].prev = rdx;
+      items[idx].next = items[rdx].next;
+      items[items[rdx].next].prev = idx;
+      items[rdx].next = idx;
+    }
+
+    void unlaceItem(int idx) {
+      items[items[idx].prev].next = items[idx].next;
+      items[items[idx].next].prev = items[idx].prev;
+      
+      items[idx].next = firstFreeItem;
+      firstFreeItem = idx;
+    }
+
+    void spliceItems(int ak, int bk) {
+      items[items[ak].prev].next = bk;
+      items[items[bk].prev].next = ak;
+      int tmp = items[ak].prev;
+      items[ak].prev = items[bk].prev;
+      items[bk].prev = tmp;
+        
+    }
+
+    void laceClass(int cls) {
+      if (firstClass != -1) {
+        classes[firstClass].prev = cls;
+      }
+      classes[cls].next = firstClass;
+      classes[cls].prev = -1;
+      firstClass = cls;
+    } 
+
+    void unlaceClass(int cls) {
+      if (classes[cls].prev != -1) {
+        classes[classes[cls].prev].next = classes[cls].next;
+      } else {
+        firstClass = classes[cls].next;
+      }
+      if (classes[cls].next != -1) {
+        classes[classes[cls].next].prev = classes[cls].prev;
+      }
+      
+      classes[cls].next = firstFreeClass;
+      firstFreeClass = cls;
+    } 
+
+  public:
+
+    UnionFindEnum(ItemIntMap& _index) 
+      : index(_index), items(), firstFreeItem(-1), 
+	firstClass(-1), firstFreeClass(-1) {}
+    
+    /// \brief Inserts the given element into a new component.
+    ///
+    /// This method creates a new component consisting only of the
+    /// given element.
+    ///
+    int insert(const Item& item) {
+      int idx = newItem();
+
+      index.set(item, idx);
+
+      singletonItem(idx);
+      items[idx].item = item;
+
+      int cdx = newClass();
+
+      items[idx].parent = ~cdx;
+
+      laceClass(cdx);
+      classes[cdx].size = 1;
+      classes[cdx].firstItem = idx;
+
+      firstClass = cdx;
+      
+      return cdx;
+    }
+
+    /// \brief Inserts the given element into the component of the others.
+    ///
+    /// This methods inserts the element \e a into the component of the
+    /// element \e comp. 
+    void insert(const Item& item, int cls) {
+      int rdx = classes[cls].firstItem;
+      int idx = newItem();
+
+      index.set(item, idx);
+
+      laceItem(idx, rdx);
+
+      items[idx].item = item;
+      items[idx].parent = rdx;
+
+      ++classes[~(items[rdx].parent)].size;
+    }
+
+    /// \brief Clears the union-find data structure
+    ///
+    /// Erase each item from the data structure.
+    void clear() {
+      items.clear();
+      firstClass = -1;
+      firstFreeItem = -1;
+    }
+
+    /// \brief Finds the component of the given element.
+    ///
+    /// The method returns the component id of the given element.
+    int find(const Item &item) const {
+      return ~(items[repIndex(index[item])].parent);
+    }
+
+    /// \brief Joining the component of element \e a and element \e b.
+    ///
+    /// This is the \e union operation of the Union-Find structure. 
+    /// Joins the component of element \e a and component of
+    /// element \e b. If \e a and \e b are in the same component then
+    /// returns -1 else returns the remaining class.
+    int join(const Item& a, const Item& b) {
+
+      int ak = repIndex(index[a]);
+      int bk = repIndex(index[b]);
+
+      if (ak == bk) {
+	return -1;
+      }
+
+      int acx = ~(items[ak].parent);
+      int bcx = ~(items[bk].parent);
+
+      int rcx;
+
+      if (classes[acx].size > classes[bcx].size) {
+	classes[acx].size += classes[bcx].size;
+	items[bk].parent = ak;
+        unlaceClass(bcx);
+	rcx = acx;
+      } else {
+	classes[bcx].size += classes[acx].size;
+	items[ak].parent = bk;
+        unlaceClass(acx);
+	rcx = bcx;
+      }
+      spliceItems(ak, bk);
+
+      return rcx;
+    }
+
+    /// \brief Returns the size of the class.
+    ///
+    /// Returns the size of the class.
+    int size(int cls) const {
+      return classes[cls].size;
+    }
+
+    /// \brief Splits up the component. 
+    ///
+    /// Splitting the component into singleton components (component
+    /// of size one).
+    void split(int cls) {
+      int fdx = classes[cls].firstItem;
+      int idx = items[fdx].next;
+      while (idx != fdx) {
+        int next = items[idx].next;
+
+	singletonItem(idx);
+
+	int cdx = newClass();        
+        items[idx].parent = ~cdx;
+
+	laceClass(cdx);
+	classes[cdx].size = 1;
+	classes[cdx].firstItem = idx;
+        
+        idx = next;
+      }
+
+      items[idx].prev = idx;
+      items[idx].next = idx;
+
+      classes[~(items[idx].parent)].size = 1;
+      
+    }
+
+    /// \brief Removes the given element from the structure.
+    ///
+    /// Removes the element from its component and if the component becomes
+    /// empty then removes that component from the component list.
+    ///
+    /// \warning It is an error to remove an element which is not in
+    /// the structure.
+    /// \warning This running time of this operation is proportional to the
+    /// number of the items in this class.
+    void erase(const Item& item) {
+      int idx = index[item];
+      int fdx = items[idx].next;
+
+      int cdx = classIndex(idx);
+      if (idx == fdx) {
+	unlaceClass(cdx);
+	items[idx].next = firstFreeItem;
+	firstFreeItem = idx;
+	return;
+      } else {
+	classes[cdx].firstItem = fdx;
+	--classes[cdx].size;
+	items[fdx].parent = ~cdx;
+
+	unlaceItem(idx);
+	idx = items[fdx].next;
+	while (idx != fdx) {
+	  items[idx].parent = fdx;
+	  idx = items[idx].next;
+	}
+          
+      }
+
+    }
+
+    /// \brief Gives back a representant item of the component.
+    ///
+    /// Gives back a representant item of the component.
+    Item item(int cls) const {
+      return items[classes[cls].firstItem].item;
+    }
+
+    /// \brief Removes the component of the given element from the structure.
+    ///
+    /// Removes the component of the given element from the structure.
+    ///
+    /// \warning It is an error to give an element which is not in the
+    /// structure.
+    void eraseClass(int cls) {
+      int fdx = classes[cls].firstItem;
+      unlaceClass(cls);
+      items[items[fdx].prev].next = firstFreeItem;
+      firstFreeItem = fdx;
+    }
+
+    /// \brief Lemon style iterator for the representant items.
+    ///
+    /// ClassIt is a lemon style iterator for the components. It iterates
+    /// on the ids of the classes.
+    class ClassIt {
+    public:
+      /// \brief Constructor of the iterator
+      ///
+      /// Constructor of the iterator
+      ClassIt(const UnionFindEnum& ufe) : unionFind(&ufe) {
+        cdx = unionFind->firstClass;
+      }
+
+      /// \brief Constructor to get invalid iterator
+      ///
+      /// Constructor to get invalid iterator
+      ClassIt(Invalid) : unionFind(0), cdx(-1) {}
+      
+      /// \brief Increment operator
+      ///
+      /// It steps to the next representant item.
+      ClassIt& operator++() {
+        cdx = unionFind->classes[cdx].next;
+        return *this;
+      }
+      
+      /// \brief Conversion operator
+      ///
+      /// It converts the iterator to the current representant item.
+      operator int() const {
+        return cdx;
+      }
+
+      /// \brief Equality operator
+      ///
+      /// Equality operator
+      bool operator==(const ClassIt& i) { 
+        return i.cdx == cdx;
+      }
+
+      /// \brief Inequality operator
+      ///
+      /// Inequality operator
+      bool operator!=(const ClassIt& i) { 
+        return i.cdx != cdx;
+      }
+      
+    private:
+      const UnionFindEnum* unionFind;
+      int cdx;
+    };
+
+    /// \brief Lemon style iterator for the items of a component.
+    ///
+    /// ClassIt is a lemon style iterator for the components. It iterates
+    /// on the items of a class. By example if you want to iterate on
+    /// each items of each classes then you may write the next code.
+    ///\code
+    /// for (ClassIt cit(ufe); cit != INVALID; ++cit) {
+    ///   std::cout << "Class: ";
+    ///   for (ItemIt iit(ufe, cit); iit != INVALID; ++iit) {
+    ///     std::cout << toString(iit) << ' ' << std::endl;
+    ///   }
+    ///   std::cout << std::endl;
+    /// }
+    ///\endcode
+    class ItemIt {
+    public:
+      /// \brief Constructor of the iterator
+      ///
+      /// Constructor of the iterator. The iterator iterates
+      /// on the class of the \c item.
+      ItemIt(const UnionFindEnum& ufe, int cls) : unionFind(&ufe) {
+        fdx = idx = unionFind->classes[cls].firstItem;
+      }
+
+      /// \brief Constructor to get invalid iterator
+      ///
+      /// Constructor to get invalid iterator
+      ItemIt(Invalid) : unionFind(0), idx(-1) {}
+      
+      /// \brief Increment operator
+      ///
+      /// It steps to the next item in the class.
+      ItemIt& operator++() {
+        idx = unionFind->items[idx].next;
+        if (idx == fdx) idx = -1;
+        return *this;
+      }
+      
+      /// \brief Conversion operator
+      ///
+      /// It converts the iterator to the current item.
+      operator const Item&() const {
+        return unionFind->items[idx].item;
+      }
+
+      /// \brief Equality operator
+      ///
+      /// Equality operator
+      bool operator==(const ItemIt& i) { 
+        return i.idx == idx;
+      }
+
+      /// \brief Inequality operator
+      ///
+      /// Inequality operator
+      bool operator!=(const ItemIt& i) { 
+        return i.idx != idx;
+      }
+      
+    private:
+      const UnionFindEnum* unionFind;
+      int idx, fdx;
+    };
+
+  };
+
+  /// \ingroup auxdat
+  ///
+  /// \brief A \e Extend-Find data structure implementation which
+  /// is able to enumerate the components.
+  ///
+  /// The class implements an \e Extend-Find data structure which is
+  /// able to enumerate the components and the items in a
+  /// component. The data structure is a simplification of the
+  /// Union-Find structure, and it does not allow to merge two components.
+  ///
+  /// \pre You need to add all the elements by the \ref insert()
+  /// method.
+  template <typename _ItemIntMap>
+  class ExtendFindEnum {
+  public:
+    
+    typedef _ItemIntMap ItemIntMap;
+    typedef typename ItemIntMap::Key Item;
+
+  private:
+    
+    ItemIntMap& index;
+
+    struct ItemT {
+      int cls;
+      Item item;
+      int next, prev;
+    };
+
+    std::vector<ItemT> items;
+    int firstFreeItem;
+
+    struct ClassT {
+      int firstItem;
+      int next, prev;
+    };
+
+    std::vector<ClassT> classes;
+
+    int firstClass, firstFreeClass;
+
+    int newClass() {
+      if (firstFreeClass != -1) {
+	int cdx = firstFreeClass;
+	firstFreeClass = classes[cdx].next;
+	return cdx;
+      } else {
+	classes.push_back(ClassT());
+	return classes.size() - 1;
+      }
+    }
+
+    int newItem() {
+      if (firstFreeItem != -1) {
+	int idx = firstFreeItem;
+	firstFreeItem = items[idx].next;
+	return idx;
+      } else {
+	items.push_back(ItemT());
+	return items.size() - 1;
+      }
+    }
+
+  public:
+
+    /// \brief Constructor
+    ExtendFindEnum(ItemIntMap& _index) 
+      : index(_index), items(), firstFreeItem(-1), 
+	classes(), firstClass(-1), firstFreeClass(-1) {}
+    
+    /// \brief Inserts the given element into a new component.
+    ///
+    /// This method creates a new component consisting only of the
+    /// given element.
+    int insert(const Item& item) {
+      int cdx = newClass();
+      classes[cdx].prev = -1;
+      classes[cdx].next = firstClass;
+      if (firstClass != -1) {
+	classes[firstClass].prev = cdx;
+      }
+      firstClass = cdx;
+      
+      int idx = newItem();
+      items[idx].item = item;
+      items[idx].cls = cdx;
+      items[idx].prev = idx;
+      items[idx].next = idx;
+
+      classes[cdx].firstItem = idx;
+
+      index.set(item, idx);
+      
+      return cdx;
+    }
+
+    /// \brief Inserts the given element into the given component.
+    ///
+    /// This methods inserts the element \e item a into the \e cls class.
+    void insert(const Item& item, int cls) {
+      int idx = newItem();
+      int rdx = classes[cls].firstItem;
+      items[idx].item = item;
+      items[idx].cls = cls;
+
+      items[idx].prev = rdx;
+      items[idx].next = items[rdx].next;
+      items[items[rdx].next].prev = idx;
+      items[rdx].next = idx;
+
+      index.set(item, idx);
+    }
+
+    /// \brief Clears the union-find data structure
+    ///
+    /// Erase each item from the data structure.
+    void clear() {
+      items.clear();
+      classes.clear;
+      firstClass = firstFreeClass = firstFreeItem = -1;
+    }
+
+    /// \brief Gives back the class of the \e item.
+    ///
+    /// Gives back the class of the \e item.
+    int find(const Item &item) const {
+      return items[index[item]].cls;
+    }
+
+    /// \brief Gives back a representant item of the component.
+    ///
+    /// Gives back a representant item of the component.
+    Item item(int cls) const {
+      return items[classes[cls].firstItem].item;
+    }
+    
+    /// \brief Removes the given element from the structure.
+    ///
+    /// Removes the element from its component and if the component becomes
+    /// empty then removes that component from the component list.
+    ///
+    /// \warning It is an error to remove an element which is not in
+    /// the structure.
+    void erase(const Item &item) {
+      int idx = index[item];
+      int cdx = items[idx].cls;
+      
+      if (idx == items[idx].next) {
+	if (classes[cdx].prev != -1) {
+	  classes[classes[cdx].prev].next = classes[cdx].next; 
+	} else {
+	  firstClass = classes[cdx].next;
+	}
+	if (classes[cdx].next != -1) {
+	  classes[classes[cdx].next].prev = classes[cdx].prev; 
+	}
+	classes[cdx].next = firstFreeClass;
+	firstFreeClass = cdx;
+      } else {
+	classes[cdx].firstItem = items[idx].next;
+	items[items[idx].next].prev = items[idx].prev;
+	items[items[idx].prev].next = items[idx].next;
+      }
+      items[idx].next = firstFreeItem;
+      firstFreeItem = idx;
+	
+    }    
+
+    
+    /// \brief Removes the component of the given element from the structure.
+    ///
+    /// Removes the component of the given element from the structure.
+    ///
+    /// \warning It is an error to give an element which is not in the
+    /// structure.
+    void eraseClass(int cdx) {
+      int idx = classes[cdx].firstItem;
+      items[items[idx].prev].next = firstFreeItem;
+      firstFreeItem = idx;
+
+      if (classes[cdx].prev != -1) {
+	classes[classes[cdx].prev].next = classes[cdx].next; 
+      } else {
+	firstClass = classes[cdx].next;
+      }
+      if (classes[cdx].next != -1) {
+	classes[classes[cdx].next].prev = classes[cdx].prev; 
+      }
+      classes[cdx].next = firstFreeClass;
+      firstFreeClass = cdx;
+    }
+
+    /// \brief Lemon style iterator for the classes.
+    ///
+    /// ClassIt is a lemon style iterator for the components. It iterates
+    /// on the ids of classes.
+    class ClassIt {
+    public:
+      /// \brief Constructor of the iterator
+      ///
+      /// Constructor of the iterator
+      ClassIt(const ExtendFindEnum& ufe) : extendFind(&ufe) {
+        cdx = extendFind->firstClass;
+      }
+
+      /// \brief Constructor to get invalid iterator
+      ///
+      /// Constructor to get invalid iterator
+      ClassIt(Invalid) : extendFind(0), cdx(-1) {}
+      
+      /// \brief Increment operator
+      ///
+      /// It steps to the next representant item.
+      ClassIt& operator++() {
+        cdx = extendFind->classes[cdx].next;
+        return *this;
+      }
+      
+      /// \brief Conversion operator
+      ///
+      /// It converts the iterator to the current class id.
+      operator int() const {
+        return cdx;
+      }
+
+      /// \brief Equality operator
+      ///
+      /// Equality operator
+      bool operator==(const ClassIt& i) { 
+        return i.cdx == cdx;
+      }
+
+      /// \brief Inequality operator
+      ///
+      /// Inequality operator
+      bool operator!=(const ClassIt& i) { 
+        return i.cdx != cdx;
+      }
+      
+    private:
+      const ExtendFindEnum* extendFind;
+      int cdx;
+    };
+
+    /// \brief Lemon style iterator for the items of a component.
+    ///
+    /// ClassIt is a lemon style iterator for the components. It iterates
+    /// on the items of a class. By example if you want to iterate on
+    /// each items of each classes then you may write the next code.
+    ///\code
+    /// for (ClassIt cit(ufe); cit != INVALID; ++cit) {
+    ///   std::cout << "Class: ";
+    ///   for (ItemIt iit(ufe, cit); iit != INVALID; ++iit) {
+    ///     std::cout << toString(iit) << ' ' << std::endl;
+    ///   }
+    ///   std::cout << std::endl;
+    /// }
+    ///\endcode
+    class ItemIt {
+    public:
+      /// \brief Constructor of the iterator
+      ///
+      /// Constructor of the iterator. The iterator iterates
+      /// on the class of the \c item.
+      ItemIt(const ExtendFindEnum& ufe, int cls) : extendFind(&ufe) {
+        fdx = idx = extendFind->classes[cls].firstItem;
+      }
+
+      /// \brief Constructor to get invalid iterator
+      ///
+      /// Constructor to get invalid iterator
+      ItemIt(Invalid) : extendFind(0), idx(-1) {}
+      
+      /// \brief Increment operator
+      ///
+      /// It steps to the next item in the class.
+      ItemIt& operator++() {
+        idx = extendFind->items[idx].next;
+	if (fdx == idx) idx = -1;
+        return *this;
+      }
+      
+      /// \brief Conversion operator
+      ///
+      /// It converts the iterator to the current item.
+      operator const Item&() const {
+        return extendFind->items[idx].item;
+      }
+
+      /// \brief Equality operator
+      ///
+      /// Equality operator
+      bool operator==(const ItemIt& i) { 
+        return i.idx == idx;
+      }
+
+      /// \brief Inequality operator
+      ///
+      /// Inequality operator
+      bool operator!=(const ItemIt& i) { 
+        return i.idx != idx;
+      }
+      
+    private:
+      const ExtendFindEnum* extendFind;
+      int idx, fdx;
+    };
+
+  };
+
+  /// \ingroup auxdat
+  ///
+  /// \brief A \e Union-Find data structure implementation which
+  /// is able to store a priority for each item and retrieve the minimum of
+  /// each class.
+  ///
+  /// A \e Union-Find data structure implementation which is able to
+  /// store a priority for each item and retrieve the minimum of each
+  /// class. In addition, it supports the joining and splitting the
+  /// components. If you don't need this feature then you makes
+  /// better to use the \ref UnionFind class which is more efficient.
+  ///
+  /// The union-find data strcuture based on a (2, 16)-tree with a
+  /// tournament minimum selection on the internal nodes. The insert
+  /// operation takes O(1), the find, set, decrease and increase takes
+  /// O(log(n)), where n is the number of nodes in the current
+  /// component.  The complexity of join and split is O(log(n)*k),
+  /// where n is the sum of the number of the nodes and k is the
+  /// number of joined components or the number of the components
+  /// after the split.
+  ///
+  /// \pre You need to add all the elements by the \ref insert()
+  /// method.
+  ///
+  template <typename _Value, typename _ItemIntMap, 
+            typename _Comp = std::less<_Value> >
+  class HeapUnionFind {
+  public:
+    
+    typedef _Value Value;
+    typedef typename _ItemIntMap::Key Item;
+
+    typedef _ItemIntMap ItemIntMap;
+
+    typedef _Comp Comp;
+
+  private:
+
+    static const int cmax = 16;
+
+    ItemIntMap& index;
+
+    struct ClassNode {
+      int parent;
+      int depth;
+
+      int left, right;
+      int next, prev;
+    };
+
+    int first_class;
+    int first_free_class;
+    std::vector<ClassNode> classes;
+
+    int newClass() {
+      if (first_free_class < 0) {
+        int id = classes.size();
+        classes.push_back(ClassNode());
+        return id;
+      } else {
+        int id = first_free_class;
+        first_free_class = classes[id].next;
+        return id;
+      }
+    }
+
+    void deleteClass(int id) {
+      classes[id].next = first_free_class;
+      first_free_class = id;
+    }
+
+    struct ItemNode {
+      int parent;
+      Item item;
+      Value prio;
+      int next, prev;
+      int left, right;
+      int size;
+    };
+
+    int first_free_node;
+    std::vector<ItemNode> nodes;
+
+    int newNode() {
+      if (first_free_node < 0) {
+        int id = nodes.size();
+        nodes.push_back(ItemNode());
+        return id;
+      } else {
+        int id = first_free_node;
+        first_free_node = nodes[id].next;
+        return id;
+      }
+    }
+
+    void deleteNode(int id) {
+      nodes[id].next = first_free_node;
+      first_free_node = id;
+    }
+
+    Comp comp;
+
+    int findClass(int id) const {
+      int kd = id;
+      while (kd >= 0) {
+        kd = nodes[kd].parent;
+      }
+      return ~kd;
+    }
+
+    int leftNode(int id) const {
+      int kd = ~(classes[id].parent);
+      for (int i = 0; i < classes[id].depth; ++i) {
+        kd = nodes[kd].left;
+      }
+      return kd;
+    }
+
+    int nextNode(int id) const {
+      int depth = 0;
+      while (id >= 0 && nodes[id].next == -1) {
+        id = nodes[id].parent;
+        ++depth;
+      }
+      if (id < 0) {
+        return -1;
+      }
+      id = nodes[id].next;
+      while (depth--) {
+        id = nodes[id].left;      
+      }
+      return id;
+    }
+
+
+    void setPrio(int id) {
+      int jd = nodes[id].left;
+      nodes[id].prio = nodes[jd].prio;
+      nodes[id].item = nodes[jd].item;
+      jd = nodes[jd].next;
+      while (jd != -1) {
+        if (comp(nodes[jd].prio, nodes[id].prio)) {
+          nodes[id].prio = nodes[jd].prio;
+          nodes[id].item = nodes[jd].item;
+        }
+        jd = nodes[jd].next;
+      }
+    }
+
+    void push(int id, int jd) {
+      nodes[id].size = 1;
+      nodes[id].left = nodes[id].right = jd;
+      nodes[jd].next = nodes[jd].prev = -1;
+      nodes[jd].parent = id;
+    }
+
+    void pushAfter(int id, int jd) {
+      int kd = nodes[id].parent;
+      if (nodes[id].next != -1) {
+        nodes[nodes[id].next].prev = jd;
+        if (kd >= 0) {
+          nodes[kd].size += 1;
+        }
+      } else {
+        if (kd >= 0) {
+          nodes[kd].right = jd;
+          nodes[kd].size += 1;
+        }
+      }
+      nodes[jd].next = nodes[id].next;
+      nodes[jd].prev = id;
+      nodes[id].next = jd;
+      nodes[jd].parent = kd;
+    }
+
+    void pushRight(int id, int jd) {
+      nodes[id].size += 1;
+      nodes[jd].prev = nodes[id].right;
+      nodes[jd].next = -1;
+      nodes[nodes[id].right].next = jd;
+      nodes[id].right = jd;
+      nodes[jd].parent = id;
+    }
+
+    void popRight(int id) {
+      nodes[id].size -= 1;
+      int jd = nodes[id].right;
+      nodes[nodes[jd].prev].next = -1;
+      nodes[id].right = nodes[jd].prev;
+    }
+
+    void splice(int id, int jd) {
+      nodes[id].size += nodes[jd].size;
+      nodes[nodes[id].right].next = nodes[jd].left;
+      nodes[nodes[jd].left].prev = nodes[id].right;
+      int kd = nodes[jd].left;
+      while (kd != -1) {
+        nodes[kd].parent = id;
+        kd = nodes[kd].next;
+      }
+      nodes[id].right = nodes[jd].right;
+    }
+
+    void split(int id, int jd) {
+      int kd = nodes[id].parent;
+      nodes[kd].right = nodes[id].prev;
+      nodes[nodes[id].prev].next = -1;
+      
+      nodes[jd].left = id;
+      nodes[id].prev = -1;
+      int num = 0;
+      while (id != -1) {
+        nodes[id].parent = jd;
+        nodes[jd].right = id;
+        id = nodes[id].next;
+        ++num;
+      }      
+      nodes[kd].size -= num;
+      nodes[jd].size = num;
+    }
+
+    void pushLeft(int id, int jd) {
+      nodes[id].size += 1;
+      nodes[jd].next = nodes[id].left;
+      nodes[jd].prev = -1;
+      nodes[nodes[id].left].prev = jd;
+      nodes[id].left = jd;
+      nodes[jd].parent = id;
+    }
+
+    void popLeft(int id) {
+      nodes[id].size -= 1;
+      int jd = nodes[id].left;
+      nodes[nodes[jd].next].prev = -1;
+      nodes[id].left = nodes[jd].next;
+    }
+
+    void repairLeft(int id) {
+      int jd = ~(classes[id].parent);
+      while (nodes[jd].left != -1) {
+	int kd = nodes[jd].left;
+	if (nodes[jd].size == 1) {
+	  if (nodes[jd].parent < 0) {
+	    classes[id].parent = ~kd;
+	    classes[id].depth -= 1;
+	    nodes[kd].parent = ~id;
+	    deleteNode(jd);
+	    jd = kd;
+	  } else {
+	    int pd = nodes[jd].parent;
+	    if (nodes[nodes[jd].next].size < cmax) {
+	      pushLeft(nodes[jd].next, nodes[jd].left);
+              if (less(jd, nodes[jd].next) ||
+		  nodes[jd].item == nodes[pd].item) {
+                nodes[nodes[jd].next].prio = nodes[jd].prio;
+                nodes[nodes[jd].next].item = nodes[jd].item;
+	      }
+	      popLeft(pd);
+	      deleteNode(jd);
+	      jd = pd;
+	    } else {
+	      int ld = nodes[nodes[jd].next].left;
+	      popLeft(nodes[jd].next);
+	      pushRight(jd, ld);
+              if (less(ld, nodes[jd].left) || 
+                  nodes[ld].item == nodes[pd].item) {
+		nodes[jd].item = nodes[ld].item;
+		nodes[jd].prio = nodes[ld].prio;
+	      }
+	      if (nodes[nodes[jd].next].item == nodes[ld].item) {
+		setPrio(nodes[jd].next);
+	      }
+	      jd = nodes[jd].left;
+	    }
+	  }
+	} else {
+	  jd = nodes[jd].left;
+	}
+      }
+    }    
+
+    void repairRight(int id) {
+      int jd = ~(classes[id].parent);
+      while (nodes[jd].right != -1) {
+	int kd = nodes[jd].right;
+	if (nodes[jd].size == 1) {
+	  if (nodes[jd].parent < 0) {
+	    classes[id].parent = ~kd;
+	    classes[id].depth -= 1;
+	    nodes[kd].parent = ~id;
+	    deleteNode(jd);
+	    jd = kd;
+	  } else {
+	    int pd = nodes[jd].parent;
+	    if (nodes[nodes[jd].prev].size < cmax) {
+	      pushRight(nodes[jd].prev, nodes[jd].right);
+              if (less(jd, nodes[jd].prev) ||
+		  nodes[jd].item == nodes[pd].item) {
+                nodes[nodes[jd].prev].prio = nodes[jd].prio;
+                nodes[nodes[jd].prev].item = nodes[jd].item;
+	      }
+	      popRight(pd);
+	      deleteNode(jd);
+	      jd = pd;
+	    } else {
+	      int ld = nodes[nodes[jd].prev].right;
+	      popRight(nodes[jd].prev);
+	      pushLeft(jd, ld);
+              if (less(ld, nodes[jd].right) ||
+                  nodes[ld].item == nodes[pd].item) {
+		nodes[jd].item = nodes[ld].item;
+		nodes[jd].prio = nodes[ld].prio;
+	      }
+	      if (nodes[nodes[jd].prev].item == nodes[ld].item) {
+		setPrio(nodes[jd].prev);
+	      }
+	      jd = nodes[jd].right;
+	    }
+	  }
+	} else {
+	  jd = nodes[jd].right;
+	}
+      }
+    }
+
+
+    bool less(int id, int jd) const {
+      return comp(nodes[id].prio, nodes[jd].prio);
+    }
+
+    bool equal(int id, int jd) const {
+      return !less(id, jd) && !less(jd, id);
+    }
+
+
+  public:
+
+    /// \brief Returns true when the given class is alive.
+    ///
+    /// Returns true when the given class is alive, ie. the class is
+    /// not nested into other class.
+    bool alive(int cls) const {
+      return classes[cls].parent < 0;
+    }
+
+    /// \brief Returns true when the given class is trivial.
+    ///
+    /// Returns true when the given class is trivial, ie. the class
+    /// contains just one item directly.
+    bool trivial(int cls) const {
+      return classes[cls].left == -1;
+    }
+
+    /// \brief Constructs the union-find.
+    ///
+    /// Constructs the union-find.  
+    /// \brief _index The index map of the union-find. The data
+    /// structure uses internally for store references.
+    HeapUnionFind(ItemIntMap& _index) 
+      : index(_index), first_class(-1), 
+	first_free_class(-1), first_free_node(-1) {}
+
+    /// \brief Insert a new node into a new component.
+    ///
+    /// Insert a new node into a new component.
+    /// \param item The item of the new node.
+    /// \param prio The priority of the new node.
+    /// \return The class id of the one-item-heap.
+    int insert(const Item& item, const Value& prio) {
+      int id = newNode();
+      nodes[id].item = item;
+      nodes[id].prio = prio;
+      nodes[id].size = 0;
+
+      nodes[id].prev = -1;
+      nodes[id].next = -1;
+
+      nodes[id].left = -1;
+      nodes[id].right = -1;
+
+      nodes[id].item = item;
+      index[item] = id;
+      
+      int class_id = newClass();
+      classes[class_id].parent = ~id;
+      classes[class_id].depth = 0;
+
+      classes[class_id].left = -1;
+      classes[class_id].right = -1;
+      
+      if (first_class != -1) {
+        classes[first_class].prev = class_id;
+      }
+      classes[class_id].next = first_class;
+      classes[class_id].prev = -1;
+      first_class = class_id;
+
+      nodes[id].parent = ~class_id;
+      
+      return class_id;
+    }
+
+    /// \brief The class of the item.
+    ///
+    /// \return The alive class id of the item, which is not nested into
+    /// other classes.
+    ///
+    /// The time complexity is O(log(n)).
+    int find(const Item& item) const {
+      return findClass(index[item]);
+    }
+    
+    /// \brief Joins the classes.
+    ///
+    /// The current function joins the given classes. The parameter is
+    /// an STL range which should be contains valid class ids. The
+    /// time complexity is O(log(n)*k) where n is the overall number
+    /// of the joined nodes and k is the number of classes.
+    /// \return The class of the joined classes.
+    /// \pre The range should contain at least two class ids.
+    template <typename Iterator>
+    int join(Iterator begin, Iterator end) {
+      std::vector<int> cs;
+      for (Iterator it = begin; it != end; ++it) {
+        cs.push_back(*it);
+      }
+
+      int class_id = newClass();
+      { // creation union-find
+
+        if (first_class != -1) {
+          classes[first_class].prev = class_id;
+        }
+        classes[class_id].next = first_class;
+        classes[class_id].prev = -1;
+        first_class = class_id;
+
+        classes[class_id].depth = classes[cs[0]].depth;
+        classes[class_id].parent = classes[cs[0]].parent;
+        nodes[~(classes[class_id].parent)].parent = ~class_id;
+
+        int l = cs[0];
+
+        classes[class_id].left = l;
+        classes[class_id].right = l;
+
+        if (classes[l].next != -1) {
+          classes[classes[l].next].prev = classes[l].prev;
+        }
+        classes[classes[l].prev].next = classes[l].next;
+        
+        classes[l].prev = -1;
+        classes[l].next = -1;
+
+        classes[l].depth = leftNode(l);
+        classes[l].parent = class_id;
+        
+      }
+
+      { // merging of heap
+        int l = class_id;
+        for (int ci = 1; ci < int(cs.size()); ++ci) {
+          int r = cs[ci];
+          int rln = leftNode(r);
+          if (classes[l].depth > classes[r].depth) {
+            int id = ~(classes[l].parent);
+            for (int i = classes[r].depth + 1; i < classes[l].depth; ++i) {
+              id = nodes[id].right;
+            }
+            while (id >= 0 && nodes[id].size == cmax) {
+              int new_id = newNode();
+              int right_id = nodes[id].right;
+
+              popRight(id);
+              if (nodes[id].item == nodes[right_id].item) {
+                setPrio(id);
+              }
+              push(new_id, right_id);
+              pushRight(new_id, ~(classes[r].parent));
+
+              if (less(~classes[r].parent, right_id)) {
+                nodes[new_id].item = nodes[~classes[r].parent].item;
+                nodes[new_id].prio = nodes[~classes[r].parent].prio;
+              } else {
+                nodes[new_id].item = nodes[right_id].item;
+                nodes[new_id].prio = nodes[right_id].prio;
+              }
+
+              id = nodes[id].parent;
+              classes[r].parent = ~new_id;
+            }
+            if (id < 0) {
+              int new_parent = newNode();
+              nodes[new_parent].next = -1;
+              nodes[new_parent].prev = -1;
+              nodes[new_parent].parent = ~l;
+
+              push(new_parent, ~(classes[l].parent));
+              pushRight(new_parent, ~(classes[r].parent));
+              setPrio(new_parent);
+
+              classes[l].parent = ~new_parent;
+              classes[l].depth += 1;
+            } else {
+              pushRight(id, ~(classes[r].parent));
+              while (id >= 0 && less(~(classes[r].parent), id)) {
+                nodes[id].prio = nodes[~(classes[r].parent)].prio;
+                nodes[id].item = nodes[~(classes[r].parent)].item;
+                id = nodes[id].parent;
+              }
+            }
+          } else if (classes[r].depth > classes[l].depth) {
+            int id = ~(classes[r].parent);
+            for (int i = classes[l].depth + 1; i < classes[r].depth; ++i) {
+              id = nodes[id].left;
+            }
+            while (id >= 0 && nodes[id].size == cmax) {
+              int new_id = newNode();
+              int left_id = nodes[id].left;
+
+              popLeft(id);
+              if (nodes[id].prio == nodes[left_id].prio) {
+                setPrio(id);
+              }
+              push(new_id, left_id);
+              pushLeft(new_id, ~(classes[l].parent));
+
+              if (less(~classes[l].parent, left_id)) {
+                nodes[new_id].item = nodes[~classes[l].parent].item;
+                nodes[new_id].prio = nodes[~classes[l].parent].prio;
+              } else {
+                nodes[new_id].item = nodes[left_id].item;
+                nodes[new_id].prio = nodes[left_id].prio;
+              }
+
+              id = nodes[id].parent;
+              classes[l].parent = ~new_id;
+
+            }
+            if (id < 0) {
+              int new_parent = newNode();
+              nodes[new_parent].next = -1;
+              nodes[new_parent].prev = -1;
+              nodes[new_parent].parent = ~l;
+
+              push(new_parent, ~(classes[r].parent));
+              pushLeft(new_parent, ~(classes[l].parent));
+              setPrio(new_parent);
+              
+              classes[r].parent = ~new_parent;
+              classes[r].depth += 1;
+            } else {
+              pushLeft(id, ~(classes[l].parent));
+              while (id >= 0 && less(~(classes[l].parent), id)) {
+                nodes[id].prio = nodes[~(classes[l].parent)].prio;
+                nodes[id].item = nodes[~(classes[l].parent)].item;
+                id = nodes[id].parent;
+              }
+            }
+            nodes[~(classes[r].parent)].parent = ~l;
+            classes[l].parent = classes[r].parent;
+            classes[l].depth = classes[r].depth;
+          } else {
+            if (classes[l].depth != 0 && 
+                nodes[~(classes[l].parent)].size + 
+                nodes[~(classes[r].parent)].size <= cmax) {
+              splice(~(classes[l].parent), ~(classes[r].parent));
+              deleteNode(~(classes[r].parent));
+              if (less(~(classes[r].parent), ~(classes[l].parent))) {
+                nodes[~(classes[l].parent)].prio = 
+                  nodes[~(classes[r].parent)].prio;
+                nodes[~(classes[l].parent)].item = 
+                  nodes[~(classes[r].parent)].item;
+              }
+            } else {
+              int new_parent = newNode();
+              nodes[new_parent].next = nodes[new_parent].prev = -1;
+              push(new_parent, ~(classes[l].parent));
+              pushRight(new_parent, ~(classes[r].parent));
+              setPrio(new_parent);
+            
+              classes[l].parent = ~new_parent;
+              classes[l].depth += 1;
+              nodes[new_parent].parent = ~l;
+            }
+          }
+          if (classes[r].next != -1) {
+            classes[classes[r].next].prev = classes[r].prev;
+          }
+          classes[classes[r].prev].next = classes[r].next;
+
+          classes[r].prev = classes[l].right;
+          classes[classes[l].right].next = r;
+          classes[l].right = r;
+          classes[r].parent = l;
+
+          classes[r].next = -1;
+          classes[r].depth = rln;
+        }
+      }
+      return class_id;
+    }
+
+    /// \brief Split the class to subclasses.
+    ///
+    /// The current function splits the given class. The join, which
+    /// made the current class, stored a reference to the
+    /// subclasses. The \c splitClass() member restores the classes
+    /// and creates the heaps. The parameter is an STL output iterator
+    /// which will be filled with the subclass ids. The time
+    /// complexity is O(log(n)*k) where n is the overall number of
+    /// nodes in the splitted classes and k is the number of the
+    /// classes.
+    template <typename Iterator>
+    void split(int cls, Iterator out) {
+      std::vector<int> cs;
+      { // splitting union-find
+        int id = cls;
+        int l = classes[id].left;
+
+        classes[l].parent = classes[id].parent;
+        classes[l].depth = classes[id].depth;
+
+        nodes[~(classes[l].parent)].parent = ~l;
+
+        *out++ = l;
+
+        while (l != -1) {
+          cs.push_back(l);
+          l = classes[l].next;
+        }
+
+        classes[classes[id].right].next = first_class;
+        classes[first_class].prev = classes[id].right;
+        first_class = classes[id].left;
+        
+        if (classes[id].next != -1) {
+          classes[classes[id].next].prev = classes[id].prev;
+        }
+        classes[classes[id].prev].next = classes[id].next;
+        
+        deleteClass(id);
+      }
+
+      {
+        for (int i = 1; i < int(cs.size()); ++i) {
+          int l = classes[cs[i]].depth;
+          while (nodes[nodes[l].parent].left == l) {
+            l = nodes[l].parent;
+          }
+          int r = l;    
+          while (nodes[l].parent >= 0) {
+            l = nodes[l].parent;
+            int new_node = newNode();
+
+            nodes[new_node].prev = -1;
+            nodes[new_node].next = -1;
+
+            split(r, new_node);
+            pushAfter(l, new_node);
+            setPrio(l);
+            setPrio(new_node);
+            r = new_node;
+          }
+          classes[cs[i]].parent = ~r;
+          classes[cs[i]].depth = classes[~(nodes[l].parent)].depth;
+          nodes[r].parent = ~cs[i];
+
+          nodes[l].next = -1;
+          nodes[r].prev = -1;
+
+          repairRight(~(nodes[l].parent));
+          repairLeft(cs[i]);
+          
+          *out++ = cs[i];
+        }
+      }
+    }
+
+    /// \brief Gives back the priority of the current item.
+    ///
+    /// \return Gives back the priority of the current item.
+    const Value& operator[](const Item& item) const {
+      return nodes[index[item]].prio;
+    }
+
+    /// \brief Sets the priority of the current item.
+    ///
+    /// Sets the priority of the current item.
+    void set(const Item& item, const Value& prio) {
+      if (comp(prio, nodes[index[item]].prio)) {
+        decrease(item, prio);
+      } else if (!comp(prio, nodes[index[item]].prio)) {
+        increase(item, prio);
+      }
+    }
+      
+    /// \brief Increase the priority of the current item.
+    ///
+    /// Increase the priority of the current item.
+    void increase(const Item& item, const Value& prio) {
+      int id = index[item];
+      int kd = nodes[id].parent;
+      nodes[id].prio = prio;
+      while (kd >= 0 && nodes[kd].item == item) {
+        setPrio(kd);
+        kd = nodes[kd].parent;
+      }
+    }
+
+    /// \brief Increase the priority of the current item.
+    ///
+    /// Increase the priority of the current item.
+    void decrease(const Item& item, const Value& prio) {
+      int id = index[item];
+      int kd = nodes[id].parent;
+      nodes[id].prio = prio;
+      while (kd >= 0 && less(id, kd)) {
+        nodes[kd].prio = prio;
+        nodes[kd].item = item;
+        kd = nodes[kd].parent;
+      }
+    }
+    
+    /// \brief Gives back the minimum priority of the class.
+    ///
+    /// \return Gives back the minimum priority of the class.
+    const Value& classPrio(int cls) const {
+      return nodes[~(classes[cls].parent)].prio;
+    }
+
+    /// \brief Gives back the minimum priority item of the class.
+    ///
+    /// \return Gives back the minimum priority item of the class.
+    const Item& classTop(int cls) const {
+      return nodes[~(classes[cls].parent)].item;
+    }
+
+    /// \brief Gives back a representant item of the class.
+    /// 
+    /// The representant is indpendent from the priorities of the
+    /// items. 
+    /// \return Gives back a representant item of the class.
+    const Item& classRep(int id) const {
+      int parent = classes[id].parent;
+      return nodes[parent >= 0 ? classes[id].depth : leftNode(id)].item;
+    }
+
+    /// \brief Lemon style iterator for the items of a class.
+    ///
+    /// ClassIt is a lemon style iterator for the components. It iterates
+    /// on the items of a class. By example if you want to iterate on
+    /// each items of each classes then you may write the next code.
+    ///\code
+    /// for (ClassIt cit(huf); cit != INVALID; ++cit) {
+    ///   std::cout << "Class: ";
+    ///   for (ItemIt iit(huf, cit); iit != INVALID; ++iit) {
+    ///     std::cout << toString(iit) << ' ' << std::endl;
+    ///   }
+    ///   std::cout << std::endl;
+    /// }
+    ///\endcode
+    class ItemIt {
+    private:
+
+      const HeapUnionFind* _huf;
+      int _id, _lid;
+      
+    public:
+
+      /// \brief Default constructor 
+      ///
+      /// Default constructor 
+      ItemIt() {}
+
+      ItemIt(const HeapUnionFind& huf, int cls) : _huf(&huf) {
+        int id = cls;
+        int parent = _huf->classes[id].parent;
+        if (parent >= 0) {
+          _id = _huf->classes[id].depth;
+          if (_huf->classes[id].next != -1) {
+            _lid = _huf->classes[_huf->classes[id].next].depth;
+          } else {
+            _lid = -1;
+          }
+        } else {
+          _id = _huf->leftNode(id);
+          _lid = -1;
+        } 
+      }
+      
+      /// \brief Increment operator
+      ///
+      /// It steps to the next item in the class.
+      ItemIt& operator++() {
+        _id = _huf->nextNode(_id);
+        return *this;
+      }
+
+      /// \brief Conversion operator
+      ///
+      /// It converts the iterator to the current item.
+      operator const Item&() const {
+        return _huf->nodes[_id].item;
+      }
+      
+      /// \brief Equality operator
+      ///
+      /// Equality operator
+      bool operator==(const ItemIt& i) { 
+        return i._id == _id;
+      }
+
+      /// \brief Inequality operator
+      ///
+      /// Inequality operator
+      bool operator!=(const ItemIt& i) { 
+        return i._id != _id;
+      }
+
+      /// \brief Equality operator
+      ///
+      /// Equality operator
+      bool operator==(Invalid) { 
+        return _id == _lid;
+      }
+
+      /// \brief Inequality operator
+      ///
+      /// Inequality operator
+      bool operator!=(Invalid) { 
+        return _id != _lid;
+      }
+      
+    };
+
+    /// \brief Class iterator
+    ///
+    /// The iterator stores 
+    class ClassIt {
+    private:
+
+      const HeapUnionFind* _huf;
+      int _id;
+
+    public:
+
+      ClassIt(const HeapUnionFind& huf) 
+        : _huf(&huf), _id(huf.first_class) {}
+
+      ClassIt(const HeapUnionFind& huf, int cls) 
+        : _huf(&huf), _id(huf.classes[cls].left) {}
+
+      ClassIt(Invalid) : _huf(0), _id(-1) {}
+      
+      const ClassIt& operator++() {
+        _id = _huf->classes[_id].next;
+	return *this;
+      }
+
+      /// \brief Equality operator
+      ///
+      /// Equality operator
+      bool operator==(const ClassIt& i) { 
+        return i._id == _id;
+      }
+
+      /// \brief Inequality operator
+      ///
+      /// Inequality operator
+      bool operator!=(const ClassIt& i) { 
+        return i._id != _id;
+      }      
+      
+      operator int() const {
+	return _id;
+      }
+            
+    };
+
+  };
+
+  //! @}
+
+} //namespace lemon
+
+#endif //LEMON_UNION_FIND_H
Index: lemon/vmap.h
===================================================================
--- lemon/vmap.h	(revision 2553)
+++ lemon/vmap.h	(revision 2553)
@@ -0,0 +1,112 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_LIST_GRAPH_H
+#define LEMON_LIST_GRAPH_H
+
+///\ingroup graphs
+///\file
+///\brief Virtual map support.
+
+namespace lemon {
+
+  ///Base class of the virtual maps.
+  template<class K, class V>
+  class VMapBase 
+  {
+  public:
+    ///\e
+    typedef K Key;
+    ///\e
+    typedef V Value;
+    
+    ///\e
+    virtual Value operator[](const Key &) const { return Value();}
+    ///\e
+    virtual void set(const Key &,const Value &) {}
+  };
+  
+  ///Base class of the virtual reference maps.
+  template<class K, class V>
+  class VRefMapBase 
+  {
+  public:
+    ///\e
+    typedef K Key;
+    ///\e
+    typedef V Value;
+    
+    ///\e
+    virtual Value& operator[](Key &) = 0;
+    ///\e
+    virtual Value& operator[](const Key &) const = 0;
+    ///\e
+    virtual void set(const Key &,const Value &) = 0;
+  };
+  
+  ///Makes a virtual map from a \ref concepts::ReadMap "ReadMap"
+  template<class M, class K=typename M::Key,class V=typename M::Value>
+  class VReadMap : public VMapBase<K,V> 
+  {
+    const M &map;
+  public:
+  ///\e
+    VReadMap(const M &m) : map(m) {}
+    virtual Value operator[](const Key &k) const { return map[k];}
+  };
+
+  ///Function interface for \ref VReadMap.
+  template<class M, class K=typename M::Key,class V=typename M::Value>
+  vReadMap(const M& m) {return VReadMap<M,K,V>(m);}
+
+  ///Makes a virtual map from a \ref concepts::WriteMap "WriteMap"
+  template<class M, class K=typename M::Key,class V=typename M::Value>
+  class VWriteMap :public VMapBase<K,V> 
+  {
+    M &map;
+  public:
+    ///\e
+    VWriteMap(M &m) : map(m) {}
+    virtual void set(const Key &k,const Value &v) { map.set(k,v);}
+  };
+
+  ///Function interface for \ref VWriteMap.
+  template<class M, class K=typename M::Key,class V=typename M::Value>
+  vWriteMap(const M& m) {return VReadMap<M,K,V>(m);}
+
+  ///Makes a virtual map from a \ref concepts::ReadWriteMap "ReadWriteMap"
+  template<class M, class K=typename M::Key,class V=typename M::Value>
+  class VReadWriteMap :public VMapBase<K,V>
+  {
+    M &map;
+  public:
+    ///\e
+    VReadWriteMap(M &m) : map(m) {}
+    virtual Value operator[](const Key &k) const { return map[k];}
+    virtual void set(const Key &k,const Value &v) { map.set(k,v);}
+  };
+    
+  ///Function interface for \ref VReadWriteMap.
+  template<class M, class K=typename M::Key,class V=typename M::Value>
+  vReadWriteMap(const M& m) {return VReadMap<M,K,V>(m);}
+  
+  /// @}  
+} //namespace lemon
+  
+
+#endif
Index: m4/lx_check_cplex.m4
===================================================================
--- m4/lx_check_cplex.m4	(revision 2647)
+++ m4/lx_check_cplex.m4	(revision 2615)
@@ -47,5 +47,5 @@
       }
 
-      int main(int argc, char* argv[])
+      int main(int argc, char** argv)
       {
         CPXENVptr env = NULL;
Index: m4/lx_check_glpk.m4
===================================================================
--- m4/lx_check_glpk.m4	(revision 2647)
+++ m4/lx_check_glpk.m4	(revision 2615)
@@ -43,5 +43,5 @@
       }
 
-      int main(int argc, char* argv[])
+      int main(int argc, char** argv)
       {
         LPX *lp;
Index: m4/lx_check_soplex.m4
===================================================================
--- m4/lx_check_soplex.m4	(revision 2615)
+++ m4/lx_check_soplex.m4	(revision 2615)
@@ -0,0 +1,71 @@
+AC_DEFUN([LX_CHECK_SOPLEX],
+[
+  AC_ARG_WITH([soplex],
+AS_HELP_STRING([--with-soplex@<:@=PREFIX@:>@], [search for SOPLEX under PREFIX or under the default search paths if PREFIX is not given @<:@default@:>@])
+AS_HELP_STRING([--without-soplex], [disable checking for SOPLEX]),
+              [], [with_soplex=yes])
+
+  AC_ARG_WITH([soplex-includedir],
+AS_HELP_STRING([--with-soplex-includedir=DIR], [search for SOPLEX headers in DIR]),
+              [], [with_soplex_includedir=no])
+
+  AC_ARG_WITH([soplex-libdir],
+AS_HELP_STRING([--with-soplex-libdir=DIR], [search for SOPLEX libraries in DIR]),
+              [], [with_soplex_libdir=no])
+
+  lx_soplex_found=no
+  if test x"$with_soplex" != x"no"; then
+    AC_MSG_CHECKING([for SOPLEX])
+
+    if test x"$with_soplex_includedir" != x"no"; then
+      SOPLEX_CXXFLAGS="-I$with_soplex_includedir"
+    elif test x"$with_soplex" != x"yes"; then
+      SOPLEX_CXXFLAGS="-I$with_soplex/include"
+    fi
+
+    if test x"$with_soplex_libdir" != x"no"; then
+      SOPLEX_LDFLAGS="-L$with_soplex_libdir"
+    elif test x"$with_soplex" != x"yes"; then
+      SOPLEX_LDFLAGS="-L$with_soplex/lib"
+    fi
+    SOPLEX_LIBS="-lsoplex -lz"
+
+    lx_save_cxxflags="$CXXFLAGS"
+    lx_save_ldflags="$LDFLAGS"
+    lx_save_libs="$LIBS"
+    CXXFLAGS="$SOPLEX_CXXFLAGS"
+    LDFLAGS="$SOPLEX_LDFLAGS"
+    LIBS="$SOPLEX_LIBS"
+
+    lx_soplex_test_prog='
+      #include <soplex/soplex.h>
+
+      int main(int argc, char** argv)
+      {
+        soplex::SoPlex soplex;
+        return 0;
+      }'
+
+    AC_LANG_PUSH(C++)
+    AC_LINK_IFELSE([$lx_soplex_test_prog], [lx_soplex_found=yes], [lx_soplex_found=no])
+    AC_LANG_POP(C++)
+
+    CXXFLAGS="$lx_save_cxxflags"
+    LDFLAGS="$lx_save_ldflags"
+    LIBS="$lx_save_libs"
+
+    if test x"$lx_soplex_found" = x"yes"; then
+      AC_DEFINE([HAVE_SOPLEX], [1], [Define to 1 if you have SOPLEX.])
+      AC_MSG_RESULT([yes])
+    else
+      SOPLEX_CXXFLAGS=""
+      SOPLEX_LDFLAGS=""
+      SOPLEX_LIBS=""
+      AC_MSG_RESULT([no])
+    fi
+  fi
+  SOPLEX_LIBS="$SOPLEX_LDFLAGS $SOPLEX_LIBS"
+  AC_SUBST(SOPLEX_CXXFLAGS)
+  AC_SUBST(SOPLEX_LIBS)
+  AM_CONDITIONAL([HAVE_SOPLEX], [test x"$lx_soplex_found" = x"yes"])
+])
Index: scripts/DO-NOT-PLAY-WITH-release
===================================================================
--- scripts/DO-NOT-PLAY-WITH-release	(revision 1937)
+++ scripts/DO-NOT-PLAY-WITH-release	(revision 1937)
@@ -0,0 +1,1 @@
+
Index: scripts/autopackage-glpk
===================================================================
--- scripts/autopackage-glpk	(revision 2270)
+++ scripts/autopackage-glpk	(revision 2270)
@@ -0,0 +1,97 @@
+#!/bin/bash
+
+case $# in
+    1)
+	;;
+    *)
+	echo "Usage: autopackage-glpk tarfile"
+	;;	
+esac
+
+
+ORIGTAR=$1
+VERSION=`echo ${ORIGTAR/.tar.gz}|tr - ' '|awk '{print $(NF)}'`
+
+echo "GLPK VERSION: $VERSION"
+echo "     RELEASE: $RELEASE"
+
+
+set -e
+
+function make-dir () {
+    if [ ! -d $1 ]; then
+	mkdir $1
+    fi
+}
+
+tar xzf $ORIGTAR
+cd glpk-${VERSION}
+mkdir autopackage
+
+echo '# -*-shell-script-*-
+
+[Meta]
+RootName: @lemon.cs.elte.hu/lemon:$SOFTWAREVERSION
+DisplayName: GLPK
+ShortName: glpk
+Maintainer: The LEMON Developers - http://lemon.cs.elte.hu/
+Packager: Alpar Juttner <alpar@cs.elte.hu>
+Summary: GLPK LP/MIP solver
+
+SoftwareVersion: '${VERSION}'
+AutopackageTarget: 1.2
+
+# Only uncomment InterfaceVersion if your package exposes interfaces to other software,
+# for instance if it includes DSOs or python/perl modules. See the developer guide for more info,
+# or ask on autopackage-dev if you dont understand interface versioning in autopackage.
+#
+InterfaceVersion: '${VERSION}'
+
+PackageVersion: 1
+
+[Description]
+The GLPK package is a set of routines written in ANSI C and organized
+in the form of a callable library. This package is intended for solving
+large-scale linear programming (LP), mixed integer linear programming
+(MIP), and other related problems.
+
+The GLPK package includes the following main components:
+
+* implementation of the simplex method;
+* implementation of the primal-dual interior-point method;
+* implementation of the branch-and-bound method;
+* application program interface (API);
+* GNU MathProg modeling language (a subset of AMPL);
+* GLPSOL, a stand-alone LP/MIP solver.
+
+See GLPK webpage <http://www.gnu.org/software/glpk/glpk.html>.
+
+[BuildPrepare]
+prepareBuild
+
+[BuildUnprepare]
+unprepareBuild
+
+[Imports]
+echo '*' | import
+
+[Prepare]
+# Dependency checking
+#require @whatever.you/need 1.0
+
+[Install]
+# Put your installation script here
+#installExe bin/*
+copyFiles * $PREFIX
+
+[Uninstall]
+# Usually just the following line is enough to uninstall everything
+uninstallFromLog
+'>autopackage/default.apspec
+
+makeinstaller
+
+cp *.package *.meta ..
+cd ..
+
+rm -rf glpk-${VERSION}
Index: scripts/check-compilers
===================================================================
--- scripts/check-compilers	(revision 2279)
+++ scripts/check-compilers	(revision 2279)
@@ -0,0 +1,71 @@
+#!/bin/bash
+
+set -e
+
+function make-dir () {
+    if [ ! -d $1 ]; then
+	mkdir $1
+    fi
+}
+
+make-dir check-compilers-dir
+cd check-compilers-dir
+
+svn co https://hugo.cs.elte.hu/svn/hugo/trunk ||
+(echo '*************************************************************';
+echo '   REPOSITORY CANNOT BE UPDATED'
+echo '*************************************************************')
+
+
+VERSION=r`svn info trunk|grep 'Revision:'|cut -d ' ' -f 2`
+NAME=lemon
+DISTNAME=${NAME}-$VERSION
+TARNAME=${DISTNAME}.tar.gz
+
+function makecheck () {
+    if [ `which $(echo $CXX|cut -f1 -d' ' )` ]; then
+	make-dir $ODIR
+	cd $ODIR
+	time ../trunk/configure $*
+	time make check
+	cd ..
+    else
+	echo
+	echo '***************************************************************'
+	echo "  COMPILER $CXX CANNOT BE FOUND"
+	echo '***************************************************************'
+	echo
+    fi
+}
+
+# CREATE TARBALL
+
+cd trunk
+#./bootstrap --amver=1.7
+autoreconf -vi
+cd ..
+
+# CHECK COMPILERS
+
+ODIR=gcc-3.3 CXX=g++-3.3 CXXFLAGS='-W -Wall -Werror' makecheck --enable-demo --enable-benchmark
+
+ODIR=gcc-3.4 CXX=g++-3.4 CXXFLAGS='-W -Wall -Werror' makecheck --enable-demo --enable-benchmark
+
+ODIR=gcc-4.0 CXX=g++-4.0 CXXFLAGS='-W -Wall -Werror' makecheck --enable-demo --enable-benchmark
+
+ODIR=gcc-4.1 CXX=g++-4.1 CXXFLAGS='-W -Wall -Werror' makecheck --enable-demo --enable-benchmark
+
+# # ODIR=icc-8.0 CXX=icpc-8.0 CXXFLAGS='-Werror' makecheck --enable-demo --enable-benchmark
+
+# ODIR=icc-9.0 CXX='icpc-9.0' CXXFLAGS='-Werror' makecheck --enable-demo --enable-benchmark
+
+# ODIR=mingw CXX='g++' makecheck --with-msw --target=i586-mingw32msvc --host=i586-mingw32msvc --build=i386-linux --without-glpk
+
+
+
+
+echo
+echo '**********************************************************************'
+echo '   REPOSITORY SEEMS OK'
+echo '**********************************************************************'
+echo
Index: scripts/check-tarball-integrity
===================================================================
--- scripts/check-tarball-integrity	(revision 1937)
+++ scripts/check-tarball-integrity	(revision 1937)
@@ -0,0 +1,51 @@
+#!/bin/bash
+
+set -e
+
+function make-dir () {
+    if [ ! -d $1 ]; then
+	mkdir $1
+    fi
+}
+
+rm -rf check-tarball-integrity-dir
+make-dir check-tarball-integrity-dir
+cd check-tarball-integrity-dir
+
+svn co https://hugo.cs.elte.hu/svn/hugo/trunk
+
+VERSION=r`svn info trunk|grep 'Revision:'|cut -d ' ' -f 2`
+NAME=lemon
+DISTNAME=${NAME}-$VERSION
+TARNAME=${DISTNAME}.tar.gz
+
+function makecheck () {
+make-dir $ODIR
+cd $ODIR
+time ../$DISTNAME/configure $*
+time make check
+cd ..
+}
+
+# CREATE TARBALL
+
+cd trunk
+./bootstrap --amver=1.7
+./configure CXXFLAGS='-W -Wall -Werror' --enable-gui --enable-demo --enable-benchmark
+make doc
+make
+make VERSION=${VERSION} distcheck
+
+cd ..
+
+tar xf trunk/$TARNAME
+
+# CHECK COMPILERS
+
+ODIR=obj-dir CXXFLAGS='-W -Wall -Werror' makecheck --enable-gui --enable-demo --enable-benchmark
+
+echo
+echo '**********************************************************************'
+echo '   REPOSITORY SEEMS OK'
+echo '**********************************************************************'
+echo
Index: scripts/make-snapshot
===================================================================
--- scripts/make-snapshot	(revision 1937)
+++ scripts/make-snapshot	(revision 1937)
@@ -0,0 +1,3 @@
+#!/bin/bash
+
+make VERSION=r`svn info|grep 'Revision:'|cut -d ' ' -f 2` $*
Index: scripts/release
===================================================================
--- scripts/release	(revision 2567)
+++ scripts/release	(revision 2567)
@@ -0,0 +1,84 @@
+#!/bin/bash
+
+# THE FIRST PARAMETER IS THE VERSION STRING
+
+if [ $# != 1 ]; then
+    echo
+    echo 'Usage: release version-string'
+    echo 
+    echo "WARNING: This script modifies the repository, so don't use it unless"
+    echo '         you really want to make a release'
+    exit 1
+fi
+
+set -e
+
+function make-dir () {
+    if [ ! -d $1 ]; then
+	mkdir $1
+    fi
+}
+
+VERSION=$1
+PKGNAME='lemon'
+VERSION_STRING='svnhead'
+
+make-dir release-dir
+cd release-dir
+
+echo
+echo '**********************************************************************'
+echo '   CHECK OUT'
+echo '**********************************************************************'
+echo
+
+rm -rf trunk
+svn co https://lemon.cs.elte.hu/svn/lemon/trunk
+# svn lock https://lemon.cs.elte.hu/svn/lemon/trunk
+
+cd trunk
+
+echo
+echo '**********************************************************************'
+echo "   CHANGE THE VERSION TO ${VERSION}"
+echo '**********************************************************************'
+echo
+
+sed "s/${VERSION_STRING}/${VERSION}/" <configure.ac >configure.ac.tmp
+mv configure.ac.tmp configure.ac
+
+echo
+echo '**********************************************************************'
+echo '   CREATE TARBALL'
+echo '**********************************************************************'
+echo
+
+#./bootstrap --amver=1.7
+autoreconf -vi
+./configure CXXFLAGS='-g -O2 -W -Wall -Werror' --enable-gui --enable-demo --enable-benchmark
+make doc
+make distcheck 
+
+cd ..
+
+echo
+echo '**********************************************************************'
+echo '   CREATE THE OTHER TAR FILES'
+echo '**********************************************************************'
+echo
+
+mv trunk/${PKGNAME}-${VERSION}.tar.gz .
+tar xzf ${PKGNAME}-${VERSION}.tar.gz
+mv ${PKGNAME}-${VERSION}/doc/html ./${PKGNAME}-doc-${VERSION}
+tar czf ${PKGNAME}-doc-${VERSION}.tar.gz ${PKGNAME}-doc-${VERSION}
+tar czf ${PKGNAME}-${VERSION}-nodoc.tar.gz ${PKGNAME}-${VERSION}
+rm -rf ${PKGNAME}-${VERSION} ${PKGNAME}-doc-${VERSION}
+
+echo
+echo '**********************************************************************'
+echo '   CREATE SVN TAG'
+echo '**********************************************************************'
+echo
+
+svn cp trunk https://lemon.cs.elte.hu/svn/lemon/tags/${PKGNAME}-${VERSION} -m "Version ${VERSION} released."
+# svn unlock https://lemon.cs.elte.hu/svn/lemon/trunk
Index: scripts/rename-graphs
===================================================================
--- scripts/rename-graphs	(revision 2560)
+++ scripts/rename-graphs	(revision 2560)
@@ -0,0 +1,45 @@
+#!/bin/bash
+
+ID=$RANDOM
+
+cat $1 | \
+sed -e "s/bipartite undirected graph/bipartite graph/g"\
+	-e "s/undirected graph/_gr_aph_label_/g"\
+	-e "s/undirected edge/_ed_ge_label_/g"\
+	-e "s/graph_/_gr_aph_label__/g"\
+	-e "s/_graph/__gr_aph_label_/g"\
+	-e "s/UGraph/_Gr_aph_label_/g"\
+	-e "s/uGraph/_gr_aph_label_/g"\
+	-e "s/ugraph/_gr_aph_label_/g"\
+	-e "s/Graph/_Digr_aph_label_/g"\
+	-e "s/graph/_digr_aph_label_/g"\
+	-e "s/UEdge/_Ed_ge_label_/g"\
+	-e "s/uEdge/_ed_ge_label_/g"\
+	-e "s/uedge/_ed_ge_label_/g"\
+	-e "s/IncEdgeIt/_In_cEd_geIt_label_/g"\
+	-e "s/Edge/_Ar_c_label_/g"\
+	-e "s/edge/_ar_c_label_/g"\
+	-e "s/ANode/_Re_d_label_/g"\
+	-e "s/BNode/_Blu_e_label_/g"\
+	-e "s/A-Node/_Re_d_label_/g"\
+	-e "s/B-Node/_Blu_e_label_/g"\
+	-e "s/anode/_re_d_label_/g"\
+	-e "s/bnode/_blu_e_label_/g"\
+	-e "s/aNode/_re_d_label_/g"\
+	-e "s/bNode/_blu_e_label_/g"\
+	-e "s/_Digr_aph_label_/Digraph/g"\
+	-e "s/_digr_aph_label_/digraph/g"\
+	-e "s/_Gr_aph_label_/Graph/g"\
+	-e "s/_gr_aph_label_/graph/g"\
+	-e "s/_Ar_c_label_/Arc/g"\
+	-e "s/_ar_c_label_/arc/g"\
+	-e "s/_Ed_ge_label_/Edge/g"\
+	-e "s/_ed_ge_label_/edge/g"\
+	-e "s/_In_cEd_geIt_label_/IncEdgeIt/g"\
+	-e "s/_Re_d_label_/Red/g"\
+	-e "s/_Blu_e_label_/Blue/g"\
+	-e "s/_re_d_label_/red/g"\
+	-e "s/_blu_e_label_/blue/g"\
+> rename_graphs_temp_file_$ID.tmp
+
+mv rename_graphs_temp_file_$ID.tmp $1
Index: scripts/rpmbuild-glpk
===================================================================
--- scripts/rpmbuild-glpk	(revision 2484)
+++ scripts/rpmbuild-glpk	(revision 2484)
@@ -0,0 +1,97 @@
+#!/bin/bash
+
+case $# in
+    1)
+	RELEASE=1
+	;;
+    2)
+	RELEASE=$2
+	;;
+    *)
+	echo "Usage: rpmbuild-glpk tarfile [release]"
+	;;	
+esac
+
+
+ORIGTAR=$1
+VERSION=`echo ${ORIGTAR/.tar.gz}|tr - ' '|awk '{print $(NF)}'`
+
+echo "GLPK VERSION: $VERSION"
+echo "     RELEASE: $RELEASE"
+
+
+set -e
+
+function make-dir () {
+    if [ ! -d $1 ]; then
+	mkdir $1
+    fi
+}
+
+rm -rf glpk-tmp
+make-dir glpk-tmp
+
+cd glpk-tmp
+
+tar xzf $ORIGTAR
+
+echo 'Summary: GNU Linear Programming toolKit
+Name: glpk
+Version: '${VERSION}'
+Release: '${RELEASE}'
+License: GPL
+URL: http://www.gnu.org/software/glpk/glpk.html
+Source0: %{name}-%{version}.tar.gz
+Group: Development/Libraries
+BuildRoot: %{_tmppath}/%{name}-root
+Provides: glpk = '${VERSION}-${RELEASE}'
+Provides: glpk-devel = '${VERSION}-${RELEASE}'
+
+%description
+The GLPK package is a set of routines written in ANSI C and organized
+in the form of a callable library. This package is intended for solving
+large-scale linear programming (LP), mixed integer linear programming
+(MIP), and other related problems.
+
+The GLPK package includes the following main components:
+
+* implementation of the simplex method;
+* implementation of the primal-dual interior-point method;
+* implementation of the branch-and-bound method;
+* application program interface (API);
+* GNU MathProg modeling language (a subset of AMPL);
+* GLPSOL, a stand-alone LP/MIP solver.
+
+See GLPK webpage <http://www.gnu.org/software/glpk/glpk.html>.
+
+%prep
+%setup -q
+
+%build
+%configure
+make
+
+%install
+rm -rf $RPM_BUILD_ROOT
+make DESTDIR=$RPM_BUILD_ROOT install
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post -p /sbin/ldconfig
+
+%postun -p /sbin/ldconfig
+
+%files
+%defattr(-,root,root)
+%{_bindir}/glpsol
+%{_includedir}
+%{_libdir}/lib*
+%doc AUTHORS COPYING NEWS README
+'>glpk-${VERSION}/glpk.spec
+
+tar czf glpk-${VERSION}.tar.gz glpk-${VERSION}
+rpmbuild -ta glpk-${VERSION}.tar.gz
+
+cd ..
+rm -rf glpk-tmp
Index: scripts/see-deps
===================================================================
--- scripts/see-deps	(revision 2170)
+++ scripts/see-deps	(revision 2170)
@@ -0,0 +1,6 @@
+#!/bin/bash
+
+echo '#include<'$1'>' >seedeps_tmp.cc
+gcc -MM -I. -I.. -I../.. $2 seedeps_tmp.cc|tr ':' ' '|tr '\' ' '|tr ' ' '\n'|
+egrep -v '^$'|egrep -v '.o$'|egrep -v '.cc$'|grep -v '^'$1'$'|sort
+rm seedeps_tmp.cc
Index: scripts/server-services/repocheck/commit-checker
===================================================================
--- scripts/server-services/repocheck/commit-checker	(revision 2365)
+++ scripts/server-services/repocheck/commit-checker	(revision 2365)
@@ -0,0 +1,122 @@
+#!/bin/bash
+
+ROOT=$PWD
+REV=$1
+LOGFILE=${ROOT}/logs/${REV}.log
+
+function im-not-the-next() {
+    for i in `ls queue`
+    do
+	if [ $i -lt $REV ]; then
+	    true
+	    return
+	fi
+    done
+    false
+}
+
+function make-dir () {
+    if [ ! -d $1 ]; then
+	mkdir $1
+    fi
+}
+
+function makecheck () {
+    if [ `which $(echo $CXX|cut -f1 -d' ' )` ]; then
+	make-dir $ODIR &&
+	cd $ODIR &&
+	time ../trunk/configure $* &&
+	time make check &&
+	cd .. 
+    else
+	echo
+	echo '***************************************************************'
+	echo "  COMPILER $CXX CANNOT BE FOUND"
+	echo '***************************************************************'
+	echo
+    fi
+}
+
+function check-compilers() {
+cd trunk &&
+autoreconf -vi &&
+cd .. &&
+ODIR=gcc-3.3 CXX=g++-3.3 CXXFLAGS='-W -Wall -Werror' makecheck --enable-demo --enable-benchmark --with-soplex=/usr/local/soplex &&
+ODIR=gcc-3.4 CXX=g++-3.4 CXXFLAGS='-W -Wall -Werror' makecheck --enable-demo --enable-benchmark --with-soplex=/usr/local/soplex &&
+ODIR=gcc-4.0 CXX=g++-4.0 CXXFLAGS='-W -Wall -Werror' makecheck --enable-demo --enable-benchmark --with-soplex=/usr/local/soplex &&
+ODIR=gcc-4.1 CXX=g++-4.1 CXXFLAGS='-W -Wall -Werror' makecheck --enable-demo --enable-benchmark --with-soplex=/usr/local/soplex &&
+# # ODIR=icc-8.0 CXX=icpc-8.0 CXXFLAGS='-Werror' makecheck --enable-demo --enable-benchmark &&
+# ODIR=icc-9.0 CXX='icpc-9.0' CXXFLAGS='-Werror' makecheck --enable-demo --enable-benchmark &&
+# ODIR=mingw CXX='g++' makecheck --with-msw --target=i586-mingw32msvc --host=i586-mingw32msvc --build=i386-linux --without-glpk &&
+echo &&
+echo '**********************************************************************' &&
+echo '   REPOSITORY SEEMS OK' &&
+echo '**********************************************************************' &&
+echo
+}
+
+if [ $# -eq 0 ]; then
+    echo 'Usage:'
+    echo '   commit-checker --init'
+    echo '   commit-checker revision'
+    exit 1
+elif [ $1 = '--init' ]; then
+    rm -rf queue
+    mkdir queue
+    make-dir logs
+    rm -rf trunk
+    svn co https://lemon.cs.elte.hu/svn/hugo/trunk
+    exit 0
+fi
+
+touch ${ROOT}/queue/$REV
+
+while im-not-the-next; do
+    sleep 10
+done
+
+# echo RUN $REV
+
+svn up -r$REV trunk >${LOGFILE} 2>&1
+
+AUTHOR=`svn info trunk|grep 'Last Changed Author:'|cut -d ' ' -f 4`
+EMAIL=`awk '$1=="'${AUTHOR}'" {print $2}' <${ROOT}/e-mails`
+
+echo '
+
+*************************************************************
+Check revision '${REV}' of '${AUTHOR}' ('${EMAIL}')
+*************************************************************
+
+'>>${LOGFILE} 2>&1
+
+if check-compilers >>${LOGFILE} 2>&1
+then
+    echo -n
+else
+    echo 'Dear '${AUTHOR}',
+Your svn commit -r'${REV}' made the repository broken, or at least
+the compiler emits warnings during the build process.
+The compilation log is attached.
+Please fix the problem as soon as possible.
+
+Best regards,
+LEMON Commit Checking Service
+'|
+    mail -a ${LOGFILE} -s '[LEMON-SVN] WARNING: Revision '${REV}' is broken' \
+	${EMAIL} alpar@cs.elte.hu
+
+    echo 'Commit -r'${REV}' made the repository broken, or at least
+the compiler emits warnings during the build process.
+Do not update until this bug is fixed, unless you really need it.
+
+Best regards,
+LEMON Commit Checking Service
+'|
+    mail -s 'WARNING: Revision '${REV}' is broken' \
+	${EMAIL} lemon-commits@lemon.cs.elte.hu
+fi
+    
+#    rm ${LOGFILE}
+rm ${ROOT}/queue/$REV
+
Index: scripts/server-services/repodoc/make-doc
===================================================================
--- scripts/server-services/repodoc/make-doc	(revision 2626)
+++ scripts/server-services/repodoc/make-doc	(revision 2626)
@@ -0,0 +1,45 @@
+#!/bin/bash
+
+(
+    export PATH=/usr/local/bin:$PATH
+    REPOSITORY=http://lemon.cs.elte.hu/hg/lemon/
+    WORKINGCOPY=lemon
+
+    ROOT=$PWD
+    LASTREV_FILE=$ROOT/last-rev
+    LASTREV=`cat $LASTREV_FILE`
+
+    cd $WORKINGCOPY
+    hg pull
+    hg update
+
+    REV=`hg id -n`
+
+    if [ $# -eq 0 ]; then
+        if [ $LASTREV -lt $REV ]; then
+            # Delete autom4te.cache in order to get configure regenerated 
+            # and the new revision number propagated into it.
+            rm -rf autom4te.cache
+            rm -rf doc/html
+            autoreconf -vi
+            ./configure
+            make html
+            cd ..
+            rm -rf latest-doc
+            cp -r $WORKINGCOPY/doc/html latest-doc
+            echo $REV >$LASTREV_FILE
+        fi
+
+    elif [ $1 = '--help' ]; then
+        echo 'Usage:'
+        echo '   make-doc --init'
+        echo '   make-doc --help'
+        echo '   make-doc'
+        exit 1
+    elif [ $1 = '--init' ]; then
+        rm -rf $WORKINGCOPY
+        hg clone $REPOSITORY $WORKINGCOPY
+        echo '0' >$LASTREV_FILE
+        exit 0
+    fi
+ ) >/dev/null 2>&1
Index: scripts/update-copyright-header
===================================================================
--- scripts/update-copyright-header	(revision 2553)
+++ scripts/update-copyright-header	(revision 2553)
@@ -0,0 +1,33 @@
+#!/bin/bash
+
+FILE_NAME=$1
+TMP_FILE=`mktemp`
+YEAR=`date +2003-%Y`
+
+(echo "/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) "$YEAR"
+ * 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.
+ *
+ */
+"
+awk 'BEGIN { pm=0; }
+     pm==3 { print }
+     /\/\* / && pm==0 { pm=1;}
+     /[^:blank:]/ && (pm==0 || pm==2) { pm=3; print;}
+     /\*\// && pm==1 { pm=2;}
+    ' $1
+) >$TMP_FILE
+rm $FILE_NAME
+mv $TMP_FILE $FILE_NAME
Index: scripts/update-libstd-tag
===================================================================
--- scripts/update-libstd-tag	(revision 2241)
+++ scripts/update-libstd-tag	(revision 2241)
@@ -0,0 +1,7 @@
+#!/bin/bash
+
+cd ${0%update-libstd-tag}../doc
+mv libstdc++.tag libstdc++.tag.old
+wget http://gcc.gnu.org/onlinedocs/libstdc++/latest-doxygen/libstdc++.tag &&
+rm libstdc++.tag.old || mv libstdc++.tag.old libstdc++.tag
+
Index: test/Makefile.am
===================================================================
--- test/Makefile.am	(revision 2658)
+++ test/Makefile.am	(revision 2604)
@@ -1,52 +1,62 @@
 EXTRA_DIST += \
-	test/Makefile
-##	test/preflow_graph.dim \
-##	test/dijkstra_test.lgf
+	test/Makefile \
+	test/preflow_graph.dim \
+	test/dijkstra_test.lgf \
+	test/min_cost_flow_test.lgf \
+	test/min_cost_flow_test.net
 
-noinst_HEADERS +=
-##	test/test_tools.h \
-##	test/graph_test.h \
-##	test/map_test.h \
-##	test/graph_utils_test.h \
-##	test/heap_test.h
+noinst_HEADERS += \
+	test/test_tools.h \
+	test/graph_test.h \
+	test/map_test.h \
+	test/graph_utils_test.h \
+	test/heap_test.h
 
-check_PROGRAMS +=
-##	test/all_pairs_shortest_path_test \
-##	test/arborescence_test \
-##	test/bfs_test \
-##	test/bipartite_matching_test \
-##	test/counter_test \
-##	test/dfs_test \
-##	test/dijkstra_test \
-	test/dim_test
-##	test/edge_set_test \
-##	test/graph_adaptor_test \
-##	test/graph_test \
-##	test/graph_utils_test \
-##	test/heap_test \
-##	test/kruskal_test \
-##	test/maps_test \
-##	test/matrix_maps_test \
-##	test/max_matching_test \
-##	test/min_cost_flow_test \
-##	test/path_test \
-##	test/polynomial_test \
-##	test/preflow_test \
-##	test/radix_sort_test \
-##	test/refptr_test \
-##	test/simann_test \
-##	test/suurballe_test \
-##	test/test_tools_fail \
-##	test/test_tools_pass \
-##	test/time_measure_test \
-##	test/ugraph_test \
-##	test/unionfind_test
+check_PROGRAMS += \
+	test/all_pairs_shortest_path_test \
+	test/arborescence_test \
+	test/bfs_test \
+	test/bipartite_matching_test \
+	test/bpugraph_test \
+	test/counter_test \
+	test/dfs_test \
+	test/dijkstra_test \
+	test/dim_test \
+	test/edge_set_test \
+	test/graph_adaptor_test \
+	test/graph_copy_test \
+	test/graph_test \
+	test/graph_utils_test \
+	test/heap_test \
+	test/kruskal_test \
+	test/maps_test \
+	test/matrix_maps_test \
+	test/max_matching_test \
+	test/max_weighted_matching_test \
+	test/min_cost_flow_test \
+	test/path_test \
+	test/polynomial_test \
+	test/preflow_test \
+	test/radix_sort_test \
+	test/refptr_test \
+	test/random_test \
+	test/simann_test \
+	test/suurballe_test \
+	test/test_tools_fail \
+	test/test_tools_pass \
+	test/time_measure_test \
+	test/ugraph_test \
+	test/unionfind_test
 
 if HAVE_GLPK
-##check_PROGRAMS += test/lp_test
+check_PROGRAMS += test/lp_test test/mip_test
 else !HAVE_GLPK
 if HAVE_CPLEX
-##check_PROGRAMS += test/lp_test
-endif HAVE_CPLEX
+check_PROGRAMS += test/lp_test test/mip_test
+else !HAVE_CPLEX
+if HAVE_SOPLEX
+check_PROGRAMS += test/lp_test
+endif HAVE_SOPLEX
+endif !HAVE_CPLEX
 endif !HAVE_GLPK
 
@@ -54,35 +64,41 @@
 XFAIL_TESTS += test/test_tools_fail$(EXEEXT)
 
-##test_all_pairs_shortest_path_test_SOURCES = test/all_pairs_shortest_path_test.cc
-##test_arborescence_test_SOURCES = test/arborescence_test.cc
-##test_bfs_test_SOURCES = test/bfs_test.cc
-##test_bipartite_matching_test_SOURCES = test/bipartite_matching_test.cc
-##test_counter_test_SOURCES = test/counter_test.cc
-##test_dfs_test_SOURCES = test/dfs_test.cc
-##test_dijkstra_test_SOURCES = test/dijkstra_test.cc
+test_all_pairs_shortest_path_test_SOURCES = test/all_pairs_shortest_path_test.cc
+test_arborescence_test_SOURCES = test/arborescence_test.cc
+test_bfs_test_SOURCES = test/bfs_test.cc
+test_bipartite_matching_test_SOURCES = test/bipartite_matching_test.cc
+test_bpugraph_test_SOURCES = test/bpugraph_test.cc
+test_counter_test_SOURCES = test/counter_test.cc
+test_dfs_test_SOURCES = test/dfs_test.cc
+test_dijkstra_test_SOURCES = test/dijkstra_test.cc
 test_dim_test_SOURCES = test/dim_test.cc
-##test_edge_set_test_SOURCES = test/edge_set_test.cc
-##test_graph_adaptor_test_SOURCES = test/graph_adaptor_test.cc
-##test_graph_test_SOURCES = test/graph_test.cc
-##test_graph_utils_test_SOURCES = test/graph_utils_test.cc
-##test_heap_test_SOURCES = test/heap_test.cc
-##test_kruskal_test_SOURCES = test/kruskal_test.cc
-##test_maps_test_SOURCES = test/maps_test.cc
-##test_matrix_maps_test_SOURCES = test/matrix_maps_test.cc
-##test_max_matching_test_SOURCES = test/max_matching_test.cc
-##test_min_cost_flow_test_SOURCES = test/min_cost_flow_test.cc
-##test_path_test_SOURCES = test/path_test.cc
-##test_polynomial_test_SOURCES = test/polynomial_test.cc
-##test_preflow_test_SOURCES = test/preflow_test.cc
-##test_radix_sort_test_SOURCES = test/radix_sort_test.cc
-##test_refptr_test_SOURCES = test/refptr_test.cc
-##test_simann_test_SOURCES = test/simann_test.cc
-##test_suurballe_test_SOURCES = test/suurballe_test.cc
-##test_test_tools_fail_SOURCES = test/test_tools_fail.cc
-##test_test_tools_pass_SOURCES = test/test_tools_pass.cc
-##test_time_measure_test_SOURCES = test/time_measure_test.cc
-##test_ugraph_test_SOURCES = test/ugraph_test.cc
-##test_unionfind_test_SOURCES = test/unionfind_test.cc
+test_edge_set_test_SOURCES = test/edge_set_test.cc
+test_graph_adaptor_test_SOURCES = test/graph_adaptor_test.cc
+test_graph_copy_test_SOURCES = test/graph_copy_test.cc
+test_graph_test_SOURCES = test/graph_test.cc
+test_graph_utils_test_SOURCES = test/graph_utils_test.cc
+test_heap_test_SOURCES = test/heap_test.cc
+test_kruskal_test_SOURCES = test/kruskal_test.cc
+test_maps_test_SOURCES = test/maps_test.cc
+test_matrix_maps_test_SOURCES = test/matrix_maps_test.cc
+test_max_matching_test_SOURCES = test/max_matching_test.cc
+test_max_weighted_matching_test_SOURCES = test/max_weighted_matching_test.cc
+test_min_cost_flow_test_SOURCES = test/min_cost_flow_test.cc
+test_path_test_SOURCES = test/path_test.cc
+test_polynomial_test_SOURCES = test/polynomial_test.cc
+test_preflow_test_SOURCES = test/preflow_test.cc
+test_radix_sort_test_SOURCES = test/radix_sort_test.cc
+test_refptr_test_SOURCES = test/refptr_test.cc
+test_random_test_SOURCES = test/random_test.cc
+test_simann_test_SOURCES = test/simann_test.cc
+test_suurballe_test_SOURCES = test/suurballe_test.cc
+test_test_tools_fail_SOURCES = test/test_tools_fail.cc
+test_test_tools_pass_SOURCES = test/test_tools_pass.cc
+test_time_measure_test_SOURCES = test/time_measure_test.cc
+test_ugraph_test_SOURCES = test/ugraph_test.cc
+test_unionfind_test_SOURCES = test/unionfind_test.cc
 
-##test_lp_test_SOURCES = test/lp_test.cc
-##test_lp_test_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS)
+test_lp_test_SOURCES = test/lp_test.cc
+test_lp_test_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS) $(SOPLEX_CXXFLAGS)
+test_mip_test_SOURCES = test/mip_test.cc
+test_mip_test_CXXFLAGS = $(GLPK_CFLAGS) $(CPLEX_CFLAGS) $(SOPLEX_CXXFLAGS)
Index: test/all_pairs_shortest_path_test.cc
===================================================================
--- test/all_pairs_shortest_path_test.cc	(revision 2569)
+++ test/all_pairs_shortest_path_test.cc	(revision 2569)
@@ -0,0 +1,143 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <vector>
+
+#include <lemon/math.h>
+#include <cstdlib>
+
+#include <lemon/smart_graph.h>
+#include <lemon/dijkstra.h>
+#include <lemon/floyd_warshall.h>
+#include <lemon/johnson.h>
+
+#include <lemon/fib_heap.h>
+
+#include <lemon/path.h>
+
+#include <lemon/time_measure.h>
+#include "test_tools.h"
+
+using namespace lemon;
+using namespace std;
+
+int main(int argc, const char *argv[]) {
+  typedef SmartGraph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::Edge Edge;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeIt EdgeIt;
+
+  typedef Graph::EdgeMap<int> LengthMap;
+  typedef Graph::NodeMap<int> DistMap;
+
+  const int n = argc > 1 ? atoi(argv[1]) : 20;
+  const int e = argc > 2 ? atoi(argv[2]) : int(n * log(double(n)));
+  const int m = argc > 3 ? atoi(argv[3]) : 100;
+
+  Graph graph;
+  LengthMap length(graph);
+  vector<Node> nodes;
+  
+  DistMap shift(graph);
+  for (int i = 0; i < n; ++i) {
+    Node node = graph.addNode();
+    nodes.push_back(node);
+    shift[node] = rnd[m];
+  }
+
+  for (int i = 0; i < e; ++i) {
+    int s = rnd[n];
+    int t = rnd[n];
+    Edge edge = graph.addEdge(nodes[s], nodes[t]);
+    length[edge] = rnd[m] - shift[nodes[s]] + shift[nodes[t]];
+  }
+
+  Johnson<Graph, LengthMap> johnson(graph, length);
+  {
+    Timer timer;
+    johnson.run();
+    cout << "Johnson: " << timer << endl;
+  }
+
+  typedef FibHeap<int, Graph::NodeMap<int> > IntFibHeap;
+  Johnson<Graph, LengthMap>::DefStandardHeap<IntFibHeap>
+    ::Create fibJohnson(graph, length);
+  {
+    Timer timer;
+    fibJohnson.run();
+    cout << "Johnson with fibonacci heap: " << timer << endl;
+  }
+
+  FloydWarshall<Graph, LengthMap> floyd(graph, length);
+  {
+    Timer timer;
+    floyd.run();
+    cout << "FloydWarshall: " << timer << endl;
+  }    
+
+  bool checked_path = false;
+
+  for (NodeIt it(graph); it != INVALID; ++it) {
+    for (NodeIt jt(graph); jt != INVALID; ++jt) {
+      check(johnson.connected(it, jt) == floyd.connected(it, jt),
+	    "Wrong connection in all pairs shortest path");
+      check(johnson.connected(it, jt) == fibJohnson.connected(it, jt),
+	    "Wrong connection in all pairs shortest path");
+      if (johnson.connected(it, jt)) {
+        if (it != jt && !checked_path) {
+          {
+            Path<Graph> path = johnson.path(it, jt);
+            check(checkPath(graph, path), "Wrong path.");
+            check(pathSource(graph, path) == it, "Wrong path.");
+            check(pathTarget(graph, path) == jt, "Wrong path.");
+          }
+          {
+            Path<Graph> path = floyd.path(it, jt);
+            check(checkPath(graph, path), "Wrong path.");
+            check(pathSource(graph, path) == it, "Wrong path.");
+            check(pathTarget(graph, path) == jt, "Wrong path.");
+          }
+          checked_path = true;
+          std::cout << "Path checked" << std::endl;
+        }
+	check(johnson.dist(it, jt) == floyd.dist(it, jt),
+	      "Wrong distance in all pairs shortest path");
+	check(johnson.dist(it, jt) == fibJohnson.dist(it, jt),
+	      "Wrong distance in all pairs shortest path");
+	if (it != jt) {
+ 	  check(johnson.dist(it, jt) == 
+		johnson.dist(it, johnson.predNode(it, jt)) +
+		length[johnson.predEdge(it, jt)],
+		"Wrong edge in all pairs shortest path");
+ 	  check(fibJohnson.dist(it, jt) == 
+		fibJohnson.dist(it, fibJohnson.predNode(it, jt)) +
+		length[fibJohnson.predEdge(it, jt)],
+		"Wrong edge in all pairs shortest path");
+	  check(floyd.dist(it, jt) == 
+		floyd.dist(it, floyd.predNode(it, jt)) +
+		length[floyd.predEdge(it, jt)],
+		"Wrong edge in all pairs shortest path");
+	}
+      }
+    }
+  }
+
+  return 0;
+}
Index: test/arborescence_test.cc
===================================================================
--- test/arborescence_test.cc	(revision 2569)
+++ test/arborescence_test.cc	(revision 2569)
@@ -0,0 +1,144 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <set>
+#include <vector>
+#include <iterator>
+
+#include <lemon/math.h>
+#include <cstdlib>
+
+#include <lemon/smart_graph.h>
+#include <lemon/min_cost_arborescence.h>
+
+#include <lemon/graph_utils.h>
+#include <lemon/time_measure.h>
+
+#include <lemon/tolerance.h>
+
+#include "test_tools.h"
+
+using namespace lemon;
+using namespace std;
+
+const int NODES = 10;
+const int EDGES = 22;
+
+int sourceNode = 0;
+
+int sources[EDGES] = {
+  1, 0, 2, 4, 4, 3, 9, 8, 9, 8,
+  4, 2, 0, 6, 4, 1, 7, 2, 8, 6,
+  1, 0
+};
+
+int targets[EDGES] = {
+  8, 3, 1, 1, 4, 9, 8, 1, 8, 0,
+  3, 2, 1, 3, 1, 1, 2, 6, 3, 9,
+  1, 3
+};
+
+double costs[EDGES] = {
+  107.444, 70.3069, 46.0496, 28.3962, 91.4325,
+  76.9443, 61.986, 39.3754, 74.9575, 39.3153,
+  45.7094, 34.6184, 100.156, 95.726, 22.3429,
+  31.587, 51.6972, 29.6773, 115.038, 32.4137,
+  60.0038, 40.1237
+};
+
+
+
+int main() {
+  typedef SmartGraph Graph;
+  GRAPH_TYPEDEFS(Graph);
+
+  typedef Graph::EdgeMap<double> CostMap;
+
+  Graph graph;
+  CostMap cost(graph);
+  vector<Node> nodes;
+  
+  for (int i = 0; i < NODES; ++i) {
+    nodes.push_back(graph.addNode());
+  }
+
+  for (int i = 0; i < EDGES; ++i) {
+    Edge edge = graph.addEdge(nodes[sources[i]], nodes[targets[i]]);
+    cost[edge] = costs[i];
+  }
+
+  Node source = nodes[sourceNode];
+
+  MinCostArborescence<Graph, CostMap> mca(graph, cost);
+  mca.run(source);
+
+  vector<pair<double, set<Node> > > dualSolution(mca.dualSize());
+
+  for (int i = 0; i < mca.dualSize(); ++i) {
+    dualSolution[i].first = mca.dualValue(i);
+    for (MinCostArborescence<Graph, CostMap>::DualIt it(mca, i); 
+         it != INVALID; ++it) {
+      dualSolution[i].second.insert(it);
+    }
+  }
+
+  Tolerance<double> tolerance;
+
+  for (EdgeIt it(graph); it != INVALID; ++it) {
+    if (mca.reached(graph.source(it))) {
+      double sum = 0.0;
+      for (int i = 0; i < int(dualSolution.size()); ++i) {
+        if (dualSolution[i].second.find(graph.target(it)) 
+            != dualSolution[i].second.end() &&
+            dualSolution[i].second.find(graph.source(it)) 
+            == dualSolution[i].second.end()) {
+          sum += dualSolution[i].first;
+        }
+      }
+      if (mca.arborescence(it)) {
+        check(!tolerance.less(sum, cost[it]), "INVALID DUAL");
+      }
+      check(!tolerance.less(cost[it], sum), "INVALID DUAL");
+    }
+  }
+
+
+  check(!tolerance.different(mca.dualValue(), mca.arborescenceValue()),
+               "INVALID DUAL");
+
+
+  check(mca.reached(source), "INVALID ARBORESCENCE");
+  for (EdgeIt it(graph); it != INVALID; ++it) {
+    check(!mca.reached(graph.source(it)) || 
+                 mca.reached(graph.target(it)), "INVALID ARBORESCENCE");
+  }
+
+  for (NodeIt it(graph); it != INVALID; ++it) {
+    if (!mca.reached(it)) continue;
+    int cnt = 0;
+    for (InEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+      if (mca.arborescence(jt)) {
+        ++cnt;
+      }
+    }
+    check((it == source ? cnt == 0 : cnt == 1), "INVALID ARBORESCENCE");
+  }
+  
+  return 0;
+}
Index: test/bfs_test.cc
===================================================================
--- test/bfs_test.cc	(revision 2553)
+++ test/bfs_test.cc	(revision 2553)
@@ -0,0 +1,139 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include "test_tools.h"
+#include <lemon/smart_graph.h>
+#include <lemon/bfs.h>
+#include <lemon/path.h>
+#include<lemon/concepts/graph.h>
+
+using namespace lemon;
+
+const int PET_SIZE =5;
+
+
+void check_Bfs_Compile() 
+{
+  typedef concepts::Graph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+ 
+  typedef Bfs<Graph> BType;
+  
+  Graph G;
+  Node n;
+  Edge e;
+  int l;
+  bool b;
+  BType::DistMap d(G);
+  BType::PredMap p(G);
+  //  BType::PredNodeMap pn(G);
+  
+  BType bfs_test(G);
+  
+  bfs_test.run(n);
+  
+  l  = bfs_test.dist(n);
+  e  = bfs_test.predEdge(n);
+  n  = bfs_test.predNode(n);
+  d  = bfs_test.distMap();
+  p  = bfs_test.predMap();
+  //  pn = bfs_test.predNodeMap();
+  b  = bfs_test.reached(n);
+
+  Path<Graph> pp = bfs_test.path(n);
+}
+
+void check_Bfs_Function_Compile() 
+{
+  typedef int VType;
+  typedef concepts::Graph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef concepts::ReadMap<Edge,VType> LengthMap;
+   
+  Graph g;
+  bfs(g,Node()).run();
+  bfs(g).source(Node()).run();
+  bfs(g)
+    .predMap(concepts::WriteMap<Node,Edge>())
+    .distMap(concepts::WriteMap<Node,VType>())
+    .reachedMap(concepts::ReadWriteMap<Node,bool>())
+    .processedMap(concepts::WriteMap<Node,bool>())
+    .run(Node());
+  
+}
+
+int main()
+{
+    
+  typedef SmartGraph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeMap<int> LengthMap;
+
+  Graph G;
+  Node s, t;
+  PetStruct<Graph> ps = addPetersen(G,PET_SIZE);
+   
+  s=ps.outer[2];
+  t=ps.inner[0];
+  
+  Bfs<Graph> bfs_test(G);
+  bfs_test.run(s);
+  
+  check(bfs_test.dist(t)==3,"Bfs found a wrong path. " << bfs_test.dist(t));
+
+  Path<Graph> p = bfs_test.path(t);
+  check(p.length()==3,"getPath() found a wrong path.");
+  check(checkPath(G, p),"path() found a wrong path.");
+  check(pathSource(G, p) == s,"path() found a wrong path.");
+  check(pathTarget(G, p) == t,"path() found a wrong path.");
+  
+
+  for(EdgeIt e(G); e==INVALID; ++e) {
+    Node u=G.source(e);
+    Node v=G.target(e);
+    check( !bfs_test.reached(u) ||
+	   (bfs_test.dist(v) > bfs_test.dist(u)+1),
+	   "Wrong output.");
+  }
+
+  for(NodeIt v(G); v==INVALID; ++v) {
+    check(bfs_test.reached(v),"Each node should be reached.");
+    if ( bfs_test.predEdge(v)!=INVALID ) {
+      Edge e=bfs_test.predEdge(v);
+      Node u=G.source(e);
+      check(u==bfs_test.predNode(v),"Wrong tree.");
+      check(bfs_test.dist(v) - bfs_test.dist(u) == 1,
+	    "Wrong distance. Difference: " 
+	    << std::abs(bfs_test.dist(v) - bfs_test.dist(u) 
+			- 1));
+    }
+  }
+}
+
Index: test/bipartite_matching_test.cc
===================================================================
--- test/bipartite_matching_test.cc	(revision 2618)
+++ test/bipartite_matching_test.cc	(revision 2618)
@@ -0,0 +1,411 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <cstdlib>
+#include <iostream>
+#include <sstream>
+
+#include <lemon/smart_graph.h>
+
+#include <lemon/bpugraph_adaptor.h>
+#include <lemon/bipartite_matching.h>
+#include <lemon/pr_bipartite_matching.h>
+
+#include <lemon/graph_utils.h>
+
+#include <lemon/maps.h>
+
+#include "test_tools.h"
+
+using namespace std;
+using namespace lemon;
+
+typedef SmartBpUGraph Graph;
+BPUGRAPH_TYPEDEFS(Graph);
+
+const int NN = 10;
+const int MM = 10;
+const int EE = 52;
+const int CC = 100;
+
+const int sa[EE] = { 6, 5, 6, 4, 1, 0, 9, 5, 2, 4, 4, 3, 5,
+                    2, 3, 8, 3, 4, 9, 6, 9, 4, 3, 1, 5, 8,
+                    4, 8, 9, 2, 2, 3, 0, 5, 2, 3, 6, 3, 8,
+                    8, 4, 0, 9, 9, 6, 2, 1, 2, 7, 1, 9, 4};
+
+const int ta[EE] = { 2, 7, 4, 8, 6, 3, 4, 1, 7, 7, 0, 1, 6,
+                    3, 2, 6, 8, 3, 5, 6, 3, 1, 8, 7, 2, 0,
+                    6, 9, 6, 7, 8, 3, 3, 4, 5, 8, 6, 4, 1,
+                    4, 3, 3, 8, 7, 7, 3, 7, 7, 3, 5, 1, 6};
+
+const int wa[EE] = { 3, 99, 85, 16, 79, 52, 83, 99, 62, 6, 42, 6, 95,
+                    13, 34, 9, 5, 38, 39, 75, 99, 12, 73, 35, 93, 43,
+                    54, 91, 45, 26, 77, 47, 11, 22, 50, 74, 37, 64, 91,
+                    60, 6, 92, 29, 46, 34, 84, 67, 34, 45, 0, 39, 47};
+
+
+int main() {
+  Graph graph;
+  vector<Node> aNodes;
+  vector<Node> bNodes;
+
+  Graph::UEdgeMap<int> weight(graph);
+
+  int max_cardinality;
+  int max_weight;
+  int max_cardinality_max_weight;
+  int min_cost_matching;
+
+  for (int i = 0; i < NN; ++i) {
+    Node node = graph.addANode();
+    aNodes.push_back(node);
+  }
+  for (int i = 0; i < MM; ++i) {
+    Node node = graph.addBNode();
+    bNodes.push_back(node);
+  }
+  for (int i = 0; i < EE; ++i) {
+    Node aNode = aNodes[sa[i]];
+    Node bNode = bNodes[ta[i]];
+    UEdge uedge = graph.addEdge(aNode, bNode);
+    weight[uedge] = wa[i];
+  }
+
+
+  {
+    MaxBipartiteMatching<Graph> bpmatch(graph);
+
+    bpmatch.run();
+
+    Graph::UEdgeMap<bool> mm(graph);
+    Graph::NodeMap<bool> cs(graph);
+    
+    check(bpmatch.coverSet(cs) == bpmatch.matching(mm), "INVALID PRIMAL-DUAL");
+    
+    for (UEdgeIt it(graph); it != INVALID; ++it) {
+      check(cs[graph.aNode(it)] || cs[graph.bNode(it)], "INVALID DUAL");
+    }
+    
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+      }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+    max_cardinality = bpmatch.matchingSize();
+  }
+
+  {
+    PrBipartiteMatching<Graph> bpmatch(graph);
+
+    bpmatch.run();
+
+    Graph::UEdgeMap<bool> mm(graph);
+    Graph::NodeMap<bool> cs(graph);
+    
+    check(bpmatch.coverSet(cs) == bpmatch.matching(mm), "INVALID PRIMAL-DUAL");
+    
+    for (UEdgeIt it(graph); it != INVALID; ++it) {
+      check(cs[graph.aNode(it)] || cs[graph.bNode(it)], "INVALID DUAL");
+    }
+    
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+      }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+    max_cardinality = bpmatch.matchingSize();
+  }
+
+  {
+    Graph::ANodeMap<UEdge> mm(graph);
+
+    check(max_cardinality == maxBipartiteMatching(graph, mm),
+          "WRONG MATCHING");
+    
+    for (BNodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[graph.aNode(jt)] == jt) ++num;
+      }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+  }
+
+  {
+    Graph::ANodeMap<UEdge> mm(graph);
+
+    check(max_cardinality == prBipartiteMatching(graph, mm),
+          "WRONG MATCHING");
+    
+    for (BNodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[graph.aNode(jt)] == jt) ++num;
+      }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+  }
+
+  {
+    MaxBipartiteMatching<Graph> bpmatch(graph);
+
+    bpmatch.greedyInit();
+    bpmatch.start();
+
+    Graph::UEdgeMap<bool> mm(graph);
+    Graph::NodeMap<bool> cs(graph);
+
+    check(bpmatch.coverSet(cs) == bpmatch.matching(mm), "INVALID PRIMAL-DUAL");
+    
+    for (UEdgeIt it(graph); it != INVALID; ++it) {
+      check(cs[graph.aNode(it)] || cs[graph.bNode(it)], "INVALID DUAL");
+    }
+    
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+    }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+  }
+
+  {
+    MaxBipartiteMatching<Graph> bpmatch(graph);
+
+    bpmatch.greedyInit();
+    while (bpmatch.simpleAugment()) { }
+    
+    Graph::UEdgeMap<bool> mm(graph);
+    Graph::NodeMap<bool> cs(graph);
+    
+    check(bpmatch.coverSet(cs) == bpmatch.matching(mm), "INVALID PRIMAL-DUAL");
+    
+    for (UEdgeIt it(graph); it != INVALID; ++it) {
+      check(cs[graph.aNode(it)] || cs[graph.bNode(it)], "INVALID DUAL");
+    }
+    
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+    }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+  }
+
+  {
+    MaxWeightedBipartiteMatching<Graph> bpmatch(graph, weight);
+
+    bpmatch.init();
+
+    max_weight = 0;
+    while (bpmatch.augment(true)) {
+    
+      Graph::UEdgeMap<bool> mm(graph);
+      Graph::NodeMap<int> pm(graph);
+      
+      bpmatch.matching(mm);
+      bpmatch.potential(pm);
+      
+      for (UEdgeIt it(graph); it != INVALID; ++it) {
+        if (mm[it]) {
+          check(pm[graph.aNode(it)] + pm[graph.bNode(it)] - weight[it] == 0,
+                "INVALID DUAL");
+        } else {
+          check(pm[graph.aNode(it)] + pm[graph.bNode(it)] - weight[it] >= 0,
+                "INVALID DUAL");
+        }
+      }
+
+      for (ANodeIt it(graph); it != INVALID; ++it) {
+        int num = 0;
+        for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+          if (mm[jt]) ++num;
+        }
+        check(num <= 1, "INVALID PRIMAL");
+      }
+      if (bpmatch.matchingValue() > max_weight) {
+        max_weight = bpmatch.matchingValue();
+      }
+    }
+  }
+
+  {
+    Graph::UEdgeMap<bool> mm(graph);
+
+    check(max_weight == maxWeightedBipartiteMatching(graph, weight, mm),
+          "WRONG MATCHING");
+    
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+      }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+  }
+
+  {
+    MaxWeightedBipartiteMatching<Graph> bpmatch(graph, weight);
+
+    bpmatch.run();
+    
+    Graph::UEdgeMap<bool> mm(graph);
+    Graph::NodeMap<int> pm(graph);
+
+    bpmatch.matching(mm);
+    bpmatch.potential(pm);
+    
+    for (UEdgeIt it(graph); it != INVALID; ++it) {
+      if (mm[it]) {
+        check(pm[graph.aNode(it)] + pm[graph.bNode(it)] - weight[it] == 0,
+              "INVALID DUAL");
+      } else {
+        check(pm[graph.aNode(it)] + pm[graph.bNode(it)] - weight[it] >= 0,
+              "INVALID DUAL");
+      }
+    }
+
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+    }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+    check(max_weight == bpmatch.matchingValue(), "WRONG WEIGHT");
+  }
+
+  {
+    MaxWeightedBipartiteMatching<Graph> bpmatch(graph, weight);
+
+    bpmatch.run(true);
+    
+    Graph::UEdgeMap<bool> mm(graph);
+    Graph::NodeMap<int> pm(graph);
+
+    bpmatch.matching(mm);
+    bpmatch.potential(pm);
+    
+    for (UEdgeIt it(graph); it != INVALID; ++it) {
+      if (mm[it]) {
+        check(pm[graph.aNode(it)] + pm[graph.bNode(it)] - weight[it] == 0,
+              "INVALID DUAL");
+      } else {
+        check(pm[graph.aNode(it)] + pm[graph.bNode(it)] - weight[it] >= 0,
+              "INVALID DUAL");
+      }
+    }
+
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+    }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+    check(max_cardinality == bpmatch.matchingSize(), "WRONG SIZE");
+    max_cardinality_max_weight = bpmatch.matchingValue();
+
+  }
+
+  {
+    Graph::UEdgeMap<bool> mm(graph);
+
+    check(max_cardinality_max_weight == 
+          maxWeightedMaxBipartiteMatching(graph, weight, mm),
+          "WRONG MATCHING");
+    
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+      }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+  }
+
+  Graph::UEdgeMap<int> cost(graph);
+  cost = subMap(constMap<UEdge>(CC), weight);
+  {
+
+    MinCostMaxBipartiteMatching<Graph> bpmatch(graph, cost);
+
+    bpmatch.run();
+    
+    Graph::UEdgeMap<bool> mm(graph);
+    Graph::NodeMap<int> pm(graph);
+
+    bpmatch.matching(mm);
+    bpmatch.potential(pm);
+    
+    min_cost_matching = bpmatch.matchingCost();
+    check(max_cardinality == bpmatch.matchingSize(), "WRONG SIZE");
+    check(max_cardinality * CC - max_cardinality_max_weight 
+          == bpmatch.matchingCost(), "WRONG SIZE");
+
+    for (UEdgeIt it(graph); it != INVALID; ++it) {
+      if (mm[it]) {
+        check(pm[graph.aNode(it)] + cost[it] - pm[graph.bNode(it)] == 0,
+              "INVALID DUAL");
+      } else {
+        check(pm[graph.aNode(it)] + cost[it] - pm[graph.bNode(it)] >= 0,
+              "INVALID DUAL");
+      }
+    }
+
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+    }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+
+    min_cost_matching = bpmatch.matchingCost();
+    check(max_cardinality == bpmatch.matchingSize(), "WRONG SIZE");
+    check(max_cardinality * CC - max_cardinality_max_weight 
+          == bpmatch.matchingCost(), "WRONG SIZE");
+
+  }
+
+  {
+    Graph::UEdgeMap<bool> mm(graph);
+
+    check(min_cost_matching == 
+          minCostMaxBipartiteMatching(graph, cost, mm),
+          "WRONG MATCHING");
+    
+    for (ANodeIt it(graph); it != INVALID; ++it) {
+      int num = 0;
+      for (IncEdgeIt jt(graph, it); jt != INVALID; ++jt) {
+        if (mm[jt]) ++num;
+      }
+      check(num <= 1, "INVALID PRIMAL");
+    }
+  }
+
+  return 0;
+}
Index: test/bpugraph_test.cc
===================================================================
--- test/bpugraph_test.cc	(revision 2553)
+++ test/bpugraph_test.cc	(revision 2553)
@@ -0,0 +1,146 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/concepts/bpugraph.h>
+#include <lemon/list_graph.h>
+#include <lemon/smart_graph.h>
+#include <lemon/full_graph.h>
+#include <lemon/grid_ugraph.h>
+
+#include <lemon/graph_utils.h>
+
+#include "test_tools.h"
+
+
+using namespace lemon;
+using namespace lemon::concepts;
+
+void check_concepts() {
+
+  { // checking graph components
+    checkConcept<BaseBpUGraphComponent, BaseBpUGraphComponent >();
+
+    checkConcept<IDableBpUGraphComponent<>, 
+      IDableBpUGraphComponent<> >();
+
+    checkConcept<IterableBpUGraphComponent<>, 
+      IterableBpUGraphComponent<> >();
+
+    checkConcept<MappableBpUGraphComponent<>, 
+      MappableBpUGraphComponent<> >();
+
+  }
+  {
+    checkConcept<BpUGraph, ListBpUGraph>();
+    
+    checkConcept<BpUGraph, SmartBpUGraph>();
+    
+    checkConcept<BpUGraph, FullBpUGraph>();
+    
+    checkConcept<BpUGraph, BpUGraph>();
+    
+  }
+}
+
+template <typename Graph>
+void check_item_counts(Graph &g, int an, int bn, int e) {
+  int nn = 0;
+  for (typename Graph::NodeIt it(g); it != INVALID; ++it) {
+    ++nn;
+  }
+
+  check(nn == an + bn, "Wrong node number.");
+  check(countNodes(g) == an + bn, "Wrong node number.");
+
+  int ann = 0;
+  for (typename Graph::ANodeIt it(g); it != INVALID; ++it) {
+    ++ann;
+  }
+
+  check(ann == an, "Wrong node number.");
+  check(countANodes(g) == an, "Wrong node number.");
+
+  int bnn = 0;
+  for (typename Graph::BNodeIt it(g); it != INVALID; ++it) {
+    ++bnn;
+  }
+
+  check(bnn == bn, "Wrong node number.");
+  check(countBNodes(g) == bn, "Wrong node number.");
+
+  int ee = 0;
+  for (typename Graph::EdgeIt it(g); it != INVALID; ++it) {
+    ++ee;
+  }
+
+  check(ee == 2*e, "Wrong edge number.");
+  check(countEdges(g) == 2*e, "Wrong edge number.");
+
+  int uee = 0;
+  for (typename Graph::UEdgeIt it(g); it != INVALID; ++it) {
+    ++uee;
+  }
+
+  check(uee == e, "Wrong uedge number.");
+  check(countUEdges(g) == e, "Wrong uedge number.");
+}
+
+template <typename Graph>
+void check_graph() {
+
+  typedef typename Graph::Node Node;
+  typedef typename Graph::UEdge UEdge;
+  typedef typename Graph::Edge Edge;
+  typedef typename Graph::NodeIt NodeIt;
+  typedef typename Graph::UEdgeIt UEdgeIt;
+  typedef typename Graph::EdgeIt EdgeIt;
+
+  Graph g;
+
+  check_item_counts(g, 0, 0, 0);
+
+  Node
+    an1 = g.addANode(),
+    an2 = g.addANode(),
+    an3 = g.addANode(),
+    bn1 = g.addBNode(),
+    bn2 = g.addBNode();
+
+  UEdge
+    e1 = g.addEdge(an1, bn1),
+    e2 = g.addEdge(an2, bn1),
+    e3 = g.addEdge(an3, bn2);
+
+  check_item_counts(g, 3, 2, 3);
+}
+
+int main() {
+  check_concepts();
+
+  check_graph<ListBpUGraph>();
+  check_graph<SmartBpUGraph>();
+
+  {
+    FullBpUGraph g(5, 10);
+    check_item_counts(g, 5, 10, 50);
+  }
+
+  std::cout << __FILE__ ": All tests passed.\n";
+
+  return 0;
+}
Index: test/counter_test.cc
===================================================================
--- test/counter_test.cc	(revision 2553)
+++ test/counter_test.cc	(revision 2553)
@@ -0,0 +1,66 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/counter.h>
+
+///\file \brief Test cases for time_measure.h
+///
+///\todo To be extended
+
+
+int fibonacci(int f) 
+{
+  static lemon::Counter count("Fibonacci steps: ");
+  count++;
+  if(f<1) return 0;
+  else if(f==1) return 1;
+  else return fibonacci(f-1)+fibonacci(f-2);
+}
+
+int main()
+{
+  fibonacci(10);
+  
+  {  
+    typedef lemon::Counter MyCounter;
+    MyCounter c("Main counter: ");
+    c++;
+    c++;
+    MyCounter::SubCounter d(c,"Subcounter: ");
+    d++;
+    d++;
+    MyCounter::SubCounter::SubCounter e(d,"SubSubCounter: ");
+    e++;
+    e++;
+  }
+  
+  {
+    typedef lemon::NoCounter MyCounter;
+    MyCounter c("Main counter: ");
+    c++;
+    c++;
+    MyCounter::SubCounter d(c,"Subcounter: ");
+    d++;
+    d++;
+    MyCounter::SubCounter::SubCounter e(d,"SubSubCounter: ");
+    e++;
+    e++;
+  }
+
+  return 0;
+}
Index: test/dfs_test.cc
===================================================================
--- test/dfs_test.cc	(revision 2553)
+++ test/dfs_test.cc	(revision 2553)
@@ -0,0 +1,128 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include "test_tools.h"
+#include <lemon/smart_graph.h>
+#include <lemon/dfs.h>
+#include <lemon/path.h>
+#include <lemon/concepts/graph.h>
+
+using namespace lemon;
+
+const int PET_SIZE =5;
+
+
+void check_Dfs_SmartGraph_Compile() 
+{
+  typedef concepts::Graph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+ 
+  typedef Dfs<Graph> DType;
+  
+  Graph G;
+  Node n;
+  Edge e;
+  int l;
+  bool b;
+  DType::DistMap d(G);
+  DType::PredMap p(G);
+  //  DType::PredNodeMap pn(G);
+  
+  DType dfs_test(G);
+  
+  dfs_test.run(n);
+  
+  l  = dfs_test.dist(n);
+  e  = dfs_test.predEdge(n);
+  n  = dfs_test.predNode(n);
+  d  = dfs_test.distMap();
+  p  = dfs_test.predMap();
+  //  pn = dfs_test.predNodeMap();
+  b  = dfs_test.reached(n);
+
+  Path<Graph> pp = dfs_test.path(n);
+}
+
+
+void check_Dfs_Function_Compile() 
+{
+  typedef int VType;
+  typedef concepts::Graph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef concepts::ReadMap<Edge,VType> LengthMap;
+   
+  Graph g;
+  dfs(g,Node()).run();
+  dfs(g).source(Node()).run();
+  dfs(g)
+    .predMap(concepts::WriteMap<Node,Edge>())
+    .distMap(concepts::WriteMap<Node,VType>())
+    .reachedMap(concepts::ReadWriteMap<Node,bool>())
+    .processedMap(concepts::WriteMap<Node,bool>())
+    .run(Node());
+  
+}
+
+int main()
+{
+    
+  typedef SmartGraph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeMap<int> LengthMap;
+
+  Graph G;
+  Node s, t;
+  PetStruct<Graph> ps = addPetersen(G,PET_SIZE);
+   
+  s=ps.outer[2];
+  t=ps.inner[0];
+  
+  Dfs<Graph> dfs_test(G);
+  dfs_test.run(s);  
+  
+  Path<Graph> p = dfs_test.path(t);
+  check(p.length()==dfs_test.dist(t),"path() found a wrong path.");
+  check(checkPath(G, p),"path() found a wrong path.");
+  check(pathSource(G, p) == s,"path() found a wrong path.");
+  check(pathTarget(G, p) == t,"path() found a wrong path.");
+  
+  for(NodeIt v(G); v!=INVALID; ++v) {
+    check(dfs_test.reached(v),"Each node should be reached.");
+    if ( dfs_test.predEdge(v)!=INVALID ) {
+      Edge e=dfs_test.predEdge(v);
+      Node u=G.source(e);
+      check(u==dfs_test.predNode(v),"Wrong tree.");
+      check(dfs_test.dist(v) - dfs_test.dist(u) == 1,
+	    "Wrong distance. (" << dfs_test.dist(u) << "->" 
+	    <<dfs_test.dist(v) << ')');
+    }
+  }
+}
+
Index: test/dijkstra_test.cc
===================================================================
--- test/dijkstra_test.cc	(revision 2553)
+++ test/dijkstra_test.cc	(revision 2553)
@@ -0,0 +1,159 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include "test_tools.h"
+#include <lemon/smart_graph.h>
+#include <lemon/dijkstra.h>
+#include <lemon/path.h>
+#include <lemon/maps.h>
+#include <lemon/concepts/graph.h>
+#include <lemon/concepts/maps.h>
+using namespace lemon;
+
+const int PET_SIZE =5;
+
+
+void check_Dijkstra_BinHeap_Compile() 
+{
+  typedef int VType;
+  typedef concepts::Graph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef concepts::ReadMap<Edge,VType> LengthMap;
+ 
+  typedef Dijkstra<Graph, LengthMap> DType;
+  
+  Graph G;
+  Node n;
+  Edge e;
+  VType l;
+  bool b;
+  DType::DistMap d(G);
+  DType::PredMap p(G);
+  //  DType::PredNodeMap pn(G);
+  LengthMap cap;
+
+  DType dijkstra_test(G,cap);
+
+  dijkstra_test.run(n);
+
+  l  = dijkstra_test.dist(n);
+  e  = dijkstra_test.predEdge(n);
+  n  = dijkstra_test.predNode(n);
+  d  = dijkstra_test.distMap();
+  p  = dijkstra_test.predMap();
+  //  pn = dijkstra_test.predNodeMap();
+  b  = dijkstra_test.reached(n);
+
+  Path<Graph> pp = dijkstra_test.path(n);
+}
+
+void check_Dijkstra_Function_Compile() 
+{
+  typedef int VType;
+  typedef concepts::Graph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef concepts::ReadMap<Edge,VType> LengthMap;
+   
+  Graph g;
+  dijkstra(g,LengthMap(),Node()).run();
+  dijkstra(g,LengthMap()).source(Node()).run();
+  dijkstra(g,LengthMap())
+    .predMap(concepts::WriteMap<Node,Edge>())
+    .distMap(concepts::WriteMap<Node,VType>())
+    .run(Node());
+  
+}
+
+
+int main()
+{
+    
+  typedef SmartGraph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeMap<int> LengthMap;
+
+  Graph G;
+  Node s, t;
+  LengthMap cap(G);
+  PetStruct<Graph> ps = addPetersen(G,PET_SIZE);
+   
+  for(int i=0;i<PET_SIZE;i++) {
+    cap[ps.outcir[i]]=4;
+    cap[ps.incir[i]]=1;
+    cap[ps.chords[i]]=10;
+  }
+  s=ps.outer[0];
+  t=ps.inner[1];
+  
+  Dijkstra<Graph, LengthMap> 
+	dijkstra_test(G, cap);
+  dijkstra_test.run(s);
+  
+  check(dijkstra_test.dist(t)==13,"Dijkstra found a wrong path.");
+
+
+  Path<Graph> p = dijkstra_test.path(t);
+  check(p.length()==4,"getPath() found a wrong path.");
+  check(checkPath(G, p),"path() found a wrong path.");
+  check(pathSource(G, p) == s,"path() found a wrong path.");
+  check(pathTarget(G, p) == t,"path() found a wrong path.");
+  
+
+  for(EdgeIt e(G); e!=INVALID; ++e) {
+    Node u=G.source(e);
+    Node v=G.target(e);
+    check( !dijkstra_test.reached(u) ||
+	   (dijkstra_test.dist(v) - dijkstra_test.dist(u) <= cap[e]),
+	   "dist(target)-dist(source)- edge_length= " 
+	   << dijkstra_test.dist(v) - dijkstra_test.dist(u) 
+	   - cap[e]);
+  }
+
+  ///\bug This works only for integer lengths
+  for(NodeIt v(G); v!=INVALID; ++v){
+    check(dijkstra_test.reached(v),"Each node should be reached.");
+    if ( dijkstra_test.predEdge(v)!=INVALID ) {
+      Edge e=dijkstra_test.predEdge(v);
+      Node u=G.source(e);
+      check(u==dijkstra_test.predNode(v),"Wrong tree.");
+      check(dijkstra_test.dist(v) - dijkstra_test.dist(u) == cap[e],
+	    "Wrong distance! Difference: " 
+	    << std::abs(dijkstra_test.dist(v) - dijkstra_test.dist(u) 
+			    - cap[e]));
+    }
+  }
+
+  
+  {
+    NullMap<Node,Edge> myPredMap;
+    dijkstra(G,cap).predMap(myPredMap).run(s);
+  }
+  return 0;
+}
Index: test/dijkstra_test.lgf
===================================================================
--- test/dijkstra_test.lgf	(revision 2000)
+++ test/dijkstra_test.lgf	(revision 2000)
@@ -0,0 +1,7914 @@
+@nodeset
+label	
+999	
+998	
+997	
+996	
+995	
+994	
+993	
+992	
+991	
+990	
+989	
+988	
+987	
+986	
+985	
+984	
+983	
+982	
+981	
+980	
+979	
+978	
+977	
+976	
+975	
+974	
+973	
+972	
+971	
+970	
+969	
+968	
+967	
+966	
+965	
+964	
+963	
+962	
+961	
+960	
+959	
+958	
+957	
+956	
+955	
+954	
+953	
+952	
+951	
+950	
+949	
+948	
+947	
+946	
+945	
+944	
+943	
+942	
+941	
+940	
+939	
+938	
+937	
+936	
+935	
+934	
+933	
+932	
+931	
+930	
+929	
+928	
+927	
+926	
+925	
+924	
+923	
+922	
+921	
+920	
+919	
+918	
+917	
+916	
+915	
+914	
+913	
+912	
+911	
+910	
+909	
+908	
+907	
+906	
+905	
+904	
+903	
+902	
+901	
+900	
+899	
+898	
+897	
+896	
+895	
+894	
+893	
+892	
+891	
+890	
+889	
+888	
+887	
+886	
+885	
+884	
+883	
+882	
+881	
+880	
+879	
+878	
+877	
+876	
+875	
+874	
+873	
+872	
+871	
+870	
+869	
+868	
+867	
+866	
+865	
+864	
+863	
+862	
+861	
+860	
+859	
+858	
+857	
+856	
+855	
+854	
+853	
+852	
+851	
+850	
+849	
+848	
+847	
+846	
+845	
+844	
+843	
+842	
+841	
+840	
+839	
+838	
+837	
+836	
+835	
+834	
+833	
+832	
+831	
+830	
+829	
+828	
+827	
+826	
+825	
+824	
+823	
+822	
+821	
+820	
+819	
+818	
+817	
+816	
+815	
+814	
+813	
+812	
+811	
+810	
+809	
+808	
+807	
+806	
+805	
+804	
+803	
+802	
+801	
+800	
+799	
+798	
+797	
+796	
+795	
+794	
+793	
+792	
+791	
+790	
+789	
+788	
+787	
+786	
+785	
+784	
+783	
+782	
+781	
+780	
+779	
+778	
+777	
+776	
+775	
+774	
+773	
+772	
+771	
+770	
+769	
+768	
+767	
+766	
+765	
+764	
+763	
+762	
+761	
+760	
+759	
+758	
+757	
+756	
+755	
+754	
+753	
+752	
+751	
+750	
+749	
+748	
+747	
+746	
+745	
+744	
+743	
+742	
+741	
+740	
+739	
+738	
+737	
+736	
+735	
+734	
+733	
+732	
+731	
+730	
+729	
+728	
+727	
+726	
+725	
+724	
+723	
+722	
+721	
+720	
+719	
+718	
+717	
+716	
+715	
+714	
+713	
+712	
+711	
+710	
+709	
+708	
+707	
+706	
+705	
+704	
+703	
+702	
+701	
+700	
+699	
+698	
+697	
+696	
+695	
+694	
+693	
+692	
+691	
+690	
+689	
+688	
+687	
+686	
+685	
+684	
+683	
+682	
+681	
+680	
+679	
+678	
+677	
+676	
+675	
+674	
+673	
+672	
+671	
+670	
+669	
+668	
+667	
+666	
+665	
+664	
+663	
+662	
+661	
+660	
+659	
+658	
+657	
+656	
+655	
+654	
+653	
+652	
+651	
+650	
+649	
+648	
+647	
+646	
+645	
+644	
+643	
+642	
+641	
+640	
+639	
+638	
+637	
+636	
+635	
+634	
+633	
+632	
+631	
+630	
+629	
+628	
+627	
+626	
+625	
+624	
+623	
+622	
+621	
+620	
+619	
+618	
+617	
+616	
+615	
+614	
+613	
+612	
+611	
+610	
+609	
+608	
+607	
+606	
+605	
+604	
+603	
+602	
+601	
+600	
+599	
+598	
+597	
+596	
+595	
+594	
+593	
+592	
+591	
+590	
+589	
+588	
+587	
+586	
+585	
+584	
+583	
+582	
+581	
+580	
+579	
+578	
+577	
+576	
+575	
+574	
+573	
+572	
+571	
+570	
+569	
+568	
+567	
+566	
+565	
+564	
+563	
+562	
+561	
+560	
+559	
+558	
+557	
+556	
+555	
+554	
+553	
+552	
+551	
+550	
+549	
+548	
+547	
+546	
+545	
+544	
+543	
+542	
+541	
+540	
+539	
+538	
+537	
+536	
+535	
+534	
+533	
+532	
+531	
+530	
+529	
+528	
+527	
+526	
+525	
+524	
+523	
+522	
+521	
+520	
+519	
+518	
+517	
+516	
+515	
+514	
+513	
+512	
+511	
+510	
+509	
+508	
+507	
+506	
+505	
+504	
+503	
+502	
+501	
+500	
+499	
+498	
+497	
+496	
+495	
+494	
+493	
+492	
+491	
+490	
+489	
+488	
+487	
+486	
+485	
+484	
+483	
+482	
+481	
+480	
+479	
+478	
+477	
+476	
+475	
+474	
+473	
+472	
+471	
+470	
+469	
+468	
+467	
+466	
+465	
+464	
+463	
+462	
+461	
+460	
+459	
+458	
+457	
+456	
+455	
+454	
+453	
+452	
+451	
+450	
+449	
+448	
+447	
+446	
+445	
+444	
+443	
+442	
+441	
+440	
+439	
+438	
+437	
+436	
+435	
+434	
+433	
+432	
+431	
+430	
+429	
+428	
+427	
+426	
+425	
+424	
+423	
+422	
+421	
+420	
+419	
+418	
+417	
+416	
+415	
+414	
+413	
+412	
+411	
+410	
+409	
+408	
+407	
+406	
+405	
+404	
+403	
+402	
+401	
+400	
+399	
+398	
+397	
+396	
+395	
+394	
+393	
+392	
+391	
+390	
+389	
+388	
+387	
+386	
+385	
+384	
+383	
+382	
+381	
+380	
+379	
+378	
+377	
+376	
+375	
+374	
+373	
+372	
+371	
+370	
+369	
+368	
+367	
+366	
+365	
+364	
+363	
+362	
+361	
+360	
+359	
+358	
+357	
+356	
+355	
+354	
+353	
+352	
+351	
+350	
+349	
+348	
+347	
+346	
+345	
+344	
+343	
+342	
+341	
+340	
+339	
+338	
+337	
+336	
+335	
+334	
+333	
+332	
+331	
+330	
+329	
+328	
+327	
+326	
+325	
+324	
+323	
+322	
+321	
+320	
+319	
+318	
+317	
+316	
+315	
+314	
+313	
+312	
+311	
+310	
+309	
+308	
+307	
+306	
+305	
+304	
+303	
+302	
+301	
+300	
+299	
+298	
+297	
+296	
+295	
+294	
+293	
+292	
+291	
+290	
+289	
+288	
+287	
+286	
+285	
+284	
+283	
+282	
+281	
+280	
+279	
+278	
+277	
+276	
+275	
+274	
+273	
+272	
+271	
+270	
+269	
+268	
+267	
+266	
+265	
+264	
+263	
+262	
+261	
+260	
+259	
+258	
+257	
+256	
+255	
+254	
+253	
+252	
+251	
+250	
+249	
+248	
+247	
+246	
+245	
+244	
+243	
+242	
+241	
+240	
+239	
+238	
+237	
+236	
+235	
+234	
+233	
+232	
+231	
+230	
+229	
+228	
+227	
+226	
+225	
+224	
+223	
+222	
+221	
+220	
+219	
+218	
+217	
+216	
+215	
+214	
+213	
+212	
+211	
+210	
+209	
+208	
+207	
+206	
+205	
+204	
+203	
+202	
+201	
+200	
+199	
+198	
+197	
+196	
+195	
+194	
+193	
+192	
+191	
+190	
+189	
+188	
+187	
+186	
+185	
+184	
+183	
+182	
+181	
+180	
+179	
+178	
+177	
+176	
+175	
+174	
+173	
+172	
+171	
+170	
+169	
+168	
+167	
+166	
+165	
+164	
+163	
+162	
+161	
+160	
+159	
+158	
+157	
+156	
+155	
+154	
+153	
+152	
+151	
+150	
+149	
+148	
+147	
+146	
+145	
+144	
+143	
+142	
+141	
+140	
+139	
+138	
+137	
+136	
+135	
+134	
+133	
+132	
+131	
+130	
+129	
+128	
+127	
+126	
+125	
+124	
+123	
+122	
+121	
+120	
+119	
+118	
+117	
+116	
+115	
+114	
+113	
+112	
+111	
+110	
+109	
+108	
+107	
+106	
+105	
+104	
+103	
+102	
+101	
+100	
+99	
+98	
+97	
+96	
+95	
+94	
+93	
+92	
+91	
+90	
+89	
+88	
+87	
+86	
+85	
+84	
+83	
+82	
+81	
+80	
+79	
+78	
+77	
+76	
+75	
+74	
+73	
+72	
+71	
+70	
+69	
+68	
+67	
+66	
+65	
+64	
+63	
+62	
+61	
+60	
+59	
+58	
+57	
+56	
+55	
+54	
+53	
+52	
+51	
+50	
+49	
+48	
+47	
+46	
+45	
+44	
+43	
+42	
+41	
+40	
+39	
+38	
+37	
+36	
+35	
+34	
+33	
+32	
+31	
+30	
+29	
+28	
+27	
+26	
+25	
+24	
+23	
+22	
+21	
+20	
+19	
+18	
+17	
+16	
+15	
+14	
+13	
+12	
+11	
+10	
+9	
+8	
+7	
+6	
+5	
+4	
+3	
+2	
+1	
+0	
+@edgeset 
+		label	capacity	
+75	377	6906	27	
+417	515	6905	69	
+603	249	6904	80	
+246	344	6903	69	
+382	827	6902	19	
+714	879	6901	76	
+13	481	6900	22	
+863	754	6899	97	
+19	530	6898	64	
+122	597	6897	78	
+861	579	6896	17	
+266	888	6895	65	
+905	105	6894	81	
+516	501	6893	35	
+948	430	6892	86	
+398	535	6891	66	
+727	258	6890	70	
+223	322	6889	15	
+933	864	6888	84	
+17	604	6887	89	
+691	520	6886	26	
+782	843	6885	59	
+604	457	6884	36	
+70	492	6883	38	
+895	195	6882	56	
+277	968	6881	55	
+935	550	6880	67	
+457	306	6879	50	
+260	946	6878	29	
+84	636	6877	91	
+677	665	6876	32	
+385	234	6875	90	
+964	972	6874	17	
+296	819	6873	53	
+227	18	6872	17	
+418	879	6871	61	
+243	167	6870	34	
+359	212	6869	47	
+310	374	6868	19	
+970	590	6867	17	
+431	416	6866	40	
+261	730	6865	29	
+152	643	6864	42	
+800	358	6863	66	
+139	557	6862	6	
+711	276	6861	80	
+954	863	6860	17	
+838	279	6859	88	
+784	22	6858	4	
+173	767	6857	33	
+686	116	6856	53	
+87	870	6855	16	
+284	753	6854	10	
+801	599	6853	35	
+281	259	6852	66	
+412	635	6851	42	
+583	291	6850	75	
+257	833	6849	11	
+254	710	6848	5	
+651	799	6847	61	
+245	370	6846	48	
+117	60	6845	59	
+153	757	6844	80	
+339	690	6843	48	
+624	232	6842	52	
+343	671	6841	86	
+457	639	6840	82	
+123	62	6839	32	
+910	442	6838	0	
+429	124	6837	60	
+310	888	6836	40	
+303	796	6835	12	
+66	319	6834	96	
+457	963	6833	81	
+560	651	6832	71	
+32	39	6831	28	
+577	502	6830	88	
+620	323	6829	33	
+318	400	6828	21	
+235	196	6827	48	
+92	277	6826	11	
+477	164	6825	0	
+356	149	6824	23	
+311	98	6823	60	
+612	435	6822	89	
+537	394	6821	52	
+179	552	6820	45	
+923	121	6819	95	
+203	731	6818	30	
+918	362	6817	8	
+112	111	6816	14	
+15	770	6815	61	
+51	628	6814	12	
+663	711	6813	4	
+41	368	6812	69	
+841	73	6811	7	
+431	497	6810	35	
+389	655	6809	25	
+369	218	6808	71	
+250	939	6807	28	
+341	528	6806	80	
+141	493	6805	9	
+916	76	6804	96	
+343	345	6803	38	
+294	623	6802	62	
+575	717	6801	19	
+842	102	6800	41	
+437	535	6799	4	
+279	435	6798	2	
+410	478	6797	11	
+35	709	6796	90	
+417	132	6795	20	
+730	576	6794	22	
+722	766	6793	57	
+906	422	6792	4	
+615	788	6791	71	
+566	369	6790	73	
+100	21	6789	40	
+957	901	6788	15	
+769	209	6787	86	
+576	708	6786	37	
+556	975	6785	61	
+810	651	6784	68	
+343	524	6783	0	
+634	330	6782	81	
+418	984	6781	29	
+348	328	6780	4	
+119	246	6779	46	
+691	289	6778	14	
+501	492	6777	18	
+733	758	6776	19	
+324	930	6775	1	
+126	679	6774	74	
+194	192	6773	46	
+345	524	6772	70	
+656	242	6771	21	
+82	582	6770	7	
+956	322	6769	22	
+797	955	6768	42	
+734	994	6767	19	
+827	173	6766	76	
+251	273	6765	40	
+487	279	6764	19	
+667	757	6763	93	
+282	492	6762	84	
+659	145	6761	68	
+260	840	6760	57	
+366	801	6759	12	
+960	236	6758	15	
+821	422	6757	6	
+900	358	6756	90	
+993	211	6755	57	
+521	265	6754	76	
+265	83	6753	81	
+346	159	6752	38	
+304	114	6751	62	
+39	448	6750	39	
+565	965	6749	89	
+813	96	6748	40	
+64	155	6747	13	
+147	330	6746	92	
+945	812	6745	90	
+182	943	6744	47	
+923	434	6743	25	
+44	763	6742	91	
+666	222	6741	4	
+482	505	6740	26	
+869	487	6739	47	
+941	266	6738	75	
+825	217	6737	74	
+517	14	6736	91	
+868	435	6735	20	
+509	214	6734	76	
+671	338	6733	25	
+540	876	6732	87	
+717	776	6731	37	
+17	791	6730	18	
+221	721	6729	61	
+49	2	6728	92	
+202	831	6727	11	
+579	716	6726	30	
+220	437	6725	64	
+876	505	6724	35	
+462	379	6723	83	
+99	500	6722	13	
+984	195	6721	82	
+70	569	6720	69	
+719	685	6719	79	
+170	812	6718	17	
+115	806	6717	84	
+278	660	6716	62	
+932	288	6715	35	
+125	521	6714	34	
+879	707	6713	41	
+304	308	6712	36	
+626	123	6711	11	
+883	903	6710	91	
+873	624	6709	35	
+5	325	6708	54	
+146	223	6707	5	
+371	264	6706	83	
+767	14	6705	34	
+814	929	6704	80	
+399	52	6703	24	
+184	246	6702	57	
+219	201	6701	67	
+279	563	6700	74	
+298	801	6699	0	
+102	494	6698	86	
+959	217	6697	85	
+249	491	6696	77	
+84	538	6695	60	
+877	560	6694	95	
+805	671	6693	41	
+45	896	6692	21	
+637	935	6691	96	
+761	733	6690	94	
+307	142	6689	98	
+276	7	6688	19	
+725	85	6687	14	
+953	169	6686	70	
+977	650	6685	16	
+889	538	6684	20	
+775	200	6683	7	
+960	248	6682	75	
+202	24	6681	40	
+591	959	6680	87	
+134	785	6679	45	
+922	51	6678	3	
+915	433	6677	55	
+519	545	6676	77	
+112	957	6675	97	
+337	134	6674	8	
+952	312	6673	11	
+224	351	6672	81	
+64	532	6671	75	
+174	421	6670	61	
+733	422	6669	45	
+618	479	6668	21	
+888	778	6667	0	
+588	797	6666	39	
+822	886	6665	40	
+822	974	6664	77	
+960	299	6663	38	
+819	55	6662	72	
+110	147	6661	15	
+998	154	6660	89	
+943	244	6659	44	
+700	204	6658	11	
+981	610	6657	73	
+910	989	6656	29	
+912	631	6655	76	
+675	389	6654	0	
+243	657	6653	86	
+908	567	6652	14	
+993	268	6651	70	
+909	450	6650	11	
+39	324	6649	5	
+594	385	6648	24	
+620	430	6647	71	
+358	533	6646	7	
+242	765	6645	99	
+731	138	6644	23	
+89	720	6643	43	
+299	433	6642	33	
+818	596	6641	91	
+125	56	6640	8	
+939	813	6639	86	
+954	523	6638	44	
+896	647	6637	97	
+768	73	6636	26	
+627	760	6635	11	
+417	805	6634	51	
+287	96	6633	64	
+836	420	6632	79	
+539	831	6631	48	
+243	213	6630	69	
+290	423	6629	18	
+875	472	6628	98	
+574	710	6627	5	
+312	146	6626	12	
+955	605	6625	14	
+708	868	6624	20	
+676	850	6623	13	
+588	310	6622	45	
+617	787	6621	29	
+790	507	6620	29	
+951	201	6619	95	
+762	926	6618	41	
+563	930	6617	30	
+541	987	6616	26	
+736	930	6615	35	
+18	78	6614	24	
+540	680	6613	3	
+522	153	6612	8	
+280	0	6611	97	
+306	343	6610	82	
+274	538	6609	83	
+996	114	6608	18	
+942	38	6607	19	
+56	904	6606	2	
+851	111	6605	80	
+398	213	6604	71	
+526	944	6603	47	
+153	116	6602	1	
+657	143	6601	24	
+805	988	6600	97	
+423	650	6599	3	
+75	990	6598	27	
+133	175	6597	5	
+793	218	6596	88	
+897	86	6595	20	
+268	240	6594	45	
+828	459	6593	87	
+972	776	6592	37	
+155	266	6591	49	
+338	943	6590	85	
+660	753	6589	38	
+814	223	6588	34	
+957	169	6587	94	
+131	680	6586	34	
+845	751	6585	89	
+781	580	6584	62	
+683	498	6583	44	
+509	877	6582	85	
+323	644	6581	81	
+189	470	6580	81	
+529	33	6579	67	
+54	406	6578	84	
+488	601	6577	85	
+928	444	6576	82	
+171	267	6575	28	
+81	188	6574	6	
+621	585	6573	9	
+233	37	6572	17	
+173	0	6571	18	
+437	138	6570	13	
+627	832	6569	66	
+804	989	6568	47	
+157	30	6567	56	
+176	539	6566	56	
+79	222	6565	75	
+602	966	6564	8	
+547	923	6563	46	
+36	988	6562	38	
+861	51	6561	5	
+306	473	6560	73	
+842	185	6559	81	
+959	908	6558	82	
+490	5	6557	64	
+317	802	6556	98	
+255	668	6555	9	
+42	628	6554	47	
+935	72	6553	5	
+936	328	6552	51	
+578	323	6551	17	
+287	925	6550	55	
+277	987	6549	46	
+902	176	6548	88	
+203	665	6547	46	
+134	883	6546	17	
+39	621	6545	6	
+556	420	6544	21	
+743	544	6543	10	
+4	335	6542	99	
+398	619	6541	35	
+937	91	6540	29	
+811	580	6539	1	
+510	414	6538	37	
+782	295	6537	69	
+261	111	6536	6	
+200	848	6535	9	
+875	105	6534	48	
+209	107	6533	81	
+715	641	6532	73	
+528	67	6531	60	
+511	280	6530	46	
+165	635	6529	12	
+119	675	6528	30	
+183	630	6527	72	
+262	973	6526	52	
+743	612	6525	6	
+998	669	6524	32	
+466	74	6523	66	
+574	132	6522	49	
+786	145	6521	18	
+645	334	6520	1	
+959	824	6519	34	
+44	573	6518	4	
+657	206	6517	93	
+361	459	6516	92	
+942	736	6515	51	
+595	658	6514	74	
+941	172	6513	53	
+986	305	6512	89	
+810	170	6511	78	
+510	671	6510	14	
+250	299	6509	68	
+367	109	6508	91	
+746	15	6507	38	
+723	401	6506	29	
+77	774	6505	41	
+485	212	6504	34	
+866	640	6503	65	
+135	103	6502	95	
+499	647	6501	17	
+371	454	6500	30	
+190	771	6499	25	
+93	526	6498	88	
+614	92	6497	62	
+626	876	6496	2	
+562	71	6495	64	
+571	693	6494	59	
+537	698	6493	61	
+455	779	6492	73	
+193	875	6491	63	
+682	40	6490	12	
+245	376	6489	18	
+434	262	6488	9	
+215	597	6487	47	
+804	376	6486	98	
+378	54	6485	6	
+995	973	6484	99	
+919	886	6483	3	
+903	95	6482	8	
+834	508	6481	26	
+664	946	6480	51	
+113	84	6479	43	
+664	618	6478	81	
+221	490	6477	21	
+322	924	6476	41	
+80	72	6475	42	
+86	956	6474	38	
+791	952	6473	7	
+587	820	6472	1	
+562	750	6471	6	
+862	74	6470	16	
+465	626	6469	55	
+128	592	6468	44	
+565	806	6467	44	
+852	985	6466	89	
+116	42	6465	24	
+4	307	6464	99	
+132	60	6463	29	
+69	946	6462	20	
+676	899	6461	2	
+448	619	6460	70	
+33	101	6459	39	
+786	6	6458	33	
+821	544	6457	56	
+942	656	6456	71	
+735	246	6455	73	
+246	699	6454	11	
+114	90	6453	87	
+46	179	6452	6	
+279	324	6451	39	
+518	303	6450	22	
+94	58	6449	41	
+461	774	6448	24	
+887	849	6447	96	
+410	976	6446	87	
+546	624	6445	20	
+609	239	6444	48	
+911	810	6443	13	
+855	668	6442	6	
+20	165	6441	76	
+244	812	6440	76	
+283	168	6439	42	
+924	281	6438	63	
+872	86	6437	57	
+352	671	6436	47	
+384	718	6435	86	
+429	355	6434	93	
+141	65	6433	69	
+502	300	6432	5	
+352	5	6431	83	
+644	338	6430	77	
+886	790	6429	96	
+195	59	6428	35	
+415	96	6427	5	
+952	614	6426	51	
+363	925	6425	96	
+290	239	6424	95	
+765	642	6423	28	
+294	221	6422	63	
+667	58	6421	15	
+547	814	6420	70	
+731	601	6419	75	
+962	307	6418	69	
+481	532	6417	78	
+689	551	6416	46	
+685	14	6415	58	
+597	666	6414	7	
+420	649	6413	52	
+163	488	6412	47	
+243	441	6411	62	
+213	950	6410	11	
+294	66	6409	81	
+775	911	6408	76	
+980	317	6407	48	
+536	873	6406	79	
+347	516	6405	0	
+17	548	6404	8	
+160	54	6403	17	
+46	842	6402	25	
+491	508	6401	91	
+884	302	6400	3	
+154	48	6399	91	
+593	287	6398	51	
+444	688	6397	79	
+356	789	6396	44	
+968	915	6395	18	
+493	911	6394	33	
+212	920	6393	85	
+333	337	6392	11	
+205	889	6391	55	
+254	112	6390	60	
+760	398	6389	72	
+598	725	6388	56	
+899	350	6387	14	
+874	254	6386	8	
+4	858	6385	38	
+990	474	6384	47	
+583	742	6383	28	
+447	558	6382	87	
+777	947	6381	12	
+713	878	6380	95	
+673	168	6379	49	
+375	411	6378	16	
+95	61	6377	69	
+396	699	6376	2	
+384	913	6375	87	
+731	193	6374	1	
+183	403	6373	40	
+611	750	6372	13	
+69	177	6371	67	
+710	456	6370	6	
+756	332	6369	4	
+350	461	6368	29	
+362	675	6367	27	
+785	154	6366	69	
+720	856	6365	1	
+790	605	6364	65	
+652	272	6363	54	
+572	464	6362	57	
+720	607	6361	54	
+124	22	6360	35	
+870	742	6359	95	
+786	17	6358	40	
+520	580	6357	98	
+297	686	6356	57	
+251	359	6355	6	
+333	104	6354	93	
+807	975	6353	13	
+857	30	6352	8	
+584	182	6351	85	
+280	405	6350	59	
+724	547	6349	25	
+437	418	6348	8	
+893	410	6347	26	
+327	512	6346	22	
+254	133	6345	4	
+129	793	6344	91	
+945	56	6343	52	
+847	227	6342	94	
+777	256	6341	27	
+857	342	6340	30	
+129	169	6339	55	
+7	817	6338	28	
+897	43	6337	54	
+379	176	6336	56	
+339	128	6335	7	
+736	392	6334	12	
+828	576	6333	18	
+971	676	6332	9	
+913	969	6331	7	
+172	749	6330	91	
+352	267	6329	72	
+774	744	6328	12	
+867	977	6327	11	
+47	493	6326	51	
+736	947	6325	3	
+815	941	6324	60	
+899	85	6323	90	
+706	27	6322	85	
+220	150	6321	5	
+481	191	6320	74	
+522	607	6319	82	
+767	11	6318	57	
+483	592	6317	90	
+545	478	6316	81	
+5	436	6315	31	
+856	695	6314	92	
+58	50	6313	91	
+876	798	6312	19	
+959	317	6311	48	
+583	920	6310	73	
+595	242	6309	95	
+419	671	6308	75	
+113	86	6307	28	
+42	508	6306	93	
+740	390	6305	54	
+644	4	6304	14	
+251	722	6303	79	
+481	706	6302	18	
+396	747	6301	91	
+677	779	6300	37	
+571	203	6299	98	
+584	471	6298	17	
+578	345	6297	30	
+118	397	6296	7	
+386	391	6295	30	
+281	350	6294	9	
+16	617	6293	39	
+958	263	6292	77	
+968	541	6291	8	
+575	387	6290	71	
+732	811	6289	10	
+125	870	6288	98	
+948	235	6287	0	
+5	768	6286	45	
+40	205	6285	73	
+733	703	6284	10	
+353	622	6283	26	
+722	685	6282	5	
+154	365	6281	99	
+576	612	6280	39	
+940	120	6279	84	
+635	979	6278	60	
+466	546	6277	17	
+563	727	6276	94	
+501	627	6275	96	
+80	838	6274	30	
+937	208	6273	38	
+319	67	6272	63	
+753	597	6271	56	
+492	549	6270	57	
+140	235	6269	63	
+433	430	6268	30	
+818	233	6267	16	
+100	977	6266	90	
+789	658	6265	6	
+630	925	6264	42	
+141	749	6263	14	
+469	62	6262	61	
+47	990	6261	56	
+313	941	6260	26	
+805	331	6259	35	
+196	135	6258	70	
+256	266	6257	61	
+318	841	6256	71	
+732	640	6255	31	
+176	277	6254	15	
+687	526	6253	48	
+72	50	6252	67	
+48	305	6251	42	
+610	909	6250	73	
+196	644	6249	50	
+868	92	6248	60	
+424	895	6247	93	
+201	407	6246	93	
+362	152	6245	58	
+750	669	6244	55	
+475	817	6243	48	
+745	249	6242	61	
+395	688	6241	2	
+264	225	6240	43	
+551	898	6239	41	
+197	669	6238	32	
+487	2	6237	44	
+255	351	6236	22	
+483	29	6235	83	
+851	67	6234	61	
+568	874	6233	27	
+560	591	6232	73	
+463	584	6231	34	
+326	25	6230	13	
+228	86	6229	71	
+667	883	6228	35	
+651	220	6227	70	
+321	385	6226	23	
+961	226	6225	77	
+193	336	6224	63	
+282	544	6223	28	
+7	380	6222	0	
+559	219	6221	9	
+939	417	6220	13	
+202	358	6219	9	
+663	645	6218	56	
+834	477	6217	1	
+158	459	6216	32	
+889	140	6215	36	
+792	349	6214	76	
+164	274	6213	91	
+161	911	6212	27	
+801	960	6211	44	
+59	38	6210	61	
+712	536	6209	73	
+167	545	6208	53	
+18	686	6207	82	
+318	969	6206	67	
+791	591	6205	26	
+74	857	6204	9	
+362	635	6203	62	
+951	827	6202	0	
+921	828	6201	36	
+502	882	6200	74	
+990	198	6199	34	
+858	709	6198	54	
+717	153	6197	14	
+377	406	6196	69	
+734	172	6195	52	
+222	469	6194	71	
+808	625	6193	71	
+998	642	6192	41	
+945	618	6191	3	
+684	394	6190	41	
+489	801	6189	51	
+556	396	6188	13	
+747	449	6187	14	
+233	172	6186	34	
+703	810	6185	64	
+843	4	6184	51	
+982	300	6183	41	
+24	381	6182	80	
+223	612	6181	5	
+593	906	6180	26	
+405	380	6179	19	
+946	990	6178	93	
+276	800	6177	80	
+362	697	6176	51	
+805	131	6175	53	
+704	97	6174	85	
+919	604	6173	86	
+768	757	6172	95	
+705	790	6171	80	
+525	66	6170	63	
+389	262	6169	18	
+190	123	6168	45	
+103	295	6167	67	
+566	983	6166	91	
+33	670	6165	55	
+493	998	6164	10	
+847	902	6163	78	
+966	157	6162	15	
+724	170	6161	6	
+804	441	6160	17	
+138	729	6159	13	
+828	788	6158	19	
+312	756	6157	8	
+312	356	6156	53	
+671	455	6155	53	
+96	316	6154	53	
+744	633	6153	64	
+987	87	6152	88	
+728	882	6151	24	
+712	43	6150	91	
+941	936	6149	66	
+31	112	6148	30	
+399	550	6147	51	
+900	3	6146	99	
+139	993	6145	64	
+682	893	6144	57	
+546	765	6143	35	
+204	638	6142	75	
+839	322	6141	25	
+106	253	6140	1	
+824	356	6139	77	
+562	793	6138	90	
+546	516	6137	63	
+9	359	6136	49	
+100	65	6135	76	
+127	223	6134	45	
+126	595	6133	13	
+316	497	6132	34	
+69	242	6131	36	
+896	246	6130	73	
+562	860	6129	28	
+277	277	6128	26	
+156	132	6127	1	
+293	737	6126	53	
+842	305	6125	90	
+628	319	6124	97	
+97	795	6123	0	
+255	976	6122	81	
+996	632	6121	24	
+385	450	6120	17	
+582	20	6119	33	
+145	245	6118	28	
+395	478	6117	12	
+432	626	6116	86	
+985	937	6115	45	
+524	971	6114	21	
+819	190	6113	53	
+343	563	6112	84	
+182	73	6111	25	
+429	839	6110	61	
+774	48	6109	80	
+767	164	6108	43	
+852	257	6107	75	
+689	411	6106	96	
+966	237	6105	44	
+780	683	6104	46	
+626	688	6103	70	
+490	583	6102	47	
+234	647	6101	16	
+791	807	6100	75	
+883	365	6099	65	
+906	687	6098	0	
+845	787	6097	91	
+174	515	6096	16	
+554	986	6095	72	
+994	755	6094	18	
+104	229	6093	15	
+935	315	6092	13	
+839	407	6091	25	
+442	99	6090	44	
+678	646	6089	90	
+899	92	6088	97	
+272	752	6087	6	
+528	439	6086	67	
+231	537	6085	62	
+525	31	6084	55	
+914	18	6083	88	
+908	880	6082	16	
+307	812	6081	9	
+452	536	6080	39	
+553	929	6079	76	
+340	916	6078	77	
+312	389	6077	62	
+902	51	6076	74	
+506	60	6075	29	
+13	669	6074	70	
+137	720	6073	61	
+67	72	6072	0	
+276	698	6071	60	
+606	633	6070	85	
+13	985	6069	89	
+526	151	6068	21	
+337	882	6067	2	
+991	447	6066	41	
+390	590	6065	39	
+948	95	6064	49	
+648	604	6063	87	
+374	405	6062	7	
+64	744	6061	79	
+648	956	6060	66	
+833	685	6059	59	
+269	185	6058	48	
+434	617	6057	18	
+857	13	6056	34	
+494	903	6055	60	
+490	617	6054	44	
+198	805	6053	30	
+661	278	6052	27	
+787	121	6051	30	
+271	76	6050	41	
+500	105	6049	81	
+567	298	6048	56	
+604	842	6047	83	
+110	746	6046	57	
+285	157	6045	36	
+812	141	6044	0	
+526	26	6043	29	
+156	965	6042	53	
+44	893	6041	87	
+971	600	6040	51	
+807	251	6039	77	
+456	729	6038	93	
+95	257	6037	96	
+588	213	6036	49	
+15	359	6035	82	
+115	712	6034	47	
+61	753	6033	28	
+71	664	6032	36	
+292	356	6031	11	
+349	745	6030	7	
+521	837	6029	16	
+472	970	6028	35	
+43	469	6027	36	
+854	667	6026	50	
+646	352	6025	57	
+958	186	6024	90	
+89	915	6023	5	
+307	257	6022	98	
+611	38	6021	77	
+907	910	6020	94	
+867	811	6019	82	
+500	991	6018	4	
+802	854	6017	42	
+314	933	6016	18	
+166	672	6015	20	
+271	845	6014	68	
+657	65	6013	86	
+219	209	6012	78	
+127	836	6011	69	
+99	114	6010	70	
+820	778	6009	3	
+136	621	6008	36	
+920	238	6007	69	
+260	981	6006	48	
+827	519	6005	14	
+779	819	6004	89	
+855	87	6003	61	
+373	85	6002	43	
+721	991	6001	9	
+336	664	6000	2	
+157	671	5999	27	
+382	669	5998	68	
+256	210	5997	21	
+462	338	5996	66	
+699	253	5995	43	
+731	281	5994	4	
+1	174	5993	92	
+94	346	5992	48	
+326	63	5991	65	
+993	749	5990	38	
+2	595	5989	17	
+459	467	5988	77	
+871	555	5987	12	
+85	226	5986	79	
+971	385	5985	76	
+106	123	5984	96	
+828	441	5983	73	
+283	831	5982	90	
+313	265	5981	76	
+153	206	5980	33	
+128	403	5979	99	
+911	649	5978	54	
+329	331	5977	58	
+840	31	5976	78	
+262	794	5975	11	
+682	237	5974	86	
+609	823	5973	27	
+565	139	5972	54	
+58	434	5971	96	
+803	342	5970	15	
+754	447	5969	2	
+317	955	5968	21	
+300	801	5967	58	
+236	672	5966	48	
+557	248	5965	57	
+414	586	5964	57	
+684	733	5963	7	
+704	575	5962	4	
+91	809	5961	50	
+894	133	5960	25	
+492	809	5959	4	
+153	634	5958	43	
+129	93	5957	1	
+424	909	5956	6	
+661	998	5955	67	
+853	506	5954	14	
+157	29	5953	73	
+765	536	5952	97	
+676	251	5951	61	
+324	207	5950	19	
+175	611	5949	40	
+540	419	5948	33	
+184	953	5947	2	
+911	384	5946	70	
+492	536	5945	76	
+477	412	5944	80	
+492	750	5943	69	
+285	367	5942	39	
+43	415	5941	8	
+595	795	5940	35	
+192	62	5939	14	
+465	315	5938	63	
+569	319	5937	35	
+847	941	5936	27	
+123	955	5935	41	
+662	111	5934	1	
+383	305	5933	98	
+951	301	5932	20	
+619	737	5931	24	
+733	202	5930	44	
+746	513	5929	40	
+995	279	5928	72	
+378	82	5927	89	
+986	854	5926	72	
+844	403	5925	72	
+806	30	5924	46	
+3	776	5923	27	
+563	965	5922	43	
+534	793	5921	33	
+689	44	5920	88	
+234	677	5919	98	
+196	829	5918	75	
+228	175	5917	61	
+450	997	5916	39	
+373	262	5915	14	
+253	182	5914	3	
+810	847	5913	80	
+172	99	5912	43	
+748	445	5911	2	
+367	899	5910	84	
+848	236	5909	45	
+654	132	5908	3	
+177	225	5907	96	
+735	250	5906	77	
+80	103	5905	7	
+334	235	5904	11	
+748	363	5903	44	
+653	410	5902	63	
+546	183	5901	42	
+662	390	5900	38	
+103	417	5899	51	
+907	70	5898	19	
+975	189	5897	47	
+146	701	5896	44	
+868	957	5895	65	
+871	676	5894	74	
+952	804	5893	58	
+227	214	5892	9	
+792	41	5891	10	
+972	862	5890	88	
+347	325	5889	55	
+880	716	5888	19	
+487	34	5887	93	
+743	786	5886	82	
+280	909	5885	27	
+872	159	5884	99	
+590	492	5883	91	
+172	987	5882	72	
+179	223	5881	43	
+537	324	5880	81	
+608	363	5879	62	
+681	264	5878	46	
+248	101	5877	39	
+877	552	5876	74	
+750	280	5875	46	
+667	77	5874	40	
+505	193	5873	28	
+763	290	5872	41	
+899	614	5871	99	
+961	194	5870	64	
+98	158	5869	92	
+162	73	5868	92	
+549	648	5867	43	
+271	280	5866	37	
+203	54	5865	12	
+883	126	5864	8	
+902	864	5863	16	
+676	424	5862	74	
+420	351	5861	86	
+35	712	5860	93	
+85	2	5859	86	
+424	493	5858	93	
+368	62	5857	61	
+226	244	5856	27	
+928	42	5855	6	
+261	921	5854	31	
+440	420	5853	98	
+72	877	5852	22	
+639	925	5851	25	
+710	75	5850	38	
+508	927	5849	95	
+431	322	5848	66	
+817	334	5847	5	
+202	210	5846	14	
+121	748	5845	29	
+501	338	5844	66	
+542	754	5843	82	
+952	970	5842	36	
+849	871	5841	43	
+148	434	5840	92	
+604	289	5839	20	
+988	603	5838	7	
+123	914	5837	61	
+462	844	5836	61	
+409	631	5835	8	
+584	845	5834	61	
+783	453	5833	95	
+99	935	5832	58	
+436	504	5831	10	
+144	726	5830	70	
+686	124	5829	54	
+689	464	5828	61	
+70	998	5827	86	
+212	534	5826	66	
+786	461	5825	5	
+392	660	5824	82	
+517	369	5823	80	
+431	487	5822	68	
+777	401	5821	66	
+602	157	5820	29	
+659	927	5819	45	
+465	751	5818	99	
+464	203	5817	61	
+72	608	5816	85	
+800	227	5815	42	
+291	23	5814	39	
+881	117	5813	87	
+85	21	5812	8	
+243	370	5811	65	
+230	833	5810	17	
+175	461	5809	94	
+548	378	5808	19	
+594	760	5807	0	
+380	432	5806	39	
+204	31	5805	27	
+905	519	5804	50	
+96	787	5803	40	
+650	432	5802	79	
+536	479	5801	84	
+372	231	5800	1	
+82	748	5799	5	
+618	192	5798	62	
+328	609	5797	95	
+400	120	5796	21	
+512	762	5795	17	
+731	99	5794	29	
+354	613	5793	80	
+953	954	5792	44	
+247	829	5791	11	
+482	958	5790	16	
+555	427	5789	28	
+583	673	5788	46	
+489	740	5787	29	
+357	37	5786	92	
+662	877	5785	88	
+486	489	5784	78	
+659	364	5783	37	
+124	331	5782	40	
+871	949	5781	70	
+530	874	5780	76	
+754	826	5779	92	
+933	173	5778	97	
+702	362	5777	9	
+160	40	5776	13	
+387	107	5775	69	
+124	403	5774	17	
+33	975	5773	82	
+381	695	5772	53	
+74	940	5771	25	
+48	838	5770	34	
+652	953	5769	77	
+810	879	5768	82	
+322	961	5767	23	
+932	436	5766	54	
+704	519	5765	77	
+427	348	5764	26	
+279	293	5763	9	
+755	280	5762	65	
+101	913	5761	30	
+884	564	5760	2	
+74	955	5759	39	
+917	590	5758	84	
+525	688	5757	48	
+916	768	5756	38	
+170	510	5755	22	
+55	171	5754	27	
+12	439	5753	14	
+366	345	5752	52	
+349	280	5751	65	
+609	630	5750	21	
+364	553	5749	81	
+901	354	5748	15	
+919	98	5747	39	
+258	161	5746	60	
+339	951	5745	74	
+731	129	5744	11	
+94	623	5743	4	
+64	870	5742	64	
+649	436	5741	1	
+77	406	5740	73	
+198	653	5739	24	
+256	764	5738	46	
+936	784	5737	98	
+210	862	5736	66	
+822	631	5735	91	
+505	72	5734	60	
+753	396	5733	63	
+433	627	5732	2	
+29	278	5731	41	
+753	495	5730	57	
+889	781	5729	87	
+980	481	5728	94	
+921	320	5727	31	
+231	741	5726	72	
+558	312	5725	38	
+675	970	5724	31	
+769	607	5723	75	
+349	614	5722	31	
+782	842	5721	40	
+713	693	5720	27	
+300	936	5719	86	
+160	623	5718	90	
+578	592	5717	5	
+429	338	5716	69	
+341	70	5715	67	
+363	565	5714	88	
+992	432	5713	90	
+771	914	5712	41	
+149	128	5711	56	
+757	411	5710	6	
+313	955	5709	41	
+30	850	5708	13	
+253	367	5707	58	
+268	18	5706	14	
+505	788	5705	8	
+132	976	5704	97	
+517	487	5703	37	
+786	852	5702	22	
+716	498	5701	62	
+456	655	5700	39	
+104	274	5699	44	
+483	557	5698	28	
+348	433	5697	77	
+229	60	5696	98	
+811	109	5695	76	
+489	608	5694	37	
+635	149	5693	61	
+354	598	5692	73	
+842	229	5691	6	
+380	948	5690	26	
+717	161	5689	35	
+123	505	5688	62	
+372	791	5687	13	
+950	222	5686	11	
+501	389	5685	41	
+459	758	5684	32	
+550	883	5683	85	
+368	661	5682	28	
+281	809	5681	51	
+787	908	5680	46	
+655	730	5679	66	
+713	486	5678	59	
+569	15	5677	75	
+833	701	5676	42	
+630	95	5675	44	
+875	467	5674	4	
+221	573	5673	90	
+851	769	5672	18	
+901	49	5671	8	
+177	798	5670	49	
+244	69	5669	13	
+471	842	5668	94	
+314	329	5667	14	
+606	972	5666	73	
+627	406	5665	20	
+894	133	5664	75	
+803	727	5663	65	
+720	93	5662	37	
+250	593	5661	94	
+729	361	5660	72	
+227	190	5659	93	
+512	797	5658	77	
+357	409	5657	15	
+565	532	5656	70	
+272	448	5655	97	
+405	101	5654	73	
+634	283	5653	9	
+499	420	5652	8	
+231	225	5651	46	
+171	791	5650	52	
+392	160	5649	50	
+387	615	5648	71	
+876	448	5647	15	
+84	729	5646	79	
+346	244	5645	29	
+817	642	5644	86	
+862	7	5643	77	
+195	613	5642	13	
+433	947	5641	26	
+631	19	5640	5	
+544	787	5639	77	
+166	558	5638	0	
+719	364	5637	51	
+484	498	5636	79	
+602	425	5635	73	
+634	95	5634	52	
+394	637	5633	95	
+665	866	5632	66	
+928	208	5631	76	
+232	280	5630	80	
+228	773	5629	8	
+194	494	5628	37	
+866	718	5627	44	
+72	55	5626	23	
+330	208	5625	88	
+458	573	5624	96	
+770	287	5623	23	
+658	905	5622	72	
+927	958	5621	73	
+506	716	5620	69	
+279	709	5619	0	
+776	929	5618	3	
+662	213	5617	32	
+846	351	5616	79	
+634	914	5615	74	
+285	727	5614	87	
+382	510	5613	68	
+946	992	5612	11	
+242	41	5611	73	
+6	691	5610	42	
+779	969	5609	22	
+715	706	5608	50	
+861	534	5607	11	
+437	52	5606	81	
+186	869	5605	21	
+217	183	5604	34	
+518	576	5603	90	
+950	380	5602	43	
+349	311	5601	70	
+722	192	5600	23	
+263	724	5599	22	
+172	389	5598	6	
+481	297	5597	85	
+182	604	5596	42	
+686	863	5595	25	
+607	445	5594	96	
+196	468	5593	69	
+69	731	5592	56	
+118	467	5591	60	
+468	9	5590	62	
+334	163	5589	45	
+92	209	5588	9	
+693	429	5587	69	
+740	174	5586	29	
+417	280	5585	49	
+977	270	5584	7	
+736	131	5583	41	
+263	967	5582	12	
+458	972	5581	95	
+845	169	5580	65	
+953	367	5579	13	
+780	401	5578	24	
+254	390	5577	39	
+893	803	5576	95	
+10	417	5575	32	
+139	667	5574	44	
+163	284	5573	24	
+994	176	5572	47	
+803	300	5571	80	
+802	516	5570	61	
+966	891	5569	89	
+10	842	5568	17	
+586	446	5567	52	
+386	629	5566	36	
+749	882	5565	88	
+383	200	5564	87	
+107	767	5563	97	
+875	668	5562	16	
+784	191	5561	19	
+624	720	5560	0	
+48	720	5559	83	
+395	646	5558	95	
+817	165	5557	42	
+747	477	5556	20	
+682	12	5555	63	
+432	895	5554	36	
+99	806	5553	27	
+476	977	5552	23	
+471	190	5551	9	
+0	165	5550	15	
+73	880	5549	57	
+481	531	5548	65	
+687	223	5547	57	
+465	563	5546	7	
+116	271	5545	6	
+89	89	5544	24	
+828	44	5543	33	
+787	140	5542	62	
+24	932	5541	0	
+284	583	5540	47	
+349	922	5539	92	
+307	75	5538	59	
+660	507	5537	79	
+291	5	5536	22	
+181	815	5535	34	
+45	917	5534	2	
+903	708	5533	26	
+208	619	5532	4	
+348	533	5531	76	
+661	544	5530	74	
+847	334	5529	93	
+567	798	5528	4	
+502	571	5527	64	
+189	872	5526	36	
+897	323	5525	11	
+208	765	5524	13	
+89	220	5523	14	
+86	277	5522	69	
+988	22	5521	85	
+209	805	5520	68	
+536	892	5519	81	
+226	395	5518	28	
+699	277	5517	6	
+549	258	5516	31	
+557	974	5515	29	
+544	993	5514	68	
+942	446	5513	11	
+254	835	5512	0	
+217	173	5511	9	
+912	873	5510	77	
+497	533	5509	67	
+117	216	5508	31	
+19	751	5507	52	
+283	21	5506	14	
+981	603	5505	99	
+546	569	5504	1	
+611	116	5503	60	
+662	905	5502	68	
+300	319	5501	3	
+339	104	5500	30	
+317	363	5499	41	
+465	783	5498	37	
+729	377	5497	9	
+417	157	5496	73	
+33	978	5495	30	
+452	411	5494	43	
+211	913	5493	93	
+585	650	5492	94	
+214	732	5491	36	
+741	889	5490	96	
+580	35	5489	2	
+405	281	5488	85	
+219	362	5487	73	
+179	434	5486	31	
+566	867	5485	38	
+497	499	5484	58	
+263	986	5483	24	
+918	586	5482	62	
+842	402	5481	37	
+854	938	5480	47	
+754	170	5479	16	
+919	116	5478	17	
+928	423	5477	18	
+566	928	5476	4	
+367	803	5475	61	
+512	338	5474	6	
+400	616	5473	23	
+184	254	5472	34	
+464	898	5471	7	
+767	311	5470	98	
+53	986	5469	9	
+693	988	5468	83	
+494	145	5467	99	
+125	427	5466	36	
+464	543	5465	19	
+722	834	5464	85	
+362	889	5463	11	
+355	268	5462	21	
+586	88	5461	71	
+324	887	5460	69	
+998	264	5459	71	
+843	844	5458	35	
+717	629	5457	19	
+884	162	5456	36	
+708	343	5455	66	
+945	744	5454	74	
+621	894	5453	35	
+179	496	5452	0	
+200	23	5451	76	
+623	982	5450	26	
+419	354	5449	32	
+215	161	5448	15	
+466	828	5447	12	
+819	708	5446	83	
+598	919	5445	17	
+849	381	5444	76	
+397	353	5443	32	
+473	237	5442	44	
+41	506	5441	97	
+628	936	5440	57	
+192	171	5439	20	
+332	29	5438	20	
+119	291	5437	74	
+789	658	5436	64	
+537	411	5435	22	
+28	439	5434	74	
+115	882	5433	45	
+731	462	5432	92	
+569	401	5431	43	
+765	374	5430	41	
+141	998	5429	43	
+737	456	5428	86	
+633	100	5427	21	
+246	427	5426	33	
+971	471	5425	25	
+557	296	5424	50	
+419	527	5423	91	
+61	492	5422	38	
+27	19	5421	16	
+375	977	5420	80	
+542	574	5419	62	
+355	648	5418	40	
+673	882	5417	10	
+956	77	5416	38	
+174	743	5415	27	
+769	595	5414	41	
+35	528	5413	13	
+472	222	5412	35	
+41	357	5411	3	
+402	181	5410	65	
+926	219	5409	83	
+765	299	5408	18	
+804	717	5407	68	
+333	112	5406	71	
+148	860	5405	78	
+66	275	5404	40	
+306	780	5403	73	
+865	323	5402	56	
+176	381	5401	43	
+961	819	5400	63	
+919	646	5399	47	
+582	504	5398	16	
+604	965	5397	96	
+251	934	5396	47	
+585	376	5395	18	
+494	671	5394	8	
+456	170	5393	76	
+941	131	5392	44	
+562	791	5391	68	
+172	163	5390	21	
+142	315	5389	4	
+538	199	5388	33	
+30	490	5387	97	
+558	285	5386	35	
+704	103	5385	66	
+501	320	5384	9	
+38	320	5383	3	
+339	751	5382	51	
+628	474	5381	37	
+848	172	5380	38	
+115	704	5379	3	
+709	360	5378	60	
+204	624	5377	50	
+181	686	5376	47	
+783	575	5375	85	
+0	52	5374	20	
+569	523	5373	46	
+276	135	5372	69	
+302	989	5371	71	
+468	359	5370	78	
+343	427	5369	73	
+736	96	5368	40	
+937	35	5367	50	
+110	619	5366	2	
+523	649	5365	39	
+529	741	5364	78	
+387	762	5363	43	
+146	988	5362	29	
+630	930	5361	97	
+932	47	5360	83	
+330	326	5359	12	
+61	901	5358	60	
+415	481	5357	79	
+969	624	5356	82	
+907	614	5355	58	
+978	352	5354	99	
+774	138	5353	14	
+57	318	5352	24	
+882	140	5351	51	
+721	708	5350	69	
+425	516	5349	60	
+419	809	5348	26	
+857	971	5347	64	
+10	239	5346	44	
+262	592	5345	6	
+214	853	5344	92	
+819	899	5343	20	
+178	725	5342	71	
+431	818	5341	17	
+192	96	5340	16	
+707	331	5339	29	
+838	624	5338	0	
+731	199	5337	56	
+647	384	5336	84	
+739	132	5335	74	
+953	725	5334	4	
+174	486	5333	39	
+907	542	5332	64	
+721	13	5331	74	
+765	865	5330	23	
+707	289	5329	48	
+425	443	5328	86	
+814	715	5327	10	
+252	99	5326	8	
+406	699	5325	90	
+239	653	5324	78	
+943	752	5323	77	
+529	894	5322	26	
+147	507	5321	18	
+575	754	5320	95	
+846	615	5319	5	
+728	762	5318	28	
+615	22	5317	61	
+399	176	5316	56	
+45	121	5315	84	
+900	8	5314	16	
+857	511	5313	29	
+387	81	5312	41	
+752	230	5311	38	
+138	897	5310	57	
+852	776	5309	72	
+740	670	5308	11	
+845	48	5307	11	
+55	717	5306	21	
+113	677	5305	35	
+496	871	5304	14	
+429	882	5303	4	
+850	31	5302	47	
+332	810	5301	63	
+120	842	5300	61	
+105	612	5299	28	
+622	3	5298	11	
+330	897	5297	89	
+39	861	5296	78	
+806	209	5295	94	
+989	101	5294	61	
+851	572	5293	6	
+220	835	5292	57	
+968	21	5291	51	
+229	327	5290	21	
+608	174	5289	1	
+106	216	5288	48	
+36	105	5287	29	
+651	847	5286	29	
+108	326	5285	23	
+528	549	5284	81	
+737	487	5283	13	
+813	60	5282	63	
+694	305	5281	25	
+153	197	5280	73	
+957	532	5279	62	
+111	190	5278	50	
+257	1	5277	7	
+521	57	5276	38	
+777	416	5275	54	
+61	679	5274	57	
+426	506	5273	79	
+754	379	5272	92	
+108	512	5271	11	
+664	117	5270	54	
+341	119	5269	19	
+188	431	5268	84	
+944	685	5267	85	
+640	840	5266	73	
+736	964	5265	74	
+173	788	5264	71	
+126	866	5263	63	
+866	804	5262	67	
+394	578	5261	64	
+998	344	5260	44	
+687	349	5259	32	
+745	992	5258	15	
+845	116	5257	24	
+876	992	5256	30	
+175	28	5255	90	
+922	81	5254	56	
+61	962	5253	4	
+225	25	5252	26	
+233	201	5251	47	
+995	120	5250	39	
+357	170	5249	31	
+875	908	5248	94	
+124	940	5247	90	
+964	399	5246	96	
+946	340	5245	70	
+119	517	5244	25	
+936	786	5243	86	
+823	788	5242	83	
+80	75	5241	99	
+950	86	5240	23	
+261	368	5239	63	
+968	41	5238	48	
+540	932	5237	75	
+59	266	5236	15	
+822	448	5235	1	
+731	392	5234	82	
+997	24	5233	18	
+712	843	5232	11	
+988	753	5231	74	
+717	601	5230	13	
+326	155	5229	68	
+109	730	5228	29	
+665	592	5227	42	
+818	142	5226	48	
+55	189	5225	23	
+368	644	5224	9	
+180	70	5223	73	
+90	369	5222	28	
+151	612	5221	72	
+445	440	5220	27	
+425	396	5219	39	
+137	865	5218	21	
+449	946	5217	44	
+952	244	5216	84	
+544	145	5215	76	
+574	357	5214	68	
+700	448	5213	18	
+756	561	5212	8	
+172	452	5211	93	
+43	880	5210	70	
+531	173	5209	1	
+918	773	5208	28	
+702	597	5207	68	
+98	83	5206	49	
+788	76	5205	40	
+909	499	5204	97	
+887	97	5203	87	
+108	151	5202	94	
+572	232	5201	58	
+707	686	5200	12	
+399	731	5199	51	
+176	599	5198	61	
+513	190	5197	21	
+6	90	5196	60	
+577	436	5195	31	
+401	96	5194	87	
+946	929	5193	2	
+919	360	5192	77	
+545	455	5191	53	
+954	617	5190	86	
+132	898	5189	30	
+409	397	5188	22	
+99	611	5187	66	
+653	294	5186	50	
+340	431	5185	42	
+167	856	5184	17	
+569	242	5183	45	
+905	243	5182	2	
+837	669	5181	37	
+718	557	5180	59	
+501	85	5179	82	
+785	559	5178	72	
+317	155	5177	30	
+862	77	5176	44	
+574	253	5175	31	
+614	721	5174	17	
+999	427	5173	59	
+573	653	5172	66	
+111	783	5171	6	
+472	768	5170	11	
+525	100	5169	21	
+404	412	5168	71	
+78	863	5167	46	
+824	133	5166	45	
+531	140	5165	28	
+294	575	5164	96	
+774	933	5163	61	
+870	597	5162	42	
+14	947	5161	46	
+667	903	5160	63	
+687	499	5159	94	
+549	249	5158	12	
+730	12	5157	32	
+992	166	5156	25	
+564	328	5155	29	
+641	345	5154	23	
+336	188	5153	52	
+649	963	5152	90	
+44	822	5151	85	
+403	692	5150	34	
+250	825	5149	98	
+237	795	5148	13	
+845	71	5147	81	
+838	961	5146	73	
+982	54	5145	42	
+156	717	5144	92	
+225	616	5143	30	
+141	48	5142	68	
+130	508	5141	60	
+866	366	5140	64	
+30	842	5139	15	
+723	318	5138	1	
+109	82	5137	39	
+907	309	5136	0	
+336	505	5135	85	
+101	617	5134	82	
+568	618	5133	93	
+539	82	5132	8	
+141	964	5131	1	
+523	487	5130	26	
+524	140	5129	83	
+236	620	5128	30	
+772	384	5127	61	
+803	150	5126	20	
+887	30	5125	57	
+998	893	5124	23	
+536	848	5123	53	
+118	72	5122	2	
+476	748	5121	39	
+347	426	5120	61	
+519	530	5119	99	
+236	692	5118	28	
+234	411	5117	46	
+120	630	5116	96	
+136	336	5115	91	
+45	701	5114	88	
+776	505	5113	46	
+323	630	5112	41	
+321	779	5111	64	
+896	618	5110	12	
+837	711	5109	82	
+281	824	5108	28	
+780	494	5107	0	
+294	53	5106	11	
+634	26	5105	98	
+196	426	5104	9	
+875	44	5103	26	
+850	776	5102	45	
+160	512	5101	0	
+907	301	5100	42	
+887	544	5099	5	
+329	281	5098	55	
+441	888	5097	50	
+26	129	5096	48	
+600	893	5095	65	
+382	821	5094	43	
+267	817	5093	32	
+264	450	5092	2	
+211	576	5091	68	
+757	367	5090	25	
+262	502	5089	1	
+393	55	5088	55	
+758	14	5087	88	
+236	826	5086	41	
+72	220	5085	42	
+3	118	5084	21	
+366	295	5083	11	
+874	335	5082	0	
+208	435	5081	5	
+864	233	5080	45	
+446	461	5079	49	
+41	670	5078	86	
+187	472	5077	63	
+606	989	5076	52	
+102	208	5075	16	
+822	102	5074	6	
+959	112	5073	63	
+900	949	5072	49	
+201	599	5071	66	
+772	959	5070	34	
+791	624	5069	41	
+197	235	5068	40	
+483	111	5067	85	
+780	359	5066	58	
+106	95	5065	50	
+990	431	5064	27	
+162	144	5063	86	
+350	826	5062	5	
+639	321	5061	69	
+335	926	5060	42	
+388	12	5059	98	
+124	551	5058	59	
+752	272	5057	71	
+264	77	5056	70	
+663	223	5055	67	
+287	417	5054	11	
+317	803	5053	82	
+505	360	5052	81	
+395	269	5051	71	
+913	448	5050	30	
+460	387	5049	94	
+279	879	5048	26	
+194	11	5047	37	
+854	29	5046	48	
+806	557	5045	60	
+613	288	5044	37	
+442	16	5043	96	
+91	100	5042	81	
+821	407	5041	11	
+60	357	5040	48	
+508	681	5039	45	
+867	892	5038	18	
+982	884	5037	8	
+471	886	5036	34	
+269	225	5035	4	
+272	406	5034	19	
+915	157	5033	17	
+692	701	5032	35	
+50	628	5031	26	
+675	28	5030	76	
+789	272	5029	55	
+8	95	5028	64	
+997	745	5027	88	
+661	292	5026	51	
+819	855	5025	20	
+248	21	5024	99	
+455	819	5023	35	
+73	81	5022	22	
+600	508	5021	64	
+756	209	5020	37	
+176	911	5019	88	
+350	755	5018	78	
+453	374	5017	1	
+437	308	5016	33	
+833	205	5015	84	
+202	640	5014	57	
+737	133	5013	79	
+572	580	5012	38	
+299	268	5011	47	
+297	487	5010	84	
+155	105	5009	57	
+380	770	5008	82	
+65	674	5007	89	
+103	493	5006	1	
+565	272	5005	60	
+506	777	5004	63	
+552	410	5003	46	
+312	909	5002	16	
+780	628	5001	27	
+382	264	5000	0	
+335	752	4999	14	
+95	929	4998	77	
+181	881	4997	31	
+220	412	4996	96	
+494	972	4995	53	
+366	167	4994	5	
+500	299	4993	95	
+281	891	4992	23	
+363	271	4991	53	
+512	859	4990	39	
+823	366	4989	4	
+48	459	4988	23	
+468	353	4987	91	
+440	424	4986	96	
+804	479	4985	72	
+867	104	4984	12	
+407	714	4983	86	
+620	708	4982	21	
+411	133	4981	91	
+492	351	4980	85	
+907	807	4979	68	
+106	325	4978	77	
+929	953	4977	57	
+944	234	4976	2	
+375	598	4975	63	
+389	261	4974	93	
+6	646	4973	46	
+575	302	4972	78	
+781	66	4971	20	
+543	162	4970	91	
+482	914	4969	58	
+372	195	4968	80	
+718	550	4967	17	
+635	393	4966	98	
+336	698	4965	56	
+615	476	4964	98	
+343	673	4963	38	
+236	577	4962	43	
+903	290	4961	79	
+248	332	4960	23	
+718	785	4959	6	
+644	622	4958	11	
+157	192	4957	65	
+695	415	4956	8	
+221	582	4955	29	
+803	602	4954	72	
+95	951	4953	27	
+286	637	4952	10	
+958	556	4951	33	
+547	175	4950	65	
+162	951	4949	52	
+429	456	4948	7	
+777	570	4947	48	
+833	783	4946	46	
+979	577	4945	47	
+651	449	4944	41	
+314	164	4943	70	
+81	775	4942	80	
+380	676	4941	32	
+224	125	4940	41	
+495	455	4939	38	
+885	586	4938	73	
+787	25	4937	65	
+206	988	4936	94	
+127	55	4935	85	
+285	710	4934	32	
+388	898	4933	33	
+98	479	4932	23	
+550	918	4931	70	
+669	26	4930	15	
+869	651	4929	72	
+560	80	4928	60	
+37	708	4927	9	
+932	90	4926	58	
+345	524	4925	7	
+811	991	4924	84	
+419	103	4923	89	
+561	532	4922	29	
+892	543	4921	54	
+374	427	4920	88	
+571	119	4919	80	
+372	511	4918	30	
+617	517	4917	52	
+566	502	4916	10	
+532	235	4915	58	
+888	945	4914	53	
+570	606	4913	39	
+988	742	4912	85	
+116	666	4911	66	
+307	80	4910	51	
+608	491	4909	80	
+993	784	4908	19	
+14	418	4907	75	
+266	517	4906	5	
+290	53	4905	3	
+339	141	4904	64	
+863	534	4903	31	
+75	188	4902	58	
+586	151	4901	87	
+588	714	4900	80	
+706	604	4899	69	
+366	443	4898	61	
+901	704	4897	97	
+463	16	4896	74	
+912	390	4895	97	
+606	325	4894	95	
+346	736	4893	47	
+36	709	4892	78	
+437	63	4891	48	
+109	109	4890	99	
+160	85	4889	88	
+739	635	4888	34	
+687	230	4887	46	
+626	771	4886	43	
+64	26	4885	55	
+589	474	4884	30	
+27	687	4883	26	
+646	298	4882	31	
+953	492	4881	59	
+24	114	4880	32	
+449	541	4879	94	
+404	875	4878	42	
+459	27	4877	5	
+745	885	4876	6	
+551	246	4875	56	
+787	45	4874	47	
+388	949	4873	56	
+806	711	4872	38	
+377	269	4871	69	
+573	379	4870	92	
+666	527	4869	57	
+848	367	4868	4	
+141	992	4867	94	
+639	498	4866	71	
+200	87	4865	19	
+95	913	4864	76	
+237	179	4863	39	
+441	689	4862	58	
+889	763	4861	42	
+852	354	4860	80	
+159	529	4859	90	
+375	99	4858	81	
+494	231	4857	70	
+411	518	4856	50	
+173	430	4855	43	
+734	365	4854	10	
+490	817	4853	85	
+925	151	4852	79	
+409	625	4851	55	
+824	896	4850	3	
+429	89	4849	69	
+867	111	4848	78	
+712	203	4847	88	
+88	63	4846	8	
+65	334	4845	23	
+548	246	4844	43	
+665	61	4843	24	
+525	243	4842	56	
+729	514	4841	51	
+807	345	4840	58	
+977	908	4839	39	
+907	902	4838	56	
+140	798	4837	15	
+728	844	4836	62	
+87	798	4835	2	
+185	195	4834	51	
+818	678	4833	88	
+729	49	4832	13	
+168	930	4831	79	
+437	190	4830	92	
+5	833	4829	82	
+103	406	4828	6	
+953	530	4827	76	
+46	601	4826	41	
+603	506	4825	64	
+517	634	4824	90	
+628	743	4823	36	
+118	343	4822	8	
+740	874	4821	56	
+357	92	4820	73	
+426	759	4819	43	
+876	302	4818	90	
+929	355	4817	15	
+94	770	4816	90	
+871	738	4815	44	
+891	535	4814	8	
+400	278	4813	88	
+468	527	4812	51	
+781	829	4811	37	
+332	299	4810	38	
+457	529	4809	93	
+947	751	4808	55	
+584	242	4807	94	
+31	464	4806	83	
+203	357	4805	22	
+256	196	4804	98	
+750	377	4803	49	
+698	133	4802	93	
+529	993	4801	68	
+769	452	4800	44	
+778	380	4799	87	
+509	603	4798	50	
+777	112	4797	36	
+107	611	4796	55	
+160	243	4795	82	
+818	488	4794	94	
+244	560	4793	50	
+139	244	4792	5	
+541	237	4791	16	
+71	573	4790	75	
+777	366	4789	99	
+490	145	4788	26	
+501	810	4787	73	
+367	724	4786	67	
+754	881	4785	94	
+928	440	4784	34	
+315	454	4783	57	
+7	882	4782	10	
+663	410	4781	59	
+207	767	4780	46	
+220	722	4779	29	
+334	538	4778	28	
+86	60	4777	98	
+842	724	4776	13	
+441	604	4775	61	
+985	767	4774	82	
+572	468	4773	61	
+471	507	4772	30	
+642	128	4771	34	
+45	175	4770	45	
+184	7	4769	98	
+477	296	4768	88	
+335	856	4767	24	
+119	519	4766	24	
+836	787	4765	40	
+298	212	4764	45	
+961	305	4763	41	
+378	964	4762	10	
+952	888	4761	82	
+167	468	4760	59	
+710	101	4759	86	
+440	637	4758	70	
+336	4	4757	14	
+731	841	4756	21	
+575	946	4755	28	
+906	41	4754	53	
+341	313	4753	33	
+75	270	4752	58	
+419	232	4751	42	
+367	735	4750	78	
+464	155	4749	45	
+632	564	4748	27	
+162	925	4747	10	
+895	933	4746	60	
+905	745	4745	15	
+728	200	4744	66	
+42	754	4743	56	
+38	157	4742	26	
+497	640	4741	65	
+580	327	4740	5	
+591	187	4739	90	
+638	166	4738	83	
+992	498	4737	46	
+187	448	4736	26	
+545	487	4735	99	
+445	103	4734	17	
+597	300	4733	68	
+516	608	4732	0	
+313	605	4731	54	
+140	148	4730	91	
+20	71	4729	98	
+667	362	4728	95	
+50	201	4727	64	
+960	277	4726	80	
+384	813	4725	64	
+802	491	4724	9	
+691	681	4723	84	
+3	462	4722	8	
+456	624	4721	20	
+76	927	4720	17	
+709	36	4719	12	
+160	306	4718	35	
+924	840	4717	61	
+464	162	4716	8	
+321	543	4715	57	
+809	250	4714	58	
+219	767	4713	11	
+838	878	4712	68	
+697	30	4711	54	
+890	52	4710	38	
+729	767	4709	36	
+466	735	4708	54	
+677	527	4707	23	
+619	513	4706	45	
+292	994	4705	14	
+483	471	4704	51	
+888	422	4703	58	
+848	141	4702	38	
+977	166	4701	14	
+285	13	4700	80	
+31	817	4699	16	
+208	312	4698	26	
+13	776	4697	78	
+519	316	4696	5	
+523	629	4695	32	
+48	922	4694	80	
+280	208	4693	59	
+975	240	4692	4	
+152	334	4691	87	
+196	645	4690	69	
+504	897	4689	25	
+535	474	4688	82	
+460	731	4687	19	
+686	729	4686	49	
+706	519	4685	99	
+714	213	4684	47	
+968	554	4683	76	
+905	169	4682	30	
+689	179	4681	82	
+747	438	4680	95	
+423	429	4679	69	
+743	629	4678	96	
+1	701	4677	7	
+210	496	4676	77	
+305	522	4675	97	
+659	706	4674	99	
+384	462	4673	74	
+990	481	4672	6	
+740	868	4671	21	
+8	263	4670	94	
+800	723	4669	32	
+927	892	4668	67	
+204	302	4667	74	
+974	793	4666	79	
+815	987	4665	90	
+244	246	4664	64	
+981	682	4663	27	
+613	846	4662	39	
+604	274	4661	24	
+540	617	4660	73	
+830	644	4659	20	
+590	937	4658	87	
+509	951	4657	72	
+805	885	4656	22	
+740	259	4655	15	
+563	371	4654	57	
+836	880	4653	26	
+572	144	4652	36	
+656	517	4651	0	
+973	523	4650	6	
+706	335	4649	71	
+986	148	4648	24	
+66	494	4647	8	
+626	70	4646	70	
+887	588	4645	6	
+491	307	4644	17	
+735	895	4643	72	
+627	358	4642	26	
+993	945	4641	91	
+188	353	4640	68	
+186	469	4639	26	
+654	159	4638	72	
+424	377	4637	91	
+481	637	4636	44	
+280	889	4635	73	
+412	448	4634	39	
+536	464	4633	75	
+413	347	4632	10	
+591	232	4631	63	
+883	417	4630	80	
+310	545	4629	0	
+782	800	4628	53	
+739	479	4627	23	
+748	701	4626	94	
+440	341	4625	20	
+984	640	4624	86	
+117	648	4623	87	
+114	473	4622	12	
+815	828	4621	82	
+871	803	4620	70	
+744	470	4619	57	
+320	300	4618	52	
+778	288	4617	4	
+359	742	4616	99	
+701	332	4615	30	
+992	992	4614	45	
+174	752	4613	86	
+645	301	4612	0	
+24	114	4611	29	
+333	134	4610	94	
+169	45	4609	12	
+12	485	4608	42	
+545	51	4607	54	
+410	683	4606	41	
+339	851	4605	65	
+239	590	4604	70	
+451	863	4603	81	
+187	704	4602	52	
+979	355	4601	62	
+89	816	4600	69	
+559	702	4599	16	
+434	881	4598	15	
+368	123	4597	46	
+832	760	4596	13	
+261	948	4595	7	
+726	891	4594	10	
+159	288	4593	78	
+349	907	4592	26	
+538	930	4591	20	
+114	526	4590	89	
+821	7	4589	52	
+757	689	4588	12	
+363	331	4587	6	
+812	64	4586	53	
+56	970	4585	57	
+603	312	4584	53	
+380	523	4583	56	
+977	56	4582	81	
+403	317	4581	81	
+518	360	4580	42	
+318	404	4579	29	
+358	59	4578	6	
+266	529	4577	39	
+94	964	4576	55	
+658	36	4575	75	
+788	967	4574	45	
+467	757	4573	22	
+739	999	4572	40	
+956	386	4571	57	
+956	131	4570	88	
+344	229	4569	20	
+529	669	4568	95	
+564	843	4567	9	
+928	795	4566	17	
+69	301	4565	43	
+210	231	4564	86	
+757	819	4563	32	
+612	829	4562	72	
+255	688	4561	78	
+902	685	4560	0	
+559	240	4559	61	
+826	867	4558	81	
+47	920	4557	96	
+494	735	4556	63	
+70	566	4555	85	
+412	548	4554	85	
+989	593	4553	45	
+140	945	4552	14	
+3	781	4551	35	
+444	389	4550	35	
+372	796	4549	34	
+947	850	4548	73	
+184	328	4547	77	
+168	778	4546	55	
+18	999	4545	42	
+955	407	4544	65	
+647	307	4543	42	
+163	787	4542	84	
+392	5	4541	13	
+593	9	4540	55	
+946	609	4539	7	
+521	954	4538	42	
+550	226	4537	76	
+778	128	4536	1	
+592	766	4535	14	
+99	235	4534	6	
+520	573	4533	30	
+781	711	4532	48	
+995	579	4531	77	
+400	485	4530	79	
+655	647	4529	64	
+728	661	4528	42	
+97	746	4527	97	
+362	866	4526	77	
+530	86	4525	18	
+662	756	4524	49	
+861	823	4523	57	
+132	713	4522	73	
+93	971	4521	78	
+838	152	4520	59	
+986	222	4519	74	
+914	452	4518	92	
+880	200	4517	63	
+780	584	4516	73	
+329	694	4515	83	
+933	913	4514	86	
+110	840	4513	80	
+741	952	4512	72	
+819	190	4511	3	
+929	850	4510	25	
+770	817	4509	85	
+251	296	4508	7	
+616	896	4507	3	
+889	902	4506	9	
+780	963	4505	45	
+73	67	4504	39	
+888	71	4503	82	
+761	690	4502	36	
+340	782	4501	92	
+32	403	4500	88	
+521	780	4499	15	
+399	37	4498	51	
+994	934	4497	63	
+938	648	4496	72	
+896	54	4495	10	
+995	573	4494	70	
+380	454	4493	18	
+908	446	4492	12	
+378	32	4491	42	
+623	730	4490	30	
+743	640	4489	51	
+102	883	4488	12	
+285	908	4487	40	
+594	617	4486	5	
+480	401	4485	4	
+119	522	4484	90	
+8	58	4483	61	
+413	705	4482	47	
+301	113	4481	52	
+90	796	4480	75	
+756	388	4479	87	
+974	717	4478	64	
+291	349	4477	81	
+215	12	4476	69	
+878	142	4475	11	
+464	285	4474	36	
+353	141	4473	11	
+591	943	4472	59	
+317	773	4471	11	
+407	875	4470	21	
+671	238	4469	33	
+368	824	4468	78	
+336	125	4467	68	
+870	576	4466	7	
+856	753	4465	33	
+143	249	4464	41	
+198	516	4463	11	
+169	482	4462	76	
+898	901	4461	27	
+636	877	4460	90	
+414	551	4459	73	
+698	99	4458	30	
+549	606	4457	3	
+822	738	4456	46	
+503	922	4455	1	
+733	303	4454	71	
+33	349	4453	94	
+581	486	4452	2	
+24	365	4451	27	
+326	172	4450	26	
+451	433	4449	22	
+492	271	4448	71	
+868	565	4447	14	
+816	452	4446	72	
+619	300	4445	31	
+953	768	4444	77	
+863	916	4443	69	
+121	757	4442	45	
+192	10	4441	55	
+739	39	4440	69	
+161	506	4439	87	
+706	566	4438	95	
+112	422	4437	62	
+152	407	4436	5	
+532	548	4435	19	
+851	70	4434	66	
+159	246	4433	9	
+746	896	4432	74	
+970	858	4431	92	
+533	823	4430	45	
+939	915	4429	57	
+144	334	4428	45	
+14	573	4427	59	
+858	854	4426	96	
+478	531	4425	62	
+823	575	4424	68	
+350	348	4423	69	
+37	813	4422	41	
+35	475	4421	77	
+907	875	4420	43	
+581	122	4419	59	
+760	862	4418	79	
+718	632	4417	12	
+323	340	4416	15	
+955	939	4415	38	
+227	989	4414	65	
+534	279	4413	47	
+337	636	4412	31	
+600	338	4411	0	
+752	844	4410	12	
+260	798	4409	32	
+229	666	4408	82	
+292	973	4407	4	
+401	776	4406	39	
+950	725	4405	36	
+710	181	4404	72	
+642	159	4403	69	
+298	311	4402	19	
+494	875	4401	73	
+46	801	4400	84	
+131	505	4399	49	
+693	778	4398	3	
+196	647	4397	93	
+50	26	4396	89	
+543	640	4395	45	
+22	35	4394	24	
+848	495	4393	6	
+436	459	4392	34	
+73	889	4391	80	
+295	356	4390	44	
+727	460	4389	91	
+130	94	4388	43	
+621	45	4387	49	
+385	440	4386	14	
+605	210	4385	50	
+540	172	4384	52	
+35	722	4383	17	
+569	540	4382	41	
+533	355	4381	36	
+895	533	4380	77	
+366	475	4379	56	
+48	942	4378	59	
+605	350	4377	50	
+229	638	4376	23	
+38	985	4375	78	
+449	347	4374	6	
+182	761	4373	50	
+184	50	4372	46	
+822	583	4371	3	
+57	209	4370	63	
+533	971	4369	52	
+592	87	4368	31	
+711	273	4367	44	
+653	455	4366	37	
+637	715	4365	19	
+586	560	4364	58	
+710	38	4363	26	
+466	429	4362	99	
+374	397	4361	36	
+237	109	4360	76	
+884	210	4359	52	
+814	875	4358	94	
+818	66	4357	88	
+739	184	4356	5	
+154	603	4355	1	
+522	320	4354	5	
+608	269	4353	87	
+31	635	4352	24	
+288	597	4351	9	
+898	240	4350	13	
+334	583	4349	35	
+809	59	4348	6	
+882	822	4347	99	
+581	43	4346	7	
+282	963	4345	58	
+51	175	4344	63	
+634	631	4343	91	
+37	152	4342	57	
+357	954	4341	74	
+656	783	4340	38	
+524	284	4339	56	
+236	72	4338	52	
+779	918	4337	92	
+79	494	4336	30	
+788	952	4335	29	
+543	718	4334	23	
+479	337	4333	41	
+197	833	4332	59	
+171	353	4331	68	
+499	825	4330	70	
+211	38	4329	13	
+154	598	4328	28	
+423	626	4327	45	
+542	2	4326	70	
+233	67	4325	29	
+380	814	4324	24	
+504	819	4323	6	
+479	916	4322	28	
+528	978	4321	2	
+786	569	4320	67	
+440	845	4319	28	
+971	829	4318	5	
+623	757	4317	73	
+934	409	4316	88	
+252	46	4315	30	
+995	180	4314	85	
+902	782	4313	87	
+937	255	4312	2	
+409	355	4311	95	
+724	383	4310	74	
+15	229	4309	34	
+72	327	4308	46	
+348	848	4307	34	
+362	573	4306	68	
+865	455	4305	68	
+397	977	4304	25	
+527	850	4303	9	
+900	73	4302	96	
+971	209	4301	52	
+153	396	4300	68	
+902	876	4299	70	
+478	120	4298	94	
+275	659	4297	72	
+118	6	4296	98	
+478	424	4295	49	
+126	164	4294	46	
+777	127	4293	87	
+864	437	4292	62	
+813	842	4291	92	
+519	976	4290	81	
+755	765	4289	25	
+461	218	4288	42	
+652	738	4287	20	
+582	488	4286	15	
+259	28	4285	64	
+37	597	4284	35	
+690	243	4283	34	
+594	697	4282	91	
+865	111	4281	5	
+210	566	4280	29	
+547	826	4279	76	
+480	221	4278	29	
+250	45	4277	80	
+459	517	4276	7	
+431	288	4275	32	
+353	2	4274	22	
+546	436	4273	34	
+585	861	4272	9	
+545	757	4271	72	
+739	530	4270	65	
+605	469	4269	66	
+176	484	4268	6	
+527	739	4267	23	
+229	747	4266	79	
+285	100	4265	2	
+565	874	4264	7	
+575	252	4263	80	
+104	365	4262	96	
+226	75	4261	3	
+60	990	4260	80	
+985	596	4259	13	
+744	837	4258	42	
+991	439	4257	64	
+647	762	4256	29	
+225	949	4255	94	
+622	271	4254	71	
+886	846	4253	99	
+290	920	4252	47	
+84	233	4251	87	
+393	672	4250	16	
+759	704	4249	7	
+397	781	4248	24	
+677	349	4247	75	
+812	354	4246	34	
+678	224	4245	42	
+424	728	4244	60	
+925	520	4243	73	
+687	592	4242	59	
+560	712	4241	20	
+967	90	4240	69	
+923	834	4239	63	
+431	487	4238	36	
+994	409	4237	71	
+130	921	4236	86	
+495	819	4235	13	
+208	868	4234	25	
+927	138	4233	49	
+880	391	4232	23	
+621	514	4231	12	
+255	56	4230	59	
+347	272	4229	4	
+77	642	4228	49	
+488	854	4227	43	
+101	731	4226	86	
+951	879	4225	63	
+729	754	4224	28	
+747	260	4223	28	
+876	112	4222	4	
+458	533	4221	25	
+783	548	4220	36	
+630	552	4219	90	
+788	55	4218	26	
+122	572	4217	58	
+852	228	4216	38	
+124	348	4215	15	
+494	4	4214	22	
+148	235	4213	98	
+578	786	4212	87	
+984	892	4211	41	
+996	458	4210	67	
+497	638	4209	15	
+482	680	4208	84	
+344	202	4207	66	
+879	236	4206	27	
+344	928	4205	72	
+769	239	4204	63	
+448	111	4203	34	
+894	452	4202	56	
+434	743	4201	59	
+820	520	4200	98	
+957	311	4199	49	
+478	176	4198	1	
+966	395	4197	13	
+307	543	4196	46	
+689	97	4195	53	
+127	283	4194	57	
+659	777	4193	32	
+708	975	4192	55	
+222	604	4191	45	
+208	489	4190	61	
+135	484	4189	86	
+780	877	4188	47	
+852	672	4187	51	
+446	929	4186	65	
+813	960	4185	61	
+506	253	4184	56	
+801	766	4183	46	
+370	94	4182	95	
+115	845	4181	48	
+5	750	4180	1	
+607	383	4179	7	
+204	967	4178	35	
+742	852	4177	92	
+969	41	4176	40	
+706	54	4175	63	
+487	95	4174	30	
+671	516	4173	70	
+248	465	4172	43	
+95	471	4171	25	
+366	940	4170	11	
+416	717	4169	39	
+114	426	4168	40	
+810	522	4167	46	
+986	773	4166	77	
+959	325	4165	26	
+578	602	4164	21	
+50	273	4163	81	
+993	175	4162	42	
+531	144	4161	15	
+222	712	4160	72	
+291	994	4159	95	
+904	941	4158	30	
+749	687	4157	30	
+447	511	4156	82	
+722	42	4155	2	
+328	403	4154	38	
+98	392	4153	52	
+30	269	4152	5	
+432	425	4151	46	
+717	777	4150	30	
+53	648	4149	93	
+253	998	4148	38	
+176	479	4147	15	
+468	796	4146	30	
+639	646	4145	72	
+11	852	4144	39	
+122	472	4143	23	
+844	593	4142	6	
+647	154	4141	59	
+129	376	4140	71	
+650	544	4139	66	
+518	232	4138	79	
+683	853	4137	7	
+150	576	4136	70	
+794	330	4135	82	
+380	163	4134	62	
+878	162	4133	88	
+439	469	4132	27	
+777	883	4131	19	
+832	49	4130	51	
+311	864	4129	47	
+378	722	4128	13	
+277	369	4127	83	
+245	878	4126	53	
+167	201	4125	35	
+0	739	4124	41	
+693	610	4123	50	
+585	81	4122	43	
+833	678	4121	66	
+185	38	4120	94	
+141	347	4119	52	
+353	296	4118	93	
+490	302	4117	10	
+677	176	4116	3	
+461	942	4115	7	
+129	912	4114	16	
+528	62	4113	30	
+403	777	4112	10	
+639	715	4111	75	
+691	424	4110	64	
+50	587	4109	4	
+994	831	4108	78	
+125	69	4107	86	
+234	953	4106	81	
+30	911	4105	21	
+849	858	4104	33	
+284	200	4103	60	
+62	355	4102	12	
+291	103	4101	76	
+837	604	4100	94	
+756	255	4099	64	
+761	925	4098	5	
+115	48	4097	86	
+42	598	4096	89	
+52	882	4095	20	
+658	731	4094	18	
+844	475	4093	56	
+251	361	4092	22	
+499	815	4091	77	
+349	307	4090	45	
+329	584	4089	8	
+877	187	4088	99	
+450	977	4087	64	
+715	687	4086	7	
+151	23	4085	98	
+255	615	4084	39	
+114	343	4083	81	
+545	451	4082	59	
+507	316	4081	75	
+723	373	4080	14	
+396	86	4079	2	
+209	348	4078	45	
+289	571	4077	42	
+664	84	4076	73	
+408	594	4075	56	
+271	580	4074	89	
+891	220	4073	14	
+134	841	4072	56	
+943	602	4071	3	
+286	129	4070	78	
+737	568	4069	32	
+777	24	4068	18	
+487	692	4067	92	
+489	169	4066	62	
+13	668	4065	25	
+360	755	4064	13	
+379	571	4063	38	
+238	530	4062	75	
+473	254	4061	19	
+561	456	4060	65	
+543	139	4059	54	
+331	267	4058	96	
+522	294	4057	28	
+501	369	4056	99	
+912	119	4055	47	
+183	756	4054	65	
+41	623	4053	98	
+275	566	4052	14	
+797	534	4051	76	
+317	107	4050	91	
+872	589	4049	1	
+972	670	4048	21	
+925	292	4047	80	
+249	521	4046	2	
+363	822	4045	58	
+132	671	4044	72	
+57	841	4043	14	
+32	375	4042	76	
+426	852	4041	47	
+517	894	4040	48	
+919	805	4039	44	
+377	403	4038	90	
+771	787	4037	4	
+698	432	4036	67	
+150	859	4035	88	
+830	587	4034	23	
+465	375	4033	7	
+522	288	4032	2	
+958	997	4031	60	
+89	35	4030	90	
+402	544	4029	59	
+615	853	4028	54	
+354	370	4027	60	
+573	790	4026	7	
+271	655	4025	54	
+211	154	4024	31	
+87	50	4023	36	
+290	419	4022	94	
+961	696	4021	56	
+491	310	4020	86	
+690	56	4019	68	
+482	935	4018	78	
+580	533	4017	26	
+134	524	4016	78	
+500	228	4015	30	
+104	954	4014	5	
+630	421	4013	12	
+723	378	4012	79	
+385	695	4011	32	
+253	182	4010	46	
+121	899	4009	80	
+401	526	4008	20	
+9	478	4007	90	
+295	479	4006	44	
+273	242	4005	63	
+533	935	4004	39	
+42	327	4003	47	
+683	467	4002	90	
+513	859	4001	33	
+282	669	4000	13	
+372	592	3999	13	
+47	305	3998	72	
+999	457	3997	39	
+237	811	3996	71	
+307	238	3995	2	
+608	922	3994	74	
+859	566	3993	49	
+608	568	3992	35	
+189	206	3991	17	
+77	999	3990	23	
+287	411	3989	91	
+848	328	3988	32	
+645	678	3987	4	
+572	691	3986	76	
+315	282	3985	93	
+356	250	3984	69	
+998	131	3983	74	
+361	188	3982	25	
+206	940	3981	41	
+588	320	3980	11	
+82	584	3979	78	
+650	277	3978	43	
+986	286	3977	20	
+409	831	3976	7	
+31	230	3975	25	
+118	950	3974	95	
+942	496	3973	35	
+248	833	3972	63	
+620	305	3971	15	
+735	322	3970	61	
+307	351	3969	50	
+990	236	3968	43	
+454	129	3967	66	
+600	815	3966	57	
+280	297	3965	37	
+454	601	3964	91	
+663	721	3963	17	
+528	480	3962	69	
+982	537	3961	62	
+971	111	3960	88	
+115	74	3959	42	
+106	767	3958	31	
+314	86	3957	53	
+517	200	3956	85	
+696	464	3955	32	
+879	736	3954	82	
+240	483	3953	79	
+943	65	3952	13	
+425	743	3951	54	
+36	456	3950	1	
+307	110	3949	85	
+681	781	3948	0	
+886	681	3947	79	
+736	533	3946	79	
+728	495	3945	82	
+253	34	3944	81	
+418	656	3943	63	
+321	588	3942	29	
+286	535	3941	51	
+345	154	3940	38	
+329	847	3939	72	
+99	216	3938	62	
+148	996	3937	79	
+38	975	3936	14	
+460	4	3935	0	
+377	178	3934	47	
+68	341	3933	83	
+52	779	3932	9	
+381	129	3931	3	
+306	658	3930	94	
+631	104	3929	1	
+220	830	3928	23	
+20	645	3927	95	
+970	141	3926	11	
+826	533	3925	57	
+837	640	3924	8	
+561	738	3923	30	
+650	62	3922	1	
+470	93	3921	67	
+554	924	3920	7	
+273	785	3919	67	
+185	280	3918	41	
+503	839	3917	19	
+608	533	3916	5	
+893	494	3915	14	
+901	773	3914	98	
+676	292	3913	27	
+968	346	3912	91	
+168	594	3911	18	
+139	400	3910	91	
+505	263	3909	28	
+441	211	3908	8	
+305	148	3907	68	
+39	905	3906	89	
+720	155	3905	71	
+481	713	3904	99	
+946	364	3903	22	
+751	730	3902	70	
+194	264	3901	80	
+136	634	3900	2	
+52	193	3899	63	
+62	405	3898	6	
+243	787	3897	13	
+750	179	3896	26	
+441	724	3895	31	
+349	766	3894	23	
+633	518	3893	53	
+466	906	3892	19	
+630	771	3891	55	
+440	395	3890	5	
+788	569	3889	8	
+618	929	3888	98	
+608	868	3887	81	
+454	947	3886	49	
+958	79	3885	30	
+247	703	3884	9	
+611	340	3883	71	
+135	637	3882	16	
+376	499	3881	83	
+825	973	3880	19	
+640	95	3879	65	
+60	169	3878	16	
+920	326	3877	0	
+867	184	3876	15	
+376	216	3875	49	
+362	376	3874	71	
+703	548	3873	63	
+137	331	3872	47	
+526	645	3871	75	
+877	538	3870	55	
+925	482	3869	18	
+842	159	3868	58	
+142	856	3867	13	
+968	657	3866	5	
+840	786	3865	49	
+827	74	3864	1	
+217	160	3863	65	
+686	717	3862	56	
+107	207	3861	61	
+55	366	3860	64	
+322	604	3859	95	
+303	440	3858	8	
+199	86	3857	70	
+870	561	3856	17	
+712	477	3855	12	
+913	354	3854	1	
+443	92	3853	61	
+509	955	3852	53	
+841	962	3851	57	
+762	696	3850	5	
+163	869	3849	73	
+353	381	3848	1	
+525	527	3847	10	
+83	45	3846	32	
+122	115	3845	15	
+262	402	3844	79	
+137	79	3843	47	
+992	951	3842	93	
+265	527	3841	66	
+827	318	3840	7	
+487	713	3839	59	
+854	914	3838	80	
+481	775	3837	82	
+930	169	3836	44	
+713	360	3835	96	
+322	327	3834	86	
+127	536	3833	12	
+424	266	3832	14	
+208	588	3831	72	
+605	479	3830	43	
+798	789	3829	33	
+138	981	3828	63	
+606	385	3827	37	
+809	481	3826	55	
+32	100	3825	21	
+791	735	3824	39	
+269	980	3823	19	
+677	417	3822	70	
+108	288	3821	21	
+690	98	3820	60	
+807	707	3819	80	
+595	259	3818	65	
+903	822	3817	53	
+381	334	3816	79	
+364	826	3815	77	
+755	195	3814	24	
+562	492	3813	52	
+128	486	3812	59	
+190	613	3811	56	
+391	796	3810	41	
+448	146	3809	88	
+437	127	3808	21	
+487	735	3807	69	
+508	20	3806	52	
+631	535	3805	1	
+703	719	3804	60	
+5	930	3803	19	
+873	22	3802	43	
+816	150	3801	93	
+650	535	3800	79	
+19	670	3799	94	
+391	519	3798	1	
+715	169	3797	94	
+484	504	3796	97	
+816	408	3795	87	
+789	416	3794	92	
+907	758	3793	69	
+872	496	3792	13	
+614	139	3791	5	
+865	855	3790	16	
+151	932	3789	63	
+350	61	3788	62	
+664	969	3787	67	
+96	102	3786	23	
+992	949	3785	66	
+658	229	3784	2	
+262	566	3783	88	
+356	74	3782	3	
+283	890	3781	25	
+923	534	3780	74	
+870	3	3779	71	
+92	952	3778	80	
+866	444	3777	68	
+153	563	3776	56	
+719	640	3775	10	
+663	145	3774	33	
+491	846	3773	39	
+183	778	3772	90	
+356	507	3771	7	
+531	35	3770	35	
+51	913	3769	5	
+507	115	3768	77	
+881	116	3767	22	
+922	464	3766	71	
+494	769	3765	43	
+299	938	3764	5	
+68	490	3763	17	
+270	832	3762	30	
+471	713	3761	82	
+122	306	3760	82	
+797	275	3759	48	
+999	552	3758	54	
+651	512	3757	62	
+695	279	3756	95	
+830	378	3755	42	
+447	883	3754	19	
+658	864	3753	23	
+118	479	3752	79	
+407	2	3751	79	
+30	344	3750	34	
+722	937	3749	32	
+40	916	3748	79	
+232	668	3747	34	
+900	530	3746	95	
+494	232	3745	86	
+18	963	3744	38	
+385	434	3743	78	
+477	998	3742	53	
+658	449	3741	71	
+407	23	3740	37	
+20	527	3739	30	
+248	450	3738	68	
+137	391	3737	80	
+297	91	3736	33	
+268	481	3735	40	
+529	593	3734	47	
+435	249	3733	63	
+548	828	3732	90	
+425	334	3731	81	
+496	68	3730	25	
+76	626	3729	38	
+59	873	3728	77	
+300	475	3727	11	
+609	925	3726	83	
+888	930	3725	2	
+343	841	3724	73	
+421	725	3723	9	
+494	88	3722	88	
+265	568	3721	12	
+441	863	3720	92	
+752	614	3719	42	
+397	662	3718	1	
+550	270	3717	75	
+994	811	3716	69	
+88	289	3715	72	
+116	645	3714	54	
+637	207	3713	92	
+520	764	3712	92	
+704	193	3711	22	
+249	508	3710	82	
+952	403	3709	68	
+391	258	3708	35	
+459	67	3707	84	
+521	970	3706	55	
+644	175	3705	90	
+437	622	3704	97	
+443	995	3703	47	
+570	698	3702	11	
+685	404	3701	81	
+105	135	3700	45	
+144	333	3699	29	
+191	507	3698	56	
+96	291	3697	93	
+794	649	3696	93	
+553	933	3695	87	
+626	493	3694	20	
+297	362	3693	99	
+294	301	3692	87	
+268	359	3691	88	
+801	158	3690	57	
+826	736	3689	96	
+215	628	3688	95	
+642	994	3687	9	
+715	60	3686	30	
+440	670	3685	24	
+131	212	3684	92	
+60	121	3683	32	
+941	988	3682	0	
+201	305	3681	2	
+421	618	3680	46	
+107	7	3679	97	
+634	859	3678	61	
+933	791	3677	57	
+390	60	3676	92	
+458	315	3675	27	
+90	596	3674	30	
+133	327	3673	7	
+683	976	3672	11	
+686	558	3671	74	
+611	491	3670	77	
+147	364	3669	31	
+67	37	3668	47	
+731	646	3667	70	
+745	651	3666	54	
+718	966	3665	93	
+269	238	3664	36	
+350	951	3663	95	
+418	379	3662	45	
+66	960	3661	99	
+127	465	3660	7	
+326	840	3659	46	
+391	772	3658	8	
+995	157	3657	33	
+684	610	3656	98	
+728	564	3655	2	
+287	409	3654	44	
+572	507	3653	91	
+418	453	3652	93	
+494	922	3651	35	
+625	610	3650	93	
+67	383	3649	80	
+614	744	3648	93	
+546	349	3647	39	
+45	959	3646	31	
+155	577	3645	95	
+901	529	3644	44	
+54	987	3643	71	
+531	580	3642	15	
+311	411	3641	92	
+227	138	3640	86	
+639	866	3639	55	
+394	537	3638	45	
+390	85	3637	6	
+382	355	3636	50	
+47	513	3635	89	
+542	726	3634	25	
+406	561	3633	84	
+168	229	3632	52	
+273	54	3631	21	
+271	312	3630	8	
+328	104	3629	58	
+451	385	3628	24	
+730	566	3627	0	
+841	610	3626	0	
+787	636	3625	33	
+165	406	3624	50	
+331	323	3623	13	
+175	303	3622	23	
+742	135	3621	89	
+207	496	3620	0	
+719	342	3619	94	
+818	241	3618	87	
+956	995	3617	72	
+973	673	3616	88	
+230	828	3615	5	
+82	370	3614	62	
+20	897	3613	83	
+167	342	3612	15	
+639	894	3611	43	
+154	58	3610	53	
+100	65	3609	48	
+245	155	3608	90	
+321	832	3607	86	
+845	834	3606	98	
+457	431	3605	74	
+473	789	3604	14	
+554	676	3603	6	
+448	723	3602	85	
+835	898	3601	52	
+992	45	3600	48	
+910	587	3599	5	
+322	39	3598	85	
+998	878	3597	92	
+403	239	3596	47	
+642	595	3595	38	
+112	85	3594	98	
+953	209	3593	91	
+824	324	3592	10	
+853	42	3591	61	
+458	431	3590	84	
+548	198	3589	8	
+160	930	3588	58	
+639	447	3587	32	
+643	89	3586	59	
+509	403	3585	76	
+876	65	3584	53	
+884	812	3583	15	
+281	493	3582	12	
+611	769	3581	97	
+233	760	3580	39	
+267	494	3579	90	
+483	262	3578	38	
+358	729	3577	52	
+686	834	3576	99	
+337	229	3575	13	
+253	372	3574	63	
+318	28	3573	99	
+723	158	3572	60	
+9	576	3571	67	
+265	485	3570	37	
+232	522	3569	96	
+533	866	3568	78	
+895	525	3567	12	
+604	861	3566	67	
+857	500	3565	34	
+343	641	3564	8	
+870	387	3563	93	
+582	933	3562	59	
+91	292	3561	71	
+962	412	3560	74	
+655	181	3559	3	
+341	658	3558	69	
+663	453	3557	63	
+360	323	3556	29	
+858	265	3555	74	
+253	148	3554	51	
+454	340	3553	47	
+641	880	3552	28	
+879	970	3551	49	
+231	710	3550	12	
+522	334	3549	30	
+205	61	3548	31	
+129	347	3547	67	
+58	543	3546	30	
+117	232	3545	50	
+807	40	3544	60	
+460	185	3543	79	
+909	796	3542	81	
+259	362	3541	76	
+376	821	3540	64	
+273	992	3539	70	
+713	636	3538	31	
+803	374	3537	7	
+311	801	3536	7	
+192	897	3535	94	
+854	805	3534	30	
+389	985	3533	34	
+433	51	3532	55	
+541	114	3531	65	
+828	937	3530	88	
+356	393	3529	10	
+262	240	3528	55	
+572	4	3527	91	
+904	130	3526	49	
+91	631	3525	11	
+820	963	3524	33	
+933	795	3523	46	
+937	900	3522	95	
+176	766	3521	89	
+544	780	3520	71	
+153	543	3519	47	
+235	648	3518	9	
+873	418	3517	69	
+499	373	3516	66	
+667	781	3515	81	
+167	872	3514	27	
+895	508	3513	88	
+133	64	3512	99	
+986	178	3511	76	
+237	241	3510	63	
+894	378	3509	39	
+230	403	3508	91	
+45	21	3507	36	
+592	855	3506	37	
+908	541	3505	83	
+364	384	3504	50	
+444	890	3503	27	
+886	235	3502	76	
+936	128	3501	14	
+862	240	3500	74	
+975	474	3499	34	
+381	555	3498	66	
+165	987	3497	18	
+313	543	3496	45	
+157	330	3495	68	
+494	228	3494	54	
+654	510	3493	91	
+107	614	3492	55	
+887	399	3491	94	
+766	405	3490	7	
+918	679	3489	88	
+568	478	3488	59	
+444	732	3487	21	
+212	769	3486	85	
+102	139	3485	15	
+718	624	3484	66	
+895	361	3483	83	
+215	608	3482	54	
+993	875	3481	21	
+726	187	3480	12	
+200	292	3479	84	
+745	378	3478	35	
+963	364	3477	12	
+629	695	3476	23	
+515	493	3475	10	
+262	823	3474	38	
+752	292	3473	82	
+733	327	3472	68	
+687	99	3471	22	
+895	272	3470	26	
+914	498	3469	52	
+14	226	3468	45	
+668	892	3467	78	
+201	122	3466	33	
+670	726	3465	11	
+530	560	3464	25	
+965	142	3463	50	
+227	458	3462	1	
+827	954	3461	4	
+773	742	3460	79	
+271	70	3459	98	
+334	672	3458	90	
+769	448	3457	34	
+395	221	3456	46	
+165	860	3455	53	
+418	743	3454	13	
+683	490	3453	56	
+504	973	3452	73	
+211	253	3451	40	
+672	811	3450	5	
+397	80	3449	50	
+224	554	3448	93	
+226	878	3447	56	
+360	934	3446	37	
+116	392	3445	23	
+253	573	3444	74	
+517	828	3443	73	
+719	337	3442	17	
+442	346	3441	29	
+730	551	3440	53	
+526	564	3439	27	
+676	373	3438	17	
+943	190	3437	99	
+542	143	3436	86	
+819	483	3435	24	
+745	11	3434	86	
+490	556	3433	73	
+990	885	3432	79	
+795	753	3431	27	
+987	265	3430	71	
+190	101	3429	20	
+183	175	3428	84	
+46	131	3427	73	
+660	621	3426	40	
+472	380	3425	72	
+454	127	3424	7	
+671	938	3423	25	
+132	520	3422	50	
+488	564	3421	19	
+163	507	3420	80	
+925	354	3419	79	
+43	117	3418	0	
+510	330	3417	13	
+240	679	3416	38	
+253	648	3415	18	
+189	819	3414	1	
+417	753	3413	78	
+956	305	3412	53	
+57	386	3411	64	
+153	11	3410	32	
+236	789	3409	23	
+787	869	3408	88	
+651	750	3407	53	
+30	198	3406	26	
+829	170	3405	98	
+65	234	3404	6	
+448	244	3403	77	
+919	894	3402	46	
+374	320	3401	89	
+222	86	3400	90	
+919	355	3399	91	
+119	348	3398	44	
+552	264	3397	13	
+28	281	3396	62	
+936	924	3395	20	
+989	291	3394	76	
+349	310	3393	61	
+574	562	3392	52	
+233	994	3391	54	
+730	988	3390	15	
+7	466	3389	30	
+83	314	3388	80	
+983	514	3387	56	
+357	420	3386	52	
+632	436	3385	9	
+980	146	3384	94	
+748	88	3383	63	
+567	984	3382	77	
+6	392	3381	34	
+521	849	3380	50	
+151	501	3379	72	
+799	233	3378	92	
+94	42	3377	10	
+983	431	3376	62	
+290	145	3375	72	
+58	307	3374	65	
+104	864	3373	23	
+592	434	3372	18	
+542	837	3371	56	
+347	780	3370	48	
+268	798	3369	36	
+190	823	3368	35	
+610	474	3367	70	
+286	901	3366	11	
+837	72	3365	69	
+443	418	3364	23	
+429	52	3363	95	
+596	618	3362	51	
+57	76	3361	4	
+981	114	3360	19	
+975	17	3359	7	
+349	647	3358	7	
+572	593	3357	58	
+828	418	3356	32	
+654	460	3355	44	
+366	278	3354	39	
+433	441	3353	1	
+542	462	3352	83	
+962	855	3351	53	
+97	114	3350	7	
+370	2	3349	0	
+53	497	3348	62	
+174	255	3347	77	
+958	875	3346	74	
+182	54	3345	17	
+836	380	3344	28	
+979	181	3343	93	
+606	292	3342	89	
+741	464	3341	58	
+111	68	3340	86	
+505	380	3339	72	
+241	848	3338	31	
+380	33	3337	87	
+820	569	3336	21	
+673	886	3335	77	
+199	355	3334	34	
+888	41	3333	85	
+828	311	3332	37	
+395	715	3331	86	
+687	138	3330	62	
+532	410	3329	60	
+815	437	3328	26	
+464	662	3327	86	
+682	441	3326	55	
+531	429	3325	14	
+313	488	3324	47	
+730	483	3323	31	
+595	507	3322	6	
+577	236	3321	43	
+727	22	3320	70	
+973	342	3319	15	
+775	403	3318	71	
+221	301	3317	35	
+11	412	3316	78	
+941	672	3315	15	
+5	164	3314	21	
+975	249	3313	58	
+271	627	3312	13	
+213	725	3311	1	
+680	552	3310	84	
+938	438	3309	75	
+102	366	3308	19	
+888	569	3307	55	
+739	630	3306	20	
+508	933	3305	7	
+914	634	3304	93	
+621	448	3303	2	
+902	115	3302	70	
+172	169	3301	5	
+113	94	3300	53	
+72	557	3299	74	
+796	643	3298	83	
+939	344	3297	21	
+696	139	3296	14	
+298	134	3295	23	
+186	906	3294	59	
+332	325	3293	29	
+946	646	3292	71	
+74	524	3291	72	
+537	791	3290	5	
+913	904	3289	4	
+299	623	3288	27	
+204	64	3287	85	
+5	917	3286	24	
+228	637	3285	39	
+580	301	3284	11	
+679	573	3283	85	
+121	988	3282	38	
+732	670	3281	87	
+887	17	3280	53	
+281	765	3279	62	
+558	419	3278	61	
+147	613	3277	9	
+279	844	3276	19	
+336	285	3275	77	
+727	259	3274	64	
+584	467	3273	90	
+318	514	3272	55	
+653	334	3271	38	
+251	912	3270	84	
+346	9	3269	60	
+805	519	3268	72	
+769	896	3267	41	
+559	421	3266	86	
+26	129	3265	94	
+792	746	3264	60	
+953	343	3263	14	
+179	169	3262	26	
+422	543	3261	66	
+903	239	3260	40	
+489	882	3259	90	
+623	312	3258	54	
+474	542	3257	3	
+291	925	3256	21	
+383	334	3255	53	
+403	465	3254	23	
+173	876	3253	83	
+626	601	3252	77	
+303	263	3251	75	
+356	496	3250	51	
+570	364	3249	41	
+769	505	3248	86	
+617	825	3247	14	
+590	677	3246	18	
+869	299	3245	90	
+588	394	3244	98	
+275	65	3243	22	
+338	16	3242	54	
+767	238	3241	32	
+131	104	3240	94	
+859	547	3239	78	
+679	716	3238	80	
+147	965	3237	15	
+378	275	3236	2	
+904	927	3235	72	
+329	750	3234	28	
+48	682	3233	31	
+777	224	3232	93	
+133	376	3231	57	
+557	160	3230	63	
+831	985	3229	27	
+750	649	3228	17	
+690	124	3227	53	
+347	306	3226	76	
+177	439	3225	47	
+67	968	3224	57	
+458	376	3223	28	
+847	365	3222	27	
+216	935	3221	64	
+175	363	3220	57	
+335	92	3219	72	
+525	648	3218	8	
+818	762	3217	6	
+866	295	3216	34	
+471	899	3215	17	
+591	293	3214	10	
+11	10	3213	60	
+429	626	3212	61	
+572	67	3211	63	
+271	850	3210	4	
+443	645	3209	83	
+886	19	3208	81	
+466	717	3207	70	
+395	172	3206	95	
+605	60	3205	39	
+283	500	3204	87	
+383	998	3203	58	
+559	978	3202	58	
+216	590	3201	85	
+204	201	3200	30	
+626	29	3199	82	
+301	103	3198	55	
+545	755	3197	41	
+111	556	3196	7	
+559	515	3195	78	
+502	299	3194	32	
+19	997	3193	90	
+388	725	3192	82	
+389	555	3191	34	
+172	474	3190	1	
+925	269	3189	57	
+348	138	3188	32	
+198	348	3187	75	
+41	280	3186	43	
+215	467	3185	55	
+301	422	3184	5	
+272	75	3183	48	
+170	481	3182	63	
+81	330	3181	99	
+204	433	3180	21	
+131	254	3179	24	
+789	568	3178	57	
+67	322	3177	15	
+813	882	3176	15	
+45	494	3175	82	
+346	573	3174	91	
+594	852	3173	2	
+150	632	3172	10	
+897	781	3171	8	
+178	970	3170	87	
+685	670	3169	7	
+246	426	3168	34	
+439	993	3167	72	
+388	330	3166	25	
+920	913	3165	76	
+721	883	3164	69	
+219	928	3163	75	
+850	12	3162	44	
+810	212	3161	25	
+300	803	3160	71	
+243	731	3159	49	
+432	620	3158	43	
+663	467	3157	80	
+417	485	3156	5	
+29	70	3155	46	
+955	945	3154	19	
+915	309	3153	50	
+799	190	3152	36	
+409	533	3151	4	
+72	226	3150	51	
+110	53	3149	5	
+153	632	3148	81	
+981	755	3147	76	
+415	584	3146	24	
+124	268	3145	38	
+636	697	3144	7	
+118	132	3143	3	
+656	328	3142	11	
+307	529	3141	39	
+172	453	3140	33	
+420	245	3139	96	
+877	42	3138	95	
+171	522	3137	17	
+315	858	3136	56	
+571	312	3135	29	
+564	35	3134	48	
+803	922	3133	51	
+798	726	3132	46	
+76	53	3131	34	
+208	374	3130	13	
+203	5	3129	75	
+519	783	3128	54	
+663	607	3127	70	
+546	273	3126	85	
+277	804	3125	74	
+112	969	3124	0	
+196	55	3123	76	
+673	113	3122	0	
+678	213	3121	72	
+369	383	3120	86	
+221	208	3119	0	
+176	837	3118	68	
+334	850	3117	85	
+469	112	3116	11	
+834	736	3115	26	
+914	246	3114	16	
+942	755	3113	91	
+899	282	3112	52	
+829	854	3111	99	
+175	862	3110	30	
+371	321	3109	14	
+986	828	3108	4	
+738	737	3107	84	
+375	848	3106	86	
+489	104	3105	63	
+490	248	3104	92	
+473	393	3103	97	
+427	528	3102	4	
+992	685	3101	7	
+541	161	3100	65	
+492	102	3099	80	
+90	202	3098	38	
+889	976	3097	24	
+744	230	3096	36	
+856	714	3095	88	
+855	948	3094	99	
+864	929	3093	1	
+842	971	3092	4	
+524	416	3091	43	
+58	849	3090	45	
+899	420	3089	4	
+226	135	3088	40	
+746	886	3087	20	
+516	476	3086	14	
+765	887	3085	88	
+18	981	3084	0	
+958	971	3083	99	
+555	610	3082	2	
+566	984	3081	31	
+429	401	3080	46	
+284	646	3079	15	
+249	200	3078	67	
+410	56	3077	47	
+588	257	3076	22	
+906	886	3075	75	
+9	10	3074	74	
+360	968	3073	6	
+626	704	3072	40	
+582	851	3071	98	
+755	307	3070	13	
+445	484	3069	14	
+144	193	3068	3	
+798	250	3067	83	
+370	478	3066	82	
+876	3	3065	68	
+41	686	3064	89	
+264	658	3063	64	
+852	413	3062	73	
+543	851	3061	4	
+822	992	3060	82	
+291	110	3059	30	
+943	195	3058	30	
+771	17	3057	34	
+474	138	3056	42	
+317	786	3055	49	
+28	248	3054	83	
+244	913	3053	77	
+561	690	3052	41	
+859	216	3051	30	
+881	517	3050	72	
+915	8	3049	53	
+177	954	3048	34	
+879	917	3047	17	
+352	934	3046	29	
+537	659	3045	15	
+334	57	3044	28	
+222	366	3043	78	
+474	102	3042	68	
+698	588	3041	70	
+508	189	3040	97	
+53	183	3039	96	
+37	176	3038	73	
+982	874	3037	29	
+275	139	3036	52	
+602	869	3035	81	
+691	504	3034	20	
+263	100	3033	11	
+514	980	3032	74	
+398	725	3031	77	
+5	10	3030	19	
+7	228	3029	45	
+301	439	3028	1	
+734	771	3027	5	
+270	711	3026	70	
+364	611	3025	67	
+403	91	3024	91	
+120	363	3023	42	
+254	972	3022	74	
+714	585	3021	11	
+781	734	3020	39	
+788	439	3019	99	
+668	960	3018	70	
+59	348	3017	56	
+100	33	3016	46	
+519	762	3015	90	
+728	483	3014	96	
+390	678	3013	28	
+387	633	3012	86	
+850	722	3011	54	
+295	395	3010	93	
+478	291	3009	99	
+611	138	3008	12	
+315	103	3007	60	
+271	557	3006	95	
+278	945	3005	58	
+805	677	3004	79	
+44	418	3003	33	
+910	325	3002	0	
+327	607	3001	53	
+103	940	3000	55	
+153	872	2999	81	
+34	512	2998	86	
+546	648	2997	29	
+611	379	2996	4	
+268	788	2995	99	
+258	453	2994	47	
+92	334	2993	76	
+717	466	2992	13	
+667	981	2991	58	
+67	737	2990	22	
+359	950	2989	95	
+863	570	2988	11	
+269	252	2987	48	
+590	51	2986	93	
+335	519	2985	34	
+118	712	2984	0	
+868	626	2983	16	
+484	550	2982	37	
+244	360	2981	5	
+786	272	2980	59	
+380	832	2979	70	
+317	630	2978	49	
+200	553	2977	59	
+532	591	2976	67	
+807	333	2975	25	
+85	843	2974	21	
+76	790	2973	25	
+189	324	2972	38	
+88	451	2971	23	
+440	891	2970	45	
+201	212	2969	40	
+76	902	2968	6	
+962	915	2967	11	
+257	423	2966	66	
+489	38	2965	72	
+52	966	2964	72	
+466	866	2963	0	
+873	144	2962	88	
+560	781	2961	10	
+679	52	2960	64	
+310	342	2959	23	
+986	946	2958	12	
+491	448	2957	11	
+385	943	2956	70	
+72	3	2955	76	
+99	713	2954	43	
+722	120	2953	58	
+362	786	2952	59	
+729	452	2951	31	
+709	409	2950	88	
+396	112	2949	36	
+497	11	2948	32	
+505	408	2947	49	
+940	937	2946	10	
+289	331	2945	31	
+592	850	2944	97	
+334	993	2943	37	
+333	279	2942	35	
+43	432	2941	63	
+297	511	2940	1	
+101	45	2939	31	
+602	827	2938	89	
+471	390	2937	99	
+605	792	2936	56	
+480	340	2935	65	
+857	594	2934	69	
+713	17	2933	25	
+847	726	2932	0	
+920	613	2931	29	
+466	706	2930	74	
+218	413	2929	19	
+436	907	2928	49	
+598	427	2927	13	
+451	914	2926	86	
+746	954	2925	12	
+576	437	2924	62	
+291	257	2923	14	
+112	710	2922	86	
+906	544	2921	92	
+292	549	2920	45	
+506	697	2919	24	
+479	368	2918	78	
+513	264	2917	83	
+959	740	2916	14	
+516	501	2915	70	
+180	479	2914	16	
+547	278	2913	28	
+166	938	2912	17	
+994	472	2911	20	
+852	207	2910	61	
+329	465	2909	78	
+103	943	2908	2	
+524	691	2907	96	
+238	441	2906	55	
+22	535	2905	44	
+201	884	2904	33	
+339	106	2903	63	
+465	972	2902	38	
+265	591	2901	17	
+741	828	2900	14	
+522	758	2899	52	
+251	60	2898	22	
+250	413	2897	57	
+906	109	2896	28	
+651	107	2895	21	
+777	703	2894	82	
+134	251	2893	86	
+380	209	2892	87	
+763	29	2891	19	
+69	618	2890	52	
+698	297	2889	21	
+647	646	2888	27	
+303	294	2887	0	
+2	68	2886	34	
+404	396	2885	25	
+451	958	2884	87	
+42	987	2883	64	
+179	674	2882	75	
+411	675	2881	61	
+321	304	2880	69	
+650	948	2879	37	
+352	269	2878	5	
+225	656	2877	34	
+672	89	2876	30	
+437	380	2875	59	
+970	231	2874	95	
+313	888	2873	40	
+999	136	2872	86	
+370	922	2871	76	
+355	323	2870	9	
+679	319	2869	67	
+613	707	2868	29	
+566	43	2867	12	
+709	701	2866	55	
+148	646	2865	23	
+342	543	2864	46	
+751	546	2863	65	
+214	93	2862	31	
+598	678	2861	62	
+4	419	2860	1	
+612	372	2859	67	
+663	171	2858	6	
+341	573	2857	4	
+55	318	2856	85	
+102	767	2855	56	
+996	809	2854	80	
+453	343	2853	59	
+415	686	2852	53	
+258	612	2851	61	
+47	338	2850	59	
+200	610	2849	39	
+598	19	2848	94	
+254	188	2847	32	
+550	296	2846	28	
+958	754	2845	95	
+466	214	2844	10	
+657	53	2843	54	
+73	921	2842	3	
+274	22	2841	15	
+728	201	2840	21	
+590	444	2839	84	
+831	626	2838	60	
+891	35	2837	34	
+541	333	2836	70	
+540	846	2835	59	
+160	563	2834	49	
+132	505	2833	80	
+899	881	2832	58	
+820	945	2831	79	
+757	363	2830	54	
+817	245	2829	13	
+590	258	2828	75	
+702	639	2827	93	
+486	111	2826	34	
+283	99	2825	0	
+57	683	2824	37	
+623	224	2823	2	
+936	785	2822	23	
+581	253	2821	7	
+118	407	2820	6	
+986	378	2819	93	
+618	819	2818	22	
+528	589	2817	88	
+12	348	2816	21	
+416	621	2815	20	
+458	351	2814	22	
+439	794	2813	43	
+532	154	2812	68	
+845	15	2811	35	
+29	123	2810	46	
+559	712	2809	13	
+229	339	2808	36	
+241	671	2807	9	
+726	13	2806	51	
+270	977	2805	59	
+557	791	2804	95	
+639	746	2803	1	
+139	332	2802	90	
+892	891	2801	68	
+410	331	2800	81	
+372	763	2799	47	
+668	278	2798	32	
+658	574	2797	98	
+35	920	2796	51	
+185	638	2795	45	
+44	938	2794	71	
+413	111	2793	91	
+441	220	2792	50	
+559	871	2791	24	
+568	345	2790	48	
+484	141	2789	3	
+703	340	2788	70	
+654	473	2787	0	
+281	59	2786	62	
+700	743	2785	85	
+826	793	2784	14	
+891	418	2783	63	
+349	253	2782	97	
+525	764	2781	88	
+204	443	2780	99	
+800	333	2779	8	
+867	694	2778	78	
+414	387	2777	4	
+315	772	2776	37	
+949	708	2775	58	
+375	510	2774	87	
+164	658	2773	93	
+489	89	2772	54	
+320	892	2771	82	
+110	906	2770	32	
+639	302	2769	40	
+307	731	2768	93	
+615	677	2767	45	
+63	792	2766	9	
+198	706	2765	36	
+852	939	2764	57	
+568	393	2763	21	
+197	718	2762	67	
+985	502	2761	16	
+603	917	2760	21	
+571	470	2759	47	
+54	479	2758	33	
+885	354	2757	69	
+85	733	2756	55	
+767	791	2755	86	
+545	363	2754	34	
+674	535	2753	28	
+215	505	2752	37	
+585	959	2751	21	
+446	739	2750	38	
+990	138	2749	3	
+125	639	2748	51	
+620	140	2747	16	
+942	686	2746	79	
+427	518	2745	31	
+828	62	2744	22	
+29	912	2743	87	
+546	159	2742	45	
+219	830	2741	63	
+600	350	2740	13	
+498	514	2739	45	
+499	348	2738	86	
+453	369	2737	50	
+167	481	2736	67	
+456	96	2735	51	
+150	350	2734	59	
+753	412	2733	79	
+328	828	2732	48	
+480	492	2731	32	
+835	682	2730	61	
+165	590	2729	10	
+979	360	2728	99	
+887	826	2727	4	
+384	163	2726	28	
+746	915	2725	71	
+937	801	2724	30	
+584	314	2723	39	
+336	156	2722	42	
+809	708	2721	84	
+91	516	2720	64	
+230	102	2719	67	
+534	954	2718	18	
+662	758	2717	9	
+247	574	2716	50	
+114	405	2715	63	
+486	908	2714	80	
+158	972	2713	35	
+447	575	2712	24	
+191	204	2711	52	
+414	973	2710	71	
+147	483	2709	86	
+195	95	2708	69	
+184	588	2707	87	
+169	864	2706	41	
+496	830	2705	13	
+935	454	2704	62	
+397	105	2703	32	
+370	721	2702	71	
+230	809	2701	25	
+490	856	2700	77	
+388	165	2699	26	
+507	824	2698	95	
+723	457	2697	1	
+34	281	2696	1	
+375	504	2695	67	
+348	300	2694	56	
+384	617	2693	53	
+912	454	2692	2	
+953	478	2691	14	
+690	510	2690	74	
+341	314	2689	10	
+366	940	2688	88	
+176	996	2687	78	
+776	342	2686	68	
+203	111	2685	65	
+683	22	2684	2	
+162	512	2683	96	
+975	886	2682	47	
+968	399	2681	95	
+196	639	2680	26	
+373	220	2679	34	
+943	98	2678	97	
+654	93	2677	19	
+230	31	2676	39	
+89	631	2675	57	
+510	63	2674	51	
+625	491	2673	52	
+487	513	2672	18	
+760	696	2671	0	
+419	912	2670	77	
+122	375	2669	82	
+4	783	2668	42	
+62	791	2667	28	
+400	826	2666	42	
+567	53	2665	14	
+571	998	2664	57	
+978	334	2663	88	
+816	178	2662	13	
+783	235	2661	72	
+537	949	2660	34	
+591	392	2659	29	
+992	140	2658	11	
+964	864	2657	94	
+773	283	2656	66	
+54	561	2655	83	
+663	694	2654	99	
+156	745	2653	59	
+943	411	2652	16	
+285	386	2651	3	
+557	43	2650	24	
+251	179	2649	94	
+276	176	2648	59	
+581	279	2647	2	
+721	829	2646	19	
+866	836	2645	71	
+949	402	2644	39	
+334	431	2643	50	
+25	128	2642	21	
+342	786	2641	65	
+864	299	2640	72	
+3	348	2639	30	
+896	570	2638	97	
+449	836	2637	69	
+993	472	2636	85	
+434	327	2635	85	
+970	883	2634	91	
+302	294	2633	61	
+342	555	2632	30	
+487	928	2631	68	
+951	423	2630	47	
+777	329	2629	86	
+733	280	2628	10	
+364	835	2627	44	
+144	3	2626	45	
+444	937	2625	55	
+588	303	2624	46	
+739	305	2623	66	
+626	626	2622	96	
+505	204	2621	85	
+93	617	2620	53	
+48	754	2619	17	
+445	659	2618	4	
+831	990	2617	36	
+66	897	2616	22	
+634	95	2615	69	
+997	795	2614	85	
+678	707	2613	84	
+422	106	2612	11	
+586	318	2611	12	
+862	361	2610	41	
+95	129	2609	4	
+668	675	2608	60	
+93	148	2607	61	
+801	520	2606	76	
+300	844	2605	43	
+87	6	2604	63	
+601	735	2603	31	
+787	992	2602	25	
+956	709	2601	83	
+232	366	2600	72	
+454	441	2599	76	
+526	990	2598	42	
+628	848	2597	57	
+676	333	2596	29	
+837	795	2595	50	
+270	317	2594	21	
+743	62	2593	48	
+283	420	2592	81	
+342	111	2591	83	
+925	957	2590	72	
+451	339	2589	77	
+142	852	2588	92	
+514	282	2587	89	
+538	791	2586	95	
+477	287	2585	83	
+255	726	2584	56	
+642	672	2583	52	
+309	983	2582	45	
+153	105	2581	94	
+617	946	2580	41	
+487	850	2579	47	
+569	29	2578	30	
+490	945	2577	62	
+504	114	2576	97	
+561	271	2575	6	
+54	39	2574	22	
+688	67	2573	61	
+877	518	2572	33	
+159	524	2571	15	
+96	942	2570	53	
+820	165	2569	13	
+84	681	2568	91	
+831	651	2567	7	
+842	915	2566	98	
+231	839	2565	94	
+972	609	2564	50	
+548	279	2563	36	
+994	177	2562	81	
+581	619	2561	71	
+777	405	2560	6	
+483	213	2559	27	
+30	838	2558	73	
+736	91	2557	25	
+75	44	2556	98	
+229	435	2555	61	
+329	141	2554	25	
+101	554	2553	42	
+558	91	2552	55	
+213	656	2551	41	
+191	786	2550	80	
+375	540	2549	29	
+746	483	2548	45	
+47	263	2547	29	
+608	378	2546	66	
+294	351	2545	84	
+587	835	2544	90	
+462	869	2543	22	
+435	141	2542	54	
+870	609	2541	34	
+246	509	2540	2	
+56	841	2539	81	
+219	158	2538	62	
+885	634	2537	69	
+26	814	2536	43	
+515	945	2535	31	
+966	672	2534	70	
+728	685	2533	12	
+531	198	2532	2	
+100	322	2531	56	
+667	206	2530	62	
+682	186	2529	18	
+523	931	2528	83	
+820	258	2527	33	
+868	125	2526	85	
+273	607	2525	51	
+987	582	2524	54	
+486	96	2523	23	
+876	462	2522	19	
+115	941	2521	43	
+20	434	2520	43	
+254	352	2519	98	
+672	502	2518	15	
+133	475	2517	70	
+518	347	2516	95	
+24	961	2515	59	
+486	312	2514	28	
+634	40	2513	50	
+521	765	2512	61	
+506	999	2511	76	
+81	447	2510	9	
+850	826	2509	76	
+26	455	2508	58	
+127	751	2507	53	
+386	357	2506	61	
+649	308	2505	49	
+272	785	2504	53	
+274	889	2503	85	
+766	849	2502	11	
+552	666	2501	1	
+621	328	2500	42	
+370	184	2499	23	
+703	41	2498	82	
+394	925	2497	89	
+48	120	2496	74	
+522	956	2495	73	
+896	685	2494	37	
+39	738	2493	99	
+183	98	2492	50	
+338	589	2491	21	
+143	194	2490	93	
+143	407	2489	25	
+116	925	2488	66	
+804	157	2487	30	
+164	4	2486	34	
+270	359	2485	52	
+946	379	2484	62	
+640	488	2483	85	
+509	294	2482	85	
+395	282	2481	84	
+786	681	2480	19	
+482	583	2479	0	
+767	357	2478	2	
+152	963	2477	31	
+645	818	2476	64	
+979	900	2475	89	
+890	769	2474	32	
+194	0	2473	30	
+12	11	2472	13	
+601	650	2471	11	
+97	195	2470	60	
+225	973	2469	30	
+393	714	2468	71	
+145	672	2467	61	
+918	746	2466	50	
+130	570	2465	66	
+769	16	2464	8	
+989	176	2463	69	
+361	16	2462	18	
+454	505	2461	41	
+221	303	2460	50	
+259	590	2459	87	
+42	98	2458	83	
+926	108	2457	24	
+175	841	2456	22	
+553	576	2455	78	
+840	392	2454	36	
+159	515	2453	78	
+511	770	2452	62	
+202	907	2451	90	
+712	631	2450	23	
+492	40	2449	96	
+989	583	2448	21	
+267	21	2447	11	
+265	439	2446	75	
+184	425	2445	62	
+876	581	2444	71	
+744	152	2443	68	
+863	721	2442	64	
+276	672	2441	30	
+590	271	2440	48	
+457	745	2439	22	
+561	100	2438	50	
+581	365	2437	72	
+14	128	2436	0	
+844	908	2435	8	
+429	31	2434	30	
+430	33	2433	13	
+49	339	2432	88	
+401	819	2431	58	
+525	269	2430	68	
+644	717	2429	13	
+735	780	2428	89	
+237	720	2427	98	
+219	919	2426	56	
+876	774	2425	16	
+998	174	2424	41	
+693	251	2423	99	
+520	293	2422	38	
+550	901	2421	64	
+551	551	2420	87	
+936	238	2419	88	
+59	914	2418	90	
+801	412	2417	49	
+145	397	2416	1	
+599	754	2415	34	
+922	416	2414	87	
+957	617	2413	30	
+391	733	2412	17	
+350	772	2411	96	
+313	994	2410	99	
+323	972	2409	61	
+502	411	2408	87	
+15	480	2407	25	
+642	674	2406	65	
+338	465	2405	54	
+798	572	2404	67	
+884	131	2403	96	
+961	203	2402	56	
+777	971	2401	4	
+21	383	2400	3	
+560	737	2399	98	
+931	618	2398	82	
+805	602	2397	48	
+209	110	2396	37	
+892	868	2395	30	
+440	711	2394	53	
+928	399	2393	91	
+231	524	2392	92	
+588	4	2391	18	
+645	47	2390	75	
+118	168	2389	46	
+15	334	2388	62	
+492	114	2387	12	
+241	67	2386	59	
+156	765	2385	31	
+312	625	2384	45	
+875	990	2383	51	
+519	740	2382	69	
+956	427	2381	64	
+879	294	2380	94	
+833	831	2379	52	
+219	504	2378	10	
+47	529	2377	52	
+302	278	2376	25	
+139	865	2375	8	
+634	938	2374	84	
+250	816	2373	43	
+312	53	2372	35	
+132	699	2371	56	
+463	416	2370	7	
+327	423	2369	4	
+974	579	2368	61	
+250	271	2367	17	
+413	166	2366	74	
+926	239	2365	16	
+122	408	2364	50	
+763	81	2363	38	
+353	792	2362	93	
+282	485	2361	18	
+993	32	2360	66	
+843	431	2359	13	
+308	441	2358	35	
+105	427	2357	72	
+926	581	2356	83	
+831	658	2355	48	
+326	120	2354	80	
+289	446	2353	35	
+306	757	2352	41	
+453	511	2351	7	
+601	532	2350	28	
+989	784	2349	15	
+13	628	2348	53	
+846	887	2347	20	
+923	350	2346	17	
+538	681	2345	9	
+673	445	2344	50	
+688	948	2343	3	
+246	339	2342	98	
+978	780	2341	85	
+748	139	2340	85	
+155	614	2339	61	
+741	332	2338	97	
+536	24	2337	16	
+668	83	2336	92	
+235	589	2335	38	
+497	467	2334	86	
+609	54	2333	98	
+558	129	2332	44	
+641	1	2331	26	
+524	240	2330	22	
+282	635	2329	59	
+308	808	2328	41	
+940	244	2327	20	
+493	538	2326	86	
+122	520	2325	43	
+412	878	2324	73	
+925	544	2323	88	
+127	173	2322	5	
+760	38	2321	91	
+605	637	2320	11	
+826	178	2319	24	
+564	210	2318	97	
+705	336	2317	36	
+18	435	2316	44	
+641	693	2315	37	
+334	850	2314	71	
+370	837	2313	48	
+134	133	2312	79	
+401	800	2311	36	
+459	874	2310	15	
+967	268	2309	77	
+873	605	2308	26	
+901	921	2307	85	
+741	75	2306	68	
+843	661	2305	37	
+13	223	2304	30	
+704	688	2303	96	
+333	431	2302	23	
+925	211	2301	73	
+606	375	2300	94	
+662	518	2299	49	
+684	401	2298	9	
+846	172	2297	97	
+414	310	2296	16	
+437	70	2295	89	
+535	343	2294	83	
+257	727	2293	30	
+219	502	2292	37	
+836	791	2291	40	
+857	451	2290	31	
+116	396	2289	94	
+229	122	2288	97	
+861	812	2287	83	
+240	262	2286	43	
+726	67	2285	97	
+615	521	2284	90	
+224	937	2283	27	
+711	962	2282	3	
+340	89	2281	38	
+54	374	2280	97	
+274	965	2279	74	
+309	140	2278	88	
+549	405	2277	36	
+194	455	2276	62	
+546	74	2275	51	
+583	624	2274	11	
+975	239	2273	39	
+873	655	2272	51	
+714	403	2271	37	
+409	238	2270	28	
+824	854	2269	77	
+735	519	2268	96	
+949	745	2267	76	
+381	108	2266	35	
+449	402	2265	64	
+384	720	2264	96	
+584	877	2263	60	
+251	142	2262	10	
+165	84	2261	15	
+384	506	2260	30	
+334	814	2259	58	
+773	204	2258	8	
+637	404	2257	78	
+706	706	2256	56	
+681	685	2255	93	
+842	353	2254	6	
+734	507	2253	80	
+57	942	2252	33	
+578	854	2251	8	
+692	720	2250	78	
+609	494	2249	4	
+799	304	2248	56	
+697	217	2247	13	
+20	635	2246	93	
+331	867	2245	2	
+846	264	2244	83	
+564	467	2243	10	
+87	247	2242	67	
+134	303	2241	47	
+225	732	2240	88	
+190	487	2239	8	
+86	425	2238	80	
+581	205	2237	10	
+768	906	2236	67	
+602	185	2235	68	
+797	730	2234	48	
+219	430	2233	28	
+943	197	2232	47	
+571	593	2231	95	
+244	803	2230	90	
+62	272	2229	3	
+220	707	2228	10	
+299	424	2227	50	
+720	987	2226	81	
+454	203	2225	16	
+300	203	2224	80	
+233	804	2223	57	
+604	523	2222	27	
+790	44	2221	37	
+530	873	2220	32	
+564	932	2219	18	
+283	597	2218	84	
+436	692	2217	92	
+784	646	2216	57	
+0	360	2215	26	
+398	227	2214	15	
+280	301	2213	6	
+479	903	2212	62	
+171	46	2211	81	
+940	143	2210	25	
+334	340	2209	96	
+905	921	2208	28	
+46	341	2207	84	
+285	313	2206	65	
+133	111	2205	78	
+926	87	2204	60	
+397	438	2203	11	
+857	814	2202	80	
+902	554	2201	30	
+802	294	2200	23	
+419	684	2199	60	
+579	435	2198	42	
+28	193	2197	85	
+201	869	2196	76	
+24	181	2195	15	
+649	483	2194	20	
+623	316	2193	52	
+260	493	2192	54	
+259	77	2191	95	
+610	623	2190	10	
+248	177	2189	38	
+242	570	2188	83	
+324	97	2187	55	
+687	608	2186	82	
+698	945	2185	17	
+166	678	2184	37	
+823	988	2183	2	
+416	585	2182	36	
+453	854	2181	0	
+446	717	2180	64	
+606	543	2179	36	
+472	288	2178	0	
+489	724	2177	91	
+662	649	2176	63	
+267	802	2175	98	
+689	349	2174	53	
+402	663	2173	34	
+731	361	2172	40	
+137	351	2171	96	
+174	288	2170	0	
+254	355	2169	84	
+564	87	2168	13	
+74	281	2167	98	
+846	647	2166	82	
+453	457	2165	39	
+685	188	2164	57	
+302	936	2163	28	
+10	444	2162	67	
+62	956	2161	59	
+932	166	2160	96	
+267	706	2159	91	
+806	150	2158	68	
+634	156	2157	48	
+190	432	2156	22	
+268	817	2155	39	
+252	290	2154	76	
+491	615	2153	38	
+487	77	2152	29	
+789	630	2151	94	
+459	43	2150	13	
+556	229	2149	66	
+993	200	2148	46	
+724	261	2147	17	
+615	835	2146	44	
+526	625	2145	92	
+674	384	2144	1	
+537	91	2143	76	
+447	344	2142	0	
+586	817	2141	69	
+813	464	2140	32	
+29	203	2139	90	
+939	289	2138	56	
+425	728	2137	26	
+209	522	2136	10	
+240	904	2135	8	
+293	256	2134	85	
+746	756	2133	13	
+527	305	2132	9	
+352	368	2131	86	
+261	426	2130	77	
+914	341	2129	78	
+561	292	2128	9	
+205	160	2127	51	
+617	20	2126	21	
+648	236	2125	96	
+499	714	2124	94	
+450	47	2123	54	
+937	229	2122	21	
+941	87	2121	17	
+85	988	2120	9	
+48	693	2119	34	
+132	577	2118	35	
+139	297	2117	35	
+783	246	2116	58	
+522	21	2115	96	
+667	401	2114	14	
+817	328	2113	4	
+141	42	2112	51	
+99	84	2111	99	
+295	744	2110	85	
+116	993	2109	3	
+280	997	2108	91	
+50	767	2107	99	
+225	619	2106	35	
+620	820	2105	26	
+72	99	2104	85	
+285	536	2103	84	
+958	517	2102	67	
+340	139	2101	4	
+750	820	2100	80	
+996	120	2099	17	
+229	923	2098	83	
+148	636	2097	23	
+798	94	2096	82	
+721	406	2095	60	
+562	5	2094	54	
+19	173	2093	78	
+377	634	2092	32	
+319	238	2091	61	
+699	624	2090	58	
+196	343	2089	75	
+286	605	2088	76	
+542	405	2087	8	
+687	218	2086	34	
+401	58	2085	7	
+831	759	2084	15	
+538	460	2083	54	
+396	708	2082	64	
+613	28	2081	5	
+281	836	2080	61	
+737	987	2079	50	
+199	685	2078	90	
+186	731	2077	74	
+160	272	2076	85	
+298	919	2075	28	
+299	615	2074	56	
+751	901	2073	29	
+680	582	2072	14	
+192	439	2071	78	
+849	116	2070	33	
+301	593	2069	54	
+953	165	2068	53	
+459	889	2067	1	
+353	569	2066	2	
+303	715	2065	86	
+714	276	2064	99	
+318	150	2063	54	
+143	359	2062	7	
+323	450	2061	48	
+522	787	2060	34	
+428	6	2059	54	
+275	524	2058	34	
+319	986	2057	49	
+853	164	2056	10	
+438	863	2055	4	
+126	451	2054	58	
+790	476	2053	39	
+908	583	2052	17	
+662	145	2051	82	
+781	796	2050	80	
+481	198	2049	9	
+538	854	2048	15	
+822	387	2047	95	
+301	56	2046	46	
+411	460	2045	41	
+975	193	2044	31	
+893	221	2043	33	
+437	354	2042	88	
+349	19	2041	24	
+597	705	2040	88	
+343	942	2039	30	
+466	196	2038	94	
+330	489	2037	71	
+596	51	2036	52	
+266	101	2035	88	
+972	977	2034	43	
+866	453	2033	8	
+334	635	2032	45	
+314	365	2031	8	
+762	580	2030	75	
+746	356	2029	25	
+706	227	2028	87	
+438	195	2027	13	
+949	631	2026	73	
+124	453	2025	33	
+524	353	2024	29	
+817	626	2023	10	
+270	367	2022	53	
+784	336	2021	2	
+224	498	2020	55	
+129	376	2019	1	
+32	740	2018	4	
+563	402	2017	26	
+178	403	2016	48	
+99	35	2015	82	
+727	188	2014	59	
+259	573	2013	70	
+30	511	2012	54	
+838	469	2011	48	
+121	535	2010	55	
+635	975	2009	9	
+338	773	2008	9	
+998	777	2007	46	
+367	664	2006	38	
+847	225	2005	7	
+614	892	2004	37	
+62	160	2003	46	
+42	60	2002	22	
+934	926	2001	19	
+559	465	2000	71	
+202	997	1999	48	
+995	629	1998	29	
+113	82	1997	34	
+438	306	1996	63	
+333	707	1995	52	
+731	904	1994	23	
+99	238	1993	55	
+133	36	1992	1	
+461	476	1991	10	
+467	230	1990	37	
+368	188	1989	35	
+546	957	1988	20	
+776	709	1987	88	
+599	110	1986	67	
+802	287	1985	10	
+666	679	1984	60	
+201	533	1983	63	
+560	910	1982	96	
+245	733	1981	67	
+42	17	1980	99	
+231	150	1979	9	
+247	324	1978	82	
+599	207	1977	77	
+822	569	1976	17	
+607	503	1975	79	
+146	969	1974	13	
+622	666	1973	46	
+177	293	1972	64	
+715	678	1971	31	
+867	894	1970	20	
+825	277	1969	81	
+117	51	1968	98	
+637	593	1967	64	
+66	379	1966	77	
+533	661	1965	21	
+303	670	1964	46	
+372	823	1963	52	
+615	326	1962	44	
+783	111	1961	46	
+617	392	1960	84	
+225	827	1959	4	
+458	335	1958	70	
+213	870	1957	48	
+718	562	1956	57	
+990	753	1955	53	
+847	937	1954	23	
+497	79	1953	93	
+214	983	1952	75	
+718	613	1951	83	
+564	805	1950	16	
+492	335	1949	39	
+464	227	1948	76	
+308	909	1947	24	
+809	38	1946	49	
+816	302	1945	72	
+858	298	1944	14	
+95	173	1943	35	
+370	925	1942	28	
+807	665	1941	49	
+470	773	1940	15	
+108	625	1939	7	
+317	521	1938	2	
+871	750	1937	15	
+735	766	1936	49	
+3	585	1935	99	
+124	792	1934	95	
+248	68	1933	76	
+259	786	1932	72	
+891	342	1931	56	
+148	81	1930	33	
+104	44	1929	36	
+770	871	1928	79	
+984	657	1927	44	
+181	504	1926	13	
+792	35	1925	73	
+724	195	1924	87	
+281	38	1923	87	
+444	161	1922	98	
+260	225	1921	36	
+36	974	1920	74	
+172	571	1919	4	
+214	344	1918	33	
+153	310	1917	78	
+468	403	1916	80	
+840	853	1915	38	
+156	2	1914	6	
+876	887	1913	44	
+935	620	1912	83	
+250	624	1911	18	
+403	699	1910	22	
+227	709	1909	86	
+33	548	1908	95	
+907	982	1907	6	
+550	413	1906	68	
+850	321	1905	62	
+114	624	1904	68	
+267	605	1903	27	
+996	654	1902	94	
+924	959	1901	68	
+990	360	1900	84	
+161	905	1899	17	
+565	897	1898	19	
+568	376	1897	12	
+92	56	1896	35	
+697	943	1895	69	
+19	404	1894	73	
+950	338	1893	84	
+695	256	1892	27	
+598	837	1891	7	
+454	672	1890	93	
+7	980	1889	82	
+520	68	1888	59	
+320	769	1887	99	
+112	657	1886	47	
+539	962	1885	39	
+65	889	1884	67	
+82	577	1883	6	
+418	197	1882	25	
+164	138	1881	9	
+691	104	1880	14	
+912	233	1879	44	
+299	598	1878	48	
+111	520	1877	20	
+694	82	1876	20	
+73	716	1875	57	
+312	609	1874	47	
+379	814	1873	98	
+58	157	1872	66	
+34	952	1871	25	
+871	697	1870	47	
+635	959	1869	77	
+77	286	1868	61	
+438	993	1867	18	
+365	634	1866	41	
+106	99	1865	62	
+794	490	1864	76	
+656	319	1863	93	
+205	409	1862	32	
+254	780	1861	2	
+738	694	1860	16	
+673	165	1859	23	
+293	425	1858	55	
+358	770	1857	63	
+534	796	1856	7	
+608	859	1855	25	
+171	829	1854	31	
+909	610	1853	13	
+629	297	1852	45	
+86	861	1851	95	
+528	927	1850	51	
+740	677	1849	6	
+655	918	1848	38	
+973	566	1847	93	
+936	813	1846	82	
+30	946	1845	92	
+218	174	1844	43	
+313	686	1843	26	
+435	500	1842	28	
+933	434	1841	54	
+249	451	1840	55	
+759	684	1839	78	
+351	446	1838	8	
+753	110	1837	68	
+866	897	1836	3	
+772	488	1835	90	
+487	175	1834	81	
+186	982	1833	90	
+65	737	1832	87	
+983	984	1831	50	
+766	769	1830	68	
+238	704	1829	49	
+335	402	1828	40	
+212	644	1827	59	
+408	131	1826	88	
+313	93	1825	9	
+193	908	1824	28	
+244	26	1823	30	
+752	376	1822	12	
+215	817	1821	8	
+65	194	1820	21	
+302	82	1819	52	
+757	809	1818	90	
+513	711	1817	12	
+37	793	1816	80	
+185	808	1815	9	
+882	985	1814	12	
+649	179	1813	94	
+558	39	1812	49	
+623	864	1811	53	
+111	689	1810	14	
+272	624	1809	76	
+98	780	1808	54	
+917	318	1807	24	
+985	708	1806	47	
+822	974	1805	85	
+806	172	1804	30	
+139	455	1803	23	
+175	955	1802	9	
+174	387	1801	93	
+65	386	1800	51	
+844	218	1799	83	
+461	301	1798	17	
+610	767	1797	18	
+733	623	1796	93	
+802	549	1795	16	
+716	70	1794	1	
+499	141	1793	66	
+568	155	1792	96	
+1	423	1791	0	
+167	672	1790	10	
+916	665	1789	22	
+534	992	1788	38	
+144	248	1787	85	
+73	770	1786	87	
+479	145	1785	93	
+929	350	1784	8	
+985	701	1783	21	
+732	963	1782	93	
+751	891	1781	56	
+7	888	1780	83	
+672	837	1779	25	
+744	531	1778	38	
+477	975	1777	38	
+625	944	1776	7	
+794	845	1775	59	
+648	868	1774	54	
+738	286	1773	94	
+72	363	1772	25	
+2	733	1771	98	
+50	583	1770	74	
+306	867	1769	33	
+556	993	1768	92	
+30	318	1767	26	
+99	477	1766	85	
+976	43	1765	83	
+582	605	1764	14	
+922	691	1763	91	
+629	272	1762	66	
+150	236	1761	7	
+715	409	1760	95	
+874	406	1759	74	
+674	660	1758	74	
+841	415	1757	52	
+433	21	1756	93	
+438	684	1755	12	
+914	235	1754	39	
+419	244	1753	65	
+35	595	1752	29	
+826	118	1751	47	
+2	206	1750	43	
+746	995	1749	84	
+245	223	1748	20	
+393	595	1747	83	
+336	807	1746	40	
+449	728	1745	99	
+990	734	1744	52	
+649	366	1743	49	
+476	813	1742	38	
+912	44	1741	20	
+211	594	1740	82	
+771	640	1739	25	
+628	366	1738	50	
+787	425	1737	85	
+78	412	1736	5	
+994	470	1735	88	
+368	29	1734	45	
+552	111	1733	34	
+769	173	1732	17	
+449	385	1731	56	
+954	567	1730	70	
+273	755	1729	43	
+941	649	1728	14	
+12	793	1727	84	
+942	170	1726	70	
+441	428	1725	8	
+917	117	1724	62	
+937	167	1723	81	
+788	609	1722	78	
+818	863	1721	32	
+811	261	1720	49	
+105	296	1719	68	
+855	301	1718	33	
+623	132	1717	92	
+742	624	1716	7	
+310	457	1715	50	
+950	811	1714	52	
+558	32	1713	97	
+746	462	1712	14	
+601	825	1711	96	
+964	814	1710	0	
+994	348	1709	70	
+168	403	1708	25	
+508	858	1707	23	
+166	569	1706	88	
+646	976	1705	43	
+779	544	1704	35	
+569	829	1703	39	
+637	180	1702	81	
+10	962	1701	14	
+466	301	1700	63	
+944	455	1699	96	
+544	17	1698	82	
+289	351	1697	66	
+592	448	1696	34	
+432	72	1695	51	
+715	967	1694	86	
+649	579	1693	21	
+218	667	1692	93	
+660	507	1691	62	
+845	666	1690	54	
+438	143	1689	52	
+665	166	1688	40	
+903	317	1687	25	
+376	823	1686	69	
+104	651	1685	16	
+388	657	1684	71	
+912	279	1683	6	
+159	303	1682	43	
+840	82	1681	55	
+522	23	1680	81	
+977	121	1679	40	
+848	144	1678	77	
+493	558	1677	76	
+171	536	1676	52	
+994	443	1675	27	
+378	651	1674	71	
+975	635	1673	47	
+220	872	1672	75	
+59	742	1671	31	
+901	407	1670	31	
+976	634	1669	54	
+586	10	1668	12	
+22	234	1667	35	
+93	255	1666	32	
+792	555	1665	17	
+15	240	1664	61	
+762	723	1663	40	
+130	433	1662	75	
+335	0	1661	16	
+772	772	1660	15	
+623	415	1659	92	
+776	774	1658	39	
+979	32	1657	56	
+699	145	1656	92	
+315	561	1655	30	
+516	212	1654	77	
+290	648	1653	25	
+432	593	1652	63	
+227	2	1651	79	
+356	233	1650	56	
+641	534	1649	14	
+742	826	1648	84	
+887	634	1647	79	
+584	628	1646	28	
+348	524	1645	38	
+563	523	1644	79	
+55	620	1643	22	
+590	838	1642	85	
+769	231	1641	20	
+698	414	1640	87	
+707	300	1639	71	
+191	51	1638	89	
+6	516	1637	85	
+103	896	1636	30	
+1	585	1635	23	
+902	572	1634	78	
+782	368	1633	50	
+606	653	1632	46	
+816	333	1631	82	
+113	155	1630	7	
+249	815	1629	99	
+534	44	1628	51	
+620	551	1627	18	
+310	67	1626	90	
+12	451	1625	10	
+204	276	1624	9	
+714	42	1623	11	
+320	644	1622	17	
+177	750	1621	79	
+339	79	1620	70	
+771	475	1619	86	
+492	330	1618	71	
+484	282	1617	91	
+616	800	1616	30	
+174	3	1615	29	
+233	979	1614	80	
+398	943	1613	49	
+894	385	1612	39	
+670	87	1611	14	
+603	839	1610	83	
+145	148	1609	56	
+48	800	1608	27	
+481	605	1607	0	
+797	10	1606	86	
+24	491	1605	44	
+35	317	1604	94	
+558	95	1603	83	
+298	252	1602	50	
+247	304	1601	22	
+690	268	1600	6	
+348	290	1599	45	
+195	269	1598	9	
+594	140	1597	56	
+519	426	1596	68	
+174	499	1595	77	
+221	106	1594	98	
+843	330	1593	47	
+947	280	1592	25	
+35	157	1591	5	
+978	607	1590	55	
+21	361	1589	34	
+129	529	1588	15	
+713	883	1587	60	
+926	910	1586	7	
+393	784	1585	34	
+776	511	1584	95	
+50	217	1583	37	
+123	209	1582	89	
+549	493	1581	91	
+245	214	1580	5	
+832	189	1579	95	
+646	551	1578	89	
+972	526	1577	41	
+126	729	1576	78	
+273	392	1575	53	
+294	574	1574	61	
+7	482	1573	72	
+715	982	1572	92	
+278	855	1571	57	
+25	100	1570	30	
+637	65	1569	41	
+25	476	1568	18	
+796	628	1567	67	
+336	253	1566	84	
+818	916	1565	85	
+91	891	1564	97	
+499	798	1563	28	
+127	353	1562	29	
+754	270	1561	43	
+35	889	1560	25	
+589	227	1559	38	
+847	511	1558	61	
+375	828	1557	22	
+336	992	1556	45	
+24	874	1555	51	
+93	693	1554	72	
+444	994	1553	59	
+82	854	1552	37	
+380	184	1551	37	
+662	864	1550	71	
+715	775	1549	44	
+683	383	1548	74	
+835	768	1547	47	
+118	941	1546	3	
+181	792	1545	31	
+698	134	1544	93	
+139	220	1543	64	
+669	999	1542	36	
+319	653	1541	70	
+88	273	1540	71	
+392	703	1539	94	
+614	270	1538	3	
+827	432	1537	84	
+148	727	1536	71	
+658	380	1535	93	
+914	282	1534	48	
+221	286	1533	55	
+345	659	1532	46	
+379	983	1531	35	
+570	771	1530	23	
+432	915	1529	69	
+838	182	1528	77	
+705	132	1527	78	
+346	778	1526	67	
+97	455	1525	48	
+995	922	1524	74	
+627	89	1523	69	
+676	119	1522	87	
+211	119	1521	96	
+856	534	1520	80	
+732	919	1519	13	
+50	990	1518	59	
+353	107	1517	13	
+323	189	1516	35	
+533	745	1515	24	
+832	51	1514	10	
+970	817	1513	36	
+0	908	1512	95	
+584	157	1511	46	
+615	671	1510	35	
+928	542	1509	12	
+882	461	1508	68	
+918	774	1507	69	
+444	109	1506	3	
+693	147	1505	79	
+233	733	1504	70	
+908	417	1503	86	
+751	486	1502	96	
+485	109	1501	41	
+129	230	1500	96	
+81	442	1499	68	
+686	984	1498	4	
+665	666	1497	96	
+961	240	1496	47	
+414	89	1495	75	
+315	838	1494	45	
+931	892	1493	32	
+376	554	1492	15	
+879	445	1491	26	
+788	282	1490	35	
+457	640	1489	4	
+318	81	1488	39	
+425	490	1487	2	
+150	723	1486	70	
+251	291	1485	54	
+945	134	1484	9	
+338	167	1483	38	
+108	891	1482	55	
+163	909	1481	49	
+642	308	1480	9	
+558	653	1479	33	
+591	373	1478	13	
+767	316	1477	89	
+432	156	1476	27	
+156	449	1475	89	
+967	713	1474	30	
+276	829	1473	60	
+981	58	1472	22	
+601	405	1471	94	
+654	760	1470	52	
+279	191	1469	8	
+56	246	1468	96	
+160	617	1467	82	
+706	375	1466	33	
+735	593	1465	27	
+884	698	1464	18	
+770	377	1463	69	
+652	284	1462	29	
+644	424	1461	38	
+568	437	1460	94	
+945	115	1459	37	
+628	143	1458	22	
+241	489	1457	89	
+782	58	1456	45	
+894	86	1455	97	
+320	498	1454	85	
+93	396	1453	11	
+859	914	1452	11	
+986	433	1451	0	
+321	571	1450	7	
+972	151	1449	62	
+653	327	1448	31	
+430	441	1447	38	
+972	482	1446	45	
+588	120	1445	88	
+102	736	1444	57	
+481	996	1443	22	
+480	109	1442	23	
+862	931	1441	87	
+419	453	1440	66	
+824	306	1439	34	
+885	930	1438	31	
+959	927	1437	22	
+362	571	1436	45	
+384	313	1435	38	
+739	347	1434	48	
+886	993	1433	62	
+178	360	1432	0	
+478	207	1431	61	
+147	316	1430	44	
+375	29	1429	59	
+2	96	1428	93	
+356	764	1427	92	
+257	74	1426	59	
+966	897	1425	97	
+354	865	1424	64	
+632	619	1423	85	
+153	382	1422	70	
+891	175	1421	69	
+286	846	1420	33	
+933	657	1419	77	
+332	11	1418	37	
+689	329	1417	64	
+176	618	1416	9	
+32	333	1415	29	
+245	791	1414	61	
+237	144	1413	72	
+207	9	1412	47	
+328	368	1411	26	
+189	559	1410	60	
+645	397	1409	35	
+681	727	1408	60	
+711	547	1407	64	
+285	807	1406	51	
+542	679	1405	14	
+647	890	1404	78	
+135	242	1403	0	
+640	217	1402	2	
+809	656	1401	87	
+161	251	1400	13	
+669	752	1399	54	
+180	958	1398	96	
+740	129	1397	97	
+127	368	1396	42	
+789	357	1395	74	
+647	778	1394	89	
+25	978	1393	51	
+560	151	1392	49	
+404	739	1391	83	
+499	594	1390	64	
+793	580	1389	49	
+829	993	1388	48	
+761	544	1387	44	
+10	682	1386	61	
+579	848	1385	33	
+799	382	1384	14	
+827	17	1383	62	
+411	663	1382	46	
+145	184	1381	15	
+14	154	1380	90	
+587	3	1379	70	
+448	48	1378	96	
+862	828	1377	6	
+834	274	1376	75	
+466	195	1375	43	
+364	520	1374	78	
+354	156	1373	97	
+479	308	1372	41	
+29	251	1371	26	
+151	198	1370	13	
+954	742	1369	42	
+220	895	1368	13	
+554	317	1367	58	
+78	319	1366	2	
+674	650	1365	36	
+364	808	1364	10	
+848	555	1363	0	
+56	149	1362	87	
+53	135	1361	44	
+455	703	1360	87	
+846	287	1359	19	
+578	552	1358	73	
+997	558	1357	66	
+669	659	1356	47	
+842	266	1355	40	
+252	91	1354	31	
+405	134	1353	51	
+14	425	1352	79	
+431	572	1351	0	
+415	680	1350	59	
+735	462	1349	60	
+994	68	1348	26	
+898	190	1347	58	
+393	72	1346	32	
+174	92	1345	82	
+957	794	1344	58	
+708	724	1343	84	
+853	787	1342	39	
+891	405	1341	58	
+217	989	1340	1	
+393	340	1339	68	
+878	687	1338	74	
+118	252	1337	9	
+979	501	1336	50	
+297	237	1335	21	
+69	742	1334	21	
+936	456	1333	24	
+382	808	1332	85	
+416	566	1331	96	
+648	335	1330	67	
+653	940	1329	82	
+435	644	1328	51	
+750	591	1327	76	
+264	285	1326	13	
+495	2	1325	68	
+285	968	1324	22	
+647	393	1323	13	
+242	893	1322	55	
+230	287	1321	96	
+395	849	1320	76	
+296	308	1319	99	
+52	755	1318	21	
+305	621	1317	68	
+283	456	1316	48	
+34	453	1315	76	
+574	94	1314	20	
+500	578	1313	63	
+605	587	1312	40	
+438	198	1311	1	
+541	772	1310	83	
+553	777	1309	9	
+133	533	1308	24	
+164	198	1307	74	
+3	716	1306	2	
+358	560	1305	24	
+515	570	1304	45	
+991	233	1303	7	
+388	393	1302	89	
+426	176	1301	16	
+995	736	1300	89	
+243	856	1299	98	
+334	495	1298	42	
+482	724	1297	96	
+156	773	1296	16	
+989	789	1295	64	
+337	386	1294	84	
+840	178	1293	52	
+216	728	1292	60	
+440	270	1291	96	
+880	909	1290	43	
+360	566	1289	75	
+771	451	1288	90	
+950	807	1287	85	
+984	517	1286	32	
+403	801	1285	16	
+207	318	1284	65	
+450	922	1283	49	
+458	639	1282	62	
+360	531	1281	77	
+342	679	1280	56	
+115	842	1279	51	
+644	57	1278	58	
+290	526	1277	82	
+715	158	1276	96	
+483	515	1275	58	
+395	155	1274	19	
+282	873	1273	75	
+108	847	1272	99	
+851	216	1271	9	
+837	40	1270	1	
+784	931	1269	22	
+531	768	1268	47	
+367	853	1267	35	
+643	385	1266	57	
+359	385	1265	23	
+282	437	1264	8	
+26	765	1263	11	
+630	894	1262	17	
+176	79	1261	25	
+109	790	1260	1	
+162	757	1259	5	
+914	115	1258	25	
+468	780	1257	16	
+999	342	1256	72	
+947	143	1255	28	
+672	975	1254	7	
+871	939	1253	25	
+814	916	1252	39	
+289	243	1251	45	
+32	961	1250	6	
+642	798	1249	94	
+335	90	1248	24	
+437	439	1247	44	
+198	440	1246	46	
+168	205	1245	5	
+35	822	1244	27	
+22	860	1243	80	
+673	940	1242	5	
+281	387	1241	52	
+162	119	1240	25	
+708	698	1239	39	
+650	802	1238	30	
+998	977	1237	89	
+235	417	1236	23	
+383	776	1235	3	
+961	474	1234	13	
+919	744	1233	1	
+552	530	1232	34	
+268	268	1231	39	
+421	866	1230	11	
+896	83	1229	45	
+824	408	1228	5	
+560	659	1227	65	
+641	208	1226	76	
+301	897	1225	85	
+729	120	1224	42	
+213	663	1223	4	
+262	958	1222	36	
+402	272	1221	28	
+782	664	1220	84	
+674	396	1219	52	
+749	405	1218	7	
+451	889	1217	26	
+311	911	1216	91	
+776	430	1215	33	
+457	379	1214	57	
+704	675	1213	51	
+685	81	1212	95	
+608	438	1211	86	
+267	321	1210	61	
+991	453	1209	10	
+515	806	1208	92	
+978	345	1207	29	
+480	579	1206	14	
+51	768	1205	53	
+703	55	1204	31	
+594	564	1203	75	
+643	91	1202	1	
+116	240	1201	7	
+868	512	1200	34	
+646	182	1199	27	
+461	627	1198	47	
+765	158	1197	53	
+811	605	1196	49	
+712	214	1195	42	
+491	567	1194	34	
+472	733	1193	10	
+850	942	1192	95	
+728	735	1191	52	
+329	65	1190	24	
+554	799	1189	22	
+469	938	1188	18	
+552	39	1187	69	
+391	69	1186	95	
+647	80	1185	9	
+834	239	1184	22	
+790	157	1183	1	
+206	423	1182	62	
+669	278	1181	12	
+266	25	1180	39	
+860	37	1179	77	
+898	489	1178	8	
+970	741	1177	91	
+988	855	1176	16	
+840	878	1175	74	
+81	201	1174	81	
+733	396	1173	4	
+145	499	1172	58	
+253	723	1171	53	
+988	623	1170	40	
+548	689	1169	40	
+748	169	1168	96	
+886	755	1167	92	
+976	416	1166	98	
+676	931	1165	14	
+805	769	1164	75	
+897	458	1163	34	
+776	48	1162	58	
+99	133	1161	89	
+934	997	1160	26	
+520	443	1159	44	
+413	34	1158	79	
+339	946	1157	86	
+485	833	1156	90	
+161	389	1155	29	
+310	410	1154	87	
+410	758	1153	90	
+914	696	1152	12	
+135	627	1151	67	
+553	824	1150	16	
+409	640	1149	41	
+87	937	1148	10	
+113	952	1147	7	
+443	610	1146	85	
+979	428	1145	32	
+651	963	1144	85	
+62	787	1143	90	
+69	444	1142	49	
+803	511	1141	77	
+183	750	1140	58	
+702	307	1139	14	
+985	32	1138	32	
+342	220	1137	97	
+182	530	1136	67	
+464	472	1135	46	
+176	950	1134	32	
+342	404	1133	58	
+933	717	1132	99	
+760	196	1131	26	
+442	437	1130	62	
+275	822	1129	48	
+811	347	1128	71	
+689	304	1127	64	
+58	205	1126	16	
+521	136	1125	71	
+546	737	1124	28	
+687	596	1123	83	
+520	727	1122	40	
+758	645	1121	17	
+615	139	1120	31	
+474	763	1119	16	
+43	73	1118	46	
+98	483	1117	12	
+69	442	1116	63	
+399	429	1115	53	
+141	455	1114	97	
+868	423	1113	85	
+82	236	1112	16	
+506	855	1111	76	
+375	150	1110	14	
+690	702	1109	14	
+590	342	1108	43	
+40	491	1107	94	
+13	93	1106	2	
+974	562	1105	66	
+31	115	1104	25	
+186	692	1103	27	
+380	405	1102	78	
+705	618	1101	57	
+447	1	1100	13	
+360	711	1099	68	
+851	484	1098	9	
+397	916	1097	55	
+530	359	1096	2	
+446	411	1095	3	
+423	986	1094	94	
+287	485	1093	84	
+786	210	1092	80	
+617	445	1091	67	
+290	445	1090	25	
+226	585	1089	8	
+567	549	1088	50	
+557	523	1087	45	
+948	987	1086	86	
+424	97	1085	8	
+500	97	1084	2	
+274	38	1083	13	
+765	131	1082	50	
+999	416	1081	16	
+859	170	1080	32	
+36	578	1079	6	
+25	55	1078	65	
+536	586	1077	1	
+890	782	1076	60	
+999	60	1075	52	
+59	887	1074	92	
+906	634	1073	22	
+715	332	1072	50	
+245	841	1071	76	
+592	263	1070	13	
+522	404	1069	82	
+469	648	1068	1	
+803	401	1067	48	
+721	85	1066	64	
+173	599	1065	89	
+253	697	1064	93	
+302	717	1063	15	
+490	742	1062	19	
+577	626	1061	46	
+858	316	1060	65	
+756	812	1059	7	
+246	521	1058	5	
+315	843	1057	66	
+486	755	1056	8	
+901	950	1055	54	
+979	787	1054	91	
+975	961	1053	95	
+115	722	1052	81	
+309	816	1051	91	
+504	581	1050	71	
+290	18	1049	10	
+678	386	1048	51	
+87	584	1047	93	
+804	533	1046	82	
+163	628	1045	58	
+825	968	1044	92	
+239	139	1043	0	
+905	899	1042	86	
+234	193	1041	80	
+563	616	1040	80	
+632	591	1039	21	
+802	579	1038	61	
+50	101	1037	59	
+904	243	1036	28	
+659	663	1035	64	
+829	917	1034	33	
+240	143	1033	58	
+705	54	1032	33	
+576	0	1031	67	
+25	590	1030	67	
+11	602	1029	93	
+477	21	1028	82	
+857	307	1027	75	
+580	642	1026	14	
+745	302	1025	24	
+774	751	1024	83	
+89	252	1023	58	
+53	663	1022	53	
+410	999	1021	12	
+988	739	1020	55	
+580	101	1019	1	
+714	78	1018	53	
+664	604	1017	61	
+339	902	1016	27	
+550	414	1015	83	
+499	240	1014	97	
+589	54	1013	68	
+663	406	1012	3	
+260	577	1011	64	
+637	538	1010	42	
+23	479	1009	40	
+473	914	1008	86	
+702	342	1007	5	
+487	442	1006	32	
+173	863	1005	78	
+185	285	1004	5	
+648	649	1003	91	
+829	392	1002	92	
+39	221	1001	40	
+58	13	1000	62	
+565	542	999	61	
+571	815	998	54	
+899	725	997	77	
+578	535	996	21	
+578	738	995	31	
+636	141	994	98	
+257	984	993	53	
+170	522	992	81	
+207	781	991	78	
+471	7	990	98	
+726	64	989	49	
+89	778	988	99	
+190	556	987	67	
+797	900	986	32	
+596	326	985	0	
+156	450	984	94	
+461	718	983	37	
+741	29	982	8	
+773	809	981	96	
+942	486	980	73	
+286	499	979	74	
+221	321	978	63	
+656	351	977	89	
+573	320	976	39	
+876	59	975	20	
+731	562	974	44	
+688	292	973	69	
+220	123	972	72	
+322	226	971	96	
+986	991	970	83	
+178	107	969	65	
+970	737	968	6	
+30	506	967	56	
+261	192	966	8	
+496	760	965	69	
+270	745	964	14	
+168	974	963	4	
+896	752	962	46	
+235	136	961	89	
+883	174	960	33	
+369	590	959	80	
+231	501	958	20	
+313	480	957	93	
+432	387	956	76	
+15	551	955	76	
+770	101	954	22	
+221	574	953	10	
+615	571	952	27	
+962	561	951	66	
+584	527	950	35	
+89	600	949	51	
+20	268	948	13	
+93	169	947	91	
+835	4	946	88	
+450	539	945	41	
+526	122	944	24	
+3	831	943	54	
+9	609	942	60	
+34	309	941	65	
+926	837	940	37	
+331	375	939	49	
+98	221	938	6	
+164	35	937	92	
+465	464	936	25	
+416	173	935	38	
+291	695	934	92	
+221	943	933	52	
+299	951	932	99	
+472	276	931	97	
+461	882	930	10	
+154	426	929	59	
+185	142	928	23	
+571	668	927	93	
+291	873	926	69	
+477	461	925	4	
+751	401	924	12	
+991	528	923	6	
+675	19	922	92	
+393	867	921	82	
+455	512	920	1	
+284	361	919	30	
+474	298	918	96	
+794	235	917	61	
+412	650	916	28	
+59	923	915	81	
+873	55	914	72	
+508	148	913	75	
+152	94	912	31	
+354	816	911	28	
+151	703	910	93	
+63	338	909	17	
+63	355	908	81	
+584	333	907	67	
+727	467	906	38	
+867	86	905	35	
+907	966	904	18	
+53	443	903	36	
+277	34	902	35	
+113	343	901	79	
+364	766	900	20	
+983	361	899	8	
+22	130	898	99	
+865	296	897	47	
+380	29	896	85	
+119	165	895	85	
+523	821	894	96	
+409	8	893	85	
+690	557	892	77	
+576	595	891	16	
+405	115	890	74	
+230	88	889	38	
+834	520	888	96	
+266	622	887	15	
+864	997	886	48	
+344	898	885	26	
+812	106	884	59	
+451	78	883	11	
+962	611	882	71	
+479	415	881	11	
+27	367	880	17	
+567	420	879	17	
+898	804	878	39	
+624	670	877	56	
+99	224	876	40	
+791	664	875	51	
+28	482	874	53	
+466	395	873	36	
+195	603	872	48	
+48	943	871	48	
+946	995	870	45	
+616	779	869	45	
+133	828	868	66	
+446	164	867	27	
+559	883	866	52	
+182	988	865	30	
+86	169	864	76	
+791	872	863	56	
+660	5	862	27	
+948	30	861	14	
+215	992	860	10	
+950	790	859	33	
+664	394	858	48	
+281	749	857	68	
+894	217	856	88	
+818	544	855	37	
+296	201	854	9	
+866	290	853	29	
+975	123	852	13	
+37	45	851	71	
+202	771	850	73	
+395	847	849	26	
+645	795	848	28	
+532	800	847	38	
+672	508	846	38	
+343	282	845	7	
+910	800	844	52	
+167	163	843	42	
+78	418	842	89	
+273	979	841	93	
+924	467	840	83	
+52	978	839	80	
+995	903	838	75	
+291	995	837	11	
+226	311	836	85	
+482	553	835	32	
+636	92	834	43	
+744	538	833	74	
+439	953	832	8	
+511	102	831	80	
+489	28	830	34	
+74	56	829	87	
+907	636	828	5	
+684	253	827	70	
+758	530	826	6	
+460	896	825	74	
+554	690	824	84	
+584	654	823	89	
+851	284	822	30	
+73	454	821	92	
+972	477	820	2	
+419	814	819	41	
+383	352	818	16	
+723	638	817	22	
+633	320	816	92	
+205	898	815	29	
+35	953	814	90	
+369	586	813	96	
+829	378	812	73	
+976	904	811	77	
+662	607	810	10	
+462	248	809	55	
+714	943	808	3	
+318	297	807	65	
+421	627	806	8	
+945	391	805	42	
+366	936	804	17	
+208	236	803	66	
+473	955	802	54	
+297	675	801	85	
+358	548	800	31	
+305	516	799	20	
+645	377	798	74	
+669	569	797	39	
+236	661	796	89	
+455	257	795	47	
+699	504	794	57	
+280	125	793	15	
+280	687	792	73	
+126	538	791	17	
+32	113	790	93	
+138	452	789	5	
+808	351	788	65	
+907	500	787	97	
+404	419	786	43	
+753	897	785	78	
+378	420	784	75	
+437	423	783	41	
+149	559	782	0	
+425	236	781	15	
+660	885	780	9	
+101	394	779	89	
+851	683	778	33	
+80	542	777	90	
+522	653	776	50	
+477	24	775	65	
+996	336	774	37	
+864	418	773	94	
+322	847	772	28	
+350	59	771	72	
+491	200	770	76	
+710	563	769	55	
+141	429	768	24	
+889	397	767	77	
+628	852	766	55	
+688	276	765	4	
+917	433	764	48	
+571	652	763	13	
+787	564	762	54	
+859	958	761	97	
+636	205	760	85	
+133	309	759	78	
+32	477	758	56	
+545	213	757	25	
+576	513	756	26	
+843	563	755	93	
+780	348	754	77	
+88	590	753	34	
+605	569	752	78	
+752	112	751	92	
+895	79	750	22	
+832	210	749	50	
+264	317	748	10	
+699	991	747	48	
+949	321	746	96	
+215	169	745	73	
+758	424	744	6	
+21	561	743	69	
+457	855	742	48	
+33	706	741	85	
+868	718	740	85	
+893	401	739	6	
+326	614	738	56	
+669	517	737	56	
+152	236	736	75	
+744	669	735	73	
+862	370	734	45	
+706	209	733	73	
+149	629	732	56	
+987	995	731	42	
+316	793	730	16	
+787	496	729	97	
+97	2	728	56	
+280	815	727	65	
+566	15	726	51	
+299	277	725	40	
+161	719	724	88	
+580	173	723	15	
+633	140	722	55	
+202	259	721	16	
+296	189	720	67	
+494	408	719	52	
+186	910	718	68	
+799	138	717	81	
+737	110	716	71	
+558	526	715	26	
+546	725	714	13	
+33	598	713	58	
+880	395	712	94	
+69	490	711	43	
+780	140	710	90	
+498	840	709	80	
+771	872	708	30	
+28	102	707	38	
+584	446	706	6	
+800	129	705	17	
+126	557	704	1	
+202	634	703	51	
+905	515	702	15	
+350	526	701	81	
+300	102	700	28	
+967	495	699	28	
+770	920	698	72	
+655	325	697	74	
+316	882	696	44	
+572	166	695	78	
+922	499	694	67	
+119	360	693	92	
+989	341	692	29	
+423	521	691	55	
+607	6	690	4	
+575	556	689	33	
+594	983	688	19	
+442	298	687	11	
+716	660	686	33	
+667	109	685	74	
+138	750	684	65	
+18	626	683	80	
+819	742	682	13	
+515	504	681	56	
+449	717	680	81	
+572	135	679	3	
+684	82	678	98	
+637	775	677	15	
+551	594	676	72	
+358	94	675	4	
+124	846	674	52	
+883	673	673	11	
+237	564	672	19	
+787	749	671	30	
+581	783	670	6	
+52	51	669	87	
+306	827	668	88	
+180	426	667	4	
+500	677	666	8	
+247	519	665	19	
+173	409	664	23	
+108	920	663	24	
+814	895	662	64	
+965	238	661	45	
+731	188	660	20	
+224	989	659	52	
+401	840	658	74	
+748	961	657	12	
+158	893	656	68	
+110	958	655	25	
+488	993	654	7	
+25	595	653	6	
+656	195	652	29	
+49	244	651	84	
+199	677	650	23	
+148	782	649	50	
+879	620	648	82	
+67	445	647	65	
+935	426	646	59	
+964	179	645	4	
+398	9	644	62	
+400	770	643	46	
+951	445	642	36	
+566	614	641	60	
+894	726	640	84	
+162	684	639	5	
+174	170	638	26	
+18	61	637	81	
+247	543	636	13	
+169	425	635	97	
+238	158	634	56	
+325	94	633	99	
+830	761	632	44	
+888	757	631	38	
+41	798	630	67	
+514	783	629	73	
+108	456	628	98	
+518	679	627	15	
+117	161	626	77	
+267	405	625	7	
+63	567	624	93	
+333	549	623	91	
+3	64	622	49	
+959	712	621	94	
+15	939	620	84	
+326	743	619	52	
+776	833	618	40	
+518	384	617	59	
+756	693	616	40	
+837	147	615	84	
+18	17	614	20	
+484	417	613	72	
+351	554	612	33	
+772	93	611	4	
+196	320	610	94	
+910	120	609	68	
+449	815	608	55	
+690	188	607	25	
+546	551	606	76	
+129	645	605	91	
+599	474	604	81	
+863	399	603	53	
+460	286	602	13	
+773	100	601	57	
+199	255	600	57	
+304	138	599	28	
+627	292	598	46	
+637	495	597	75	
+906	843	596	14	
+170	100	595	41	
+75	285	594	52	
+112	400	593	73	
+185	553	592	40	
+845	2	591	68	
+116	291	590	57	
+845	823	589	89	
+796	703	588	67	
+652	613	587	99	
+742	727	586	73	
+815	886	585	73	
+884	794	584	9	
+846	332	583	96	
+551	716	582	92	
+711	114	581	33	
+467	678	580	72	
+120	217	579	27	
+89	687	578	4	
+886	259	577	14	
+841	995	576	90	
+92	640	575	92	
+462	132	574	93	
+615	35	573	3	
+602	587	572	29	
+436	611	571	83	
+460	457	570	24	
+529	222	569	34	
+428	904	568	3	
+263	234	567	20	
+355	981	566	4	
+507	997	565	74	
+97	892	564	63	
+447	742	563	84	
+976	455	562	1	
+153	595	561	16	
+234	896	560	97	
+318	316	559	93	
+670	827	558	10	
+252	158	557	16	
+984	296	556	90	
+104	118	555	84	
+150	784	554	41	
+287	832	553	65	
+859	848	552	47	
+699	190	551	82	
+579	44	550	91	
+489	829	549	91	
+668	936	548	64	
+862	256	547	41	
+178	60	546	26	
+333	437	545	88	
+952	759	544	95	
+984	180	543	86	
+657	647	542	42	
+146	903	541	16	
+214	3	540	11	
+892	268	539	9	
+680	230	538	82	
+196	149	537	80	
+622	387	536	68	
+678	926	535	84	
+579	91	534	38	
+532	435	533	96	
+744	267	532	32	
+900	40	531	51	
+735	29	530	93	
+37	269	529	32	
+80	14	528	21	
+762	122	527	48	
+460	839	526	57	
+835	462	525	94	
+656	413	524	9	
+167	641	523	4	
+226	815	522	78	
+11	580	521	84	
+759	609	520	16	
+254	109	519	69	
+892	728	518	95	
+283	909	517	31	
+376	630	516	30	
+48	845	515	62	
+772	52	514	17	
+825	258	513	48	
+235	944	512	94	
+970	678	511	21	
+500	467	510	25	
+380	741	509	50	
+819	638	508	36	
+279	15	507	60	
+785	676	506	90	
+792	446	505	32	
+793	690	504	27	
+313	547	503	94	
+265	725	502	59	
+211	963	501	26	
+726	746	500	47	
+102	143	499	11	
+622	752	498	56	
+339	702	497	54	
+229	578	496	49	
+756	51	495	99	
+142	329	494	99	
+821	356	493	48	
+762	326	492	4	
+216	793	491	5	
+603	351	490	48	
+390	558	489	62	
+50	20	488	47	
+123	46	487	28	
+527	501	486	10	
+722	993	485	47	
+973	519	484	61	
+30	432	483	32	
+532	993	482	5	
+442	568	481	54	
+792	861	480	61	
+537	144	479	21	
+974	195	478	34	
+544	174	477	92	
+508	635	476	59	
+474	860	475	80	
+86	292	474	74	
+438	261	473	94	
+424	512	472	49	
+706	933	471	8	
+717	399	470	65	
+948	873	469	25	
+20	413	468	56	
+539	329	467	42	
+774	792	466	3	
+568	55	465	3	
+30	806	464	38	
+748	445	463	64	
+579	408	462	1	
+533	439	461	71	
+526	395	460	98	
+459	691	459	76	
+84	133	458	92	
+537	393	457	48	
+736	2	456	76	
+249	646	455	20	
+360	739	454	53	
+36	633	453	28	
+969	296	452	16	
+43	728	451	4	
+703	220	450	0	
+558	840	449	6	
+740	446	448	37	
+390	716	447	54	
+355	558	446	80	
+907	668	445	48	
+106	256	444	88	
+337	112	443	32	
+568	122	442	6	
+507	40	441	92	
+379	938	440	34	
+393	692	439	14	
+730	827	438	81	
+157	747	437	34	
+890	312	436	3	
+411	599	435	44	
+144	564	434	80	
+989	256	433	76	
+82	142	432	76	
+101	584	431	6	
+246	194	430	12	
+864	327	429	98	
+80	468	428	66	
+434	314	427	57	
+713	587	426	26	
+35	647	425	47	
+307	31	424	26	
+114	0	423	15	
+557	708	422	90	
+390	932	421	98	
+867	141	420	85	
+859	322	419	38	
+154	90	418	78	
+726	305	417	64	
+939	788	416	72	
+615	211	415	67	
+31	112	414	72	
+291	247	413	19	
+775	925	412	55	
+790	126	411	16	
+819	473	410	52	
+232	597	409	0	
+784	138	408	70	
+517	924	407	42	
+576	43	406	78	
+99	950	405	32	
+864	533	404	58	
+322	636	403	74	
+798	389	402	51	
+653	644	401	98	
+875	514	400	97	
+458	302	399	58	
+214	278	398	44	
+880	640	397	26	
+92	463	396	94	
+417	739	395	47	
+897	844	394	23	
+246	224	393	54	
+745	530	392	52	
+129	13	391	14	
+212	385	390	77	
+24	138	389	41	
+637	182	388	24	
+176	325	387	33	
+723	464	386	78	
+895	241	385	67	
+619	693	384	52	
+694	17	383	65	
+517	378	382	50	
+627	367	381	61	
+247	360	380	91	
+956	174	379	18	
+856	909	378	38	
+860	545	377	46	
+222	112	376	45	
+547	155	375	82	
+675	870	374	27	
+639	148	373	92	
+11	886	372	17	
+6	698	371	88	
+186	729	370	38	
+264	801	369	29	
+363	925	368	9	
+432	8	367	99	
+957	624	366	63	
+285	552	365	67	
+721	350	364	87	
+261	748	363	3	
+188	287	362	62	
+968	508	361	0	
+928	89	360	82	
+875	191	359	92	
+916	103	358	90	
+384	358	357	93	
+71	962	356	47	
+202	803	355	67	
+601	835	354	56	
+461	408	353	45	
+778	622	352	7	
+419	183	351	21	
+897	899	350	3	
+88	20	349	5	
+745	970	348	95	
+395	455	347	53	
+159	802	346	31	
+967	109	345	86	
+426	103	344	60	
+786	386	343	14	
+438	853	342	68	
+284	180	341	35	
+879	986	340	52	
+50	94	339	80	
+514	426	338	34	
+653	219	337	34	
+693	444	336	23	
+5	268	335	19	
+717	460	334	54	
+532	457	333	64	
+673	323	332	34	
+193	837	331	15	
+892	711	330	40	
+667	465	329	82	
+207	994	328	53	
+775	112	327	86	
+175	44	326	95	
+808	650	325	68	
+2	900	324	28	
+133	293	323	18	
+485	192	322	85	
+126	749	321	48	
+246	576	320	30	
+471	292	319	22	
+881	674	318	46	
+68	901	317	43	
+394	272	316	59	
+749	398	315	36	
+607	104	314	80	
+100	325	313	86	
+443	378	312	64	
+172	178	311	35	
+284	76	310	88	
+617	763	309	77	
+773	28	308	59	
+629	832	307	81	
+873	232	306	67	
+294	561	305	64	
+778	936	304	14	
+947	221	303	50	
+199	287	302	65	
+102	479	301	27	
+312	105	300	88	
+735	184	299	66	
+195	777	298	84	
+599	139	297	14	
+671	29	296	75	
+624	502	295	57	
+714	635	294	51	
+934	849	293	83	
+807	387	292	74	
+374	381	291	9	
+921	221	290	78	
+406	822	289	57	
+638	700	288	53	
+109	387	287	59	
+527	177	286	92	
+867	62	285	4	
+785	684	284	91	
+461	84	283	78	
+5	649	282	12	
+160	308	281	43	
+399	211	280	45	
+122	38	279	51	
+312	943	278	76	
+210	668	277	52	
+114	880	276	58	
+377	136	275	65	
+600	129	274	8	
+434	654	273	32	
+341	692	272	45	
+96	981	271	84	
+173	937	270	76	
+95	746	269	27	
+274	239	268	80	
+787	946	267	10	
+743	922	266	9	
+6	578	265	73	
+475	757	264	77	
+961	867	263	16	
+711	611	262	9	
+43	84	261	24	
+190	483	260	92	
+507	467	259	7	
+292	708	258	82	
+23	5	257	48	
+343	359	256	4	
+821	958	255	73	
+889	611	254	53	
+256	73	253	51	
+526	848	252	25	
+600	321	251	66	
+16	845	250	85	
+759	258	249	68	
+703	332	248	21	
+645	443	247	26	
+400	307	246	67	
+347	205	245	52	
+538	16	244	93	
+225	264	243	63	
+526	582	242	72	
+476	815	241	92	
+587	168	240	58	
+925	469	239	25	
+889	945	238	5	
+136	589	237	5	
+101	157	236	24	
+189	591	235	5	
+752	297	234	80	
+681	904	233	31	
+766	803	232	69	
+646	341	231	5	
+699	327	230	88	
+523	200	229	66	
+356	997	228	3	
+431	813	227	75	
+566	190	226	3	
+293	244	225	91	
+393	496	224	43	
+100	614	223	7	
+461	648	222	91	
+13	160	221	11	
+126	227	220	94	
+202	626	219	17	
+184	282	218	16	
+623	718	217	92	
+946	122	216	86	
+747	475	215	27	
+882	366	214	89	
+965	155	213	29	
+487	795	212	63	
+933	173	211	44	
+601	770	210	88	
+343	9	209	92	
+563	242	208	1	
+596	58	207	56	
+646	592	206	67	
+109	373	205	19	
+210	606	204	86	
+360	653	203	91	
+622	191	202	47	
+402	560	201	55	
+761	963	200	33	
+766	904	199	25	
+183	458	198	78	
+466	884	197	96	
+219	477	196	94	
+767	333	195	53	
+952	948	194	89	
+462	438	193	85	
+630	923	192	73	
+597	222	191	21	
+58	74	190	64	
+446	477	189	99	
+573	812	188	58	
+406	17	187	71	
+143	413	186	24	
+384	637	185	45	
+510	48	184	81	
+515	112	183	48	
+700	518	182	83	
+148	579	181	3	
+596	645	180	53	
+664	412	179	61	
+795	865	178	87	
+604	470	177	16	
+775	794	176	26	
+589	637	175	75	
+935	324	174	87	
+594	657	173	99	
+939	799	172	81	
+933	494	171	55	
+233	926	170	55	
+547	738	169	93	
+394	706	168	86	
+675	904	167	19	
+157	503	166	82	
+313	885	165	18	
+667	879	164	65	
+857	181	163	34	
+305	261	162	65	
+567	1	161	0	
+187	618	160	70	
+32	63	159	68	
+801	677	158	15	
+400	362	157	71	
+618	642	156	51	
+6	532	155	84	
+697	311	154	64	
+919	685	153	80	
+260	649	152	55	
+382	305	151	73	
+555	14	150	38	
+385	532	149	15	
+315	434	148	23	
+719	200	147	40	
+109	674	146	78	
+221	198	145	61	
+625	836	144	30	
+36	257	143	77	
+344	814	142	65	
+290	357	141	87	
+481	225	140	82	
+98	923	139	16	
+233	829	138	7	
+525	618	137	59	
+476	169	136	60	
+361	304	135	88	
+578	529	134	59	
+442	119	133	58	
+457	780	132	69	
+131	51	131	5	
+301	657	130	80	
+93	99	129	38	
+210	473	128	86	
+449	986	127	70	
+865	721	126	4	
+774	293	125	11	
+410	5	124	78	
+338	897	123	13	
+729	638	122	98	
+394	244	121	32	
+557	426	120	82	
+625	517	119	20	
+487	157	118	88	
+265	658	117	76	
+427	934	116	58	
+288	331	115	9	
+107	647	114	36	
+258	151	113	7	
+394	658	112	60	
+818	496	111	33	
+908	622	110	83	
+360	324	109	93	
+498	121	108	13	
+724	178	107	22	
+603	492	106	83	
+684	727	105	13	
+495	291	104	18	
+492	463	103	84	
+162	273	102	86	
+873	498	101	57	
+297	904	100	90	
+203	793	99	54	
+943	916	98	86	
+685	383	97	77	
+764	699	96	12	
+436	958	95	91	
+827	331	94	18	
+189	984	93	0	
+775	288	92	32	
+593	666	91	28	
+111	361	90	57	
+877	686	89	9	
+532	87	88	26	
+684	653	87	25	
+740	202	86	92	
+627	730	85	32	
+347	184	84	60	
+695	673	83	63	
+621	40	82	41	
+304	712	81	18	
+675	482	80	48	
+598	833	79	23	
+434	3	78	34	
+450	336	77	84	
+471	592	76	94	
+546	719	75	11	
+510	971	74	28	
+633	223	73	65	
+328	231	72	7	
+229	700	71	31	
+649	248	70	62	
+830	888	69	7	
+666	497	68	16	
+743	903	67	98	
+873	831	66	97	
+747	833	65	92	
+747	628	64	3	
+992	576	63	87	
+530	757	62	30	
+452	687	61	9	
+359	552	60	57	
+391	913	59	81	
+593	180	58	16	
+72	4	57	92	
+997	54	56	87	
+204	889	55	12	
+51	157	54	99	
+819	573	53	75	
+69	204	52	46	
+134	520	51	7	
+639	759	50	9	
+732	656	49	96	
+176	240	48	79	
+950	52	47	52	
+164	745	46	7	
+732	125	45	79	
+584	244	44	15	
+368	294	43	23	
+684	383	42	74	
+760	984	41	93	
+103	126	40	49	
+416	169	39	90	
+187	276	38	55	
+307	447	37	22	
+619	281	36	78	
+881	641	35	43	
+950	920	34	14	
+910	482	33	21	
+398	814	32	68	
+858	439	31	92	
+956	588	30	65	
+893	350	29	68	
+829	330	28	22	
+165	440	27	88	
+639	354	26	68	
+720	284	25	73	
+437	931	24	93	
+667	531	23	3	
+375	760	22	51	
+850	266	21	53	
+238	970	20	90	
+20	457	19	6	
+890	348	18	6	
+86	192	17	66	
+69	949	16	52	
+352	807	15	91	
+400	891	14	28	
+771	526	13	76	
+493	972	12	29	
+296	637	11	52	
+512	839	10	61	
+108	998	9	21	
+156	400	8	12	
+242	137	7	80	
+141	606	6	1	
+916	635	5	71	
+364	513	4	95	
+553	477	3	62	
+335	768	2	27	
+798	911	1	19	
+840	394	0	78	
+@nodes
+source	252	
+@end
Index: test/dim_test.cc
===================================================================
--- test/dim_test.cc	(revision 2658)
+++ test/dim_test.cc	(revision 2561)
@@ -3,5 +3,5 @@
  * This file is a part of LEMON, a generic C++ optimization library
  *
- * Copyright (C) 2003-2006
+ * Copyright (C) 2003-2008
  * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
  * (Egervary Research Group on Combinatorial Optimization, EGRES).
@@ -23,64 +23,65 @@
 using namespace std;
 using namespace lemon;
+
 int main()
 {
-
-  cout << "Testing classes `dim2::Point' and `dim2::BoundingBox'." << endl;
+  cout << "Testing classes 'dim2::Point' and 'dim2::BoundingBox'." << endl;
 
   typedef dim2::Point<int> Point;
-	
-  Point seged;
-  check(seged.size()==2, "Wrong vector addition");
+
+  Point p;
+  check(p.size()==2, "Wrong vector initialization.");
 
   Point a(1,2);
   Point b(3,4);
+  check(a[0]==1 && a[1]==2, "Wrong vector initialization.");
 
-  check(a[0]==1 && a[1]==2, "Wrong vector addition");
+  p = a+b;
+  check(p.x==4 && p.y==6, "Wrong vector addition.");
 
-  seged = a+b;
-  check(seged.x==4 && seged.y==6, "Wrong vector addition");
+  p = a-b;
+  check(p.x==-2 && p.y==-2, "Wrong vector subtraction.");
 
-  seged = a-b;
-  check(seged.x==-2 && seged.y==-2, "a-b");
-
-  check(a.normSquare()==5,"Wrong norm calculation");
-  check(a*b==11, "a*b");
+  check(a.normSquare()==5,"Wrong vector norm calculation.");
+  check(a*b==11, "Wrong vector scalar product.");
 
   int l=2;
-  seged = a*l;
-  check(seged.x==2 && seged.y==4, "a*l");
+  p = a*l;
+  check(p.x==2 && p.y==4, "Wrong vector multiplication by a scalar.");
 
-  seged = b/l;
-  check(seged.x==1 && seged.y==2, "b/l");
+  p = b/l;
+  check(p.x==1 && p.y==2, "Wrong vector division by a scalar.");
 
   typedef dim2::BoundingBox<int> BB;
-  BB doboz1;
-  check(doboz1.empty(), "It should be empty.");
-	
-  doboz1.add(a);
-  check(!doboz1.empty(), "It should not be empty.");
-  doboz1.add(b);
+  BB box1;
+  check(box1.empty(), "It should be empty.");
 
-  check(doboz1.bottomLeft().x==1 && 
-        doboz1.bottomLeft().y==2 &&
-        doboz1.topRight().x==3 && 
-        doboz1.topRight().y==4,  
-        "added points to box");
+  box1.add(a);
+  check(!box1.empty(), "It should not be empty.");
+  box1.add(b);
 
-  seged.x=2;seged.y=3;
-  check(doboz1.inside(seged),"It should be inside.");
+  check(box1.bottomLeft().x==1 &&
+        box1.bottomLeft().y==2 &&
+        box1.topRight().x==3 &&
+        box1.topRight().y==4,
+        "Wrong addition of points to box.");
 
-  seged.x=1;seged.y=3;
-  check(doboz1.inside(seged),"It should be inside.");
+  p.x=2; p.y=3;
+  check(box1.inside(p), "It should be inside.");
 
-  seged.x=0;seged.y=3;
-  check(!doboz1.inside(seged),"It should not be inside.");
+  p.x=1; p.y=3;
+  check(box1.inside(p), "It should be inside.");
 
-  BB doboz2(seged);
-  check(!doboz2.empty(),
+  p.x=0; p.y=3;
+  check(!box1.inside(p), "It should not be inside.");
+
+  BB box2(p);
+  check(!box2.empty(),
         "It should not be empty. Constructed from 1 point.");
 
-  doboz2.add(doboz1);
-  check(doboz2.inside(seged),
+  box2.add(box1);
+  check(box2.inside(p),
         "It should be inside. Incremented a box with another one.");
+
+  return 0;
 }
Index: test/edge_set_test.cc
===================================================================
--- test/edge_set_test.cc	(revision 2553)
+++ test/edge_set_test.cc	(revision 2553)
@@ -0,0 +1,49 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <vector>
+
+#include <lemon/concepts/graph.h>
+#include <lemon/concepts/ugraph.h>
+#include <lemon/smart_graph.h>
+
+#include <lemon/edge_set.h>
+
+#include "test_tools.h"
+#include "graph_test.h"
+#include "map_test.h"
+
+
+using namespace lemon;
+using namespace lemon::concepts;
+
+typedef SmartGraph RGraph;
+
+int main() {
+  { // checking edge_sets
+    checkConcept<Graph, ListEdgeSet<RGraph> >();
+    checkConcept<UGraph, ListUEdgeSet<RGraph> >();
+    checkConcept<Graph, SmartEdgeSet<RGraph> >();
+    checkConcept<UGraph, SmartUEdgeSet<RGraph> >();
+  }
+
+  std::cout << __FILE__ ": All tests passed.\n";
+
+  return 0;
+}
Index: test/error_test.cc
===================================================================
--- test/error_test.cc	(revision 2553)
+++ test/error_test.cc	(revision 2553)
@@ -0,0 +1,67 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+
+#include <lemon/error.h>
+#include "test_tools.h"
+using namespace lemon;
+using std::cout;
+using std::endl;
+
+void faulty_fn() {
+  fault("This is a fault message");
+}
+
+void exception_fn() {
+  throw Exception("This is a fn throwing excpt with some args: ") 
+    << 5 << ", " << 18;
+}
+
+void unfinished_fn() {
+  FIXME("unfinished_fn() is unfinished!");
+}
+
+
+int main() {
+  try {
+    faulty_fn();
+    check(false, "A faulty function did not fail.");
+  }
+  catch(const Exception &e) {
+    cout << "Exeption = \"" << e.what() << "\" (Right behaviour)" << endl;
+  }
+
+  try {
+    exception_fn();
+    check(false, "The function did not throw Exception.");
+  }
+  catch(const Exception &e) {
+    cout << "Exeption = \"" << e.what() << "\" (Right behaviour)" << endl;
+  }
+
+  try {
+    unfinished_fn();
+    check(false, "FIXME macro does not work.");
+  }
+  catch(const Exception &e) {
+    cout << "Exeption = \"" << e.what() << "\" (Right behaviour)" << endl;
+  }
+
+  return 0;
+}
Index: test/graph_adaptor_test.cc
===================================================================
--- test/graph_adaptor_test.cc	(revision 2553)
+++ test/graph_adaptor_test.cc	(revision 2553)
@@ -0,0 +1,91 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<iostream>
+#include<lemon/concept_check.h>
+
+#include<lemon/smart_graph.h>
+#include<lemon/concepts/graph.h>
+#include<lemon/concepts/ugraph.h>
+#include<lemon/concepts/bpugraph.h>
+
+#include<lemon/list_graph.h>
+#include<lemon/full_graph.h>
+#include<lemon/graph_adaptor.h>
+#include<lemon/ugraph_adaptor.h>
+#include<lemon/bpugraph_adaptor.h>
+
+#include"test/test_tools.h"
+#include"test/graph_test.h"
+
+/**
+\file
+This test makes consistency checks of graph adaptors.
+
+\todo More extensive tests are needed 
+*/
+
+using namespace lemon;
+using namespace lemon::concepts;
+
+
+
+int main() 
+{
+  {
+    typedef Graph Graph;
+    checkConcept<Graph, GraphAdaptor<Graph> >();
+
+    checkConcept<Graph, RevGraphAdaptor<Graph> >();
+
+    checkConcept<Graph, SubGraphAdaptor<Graph, 
+      Graph::NodeMap<bool> , Graph::EdgeMap<bool> > >();
+    checkConcept<Graph, NodeSubGraphAdaptor<Graph, 
+      Graph::NodeMap<bool> > >();
+    checkConcept<Graph, EdgeSubGraphAdaptor<Graph, 
+      Graph::EdgeMap<bool> > >();
+    
+    checkConcept<Graph, ResGraphAdaptor<Graph, int, 
+      Graph::EdgeMap<int>, Graph::EdgeMap<int> > >();
+
+    checkConcept<Graph, ErasingFirstGraphAdaptor<Graph, 
+      Graph::NodeMap<Graph::Edge> > >(); 
+
+    checkConcept<Graph, SplitGraphAdaptor<Graph> >(); 
+
+    checkConcept<UGraph, UndirGraphAdaptor<Graph> >();
+
+    checkConcept<UGraph, SubUGraphAdaptor<UGraph, 
+      UGraph::NodeMap<bool> , UGraph::UEdgeMap<bool> > >();
+    checkConcept<UGraph, NodeSubUGraphAdaptor<UGraph, 
+      UGraph::NodeMap<bool> > >();
+    checkConcept<UGraph, EdgeSubUGraphAdaptor<UGraph, 
+      UGraph::UEdgeMap<bool> > >();
+
+    checkConcept<Graph, DirUGraphAdaptor<UGraph, 
+      UGraph::UEdgeMap<bool> > >();
+
+    checkConcept<BpUGraph, BpUGraphAdaptor<BpUGraph> >();
+
+    checkConcept<BpUGraph, SwapBpUGraphAdaptor<BpUGraph> >();
+
+  }
+  std::cout << __FILE__ ": All tests passed.\n";
+
+  return 0;
+}
Index: test/graph_copy_test.cc
===================================================================
--- test/graph_copy_test.cc	(revision 2553)
+++ test/graph_copy_test.cc	(revision 2553)
@@ -0,0 +1,330 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/smart_graph.h>
+#include <lemon/list_graph.h>
+#include <lemon/graph_reader.h>
+#include <lemon/graph_utils.h>
+#include <lemon/error.h>
+
+#include "test_tools.h"
+
+using namespace std;
+using namespace lemon;
+
+void graph_copy_test() {
+  const int nn = 10;
+
+  SmartGraph source;
+  SmartGraph::NodeMap<int> snm(source);
+  SmartGraph::EdgeMap<int> sem(source);
+  SmartGraph::Node sn = INVALID;
+  SmartGraph::Edge se = INVALID;
+
+  std::vector<SmartGraph::Node> snv;
+  for (int i = 0; i < nn; ++i) {
+    SmartGraph::Node node = source.addNode();
+    snv.push_back(node);
+    snm[node] = i * i;
+    if (i == 0) sn = node;
+  }
+
+  for (int i = 0; i < nn; ++i) {
+    for (int j = 0; j < nn; ++j) {
+      SmartGraph::Edge edge = source.addEdge(snv[i], snv[j]);
+      sem[edge] = i + j * j;
+      if (i == 0 && j == 0) se = edge;
+    }
+  }
+
+  ListGraph target;
+  ListGraph::NodeMap<int> tnm(target);
+  ListGraph::EdgeMap<int> tem(target);
+  ListGraph::Node tn;
+  ListGraph::Edge te;
+
+  SmartGraph::NodeMap<ListGraph::Node> nr(source);
+  SmartGraph::EdgeMap<ListGraph::Edge> er(source);
+
+  ListGraph::NodeMap<SmartGraph::Node> ncr(target);
+  ListGraph::EdgeMap<SmartGraph::Edge> ecr(target);
+
+  GraphCopy<ListGraph, SmartGraph>(target, source).
+    nodeMap(tnm, snm).edgeMap(tem, sem).
+    nodeRef(nr).edgeRef(er).
+    nodeCrossRef(ncr).edgeCrossRef(ecr).
+    node(tn, sn).edge(te, se).run();
+
+  for (SmartGraph::NodeIt it(source); it != INVALID; ++it) {
+    check(ncr[nr[it]] == it, "Wrong copy.");
+    check(snm[it] == tnm[nr[it]], "Wrong copy.");
+  }
+
+  for (SmartGraph::EdgeIt it(source); it != INVALID; ++it) {
+    check(ecr[er[it]] == it, "Wrong copy.");
+    check(sem[it] == tem[er[it]], "Wrong copy.");
+    check(nr[source.source(it)] == 
+                 target.source(er[it]), "Wrong copy.");
+    check(nr[source.target(it)] == 
+                 target.target(er[it]), "Wrong copy.");
+  }
+
+  for (ListGraph::NodeIt it(target); it != INVALID; ++it) {
+    check(nr[ncr[it]] == it, "Wrong copy.");
+  }
+
+  for (ListGraph::EdgeIt it(target); it != INVALID; ++it) {
+    check(er[ecr[it]] == it, "Wrong copy.");
+  }
+  check(tn == nr[sn], "Wrong copy.");
+  check(te == er[se], "Wrong copy.");
+}
+
+void ugraph_copy_test() {
+  const int nn = 10;
+
+  SmartUGraph source;
+  SmartUGraph::NodeMap<int> snm(source);
+  SmartUGraph::EdgeMap<int> sem(source);
+  SmartUGraph::UEdgeMap<int> suem(source);
+  SmartUGraph::Node sn = INVALID;
+  SmartUGraph::Edge se = INVALID;
+  SmartUGraph::UEdge sue = INVALID;
+
+  std::vector<SmartUGraph::Node> snv;
+  for (int i = 0; i < nn; ++i) {
+    SmartUGraph::Node node = source.addNode();
+    snv.push_back(node);
+    snm[node] = i * i;
+    if (i == 0) sn = node;
+  }
+
+  for (int i = 0; i < nn; ++i) {
+    for (int j = 0; j < nn; ++j) {
+      SmartUGraph::UEdge edge = source.addEdge(snv[i], snv[j]);
+      suem[edge] = i * i + j * j;
+      sem[source.direct(edge, true)] = i + j * j;
+      sem[source.direct(edge, false)] = i * i + j;
+      if (i == 0 && j == 0) se = source.direct(edge, true);
+      if (i == 0 && j == 0) sue = edge;
+    }
+  }
+  
+  ListUGraph target;
+  ListUGraph::NodeMap<int> tnm(target);
+  ListUGraph::EdgeMap<int> tem(target);
+  ListUGraph::UEdgeMap<int> tuem(target);
+  ListUGraph::Node tn;
+  ListUGraph::Edge te;
+  ListUGraph::UEdge tue;
+
+  SmartUGraph::NodeMap<ListUGraph::Node> nr(source);
+  SmartUGraph::EdgeMap<ListUGraph::Edge> er(source);
+  SmartUGraph::UEdgeMap<ListUGraph::UEdge> uer(source);
+
+  ListUGraph::NodeMap<SmartUGraph::Node> ncr(target);
+  ListUGraph::EdgeMap<SmartUGraph::Edge> ecr(target);
+  ListUGraph::UEdgeMap<SmartUGraph::UEdge> uecr(target);
+
+  UGraphCopy<ListUGraph, SmartUGraph>(target, source).
+    nodeMap(tnm, snm).edgeMap(tem, sem).uEdgeMap(tuem, suem).
+    nodeRef(nr).edgeRef(er).uEdgeRef(uer).
+    nodeCrossRef(ncr).edgeCrossRef(ecr).uEdgeCrossRef(uecr).
+    node(tn, sn).edge(te, se).uEdge(tue, sue).run();
+
+  for (SmartUGraph::NodeIt it(source); it != INVALID; ++it) {
+    check(ncr[nr[it]] == it, "Wrong copy.");
+    check(snm[it] == tnm[nr[it]], "Wrong copy.");
+  }
+
+  for (SmartUGraph::EdgeIt it(source); it != INVALID; ++it) {
+    check(ecr[er[it]] == it, "Wrong copy.");
+    check(sem[it] == tem[er[it]], "Wrong copy.");
+    check(nr[source.source(it)] == 
+                 target.source(er[it]), "Wrong copy.");
+    check(nr[source.target(it)] == 
+                 target.target(er[it]), "Wrong copy.");
+  }
+
+  for (SmartUGraph::UEdgeIt it(source); it != INVALID; ++it) {
+    check(uecr[uer[it]] == it, "Wrong copy.");
+    check(suem[it] == tuem[uer[it]], "Wrong copy.");
+    check(nr[source.source(it)] == target.source(uer[it]) ||
+                 nr[source.source(it)] == target.target(uer[it]), 
+                 "Wrong copy.");
+    check(nr[source.target(it)] == target.source(uer[it]) ||
+                 nr[source.target(it)] == target.target(uer[it]), 
+                 "Wrong copy.");
+    check((source.source(it) != source.target(it)) ==
+                 (target.source(uer[it]) != target.target(uer[it])), 
+                 "Wrong copy.");
+  }
+
+  for (ListUGraph::NodeIt it(target); it != INVALID; ++it) {
+    check(nr[ncr[it]] == it, "Wrong copy.");
+  }
+
+  for (ListUGraph::EdgeIt it(target); it != INVALID; ++it) {
+    check(er[ecr[it]] == it, "Wrong copy.");
+  }
+  for (ListUGraph::UEdgeIt it(target); it != INVALID; ++it) {
+    check(uer[uecr[it]] == it, "Wrong copy.");
+  }
+  check(tn == nr[sn], "Wrong copy.");
+  check(te == er[se], "Wrong copy.");
+  check(tue == uer[sue], "Wrong copy.");
+}
+
+void bpugraph_copy_test() {
+  const int nn = 10;
+
+  SmartBpUGraph source;
+  SmartBpUGraph::ANodeMap<int> sanm(source);
+  SmartBpUGraph::BNodeMap<int> sbnm(source);
+  SmartBpUGraph::NodeMap<int> snm(source);
+  SmartBpUGraph::EdgeMap<int> sem(source);
+  SmartBpUGraph::UEdgeMap<int> suem(source);
+  SmartBpUGraph::Node sn = INVALID;
+  SmartBpUGraph::Edge se = INVALID;
+  SmartBpUGraph::UEdge sue = INVALID;
+
+  std::vector<SmartBpUGraph::Node> sanv;
+  for (int i = 0; i < nn; ++i) {
+    SmartBpUGraph::Node node = source.addANode();
+    sanv.push_back(node);
+    sanm[node] = i * i;
+    snm[node] = i * i + i;
+    if (i == 0) sn = node;
+  }
+
+  std::vector<SmartBpUGraph::Node> sbnv;
+  for (int i = 0; i < nn; ++i) {
+    SmartBpUGraph::Node node = source.addBNode();
+    sbnv.push_back(node);
+    sbnm[node] = i * i - i;
+    snm[node] = i * i + i + 1;
+  }
+
+  for (int i = 0; i < nn; ++i) {
+    for (int j = 0; j < nn; ++j) {
+      SmartBpUGraph::UEdge edge = source.addEdge(sanv[i], sbnv[j]);
+      suem[edge] = i * i + j * j;
+      sem[source.direct(edge, true)] = i + j * j;
+      sem[source.direct(edge, false)] = i * i + j;
+      if (i == 0 && j == 0) se = source.direct(edge, true);
+      if (i == 0 && j == 0) sue = edge;
+    }
+  }
+  
+  ListBpUGraph target;
+  ListBpUGraph::ANodeMap<int> tanm(target);
+  ListBpUGraph::BNodeMap<int> tbnm(target);
+  ListBpUGraph::NodeMap<int> tnm(target);
+  ListBpUGraph::EdgeMap<int> tem(target);
+  ListBpUGraph::UEdgeMap<int> tuem(target);
+  ListBpUGraph::Node tn;
+  ListBpUGraph::Edge te;
+  ListBpUGraph::UEdge tue;
+
+  SmartBpUGraph::ANodeMap<ListBpUGraph::Node> anr(source);
+  SmartBpUGraph::BNodeMap<ListBpUGraph::Node> bnr(source);
+  SmartBpUGraph::NodeMap<ListBpUGraph::Node> nr(source);
+  SmartBpUGraph::EdgeMap<ListBpUGraph::Edge> er(source);
+  SmartBpUGraph::UEdgeMap<ListBpUGraph::UEdge> uer(source);
+
+  ListBpUGraph::ANodeMap<SmartBpUGraph::Node> ancr(target);
+  ListBpUGraph::BNodeMap<SmartBpUGraph::Node> bncr(target);
+  ListBpUGraph::NodeMap<SmartBpUGraph::Node> ncr(target);
+  ListBpUGraph::EdgeMap<SmartBpUGraph::Edge> ecr(target);
+  ListBpUGraph::UEdgeMap<SmartBpUGraph::UEdge> uecr(target);
+
+  BpUGraphCopy<ListBpUGraph, SmartBpUGraph>(target, source).
+    aNodeMap(tanm, sanm).bNodeMap(tbnm, sbnm).nodeMap(tnm, snm).
+    edgeMap(tem, sem).uEdgeMap(tuem, suem).
+    aNodeRef(anr).bNodeRef(bnr).nodeRef(nr).edgeRef(er).uEdgeRef(uer).
+    aNodeCrossRef(ancr).bNodeCrossRef(bncr).nodeCrossRef(ncr).
+    edgeCrossRef(ecr).uEdgeCrossRef(uecr).
+    node(tn, sn).edge(te, se).uEdge(tue, sue).run();
+
+  for (SmartBpUGraph::ANodeIt it(source); it != INVALID; ++it) {
+    check(nr[it] == anr[it], "Wrong copy.");
+    check(ancr[anr[it]] == it, "Wrong copy.");
+    check(sanm[it] == tanm[anr[it]], "Wrong copy.");
+  }
+
+  for (SmartBpUGraph::BNodeIt it(source); it != INVALID; ++it) {
+    check(nr[it] == bnr[it], "Wrong copy.");
+    check(bncr[bnr[it]] == it, "Wrong copy.");
+    check(sbnm[it] == tbnm[bnr[it]], "Wrong copy.");
+  }
+
+  for (SmartBpUGraph::NodeIt it(source); it != INVALID; ++it) {
+    check(ncr[nr[it]] == it, "Wrong copy.");
+    check(snm[it] == tnm[nr[it]], "Wrong copy.");
+  }
+
+  for (SmartBpUGraph::EdgeIt it(source); it != INVALID; ++it) {
+    check(ecr[er[it]] == it, "Wrong copy.");
+    check(sem[it] == tem[er[it]], "Wrong copy.");
+    check(nr[source.source(it)] == 
+                 target.source(er[it]), "Wrong copy.");
+    check(nr[source.target(it)] == 
+                 target.target(er[it]), "Wrong copy.");
+  }
+
+  for (SmartBpUGraph::UEdgeIt it(source); it != INVALID; ++it) {
+    check(uecr[uer[it]] == it, "Wrong copy.");
+    check(suem[it] == tuem[uer[it]], "Wrong copy.");
+    check(nr[source.aNode(it)] == 
+                 target.aNode(uer[it]), "Wrong copy.");
+    check(nr[source.bNode(it)] == 
+                 target.bNode(uer[it]), "Wrong copy.");
+  }
+
+  for (ListBpUGraph::ANodeIt it(target); it != INVALID; ++it) {
+    check(ancr[it] == ncr[it], "Wrong copy.");
+    check(anr[ancr[it]] == it, "Wrong copy.");
+  }
+
+  for (ListBpUGraph::BNodeIt it(target); it != INVALID; ++it) {
+    check(bncr[it] == ncr[it], "Wrong copy.");
+    check(bnr[bncr[it]] == it, "Wrong copy.");
+  }
+
+  for (ListBpUGraph::NodeIt it(target); it != INVALID; ++it) {
+    check(nr[ncr[it]] == it, "Wrong copy.");
+  }
+
+  for (ListBpUGraph::EdgeIt it(target); it != INVALID; ++it) {
+    check(er[ecr[it]] == it, "Wrong copy.");
+  }
+  for (ListBpUGraph::UEdgeIt it(target); it != INVALID; ++it) {
+    check(uer[uecr[it]] == it, "Wrong copy.");
+  }
+  check(tn == nr[sn], "Wrong copy.");
+  check(te == er[se], "Wrong copy.");
+  check(tue == uer[sue], "Wrong copy.");
+}
+
+int main() {
+  graph_copy_test();
+  ugraph_copy_test();
+  bpugraph_copy_test();
+
+  return 0; 
+}
Index: test/graph_factory_test.cc
===================================================================
--- test/graph_factory_test.cc	(revision 2553)
+++ test/graph_factory_test.cc	(revision 2553)
@@ -0,0 +1,156 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<iostream>
+#include<lemon/smart_graph.h>
+#include<lemon/concepts/graph.h>
+#include<lemon/concepts/maps.h>
+#include<lemon/list_graph_base.h>
+#include<lemon/full_graph.h>
+
+#include"test_tools.h"
+#include"graph_test.h"
+
+/**
+\file
+This test makes consistency checks of list graph structures.
+
+G.addNode(), G.addEdge(), G.source(), G.target()
+
+\todo Checks for empty graphs and isolated points.
+conversion.
+*/
+
+using namespace lemon;
+
+template<class Graph> void bidirPetersen(Graph &G)
+{
+  typedef typename Graph::Edge Edge;
+  typedef typename Graph::EdgeIt EdgeIt;
+  
+  checkGraphEdgeList(G,15);
+  
+  std::vector<Edge> ee;
+  
+  for(EdgeIt e(G);e!=INVALID;++e) ee.push_back(e);
+
+  for(typename std::vector<Edge>::iterator p=ee.begin();p!=ee.end();p++)
+    G.addEdge(G.target(*p),G.source(*p));
+}
+
+template<class Graph> void checkPetersen(Graph &G)
+{
+  typedef typename Graph::Node Node;
+
+  typedef typename Graph::EdgeIt EdgeIt;
+  typedef typename Graph::NodeIt NodeIt;
+
+  checkGraphNodeList(G,10);
+  checkGraphEdgeList(G,30);
+
+  for(NodeIt n(G);n!=INVALID;++n) {
+    checkGraphInEdgeList(G,n,3);
+    checkGraphOutEdgeList(G,n,3);
+  }  
+}
+
+//Compile Graph
+template void lemon::concepts::checkCompileGraph<concepts::Graph>
+(concepts::Graph &);
+
+template
+void lemon::concepts::checkCompileGraph<concepts::Graph>
+(concepts::Graph &);
+
+template
+void lemon::concepts::checkCompileGraph<concepts::Graph>
+(concepts::Graph &);
+
+//Compile SmartGraph
+template
+void lemon::concepts::checkCompileGraph<SmartGraph>(SmartGraph &);
+template
+void lemon::concepts::checkCompileGraphFindEdge<SmartGraph>(SmartGraph &);
+
+//Compile SymSmartGraph
+//template void hugo::checkCompileGraph<SymSmartGraph>(SymSmartGraph &);
+//template void hugo::checkCompileGraphFindEdge<SymSmartGraph>(SymSmartGraph &);
+
+//Compile ListGraph
+template
+void lemon::concepts::checkCompileGraph<ListGraph>(ListGraph &);
+template
+void lemon::concepts::checkCompileGraph<ListGraph>(ListGraph &);
+template
+void lemon::concepts::checkCompileGraphFindEdge<ListGraph>(ListGraph &);
+
+
+//Compile SymListGraph
+//template void hugo::checkCompileGraph<SymListGraph>(SymListGraph &);
+//template void hugo::checkCompileGraph<SymListGraph>(SymListGraph &);
+//template void hugo::checkCompileGraphFindEdge<SymListGraph>(SymListGraph &);
+
+//Compile FullGraph
+template void lemon::concepts::checkCompileGraph<FullGraph>(FullGraph &);
+template
+void lemon::concepts::checkCompileGraphFindEdge<FullGraph>(FullGraph &);
+
+
+int main() 
+{
+  {
+    SmartGraph G;
+    addPetersen(G);
+    bidirPetersen(G);
+    checkPetersen(G);
+  }
+  {
+    ListGraph G;
+    addPetersen(G);
+    bidirPetersen(G);
+    checkPetersen(G);
+  }
+  {
+    //    SymSmartGraph G;
+    //    addPetersen(G);
+    //    checkPetersen(G);
+  }
+  {
+    //    SymListGraph G;
+    //    addPetersen(G);
+    //    checkPetersen(G);
+  }
+
+  ///\file
+  ///\todo map tests.
+  ///\todo copy constr tests.
+
+
+  // Some map tests.
+  // FIXME: These shouldn't be here.
+  using namespace concepts;
+  function_requires< ReadMapConcept< ReadMap<int,int> > >();
+  function_requires< WriteMapConcept< WriteMap<int,int> > >();
+  function_requires< ReadWriteMapConcept< ReadWriteMap<int,int> > >();
+  function_requires< ReferenceMapConcept< ReferenceMap<int,int> > >();
+
+
+  std::cout << __FILE__ ": All tests passed.\n";
+
+  return 0;
+}
Index: test/graph_test.cc
===================================================================
--- test/graph_test.cc	(revision 2553)
+++ test/graph_test.cc	(revision 2553)
@@ -0,0 +1,82 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <vector>
+
+#include <lemon/concepts/graph.h>
+#include <lemon/list_graph.h>
+#include <lemon/smart_graph.h>
+#include <lemon/full_graph.h>
+#include <lemon/hypercube_graph.h>
+
+#include "test_tools.h"
+#include "graph_test.h"
+#include "map_test.h"
+
+
+using namespace lemon;
+using namespace lemon::concepts;
+
+
+int main() {
+  { // checking graph components
+    checkConcept<BaseGraphComponent, BaseGraphComponent >();
+
+    checkConcept<IDableGraphComponent<>, 
+      IDableGraphComponent<> >();
+
+    checkConcept<IterableGraphComponent<>, 
+      IterableGraphComponent<> >();
+
+    checkConcept<MappableGraphComponent<>, 
+      MappableGraphComponent<> >();
+
+  }
+  { // checking skeleton graphs
+    checkConcept<Graph, Graph>();
+  }
+  { // checking list graph
+    checkConcept<Graph, ListGraph >();
+    checkConcept<AlterableGraphComponent<>, ListGraph>();
+    checkConcept<ExtendableGraphComponent<>, ListGraph>();
+    checkConcept<ClearableGraphComponent<>, ListGraph>();
+    checkConcept<ErasableGraphComponent<>, ListGraph>();
+
+    checkGraph<ListGraph>();
+    checkGraphNodeMap<ListGraph>();
+    checkGraphEdgeMap<ListGraph>();
+  }
+  { // checking smart graph
+    checkConcept<Graph, SmartGraph >();
+
+    checkGraph<SmartGraph>();
+    checkGraphNodeMap<SmartGraph>();
+    checkGraphEdgeMap<SmartGraph>();
+  }
+  { // checking full graph
+    checkConcept<Graph, FullGraph >();
+  }
+  { // checking full graph
+    checkConcept<Graph, HyperCubeGraph >();
+  }
+
+  std::cout << __FILE__ ": All tests passed.\n";
+
+  return 0;
+}
Index: test/graph_test.h
===================================================================
--- test/graph_test.h	(revision 2553)
+++ test/graph_test.h	(revision 2553)
@@ -0,0 +1,106 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_TEST_GRAPH_TEST_H
+#define LEMON_TEST_GRAPH_TEST_H
+
+#include <lemon/graph_utils.h>
+#include "test_tools.h"
+
+//! \ingroup misc
+//! \file
+//! \brief Some utility and test cases to test graph classes.
+namespace lemon {
+
+  template<class Graph> void checkGraphNodeList(Graph &G, int nn)
+  {
+    typename Graph::NodeIt n(G);
+    for(int i=0;i<nn;i++) {
+      check(n!=INVALID,"Wrong Node list linking.");
+      ++n;
+    }
+    check(n==INVALID,"Wrong Node list linking.");
+  }
+
+  template<class Graph>
+  void checkGraphEdgeList(Graph &G, int nn)
+  {
+    typedef typename Graph::EdgeIt EdgeIt;
+
+    EdgeIt e(G);
+    for(int i=0;i<nn;i++) {
+      check(e!=INVALID,"Wrong Edge list linking.");
+      ++e;
+    }
+    check(e==INVALID,"Wrong Edge list linking.");
+  }
+
+  template<class Graph> 
+  void checkGraphOutEdgeList(Graph &G, typename Graph::Node n, int nn)
+  {
+    typename Graph::OutEdgeIt e(G,n);
+    for(int i=0;i<nn;i++) {
+      check(e!=INVALID,"Wrong OutEdge list linking.");
+      check(n==G.source(e), "Wrong OutEdge list linking.");
+      ++e;
+    }
+    check(e==INVALID,"Wrong OutEdge list linking.");
+  }
+
+  template<class Graph> void 
+  checkGraphInEdgeList(Graph &G, typename Graph::Node n, int nn)
+  {
+    typename Graph::InEdgeIt e(G,n);
+    for(int i=0;i<nn;i++) {
+      check(e!=INVALID,"Wrong InEdge list linking.");
+      check(n==G.target(e), "Wrong InEdge list linking.");
+      ++e;
+    }
+    check(e==INVALID,"Wrong InEdge list linking.");
+  }
+
+  template <class Graph> 
+  void checkGraph() {
+    const int num = 5;
+    Graph G;
+    addPetersen(G, num);
+    bidirGraph(G);
+    checkBidirPetersen(G, num);
+  }
+
+  template <class Graph> 
+  void checkGraphIterators(const Graph& graph) {
+    typedef typename Graph::Node Node;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::EdgeIt EdgeIt;
+    typedef typename Graph::InEdgeIt InEdgeIt;
+    typedef typename Graph::OutEdgeIt OutEdgeIt;
+    typedef ConEdgeIt<Graph> ConEdgeIt;
+    
+    for (NodeIt it(graph); it != INVALID; ++it) {}
+  }
+
+  ///\file
+  ///\todo Check target(), source() as well;
+
+  
+} //namespace lemon
+
+
+#endif
Index: test/graph_utils_test.cc
===================================================================
--- test/graph_utils_test.cc	(revision 2553)
+++ test/graph_utils_test.cc	(revision 2553)
@@ -0,0 +1,135 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <vector>
+
+#include <lemon/graph_utils.h>
+
+#include <lemon/list_graph.h>
+#include <lemon/smart_graph.h>
+#include <lemon/full_graph.h>
+
+#include "test_tools.h"
+#include "graph_utils_test.h"
+
+
+using namespace lemon;
+
+template<class Graph>
+void checkSnapDeg() 
+{
+  Graph g;
+  typename Graph::Node n1=g.addNode();
+  typename Graph::Node n2=g.addNode();
+   
+  InDegMap<Graph> ind(g);
+ 
+  g.addEdge(n1,n2);
+  
+  typename Graph::Snapshot snap(g);
+  
+  OutDegMap<Graph> outd(g);
+  
+  check(ind[n1]==0 && ind[n2]==1, "Wrong InDegMap value.");
+  check(outd[n1]==1 && outd[n2]==0, "Wrong OutDegMap value.");
+
+  g.addEdge(n1,n2);
+  g.addEdge(n2,n1);
+ 
+  check(ind[n1]==1 && ind[n2]==2, "Wrong InDegMap value.");
+  check(outd[n1]==2 && outd[n2]==1, "Wrong OutDegMap value.");
+
+  snap.restore();
+
+  check(ind[n1]==0 && ind[n2]==1, "Wrong InDegMap value.");
+  check(outd[n1]==1 && outd[n2]==0, "Wrong OutDegMap value.");
+  
+}
+
+int main() {
+  ///\file
+  { // checking list graph
+    checkGraphCounters<ListGraph>();
+    checkFindEdge<ListGraph>();
+  }
+  { // checking smart graph
+    checkGraphCounters<SmartGraph>();
+    checkFindEdge<SmartGraph>();
+  }
+  {
+    int num = 5;
+    FullGraph fg(num);
+    check(countNodes(fg) == num, "FullGraph: wrong node number.");
+    check(countEdges(fg) == num*num, "FullGraph: wrong edge number.");
+    for (FullGraph::NodeIt src(fg); src != INVALID; ++src) {
+      for (FullGraph::NodeIt trg(fg); trg != INVALID; ++trg) {
+	ConEdgeIt<FullGraph> con(fg, src, trg);
+	check(con != INVALID, "There is no connecting edge.");
+	check(fg.source(con) == src, "Wrong source.");
+	check(fg.target(con) == trg, "Wrong target.");
+	check(++con == INVALID, "There is more connecting edge.");
+      }
+    }
+    AllEdgeLookUp<FullGraph> el(fg);
+    for (FullGraph::NodeIt src(fg); src != INVALID; ++src) {
+      for (FullGraph::NodeIt trg(fg); trg != INVALID; ++trg) {
+	FullGraph::Edge con = el(src, trg);
+	check(con != INVALID, "There is no connecting edge.");
+	check(fg.source(con) == src, "Wrong source.");
+	check(fg.target(con) == trg, "Wrong target.");
+	check(el(src,trg,con) == INVALID, "There is more connecting edge.");
+      }
+    }
+  }
+
+  //check In/OutDegMap (and Snapshot feature)
+
+  checkSnapDeg<ListGraph>();
+  checkSnapDeg<SmartGraph>();
+  
+  {
+    const int nodeNum = 10;
+    const int edgeNum = 100;
+    ListGraph graph;
+    InDegMap<ListGraph> inDeg(graph);
+    OutDegMap<ListGraph> outDeg(graph);
+    std::vector<ListGraph::Node> nodes(nodeNum);
+    for (int i = 0; i < nodeNum; ++i) {
+      nodes[i] = graph.addNode();
+    }
+    std::vector<ListGraph::Edge> edges(edgeNum);
+    for (int i = 0; i < edgeNum; ++i) {
+      edges[i] = 
+	graph.addEdge(nodes[rnd[nodeNum]], nodes[rnd[nodeNum]]);
+    }
+    for (int i = 0; i < nodeNum; ++i) {
+      check(inDeg[nodes[i]] == countInEdges(graph, nodes[i]), 
+	    "Wrong in degree map");
+    }
+    for (int i = 0; i < nodeNum; ++i) {
+      check(outDeg[nodes[i]] == countOutEdges(graph, nodes[i]), 
+	    "Wrong in degree map");
+    }
+  }
+
+  ///Everything is OK
+  std::cout << __FILE__ ": All tests passed.\n";
+
+  return 0;
+}
Index: test/graph_utils_test.h
===================================================================
--- test/graph_utils_test.h	(revision 2553)
+++ test/graph_utils_test.h	(revision 2553)
@@ -0,0 +1,83 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_TEST_GRAPH_UTILS_TEST_H
+#define LEMON_TEST_GRAPH_UTILS_TEST_H
+
+
+#include "test_tools.h"
+#include <cstdlib>
+#include <ctime>
+
+//! \ingroup misc
+//! \file
+//! \brief Test cases for graph utils.
+namespace lemon {
+  
+  template <typename Graph>
+  void checkGraphCounters() {
+    const int num = 5;
+    Graph graph;
+    addPetersen(graph, num);
+    bidirGraph(graph);
+    check(countNodes(graph) == 2*num, "Wrong node number.");
+    check(countEdges(graph) == 6*num, "Wrong edge number.");    
+    for (typename Graph::NodeIt it(graph); it != INVALID; ++it) {
+      check(countOutEdges(graph, it) == 3, "Wrong out degree number.");
+      check(countInEdges(graph, it) == 3, "Wrong in degree number.");
+    }
+  }
+
+  template <typename Graph>
+  void checkFindEdge() {
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    typedef typename Graph::NodeIt NodeIt;
+    typedef typename Graph::EdgeIt EdgeIt;
+    Graph graph;
+    for (int i = 0; i < 10; ++i) {
+      graph.addNode();
+    }
+    DescriptorMap<Graph, Node> nodes(graph);
+    typename DescriptorMap<Graph, Node>::InverseMap invNodes(nodes);
+    for (int i = 0; i < 100; ++i) {
+      int src = rnd[invNodes.size()];
+      int trg = rnd[invNodes.size()];
+      graph.addEdge(invNodes[src], invNodes[trg]);
+    }
+    typename Graph::template EdgeMap<bool> found(graph, false);
+    DescriptorMap<Graph, Edge> edges(graph);
+    for (NodeIt src(graph); src != INVALID; ++src) {
+      for (NodeIt trg(graph); trg != INVALID; ++trg) {
+	for (ConEdgeIt<Graph> con(graph, src, trg); con != INVALID; ++con) {
+	  check(graph.source(con) == src, "Wrong source.");
+	  check(graph.target(con) == trg, "Wrong target.");
+	  check(found[con] == false, "The edge found already.");
+	  found[con] = true;
+	}
+      }
+    }
+    for (EdgeIt it(graph); it != INVALID; ++it) {
+      check(found[it] == true, "The edge is not found.");
+    }
+  }
+  
+} //namespace lemon
+
+
+#endif
Index: test/heap_test.cc
===================================================================
--- test/heap_test.cc	(revision 2565)
+++ test/heap_test.cc	(revision 2565)
@@ -0,0 +1,140 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <fstream>
+#include <string>
+#include <vector>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/heap.h>
+
+#include <lemon/smart_graph.h>
+
+#include <lemon/graph_reader.h>
+
+#include <lemon/bin_heap.h>
+#include <lemon/fib_heap.h>
+#include <lemon/radix_heap.h>
+#include <lemon/bucket_heap.h>
+
+#include "test_tools.h"
+
+#include "heap_test.h"
+
+#include <lemon/time_measure.h>
+
+using namespace lemon;
+using namespace lemon::concepts;
+
+
+int main() {
+
+  typedef int Item;
+  typedef int Prio;
+  typedef IntIntMap ItemIntMap;
+
+  typedef ListGraph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeMap<int> LengthMap;
+
+  Graph graph;
+  LengthMap length(graph);
+  Node start;
+
+  /// \todo create own test graph
+
+  std::string f_name;
+  if( getenv("srcdir") )
+    f_name = std::string(getenv("srcdir"));
+  else f_name = ".";
+  f_name += "/test/dijkstra_test.lgf";
+  
+  std::ifstream input(f_name.c_str());
+  check(input, "Input file '" << f_name << "' not found.");
+  GraphReader<Graph>(input, graph).
+    readEdgeMap("capacity", length).
+    readNode("source", start).
+    run();  
+ 
+  {
+    std::cout << "Checking Bin Heap" << std::endl;
+
+    typedef BinHeap<Prio, ItemIntMap> IntHeap;
+    checkConcept<Heap<Prio, ItemIntMap>, IntHeap>();
+    heapSortTest<IntHeap>(100);
+    heapIncreaseTest<IntHeap>(100);
+    
+    typedef BinHeap<Prio, Graph::NodeMap<int> > NodeHeap;
+    checkConcept<Heap<Prio, Graph::NodeMap<int> >, NodeHeap>();
+    Timer timer;
+    dijkstraHeapTest<Graph, LengthMap, NodeHeap>(graph, length, start);
+    std::cout << timer << std::endl;
+  }
+  {
+    std::cout << "Checking Fib Heap" << std::endl;
+
+    typedef FibHeap<Prio, ItemIntMap> IntHeap;
+    checkConcept<Heap<Prio, ItemIntMap>, IntHeap>();
+    heapSortTest<IntHeap>(100);
+    heapIncreaseTest<IntHeap>(100);
+
+    typedef FibHeap<Prio, Graph::NodeMap<int> > NodeHeap;
+    checkConcept<Heap<Prio, Graph::NodeMap<int> >, NodeHeap>();
+    Timer timer;
+    dijkstraHeapTest<Graph, LengthMap, NodeHeap>(graph, length, start);
+    std::cout << timer << std::endl;
+  }
+  {
+    std::cout << "Checking Radix Heap" << std::endl;
+
+    typedef RadixHeap<ItemIntMap> IntHeap;
+    checkConcept<Heap<Prio, ItemIntMap>, IntHeap>();
+    heapSortTest<IntHeap>(100);
+    heapIncreaseTest<IntHeap>(100);
+
+    typedef RadixHeap<Graph::NodeMap<int> > NodeHeap;
+    checkConcept<Heap<Prio, Graph::NodeMap<int> >, NodeHeap>();
+    Timer timer;
+    dijkstraHeapTest<Graph, LengthMap, NodeHeap>(graph, length, start);
+    std::cout << timer << std::endl;
+  }
+
+  {
+    std::cout << "Checking Bucket Heap" << std::endl;
+
+    typedef BucketHeap<ItemIntMap> IntHeap;
+    checkConcept<Heap<Prio, ItemIntMap>, IntHeap>();
+    heapSortTest<IntHeap>(100);
+    heapIncreaseTest<IntHeap>(100);
+
+    typedef BucketHeap<Graph::NodeMap<int> > NodeHeap;
+    checkConcept<Heap<Prio, Graph::NodeMap<int> >, NodeHeap>();
+    Timer timer;
+    dijkstraHeapTest<Graph, LengthMap, NodeHeap>(graph, length, start);
+    std::cout << timer << std::endl;
+  }
+
+  std::cout << __FILE__ ": All tests passed.\n";
+
+  return 0;
+}
Index: test/heap_test.h
===================================================================
--- test/heap_test.h	(revision 2553)
+++ test/heap_test.h	(revision 2553)
@@ -0,0 +1,123 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <vector>
+#include <algorithm>
+
+#include <lemon/dijkstra.h>
+
+class IntIntMap : public std::vector<int> {
+public:
+  typedef std::vector<int> Parent;
+
+  typedef int Key;
+  typedef int Value;
+
+  IntIntMap() : Parent() {}
+  IntIntMap(int n) : Parent(n) {}
+  IntIntMap(int n, int v) : Parent(n, v) {}
+
+  void set(int key, int value) {
+    Parent::operator[](key) = value;
+  }
+};
+
+
+template <typename _Heap>
+void heapSortTest(int n) {
+  typedef _Heap Heap;
+  IntIntMap map(n, -1);
+
+  Heap heap(map);
+  
+  std::vector<int> v(n);
+
+  for (int i = 0; i < n; ++i) {
+    v[i] = rnd[1000];
+    heap.push(i, v[i]);
+  }
+  std::sort(v.begin(), v.end());
+  for (int i = 0; i < n; ++i) {
+    check(v[i] == heap.prio() ,"Wrong order in heap sort.");
+    heap.pop();
+  }
+}
+
+template <typename _Heap>
+void heapIncreaseTest(int n) {
+  typedef _Heap Heap;
+  IntIntMap map(n, -1);
+
+  Heap heap(map);
+  
+  std::vector<int> v(n);
+
+  for (int i = 0; i < n; ++i) {
+    v[i] = rnd[1000];
+    heap.push(i, v[i]);
+  }
+  for (int i = 0; i < n; ++i) {
+    v[i] += rnd[1000];
+    heap.increase(i, v[i]);
+  }
+  std::sort(v.begin(), v.end());
+  for (int i = 0; i < n; ++i) {
+    check(v[i] == heap.prio() ,"Wrong order in heap increase test.");
+    heap.pop();
+  }
+}
+
+
+
+template <typename _Graph, typename _LengthMap, typename _Heap>
+void dijkstraHeapTest(_Graph& graph, _LengthMap& length,
+		      typename _Graph::Node& start) {
+
+  typedef _Heap Heap;
+  typedef _Graph Graph;
+  typedef _LengthMap LengthMap;
+
+  typedef typename Graph::Node Node;
+  typedef typename Graph::Edge Edge;
+  typedef typename Graph::NodeIt NodeIt;
+  typedef typename Graph::EdgeIt EdgeIt;
+
+  typename Dijkstra<Graph, LengthMap>::template DefStandardHeap<Heap>::
+    Create dijkstra(graph, length);
+
+  dijkstra.run(start);
+
+  for(EdgeIt e(graph); e!=INVALID; ++e) {
+    Node u=graph.source(e); 
+    Node v=graph.target(e);
+    if (dijkstra.reached(u)) {
+      check( dijkstra.dist(v) - dijkstra.dist(u) <= length[e],
+      	     "Error in a shortest path tree edge!");
+    }
+  }
+
+  for(NodeIt v(graph); v!=INVALID; ++v) {
+    if ( dijkstra.reached(v) && dijkstra.predEdge(v) != INVALID ) {
+      Edge e=dijkstra.predEdge(v);
+      Node u=graph.source(e);
+      check( dijkstra.dist(v) - dijkstra .dist(u) == length[e],
+	     "Error in a shortest path tree edge!");
+    }
+  }
+
+}
Index: test/kruskal_test.cc
===================================================================
--- test/kruskal_test.cc	(revision 2553)
+++ test/kruskal_test.cc	(revision 2553)
@@ -0,0 +1,180 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <vector>
+
+#include "test_tools.h"
+#include <lemon/maps.h>
+#include <lemon/kruskal.h>
+#include <lemon/list_graph.h>
+
+#include <lemon/concepts/maps.h>
+#include <lemon/concepts/graph.h>
+#include <lemon/concepts/ugraph.h>
+
+
+using namespace std;
+using namespace lemon;
+
+void checkCompileKruskal()
+{
+  concepts::WriteMap<concepts::Graph::Edge,bool> w;
+  concepts::WriteMap<concepts::UGraph::UEdge,bool> uw;
+
+  concepts::ReadMap<concepts::Graph::Edge,int> r;
+  concepts::ReadMap<concepts::UGraph::UEdge,int> ur;
+
+  concepts::Graph g;
+  concepts::UGraph ug;
+
+  kruskal(g, r, w);
+  kruskal(ug, ur, uw);
+
+  std::vector<std::pair<concepts::Graph::Edge, int> > rs;
+  std::vector<std::pair<concepts::UGraph::UEdge, int> > urs;
+
+  kruskal(g, rs, w);
+  kruskal(ug, urs, uw);
+
+  std::vector<concepts::Graph::Edge> ws;
+  std::vector<concepts::UGraph::UEdge> uws;
+
+  kruskal(g, r, ws.begin());
+  kruskal(ug, ur, uws.begin());
+
+  Kruskal<concepts::UGraph,concepts::ReadMap<concepts::UGraph::UEdge,int> >
+    alg(ug, ur);
+
+  alg.init();
+  alg.initPresorted(uws.begin(), uws.end());
+  alg.reinit();
+  
+  alg.emptyQueue();
+  
+  alg.nextEdge();
+  alg.processNextEdge();
+  alg.processEdge(concepts::UGraph::UEdge());
+
+  alg.run();
+  
+  alg.treeMap();
+  alg.tree(concepts::UGraph::UEdge());
+}
+
+int main() {
+
+  typedef ListUGraph::Node Node;
+  typedef ListUGraph::UEdge UEdge;
+  typedef ListUGraph::NodeIt NodeIt;
+  typedef ListUGraph::EdgeIt EdgeIt;
+
+  ListUGraph G;
+
+  Node s=G.addNode();
+  Node v1=G.addNode();
+  Node v2=G.addNode();
+  Node v3=G.addNode();
+  Node v4=G.addNode();
+  Node t=G.addNode();
+  
+  UEdge e1 = G.addEdge(s, v1);
+  UEdge e2 = G.addEdge(s, v2);
+  UEdge e3 = G.addEdge(v1, v2);
+  UEdge e4 = G.addEdge(v2, v1);
+  UEdge e5 = G.addEdge(v1, v3);
+  UEdge e6 = G.addEdge(v3, v2);
+  UEdge e7 = G.addEdge(v2, v4);
+  UEdge e8 = G.addEdge(v4, v3);
+  UEdge e9 = G.addEdge(v3, t);
+  UEdge e10 = G.addEdge(v4, t);
+
+  typedef ListUGraph::UEdgeMap<int> ECostMap;
+  typedef ListUGraph::UEdgeMap<bool> EBoolMap;
+
+  ECostMap edge_cost_map(G, 2);
+  EBoolMap tree_map(G);
+  
+
+  //Test with const map.
+  check(kruskal(G, ConstMap<ListUGraph::UEdge,int>(2), tree_map)==10,
+	"Total cost should be 10");
+  //Test with a edge map (filled with uniform costs).
+  check(kruskal(G, edge_cost_map, tree_map)==10,
+	"Total cost should be 10");
+
+  edge_cost_map.set(e1, -10);
+  edge_cost_map.set(e2, -9);
+  edge_cost_map.set(e3, -8);
+  edge_cost_map.set(e4, -7);
+  edge_cost_map.set(e5, -6);
+  edge_cost_map.set(e6, -5);
+  edge_cost_map.set(e7, -4);
+  edge_cost_map.set(e8, -3);
+  edge_cost_map.set(e9, -2);
+  edge_cost_map.set(e10, -1);
+
+  vector<UEdge> tree_edge_vec(5);
+
+  //Test with a edge map and inserter.
+  check(kruskal(G, edge_cost_map,
+		 tree_edge_vec.begin())
+	==-31,
+	"Total cost should be -31.");
+  
+  tree_edge_vec.clear();
+
+  check(kruskal(G, edge_cost_map,
+		back_inserter(tree_edge_vec))
+	==-31,
+	"Total cost should be -31.");
+  
+//   tree_edge_vec.clear();
+  
+//   //The above test could also be coded like this:
+//   check(kruskal(G,
+// 		makeKruskalMapInput(G, edge_cost_map),
+// 		makeKruskalSequenceOutput(back_inserter(tree_edge_vec)))
+// 	==-31,
+// 	"Total cost should be -31.");
+
+  check(tree_edge_vec.size()==5,"The tree should have 5 edges.");
+
+  check(tree_edge_vec[0]==e1 &&
+	tree_edge_vec[1]==e2 &&
+	tree_edge_vec[2]==e5 &&
+	tree_edge_vec[3]==e7 &&
+	tree_edge_vec[4]==e9,
+	"Wrong tree.");
+
+  Kruskal<ListUGraph, ECostMap> ka(G, edge_cost_map);
+  
+  ka.run();
+  
+  check(ka.tree(e1) && 
+        ka.tree(e2) &&
+        ka.tree(e5) &&
+        ka.tree(e7) &&
+        ka.tree(e9),
+        "Wrong tree.");
+
+  check(ka.treeValue() == -31,
+	"Total cost should be -31.");
+
+  return 0;
+}
Index: test/lp_test.cc
===================================================================
--- test/lp_test.cc	(revision 2637)
+++ test/lp_test.cc	(revision 2637)
@@ -0,0 +1,421 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <sstream>
+#include <lemon/lp_skeleton.h>
+#include "test_tools.h"
+#include <lemon/tolerance.h>
+#include <lemon/lp_utils.h>
+
+#ifdef HAVE_CONFIG_H
+#include <lemon/config.h>
+#endif
+
+#ifdef HAVE_GLPK
+#include <lemon/lp_glpk.h>
+#endif
+
+#ifdef HAVE_CPLEX
+#include <lemon/lp_cplex.h>
+#endif
+
+#ifdef HAVE_SOPLEX
+#include <lemon/lp_soplex.h>
+#endif
+
+using namespace lemon;
+
+void lpTest(LpSolverBase & lp)
+{
+
+
+
+  typedef LpSolverBase LP;
+
+  std::vector<LP::Col> x(10);
+  //  for(int i=0;i<10;i++) x.push_back(lp.addCol());
+  lp.addColSet(x);
+  lp.colLowerBound(x,1);
+  lp.colUpperBound(x,1);
+  lp.colBounds(x,1,2);
+#ifndef GYORSITAS
+
+  std::vector<LP::Col> y(10);
+  lp.addColSet(y);
+
+  lp.colLowerBound(y,1);
+  lp.colUpperBound(y,1);
+  lp.colBounds(y,1,2);
+
+  std::map<int,LP::Col> z;
+  
+  z.insert(std::make_pair(12,INVALID));
+  z.insert(std::make_pair(2,INVALID));
+  z.insert(std::make_pair(7,INVALID));
+  z.insert(std::make_pair(5,INVALID));
+
+  lp.addColSet(z);
+
+  lp.colLowerBound(z,1);
+  lp.colUpperBound(z,1);
+  lp.colBounds(z,1,2);
+
+  {
+    LP::Expr e,f,g;
+    LP::Col p1,p2,p3,p4,p5;
+    LP::Constr c;
+    
+    p1=lp.addCol();
+    p2=lp.addCol();
+    p3=lp.addCol();
+    p4=lp.addCol();
+    p5=lp.addCol();
+    
+    e[p1]=2;
+    e.constComp()=12;
+    e[p1]+=2;
+    e.constComp()+=12;
+    e[p1]-=2;
+    e.constComp()-=12;
+    
+    e=2;
+    e=2.2;
+    e=p1;
+    e=f;
+    
+    e+=2;
+    e+=2.2;
+    e+=p1;
+    e+=f;
+    
+    e-=2;
+    e-=2.2;
+    e-=p1;
+    e-=f;
+    
+    e*=2;
+    e*=2.2;
+    e/=2;
+    e/=2.2;
+    
+    e=((p1+p2)+(p1-p2)+(p1+12)+(12+p1)+(p1-12)+(12-p1)+
+       (f+12)+(12+f)+(p1+f)+(f+p1)+(f+g)+
+       (f-12)+(12-f)+(p1-f)+(f-p1)+(f-g)+
+       2.2*f+f*2.2+f/2.2+
+       2*f+f*2+f/2+
+       2.2*p1+p1*2.2+p1/2.2+
+       2*p1+p1*2+p1/2
+       );
+
+
+    c = (e  <= f  );
+    c = (e  <= 2.2);
+    c = (e  <= 2  );
+    c = (e  <= p1 );
+    c = (2.2<= f  );
+    c = (2  <= f  );
+    c = (p1 <= f  );
+    c = (p1 <= p2 );
+    c = (p1 <= 2.2);
+    c = (p1 <= 2  );
+    c = (2.2<= p2 );
+    c = (2  <= p2 );
+    
+    c = (e  >= f  );
+    c = (e  >= 2.2);
+    c = (e  >= 2  );
+    c = (e  >= p1 );
+    c = (2.2>= f  );
+    c = (2  >= f  );
+    c = (p1 >= f  );
+    c = (p1 >= p2 );
+    c = (p1 >= 2.2);
+    c = (p1 >= 2  );
+    c = (2.2>= p2 );
+    c = (2  >= p2 );
+    
+    c = (e  == f  );
+    c = (e  == 2.2);
+    c = (e  == 2  );
+    c = (e  == p1 );
+    c = (2.2== f  );
+    c = (2  == f  );
+    c = (p1 == f  );
+    //c = (p1 == p2 );
+    c = (p1 == 2.2);
+    c = (p1 == 2  );
+    c = (2.2== p2 );
+    c = (2  == p2 );
+    
+    c = (2 <= e <= 3);
+    c = (2 <= p1<= 3);
+    
+    c = (2 >= e >= 3);
+    c = (2 >= p1>= 3);
+    
+    e[x[3]]=2;
+    e[x[3]]=4;
+    e[x[3]]=1;
+    e.constComp()=12;
+    
+    lp.addRow(LP::INF,e,23);
+    lp.addRow(LP::INF,3.0*(x[1]+x[2]/2)-x[3],23);
+    lp.addRow(LP::INF,3.0*(x[1]+x[2]*2-5*x[3]+12-x[4]/3)+2*x[4]-4,23);
+    
+    lp.addRow(x[1]+x[3]<=x[5]-3);
+    lp.addRow(-7<=x[1]+x[3]-12<=3);
+    lp.addRow(x[1]<=x[5]);
+
+    std::ostringstream buf;
+
+
+    //Checking the simplify function
+
+//     //How to check the simplify function? A map gives no information
+//     //on the question whether a given key is or is not stored in it, or
+//     //it does?
+//   Yes, it does, using the find() function.
+    e=((p1+p2)+(p1-p2));
+    e.simplify();
+    buf << "Coeff. of p2 should be 0";
+    //    std::cout<<e[p1]<<e[p2]<<e[p3]<<std::endl;
+    check(e.find(p2)==e.end(), buf.str());
+    
+     
+
+
+    e=((p1+p2)+(p1-0.99*p2));
+    //e.prettyPrint(std::cout);
+    //(e<=2).prettyPrint(std::cout);
+    double tolerance=0.001;
+    e.simplify(tolerance);
+    buf << "Coeff. of p2 should be 0.01";
+    check(e[p2]>0, buf.str());
+    
+    tolerance=0.02;
+    e.simplify(tolerance);
+    buf << "Coeff. of p2 should be 0";
+    check(e.find(p2)==e.end(), buf.str());
+    
+
+  }
+  
+  {
+    LP::DualExpr e,f,g;
+    LP::Row p1 = INVALID, p2 = INVALID, p3 = INVALID, 
+      p4 = INVALID, p5 = INVALID;
+    
+    e[p1]=2;
+    e[p1]+=2;
+    e[p1]-=2;
+    
+    e=p1;
+    e=f;
+    
+    e+=p1;
+    e+=f;
+    
+    e-=p1;
+    e-=f;
+    
+    e*=2;
+    e*=2.2;
+    e/=2;
+    e/=2.2;
+    
+    e=((p1+p2)+(p1-p2)+
+       (p1+f)+(f+p1)+(f+g)+
+       (p1-f)+(f-p1)+(f-g)+
+       2.2*f+f*2.2+f/2.2+
+       2*f+f*2+f/2+
+       2.2*p1+p1*2.2+p1/2.2+
+       2*p1+p1*2+p1/2
+       );
+  }
+  
+#endif
+}
+
+void solveAndCheck(LpSolverBase& lp, LpSolverBase::SolutionStatus stat, 
+		   double exp_opt) {
+  using std::string;
+  lp.solve();
+  //int decimal,sign;
+  std::ostringstream buf;
+  buf << "Primalstatus should be: " << int(stat);
+
+  //  itoa(stat,buf1, 10);
+  check(lp.primalStatus()==stat, buf.str());
+
+  if (stat ==  LpSolverBase::OPTIMAL) {
+    std::ostringstream sbuf;
+    sbuf << "Wrong optimal value: the right optimum is " << exp_opt; 
+    check(std::abs(lp.primalValue()-exp_opt) < 1e-3, sbuf.str());
+    //+ecvt(exp_opt,2)
+  }
+}
+ 
+void aTest(LpSolverBase & lp)
+{
+  typedef LpSolverBase LP;
+
+ //The following example is very simple
+
+  typedef LpSolverBase::Row Row;
+  typedef LpSolverBase::Col Col;
+
+
+  Col x1 = lp.addCol();
+  Col x2 = lp.addCol();
+
+
+  //Constraints
+  Row upright=lp.addRow(x1+x2 <=1);  
+  lp.addRow(x1+x2 >=-1);  
+  lp.addRow(x1-x2 <=1);  
+  lp.addRow(x1-x2 >=-1);  
+  //Nonnegativity of the variables
+  lp.colLowerBound(x1, 0);
+  lp.colLowerBound(x2, 0);
+  //Objective function
+  lp.obj(x1+x2);
+
+  lp.max();
+
+  //Testing the problem retrieving routines
+  check(lp.objCoeff(x1)==1,"First term should be 1 in the obj function!");
+  check(lp.isMax(),"This is a maximization!");
+  check(lp.coeff(upright,x1)==1,"The coefficient in question is 1!");
+  //  std::cout<<lp.colLowerBound(x1)<<std::endl;
+  check(  lp.colLowerBound(x1)==0,"The lower bound for variable x1 should be 0.");
+  check(  lp.colUpperBound(x1)==LpSolverBase::INF,"The upper bound for variable x1 should be infty.");
+  LpSolverBase::Value lb,ub;
+  lp.getRowBounds(upright,lb,ub);
+  check(  lb==-LpSolverBase::INF,"The lower bound for the first row should be -infty.");
+  check(  ub==1,"The upper bound for the first row should be 1.");
+  LpSolverBase::Expr e = lp.row(upright);
+  check(  e.size() == 2, "The row retrieval gives back wrong expression.");
+  check(  e[x1] == 1, "The first coefficient should 1.");
+  check(  e[x2] == 1, "The second coefficient should 1.");
+
+  LpSolverBase::DualExpr de = lp.col(x1);
+  check(  de.size() == 4, "The col retrieval gives back wrong expression.");
+  check(  de[upright] == 1, "The first coefficient should 1.");
+
+  LpSolverBase* clp = lp.copyLp();
+
+  //Testing the problem retrieving routines
+  check(clp->objCoeff(x1)==1,"First term should be 1 in the obj function!");
+  check(clp->isMax(),"This is a maximization!");
+  check(clp->coeff(upright,x1)==1,"The coefficient in question is 1!");
+  //  std::cout<<lp.colLowerBound(x1)<<std::endl;
+  check(  clp->colLowerBound(x1)==0,"The lower bound for variable x1 should be 0.");
+  // std::cout << clp->colUpperBound(x1) << std::endl;
+  check(  clp->colUpperBound(x1)==LpSolverBase::INF,"The upper bound for variable x1 should be infty.");
+
+  clp->getRowBounds(upright,lb,ub);
+  check(  lb==-LpSolverBase::INF,"The lower bound for the first row should be -infty.");
+  check(  ub==1,"The upper bound for the first row should be 1.");
+  e = clp->row(upright);
+  check(  e.size() == 2, "The row retrieval gives back wrong expression.");
+  check(  e[x1] == 1, "The first coefficient should 1.");
+  check(  e[x2] == 1, "The second coefficient should 1.");
+
+  de = clp->col(x1);
+  check(  de.size() == 4, "The col retrieval gives back wrong expression.");
+  check(  de[upright] == 1, "The first coefficient should 1.");
+  
+  delete clp;
+
+  //Maximization of x1+x2
+  //over the triangle with vertices (0,0) (0,1) (1,0)
+  double expected_opt=1;
+  solveAndCheck(lp, LpSolverBase::OPTIMAL, expected_opt);
+  
+  //Minimization
+  lp.min();
+  expected_opt=0;
+  solveAndCheck(lp, LpSolverBase::OPTIMAL, expected_opt);
+  
+  //Vertex (-1,0) instead of (0,0)
+  lp.colLowerBound(x1, -LpSolverBase::INF);
+  expected_opt=-1;
+  solveAndCheck(lp, LpSolverBase::OPTIMAL, expected_opt);
+
+/*
+  //Erase one constraint and return to maximization
+  lp.eraseRow(upright);
+  lp.max();
+  expected_opt=LpSolverBase::INF;
+  solveAndCheck(lp, LpSolverBase::INFINITE, expected_opt);
+*/
+
+  //Infeasibilty
+  lp.addRow(x1+x2 <=-2);  
+  lp.max();
+  solveAndCheck(lp, LpSolverBase::INFEASIBLE, expected_opt);
+
+  //Change problem and forget to solve
+  lp.min();
+  check(lp.primalStatus()==LpSolverBase::UNDEFINED,"Primalstatus should be UNDEFINED");
+
+
+//   lp.solve();
+//   if (lp.primalStatus()==LpSolverBase::OPTIMAL){
+//     std::cout<< "Z = "<<lp.primalValue()
+// 	     << " (error = " << lp.primalValue()-expected_opt
+// 	     << "); x1 = "<<lp.primal(x1)
+// 	     << "; x2 = "<<lp.primal(x2)
+// 	     <<std::endl;
+    
+//   }
+//   else{
+//     std::cout<<lp.primalStatus()<<std::endl;
+//     std::cout<<"Optimal solution not found!"<<std::endl;
+//   }
+
+ 
+
+}
+
+
+int main() 
+{
+  LpSkeleton lp_skel;
+  lpTest(lp_skel);
+
+#ifdef HAVE_GLPK
+  LpGlpk lp_glpk1,lp_glpk2;
+  lpTest(lp_glpk1);
+  aTest(lp_glpk2);
+#endif
+
+#ifdef HAVE_CPLEX
+  LpCplex lp_cplex1,lp_cplex2;
+  lpTest(lp_cplex1);
+  aTest(lp_cplex2);
+#endif
+
+#ifdef HAVE_SOPLEX
+  LpSoplex lp_soplex1,lp_soplex2;
+  lpTest(lp_soplex1);
+  aTest(lp_soplex2);
+#endif
+
+  return 0;
+}
Index: test/map_test.h
===================================================================
--- test/map_test.h	(revision 2553)
+++ test/map_test.h	(revision 2553)
@@ -0,0 +1,106 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_TEST_MAP_TEST_H
+#define LEMON_TEST_MAP_TEST_H
+
+
+#include <vector>
+
+#include "test_tools.h"
+
+
+//! \ingroup misc
+//! \file
+//! \brief Some utilities to test map classes.
+
+namespace lemon {
+
+
+  template <typename Graph>
+  void checkGraphNodeMap() {
+    Graph graph;
+    const int num = 16;
+    
+    typedef typename Graph::Node Node;
+
+    std::vector<Node> nodes;
+    for (int i = 0; i < num; ++i) {
+      nodes.push_back(graph.addNode());      
+    }
+    typedef typename Graph::template NodeMap<int> IntNodeMap;
+    IntNodeMap map(graph, 42);
+    for (int i = 0; i < int(nodes.size()); ++i) {
+      check(map[nodes[i]] == 42, "Wrong map constructor.");      
+    }
+    for (int i = 0; i < num; ++i) {
+      nodes.push_back(graph.addNode());
+      map[nodes.back()] = 23;
+    }
+    map = constMap<Node>(12);
+    for (int i = 0; i < int(nodes.size()); ++i) {
+      check(map[nodes[i]] == 12, "Wrong map constructor.");      
+    }    
+    graph.clear();
+    nodes.clear();
+  }
+
+  template <typename Graph>
+  void checkGraphEdgeMap() {
+    Graph graph;
+    const int num = 16;
+    
+    typedef typename Graph::Node Node;
+    typedef typename Graph::Edge Edge;
+    
+    std::vector<Node> nodes;
+    for (int i = 0; i < num; ++i) {
+      nodes.push_back(graph.addNode());
+    }
+    
+    std::vector<Edge> edges;
+    for (int i = 0; i < num; ++i) {
+      for (int j = 0; j < i; ++j) {
+	edges.push_back(graph.addEdge(nodes[i], nodes[j]));
+      }
+    }
+    
+    typedef typename Graph::template EdgeMap<int> IntEdgeMap;
+    IntEdgeMap map(graph, 42);
+    
+    for (int i = 0; i < int(edges.size()); ++i) {
+      check(map[edges[i]] == 42, "Wrong map constructor.");      
+    }
+    
+    for (int i = 0; i < num; ++i) {
+      for (int j = i + 1; j < num; ++j) {
+	edges.push_back(graph.addEdge(nodes[i], nodes[j]));
+	map[edges.back()] = 23;
+      }
+    }
+    map = constMap<Edge>(12);
+    for (int i = 0; i < int(edges.size()); ++i) {
+      check(map[edges[i]] == 12, "Wrong map constructor.");      
+    }    
+    graph.clear();
+    edges.clear();    
+  }
+
+}
+
+#endif
Index: test/maps_test.cc
===================================================================
--- test/maps_test.cc	(revision 2553)
+++ test/maps_test.cc	(revision 2553)
@@ -0,0 +1,108 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <deque>
+#include <set>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/maps.h>
+#include <lemon/maps.h>
+
+#include "test_tools.h"
+
+using namespace lemon;
+using namespace lemon::concepts;
+
+struct A {};
+inline bool operator<(A, A) { return true; }
+struct B {};
+
+class F {
+public:
+  typedef A argument_type;
+  typedef B result_type;
+
+  B operator()(const A &) const {return B();}
+};
+
+int func(A) {return 3;}
+
+int binc(int, B) {return 4;}
+
+typedef ReadMap<A,double> DoubleMap;
+typedef ReadWriteMap<A, double> WriteDoubleMap;
+
+typedef ReadMap<A,bool> BoolMap;
+typedef ReadWriteMap<A, bool> BoolWriteMap;
+
+int main()
+{ // checking graph components
+  
+  checkConcept<ReadMap<A,B>, ReadMap<A,B> >();
+  checkConcept<WriteMap<A,B>, WriteMap<A,B> >();
+  checkConcept<ReadWriteMap<A,B>, ReadWriteMap<A,B> >();
+  checkConcept<ReferenceMap<A,B,B&,const B&>, ReferenceMap<A,B,B&,const B&> >();
+
+  checkConcept<ReadMap<A,double>, AddMap<DoubleMap,DoubleMap> >();
+  checkConcept<ReadMap<A,double>, SubMap<DoubleMap,DoubleMap> >();
+  checkConcept<ReadMap<A,double>, MulMap<DoubleMap,DoubleMap> >();
+  checkConcept<ReadMap<A,double>, DivMap<DoubleMap,DoubleMap> >();
+  checkConcept<ReadMap<A,double>, NegMap<DoubleMap> >();
+  checkConcept<ReadWriteMap<A,double>, NegWriteMap<WriteDoubleMap> >();
+  checkConcept<ReadMap<A,double>, AbsMap<DoubleMap> >();
+  checkConcept<ReadMap<A,double>, ShiftMap<DoubleMap> >();
+  checkConcept<ReadWriteMap<A,double>, ShiftWriteMap<WriteDoubleMap> >();
+  checkConcept<ReadMap<A,double>, ScaleMap<DoubleMap> >();
+  checkConcept<ReadWriteMap<A,double>, ScaleWriteMap<WriteDoubleMap> >();
+  checkConcept<ReadMap<A,double>, ForkMap<DoubleMap, DoubleMap> >();
+  checkConcept<ReadWriteMap<A,double>, 
+    ForkWriteMap<WriteDoubleMap, WriteDoubleMap> >();
+  
+  checkConcept<ReadMap<B,double>, ComposeMap<DoubleMap,ReadMap<B,A> > >();
+
+  checkConcept<ReadMap<A,B>, FunctorMap<F, A, B> >();
+
+  checkConcept<ReadMap<A, bool>, NotMap<BoolMap> >();
+  checkConcept<ReadWriteMap<A, bool>, NotWriteMap<BoolWriteMap> >();
+
+  checkConcept<WriteMap<A, bool>, StoreBoolMap<A*> >();
+  checkConcept<WriteMap<A, bool>, BackInserterBoolMap<std::deque<A> > >();
+  checkConcept<WriteMap<A, bool>, FrontInserterBoolMap<std::deque<A> > >();
+  checkConcept<WriteMap<A, bool>, InserterBoolMap<std::set<A> > >();
+  checkConcept<WriteMap<A, bool>, FillBoolMap<WriteMap<A, B> > >();
+  checkConcept<WriteMap<A, bool>, SettingOrderBoolMap<WriteMap<A, int> > >();
+
+  int a;
+  
+  a=mapFunctor(constMap<A,int>(2))(A());
+  check(a==2,"Something is wrong with mapFunctor");
+
+  B b;
+  b=functorMap(F())[A()];
+
+  a=functorMap(&func)[A()];
+  check(a==3,"Something is wrong with functorMap");
+
+  a=combineMap(constMap<B, int, 1>(), identityMap<B>(), &binc)[B()];
+  check(a==4,"Something is wrong with combineMap");
+  
+
+  std::cout << __FILE__ ": All tests passed.\n";
+  
+  return 0;
+}
Index: test/matrix_maps_test.cc
===================================================================
--- test/matrix_maps_test.cc	(revision 2553)
+++ test/matrix_maps_test.cc	(revision 2553)
@@ -0,0 +1,220 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <vector>
+
+#include <lemon/concept_check.h>
+
+#include <lemon/concepts/matrix_maps.h>
+#include <lemon/concepts/maps.h>
+#include <lemon/concepts/graph.h>
+
+#include <lemon/matrix_maps.h>
+
+#include <lemon/smart_graph.h>
+
+#include "test_tools.h"
+#include "graph_test.h"
+#include "map_test.h"
+
+
+using namespace lemon;
+using namespace lemon::concepts;
+
+int main() {
+  typedef SmartGraph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::Edge Edge;
+
+  { // checking MatrixMap for int
+    typedef DynamicMatrixMap<Graph, Node, int> IntMatrixMap;
+    checkConcept<ReferenceMatrixMap<Node, Node, int, 
+      IntMatrixMap::Reference, IntMatrixMap::ConstReference>,
+      IntMatrixMap>();
+
+  }
+
+  { // checking MatrixMap for bool
+    typedef DynamicMatrixMap<Graph, Node, bool> BoolMatrixMap;
+    checkConcept<ReferenceMatrixMap<Node, Node, bool, 
+      BoolMatrixMap::Reference, BoolMatrixMap::ConstReference>,
+      BoolMatrixMap>();
+
+  }
+
+  {
+    Graph graph;
+    typedef DynamicMatrixMap<Graph, Node, int> IntMatrixMap;
+    IntMatrixMap matrix(graph);
+    for (int i = 0; i < 10; ++i) {
+      graph.addNode();
+    }
+    for (Graph::NodeIt it(graph); it != INVALID; ++it) {
+      for (Graph::NodeIt jt(graph); jt != INVALID; ++jt) {
+	int val = rnd[100];
+	matrix.set(it, jt, val);
+	check(matrix(it, jt) == val, "Wrong assign");
+	check(matrix(it, jt) == matrixRowMap(matrix, it)[jt], "Wrong rowMap");
+	check(matrix(it, jt) == matrixColMap(matrix, jt)[it], "Wrong colMap");
+      }
+    }
+    const IntMatrixMap& cm = matrix;
+    for (Graph::NodeIt it(graph); it != INVALID; ++it) {
+      for (Graph::NodeIt jt(graph); jt != INVALID; ++jt) {
+	check(cm(it, jt) == matrixRowMap(cm, it)[jt], "Wrong rowMap");
+	check(cm(it, jt) == matrixColMap(cm, jt)[it], "Wrong colMap");
+      }
+    }
+  }
+
+  { // checking MatrixMap for int
+    typedef DynamicSymMatrixMap<Graph, Node, int> IntMatrixMap;
+    checkConcept<ReferenceMatrixMap<Node, Node, int, 
+      IntMatrixMap::Reference, IntMatrixMap::ConstReference>,
+      IntMatrixMap>();
+
+  }
+
+  { // checking MatrixMap for bool
+    typedef DynamicSymMatrixMap<Graph, Node, bool> BoolMatrixMap;
+    checkConcept<ReferenceMatrixMap<Node, Node, bool, 
+      BoolMatrixMap::Reference, BoolMatrixMap::ConstReference>,
+      BoolMatrixMap>();
+
+  }
+
+  {
+    Graph graph;
+    typedef DynamicSymMatrixMap<Graph, Node, int> IntMatrixMap;
+    IntMatrixMap matrix(graph);
+    for (int i = 0; i < 10; ++i) {
+      graph.addNode();
+    }
+    for (Graph::NodeIt it(graph); it != INVALID; ++it) {
+      for (Graph::NodeIt jt(graph); jt != INVALID; ++jt) {
+	int val = rnd[100];
+	matrix.set(it, jt, val);
+	check(matrix(it, jt) == val, "Wrong assign");
+	check(matrix(jt, it) == val, "Wrong assign");
+	check(matrix(it, jt) == matrixRowMap(matrix, it)[jt], "Wrong rowMap");
+	check(matrix(it, jt) == matrixColMap(matrix, jt)[it], "Wrong colMap");
+      }
+    }
+    const IntMatrixMap& cm = matrix;
+    for (Graph::NodeIt it(graph); it != INVALID; ++it) {
+      for (Graph::NodeIt jt(graph); jt != INVALID; ++jt) {
+	check(cm(it, jt) == matrixRowMap(cm, it)[jt], "Wrong rowMap");
+	check(cm(it, jt) == matrixColMap(cm, jt)[it], "Wrong colMap");
+      }
+    }
+  }
+
+  { // checking MatrixMap for int
+    typedef DynamicAsymMatrixMap<Graph, Node, Graph, Edge, int> IntMatrixMap;
+    checkConcept<ReferenceMatrixMap<Node, Edge, int, 
+      IntMatrixMap::Reference, IntMatrixMap::ConstReference>,
+      IntMatrixMap>();
+
+  }
+
+  { // checking MatrixMap for bool
+    typedef DynamicAsymMatrixMap<Graph, Node, Graph, Edge, bool> BoolMatrixMap;
+    checkConcept<ReferenceMatrixMap<Node, Edge, bool, 
+      BoolMatrixMap::Reference, BoolMatrixMap::ConstReference>,
+      BoolMatrixMap>();
+
+  }
+
+  {
+    Graph graph1, graph2;
+    typedef DynamicAsymMatrixMap<Graph, Node, Graph, Edge, int> IntMatrixMap;
+    IntMatrixMap matrix(graph1, graph2);
+    for (int i = 0; i < 10; ++i) {
+      graph1.addNode();
+    }
+    graph2.addNode();
+    for (int i = 0; i < 20; ++i) {
+      graph2.addEdge(Graph::NodeIt(graph2), Graph::NodeIt(graph2));
+    }
+    for (Graph::NodeIt it(graph1); it != INVALID; ++it) {
+      for (Graph::EdgeIt jt(graph2); jt != INVALID; ++jt) {
+	int val = rnd[100];
+	matrix.set(it, jt, val);
+	check(matrix(it, jt) == val, "Wrong assign");
+	check(matrix(it, jt) == matrixRowMap(matrix, it)[jt], "Wrong rowMap");
+	check(matrix(it, jt) == matrixColMap(matrix, jt)[it], "Wrong colMap");
+      }
+    }
+    const IntMatrixMap& cm = matrix;
+    for (Graph::NodeIt it(graph1); it != INVALID; ++it) {
+      for (Graph::EdgeIt jt(graph2); jt != INVALID; ++jt) {
+	check(cm(it, jt) == matrixRowMap(cm, it)[jt], "Wrong rowMap");
+	check(cm(it, jt) == matrixColMap(cm, jt)[it], "Wrong colMap");
+      }
+    }
+  }
+
+  { // checking MatrixMap for int
+    typedef DynamicAsymMatrixMap<Graph, Node, Graph, Node, int> IntMatrixMap;
+    checkConcept<ReferenceMatrixMap<Node, Node, int, 
+      IntMatrixMap::Reference, IntMatrixMap::ConstReference>,
+      IntMatrixMap>();
+
+  }
+
+  { // checking MatrixMap for bool
+    typedef DynamicAsymMatrixMap<Graph, Node, Graph, Node, bool> BoolMatrixMap;
+    checkConcept<ReferenceMatrixMap<Node, Node, bool, 
+      BoolMatrixMap::Reference, BoolMatrixMap::ConstReference>,
+      BoolMatrixMap>();
+
+  }
+
+  {
+    Graph graph;
+    typedef DynamicAsymMatrixMap<Graph, Node, Graph, Node, int> IntMatrixMap;
+    IntMatrixMap matrix(graph, graph);
+    for (int i = 0; i < 10; ++i) {
+      graph.addNode();
+    }
+    for (int i = 0; i < 20; ++i) {
+      graph.addEdge(Graph::NodeIt(graph), Graph::NodeIt(graph));
+    }
+    for (Graph::NodeIt it(graph); it != INVALID; ++it) {
+      for (Graph::NodeIt jt(graph); jt != INVALID; ++jt) {
+	int val = rnd[100];
+	matrix.set(it, jt, val);
+	check(matrix(it, jt) == val, "Wrong assign");
+	check(matrix(it, jt) == matrixRowMap(matrix, it)[jt], "Wrong rowMap");
+	check(matrix(it, jt) == matrixColMap(matrix, jt)[it], "Wrong colMap");
+      }
+    }
+    const IntMatrixMap& cm = matrix;
+    for (Graph::NodeIt it(graph); it != INVALID; ++it) {
+      for (Graph::NodeIt jt(graph); jt != INVALID; ++jt) {
+	check(cm(it, jt) == matrixRowMap(cm, it)[jt], "Wrong rowMap");
+	check(cm(it, jt) == matrixColMap(cm, jt)[it], "Wrong colMap");
+      }
+    }
+  }
+
+  std::cout << __FILE__ ": All tests passed.\n";
+
+  return 0;
+}
Index: test/max_matching_test.cc
===================================================================
--- test/max_matching_test.cc	(revision 2569)
+++ test/max_matching_test.cc	(revision 2569)
@@ -0,0 +1,185 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <vector>
+#include <queue>
+#include <lemon/math.h>
+#include <cstdlib>
+
+#include "test_tools.h"
+#include <lemon/list_graph.h>
+#include <lemon/max_matching.h>
+
+using namespace std;
+using namespace lemon;
+
+int main() {
+
+  typedef ListUGraph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::UEdgeIt UEdgeIt;
+  typedef Graph::IncEdgeIt IncEdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::Node Node;
+   
+  Graph g;
+  g.clear();
+
+  std::vector<Graph::Node> nodes;
+  for (int i=0; i<13; ++i)
+      nodes.push_back(g.addNode());
+
+  g.addEdge(nodes[0], nodes[0]);
+  g.addEdge(nodes[6], nodes[10]);
+  g.addEdge(nodes[5], nodes[10]);
+  g.addEdge(nodes[4], nodes[10]);
+  g.addEdge(nodes[3], nodes[11]);  
+  g.addEdge(nodes[1], nodes[6]);
+  g.addEdge(nodes[4], nodes[7]);  
+  g.addEdge(nodes[1], nodes[8]);
+  g.addEdge(nodes[0], nodes[8]);
+  g.addEdge(nodes[3], nodes[12]);
+  g.addEdge(nodes[6], nodes[9]);
+  g.addEdge(nodes[9], nodes[11]);
+  g.addEdge(nodes[2], nodes[10]);
+  g.addEdge(nodes[10], nodes[8]);
+  g.addEdge(nodes[5], nodes[8]);
+  g.addEdge(nodes[6], nodes[3]);
+  g.addEdge(nodes[0], nodes[5]);
+  g.addEdge(nodes[6], nodes[12]);
+  
+  MaxMatching<Graph> max_matching(g);
+  max_matching.init();
+  max_matching.startDense();
+  
+  int s=0;
+  Graph::NodeMap<Node> mate(g,INVALID);
+  max_matching.mateMap(mate);
+  for(NodeIt v(g); v!=INVALID; ++v) {
+    if ( mate[v]!=INVALID ) ++s;
+  }
+  int size=int(s/2);  //size will be used as the size of a maxmatching
+
+  for(NodeIt v(g); v!=INVALID; ++v) {
+    max_matching.mate(v);
+  }
+
+  check ( size == max_matching.size(), "mate() returns a different size matching than max_matching.size()" );
+
+  Graph::NodeMap<MaxMatching<Graph>::DecompType> pos0(g);
+  max_matching.decomposition(pos0);
+  
+  max_matching.init();
+  max_matching.startSparse();
+  s=0;
+  max_matching.mateMap(mate);
+  for(NodeIt v(g); v!=INVALID; ++v) {
+    if ( mate[v]!=INVALID ) ++s;
+  }
+  check ( int(s/2) == size, "The size does not equal!" );
+
+  Graph::NodeMap<MaxMatching<Graph>::DecompType> pos1(g);
+  max_matching.decomposition(pos1);
+
+  max_matching.run();
+  s=0;
+  max_matching.mateMap(mate);
+  for(NodeIt v(g); v!=INVALID; ++v) {
+    if ( mate[v]!=INVALID ) ++s;
+  }
+  check ( int(s/2) == size, "The size does not equal!" ); 
+  
+  Graph::NodeMap<MaxMatching<Graph>::DecompType> pos2(g);
+  max_matching.decomposition(pos2);
+
+  max_matching.run();
+  s=0;
+  max_matching.mateMap(mate);
+  for(NodeIt v(g); v!=INVALID; ++v) {
+    if ( mate[v]!=INVALID ) ++s;
+  }
+  check ( int(s/2) == size, "The size does not equal!" ); 
+  
+  Graph::NodeMap<MaxMatching<Graph>::DecompType> pos(g);
+  max_matching.decomposition(pos);
+   
+  bool ismatching=true;
+  for(NodeIt v(g); v!=INVALID; ++v) {
+    if ( mate[v]!=INVALID ) {
+      Node u=mate[v];
+      if (mate[u]!=v) ismatching=false; 
+    }
+  }  
+  check ( ismatching, "It is not a matching!" );
+
+  bool coincide=true;
+  for(NodeIt v(g); v!=INVALID; ++v) {
+   if ( pos0[v] != pos1[v] || pos1[v]!=pos2[v] || pos2[v]!=pos[v] ) {
+     coincide=false;
+    }
+  }
+  check ( coincide, "The decompositions do not coincide! " );
+
+  bool noedge=true;
+  for(UEdgeIt e(g); e!=INVALID; ++e) {
+   if ( (pos[g.target(e)]==max_matching.C && 
+	 pos[g.source(e)]==max_matching.D) || 
+	 (pos[g.target(e)]==max_matching.D && 
+	  pos[g.source(e)]==max_matching.C) )
+      noedge=false; 
+  }
+  check ( noedge, "There are edges between D and C!" );
+  
+  bool oddcomp=true;
+  Graph::NodeMap<bool> todo(g,true);
+  int num_comp=0;
+  for(NodeIt v(g); v!=INVALID; ++v) {
+   if ( pos[v]==max_matching.D && todo[v] ) {
+      int comp_size=1;
+      ++num_comp;
+      std::queue<Node> Q;
+      Q.push(v);
+      todo.set(v,false);
+      while (!Q.empty()) {
+	Node w=Q.front();	
+	Q.pop();
+	for(IncEdgeIt e(g,w); e!=INVALID; ++e) {
+	  Node u=g.runningNode(e);
+	  if ( pos[u]==max_matching.D && todo[u] ) {
+	    ++comp_size;
+	    Q.push(u);
+	    todo.set(u,false);
+	  }
+	}
+      }
+      if ( !(comp_size % 2) ) oddcomp=false;  
+    }
+  }
+  check ( oddcomp, "A component of g[D] is not odd." );
+
+  int barrier=0;
+  for(NodeIt v(g); v!=INVALID; ++v) {
+    if ( pos[v]==max_matching.A ) ++barrier;
+  }
+  int expected_size=int( countNodes(g)-num_comp+barrier)/2;
+  check ( size==expected_size, "The size of the matching is wrong." );
+  
+  return 0;
+}
Index: test/max_weighted_matching_test.cc
===================================================================
--- test/max_weighted_matching_test.cc	(revision 2569)
+++ test/max_weighted_matching_test.cc	(revision 2569)
@@ -0,0 +1,253 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <sstream>
+#include <vector>
+#include <queue>
+#include <lemon/math.h>
+#include <cstdlib>
+
+#include "test_tools.h"
+#include <lemon/smart_graph.h>
+#include <lemon/max_matching.h>
+#include <lemon/graph_reader.h>
+
+UGRAPH_TYPEDEFS(SmartUGraph);
+
+using namespace std;
+using namespace lemon;
+
+const int lgfn = 3;
+const std::string lgf[lgfn] = {   
+  "@nodeset\n"
+  "label\n"
+  "0\n"
+  "1\n"
+  "2\n"
+  "3\n"
+  "4\n"
+  "5\n"
+  "6\n"
+  "7\n"
+  "@uedgeset\n"
+  "label        weight\n"
+  "7    4       0       984\n"
+  "0    7       1       73\n"
+  "7    1       2       204\n"
+  "2    3       3       583\n"
+  "2    7       4       565\n"
+  "2    1       5       582\n"
+  "0    4       6       551\n"
+  "2    5       7       385\n"
+  "1    5       8       561\n"
+  "5    3       9       484\n"
+  "7    5       10      904\n"
+  "3    6       11      47\n"
+  "7    6       12      888\n"
+  "3    0       13      747\n"
+  "6    1       14      310\n"
+  "@end\n",
+
+  "@nodeset\n"
+  "label\n"
+  "0\n"
+  "1\n"
+  "2\n"
+  "3\n"
+  "4\n"
+  "5\n"
+  "6\n"
+  "7\n"
+  "@uedgeset\n"
+  "label        weight\n"
+  "2    5       0       710\n"
+  "0    5       1       241\n"
+  "2    4       2       856\n"
+  "2    6       3       762\n"
+  "4    1       4       747\n"
+  "6    1       5       962\n"
+  "4    7       6       723\n"
+  "1    7       7       661\n"
+  "2    3       8       376\n"
+  "1    0       9       416\n"
+  "6    7       10      391\n"
+  "@end\n",
+
+  "@nodeset\n"
+  "label\n"
+  "0\n"
+  "1\n"
+  "2\n"
+  "3\n"
+  "4\n"
+  "5\n"
+  "6\n"
+  "7\n"
+  "@uedgeset\n"
+  "label        weight\n"
+  "6    2       0       553\n"
+  "0    7       1       653\n"
+  "6    3       2       22\n"
+  "4    7       3       846\n"
+  "7    2       4       981\n"
+  "7    6       5       250\n"
+  "5    2       6       539\n"
+  "@end\n"
+};
+
+void checkMatching(const SmartUGraph& ugraph,
+		   const SmartUGraph::UEdgeMap<int>& weight,
+		   const MaxWeightedMatching<SmartUGraph>& mwm) {
+  for (SmartUGraph::UEdgeIt e(ugraph); e != INVALID; ++e) {
+    if (ugraph.source(e) == ugraph.target(e)) continue;
+    int rw = 
+      mwm.nodeValue(ugraph.source(e)) + mwm.nodeValue(ugraph.target(e));
+
+    for (int i = 0; i < mwm.blossomNum(); ++i) {
+      bool s = false, t = false;
+      for (MaxWeightedMatching<SmartUGraph>::BlossomIt n(mwm, i); 
+	   n != INVALID; ++n) {
+	if (ugraph.source(e) == n) s = true;
+	if (ugraph.target(e) == n) t = true;
+      }
+      if (s == true && t == true) {
+	rw += mwm.blossomValue(i);
+      }
+    }
+    rw -= weight[e] * mwm.dualScale;
+
+    check(rw >= 0, "Negative reduced weight");
+    check(rw == 0 || !mwm.matching(e), 
+	  "Non-zero reduced weight on matching edge");
+  }
+
+  int pv = 0;
+  for (SmartUGraph::NodeIt n(ugraph); n != INVALID; ++n) {
+    if (mwm.matching(n) != INVALID) {
+      check(mwm.nodeValue(n) >= 0, "Invalid node value");
+      pv += weight[mwm.matching(n)];
+      SmartUGraph::Node o = ugraph.target(mwm.matching(n));
+      check(mwm.mate(n) == o, "Invalid matching");
+      check(mwm.matching(n) == ugraph.oppositeEdge(mwm.matching(o)), 
+	    "Invalid matching");
+    } else {
+      check(mwm.mate(n) == INVALID, "Invalid matching");
+      check(mwm.nodeValue(n) == 0, "Invalid matching");
+    }
+  }
+
+  int dv = 0;
+  for (SmartUGraph::NodeIt n(ugraph); n != INVALID; ++n) {
+    dv += mwm.nodeValue(n);
+  }
+
+  for (int i = 0; i < mwm.blossomNum(); ++i) {
+    check(mwm.blossomValue(i) >= 0, "Invalid blossom value");
+    check(mwm.blossomSize(i) % 2 == 1, "Even blossom size");
+    dv += mwm.blossomValue(i) * ((mwm.blossomSize(i) - 1) / 2);
+  }
+
+  check(pv * mwm.dualScale == dv * 2, "Wrong duality");
+
+  return;
+}
+
+void checkPerfectMatching(const SmartUGraph& ugraph,
+			  const SmartUGraph::UEdgeMap<int>& weight,
+			  const MaxWeightedPerfectMatching<SmartUGraph>& mwpm) {
+  for (SmartUGraph::UEdgeIt e(ugraph); e != INVALID; ++e) {
+    if (ugraph.source(e) == ugraph.target(e)) continue;
+    int rw = 
+      mwpm.nodeValue(ugraph.source(e)) + mwpm.nodeValue(ugraph.target(e));
+
+    for (int i = 0; i < mwpm.blossomNum(); ++i) {
+      bool s = false, t = false;
+      for (MaxWeightedPerfectMatching<SmartUGraph>::BlossomIt n(mwpm, i); 
+	   n != INVALID; ++n) {
+	if (ugraph.source(e) == n) s = true;
+	if (ugraph.target(e) == n) t = true;
+      }
+      if (s == true && t == true) {
+	rw += mwpm.blossomValue(i);
+      }
+    }
+    rw -= weight[e] * mwpm.dualScale;
+
+    check(rw >= 0, "Negative reduced weight");
+    check(rw == 0 || !mwpm.matching(e), 
+	  "Non-zero reduced weight on matching edge");
+  }
+
+  int pv = 0;
+  for (SmartUGraph::NodeIt n(ugraph); n != INVALID; ++n) {
+    check(mwpm.matching(n) != INVALID, "Non perfect");
+    pv += weight[mwpm.matching(n)];
+    SmartUGraph::Node o = ugraph.target(mwpm.matching(n));
+    check(mwpm.mate(n) == o, "Invalid matching");
+    check(mwpm.matching(n) == ugraph.oppositeEdge(mwpm.matching(o)), 
+	  "Invalid matching");
+  }
+
+  int dv = 0;
+  for (SmartUGraph::NodeIt n(ugraph); n != INVALID; ++n) {
+    dv += mwpm.nodeValue(n);
+  }
+
+  for (int i = 0; i < mwpm.blossomNum(); ++i) {
+    check(mwpm.blossomValue(i) >= 0, "Invalid blossom value");
+    check(mwpm.blossomSize(i) % 2 == 1, "Even blossom size");
+    dv += mwpm.blossomValue(i) * ((mwpm.blossomSize(i) - 1) / 2);
+  }
+
+  check(pv * mwpm.dualScale == dv * 2, "Wrong duality");
+
+  return;
+}
+
+
+int main() {
+
+  for (int i = 0; i < lgfn; ++i) {
+    SmartUGraph ugraph;
+    SmartUGraph::UEdgeMap<int> weight(ugraph);
+    
+    istringstream lgfs(lgf[i]);
+    UGraphReader<SmartUGraph>(lgfs, ugraph).
+      readUEdgeMap("weight", weight).run();
+
+    MaxWeightedMatching<SmartUGraph> mwm(ugraph, weight);
+    mwm.run();
+    checkMatching(ugraph, weight, mwm);
+
+    MaxMatching<SmartUGraph> mm(ugraph);
+    mm.run();
+
+    MaxWeightedPerfectMatching<SmartUGraph> mwpm(ugraph, weight);
+    bool perfect = mwpm.run();
+
+    check(perfect == (mm.size() * 2 == countNodes(ugraph)), 
+	  "Perfect matching found");
+
+    if (perfect) {
+      checkPerfectMatching(ugraph, weight, mwpm);
+    }
+  }
+  
+  return 0;
+}
Index: test/min_cost_flow_test.cc
===================================================================
--- test/min_cost_flow_test.cc	(revision 2621)
+++ test/min_cost_flow_test.cc	(revision 2621)
@@ -0,0 +1,329 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <fstream>
+
+#include <lemon/list_graph.h>
+#include <lemon/smart_graph.h>
+#include <lemon/graph_reader.h>
+#include <lemon/dimacs.h>
+#include <lemon/time_measure.h>
+
+#include <lemon/cycle_canceling.h>
+#include <lemon/capacity_scaling.h>
+#include <lemon/cost_scaling.h>
+#include <lemon/network_simplex.h>
+
+#include <lemon/min_cost_flow.h>
+#include <lemon/min_cost_max_flow.h>
+
+#include "test_tools.h"
+
+using namespace lemon;
+
+// Checks the feasibility of a flow
+template < typename Graph, typename LowerMap, typename CapacityMap,
+           typename SupplyMap, typename FlowMap >
+bool checkFlow( const Graph& gr,
+                const LowerMap& lower, const CapacityMap& upper,
+                const SupplyMap& supply, const FlowMap& flow )
+{
+  GRAPH_TYPEDEFS(typename Graph);
+  for (EdgeIt e(gr); e != INVALID; ++e)
+    if (flow[e] < lower[e] || flow[e] > upper[e]) return false;
+
+  for (NodeIt n(gr); n != INVALID; ++n) {
+    typename SupplyMap::Value sum = 0;
+    for (OutEdgeIt e(gr, n); e != INVALID; ++e)
+      sum += flow[e];
+    for (InEdgeIt e(gr, n); e != INVALID; ++e)
+      sum -= flow[e];
+    if (sum != supply[n]) return false;
+  }
+
+  return true;
+}
+
+// Checks the optimalitiy of a flow
+template < typename Graph, typename LowerMap, typename CapacityMap,
+           typename CostMap, typename FlowMap, typename PotentialMap >
+bool checkOptimality( const Graph& gr, const LowerMap& lower,
+                      const CapacityMap& upper, const CostMap& cost,
+                      const FlowMap& flow, const PotentialMap& pi )
+{
+  GRAPH_TYPEDEFS(typename Graph);
+  // Checking the Complementary Slackness optimality condition
+  bool opt = true;
+  for (EdgeIt e(gr); e != INVALID; ++e) {
+    typename CostMap::Value red_cost =
+      cost[e] + pi[gr.source(e)] - pi[gr.target(e)];
+    opt = red_cost == 0 ||
+          (red_cost > 0 && flow[e] == lower[e]) ||
+          (red_cost < 0 && flow[e] == upper[e]);
+    if (!opt) break;
+  }
+  return opt;
+}
+
+// Runs a minimum cost flow algorithm and checks the results
+template < typename MinCostFlowImpl, typename Graph,
+           typename LowerMap, typename CapacityMap,
+           typename CostMap, typename SupplyMap >
+void checkMcf( std::string test_id,
+               const MinCostFlowImpl& mcf, const Graph& gr,
+               const LowerMap& lower, const CapacityMap& upper,
+               const CostMap& cost, const SupplyMap& supply,
+               bool mcf_result, bool result,
+               typename CostMap::Value total )
+{
+  check(mcf_result == result, "Wrong result " + test_id);
+  if (result) {
+    check(checkFlow(gr, lower, upper, supply, mcf.flowMap()),
+          "The flow is not feasible " + test_id);
+    check(mcf.totalCost() == total, "The flow is not optimal " + test_id);
+    check(checkOptimality(gr, lower, upper, cost, mcf.flowMap(), mcf.potentialMap()),
+          "Wrong potentials " + test_id);
+  }
+}
+
+int main()
+{
+  // Various tests on a small graph
+  {
+    typedef ListGraph Graph;
+    GRAPH_TYPEDEFS(ListGraph);
+
+    // Reading the test graph
+    Graph gr;
+    Graph::EdgeMap<int> c(gr), l1(gr), l2(gr), u(gr);
+    Graph::NodeMap<int> s1(gr), s2(gr), s3(gr);
+    Node v, w;
+
+    std::string fname;
+    if(getenv("srcdir"))
+      fname = std::string(getenv("srcdir"));
+    else fname = ".";
+    fname += "/test/min_cost_flow_test.lgf";
+
+    std::ifstream input(fname.c_str());
+    check(input, "Input file '" << fname << "' not found");
+    GraphReader<Graph>(input, gr).
+      readEdgeMap("cost", c).
+      readEdgeMap("capacity", u).
+      readEdgeMap("lower1", l1).
+      readEdgeMap("lower2", l2).
+      readNodeMap("supply1", s1).
+      readNodeMap("supply2", s2).
+      readNodeMap("supply3", s3).
+      readNode("source", v).
+      readNode("target", w).
+      run();
+    input.close();
+
+    // Testing CapacityScaling (scaling enabled)
+    {
+      CapacityScaling<Graph> mcf1(gr,u,c,s1);        checkMcf("#A1",mcf1,gr,l1,u,c,s1,mcf1.run(),true,    0);
+      CapacityScaling<Graph> mcf2(gr,u,c,s2);        checkMcf("#A2",mcf2,gr,l1,u,c,s2,mcf2.run(),true, 5240);
+      CapacityScaling<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#A3",mcf3,gr,l1,u,c,s3,mcf3.run(),true, 7620);
+      CapacityScaling<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#A4",mcf4,gr,l2,u,c,s1,mcf4.run(),false,   0);
+      CapacityScaling<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#A5",mcf5,gr,l2,u,c,s2,mcf5.run(),true, 5970);
+      CapacityScaling<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#A6",mcf6,gr,l2,u,c,s3,mcf6.run(),true, 8010);
+    }
+    // Testing CapacityScaling (scaling disabled)
+    {
+      CapacityScaling<Graph> mcf1(gr,u,c,s1);        checkMcf("#B1",mcf1,gr,l1,u,c,s1,mcf1.run(false),true,    0);
+      CapacityScaling<Graph> mcf2(gr,u,c,s2);        checkMcf("#B2",mcf2,gr,l1,u,c,s2,mcf2.run(false),true, 5240);
+      CapacityScaling<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#B3",mcf3,gr,l1,u,c,s3,mcf3.run(false),true, 7620);
+      CapacityScaling<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#B4",mcf4,gr,l2,u,c,s1,mcf4.run(false),false,   0);
+      CapacityScaling<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#B5",mcf5,gr,l2,u,c,s2,mcf5.run(false),true, 5970);
+      CapacityScaling<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#B6",mcf6,gr,l2,u,c,s3,mcf6.run(false),true, 8010);
+    }
+
+    // Testing CostScaling
+    {
+      CostScaling<Graph> mcf1(gr,u,c,s1);        checkMcf("#C1",mcf1,gr,l1,u,c,s1,mcf1.run(),true,    0);
+      CostScaling<Graph> mcf2(gr,u,c,s2);        checkMcf("#C2",mcf2,gr,l1,u,c,s2,mcf2.run(),true, 5240);
+      CostScaling<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#C3",mcf3,gr,l1,u,c,s3,mcf3.run(),true, 7620);
+      CostScaling<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#C4",mcf4,gr,l2,u,c,s1,mcf4.run(),false,   0);
+      CostScaling<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#C5",mcf5,gr,l2,u,c,s2,mcf5.run(),true, 5970);
+      CostScaling<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#C6",mcf6,gr,l2,u,c,s3,mcf6.run(),true, 8010);
+    }
+
+    // Testing NetworkSimplex (with the default pivot rule)
+    {
+      NetworkSimplex<Graph> mcf1(gr,u,c,s1);        checkMcf("#D1",mcf1,gr,l1,u,c,s1,mcf1.run(),true,    0);
+      NetworkSimplex<Graph> mcf2(gr,u,c,s2);        checkMcf("#D2",mcf2,gr,l1,u,c,s2,mcf2.run(),true, 5240);
+      NetworkSimplex<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#D3",mcf3,gr,l1,u,c,s3,mcf3.run(),true, 7620);
+      NetworkSimplex<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#D4",mcf4,gr,l2,u,c,s1,mcf4.run(),false,   0);
+      NetworkSimplex<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#D5",mcf5,gr,l2,u,c,s2,mcf5.run(),true, 5970);
+      NetworkSimplex<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#D6",mcf6,gr,l2,u,c,s3,mcf6.run(),true, 8010);
+    }
+    // Testing NetworkSimplex (with FIRST_ELIGIBLE_PIVOT)
+    {
+      NetworkSimplex<Graph>::PivotRuleEnum pr = NetworkSimplex<Graph>::FIRST_ELIGIBLE_PIVOT;
+      NetworkSimplex<Graph> mcf1(gr,u,c,s1);        checkMcf("#E1",mcf1,gr,l1,u,c,s1,mcf1.run(pr),true,    0);
+      NetworkSimplex<Graph> mcf2(gr,u,c,s2);        checkMcf("#E2",mcf2,gr,l1,u,c,s2,mcf2.run(pr),true, 5240);
+      NetworkSimplex<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#E3",mcf3,gr,l1,u,c,s3,mcf3.run(pr),true, 7620);
+      NetworkSimplex<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#E4",mcf4,gr,l2,u,c,s1,mcf4.run(pr),false,   0);
+      NetworkSimplex<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#E5",mcf5,gr,l2,u,c,s2,mcf5.run(pr),true, 5970);
+      NetworkSimplex<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#E6",mcf6,gr,l2,u,c,s3,mcf6.run(pr),true, 8010);
+    }
+    // Testing NetworkSimplex (with BEST_ELIGIBLE_PIVOT)
+    {
+      NetworkSimplex<Graph>::PivotRuleEnum pr = NetworkSimplex<Graph>::BEST_ELIGIBLE_PIVOT;
+      NetworkSimplex<Graph> mcf1(gr,u,c,s1);        checkMcf("#F1",mcf1,gr,l1,u,c,s1,mcf1.run(pr),true,    0);
+      NetworkSimplex<Graph> mcf2(gr,u,c,s2);        checkMcf("#F2",mcf2,gr,l1,u,c,s2,mcf2.run(pr),true, 5240);
+      NetworkSimplex<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#F3",mcf3,gr,l1,u,c,s3,mcf3.run(pr),true, 7620);
+      NetworkSimplex<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#F4",mcf4,gr,l2,u,c,s1,mcf4.run(pr),false,   0);
+      NetworkSimplex<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#F5",mcf5,gr,l2,u,c,s2,mcf5.run(pr),true, 5970);
+      NetworkSimplex<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#F6",mcf6,gr,l2,u,c,s3,mcf6.run(pr),true, 8010);
+    }
+    // Testing NetworkSimplex (with BLOCK_SEARCH_PIVOT)
+    {
+      NetworkSimplex<Graph>::PivotRuleEnum pr = NetworkSimplex<Graph>::BLOCK_SEARCH_PIVOT;
+      NetworkSimplex<Graph> mcf1(gr,u,c,s1);        checkMcf("#G1",mcf1,gr,l1,u,c,s1,mcf1.run(pr),true,    0);
+      NetworkSimplex<Graph> mcf2(gr,u,c,s2);        checkMcf("#G2",mcf2,gr,l1,u,c,s2,mcf2.run(pr),true, 5240);
+      NetworkSimplex<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#G3",mcf3,gr,l1,u,c,s3,mcf3.run(pr),true, 7620);
+      NetworkSimplex<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#G4",mcf4,gr,l2,u,c,s1,mcf4.run(pr),false,   0);
+      NetworkSimplex<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#G5",mcf5,gr,l2,u,c,s2,mcf5.run(pr),true, 5970);
+      NetworkSimplex<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#G6",mcf6,gr,l2,u,c,s3,mcf6.run(pr),true, 8010);
+    }
+    // Testing NetworkSimplex (with CANDIDATE_LIST_PIVOT)
+    {
+      NetworkSimplex<Graph>::PivotRuleEnum pr = NetworkSimplex<Graph>::CANDIDATE_LIST_PIVOT;
+      NetworkSimplex<Graph> mcf1(gr,u,c,s1);        checkMcf("#I1",mcf1,gr,l1,u,c,s1,mcf1.run(pr),true,    0);
+      NetworkSimplex<Graph> mcf2(gr,u,c,s2);        checkMcf("#I2",mcf2,gr,l1,u,c,s2,mcf2.run(pr),true, 5240);
+      NetworkSimplex<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#I3",mcf3,gr,l1,u,c,s3,mcf3.run(pr),true, 7620);
+      NetworkSimplex<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#I4",mcf4,gr,l2,u,c,s1,mcf4.run(pr),false,   0);
+      NetworkSimplex<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#I5",mcf5,gr,l2,u,c,s2,mcf5.run(pr),true, 5970);
+      NetworkSimplex<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#I6",mcf6,gr,l2,u,c,s3,mcf6.run(pr),true, 8010);
+    }
+    // Testing NetworkSimplex (with ALTERING_LIST_PIVOT)
+    {
+      NetworkSimplex<Graph>::PivotRuleEnum pr = NetworkSimplex<Graph>::ALTERING_LIST_PIVOT;
+      NetworkSimplex<Graph> mcf1(gr,u,c,s1);        checkMcf("#H1",mcf1,gr,l1,u,c,s1,mcf1.run(pr),true,    0);
+      NetworkSimplex<Graph> mcf2(gr,u,c,s2);        checkMcf("#H2",mcf2,gr,l1,u,c,s2,mcf2.run(pr),true, 5240);
+      NetworkSimplex<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#H3",mcf3,gr,l1,u,c,s3,mcf3.run(pr),true, 7620);
+      NetworkSimplex<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#H4",mcf4,gr,l2,u,c,s1,mcf4.run(pr),false,   0);
+      NetworkSimplex<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#H5",mcf5,gr,l2,u,c,s2,mcf5.run(pr),true, 5970);
+      NetworkSimplex<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#H6",mcf6,gr,l2,u,c,s3,mcf6.run(pr),true, 8010);
+    }
+
+    // Testing CycleCanceling (with BellmanFord)
+    {
+      CycleCanceling<Graph> mcf1(gr,u,c,s1);        checkMcf("#J1",mcf1,gr,l1,u,c,s1,mcf1.run(),true,    0);
+      CycleCanceling<Graph> mcf2(gr,u,c,s2);        checkMcf("#J2",mcf2,gr,l1,u,c,s2,mcf2.run(),true, 5240);
+      CycleCanceling<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#J3",mcf3,gr,l1,u,c,s3,mcf3.run(),true, 7620);
+      CycleCanceling<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#J4",mcf4,gr,l2,u,c,s1,mcf4.run(),false,   0);
+      CycleCanceling<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#J5",mcf5,gr,l2,u,c,s2,mcf5.run(),true, 5970);
+      CycleCanceling<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#J6",mcf6,gr,l2,u,c,s3,mcf6.run(),true, 8010);
+    }
+    // Testing CycleCanceling (with MinMeanCycle)
+    {
+      CycleCanceling<Graph> mcf1(gr,u,c,s1);        checkMcf("#K1",mcf1,gr,l1,u,c,s1,mcf1.run(true),true,    0);
+      CycleCanceling<Graph> mcf2(gr,u,c,s2);        checkMcf("#K2",mcf2,gr,l1,u,c,s2,mcf2.run(true),true, 5240);
+      CycleCanceling<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#K3",mcf3,gr,l1,u,c,s3,mcf3.run(true),true, 7620);
+      CycleCanceling<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#K4",mcf4,gr,l2,u,c,s1,mcf4.run(true),false,   0);
+      CycleCanceling<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#K5",mcf5,gr,l2,u,c,s2,mcf5.run(true),true, 5970);
+      CycleCanceling<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#K6",mcf6,gr,l2,u,c,s3,mcf6.run(true),true, 8010);
+    }
+
+    // Testing MinCostFlow
+    {
+      MinCostFlow<Graph> mcf1(gr,u,c,s1);        checkMcf("#L1",mcf1,gr,l1,u,c,s1,mcf1.run(),true,    0);
+      MinCostFlow<Graph> mcf2(gr,u,c,s2);        checkMcf("#L2",mcf2,gr,l1,u,c,s2,mcf2.run(),true, 5240);
+      MinCostFlow<Graph> mcf3(gr,u,c,v,w,27);    checkMcf("#L3",mcf3,gr,l1,u,c,s3,mcf3.run(),true, 7620);
+      MinCostFlow<Graph> mcf4(gr,l2,u,c,s1);     checkMcf("#L4",mcf4,gr,l2,u,c,s1,mcf4.run(),false,   0);
+      MinCostFlow<Graph> mcf5(gr,l2,u,c,s2);     checkMcf("#L5",mcf5,gr,l2,u,c,s2,mcf5.run(),true, 5970);
+      MinCostFlow<Graph> mcf6(gr,l2,u,c,v,w,27); checkMcf("#L6",mcf6,gr,l2,u,c,s3,mcf6.run(),true, 8010);
+    }
+
+    // Testing MinCostMaxFlow
+    {
+      MinCostMaxFlow<Graph> mcmf(gr,u,c,v,w);
+      mcmf.run();
+      checkMcf("#M1",mcmf,gr,l1,u,c,s3,true,true,7620);
+    }
+  }
+
+  // Benchmark test on a DIMACS network
+  {
+    typedef SmartGraph Graph;
+    GRAPH_TYPEDEFS(SmartGraph);
+
+    // Reading the test graph
+    Graph graph;
+    Graph::EdgeMap<int> lower(graph), capacity(graph), cost(graph);
+    Graph::NodeMap<int> supply(graph);
+
+    std::string fname;
+    if(getenv("srcdir"))
+      fname = std::string(getenv("srcdir"));
+    else fname = ".";
+    fname += "/test/min_cost_flow_test.net";
+
+    std::ifstream input(fname.c_str());
+    check(input, "Input file '" << fname << "' not found");
+    readDimacs(input, graph, lower, capacity, cost, supply);
+    input.close();
+
+    // NetworkSimplex
+    {
+      Timer t;
+      NetworkSimplex<Graph> mcf(graph, lower, capacity, cost, supply);
+      bool res = mcf.run();
+      t.stop();
+      checkMcf("#T3", mcf, graph, lower, capacity, cost, supply, res, true, 196587626);
+      std::cout << "NetworkSimplex";
+      std::cout << std::endl << t << std::endl;
+    }
+    // CapacityScaling
+    {
+      Timer t;
+      CapacityScaling<Graph> mcf(graph, lower, capacity, cost, supply);
+      bool res = mcf.run();
+      t.stop();
+      checkMcf("#T1", mcf, graph, lower, capacity, cost, supply, res, true, 196587626);
+      std::cout << "CapacityScaling";
+      std::cout << std::endl << t << std::endl;
+    }
+    // CostScaling
+    {
+      Timer t;
+      CostScaling<Graph> mcf(graph, lower, capacity, cost, supply);
+      bool res = mcf.run();
+      t.stop();
+      checkMcf("#T2", mcf, graph, lower, capacity, cost, supply, res, true, 196587626);
+      std::cout << "CostScaling";
+      std::cout << std::endl << t << std::endl;
+    }
+    // CycleCanceling
+    {
+      Timer t;
+      CycleCanceling<Graph> mcf(graph, lower, capacity, cost, supply);
+      bool res = mcf.run();
+      t.stop();
+      checkMcf("#T4", mcf, graph, lower, capacity, cost, supply, res, true, 196587626);
+      std::cout << "CycleCanceling";
+      std::cout << std::endl << t << std::endl;
+    }
+  }
+
+  return 0;
+}
Index: test/min_cost_flow_test.lgf
===================================================================
--- test/min_cost_flow_test.lgf	(revision 2584)
+++ test/min_cost_flow_test.lgf	(revision 2584)
@@ -0,0 +1,44 @@
+@nodeset
+label	supply1	supply2	supply3
+1	0	20	27	
+2	0	-4	0		
+3	0	0	0	
+4	0	0	0	
+5	0	9	0	
+6	0	-6	0	
+7	0	0	0	
+8	0	0	0	
+9	0	3	0	
+10	0	-2	0	
+11	0	0	0		
+12	0	-20	-27	
+               
+@edgeset
+		cost	capacity	lower1	lower2
+1	2	70	11		0	8
+1	3	150	3		0	1
+1	4	80	15		0	2
+2	8	80	12		0	0
+3	5	140	5		0	3
+4	6	60	10		0	1
+4	7	80	2		0	0
+4	8	110	3		0	0
+5	7	60	14		0	0
+5	11	120	12		0	0
+6	3	0	3		0	0
+6	9	140	4		0	0
+6	10	90	8		0	0
+7	1	30	5		0	0
+8	12	60	16		0	4
+9	12	50	6		0	0
+10	12	70	13		0	5
+10	2	100	7		0	0
+10	7	60	10		0	0
+11	10	20	14		0	6
+12	11	30	10		0	0
+
+@nodes
+source	1
+target	12
+
+@end
Index: test/min_cost_flow_test.net
===================================================================
--- test/min_cost_flow_test.net	(revision 2584)
+++ test/min_cost_flow_test.net	(revision 2584)
@@ -0,0 +1,1531 @@
+c NETGEN flow network generator (C version)
+c  Problem  1 input parameters
+c  ---------------------------
+c   Random seed:            13502460
+c   Number of nodes:             200
+c   Source nodes:                100
+c   Sink nodes:                  100
+c   Number of arcs:             1300
+c   Minimum arc cost:              1
+c   Maximum arc cost:          10000
+c   Total supply:             100000
+c   Transshipment -
+c     Sources:                     0
+c     Sinks:                       0
+c   Skeleton arcs -
+c     With max cost:               0%
+c     Capacitated:                 0%
+c   Minimum arc capacity:          0
+c   Maximum arc capacity:          0
+c
+c  *** Minimum cost flow ***
+c
+p min 200 1308
+n 1 286
+n 2 671
+n 3 605
+n 4 195
+n 5 1287
+n 6 497
+n 7 149
+n 8 660
+n 9 676
+n 10 1338
+n 11 222
+n 12 738
+n 13 1819
+n 14 1857
+n 15 1749
+n 16 1479
+n 17 154
+n 18 1897
+n 19 707
+n 20 367
+n 21 917
+n 22 410
+n 23 1000
+n 24 770
+n 25 1122
+n 26 1895
+n 27 1501
+n 28 514
+n 29 2227
+n 30 913
+n 31 947
+n 32 2260
+n 33 996
+n 34 986
+n 35 125
+n 36 362
+n 37 706
+n 38 1262
+n 39 389
+n 40 1410
+n 41 758
+n 42 2189
+n 43 531
+n 44 527
+n 45 2028
+n 46 1710
+n 47 1196
+n 48 832
+n 49 73
+n 50 1269
+n 51 1485
+n 52 1174
+n 53 1325
+n 54 2136
+n 55 852
+n 56 301
+n 57 707
+n 58 807
+n 59 1242
+n 60 1739
+n 61 1225
+n 62 94
+n 63 989
+n 64 1641
+n 65 805
+n 66 236
+n 67 1520
+n 68 1421
+n 69 936
+n 70 100
+n 71 952
+n 72 501
+n 73 1858
+n 74 1563
+n 75 186
+n 76 1307
+n 77 626
+n 78 1032
+n 79 939
+n 80 1159
+n 81 904
+n 82 1332
+n 83 1280
+n 84 2080
+n 85 1260
+n 86 512
+n 87 191
+n 88 309
+n 89 1053
+n 90 1070
+n 91 656
+n 92 1155
+n 93 493
+n 94 1135
+n 95 1199
+n 96 1914
+n 97 677
+n 98 192
+n 99 914
+n 100 1638
+n 101 -1827
+n 102 -1234
+n 103 -903
+n 104 -1166
+n 105 -2594
+n 106 -10
+n 107 -710
+n 108 -1074
+n 109 -686
+n 110 -147
+n 111 -955
+n 112 -535
+n 113 -1118
+n 114 -381
+n 115 -297
+n 116 -599
+n 117 -1534
+n 118 -160
+n 119 -114
+n 120 -1633
+n 121 -195
+n 122 -689
+n 123 -62
+n 124 -111
+n 125 -869
+n 126 -84
+n 127 -2074
+n 128 -31
+n 129 -1851
+n 130 -1720
+n 131 -754
+n 132 -2739
+n 133 -155
+n 134 -3154
+n 135 -572
+n 136 -2372
+n 137 -321
+n 138 -86
+n 139 -1687
+n 140 -1346
+n 141 -2465
+n 142 -388
+n 143 -1861
+n 144 -971
+n 145 -628
+n 146 -187
+n 147 -26
+n 148 -1975
+n 149 -2424
+n 150 -574
+n 151 -163
+n 152 -1126
+n 153 -2865
+n 154 -233
+n 155 -2837
+n 156 -1209
+n 157 -2017
+n 158 -2228
+n 159 -740
+n 160 -290
+n 161 -9
+n 162 -151
+n 163 -2922
+n 164 -1405
+n 165 -374
+n 166 -880
+n 167 -47
+n 168 -865
+n 169 -728
+n 170 -103
+n 171 -616
+n 172 -318
+n 173 -2548
+n 174 -353
+n 175 -937
+n 176 -1012
+n 177 -504
+n 178 -39
+n 179 -1897
+n 180 -1130
+n 181 -1971
+n 182 -1941
+n 183 -1758
+n 184 -2284
+n 185 -998
+n 186 -875
+n 187 -1083
+n 188 -257
+n 189 -2394
+n 190 -351
+n 191 -578
+n 192 -53
+n 193 -223
+n 194 -869
+n 195 -1088
+n 196 -96
+n 197 -755
+n 198 -1577
+n 199 -131
+n 200 -124
+a 1 102 0 100000 8550
+a 1 171 0 100000 7415
+a 1 101 0 100000 7178
+a 1 165 0 100000 4494
+a 1 151 0 100000 6289
+a 1 187 0 100000 1281
+a 1 189 0 100000 6859
+a 1 166 0 100000 8963
+a 1 182 0 100000 1704
+a 1 112 0 100000 6045
+a 1 154 0 100000 5938
+a 1 160 0 100000 8099
+a 1 186 0 100000 3667
+a 1 126 0 100000 6885
+a 1 132 0 100000 1207
+a 1 197 0 100000 7041
+a 2 181 0 100000 8581
+a 2 155 0 100000 4218
+a 2 152 0 100000 9984
+a 2 166 0 100000 7839
+a 2 184 0 100000 6509
+a 2 164 0 100000 4037
+a 2 167 0 100000 3308
+a 2 180 0 100000 3719
+a 2 157 0 100000 2558
+a 2 120 0 100000 1380
+a 2 159 0 100000 452
+a 2 119 0 100000 1576
+a 2 111 0 100000 9029
+a 2 146 0 100000 3919
+a 2 145 0 100000 2355
+a 3 166 0 100000 9197
+a 3 180 0 100000 5974
+a 3 106 0 100000 5746
+a 3 119 0 100000 7933
+a 3 145 0 100000 8276
+a 3 120 0 100000 3279
+a 3 103 0 100000 5734
+a 3 130 0 100000 5935
+a 3 157 0 100000 5403
+a 3 175 0 100000 730
+a 4 119 0 100000 4678
+a 4 134 0 100000 752
+a 4 199 0 100000 6613
+a 4 104 0 100000 5132
+a 4 158 0 100000 6946
+a 4 139 0 100000 5430
+a 4 113 0 100000 5236
+a 4 174 0 100000 6554
+a 4 179 0 100000 4745
+a 4 103 0 100000 3365
+a 4 144 0 100000 2841
+a 4 169 0 100000 743
+a 4 130 0 100000 1917
+a 4 197 0 100000 5331
+a 4 175 0 100000 2557
+a 5 158 0 100000 8388
+a 5 102 0 100000 3231
+a 5 155 0 100000 4091
+a 5 125 0 100000 7576
+a 6 106 0 100000 1759
+a 6 120 0 100000 3707
+a 6 192 0 100000 2581
+a 6 176 0 100000 8376
+a 6 121 0 100000 5426
+a 6 102 0 100000 895
+a 6 167 0 100000 8750
+a 6 152 0 100000 454
+a 6 124 0 100000 2864
+a 6 108 0 100000 3204
+a 6 184 0 100000 8370
+a 6 195 0 100000 2914
+a 6 149 0 100000 9326
+a 6 140 0 100000 7174
+a 6 169 0 100000 9346
+a 6 127 0 100000 6898
+a 6 134 0 100000 8782
+a 6 173 0 100000 9386
+a 6 183 0 100000 9188
+a 7 198 0 100000 1118
+a 7 102 0 100000 6098
+a 7 170 0 100000 5021
+a 7 199 0 100000 6752
+a 8 180 0 100000 1271
+a 8 129 0 100000 4668
+a 8 170 0 100000 7417
+a 8 177 0 100000 3773
+a 8 106 0 100000 7995
+a 8 134 0 100000 4729
+a 8 183 0 100000 2999
+a 8 159 0 100000 7149
+a 8 164 0 100000 4594
+a 9 140 0 100000 7422
+a 9 159 0 100000 1784
+a 9 182 0 100000 7713
+a 9 193 0 100000 194
+a 9 125 0 100000 2095
+a 9 198 0 100000 7925
+a 9 169 0 100000 2421
+a 9 195 0 100000 9863
+a 9 146 0 100000 7451
+a 9 126 0 100000 858
+a 9 197 0 100000 4286
+a 9 192 0 100000 9168
+a 9 109 0 100000 6058
+a 9 106 0 100000 9915
+a 9 138 0 100000 7024
+a 9 123 0 100000 3551
+a 9 163 0 100000 5507
+a 9 104 0 100000 5826
+a 9 139 0 100000 787
+a 10 143 0 100000 6434
+a 10 175 0 100000 5810
+a 10 165 0 100000 612
+a 10 126 0 100000 6095
+a 10 101 0 100000 1609
+a 10 153 0 100000 4862
+a 10 149 0 100000 1918
+a 10 140 0 100000 782
+a 10 145 0 100000 9166
+a 10 141 0 100000 846
+a 10 176 0 100000 2056
+a 10 113 0 100000 4056
+a 11 124 0 100000 4877
+a 11 176 0 100000 683
+a 11 177 0 100000 4842
+a 11 107 0 100000 5609
+a 11 139 0 100000 7808
+a 11 188 0 100000 2218
+a 11 134 0 100000 9467
+a 11 169 0 100000 5894
+a 11 109 0 100000 8396
+a 11 165 0 100000 9248
+a 11 149 0 100000 889
+a 11 175 0 100000 9202
+a 11 130 0 100000 4593
+a 11 152 0 100000 1837
+a 11 145 0 100000 9058
+a 11 138 0 100000 3582
+a 11 122 0 100000 7516
+a 11 146 0 100000 719
+a 11 112 0 100000 9082
+a 11 160 0 100000 6105
+a 11 128 0 100000 4323
+a 11 194 0 100000 8202
+a 11 168 0 100000 8736
+a 11 102 0 100000 8382
+a 11 101 0 100000 9503
+a 12 117 0 100000 3034
+a 12 172 0 100000 7033
+a 12 183 0 100000 7235
+a 12 105 0 100000 2219
+a 12 163 0 100000 9998
+a 12 198 0 100000 6881
+a 12 114 0 100000 8613
+a 12 174 0 100000 4456
+a 12 147 0 100000 4762
+a 12 101 0 100000 2794
+a 12 120 0 100000 5705
+a 12 144 0 100000 9694
+a 12 191 0 100000 1124
+a 12 161 0 100000 8140
+a 12 185 0 100000 8678
+a 13 163 0 100000 854
+a 13 141 0 100000 3211
+a 13 122 0 100000 5557
+a 13 169 0 100000 4912
+a 13 151 0 100000 9351
+a 13 162 0 100000 5018
+a 13 131 0 100000 6210
+a 13 167 0 100000 1858
+a 13 133 0 100000 2148
+a 13 175 0 100000 4424
+a 13 112 0 100000 8310
+a 13 179 0 100000 7491
+a 13 142 0 100000 3439
+a 13 199 0 100000 7269
+a 14 148 0 100000 8480
+a 14 163 0 100000 2274
+a 14 143 0 100000 2854
+a 14 140 0 100000 2177
+a 14 161 0 100000 5688
+a 14 146 0 100000 7526
+a 14 118 0 100000 2712
+a 14 169 0 100000 552
+a 14 187 0 100000 9060
+a 14 166 0 100000 248
+a 14 155 0 100000 5144
+a 14 186 0 100000 3864
+a 14 111 0 100000 6005
+a 14 193 0 100000 4245
+a 14 120 0 100000 8330
+a 14 152 0 100000 7421
+a 14 126 0 100000 142
+a 14 165 0 100000 3420
+a 14 199 0 100000 6522
+a 14 153 0 100000 5961
+a 14 130 0 100000 5736
+a 15 186 0 100000 4114
+a 15 148 0 100000 9833
+a 15 187 0 100000 8173
+a 15 134 0 100000 2495
+a 15 115 0 100000 4604
+a 15 146 0 100000 2949
+a 15 189 0 100000 9903
+a 15 138 0 100000 8139
+a 15 184 0 100000 7591
+a 15 110 0 100000 5914
+a 15 165 0 100000 5669
+a 15 103 0 100000 3590
+a 16 130 0 100000 9385
+a 16 176 0 100000 9727
+a 16 199 0 100000 9266
+a 16 198 0 100000 9129
+a 16 194 0 100000 6915
+a 16 155 0 100000 5789
+a 16 190 0 100000 1965
+a 16 135 0 100000 7619
+a 16 195 0 100000 6171
+a 16 131 0 100000 2529
+a 16 171 0 100000 5969
+a 17 144 0 100000 9423
+a 17 157 0 100000 9156
+a 17 176 0 100000 2918
+a 17 158 0 100000 7903
+a 17 129 0 100000 7213
+a 17 160 0 100000 4253
+a 17 156 0 100000 8909
+a 17 182 0 100000 6735
+a 17 139 0 100000 9549
+a 17 162 0 100000 7045
+a 17 138 0 100000 2554
+a 17 143 0 100000 4064
+a 17 173 0 100000 5104
+a 17 166 0 100000 4292
+a 17 105 0 100000 1842
+a 18 158 0 100000 9866
+a 18 197 0 100000 7354
+a 18 184 0 100000 6383
+a 18 161 0 100000 1002
+a 18 199 0 100000 2172
+a 18 155 0 100000 7750
+a 19 158 0 100000 7165
+a 19 190 0 100000 5440
+a 19 159 0 100000 3536
+a 19 117 0 100000 3537
+a 19 109 0 100000 3991
+a 19 140 0 100000 3108
+a 19 128 0 100000 7287
+a 20 159 0 100000 1035
+a 20 185 0 100000 535
+a 20 148 0 100000 9177
+a 20 171 0 100000 2425
+a 20 144 0 100000 7990
+a 20 186 0 100000 2564
+a 20 187 0 100000 2509
+a 20 172 0 100000 4673
+a 20 110 0 100000 6121
+a 20 149 0 100000 8447
+a 20 101 0 100000 6134
+a 20 157 0 100000 8659
+a 20 178 0 100000 6884
+a 20 135 0 100000 1567
+a 20 106 0 100000 8015
+a 20 128 0 100000 4746
+a 20 121 0 100000 8069
+a 20 194 0 100000 1385
+a 21 111 0 100000 4392
+a 21 105 0 100000 9561
+a 21 134 0 100000 1551
+a 21 108 0 100000 5449
+a 21 126 0 100000 103
+a 21 103 0 100000 4043
+a 21 142 0 100000 8749
+a 21 183 0 100000 4714
+a 21 172 0 100000 4855
+a 21 123 0 100000 9136
+a 21 117 0 100000 9771
+a 21 114 0 100000 8472
+a 21 101 0 100000 299
+a 21 113 0 100000 1446
+a 21 165 0 100000 4952
+a 21 163 0 100000 4478
+a 21 153 0 100000 5954
+a 21 170 0 100000 279
+a 21 129 0 100000 6788
+a 21 152 0 100000 578
+a 21 198 0 100000 2459
+a 22 152 0 100000 8855
+a 22 142 0 100000 829
+a 22 176 0 100000 6797
+a 22 126 0 100000 2513
+a 22 188 0 100000 7332
+a 22 177 0 100000 3842
+a 22 186 0 100000 473
+a 22 127 0 100000 8075
+a 22 171 0 100000 924
+a 22 156 0 100000 4585
+a 22 130 0 100000 9616
+a 22 112 0 100000 2078
+a 22 155 0 100000 79
+a 23 193 0 100000 7025
+a 23 129 0 100000 4876
+a 23 114 0 100000 5073
+a 23 126 0 100000 1821
+a 23 199 0 100000 7200
+a 23 128 0 100000 2940
+a 23 181 0 100000 9911
+a 23 155 0 100000 3948
+a 23 197 0 100000 9522
+a 23 151 0 100000 5662
+a 23 111 0 100000 6135
+a 23 175 0 100000 5329
+a 23 102 0 100000 8364
+a 23 139 0 100000 6544
+a 23 104 0 100000 283
+a 23 156 0 100000 8369
+a 23 108 0 100000 3491
+a 23 110 0 100000 6481
+a 23 124 0 100000 946
+a 23 131 0 100000 9861
+a 23 141 0 100000 4976
+a 24 183 0 100000 2975
+a 24 149 0 100000 2843
+a 24 117 0 100000 3594
+a 24 166 0 100000 1261
+a 24 184 0 100000 2514
+a 24 153 0 100000 2271
+a 24 114 0 100000 7316
+a 24 198 0 100000 6092
+a 24 105 0 100000 7868
+a 24 139 0 100000 8309
+a 24 174 0 100000 5131
+a 24 197 0 100000 1045
+a 24 195 0 100000 845
+a 24 176 0 100000 5820
+a 24 181 0 100000 6085
+a 24 101 0 100000 7898
+a 25 152 0 100000 4264
+a 25 140 0 100000 5481
+a 25 126 0 100000 8929
+a 25 196 0 100000 3220
+a 25 165 0 100000 5562
+a 25 151 0 100000 5705
+a 25 112 0 100000 830
+a 25 191 0 100000 5730
+a 25 178 0 100000 7717
+a 25 167 0 100000 4126
+a 25 163 0 100000 3714
+a 25 185 0 100000 225
+a 25 129 0 100000 3369
+a 25 123 0 100000 3660
+a 25 177 0 100000 2367
+a 25 116 0 100000 2469
+a 25 139 0 100000 9779
+a 25 125 0 100000 1489
+a 26 139 0 100000 6155
+a 26 182 0 100000 7651
+a 26 189 0 100000 707
+a 26 190 0 100000 7671
+a 26 180 0 100000 1178
+a 26 124 0 100000 6625
+a 26 184 0 100000 1171
+a 26 154 0 100000 7505
+a 27 143 0 100000 423
+a 27 117 0 100000 5685
+a 27 180 0 100000 6991
+a 27 129 0 100000 4564
+a 27 193 0 100000 2539
+a 27 173 0 100000 7896
+a 27 195 0 100000 3690
+a 27 142 0 100000 8270
+a 27 131 0 100000 2276
+a 27 153 0 100000 2689
+a 28 188 0 100000 8418
+a 28 111 0 100000 1308
+a 28 158 0 100000 709
+a 28 161 0 100000 1968
+a 28 130 0 100000 6317
+a 28 168 0 100000 8008
+a 28 160 0 100000 879
+a 29 101 0 100000 767
+a 29 157 0 100000 6845
+a 29 149 0 100000 9061
+a 29 112 0 100000 281
+a 29 164 0 100000 5274
+a 29 199 0 100000 8463
+a 29 180 0 100000 9707
+a 29 165 0 100000 7565
+a 29 178 0 100000 8621
+a 29 118 0 100000 7437
+a 29 169 0 100000 9960
+a 29 125 0 100000 51
+a 29 150 0 100000 474
+a 29 160 0 100000 2568
+a 29 141 0 100000 4219
+a 29 187 0 100000 731
+a 29 158 0 100000 2476
+a 29 144 0 100000 7245
+a 29 129 0 100000 7548
+a 29 190 0 100000 3895
+a 30 185 0 100000 1822
+a 30 134 0 100000 9893
+a 30 122 0 100000 1153
+a 31 159 0 100000 7778
+a 31 105 0 100000 4967
+a 31 153 0 100000 3541
+a 31 160 0 100000 2677
+a 31 111 0 100000 3222
+a 31 136 0 100000 3269
+a 31 125 0 100000 9717
+a 31 181 0 100000 2325
+a 31 119 0 100000 8407
+a 31 127 0 100000 890
+a 31 124 0 100000 9168
+a 31 104 0 100000 6356
+a 31 179 0 100000 9162
+a 31 167 0 100000 383
+a 31 112 0 100000 1886
+a 31 120 0 100000 5326
+a 31 114 0 100000 3436
+a 32 173 0 100000 6787
+a 32 145 0 100000 1839
+a 32 113 0 100000 3758
+a 32 182 0 100000 4761
+a 32 119 0 100000 9817
+a 32 196 0 100000 9686
+a 32 129 0 100000 716
+a 32 116 0 100000 5747
+a 32 178 0 100000 1074
+a 32 167 0 100000 8680
+a 33 194 0 100000 4684
+a 33 127 0 100000 8502
+a 33 174 0 100000 7338
+a 33 175 0 100000 6420
+a 33 138 0 100000 9551
+a 33 115 0 100000 4239
+a 33 107 0 100000 6930
+a 33 104 0 100000 2172
+a 33 190 0 100000 8714
+a 33 151 0 100000 4263
+a 33 182 0 100000 2765
+a 33 161 0 100000 5954
+a 33 173 0 100000 274
+a 33 154 0 100000 9371
+a 33 156 0 100000 75
+a 33 114 0 100000 8067
+a 33 153 0 100000 2563
+a 33 169 0 100000 6915
+a 33 164 0 100000 8577
+a 33 110 0 100000 3079
+a 34 139 0 100000 3061
+a 34 183 0 100000 7251
+a 34 178 0 100000 8023
+a 34 163 0 100000 2993
+a 34 109 0 100000 9045
+a 34 172 0 100000 5404
+a 34 112 0 100000 7608
+a 34 196 0 100000 5449
+a 34 148 0 100000 2226
+a 34 142 0 100000 8808
+a 34 174 0 100000 9183
+a 34 123 0 100000 9092
+a 34 145 0 100000 1530
+a 34 162 0 100000 1288
+a 34 166 0 100000 388
+a 34 133 0 100000 1153
+a 34 115 0 100000 2210
+a 34 151 0 100000 979
+a 34 171 0 100000 1136
+a 34 137 0 100000 4830
+a 35 143 0 100000 8167
+a 35 123 0 100000 2401
+a 35 112 0 100000 4052
+a 35 149 0 100000 721
+a 35 132 0 100000 9237
+a 35 172 0 100000 9679
+a 35 117 0 100000 1469
+a 35 131 0 100000 7061
+a 35 106 0 100000 8448
+a 36 175 0 100000 8043
+a 36 121 0 100000 5151
+a 36 197 0 100000 7643
+a 36 116 0 100000 5790
+a 36 180 0 100000 1932
+a 36 128 0 100000 2477
+a 36 151 0 100000 5441
+a 36 174 0 100000 2204
+a 36 146 0 100000 7937
+a 36 193 0 100000 1912
+a 36 156 0 100000 5652
+a 36 138 0 100000 297
+a 36 191 0 100000 5116
+a 36 167 0 100000 8999
+a 36 140 0 100000 996
+a 36 103 0 100000 9577
+a 36 190 0 100000 1154
+a 36 165 0 100000 3326
+a 36 109 0 100000 1374
+a 36 110 0 100000 4679
+a 36 199 0 100000 134
+a 36 133 0 100000 9431
+a 37 174 0 100000 8274
+a 37 155 0 100000 4671
+a 37 114 0 100000 5912
+a 37 115 0 100000 506
+a 37 105 0 100000 592
+a 37 183 0 100000 2115
+a 37 108 0 100000 4928
+a 37 151 0 100000 4240
+a 37 148 0 100000 3234
+a 37 102 0 100000 8815
+a 37 109 0 100000 2968
+a 37 169 0 100000 6360
+a 37 128 0 100000 2348
+a 37 131 0 100000 6860
+a 37 166 0 100000 63
+a 37 103 0 100000 6161
+a 37 189 0 100000 4195
+a 37 147 0 100000 2127
+a 37 138 0 100000 7864
+a 37 163 0 100000 8904
+a 37 173 0 100000 1849
+a 38 134 0 100000 4026
+a 38 145 0 100000 2413
+a 38 165 0 100000 9230
+a 38 123 0 100000 6347
+a 38 185 0 100000 7621
+a 38 176 0 100000 6322
+a 38 198 0 100000 6454
+a 38 144 0 100000 5084
+a 38 121 0 100000 4462
+a 38 171 0 100000 5174
+a 38 136 0 100000 7419
+a 38 197 0 100000 7167
+a 38 179 0 100000 8980
+a 38 149 0 100000 7865
+a 38 178 0 100000 8248
+a 38 174 0 100000 6791
+a 38 164 0 100000 2361
+a 38 112 0 100000 2817
+a 38 196 0 100000 4887
+a 38 186 0 100000 9293
+a 38 106 0 100000 8175
+a 38 162 0 100000 8814
+a 38 181 0 100000 6761
+a 38 118 0 100000 7130
+a 39 157 0 100000 2168
+a 39 175 0 100000 5692
+a 39 178 0 100000 824
+a 39 142 0 100000 8831
+a 39 102 0 100000 8242
+a 39 121 0 100000 4162
+a 39 120 0 100000 658
+a 39 115 0 100000 451
+a 39 187 0 100000 7287
+a 39 117 0 100000 920
+a 40 107 0 100000 9440
+a 40 136 0 100000 9931
+a 40 103 0 100000 2181
+a 40 167 0 100000 3325
+a 40 129 0 100000 2074
+a 40 112 0 100000 8163
+a 40 104 0 100000 7518
+a 40 178 0 100000 8993
+a 40 116 0 100000 5561
+a 40 153 0 100000 1486
+a 40 171 0 100000 2580
+a 40 120 0 100000 9790
+a 40 175 0 100000 3030
+a 40 137 0 100000 7218
+a 40 177 0 100000 3087
+a 40 157 0 100000 4168
+a 41 181 0 100000 2843
+a 41 195 0 100000 38
+a 41 188 0 100000 5970
+a 41 129 0 100000 9147
+a 41 191 0 100000 6004
+a 41 116 0 100000 641
+a 41 122 0 100000 4426
+a 41 130 0 100000 9454
+a 41 170 0 100000 6046
+a 41 190 0 100000 4061
+a 41 174 0 100000 2125
+a 41 154 0 100000 5084
+a 41 160 0 100000 6356
+a 41 126 0 100000 5929
+a 41 196 0 100000 5812
+a 42 192 0 100000 517
+a 42 132 0 100000 9462
+a 42 146 0 100000 9442
+a 42 115 0 100000 897
+a 42 136 0 100000 1010
+a 42 143 0 100000 5852
+a 42 121 0 100000 1511
+a 42 189 0 100000 8165
+a 43 173 0 100000 8839
+a 43 177 0 100000 7059
+a 43 190 0 100000 5703
+a 43 106 0 100000 2300
+a 43 183 0 100000 8036
+a 43 184 0 100000 3295
+a 43 149 0 100000 47
+a 43 138 0 100000 8879
+a 43 129 0 100000 6876
+a 43 159 0 100000 2735
+a 43 191 0 100000 5062
+a 43 114 0 100000 9343
+a 43 187 0 100000 7699
+a 43 101 0 100000 6528
+a 44 136 0 100000 4162
+a 44 187 0 100000 2697
+a 44 163 0 100000 5418
+a 44 164 0 100000 398
+a 44 185 0 100000 4266
+a 44 161 0 100000 1979
+a 44 108 0 100000 290
+a 44 142 0 100000 6228
+a 45 153 0 100000 7269
+a 45 131 0 100000 9755
+a 45 143 0 100000 2025
+a 45 103 0 100000 8690
+a 45 118 0 100000 2138
+a 45 197 0 100000 5449
+a 45 102 0 100000 1992
+a 45 178 0 100000 8724
+a 45 145 0 100000 3579
+a 45 148 0 100000 3401
+a 45 137 0 100000 6512
+a 45 101 0 100000 4089
+a 45 166 0 100000 9039
+a 45 136 0 100000 3125
+a 45 156 0 100000 9040
+a 45 117 0 100000 9017
+a 45 130 0 100000 7846
+a 45 167 0 100000 5795
+a 45 112 0 100000 4049
+a 45 189 0 100000 5361
+a 45 110 0 100000 3463
+a 45 104 0 100000 2703
+a 45 191 0 100000 4933
+a 45 199 0 100000 453
+a 46 105 0 100000 2727
+a 46 101 0 100000 5811
+a 46 155 0 100000 4784
+a 46 118 0 100000 8390
+a 46 125 0 100000 1868
+a 46 102 0 100000 1061
+a 46 116 0 100000 6477
+a 46 117 0 100000 9105
+a 46 160 0 100000 8012
+a 46 111 0 100000 1797
+a 46 154 0 100000 3602
+a 46 167 0 100000 7643
+a 47 183 0 100000 3875
+a 47 185 0 100000 6570
+a 47 132 0 100000 4893
+a 47 110 0 100000 8941
+a 47 126 0 100000 7755
+a 47 149 0 100000 2372
+a 47 148 0 100000 9010
+a 47 172 0 100000 6363
+a 47 167 0 100000 8364
+a 47 188 0 100000 3388
+a 47 191 0 100000 9257
+a 47 147 0 100000 5413
+a 47 195 0 100000 5203
+a 47 154 0 100000 8479
+a 48 127 0 100000 4388
+a 48 184 0 100000 2303
+a 48 188 0 100000 5084
+a 48 169 0 100000 7676
+a 48 105 0 100000 2852
+a 48 193 0 100000 690
+a 48 158 0 100000 417
+a 48 153 0 100000 5
+a 48 111 0 100000 3129
+a 48 125 0 100000 2579
+a 48 166 0 100000 5544
+a 49 147 0 100000 7701
+a 49 167 0 100000 1900
+a 49 114 0 100000 233
+a 50 136 0 100000 3386
+a 50 144 0 100000 5104
+a 50 124 0 100000 3836
+a 50 103 0 100000 9195
+a 50 132 0 100000 9972
+a 50 105 0 100000 9808
+a 50 109 0 100000 7794
+a 50 185 0 100000 1427
+a 50 171 0 100000 861
+a 50 172 0 100000 8095
+a 50 137 0 100000 1247
+a 50 146 0 100000 1390
+a 50 164 0 100000 7230
+a 50 128 0 100000 6607
+a 50 192 0 100000 536
+a 50 162 0 100000 8900
+a 50 139 0 100000 4048
+a 50 168 0 100000 866
+a 50 163 0 100000 3045
+a 50 160 0 100000 5860
+a 50 154 0 100000 3524
+a 51 198 0 100000 8797
+a 51 113 0 100000 7824
+a 51 119 0 100000 6822
+a 51 121 0 100000 906
+a 51 126 0 100000 5758
+a 51 108 0 100000 482
+a 51 164 0 100000 7309
+a 51 179 0 100000 140
+a 51 151 0 100000 3541
+a 51 152 0 100000 4888
+a 51 191 0 100000 7396
+a 51 120 0 100000 450
+a 51 175 0 100000 164
+a 51 184 0 100000 2982
+a 51 109 0 100000 1592
+a 52 103 0 100000 5867
+a 52 168 0 100000 9405
+a 52 166 0 100000 1851
+a 52 107 0 100000 8869
+a 52 185 0 100000 8713
+a 52 105 0 100000 4844
+a 52 187 0 100000 5453
+a 52 177 0 100000 663
+a 52 161 0 100000 5850
+a 52 183 0 100000 4625
+a 52 133 0 100000 3978
+a 52 148 0 100000 9864
+a 52 155 0 100000 1239
+a 52 152 0 100000 1119
+a 52 120 0 100000 7484
+a 52 198 0 100000 1265
+a 52 149 0 100000 9158
+a 52 109 0 100000 8778
+a 52 181 0 100000 8651
+a 52 170 0 100000 5148
+a 52 122 0 100000 6264
+a 53 127 0 100000 6883
+a 53 171 0 100000 6015
+a 53 153 0 100000 1067
+a 53 184 0 100000 4740
+a 53 131 0 100000 2021
+a 53 176 0 100000 3635
+a 53 141 0 100000 6086
+a 53 159 0 100000 4074
+a 54 184 0 100000 9056
+a 54 137 0 100000 1830
+a 54 134 0 100000 1633
+a 54 106 0 100000 7750
+a 55 158 0 100000 8771
+a 55 103 0 100000 9981
+a 55 105 0 100000 4340
+a 55 141 0 100000 1298
+a 55 198 0 100000 2025
+a 55 136 0 100000 7016
+a 55 111 0 100000 9926
+a 55 152 0 100000 7367
+a 55 147 0 100000 7000
+a 55 133 0 100000 2114
+a 55 188 0 100000 6509
+a 55 102 0 100000 7100
+a 55 140 0 100000 9075
+a 55 195 0 100000 2705
+a 55 183 0 100000 3775
+a 55 199 0 100000 9215
+a 55 193 0 100000 2312
+a 56 162 0 100000 3207
+a 56 104 0 100000 2760
+a 56 146 0 100000 129
+a 56 115 0 100000 6086
+a 56 181 0 100000 8352
+a 56 142 0 100000 5707
+a 56 164 0 100000 8547
+a 56 168 0 100000 2167
+a 56 153 0 100000 2387
+a 56 151 0 100000 6697
+a 56 187 0 100000 3439
+a 56 160 0 100000 5918
+a 57 173 0 100000 1494
+a 57 111 0 100000 3886
+a 57 183 0 100000 8402
+a 57 169 0 100000 9896
+a 57 146 0 100000 376
+a 57 192 0 100000 5247
+a 58 150 0 100000 9423
+a 58 183 0 100000 9465
+a 58 148 0 100000 3885
+a 58 111 0 100000 4529
+a 58 129 0 100000 4093
+a 58 196 0 100000 3619
+a 58 102 0 100000 4690
+a 58 101 0 100000 9365
+a 59 120 0 100000 9651
+a 59 181 0 100000 1323
+a 59 155 0 100000 4233
+a 59 156 0 100000 6044
+a 59 194 0 100000 7289
+a 59 148 0 100000 1133
+a 59 198 0 100000 3136
+a 59 130 0 100000 4275
+a 59 184 0 100000 5271
+a 59 132 0 100000 4958
+a 59 101 0 100000 705
+a 59 186 0 100000 576
+a 59 179 0 100000 6456
+a 59 188 0 100000 5973
+a 59 173 0 100000 3298
+a 59 102 0 100000 125
+a 59 196 0 100000 6596
+a 59 195 0 100000 2748
+a 59 182 0 100000 5207
+a 59 127 0 100000 2055
+a 60 140 0 100000 198
+a 60 125 0 100000 5868
+a 60 112 0 100000 1114
+a 60 139 0 100000 6263
+a 60 135 0 100000 7430
+a 60 113 0 100000 9681
+a 60 173 0 100000 4299
+a 60 114 0 100000 3324
+a 60 148 0 100000 6396
+a 60 105 0 100000 8471
+a 60 137 0 100000 6050
+a 60 176 0 100000 1898
+a 60 144 0 100000 7048
+a 60 158 0 100000 1960
+a 60 142 0 100000 808
+a 60 199 0 100000 6892
+a 60 181 0 100000 9745
+a 60 183 0 100000 4567
+a 60 129 0 100000 8038
+a 60 182 0 100000 4638
+a 61 189 0 100000 622
+a 61 198 0 100000 2853
+a 61 124 0 100000 5593
+a 61 163 0 100000 5273
+a 61 190 0 100000 7555
+a 61 176 0 100000 5610
+a 61 147 0 100000 3824
+a 61 160 0 100000 2776
+a 61 164 0 100000 611
+a 61 112 0 100000 3067
+a 61 156 0 100000 7410
+a 62 104 0 100000 2965
+a 62 190 0 100000 5531
+a 62 162 0 100000 951
+a 62 191 0 100000 9851
+a 62 108 0 100000 2837
+a 62 165 0 100000 9780
+a 62 147 0 100000 2541
+a 62 169 0 100000 9168
+a 62 125 0 100000 3518
+a 62 102 0 100000 6357
+a 62 117 0 100000 7423
+a 62 149 0 100000 6295
+a 62 133 0 100000 3556
+a 62 172 0 100000 2760
+a 62 131 0 100000 1038
+a 62 112 0 100000 8003
+a 62 196 0 100000 5587
+a 62 157 0 100000 7749
+a 63 111 0 100000 2883
+a 63 195 0 100000 5347
+a 63 112 0 100000 5677
+a 63 115 0 100000 7834
+a 63 174 0 100000 112
+a 63 126 0 100000 6624
+a 63 117 0 100000 6148
+a 64 144 0 100000 6266
+a 64 164 0 100000 4807
+a 64 171 0 100000 3160
+a 64 119 0 100000 1438
+a 64 136 0 100000 7963
+a 64 197 0 100000 2673
+a 64 155 0 100000 5421
+a 64 133 0 100000 5839
+a 64 138 0 100000 1274
+a 64 127 0 100000 1906
+a 64 161 0 100000 1934
+a 64 118 0 100000 2475
+a 64 169 0 100000 6793
+a 64 116 0 100000 1502
+a 64 158 0 100000 9432
+a 64 148 0 100000 5157
+a 64 145 0 100000 2663
+a 64 174 0 100000 5351
+a 64 114 0 100000 390
+a 64 181 0 100000 6721
+a 64 113 0 100000 521
+a 65 132 0 100000 983
+a 65 177 0 100000 277
+a 65 199 0 100000 8990
+a 65 179 0 100000 7885
+a 65 136 0 100000 3413
+a 65 130 0 100000 751
+a 65 168 0 100000 9573
+a 65 111 0 100000 1534
+a 65 124 0 100000 3928
+a 65 106 0 100000 3456
+a 66 115 0 100000 3992
+a 66 104 0 100000 5112
+a 66 130 0 100000 7285
+a 66 163 0 100000 3213
+a 67 153 0 100000 5367
+a 67 164 0 100000 992
+a 67 179 0 100000 3091
+a 67 193 0 100000 6000
+a 67 107 0 100000 2802
+a 67 110 0 100000 6027
+a 67 176 0 100000 1881
+a 68 189 0 100000 8212
+a 68 117 0 100000 5853
+a 68 102 0 100000 1766
+a 68 147 0 100000 9440
+a 68 125 0 100000 4494
+a 68 196 0 100000 2219
+a 68 128 0 100000 8093
+a 68 145 0 100000 1500
+a 68 152 0 100000 7419
+a 68 112 0 100000 357
+a 69 169 0 100000 7598
+a 69 180 0 100000 4870
+a 69 147 0 100000 5253
+a 69 119 0 100000 1569
+a 69 123 0 100000 2218
+a 69 128 0 100000 3191
+a 69 178 0 100000 3243
+a 69 109 0 100000 2712
+a 70 104 0 100000 3090
+a 70 161 0 100000 8413
+a 70 160 0 100000 5623
+a 70 164 0 100000 4675
+a 70 101 0 100000 3196
+a 70 151 0 100000 6580
+a 70 182 0 100000 2231
+a 70 189 0 100000 4394
+a 70 176 0 100000 7897
+a 70 118 0 100000 2776
+a 70 135 0 100000 1215
+a 70 163 0 100000 3973
+a 70 147 0 100000 6983
+a 70 145 0 100000 9550
+a 70 177 0 100000 9000
+a 71 189 0 100000 9496
+a 71 176 0 100000 7401
+a 71 168 0 100000 3386
+a 71 171 0 100000 857
+a 71 106 0 100000 1626
+a 71 180 0 100000 4392
+a 71 117 0 100000 1387
+a 71 120 0 100000 2961
+a 72 114 0 100000 1334
+a 72 155 0 100000 1601
+a 72 125 0 100000 4500
+a 72 193 0 100000 6333
+a 72 142 0 100000 2443
+a 72 143 0 100000 6087
+a 72 126 0 100000 3103
+a 72 122 0 100000 7043
+a 72 144 0 100000 2262
+a 72 149 0 100000 8288
+a 72 169 0 100000 7041
+a 72 191 0 100000 1744
+a 72 102 0 100000 800
+a 72 112 0 100000 6299
+a 72 135 0 100000 4666
+a 73 149 0 100000 7120
+a 73 135 0 100000 4142
+a 73 126 0 100000 4345
+a 73 163 0 100000 2025
+a 73 181 0 100000 6997
+a 73 183 0 100000 4271
+a 73 137 0 100000 1721
+a 73 108 0 100000 8579
+a 73 157 0 100000 3323
+a 73 189 0 100000 7748
+a 73 193 0 100000 2716
+a 73 133 0 100000 7771
+a 74 179 0 100000 6114
+a 74 165 0 100000 2864
+a 74 143 0 100000 8298
+a 74 185 0 100000 25
+a 74 122 0 100000 6212
+a 74 153 0 100000 3894
+a 74 171 0 100000 4548
+a 74 119 0 100000 118
+a 74 199 0 100000 993
+a 74 142 0 100000 450
+a 74 157 0 100000 239
+a 74 133 0 100000 4863
+a 74 149 0 100000 6706
+a 74 131 0 100000 6898
+a 74 170 0 100000 3870
+a 74 155 0 100000 1070
+a 74 160 0 100000 8776
+a 74 186 0 100000 1287
+a 74 156 0 100000 168
+a 74 115 0 100000 9426
+a 74 178 0 100000 8333
+a 75 158 0 100000 8894
+a 75 118 0 100000 5751
+a 75 183 0 100000 701
+a 75 136 0 100000 7606
+a 75 114 0 100000 6108
+a 75 187 0 100000 1344
+a 75 139 0 100000 6359
+a 76 154 0 100000 2123
+a 76 108 0 100000 8824
+a 76 177 0 100000 7541
+a 76 164 0 100000 2126
+a 77 112 0 100000 4554
+a 77 135 0 100000 1530
+a 77 174 0 100000 8435
+a 77 163 0 100000 2591
+a 77 115 0 100000 2699
+a 77 148 0 100000 1129
+a 77 151 0 100000 3926
+a 77 122 0 100000 5591
+a 77 171 0 100000 485
+a 77 185 0 100000 3582
+a 77 159 0 100000 6813
+a 77 186 0 100000 9253
+a 77 192 0 100000 8683
+a 77 189 0 100000 2594
+a 77 126 0 100000 3857
+a 77 187 0 100000 4829
+a 77 101 0 100000 3127
+a 77 168 0 100000 9562
+a 78 130 0 100000 4773
+a 78 181 0 100000 8278
+a 78 174 0 100000 9425
+a 78 157 0 100000 960
+a 78 153 0 100000 6664
+a 78 193 0 100000 1091
+a 78 191 0 100000 1146
+a 78 167 0 100000 2079
+a 78 187 0 100000 7846
+a 78 180 0 100000 6890
+a 78 140 0 100000 3681
+a 78 123 0 100000 9889
+a 78 136 0 100000 2581
+a 78 114 0 100000 8237
+a 78 185 0 100000 7211
+a 78 179 0 100000 2871
+a 78 163 0 100000 9106
+a 78 176 0 100000 613
+a 78 113 0 100000 6406
+a 78 120 0 100000 2646
+a 79 129 0 100000 9500
+a 79 117 0 100000 642
+a 79 112 0 100000 4390
+a 79 163 0 100000 8981
+a 79 134 0 100000 692
+a 79 151 0 100000 9675
+a 79 141 0 100000 9335
+a 79 195 0 100000 592
+a 79 148 0 100000 9350
+a 80 163 0 100000 7627
+a 80 115 0 100000 1213
+a 80 176 0 100000 6650
+a 80 154 0 100000 1461
+a 80 129 0 100000 5116
+a 80 190 0 100000 8975
+a 80 110 0 100000 6622
+a 80 172 0 100000 5146
+a 80 179 0 100000 9326
+a 80 194 0 100000 9545
+a 80 193 0 100000 9695
+a 80 105 0 100000 6431
+a 80 153 0 100000 8063
+a 80 151 0 100000 268
+a 80 141 0 100000 3870
+a 80 127 0 100000 7778
+a 80 186 0 100000 1408
+a 80 103 0 100000 8091
+a 80 147 0 100000 7096
+a 81 176 0 100000 5892
+a 81 104 0 100000 9989
+a 81 148 0 100000 2980
+a 81 117 0 100000 4901
+a 81 168 0 100000 7736
+a 81 183 0 100000 2080
+a 81 109 0 100000 4254
+a 81 136 0 100000 4219
+a 81 113 0 100000 599
+a 81 194 0 100000 945
+a 81 131 0 100000 6901
+a 81 120 0 100000 8066
+a 81 112 0 100000 6948
+a 81 163 0 100000 290
+a 81 167 0 100000 3149
+a 81 192 0 100000 3799
+a 81 199 0 100000 9046
+a 81 114 0 100000 3217
+a 82 155 0 100000 1806
+a 82 149 0 100000 8452
+a 82 131 0 100000 9547
+a 82 164 0 100000 6171
+a 82 123 0 100000 746
+a 82 192 0 100000 7626
+a 82 109 0 100000 6452
+a 82 183 0 100000 6875
+a 82 199 0 100000 9335
+a 82 106 0 100000 8829
+a 82 140 0 100000 4045
+a 82 139 0 100000 1519
+a 82 198 0 100000 8376
+a 82 132 0 100000 1494
+a 83 134 0 100000 8175
+a 83 148 0 100000 9715
+a 83 137 0 100000 5879
+a 83 187 0 100000 6419
+a 83 158 0 100000 8364
+a 83 109 0 100000 1339
+a 83 189 0 100000 3531
+a 83 104 0 100000 8448
+a 83 142 0 100000 7624
+a 84 122 0 100000 9325
+a 84 155 0 100000 6505
+a 84 197 0 100000 2423
+a 84 162 0 100000 7925
+a 85 120 0 100000 5058
+a 85 141 0 100000 7909
+a 85 116 0 100000 744
+a 85 117 0 100000 3459
+a 85 178 0 100000 6907
+a 85 105 0 100000 5893
+a 85 111 0 100000 5745
+a 85 119 0 100000 5858
+a 85 128 0 100000 2066
+a 85 168 0 100000 3736
+a 85 172 0 100000 7023
+a 85 109 0 100000 4184
+a 85 197 0 100000 5602
+a 86 139 0 100000 7483
+a 86 168 0 100000 3950
+a 86 157 0 100000 9064
+a 86 162 0 100000 2213
+a 87 103 0 100000 2133
+a 87 152 0 100000 4604
+a 87 169 0 100000 5604
+a 87 146 0 100000 2714
+a 87 166 0 100000 5340
+a 87 199 0 100000 5069
+a 87 148 0 100000 9419
+a 87 104 0 100000 9528
+a 87 141 0 100000 9671
+a 87 107 0 100000 7085
+a 87 131 0 100000 4186
+a 87 114 0 100000 2238
+a 87 191 0 100000 2804
+a 87 132 0 100000 1397
+a 87 185 0 100000 9858
+a 88 139 0 100000 2066
+a 88 144 0 100000 892
+a 88 197 0 100000 5596
+a 89 184 0 100000 9075
+a 89 179 0 100000 4975
+a 89 161 0 100000 2205
+a 89 176 0 100000 7314
+a 89 126 0 100000 6811
+a 89 187 0 100000 8180
+a 89 102 0 100000 7763
+a 89 173 0 100000 8398
+a 89 181 0 100000 7363
+a 89 129 0 100000 7490
+a 89 162 0 100000 8354
+a 90 187 0 100000 7647
+a 90 153 0 100000 5311
+a 90 192 0 100000 2193
+a 90 141 0 100000 4888
+a 90 165 0 100000 8780
+a 90 102 0 100000 5458
+a 90 125 0 100000 7208
+a 90 158 0 100000 1113
+a 90 198 0 100000 6401
+a 90 111 0 100000 1515
+a 90 138 0 100000 3238
+a 90 180 0 100000 3045
+a 90 186 0 100000 3
+a 90 178 0 100000 8749
+a 90 177 0 100000 1632
+a 90 106 0 100000 4327
+a 90 196 0 100000 470
+a 90 163 0 100000 7911
+a 91 113 0 100000 8296
+a 91 127 0 100000 2971
+a 91 146 0 100000 3356
+a 91 182 0 100000 2580
+a 91 196 0 100000 8202
+a 91 116 0 100000 3104
+a 92 191 0 100000 8165
+a 92 166 0 100000 2242
+a 92 197 0 100000 9395
+a 93 136 0 100000 8664
+a 93 129 0 100000 7802
+a 93 170 0 100000 4699
+a 93 124 0 100000 5870
+a 93 137 0 100000 9775
+a 93 115 0 100000 7499
+a 93 110 0 100000 9601
+a 93 101 0 100000 9002
+a 93 150 0 100000 9882
+a 93 104 0 100000 1079
+a 93 193 0 100000 7464
+a 93 105 0 100000 7327
+a 93 166 0 100000 1808
+a 94 169 0 100000 7589
+a 94 141 0 100000 2981
+a 94 180 0 100000 9358
+a 94 176 0 100000 8554
+a 94 124 0 100000 2707
+a 94 122 0 100000 7508
+a 94 166 0 100000 3171
+a 94 165 0 100000 9695
+a 94 154 0 100000 8485
+a 94 170 0 100000 2444
+a 94 177 0 100000 3552
+a 94 114 0 100000 6951
+a 94 164 0 100000 6526
+a 94 189 0 100000 8986
+a 94 110 0 100000 4338
+a 94 109 0 100000 2554
+a 94 116 0 100000 7506
+a 94 133 0 100000 1605
+a 94 156 0 100000 9888
+a 95 157 0 100000 8289
+a 95 116 0 100000 1995
+a 95 194 0 100000 8381
+a 95 132 0 100000 7280
+a 95 134 0 100000 6754
+a 95 136 0 100000 1773
+a 95 144 0 100000 9910
+a 95 156 0 100000 1163
+a 95 124 0 100000 9214
+a 95 146 0 100000 6315
+a 95 126 0 100000 2269
+a 95 140 0 100000 637
+a 95 183 0 100000 924
+a 95 163 0 100000 8392
+a 95 145 0 100000 8797
+a 96 156 0 100000 6213
+a 96 129 0 100000 7538
+a 96 123 0 100000 8516
+a 96 169 0 100000 3383
+a 96 142 0 100000 2851
+a 96 124 0 100000 8365
+a 96 184 0 100000 4157
+a 97 182 0 100000 3135
+a 97 130 0 100000 3328
+a 97 170 0 100000 5735
+a 97 174 0 100000 2525
+a 97 151 0 100000 5910
+a 97 141 0 100000 4351
+a 97 126 0 100000 8844
+a 97 155 0 100000 629
+a 97 149 0 100000 9449
+a 97 108 0 100000 422
+a 97 131 0 100000 775
+a 97 154 0 100000 9304
+a 97 172 0 100000 5967
+a 97 123 0 100000 793
+a 97 128 0 100000 7372
+a 97 121 0 100000 835
+a 97 157 0 100000 690
+a 97 165 0 100000 1889
+a 97 156 0 100000 2855
+a 97 106 0 100000 3640
+a 97 105 0 100000 9742
+a 97 122 0 100000 9646
+a 97 107 0 100000 3286
+a 98 131 0 100000 9078
+a 98 196 0 100000 5946
+a 98 113 0 100000 9995
+a 98 177 0 100000 825
+a 98 119 0 100000 7372
+a 98 188 0 100000 2749
+a 98 130 0 100000 7285
+a 98 120 0 100000 7653
+a 98 152 0 100000 3129
+a 98 104 0 100000 9652
+a 98 108 0 100000 7514
+a 98 117 0 100000 7705
+a 98 171 0 100000 1725
+a 99 105 0 100000 5557
+a 99 109 0 100000 5355
+a 99 114 0 100000 8765
+a 99 112 0 100000 100
+a 99 187 0 100000 8348
+a 99 199 0 100000 419
+a 99 167 0 100000 2556
+a 99 129 0 100000 196
+a 100 184 0 100000 5607
+a 100 150 0 100000 749
+a 100 110 0 100000 2973
+a 100 126 0 100000 9347
+a 100 128 0 100000 3349
+a 100 133 0 100000 3154
+a 100 138 0 100000 8997
+a 100 146 0 100000 4125
+a 100 151 0 100000 8931
+a 100 160 0 100000 1750
+a 100 170 0 100000 5508
+a 100 178 0 100000 1772
+a 100 199 0 100000 9538
+a 100 200 0 100000 3509
Index: test/mip_test.cc
===================================================================
--- test/mip_test.cc	(revision 2571)
+++ test/mip_test.cc	(revision 2571)
@@ -0,0 +1,125 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include "test_tools.h"
+
+
+#ifdef HAVE_CONFIG_H
+#include <lemon/config.h>
+#endif
+
+#ifdef HAVE_CPLEX
+#include <lemon/mip_cplex.h>
+#endif
+
+#ifdef HAVE_GLPK
+#include <lemon/mip_glpk.h>
+#endif
+
+
+using namespace lemon;
+
+void solveAndCheck(MipSolverBase& lp, MipSolverBase::SolutionStatus stat, 
+		   double exp_opt) {
+  using std::string;
+
+  lp.solve();
+  //int decimal,sign;
+  std::ostringstream buf;
+  buf << "Primalstatus should be: " << int(stat)<<" and it is "<<int(lp.mipStatus());
+
+
+  //  itoa(stat,buf1, 10);
+  check(lp.mipStatus()==stat, buf.str());
+
+  if (stat ==  MipSolverBase::OPTIMAL) {
+    std::ostringstream sbuf;
+    buf << "Wrong optimal value: the right optimum is " << exp_opt; 
+    check(std::abs(lp.primalValue()-exp_opt) < 1e-3, sbuf.str());
+    //+ecvt(exp_opt,2)
+  }
+}
+
+void aTest(MipSolverBase& mip)
+{
+ //The following example is very simple
+
+
+  typedef MipSolverBase::Row Row;
+  typedef MipSolverBase::Col Col;
+
+
+
+  Col x1 = mip.addCol();
+  Col x2 = mip.addCol();
+
+
+  //Objective function
+  mip.obj(x1);
+
+  mip.max();
+
+
+  //Unconstrained optimization
+  mip.solve();
+  //Check it out!
+
+  //Constraints
+  mip.addRow(2*x1+x2 <=2);  
+  mip.addRow(x1-2*x2 <=0);
+
+  //Nonnegativity of the variable x1
+  mip.colLowerBound(x1, 0);
+
+  //Maximization of x1
+  //over the triangle with vertices (0,0),(4/5,2/5),(0,2)
+  double expected_opt=4.0/5.0;
+  solveAndCheck(mip, MipSolverBase::OPTIMAL, expected_opt);
+
+  //Restrict x2 to integer
+  mip.colType(x2,MipSolverBase::INT);  
+  expected_opt=1.0/2.0;
+  solveAndCheck(mip, MipSolverBase::OPTIMAL, expected_opt);
+
+
+  //Restrict both to integer
+  mip.colType(x1,MipSolverBase::INT);  
+  expected_opt=0;
+  solveAndCheck(mip, MipSolverBase::OPTIMAL, expected_opt);
+
+ 
+
+}
+
+
+int main() 
+{
+
+#ifdef HAVE_GLPK
+  MipGlpk mip1;
+  aTest(mip1);
+#endif
+
+#ifdef HAVE_CPLEX
+  MipCplex mip2;
+  aTest(mip2);
+#endif
+
+  return 0;
+
+}
Index: test/path_test.cc
===================================================================
--- test/path_test.cc	(revision 2553)
+++ test/path_test.cc	(revision 2553)
@@ -0,0 +1,44 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <string>
+#include <iostream>
+
+#include <lemon/concepts/path.h>
+#include <lemon/concepts/graph.h>
+
+#include <lemon/path.h>
+#include <lemon/list_graph.h>
+
+#include "test_tools.h"
+
+using namespace std;
+using namespace lemon;
+
+void check_concepts() {
+  checkConcept<concepts::Path<ListGraph>, concepts::Path<ListGraph> >();
+  checkConcept<concepts::Path<ListGraph>, Path<ListGraph> >();
+  checkConcept<concepts::Path<ListGraph>, SimplePath<ListGraph> >();
+  checkConcept<concepts::Path<ListGraph>, StaticPath<ListGraph> >();
+  checkConcept<concepts::Path<ListGraph>, ListPath<ListGraph> >();
+}
+
+int main() {
+  check_concepts();  
+  return 0;
+}
Index: test/polynomial_test.cc
===================================================================
--- test/polynomial_test.cc	(revision 2553)
+++ test/polynomial_test.cc	(revision 2553)
@@ -0,0 +1,81 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/polynomial.h>
+#include <lemon/dim2.h>
+#include <iostream>
+#include "test_tools.h"
+
+using namespace std;
+using namespace lemon;
+int main()
+{
+  Polynomial<int> pi(5);
+  check(pi.deg()==5,"Something is wrong here.");
+  pi[0]=12;
+  pi[5]=3;
+  pi[2]=7;
+  check(pi[1]==0,"Uninitialized elements should be(?) zero.");
+  {
+    Polynomial<double> pd=pi;
+    check(pd.deg()==5,"Something is wrong here.");
+    check(pd[0]==12,"Something is wrong here.");
+    check(pd[5]==3,"Something is wrong here.");
+
+  }
+
+  Polynomial<double> pd;
+  pd=pi;
+  check(pd.deg()==5,"Something is wrong here.");
+  check(pd[0]==12,"Something is wrong here.");
+  check(pd[5]==3,"Something is wrong here.");
+
+  check(pd(0)==12,"Something is wrong here.");
+  check(pd(1)==22,"Something is wrong here.");
+  check(pd(2)==136,"Something is wrong here.");
+
+  check((pd*pi).deg()==10,"Something is wrong here.");
+  check((pd*pi)[10]==9,"Something is wrong here.");
+  check((pd*pi)[7]==42,"Something is wrong here.");
+
+  Polynomial<double> pd2=pd+pi;
+  check(pd2[5]==6,"Something is wrong here.");
+  pd2+=pd;
+  pd2+=pi;
+  check(pd2[5]==12,"Something is wrong here.");
+  pd2-=pd;
+  pd2-=pi;
+  check(pd2[5]==6,"Something is wrong here.");
+  check((pd-pi)[5]==0,"Something is wrong here.");
+
+  Polynomial<double> pdd=pd.derivate();
+  pd.derivateMyself();
+  check(pdd==pd,"Something is wrong here.");
+  check(pd.deg()==4,"Something is wrong here.");
+  check(pd[4]==15,"Something is wrong here.");
+
+  
+  Polynomial<double> pdi=pd.integrate();
+  pd.integrateMyself();
+  check(pdi==pd,"Something is wrong here.");
+  check(pd.deg()==5,"Something is wrong here.");
+  check(pd[5]==3,"Something is wrong here.");
+  check(pd[0]==0,"Something is wrong here.");
+  
+  
+}
Index: test/preflow_graph.dim
===================================================================
--- test/preflow_graph.dim	(revision 1435)
+++ test/preflow_graph.dim	(revision 1435)
@@ -0,0 +1,20 @@
+p max 10 17
+n 2 s
+n 9 t
+a 1 2 20
+a 1 3 0
+a 2 2 3
+a 2 3 8
+a 2 4 8
+a 3 6 5
+a 4 3 5
+a 4 6 5
+a 4 7 5
+a 5 4 3
+a 6 8 3
+a 6 7 10
+a 6 9 10
+a 7 9 8
+a 9 10 20
+a 9 2 5
+a 10 6 5
Index: test/preflow_test.cc
===================================================================
--- test/preflow_test.cc	(revision 2553)
+++ test/preflow_test.cc	(revision 2553)
@@ -0,0 +1,201 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <fstream>
+#include <string>
+
+#include "test_tools.h"
+#include <lemon/smart_graph.h>
+#include <lemon/dimacs.h>
+#include <lemon/preflow.h>
+#include <lemon/concepts/graph.h>
+#include <lemon/concepts/maps.h>
+
+using namespace lemon;
+
+void checkPreflow() 
+{
+  typedef int VType;
+  typedef concepts::Graph Graph;
+
+  typedef Graph::Node Node;
+  typedef Graph::Edge Edge;
+  typedef concepts::ReadMap<Edge,VType> CapMap;
+  typedef concepts::ReadWriteMap<Edge,VType> FlowMap;
+  typedef concepts::WriteMap<Node,bool> CutMap;
+ 
+  Graph g;
+  Node n;
+  Edge e;
+  CapMap cap;
+  FlowMap flow;
+  CutMap cut;
+
+  Preflow<Graph, CapMap>::DefFlowMap<FlowMap>::Create preflow_test(g,cap,n,n);
+
+  preflow_test.capacityMap(cap);
+  flow = preflow_test.flowMap();
+  preflow_test.flowMap(flow);
+  preflow_test.source(n);
+  preflow_test.target(n);
+  
+  preflow_test.init();
+  preflow_test.flowInit(cap);
+  preflow_test.startFirstPhase();
+  preflow_test.startSecondPhase();
+  preflow_test.run();
+  preflow_test.runMinCut();
+
+  preflow_test.flowValue();
+  preflow_test.minCut(n);
+  preflow_test.minCutMap(cut);
+  preflow_test.flow(e);
+
+}
+
+int cutValue (const SmartGraph& g, 
+	      const SmartGraph::NodeMap<bool>& cut, 
+	      const SmartGraph::EdgeMap<int>& cap) {
+  
+  int c=0;
+  for(SmartGraph::EdgeIt e(g); e!=INVALID; ++e) {
+    if (cut[g.source(e)] && !cut[g.target(e)]) c+=cap[e];
+  }
+  return c;
+}
+
+bool checkFlow(const SmartGraph& g, 
+	       const SmartGraph::EdgeMap<int>& flow, 
+	       const SmartGraph::EdgeMap<int>& cap, 
+	       SmartGraph::Node s, SmartGraph::Node t) {
+
+  for (SmartGraph::EdgeIt e(g); e != INVALID; ++e) {
+    if (flow[e] < 0 || flow[e] > cap[e]) return false;
+  }
+
+  for (SmartGraph::NodeIt n(g); n != INVALID; ++n) {
+    if (n == s || n == t) continue;
+    int sum = 0;
+    for (SmartGraph::OutEdgeIt e(g, n); e != INVALID; ++e) {
+      sum += flow[e];
+    }
+    for (SmartGraph::InEdgeIt e(g, n); e != INVALID; ++e) {
+      sum -= flow[e];
+    }
+    if (sum != 0) return false;
+  }
+  return true;
+}
+
+int main() {
+
+  typedef SmartGraph Graph;
+  
+  typedef Graph::Node Node;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::EdgeMap<int> CapMap;
+  typedef Graph::EdgeMap<int> FlowMap;
+  typedef Graph::NodeMap<bool> CutMap;
+
+  typedef Preflow<Graph, CapMap> PType;
+
+  std::string f_name;
+  if( getenv("srcdir") )
+    f_name = std::string(getenv("srcdir"));
+  else f_name = ".";
+  f_name += "/test/preflow_graph.dim";
+  
+  std::ifstream file(f_name.c_str());
+  
+  check(file, "Input file '" << f_name << "' not found.");
+  
+  Graph g;
+  Node s, t;
+  CapMap cap(g);
+  readDimacs(file, g, cap, s, t);
+
+  PType preflow_test(g, cap, s, t);
+  preflow_test.run();
+    
+  check(checkFlow(g, preflow_test.flowMap(), cap, s, t),
+	"The flow is not feasible.");
+
+  CutMap min_cut(g);
+  preflow_test.minCutMap(min_cut); 
+  int min_cut_value=cutValue(g,min_cut,cap);
+  
+  check(preflow_test.flowValue() == min_cut_value,
+	"The max flow value is not equal to the three min cut values.");
+
+  FlowMap flow(g);
+  flow = preflow_test.flowMap();
+
+  int flow_value=preflow_test.flowValue();
+
+  for(EdgeIt e(g); e!=INVALID; ++e) cap[e]=2*cap[e]; 
+  preflow_test.flowInit(flow);
+  preflow_test.startFirstPhase();
+
+  CutMap min_cut1(g);
+  preflow_test.minCutMap(min_cut1); 
+  min_cut_value=cutValue(g,min_cut1,cap);
+   
+  check(preflow_test.flowValue() == min_cut_value &&
+	min_cut_value == 2*flow_value,
+	"The max flow value or the min cut value is wrong.");
+
+  preflow_test.startSecondPhase();
+
+  check(checkFlow(g, preflow_test.flowMap(), cap, s, t),
+	"The flow is not feasible.");
+
+  CutMap min_cut2(g);
+  preflow_test.minCutMap(min_cut2); 
+  min_cut_value=cutValue(g,min_cut2,cap);
+   
+  check(preflow_test.flowValue() == min_cut_value &&
+	min_cut_value == 2*flow_value,
+	"The max flow value or the three min cut values were not doubled");
+
+
+  preflow_test.flowMap(flow); 
+
+  NodeIt tmp1(g,s);
+  ++tmp1;
+  if ( tmp1 != INVALID ) s=tmp1;
+
+  NodeIt tmp2(g,t);
+  ++tmp2;
+  if ( tmp2 != INVALID ) t=tmp2;
+
+  preflow_test.source(s);
+  preflow_test.target(t); 
+  
+  preflow_test.run();
+
+  CutMap min_cut3(g);
+  preflow_test.minCutMap(min_cut3); 
+  min_cut_value=cutValue(g,min_cut3,cap);
+   
+
+  check(preflow_test.flowValue() == min_cut_value,
+	"The max flow value or the three min cut values are incorrect.");
+  
+  return 0;
+}
Index: test/radix_sort_test.cc
===================================================================
--- test/radix_sort_test.cc	(revision 2569)
+++ test/radix_sort_test.cc	(revision 2569)
@@ -0,0 +1,190 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/time_measure.h>
+#include <lemon/smart_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/maps.h>
+#include <lemon/radix_sort.h>
+
+#include "test_tools.h"
+
+
+#include <vector>
+#include <algorithm>
+#include <lemon/math.h>
+
+using namespace std;
+using namespace lemon;
+
+typedef unsigned char uchar;
+
+void checkRadixSort() {
+  {
+    int n = 10000;
+    vector<int> data1(n), data2(n);
+    for (int i = 0; i < n; ++i) {
+      data1[i] = data2[i] = rnd[1000] - 500;
+    }
+    radixSort(data1.begin(), data1.end());
+    sort(data2.begin(), data2.end());
+    for (int i = 0; i < n; ++i) {
+      check(data1[i] == data2[i], "Test failed");
+    }
+  } {
+    int n = 10000;
+    vector<unsigned char> data1(n), data2(n);
+    for (int i = 0; i < n; ++i) {
+      data1[i] = data2[i] = rnd[uchar(200)];
+    }
+    radixSort(data1.begin(), data1.end());
+    sort(data2.begin(), data2.end());
+    for (int i = 0; i < n; ++i) {
+      check(data1[i] == data2[i], "Test failed");
+    }
+  }
+}
+
+
+void checkCounterSort() {
+  {
+    int n = 10000;
+    vector<int> data1(n), data2(n);
+    for (int i = 0; i < n; ++i) {
+      data1[i] = data2[i] = rnd[1000] - 500;
+    }
+    counterSort(data1.begin(), data1.end());
+    sort(data2.begin(), data2.end());
+    for (int i = 0; i < n; ++i) {
+      check(data1[i] == data2[i], "Test failed");
+    } 
+  } {
+    int n = 10000;
+    vector<unsigned char> data1(n), data2(n);
+    for (int i = 0; i < n; ++i) {
+      data1[i] = data2[i] = rnd[uchar(200)];
+    }
+    counterSort(data1.begin(), data1.end());
+    sort(data2.begin(), data2.end());
+    for (int i = 0; i < n; ++i) {
+      check(data1[i] == data2[i], "Test failed");
+    } 
+  }
+}
+
+void checkSorts() {
+  checkRadixSort();
+  checkCounterSort();
+}
+
+void checkGraphRadixSort() {
+  typedef SmartGraph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::Edge Edge;
+
+  const int n = 100;
+  const int e = int(n * log(double(n)));
+
+  Graph graph;
+  vector<Node> nodes;
+
+  for (int i = 0; i < n; ++i) {
+    nodes.push_back(graph.addNode());
+  }
+  vector<Edge> edges;
+  for (int i = 0; i < e; ++i) {
+    int s = rnd[n];
+    int t = rnd[n];
+    edges.push_back(graph.addEdge(nodes[s], nodes[t]));
+  }
+
+  radixSort(edges.begin(), edges.end(), 
+	    mapFunctor(composeMap(IdMap<Graph, Node>(graph), 
+				  sourceMap(graph))));
+
+  Graph::EdgeMap<bool> was(graph, false);
+
+  for (int i = 0; i < int(edges.size()); ++i) {
+    check(!was[edges[i]], "Test failed");
+    was[edges[i]] = true;
+  }
+
+  for (int i = 1; i < int(edges.size()); ++i) {
+    check(graph.id(graph.source(edges[i - 1])) <= 
+	  graph.id(graph.source(edges[i])), "Test failed");
+  }
+
+}
+
+void checkGraphCounterSort() {
+  typedef SmartGraph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::Edge Edge;
+
+  const int n = 100;
+  const int e = int(n * log(double(n)));
+
+  Graph graph;
+  vector<Node> nodes;
+
+  for (int i = 0; i < n; ++i) {
+    nodes.push_back(graph.addNode());
+  }
+  vector<Edge> edges;
+  for (int i = 0; i < e; ++i) {
+    int s = rnd[n];
+    int t = rnd[n];
+    edges.push_back(graph.addEdge(nodes[s], nodes[t]));
+  }
+
+  counterSort(edges.begin(), edges.end(), 
+	      mapFunctor(composeMap(IdMap<Graph, Node>(graph), 
+				    sourceMap(graph))));
+
+  counterSort(edges.begin(), edges.end(), 
+	      mapFunctor(composeMap(IdMap<Graph, Node>(graph), 
+				    targetMap(graph))));
+
+  Graph::EdgeMap<bool> was(graph, false);
+
+  for (int i = 0; i < int(edges.size()); ++i) {
+    check(!was[edges[i]], "Test failed");
+    was[edges[i]] = true;
+  }
+
+  for (int i = 1; i < int(edges.size()); ++i) {
+    check(graph.id(graph.target(edges[i - 1])) < 
+	  graph.id(graph.target(edges[i])) || 
+	  (graph.id(graph.target(edges[i - 1])) ==
+	   graph.id(graph.target(edges[i])) &&
+	   graph.id(graph.source(edges[i - 1])) <= 
+	   graph.id(graph.source(edges[i]))), "Test failed");
+  }
+
+}
+
+void checkGraphSorts() {
+  checkGraphRadixSort();
+  checkGraphCounterSort();
+}
+
+int main() {
+  checkSorts();
+  checkGraphSorts();
+  return 0;
+}
Index: test/random_test.cc
===================================================================
--- test/random_test.cc	(revision 2597)
+++ test/random_test.cc	(revision 2597)
@@ -0,0 +1,43 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/random.h>
+#include "test_tools.h"
+
+///\file \brief Test cases for random.h
+///
+///\todo To be extended
+///
+
+int seed_array[] = {1, 2};
+
+int main()
+{
+  double a=rnd();
+  check(a<1.0&&a>0.0,"This should be in [0,1)");
+  a=rnd.gauss();
+  a=rnd.gamma(3.45,0);
+  a=rnd.gamma(4);
+  //Does gamma work with integer k?
+  a=rnd.gamma(4.0,0);
+
+  lemon::rnd.seed(100);
+  lemon::rnd.seed(seed_array, seed_array + 
+		  (sizeof(seed_array) / sizeof(seed_array[0])));
+  return 0;
+}
Index: test/refptr_test.cc
===================================================================
--- test/refptr_test.cc	(revision 2553)
+++ test/refptr_test.cc	(revision 2553)
@@ -0,0 +1,61 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include<lemon/refptr.h>
+#include "test_tools.h"
+#include <iostream>
+
+class Test 
+{
+  int &_counter;
+public:
+  Test(int &co) : _counter(co)
+  {
+    std::cerr << "Init\n";
+    _counter++;
+  }
+  ~Test()
+  {
+    std::cerr << "Destroy\n";
+    _counter--;
+  }
+  int &counter() { return _counter; }
+  
+};
+
+int main()
+{
+  int c=0;
+  
+  {
+    RefPtr<Test> a = new Test(c);
+    check(a->counter() == 1, "Wrong number of initialization");
+    {
+      RefPtr<Test> b = a;
+      check((*b).counter() == 1, "Wrong number of initialization");
+      b=a;
+      a=b;
+      check((*a).counter() == 1, "Wrong number of initialization");
+    }
+    check(a->counter() == 1, "Wrong number of initialization");
+  }
+  check(c == 0, "Wrong number of initialization");
+
+  return 0;
+}
+
Index: test/simann_test.cc
===================================================================
--- test/simann_test.cc	(revision 2553)
+++ test/simann_test.cc	(revision 2553)
@@ -0,0 +1,60 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/simann.h>
+
+using namespace lemon;
+
+class MyEntity : public EntityBase {
+public:
+  double d, prev_d;
+  MyEntity() : d(100000.0) {}
+  double mutate() {
+    prev_d = d;
+    if (rnd.boolean(0.8)) { d += 1.0; }
+    else { d -= 1.0; }
+    return d;
+  }
+  void revert() { d = prev_d; }
+  MyEntity* clone() { return new MyEntity (*this); }
+  void randomize() {}
+};
+
+int main() {
+  SimAnn simann;
+  SimpleController ctrl;
+  simann.setController(ctrl);
+  MyEntity ent;
+  simann.setEntity(ent);
+  simann.run();
+
+  //MyEntity *best_ent = (MyEntity *) simann.getBestEntity();
+  //std::cout << best_ent->d << std::endl;
+
+  SimAnn simann2;
+  AdvancedController ctrl2(2.0);
+  simann2.setController(ctrl2);
+  MyEntity ent2;
+  simann2.setEntity(ent2);
+  simann2.run();
+
+  //MyEntity *best_ent2 = (MyEntity *) simann2.getBestEntity();
+  //std::cout << best_ent2->d << std::endl;
+
+  return 0;
+}
Index: test/suurballe_test.cc
===================================================================
--- test/suurballe_test.cc	(revision 2586)
+++ test/suurballe_test.cc	(revision 2586)
@@ -0,0 +1,160 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+#include <fstream>
+
+#include <lemon/list_graph.h>
+#include <lemon/graph_reader.h>
+#include <lemon/path.h>
+#include <lemon/suurballe.h>
+
+#include "test_tools.h"
+
+using namespace lemon;
+
+// Checks the feasibility of the flow
+template <typename Graph, typename FlowMap>
+bool checkFlow( const Graph& gr, const FlowMap& flow, 
+                typename Graph::Node s, typename Graph::Node t,
+                int value )
+{
+  GRAPH_TYPEDEFS(typename Graph);
+  for (EdgeIt e(gr); e != INVALID; ++e)
+    if (!(flow[e] == 0 || flow[e] == 1)) return false;
+
+  for (NodeIt n(gr); n != INVALID; ++n) {
+    int sum = 0;
+    for (OutEdgeIt e(gr, n); e != INVALID; ++e)
+      sum += flow[e];
+    for (InEdgeIt e(gr, n); e != INVALID; ++e)
+      sum -= flow[e];
+    if (n == s && sum != value) return false;
+    if (n == t && sum != -value) return false;
+    if (n != s && n != t && sum != 0) return false;
+  }
+
+  return true;
+}
+
+// Checks the optimalitiy of the flow
+template < typename Graph, typename CostMap, 
+           typename FlowMap, typename PotentialMap >
+bool checkOptimality( const Graph& gr, const CostMap& cost,
+                      const FlowMap& flow, const PotentialMap& pi )
+{
+  // Checking the Complementary Slackness optimality condition
+  GRAPH_TYPEDEFS(typename Graph);
+  bool opt = true;
+  for (EdgeIt e(gr); e != INVALID; ++e) {
+    typename CostMap::Value red_cost =
+      cost[e] + pi[gr.source(e)] - pi[gr.target(e)];
+    opt = (flow[e] == 0 && red_cost >= 0) ||
+          (flow[e] == 1 && red_cost <= 0);
+    if (!opt) break;
+  }
+  return opt;
+}
+
+// Checks a path
+template < typename Graph, typename Path >
+bool checkPath( const Graph& gr, const Path& path,
+                typename Graph::Node s, typename Graph::Node t)
+{
+  // Checking the Complementary Slackness optimality condition
+  GRAPH_TYPEDEFS(typename Graph);
+  Node n = s;
+  for (int i = 0; i < path.length(); ++i) {
+    if (gr.source(path.nth(i)) != n) return false;
+    n = gr.target(path.nth(i));
+  }
+  return n == t;
+}
+
+
+int main()
+{
+  GRAPH_TYPEDEFS(ListGraph);
+
+  // Reading the test graph
+  ListGraph graph;
+  ListGraph::EdgeMap<int> length(graph);
+  Node source, target;
+
+  std::string fname;
+  if(getenv("srcdir"))
+    fname = std::string(getenv("srcdir"));
+  else fname = ".";
+  fname += "/test/min_cost_flow_test.lgf";
+
+  std::ifstream input(fname.c_str());
+  check(input, "Input file '" << fname << "' not found");
+  GraphReader<ListGraph>(input, graph).
+    readEdgeMap("cost", length).
+    readNode("source", source).
+    readNode("target", target).
+    run();
+  input.close();
+  
+  // Finding 2 paths
+  {
+    Suurballe<ListGraph> suurballe(graph, length, source, target);
+    check(suurballe.run(2) == 2, "Wrong number of paths");
+    check(checkFlow(graph, suurballe.flowMap(), source, target, 2),
+          "The flow is not feasible");
+    check(suurballe.totalLength() == 510, "The flow is not optimal");
+    check(checkOptimality(graph, length, suurballe.flowMap(), 
+                          suurballe.potentialMap()),
+          "Wrong potentials");
+    for (int i = 0; i < suurballe.pathNum(); ++i)
+      check(checkPath(graph, suurballe.path(i), source, target),
+            "Wrong path");
+  }
+
+  // Finding 3 paths
+  {
+    Suurballe<ListGraph> suurballe(graph, length, source, target);
+    check(suurballe.run(3) == 3, "Wrong number of paths");
+    check(checkFlow(graph, suurballe.flowMap(), source, target, 3),
+          "The flow is not feasible");
+    check(suurballe.totalLength() == 1040, "The flow is not optimal");
+    check(checkOptimality(graph, length, suurballe.flowMap(), 
+                          suurballe.potentialMap()),
+          "Wrong potentials");
+    for (int i = 0; i < suurballe.pathNum(); ++i)
+      check(checkPath(graph, suurballe.path(i), source, target),
+            "Wrong path");
+  }
+
+  // Finding 5 paths (only 3 can be found)
+  {
+    Suurballe<ListGraph> suurballe(graph, length, source, target);
+    check(suurballe.run(5) == 3, "Wrong number of paths");
+    check(checkFlow(graph, suurballe.flowMap(), source, target, 3),
+          "The flow is not feasible");
+    check(suurballe.totalLength() == 1040, "The flow is not optimal");
+    check(checkOptimality(graph, length, suurballe.flowMap(), 
+                          suurballe.potentialMap()),
+          "Wrong potentials");
+    for (int i = 0; i < suurballe.pathNum(); ++i)
+      check(checkPath(graph, suurballe.path(i), source, target),
+            "Wrong path");
+  }
+
+  return 0;
+}
Index: test/test_tools.h
===================================================================
--- test/test_tools.h	(revision 2553)
+++ test/test_tools.h	(revision 2553)
@@ -0,0 +1,181 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#ifndef LEMON_TEST_TEST_TOOLS_H
+#define LEMON_TEST_TEST_TOOLS_H
+
+#include <iostream>
+#include <vector>
+
+#include <cstdlib>
+#include <ctime>
+
+#include <lemon/concept_check.h>
+#include <lemon/concepts/graph.h>
+
+#include <lemon/random.h>
+
+using namespace lemon;
+
+//! \ingroup misc
+//! \file
+//! \brief Some utilities to write test programs.
+
+
+///If \c rc is fail, writes an error message end exit.
+
+///If \c rc is fail, writes an error message end exit.
+///The error message contains the file name and the line number of the
+///source code in a standard from, which makes it possible to go there
+///using good source browsers like e.g. \c emacs.
+///
+///For example
+///\code check(0==1,"This is obviously false.");\endcode will
+///print this (and then exits).
+///\verbatim graph_test.cc:123: error: This is obviously false. \endverbatim
+///
+///\todo It should be in \c error.h
+#define check(rc, msg) \
+  if(!(rc)) { \
+    std::cerr << __FILE__ ":" << __LINE__ << ": error: " << msg << std::endl; \
+    abort(); \
+  } else { } \
+
+///Structure returned by \ref addPetersen().
+
+///Structure returned by \ref addPetersen().
+///
+template<class Graph> struct PetStruct
+{
+  ///Vector containing the outer nodes.
+  std::vector<typename Graph::Node> outer;
+  ///Vector containing the inner nodes.
+  std::vector<typename Graph::Node> inner;
+  ///Vector containing the edges of the inner circle.
+  std::vector<typename Graph::Edge> incir;
+  ///Vector containing the edges of the outer circle.
+  std::vector<typename Graph::Edge> outcir;
+  ///Vector containing the chord edges.
+  std::vector<typename Graph::Edge> chords;
+};
+
+
+
+///Adds a Petersen graph to \c G.
+
+///Adds a Petersen graph to \c G.
+///\return The nodes and edges of the generated graph.
+
+template<typename Graph>
+PetStruct<Graph> addPetersen(Graph &G,int num = 5)
+{
+  PetStruct<Graph> n;
+
+  for(int i=0;i<num;i++) {
+    n.outer.push_back(G.addNode());
+    n.inner.push_back(G.addNode());
+  }
+
+ for(int i=0;i<num;i++) {
+   n.chords.push_back(G.addEdge(n.outer[i],n.inner[i]));
+   n.outcir.push_back(G.addEdge(n.outer[i],n.outer[(i+1) % num]));
+   n.incir.push_back(G.addEdge(n.inner[i],n.inner[(i+2) % num]));
+  }
+ return n;
+}
+
+/// \brief Adds to the graph the reverse pair of all edges.
+///
+/// Adds to the graph the reverse pair of all edges.
+///
+template<class Graph> void bidirGraph(Graph &G)
+{
+  typedef typename Graph::Edge Edge;
+  typedef typename Graph::EdgeIt EdgeIt;
+  
+  std::vector<Edge> ee;
+  
+  for(EdgeIt e(G);e!=INVALID;++e) ee.push_back(e);
+
+  for(typename std::vector<Edge>::iterator p=ee.begin();p!=ee.end();p++)
+    G.addEdge(G.target(*p),G.source(*p));
+}
+
+
+/// \brief Checks the bidirectioned Petersen graph.
+///
+///  Checks the bidirectioned Petersen graph.
+///
+template<class Graph> void checkBidirPetersen(Graph &G, int num = 5)
+{
+  typedef typename Graph::Node Node;
+
+  typedef typename Graph::EdgeIt EdgeIt;
+  typedef typename Graph::NodeIt NodeIt;
+
+  checkGraphNodeList(G, 2 * num);
+  checkGraphEdgeList(G, 6 * num);
+
+  for(NodeIt n(G);n!=INVALID;++n) {
+    checkGraphInEdgeList(G, n, 3);
+    checkGraphOutEdgeList(G, n, 3);
+  }  
+}
+
+///Structure returned by \ref addUPetersen().
+
+///Structure returned by \ref addUPetersen().
+///
+template<class Graph> struct UPetStruct
+{
+  ///Vector containing the outer nodes.
+  std::vector<typename Graph::Node> outer;
+  ///Vector containing the inner nodes.
+  std::vector<typename Graph::Node> inner;
+  ///Vector containing the edges of the inner circle.
+  std::vector<typename Graph::UEdge> incir;
+  ///Vector containing the edges of the outer circle.
+  std::vector<typename Graph::UEdge> outcir;
+  ///Vector containing the chord edges.
+  std::vector<typename Graph::UEdge> chords;
+};
+
+///Adds a Petersen graph to the undirected \c G.
+
+///Adds a Petersen graph to the undirected \c G.
+///\return The nodes and edges of the generated graph.
+
+template<typename Graph>
+UPetStruct<Graph> addUPetersen(Graph &G,int num=5)
+{
+  UPetStruct<Graph> n;
+
+  for(int i=0;i<num;i++) {
+    n.outer.push_back(G.addNode());
+    n.inner.push_back(G.addNode());
+  }
+
+ for(int i=0;i<num;i++) {
+   n.chords.push_back(G.addEdge(n.outer[i],n.inner[i]));
+   n.outcir.push_back(G.addEdge(n.outer[i],n.outer[(i+1)%5]));
+   n.incir.push_back(G.addEdge(n.inner[i],n.inner[(i+2)%5]));
+ }
+ return n;
+}
+
+#endif
Index: test/test_tools_fail.cc
===================================================================
--- test/test_tools_fail.cc	(revision 2553)
+++ test/test_tools_fail.cc	(revision 2553)
@@ -0,0 +1,25 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include "test_tools.h"
+
+int main() 
+{
+  check(false, "Don't panic. Failing is the right behaviour here.");
+  return 0;
+}
Index: test/test_tools_pass.cc
===================================================================
--- test/test_tools_pass.cc	(revision 2553)
+++ test/test_tools_pass.cc	(revision 2553)
@@ -0,0 +1,25 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include "test_tools.h"
+
+int main() 
+{
+  check(true, "It should pass.");
+  return 0;
+}
Index: test/time_measure_test.cc
===================================================================
--- test/time_measure_test.cc	(revision 2553)
+++ test/time_measure_test.cc	(revision 2553)
@@ -0,0 +1,63 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/time_measure.h>
+
+///\file \brief Test cases for time_measure.h
+///
+///\todo To be extended
+
+
+using namespace lemon;
+
+void f() 
+{
+  double d=0;
+  for(int i=0;i<1000;i++)
+    d+=0.1;
+}
+
+void g() 
+{
+  static Timer T;
+  
+  for(int i=0;i<1000;i++)
+    TimeStamp x(T);
+}
+
+int main()
+{
+  Timer T;
+  unsigned int n;
+  for(n=0;T.realTime()<1.0;n++) ;
+  std::cout << T << " (" << n << " time queries)\n";
+  T.restart();
+  while(T.realTime()<2.0) ;
+  std::cout << T << '\n';
+  TimeStamp full;
+  TimeStamp t;
+  t=runningTimeTest(f,1,&n,&full);
+  std::cout << t << " (" << n << " tests)\n";
+  std::cout << "Total: " << full << "\n";
+  
+  t=runningTimeTest(g,1,&n,&full);
+  std::cout << t << " (" << n << " tests)\n";
+  std::cout << "Total: " << full << "\n";
+  
+  return 0;
+}
Index: test/ugraph_test.cc
===================================================================
--- test/ugraph_test.cc	(revision 2553)
+++ test/ugraph_test.cc	(revision 2553)
@@ -0,0 +1,212 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <lemon/bits/graph_extender.h>
+#include <lemon/concepts/ugraph.h>
+#include <lemon/list_graph.h>
+#include <lemon/smart_graph.h>
+#include <lemon/full_graph.h>
+#include <lemon/grid_ugraph.h>
+
+#include <lemon/graph_utils.h>
+
+#include "test_tools.h"
+
+
+using namespace lemon;
+using namespace lemon::concepts;
+
+void check_concepts() {
+
+  { // checking graph components
+    checkConcept<BaseUGraphComponent, BaseUGraphComponent >();
+
+    checkConcept<IDableUGraphComponent<>, 
+      IDableUGraphComponent<> >();
+
+    checkConcept<IterableUGraphComponent<>, 
+      IterableUGraphComponent<> >();
+
+    checkConcept<MappableUGraphComponent<>, 
+      MappableUGraphComponent<> >();
+
+  }
+  {
+    checkConcept<UGraph, ListUGraph>();
+    
+    checkConcept<UGraph, SmartUGraph>();
+    
+    checkConcept<UGraph, FullUGraph>();
+    
+    checkConcept<UGraph, UGraph>();
+    
+    checkConcept<UGraph, GridUGraph>();
+  }
+}
+
+template <typename Graph>
+void check_item_counts(Graph &g, int n, int e) {
+  int nn = 0;
+  for (typename Graph::NodeIt it(g); it != INVALID; ++it) {
+    ++nn;
+  }
+
+  check(nn == n, "Wrong node number.");
+  check(countNodes(g) == n, "Wrong node number.");
+
+  int ee = 0;
+  for (typename Graph::EdgeIt it(g); it != INVALID; ++it) {
+    ++ee;
+  }
+
+  check(ee == 2*e, "Wrong edge number.");
+  check(countEdges(g) == 2*e, "Wrong edge number.");
+
+  int uee = 0;
+  for (typename Graph::UEdgeIt it(g); it != INVALID; ++it) {
+    ++uee;
+  }
+
+  check(uee == e, "Wrong uedge number.");
+  check(countUEdges(g) == e, "Wrong uedge number.");
+}
+
+template <typename Graph>
+void print_items(Graph &g) {
+
+  typedef typename Graph::NodeIt NodeIt;
+  typedef typename Graph::UEdgeIt UEdgeIt;
+  typedef typename Graph::EdgeIt EdgeIt;
+
+  std::cout << "Nodes" << std::endl;
+  int i=0;
+  for(NodeIt it(g); it!=INVALID; ++it, ++i) {
+    std::cout << "  " << i << ": " << g.id(it) << std::endl;
+  }
+
+  std::cout << "UEdge" << std::endl;
+  i=0;
+  for(UEdgeIt it(g); it!=INVALID; ++it, ++i) {
+    std::cout << "  " << i << ": " << g.id(it) 
+	 << " (" << g.id(g.source(it)) << ", " << g.id(g.target(it)) 
+	 << ")" << std::endl;
+  }
+
+  std::cout << "Edge" << std::endl;
+  i=0;
+  for(EdgeIt it(g); it!=INVALID; ++it, ++i) {
+    std::cout << "  " << i << ": " << g.id(it)
+	 << " (" << g.id(g.source(it)) << ", " << g.id(g.target(it)) 
+	 << ")" << std::endl;
+  }
+
+}
+
+template <typename Graph>
+void check_graph() {
+
+  typedef typename Graph::Node Node;
+  typedef typename Graph::UEdge UEdge;
+  typedef typename Graph::Edge Edge;
+  typedef typename Graph::NodeIt NodeIt;
+  typedef typename Graph::UEdgeIt UEdgeIt;
+  typedef typename Graph::EdgeIt EdgeIt;
+
+  Graph g;
+
+  check_item_counts(g,0,0);
+
+  Node
+    n1 = g.addNode(),
+    n2 = g.addNode(),
+    n3 = g.addNode();
+
+  UEdge
+    e1 = g.addEdge(n1, n2),
+    e2 = g.addEdge(n2, n3);
+
+  // print_items(g);
+
+  check_item_counts(g,3,2);
+}
+
+void checkGridUGraph(const GridUGraph& g, int w, int h) {
+  check(g.width() == w, "Wrong width");
+  check(g.height() == h, "Wrong height");
+
+  for (int i = 0; i < w; ++i) {
+    for (int j = 0; j < h; ++j) {
+      check(g.col(g(i, j)) == i, "Wrong col");
+      check(g.row(g(i, j)) == j, "Wrong row");
+    }
+  }
+  
+  for (int i = 0; i < w; ++i) {
+    for (int j = 0; j < h - 1; ++j) {
+      check(g.source(g.down(g(i, j))) == g(i, j), "Wrong down");
+      check(g.target(g.down(g(i, j))) == g(i, j + 1), "Wrong down");
+    }
+    check(g.down(g(i, h - 1)) == INVALID, "Wrong down");
+  }
+
+  for (int i = 0; i < w; ++i) {
+    for (int j = 1; j < h; ++j) {
+      check(g.source(g.up(g(i, j))) == g(i, j), "Wrong up");
+      check(g.target(g.up(g(i, j))) == g(i, j - 1), "Wrong up");
+    }
+    check(g.up(g(i, 0)) == INVALID, "Wrong up");
+  }
+
+  for (int j = 0; j < h; ++j) {
+    for (int i = 0; i < w - 1; ++i) {
+      check(g.source(g.right(g(i, j))) == g(i, j), "Wrong right");
+      check(g.target(g.right(g(i, j))) == g(i + 1, j), "Wrong right");      
+    }
+    check(g.right(g(w - 1, j)) == INVALID, "Wrong right");    
+  }
+
+  for (int j = 0; j < h; ++j) {
+    for (int i = 1; i < w; ++i) {
+      check(g.source(g.left(g(i, j))) == g(i, j), "Wrong left");
+      check(g.target(g.left(g(i, j))) == g(i - 1, j), "Wrong left");      
+    }
+    check(g.left(g(0, j)) == INVALID, "Wrong left");    
+  }
+}
+
+int main() {
+  check_concepts();
+
+  check_graph<ListUGraph>();
+  check_graph<SmartUGraph>();
+
+  {
+    FullUGraph g(5);
+    check_item_counts(g, 5, 10);
+  }
+
+  {
+    GridUGraph g(5, 6);
+    check_item_counts(g, 30, 49);
+    checkGridUGraph(g, 5, 6);
+  }
+
+  std::cout << __FILE__ ": All tests passed.\n";
+
+  return 0;
+}
Index: test/unionfind_test.cc
===================================================================
--- test/unionfind_test.cc	(revision 2553)
+++ test/unionfind_test.cc	(revision 2553)
@@ -0,0 +1,114 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+#include <iostream>
+
+#include <lemon/maps.h>
+#include <lemon/unionfind.h>
+#include "test_tools.h"
+
+using namespace lemon;
+using namespace std;
+
+typedef UnionFindEnum<StdMap<int, int> > UFE;
+
+void print(UFE const &ufe) {
+  cout << "Print the classes of the structure:" << endl;
+  int i = 1;
+  for (UFE::ClassIt cit(ufe); cit != INVALID; ++cit) {
+    cout << "  " << i << " (" << cit << "):" << flush;
+    for (UFE::ItemIt iit(ufe, cit); iit != INVALID; ++iit) {
+      cout << " " << iit << flush;
+    }
+    cout << endl;
+    i++;
+  }
+  cout << "done" << endl;
+}
+
+
+int main() {
+  StdMap<int, int> base;
+  UFE U(base);
+
+  U.insert(1);
+  U.insert(2);
+
+  check(U.join(1,2) != -1,"Test failed.");
+
+  U.insert(3);
+  U.insert(4);
+  U.insert(5);
+  U.insert(6);
+  U.insert(7);
+
+
+  check(U.join(1,4) != -1,"Test failed.");
+  check(U.join(2,4) == -1,"Test failed.");
+  check(U.join(3,5) != -1,"Test failed.");
+
+
+  U.insert(8,U.find(5));
+
+
+  check(U.size(U.find(4)) == 3,"Test failed.");
+  check(U.size(U.find(5)) == 3,"Test failed.");
+  check(U.size(U.find(6)) == 1,"Test failed.");
+  check(U.size(U.find(2)) == 3,"Test failed.");
+
+
+  U.insert(9);
+  U.insert(10,U.find(9));
+
+
+  check(U.join(8,10) != -1,"Test failed.");
+
+
+  check(U.size(U.find(4)) == 3,"Test failed.");
+  check(U.size(U.find(9)) == 5,"Test failed.");
+
+  check(U.size(U.find(8)) == 5,"Test failed.");
+
+  U.erase(9);
+  U.erase(1);
+
+  check(U.size(U.find(10)) == 4,"Test failed.");
+  check(U.size(U.find(2)) == 2,"Test failed.");
+
+  U.erase(6);
+  U.split(U.find(8));
+
+
+  check(U.size(U.find(4)) == 2,"Test failed.");
+  check(U.size(U.find(3)) == 1,"Test failed.");
+  check(U.size(U.find(2)) == 2,"Test failed.");
+
+
+  check(U.join(3,4) != -1,"Test failed.");
+  check(U.join(2,4) == -1,"Test failed.");
+
+
+  check(U.size(U.find(4)) == 3,"Test failed.");
+  check(U.size(U.find(3)) == 3,"Test failed.");
+  check(U.size(U.find(2)) == 3,"Test failed.");
+
+  U.eraseClass(U.find(4));
+  U.eraseClass(U.find(7));
+
+  return 0;
+}
Index: tools/Makefile
===================================================================
--- tools/Makefile	(revision 2390)
+++ tools/Makefile	(revision 2390)
@@ -0,0 +1,2 @@
+all:
+	$(MAKE) -C ..
Index: tools/Makefile.am
===================================================================
--- tools/Makefile.am	(revision 2404)
+++ tools/Makefile.am	(revision 2404)
@@ -0,0 +1,15 @@
+EXTRA_DIST += \
+	tools/Makefile
+
+	
+if WANT_TOOLS
+
+bin_PROGRAMS += \
+	tools/dim_to_lgf \
+	tools/lgf-gen
+
+endif WANT_TOOLS
+
+tools_lgf_gen_SOURCES = tools/lgf-gen.cc
+
+tools_dim_to_lgf_SOURCES = tools/dim_to_lgf.cc
Index: tools/dim_to_lgf.cc
===================================================================
--- tools/dim_to_lgf.cc	(revision 2553)
+++ tools/dim_to_lgf.cc	(revision 2553)
@@ -0,0 +1,188 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup tools
+///\file
+///\brief DIMACS to LGF converter.
+///
+/// This program converts various DIMACS formats to the LEMON Graph Format
+/// (LGF).
+///
+///\verbatim
+///Usage:
+///  ./tools/dim_to_lgf
+///     --mincostflow|-mcf|--maxflow|-mf|--shortestpath|-sp|--capacitated|-cap|--plain|-pl
+///     [--help|-h|-help] [--input|-i str] [--output|-o str] [--version|-v]
+///Where:
+///  --capacitated|-cap
+///     set the type of the graph to "capacitated" graph
+///  --help|-h|-help
+///     Print a short help message
+///  --input|-i str
+///     use FILE as input instead of standard input
+///  --maxflow|-mf
+///     set the type of the graph to "maxflow" graph
+///  --mincostflow|-mcf
+///     set the type of the graph to "mincostflow" graph
+///  --output|-o str
+///     use FILE as output instead of standard output
+///  --plain|-pl
+///     set the type of the graph to "plain" graph
+///  --shortestpath|-sp
+///     set the type of the graph to "shortestpath" graph
+///  --version|-v
+///     show version information
+///\endverbatim
+///
+
+#include <iostream>
+#include <fstream>
+#include <cstring>
+
+#include <lemon/smart_graph.h>
+#include <lemon/dimacs.h>
+#include <lemon/graph_writer.h>
+
+#include <lemon/arg_parser.h>
+
+using namespace std;
+using namespace lemon;
+
+
+int main(int argc, const char *argv[]) {
+  typedef SmartGraph Graph;
+
+  typedef Graph::Edge Edge;
+  typedef Graph::Node Node;
+  typedef Graph::EdgeIt EdgeIt;
+  typedef Graph::NodeIt NodeIt;
+  typedef Graph::EdgeMap<double> DoubleEdgeMap;
+  typedef Graph::NodeMap<double> DoubleNodeMap;
+
+  std::string inputName;
+  std::string outputName;
+  std::string typeName;
+
+  bool mincostflow;
+  bool maxflow;
+  bool shortestpath;
+  bool capacitated;
+  bool plain;
+
+  bool version;
+
+  ArgParser ap(argc, argv);
+  ap.refOption("-input", 
+               "use FILE as input instead of standard input", 
+               inputName).synonym("i", "-input")
+    .refOption("-output", 
+               "use FILE as output instead of standard output", 
+               outputName).synonym("o", "-output")
+    .refOption("-mincostflow", 
+               "set the type of the graph to \"mincostflow\" graph", 
+               mincostflow)
+    .optionGroup("type", "-mincostflow").synonym("mcf", "-mincostflow")
+    .refOption("-maxflow", 
+               "set the type of the graph to \"maxflow\" graph", 
+               maxflow)
+    .optionGroup("type", "-maxflow").synonym("mf", "-maxflow")
+    .refOption("-shortestpath", 
+               "set the type of the graph to \"shortestpath\" graph", 
+               shortestpath)
+    .optionGroup("type", "-shortestpath").synonym("sp", "-shortestpath")
+    .refOption("-capacitated", 
+               "set the type of the graph to \"capacitated\" graph", 
+               capacitated)
+    .optionGroup("type", "-capacitated").synonym("cap", "-capacitated")
+    .refOption("-plain", 
+               "set the type of the graph to \"plain\" graph", 
+               plain)
+    .optionGroup("type", "-plain").synonym("pl", "-plain")
+    .onlyOneGroup("type")
+    .mandatoryGroup("type")
+    .refOption("-version", "show version information", version)
+    .synonym("v", "-version")
+    .run();
+
+  ifstream input;
+  if (!inputName.empty()) {
+    input.open(inputName.c_str());
+    if (!input) {
+      cerr << "File open error" << endl;
+      return -1;
+    }
+  }
+  istream& is = (inputName.empty() ? cin : input);
+
+  ofstream output;
+  if (!outputName.empty()) {
+    output.open(outputName.c_str());
+    if (!output) {
+      cerr << "File open error" << endl;
+      return -1;
+    }
+  }
+  ostream& os = (outputName.empty() ? cout : output);
+
+  if (mincostflow) {
+    Graph graph;
+    DoubleEdgeMap lower(graph), capacity(graph), cost(graph);
+    DoubleNodeMap supply(graph);
+    readDimacs(is, graph, lower, capacity, cost, supply);
+    GraphWriter<Graph>(os, graph).
+      writeNodeMap("supply", supply).
+      writeEdgeMap("lower", lower).
+      writeEdgeMap("capacity", capacity).
+      writeEdgeMap("cost", cost).
+      run();
+  } else if (maxflow) {
+    Graph graph;
+    Node s, t;
+    DoubleEdgeMap capacity(graph);
+    readDimacs(is, graph, capacity, s, t);
+    GraphWriter<Graph>(os, graph).
+      writeEdgeMap("capacity", capacity).
+      writeNode("source", s).
+      writeNode("target", t).
+      run();
+  } else if (shortestpath) {
+    Graph graph;
+    Node s;
+    DoubleEdgeMap capacity(graph);
+    readDimacs(is, graph, capacity, s);
+    GraphWriter<Graph>(os, graph).
+      writeEdgeMap("capacity", capacity).
+      writeNode("source", s).
+      run();
+  } else if (capacitated) {
+    Graph graph;
+    DoubleEdgeMap capacity(graph);
+    readDimacs(is, graph, capacity);
+    GraphWriter<Graph>(os, graph).
+      writeEdgeMap("capacity", capacity).
+      run();
+  } else if (plain) {
+    Graph graph;
+    readDimacs(is, graph);
+    GraphWriter<Graph>(os, graph).run();
+  } else {
+    cerr << "Invalid type error" << endl;
+    return -1;
+  }
+  return 0;
+}
Index: tools/lgf-gen.cc
===================================================================
--- tools/lgf-gen.cc	(revision 2618)
+++ tools/lgf-gen.cc	(revision 2618)
@@ -0,0 +1,874 @@
+/* -*- C++ -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library
+ *
+ * Copyright (C) 2003-2008
+ * 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.
+ *
+ */
+
+///\ingroup tools
+///\file
+///\brief Special plane graph generator.
+///
+///Graph generator application for various types of plane graphs.
+///
+///\verbatim
+/// Usage:
+///   ./tools/lgf-gen [-2con|-tree|-tsp|-tsp2|-dela] [-disc|-square|-gauss]
+///      [-rand|-seed int] [--help|-h|-help] [-area num] [-cities int] [-dir]
+///      [-eps] [-g int] [-n int] [prefix]
+/// Where:
+///   [prefix]
+///      Prefix of the output files. Default is 'lgf-gen-out'
+///   --help|-h|-help
+///      Print a short help message
+///   -2con
+///      Create a two connected planar graph
+///   -area num
+///      Full relative area of the cities (default is 1)
+///   -cities int
+///      Number of cities (default is 1)
+///   -dela
+///      Delaunay triangulation graph
+///   -dir
+///      Directed graph is generated (each edges are replaced by two directed ones)
+///   -disc
+///      Nodes are evenly distributed on a unit disc (default)
+///   -eps
+///      Also generate .eps output (prefix.eps)
+///   -g int
+///      Girth parameter (default is 10)
+///   -gauss
+///      Nodes are located according to a two-dim gauss distribution
+///   -n int
+///      Number of nodes (default is 100)
+///   -rand
+///      Use time seed for random number generator
+///   -seed int
+///      Random seed
+///   -square
+///      Nodes are evenly distributed on a unit square
+///   -tree
+///      Create a min. cost spanning tree
+///   -tsp
+///      Create a TSP tour
+///   -tsp2
+///      Create a TSP tour (tree based)
+///\endverbatim
+/// \image html plane_tree.png
+/// \image latex plane_tree.eps "Eucledian spanning tree" width=\textwidth
+///
+
+
+#include <lemon/list_graph.h>
+#include <lemon/graph_utils.h>
+#include <lemon/random.h>
+#include <lemon/dim2.h>
+#include <lemon/bfs.h>
+#include <lemon/counter.h>
+#include <lemon/suurballe.h>
+#include <lemon/graph_to_eps.h>
+#include <lemon/graph_writer.h>
+#include <lemon/arg_parser.h>
+#include <lemon/euler.h>
+#include <lemon/math.h>
+#include <algorithm>
+#include <lemon/kruskal.h>
+#include <lemon/time_measure.h>
+
+using namespace lemon;
+
+typedef dim2::Point<double> Point;
+
+UGRAPH_TYPEDEFS(ListUGraph);
+
+bool progress=true;
+
+int N;
+// int girth;
+
+ListUGraph g;
+
+std::vector<Node> nodes;
+ListUGraph::NodeMap<Point> coords(g);
+
+
+double totalLen(){
+  double tlen=0;
+  for(UEdgeIt e(g);e!=INVALID;++e)
+    tlen+=sqrt((coords[g.source(e)]-coords[g.target(e)]).normSquare());
+  return tlen;
+}
+
+int tsp_impr_num=0;
+
+const double EPSILON=1e-8; 
+bool tsp_improve(Node u, Node v)
+{
+  double luv=std::sqrt((coords[v]-coords[u]).normSquare());
+  Node u2=u;
+  Node v2=v;
+  do {
+    Node n;
+    for(IncEdgeIt e(g,v2);(n=g.runningNode(e))==u2;++e) { }
+    u2=v2;
+    v2=n;
+    if(luv+std::sqrt((coords[v2]-coords[u2]).normSquare())-EPSILON>
+       std::sqrt((coords[u]-coords[u2]).normSquare())+
+       std::sqrt((coords[v]-coords[v2]).normSquare()))
+      {
+ 	g.erase(findUEdge(g,u,v));
+ 	g.erase(findUEdge(g,u2,v2));
+	g.addEdge(u2,u);
+	g.addEdge(v,v2);
+	tsp_impr_num++;
+	return true;
+      }
+  } while(v2!=u);
+  return false;
+}
+
+bool tsp_improve(Node u)
+{
+  for(IncEdgeIt e(g,u);e!=INVALID;++e)
+    if(tsp_improve(u,g.runningNode(e))) return true;
+  return false;
+}
+
+void tsp_improve()
+{
+  bool b;
+  do {
+    b=false;
+    for(NodeIt n(g);n!=INVALID;++n)
+      if(tsp_improve(n)) b=true;
+  } while(b);
+}
+
+void tsp()
+{
+  for(int i=0;i<N;i++) g.addEdge(nodes[i],nodes[(i+1)%N]);
+  tsp_improve();
+}
+
+class Line
+{
+public:
+  Point a;
+  Point b;
+  Line(Point _a,Point _b) :a(_a),b(_b) {}
+  Line(Node _a,Node _b) : a(coords[_a]),b(coords[_b]) {}
+  Line(const Edge &e) : a(coords[g.source(e)]),b(coords[g.target(e)]) {}
+  Line(const UEdge &e) : a(coords[g.source(e)]),b(coords[g.target(e)]) {}
+};
+  
+inline std::ostream& operator<<(std::ostream &os, const Line &l)
+{
+  os << l.a << "->" << l.b;
+  return os;
+}
+
+bool cross(Line a, Line b) 
+{
+  Point ao=rot90(a.b-a.a);
+  Point bo=rot90(b.b-b.a);
+  return (ao*(b.a-a.a))*(ao*(b.b-a.a))<0 &&
+    (bo*(a.a-b.a))*(bo*(a.b-b.a))<0;
+}
+
+struct Pedge
+{
+  Node a;
+  Node b;
+  double len;
+};
+
+bool pedgeLess(Pedge a,Pedge b)
+{
+  return a.len<b.len;
+}
+
+std::vector<UEdge> edges;
+
+namespace _delaunay_bits {
+
+  struct Part {
+    int prev, curr, next;
+
+    Part(int p, int c, int n) : prev(p), curr(c), next(n) {} 
+  };
+
+  inline std::ostream& operator<<(std::ostream& os, const Part& part) {
+    os << '(' << part.prev << ',' << part.curr << ',' << part.next << ')';
+    return os;
+  }
+
+  inline double circle_point(const Point& p, const Point& q, const Point& r) {
+    double a = p.x * (q.y - r.y) + q.x * (r.y - p.y) + r.x * (p.y - q.y);
+    if (a == 0) return std::numeric_limits<double>::quiet_NaN();
+
+    double d = (p.x * p.x + p.y * p.y) * (q.y - r.y) +
+      (q.x * q.x + q.y * q.y) * (r.y - p.y) +
+      (r.x * r.x + r.y * r.y) * (p.y - q.y);
+
+    double e = (p.x * p.x + p.y * p.y) * (q.x - r.x) +
+      (q.x * q.x + q.y * q.y) * (r.x - p.x) +
+      (r.x * r.x + r.y * r.y) * (p.x - q.x);
+
+    double f = (p.x * p.x + p.y * p.y) * (q.x * r.y - r.x * q.y) +
+      (q.x * q.x + q.y * q.y) * (r.x * p.y - p.x * r.y) +
+      (r.x * r.x + r.y * r.y) * (p.x * q.y - q.x * p.y);
+
+    return d / (2 * a) + sqrt((d * d + e * e) / (4 * a * a) + f / a);
+  }
+
+  inline bool circle_form(const Point& p, const Point& q, const Point& r) {
+    return rot90(q - p) * (r - q) < 0.0;
+  }
+
+  inline double intersection(const Point& p, const Point& q, double sx) {
+    const double epsilon = 1e-8;
+
+    if (p.x == q.x) return (p.y + q.y) / 2.0;
+
+    if (sx < p.x + epsilon) return p.y;
+    if (sx < q.x + epsilon) return q.y;
+    
+    double a = q.x - p.x;
+    double b = (q.x - sx) * p.y - (p.x - sx) * q.y;    
+    double d = (q.x - sx) * (p.x - sx) * (p - q).normSquare();
+    return (b - sqrt(d)) / a;
+  }
+
+  struct YLess {
+
+
+    YLess(const std::vector<Point>& points, double& sweep) 
+      : _points(points), _sweep(sweep) {}
+
+    bool operator()(const Part& l, const Part& r) const {
+      const double epsilon = 1e-8;
+
+      //      std::cerr << l << " vs " << r << std::endl;
+      double lbx = l.prev != -1 ?
+	intersection(_points[l.prev], _points[l.curr], _sweep) :
+	- std::numeric_limits<double>::infinity();
+      double rbx = r.prev != -1 ?
+	intersection(_points[r.prev], _points[r.curr], _sweep) :
+	- std::numeric_limits<double>::infinity();
+      double lex = l.next != -1 ?
+	intersection(_points[l.curr], _points[l.next], _sweep) :
+	std::numeric_limits<double>::infinity();
+      double rex = r.next != -1 ?
+	intersection(_points[r.curr], _points[r.next], _sweep) :
+	std::numeric_limits<double>::infinity();
+
+      if (lbx > lex) std::swap(lbx, lex);
+      if (rbx > rex) std::swap(rbx, rex);
+
+      if (lex < epsilon + rex && lbx + epsilon < rex) return true;
+      if (rex < epsilon + lex && rbx + epsilon < lex) return false;
+      return lex < rex;
+    }
+    
+    const std::vector<Point>& _points;
+    double& _sweep;
+  };
+  
+  struct BeachIt;
+  
+  typedef std::multimap<double, BeachIt> SpikeHeap;
+
+  typedef std::multimap<Part, SpikeHeap::iterator, YLess> Beach;
+
+  struct BeachIt {
+    Beach::iterator it;
+
+    BeachIt(Beach::iterator iter) : it(iter) {}
+  };
+
+}
+
+inline void delaunay() {
+  Counter cnt("Number of edges added: ");
+  
+  using namespace _delaunay_bits;
+
+  typedef _delaunay_bits::Part Part;
+  typedef std::vector<std::pair<double, int> > SiteHeap;
+
+
+  std::vector<Point> points;
+  std::vector<Node> nodes;
+
+  for (NodeIt it(g); it != INVALID; ++it) {
+    nodes.push_back(it);
+    points.push_back(coords[it]);
+  }
+
+  SiteHeap siteheap(points.size());
+
+  double sweep;
+
+
+  for (int i = 0; i < int(siteheap.size()); ++i) {
+    siteheap[i] = std::make_pair(points[i].x, i);
+  }
+  
+  std::sort(siteheap.begin(), siteheap.end());
+  sweep = siteheap.front().first;
+  
+  YLess yless(points, sweep);
+  Beach beach(yless);
+
+  SpikeHeap spikeheap;
+
+  std::set<std::pair<int, int> > edges;
+
+  int siteindex = 0;
+  {
+    SiteHeap front;
+
+    while (siteindex < int(siteheap.size()) &&
+	   siteheap[0].first == siteheap[siteindex].first) {
+      front.push_back(std::make_pair(points[siteheap[siteindex].second].y,
+				     siteheap[siteindex].second));
+      ++siteindex;
+    }
+    
+    std::sort(front.begin(), front.end());
+
+    for (int i = 0; i < int(front.size()); ++i) {
+      int prev = (i == 0 ? -1 : front[i - 1].second);
+      int curr = front[i].second;
+      int next = (i + 1 == int(front.size()) ? -1 : front[i + 1].second);
+
+      beach.insert(std::make_pair(Part(prev, curr, next), 
+				  spikeheap.end()));      
+    }
+  }
+
+  while (siteindex < int(points.size()) || !spikeheap.empty()) {
+
+    SpikeHeap::iterator spit = spikeheap.begin();
+
+    if (siteindex < int(points.size()) && 
+	(spit == spikeheap.end() || siteheap[siteindex].first < spit->first)) {
+      int site = siteheap[siteindex].second;
+      sweep = siteheap[siteindex].first;
+          
+      Beach::iterator bit = beach.upper_bound(Part(site, site, site));
+      
+      if (bit->second != spikeheap.end()) {
+	spikeheap.erase(bit->second);	
+      }
+
+      int prev = bit->first.prev;
+      int curr = bit->first.curr;
+      int next = bit->first.next;
+
+      beach.erase(bit);
+      
+      SpikeHeap::iterator pit = spikeheap.end();
+      if (prev != -1 && 
+	  circle_form(points[prev], points[curr], points[site])) {
+	double x = circle_point(points[prev], points[curr], points[site]);
+	pit = spikeheap.insert(std::make_pair(x, BeachIt(beach.end())));
+	pit->second.it =
+	  beach.insert(std::make_pair(Part(prev, curr, site), pit));
+      } else {
+	beach.insert(std::make_pair(Part(prev, curr, site), pit));
+      }
+
+      beach.insert(std::make_pair(Part(curr, site, curr), spikeheap.end()));
+      
+      SpikeHeap::iterator nit = spikeheap.end();
+      if (next != -1 && 
+	  circle_form(points[site], points[curr],points[next])) {
+	double x = circle_point(points[site], points[curr], points[next]);
+	nit = spikeheap.insert(std::make_pair(x, BeachIt(beach.end())));
+	nit->second.it =
+	  beach.insert(std::make_pair(Part(site, curr, next), nit));
+      } else {
+	beach.insert(std::make_pair(Part(site, curr, next), nit));
+      }
+      
+      ++siteindex;
+    } else {
+      sweep = spit->first;      
+
+      Beach::iterator bit = spit->second.it;
+
+      int prev = bit->first.prev;
+      int curr = bit->first.curr;
+      int next = bit->first.next;
+
+      {
+	std::pair<int, int> edge;
+
+	edge = prev < curr ? 
+	  std::make_pair(prev, curr) : std::make_pair(curr, prev);
+	
+	if (edges.find(edge) == edges.end()) {
+	  edges.insert(edge);
+	  g.addEdge(nodes[prev], nodes[curr]);
+	  ++cnt;
+	}
+
+	edge = curr < next ? 
+	  std::make_pair(curr, next) : std::make_pair(next, curr);
+	
+	if (edges.find(edge) == edges.end()) {
+	  edges.insert(edge);
+	  g.addEdge(nodes[curr], nodes[next]);
+	  ++cnt;
+	}
+      }
+      
+      Beach::iterator pbit = bit; --pbit;
+      int ppv = pbit->first.prev;
+      Beach::iterator nbit = bit; ++nbit;
+      int nnt = nbit->first.next;
+
+      if (bit->second != spikeheap.end()) spikeheap.erase(bit->second);
+      if (pbit->second != spikeheap.end()) spikeheap.erase(pbit->second);
+      if (nbit->second != spikeheap.end()) spikeheap.erase(nbit->second);
+
+      beach.erase(nbit);
+      beach.erase(bit);
+      beach.erase(pbit);
+
+      SpikeHeap::iterator pit = spikeheap.end();
+      if (ppv != -1 && ppv != next && 
+	  circle_form(points[ppv], points[prev], points[next])) {
+	double x = circle_point(points[ppv], points[prev], points[next]);
+	if (x < sweep) x = sweep;
+	pit = spikeheap.insert(std::make_pair(x, BeachIt(beach.end())));
+	pit->second.it =
+	  beach.insert(std::make_pair(Part(ppv, prev, next), pit));
+      } else {
+	beach.insert(std::make_pair(Part(ppv, prev, next), pit));
+      }
+
+      SpikeHeap::iterator nit = spikeheap.end();
+      if (nnt != -1 && prev != nnt &&
+	  circle_form(points[prev], points[next], points[nnt])) {
+	double x = circle_point(points[prev], points[next], points[nnt]);
+	if (x < sweep) x = sweep;
+	nit = spikeheap.insert(std::make_pair(x, BeachIt(beach.end())));
+	nit->second.it =
+	  beach.insert(std::make_pair(Part(prev, next, nnt), nit));
+      } else {
+	beach.insert(std::make_pair(Part(prev, next, nnt), nit));
+      }
+      
+    }
+  }
+
+  for (Beach::iterator it = beach.begin(); it != beach.end(); ++it) {
+    int curr = it->first.curr;
+    int next = it->first.next;
+
+    if (next == -1) continue;
+
+    std::pair<int, int> edge;
+
+    edge = curr < next ? 
+      std::make_pair(curr, next) : std::make_pair(next, curr);
+    
+    if (edges.find(edge) == edges.end()) {
+      edges.insert(edge);
+      g.addEdge(nodes[curr], nodes[next]);
+      ++cnt;
+    }
+  }
+}
+
+void sparse(int d) 
+{
+  Counter cnt("Number of edges removed: ");
+  Bfs<ListUGraph> bfs(g);
+  for(std::vector<UEdge>::reverse_iterator ei=edges.rbegin();
+      ei!=edges.rend();++ei)
+    {
+      Node a=g.source(*ei);
+      Node b=g.target(*ei);
+      g.erase(*ei);
+      bfs.run(a,b);
+      if(bfs.predEdge(b)==INVALID || bfs.dist(b)>d)
+	g.addEdge(a,b);
+      else cnt++;
+    }
+}
+
+void sparse2(int d) 
+{
+  Counter cnt("Number of edges removed: ");
+  for(std::vector<UEdge>::reverse_iterator ei=edges.rbegin();
+      ei!=edges.rend();++ei)
+    {
+      Node a=g.source(*ei);
+      Node b=g.target(*ei);
+      g.erase(*ei);
+      ConstMap<Edge,int> cegy(1);
+      Suurballe<ListUGraph,ConstMap<Edge,int> > sur(g,cegy,a,b);
+      int k=sur.run(2);
+      if(k<2 || sur.totalLength()>d)
+	g.addEdge(a,b);
+      else cnt++;
+//       else std::cout << "Remove edge " << g.id(a) << "-" << g.id(b) << '\n';
+    }
+}
+
+void sparseTriangle(int d)
+{
+  Counter cnt("Number of edges added: ");
+  std::vector<Pedge> pedges;
+  for(NodeIt n(g);n!=INVALID;++n) 
+    for(NodeIt m=++(NodeIt(n));m!=INVALID;++m)
+      {
+	Pedge p;
+	p.a=n;
+	p.b=m;
+	p.len=(coords[m]-coords[n]).normSquare();
+	pedges.push_back(p);
+      }
+  std::sort(pedges.begin(),pedges.end(),pedgeLess);
+  for(std::vector<Pedge>::iterator pi=pedges.begin();pi!=pedges.end();++pi)
+    {
+      Line li(pi->a,pi->b);
+      UEdgeIt e(g);
+      for(;e!=INVALID && !cross(e,li);++e) ;
+      UEdge ne;
+      if(e==INVALID) {
+	ConstMap<Edge,int> cegy(1);
+	Suurballe<ListUGraph,ConstMap<Edge,int> >
+	  sur(g,cegy,pi->a,pi->b);
+	int k=sur.run(2);
+	if(k<2 || sur.totalLength()>d)
+	  {
+	    ne=g.addEdge(pi->a,pi->b);
+	    edges.push_back(ne);
+	    cnt++;
+	  }
+      }
+    }
+}
+
+template <typename UGraph, typename CoordMap>
+class LengthSquareMap {
+public:
+  typedef typename UGraph::UEdge Key;
+  typedef typename CoordMap::Value::Value Value;
+
+  LengthSquareMap(const UGraph& ugraph, const CoordMap& coords)
+    : _ugraph(ugraph), _coords(coords) {}
+
+  Value operator[](const Key& key) const {
+    return (_coords[_ugraph.target(key)] -
+	    _coords[_ugraph.source(key)]).normSquare();
+  }
+
+private:
+
+  const UGraph& _ugraph;
+  const CoordMap& _coords;
+};
+
+void minTree() {
+  std::vector<Pedge> pedges;
+  Timer T;
+  std::cout << T.realTime() << "s: Creating delaunay triangulation...\n";
+  delaunay();
+  std::cout << T.realTime() << "s: Calculating spanning tree...\n";
+  LengthSquareMap<ListUGraph, ListUGraph::NodeMap<Point> > ls(g, coords);
+  ListUGraph::UEdgeMap<bool> tree(g);
+  kruskal(g, ls, tree);
+  std::cout << T.realTime() << "s: Removing non tree edges...\n";
+  std::vector<UEdge> remove;
+  for (UEdgeIt e(g); e != INVALID; ++e) {
+    if (!tree[e]) remove.push_back(e);
+  }
+  for(int i = 0; i < int(remove.size()); ++i) {
+    g.erase(remove[i]);
+  }
+  std::cout << T.realTime() << "s: Done\n";
+}
+
+void tsp2() 
+{
+  std::cout << "Find a tree..." << std::endl;
+
+  minTree();
+
+  std::cout << "Total edge length (tree) : " << totalLen() << std::endl;
+
+  std::cout << "Make it Euler..." << std::endl;
+
+  {
+    std::vector<Node> leafs;
+    for(NodeIt n(g);n!=INVALID;++n)
+      if(countIncEdges(g,n)%2==1) leafs.push_back(n);
+
+//    for(unsigned int i=0;i<leafs.size();i+=2)
+//       g.addEdge(leafs[i],leafs[i+1]);
+
+    std::vector<Pedge> pedges;
+    for(unsigned int i=0;i<leafs.size()-1;i++)
+      for(unsigned int j=i+1;j<leafs.size();j++)
+	{
+	  Node n=leafs[i];
+	  Node m=leafs[j];
+	  Pedge p;
+	  p.a=n;
+	  p.b=m;
+	  p.len=(coords[m]-coords[n]).normSquare();
+	  pedges.push_back(p);
+	}
+    std::sort(pedges.begin(),pedges.end(),pedgeLess);
+    for(unsigned int i=0;i<pedges.size();i++)
+      if(countIncEdges(g,pedges[i].a)%2 &&
+	 countIncEdges(g,pedges[i].b)%2)
+	g.addEdge(pedges[i].a,pedges[i].b);
+  }
+
+  for(NodeIt n(g);n!=INVALID;++n)
+    if(countIncEdges(g,n)%2 || countIncEdges(g,n)==0 )
+      std::cout << "GEBASZ!!!" << std::endl;
+  
+  for(UEdgeIt e(g);e!=INVALID;++e)
+    if(g.source(e)==g.target(e))
+      std::cout << "LOOP GEBASZ!!!" << std::endl;
+  
+  std::cout << "Number of edges : " << countUEdges(g) << std::endl;
+  
+  std::cout << "Total edge length (euler) : " << totalLen() << std::endl;
+
+  ListUGraph::UEdgeMap<Edge> enext(g);
+  {
+    UEulerIt<ListUGraph> e(g);
+    Edge eo=e;
+    Edge ef=e;
+//     std::cout << "Tour edge: " << g.id(UEdge(e)) << std::endl;      
+    for(++e;e!=INVALID;++e)
+      {
+// 	std::cout << "Tour edge: " << g.id(UEdge(e)) << std::endl;      
+	enext[eo]=e;
+	eo=e;
+      }
+    enext[eo]=ef;
+  }
+    
+  std::cout << "Creating a tour from that..." << std::endl;
+  
+  int nnum = countNodes(g);
+  int ednum = countUEdges(g);
+  
+  for(Edge p=enext[UEdgeIt(g)];ednum>nnum;p=enext[p]) 
+    {
+//       std::cout << "Checking edge " << g.id(p) << std::endl;      
+      Edge e=enext[p];
+      Edge f=enext[e];
+      Node n2=g.source(f);
+      Node n1=g.oppositeNode(n2,e);
+      Node n3=g.oppositeNode(n2,f);
+      if(countIncEdges(g,n2)>2)
+	{
+// 	  std::cout << "Remove an Edge" << std::endl;
+	  Edge ff=enext[f];
+	  g.erase(e);
+	  g.erase(f);
+	  if(n1!=n3)
+	    {
+	      Edge ne=g.direct(g.addEdge(n1,n3),n1);
+	      enext[p]=ne;
+	      enext[ne]=ff;
+	      ednum--;
+	    }
+	  else {
+	    enext[p]=ff;
+	    ednum-=2;
+	  }
+	}
+    }
+
+  std::cout << "Total edge length (tour) : " << totalLen() << std::endl;
+
+  std::cout << "2-opt the tour..." << std::endl;
+  
+  tsp_improve();
+  
+  std::cout << "Total edge length (2-opt tour) : " << totalLen() << std::endl;
+}
+
+
+int main(int argc,const char **argv) 
+{
+  ArgParser ap(argc,argv);
+
+//   bool eps;
+  bool disc_d, square_d, gauss_d;
+//   bool tsp_a,two_a,tree_a;
+  int num_of_cities=1;
+  double area=1;
+  N=100;
+//   girth=10;
+  std::string ndist("disc");
+  ap.refOption("n", "Number of nodes (default is 100)", N)
+    .intOption("g", "Girth parameter (default is 10)", 10)
+    .refOption("cities", "Number of cities (default is 1)", num_of_cities)
+    .refOption("area", "Full relative area of the cities (default is 1)", area)
+    .refOption("disc", "Nodes are evenly distributed on a unit disc (default)",disc_d)
+    .optionGroup("dist", "disc")
+    .refOption("square", "Nodes are evenly distributed on a unit square", square_d)
+    .optionGroup("dist", "square")
+    .refOption("gauss",
+	    "Nodes are located according to a two-dim gauss distribution",
+	    gauss_d)
+    .optionGroup("dist", "gauss")
+//     .mandatoryGroup("dist")
+    .onlyOneGroup("dist")
+    .boolOption("eps", "Also generate .eps output (prefix.eps)")
+    .boolOption("dir", "Directed graph is generated (each edges are replaced by two directed ones)")
+    .boolOption("2con", "Create a two connected planar graph")
+    .optionGroup("alg","2con")
+    .boolOption("tree", "Create a min. cost spanning tree")
+    .optionGroup("alg","tree")
+    .boolOption("tsp", "Create a TSP tour")
+    .optionGroup("alg","tsp")
+    .boolOption("tsp2", "Create a TSP tour (tree based)")
+    .optionGroup("alg","tsp2")
+    .boolOption("dela", "Delaunay triangulation graph")
+    .optionGroup("alg","dela")
+    .onlyOneGroup("alg")
+    .boolOption("rand", "Use time seed for random number generator")
+    .optionGroup("rand", "rand")
+    .intOption("seed", "Random seed", -1)
+    .optionGroup("rand", "seed")
+    .onlyOneGroup("rand")
+    .other("[prefix]","Prefix of the output files. Default is 'lgf-gen-out'")
+    .run();
+
+  if (ap["rand"]) {
+    int seed = time(0);
+    std::cout << "Random number seed: " << seed << std::endl;
+    rnd = Random(seed);
+  }
+  if (ap.given("seed")) {
+    int seed = ap["seed"];
+    std::cout << "Random number seed: " << seed << std::endl;
+    rnd = Random(seed);
+  }
+  
+  std::string prefix;
+  switch(ap.files().size()) 
+    {
+    case 0:
+      prefix="lgf-gen-out";
+      break;
+    case 1:
+      prefix=ap.files()[0];
+      break;
+    default:
+      std::cerr << "\nAt most one prefix can be given\n\n";
+      exit(1);
+    }
+  
+  double sum_sizes=0;
+  std::vector<double> sizes;
+  std::vector<double> cum_sizes;
+  for(int s=0;s<num_of_cities;s++) 
+    {
+      // 	sum_sizes+=rnd.exponential();
+      double d=rnd();
+      sum_sizes+=d;
+      sizes.push_back(d);
+      cum_sizes.push_back(sum_sizes);
+    }
+  int i=0;
+  for(int s=0;s<num_of_cities;s++) 
+    {
+      Point center=(num_of_cities==1?Point(0,0):rnd.disc());
+      if(gauss_d)
+	for(;i<N*(cum_sizes[s]/sum_sizes);i++) {
+	  Node n=g.addNode();
+	  nodes.push_back(n);
+	  coords[n]=center+rnd.gauss2()*area*
+	    std::sqrt(sizes[s]/sum_sizes);
+	}
+      else if(square_d)
+	for(;i<N*(cum_sizes[s]/sum_sizes);i++) {
+	  Node n=g.addNode();
+	  nodes.push_back(n);
+	  coords[n]=center+Point(rnd()*2-1,rnd()*2-1)*area*
+	    std::sqrt(sizes[s]/sum_sizes);
+	}
+      else if(disc_d || true)
+	for(;i<N*(cum_sizes[s]/sum_sizes);i++) {
+	  Node n=g.addNode();
+	  nodes.push_back(n);
+	  coords[n]=center+rnd.disc()*area*
+	    std::sqrt(sizes[s]/sum_sizes);
+	}
+    }
+
+//   for (ListUGraph::NodeIt n(g); n != INVALID; ++n) {
+//     std::cerr << coords[n] << std::endl;
+//   }
+  
+  if(ap["tsp"]) {
+    tsp();
+    std::cout << "#2-opt improvements: " << tsp_impr_num << std::endl;
+  }
+  if(ap["tsp2"]) {
+    tsp2();
+    std::cout << "#2-opt improvements: " << tsp_impr_num << std::endl;
+  }
+  else if(ap["2con"]) {
+    std::cout << "Make triangles\n";
+    //   triangle();
+    sparseTriangle(ap["g"]);
+    std::cout << "Make it sparser\n";
+    sparse2(ap["g"]);
+  }
+  else if(ap["tree"]) {
+    minTree();
+  }
+  else if(ap["dela"]) {
+    delaunay();
+  }
+  
+
+  std::cout << "Number of nodes    : " << countNodes(g) << std::endl;
+  std::cout << "Number of edges    : " << countUEdges(g) << std::endl;
+  double tlen=0;
+  for(UEdgeIt e(g);e!=INVALID;++e)
+    tlen+=sqrt((coords[g.source(e)]-coords[g.target(e)]).normSquare());
+  std::cout << "Total edge length  : " << tlen << std::endl;
+
+  if(ap["eps"])
+    graphToEps(g,prefix+".eps").scaleToA4().
+      scale(600).nodeScale(.2).edgeWidthScale(.001).preScale(false).
+      coords(coords).run();
+  
+  if(ap["dir"])
+    GraphWriter<ListUGraph>(prefix+".lgf",g).
+      writeNodeMap("coordinates_x",scaleMap(xMap(coords),600)).
+      writeNodeMap("coordinates_y",scaleMap(yMap(coords),600)).
+      run();
+  else UGraphWriter<ListUGraph>(prefix+".lgf",g).
+	 writeNodeMap("coordinates_x",scaleMap(xMap(coords),600)).
+	 writeNodeMap("coordinates_y",scaleMap(yMap(coords),600)).
+	 run();
+}
+
