Index: src/lemon/concept/graph.h
===================================================================
--- src/lemon/concept/graph.h	(revision 989)
+++ src/lemon/concept/graph.h	(revision 1030)
@@ -18,5 +18,5 @@
 #define LEMON_CONCEPT_GRAPH_H
 
-///\ingroup concept
+///\ingroup graph_concepts
 ///\file
 ///\brief Declaration of Graph.
@@ -30,5 +30,5 @@
   namespace concept {
     
-    /// \addtogroup concept
+    /// \addtogroup graph_concepts
     /// @{
 
Index: src/lemon/concept/graph_component.h
===================================================================
--- src/lemon/concept/graph_component.h	(revision 1022)
+++ src/lemon/concept/graph_component.h	(revision 1030)
@@ -15,5 +15,5 @@
  */
 
-///\ingroup concept
+///\ingroup graph_concepts
 ///\file
 ///\brief The graph components.
@@ -29,20 +29,30 @@
   namespace concept {
 
+    /// \addtogroup graph_concepts
+    /// @{
 
     /****************   Graph iterator concepts   ****************/
 
-    /// Skeleton class for graph Node and Edge
-
-    /// \note Because Node and Edge are forbidden to inherit from the same
-    /// base class, this is a template. For Node you should instantiate it
-    /// with character 'n' and for Edge with 'e'.
-
-    template<char _selector>
+    /// Skeleton class for graph Node and Edge types
+
+    /// This class describes the interface of Node and Edge (and UndirEdge
+    /// 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:
       /// Default constructor.
       
-      /// @warning The default constructor sets the item
-      /// to an undefined value.
+      /// \warning The default constructor is not required to set
+      /// the item to some well-defined value. So you should consider it
+      /// as uninitialized.
       GraphItem() {}
       /// Copy constructor.
@@ -72,7 +82,15 @@
       bool operator!=(GraphItem) const { return false; }
 
-      // Technical requirement. Do we really need this?
-      //      bool operator<(GraphItem) const { return false; }
-
+      /// 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.
+      ///
+      /// \bug This is a technical requirement. Do we really need this?
+      bool operator<(GraphItem) const { return false; }
 
       template<typename _GraphItem>
@@ -89,4 +107,5 @@
 	  b = (ia == ib) && (ia != ib);
 	  b = (ia == INVALID) && (ib != INVALID);
+	  b = (ia < ib);
 	}
 
@@ -95,4 +114,19 @@
       };
     };
+
+    /// A type describing the concept of graph node
+
+    /// This is an instantiation of \ref GraphItem which can be used as a
+    /// Node subtype in graph skeleton definitions
+    typedef GraphItem<'n'> GraphNode;
+
+    /// A type describing the concept of graph edge
+
+    /// This is an instantiation of \ref GraphItem which can be used as a
+    /// Edge subtype in graph skeleton definitions
+    typedef GraphItem<'e'> GraphEdge;
+
+
+    /**************** Basic features of graphs ****************/
 
     /// An empty base graph class.
@@ -630,4 +664,9 @@
 
 
+    /// Class describing the concept of graph maps
+
+    /// This class describes the common interface of the graph maps
+    /// (NodeMap, EdgeMap), that is \ref maps "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> {
@@ -805,4 +844,6 @@
     };
 
+    /// @}
+
   }
 
Index: src/lemon/concept/undir_graph.h
===================================================================
--- src/lemon/concept/undir_graph.h	(revision 1022)
+++ src/lemon/concept/undir_graph.h	(revision 1030)
@@ -18,5 +18,5 @@
  */
 
-///\ingroup concept
+///\ingroup graph_concepts
 ///\file
 ///\brief Undirected graphs and components of.
