Doc improvements for kruskal()
authorPeter Kovacs <kpeter@inf.elte.hu>
Tue, 08 Jul 2008 22:56:02 +0200
changeset 19474cd0c58b348
parent 193 65cba1032f90
child 196 420013ff029b
Doc improvements for kruskal()
lemon/kruskal.h
     1.1 --- a/lemon/kruskal.h	Sun Jul 06 07:49:03 2008 +0100
     1.2 +++ b/lemon/kruskal.h	Tue Jul 08 22:56:02 2008 +0200
     1.3 @@ -32,9 +32,9 @@
     1.4  
     1.5  ///\ingroup spantree
     1.6  ///\file
     1.7 -///\brief Kruskal's algorithm to compute a minimum cost tree
     1.8 +///\brief Kruskal's algorithm to compute a minimum cost spanning tree
     1.9  ///
    1.10 -///Kruskal's algorithm to compute a minimum cost tree.
    1.11 +///Kruskal's algorithm to compute a minimum cost spanning tree.
    1.12  ///
    1.13  
    1.14  namespace lemon {
    1.15 @@ -251,9 +251,11 @@
    1.16  
    1.17    /// \ingroup spantree
    1.18    ///
    1.19 -  /// \brief Kruskal's algorithm to find a minimum cost tree of a graph.
    1.20 +  /// \brief Kruskal algorithm to find a minimum cost spanning tree of
    1.21 +  /// a graph.
    1.22    ///
    1.23 -  /// This function runs Kruskal's algorithm to find a minimum cost tree.
    1.24 +  /// This function runs Kruskal's algorithm to find a minimum cost 
    1.25 +  /// spanning tree.
    1.26    /// Due to some C++ hacking, it accepts various input and output types.
    1.27    ///
    1.28    /// \param g The graph the algorithm runs on.
    1.29 @@ -262,24 +264,25 @@
    1.30    /// If the graph is directed, the algorithm consider it to be 
    1.31    /// undirected by disregarding the direction of the arcs.
    1.32    ///
    1.33 -  /// \param in This object is used to describe the arc costs. It can be one
    1.34 -  /// of the following choices.
    1.35 +  /// \param in This object is used to describe the arc/edge costs. 
    1.36 +  /// It can be one of the following choices.
    1.37    /// - An STL compatible 'Forward Container' with
    1.38 -  /// <tt>std::pair<GR::Edge,X></tt> or
    1.39 -  /// <tt>std::pair<GR::Arc,X></tt> as its <tt>value_type</tt>, where
    1.40 -  /// \c X is the type of the costs. The pairs indicates the arcs
    1.41 +  /// <tt>std::pair<GR::Arc,X></tt> or
    1.42 +  /// <tt>std::pair<GR::Edge,X></tt> as its <tt>value_type</tt>, where
    1.43 +  /// \c X is the type of the costs. The pairs indicates the arcs/edges
    1.44    /// along with the assigned cost. <em>They must be in a
    1.45    /// cost-ascending order.</em>
    1.46 -  /// - Any readable Arc map. The values of the map indicate the arc costs.
    1.47 +  /// - Any readable arc/edge map. The values of the map indicate the 
    1.48 +  /// arc/edge costs.
    1.49    ///
    1.50 -  /// \retval out Here we also have a choise.
    1.51 -  /// - It can be a writable \c bool arc map.  After running the
    1.52 -  /// algorithm this will contain the found minimum cost spanning
    1.53 -  /// tree: the value of an arc will be set to \c true if it belongs
    1.54 +  /// \retval out Here we also have a choice.
    1.55 +  /// - It can be a writable \c bool arc/edge map. After running the
    1.56 +  /// algorithm it will contain the found minimum cost spanning
    1.57 +  /// tree: the value of an arc/edge will be set to \c true if it belongs
    1.58    /// to the tree, otherwise it will be set to \c false. The value of
    1.59 -  /// each arc will be set exactly once.
    1.60 +  /// each arc/edge will be set exactly once.
    1.61    /// - It can also be an iteraror of an STL Container with
    1.62 -  /// <tt>GR::Edge</tt> or <tt>GR::Arc</tt> as its
    1.63 +  /// <tt>GR::Arc</tt> or <tt>GR::Edge</tt> as its
    1.64    /// <tt>value_type</tt>.  The algorithm copies the elements of the
    1.65    /// found tree into this sequence.  For example, if we know that the
    1.66    /// spanning tree of the graph \c g has say 53 arcs, then we can
    1.67 @@ -290,13 +293,14 @@
    1.68    ///\endcode
    1.69    /// Or if we don't know in advance the size of the tree, we can
    1.70    /// write this.  
    1.71 -  ///\code std::vector<Arc> tree;
    1.72 +  ///\code
    1.73 +  /// std::vector<Arc> tree;
    1.74    /// kruskal(g,cost,std::back_inserter(tree)); 
    1.75    ///\endcode
    1.76    ///
    1.77 -  /// \return The total cost of the found tree.
    1.78 +  /// \return The total cost of the found spanning tree.
    1.79    ///
    1.80 -  /// \warning If kruskal runs on an be consistent of using the same
    1.81 +  /// \warning If Kruskal runs on an be consistent of using the same
    1.82    /// Arc type for input and output.
    1.83    ///
    1.84