COIN-OR::LEMON - Graph Library

Changes in / [782:ceb2756dea2a:780:580af8cf2f6a] in lemon-main


Ignore:
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • lemon/bellman_ford.h

    r781 r699  
    2424/// \brief Bellman-Ford algorithm.
    2525
    26 #include <lemon/list_graph.h>
    2726#include <lemon/bits/path_dump.h>
    2827#include <lemon/core.h>
     
    777776    /// length if the algorithm has already found one.
    778777    /// Otherwise it gives back an empty path.
    779     lemon::Path<Digraph> negativeCycle() const {
     778    lemon::Path<Digraph> negativeCycle() {
    780779      typename Digraph::template NodeMap<int> state(*_gr, -1);
    781780      lemon::Path<Digraph> cycle;
  • test/bellman_ford_test.cc

    r781 r699  
    9797    p  = const_bf_test.predMap();
    9898    pp = const_bf_test.path(t);
    99     pp = const_bf_test.negativeCycle();
    10099   
    101100    for (BF::ActiveIt it(const_bf_test); it != INVALID; ++it) {}
     
    134133    b  = bf_test.reached(t);
    135134    pp = bf_test.path(t);
    136     pp = bf_test.negativeCycle();
    137135  }
    138136}
Note: See TracChangeset for help on using the changeset viewer.