enhancing kruskal's algorithm

Job ID: 33539948

Budget: $30 – $250 USD

Part I. In the theoretical part, you are requested to:
a. Redesign the Kruskal's algorithm in more efficient way if we assume that the edge weights in the input
graphs are uniformly distributed over [0, 1).
b. Analyze the designed algorithm
c. Compare the modified algorithm with the original one.

Part II. In the practical part, you are requested to:
a. Implement the Kruskal's algorithm before (Kruskal_before) and after (Kruskal_after) the modification.
b. Test and analyze the implemented algorithms on graphs in which edge weights are uniformly distributed
over [0, 1) as follow:

1. Run your programs Kruskal_before and Kruskal_after on different sizes of edges varying from E=50
to E=200 by step of 50. Record the running time in each run. For each graph, perform 5 runs with
different edge weights that are uniformly distributed over [0, 1). Then display your results as shown
in the following tables A, B, and C.

Table A: For each algorithm (Kruskal_before and Kruskal_after) and each size (50, 100, 150, and 200)
of the edges, provide the average running time performed by the algorithm.

Table B: For each algorithm (Kruskal_before and Kruskal_after) and each size (50, 100, 150, and 200)
of the edges, provide the best case of the algorithm (case where the minimum running time by the
algorithm is reached).

Table C: For each algorithm (Kruskal_before and Kruskal_after) and each size (50, 100, 150, and 200)
of the edges, provide the worst case of the algorithm (case where the maximum running time by the
algorithm is reached).

2. Draw illustrative figures from the three tables A, B and C showing the behaviors of the two
algorithms when the size of the edges E is increased; where X-axis represents the sizes of the arrays
(E) and the Y-axis represents the running time of the algorithm (T).
3. Interpret and analyze your results; compare and explain the behavior of the two algorithms.
4. Check whether the theoretical and practical analysis are correlated.