scispace - formally typeset
Search or ask a question

Showing papers on "Greedy algorithm published in 1972"


Proceedings ArticleDOI
01 Aug 1972
TL;DR: Modifications to both Prim's and Kruskal's Algorithms are introduced which give significant improvements for the complete range of sparseness, and a dramatic reduction in execution time can be obtained for sparse networks when the network under consideration is sparse.
Abstract: A ubiquitous problem in mathematical programming is the calculation of minimum spanning trees. Minimum spanning tree algorithms find application in such diverse areas as: least cost electrical wiring, minimum cost connecting communication and transportation networks, network reliability problems, minimum stress networks, clustering and numerical taxonomy, algorithms for solving traveling salesman problems, and multiterminal network flows. It is therefore important to know how to carry out these computations as efficiently as possible.The problem is to find a spanning subtree of a given connected network which has minimum total length. Kruskal in 1956 showed that a "greedy" algorithm could be used; that is, if one looks at arcs in order of increasing length the first tree that can be formed is a minimum spanning tree. Shortly thereafter Prim and Dijkstra suggested another algorithm which appeared to be more efficient. Recent work suggests that a suitable implementation of Kruskal's Algorithm is computationally more efficient in a number of interesting cases, in particular when the network under consideration is sparse.A modification of Kruskal's Algorithm for the solution to the MST problem is presented and is compared with Prim's Algorithm. Prim's Algorithm is shown to have an upper bound on the number of calculations on the order of NN2, when applied to a network with NN nodes, regardless of the number of arcs in the network. The modification of Kruskal's Algorithm is shown to have an upper bound on the order of NA log2 NA calculations, where NA is the number of arcs in the network. Thus for sparse networks a dramatic reduction in execution time can be obtained by the use of Kruskal's Algorithm. The effect is enhanced by the fact that Prim's Algorithm achieves its upper bound while the Kruskal modification, in general, does not. Modifications to both Prim's and Kruskal's Algorithms are introduced which give significant improvements for the complete range of sparseness.The relative merit of each algorithm is a function of sparseness of the network, the form in which the problem data is represented, the tradeoff between computation speed and storage requirements, the amount of time one wants to spend in coding, as well as many other factors. The interaction of these factors in choosing the appropriate algorithms for important classes of applications will be discussed in detail.

75 citations