1MM2GV(1) General Commands Manual MM2GV(1)
2
3
4
5delim $$
6
8 mm2gv - Matrix Market-DOT converters
9
11 mm2gv [ -cluv? ] [ -Ui ] [ -ooutfile ] [ file ]
12
14 mm2gv converts a sparse matrix of the Matrix Market format to a graph
15 in the GV (formerly DOT) format. If the matrix M is not square, the
16 graph is considered bipartite and the matrix is viewed as a bipartite
17 graph adjacency matrix, with the rows and columns of the matrix speci‐
18 fying the two sets of vertices. Equivalently, the matrix is converted
19 into a symmetric square matrix
20
21 0 M
22 $M sup T$ 0
23 a block matrix with square blocks of 0's in the upper left and lower
24 right, the upper right block being M and the lower left block being the
25 transpose of M. This matrix is then viewed as the adjacency matrix of
26 the graph.
27
28 For a square matrix, mm2gv uses it directly as an adjacency matrix if
29 its pattern of non-zero entries is symmetric; otherwise, it will treat
30 it as a bipartite graph as with the case of non-square matrices. This
31 behavior can be modified by the -U flag.
32
34 The following options are supported:
35
36 -c This flag causes mm2gv to assign colors to the edges. The matrix
37 element is scaled to the range [0,1] depending on where it lies
38 between the minimum and maximum set matrix values. This scaled
39 value is used as the "wt" attribute of the corresponding edge.
40 In addition, this scalar value is mapped to an RGB value, which
41 is stored as the edge "color".
42
43 -l If set, mm2gv attaches a label to the graph indicating the base
44 name of the input file, and the number of nodes and edges.
45
46 -u If specified, the graph is assumed to be undirected. By default,
47 the graph generated is directed.
48
49 -v This flag causes mm2gv to store the matrix values as the "len"
50 attribute of the corresponding edge.
51
52 -Ubflag
53 Specifies how square matrices are handled. If bflag is 0, a
54 square matrix will always be treated as an adjacency matrix. If
55 bflag is 1 (the default), a square matrix with a symmetric pat‐
56 tern of non-zero entries will be used as an adjacency matrix;
57 otherwise, it will be used a bipartite graph. If bflag is 2, a
58 symmetric matrix will be used as an adjacency matrix; otherwise,
59 it will be used a bipartite graph. If bflag is 3, any input
60 matrix will be treated like a bipartite graph.
61
62 -ooutfile
63 Prints output to the file outfile. If not given, mm2gv uses std‐
64 out.
65
66
67 OPERANDS
68 The following operand is supported:
69
70 file Name of the file in MatrixMarket format. If no file operand is
71 specified, the standard input will be used.
72
74 Return 0 if there were no problems during conversion; and non-zero if
75 any error occurred.
76
78 Yifan Hu <yifanhu@yahoo.com>
79 Emden R. Gansner <erg@graphviz.com>
80
82 See http://math.nist.gov/MatrixMarket/ for description of the format
83 and http://www.cise.ufl.edu/research/sparse/matrices/ for a large col‐
84 lection of sparse matrices in this format.
85
86
87
88 31 July 2008 MM2GV(1)