I'm trying to think about an algorithm for this problem. I know there is an algorithm for the second cheapest MST in a graph, but if I understood it correctly it only solves cases in which every weight is singular. My question is how do I get the n'th (say 3rd) MST where duplicate weights count as same tree.
I thought about first applying prim's algorithm to get the MST, then given that such edge exists take the smallest out of the edges in G that are not in MST1, and then, because we create a circle, remove the maximum edge that is in the circle but still smaller than the edge we added. I believe it will take linear time. Am I on the right direction?