Bug fix in def pred map
authordeba
Wed, 14 Dec 2005 18:07:28 +0000
changeset 1858a5b6d941ed52
parent 1857 2e3a4481901e
child 1859 075aaa0a4e6f
Bug fix in def pred map
lemon/belmann_ford.h
     1.1 --- a/lemon/belmann_ford.h	Sat Dec 10 19:38:53 2005 +0000
     1.2 +++ b/lemon/belmann_ford.h	Wed Dec 14 18:07:28 2005 +0000
     1.3 @@ -17,7 +17,7 @@
     1.4  #ifndef LEMON_BELMANN_FORD_H
     1.5  #define LEMON_BELMANN_FORD_H
     1.6  
     1.7 -///\ingroup flowalgs
     1.8 +/// \ingroup flowalgs
     1.9  /// \file
    1.10  /// \brief BelmannFord algorithm.
    1.11  ///
    1.12 @@ -115,8 +115,7 @@
    1.13      /// \brief Instantiates a PredMap.
    1.14      /// 
    1.15      /// This function instantiates a \ref PredMap. 
    1.16 -    /// \param G is the graph, to which we would like to define the PredMap.
    1.17 -    /// \todo The graph alone may be insufficient for the initialization
    1.18 +    /// \param graph is the graph, to which we would like to define the PredMap.
    1.19      static PredMap *createPredMap(const _Graph& graph) {
    1.20        return new PredMap(graph);
    1.21      }
    1.22 @@ -132,7 +131,7 @@
    1.23      /// \brief Instantiates a DistMap.
    1.24      ///
    1.25      /// This function instantiates a \ref DistMap. 
    1.26 -    /// \param G is the graph, to which we would like to define the 
    1.27 +    /// \param graph is the graph, to which we would like to define the 
    1.28      /// \ref DistMap
    1.29      static DistMap *createDistMap(const _Graph& graph) {
    1.30        return new DistMap(graph);
    1.31 @@ -269,7 +268,8 @@
    1.32      /// \ref named-templ-param "Named parameter" for setting PredMap type
    1.33      ///
    1.34      template <class T>
    1.35 -    struct DefPredMap {
    1.36 +    struct DefPredMap 
    1.37 +      : public BelmannFord< Graph, LengthMap, DefPredMapTraits<T> > {
    1.38        typedef BelmannFord< Graph, LengthMap, DefPredMapTraits<T> > Create;
    1.39      };
    1.40      
    1.41 @@ -422,7 +422,7 @@
    1.42      /// strictly for all at most k length paths then it will calculate the 
    1.43      /// distances strictly for all at most k + 1 length paths. With k
    1.44      /// iteration this function calculates the at most k length paths.
    1.45 -    ///\todo what is the return value?
    1.46 +    /// \return %True when the algorithm have not found more shorter paths.
    1.47      bool processNextRound() {
    1.48        for (int i = 0; i < (int)_process.size(); ++i) {
    1.49  	_mask->set(_process[i], false);
    1.50 @@ -458,7 +458,7 @@
    1.51      /// This function does not make it possible to calculate strictly the
    1.52      /// at most k length minimal paths, this is why it is
    1.53      /// called just weak round.
    1.54 -    ///\todo what is the return value?
    1.55 +    /// \return %True when the algorithm have not found more shorter paths.
    1.56      bool processNextWeakRound() {
    1.57        for (int i = 0; i < (int)_process.size(); ++i) {
    1.58  	_mask->set(_process[i], false);
    1.59 @@ -845,7 +845,7 @@
    1.60      /// \brief Runs BelmannFord algorithm from the given node.
    1.61      ///
    1.62      /// Runs BelmannFord algorithm from the given node.
    1.63 -    /// \param s is the given source.
    1.64 +    /// \param source is the given source.
    1.65      void run(Node source) {
    1.66        Base::_source = source;
    1.67        run();
    1.68 @@ -910,7 +910,7 @@
    1.69      /// \brief Sets the source node, from which the BelmannFord algorithm runs.
    1.70      ///
    1.71      /// Sets the source node, from which the BelmannFord algorithm runs.
    1.72 -    /// \param s is the source node.
    1.73 +    /// \param source is the source node.
    1.74      BelmannFordWizard<_Traits>& source(Node source) {
    1.75        Base::_source = source;
    1.76        return *this;