/ Visualizers / Development of heapsort algorithm visualizer based on Vizi technology
(версия для печати)
Development of heapsort algorithm visualizer based on Vizi technology
© G.G. Udov, A.A. Shalyto
Saint-Petersburg State University of Information Technologies, Mechanics and Optics
Project documentation in Russian (PDF)
Visualizer (English, online)
Annotation
Visualizer is a program, that gives an easy and accessible way to study an algorithm by demonstrating its work on a test data set.
The Vizi technology was developed on the Computer technologies department of SPbSU ITMO for the purpose of automation of algorithms visualizers creation. The application of Vizi technology was demonstrated in this work by development of visualizer for heapsort algorithm.
Using Vizi technology gives us noticeable advantages in comparison with implementing visualizers manually "from zero":
- building both straight and back passes using XML-description of algorithm;
- the logics of algorithm is implemented using four automatons, for each procedure two automatons were used («straight» and «back»). The summary quantity of states is 46. Each automaton is implemented using two switch statements;
- XML description of algorithm lets automatic insertion of comments into generated code (this is not about comments, using for visualization), and features of Vizi technology, validating XML-code, make programmer to write this comments. This increases readability of code, and so makes its further support much easier;
- binding of comments and drawing actions to states is automatically implemented by additional switch statements;
- using universal technology for building visualizers standardizes development process and lets us evade duplication of code and errors resulting from this;
- standard ergonomic visualizer interface makes process of studying collections of algorithms mush easier;
- XML-description is very compact (nine pages against twenty-five pages of automatically generated code).
|