algorithm of Kruskal
algorithm of Kruskal
You can create the minimal spanning tree following the algorithm of Kruskal:
- Start with the connection that has got the lowest weight.
- Selectect the connection with the lowest weight that's still left and add it to the tree. Note: if the addition of the connection with the lowest weight creates a cycle, drop it and take the next lowest connection.
- Continue this way until all points are connected. The subgraph you arrived at is called the minimal spanning tree.