# HG changeset patch # User deba # Date 1134583648 0 # Node ID a5b6d941ed52fd3df70ccc96084f026394abda7c # Parent 2e3a4481901ef37c466751cd711a35c62430245b Bug fix in def pred map diff -r 2e3a4481901e -r a5b6d941ed52 lemon/belmann_ford.h --- a/lemon/belmann_ford.h Sat Dec 10 19:38:53 2005 +0000 +++ b/lemon/belmann_ford.h Wed Dec 14 18:07:28 2005 +0000 @@ -17,7 +17,7 @@ #ifndef LEMON_BELMANN_FORD_H #define LEMON_BELMANN_FORD_H -///\ingroup flowalgs +/// \ingroup flowalgs /// \file /// \brief BelmannFord algorithm. /// @@ -115,8 +115,7 @@ /// \brief Instantiates a PredMap. /// /// This function instantiates a \ref PredMap. - /// \param G is the graph, to which we would like to define the PredMap. - /// \todo The graph alone may be insufficient for the initialization + /// \param graph is the graph, to which we would like to define the PredMap. static PredMap *createPredMap(const _Graph& graph) { return new PredMap(graph); } @@ -132,7 +131,7 @@ /// \brief Instantiates a DistMap. /// /// This function instantiates a \ref DistMap. - /// \param G is the graph, to which we would like to define the + /// \param graph is the graph, to which we would like to define the /// \ref DistMap static DistMap *createDistMap(const _Graph& graph) { return new DistMap(graph); @@ -269,7 +268,8 @@ /// \ref named-templ-param "Named parameter" for setting PredMap type /// template - struct DefPredMap { + struct DefPredMap + : public BelmannFord< Graph, LengthMap, DefPredMapTraits > { typedef BelmannFord< Graph, LengthMap, DefPredMapTraits > Create; }; @@ -422,7 +422,7 @@ /// strictly for all at most k length paths then it will calculate the /// distances strictly for all at most k + 1 length paths. With k /// iteration this function calculates the at most k length paths. - ///\todo what is the return value? + /// \return %True when the algorithm have not found more shorter paths. bool processNextRound() { for (int i = 0; i < (int)_process.size(); ++i) { _mask->set(_process[i], false); @@ -458,7 +458,7 @@ /// This function does not make it possible to calculate strictly the /// at most k length minimal paths, this is why it is /// called just weak round. - ///\todo what is the return value? + /// \return %True when the algorithm have not found more shorter paths. bool processNextWeakRound() { for (int i = 0; i < (int)_process.size(); ++i) { _mask->set(_process[i], false); @@ -845,7 +845,7 @@ /// \brief Runs BelmannFord algorithm from the given node. /// /// Runs BelmannFord algorithm from the given node. - /// \param s is the given source. + /// \param source is the given source. void run(Node source) { Base::_source = source; run(); @@ -910,7 +910,7 @@ /// \brief Sets the source node, from which the BelmannFord algorithm runs. /// /// Sets the source node, from which the BelmannFord algorithm runs. - /// \param s is the source node. + /// \param source is the source node. BelmannFordWizard<_Traits>& source(Node source) { Base::_source = source; return *this;