Does lowest edge weight algorithm works for non-complete graphs? (TSP)

29 Views Asked by At

I am not sure if I translated this algorithm's name but it is one of ways to solve TSP.

Algorithm does these steps:

  • it sorts edges by weights,
  • it chooses the lowest weight edge such that it will not create a cycle and it will not create a vertice with 3 edges,
  • repeat,
  • in last step close the cycle

enter image description here

Many algorithms are guaranteed to work even in non-complete graphs and I am wondering what about this one?

Can anyone provide an explanation?