Index: doc/groups.dox
===================================================================
--- doc/groups.dox	(revision 633)
+++ doc/groups.dox	(revision 637)
@@ -436,7 +436,8 @@
 \brief Algorithms for finding matchings in graphs and bipartite graphs.
 
-This group contains algorithm objects and functions to calculate
+This group contains the algorithms for calculating
 matchings in graphs and bipartite graphs. The general matching problem is
-finding a subset of the arcs which does not shares common endpoints.
+finding a subset of the edges for which each node has at most one incident
+edge.
 
 There are several different algorithms for calculate matchings in
Index: lemon/euler.h
===================================================================
--- lemon/euler.h	(revision 639)
+++ lemon/euler.h	(revision 633)
@@ -27,29 +27,31 @@
 /// \ingroup graph_properties
 /// \file
-/// \brief Euler tour iterators and a function for checking the \e Eulerian 
-/// property.
+/// \brief Euler tour
 ///
-///This file provides Euler tour iterators and a function to check
-///if a (di)graph is \e Eulerian.
+///This file provides an Euler tour iterator and ways to check
+///if a digraph is euler.
+
 
 namespace lemon {
 
-  ///Euler tour iterator for digraphs.
-
-  /// \ingroup graph_prop
-  ///This iterator provides an Euler tour (Eulerian circuit) of a \e directed
-  ///graph (if there exists) and it converts to the \c Arc type of the digraph.
+  ///Euler iterator for digraphs.
+
+  /// \ingroup graph_properties
+  ///This iterator converts to the \c Arc type of the digraph and using
+  ///operator ++, it provides an Euler tour of a \e directed
+  ///graph (if there exists).
   ///
-  ///For example, if the given digraph has an Euler tour (i.e it has only one
-  ///non-trivial component and the in-degree is equal to the out-degree 
-  ///for all nodes), then the following code will put the arcs of \c g
-  ///to the vector \c et according to an Euler tour of \c g.
+  ///For example
+  ///if the given digraph is 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 arcs of \c g
+  ///to the vector \c et according to an
+  ///Euler tour of \c g.
   ///\code
   ///  std::vector<ListDigraph::Arc> et;
-  ///  for(DiEulerIt<ListDigraph> e(g); e!=INVALID; ++e)
+  ///  for(DiEulerIt<ListDigraph> e(g),e!=INVALID;++e)
   ///    et.push_back(e);
   ///\endcode
-  ///If \c g has no Euler tour, then the resulted walk will not be closed
-  ///or not contain all arcs.
+  ///If \c g is not Euler then the resulted tour will not be full or closed.
   ///\sa EulerIt
   template<typename GR>
@@ -64,5 +66,5 @@
 
     const GR &g;
-    typename GR::template NodeMap<OutArcIt> narc;
+    typename GR::template NodeMap<OutArcIt> nedge;
     std::list<Arc> euler;
 
@@ -71,46 +73,36 @@
     ///Constructor
 
-    ///Constructor.
     ///\param gr A digraph.
-    ///\param start The starting point of the tour. If it is not given,
-    ///the tour will start from the first node that has an outgoing arc.
+    ///\param start The starting point of the tour. If it is not given
+    ///       the tour will start from the first node.
     DiEulerIt(const GR &gr, typename GR::Node start = INVALID)
-      : g(gr), narc(g)
-    {
-      if (start==INVALID) {
-        NodeIt n(g);
-        while (n!=INVALID && OutArcIt(g,n)==INVALID) ++n;
-        start=n;
-      }
-      if (start!=INVALID) {
-        for (NodeIt n(g); n!=INVALID; ++n) narc[n]=OutArcIt(g,n);
-        while (narc[start]!=INVALID) {
-          euler.push_back(narc[start]);
-          Node next=g.target(narc[start]);
-          ++narc[start];
-          start=next;
-        }
-      }
-    }
-
-    ///Arc conversion
+      : g(gr), nedge(g)
+    {
+      if(start==INVALID) start=NodeIt(g);
+      for(NodeIt n(g);n!=INVALID;++n) nedge[n]=OutArcIt(g,n);
+      while(nedge[start]!=INVALID) {
+        euler.push_back(nedge[start]);
+        Node next=g.target(nedge[start]);
+        ++nedge[start];
+        start=next;
+      }
+    }
+
+    ///Arc Conversion
     operator Arc() { return euler.empty()?INVALID:euler.front(); }
-    ///Compare with \c INVALID
     bool operator==(Invalid) { return euler.empty(); }
-    ///Compare with \c INVALID
     bool operator!=(Invalid) { return !euler.empty(); }
 
     ///Next arc of the tour
-
-    ///Next arc of the tour
-    ///
     DiEulerIt &operator++() {
       Node s=g.target(euler.front());
       euler.pop_front();
+      //This produces a warning.Strange.
+      //std::list<Arc>::iterator next=euler.begin();
       typename std::list<Arc>::iterator next=euler.begin();
-      while(narc[s]!=INVALID) {
-        euler.insert(next,narc[s]);
-        Node n=g.target(narc[s]);
-        ++narc[s];
+      while(nedge[s]!=INVALID) {
+        euler.insert(next,nedge[s]);
+        Node n=g.target(nedge[s]);
+        ++nedge[s];
         s=n;
       }
@@ -119,8 +111,6 @@
     ///Postfix incrementation
 
-    /// Postfix incrementation.
-    ///
     ///\warning This incrementation
-    ///returns an \c Arc, not a \ref DiEulerIt, as one may
+    ///returns an \c Arc, not an \ref DiEulerIt, as one may
     ///expect.
     Arc operator++(int)
@@ -132,26 +122,28 @@
   };
 
-  ///Euler tour iterator for graphs.
+  ///Euler iterator for graphs.
 
   /// \ingroup graph_properties
-  ///This iterator provides an Euler tour (Eulerian circuit) of an
-  ///\e undirected graph (if there exists) and it converts to the \c Arc
-  ///and \c Edge types of the graph.
+  ///This iterator converts to the \c Arc (or \c Edge)
+  ///type of the digraph and using
+  ///operator ++, it provides an Euler tour of an undirected
+  ///digraph (if there exists).
   ///
-  ///For example, if the given graph has an Euler tour (i.e it has only one 
-  ///non-trivial component and the degree of each node is even),
+  ///For example
+  ///if the given digraph if Euler (i.e it has only one nontrivial component
+  ///and the degree of each node is even),
   ///the following code will print the arc IDs according to an
   ///Euler tour of \c g.
   ///\code
-  ///  for(EulerIt<ListGraph> e(g); e!=INVALID; ++e) {
+  ///  for(EulerIt<ListGraph> e(g),e!=INVALID;++e) {
   ///    std::cout << g.id(Edge(e)) << std::eol;
   ///  }
   ///\endcode
-  ///Although this iterator is for undirected graphs, it still returns 
-  ///arcs in order to indicate the direction of the tour.
-  ///(But arcs convert to edges, of course.)
+  ///Although the iterator provides an Euler tour of an graph,
+  ///it still returns Arcs in order to indicate the direction of the tour.
+  ///(But Arc will convert to Edges, of course).
   ///
-  ///If \c g has no Euler tour, then the resulted walk will not be closed
-  ///or not contain all edges.
+  ///If \c g is not Euler then the resulted tour will not be full or closed.
+  ///\sa EulerIt
   template<typename GR>
   class EulerIt
@@ -166,5 +158,5 @@
 
     const GR &g;
-    typename GR::template NodeMap<OutArcIt> narc;
+    typename GR::template NodeMap<OutArcIt> nedge;
     typename GR::template EdgeMap<bool> visited;
     std::list<Arc> euler;
@@ -174,54 +166,45 @@
     ///Constructor
 
-    ///Constructor.
-    ///\param gr A graph.
-    ///\param start The starting point of the tour. If it is not given,
-    ///the tour will start from the first node that has an incident edge.
+    ///\param gr An graph.
+    ///\param start The starting point of the tour. If it is not given
+    ///       the tour will start from the first node.
     EulerIt(const GR &gr, typename GR::Node start = INVALID)
-      : g(gr), narc(g), visited(g, false)
-    {
-      if (start==INVALID) {
-        NodeIt n(g);
-        while (n!=INVALID && OutArcIt(g,n)==INVALID) ++n;
-        start=n;
-      }
-      if (start!=INVALID) {
-        for (NodeIt n(g); n!=INVALID; ++n) narc[n]=OutArcIt(g,n);
-        while(narc[start]!=INVALID) {
-          euler.push_back(narc[start]);
-          visited[narc[start]]=true;
-          Node next=g.target(narc[start]);
-          ++narc[start];
-          start=next;
-          while(narc[start]!=INVALID && visited[narc[start]]) ++narc[start];
-        }
-      }
-    }
-
-    ///Arc conversion
+      : g(gr), nedge(g), visited(g, false)
+    {
+      if(start==INVALID) start=NodeIt(g);
+      for(NodeIt n(g);n!=INVALID;++n) nedge[n]=OutArcIt(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];
+      }
+    }
+
+    ///Arc Conversion
     operator Arc() const { return euler.empty()?INVALID:euler.front(); }
-    ///Edge conversion
+    ///Arc Conversion
     operator Edge() const { return euler.empty()?INVALID:euler.front(); }
-    ///Compare with \c INVALID
+    ///\e
     bool operator==(Invalid) const { return euler.empty(); }
-    ///Compare with \c INVALID
+    ///\e
     bool operator!=(Invalid) const { return !euler.empty(); }
 
     ///Next arc of the tour
-
-    ///Next arc of the tour
-    ///
     EulerIt &operator++() {
       Node s=g.target(euler.front());
       euler.pop_front();
       typename std::list<Arc>::iterator next=euler.begin();
-      while(narc[s]!=INVALID) {
-        while(narc[s]!=INVALID && visited[narc[s]]) ++narc[s];
-        if(narc[s]==INVALID) break;
+
+      while(nedge[s]!=INVALID) {
+        while(nedge[s]!=INVALID && visited[nedge[s]]) ++nedge[s];
+        if(nedge[s]==INVALID) break;
         else {
-          euler.insert(next,narc[s]);
-          visited[narc[s]]=true;
-          Node n=g.target(narc[s]);
-          ++narc[s];
+          euler.insert(next,nedge[s]);
+          visited[nedge[s]]=true;
+          Node n=g.target(nedge[s]);
+          ++nedge[s];
           s=n;
         }
@@ -232,8 +215,7 @@
     ///Postfix incrementation
 
-    /// Postfix incrementation.
-    ///
-    ///\warning This incrementation returns an \c Arc (which converts to 
-    ///an \c Edge), not an \ref EulerIt, as one may expect.
+    ///\warning This incrementation
+    ///returns an \c Arc, not an \ref EulerIt, as one may
+    ///expect.
     Arc operator++(int)
     {
@@ -245,21 +227,16 @@
 
 
-  ///Check if the given graph is \e Eulerian
+  ///Checks if the graph is Eulerian
 
   /// \ingroup graph_properties
-  ///This function checks if the given graph is \e Eulerian.
-  ///It works for both directed and undirected graphs.
-  ///
-  ///By definition, a digraph is called \e Eulerian if
-  ///and only if it is connected and the number of incoming and outgoing
+  ///Checks if the graph is Eulerian. It works for both directed and undirected
+  ///graphs.
+  ///\note By definition, a digraph is called \e Eulerian if
+  ///and only if it is connected and the number of its incoming and outgoing
   ///arcs are the same for each node.
   ///Similarly, an undirected graph is called \e Eulerian if
-  ///and only if it is connected and the number of incident edges is even
-  ///for each node.
-  ///
-  ///\note There are (di)graphs that are not Eulerian, but still have an
-  /// Euler tour, since they may contain isolated nodes.
-  ///
-  ///\sa DiEulerIt, EulerIt
+  ///and only if it is connected and the number of incident arcs is even
+  ///for each node. <em>Therefore, there are digraphs which are not Eulerian,
+  ///but still have an Euler tour</em>.
   template<typename GR>
 #ifdef DOXYGEN
@@ -280,5 +257,5 @@
     for(typename GR::NodeIt n(g);n!=INVALID;++n)
       if(countInArcs(g,n)!=countOutArcs(g,n)) return false;
-    return connected(undirector(g));
+    return connected(Undirector<const GR>(g));
   }
 
Index: lemon/max_matching.h
===================================================================
--- lemon/max_matching.h	(revision 628)
+++ lemon/max_matching.h	(revision 640)
@@ -38,42 +38,53 @@
   /// \ingroup matching
   ///
-  /// \brief Edmonds' alternating forest maximum matching algorithm.
+  /// \brief Maximum cardinality matching in general graphs
   ///
-  /// This class implements Edmonds' alternating forest matching
-  /// algorithm. The algorithm can be started from an arbitrary initial
-  /// matching (the default is the empty one)
+  /// This class implements Edmonds' alternating forest matching algorithm
+  /// for finding a maximum cardinality matching in a general undirected graph.
+  /// It can be started from an arbitrary initial matching 
+  /// (the default is the empty one).
   ///
   /// The dual solution of the problem is a map of the nodes to
-  /// MaxMatching::Status, having values \c EVEN/D, \c ODD/A and \c
-  /// MATCHED/C showing the Gallai-Edmonds decomposition of the
-  /// graph. The nodes in \c EVEN/D induce a graph with
-  /// factor-critical components, the nodes in \c ODD/A form the
-  /// barrier, and the nodes in \c MATCHED/C induce a graph having a
-  /// perfect matching. The number of the factor-critical components
+  /// \ref MaxMatching::Status "Status", having values \c EVEN (or \c D),
+  /// \c ODD (or \c A) and \c MATCHED (or \c C) defining the Gallai-Edmonds
+  /// decomposition of the graph. The nodes in \c EVEN/D induce a subgraph
+  /// with factor-critical components, the nodes in \c ODD/A form the
+  /// canonical barrier, and the nodes in \c MATCHED/C induce a graph having
+  /// a perfect matching. The number of the factor-critical components
   /// minus the number of barrier nodes is a lower bound on the
   /// unmatched nodes, and the matching is optimal if and only if this bound is
-  /// tight. This decomposition can be attained by calling \c
-  /// decomposition() after running the algorithm.
+  /// tight. This decomposition can be obtained using \ref status() or
+  /// \ref statusMap() after running the algorithm.
   ///
-  /// \param GR The graph type the algorithm runs on.
+  /// \tparam GR The undirected graph type the algorithm runs on.
   template <typename GR>
   class MaxMatching {
   public:
 
+    /// The graph type of the algorithm
     typedef GR Graph;
+    /// The type of the matching map
     typedef typename Graph::template NodeMap<typename Graph::Arc>
     MatchingMap;
 
-    ///\brief Indicates the Gallai-Edmonds decomposition of the graph.
-    ///
-    ///Indicates the Gallai-Edmonds decomposition of the graph. The
-    ///nodes with Status \c EVEN/D induce a graph with factor-critical
-    ///components, the nodes in \c ODD/A form the canonical barrier,
-    ///and the nodes in \c MATCHED/C induce a graph having a perfect
-    ///matching.
+    ///\brief Status constants for Gallai-Edmonds decomposition.
+    ///
+    ///These constants are used for indicating the Gallai-Edmonds 
+    ///decomposition of a graph. The nodes with status \c EVEN (or \c D)
+    ///induce a subgraph with factor-critical components, the nodes with
+    ///status \c ODD (or \c A) form the canonical barrier, and the nodes
+    ///with status \c MATCHED (or \c C) induce a subgraph having a 
+    ///perfect matching.
     enum Status {
-      EVEN = 1, D = 1, MATCHED = 0, C = 0, ODD = -1, A = -1, UNMATCHED = -2
+      EVEN = 1,       ///< = 1. (\c D is an alias for \c EVEN.)
+      D = 1,
+      MATCHED = 0,    ///< = 0. (\c C is an alias for \c MATCHED.)
+      C = 0,
+      ODD = -1,       ///< = -1. (\c A is an alias for \c ODD.)
+      A = -1,
+      UNMATCHED = -2  ///< = -2.
     };
 
+    /// The type of the status map
     typedef typename Graph::template NodeMap<Status> StatusMap;
 
@@ -339,6 +350,4 @@
     }
 
-
-
     void extendOnArc(const Arc& a) {
       Node base = _graph.source(a);
@@ -409,20 +418,17 @@
     }
 
-    /// \name Execution control
+    /// \name Execution Control
     /// The simplest way to execute the algorithm is to use the
-    /// \c run() member function.
-    /// \n
-
-    /// If you need better control on the execution, you must call
-    /// \ref init(), \ref greedyInit() or \ref matchingInit()
-    /// functions first, then you can start the algorithm with the \ref
-    /// startSparse() or startDense() functions.
+    /// \c run() member function.\n
+    /// If you need better control on the execution, you have to call
+    /// one of the functions \ref init(), \ref greedyInit() or
+    /// \ref matchingInit() first, then you can start the algorithm with
+    /// \ref startSparse() or \ref startDense().
 
     ///@{
 
-    /// \brief Sets the actual matching to the empty matching.
-    ///
-    /// Sets the actual matching to the empty matching.
-    ///
+    /// \brief Set the initial matching to the empty matching.
+    ///
+    /// This function sets the initial matching to the empty matching.
     void init() {
       createStructures();
@@ -433,7 +439,7 @@
     }
 
-    ///\brief Finds an initial matching in a greedy way
-    ///
-    ///It finds an initial matching in a greedy way.
+    /// \brief Find an initial matching in a greedy way.
+    ///
+    /// This function finds an initial matching in a greedy way.
     void greedyInit() {
       createStructures();
@@ -459,9 +465,9 @@
 
 
-    /// \brief Initialize the matching from a map containing.
-    ///
-    /// Initialize the matching from a \c bool valued \c Edge map. This
-    /// map must have the property that there are no two incident edges
-    /// with true value, ie. it contains a matching.
+    /// \brief Initialize the matching from a map.
+    ///
+    /// This function initializes the matching from a \c bool valued edge
+    /// map. This map should have the property that there are no two incident
+    /// edges with \c true value, i.e. it really contains a matching.
     /// \return \c true if the map contains a matching.
     template <typename MatchingMap>
@@ -490,7 +496,10 @@
     }
 
-    /// \brief Starts Edmonds' algorithm
-    ///
-    /// If runs the original Edmonds' algorithm.
+    /// \brief Start Edmonds' algorithm
+    ///
+    /// This function runs the original Edmonds' algorithm.
+    ///
+    /// \pre \ref Init(), \ref greedyInit() or \ref matchingInit() must be
+    /// called before using this function.
     void startSparse() {
       for(NodeIt n(_graph); n != INVALID; ++n) {
@@ -504,8 +513,12 @@
     }
 
-    /// \brief Starts Edmonds' algorithm.
-    ///
-    /// It runs Edmonds' algorithm with a heuristic of postponing
+    /// \brief Start Edmonds' algorithm with a heuristic improvement 
+    /// for dense graphs
+    ///
+    /// This function runs Edmonds' algorithm with a heuristic of postponing
     /// shrinks, therefore resulting in a faster algorithm for dense graphs.
+    ///
+    /// \pre \ref Init(), \ref greedyInit() or \ref matchingInit() must be
+    /// called before using this function.
     void startDense() {
       for(NodeIt n(_graph); n != INVALID; ++n) {
@@ -520,9 +533,9 @@
 
 
-    /// \brief Runs Edmonds' algorithm
-    ///
-    /// Runs Edmonds' algorithm for sparse graphs (<tt>m<2*n</tt>)
-    /// or Edmonds' algorithm with a heuristic of
-    /// postponing shrinks for dense graphs.
+    /// \brief Run Edmonds' algorithm
+    ///
+    /// This function runs Edmonds' algorithm. An additional heuristic of 
+    /// postponing shrinks is used for relatively dense graphs 
+    /// (for which <tt>m>=2*n</tt> holds).
     void run() {
       if (countEdges(_graph) < 2 * countNodes(_graph)) {
@@ -537,13 +550,13 @@
     /// @}
 
-    /// \name Primal solution
-    /// Functions to get the primal solution, ie. the matching.
+    /// \name Primal Solution
+    /// Functions to get the primal solution, i.e. the maximum matching.
 
     /// @{
 
-    ///\brief Returns the size of the current matching.
-    ///
-    ///Returns the size of the current matching. After \ref
-    ///run() it returns the size of the maximum matching in the graph.
+    /// \brief Return the size (cardinality) of the matching.
+    ///
+    /// This function returns the size (cardinality) of the current matching. 
+    /// After run() it returns the size of the maximum matching in the graph.
     int matchingSize() const {
       int size = 0;
@@ -556,23 +569,33 @@
     }
 
-    /// \brief Returns true when the edge is in the matching.
-    ///
-    /// Returns true when the edge is in the matching.
+    /// \brief Return \c true if the given edge is in the matching.
+    ///
+    /// This function returns \c true if the given edge is in the current 
+    /// matching.
     bool matching(const Edge& edge) const {
       return edge == (*_matching)[_graph.u(edge)];
     }
 
-    /// \brief Returns the matching edge incident to the given node.
-    ///
-    /// Returns the matching edge of a \c node in the actual matching or
-    /// INVALID if the \c node is not covered by the actual matching.
+    /// \brief Return the matching arc (or edge) incident to the given node.
+    ///
+    /// This function returns the matching arc (or edge) incident to the
+    /// given node in the current matching or \c INVALID if the node is 
+    /// not covered by the matching.
     Arc matching(const Node& n) const {
       return (*_matching)[n];
     }
 
-    ///\brief Returns the mate of a node in the actual matching.
-    ///
-    ///Returns the mate of a \c node in the actual matching or
-    ///INVALID if the \c node is not covered by the actual matching.
+    /// \brief Return a const reference to the matching map.
+    ///
+    /// This function returns a const reference to a node map that stores
+    /// the matching arc (or edge) incident to each node.
+    const MatchingMap& matchingMap() const {
+      return *_matching;
+    }
+
+    /// \brief Return the mate of the given node.
+    ///
+    /// This function returns the mate of the given node in the current 
+    /// matching or \c INVALID if the node is not covered by the matching.
     Node mate(const Node& n) const {
       return (*_matching)[n] != INVALID ?
@@ -582,21 +605,31 @@
     /// @}
 
-    /// \name Dual solution
-    /// Functions to get the dual solution, ie. the decomposition.
+    /// \name Dual Solution
+    /// Functions to get the dual solution, i.e. the Gallai-Edmonds 
+    /// decomposition.
 
     /// @{
 
-    /// \brief Returns the class of the node in the Edmonds-Gallai
+    /// \brief Return the status of the given node in the Edmonds-Gallai
     /// decomposition.
     ///
-    /// Returns the class of the node in the Edmonds-Gallai
-    /// decomposition.
-    Status decomposition(const Node& n) const {
+    /// This function returns the \ref Status "status" of the given node
+    /// in the Edmonds-Gallai decomposition.
+    Status status(const Node& n) const {
       return (*_status)[n];
     }
 
-    /// \brief Returns true when the node is in the barrier.
-    ///
-    /// Returns true when the node is in the barrier.
+    /// \brief Return a const reference to the status map, which stores
+    /// the Edmonds-Gallai decomposition.
+    ///
+    /// This function returns a const reference to a node map that stores the
+    /// \ref Status "status" of each node in the Edmonds-Gallai decomposition.
+    const StatusMap& statusMap() const {
+      return *_status;
+    }
+
+    /// \brief Return \c true if the given node is in the barrier.
+    ///
+    /// This function returns \c true if the given node is in the barrier.
     bool barrier(const Node& n) const {
       return (*_status)[n] == ODD;
@@ -616,8 +649,8 @@
   /// \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 ends. The problem can be formulated with the
-  /// following linear program.
+  /// The maximum weighted matching problem is to find a subset of the 
+  /// edges in an undirected graph with maximum overall weight for which 
+  /// each node has at most one incident edge.
+  /// It can be formulated with the following 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}
@@ -633,4 +666,5 @@
   /// optimality. The solution of the dual problem can be used to check
   /// the result of the algorithm. The dual linear problem is the
+  /// following.
   /** \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] */
@@ -640,33 +674,41 @@
       \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".
+  /// The algorithm can be executed with the run() function. 
+  /// After it the matching (the primal solution) and the dual solution
+  /// can be obtained using the query functions and the 
+  /// \ref MaxWeightedMatching::BlossomIt "BlossomIt" nested class, 
+  /// which is able to iterate on the nodes of a blossom. 
+  /// If the value type is integer, then the dual solution is multiplied
+  /// by \ref MaxWeightedMatching::dualScale "4".
+  ///
+  /// \tparam GR The undirected graph type the algorithm runs on.
+  /// \tparam WM The type edge weight map. The default type is 
+  /// \ref concepts::Graph::EdgeMap "GR::EdgeMap<int>".
+#ifdef DOXYGEN
+  template <typename GR, typename WM>
+#else
   template <typename GR,
             typename WM = typename GR::template EdgeMap<int> >
+#endif
   class MaxWeightedMatching {
   public:
 
-    ///\e
+    /// The graph type of the algorithm
     typedef GR Graph;
-    ///\e
+    /// The type of the edge weight map
     typedef WM WeightMap;
-    ///\e
+    /// The value type of the edge weights
     typedef typename WeightMap::Value Value;
 
+    /// The type of the matching map
+    typedef typename Graph::template NodeMap<typename Graph::Arc>
+    MatchingMap;
+
     /// \brief Scaling factor for dual solution
     ///
-    /// Scaling factor for dual solution, it is equal to 4 or 1
+    /// 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 Graph::template NodeMap<typename Graph::Arc>
-    MatchingMap;
 
   private:
@@ -1632,7 +1674,7 @@
     }
 
-    /// \name Execution control
+    /// \name Execution Control
     /// The simplest way to execute the algorithm is to use the
-    /// \c run() member function.
+    /// \ref run() member function.
 
     ///@{
@@ -1640,5 +1682,5 @@
     /// \brief Initialize the algorithm
     ///
-    /// Initialize the algorithm
+    /// This function initializes the algorithm.
     void init() {
       createStructures();
@@ -1692,7 +1734,9 @@
     }
 
-    /// \brief Starts the algorithm
-    ///
-    /// Starts the algorithm
+    /// \brief Start the algorithm
+    ///
+    /// This function starts the algorithm.
+    ///
+    /// \pre \ref init() must be called before using this function.
     void start() {
       enum OpType {
@@ -1777,7 +1821,7 @@
     }
 
-    /// \brief Runs %MaxWeightedMatching algorithm.
-    ///
-    /// This method runs the %MaxWeightedMatching algorithm.
+    /// \brief Run the algorithm.
+    ///
+    /// This method runs the \c %MaxWeightedMatching algorithm.
     ///
     /// \note mwm.run() is just a shortcut of the following code.
@@ -1793,13 +1837,18 @@
     /// @}
 
-    /// \name Primal solution
-    /// Functions to get the primal solution, ie. the matching.
+    /// \name Primal Solution
+    /// Functions to get the primal solution, i.e. the maximum weighted 
+    /// matching.\n
+    /// Either \ref run() or \ref start() function should be called before
+    /// using them.
 
     /// @{
 
-    /// \brief Returns the weight of the matching.
-    ///
-    /// Returns the weight of the matching.
-    Value matchingValue() const {
+    /// \brief Return the weight of the matching.
+    ///
+    /// This function returns the weight of the found matching.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
+    Value matchingWeight() const {
       Value sum = 0;
       for (NodeIt n(_graph); n != INVALID; ++n) {
@@ -1811,7 +1860,9 @@
     }
 
-    /// \brief Returns the cardinality of the matching.
-    ///
-    /// Returns the cardinality of the matching.
+    /// \brief Return the size (cardinality) of the matching.
+    ///
+    /// This function returns the size (cardinality) of the found matching.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     int matchingSize() const {
       int num = 0;
@@ -1824,23 +1875,39 @@
     }
 
-    /// \brief Returns true when the edge is in the matching.
-    ///
-    /// Returns true when the edge is in the matching.
+    /// \brief Return \c true if the given edge is in the matching.
+    ///
+    /// This function returns \c true if the given edge is in the found 
+    /// matching.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     bool matching(const Edge& edge) const {
       return edge == (*_matching)[_graph.u(edge)];
     }
 
-    /// \brief Returns the incident matching arc.
-    ///
-    /// Returns the incident matching arc from given node. If the
-    /// node is not matched then it gives back \c INVALID.
+    /// \brief Return the matching arc (or edge) incident to the given node.
+    ///
+    /// This function returns the matching arc (or edge) incident to the
+    /// given node in the found matching or \c INVALID if the node is 
+    /// not covered by the matching.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     Arc matching(const Node& node) const {
       return (*_matching)[node];
     }
 
-    /// \brief Returns the mate of the node.
-    ///
-    /// Returns the adjancent node in a mathcing arc. If the node is
-    /// not matched then it gives back \c INVALID.
+    /// \brief Return a const reference to the matching map.
+    ///
+    /// This function returns a const reference to a node map that stores
+    /// the matching arc (or edge) incident to each node.
+    const MatchingMap& matchingMap() const {
+      return *_matching;
+    }
+
+    /// \brief Return the mate of the given node.
+    ///
+    /// This function returns the mate of the given node in the found 
+    /// matching or \c INVALID if the node is not covered by the matching.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     Node mate(const Node& node) const {
       return (*_matching)[node] != INVALID ?
@@ -1850,13 +1917,18 @@
     /// @}
 
-    /// \name Dual solution
-    /// Functions to get the dual solution.
+    /// \name Dual Solution
+    /// Functions to get the dual solution.\n
+    /// Either \ref run() or \ref start() function should be called before
+    /// using them.
 
     /// @{
 
-    /// \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".
+    /// \brief Return the value of the dual solution.
+    ///
+    /// This function returns the value of the dual solution. 
+    /// It should be equal to the primal value scaled by \ref dualScale 
+    /// "dual scale".
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     Value dualValue() const {
       Value sum = 0;
@@ -1870,14 +1942,18 @@
     }
 
-    /// \brief Returns the value of the node.
-    ///
-    /// Returns the the value of the node.
+    /// \brief Return the dual value (potential) of the given node.
+    ///
+    /// This function returns the dual value (potential) of the given node.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     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.
+    /// \brief Return the number of the blossoms in the basis.
+    ///
+    /// This function returns the number of the blossoms in the basis.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     /// \see BlossomIt
     int blossomNum() const {
@@ -1885,25 +1961,29 @@
     }
 
-
-    /// \brief Returns the number of the nodes in the blossom.
-    ///
-    /// Returns the number of the nodes in the blossom.
+    /// \brief Return the number of the nodes in the given blossom.
+    ///
+    /// This function returns the number of the nodes in the given blossom.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
+    /// \see BlossomIt
     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
+    /// \brief Return the dual value (ptential) of the given blossom.
+    ///
+    /// This function returns the dual value (ptential) of the given blossom.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     Value blossomValue(int k) const {
       return _blossom_potential[k].value;
     }
 
-    /// \brief Iterator for obtaining the nodes of the blossom.
-    ///
-    /// Iterator for obtaining the nodes of the blossom. This class
-    /// provides a common lemon style iterator for listing a
-    /// subset of the nodes.
+    /// \brief Iterator for obtaining the nodes of a blossom.
+    ///
+    /// This class provides an iterator for obtaining the nodes of the 
+    /// given blossom. It lists a subset of the nodes.
+    /// Before using this iterator, you must allocate a 
+    /// MaxWeightedMatching class and execute it.
     class BlossomIt {
     public:
@@ -1911,5 +1991,9 @@
       /// \brief Constructor.
       ///
-      /// Constructor to get the nodes of the variable.
+      /// Constructor to get the nodes of the given variable.
+      ///
+      /// \pre Either \ref MaxWeightedMatching::run() "algorithm.run()" or 
+      /// \ref MaxWeightedMatching::start() "algorithm.start()" must be 
+      /// called before initializing this iterator.
       BlossomIt(const MaxWeightedMatching& algorithm, int variable)
         : _algorithm(&algorithm)
@@ -1919,7 +2003,7 @@
       }
 
-      /// \brief Conversion to node.
+      /// \brief Conversion to \c Node.
       ///
-      /// Conversion to node.
+      /// Conversion to \c Node.
       operator Node() const {
         return _algorithm->_blossom_node_list[_index];
@@ -1963,8 +2047,8 @@
   /// \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 ends and covers all nodes. The problem can be
-  /// formulated with the following linear program.
+  /// The maximum weighted perfect matching problem is to find a subset of 
+  /// the edges in an undirected graph with maximum overall weight for which 
+  /// each node has exactly one incident edge.
+  /// It can be formulated with the following 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}
@@ -1980,4 +2064,5 @@
   /// optimality. The solution of the dual problem can be used to check
   /// the result of the algorithm. The dual linear problem is the
+  /// following.
   /** \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] */
@@ -1986,19 +2071,29 @@
       \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".
+  /// The algorithm can be executed with the run() function. 
+  /// After it the matching (the primal solution) and the dual solution
+  /// can be obtained using the query functions and the 
+  /// \ref MaxWeightedPerfectMatching::BlossomIt "BlossomIt" nested class, 
+  /// which is able to iterate on the nodes of a blossom. 
+  /// If the value type is integer, then the dual solution is multiplied
+  /// by \ref MaxWeightedMatching::dualScale "4".
+  ///
+  /// \tparam GR The undirected graph type the algorithm runs on.
+  /// \tparam WM The type edge weight map. The default type is 
+  /// \ref concepts::Graph::EdgeMap "GR::EdgeMap<int>".
+#ifdef DOXYGEN
+  template <typename GR, typename WM>
+#else
   template <typename GR,
             typename WM = typename GR::template EdgeMap<int> >
+#endif
   class MaxWeightedPerfectMatching {
   public:
 
+    /// The graph type of the algorithm
     typedef GR Graph;
+    /// The type of the edge weight map
     typedef WM WeightMap;
+    /// The value type of the edge weights
     typedef typename WeightMap::Value Value;
 
@@ -2010,4 +2105,5 @@
       std::numeric_limits<Value>::is_integer ? 4 : 1;
 
+    /// The type of the matching map
     typedef typename Graph::template NodeMap<typename Graph::Arc>
     MatchingMap;
@@ -2819,7 +2915,7 @@
     }
 
-    /// \name Execution control
+    /// \name Execution Control
     /// The simplest way to execute the algorithm is to use the
-    /// \c run() member function.
+    /// \ref run() member function.
 
     ///@{
@@ -2827,5 +2923,5 @@
     /// \brief Initialize the algorithm
     ///
-    /// Initialize the algorithm
+    /// This function initializes the algorithm.
     void init() {
       createStructures();
@@ -2875,7 +2971,9 @@
     }
 
-    /// \brief Starts the algorithm
-    ///
-    /// Starts the algorithm
+    /// \brief Start the algorithm
+    ///
+    /// This function starts the algorithm.
+    ///
+    /// \pre \ref init() must be called before using this function.
     bool start() {
       enum OpType {
@@ -2941,12 +3039,12 @@
     }
 
-    /// \brief Runs %MaxWeightedPerfectMatching algorithm.
-    ///
-    /// This method runs the %MaxWeightedPerfectMatching algorithm.
-    ///
-    /// \note mwm.run() is just a shortcut of the following code.
+    /// \brief Run the algorithm.
+    ///
+    /// This method runs the \c %MaxWeightedPerfectMatching algorithm.
+    ///
+    /// \note mwpm.run() is just a shortcut of the following code.
     /// \code
-    ///   mwm.init();
-    ///   mwm.start();
+    ///   mwpm.init();
+    ///   mwpm.start();
     /// \endcode
     bool run() {
@@ -2957,13 +3055,18 @@
     /// @}
 
-    /// \name Primal solution
-    /// Functions to get the primal solution, ie. the matching.
+    /// \name Primal Solution
+    /// Functions to get the primal solution, i.e. the maximum weighted 
+    /// perfect matching.\n
+    /// Either \ref run() or \ref start() function should be called before
+    /// using them.
 
     /// @{
 
-    /// \brief Returns the matching value.
-    ///
-    /// Returns the matching value.
-    Value matchingValue() const {
+    /// \brief Return the weight of the matching.
+    ///
+    /// This function returns the weight of the found matching.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
+    Value matchingWeight() const {
       Value sum = 0;
       for (NodeIt n(_graph); n != INVALID; ++n) {
@@ -2975,21 +3078,39 @@
     }
 
-    /// \brief Returns true when the edge is in the matching.
-    ///
-    /// Returns true when the edge is in the matching.
+    /// \brief Return \c true if the given edge is in the matching.
+    ///
+    /// This function returns \c true if the given edge is in the found 
+    /// matching.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     bool matching(const Edge& edge) const {
       return static_cast<const Edge&>((*_matching)[_graph.u(edge)]) == edge;
     }
 
-    /// \brief Returns the incident matching edge.
-    ///
-    /// Returns the incident matching arc from given edge.
+    /// \brief Return the matching arc (or edge) incident to the given node.
+    ///
+    /// This function returns the matching arc (or edge) incident to the
+    /// given node in the found matching or \c INVALID if the node is 
+    /// not covered by the matching.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     Arc matching(const Node& node) const {
       return (*_matching)[node];
     }
 
-    /// \brief Returns the mate of the node.
-    ///
-    /// Returns the adjancent node in a mathcing arc.
+    /// \brief Return a const reference to the matching map.
+    ///
+    /// This function returns a const reference to a node map that stores
+    /// the matching arc (or edge) incident to each node.
+    const MatchingMap& matchingMap() const {
+      return *_matching;
+    }
+
+    /// \brief Return the mate of the given node.
+    ///
+    /// This function returns the mate of the given node in the found 
+    /// matching or \c INVALID if the node is not covered by the matching.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     Node mate(const Node& node) const {
       return _graph.target((*_matching)[node]);
@@ -2998,13 +3119,18 @@
     /// @}
 
-    /// \name Dual solution
-    /// Functions to get the dual solution.
+    /// \name Dual Solution
+    /// Functions to get the dual solution.\n
+    /// Either \ref run() or \ref start() function should be called before
+    /// using them.
 
     /// @{
 
-    /// \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".
+    /// \brief Return the value of the dual solution.
+    ///
+    /// This function returns the value of the dual solution. 
+    /// It should be equal to the primal value scaled by \ref dualScale 
+    /// "dual scale".
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     Value dualValue() const {
       Value sum = 0;
@@ -3018,14 +3144,18 @@
     }
 
-    /// \brief Returns the value of the node.
-    ///
-    /// Returns the the value of the node.
+    /// \brief Return the dual value (potential) of the given node.
+    ///
+    /// This function returns the dual value (potential) of the given node.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     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.
+    /// \brief Return the number of the blossoms in the basis.
+    ///
+    /// This function returns the number of the blossoms in the basis.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     /// \see BlossomIt
     int blossomNum() const {
@@ -3033,25 +3163,29 @@
     }
 
-
-    /// \brief Returns the number of the nodes in the blossom.
-    ///
-    /// Returns the number of the nodes in the blossom.
+    /// \brief Return the number of the nodes in the given blossom.
+    ///
+    /// This function returns the number of the nodes in the given blossom.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
+    /// \see BlossomIt
     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
+    /// \brief Return the dual value (ptential) of the given blossom.
+    ///
+    /// This function returns the dual value (ptential) of the given blossom.
+    ///
+    /// \pre Either run() or start() must be called before using this function.
     Value blossomValue(int k) const {
       return _blossom_potential[k].value;
     }
 
-    /// \brief Iterator for obtaining the nodes of the blossom.
-    ///
-    /// Iterator for obtaining the nodes of the blossom. This class
-    /// provides a common lemon style iterator for listing a
-    /// subset of the nodes.
+    /// \brief Iterator for obtaining the nodes of a blossom.
+    ///
+    /// This class provides an iterator for obtaining the nodes of the 
+    /// given blossom. It lists a subset of the nodes.
+    /// Before using this iterator, you must allocate a 
+    /// MaxWeightedPerfectMatching class and execute it.
     class BlossomIt {
     public:
@@ -3059,5 +3193,9 @@
       /// \brief Constructor.
       ///
-      /// Constructor to get the nodes of the variable.
+      /// Constructor to get the nodes of the given variable.
+      ///
+      /// \pre Either \ref MaxWeightedPerfectMatching::run() "algorithm.run()" 
+      /// or \ref MaxWeightedPerfectMatching::start() "algorithm.start()" 
+      /// must be called before initializing this iterator.
       BlossomIt(const MaxWeightedPerfectMatching& algorithm, int variable)
         : _algorithm(&algorithm)
@@ -3067,7 +3205,7 @@
       }
 
-      /// \brief Conversion to node.
+      /// \brief Conversion to \c Node.
       ///
-      /// Conversion to node.
+      /// Conversion to \c Node.
       operator Node() const {
         return _algorithm->_blossom_node_list[_index];
@@ -3084,10 +3222,10 @@
       /// \brief Validity checking
       ///
-      /// Checks whether the iterator is invalid.
+      /// This function checks whether the iterator is invalid.
       bool operator==(Invalid) const { return _index == _last; }
 
       /// \brief Validity checking
       ///
-      /// Checks whether the iterator is valid.
+      /// This function checks whether the iterator is valid.
       bool operator!=(Invalid) const { return _index != _last; }
 
@@ -3102,5 +3240,4 @@
   };
 
-
 } //END OF NAMESPACE LEMON
 
Index: test/euler_test.cc
===================================================================
--- test/euler_test.cc	(revision 639)
+++ test/euler_test.cc	(revision 578)
@@ -19,64 +19,61 @@
 #include <lemon/euler.h>
 #include <lemon/list_graph.h>
-#include <lemon/adaptors.h>
-#include "test_tools.h"
+#include <test/test_tools.h>
 
 using namespace lemon;
 
 template <typename Digraph>
-void checkDiEulerIt(const Digraph& g,
-                    const typename Digraph::Node& start = INVALID)
+void checkDiEulerIt(const Digraph& g)
 {
   typename Digraph::template ArcMap<int> visitationNumber(g, 0);
 
-  DiEulerIt<Digraph> e(g, start);
-  if (e == INVALID) return;
+  DiEulerIt<Digraph> e(g);
   typename Digraph::Node firstNode = g.source(e);
   typename Digraph::Node lastNode = g.target(e);
-  if (start != INVALID) {
-    check(firstNode == start, "checkDiEulerIt: Wrong first node");
-  }
 
-  for (; e != INVALID; ++e) {
-    if (e != INVALID) lastNode = g.target(e);
+  for (; e != INVALID; ++e)
+  {
+    if (e != INVALID)
+    {
+      lastNode = g.target(e);
+    }
     ++visitationNumber[e];
   }
 
   check(firstNode == lastNode,
-      "checkDiEulerIt: First and last nodes are not the same");
+      "checkDiEulerIt: first and last node are not the same");
 
   for (typename Digraph::ArcIt a(g); a != INVALID; ++a)
   {
     check(visitationNumber[a] == 1,
-        "checkDiEulerIt: Not visited or multiple times visited arc found");
+        "checkDiEulerIt: not visited or multiple times visited arc found");
   }
 }
 
 template <typename Graph>
-void checkEulerIt(const Graph& g,
-                  const typename Graph::Node& start = INVALID)
+void checkEulerIt(const Graph& g)
 {
   typename Graph::template EdgeMap<int> visitationNumber(g, 0);
 
-  EulerIt<Graph> e(g, start);
-  if (e == INVALID) return;
-  typename Graph::Node firstNode = g.source(typename Graph::Arc(e));
-  typename Graph::Node lastNode = g.target(typename Graph::Arc(e));
-  if (start != INVALID) {
-    check(firstNode == start, "checkEulerIt: Wrong first node");
-  }
+  EulerIt<Graph> e(g);
+  typename Graph::Node firstNode = g.u(e);
+  typename Graph::Node lastNode = g.v(e);
 
-  for (; e != INVALID; ++e) {
-    if (e != INVALID) lastNode = g.target(typename Graph::Arc(e));
+  for (; e != INVALID; ++e)
+  {
+    if (e != INVALID)
+    {
+      lastNode = g.v(e);
+    }
     ++visitationNumber[e];
   }
 
   check(firstNode == lastNode,
-      "checkEulerIt: First and last nodes are not the same");
+      "checkEulerIt: first and last node are not the same");
 
   for (typename Graph::EdgeIt e(g); e != INVALID; ++e)
   {
     check(visitationNumber[e] == 1,
-        "checkEulerIt: Not visited or multiple times visited edge found");
+        "checkEulerIt: not visited or multiple times visited edge found");
   }
 }
@@ -85,138 +82,71 @@
 {
   typedef ListDigraph Digraph;
-  typedef Undirector<Digraph> Graph;
-  
+  typedef ListGraph Graph;
+
+  Digraph digraphWithEulerianCircuit;
   {
-    Digraph d;
-    Graph g(d);
-    
-    checkDiEulerIt(d);
-    checkDiEulerIt(g);
-    checkEulerIt(g);
+    Digraph& g = digraphWithEulerianCircuit;
 
-    check(eulerian(d), "This graph is Eulerian");
-    check(eulerian(g), "This graph is Eulerian");
+    Digraph::Node n0 = g.addNode();
+    Digraph::Node n1 = g.addNode();
+    Digraph::Node n2 = g.addNode();
+
+    g.addArc(n0, n1);
+    g.addArc(n1, n0);
+    g.addArc(n1, n2);
+    g.addArc(n2, n1);
   }
+
+  Digraph digraphWithoutEulerianCircuit;
   {
-    Digraph d;
-    Graph g(d);
-    Digraph::Node n = d.addNode();
+    Digraph& g = digraphWithoutEulerianCircuit;
 
-    checkDiEulerIt(d);
-    checkDiEulerIt(g);
-    checkEulerIt(g);
+    Digraph::Node n0 = g.addNode();
+    Digraph::Node n1 = g.addNode();
+    Digraph::Node n2 = g.addNode();
 
-    check(eulerian(d), "This graph is Eulerian");
-    check(eulerian(g), "This graph is Eulerian");
+    g.addArc(n0, n1);
+    g.addArc(n1, n0);
+    g.addArc(n1, n2);
   }
+
+  Graph graphWithEulerianCircuit;
   {
-    Digraph d;
-    Graph g(d);
-    Digraph::Node n = d.addNode();
-    d.addArc(n, n);
+    Graph& g = graphWithEulerianCircuit;
 
-    checkDiEulerIt(d);
-    checkDiEulerIt(g);
-    checkEulerIt(g);
+    Graph::Node n0 = g.addNode();
+    Graph::Node n1 = g.addNode();
+    Graph::Node n2 = g.addNode();
 
-    check(eulerian(d), "This graph is Eulerian");
-    check(eulerian(g), "This graph is Eulerian");
+    g.addEdge(n0, n1);
+    g.addEdge(n1, n2);
+    g.addEdge(n2, n0);
   }
+
+  Graph graphWithoutEulerianCircuit;
   {
-    Digraph d;
-    Graph g(d);
-    Digraph::Node n1 = d.addNode();
-    Digraph::Node n2 = d.addNode();
-    Digraph::Node n3 = d.addNode();
-    
-    d.addArc(n1, n2);
-    d.addArc(n2, n1);
-    d.addArc(n2, n3);
-    d.addArc(n3, n2);
+    Graph& g = graphWithoutEulerianCircuit;
 
-    checkDiEulerIt(d);
-    checkDiEulerIt(d, n2);
-    checkDiEulerIt(g);
-    checkDiEulerIt(g, n2);
-    checkEulerIt(g);
-    checkEulerIt(g, n2);
+    Graph::Node n0 = g.addNode();
+    Graph::Node n1 = g.addNode();
+    Graph::Node n2 = g.addNode();
 
-    check(eulerian(d), "This graph is Eulerian");
-    check(eulerian(g), "This graph is Eulerian");
+    g.addEdge(n0, n1);
+    g.addEdge(n1, n2);
   }
-  {
-    Digraph d;
-    Graph g(d);
-    Digraph::Node n1 = d.addNode();
-    Digraph::Node n2 = d.addNode();
-    Digraph::Node n3 = d.addNode();
-    Digraph::Node n4 = d.addNode();
-    Digraph::Node n5 = d.addNode();
-    Digraph::Node n6 = d.addNode();
-    
-    d.addArc(n1, n2);
-    d.addArc(n2, n4);
-    d.addArc(n1, n3);
-    d.addArc(n3, n4);
-    d.addArc(n4, n1);
-    d.addArc(n3, n5);
-    d.addArc(n5, n2);
-    d.addArc(n4, n6);
-    d.addArc(n2, n6);
-    d.addArc(n6, n1);
-    d.addArc(n6, n3);
 
-    checkDiEulerIt(d);
-    checkDiEulerIt(d, n1);
-    checkDiEulerIt(d, n5);
+  checkDiEulerIt(digraphWithEulerianCircuit);
 
-    checkDiEulerIt(g);
-    checkDiEulerIt(g, n1);
-    checkDiEulerIt(g, n5);
-    checkEulerIt(g);
-    checkEulerIt(g, n1);
-    checkEulerIt(g, n5);
+  checkEulerIt(graphWithEulerianCircuit);
 
-    check(eulerian(d), "This graph is Eulerian");
-    check(eulerian(g), "This graph is Eulerian");
-  }
-  {
-    Digraph d;
-    Graph g(d);
-    Digraph::Node n0 = d.addNode();
-    Digraph::Node n1 = d.addNode();
-    Digraph::Node n2 = d.addNode();
-    Digraph::Node n3 = d.addNode();
-    Digraph::Node n4 = d.addNode();
-    Digraph::Node n5 = d.addNode();
-    
-    d.addArc(n1, n2);
-    d.addArc(n2, n3);
-    d.addArc(n3, n1);
+  check(eulerian(digraphWithEulerianCircuit),
+      "this graph should have an Eulerian circuit");
+  check(!eulerian(digraphWithoutEulerianCircuit),
+      "this graph should not have an Eulerian circuit");
 
-    checkDiEulerIt(d);
-    checkDiEulerIt(d, n2);
-
-    checkDiEulerIt(g);
-    checkDiEulerIt(g, n2);
-    checkEulerIt(g);
-    checkEulerIt(g, n2);
-
-    check(!eulerian(d), "This graph is not Eulerian");
-    check(!eulerian(g), "This graph is not Eulerian");
-  }
-  {
-    Digraph d;
-    Graph g(d);
-    Digraph::Node n1 = d.addNode();
-    Digraph::Node n2 = d.addNode();
-    Digraph::Node n3 = d.addNode();
-    
-    d.addArc(n1, n2);
-    d.addArc(n2, n3);
-
-    check(!eulerian(d), "This graph is not Eulerian");
-    check(!eulerian(g), "This graph is not Eulerian");
-  }
+  check(eulerian(graphWithEulerianCircuit),
+      "this graph should have an Eulerian circuit");
+  check(!eulerian(graphWithoutEulerianCircuit),
+      "this graph should have an Eulerian circuit");
 
   return 0;
Index: test/max_matching_test.cc
===================================================================
--- test/max_matching_test.cc	(revision 463)
+++ test/max_matching_test.cc	(revision 640)
@@ -21,10 +21,12 @@
 #include <vector>
 #include <queue>
-#include <lemon/math.h>
 #include <cstdlib>
 
 #include <lemon/max_matching.h>
 #include <lemon/smart_graph.h>
+#include <lemon/concepts/graph.h>
+#include <lemon/concepts/maps.h>
 #include <lemon/lgf_reader.h>
+#include <lemon/math.h>
 
 #include "test_tools.h"
@@ -111,4 +113,116 @@
 };
 
+void checkMaxMatchingCompile()
+{
+  typedef concepts::Graph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::Edge Edge;
+  typedef Graph::EdgeMap<bool> MatMap;
+
+  Graph g;
+  Node n;
+  Edge e;
+  MatMap mat(g);
+
+  MaxMatching<Graph> mat_test(g);
+  const MaxMatching<Graph>&
+    const_mat_test = mat_test;
+
+  mat_test.init();
+  mat_test.greedyInit();
+  mat_test.matchingInit(mat);
+  mat_test.startSparse();
+  mat_test.startDense();
+  mat_test.run();
+  
+  const_mat_test.matchingSize();
+  const_mat_test.matching(e);
+  const_mat_test.matching(n);
+  const MaxMatching<Graph>::MatchingMap& mmap =
+    const_mat_test.matchingMap();
+  e = mmap[n];
+  const_mat_test.mate(n);
+
+  MaxMatching<Graph>::Status stat = 
+    const_mat_test.status(n);
+  const MaxMatching<Graph>::StatusMap& smap =
+    const_mat_test.statusMap();
+  stat = smap[n];
+  const_mat_test.barrier(n);
+}
+
+void checkMaxWeightedMatchingCompile()
+{
+  typedef concepts::Graph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::Edge Edge;
+  typedef Graph::EdgeMap<int> WeightMap;
+
+  Graph g;
+  Node n;
+  Edge e;
+  WeightMap w(g);
+
+  MaxWeightedMatching<Graph> mat_test(g, w);
+  const MaxWeightedMatching<Graph>&
+    const_mat_test = mat_test;
+
+  mat_test.init();
+  mat_test.start();
+  mat_test.run();
+  
+  const_mat_test.matchingWeight();
+  const_mat_test.matchingSize();
+  const_mat_test.matching(e);
+  const_mat_test.matching(n);
+  const MaxWeightedMatching<Graph>::MatchingMap& mmap =
+    const_mat_test.matchingMap();
+  e = mmap[n];
+  const_mat_test.mate(n);
+  
+  int k = 0;
+  const_mat_test.dualValue();
+  const_mat_test.nodeValue(n);
+  const_mat_test.blossomNum();
+  const_mat_test.blossomSize(k);
+  const_mat_test.blossomValue(k);
+}
+
+void checkMaxWeightedPerfectMatchingCompile()
+{
+  typedef concepts::Graph Graph;
+  typedef Graph::Node Node;
+  typedef Graph::Edge Edge;
+  typedef Graph::EdgeMap<int> WeightMap;
+
+  Graph g;
+  Node n;
+  Edge e;
+  WeightMap w(g);
+
+  MaxWeightedPerfectMatching<Graph> mat_test(g, w);
+  const MaxWeightedPerfectMatching<Graph>&
+    const_mat_test = mat_test;
+
+  mat_test.init();
+  mat_test.start();
+  mat_test.run();
+  
+  const_mat_test.matchingWeight();
+  const_mat_test.matching(e);
+  const_mat_test.matching(n);
+  const MaxWeightedPerfectMatching<Graph>::MatchingMap& mmap =
+    const_mat_test.matchingMap();
+  e = mmap[n];
+  const_mat_test.mate(n);
+  
+  int k = 0;
+  const_mat_test.dualValue();
+  const_mat_test.nodeValue(n);
+  const_mat_test.blossomNum();
+  const_mat_test.blossomSize(k);
+  const_mat_test.blossomValue(k);
+}
+
 void checkMatching(const SmartGraph& graph,
                    const MaxMatching<SmartGraph>& mm) {
@@ -121,7 +235,7 @@
 
   for (NodeIt n(graph); n != INVALID; ++n) {
-    check(mm.decomposition(n) == MaxMatching<SmartGraph>::EVEN ||
+    check(mm.status(n) == MaxMatching<SmartGraph>::EVEN ||
           mm.matching(n) != INVALID, "Wrong Gallai-Edmonds decomposition");
-    if (mm.decomposition(n) == MaxMatching<SmartGraph>::ODD) {
+    if (mm.status(n) == MaxMatching<SmartGraph>::ODD) {
       ++barrier_num;
     } else {
@@ -136,14 +250,14 @@
       ++num;
     }
-    check(mm.decomposition(graph.u(e)) != MaxMatching<SmartGraph>::EVEN ||
-          mm.decomposition(graph.v(e)) != MaxMatching<SmartGraph>::MATCHED,
+    check(mm.status(graph.u(e)) != MaxMatching<SmartGraph>::EVEN ||
+          mm.status(graph.v(e)) != MaxMatching<SmartGraph>::MATCHED,
           "Wrong Gallai-Edmonds decomposition");
 
-    check(mm.decomposition(graph.v(e)) != MaxMatching<SmartGraph>::EVEN ||
-          mm.decomposition(graph.u(e)) != MaxMatching<SmartGraph>::MATCHED,
+    check(mm.status(graph.v(e)) != MaxMatching<SmartGraph>::EVEN ||
+          mm.status(graph.u(e)) != MaxMatching<SmartGraph>::MATCHED,
           "Wrong Gallai-Edmonds decomposition");
 
-    if (mm.decomposition(graph.u(e)) != MaxMatching<SmartGraph>::ODD &&
-        mm.decomposition(graph.v(e)) != MaxMatching<SmartGraph>::ODD) {
+    if (mm.status(graph.u(e)) != MaxMatching<SmartGraph>::ODD &&
+        mm.status(graph.v(e)) != MaxMatching<SmartGraph>::ODD) {
       comp.join(graph.u(e), graph.v(e));
     }
@@ -153,5 +267,5 @@
   int odd_comp_num = 0;
   for (NodeIt n(graph); n != INVALID; ++n) {
-    if (mm.decomposition(n) != MaxMatching<SmartGraph>::ODD) {
+    if (mm.status(n) != MaxMatching<SmartGraph>::ODD) {
       int root = comp.find(n);
       if (comp_root.find(root) == comp_root.end()) {
