Drawing Trees Nicely with T E X
Various algorithms have been proposed for the diicult problem of producing aesthetically pleasing drawings of trees, see 15, 17] but implementations only exist as \special purpose software", designed for special environments. Therefore, many users resort to the drawing facilities available on most personal computers, but the gures obtained in this way still look \hand-drawn"; their quality is inferior to the quality of the surrounding text that can be realized by today's high quality text processing systems. In this paper we present an entirely new solution that integrates a tree drawing algorithm into one of the best text processing systems available. More precisely, we present a T E X macro package TreeT E X that produces a drawing of a tree from a purely logical description. Our approach has three advantages. First, labels for nodes can be handled in a reasonable way. On the one hand, the tree drawing algorithm can compute the widths of the labels and take them into account for the positioning of the nodes; on the other hand, all the textual parts of the document can be treated uniformly. Second, TreeT E X can be trivially ported to any site running T E X. Finally, modularity in the description of a tree and T E X's macro capabilities allow for libraries of subtrees and tree classes. In addition, we have implemented an option that produces drawings which make the structure of the trees more obvious to the human eye, even though they may not be as aesthetically pleasing. 1 Aesthetical criteria for drawing trees One of the most commonly used data structures in computer science is the tree. As many people are using trees in their research or just as illustration tools, they are usually struggling with the problem of drawing trees. We are concerned primarily with ordered trees in the