equal
deleted
inserted
replaced
809 bool valid(Edge e) const { |
809 bool valid(Edge e) const { |
810 return this->graph->valid(e); |
810 return this->graph->valid(e); |
811 //return e.forward ? graph->valid(e.out) : graph->valid(e.in); |
811 //return e.forward ? graph->valid(e.out) : graph->valid(e.in); |
812 } |
812 } |
813 |
813 |
|
814 bool forward(const Edge& e) const { return e.forward; } |
|
815 bool backward(const Edge& e) const { return !e.forward; } |
|
816 |
814 void augment(const Edge& e, Number a) const { |
817 void augment(const Edge& e, Number a) const { |
815 if (e.forward) |
818 if (e.forward) |
816 // flow->set(e.out, flow->get(e.out)+a); |
819 // flow->set(e.out, flow->get(e.out)+a); |
817 flow->set(e, (*flow)[e]+a); |
820 flow->set(e, (*flow)[e]+a); |
818 else |
821 else |