COIN-OR::LEMON - Graph Library

Changeset 375:2d87dbd7f8c8 in lemon-1.2 for lemon/smart_graph.h


Ignore:
Timestamp:
11/07/08 14:14:22 (11 years ago)
Author:
Alpar Juttner <alpar@…>
Branch:
default
Parents:
372:7b6466ed488a (diff), 374:49d9a36b3b84 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Phase:
public
Message:

Merge

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • lemon/smart_graph.h

    r371 r375  
    738738        dir.push_back(arcFromId(n-1));
    739739        Parent::notifier(Arc()).erase(dir);
    740         nodes[arcs[n].target].first_out=arcs[n].next_out;
    741         nodes[arcs[n-1].target].first_out=arcs[n-1].next_out;
     740        nodes[arcs[n-1].target].first_out=arcs[n].next_out;
     741        nodes[arcs[n].target].first_out=arcs[n-1].next_out;
    742742        arcs.pop_back();
    743743        arcs.pop_back();
  • lemon/smart_graph.h

    r373 r375  
    6868
    6969    typedef True NodeNumTag;
    70     typedef True EdgeNumTag;
     70    typedef True ArcNumTag;
    7171
    7272    int nodeNum() const { return nodes.size(); }
     
    467467
    468468    public:
    469       operator Edge() const { 
    470         return _id != -1 ? edgeFromId(_id / 2) : INVALID; 
     469      operator Edge() const {
     470        return _id != -1 ? edgeFromId(_id / 2) : INVALID;
    471471      }
    472472
     
    483483      : nodes(), arcs() {}
    484484
     485    typedef True NodeNumTag;
     486    typedef True EdgeNumTag;
     487    typedef True ArcNumTag;
     488
     489    int nodeNum() const { return nodes.size(); }
     490    int edgeNum() const { return arcs.size() / 2; }
     491    int arcNum() const { return arcs.size(); }
    485492
    486493    int maxNodeId() const { return nodes.size()-1; }
Note: See TracChangeset for help on using the changeset viewer.