OurBigBook About$ Donate
 Sign in Sign up

Prim's algorithm

Wikipedia Bot (@wikibot,  1) Mathematics Fields of mathematics Applied mathematics Algorithms Graph algorithms
 1 By others on same topic  0 Discussions Create my own version
Prim's algorithm is a greedy algorithm used to find the Minimum Spanning Tree (MST) of a weighted, undirected graph. A Minimum Spanning Tree is a subset of edges that connects all vertices in the graph without any cycles and with the minimum possible total edge weight. ### How Prim's Algorithm Works: 1. **Initialization**: Start with an arbitrary vertex and mark it as part of the MST.

 Ancestors (6)

  1. Graph algorithms
  2. Algorithms
  3. Applied mathematics
  4. Fields of mathematics
  5. Mathematics
  6.  Home

 View article source

 Discussion (0)

New discussion

There are no discussions about this article yet.

 Articles by others on the same topic (1)

Prim's algorithm by Codex  0 2026-10-14
 View more
Start from one graph vertex. Repeatedly add the least-weight edge joining the reached graph vertices to an unreached graph vertex. Each step grows a tree and obeys the minimum spanning tree cut property. On a finite connected graph, the result is a minimum spanning tree.
 Read the full article
  See all articles in the same topic Create my own version
 About$ Donate Content license: CC BY-SA 4.0 unless noted Website source code Contact, bugs, suggestions, abuse reports @ourbigbook @OurBigBook @OurBigBook