Doc improvements contributed by Peter Kovacs.
authoralpar
Tue, 13 Mar 2007 15:42:06 +0000
changeset 2408467ca6d16556
parent 2407 fb2052c94ebd
child 2409 fe0a8fe16271
Doc improvements contributed by Peter Kovacs.
demo/hello_world.cc
doc/algorithms.dox
doc/getting_started.dox
doc/maps1.dox
doc/maps2.dox
lemon/bellman_ford.h
lemon/circulation.h
lemon/graph_adaptor.h
lemon/ssp_min_cost_flow.h
lemon/time_measure.h
     1.1 --- a/demo/hello_world.cc	Tue Mar 13 15:35:56 2007 +0000
     1.2 +++ b/demo/hello_world.cc	Tue Mar 13 15:42:06 2007 +0000
     1.3 @@ -24,7 +24,7 @@
     1.4  /// the very basic notions of the LEMON library: \ref graphs "graphs" and
     1.5  /// \ref maps-page "maps". Click on the links to read more about these.
     1.6  ///
     1.7 -/// \include hello_lemon.cc
     1.8 +/// \include hello_world.cc
     1.9  
    1.10  #include <iostream>
    1.11  #include <lemon/list_graph.h>
     2.1 --- a/doc/algorithms.dox	Tue Mar 13 15:35:56 2007 +0000
     2.2 +++ b/doc/algorithms.dox	Tue Mar 13 15:42:06 2007 +0000
     2.3 @@ -28,7 +28,7 @@
     2.4  
     2.5  \subsection Bfs
     2.6  The algorithm is implemented in the \ref lemon::Bfs "Bfs" template class - rather than as function.
     2.7 -The class has two template parameters: \b GR and \TR.<br>
     2.8 +The class has two template parameters: \b GR and \b TR.<br>
     2.9  GR is the graph the algorithm runs on. It has \ref lemon::ListGraph "ListGraph" as default type.
    2.10  TR is a Traits class commonly used to easy the parametrization of templates. In most cases you
    2.11  wont need to modify the default type \ref lemon::BfsDefaultTraits "BfsDefaultTraits<GR>".
    2.12 @@ -51,7 +51,7 @@
    2.13  \endcode
    2.14  Now the distances and path information are stored in maps which you can access with
    2.15  member functions like \ref lemon::Bfs::distMap "distMap()" or \ref lemon::Bfs::predMap "predMap()".<br>
    2.16 -Or more directly whit other member functions like \c predNode(). Once the algorithm
    2.17 +Or more directly with other member functions like \ref lemon::Bfs::predNode "predNode()". Once the algorithm
    2.18  is finished (or to be precise reached that node) \ref lemon::Bfs::dist "dist()" or \ref lemon::Bfs::predNode
    2.19  "predNode()" can be called.
    2.20  
    2.21 @@ -115,7 +115,7 @@
    2.22  \skip MyOrdererMap
    2.23  \until };
    2.24  The class meets the \ref lemon::WriteMap "WriteMap" concept. In it's \c set() method the only thing
    2.25 -we need to do is insert the key - that is the node who's processing just finished - into the beginning
    2.26 +we need to do is insert the key - that is the node whose processing just finished - into the beginning
    2.27  of the list.<br>
    2.28  Although we implemented this needed helper class ourselves it was not necessary.
    2.29  The \ref lemon::FrontInserterBoolMap "FrontInserterBoolMap" class does exactly
     3.1 --- a/doc/getting_started.dox	Tue Mar 13 15:35:56 2007 +0000
     3.2 +++ b/doc/getting_started.dox	Tue Mar 13 15:42:06 2007 +0000
     3.3 @@ -76,7 +76,7 @@
     3.4  
     3.5  In the next few lines we add some more nodes and edges and to the graph we need.
     3.6  Those lines are not very interesting so we skip them, but you find the whole
     3.7 -working program in file hello_lemon.cc in the demo section.
     3.8 +working program in file hello_world.cc in the demo section.
     3.9  
    3.10  The next statement must be familiar. But what is that INVALID in the \c while
    3.11  test statement? In LEMON we usually use the INVALID to check if an object
     4.1 --- a/doc/maps1.dox	Tue Mar 13 15:35:56 2007 +0000
     4.2 +++ b/doc/maps1.dox	Tue Mar 13 15:42:06 2007 +0000
     4.3 @@ -34,7 +34,7 @@
     4.4  
     4.5  To make easy to use them - especially as template parameters - there are <i>map concepts</i> like by graph classes.
     4.6  <ul>
     4.7 -<li>\ref ReadMap - values can be red out with the \c operator[].
     4.8 +<li>\ref ReadMap - values can be read out with the \c operator[].
     4.9  \code value_typed_variable = map_instance[key_value]; \endcode
    4.10  </li>
    4.11  <li>\ref WriteMap - values can be set with the \c set() member function.
    4.12 @@ -59,7 +59,7 @@
    4.13  If you want to assign data to nodes, just declare a NodeMap with the corresponding
    4.14  type. As an example, think of a edge-weighted directed graph.
    4.15  \code ListGraph::EdgeMap<int>  weight(graph); \endcode
    4.16 -You can see that the map needs the graph hows edges will mapped, but nothing more.
    4.17 +You can see that the map needs the graph whose edges will mapped, but nothing more.
    4.18  
    4.19  If the graph class is extendable or erasable the map will automatically follow
    4.20  the changes you make. If a new node is added a default value is mapped to it.
     5.1 --- a/doc/maps2.dox	Tue Mar 13 15:35:56 2007 +0000
     5.2 +++ b/doc/maps2.dox	Tue Mar 13 15:42:06 2007 +0000
     5.3 @@ -42,7 +42,7 @@
     5.4  {
     5.5    typedef double Value;
     5.6    typedef Graph::Edge Key;
     5.7 -  double operator[](Key e) const { return M_PI;}
     5.8 +  double operator[](const Key &e) const { return M_PI;}
     5.9  };
    5.10  \endcode
    5.11  
    5.12 @@ -51,7 +51,7 @@
    5.13  \code
    5.14  struct MyMap : public MapBase<Graph::Edge,double>
    5.15  {
    5.16 -  Value operator[](Key e) const { return M_PI;}
    5.17 +  Value operator[](const Key& e) const { return M_PI;}
    5.18  };
    5.19  \endcode
    5.20  
     6.1 --- a/lemon/bellman_ford.h	Tue Mar 13 15:35:56 2007 +0000
     6.2 +++ b/lemon/bellman_ford.h	Tue Mar 13 15:42:06 2007 +0000
     6.3 @@ -38,7 +38,7 @@
     6.4    /// \brief Default OperationTraits for the BellmanFord algorithm class.
     6.5    ///  
     6.6    /// It defines all computational operations and constants which are
     6.7 -  /// used in the bellman ford algorithm. The default implementation
     6.8 +  /// used in the Bellman-Ford algorithm. The default implementation
     6.9    /// is based on the numeric_limits class. If the numeric type does not
    6.10    /// have infinity value then the maximum value is used as extremal
    6.11    /// infinity value.
    6.12 @@ -100,7 +100,7 @@
    6.13      // The type of the length of the edges.
    6.14      typedef typename _LengthMap::Value Value;
    6.15  
    6.16 -    /// \brief Operation traits for bellman-ford algorithm.
    6.17 +    /// \brief Operation traits for Bellman-Ford algorithm.
    6.18      ///
    6.19      /// It defines the infinity type on the given Value type
    6.20      /// and the used operation.
    6.21 @@ -410,8 +410,9 @@
    6.22      
    6.23      /// \brief Adds a new source node.
    6.24      ///
    6.25 -    /// The optional second parameter is the initial distance of the node.
    6.26 -    /// It just sets the distance of the node to the given value.
    6.27 +    /// Adds a new source node. The optional second parameter is the 
    6.28 +    /// initial distance of the node. It just sets the distance of the 
    6.29 +    /// node to the given value.
    6.30      void addSource(Node source, Value dst = OperationTraits::zero()) {
    6.31        _dist->set(source, dst);
    6.32        if (!(*_mask)[source]) {
    6.33 @@ -420,7 +421,7 @@
    6.34        }
    6.35      }
    6.36  
    6.37 -    /// \brief Executes one round from the bellman ford algorithm.
    6.38 +    /// \brief Executes one round from the Bellman-Ford algorithm.
    6.39      ///
    6.40      /// If the algoritm calculated the distances in the previous round
    6.41      /// exactly for all at most \f$ k \f$ length path lengths then it will
    6.42 @@ -463,7 +464,7 @@
    6.43        return _process.empty();
    6.44      }
    6.45  
    6.46 -    /// \brief Executes one weak round from the bellman ford algorithm.
    6.47 +    /// \brief Executes one weak round from the Bellman-Ford algorithm.
    6.48      ///
    6.49      /// If the algorithm calculated the distances in the
    6.50      /// previous round at least for all at most k length paths then it will
    6.51 @@ -517,7 +518,7 @@
    6.52      ///
    6.53      /// \pre init() must be called and at least one node should be added
    6.54      /// with addSource() before using this function. If there is
    6.55 -    /// a negative cycles in the graph it gives back false.
    6.56 +    /// a negative cycle in the graph it gives back false.
    6.57      ///
    6.58      /// This method runs the %BellmanFord algorithm from the root node(s)
    6.59      /// in order to compute the shortest path to each node. The algorithm 
    6.60 @@ -607,7 +608,7 @@
    6.61      
    6.62      ///@{
    6.63  
    6.64 -    /// \brief Lemon iterator for get a active nodes.
    6.65 +    /// \brief Lemon iterator for get the active nodes.
    6.66      ///
    6.67      /// Lemon iterator for get the active nodes. This class provides a
    6.68      /// common style lemon iterator which gives back a subset of the
    6.69 @@ -784,7 +785,7 @@
    6.70      /// \brief The value type of the length map.
    6.71      typedef typename _LengthMap::Value Value;
    6.72  
    6.73 -    /// \brief Operation traits for bellman-ford algorithm.
    6.74 +    /// \brief Operation traits for Bellman-Ford algorithm.
    6.75      ///
    6.76      /// It defines the infinity type on the given Value type
    6.77      /// and the used operation.
     7.1 --- a/lemon/circulation.h	Tue Mar 13 15:35:56 2007 +0000
     7.2 +++ b/lemon/circulation.h	Tue Mar 13 15:42:06 2007 +0000
     7.3 @@ -130,9 +130,9 @@
     7.4      ///Check if the default \c x is a feasible circulation
     7.5      bool checkX() { return checkX(_x); }
     7.6  
     7.7 -    ///Chech if \c bar is a real barrier
     7.8 +    ///Check if \c bar is a real barrier
     7.9  
    7.10 -    ///Chech if \c bar is a real barrier
    7.11 +    ///Check if \c bar is a real barrier
    7.12      ///\sa barrier()
    7.13      template<class GT>
    7.14      bool checkBarrier(GT &bar) 
    7.15 @@ -150,9 +150,9 @@
    7.16  	}
    7.17        return _tol.negative(delta);
    7.18      }  
    7.19 -    ///Chech whether or not the last execution provides a barrier
    7.20 +    ///Check whether or not the last execution provides a barrier
    7.21  
    7.22 -    ///Chech whether or not the last execution provides a barrier
    7.23 +    ///Check whether or not the last execution provides a barrier
    7.24      ///\sa barrier()
    7.25      bool checkBarrier() 
    7.26      {
     8.1 --- a/lemon/graph_adaptor.h	Tue Mar 13 15:35:56 2007 +0000
     8.2 +++ b/lemon/graph_adaptor.h	Tue Mar 13 15:42:06 2007 +0000
     8.3 @@ -1496,7 +1496,7 @@
     8.4    ///  ListGraph g;
     8.5    ///\endcode 
     8.6    ///
     8.7 -  ///Then RevGraphAdaptor implements the graph structure with node-set
     8.8 +  ///Then ResGraphAdaptor implements the graph structure with node-set
     8.9    /// \f$ V \f$ and edge-set \f$ A_{forward}\cup A_{backward} \f$,
    8.10    ///where \f$ A_{forward}=\{uv : uv\in A, f(uv)<c(uv)\} \f$ and 
    8.11    /// \f$ A_{backward}=\{vu : uv\in A, f(uv)>0\} \f$, i.e. the so called
     9.1 --- a/lemon/ssp_min_cost_flow.h	Tue Mar 13 15:35:56 2007 +0000
     9.2 +++ b/lemon/ssp_min_cost_flow.h	Tue Mar 13 15:42:06 2007 +0000
     9.3 @@ -188,8 +188,7 @@
     9.4        return flowValue();
     9.5      }
     9.6  
     9.7 -    /// \brief The class is reset to zero flow and potential. The
     9.8 -    /// class is reset to zero flow and potential.
     9.9 +    /// \brief The class is reset to zero flow and potential.
    9.10      void reset() {
    9.11        total_length=0;
    9.12        for (typename Graph::EdgeIt e(g); e!=INVALID; ++e) flow.set(e, 0);
    10.1 --- a/lemon/time_measure.h	Tue Mar 13 15:35:56 2007 +0000
    10.2 +++ b/lemon/time_measure.h	Tue Mar 13 15:42:06 2007 +0000
    10.3 @@ -233,24 +233,24 @@
    10.4    ///Class for measuring the cpu time and real time usage of the process.
    10.5    ///It is quite easy-to-use, here is a short example.
    10.6    ///\code
    10.7 -  ///#include<lemon/time_measure.h>
    10.8 -  ///#include<iostream>
    10.9 +  /// #include<lemon/time_measure.h>
   10.10 +  /// #include<iostream>
   10.11    ///
   10.12 -  ///int main()
   10.13 -  ///{
   10.14 +  /// int main()
   10.15 +  /// {
   10.16    ///
   10.17 -  ///  ...
   10.18 +  ///   ...
   10.19    ///
   10.20 -  ///  Timer T;
   10.21 -  ///  doSomething();
   10.22 -  ///  std::cout << T << '\n';
   10.23 -  ///  T.restart();
   10.24 -  ///  doSomethingElse();
   10.25 -  ///  std::cout << T << '\n';
   10.26 +  ///   Timer T;
   10.27 +  ///   doSomething();
   10.28 +  ///   std::cout << T << '\n';
   10.29 +  ///   T.restart();
   10.30 +  ///   doSomethingElse();
   10.31 +  ///   std::cout << T << '\n';
   10.32    ///
   10.33 -  ///  ...
   10.34 +  ///   ...
   10.35    ///
   10.36 -  ///}
   10.37 +  /// }
   10.38    ///\endcode
   10.39    ///
   10.40    ///The \ref Timer can also be \ref stop() "stopped" and