1
.TH TWOPI 1 "21 July 2001"
3
twopi \- preprocessor for circular layouts of graphs
5
\fBtwopi\fR [\fB\-G\fIname=value\fR]
6
[\fB\-N\fIname=value\fR]
10
[\fB\-o \fIoutfile\fR]
15
draws graphs using a circular layout (see G. Wills,
16
Symposium on Graph Drawing GD'97, September, 1997).
17
Basically, one node is chosen as the center and put at the origin.
18
The remaining nodes are placed on a sequence of concentric circles
19
centered about the origin, each a fixed radial distance from the
21
All nodes distance 1 from the center are placed on the first circle;
22
all nodes distance 1 from a node on the first circle are placed on
23
the second circle; and so forth.
25
Input files must be formatted in the
27
attributed graph language.
28
By default, the output of
30
is the input graph with layout coordinates appended.
31
To make PostScript, use the \fB\-Tps\fP option.
32
FrameMaker MIF (\fB-Tmif\fP), HPGL (\fB-Thpgl\fP),
33
JPEG (\fB-Tjpeg\fP), SVG (\fB-Tsvg\fP),
34
and GIF (\fB-Tgif\fP) are other choices.
36
Here is a brief synopsis of the graph language.
38
\fBgraph \fIname\fP { \fIstatement-list\fP }\fR is the top level graph.
41
\fIname\fB=\fIval\fB;\fR
43
\fBnode [\fIname\fB=\fIval\fB];\fR
45
\fBedge [\fIname\fB=\fIval\fB];\fR
46
Set the default graph, node, or edge attribute \fIname\fP to \fIval\fP.
47
Any subgraph, node, or edge specified after one of these statements
48
inherits these attributes.
50
\fBn0 [\fIname0=val0,name1=val1,...\fB];\fR
51
Creates node \fBn0\fP if it does not exist,
52
and sets its attributes according to the optional list.
54
\fBn0 \-\- n1 \-\- \fI...\fB \-\- nn [\fIname0=val0,name1=val1,...\fB];\fR
55
Creates edges between nodes \fBn0\fP, \fBn1\fP, ..., \fBnn\fP and optionally
56
sets the given attributes. Creates nodes as necessary.
58
\fBsubgraph \fIname\fB { \fIstatement-list \fB}\fR
59
Creates a subgraph. A subgraph may appear in place of
60
an individual node within an edge statement.
61
The \fBsubgraph \fIname\fR part is optional. If missing,
62
the subgraph is given an internal name.
64
While attribute names and values may be arbitrary strings,
65
certain fixed attributes control \fItwopi\fP's layout algorithm,
67
.SH "GRAPH ATTRIBUTES"
68
Refer to \fIdot\fP(1) options to control the layout size.
69
In addition, \fItwopi\fP recognizes the following:
71
\fBcenter=\fIctr\fR. This specifies the node to be used as the center of
72
the layout. If not specified, \fItwopi\fP will randomly pick one of the
73
nodes that are furthest from a leaf node, where a leaf node is a node
74
of degree 1. If no leaf nodes exists, an arbitrary node is picked as center.
76
\fBranksep=\fIval\fR. Specifies the radial distance in inches between
77
the sequence of rings. The default is 0.75.
79
\fBoverlap=\fImode\fR. This specifies what \fItwopi\fP should do if
80
any nodes overlap. If mode is \fI"false"\fP, the program uses Voronoi
81
diagrams to adjust the nodes to eliminate overlaps. If mode is \fI"scale"\fP,
82
the layout is uniformly scaled up, preserving node sizes, until nodes no
83
longer overlap. The latter technique removes overlaps while preserving
84
symmetry and structure, while the former removes overlaps more compactly
85
but destroys symmetries.
86
If mode is \fI"true"\fP (the default), no repositioning is done.
88
\fBsplines=\fItrue/false\fR. If set to true, \fItwopi\fP will use the
89
graphviz path planning library to draw edges as splines avoiding nodes.
90
If the value is false, or some nodes overlap,
91
edges are drawn as straight line segments connecting nodes.
92
This is also the default style.
94
Refer to \fIdot\fP(1) for options to control node labels, shapes,
95
sizes, colors, fonts, etc.
97
Refer to \fIdot\fP(1) for options to control edge line style and labels.
98
.SH "COMMAND LINE OPTIONS"
99
\fB\-v\fP (verbose) prints the center node and the rank separation.
100
\fB\-V\fP (version) prints version information and exits.
102
At present, the graph must be connected, with no
105
Emden R. Gansner <erg@research.att.com>