COIN-OR::LEMON - Graph Library

Changeset 1788:614ce2dd3cba in lemon-0.x


Ignore:
Timestamp:
11/14/05 19:34:16 (14 years ago)
Author:
Balazs Dezso
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2329
Message:

Some documentation modifications

Location:
doc
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • doc/coding_style.dox

    r1083 r1788  
    7878\endcode
    7979
     80or
     81
     82\code
     83ClassNameEndsWithError
     84\endcode
     85
    8086\section header-template Template Header File
    8187
  • doc/graph_io.dox

    r1631 r1788  
    111111\section use Using graph input-output
    112112
    113 The easiest way of using graph input and output is using the versions of the
    114   public \ref readGraph() and \ref writeGraph() functions; if you don't need
    115   very sophisticated behaviour then you might be satisfied with
    116   those. Otherwise go on reading this page.
    117113
    118114The graph input and output is based on <em> reading and writing
     
    362358and \ref lemon::UndirGraphWriter "UndirGraphWriter".
    363359
    364 The \ref lemon::UndirGraphReader::readUndirMap() "readUndirMap()"
     360The \ref lemon::UndirGraphReader::readUndirEdgeMap() "readUndirEdgeMap()"
    365361function reads an undirected map and the
    366362\ref lemon::UndirGraphReader::readUndirEdge() "readUndirEdge()"
  • doc/maps.dox

    r1183 r1788  
    2828\c EdgeMap and \c NodeMap. Both are reference maps and you can easily
    2929assign data to the nodes and to the edges of the graph. For example if you
    30 have a graph \c G defined as
     30have a graph \c g defined as
    3131\code
    32   ListGraph G;
     32  ListGraph g;
    3333\endcode
    3434and you want to assign a floating point value to each edge, you can do
    3535it like this.
    3636\code
    37   ListGraph::EdgeMap<double> length(G);
     37  ListGraph::EdgeMap<double> length(g);
    3838\endcode
    3939Note that you must give the underlying graph to the constructor.
     
    9595An alternative way to define maps is to use \c MapBase
    9696
    97 \todo For this, \c MapBase seems to be a better name then \c NullMap.
    98 
    9997\code
    10098struct MyMap : public MapBase<Graph::Edge,double>
     
    117115public:
    118116  Value operator[](Key e) const {
    119     return orig_len.get(e)-(pot.get(G.target(e))-pot.get(G.source(e)));
     117    return orig_len[e]-(pot[g.target(e)]-pot[g.source(e)]);
    120118  }
    121119 
    122120  ReducedLengthMap(const Graph &_g,
    123                    const Graph::EdgeMap &o,
    124                    const Graph::NodeMap &p)
    125     : G(g), orig_len(o), pot(p) {};
     121                   const Graph::EdgeMap &_o,
     122                   const Graph::NodeMap &_p)
     123    : g(_g), orig_len(_o), pot(_p) {};
    126124};
    127125\endcode
Note: See TracChangeset for help on using the changeset viewer.