网络流
文章平均质量分 83
i-unique
擅长各种姿势划水
展开
-
HDU 1532 Drainage Ditches(最大流+EK算法模板题)
Every time it rains on Farmer John's fields, a pond forms over Bessie's favorite clover patch. This means that the clover is covered by water for awhile and takes quite a long time to regrow. Thus, Farmer John has built a set of drainage ditches so that Be原创 2017-09-03 20:29:58 · 577 阅读 · 0 评论 -
POJ 1459 Power Network(最大流+EK算法邻接矩阵写法)
A power network consists of nodes (power stations, consumers and dispatchers) connected by power transport lines. A node u may be supplied with an amount s(u) >= 0 of power, may produce an amount 0 <= p(u) <= p max(u) of power, may consume an amount 0 <= c原创 2017-09-04 10:53:13 · 475 阅读 · 0 评论 -
POJ 1459 Power Network(最大流+dinic算法模板)
A power network consists of nodes (power stations, consumers and dispatchers) connected by power transport lines. A node u may be supplied with an amount s(u) >= 0 of power, may produce an amount 0 <= p(u) <= p max(u) of power, may consume an amount 0 <= c原创 2017-09-04 16:53:33 · 411 阅读 · 0 评论 -
网络流题集【转】
博客原文:http://blog.csdn.net/shahdza/article/details/7779537 最近搞网络流。。觉得这篇博客总结的题集感觉很有用,mark转载下来 【HDU】 1532 Drainage Ditches(入门) [最大流] 3549 Flow Problem(入门) [最大流] 3572 Task Schedule(基础) [最大流转载 2017-09-04 19:40:20 · 548 阅读 · 0 评论 -
HDU 3549 Flow Problem(最大流+EK邻接表||邻接矩阵||dinic算法模板比较)
Network flow is a well-known difficult problem for ACMers. Given a graph, your task is to find out the maximum flow for the weighted directed graph.原创 2017-09-04 19:48:33 · 886 阅读 · 0 评论 -
模板总结
属于自己的模板。。。比赛防忘记赛前复习向原创 2017-07-24 10:25:30 · 1551 阅读 · 1 评论 -
网络流基础篇——Edmond-Karp算法
网络流的相关定义: 源点:有n个点,有m条有向边,有一个点很特殊,只出不进,叫做源点。 汇点:另一个点也很特殊,只进不出,叫做汇点。 容量和流量:每条有向边上有两个量,容量和流量,从i到j的容量通常用c[i,j]表示,流量则通常是f[i,j]. 通常可以把这些边想象成道路,流量就是这条道路的车流量,容量就是道路可承受的最大的车流量。很显然的,流量<=容量。而对于每个不是源点和汇点的点来说,可以类比的想象成没有存储功能的货物的中转站,所有“进入”他们的流量和等于所有从他本身“出去”的流量。 最大流:把源点转载 2017-08-31 09:36:54 · 621 阅读 · 0 评论