Skip to content

Commit ce013fa

Browse files
authored
Merge pull request #258 from AdvikEshan/master
Readme for MST
2 parents 9d03eed + 8bc4d64 commit ce013fa

File tree

1 file changed

+33
-0
lines changed
  • Competitive Coding/Tree/Minimum Spanning Tree

1 file changed

+33
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
## Minimum spanning tree ##
2+
3+
A minimum spanning tree (MST) or minimum weight spanning tree is a subset of the edges of
4+
a connected, edge-weighted (un)directed graph that connects all the vertices together,
5+
without any cycles and with the minimum possible total edge weight.
6+
7+
That is, it is a spanning tree whose sum of edge weights is as small as possible.
8+
9+
<p align="center">
10+
<img src="https://upload.wikimedia.org/wikipedia/commons/d/d2/Minimum_spanning_tree.svg"/>
11+
</p>
12+
13+
> Properties :
14+
* A connected graph G can have more than one spanning tree.
15+
* All possible spanning trees of graph G, have the same number of edges and vertices.
16+
* Removing one edge from the spanning tree will make the graph disconnected, i.e. the spanning tree is minimally connected.
17+
* Adding one edge to the spanning tree will create a circuit or loop, i.e. the spanning tree is maximally acyclic.
18+
* A spanning tree does not have cycles and it cannot be disconnected.
19+
20+
> Mathematical Properties of Spanning Tree :
21+
* Spanning tree has n-1 edges, where n is the number of nodes (vertices).
22+
* From a complete graph, by removing maximum e - n + 1 edges, we can construct a spanning tree.
23+
* A complete undirected graph can have maximum n^(n-2) number of spanning trees.
24+
25+
> Application of Minimum spanning tree :-
26+
* Design of networks in telephone, electrical, hydraulic, TV cable, computer, road etc.
27+
* Cluster Analysis
28+
* Traveling salesman problem
29+
* Handwriting recognition
30+
31+
> There are two most important & famous spanning tree algorithm :
32+
1. Kruskal's Algorithm
33+
2. Prim's Algorithm

0 commit comments

Comments
 (0)