equal
deleted
inserted
replaced
65 int cut_value ( SmartGraph& g, SmartGraph::NodeMap<bool>& cut, |
65 int cut_value ( SmartGraph& g, SmartGraph::NodeMap<bool>& cut, |
66 SmartGraph::EdgeMap<int>& cap) { |
66 SmartGraph::EdgeMap<int>& cap) { |
67 |
67 |
68 int c=0; |
68 int c=0; |
69 for(SmartGraph::EdgeIt e(g); e!=INVALID; ++e) { |
69 for(SmartGraph::EdgeIt e(g); e!=INVALID; ++e) { |
70 if (cut[g.tail(e)] && !cut[g.head(e)]) c+=cap[e]; |
70 if (cut[g.source(e)] && !cut[g.target(e)]) c+=cap[e]; |
71 } |
71 } |
72 return c; |
72 return c; |
73 } |
73 } |
74 |
74 |
75 int main() { |
75 int main() { |