Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

README.md

Union Find

What kind of problems are commonly solved via union find:

  • Kruskal’s Algorithm (minimum spanning tree algorithm) useful in landing cables, tour operations and TV network
  • Computing the shorelines of a terrain
  • Classifying a set of atoms into molecules or fragments
  • Connected component labeling in image analysis
  • Generating a maze
  • Grid perlocation
  • Least common ancestor in trees
  • Alias analysis in compiler theory
  • Maintaining the connected components of an undirected-graph, when the adges are being added dynamically
  • Board games such as Carcasonne

Java Union Find Algorithm

  • No default implementation in JDK
  • Find here example of Union Find without path compression
  • Find here example of Union Find with path compression