COIN-OR::LEMON - Graph Library

Ticket #57: fb41d1fb4641.patch

File fb41d1fb4641.patch, 2.3 KB (added by Peter Kovacs, 16 years ago)

More improvements

  • lemon/grid_graph.h

    # HG changeset patch
    # User Peter Kovacs <kpeter@inf.elte.hu>
    # Date 1224328500 -7200
    # Node ID fb41d1fb4641830275aa31079ab5dc65f058abe1
    # Parent  109f3948dcc39faff5b00a266c77a3d372a4807d
    Fixes and improvements related to GridGraph
    
    diff --git a/lemon/grid_graph.h b/lemon/grid_graph.h
    a b  
    184184
    185185    class Edge {
    186186      friend class GridGraphBase;
     187      friend class Arc;
    187188
    188189    protected:
    189190      int _id;
     
    472473  /// in the \c [0..width()-1] range and j is in the \c
    473474  /// [0..height()-1] range.  Two nodes are connected in the graph if
    474475  /// the indexes differ exactly on one position and exactly one is
    475   /// the difference. The nodes of the graph be indexed by position
    476   /// with \c operator()() function. The positions of the nodes can be
     476  /// the difference. The nodes of the graph can be indexed by position
     477  /// with the \c operator()() function. The positions of the nodes can be
    477478  /// get with \c pos(), \c col() and \c row() members. The outgoing
    478479  /// arcs can be retrieved with the \c right(), \c up(), \c left()
    479480  /// and \c down() functions, where the bottom-left corner is the
    480481  /// origin.
    481482  ///
    482483  /// \image html grid_graph.png
    483   /// \image latex grid_graph.eps "Grid digraph" row_num=\textrow_num
     484  /// \image latex grid_graph.eps "Grid graph" row_num=\textrow_num
    484485  ///
    485486  /// A short example about the basic usage:
    486487  ///\code
     
    493494  /// }
    494495  ///\endcode
    495496  ///
    496   /// The graph type is fully conform to the \ref concepts::Graph
     497  /// This graph type is fully conform to the \ref concepts::Graph
    497498  /// "Graph" concept, and it also has an important extra feature
    498   /// that its maps are real \ref concepts::ReferenceMap "reference
    499   /// map"s.
     499  /// that its maps are real \ref concepts::ReferenceMap
     500  /// "reference map"s.
    500501  class GridGraph : public ExtendedGridGraphBase {
    501502  public:
    502503
  • test/graph_test.cc

    diff --git a/test/graph_test.cc b/test/graph_test.cc
    a b  
    192192  GRAPH_TYPEDEFS(Graph);
    193193  Graph G(width, height);
    194194
    195   check(G.width() == width, "Wrong row number");
    196   check(G.height() == height, "Wrong column number");
     195  check(G.width() == width, "Wrong column number");
     196  check(G.height() == height, "Wrong row number");
    197197
    198198  for (int i = 0; i < width; ++i) {
    199199    for (int j = 0; j < height; ++j) {