Index: lemon/bellman_ford.h
===================================================================
--- lemon/bellman_ford.h	(revision 1270)
+++ lemon/bellman_ford.h	(revision 1337)
@@ -30,4 +30,5 @@
 #include <lemon/maps.h>
 #include <lemon/path.h>
+#include <lemon/bits/stl_iterators.h>
 
 #include <limits>
@@ -690,4 +691,19 @@
       int _index;
     };
+
+    /// \brief Gets the collection of the active nodes.
+    ///
+    /// This function can be used for iterating on the active nodes of the
+    /// Bellman-Ford algorithm after the last phase.
+    /// These nodes should be checked in the next phase to
+    /// find augmenting arcs outgoing from them.
+    /// It returns a wrapped ActiveIt, which looks
+    /// like an STL container (by having begin() and end())
+    /// which you can use in range-based for loops, STL algorithms, etc.
+    LemonRangeWrapper1<ActiveIt, BellmanFord>
+    activeNodes() const {
+      return LemonRangeWrapper1<ActiveIt, BellmanFord>(*this);
+    }
+
 
     /// \name Query Functions
Index: lemon/bits/edge_set_extender.h
===================================================================
--- lemon/bits/edge_set_extender.h	(revision 1270)
+++ lemon/bits/edge_set_extender.h	(revision 1337)
@@ -114,4 +114,7 @@
     };
 
+    LemonRangeWrapper1<NodeIt, Digraph> nodes() const {
+      return LemonRangeWrapper1<NodeIt, Digraph>(*this);
+    }
 
     class ArcIt : public Arc {
@@ -137,4 +140,7 @@
     };
 
+    LemonRangeWrapper1<ArcIt, Digraph> arcs() const {
+      return LemonRangeWrapper1<ArcIt, Digraph>(*this);
+    }
 
     class OutArcIt : public Arc {
@@ -161,4 +167,7 @@
     };
 
+    LemonRangeWrapper2<OutArcIt, Digraph, Node> outArcs(const Node& u) const {
+      return LemonRangeWrapper2<OutArcIt, Digraph, Node>(*this, u);
+    }
 
     class InArcIt : public Arc {
@@ -184,4 +193,8 @@
 
     };
+
+    LemonRangeWrapper2<InArcIt, Digraph, Node> inArcs(const Node& u) const {
+      return LemonRangeWrapper2<InArcIt, Digraph, Node>(*this, u);
+    }
 
     // \brief Base node of the iterator
@@ -373,4 +386,7 @@
     };
 
+    LemonRangeWrapper1<NodeIt, Graph> nodes() const {
+      return LemonRangeWrapper1<NodeIt, Graph>(*this);
+    }
 
     class ArcIt : public Arc {
@@ -396,4 +412,7 @@
     };
 
+    LemonRangeWrapper1<ArcIt, Graph> arcs() const {
+      return LemonRangeWrapper1<ArcIt, Graph>(*this);
+    }
 
     class OutArcIt : public Arc {
@@ -420,4 +439,7 @@
     };
 
+    LemonRangeWrapper2<OutArcIt, Graph, Node> outArcs(const Node& u) const {
+      return LemonRangeWrapper2<OutArcIt, Graph, Node>(*this, u);
+    }
 
     class InArcIt : public Arc {
@@ -444,4 +466,7 @@
     };
 
+    LemonRangeWrapper2<InArcIt, Graph, Node> inArcs(const Node& u) const {
+      return LemonRangeWrapper2<InArcIt, Graph, Node>(*this, u);
+    }
 
     class EdgeIt : public Parent::Edge {
@@ -466,4 +491,8 @@
 
     };
+
+    LemonRangeWrapper1<EdgeIt, Graph> edges() const {
+      return LemonRangeWrapper1<EdgeIt, Graph>(*this);
+    }
 
     class IncEdgeIt : public Parent::Edge {
@@ -491,4 +520,8 @@
       }
     };
+
+    LemonRangeWrapper2<IncEdgeIt, Graph, Node> incEdges(const Node& u) const {
+      return LemonRangeWrapper2<IncEdgeIt, Graph, Node>(*this, u);
+    }
 
     // \brief Base node of the iterator
Index: lemon/bits/graph_adaptor_extender.h
===================================================================
--- lemon/bits/graph_adaptor_extender.h	(revision 1270)
+++ lemon/bits/graph_adaptor_extender.h	(revision 1337)
@@ -86,4 +86,7 @@
     };
 
+    LemonRangeWrapper1<NodeIt, Adaptor> nodes() const {
+      return LemonRangeWrapper1<NodeIt, Adaptor>(*this);
+    }
 
     class ArcIt : public Arc {
@@ -108,4 +111,8 @@
 
     };
+
+    LemonRangeWrapper1<ArcIt, Adaptor> arcs() const {
+      return LemonRangeWrapper1<ArcIt, Adaptor>(*this);
+    }
 
 
@@ -133,4 +140,8 @@
     };
 
+    LemonRangeWrapper2<OutArcIt, Adaptor, Node> outArcs(const Node& u) const {
+      return LemonRangeWrapper2<OutArcIt, Adaptor, Node>(*this, u);
+    }
+
 
     class InArcIt : public Arc {
@@ -156,4 +167,8 @@
 
     };
+
+    LemonRangeWrapper2<InArcIt, Adaptor, Node> inArcs(const Node& u) const {
+      return LemonRangeWrapper2<InArcIt, Adaptor, Node>(*this, u);
+    }
 
     Node baseNode(const OutArcIt &e) const {
@@ -255,4 +270,8 @@
     };
 
+    LemonRangeWrapper1<NodeIt, Adaptor> nodes() const {
+      return LemonRangeWrapper1<NodeIt, Adaptor>(*this);
+    }
+
 
     class ArcIt : public Arc {
@@ -277,4 +296,8 @@
 
     };
+
+    LemonRangeWrapper1<ArcIt, Adaptor> arcs() const {
+      return LemonRangeWrapper1<ArcIt, Adaptor>(*this);
+    }
 
 
@@ -302,4 +325,8 @@
     };
 
+    LemonRangeWrapper2<OutArcIt, Adaptor, Node> outArcs(const Node& u) const {
+      return LemonRangeWrapper2<OutArcIt, Adaptor, Node>(*this, u);
+    }
+
 
     class InArcIt : public Arc {
@@ -326,4 +353,8 @@
     };
 
+    LemonRangeWrapper2<InArcIt, Adaptor, Node> inArcs(const Node& u) const {
+      return LemonRangeWrapper2<InArcIt, Adaptor, Node>(*this, u);
+    }
+
     class EdgeIt : public Parent::Edge {
       const Adaptor* _adaptor;
@@ -347,4 +378,9 @@
 
     };
+
+    LemonRangeWrapper1<EdgeIt, Adaptor> edges() const {
+      return LemonRangeWrapper1<EdgeIt, Adaptor>(*this);
+    }
+
 
     class IncEdgeIt : public Edge {
@@ -373,4 +409,9 @@
     };
 
+    LemonRangeWrapper2<IncEdgeIt, Adaptor, Node> incEdges(const Node& u) const {
+      return LemonRangeWrapper2<IncEdgeIt, Adaptor, Node>(*this, u);
+    }
+
+
     Node baseNode(const OutArcIt &a) const {
       return Parent::source(a);
Index: lemon/bits/graph_extender.h
===================================================================
--- lemon/bits/graph_extender.h	(revision 1270)
+++ lemon/bits/graph_extender.h	(revision 1336)
@@ -28,4 +28,6 @@
 #include <lemon/concepts/maps.h>
 
+#include <lemon/bits/stl_iterators.h>
+
 //\ingroup graphbits
 //\file
@@ -117,4 +119,8 @@
     };
 
+    LemonRangeWrapper1<NodeIt, Digraph> nodes() const {
+      return LemonRangeWrapper1<NodeIt, Digraph>(*this);
+    }
+
 
     class ArcIt : public Arc {
@@ -139,4 +145,8 @@
 
     };
+
+    LemonRangeWrapper1<ArcIt, Digraph> arcs() const {
+      return LemonRangeWrapper1<ArcIt, Digraph>(*this);
+    }
 
 
@@ -164,4 +174,8 @@
     };
 
+    LemonRangeWrapper2<OutArcIt, Digraph, Node> outArcs(const Node& u) const {
+      return LemonRangeWrapper2<OutArcIt, Digraph, Node>(*this, u);
+    }
+
 
     class InArcIt : public Arc {
@@ -187,4 +201,8 @@
 
     };
+
+    LemonRangeWrapper2<InArcIt, Digraph, Node> inArcs(const Node& u) const {
+      return LemonRangeWrapper2<InArcIt, Digraph, Node>(*this, u);
+    }
 
     // \brief Base node of the iterator
@@ -437,4 +455,8 @@
     };
 
+    LemonRangeWrapper1<NodeIt, Graph> nodes() const {
+      return LemonRangeWrapper1<NodeIt, Graph>(*this);
+    }
+
 
     class ArcIt : public Arc {
@@ -459,4 +481,8 @@
 
     };
+
+    LemonRangeWrapper1<ArcIt, Graph> arcs() const {
+      return LemonRangeWrapper1<ArcIt, Graph>(*this);
+    }
 
 
@@ -484,4 +510,8 @@
     };
 
+    LemonRangeWrapper2<OutArcIt, Graph, Node> outArcs(const Node& u) const {
+      return LemonRangeWrapper2<OutArcIt, Graph, Node>(*this, u);
+    }
+
 
     class InArcIt : public Arc {
@@ -508,4 +538,8 @@
     };
 
+    LemonRangeWrapper2<InArcIt, Graph, Node> inArcs(const Node& u) const {
+      return LemonRangeWrapper2<InArcIt, Graph, Node>(*this, u);
+    }
+
 
     class EdgeIt : public Parent::Edge {
@@ -530,4 +564,9 @@
 
     };
+
+    LemonRangeWrapper1<EdgeIt, Graph> edges() const {
+      return LemonRangeWrapper1<EdgeIt, Graph>(*this);
+    }
+
 
     class IncEdgeIt : public Parent::Edge {
@@ -555,4 +594,9 @@
       }
     };
+
+    LemonRangeWrapper2<IncEdgeIt, Graph, Node> incEdges(const Node& u) const {
+      return LemonRangeWrapper2<IncEdgeIt, Graph, Node>(*this, u);
+    }
+
 
     // \brief Base node of the iterator
@@ -904,4 +948,9 @@
     };
 
+    LemonRangeWrapper1<NodeIt, BpGraph> nodes() const {
+      return LemonRangeWrapper1<NodeIt, BpGraph>(*this);
+    }
+
+
     class RedNodeIt : public RedNode {
       const BpGraph* _graph;
@@ -926,4 +975,9 @@
     };
 
+    LemonRangeWrapper1<RedNodeIt, BpGraph> redNodes() const {
+      return LemonRangeWrapper1<RedNodeIt, BpGraph>(*this);
+    }
+
+
     class BlueNodeIt : public BlueNode {
       const BpGraph* _graph;
@@ -948,4 +1002,9 @@
     };
 
+    LemonRangeWrapper1<BlueNodeIt, BpGraph> blueNodes() const {
+      return LemonRangeWrapper1<BlueNodeIt, BpGraph>(*this);
+    }
+
+
 
     class ArcIt : public Arc {
@@ -970,4 +1029,8 @@
 
     };
+
+    LemonRangeWrapper1<ArcIt, BpGraph> arcs() const {
+      return LemonRangeWrapper1<ArcIt, BpGraph>(*this);
+    }
 
 
@@ -995,4 +1058,8 @@
     };
 
+    LemonRangeWrapper2<OutArcIt, BpGraph, Node> outArcs(const Node& u) const {
+      return LemonRangeWrapper2<OutArcIt, BpGraph, Node>(*this, u);
+    }
+
 
     class InArcIt : public Arc {
@@ -1019,4 +1086,8 @@
     };
 
+    LemonRangeWrapper2<InArcIt, BpGraph, Node> inArcs(const Node& u) const {
+      return LemonRangeWrapper2<InArcIt, BpGraph, Node>(*this, u);
+    }
+
 
     class EdgeIt : public Parent::Edge {
@@ -1041,4 +1112,9 @@
 
     };
+
+    LemonRangeWrapper1<EdgeIt, BpGraph> edges() const {
+      return LemonRangeWrapper1<EdgeIt, BpGraph>(*this);
+    }
+
 
     class IncEdgeIt : public Parent::Edge {
@@ -1066,4 +1142,9 @@
       }
     };
+
+    LemonRangeWrapper2<IncEdgeIt, BpGraph, Node> incEdges(const Node& u) const {
+      return LemonRangeWrapper2<IncEdgeIt, BpGraph, Node>(*this, u);
+    }
+
 
     // \brief Base node of the iterator
Index: lemon/bits/path_dump.h
===================================================================
--- lemon/bits/path_dump.h	(revision 1270)
+++ lemon/bits/path_dump.h	(revision 1338)
@@ -62,5 +62,5 @@
       }
 
-      operator const typename Digraph::Arc() const {
+      operator typename Digraph::Arc() const {
         return path->predMap[current];
       }
Index: lemon/bits/stl_iterators.h
===================================================================
--- lemon/bits/stl_iterators.h	(revision 1339)
+++ lemon/bits/stl_iterators.h	(revision 1339)
@@ -0,0 +1,99 @@
+/* -*- mode: C++; indent-tabs-mode: nil; -*-
+ */
+
+#ifndef STL_ITERATORS_H_
+#define STL_ITERATORS_H_
+
+#include <lemon/core.h>
+
+namespace lemon {
+
+  /// \brief Template to make STL iterators from Lemon iterators.
+  ///
+  /// This template makes an STL iterator from a Lemon iterator
+  /// by adding the missing features.
+  /// It inherits from \c std::iterator to make \c iterator_concept work
+  /// (so that STL algorithms work).
+  /// \c T should be the lemon iterator to be decorated.
+  template<class T>
+  struct LemonItWrapper
+      : public T, public std::iterator<std::input_iterator_tag, T> {
+
+    LemonItWrapper(const T &x) : T(x) {}
+
+    //Lemon iterators don't have operator*, (because they rather
+    //inherit from their "value_type"),
+    //so we add one that just returns the object.
+    const T& operator*() const {
+      return static_cast<const T&>(*this);
+    }
+
+    //I can't think of any use case for this with Lemon iterators,
+    //but maybe it should be included for completeness.
+    const T* operator->() {
+      return static_cast<const T*>(this);
+    }
+
+    //Lemon iterators don't have postincrement.
+    void operator++(int) {
+      T::operator++();
+    }
+
+    using T::operator++;
+
+  };
+
+
+  /// \brief A generic wrapper for Lemon iterators for range-based for loops.
+  ///
+  /// This template can be used to create a class
+  /// that has begin() and end() from a Lemon iterator
+  /// (with a 1-parameter constructor)
+  /// to make range-based for loops and STL algorithms work.
+  ///
+  /// \c LIT is the Lemon iterator that will be wrapped
+  /// \c P is the type of the parameter of the constructor of \c LIT.
+  template<class LIT, class P>
+  class LemonRangeWrapper1 {
+    typedef LemonItWrapper<LIT> It;
+    It _begin;
+    
+  public:
+    LemonRangeWrapper1(const P &p) : _begin(LIT(p)) {}
+    It begin() const {
+      return _begin;
+    }
+    It end() const {
+      return It(lemon::INVALID);
+    }
+  };
+
+
+  /// \brief A generic wrapper for Lemon iterators for range-based for loops.
+  ///
+  /// This template can be used to create a class
+  /// that has begin() and end() from a Lemon iterator
+  /// (with a 2-parameter constructor)
+  /// to make range-based for loops and STL algorithms work.
+  ///
+  /// \c LIT is the Lemon iterator that will be wrapped
+  /// \c P1 and \c P2 are the types of the parameters
+  /// of the constructor of \c LIT.
+  template<class LIT, class P1, class P2>
+  class LemonRangeWrapper2 {
+    typedef LemonItWrapper<LIT> It; 
+    It _begin;
+ public:
+    LemonRangeWrapper2(const P1 &p1, const P2 &p2) : _begin(LIT(p1, p2)) {}
+    It begin() const {
+      return _begin;
+    }
+    It end() const {
+      return It(lemon::INVALID);
+    }
+  };
+
+
+}
+
+#endif /* STL_ITERATORS_H_ */
Index: lemon/cbc.cc
===================================================================
--- lemon/cbc.cc	(revision 1270)
+++ lemon/cbc.cc	(revision 1336)
@@ -112,9 +112,9 @@
 
   void CbcMip::_eraseColId(int i) {
-    cols.eraseIndex(i);
+    _cols.eraseIndex(i);
   }
 
   void CbcMip::_eraseRowId(int i) {
-    rows.eraseIndex(i);
+    _rows.eraseIndex(i);
   }
 
Index: lemon/clp.cc
===================================================================
--- lemon/clp.cc	(revision 1270)
+++ lemon/clp.cc	(revision 1336)
@@ -30,6 +30,6 @@
   ClpLp::ClpLp(const ClpLp& other) {
     _prob = new ClpSimplex(*other._prob);
-    rows = other.rows;
-    cols = other.cols;
+    _rows = other._rows;
+    _cols = other._cols;
     _init_temporals();
     messageLevel(MESSAGE_NOTHING);
@@ -104,11 +104,11 @@
 
   void ClpLp::_eraseColId(int i) {
-    cols.eraseIndex(i);
-    cols.shiftIndices(i);
+    _cols.eraseIndex(i);
+    _cols.shiftIndices(i);
   }
 
   void ClpLp::_eraseRowId(int i) {
-    rows.eraseIndex(i);
-    rows.shiftIndices(i);
+    _rows.eraseIndex(i);
+    _rows.shiftIndices(i);
   }
 
Index: lemon/clp.h
===================================================================
--- lemon/clp.h	(revision 1270)
+++ lemon/clp.h	(revision 1336)
@@ -152,8 +152,8 @@
 
     ///Returns the constraint identifier understood by CLP.
-    int clpRow(Row r) const { return rows(id(r)); }
+    int clpRow(Row r) const { return _rows(id(r)); }
 
     ///Returns the variable identifier understood by CLP.
-    int clpCol(Col c) const { return cols(id(c)); }
+    int clpCol(Col c) const { return _cols(id(c)); }
 
   };
Index: lemon/concepts/bpgraph.h
===================================================================
--- lemon/concepts/bpgraph.h	(revision 1270)
+++ lemon/concepts/bpgraph.h	(revision 1336)
@@ -28,4 +28,5 @@
 #include <lemon/concept_check.h>
 #include <lemon/core.h>
+#include <lemon/bits/stl_iterators.h>
 
 namespace lemon {
@@ -222,4 +223,20 @@
       };
 
+      /// \brief Gets the collection of the red nodes of the graph.
+      ///
+      /// This function can be used for iterating on
+      /// the red nodes of the graph. It returns a wrapped RedNodeIt,
+      /// which looks like an STL container (by having begin() and end())
+      /// which you can use in range-based for loops, stl algorithms, etc.
+      /// For example if g is a BpGraph, you can write:
+      ///\code
+      /// for(auto v: g.redNodes())
+      ///   doSomething(v);
+      ///\endcode
+      LemonRangeWrapper1<RedNodeIt, BpGraph> redNodes() const {
+        return LemonRangeWrapper1<RedNodeIt, BpGraph>(*this);
+      }
+
+
       /// Iterator class for the blue nodes.
 
@@ -265,4 +282,20 @@
       };
 
