开发工具:
文件大小: 451kb
下载次数: 0
上传时间: 2012-12-02
详细说明: 目录 一.数论..................................................................................................................................................4 1.阶乘最后非零位..........................................................................................................................4 2. 模线性方程(组).........................................................................................................................4 3. 素数表.......................................................................................................... .............................. 6 4. 素数随机判定(miller_rabin).................................................................................................... 6 5. 质因数分解................................................................................................................................7 6. 最大公约数欧拉函数............................................................................................................... 8 二.图论_匹配.....................................................................................................................................10 1. 二分图最大匹配(hungary 邻接表形式)............................................................................... 10 2. 二分图最大匹配(hungary 邻接表形式,邻接阵接口)......................................................... 10 3. 二分图最大匹配(hungary 邻接阵形式)............................................................................... 11 4. 二分图最大匹配(hungary 正向表形式)............................................................................... 11 5. 二分图最佳匹配(kuhn_munkras 邻接阵形式)....................................................................12 6. 一般图匹配(邻接表形式)...................................................................................................... 13 7. 一般图匹配(邻接表形式,邻接阵接口)................................................................................ 14 8. 一般图匹配(邻接阵形式)...................................................................................................... 15 9. 一般图匹配(正向表形式)...................................................................................................... 16 三.图论_生成树.................................................................................................................................19 1. 最小生成树(kruskal 邻接表形式).........................................................................................19 2. 最小生成树(kruskal 正向表形式).........................................................................................20 3. 最小生成树(prim+binary_heap 邻接表形式)...................................................................... 21 4. 最小生成树(prim+binary_heap 正向表形式)...................................................................... 22 5. 最小生成树(prim+mapped_heap 邻接表形式)....................................................................23 6. 最小生成树(prim+mapped_heap 正向表形式)....................................................................24 7. 最小生成树(prim 邻接阵形式)............................................................................................. 26 8. 最小树形图(邻接阵形式)...................................................................................................... 26 四.图论_网络流.................................................................................................................................28 1. 上下界最大流(邻接表形式)..................................................................................................28 2. 上下界最大流(邻接阵形式)..................................................................................................29 3. 上下界最小流(邻接表形式)..................................................................................................30 4. 上下界最小流(邻接阵形式)..................................................................................................31 5. 最大流(邻接表形式).............................................................................................................. 32 6. 最大流(邻接表形式,邻接阵接口).........................................................................................33 7. 最大流(邻接阵形式).............................................................................................................. 34 8. 最大流无流量(邻接阵形式)..................................................................................................35 9. 最小费用最大流(邻接阵形式)..............................................................................................36 五. 图论_最短路径..............................................................................................................................37 1. 最短路径(单源bellman_ford 邻接阵形式)......................................................................... 37 2. 最短路径(单源dijkstra_bfs 邻接表形式)............................................................................ 37 3. 最短路径(单源dijkstra_bfs 正向表形式)............................................................................ 38 4. 最短路径(单源dijkstra+binary_heap 邻接表形式)............................................................ 38 2 5. 最短路径(单源dijkstra+binary_heap 正向表形式)............................................................ 39 6. 最短路径(单源dijkstra+mapped_heap 邻接表形式)..........................................................40 7. 最短路径(单源dijkstra+mapped_heap 正向表形式)..........................................................41 8. 最短路径(单源dijkstra 邻接阵形式)................................................................................... 43 9. 最短路径(多源floyd_warshall 邻接阵形式).......................................................................43 六. 图论_连通性..................................................................................................................................46 1. 无向图关键边(dfs 邻接阵形式)............................................................................................46 2. 无向图关键点(dfs 邻接阵形式)............................................................................................46 3. 无向图块(bfs 邻接阵形式).................................................................................................... 47 4. 无向图连通分支(bfs 邻接阵形式)........................................................................................48 5. 无向图连通分支(dfs 邻接阵形式)........................................................................................49 6. 有向图强连通分支(bfs 邻接阵形式)....................................................................................49 7. 有向图强连通分支(dfs 邻接阵形式)....................................................................................50 8. 有向图最小点基(邻接阵形式)..............................................................................................51 七. 图论_应用...................................................................................................................................... 52 1.欧拉回路(邻接阵形式)............................................................................................................ 52 2. 前序表转化..............................................................................................................................52 3. 树的优化算法..........................................................................................................................53 4. 拓扑排序(邻接阵形式).......................................................................................................... 54 5. 最佳边割集..............................................................................................................................55 6. 最佳顶点割集..........................................................................................................................56 7. 最小边割集..............................................................................................................................57 8. 最小顶点割集..........................................................................................................................59 9. 最小路径覆盖..........................................................................................................................60 八. 图论_NP 搜索................................................................................................................................61 1. 最大团(n 小于64)(faster).......................................................................................................61 2. 最大团...................................................................................................................................... 63 九. 组合.................................................................................................................................................65 1. 排列组合生成..........................................................................................................................65 2. 生成gray 码.............................................................................................................................66 3. 置换(polya).............................................................................................................................. 67 4. 字典序全排列..........................................................................................................................67 5. 字典序组合..............................................................................................................................68 6. 组合公式..................................................................................................................................68 十. 数值计算........................................................................................................................................ 70 1. 定积分计算(Romberg)............................................................................................................70 2. 多项式求根(牛顿法).............................................................................................................. 71 3. 周期性方程(追赶法).............................................................................................................. 73 十一. 几何............................................................................................................................................ 75 1. 多边形...................................................................................................................................... 75 2. 多边形切割..............................................................................................................................78 3. 浮点函数..................................................................................................................................79 4. 几何公式..................................................................................................................................84 5. 面积.......................................................................................................................................... 85 3 6. 球面.......................................................................................................................................... 86 7. 三角形...................................................................................................................................... 87 8. 三维几何..................................................................................................................................89 9. 凸包(graham)...........................................................................................................................97 10. 网格(pick).............................................................................................................................. 99 11. 圆.......................................................................................................................................... 100 12. 整数函数..............................................................................................................................102 13. 注意...................................................................................................................................... 104 十二. 结构.......................................................................................................................................... 106 1. 并查集.................................................................................................................................... 106 2. 并查集扩展(friend_enemy)..................................................................................................106 3. 堆(binary)...............................................................................................................................107 4. 堆(mapped)............................................................................................................................ 107 5. 矩形切割................................................................................................................................108 6. 线段树.................................................................................................................................... 109 7. 线段树扩展............................................................................................................................111 8. 线段树应用............................................................................................................................113 9. 子段和.................................................................................................................................... 113 10. 子阵和.................................................................................................................................. 114 十三. 其他.......................................................................................................................................... 115 1. 分数........................................................................................................................................ 115 2. 矩阵........................................................................................................................................ 116 3. 日期........................................................................................................................................ 119 4. 线性方程组(gauss)................................................................................................................120 5. 线性相关................................................................................................................................122 十四. 应用.......................................................................................................................................... 123 1. joseph.......................................................................................................................................123 2. N 皇后构造解.........................................................................................................................123 3. 布尔母函数............................................................................................................................124 4. 第k 元素................................................................................................................................125 5. 幻方构造................................................................................................................................125 6. 模式匹配(kmp)......................................................................................................................126 7. 逆序对数................................................................................................................................127 8. 字符串最小表示................................................................................................................... 127 9. 最长公共单调子序列........................................................................................................... 128 10. 最长子序列..........................................................................................................................129 11. 最大子串匹配......................................................................................................................130 12. 最大子段和..........................................................................................................................131 13. 最大子阵和..........................................................................................................................131 ...展开收缩
(系统自动生成,下载前可以参看下载内容)
下载文件列表
相关说明
- 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
- 本站是交换下载平台,提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度。
- 本站已设置防盗链,请勿用迅雷、QQ旋风等多线程下载软件下载资源,下载后用WinRAR最新版进行解压.
- 如果您发现内容无法下载,请稍后再次尝试;或者到消费记录里找到下载记录反馈给我们.
- 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
- 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.