Provided by: graphviz_2.36.0-0ubuntu3_amd64

**NAME**

gvgen - generate graphs

**SYNOPSIS**

gvgen[-dv?] [-in] [-cn] [-Cx,y] [-g[f]x,y] [-G[f]x,y] [-hn] [-kn] [-bx,y] [-Bx,y] [-mn] [-Mx,y] [-pn] [-rx,y] [-Rx] [-sn] [-Sn] [-tn] [-td,n] [-Tx,y] [-Tx,y,u,v] [-wn] [-nprefix] [-Nname] [-ooutfile]

**DESCRIPTION**

gvgengenerates a variety of simple, regularly-structured abstract graphs.

**OPTIONS**

The following options are supported:-cnGenerate a cycle withnvertices and edges.-Cx,yGenerate anxbyycylinder. This will havex*yvertices and2*x*y-yedges.-g[f]x,yGenerate anxbyygrid. Iffis given, the grid is folded, with an edge attaching each pair of opposing corner vertices. This will havex*yvertices and2*x*y-y-xedges if unfolded and2*x*y-y-x+2edges if folded.-G[f]x,yGenerate anxbyypartial grid. Iffis given, the grid is folded, with an edge attaching each pair of opposing corner vertices. This will havex*yvertices.-hnGenerate a hypercube of degreen. This will have2^nvertices andn*2^(n-1)edges.-knGenerate a complete graph onnvertices withn*(n-1)/2edges.-bx,yGenerate a completexbyybipartite graph. This will havex+yvertices andx*yedges.-Bx,yGenerate anxbyyball, i.e., anxbyycylinder with two "cap" nodes closing the ends. This will havex*y+2vertices and2*x*y+yedges.-mnGenerate a triangular mesh withnvertices on a side. This will have(n+1)*n/2vertices and3*(n-1)*n/2edges.-Mx,yGenerate an x by y Moebius strip. This will havex*yvertices and2*x*y-yedges.-pnGenerate a path onnvertices. This will haven-1edges.-rx,yGenerate a random graph. The number of vertices will be the largest value of the form2^n-1less than or equal tox. Larger values ofyincrease the density of the graph.-RxGenerate a random rooted tree onxvertices.-snGenerate a star onnvertices. This will haven-1edges.-SnGenerate a Sierpinski graph of ordern. This will have3*(3^(n-1)-1)/2vertices and3^nedges.-tnGenerate a binary tree of heightn. This will have2^n-1vertices and2^n-2edges.-th,nGenerate a n-ary tree of heighth.-Tx,y-Tx,y,u,vGenerate anxbyytorus. This will havex*yvertices and2*x*yedges. Ifuandvare given, they specify twists of that amount in the horizontal and vertical directions, respectively.-wnGenerate a path onnvertices. This will haven-1edges.-inGeneratengraphs of the requested type. At present, only available if the-Rflag is used.-nprefixNormally, integers are used as node names. Ifprefixis specified, this will be prepended to the integer to create the name.-NnameUsenameas the name of the graph. By default, the graph is anonymous.-ooutfileIf specified, the generated graph is written into the fileoutfile.Otherwise, the graph is written to standard out.-dMake the generated graph directed.-vVerbose output.-?Print usage information.

**EXIT** **STATUS**

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

**AUTHOR**

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

**SEE** **ALSO**

gc(1), acyclic(1), gvpr(1), gvcolor(1), ccomps(1), sccmap(1), tred(1), libgraph(3) 5 June 2012 GVGEN(1)