# FreeBSD Manual Pages

GVGEN(1) General Commands Manual GVGEN(1)NAMEgvgen - generate graphsSYNOPSISgvgen[-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] [-Sn,d] [-tn] [-td,n] [-Tx,y] [-Tx,y,u,v] [-wn] [-nprefix] [-Nname] [-ooutfile]DESCRIPTIONgvgengenerates a variety of simple, regularly-structured abstract graphs.OPTIONSThe 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 ver- tices. 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.-Sn,dGenerate ad-dimensional Sierpinski graph of ordern. At present,dmust be 2 or 3. For d equal to 3, there will be4*(4^(n-1)+1)/2vertices and6*4^(n-1)edges.-tnGenerate a binary tree of heightn. This will have2^n-1ver- tices 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 avail- able if the-Rflag is used.-nprefixNormally, integers are used as node names. Ifprefixis speci- fied, 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 fileout-file.Otherwise, the graph is written to standard out.-dMake the generated graph directed.-vVerbose output.-?Print usage information.EXIT STATUSgvgenexits 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.AUTHOREmden R. Gansner <erg@research.att.com>SEE ALSOgc(1), acyclic(1), gvpr(1), gvcolor(1), ccomps(1), sccmap(1), tred(1), libgraph(3) 5 June 2012 GVGEN(1)

NAME | SYNOPSIS | DESCRIPTION | OPTIONS | EXIT STATUS | AUTHOR | SEE ALSO

Want to link to this manual page? Use this URL:

<https://www.freebsd.org/cgi/man.cgi?query=gvgen&manpath=FreeBSD+12.1-RELEASE+and+Ports>