@@ -31,5 +31,60 @@
   namespace concept {
 
-    /// \todo to be done
+    /// \addtogroup graph_concepts
+    /// @{
+
+
+    /// Skeleton class which describes an edge with direction in \ref
+    /// UndirGraph "undirected graph".
+    template <typename UndirEdge>
+    class UndirGraphEdge : public UndirEdge {
+    public:
+
+      /// \e
+      UndirGraphEdge() {}
+
+      /// \e
+      UndirGraphEdge(const UndirGraphEdge&) {}
+
+      /// \e
+      UndirGraphEdge(Invalid) {}
+
+      /// \brief Constructs a directed version of an undirected edge
+      ///
+      /// \param forward If \c true the direction of the contructed edge
+      /// is the same as the inherent direction of the \c undir_edge; if
+      /// \c false --- the opposite.
+      UndirGraphEdge(UndirEdge undir_edge, bool forward) {
+	ignore_unused_variable_warning(undir_edge);
+	ignore_unused_variable_warning(forward);
+      }
+
+      /// \e
+      UndirGraphEdge& operator=(UndirGraphEdge) { return *this; }
+
+      /// \e
+      bool operator==(UndirGraphEdge) const { return true; }
+      /// \e
+      bool operator!=(UndirGraphEdge) const { return false; }
+
+      /// \e
+      bool operator<(UndirGraphEdge) const { return false; }
+
+      template <typename Edge>
+      struct Constraints {
+	void constraints() {
+	  /// \bug This should be is_base_and_derived ...
+	  UndirEdge ue = e;
+	  ue = e;
+	  Edge forward(ue, true);
+	  Edge backward(ue, false);
+
+	  ignore_unused_variable_warning(forward);
+	  ignore_unused_variable_warning(backward);
+	}
+	Edge e;
+      };
+    };
+    
 
     struct BaseIterableUndirGraphConcept {
@@ -44,19 +99,27 @@
 	void constraints() {
 	  checkConcept<BaseIterableGraphComponent, Graph>();
-	  checkConcept<GraphItem<'u'>, UndirEdge >();
-
-	  /// \bug this should be base_and_derived:
-	  UndirEdge ue = e;
-	  ue = e;
-
+	  checkConcept<GraphItem<>, UndirEdge>();
+	  checkConcept<UndirGraphEdge<UndirEdge>, Edge>();
+
+	  graph.first(ue);
+	  graph.next(ue);
+
+	  const_constraints();
+	}
+	void const_constraints() {
 	  Node n;
 	  n = graph.target(ue);
 	  n = graph.source(ue);
-
-	  graph.first(ue);
-	  graph.next(ue);
-	}
-	const Graph &graph;
+	  n = graph.oppositeNode(n0, ue);
+
+	  bool b;
+	  b = graph.forward(e);
+	  ignore_unused_variable_warning(b);
+	}
+
+	Graph graph;
 	Edge e;
+	Node n0;
+	UndirEdge ue;
       };
 
@@ -77,8 +140,8 @@
 	  typedef typename Graph::UndirEdge UndirEdge;
 	  typedef typename Graph::UndirEdgeIt UndirEdgeIt;
-	  typedef typename Graph::UndirIncEdgeIt UndirIncEdgeIt;
+	  typedef typename Graph::IncEdgeIt IncEdgeIt;
 
 	  checkConcept<GraphIterator<Graph, UndirEdge>, UndirEdgeIt>();
-	  checkConcept<GraphIncIterator<Graph, UndirEdge>, UndirIncEdgeIt>();
+	  checkConcept<GraphIncIterator<Graph, UndirEdge>, IncEdgeIt>();
 	}
       };
@@ -146,6 +209,225 @@
     };
 