+      /// \brief Gets the collection of the blue nodes of the graph.
+      ///
+      /// This function can be used for iterating on
+      /// the blue nodes of the graph. It returns a wrapped BlueNodeIt,
+      /// which looks like an STL container (by having begin() and end())
+      /// which you can use in range-based for loops, stl algorithms, etc.
+      /// For example if g is a BpGraph, you can write:
+      ///\code
+      /// for(auto v: g.blueNodes())
+      ///   doSomething(v);
+      ///\endcode
+      LemonRangeWrapper1<BlueNodeIt, BpGraph> blueNodes() const {
+        return LemonRangeWrapper1<BlueNodeIt, BpGraph>(*this);
+      }
+
+
       /// Iterator class for the nodes.
 
@@ -307,4 +340,20 @@
         NodeIt& operator++() { return *this; }
       };
+
+      /// \brief Gets the collection of the nodes of the graph.
+      ///
+      /// This function can be used for iterating on
+      /// the nodes of the graph. It returns a wrapped NodeIt,
+      /// which looks like an STL container (by having begin() and end())
+      /// which you can use in range-based for loops, stl algorithms, etc.
+      /// For example if g is a BpGraph, you can write:
+      ///\code
+      /// for(auto v: g.nodes())
+      ///   doSomething(v);
+      ///\endcode
+      LemonRangeWrapper1<NodeIt, BpGraph> nodes() const {
+        return LemonRangeWrapper1<NodeIt, BpGraph>(*this);
+      }
+
 
 
@@ -395,4 +444,21 @@
         EdgeIt& operator++() { return *this; }
       };
+
+      /// \brief Gets the collection of the edges of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// edges of the graph. It returns a wrapped
+      /// EdgeIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, stl algorithms, etc.
+      /// For example if g is a BpGraph, you can write:
+      ///\code
+      /// for(auto e: g.edges())
+      ///   doSomething(e);
+      ///\endcode
+      LemonRangeWrapper1<EdgeIt, BpGraph> edges() const {
+        return LemonRangeWrapper1<EdgeIt, BpGraph>(*this);
+      }
+
 
       /// Iterator class for the incident edges of a node.
@@ -444,4 +510,23 @@
       };
 
+      /// \brief Gets the collection of the incident edges
+      ///  of a certain node of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// incident undirected edges of a certain node of the graph.
+      /// It returns a wrapped
+      /// IncEdgeIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, stl algorithms, etc.
+      /// For example if g is a BpGraph and u is a Node, you can write:
+      ///\code
+      /// for(auto e: g.incEdges(u))
+      ///   doSomething(e);
+      ///\endcode
+      LemonRangeWrapper2<IncEdgeIt, BpGraph, Node> incEdges(const Node& u) const {
+        return LemonRangeWrapper2<IncEdgeIt, BpGraph, Node>(*this, u);
+      }
+
+
       /// The arc type of the graph
 
@@ -540,4 +625,21 @@
       };
 
+      /// \brief Gets the collection of the directed arcs of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// arcs of the graph. It returns a wrapped
+      /// ArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, stl algorithms, etc.
+      /// For example if g is a BpGraph you can write:
+      ///\code
+      /// for(auto a: g.arcs())
+      ///   doSomething(a);
+      ///\endcode
+      LemonRangeWrapper1<ArcIt, BpGraph> arcs() const {
+        return LemonRangeWrapper1<ArcIt, BpGraph>(*this);
+      }
+
+
       /// Iterator class for the outgoing arcs of a node.
 
@@ -588,4 +690,22 @@
       };
 
+      /// \brief Gets the collection of the outgoing directed arcs of a
+      /// certain node of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// outgoing arcs of a certain node of the graph. It returns a wrapped
+      /// OutArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, stl algorithms, etc.
+      /// For example if g is a BpGraph and u is a Node, you can write:
+      ///\code
+      /// for(auto a: g.outArcs(u))
+      ///   doSomething(a);
+      ///\endcode
+      LemonRangeWrapper2<OutArcIt, BpGraph, Node> outArcs(const Node& u) const {
+        return LemonRangeWrapper2<OutArcIt, BpGraph, Node>(*this, u);
+      }
+
+
       /// Iterator class for the incoming arcs of a node.
 
@@ -635,4 +755,22 @@
         InArcIt& operator++() { return *this; }
       };
+
+      /// \brief Gets the collection of the incoming directed arcs of a
+      /// certain node of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// incoming arcs of a certain node of the graph. It returns a wrapped
+      /// InArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, stl algorithms, etc.
+      /// For example if g is a BpGraph and u is a Node, you can write:
+      ///\code
+      /// for(auto a: g.inArcs(u))
+      ///   doSomething(a);
+      ///\endcode
+      LemonRangeWrapper2<InArcIt, BpGraph, Node> inArcs(const Node& u) const {
+        return LemonRangeWrapper2<InArcIt, BpGraph, Node>(*this, u);
+      }
+
 
       /// \brief Standard graph map type for the nodes.
Index: lemon/concepts/digraph.h
===================================================================
--- lemon/concepts/digraph.h	(revision 1271)
+++ lemon/concepts/digraph.h	(revision 1336)
@@ -28,4 +28,5 @@
 #include <lemon/concept_check.h>
 #include <lemon/concepts/graph_components.h>
+#include <lemon/bits/stl_iterators.h>
 
 namespace lemon {
@@ -148,4 +149,23 @@
       };
 
+      /// \brief Gets the collection of the nodes of the digraph.
+      ///
+      /// This function can be used for iterating on
+      /// the nodes of the digraph. It returns a wrapped NodeIt, which looks
+      /// like an STL container (by having begin() and end())
+      /// which you can use in range-based for loops, STL algorithms, etc.
+      /// For example you can write:
+      ///\code
+      /// ListDigraph g;
+      /// for(auto v: g.nodes())
+      ///   doSomething(v);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.nodes().begin(), g.nodes().end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper1<NodeIt, Digraph> nodes() const {
+        return LemonRangeWrapper1<NodeIt, Digraph>(*this);
+      }
+
 
       /// The arc type of the digraph
@@ -238,4 +258,25 @@
       };
 
+      /// \brief Gets the collection of the outgoing arcs of a certain node
+      /// of the digraph.
+      ///
+      /// This function can be used for iterating on the
+      /// outgoing arcs of a certain node of the digraph. It returns a wrapped
+      /// OutArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example if g is a Digraph and u is a node, you can write:
+      ///\code
+      /// for(auto a: g.outArcs(u))
+      ///   doSomething(a);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.outArcs(u).begin(), g.outArcs(u).end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper2<OutArcIt, Digraph, Node> outArcs(const Node& u) const {
+        return LemonRangeWrapper2<OutArcIt, Digraph, Node>(*this, u);
+      }
+
+
       /// Iterator class for the incoming arcs of a node.
 
@@ -283,4 +324,25 @@
       };
 
+      /// \brief Gets the collection of the incoming arcs of a certain node
+      /// of the digraph.
+      ///
+      /// This function can be used for iterating on the
+      /// incoming arcs of a certain node of the digraph. It returns a wrapped
+      /// InArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example if g is a Digraph and u is a node, you can write:
+      ///\code
+      /// for(auto a: g.inArcs(u))
+      ///   doSomething(a);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.inArcs(u).begin(), g.inArcs(u).end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper2<InArcIt, Digraph, Node> inArcs(const Node& u) const {
+        return LemonRangeWrapper2<InArcIt, Digraph, Node>(*this, u);
+      }
+
+
       /// Iterator class for the arcs.
 
@@ -327,4 +389,25 @@
         ArcIt& operator++() { return *this; }
       };
+
+      /// \brief Gets the collection of the arcs of the digraph.
+      ///
+      /// This function can be used for iterating on the
+      /// arcs of the digraph. It returns a wrapped
+      /// ArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example you can write:
+      ///\code
+      /// ListDigraph g;
+      /// for(auto a: g.arcs())
+      ///   doSomething(a);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.arcs().begin(), g.arcs().end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper1<ArcIt, Digraph> arcs() const {
+        return LemonRangeWrapper1<ArcIt, Digraph>(*this);
+      }
+
 
       /// \brief The source node of the arc.
Index: lemon/concepts/graph.h
===================================================================
--- lemon/concepts/graph.h	(revision 1271)
+++ lemon/concepts/graph.h	(revision 1336)
@@ -28,4 +28,5 @@
 #include <lemon/concept_check.h>
 #include <lemon/core.h>
+#include <lemon/bits/stl_iterators.h>
 
 namespace lemon {
@@ -181,4 +182,23 @@
       };
 
+      /// \brief Gets the collection of the nodes of the graph.
+      ///
+      /// This function can be used for iterating on
+      /// the nodes of the graph. It returns a wrapped NodeIt, which looks
+      /// like an STL container (by having begin() and end())
+      /// which you can use in range-based for loops, STL algorithms, etc.
+      /// For example you can write:
+      ///\code
+      /// ListGraph g;
+      /// for(auto v: g.nodes())
+      ///   doSomething(v);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.nodes().begin(), g.nodes().end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper1<NodeIt, Graph> nodes() const {
+        return LemonRangeWrapper1<NodeIt, Graph>(*this);
+      }
+
 
       /// The edge type of the graph
@@ -268,4 +288,25 @@
         EdgeIt& operator++() { return *this; }
       };
+
+      /// \brief Gets the collection of the edges of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// edges of the graph. It returns a wrapped
+      /// EdgeIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example you can write:
+      ///\code
+      /// ListGraph g;
+      /// for(auto e: g.edges())
+      ///   doSomething(e);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.edges().begin(), g.edges().end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper1<EdgeIt, Graph> edges() const {
+        return LemonRangeWrapper1<EdgeIt, Graph>(*this);
+      }
+
 
       /// Iterator class for the incident edges of a node.
@@ -317,4 +358,26 @@
       };
 
+      /// \brief Gets the collection of the incident undirected edges
+      ///  of a certain node of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// incident undirected edges of a certain node of the graph.
+      /// It returns a wrapped
+      /// IncEdgeIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example if g is a Graph and u is a Node, you can write:
+      ///\code
+      /// for(auto e: g.incEdges(u))
+      ///   doSomething(e);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.incEdges(u).begin(), g.incEdges(u).end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper2<IncEdgeIt, Graph, Node> incEdges(const Node& u) const {
+        return LemonRangeWrapper2<IncEdgeIt, Graph, Node>(*this, u);
+      }
+
+
       /// The arc type of the graph
 
@@ -411,4 +474,25 @@
         ArcIt& operator++() { return *this; }
       };
+
+      /// \brief Gets the collection of the directed arcs of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// arcs of the graph. It returns a wrapped
+      /// ArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example you can write:
+      ///\code
+      /// ListGraph g;
+      /// for(auto a: g.arcs())
+      ///   doSomething(a);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.arcs().begin(), g.arcs().end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper1<ArcIt, Graph> arcs() const {
+        return LemonRangeWrapper1<ArcIt, Graph>(*this);
+      }
+
 
       /// Iterator class for the outgoing arcs of a node.
@@ -460,4 +544,25 @@
       };
 
+      /// \brief Gets the collection of the outgoing directed arcs of a
+      /// certain node of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// outgoing arcs of a certain node of the graph. It returns a wrapped
+      /// OutArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example if g is a Graph and u is a Node, you can write:
+      ///\code
+      /// for(auto a: g.outArcs(u))
+      ///   doSomething(a);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.outArcs(u).begin(), g.outArcs(u).end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper2<OutArcIt, Graph, Node> outArcs(const Node& u) const {
+        return LemonRangeWrapper2<OutArcIt, Graph, Node>(*this, u);
+      }
+
+
       /// Iterator class for the incoming arcs of a node.
 
@@ -507,4 +612,24 @@
         InArcIt& operator++() { return *this; }
       };
+
+      /// \brief Gets the collection of the incoming directed arcs of
+      /// a certain node of the graph.
+      ///
+      /// This function can be used for iterating on the
+      /// incoming directed arcs of a certain node of the graph. It returns
+      /// a wrapped InArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example if g is a Graph and u is a Node, you can write:
+      ///\code
+      /// for(auto a: g.inArcs(u))
+      ///   doSomething(a);
+      ///
+      /// //Using an STL algorithm:
+      /// copy(g.inArcs(u).begin(), g.inArcs(u).end(), vect.begin());
+      ///\endcode
+      LemonRangeWrapper2<InArcIt, Graph, Node> inArcs(const Node& u) const {
+        return LemonRangeWrapper2<InArcIt, Graph, Node>(*this, u);
+      }
 
       /// \brief Standard graph map type for the nodes.
Index: lemon/concepts/path.h
===================================================================
--- lemon/concepts/path.h	(revision 1270)
+++ lemon/concepts/path.h	(revision 1336)
@@ -27,4 +27,5 @@
 #include <lemon/core.h>
 #include <lemon/concept_check.h>
+#include <lemon/bits/stl_iterators.h>
 
 namespace lemon {
@@ -116,4 +117,21 @@
       };
 
+      /// \brief Gets the collection of the arcs of the path.
+      ///
+      /// This function can be used for iterating on the
+      /// arcs of the path. It returns a wrapped
+      /// ArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example you can write:
+      ///\code
+      /// for(auto a: p.arcs())
+      ///   doSomething(a);
+      ///\endcode
+      LemonRangeWrapper1<ArcIt, Path> arcs() const {
+        return LemonRangeWrapper1<ArcIt, Path>(*this);
+      }
+
+
       template <typename _Path>
       struct Constraints {
@@ -264,4 +282,21 @@
 
       };
+
+      /// \brief Gets the collection of the arcs of the path.
+      ///
+      /// This function can be used for iterating on the
+      /// arcs of the path. It returns a wrapped
+      /// ArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example you can write:
+      ///\code
+      /// for(auto a: p.arcs())
+      ///   doSomething(a);
+      ///\endcode
+      LemonRangeWrapper1<ArcIt, PathDumper> arcs() const {
+        return LemonRangeWrapper1<ArcIt, PathDumper>(*this);
+      }
+
 
       /// \brief LEMON style iterator for enumerating the arcs of a path
@@ -294,4 +329,22 @@
       };
 
+      /// \brief Gets the collection of the arcs of the path
+      /// in reverse direction.
+      ///
+      /// This function can be used for iterating on the
+      /// arcs of the path in reverse direction. It returns a wrapped
+      /// RevArcIt, which looks like an STL container
+      /// (by having begin() and end()) which you can use in range-based
+      /// for loops, STL algorithms, etc.
+      /// For example you can write:
+      ///\code
+      /// for(auto a: p.revArcs())
+      ///   doSomething(a);
+      ///\endcode
+      LemonRangeWrapper1<RevArcIt, PathDumper> revArcs() const {
+        return LemonRangeWrapper1<RevArcIt, PathDumper>(*this);
+      }
+
+
       template <typename _Path>
       struct Constraints {
Index: lemon/config.h.in
===================================================================
--- lemon/config.h.in	(revision 1340)
+++ lemon/config.h.in	(revision 1343)
@@ -4,4 +4,6 @@
 #define LEMON_VERSION "@PROJECT_VERSION@"
 #cmakedefine LEMON_HAVE_LONG_LONG 1
+
+#cmakedefine LEMON_CXX11 1
 
 #cmakedefine LEMON_WIN32 1
Index: lemon/cplex.cc
===================================================================
--- lemon/cplex.cc	(revision 1347)
+++ lemon/cplex.cc	(revision 1349)
@@ -105,6 +105,6 @@
     int status;
     _prob = CPXcloneprob(cplexEnv(), cplex._prob, &status);
-    rows = cplex.rows;
-    cols = cplex.cols;
+    _rows = cplex._rows;
+    _cols = cplex._cols;
     messageLevel(MESSAGE_NOTHING);
   }
