/kruskal-visualization

Kruskal MST implementation and visualization for Information Networks class.

Primary LanguageJava

Build

You need to download GraphStream-core library and add it to your build path

Usage

The main class is Main.java. If you pass an argument, then the graph definition file will be read from that file, otherwise it will be read from stdin.

Graph definition file

Number of nodes

List of edges (node1, node2, weight)

Example run

java -jar kruskal.jar graph-example.txt

This will read graph stored in .txt file and run the program.

Screenshots

Starting window

Starting window

Found MST

MST