+    /// 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 couse.
+    ///
+    /// In LEMON undirected graphs also fulfill the concept of directed
+    /// graphs (\ref lemon::concept::Graph "Graph Concept"). For
+    /// explanation of this and more see also the page \ref undir_graphs,
+    /// a tutorial about undirected graphs.
+
     class UndirGraph {
     public:
+
+      /// Type describing a node in the graph
+      typedef GraphNode Node;
+
+      /// Type describing an undirected edge
+      typedef GraphItem<'u'> UndirEdge;
+
+      /// Type describing an UndirEdge with direction
+#ifndef DOXYGEN
+      typedef UndirGraphEdge<UndirEdge> Edge;
+#else
+      typedef UndirGraphEdge Edge;
+#endif
+
+      /// Iterator type which iterates over all nodes
+#ifndef DOXYGEN
+      typedef GraphIterator<UndirGraph, Node> NodeIt;
+#else
+      typedef GraphIterator NodeIt;
+#endif
+
+      /// Iterator type which iterates over all undirected edges
+#ifndef DOXYGEN
+      typedef GraphIterator<UndirGraph, UndirEdge> UndirEdgeIt;
+#else
+      typedef GraphIterator UndirEdgeIt;
+#endif
+
+      /// Iterator type which iterates over all directed edges.
+
+      /// Iterator type which iterates over all edges (each undirected
+      /// edge occurs twice with both directions.
+#ifndef DOXYGEN
+      typedef GraphIterator<UndirGraph, Edge> EdgeIt;
+#else
+      typedef GraphIterator EdgeIt;
+#endif
+
+
+      /// Iterator of undirected edges incident to a node
+#ifndef DOXYGEN
+      typedef GraphIncIterator<UndirGraph, UndirEdge, 'u'> IncEdgeIt;
+#else
+      typedef GraphIncIterator IncEdgeIt;
+#endif
+
+      /// Iterator of edges incoming to a node
+#ifndef DOXYGEN
+      typedef GraphIncIterator<UndirGraph, Edge, 'i'> InEdgeIt;
+#else
+      typedef GraphIncIterator InEdgeIt;
+#endif
+
+      /// Iterator of edges outgoing from a node
+#ifndef DOXYGEN
+      typedef GraphIncIterator<UndirGraph, Edge, 'o'> OutEdgeIt;
+#else
+      typedef GraphIncIterator OutEdgeIt;
+#endif
+
+      /// NodeMap template
+#ifdef DOXYGEN
+      typedef GraphMap NodeMap<T>;
+#endif
+
+      /// UndirEdgeMap template
+#ifdef DOXYGEN
+      typedef GraphMap UndirEdgeMap<T>;
+#endif
+
+      /// EdgeMap template
+#ifdef DOXYGEN
+      typedef GraphMap EdgeMap<T>;
+#endif
+
+      template <typename T>
+      class NodeMap : public GraphMap<UndirGraph, Node, T> {
+	typedef GraphMap<UndirGraph, Node, T> Parent;
+      public:
+
+	explicit NodeMap(const UndirGraph &g) : Parent(g) {}
+	NodeMap(const UndirGraph &g, T t) : Parent(g, t) {}
+      };
+
+      template <typename T>
+      class UndirEdgeMap : public GraphMap<UndirGraph, UndirEdge, T> {
+	typedef GraphMap<UndirGraph, UndirEdge, T> Parent;
+      public:
+
+	explicit UndirEdgeMap(const UndirGraph &g) : Parent(g) {}
+	UndirEdgeMap(const UndirGraph &g, T t) : Parent(g, t) {}
+      };
+
+      template <typename T>
+      class EdgeMap : public GraphMap<UndirGraph, Edge, T> {
+	typedef GraphMap<UndirGraph, Edge, T> Parent;
+      public:
+
+	explicit EdgeMap(const UndirGraph &g) : Parent(g) {}
+	EdgeMap(const UndirGraph &g, T t) : Parent(g, t) {}
+      };
+
+      /// Is the Edge oriented "forward"?
+
+      /// Returns whether the given directed edge is same orientation as
+      /// the corresponding undirected edge.
+      ///
+      /// \todo "What does the direction of an undirected edge mean?"
+      bool forward(Edge) const { return true; }
+
+      /// Opposite node on an edge
+
+      /// \return the opposite of the given Node on the given Edge
+      ///
+      /// \todo What should we do if given Node and Edge are not incident?
+      Node oppositeNode(Node, UndirEdge) const { return INVALID; }
+
+      /// First node of the undirected edge.
+
+      /// \return the first node of the given UndirEdge.
+      ///
+      /// Naturally undirectected 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 "forward" direction
+      /// of the directed versions of the edges.
+      /// \sa forward
+      Node source(UndirEdge) const { return INVALID; }
+
+      /// Second node of the undirected edge.
+      Node target(UndirEdge) const { return INVALID; }
+
+      /// Source node of the directed edge.
+      Node source(Edge) const { return INVALID; }
+
+      /// Target node of the directed edge.
+      Node target(Edge) const { return INVALID; }
+
+      /// First node of the graph
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void first(Node&) const {}
+      /// Next node of the graph
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void next(Node&) const {}
+
+      /// First undirected edge of the graph
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void first(UndirEdge&) const {}
+      /// Next undirected edge of the graph
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void next(UndirEdge&) const {}
+
+      /// First directed edge of the graph
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void first(Edge&) const {}
+      /// Next directed edge of the graph
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void next(Edge&) const {}
+
+      /// First outgoing edge from a given node
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void firstOut(Edge&, Node) const {}
+      /// Next outgoing edge to a node
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void nextOut(Edge&) const {}
+
+      /// First incoming edge to a given node
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void firstIn(Edge&, Node) const {}
+      /// Next incoming edge to a node
+
+      /// \note This method is part of so called \ref
+      /// developpers_interface "Developpers' interface", so it shouldn't
+      /// be used in an end-user program.
+      void nextIn(Edge&) const {}
+
 
       template <typename Graph>
@@ -191,4 +473,6 @@
     };
 
