In computer science, a Minimum Spanning Tree (MST) connects all nodes in a weighted graph using the cheapest possible edges without creating any cycles.
All CS Students will recognize these two greedy algorithms:
- Kruskal’s Algorithm: Sorts all the edges from smallest to largest weight and adds them one by one as long as they dont form cycles.
- Prim’s Algorithm: Starts at one node and builds the tree outward by picking the cheapest connected edge at each step.
What we are testing with Statistics:
- Hypothesis Testing & \(p\)-values: Does Prim’s actually run faster than Kruskal’s on dense graphs (graphs with lots of edges), or is the speed difference not significant?
- Simple Linear Regression: Can we use the number of edges in a graph to predict how long each algorithm takes to run?