Document "rename" and "renamename" for clav-cli
[clav.git] / clav-cli.1
blob17d683e4eae8fd9a512029c7958099db1eb6c7e8
1 .Dd 2016-12-31
2 .Dt CLAV-CLI 1
3 .Os
4 .Sh NAME
5 .Nm clav-cli
6 .Nd Visualize quivers on console
7 .Sh SYNOPSIS
8 .Nm
9 .Sh DESCRIPTION
10 .Nm
11 is a text-based program to interact with quivers.  It is intended to be
12 used in situations where
13 .Xr clav-sdl
14 is unusable, and where by-hand computation is inconvenient.
15 .Sh INFORMATION
16 When
17 .Nm
18 starts, it shows a sample quiver, which does not have many interesting
19 properties.
20 .Pp
21 Vertices are displayed in a vertical list.  The left-hand column displays
22 the index of the vertex, the right displays the name.
23 .Nm
24 interacts with vertices by index for compactness' sake.
25 .Pp
26 Edges are displayed by weight in a matrix.  The entry of row i, column
27 j is edge weight ε_{ij} of the quiver
28 .Pq a blank entry represents 0 .
29 .Sh CONTROL
30 The quiver is controlled by primitive text commands. No tab
31 completion/history is implemented. Help is available by typing
32 .Sq help .
33 .Pp
34 The following commands are available.
35 .Bl -tag -width Ds
36 .It help
37 Print a help message.
38 .It print
39 Display the quiver, as described in
40 .Sx INFORMATION.
41 .It mutate Ar idx
42 Mutate the quiver at the vertex with index
43 .Ar idx .
44 .It mutatename Ar str
45 Mutate the quiver at the vertex with name
46 .Ar str .
47 .It delete Ar idx
48 Delete the vertex with index
49 .Ar idx .
50 .It delete Ar idx-one idx-two
51 Delete edges between vertices with indices
52 .Ar idx-one
53 and
54 .Ar idx-two .
55 The order of the two parameters is unimportant.
56 .It vertex
57 Create a new vertex, called
58 .Sq v .
59 .It edge Ar i Ar j Ar p / Ar q
60 Add an edge from
61 .Ar i
62 to 
63 .Ar j .
64 The weights of both directions of the edge will be modifed by the
65 following formula
66 .Po where
67 .Ar i
68 is 
69 .Ar idx-one
70 and
71 .Ar j
73 .Ar idx-two
74 .Pc :
75 .Dl ε_{ij} := ε_{ij} + (p · F_j) / (q · GCD(F_i, F_j))
76 .Dl ε_{ji} := ε_{ij} - (p · F_i) / (q · GCD(F_i, F_j))
77 where
78 .Ar F_i
79 and 
80 .Ar F_j
81 are the fatnesses of the vertices with indices
82 .Ar i
83 and 
84 .Ar j
85 respectively.
86 .Pp
87 Omitting
88 .Ar q
89 is permitted; it implies using
90 .Sq 1
91 for
92 .Ar q .
93 .It rename Ar idx Ar str
94 Changes the name of the vertex numbered
95 .Ar idx
96 .Po which is shown by
97 .Sq help
98 .Pc
99 to be
100 .Ar str .
101 .It renamename Ar str1 Ar str2
103 .Sq rename ,
104 but the vertex is selected by current name. If the name is ambiguous,
105 this command will fail.
106 .It incfat Ar idx
107 Increment the fatness of the vertex at index
108 .Ar idx
109 by one.
110 .It decfat Ar idx
111 Decrement the fatness of the vertex at index
112 .Ar idx
113 by one.
114 .It save Ar path
115 Save the current quiver to
116 .Ar path .
117 The file will be readable by
118 .Nm clav-sdl .
119 .It load Ar path
120 Load the quiver from
121 .Ar path
122 .Pq discarding the current quiver .
123 The file may have been written by
124 .Nm clav-sdl .
126 .Sh EXAMPLES
127 Example quivers may have been installed along with this program,
128 typically in
129 .Pa /usr/share/clav/ .
130 .Sh SEE ALSO
131 .Xr clav 1
132 .Xr clav-cli 1
133 .Sh BUGS
134 Edge weights are, for performance reasons
135 .Po see
136 .Xr clav-mutation-find 1
137 .Pc , stored as fractions with
138 numerator and denominator in system-dependent ranges.  While it probably
139 will not be an issue for
140 .Sq interesting
141 usage, causing edge weights to increase arbitrarily will eventually cause
143 to compute an unrepresentable edge weight.  In this situation,
145 will terminate with a diagnostic message rather than display incorrect
146 results.
148 Files saved by
150 are readable by
151 .Nm clav-sdl ,
152 but because
154 is not graphical, there will be no good x/y information associated with
155 any vertices created by 
156 .Nm .
157 This will probably be confusing until the quiver is rarranged by a user.
158 .Sh AUTHORS
159 .An S. Gilles Aq Mt sgilles@math.umd.edu