Definition (Prim’s Algorithm) This algorithm generates the MST for any Graph G. Pick some vertex v. Let T be our MST. While T does not connect, in Graph G, find the lightest edge that connects v to the new vertex and add it to G.