Debian Codegraph @

cmd/tools/mm2gv.1

raw
1 .EQ
2 delim $$
3 .EN
4 .TH MM2GV 1 "31 July 2008"
5 .SH NAME
6 mm2gv \- Matrix Market-DOT converters
7 .SH SYNOPSIS
8 .B mm2gv
9 [
10 .B \-cluv?
11 ]
12 [
13 .BI \-U i
14 ]
15 [
16 .BI \-o outfile
17 ]
18 [
19 .I file
20 ]
21 .br
22 .SH DESCRIPTION
23 .B mm2gv
24 converts a sparse matrix of the Matrix Market format to a graph in the GV (formerly DOT) format.
25 If the matrix \fIM\fP is not square, the graph is considered bipartite and the matrix is viewed
26 as a bipartite graph adjacency matrix, with the rows and columns of the matrix specifying the
27 two sets of vertices. Equivalently, the matrix is converted into a symmetric square matrix
28 .TS
29 c c.
30 0 \fIM\fP
31 $\fIM\fP sup \fIT\fP$ 0
32 .TE
33 a block matrix with square blocks of 0's in the upper left and lower right, the upper right
34 block being \fIM\fP and the lower left block being the transpose of \fIM\fP.
35 This matrix is then viewed as the adjacency matrix of the graph.
36 .P
37 For a square matrix, \fBmm2gv\fP uses it directly as an adjacency matrix if its pattern of non-zero
38 entries is symmetric; otherwise, it will treat it as a bipartite graph as with the case of non-square
39 matrices. This behavior can be modified by the \fB\-U\fP flag.
40 .SH OPTIONS
41 The following options are supported:
42 .TP
43 .B \-c
44 This flag causes \fBmm2gv\fP to assign colors to the edges. The matrix element is scaled to the
45 range [0,1] depending on where it lies between the minimum and maximum set matrix values. This
46 scaled value is used as the \fI"wt"\fP attribute of the corresponding edge.
47 In addition, this scalar value is mapped to an RGB value, which is stored as the edge \fI"color"\fP.
48 .TP
49 .B \-l
50 If set, \fBmm2gv\fP attaches a label to the graph indicating the base name of the input file,
51 and the number of nodes and edges.
52 .TP
53 .B \-u
54 If specified, the graph is assumed to be undirected. By default, the graph generated is directed.
55 .TP
56 .B \-v
57 This flag causes \fBmm2gv\fP to store the matrix values as the \fI"len"\fP attribute of the
58 corresponding edge.
59 .TP
60 .BI \-U "bflag"
61 Specifies how square matrices are handled. If \fIbflag\fP is 0, a square matrix will always be treated
62 as an adjacency matrix.
63 If \fIbflag\fP is 1 (the default), a square matrix with a symmetric pattern
64 of non-zero entries will be used as an adjacency matrix; otherwise, it will be used a bipartite graph.
65 If \fIbflag\fP is 2, a symmetric matrix
66 will be used as an adjacency matrix; otherwise, it will be used a bipartite graph.
67 If \fIbflag\fP is 3, any input matrix will be treated like a bipartite graph.
68 .TP
69 .BI \-o "outfile"
70 Prints output to the file \fIoutfile\fP. If not given, \fBmm2gv\fP
71 uses stdout.
72 .TP
73 .SH OPERANDS
74 The following operand is supported:
75 .TP 8
76 .I file
77 Name of the file in MatrixMarket format.
78 If no
79 .I file
80 operand is specified,
81 the standard input will be used.
82 .SH RETURN CODES
83 Return \fB0\fP
84 if there were no problems during conversion;
85 and non-zero if any error occurred.
86 .SH AUTHORS
87 Yifan Hu <[email protected]>
88 .br
89 Emden R. Gansner <[email protected]>
90 .SH ADDITIONAL INFO
91 See http://math.nist.gov/MatrixMarket/ for description of the format and http://www.cise.ufl.edu/research/sparse/matrices/ for a large collection of sparse matrices in this format.