JAVA ALGORITHM VISUALIZER
(beta version)
Short User's Guide
Installing JAZ
To install the JAZ
visualization system, you simply have to copy from the CD-ROM either
the winjaz.zip file (for Windows
operating system), the unixjaz.tar
file (for Unix), or the macjaz.sea.hqx
file (for MacOS), and, subsequently, uncompress this file.
The resulting folder contains:
file JAZ.jar, file JazPMenuBar.class, directory
Algorithms, directory Examples, directory Images,
and directory PseudoCodes. In the case of MacOS, the folder
also contains a file JAZv2.0.jb
Starting JAZ
On MacOS, simply double-click the file JAZv2.0.jb. On Windows or Unix, type
java cp JAZ.jar JazPMenuBar
within the above described directory.
Notice that you must have a Java Virtual Machine. In particular, it is suggested to have at least JDK 1.2 for Windows or Unix,
and MRJ 2.1.2 for MacOS.
Using JAZ
Once launched, the interface of JAZ consists of four menus.
VCR Menu
This menu allows the user to navigate through a visualization. The commands are similar to those of a video-recorder:
Step/ Multiple Steps/Back
Advance of one or more snapshot of the visualization either forward or backward.
Reset
Go to the first snapshot.
Go forward/Go backward
Continuously advance through the snapshots of the visualization either forward or backward.
Pause/Resume
Temporarily stop or resume the continuos show of the snapshots.
Properties
Set the speed of the show.
File Menu
This menu allows the user to load a file of visualization snapshot. You will find some examples of these files in the Chapt.x directories of the directory Examples (these files have extension .sho).
The menu also allows quitting from the visualization system.
Runner Menu
This menu allows the user to execute one of the implemented algorithms. You will find these implementations in the Chapt.x directories of the directory Algorithms. When asked for the application class, the user can currently choose the following algorithms:
Algorithms/Chapt.1/InsertionSort.class
Algorithms/Chapt.1/ShortestPath.class
Algorithms/Chapt.2/GreedyIndSet.class
Algorithms/Chapt.2/PrimalDualVC.class
Algorithms/Chapt.3/GavrilVC.class
Algorithms/Chapt.4/GreedyGC.class
(Do not select the $Visualizer classes, which are inner classes used by the algorithms.)
More algorithms will be available at the
on-line web site of the book.
Each algorithm requires specifying an input file and an output file. The input file can be either an array (in the case of the insertion sort program) or a graph (in all other cases) and can be created with the Input menu (see below). Examples of input files are contained in the Chapt.x directories of the directory Examples (these files have extension .txt). The output file can have any name, but it is suggested to use extension .sho: this output file can subsequently visualized by using the File and the VCR menu (see above).
Input Menu
This menu allows the user to define an input file. Currently, two kinds of inputs can be defined: arrays and graphs. In the case of arrays, the input interface is very simple, while in the case of graphs the interface is a user-friendly graph drawer. Both interfaces allow the user to save the input into a specified file that can be subsequently used by the Runner menu (see above).
|