@@ -133,32 +133,35 @@
                          ExprIterator e, Value ub) {
     int i = CPXgetnumrows(cplexEnv(), _prob);
+
+    int rmatbeg = 0;
+    
+    std::vector<int> indices;
+    std::vector<Value> values;
+
+    for(ExprIterator it=b; it!=e; ++it) {
+      indices.push_back(it->first);
+      values.push_back(it->second);
+    }
+
     if (lb == -INF) {
       const char s = 'L';
-      CPXnewrows(cplexEnv(), _prob, 1, &ub, &s, 0, 0);
+      CPXaddrows(cplexEnv(), _prob, 0, 1, values.size(), &ub, &s,
+                 &rmatbeg, &indices.front(), &values.front(), 0, 0);
     } else if (ub == INF) {
       const char s = 'G';
-      CPXnewrows(cplexEnv(), _prob, 1, &lb, &s, 0, 0);
+      CPXaddrows(cplexEnv(), _prob, 0, 1, values.size(), &lb, &s,
+                 &rmatbeg, &indices.front(), &values.front(), 0, 0);
     } else if (lb == ub){
       const char s = 'E';
-      CPXnewrows(cplexEnv(), _prob, 1, &lb, &s, 0, 0);
+      CPXaddrows(cplexEnv(), _prob, 0, 1, values.size(), &lb, &s,
+                 &rmatbeg, &indices.front(), &values.front(), 0, 0);
     } else {
       const char s = 'R';
       double len = ub - lb;
-      CPXnewrows(cplexEnv(), _prob, 1, &lb, &s, &len, 0);
-    }
-
-    std::vector<int> indices;
-    std::vector<int> rowlist;
-    std::vector<Value> values;
-
-    for(ExprIterator it=b; it!=e; ++it) {
-      indices.push_back(it->first);
-      values.push_back(it->second);
-      rowlist.push_back(i);
-    }
-
-    CPXchgcoeflist(cplexEnv(), _prob, values.size(),
-                   &rowlist.front(), &indices.front(), &values.front());
-
+      CPXaddrows(cplexEnv(), _prob, 0, 1, values.size(), &ub, &s,
+                 &rmatbeg, &indices.front(), &values.front(), 0, 0);
+      CPXchgrngval(cplexEnv(), _prob, 1, &i, &len);
+    }
+    
     return i;
   }
@@ -173,10 +176,10 @@
 
   void CplexBase::_eraseColId(int i) {
-    cols.eraseIndex(i);
-    cols.shiftIndices(i);
+    _cols.eraseIndex(i);
+    _cols.shiftIndices(i);
   }
   void CplexBase::_eraseRowId(int i) {
-    rows.eraseIndex(i);
-    rows.shiftIndices(i);
+    _rows.eraseIndex(i);
+    _rows.shiftIndices(i);
   }
 
Index: lemon/glpk.cc
===================================================================
--- lemon/glpk.cc	(revision 1270)
+++ lemon/glpk.cc	(revision 1336)
@@ -39,6 +39,6 @@
     glp_copy_prob(lp, other.lp, GLP_ON);
     glp_create_index(lp);
-    rows = other.rows;
-    cols = other.cols;
+    _rows = other._rows;
+    _cols = other._cols;
     messageLevel(MESSAGE_NOTHING);
   }
@@ -109,11 +109,11 @@
 
   void GlpkBase::_eraseColId(int i) {
-    cols.eraseIndex(i);
-    cols.shiftIndices(i);
+    _cols.eraseIndex(i);
+    _cols.shiftIndices(i);
   }
 
   void GlpkBase::_eraseRowId(int i) {
-    rows.eraseIndex(i);
-    rows.shiftIndices(i);
+    _rows.eraseIndex(i);
+    _rows.shiftIndices(i);
   }
 
Index: lemon/glpk.h
===================================================================
--- lemon/glpk.h	(revision 1270)
+++ lemon/glpk.h	(revision 1336)
@@ -142,8 +142,8 @@
 
     ///Returns the constraint identifier understood by GLPK.
-    int lpxRow(Row r) const { return rows(id(r)); }
+    int lpxRow(Row r) const { return _rows(id(r)); }
 
     ///Returns the variable identifier understood by GLPK.
-    int lpxCol(Col c) const { return cols(id(c)); }
+    int lpxCol(Col c) const { return _cols(id(c)); }
 
 #ifdef DOXYGEN
Index: lemon/list_graph.h
===================================================================
--- lemon/list_graph.h	(revision 1270)
+++ lemon/list_graph.h	(revision 1337)
@@ -49,5 +49,5 @@
     };
 
-    std::vector<NodeT> nodes;
+    std::vector<NodeT> _nodes;
 
     int first_node;
@@ -55,5 +55,5 @@
     int first_free_node;
 
-    std::vector<ArcT> arcs;
+    std::vector<ArcT> _arcs;
 
     int first_free_arc;
@@ -98,13 +98,13 @@
 
     ListDigraphBase()
-      : nodes(), first_node(-1),
-        first_free_node(-1), arcs(), first_free_arc(-1) {}
-
-
-    int maxNodeId() const { return nodes.size()-1; }
-    int maxArcId() const { return arcs.size()-1; }
-
-    Node source(Arc e) const { return Node(arcs[e.id].source); }
-    Node target(Arc e) const { return Node(arcs[e.id].target); }
+      : _nodes(), first_node(-1),
+        first_free_node(-1), _arcs(), first_free_arc(-1) {}
+
+
+    int maxNodeId() const { return _nodes.size()-1; }
+    int maxArcId() const { return _arcs.size()-1; }
+
+    Node source(Arc e) const { return Node(_arcs[e.id].source); }
+    Node target(Arc e) const { return Node(_arcs[e.id].target); }
 
 
@@ -114,5 +114,5 @@
 
     void next(Node& node) const {
-      node.id = nodes[node.id].next;
+      node.id = _nodes[node.id].next;
     }
 
@@ -121,33 +121,33 @@
       int n;
       for(n = first_node;
-          n != -1 && nodes[n].first_out == -1;
-          n = nodes[n].next) {}
-      arc.id = (n == -1) ? -1 : nodes[n].first_out;
+          n != -1 && _nodes[n].first_out == -1;
+          n = _nodes[n].next) {}
+      arc.id = (n == -1) ? -1 : _nodes[n].first_out;
     }
 
     void next(Arc& arc) const {
-      if (arcs[arc.id].next_out != -1) {
-        arc.id = arcs[arc.id].next_out;
+      if (_arcs[arc.id].next_out != -1) {
+        arc.id = _arcs[arc.id].next_out;
       } else {
         int n;
-        for(n = nodes[arcs[arc.id].source].next;
-            n != -1 && nodes[n].first_out == -1;
-            n = nodes[n].next) {}
-        arc.id = (n == -1) ? -1 : nodes[n].first_out;
+        for(n = _nodes[_arcs[arc.id].source].next;
+            n != -1 && _nodes[n].first_out == -1;
+            n = _nodes[n].next) {}
+        arc.id = (n == -1) ? -1 : _nodes[n].first_out;
       }
     }
 
     void firstOut(Arc &e, const Node& v) const {
-      e.id = nodes[v.id].first_out;
+      e.id = _nodes[v.id].first_out;
     }
     void nextOut(Arc &e) const {
-      e.id=arcs[e.id].next_out;
+      e.id=_arcs[e.id].next_out;
     }
 
     void firstIn(Arc &e, const Node& v) const {
-      e.id = nodes[v.id].first_in;
+      e.id = _nodes[v.id].first_in;
     }
     void nextIn(Arc &e) const {
-      e.id=arcs[e.id].next_in;
+      e.id=_arcs[e.id].next_in;
     }
 
@@ -160,11 +160,11 @@
 
     bool valid(Node n) const {
-      return n.id >= 0 && n.id < static_cast<int>(nodes.size()) &&
-        nodes[n.id].prev != -2;
+      return n.id >= 0 && n.id < static_cast<int>(_nodes.size()) &&
+        _nodes[n.id].prev != -2;
     }
 
     bool valid(Arc a) const {
-      return a.id >= 0 && a.id < static_cast<int>(arcs.size()) &&
-        arcs[a.id].prev_in != -2;
+      return a.id >= 0 && a.id < static_cast<int>(_arcs.size()) &&
+        _arcs[a.id].prev_in != -2;
     }
 
@@ -173,17 +173,17 @@
 
       if(first_free_node==-1) {
-        n = nodes.size();
-        nodes.push_back(NodeT());
+        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_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;
+      _nodes[n].prev = -1;
+
+      _nodes[n].first_in = _nodes[n].first_out = -1;
 
       return Node(n);
@@ -194,27 +194,27 @@
 
       if (first_free_arc == -1) {
-        n = arcs.size();
-        arcs.push_back(ArcT());
+        n = _arcs.size();
+        _arcs.push_back(ArcT());
       } else {
         n = first_free_arc;
-        first_free_arc = arcs[n].next_in;
-      }
-
-      arcs[n].source = u.id;
-      arcs[n].target = v.id;
-
-      arcs[n].next_out = nodes[u.id].first_out;
-      if(nodes[u.id].first_out != -1) {
-        arcs[nodes[u.id].first_out].prev_out = n;
-      }
-
-      arcs[n].next_in = nodes[v.id].first_in;
-      if(nodes[v.id].first_in != -1) {
-        arcs[nodes[v.id].first_in].prev_in = n;
-      }
-
-      arcs[n].prev_in = arcs[n].prev_out = -1;
-
-      nodes[u.id].first_out = nodes[v.id].first_in = n;
+        first_free_arc = _arcs[n].next_in;
+      }
+
+      _arcs[n].source = u.id;
+      _arcs[n].target = v.id;
+
+      _arcs[n].next_out = _nodes[u.id].first_out;
+      if(_nodes[u.id].first_out != -1) {
+        _arcs[_nodes[u.id].first_out].prev_out = n;
+      }
+
+      _arcs[n].next_in = _nodes[v.id].first_in;
+      if(_nodes[v.id].first_in != -1) {
+        _arcs[_nodes[v.id].first_in].prev_in = n;
+      }
+
+      _arcs[n].prev_in = _arcs[n].prev_out = -1;
+
+      _nodes[u.id].first_out = _nodes[v.id].first_in = n;
 
       return Arc(n);
@@ -224,17 +224,17 @@
       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;
+      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;
-      nodes[n].prev = -2;
+      _nodes[n].prev = -2;
 
     }
@@ -243,33 +243,33 @@
       int n = arc.id;
 
-      if(arcs[n].next_in!=-1) {
-        arcs[arcs[n].next_in].prev_in = arcs[n].prev_in;
-      }
-
-      if(arcs[n].prev_in!=-1) {
-        arcs[arcs[n].prev_in].next_in = arcs[n].next_in;
-      } else {
-        nodes[arcs[n].target].first_in = arcs[n].next_in;
-      }
-
-
-      if(arcs[n].next_out!=-1) {
-        arcs[arcs[n].next_out].prev_out = arcs[n].prev_out;
-      }
-
-      if(arcs[n].prev_out!=-1) {
-        arcs[arcs[n].prev_out].next_out = arcs[n].next_out;
-      } else {
-        nodes[arcs[n].source].first_out = arcs[n].next_out;
-      }
-
-      arcs[n].next_in = first_free_arc;
+      if(_arcs[n].next_in!=-1) {
+        _arcs[_arcs[n].next_in].prev_in = _arcs[n].prev_in;
+      }
+
+      if(_arcs[n].prev_in!=-1) {
+        _arcs[_arcs[n].prev_in].next_in = _arcs[n].next_in;
+      } else {
+        _nodes[_arcs[n].target].first_in = _arcs[n].next_in;
+      }
+
+
+      if(_arcs[n].next_out!=-1) {
+        _arcs[_arcs[n].next_out].prev_out = _arcs[n].prev_out;
+      }
+
+      if(_arcs[n].prev_out!=-1) {
+        _arcs[_arcs[n].prev_out].next_out = _arcs[n].next_out;
+      } else {
+        _nodes[_arcs[n].source].first_out = _arcs[n].next_out;
+      }
+
+      _arcs[n].next_in = first_free_arc;
       first_free_arc = n;
-      arcs[n].prev_in = -2;
+      _arcs[n].prev_in = -2;
     }
 
     void clear() {
-      arcs.clear();
-      nodes.clear();
+      _arcs.clear();
+      _nodes.clear();
       first_node = first_free_node = first_free_arc = -1;
     }
@@ -278,31 +278,31 @@
     void changeTarget(Arc e, Node n)
     {
-      if(arcs[e.id].next_in != -1)
-        arcs[arcs[e.id].next_in].prev_in = arcs[e.id].prev_in;
-      if(arcs[e.id].prev_in != -1)
-        arcs[arcs[e.id].prev_in].next_in = arcs[e.id].next_in;
-      else nodes[arcs[e.id].target].first_in = arcs[e.id].next_in;
-      if (nodes[n.id].first_in != -1) {
-        arcs[nodes[n.id].first_in].prev_in = e.id;
-      }
-      arcs[e.id].target = n.id;
-      arcs[e.id].prev_in = -1;
-      arcs[e.id].next_in = nodes[n.id].first_in;
-      nodes[n.id].first_in = e.id;
+      if(_arcs[e.id].next_in != -1)
+        _arcs[_arcs[e.id].next_in].prev_in = _arcs[e.id].prev_in;
+      if(_arcs[e.id].prev_in != -1)
+        _arcs[_arcs[e.id].prev_in].next_in = _arcs[e.id].next_in;
+      else _nodes[_arcs[e.id].target].first_in = _arcs[e.id].next_in;
+      if (_nodes[n.id].first_in != -1) {
+        _arcs[_nodes[n.id].first_in].prev_in = e.id;
+      }
+      _arcs[e.id].target = n.id;
+      _arcs[e.id].prev_in = -1;
+      _arcs[e.id].next_in = _nodes[n.id].first_in;
+      _nodes[n.id].first_in = e.id;
     }
     void changeSource(Arc e, Node n)
     {
-      if(arcs[e.id].next_out != -1)
-        arcs[arcs[e.id].next_out].prev_out = arcs[e.id].prev_out;
-      if(arcs[e.id].prev_out != -1)
-        arcs[arcs[e.id].prev_out].next_out = arcs[e.id].next_out;
-      else nodes[arcs[e.id].source].first_out = arcs[e.id].next_out;
-      if (nodes[n.id].first_out != -1) {
-        arcs[nodes[n.id].first_out].prev_out = e.id;
-      }
-      arcs[e.id].source = n.id;
-      arcs[e.id].prev_out = -1;
-      arcs[e.id].next_out = nodes[n.id].first_out;
-      nodes[n.id].first_out = e.id;
+      if(_arcs[e.id].next_out != -1)
+        _arcs[_arcs[e.id].next_out].prev_out = _arcs[e.id].prev_out;
+      if(_arcs[e.id].prev_out != -1)
+        _arcs[_arcs[e.id].prev_out].next_out = _arcs[e.id].next_out;
+      else _nodes[_arcs[e.id].source].first_out = _arcs[e.id].next_out;
+      if (_nodes[n.id].first_out != -1) {
+        _arcs[_nodes[n.id].first_out].prev_out = e.id;
+      }
+      _arcs[e.id].source = n.id;
+      _arcs[e.id].prev_out = -1;
+      _arcs[e.id].next_out = _nodes[n.id].first_out;
+      _nodes[n.id].first_out = e.id;
     }
 
@@ -487,8 +487,8 @@
     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=arcs[i].next_out) {
-        arcs[i].source=b.id;
+      _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=_arcs[i].next_out) {
+        _arcs[i].source=b.id;
       }
       if (connect) addArc(n,b);
@@ -533,5 +533,5 @@
     /// to build the digraph.
     /// \sa reserveArc()
-    void reserveNode(int n) { nodes.reserve(n); };
+    void reserveNode(int n) { _nodes.reserve(n); };
 
     /// Reserve memory for arcs.
@@ -543,5 +543,5 @@
     /// to build the digraph.
     /// \sa reserveNode()
-    void reserveArc(int m) { arcs.reserve(m); };
+    void reserveArc(int m) { _arcs.reserve(m); };
 
     /// \brief Class to make a snapshot of the digraph and restore
@@ -804,5 +804,5 @@
     };
 
-    std::vector<NodeT> nodes;
+    std::vector<NodeT> _nodes;
 
     int first_node;
@@ -810,5 +810,5 @@
     int first_free_node;
 
-    std::vector<ArcT> arcs;
+    std::vector<ArcT> _arcs;
 
     int first_free_arc;
@@ -868,17 +868,17 @@
 
     ListGraphBase()
