
网络流
文章平均质量分 89
poursoul
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
费用流 模板 MCMF
本模板采用的是原创 2014-06-14 13:19:43 · 1246 阅读 · 0 评论 -
【HDU】3251 Being a Hero 最小割边集【注意】
传送门:【HDU】3251 Being a Hero原创 2014-07-30 22:14:01 · 1170 阅读 · 0 评论 -
【HDU】3996 Gold Mine 最大权闭合子图
传送门:【HDU】3996 Gold Mine题目分析:zui da quan bi原创 2014-08-01 21:29:14 · 1089 阅读 · 6 评论 -
【POJ】3084 Panic Room 最小割
传送门:【POJ】3084 Panic Room题目分析:POJ今天的C++逗我玩呢。。G+原创 2014-08-03 10:11:42 · 695 阅读 · 0 评论 -
【POJ】3204 Ikki's Story I - Road Reconstruction 最大流
传送门:【POJ】3204 Ikki's Story I - Road Reconstruction原创 2014-08-03 11:00:17 · 632 阅读 · 0 评论 -
【TJU】2944 Mussy Paper 最大权闭合子图
传送门:【TJU】2944 Mussy Paper原创 2014-08-07 10:47:50 · 621 阅读 · 0 评论 -
【SPOJ】13041 The Black Riders 二分最大流
传送门:【SPOJ】13041 The Black Riders原创 2014-09-05 20:30:57 · 1064 阅读 · 2 评论 -
【HDU】4975 A simple Gaussian elimination problem. 网络流——行列建边
传送门:【HDU】4975 A simple Gaussian elimination problem.原创 2014-08-21 18:41:04 · 790 阅读 · 0 评论 -
【HDU】4971 A simple brute force problem. 强连通缩点+最大权闭合子图
传送门:【HDU】4971 A simple brute force problem.题目分析:这chang duo xiao原创 2014-08-21 18:58:43 · 801 阅读 · 2 评论 -
【HDU】4406 GPA 最大费用流
传送门:原创 2014-08-24 11:55:17 · 808 阅读 · 0 评论 -
【HDU】3657 Game 最小割
传送门:【HDU】3657 Game题目分析:原创 2014-07-30 20:02:43 · 826 阅读 · 0 评论 -
UVa 1659 Help Little Laura 最大费用循环流
传送门:UVa 1659 Help Little Laura原创 2014-06-13 22:25:20 · 2228 阅读 · 0 评论 -
LA 2796 Concert Hall Scheduling 费用流
2796 - Concert Hall SchedulingTime limit: 3.000 second原创 2014-06-10 19:19:02 · 1147 阅读 · 0 评论 -
LA 2197 Paint the Roads 费用流
传送门:LA 2197 Paint the Roads原创 2014-06-10 19:45:22 · 813 阅读 · 0 评论 -
LA 5095 Transportation 费用流
传送门:LA 5095 Transportation原创 2014-06-10 19:54:46 · 956 阅读 · 3 评论 -
【HDU】3820 Golden Eggs 最小割
传送门:【HDU】3820 Golden Eggs题目分析:最小割!原创 2014-07-31 10:52:03 · 1270 阅读 · 0 评论 -
【HDU】4862 Jump 费用流
传送门:【HDU】4862 Jumpti原创 2014-07-22 20:56:05 · 1248 阅读 · 0 评论 -
【UVALive】 3353 Optimal Bus Route Design 费用流
传送门:LA 3353 Optimal Bus Route Design原创 2014-06-14 13:03:46 · 1385 阅读 · 1 评论 -
【POJ】 3422 Kaka’s Matrix Travels 费用流
Kaka's Matrix TravelsTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 7465 Accepted: 3004DescriptionOn an N × N chessboard with a non-negative number in原创 2014-07-03 19:16:35 · 656 阅读 · 0 评论 -
【POJ】 3680 Intervals 离散 + 费用流
IntervalsTime Limit: 5000MS Memory Limit: 65536KTotal Submissions: 6246 Accepted: 2542DescriptionYou are given N weighted open intervals. The ith interval covers原创 2014-07-03 19:16:37 · 716 阅读 · 0 评论 -
【POJ】 3762 The Bonus Salary! 离散 + 费用流
The Bonus Salary!Time Limit: 2000MS Memory Limit: 65536KTotal Submissions: 2321 Accepted: 606DescriptionIn order to encourage employees' productivity, ACM Compa原创 2014-07-03 19:16:39 · 611 阅读 · 0 评论 -
【ZOJ】3362 Beer Problem 最小费用流
传送门:【ZOJ】3362 Beer Problem题目分析:这道题本来ying gai原创 2014-08-05 21:29:32 · 699 阅读 · 0 评论 -
【HDU】4411 Arrest 费用流
传送门:【HDU】4411 Arrest题目分析:原创 2014-08-23 20:53:02 · 1116 阅读 · 0 评论 -
【BZOJ】1324 Exca王者之剑 最大权独立集
传送门:【BZOJ】1324 Exca王者之剑题目分析:赤裸裸的最大权独立集。原创 2014-09-09 11:44:34 · 797 阅读 · 0 评论 -
【codeforces】Codeforces Round #284 (Div. 1) 【题解】
传送门:【codeforces】Codeforces Round #284 (Div. 1)498A题目等价于给N条直线,如果两个点分别在直线两侧,则++cnt,最后的答案就是cnt的值。方法就是带入点的坐标到直线方程ax+by+c中看得到的两个值的乘积是否小于0,小于0则++cnt。而我,用了十分蠢的方法!将直线变成线段,将所给两个点连接,这样题目就变成求与所给两点构成的线段原创 2014-12-25 21:45:42 · 1928 阅读 · 5 评论 -
【Live Archive】6395 SurelyYouCongest【最短路+最大流】
传送门:【Live Archive】6395 SurelyYouCongest题目分析:我们只要从点1开始做一次最短路预处理,然后对于给定的源点们,对于最短路图构成一个层次图,然后由于每一层都是互不影响的,所以我们对每一层暴力跑网络流就好了。my code:my~~code:#include <stdio.h>#include <string.h>#include <set>#include原创 2015-05-06 21:15:03 · 879 阅读 · 0 评论 -
【HDU】4322 Candy 【最小费用流——给每条边一个被流优先级】
传送门:【HDU】4322 Candy前言:这道题我做了近两个星期,终于艹出来了,真的是太弱了…… 在上周日的时候,想到一个O(N∗3N)O(N*3^N)的BFS算法,然后果不其然的TLE了,然后测了下发现这题有超过200组数据,真是‘哔——’了狗了……题目分析: 首先,我们只考虑糖果对喜欢该糖果的小朋友的贡献,如果小朋友i喜欢糖果j,那么我们建边j->i,容量1,费用0。如果这条边被流过,说明原创 2015-05-30 13:03:23 · 1252 阅读 · 1 评论 -
【HDU】5383 Yu-Gi-Oh!【费用流】
传送门:【HDU】5383 Yu-Gi-Oh!my code:my~~code:#include <stdio.h>#include <string.h>#include <vector>#include <algorithm>using namespace std ;typedef long long LL ;#define clr( a , x ) memset ( a , x , s原创 2015-08-13 21:16:01 · 1133 阅读 · 0 评论 -
【Codeforces】280D k-Maximum Subsequence Sum【区间内k段最大和——线段树模拟费用流】
传送门:【Codeforces】280D k-Maximum Subsequence Sumkey word:取反my code:my~~code:#include <stdio.h>#include <string.h>#include <vector>#include <algorithm>using namespace std ;typedef long long LL ;#defi原创 2015-12-28 12:26:26 · 1283 阅读 · 0 评论 -
【HDU】5740 Glorious Brilliance【费用流】
题目链接:Glorious Brilliance#include <bits/stdc++.h>using namespace std ;typedef long long LL ;#define clr( a , x ) memset ( a , x , sizeof a )const int MAXN = 505 ;const int MAXE = 2000005 ;const int I原创 2016-10-08 20:01:02 · 707 阅读 · 0 评论 -
【codeforces】704D. Captain America 【上下界最小流】
题目链接:D. Captain America上下界最小流模板题,离散化建图跑即可。By No.baka, contest: Codeforces Round #366 (Div. 1), problem: (D) Captain America, Accepted, # #include <bits/stdc++.h>using namespace std ;#define clr( a ,原创 2016-10-08 10:23:16 · 940 阅读 · 0 评论 -
【codeforces】739D. Recover a functional graph【最大流实现匹配】
题目链接:【codeforces】739D. Recover a functional graph其实就是一个匹配问题,先枚举最大的那些”x ?”放在哪个环上,那么接下来哪些地方是一定要填的都已经知道了,还没有填的地方我们就用匹配来实现。构造方案比较简单,肯定是链只从同样大小的环中随便选一个,然后再选一个点连出来,然后确定最长的树链,剩下的深度为ii的就指向深度为i−1i-1的树链上的点即可,深度0原创 2016-11-29 16:11:28 · 989 阅读 · 1 评论 -
【topcoder】570div1 900 CurvyonRails【费用流】
#include <bits/stdc++.h>using namespace std ;#define clr( a , x ) memset ( a , x , sizeof a )const int MAXN = 3505 ;const int MAXE = 100005 ;const int INF = 0x3f3f3f3f ;struct Edge { int v , c ,原创 2016-11-30 21:09:02 · 614 阅读 · 0 评论 -
【POJ】3189 Steady Cow Assignment 二分最大流
传送门:【POJ】Steady Cow Assignment原创 2014-07-31 21:25:24 · 774 阅读 · 3 评论 -
【ACDream】1355 Domino in Casino 费用流
传送门:【ACDream】1355 Domino in Casino原创 2014-10-11 17:58:23 · 840 阅读 · 0 评论 -
【ZOJ】2539 Energy Minimization 最小割——项目分配问题
传送门:【ZOJ】2539 Energy Minimization题目分析:还是项目分配问题,还是曾经的wei dao原创 2014-08-04 21:04:13 · 754 阅读 · 0 评论 -
【COGS】746 [网络流24题] 骑士共存 最大独立集
传送门:原创 2014-09-10 19:28:15 · 790 阅读 · 0 评论 -
【COGS】1595 [USACO FEB05]神秘的挤奶机 二分最大流
传送门:【COGS】1595 [USACO FEB05]神秘的挤奶机题目分析:赤果果的er原创 2014-09-11 22:20:57 · 939 阅读 · 0 评论 -
【SGU】252 Railway Communication 最小权路径覆盖
传送门:【SGU】252 Railway Communication题目分析:yuan dian原创 2014-09-15 13:08:35 · 1238 阅读 · 0 评论 -
【COGS】1325 [ZJOI2010] 网络扩容 最大流+费用流
传送门:【COGS】1325 [ZJOI2010] 网络扩容原创 2014-09-15 14:34:51 · 818 阅读 · 0 评论