1GC(1)                       General Commands Manual                      GC(1)
2
3
4

NAME

6       gvgen - generate graphs
7

SYNOPSIS

9       gvgen  [  -d?   ] [ -cn ] [ -Cx,y ] [ -g[f]x,y ] [ -G[f]x,y ] [ -hn ] [
10       -kn ] [ -bx,y ] [ -pn ] [ -sn ] [ -Sn ] [ -tn ] [ -Tx,y ]  [  -wn  ]  [
11       -ooutfile ]
12

DESCRIPTION

14       gvgen  generates  a  variety  of  simple, regularly-structured abstract
15       graphs.
16

OPTIONS

18       The following options are supported:
19
20       -c n   Generate a cycle with n vertices and edges.
21
22       -C x,y Generate an x by y cylinder.  This will have  x*y  vertices  and
23              2*x*y - y edges.
24
25       -g [f]x,y
26              Generate  an  x  by  y grid.  If f is given, the grid is folded,
27              with an edge attaching each pair of  opposing  corner  vertices.
28              This  will have x*y vertices and 2*x*y - y - x edges if unfolded
29              and 2*x*y - y - x + 2 edges if folded.
30
31       -G [f]x,y
32              Generate an x by y partial grid.  If f is  given,  the  grid  is
33              folded, with an edge attaching each pair of opposing corner ver‐
34              tices.  This will have x*y vertices.
35
36       -h n   Generate a hypercube of degree n.  This will have  2^n  vertices
37              and n*2^(n-1) edges.
38
39       -k n   Generate a complete graph on n vertices with n*(n-1)/2 edges.
40
41       -b x,y Generate  a complete x by y bipartite graph.  This will have x+y
42              vertices and x*y edges.
43
44       -p n   Generate a path on n vertices.  This will have n-1 edges.
45
46       -s n   Generate a star on n vertices.  This will have n-1 edges.
47
48       -S n   Generate  a  Sierpinski  graph  of  order  n.   This  will  have
49              3*(3^(n-1) - 1)/2 vertices and 3^n edges.
50
51       -t n   Generate  a  binary tree of height n.  This will have 2^n-1 ver‐
52              tices and 2^n-2 edges.
53
54       -T x,y Generate an x by y torus.  This will have x*y vertices and 2*x*y
55              edges.
56
57       -w n   Generate a path on n vertices.  This will have n-1 edges.
58
59       -o outfile
60              If  specified, the generated graph is written into the file out‐
61              file.  Otherwise, the graph is written to standard out.
62
63       -d     Make the generated graph directed.
64
65       -?     Print usage information.
66

EXIT STATUS

68       gvgen exits with 0 on successful completion, and exits with 1 if  given
69       an  ill-formed or incorrect flag, or if the specified output file could
70       not be opened.
71

AUTHOR

73       Emden R. Gansner <erg@research.att.com>
74

SEE ALSO

76       gc(1), acyclic(1), gvpr(1), gvcolor(1), ccomps(1), sccmap(1),  tred(1),
77       libgraph(3)
78
79
80
81                                 27 March 2008                           GC(1)
Impressum