+    /// @}
+
   }
 
Index: src/lemon/iterable_graph_extender.h
===================================================================
--- src/lemon/iterable_graph_extender.h	(revision 1022)
+++ src/lemon/iterable_graph_extender.h	(revision 1030)
@@ -158,5 +158,5 @@
     };
 
-    class UndirIncEdgeIt : public UndirEdge { 
+    class IncEdgeIt : public UndirEdge { 
       const Graph* graph;
       bool forward;
@@ -166,9 +166,9 @@
     public:
 
-      UndirIncEdgeIt() { }
-
-      UndirIncEdgeIt(Invalid i) : UndirEdge(i), forward(false) { }
-
-      explicit UndirIncEdgeIt(const Graph& _graph, const Node &n)
+      IncEdgeIt() { }
+
+      IncEdgeIt(Invalid i) : UndirEdge(i), forward(false) { }
+
+      explicit IncEdgeIt(const Graph& _graph, const Node &n)
 	: graph(&_graph)
       {
@@ -177,11 +177,11 @@
 
       // FIXME: Do we need this type of constructor here?
-      // UndirIncEdgeIt(const Graph& _graph, const Edge& e) : 
+      // IncEdgeIt(const Graph& _graph, const Edge& e) : 
       //   UndirEdge(e), graph(&_graph), forward(_graph.forward(e)) { }
       // or
-      // UndirIncEdgeIt(const Graph& _graph, const Node& n,
+      // IncEdgeIt(const Graph& _graph, const Node& n,
       //    Const UndirEdge &e) ... ?
 
-      UndirIncEdgeIt& operator++() {
+      IncEdgeIt& operator++() {
 	graph->_dirNextOut(*this);
 	return *this; 
@@ -189,5 +189,5 @@
     };
 
-    Node source(const UndirIncEdgeIt &e) const {
+    Node source(const IncEdgeIt &e) const {
       return _dirSource(e);
     }
@@ -198,5 +198,5 @@
 
     /// Target of the given Edge.
-    Node target(const UndirIncEdgeIt &e) const {
+    Node target(const IncEdgeIt &e) const {
       return _dirTarget(e);
     }
Index: src/lemon/undir_graph_extender.h
===================================================================
--- src/lemon/undir_graph_extender.h	(revision 1021)
+++ src/lemon/undir_graph_extender.h	(revision 1030)
@@ -109,5 +109,5 @@
     bool forward(const Edge &e) const { return e.forward; }
 
-    Node oppsiteNode(const Node &n, const Edge &e) const {
+    Node oppositeNode(const Node &n, const UndirEdge &e) const {
       if( n == Parent::source(e))
 	return Parent::target(e);
Index: src/test/undir_graph_test.cc
===================================================================
--- src/test/undir_graph_test.cc	(revision 1022)
+++ src/test/undir_graph_test.cc	(revision 1030)
@@ -34,4 +34,6 @@
   checkConcept<ErasableUndirGraph, Graph>();
 
+  checkConcept<UndirGraph, UndirGraph>();
+
   return 0;
 }
