Class UndirectedGraphAlgorithms<V>

java.lang.Object
com.github.yellowstonegames.path.Algorithms<V>
com.github.yellowstonegames.path.UndirectedGraphAlgorithms<V>
Type Parameters:
V - the vertex type; often Coord

public class UndirectedGraphAlgorithms<V> extends Algorithms<V>
Algorithms specific to undirected graphs, like DefaultGraph, as well as general Algorithms. Currently, this only adds a findMinimumWeightSpanningTree() method.
  • Method Details

    • findMinimumWeightSpanningTree

      public Graph<V> findMinimumWeightSpanningTree()
      Find a minimum weight spanning tree using Kruskal's algorithm.
      Returns:
      a Graph object containing a minimum weight spanning tree (if this graph is connected - in general a minimum weight spanning forest)