[Lemon-commits] Alpar Juttner: Merge
Lemon HG
hg at lemon.cs.elte.hu
Wed Apr 15 08:26:54 CEST 2009
details: http://lemon.cs.elte.hu/hg/lemon/rev/58f70400e139
changeset: 620:58f70400e139
user: Alpar Juttner <alpar [at] cs.elte.hu>
date: Wed Apr 15 07:07:25 2009 +0100
description:
Merge
diffstat:
lemon/bin_heap.h | 6 +-
lemon/concepts/graph_components.h | 8 ++--
lemon/concepts/heap.h | 6 +-
lemon/dfs.h | 2 +-
lemon/dijkstra.h | 2 +-
lemon/dimacs.h | 42 +++++++++++---------
lemon/graph_to_eps.h | 8 +---
lemon/kruskal.h | 20 ++++-----
lemon/lgf_reader.h | 30 +++++++-------
lemon/lgf_writer.h | 20 +++++-----
lemon/lp_base.h | 51 ++++++++++++-------------
lemon/maps.h | 4 +-
lemon/min_cost_arborescence.h | 8 ++--
lemon/random.h | 6 +-
lemon/suurballe.h | 2 +-
lemon/time_measure.h | 4 +-
tools/dimacs-solver.cc | 7 +--
tools/dimacs-to-lgf.cc | 9 ++--
tools/lgf-gen.cc | 8 +--
19 files changed, 118 insertions(+), 125 deletions(-)
diffs (truncated from 811 to 300 lines):
diff --git a/lemon/bin_heap.h b/lemon/bin_heap.h
--- a/lemon/bin_heap.h
+++ b/lemon/bin_heap.h
@@ -73,9 +73,9 @@
/// The item-int map must be initialized in such way that it assigns
/// \c PRE_HEAP (<tt>-1</tt>) to any element to be put in the heap.
enum State {
- IN_HEAP = 0, ///< \e
- PRE_HEAP = -1, ///< \e
- POST_HEAP = -2 ///< \e
+ IN_HEAP = 0, ///< = 0.
+ PRE_HEAP = -1, ///< = -1.
+ POST_HEAP = -2 ///< = -2.
};
private:
diff --git a/lemon/concepts/graph_components.h b/lemon/concepts/graph_components.h
--- a/lemon/concepts/graph_components.h
+++ b/lemon/concepts/graph_components.h
@@ -602,7 +602,7 @@
typedef IterableDigraphComponent Digraph;
- /// \name Base iteration
+ /// \name Base Iteration
///
/// This interface provides functions for iteration on digraph items.
///
@@ -654,7 +654,7 @@
/// @}
- /// \name Class based iteration
+ /// \name Class Based Iteration
///
/// This interface provides iterator classes for digraph items.
///
@@ -779,7 +779,7 @@
typedef IterableGraphComponent Graph;
- /// \name Base iteration
+ /// \name Base Iteration
///
/// This interface provides functions for iteration on edges.
///
@@ -818,7 +818,7 @@
/// @}
- /// \name Class based iteration
+ /// \name Class Based Iteration
///
/// This interface provides iterator classes for edges.
///
diff --git a/lemon/concepts/heap.h b/lemon/concepts/heap.h
--- a/lemon/concepts/heap.h
+++ b/lemon/concepts/heap.h
@@ -71,9 +71,9 @@
/// The item-int map must be initialized in such way that it assigns
/// \c PRE_HEAP (<tt>-1</tt>) to any element to be put in the heap.
enum State {
- IN_HEAP = 0, ///< The "in heap" state constant.
- PRE_HEAP = -1, ///< The "pre heap" state constant.
- POST_HEAP = -2 ///< The "post heap" state constant.
+ IN_HEAP = 0, ///< = 0. The "in heap" state constant.
+ PRE_HEAP = -1, ///< = -1. The "pre heap" state constant.
+ POST_HEAP = -2 ///< = -2. The "post heap" state constant.
};
/// \brief The constructor.
diff --git a/lemon/dfs.h b/lemon/dfs.h
--- a/lemon/dfs.h
+++ b/lemon/dfs.h
@@ -206,7 +206,7 @@
typedef Dfs Create;
- ///\name Named template parameters
+ ///\name Named Template Parameters
///@{
diff --git a/lemon/dijkstra.h b/lemon/dijkstra.h
--- a/lemon/dijkstra.h
+++ b/lemon/dijkstra.h
@@ -286,7 +286,7 @@
typedef Dijkstra Create;
- ///\name Named template parameters
+ ///\name Named Template Parameters
///@{
diff --git a/lemon/dimacs.h b/lemon/dimacs.h
--- a/lemon/dimacs.h
+++ b/lemon/dimacs.h
@@ -37,11 +37,16 @@
/// DIMACS file type descriptor.
struct DimacsDescriptor
{
- ///File type enum
- enum Type
- {
- NONE, MIN, MAX, SP, MAT
- };
+ ///\brief DIMACS file type enum
+ ///
+ ///DIMACS file type enum.
+ enum Type {
+ NONE, ///< Undefined type.
+ MIN, ///< DIMACS file type for minimum cost flow problems.
+ MAX, ///< DIMACS file type for maximum flow problems.
+ SP, ///< DIMACS file type for shostest path problems.
+ MAT ///< DIMACS file type for plain graphs and matching problems.
+ };
///The file type
Type type;
///The number of nodes in the graph
@@ -49,16 +54,16 @@
///The number of edges in the graph
int edgeNum;
int lineShift;
- /// Constructor. Sets the type to NONE.
+ ///Constructor. It sets the type to \c NONE.
DimacsDescriptor() : type(NONE) {}
};
///Discover the type of a DIMACS file
- ///It starts seeking the beginning of the file for the problem type
- ///and size info. The found data is returned in a special struct
- ///that can be evaluated and passed to the appropriate reader
- ///function.
+ ///This function starts seeking the beginning of the given file for the
+ ///problem type and size info.
+ ///The found data is returned in a special struct that can be evaluated
+ ///and passed to the appropriate reader function.
DimacsDescriptor dimacsType(std::istream& is)
{
DimacsDescriptor r;
@@ -96,8 +101,7 @@
}
-
- /// DIMACS minimum cost flow reader function.
+ /// \brief DIMACS minimum cost flow reader function.
///
/// This function reads a minimum cost flow instance from DIMACS format,
/// i.e. from a DIMACS file having a line starting with
@@ -253,7 +257,7 @@
}
}
- /// DIMACS maximum flow reader function.
+ /// \brief DIMACS maximum flow reader function.
///
/// This function reads a maximum flow instance from DIMACS format,
/// i.e. from a DIMACS file having a line starting with
@@ -287,7 +291,7 @@
_readDimacs(is,g,capacity,s,t,infty,desc);
}
- /// DIMACS shortest path reader function.
+ /// \brief DIMACS shortest path reader function.
///
/// This function reads a shortest path instance from DIMACS format,
/// i.e. from a DIMACS file having a line starting with
@@ -313,7 +317,7 @@
_readDimacs(is, g, length, s, t, 0, desc);
}
- /// DIMACS capacitated digraph reader function.
+ /// \brief DIMACS capacitated digraph reader function.
///
/// This function reads an arc capacitated digraph instance from
/// DIMACS 'max' or 'sp' format.
@@ -359,11 +363,11 @@
g.addArc(s,t);
}
- /// DIMACS plain (di)graph reader function.
+ /// \brief DIMACS plain (di)graph reader function.
///
- /// This function reads a (di)graph without any designated nodes and
- /// maps from DIMACS format, i.e. from DIMACS files having a line
- /// starting with
+ /// This function reads a plain (di)graph without any designated nodes
+ /// and maps (e.g. a matching instance) from DIMACS format, i.e. from
+ /// DIMACS files having a line starting with
/// \code
/// p mat
/// \endcode
diff --git a/lemon/graph_to_eps.h b/lemon/graph_to_eps.h
--- a/lemon/graph_to_eps.h
+++ b/lemon/graph_to_eps.h
@@ -268,22 +268,18 @@
/// = 1
///\image html nodeshape_1.png
///\image latex nodeshape_1.eps "SQUARE shape (1)" width=2cm
- ///
SQUARE=1,
/// = 2
///\image html nodeshape_2.png
///\image latex nodeshape_2.eps "DIAMOND shape (2)" width=2cm
- ///
DIAMOND=2,
/// = 3
///\image html nodeshape_3.png
- ///\image latex nodeshape_2.eps "MALE shape (4)" width=2cm
- ///
+ ///\image latex nodeshape_3.eps "MALE shape (3)" width=2cm
MALE=3,
/// = 4
///\image html nodeshape_4.png
- ///\image latex nodeshape_2.eps "FEMALE shape (4)" width=2cm
- ///
+ ///\image latex nodeshape_4.eps "FEMALE shape (4)" width=2cm
FEMALE=4
};
diff --git a/lemon/kruskal.h b/lemon/kruskal.h
--- a/lemon/kruskal.h
+++ b/lemon/kruskal.h
@@ -248,11 +248,11 @@
/// \ingroup spantree
///
- /// \brief Kruskal algorithm to find a minimum cost spanning tree of
+ /// \brief Kruskal's algorithm for finding a minimum cost spanning tree of
/// a graph.
///
/// This function runs Kruskal's algorithm to find a minimum cost
- /// spanning tree.
+ /// spanning tree of a graph.
/// Due to some C++ hacking, it accepts various input and output types.
///
/// \param g The graph the algorithm runs on.
@@ -264,17 +264,17 @@
/// \param in This object is used to describe the arc/edge costs.
/// It can be one of the following choices.
/// - An STL compatible 'Forward Container' with
- /// <tt>std::pair<GR::Arc,X></tt> or
- /// <tt>std::pair<GR::Edge,X></tt> as its <tt>value_type</tt>, where
- /// \c X is the type of the costs. The pairs indicates the arcs/edges
+ /// <tt>std::pair<GR::Arc,C></tt> or
+ /// <tt>std::pair<GR::Edge,C></tt> as its <tt>value_type</tt>, where
+ /// \c C is the type of the costs. The pairs indicates the arcs/edges
/// along with the assigned cost. <em>They must be in a
/// cost-ascending order.</em>
/// - Any readable arc/edge map. The values of the map indicate the
/// arc/edge costs.
///
/// \retval out Here we also have a choice.
- /// - It can be a writable \c bool arc/edge map. After running the
- /// algorithm it will contain the found minimum cost spanning
+ /// - It can be a writable arc/edge map with \c bool value type. After
+ /// running the algorithm it will contain the found minimum cost spanning
/// tree: the value of an arc/edge will be set to \c true if it belongs
/// to the tree, otherwise it will be set to \c false. The value of
/// each arc/edge will be set exactly once.
@@ -301,8 +301,8 @@
/// forest is calculated instead of a spanning tree.
#ifdef DOXYGEN
- template <class Graph, class In, class Out>
- Value kruskal(GR const& g, const In& in, Out& out)
+ template <typename Graph, typename In, typename Out>
+ Value kruskal(const Graph& g, const In& in, Out& out)
#else
template <class Graph, class In, class Out>
inline typename _kruskal_bits::KruskalValueSelector<In>::Value
@@ -314,8 +314,6 @@
}
-
-
template <class Graph, class In, class Out>
inline typename _kruskal_bits::KruskalValueSelector<In>::Value
kruskal(const Graph& graph, const In& in, const Out& out)
diff --git a/lemon/lgf_reader.h b/lemon/lgf_reader.h
--- a/lemon/lgf_reader.h
+++ b/lemon/lgf_reader.h
@@ -593,7 +593,7 @@
public:
- /// \name Reading rules
+ /// \name Reading Rules
/// @{
/// \brief Node map reading rule
@@ -698,7 +698,7 @@
/// @}
- /// \name Select section by name
More information about the Lemon-commits
mailing list