-      : nodes(), first_node(-1),
-        first_free_node(-1), arcs(), first_free_arc(-1) {}
-
-
-    int maxNodeId() const { return nodes.size()-1; }
-    int maxEdgeId() const { return arcs.size() / 2 - 1; }
-    int maxArcId() const { return arcs.size()-1; }
-
-    Node source(Arc e) const { return Node(arcs[e.id ^ 1].target); }
-    Node target(Arc e) const { return Node(arcs[e.id].target); }
-
-    Node u(Edge e) const { return Node(arcs[2 * e.id].target); }
-    Node v(Edge e) const { return Node(arcs[2 * e.id + 1].target); }
+      : _nodes(), first_node(-1),
+        first_free_node(-1), _arcs(), first_free_arc(-1) {}
+
+
+    int maxNodeId() const { return _nodes.size()-1; }
+    int maxEdgeId() const { return _arcs.size() / 2 - 1; }
+    int maxArcId() const { return _arcs.size()-1; }
+
+    Node source(Arc e) const { return Node(_arcs[e.id ^ 1].target); }
+    Node target(Arc e) const { return Node(_arcs[e.id].target); }
+
+    Node u(Edge e) const { return Node(_arcs[2 * e.id].target); }
+    Node v(Edge e) const { return Node(_arcs[2 * e.id + 1].target); }
 
     static bool direction(Arc e) {
@@ -895,24 +895,24 @@
 
     void next(Node& node) const {
-      node.id = nodes[node.id].next;
+      node.id = _nodes[node.id].next;
     }
 
     void first(Arc& 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;
+      while (n != -1 && _nodes[n].first_out == -1) {
+        n = _nodes[n].next;
+      }
+      e.id = (n == -1) ? -1 : _nodes[n].first_out;
     }
 
     void next(Arc& e) const {
-      if (arcs[e.id].next_out != -1) {
-        e.id = arcs[e.id].next_out;
-      } else {
-        int n = nodes[arcs[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;
+      if (_arcs[e.id].next_out != -1) {
+        e.id = _arcs[e.id].next_out;
+      } else {
+        int n = _nodes[_arcs[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;
       }
     }
@@ -921,7 +921,7 @@
       int n = first_node;
       while (n != -1) {
-        e.id = nodes[n].first_out;
+        e.id = _nodes[n].first_out;
         while ((e.id & 1) != 1) {
-          e.id = arcs[e.id].next_out;
+          e.id = _arcs[e.id].next_out;
         }
         if (e.id != -1) {
@@ -929,5 +929,5 @@
           return;
         }
-        n = nodes[n].next;
+        n = _nodes[n].next;
       }
       e.id = -1;
@@ -935,8 +935,8 @@
 
     void next(Edge& e) const {
-      int n = arcs[e.id * 2].target;
-      e.id = arcs[(e.id * 2) | 1].next_out;
+      int n = _arcs[e.id * 2].target;
+      e.id = _arcs[(e.id * 2) | 1].next_out;
       while ((e.id & 1) != 1) {
-        e.id = arcs[e.id].next_out;
+        e.id = _arcs[e.id].next_out;
       }
       if (e.id != -1) {
@@ -944,9 +944,9 @@
         return;
       }
-      n = nodes[n].next;
+      n = _nodes[n].next;
       while (n != -1) {
-        e.id = nodes[n].first_out;
+        e.id = _nodes[n].first_out;
         while ((e.id & 1) != 1) {
-          e.id = arcs[e.id].next_out;
+          e.id = _arcs[e.id].next_out;
         }
         if (e.id != -1) {
@@ -954,5 +954,5 @@
           return;
         }
-        n = nodes[n].next;
+        n = _nodes[n].next;
       }
       e.id = -1;
@@ -960,21 +960,21 @@
 
     void firstOut(Arc &e, const Node& v) const {
-      e.id = nodes[v.id].first_out;
+      e.id = _nodes[v.id].first_out;
     }
     void nextOut(Arc &e) const {
-      e.id = arcs[e.id].next_out;
+      e.id = _arcs[e.id].next_out;
     }
 
     void firstIn(Arc &e, const Node& v) const {
-      e.id = ((nodes[v.id].first_out) ^ 1);
+      e.id = ((_nodes[v.id].first_out) ^ 1);
       if (e.id == -2) e.id = -1;
     }
     void nextIn(Arc &e) const {
-      e.id = ((arcs[e.id ^ 1].next_out) ^ 1);
+      e.id = ((_arcs[e.id ^ 1].next_out) ^ 1);
       if (e.id == -2) e.id = -1;
     }
 
     void firstInc(Edge &e, bool& d, const Node& v) const {
-      int a = nodes[v.id].first_out;
+      int a = _nodes[v.id].first_out;
       if (a != -1 ) {
         e.id = a / 2;
@@ -986,5 +986,5 @@
     }
     void nextInc(Edge &e, bool& d) const {
-      int a = (arcs[(e.id * 2) | (d ? 1 : 0)].next_out);
+      int a = (_arcs[(e.id * 2) | (d ? 1 : 0)].next_out);
       if (a != -1 ) {
         e.id = a / 2;
@@ -1005,16 +1005,16 @@
 
     bool valid(Node n) const {
-      return n.id >= 0 && n.id < static_cast<int>(nodes.size()) &&
-        nodes[n.id].prev != -2;
+      return n.id >= 0 && n.id < static_cast<int>(_nodes.size()) &&
+        _nodes[n.id].prev != -2;
     }
 
     bool valid(Arc a) const {
-      return a.id >= 0 && a.id < static_cast<int>(arcs.size()) &&
-        arcs[a.id].prev_out != -2;
+      return a.id >= 0 && a.id < static_cast<int>(_arcs.size()) &&
+        _arcs[a.id].prev_out != -2;
     }
 
     bool valid(Edge e) const {
-      return e.id >= 0 && 2 * e.id < static_cast<int>(arcs.size()) &&
-        arcs[2 * e.id].prev_out != -2;
+      return e.id >= 0 && 2 * e.id < static_cast<int>(_arcs.size()) &&
+        _arcs[2 * e.id].prev_out != -2;
     }
 
@@ -1023,17 +1023,17 @@
 
       if(first_free_node==-1) {
-        n = nodes.size();
-        nodes.push_back(NodeT());
+        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_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;
+      _nodes[n].prev = -1;
+
+      _nodes[n].first_out = -1;
 
       return Node(n);
@@ -1044,28 +1044,28 @@
 
       if (first_free_arc == -1) {
-        n = arcs.size();
-        arcs.push_back(ArcT());
-        arcs.push_back(ArcT());
+        n = _arcs.size();
+        _arcs.push_back(ArcT());
+        _arcs.push_back(ArcT());
       } else {
         n = first_free_arc;
-        first_free_arc = arcs[n].next_out;
-      }
-
-      arcs[n].target = u.id;
-      arcs[n | 1].target = v.id;
-
-      arcs[n].next_out = nodes[v.id].first_out;
-      if (nodes[v.id].first_out != -1) {
-        arcs[nodes[v.id].first_out].prev_out = n;
-      }
-      arcs[n].prev_out = -1;
-      nodes[v.id].first_out = n;
-
-      arcs[n | 1].next_out = nodes[u.id].first_out;
-      if (nodes[u.id].first_out != -1) {
-        arcs[nodes[u.id].first_out].prev_out = (n | 1);
-      }
-      arcs[n | 1].prev_out = -1;
-      nodes[u.id].first_out = (n | 1);
+        first_free_arc = _arcs[n].next_out;
+      }
+
+      _arcs[n].target = u.id;
+      _arcs[n | 1].target = v.id;
+
+      _arcs[n].next_out = _nodes[v.id].first_out;
+      if (_nodes[v.id].first_out != -1) {
+        _arcs[_nodes[v.id].first_out].prev_out = n;
+      }
+      _arcs[n].prev_out = -1;
+      _nodes[v.id].first_out = n;
+
+      _arcs[n | 1].next_out = _nodes[u.id].first_out;
+      if (_nodes[u.id].first_out != -1) {
+        _arcs[_nodes[u.id].first_out].prev_out = (n | 1);
+      }
+      _arcs[n | 1].prev_out = -1;
+      _nodes[u.id].first_out = (n | 1);
 
       return Edge(n / 2);
@@ -1075,17 +1075,17 @@
       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;
+      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;
-      nodes[n].prev = -2;
+      _nodes[n].prev = -2;
     }
 
@@ -1093,34 +1093,34 @@
       int n = edge.id * 2;
 
-      if (arcs[n].next_out != -1) {
-        arcs[arcs[n].next_out].prev_out = arcs[n].prev_out;
-      }
-
-      if (arcs[n].prev_out != -1) {
-        arcs[arcs[n].prev_out].next_out = arcs[n].next_out;
-      } else {
-        nodes[arcs[n | 1].target].first_out = arcs[n].next_out;
-      }
-
-      if (arcs[n | 1].next_out != -1) {
-        arcs[arcs[n | 1].next_out].prev_out = arcs[n | 1].prev_out;
-      }
-
-      if (arcs[n | 1].prev_out != -1) {
-        arcs[arcs[n | 1].prev_out].next_out = arcs[n | 1].next_out;
-      } else {
-        nodes[arcs[n].target].first_out = arcs[n | 1].next_out;
-      }
-
-      arcs[n].next_out = first_free_arc;
+      if (_arcs[n].next_out != -1) {
+        _arcs[_arcs[n].next_out].prev_out = _arcs[n].prev_out;
+      }
+
+      if (_arcs[n].prev_out != -1) {
+        _arcs[_arcs[n].prev_out].next_out = _arcs[n].next_out;
+      } else {
+        _nodes[_arcs[n | 1].target].first_out = _arcs[n].next_out;
+      }
+
+      if (_arcs[n | 1].next_out != -1) {
+        _arcs[_arcs[n | 1].next_out].prev_out = _arcs[n | 1].prev_out;
+      }
+
+      if (_arcs[n | 1].prev_out != -1) {
+        _arcs[_arcs[n | 1].prev_out].next_out = _arcs[n | 1].next_out;
+      } else {
+        _nodes[_arcs[n].target].first_out = _arcs[n | 1].next_out;
+      }
+
+      _arcs[n].next_out = first_free_arc;
       first_free_arc = n;
-      arcs[n].prev_out = -2;
-      arcs[n | 1].prev_out = -2;
+      _arcs[n].prev_out = -2;
+      _arcs[n | 1].prev_out = -2;
 
     }
 
     void clear() {
-      arcs.clear();
-      nodes.clear();
+      _arcs.clear();
+      _nodes.clear();
       first_node = first_free_node = first_free_arc = -1;
     }
@@ -1129,44 +1129,44 @@
 
     void changeV(Edge e, Node n) {
-      if(arcs[2 * e.id].next_out != -1) {
-        arcs[arcs[2 * e.id].next_out].prev_out = arcs[2 * e.id].prev_out;
-      }
-      if(arcs[2 * e.id].prev_out != -1) {
-        arcs[arcs[2 * e.id].prev_out].next_out =
-          arcs[2 * e.id].next_out;
-      } else {
-        nodes[arcs[(2 * e.id) | 1].target].first_out =
-          arcs[2 * e.id].next_out;
-      }
-
-      if (nodes[n.id].first_out != -1) {
-        arcs[nodes[n.id].first_out].prev_out = 2 * e.id;
-      }
-      arcs[(2 * e.id) | 1].target = n.id;
-      arcs[2 * e.id].prev_out = -1;
-      arcs[2 * e.id].next_out = nodes[n.id].first_out;
-      nodes[n.id].first_out = 2 * e.id;
+      if(_arcs[2 * e.id].next_out != -1) {
+        _arcs[_arcs[2 * e.id].next_out].prev_out = _arcs[2 * e.id].prev_out;
+      }
+      if(_arcs[2 * e.id].prev_out != -1) {
+        _arcs[_arcs[2 * e.id].prev_out].next_out =
+          _arcs[2 * e.id].next_out;
+      } else {
+        _nodes[_arcs[(2 * e.id) | 1].target].first_out =
+          _arcs[2 * e.id].next_out;
+      }
+
+      if (_nodes[n.id].first_out != -1) {
+        _arcs[_nodes[n.id].first_out].prev_out = 2 * e.id;
+      }
+      _arcs[(2 * e.id) | 1].target = n.id;
+      _arcs[2 * e.id].prev_out = -1;
+      _arcs[2 * e.id].next_out = _nodes[n.id].first_out;
+      _nodes[n.id].first_out = 2 * e.id;
     }
 
     void changeU(Edge e, Node n) {
-      if(arcs[(2 * e.id) | 1].next_out != -1) {
-        arcs[arcs[(2 * e.id) | 1].next_out].prev_out =
-          arcs[(2 * e.id) | 1].prev_out;
-      }
-      if(arcs[(2 * e.id) | 1].prev_out != -1) {
-        arcs[arcs[(2 * e.id) | 1].prev_out].next_out =
-          arcs[(2 * e.id) | 1].next_out;
-      } else {
-        nodes[arcs[2 * e.id].target].first_out =
-          arcs[(2 * e.id) | 1].next_out;
-      }
-
-      if (nodes[n.id].first_out != -1) {
-        arcs[nodes[n.id].first_out].prev_out = ((2 * e.id) | 1);
-      }
-      arcs[2 * e.id].target = n.id;
-      arcs[(2 * e.id) | 1].prev_out = -1;
-      arcs[(2 * e.id) | 1].next_out = nodes[n.id].first_out;
-      nodes[n.id].first_out = ((2 * e.id) | 1);
+      if(_arcs[(2 * e.id) | 1].next_out != -1) {
+        _arcs[_arcs[(2 * e.id) | 1].next_out].prev_out =
+          _arcs[(2 * e.id) | 1].prev_out;
+      }
+      if(_arcs[(2 * e.id) | 1].prev_out != -1) {
+        _arcs[_arcs[(2 * e.id) | 1].prev_out].next_out =
+          _arcs[(2 * e.id) | 1].next_out;
+      } else {
+        _nodes[_arcs[2 * e.id].target].first_out =
+          _arcs[(2 * e.id) | 1].next_out;
+      }
+
+      if (_nodes[n.id].first_out != -1) {
+        _arcs[_nodes[n.id].first_out].prev_out = ((2 * e.id) | 1);
+      }
+      _arcs[2 * e.id].target = n.id;
+      _arcs[(2 * e.id) | 1].prev_out = -1;
+      _arcs[(2 * e.id) | 1].next_out = _nodes[n.id].first_out;
+      _nodes[n.id].first_out = ((2 * e.id) | 1);
     }
 
@@ -1210,5 +1210,5 @@
     ListGraph() {}
 
-    typedef Parent::OutArcIt IncEdgeIt;
+    typedef Parent::IncEdgeIt IncEdgeIt;
 
     /// \brief Add a new node to the graph.
@@ -1345,5 +1345,5 @@
     /// to build the graph.
     /// \sa reserveEdge()
-    void reserveNode(int n) { nodes.reserve(n); };
+    void reserveNode(int n) { _nodes.reserve(n); };
 
     /// Reserve memory for edges.
@@ -1355,5 +1355,5 @@
     /// to build the graph.
     /// \sa reserveNode()
-    void reserveEdge(int m) { arcs.reserve(2 * m); };
+    void reserveEdge(int m) { _arcs.reserve(2 * m); };
 
     /// \brief Class to make a snapshot of the graph and restore
@@ -1618,5 +1618,5 @@
     };
 
-    std::vector<NodeT> nodes;
+    std::vector<NodeT> _nodes;
 
     int first_node, first_red, first_blue;
@@ -1625,5 +1625,5 @@
     int first_free_red, first_free_blue;
 
-    std::vector<ArcT> arcs;
+    std::vector<ArcT> _arcs;
 
     int first_free_arc;
@@ -1707,31 +1707,31 @@
 
     ListBpGraphBase()
-      : nodes(), first_node(-1),
+      : _nodes(), first_node(-1),
         first_red(-1), first_blue(-1),
         max_red(-1), max_blue(-1),
         first_free_red(-1), first_free_blue(-1),
-        arcs(), first_free_arc(-1) {}
-
-
-    bool red(Node n) const { return nodes[n.id].red; }
-    bool blue(Node n) const { return !nodes[n.id].red; }
+        _arcs(), first_free_arc(-1) {}
+
+
+    bool red(Node n) const { return _nodes[n.id].red; }
+    bool blue(Node n) const { return !_nodes[n.id].red; }
 
     static RedNode asRedNodeUnsafe(Node n) { return RedNode(n.id); }
     static BlueNode asBlueNodeUnsafe(Node n) { return BlueNode(n.id); }
 
-    int maxNodeId() const { return nodes.size()-1; }
+    int maxNodeId() const { return _nodes.size()-1; }
     int maxRedId() const { return max_red; }
     int maxBlueId() const { return max_blue; }
-    int maxEdgeId() const { return arcs.size() / 2 - 1; }
-    int maxArcId() const { return arcs.size()-1; }
-
-    Node source(Arc e) const { return Node(arcs[e.id ^ 1].target); }
-    Node target(Arc e) const { return Node(arcs[e.id].target); }
+    int maxEdgeId() const { return _arcs.size() / 2 - 1; }
+    int maxArcId() const { return _arcs.size()-1; }
+
+    Node source(Arc e) const { return Node(_arcs[e.id ^ 1].target); }
+    Node target(Arc e) const { return Node(_arcs[e.id].target); }
 
     RedNode redNode(Edge e) const {
-      return RedNode(arcs[2 * e.id].target);
+      return RedNode(_arcs[2 * e.id].target);
     }
     BlueNode blueNode(Edge e) const {
-      return BlueNode(arcs[2 * e.id + 1].target);
+      return BlueNode(_arcs[2 * e.id + 1].target);
     }
 
@@ -1749,5 +1749,5 @@
 
     void next(Node& node) const {
-      node.id = nodes[node.id].next;
+      node.id = _nodes[node.id].next;
     }
 
@@ -1757,5 +1757,5 @@
 
     void next(RedNode& node) const {
-      node.id = nodes[node.id].partition_next;
+      node.id = _nodes[node.id].partition_next;
     }
 
@@ -1765,24 +1765,24 @@
 
     void next(BlueNode& node) const {
-      node.id = nodes[node.id].partition_next;
+      node.id = _nodes[node.id].partition_next;
     }
 
     void first(Arc& 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;
+      while (n != -1 && _nodes[n].first_out == -1) {
+        n = _nodes[n].next;
+      }
+      e.id = (n == -1) ? -1 : _nodes[n].first_out;
     }
 
     void next(Arc& e) const {
-      if (arcs[e.id].next_out != -1) {
-        e.id = arcs[e.id].next_out;
-      } else {
-        int n = nodes[arcs[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;
+      if (_arcs[e.id].next_out != -1) {
+        e.id = _arcs[e.id].next_out;
+      } else {
+        int n = _nodes[_arcs[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;
       }
     }
@@ -1791,7 +1791,7 @@
       int n = first_node;
       while (n != -1) {
-        e.id = nodes[n].first_out;
+        e.id = _nodes[n].first_out;
         while ((e.id & 1) != 1) {
-          e.id = arcs[e.id].next_out;
+          e.id = _arcs[e.id].next_out;
         }
         if (e.id != -1) {
@@ -1799,5 +1799,5 @@
           return;
         }
-        n = nodes[n].next;
+        n = _nodes[n].next;
       }
       e.id = -1;
@@ -1805,8 +1805,8 @@
 
     void next(Edge& e) const {
-      int n = arcs[e.id * 2].target;
-      e.id = arcs[(e.id * 2) | 1].next_out;
+      int n = _arcs[e.id * 2].target;
+      e.id = _arcs[(e.id * 2) | 1].next_out;
       while ((e.id & 1) != 1) {
-        e.id = arcs[e.id].next_out;
+        e.id = _arcs[e.id].next_out;
       }
       if (e.id != -1) {
@@ -1814,9 +1814,9 @@
         return;
       }
-      n = nodes[n].next;
+      n = _nodes[n].next;
       while (n != -1) {
-        e.id = nodes[n].first_out;
+        e.id = _nodes[n].first_out;
         while ((e.id & 1) != 1) {
-          e.id = arcs[e.id].next_out;
+          e.id = _arcs[e.id].next_out;
         }
         if (e.id != -1) {
@@ -1824,5 +1824,5 @@
           return;
         }
-        n = nodes[n].next;
+        n = _nodes[n].next;
       }
       e.id = -1;
@@ -1830,21 +1830,21 @@
 
     void firstOut(Arc &e, const Node& v) const {
-      e.id = nodes[v.id].first_out;
+      e.id = _nodes[v.id].first_out;
     }
     void nextOut(Arc &e) const {
-      e.id = arcs[e.id].next_out;
+      e.id = _arcs[e.id].next_out;
     }
 
     void firstIn(Arc &e, const Node& v) const {
-      e.id = ((nodes[v.id].first_out) ^ 1);
+      e.id = ((_nodes[v.id].first_out) ^ 1);
       if (e.id == -2) e.id = -1;
     }
     void nextIn(Arc &e) const {
-      e.id = ((arcs[e.id ^ 1].next_out) ^ 1);
+      e.id = ((_arcs[e.id ^ 1].next_out) ^ 1);
       if (e.id == -2) e.id = -1;
     }
 
     void firstInc(Edge &e, bool& d, const Node& v) const {
-      int a = nodes[v.id].first_out;
+      int a = _nodes[v.id].first_out;
       if (a != -1 ) {
         e.id = a / 2;
@@ -1856,5 +1856,5 @@
     }
     void nextInc(Edge &e, bool& d) const {
-      int a = (arcs[(e.id * 2) | (d ? 1 : 0)].next_out);
+      int a = (_arcs[(e.id * 2) | (d ? 1 : 0)].next_out);
       if (a != -1 ) {
         e.id = a / 2;
@@ -1867,6 +1867,6 @@
 
     static int id(Node v) { return v.id; }
-    int id(RedNode v) const { return nodes[v.id].partition_index; }
-    int id(BlueNode v) const { return nodes[v.id].partition_index; }
+    int id(RedNode v) const { return _nodes[v.id].partition_index; }
+    int id(BlueNode v) const { return _nodes[v.id].partition_index; }
     static int id(Arc e) { return e.id; }
     static int id(Edge e) { return e.id; }
@@ -1877,16 +1877,16 @@
 
     bool valid(Node n) const {
-      return n.id >= 0 && n.id < static_cast<int>(nodes.size()) &&
-        nodes[n.id].prev != -2;
+      return n.id >= 0 && n.id < static_cast<int>(_nodes.size()) &&
+        _nodes[n.id].prev != -2;
     }
 
     bool valid(Arc a) const {
-      return a.id >= 0 && a.id < static_cast<int>(arcs.size()) &&
-        arcs[a.id].prev_out != -2;
+      return a.id >= 0 && a.id < static_cast<int>(_arcs.size()) &&
+        _arcs[a.id].prev_out != -2;
     }
 
     bool valid(Edge e) const {
-      return e.id >= 0 && 2 * e.id < static_cast<int>(arcs.size()) &&
-        arcs[2 * e.id].prev_out != -2;
+      return e.id >= 0 && 2 * e.id < static_cast<int>(_arcs.size()) &&
+        _arcs[2 * e.id].prev_out != -2;
     }
 
@@ -1895,24 +1895,24 @@
 
       if(first_free_red==-1) {
-        n = nodes.size();
-        nodes.push_back(NodeT());
-        nodes[n].partition_index = ++max_red;
-        nodes[n].red = true;
+        n = _nodes.size();
+        _nodes.push_back(NodeT());
+        _nodes[n].partition_index = ++max_red;
+        _nodes[n].red = true;
       } else {
         n = first_free_red;
-        first_free_red = nodes[n].next;
-      }
-
-      nodes[n].next = first_node;
-      if (first_node != -1) nodes[first_node].prev = n;
+        first_free_red = _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].partition_next = first_red;
-      if (first_red != -1) nodes[first_red].partition_prev = n;
+      _nodes[n].prev = -1;
+
+      _nodes[n].partition_next = first_red;
+      if (first_red != -1) _nodes[first_red].partition_prev = n;
       first_red = n;
-      nodes[n].partition_prev = -1;
-
-      nodes[n].first_out = -1;
+      _nodes[n].partition_prev = -1;
+
+      _nodes[n].first_out = -1;
 
       return RedNode(n);
@@ -1923,24 +1923,24 @@
 
       if(first_free_blue==-1) {
-        n = nodes.size();
-        nodes.push_back(NodeT());
-        nodes[n].partition_index = ++max_blue;
-        nodes[n].red = false;
+        n = _nodes.size();
+        _nodes.push_back(NodeT());
+        _nodes[n].partition_index = ++max_blue;
+        _nodes[n].red = false;
       } else {
         n = first_free_blue;
-        first_free_blue = nodes[n].next;
-      }
-
-      nodes[n].next = first_node;
-      if (first_node != -1) nodes[first_node].prev = n;
+        first_free_blue = _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].partition_next = first_blue;
-      if (first_blue != -1) nodes[first_blue].partition_prev = n;
+      _nodes[n].prev = -1;
+
+      _nodes[n].partition_next = first_blue;
+      if (first_blue != -1) _nodes[first_blue].partition_prev = n;
       first_blue = n;
-      nodes[n].partition_prev = -1;
-
-      nodes[n].first_out = -1;
+      _nodes[n].partition_prev = -1;
+
+      _nodes[n].first_out = -1;
 
       return BlueNode(n);
@@ -1951,28 +1951,28 @@
 
       if (first_free_arc == -1) {
-        n = arcs.size();
-        arcs.push_back(ArcT());
-        arcs.push_back(ArcT());
+        n = _arcs.size();
+        _arcs.push_back(ArcT());
+        _arcs.push_back(ArcT());
       } else {
         n = first_free_arc;
-        first_free_arc = arcs[n].next_out;
-      }
-
-      arcs[n].target = u.id;
-      arcs[n | 1].target = v.id;
-
-      arcs[n].next_out = nodes[v.id].first_out;
-      if (nodes[v.id].first_out != -1) {
-        arcs[nodes[v.id].first_out].prev_out = n;
-      }
-      arcs[n].prev_out = -1;
-      nodes[v.id].first_out = n;
-
-      arcs[n | 1].next_out = nodes[u.id].first_out;
-      if (nodes[u.id].first_out != -1) {
-        arcs[nodes[u.id].first_out].prev_out = (n | 1);
-      }
-      arcs[n | 1].prev_out = -1;
-      nodes[u.id].first_out = (n | 1);
+        first_free_arc = _arcs[n].next_out;
+      }
+
+      _arcs[n].target = u.id;
+      _arcs[n | 1].target = v.id;
+
+      _arcs[n].next_out = _nodes[v.id].first_out;
+      if (_nodes[v.id].first_out != -1) {
+        _arcs[_nodes[v.id].first_out].prev_out = n;
+      }
+      _arcs[n].prev_out = -1;
+      _nodes[v.id].first_out = n;
+
+      _arcs[n | 1].next_out = _nodes[u.id].first_out;
+      if (_nodes[u.id].first_out != -1) {
+        _arcs[_nodes[u.id].first_out].prev_out = (n | 1);
+      }
+      _arcs[n | 1].prev_out = -1;
+      _nodes[u.id].first_out = (n | 1);
 
       return Edge(n / 2);
@@ -1982,36 +1982,36 @@
       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;
-      }
-
-      if (nodes[n].partition_next != -1) {
-        nodes[nodes[n].partition_next].partition_prev = nodes[n].partition_prev;
-      }
-
-      if (nodes[n].partition_prev != -1) {
-        nodes[nodes[n].partition_prev].partition_next = nodes[n].partition_next;
-      } else {
-        if (nodes[n].red) {
-          first_red = nodes[n].partition_next;
+      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;
+      }
+
+      if (_nodes[n].partition_next != -1) {
+        _nodes[_nodes[n].partition_next].partition_prev = _nodes[n].partition_prev;
+      }
+
+      if (_nodes[n].partition_prev != -1) {
+        _nodes[_nodes[n].partition_prev].partition_next = _nodes[n].partition_next;
+      } else {
+        if (_nodes[n].red) {
+          first_red = _nodes[n].partition_next;
         } else {
-          first_blue = nodes[n].partition_next;
-        }
-      }
-
-      if (nodes[n].red) {
-        nodes[n].next = first_free_red;
+          first_blue = _nodes[n].partition_next;
+        }
+      }
+
+      if (_nodes[n].red) {
+        _nodes[n].next = first_free_red;
         first_free_red = n;
       } else {
-        nodes[n].next = first_free_blue;
+        _nodes[n].next = first_free_blue;
         first_free_blue = n;
       }
-      nodes[n].prev = -2;
+      _nodes[n].prev = -2;
     }
 
@@ -2019,34 +2019,34 @@
       int n = edge.id * 2;
 
-      if (arcs[n].next_out != -1) {
-        arcs[arcs[n].next_out].prev_out = arcs[n].prev_out;
-      }
-
-      if (arcs[n].prev_out != -1) {
-        arcs[arcs[n].prev_out].next_out = arcs[n].next_out;
-      } else {
-        nodes[arcs[n | 1].target].first_out = arcs[n].next_out;
-      }
-
-      if (arcs[n | 1].next_out != -1) {
-        arcs[arcs[n | 1].next_out].prev_out = arcs[n | 1].prev_out;
-      }
-
-      if (arcs[n | 1].prev_out != -1) {
-        arcs[arcs[n | 1].prev_out].next_out = arcs[n | 1].next_out;
-      } else {
-        nodes[arcs[n].target].first_out = arcs[n | 1].next_out;
-      }
-
-      arcs[n].next_out = first_free_arc;
+      if (_arcs[n].next_out != -1) {
+        _arcs[_arcs[n].next_out].prev_out = _arcs[n].prev_out;
+      }
+
+      if (_arcs[n].prev_out != -1) {
+        _arcs[_arcs[n].prev_out].next_out = _arcs[n].next_out;
+      } else {
+        _nodes[_arcs[n | 1].target].first_out = _arcs[n].next_out;
+      }
+
+      if (_arcs[n | 1].next_out != -1) {
+        _arcs[_arcs[n | 1].next_out].prev_out = _arcs[n | 1].prev_out;
+      }
+
+      if (_arcs[n | 1].prev_out != -1) {
+        _arcs[_arcs[n | 1].prev_out].next_out = _arcs[n | 1].next_out;
+      } else {
+        _nodes[_arcs[n].target].first_out = _arcs[n | 1].next_out;
+      }
+
+      _arcs[n].next_out = first_free_arc;
       first_free_arc = n;
-      arcs[n].prev_out = -2;
-      arcs[n | 1].prev_out = -2;
+      _arcs[n].prev_out = -2;
+      _arcs[n | 1].prev_out = -2;
 
     }
 
     void clear() {
-      arcs.clear();
-      nodes.clear();
+      _arcs.clear();
+      _nodes.clear();
       first_node = first_free_arc = first_red = first_blue =
         max_red = max_blue = first_free_red = first_free_blue = -1;
@@ -2056,44 +2056,44 @@
 
     void changeRed(Edge e, RedNode n) {
-      if(arcs[(2 * e.id) | 1].next_out != -1) {
-        arcs[arcs[(2 * e.id) | 1].next_out].prev_out =
-          arcs[(2 * e.id) | 1].prev_out;
-      }
-      if(arcs[(2 * e.id) | 1].prev_out != -1) {
-        arcs[arcs[(2 * e.id) | 1].prev_out].next_out =
-          arcs[(2 * e.id) | 1].next_out;
-      } else {
-        nodes[arcs[2 * e.id].target].first_out =
-          arcs[(2 * e.id) | 1].next_out;
-      }
-
-      if (nodes[n.id].first_out != -1) {
-        arcs[nodes[n.id].first_out].prev_out = ((2 * e.id) | 1);
-      }
-      arcs[2 * e.id].target = n.id;
-      arcs[(2 * e.id) | 1].prev_out = -1;
-      arcs[(2 * e.id) | 1].next_out = nodes[n.id].first_out;
-      nodes[n.id].first_out = ((2 * e.id) | 1);
+      if(_arcs[(2 * e.id) | 1].next_out != -1) {
+        _arcs[_arcs[(2 * e.id) | 1].next_out].prev_out =
+          _arcs[(2 * e.id) | 1].prev_out;
+      }
+      if(_arcs[(2 * e.id) | 1].prev_out != -1) {
+        _arcs[_arcs[(2 * e.id) | 1].prev_out].next_out =
+          _arcs[(2 * e.id) | 1].next_out;
+      } else {
+        _nodes[_arcs[2 * e.id].target].first_out =
+          _arcs[(2 * e.id) | 1].next_out;
+      }
+
+      if (_nodes[n.id].first_out != -1) {
+        _arcs[_nodes[n.id].first_out].prev_out = ((2 * e.id) | 1);
+      }
+      _arcs[2 * e.id].target = n.id;
+      _arcs[(2 * e.id) | 1].prev_out = -1;
+      _arcs[(2 * e.id) | 1].next_out = _nodes[n.id].first_out;
+      _nodes[n.id].first_out = ((2 * e.id) | 1);
     }
 
     void changeBlue(Edge e, BlueNode n) {
-       if(arcs[2 * e.id].next_out != -1) {
-        arcs[arcs[2 * e.id].next_out].prev_out = arcs[2 * e.id].prev_out;
-      }
-      if(arcs[2 * e.id].prev_out != -1) {
-        arcs[arcs[2 * e.id].prev_out].next_out =
-          arcs[2 * e.id].next_out;
-      } else {
-        nodes[arcs[(2 * e.id) | 1].target].first_out =
-          arcs[2 * e.id].next_out;
-      }
-
-      if (nodes[n.id].first_out != -1) {
-        arcs[nodes[n.id].first_out].prev_out = 2 * e.id;
-      }
-      arcs[(2 * e.id) | 1].target = n.id;
-      arcs[2 * e.id].prev_out = -1;
-      arcs[2 * e.id].next_out = nodes[n.id].first_out;
-      nodes[n.id].first_out = 2 * e.id;
+       if(_arcs[2 * e.id].next_out != -1) {
+        _arcs[_arcs[2 * e.id].next_out].prev_out = _arcs[2 * e.id].prev_out;
+      }
+      if(_arcs[2 * e.id].prev_out != -1) {
+        _arcs[_arcs[2 * e.id].prev_out].next_out =
+          _arcs[2 * e.id].next_out;
+      } else {
+        _nodes[_arcs[(2 * e.id) | 1].target].first_out =
+          _arcs[2 * e.id].next_out;
+      }
+
+      if (_nodes[n.id].first_out != -1) {
+        _arcs[_nodes[n.id].first_out].prev_out = 2 * e.id;
+      }
+      _arcs[(2 * e.id) | 1].target = n.id;
+      _arcs[2 * e.id].prev_out = -1;
+      _arcs[2 * e.id].next_out = _nodes[n.id].first_out;
+      _nodes[n.id].first_out = 2 * e.id;
     }
 
@@ -2137,5 +2137,5 @@
     ListBpGraph() {}
 
-    typedef Parent::OutArcIt IncEdgeIt;
+    typedef Parent::IncEdgeIt IncEdgeIt;
 
     /// \brief Add a new red node to the graph.
@@ -2250,5 +2250,5 @@
     /// to build the graph.
     /// \sa reserveEdge()
-    void reserveNode(int n) { nodes.reserve(n); };
+    void reserveNode(int n) { _nodes.reserve(n); };
 
     /// Reserve memory for edges.
@@ -2260,5 +2260,5 @@
     /// to build the graph.
     /// \sa reserveNode()
-    void reserveEdge(int m) { arcs.reserve(2 * m); };
+    void reserveEdge(int m) { _arcs.reserve(2 * m); };
 
     /// \brief Class to make a snapshot of the graph and restore
Index: lemon/lp_base.h
===================================================================
--- lemon/lp_base.h	(revision 1270)
+++ lemon/lp_base.h	(revision 1336)
@@ -32,4 +32,6 @@
 #include<lemon/bits/solver_bits.h>
 
+#include<lemon/bits/stl_iterators.h>
+
 ///\file
 ///\brief The interface of the LP solver interface.
@@ -46,6 +48,6 @@
   protected:
 
-    _solver_bits::VarIndex rows;
-    _solver_bits::VarIndex cols;
+    _solver_bits::VarIndex _rows;
+    _solver_bits::VarIndex _cols;
 
   public:
@@ -167,5 +169,5 @@
       ColIt(const LpBase &solver) : _solver(&solver)
       {
-        _solver->cols.firstItem(_id);
+        _solver->_cols.firstItem(_id);
       }
       /// Invalid constructor \& conversion
@@ -180,8 +182,23 @@
       ColIt &operator++()
       {
-        _solver->cols.nextItem(_id);
+        _solver->_cols.nextItem(_id);
         return *this;
       }
     };
+
+    /// \brief Gets the collection of the columns of the LP problem.
+    ///
+    /// This function can be used for iterating on
+    /// the columns of the LP problem. It returns a wrapped ColIt, which looks
+    /// like an STL container (by having begin() and end())
+    /// which you can use in range-based for loops, STL algorithms, etc.
+    /// For example you can write:
+    ///\code
+    /// for(auto c: lp.cols())
+    ///   doSomething(c);
+    LemonRangeWrapper1<ColIt, LpBase> cols() {
+      return LemonRangeWrapper1<ColIt, LpBase>(*this);
+    }
+
 
     /// \brief Returns the ID of the column.
@@ -262,5 +279,5 @@
       RowIt(const LpBase &solver) : _solver(&solver)
       {
-        _solver->rows.firstItem(_id);
+        _solver->_rows.firstItem(_id);
       }
       /// Invalid constructor \& conversion
@@ -275,8 +292,23 @@
       RowIt &operator++()
       {
-        _solver->rows.nextItem(_id);
+        _solver->_rows.nextItem(_id);
         return *this;
       }
     };
+    
+    /// \brief Gets the collection of the rows of the LP problem.
+    ///
+    /// This function can be used for iterating on
+    /// the rows of the LP problem. It returns a wrapped RowIt, which looks
+    /// like an STL container (by having begin() and end())
+    /// which you can use in range-based for loops, STL algorithms, etc.
+    /// For example you can write:
+    ///\code
+    /// for(auto c: lp.rows())
+    ///   doSomething(c);
+    LemonRangeWrapper1<RowIt, LpBase> rows() {
+      return LemonRangeWrapper1<RowIt, LpBase>(*this);
+    }
+    
 
     /// \brief Returns the ID of the row.
@@ -935,9 +967,9 @@
     //Abstract virtual functions
 
-    virtual int _addColId(int col) { return cols.addIndex(col); }
-    virtual int _addRowId(int row) { return rows.addIndex(row); }
-
-    virtual void _eraseColId(int col) { cols.eraseIndex(col); }
-    virtual void _eraseRowId(int row) { rows.eraseIndex(row); }
+    virtual int _addColId(int col) { return _cols.addIndex(col); }
+    virtual int _addRowId(int row) { return _rows.addIndex(row); }
+
+    virtual void _eraseColId(int col) { _cols.eraseIndex(col); }
+    virtual void _eraseRowId(int row) { _rows.eraseIndex(row); }
 
     virtual int _addCol() = 0;
@@ -1004,5 +1036,5 @@
     Value obj_const_comp;
 
-    LpBase() : rows(), cols(), obj_const_comp(0) {}
+    LpBase() : _rows(), _cols(), obj_const_comp(0) {}
 
   public:
@@ -1116,6 +1148,6 @@
     void col(Col c, const DualExpr &e) {
       e.simplify();
-      _setColCoeffs(cols(id(c)), ExprIterator(e.comps.begin(), rows),
-                    ExprIterator(e.comps.end(), rows));
+      _setColCoeffs(_cols(id(c)), ExprIterator(e.comps.begin(), _rows),
+                    ExprIterator(e.comps.end(), _rows));
     }
 
@@ -1126,5 +1158,5 @@
     DualExpr col(Col c) const {
       DualExpr e;
-      _getColCoeffs(cols(id(c)), InsertIterator(e.comps, rows));
+      _getColCoeffs(_cols(id(c)), InsertIterator(e.comps, _rows));
       return e;
     }
@@ -1213,8 +1245,8 @@
     void row(Row r, Value l, const Expr &e, Value u) {
       e.simplify();
-      _setRowCoeffs(rows(id(r)), ExprIterator(e.comps.begin(), cols),
-                    ExprIterator(e.comps.end(), cols));
-      _setRowLowerBound(rows(id(r)),l - *e);
-      _setRowUpperBound(rows(id(r)),u - *e);
+      _setRowCoeffs(_rows(id(r)), ExprIterator(e.comps.begin(), _cols),
+                    ExprIterator(e.comps.end(), _cols));
+      _setRowLowerBound(_rows(id(r)),l - *e);
+      _setRowUpperBound(_rows(id(r)),u - *e);
     }
 
@@ -1235,5 +1267,5 @@
     Expr row(Row r) const {
       Expr e;
-      _getRowCoeffs(rows(id(r)), InsertIterator(e.comps, cols));
+      _getRowCoeffs(_rows(id(r)), InsertIterator(e.comps, _cols));
       return e;
     }
@@ -1248,6 +1280,6 @@
       Row r;
       e.simplify();
-      r._id = _addRowId(_addRow(l - *e, ExprIterator(e.comps.begin(), cols),
-                                ExprIterator(e.comps.end(), cols), u - *e));
+      r._id = _addRowId(_addRow(l - *e, ExprIterator(e.comps.begin(), _cols),
+                                ExprIterator(e.comps.end(), _cols), u - *e));
       return r;
     }
@@ -1261,6 +1293,6 @@
       c.expr().simplify();
       r._id = _addRowId(_addRow(c.lowerBounded()?c.lowerBound()-*c.expr():-INF,
-                                ExprIterator(c.expr().comps.begin(), cols),
-                                ExprIterator(c.expr().comps.end(), cols),
+                                ExprIterator(c.expr().comps.begin(), _cols),
+                                ExprIterator(c.expr().comps.end(), _cols),
                                 c.upperBounded()?c.upperBound()-*c.expr():INF));
       return r;
@@ -1270,6 +1302,6 @@
     ///\param c is the column to be deleted
     void erase(Col c) {
-      _eraseCol(cols(id(c)));
-      _eraseColId(cols(id(c)));
+      _eraseCol(_cols(id(c)));
+      _eraseColId(_cols(id(c)));
     }
     ///Erase a row (i.e a constraint) from the LP
@@ -1277,6 +1309,6 @@
     ///\param r is the row to be deleted
     void erase(Row r) {
-      _eraseRow(rows(id(r)));
-      _eraseRowId(rows(id(r)));
+      _eraseRow(_rows(id(r)));
+      _eraseRowId(_rows(id(r)));
     }
 
@@ -1287,5 +1319,5 @@
     std::string colName(Col c) const {
       std::string name;
-      _getColName(cols(id(c)), name);
+      _getColName(_cols(id(c)), name);
       return name;
     }
@@ -1296,5 +1328,5 @@
     ///\param name The name to be given
     void colName(Col c, const std::string& name) {
-      _setColName(cols(id(c)), name);
+      _setColName(_cols(id(c)), name);
     }
 
@@ -1305,5 +1337,5 @@
     Col colByName(const std::string& name) const {
       int k = _colByName(name);
-      return k != -1 ? Col(cols[k]) : Col(INVALID);
+      return k != -1 ? Col(_cols[k]) : Col(INVALID);
     }
 
@@ -1314,5 +1346,5 @@
     std::string rowName(Row r) const {
       std::string name;
-      _getRowName(rows(id(r)), name);
+      _getRowName(_rows(id(r)), name);
       return name;
     }
@@ -1323,5 +1355,5 @@
     ///\param name The name to be given
     void rowName(Row r, const std::string& name) {
-      _setRowName(rows(id(r)), name);
+      _setRowName(_rows(id(r)), name);
     }
 
@@ -1332,5 +1364,5 @@
     Row rowByName(const std::string& name) const {
       int k = _rowByName(name);
-      return k != -1 ? Row(rows[k]) : Row(INVALID);
+      return k != -1 ? Row(_rows[k]) : Row(INVALID);
     }
 
@@ -1341,5 +1373,5 @@
     ///\param val is the new value of the coefficient
     void coeff(Row r, Col c, Value val) {
-      _setCoeff(rows(id(r)),cols(id(c)), val);
+      _setCoeff(_rows(id(r)),_cols(id(c)), val);
     }
 
@@ -1350,5 +1382,5 @@
     ///\return the corresponding coefficient
     Value coeff(Row r, Col c) const {
-      return _getCoeff(rows(id(r)),cols(id(c)));
+      return _getCoeff(_rows(id(r)),_cols(id(c)));
     }
 
@@ -1359,5 +1391,5 @@
     /// Value or -\ref INF.
     void colLowerBound(Col c, Value value) {
-      _setColLowerBound(cols(id(c)),value);
+      _setColLowerBound(_cols(id(c)),value);
     }
 
@@ -1368,5 +1400,5 @@
     ///\return The lower bound for column \c c
     Value colLowerBound(Col c) const {
-      return _getColLowerBound(cols(id(c)));
+      return _getColLowerBound(_cols(id(c)));
     }
 
@@ -1414,5 +1446,5 @@
     /// Value or \ref INF.
     void colUpperBound(Col c, Value value) {
-      _setColUpperBound(cols(id(c)),value);
+      _setColUpperBound(_cols(id(c)),value);
     };
 
@@ -1423,5 +1455,5 @@
     /// \return The upper bound for column \c c
     Value colUpperBound(Col c) const {
-      return _getColUpperBound(cols(id(c)));
+      return _getColUpperBound(_cols(id(c)));
     }
 
@@ -1470,6 +1502,6 @@
     /// Value, -\ref INF or \ref INF.
     void colBounds(Col c, Value lower, Value upper) {
-      _setColLowerBound(cols(id(c)),lower);
-      _setColUpperBound(cols(id(c)),upper);
+      _setColLowerBound(_cols(id(c)),lower);
+      _setColUpperBound(_cols(id(c)),upper);
     }
 
@@ -1516,5 +1548,5 @@
     /// Value or -\ref INF.
     void rowLowerBound(Row r, Value value) {
-      _setRowLowerBound(rows(id(r)),value);
+      _setRowLowerBound(_rows(id(r)),value);
     }
 
@@ -1525,5 +1557,5 @@
     ///\return The lower bound for row \c r
     Value rowLowerBound(Row r) const {
-      return _getRowLowerBound(rows(id(r)));
+      return _getRowLowerBound(_rows(id(r)));
     }
 
@@ -1534,5 +1566,5 @@
     /// Value or -\ref INF.
     void rowUpperBound(Row r, Value value) {
-      _setRowUpperBound(rows(id(r)),value);
+      _setRowUpperBound(_rows(id(r)),value);
     }
 
@@ -1543,12 +1575,12 @@
     ///\return The upper bound for row \c r
     Value rowUpperBound(Row r) const {
-      return _getRowUpperBound(rows(id(r)));
+      return _getRowUpperBound(_rows(id(r)));
     }
 
     ///Set an element of the objective function
-    void objCoeff(Col c, Value v) {_setObjCoeff(cols(id(c)),v); };
+    void objCoeff(Col c, Value v) {_setObjCoeff(_cols(id(c)),v); };
 
     ///Get an element of the objective function
-    Value objCoeff(Col c) const { return _getObjCoeff(cols(id(c))); };
+    Value objCoeff(Col c) const { return _getObjCoeff(_cols(id(c))); };
 
     ///Set the objective function
@@ -1557,6 +1589,6 @@
     ///
     void obj(const Expr& e) {
-      _setObjCoeffs(ExprIterator(e.comps.begin(), cols),
-                    ExprIterator(e.comps.end(), cols));
+      _setObjCoeffs(ExprIterator(e.comps.begin(), _cols),
+                    ExprIterator(e.comps.end(), _cols));
       obj_const_comp = *e;
     }
@@ -1568,5 +1600,5 @@
     Expr obj() const {
       Expr e;
-      _getObjCoeffs(InsertIterator(e.comps, cols));
+      _getObjCoeffs(InsertIterator(e.comps, _cols));
       *e = obj_const_comp;
       return e;
@@ -1587,5 +1619,5 @@
 
     ///Clear the problem
-    void clear() { _clear(); rows.clear(); cols.clear(); }
+    void clear() { _clear(); _rows.clear(); _cols.clear(); }
 
     /// Set the message level of the solver
@@ -1930,5 +1962,5 @@
     /// Return the primal value of the column.
     /// \pre The problem is solved.
-    Value primal(Col c) const { return _getPrimal(cols(id(c))); }
+    Value primal(Col c) const { return _getPrimal(_cols(id(c))); }
 
     /// Return the primal value of the expression
@@ -1957,5 +1989,5 @@
     /// \note Some solvers does not provide primal ray calculation
     /// functions.
-    Value primalRay(Col c) const { return _getPrimalRay(cols(id(c))); }
+    Value primalRay(Col c) const { return _getPrimalRay(_cols(id(c))); }
 
     /// Return the dual value of the row
@@ -1963,5 +1995,5 @@
     /// Return the dual value of the row.
     /// \pre The problem is solved.
-    Value dual(Row r) const { return _getDual(rows(id(r))); }
+    Value dual(Row r) const { return _getDual(_rows(id(r))); }
 
     /// Return the dual value of the dual expression
@@ -1991,15 +2023,15 @@
     /// \note Some solvers does not provide dual ray calculation
     /// functions.
-    Value dualRay(Row r) const { return _getDualRay(rows(id(r))); }
+    Value dualRay(Row r) const { return _getDualRay(_rows(id(r))); }
 
     /// Return the basis status of the column
 
     /// \see VarStatus
-    VarStatus colStatus(Col c) const { return _getColStatus(cols(id(c))); }
+    VarStatus colStatus(Col c) const { return _getColStatus(_cols(id(c))); }
 
     /// Return the basis status of the row
 
     /// \see VarStatus
-    VarStatus rowStatus(Row r) const { return _getRowStatus(rows(id(r))); }
+    VarStatus rowStatus(Row r) const { return _getRowStatus(_rows(id(r))); }
 
     ///The value of the objective function
@@ -2081,5 +2113,5 @@
     ///
     void colType(Col c, ColTypes col_type) {
-      _setColType(cols(id(c)),col_type);
+      _setColType(_cols(id(c)),col_type);
     }
 
@@ -2089,5 +2121,5 @@
     ///
     ColTypes colType(Col c) const {
-      return _getColType(cols(id(c)));
+      return _getColType(_cols(id(c)));
     }
     ///@}
@@ -2106,5 +2138,5 @@
     ///  Return the value of the row in the solution.
     /// \pre The problem is solved.
-    Value sol(Col c) const { return _getSol(cols(id(c))); }
+    Value sol(Col c) const { return _getSol(_cols(id(c))); }
 
     /// Return the value of the expression in the solution
Index: lemon/maps.h
===================================================================
--- lemon/maps.h	(revision 1270)
+++ lemon/maps.h	(revision 1336)
@@ -26,4 +26,5 @@
 
 #include <lemon/core.h>
+#include <lemon/bits/stl_iterators.h>
 
 ///\file
@@ -2582,4 +2583,14 @@
     };
 
+    /// \brief STL style iterator for the keys mapped to \c true.
+    ///
+    /// This is an STL style wrapper for \ref TrueIt.
+    /// It can be used in range-based for loops, STL algorithms, etc.
+    LemonRangeWrapper1<TrueIt, IterableBoolMap>
+    trueKeys() {
+      return LemonRangeWrapper1<TrueIt, IterableBoolMap>(*this);
+    }
+
+
     /// \brief Iterator for the keys mapped to \c false.
     ///
@@ -2620,4 +2631,14 @@
       const IterableBoolMap* _map;
     };
+
+    /// \brief STL style iterator for the keys mapped to \c false.
+    ///
+    /// This is an STL style wrapper for \ref FalseIt.
+    /// It can be used in range-based for loops, STL algorithms, etc.
+    LemonRangeWrapper1<FalseIt, IterableBoolMap>
+    falseKeys() {
+      return LemonRangeWrapper1<FalseIt, IterableBoolMap>(*this);
+    }
+
 
     /// \brief Iterator for the keys mapped to a given value.
@@ -2664,4 +2685,13 @@
       const IterableBoolMap* _map;
     };
+
+    /// \brief STL style iterator for the keys mapped to a given value.
+    ///
+    /// This is an STL style wrapper for \ref ItemIt.
+    /// It can be used in range-based for loops, STL algorithms, etc.
+    LemonRangeWrapper2<ItemIt, IterableBoolMap, bool>
+    items(bool value) {
+      return LemonRangeWrapper2<ItemIt, IterableBoolMap, bool>(*this, value);
+    }
 
   protected:
@@ -3006,4 +3036,14 @@
     };
 
+    /// \brief STL style iterator for the keys with the same value.
+    ///
+    /// This is an STL style wrapper for \ref ItemIt.
+    /// It can be used in range-based for loops, STL algorithms, etc.
+    LemonRangeWrapper2<ItemIt, IterableIntMap, int>
+    items(int value) {
+      return LemonRangeWrapper2<ItemIt, IterableIntMap, int>(*this, value);
+    }
+
+
   protected:
 
@@ -3249,4 +3289,14 @@
     };
 
+    /// \brief STL style iterator for the keys with the same value.
+    ///
+    /// This is an STL style wrapper for \ref ItemIt.
+    /// It can be used in range-based for loops, STL algorithms, etc.
+    LemonRangeWrapper2<ItemIt, IterableValueMap, V>
+    items(const V& value) {
+      return LemonRangeWrapper2<ItemIt, IterableValueMap, V>(*this, value);
+    }
+
+
   protected:
 
Index: lemon/path.h
===================================================================
--- lemon/path.h	(revision 1270)
+++ lemon/path.h	(revision 1336)
@@ -31,4 +31,5 @@
 #include <lemon/core.h>
 #include <lemon/concepts/path.h>
+#include <lemon/bits/stl_iterators.h>
 
 namespace lemon {
@@ -140,4 +141,21 @@
       int idx;
     };
+
+    /// \brief Gets the collection of the arcs of the path.
+    ///
+    /// This function can be used for iterating on the
+    /// arcs of the path. It returns a wrapped
+    /// ArcIt, which looks like an STL container
+    /// (by having begin() and end()) which you can use in range-based
+    /// for loops, STL algorithms, etc.
+    /// For example you can write:
+    ///\code
+    /// for(auto a: p.arcs())
+    ///   doSomething(a);
+    ///\endcode
+    LemonRangeWrapper1<ArcIt, Path> arcs() const {
+      return LemonRangeWrapper1<ArcIt, Path>(*this);
+    }
+
 
     /// \brief Length of the path.
@@ -346,4 +364,21 @@
     };
 
+    /// \brief Gets the collection of the arcs of the path.
+    ///
+    /// This function can be used for iterating on the
+    /// arcs of the path. It returns a wrapped
+    /// ArcIt, which looks like an STL container
+    /// (by having begin() and end()) which you can use in range-based
+    /// for loops, STL algorithms, etc.
+    /// For example you can write:
+    ///\code
+    /// for(auto a: p.arcs())
+    ///   doSomething(a);
+    ///\endcode
+    LemonRangeWrapper1<ArcIt, SimplePath> arcs() const {
+      return LemonRangeWrapper1<ArcIt, SimplePath>(*this);
+    }
+
+
     /// \brief Length of the path.
     int length() const { return data.size(); }
@@ -543,4 +578,21 @@
       Node *node;
     };
+
+    /// \brief Gets the collection of the arcs of the path.
+    ///
+    /// This function can be used for iterating on the
+    /// arcs of the path. It returns a wrapped
+    /// ArcIt, which looks like an STL container
+    /// (by having begin() and end()) which you can use in range-based
+    /// for loops, STL algorithms, etc.
+    /// For example you can write:
+    ///\code
+    /// for(auto a: p.arcs())
+    ///   doSomething(a);
+    ///\endcode
+    LemonRangeWrapper1<ArcIt, ListPath> arcs() const {
+      return LemonRangeWrapper1<ArcIt, ListPath>(*this);
+    }
+
 
     /// \brief The n-th arc.
@@ -796,9 +848,9 @@
     ///
     /// Default constructor
-    StaticPath() : len(0), arcs(0) {}
+    StaticPath() : len(0), _arcs(0) {}
 
     /// \brief Copy constructor
     ///
-    StaticPath(const StaticPath& cpath) : arcs(0) {
+    StaticPath(const StaticPath& cpath) : _arcs(0) {
       pathCopy(cpath, *this);
     }
@@ -808,5 +860,5 @@
     /// This path can be initialized from any other path type.
     template <typename CPath>
-    StaticPath(const CPath& cpath) : arcs(0) {
+    StaticPath(const CPath& cpath) : _arcs(0) {
       pathCopy(cpath, *this);
     }
@@ -816,5 +868,5 @@
     /// Destructor of the path
     ~StaticPath() {
-      if (arcs) delete[] arcs;
+      if (_arcs) delete[] _arcs;
     }
 
@@ -883,4 +935,21 @@
       int idx;
     };
+    
+    /// \brief Gets the collection of the arcs of the path.
+    ///
+    /// This function can be used for iterating on the
+    /// arcs of the path. It returns a wrapped
+    /// ArcIt, which looks like an STL container
+    /// (by having begin() and end()) which you can use in range-based
+    /// for loops, STL algorithms, etc.
+    /// For example you can write:
+    ///\code
+    /// for(auto a: p.arcs())
+    ///   doSomething(a);
+    ///\endcode
+    LemonRangeWrapper1<ArcIt, StaticPath> arcs() const {
+      return LemonRangeWrapper1<ArcIt, StaticPath>(*this);
+    }
+    
 
     /// \brief The n-th arc.
@@ -888,5 +957,5 @@
     /// \pre \c n is in the <tt>[0..length() - 1]</tt> range.
     const Arc& nth(int n) const {
-      return arcs[n];
+      return _arcs[n];
     }
 
@@ -905,16 +974,16 @@
     void clear() {
       len = 0;
-      if (arcs) delete[] arcs;
-      arcs = 0;
+      if (_arcs) delete[] _arcs;
+      _arcs = 0;
     }
 
     /// \brief The first arc of the path.
     const Arc& front() const {
-      return arcs[0];
+      return _arcs[0];
     }
 
     /// \brief The last arc of the path.
     const Arc& back() const {
-      return arcs[len - 1];
+      return _arcs[len - 1];
     }
 
@@ -925,8 +994,8 @@
     void build(const CPath& path) {
       len = path.length();
-      arcs = new Arc[len];
+      _arcs = new Arc[len];
       int index = 0;
       for (typename CPath::ArcIt it(path); it != INVALID; ++it) {
-        arcs[index] = it;
+        _arcs[index] = it;
         ++index;
       }
@@ -936,9 +1005,9 @@
     void buildRev(const CPath& path) {
       len = path.length();
-      arcs = new Arc[len];
+      _arcs = new Arc[len];
       int index = len;
       for (typename CPath::RevArcIt it(path); it != INVALID; ++it) {
         --index;
-        arcs[index] = it;
+        _arcs[index] = it;
       }
     }
@@ -946,5 +1015,5 @@
   private:
     int len;
-    Arc* arcs;
+    Arc* _arcs;
   };
 
@@ -1158,4 +1227,23 @@
   };
 
+  /// \brief Gets the collection of the nodes of the path.
+  ///
+  /// This function can be used for iterating on the
+  /// nodes of the path. It returns a wrapped
+  /// PathNodeIt, which looks like an STL container
+  /// (by having begin() and end()) which you can use in range-based
+  /// for loops, STL algorithms, etc.
+  /// For example you can write:
+  ///\code
+  /// for(auto u: pathNodes(g,p))
+  ///   doSomething(u);
+  ///\endcode
+  template<typename Path>
+  LemonRangeWrapper2<PathNodeIt<Path>, typename Path::Digraph, Path>
+      pathNodes(const typename Path::Digraph &g, const Path &p) {
+    return
+        LemonRangeWrapper2<PathNodeIt<Path>, typename Path::Digraph, Path>(g,p);
+  }
+
   ///@}
 
Index: lemon/random.h
===================================================================
--- lemon/random.h	(revision 1340)
+++ lemon/random.h	(revision 1343)
@@ -252,6 +252,6 @@
         current = state + length;
 
-        register Word *curr = state + length - 1;
-        register long num;
+        Word *curr = state + length - 1;
+        long num;
 
         num = length - shift;
Index: lemon/smart_graph.h
===================================================================
--- lemon/smart_graph.h	(revision 1270)
+++ lemon/smart_graph.h	(revision 1336)
@@ -48,6 +48,6 @@
     };
 
-    std::vector<NodeT> nodes;
-    std::vector<ArcT> arcs;
+    std::vector<NodeT> _nodes;
+    std::vector<ArcT> _arcs;
 
   public:
@@ -60,33 +60,33 @@
   public:
 
-    SmartDigraphBase() : nodes(), arcs() { }
+    SmartDigraphBase() : _nodes(), _arcs() { }
     SmartDigraphBase(const SmartDigraphBase &_g)
-      : nodes(_g.nodes), arcs(_g.arcs) { }
+      : _nodes(_g._nodes), _arcs(_g._arcs) { }
 
     typedef True NodeNumTag;
     typedef True ArcNumTag;
 
-    int nodeNum() const { return nodes.size(); }
-    int arcNum() const { return arcs.size(); }
-
-    int maxNodeId() const { return nodes.size()-1; }
-    int maxArcId() const { return arcs.size()-1; }
+    int nodeNum() const { return _nodes.size(); }
+    int arcNum() const { return _arcs.size(); }
+
+    int maxNodeId() const { return _nodes.size()-1; }
+    int maxArcId() const { return _arcs.size()-1; }
 
     Node addNode() {
-      int n = nodes.size();
-      nodes.push_back(NodeT());
-      nodes[n].first_in = -1;
-      nodes[n].first_out = -1;
+      int n = _nodes.size();
+      _nodes.push_back(NodeT());
+      _nodes[n].first_in = -1;
+      _nodes[n].first_out = -1;
       return Node(n);
     }
 
     Arc addArc(Node u, Node v) {
-      int n = arcs.size();
-      arcs.push_back(ArcT());
-      arcs[n].source = u._id;
-      arcs[n].target = v._id;
-      arcs[n].next_out = nodes[u._id].first_out;
-      arcs[n].next_in = nodes[v._id].first_in;
-      nodes[u._id].first_out = nodes[v._id].first_in = n;
+      int n = _arcs.size();
+      _arcs.push_back(ArcT());
+      _arcs[n].source = u._id;
+      _arcs[n].target = v._id;
+      _arcs[n].next_out = _nodes[u._id].first_out;
+      _arcs[n].next_in = _nodes[v._id].first_in;
+      _nodes[u._id].first_out = _nodes[v._id].first_in = n;
 
       return Arc(n);
@@ -94,10 +94,10 @@
 
     void clear() {
-      arcs.clear();
-      nodes.clear();
-    }
-
-    Node source(Arc a) const { return Node(arcs[a._id].source); }
-    Node target(Arc a) const { return Node(arcs[a._id].target); }
+      _arcs.clear();
+      _nodes.clear();
+    }
+
+    Node source(Arc a) const { return Node(_arcs[a._id].source); }
+    Node target(Arc a) const { return Node(_arcs[a._id].target); }
 
     static int id(Node v) { return v._id; }
@@ -108,8 +108,8 @@
 
     bool valid(Node n) const {
-      return n._id >= 0 && n._id < static_cast<int>(nodes.size());
+      return n._id >= 0 && n._id < static_cast<int>(_nodes.size());
     }
     bool valid(Arc a) const {
-      return a._id >= 0 && a._id < static_cast<int>(arcs.size());
+      return a._id >= 0 && a._id < static_cast<int>(_arcs.size());
     }
 
@@ -146,5 +146,5 @@
 
     void first(Node& node) const {
-      node._id = nodes.size() - 1;
+      node._id = _nodes.size() - 1;
     }
 
@@ -154,5 +154,5 @@
 
     void first(Arc& arc) const {
-      arc._id = arcs.size() - 1;
+      arc._id = _arcs.size() - 1;
     }
 
@@ -162,17 +162,17 @@
 
     void firstOut(Arc& arc, const Node& node) const {
-      arc._id = nodes[node._id].first_out;
+      arc._id = _nodes[node._id].first_out;
     }
 
     void nextOut(Arc& arc) const {
-      arc._id = arcs[arc._id].next_out;
+      arc._id = _arcs[arc._id].next_out;
     }
 
     void firstIn(Arc& arc, const Node& node) const {
-      arc._id = nodes[node._id].first_in;
+      arc._id = _nodes[node._id].first_in;
     }
 
     void nextIn(Arc& arc) const {
-      arc._id = arcs[arc._id].next_in;
+      arc._id = _arcs[arc._id].next_in;
     }
 
@@ -267,8 +267,8 @@
     {
       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=arcs[i].next_out) {
-        arcs[i].source=b._id;
+      _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=_arcs[i].next_out) {
+        _arcs[i].source=b._id;
       }
       if(connect) addArc(n,b);
@@ -292,5 +292,5 @@
     /// to build the digraph.
     /// \sa reserveArc()
-    void reserveNode(int n) { nodes.reserve(n); };
+    void reserveNode(int n) { _nodes.reserve(n); };
 
     /// Reserve memory for arcs.
@@ -302,5 +302,5 @@
     /// to build the digraph.
     /// \sa reserveNode()
-    void reserveArc(int m) { arcs.reserve(m); };
+    void reserveArc(int m) { _arcs.reserve(m); };
 
   public:
@@ -312,15 +312,15 @@
     void restoreSnapshot(const Snapshot &s)
     {
-      while(s.arc_num<arcs.size()) {
-        Arc arc = arcFromId(arcs.size()-1);
+      while(s.arc_num<_arcs.size()) {
+        Arc arc = arcFromId(_arcs.size()-1);
         Parent::notifier(Arc()).erase(arc);
-        nodes[arcs.back().source].first_out=arcs.back().next_out;
-        nodes[arcs.back().target].first_in=arcs.back().next_in;
-        arcs.pop_back();
-      }
-      while(s.node_num<nodes.size()) {
-        Node node = nodeFromId(nodes.size()-1);
+        _nodes[_arcs.back().source].first_out=_arcs.back().next_out;
+        _nodes[_arcs.back().target].first_in=_arcs.back().next_in;
+        _arcs.pop_back();
+      }
+      while(s.node_num<_nodes.size()) {
+        Node node = nodeFromId(_nodes.size()-1);
         Parent::notifier(Node()).erase(node);
-        nodes.pop_back();
+        _nodes.pop_back();
       }
     }
@@ -363,6 +363,6 @@
       ///
       Snapshot(SmartDigraph &gr) : _graph(&gr) {
-        node_num=_graph->nodes.size();
-        arc_num=_graph->arcs.size();
+        node_num=_graph->_nodes.size();
+        arc_num=_graph->_arcs.size();
       }
 
@@ -374,6 +374,6 @@
       void save(SmartDigraph &gr) {
         _graph=&gr;
-        node_num=_graph->nodes.size();
-        arc_num=_graph->arcs.size();
+        node_num=_graph->_nodes.size();
+        arc_num=_graph->_arcs.size();
       }
 
@@ -403,6 +403,6 @@
     };
 
-    std::vector<NodeT> nodes;
-    std::vector<ArcT> arcs;
+    std::vector<NodeT> _nodes;
+    std::vector<ArcT> _arcs;
 
   public:
@@ -466,5 +466,5 @@
 
     SmartGraphBase()
-      : nodes(), arcs() {}
+      : _nodes(), _arcs() {}
 
     typedef True NodeNumTag;
@@ -472,17 +472,17 @@
     typedef True ArcNumTag;
 
-    int nodeNum() const { return nodes.size(); }
-    int edgeNum() const { return arcs.size() / 2; }
-    int arcNum() const { return arcs.size(); }
-
-    int maxNodeId() const { return nodes.size()-1; }
-    int maxEdgeId() const { return arcs.size() / 2 - 1; }
-    int maxArcId() const { return arcs.size()-1; }
-
-    Node source(Arc e) const { return Node(arcs[e._id ^ 1].target); }
-    Node target(Arc e) const { return Node(arcs[e._id].target); }
-
-    Node u(Edge e) const { return Node(arcs[2 * e._id].target); }
-    Node v(Edge e) const { return Node(arcs[2 * e._id + 1].target); }
+    int nodeNum() const { return _nodes.size(); }
+    int edgeNum() const { return _arcs.size() / 2; }
+    int arcNum() const { return _arcs.size(); }
+
+    int maxNodeId() const { return _nodes.size()-1; }
+    int maxEdgeId() const { return _arcs.size() / 2 - 1; }
+    int maxArcId() const { return _arcs.size()-1; }
+
+    Node source(Arc e) const { return Node(_arcs[e._id ^ 1].target); }
+    Node target(Arc e) const { return Node(_arcs[e._id].target); }
+
+    Node u(Edge e) const { return Node(_arcs[2 * e._id].target); }
+    Node v(Edge e) const { return Node(_arcs[2 * e._id + 1].target); }
 
     static bool direction(Arc e) {
@@ -495,5 +495,5 @@
 
     void first(Node& node) const {
-      node._id = nodes.size() - 1;
+      node._id = _nodes.size() - 1;
     }
 
@@ -503,5 +503,5 @@
 
     void first(Arc& arc) const {
-      arc._id = arcs.size() - 1;
+      arc._id = _arcs.size() - 1;
     }
 
@@ -511,5 +511,5 @@
 
     void first(Edge& arc) const {
-      arc._id = arcs.size() / 2 - 1;
+      arc._id = _arcs.size() / 2 - 1;
     }
 
@@ -519,21 +519,21 @@
 
     void firstOut(Arc &arc, const Node& v) const {
-      arc._id = nodes[v._id].first_out;
+      arc._id = _nodes[v._id].first_out;
     }
     void nextOut(Arc &arc) const {
-      arc._id = arcs[arc._id].next_out;
+      arc._id = _arcs[arc._id].next_out;
     }
 
     void firstIn(Arc &arc, const Node& v) const {
-      arc._id = ((nodes[v._id].first_out) ^ 1);
+      arc._id = ((_nodes[v._id].first_out) ^ 1);
       if (arc._id == -2) arc._id = -1;
     }
     void nextIn(Arc &arc) const {
-      arc._id = ((arcs[arc._id ^ 1].next_out) ^ 1);
+      arc._id = ((_arcs[arc._id ^ 1].next_out) ^ 1);
       if (arc._id == -2) arc._id = -1;
     }
 
     void firstInc(Edge &arc, bool& d, const Node& v) const {
-      int de = nodes[v._id].first_out;
+      int de = _nodes[v._id].first_out;
       if (de != -1) {
         arc._id = de / 2;
@@ -545,5 +545,5 @@
     }
     void nextInc(Edge &arc, bool& d) const {
-      int de = (arcs[(arc._id * 2) | (d ? 1 : 0)].next_out);
+      int de = (_arcs[(arc._id * 2) | (d ? 1 : 0)].next_out);
       if (de != -1) {
         arc._id = de / 2;
@@ -564,17 +564,17 @@
 
     bool valid(Node n) const {
-      return n._id >= 0 && n._id < static_cast<int>(nodes.size());
+      return n._id >= 0 && n._id < static_cast<int>(_nodes.size());
     }
     bool valid(Arc a) const {
-      return a._id >= 0 && a._id < static_cast<int>(arcs.size());
+      return a._id >= 0 && a._id < static_cast<int>(_arcs.size());
     }
     bool valid(Edge e) const {
-      return e._id >= 0 && 2 * e._id < static_cast<int>(arcs.size());
+      return e._id >= 0 && 2 * e._id < static_cast<int>(_arcs.size());
     }
 
     Node addNode() {
-      int n = nodes.size();
-      nodes.push_back(NodeT());
-      nodes[n].first_out = -1;
+      int n = _nodes.size();
+      _nodes.push_back(NodeT());
+      _nodes[n].first_out = -1;
 
       return Node(n);
@@ -582,16 +582,16 @@
 
     Edge addEdge(Node u, Node v) {
-      int n = arcs.size();
-      arcs.push_back(ArcT());
-      arcs.push_back(ArcT());
-
-      arcs[n].target = u._id;
-      arcs[n | 1].target = v._id;
-
-      arcs[n].next_out = nodes[v._id].first_out;
-      nodes[v._id].first_out = n;
-
-      arcs[n | 1].next_out = nodes[u._id].first_out;
-      nodes[u._id].first_out = (n | 1);
+      int n = _arcs.size();
+      _arcs.push_back(ArcT());
+      _arcs.push_back(ArcT());
+
+      _arcs[n].target = u._id;
+      _arcs[n | 1].target = v._id;
+
+      _arcs[n].next_out = _nodes[v._id].first_out;
+      _nodes[v._id].first_out = n;
+
+      _arcs[n | 1].next_out = _nodes[u._id].first_out;
+      _nodes[u._id].first_out = (n | 1);
 
       return Edge(n / 2);
@@ -599,6 +599,6 @@
 
     void clear() {
-      arcs.clear();
-      nodes.clear();
+      _arcs.clear();
+      _nodes.clear();
     }
 
@@ -702,5 +702,5 @@
     /// to build the graph.
     /// \sa reserveEdge()
-    void reserveNode(int n) { nodes.reserve(n); };
+    void reserveNode(int n) { _nodes.reserve(n); };
 
     /// Reserve memory for edges.
@@ -712,5 +712,5 @@
     /// to build the graph.
     /// \sa reserveNode()
-    void reserveEdge(int m) { arcs.reserve(2 * m); };
+    void reserveEdge(int m) { _arcs.reserve(2 * m); };
 
   public:
@@ -723,12 +723,12 @@
     {
       s._graph = this;
-      s.node_num = nodes.size();
-      s.arc_num = arcs.size();
+      s.node_num = _nodes.size();
+      s.arc_num = _arcs.size();
     }
 
     void restoreSnapshot(const Snapshot &s)
     {
-      while(s.arc_num<arcs.size()) {
-        int n=arcs.size()-1;
+      while(s.arc_num<_arcs.size()) {
+        int n=_arcs.size()-1;
         Edge arc=edgeFromId(n/2);
         Parent::notifier(Edge()).erase(arc);
@@ -737,14 +737,14 @@
         dir.push_back(arcFromId(n-1));
         Parent::notifier(Arc()).erase(dir);
-        nodes[arcs[n-1].target].first_out=arcs[n].next_out;
-        nodes[arcs[n].target].first_out=arcs[n-1].next_out;
-        arcs.pop_back();
-        arcs.pop_back();
-      }
-      while(s.node_num<nodes.size()) {
-        int n=nodes.size()-1;
+        _nodes[_arcs[n-1].target].first_out=_arcs[n].next_out;
+        _nodes[_arcs[n].target].first_out=_arcs[n-1].next_out;
+        _arcs.pop_back();
+        _arcs.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();
+        _nodes.pop_back();
       }
     }
@@ -826,6 +826,6 @@
     };
 
-    std::vector<NodeT> nodes;
-    std::vector<ArcT> arcs;
+    std::vector<NodeT> _nodes;
+    std::vector<ArcT> _arcs;
 
     int first_red, first_blue;
@@ -916,5 +916,5 @@
 
     SmartBpGraphBase()
-      : nodes(), arcs(), first_red(-1), first_blue(-1),
+      : _nodes(), _arcs(), first_red(-1), first_blue(-1),
         max_red(-1), max_blue(-1) {}
 
@@ -923,30 +923,30 @@
     typedef True ArcNumTag;
 
-    int nodeNum() const { return nodes.size(); }
+    int nodeNum() const { return _nodes.size(); }
     int redNum() const { return max_red + 1; }
     int blueNum() const { return max_blue + 1; }
-    int edgeNum() const { return arcs.size() / 2; }
-    int arcNum() const { return arcs.size(); }
-
-    int maxNodeId() const { return nodes.size()-1; }
+    int edgeNum() const { return _arcs.size() / 2; }
+    int arcNum() const { return _arcs.size(); }
+
+    int maxNodeId() const { return _nodes.size()-1; }
     int maxRedId() const { return max_red; }
     int maxBlueId() const { return max_blue; }
-    int maxEdgeId() const { return arcs.size() / 2 - 1; }
-    int maxArcId() const { return arcs.size()-1; }
-
-    bool red(Node n) const { return nodes[n._id].red; }
-    bool blue(Node n) const { return !nodes[n._id].red; }
+    int maxEdgeId() const { return _arcs.size() / 2 - 1; }
+    int maxArcId() const { return _arcs.size()-1; }
+
+    bool red(Node n) const { return _nodes[n._id].red; }
+    bool blue(Node n) const { return !_nodes[n._id].red; }
 
     static RedNode asRedNodeUnsafe(Node n) { return RedNode(n._id); }
     static BlueNode asBlueNodeUnsafe(Node n) { return BlueNode(n._id); }
 
-    Node source(Arc a) const { return Node(arcs[a._id ^ 1].target); }
-    Node target(Arc a) const { return Node(arcs[a._id].target); }
+    Node source(Arc a) const { return Node(_arcs[a._id ^ 1].target); }
+    Node target(Arc a) const { return Node(_arcs[a._id].target); }
 
     RedNode redNode(Edge e) const {
-      return RedNode(arcs[2 * e._id].target);
+      return RedNode(_arcs[2 * e._id].target);
     }
     BlueNode blueNode(Edge e) const {
-      return BlueNode(arcs[2 * e._id + 1].target);
+      return BlueNode(_arcs[2 * e._id + 1].target);
     }
 
@@ -960,5 +960,5 @@
 
     void first(Node& node) const {
-      node._id = nodes.size() - 1;
+      node._id = _nodes.size() - 1;
     }
 
@@ -972,5 +972,5 @@
 
     void next(RedNode& node) const {
-      node._id = nodes[node._id].partition_next;
+      node._id = _nodes[node._id].partition_next;
     }
 
@@ -980,9 +980,9 @@
 
     void next(BlueNode& node) const {
-      node._id = nodes[node._id].partition_next;
+      node._id = _nodes[node._id].partition_next;
     }
 
     void first(Arc& arc) const {
-      arc._id = arcs.size() - 1;
+      arc._id = _arcs.size() - 1;
     }
 
@@ -992,5 +992,5 @@
 
     void first(Edge& arc) const {
-      arc._id = arcs.size() / 2 - 1;
+      arc._id = _arcs.size() / 2 - 1;
     }
 
@@ -1000,21 +1000,21 @@
 
     void firstOut(Arc &arc, const Node& v) const {
-      arc._id = nodes[v._id].first_out;
+      arc._id = _nodes[v._id].first_out;
     }
     void nextOut(Arc &arc) const {
-      arc._id = arcs[arc._id].next_out;
+      arc._id = _arcs[arc._id].next_out;
     }
 
     void firstIn(Arc &arc, const Node& v) const {
-      arc._id = ((nodes[v._id].first_out) ^ 1);
+      arc._id = ((_nodes[v._id].first_out) ^ 1);
       if (arc._id == -2) arc._id = -1;
     }
     void nextIn(Arc &arc) const {
-      arc._id = ((arcs[arc._id ^ 1].next_out) ^ 1);
+      arc._id = ((_arcs[arc._id ^ 1].next_out) ^ 1);
       if (arc._id == -2) arc._id = -1;
     }
 
     void firstInc(Edge &arc, bool& d, const Node& v) const {
-      int de = nodes[v._id].first_out;
+      int de = _nodes[v._id].first_out;
       if (de != -1) {
         arc._id = de / 2;
@@ -1026,5 +1026,5 @@
     }
     void nextInc(Edge &arc, bool& d) const {
-      int de = (arcs[(arc._id * 2) | (d ? 1 : 0)].next_out);
+      int de = (_arcs[(arc._id * 2) | (d ? 1 : 0)].next_out);
       if (de != -1) {
         arc._id = de / 2;
@@ -1037,6 +1037,6 @@
 
     static int id(Node v) { return v._id; }
-    int id(RedNode v) const { return nodes[v._id].partition_index; }
-    int id(BlueNode v) const { return nodes[v._id].partition_index; }
+    int id(RedNode v) const { return _nodes[v._id].partition_index; }
+    int id(BlueNode v) const { return _nodes[v._id].partition_index; }
     static int id(Arc e) { return e._id; }
     static int id(Edge e) { return e._id; }
@@ -1047,20 +1047,20 @@
 
     bool valid(Node n) const {
-      return n._id >= 0 && n._id < static_cast<int>(nodes.size());
+      return n._id >= 0 && n._id < static_cast<int>(_nodes.size());
     }
     bool valid(Arc a) const {
-      return a._id >= 0 && a._id < static_cast<int>(arcs.size());
+      return a._id >= 0 && a._id < static_cast<int>(_arcs.size());
     }
     bool valid(Edge e) const {
-      return e._id >= 0 && 2 * e._id < static_cast<int>(arcs.size());
+      return e._id >= 0 && 2 * e._id < static_cast<int>(_arcs.size());
     }
 
     RedNode addRedNode() {
-      int n = nodes.size();
-      nodes.push_back(NodeT());
-      nodes[n].first_out = -1;
-      nodes[n].red = true;
-      nodes[n].partition_index = ++max_red;
-      nodes[n].partition_next = first_red;
+      int n = _nodes.size();
+      _nodes.push_back(NodeT());
+      _nodes[n].first_out = -1;
+      _nodes[n].red = true;
+      _nodes[n].partition_index = ++max_red;
+      _nodes[n].partition_next = first_red;
       first_red = n;
 
@@ -1069,10 +1069,10 @@
 
     BlueNode addBlueNode() {
-      int n = nodes.size();
-      nodes.push_back(NodeT());
-      nodes[n].first_out = -1;
-      nodes[n].red = false;
-      nodes[n].partition_index = ++max_blue;
-      nodes[n].partition_next = first_blue;
+      int n = _nodes.size();
+      _nodes.push_back(NodeT());
+      _nodes[n].first_out = -1;
+      _nodes[n].red = false;
+      _nodes[n].partition_index = ++max_blue;
+      _nodes[n].partition_next = first_blue;
       first_blue = n;
 
@@ -1081,16 +1081,16 @@
 
     Edge addEdge(RedNode u, BlueNode v) {
-      int n = arcs.size();
-      arcs.push_back(ArcT());
-      arcs.push_back(ArcT());
-
-      arcs[n].target = u._id;
-      arcs[n | 1].target = v._id;
-
-      arcs[n].next_out = nodes[v._id].first_out;
-      nodes[v._id].first_out = n;
-
-      arcs[n | 1].next_out = nodes[u._id].first_out;
-      nodes[u._id].first_out = (n | 1);
+      int n = _arcs.size();
+      _arcs.push_back(ArcT());
+      _arcs.push_back(ArcT());
+
+      _arcs[n].target = u._id;
+      _arcs[n | 1].target = v._id;
+
+      _arcs[n].next_out = _nodes[v._id].first_out;
+      _nodes[v._id].first_out = n;
+
+      _arcs[n | 1].next_out = _nodes[u._id].first_out;
+      _nodes[u._id].first_out = (n | 1);
 
       return Edge(n / 2);
@@ -1098,6 +1098,6 @@
 
     void clear() {
-      arcs.clear();
-      nodes.clear();
+      _arcs.clear();
+      _nodes.clear();
       first_red = -1;
       first_blue = -1;
@@ -1214,5 +1214,5 @@
     /// to build the graph.
     /// \sa reserveEdge()
-    void reserveNode(int n) { nodes.reserve(n); };
+    void reserveNode(int n) { _nodes.reserve(n); };
 
     /// Reserve memory for edges.
@@ -1224,5 +1224,5 @@
     /// to build the graph.
     /// \sa reserveNode()
-    void reserveEdge(int m) { arcs.reserve(2 * m); };
+    void reserveEdge(int m) { _arcs.reserve(2 * m); };
 
   public:
@@ -1235,12 +1235,12 @@
     {
       s._graph = this;
-      s.node_num = nodes.size();
-      s.arc_num = arcs.size();
+      s.node_num = _nodes.size();
+      s.arc_num = _arcs.size();
     }
 
     void restoreSnapshot(const Snapshot &s)
     {
-      while(s.arc_num<arcs.size()) {
-        int n=arcs.size()-1;
+      while(s.arc_num<_arcs.size()) {
+        int n=_arcs.size()-1;
         Edge arc=edgeFromId(n/2);
         Parent::notifier(Edge()).erase(arc);
@@ -1249,16 +1249,16 @@
         dir.push_back(arcFromId(n-1));
         Parent::notifier(Arc()).erase(dir);
-        nodes[arcs[n-1].target].first_out=arcs[n].next_out;
-        nodes[arcs[n].target].first_out=arcs[n-1].next_out;
-        arcs.pop_back();
-        arcs.pop_back();
-      }
-      while(s.node_num<nodes.size()) {
-        int n=nodes.size()-1;
+        _nodes[_arcs[n-1].target].first_out=_arcs[n].next_out;
+        _nodes[_arcs[n].target].first_out=_arcs[n-1].next_out;
+        _arcs.pop_back();
+        _arcs.pop_back();
+      }
+      while(s.node_num<_nodes.size()) {
+        int n=_nodes.size()-1;
         Node node = nodeFromId(n);
         if (Parent::red(node)) {
-          first_red = nodes[n].partition_next;
+          first_red = _nodes[n].partition_next;
           if (first_red != -1) {
-            max_red = nodes[first_red].partition_index;
+            max_red = _nodes[first_red].partition_index;
           } else {
             max_red = -1;
@@ -1266,7 +1266,7 @@
           Parent::notifier(RedNode()).erase(asRedNodeUnsafe(node));
         } else {
-          first_blue = nodes[n].partition_next;
+          first_blue = _nodes[n].partition_next;
           if (first_blue != -1) {
-            max_blue = nodes[first_blue].partition_index;
+            max_blue = _nodes[first_blue].partition_index;
           } else {
             max_blue = -1;
@@ -1275,5 +1275,5 @@
         }
         Parent::notifier(Node()).erase(node);
-        nodes.pop_back();
+        _nodes.pop_back();
       }
     }
Index: lemon/soplex.cc
===================================================================
--- lemon/soplex.cc	(revision 1270)
+++ lemon/soplex.cc	(revision 1336)
@@ -38,6 +38,6 @@
 
   SoplexLp::SoplexLp(const SoplexLp& lp) {
-    rows = lp.rows;
-    cols = lp.cols;
+    _rows = lp._rows;
+    _cols = lp._cols;
 
     soplex = new soplex::SoPlex;
@@ -123,10 +123,10 @@
 
   void SoplexLp::_eraseColId(int i) {
-    cols.eraseIndex(i);
-    cols.relocateIndex(i, cols.maxIndex());
+    _cols.eraseIndex(i);
+    _cols.relocateIndex(i, _cols.maxIndex());
   }
   void SoplexLp::_eraseRowId(int i) {
-    rows.eraseIndex(i);
-    rows.relocateIndex(i, rows.maxIndex());
+    _rows.eraseIndex(i);
+    _rows.relocateIndex(i, _rows.maxIndex());
   }
 
@@ -433,6 +433,6 @@
     _row_names.clear();
     _row_names_ref.clear();
-    cols.clear();
-    rows.clear();
+    _cols.clear();
+    _rows.clear();
     _clear_temporals();
   }
