搜索资源列表
最小生成树prim算法
- 最小生成树的prim算法 是求图中的最短路径的一个重要算法 但是是O(n2)复杂度的一个算法-minimum spanning tree algorithm is the prim map for the shortest path algorithm of an important but is O (n2) of a complex algorithm
clonePtr
- a non-sharing smart pointer class that can be used with STL containers such as std::map, vector, list, set, and deque. The smart pointer has an assignment operator and greater than operator that call the target object s operator.-a non-sharing smart
ImproveShortestPathArithmetic
- 应用斐波纳契堆和邻接表改进单源最短路径算法,使其算法的时间复杂性由O( )减少为O(nlogn+e),其中e为有向图的边的条数。-application Fibonacci heap and the adjacent table to improve single source shortest path algorithm, its algorithm's time complexity of O () reduced to O (nlogn e), where e is for th
2(2)
- 最小生成树之Prim算法 Prim算法用于求无向图的最小生成树 设图G =(V,E),其生成树的顶点集合为U。 ①、把v0放入U。 ②、在所有u∈U,v∈V-U的边(u,v)∈E中找一条最小权值的边,加入生成树。 ③、把②找到的边的v加入U集合。如果U集合已有n个元素,则结束,否则继续执行②。 其算法的时间复杂度为O(n^2) Prim算法实现: (1)集合:设置一个数组set(i=0,1,..,n-1),初始值为 0,代表对
Lying-data-structure9
- 《大话数据结构》主要内容包含:数据结构介绍、算法推导大O阶的方法;顺序结构与链式结构差异、栈与队列的应用;串的朴素模式匹配、KMP模式匹配算法;二叉树前中后序遍历、赫夫曼树及应用;图的深度、广度遍历;最小生成树两种算法、最短路径两种算法;拓扑排序与关键路径算法;折半查找、插值查找、斐波那契查找等静态查找;稠密索引、分块索引、倒排索引等索引技术;冒泡、选择、插入等简单排序;希尔、堆、归并、快速等改进排序-" Westward the data structure," the m
find_way
- 求最地图的短路径 时间复杂度为o(n),空间也没要多大-Seek the shortest path of map Time complexity iso(n)