aboutsummaryrefslogtreecommitdiff
path: root/doc/nissy.1
diff options
context:
space:
mode:
Diffstat (limited to 'doc/nissy.1')
-rw-r--r--doc/nissy.1271
1 files changed, 0 insertions, 271 deletions
diff --git a/doc/nissy.1 b/doc/nissy.1
deleted file mode 100644
index 138d6ae..0000000
--- a/doc/nissy.1
+++ /dev/null
@@ -1,271 +0,0 @@
1.Dd November 2021
2.Dt NISSY 1
3.Os
4.Sh NAME
5.Nm nissy
6.Nd a Rubik's cube solver and FMC assistant
7.
8.Sh SYNOPSIS
9.Nm
10.Op Fl b
11.Nm
12.Ar command
13.Op options...
14.
15.Sh DESCRIPTION
16.Nm
17is a Rubik's Cube solver.
18It uses techniques from Herbert Kociemba's Cube Explorer and
19Tomas Rokicki's nxopt. With 4 cores at 2.5GHz and using about 3Gb
20of RAM, Nissy can find the optimal solution for a random Rubik's cube position
21in about a minute on average.
22Nissy can also solve different substeps of the Thistlethwaite's algorithm and more.
23.Pp
24When run without any argument an interactive shell is launched, otherwise
25the provided
26.Ar command
27is executed and nissy terminates. If the option
28.Fl b
29is given, every argument after it is ignored and the shell is launched without
30any prompt or welcome message. This can be used to run nissy in batch mode,
31for example writing a list of commands in a
32.Ar file
33(one per line) and running
34.Ar nissy -b < file
35.Pp
36The commands that can be run in the interactive shell are the same that can
37be run non-interactively and are provided below.
38.
39.Sh COMMANDS
40The available
41.Ar commands
42are the following:
43.
44.Bl -tag -width Ds
45.
46.It Nm cleanup Ar scramble
47Rewrites the given scramble using only the 18 base (HTM) moves and at most two
48rotations at the end. If
49Ar scramble
50uses NISS, all moves done on normal scramble are written first, followed by
51all moves done on inverse.
52.
53.It Nm commands
54List all available commands.
55.
56.It Nm freemem
57Release some large tables from memory. You can use this command in case
58you want to keep nissy open without using too much RAM.
59.
60.It Nm gen Op Fl t Ar N
61Generate all tables used by nissy. Run this to complete your installation.
62If
63.Ar N
64is specified,
65.Ar N
66CPU threads will be used (defaults to 64, use less only if you don't want
67nissy to use all of your CPU resources).
68.
69.It Nm help Op Ar command
70Display help. If no
71.Ar command
72is given, a generic help message is printed, otherwise a specific help
73relative to
74.Ar command
75is returned.
76.
77.It Nm invert Ar scramble
78Invert the given scramble.
79.
80.It Nm print Ar scramble
81Display a text-only description of the cube obtained after applying
82.Ar scramble .
83.
84.It Nm quit
85Quit nissy.
86.
87.It Nm scramble Oo Fl n Ar N Oc Oo Ar type Oc
88Print a randomly-generated (random position) scramble
89.
90If
91.Ar N
92is given, it produces
93.Ar N
94scrambles.
95.Ar type
96can be specified to be one of the following:
97.Bl -tag -width Ds
98.It Ar corners
99Scramble with solved edges (only cornes are scrambled).
100.It Ar dr
101Scramble with solved DR on U/D.
102.It Ar edges
103Scramble with solved corners (only edges are scrambled).
104.It Ar eo
105Scramble with solved EO on F/B axis.
106.It Ar fmc
107Scramble the full cube and the resulting scramble starts and ends with
108the moves R\(aq U\(aq F.
109.It Ar htr
110Scramble with HTR solved.
111.El
112.
113.It Nm solve Ar step Oo Ar options Oc Ar scramble
114Solve the given
115.Ar step
116on the given
117.Ar scramble.
118By default it finds only one (shortest) solution, without using niss, and it
119displays the number of moves at the end of the line.
120.
121The options for the
122.Ar solve
123command are the following:
124.
125.Bl -tag -width Ds
126.
127.It Fl a
128Print all solutions: some solutions are filtered out by default for some
129steps, for examples EOs that finish with F\(aq, with this options they are not.
130.
131.It Fl c
132Display only the number of solutions found, not the solutions themselves.
133.
134.It Fl m Ar min
135Only look for solution that are at least
136.Ar min
137moves long.
138.
139.It Fl M Ar MAX
140Only look for solution that are at most
141.Ar MAX
142moves long.
143.
144.It Fl n Ar N
145Try to find
146.Ar N
147solutions. By default and unless the
148.Fl M
149or
150.Fl o
151options are used, at most one solution is returned.
152If at least one of
153.Fl M
154and
155.Fl o
156is used, all the solutions found within the given bounds are returned.
157The option
158.Fl s
159overwrites these default behaviors and at most
160.Ar N
161solutions are returned, still satisfiyng the other constraints.
162.
163.It Fl N
164Allow use of NISS.
165.
166.It Fl o
167Only find solutions that require the minimum number of moves.
168.
169.It Fl O Ar N
170Only find solutions that require at most
171.Ar N
172moves more than the optimal solution. If
173.Ar N
174is 0, this is equivalent to
175.Fl o
176.
177.It Fl p
178Plain style: do not print the number of moves.
179.
180.It Fl t Ar N
181Use
182.Ar N
183CPU threads. By default nissy uses only 1 thread. Using more than one
184thread will improve performance, but the optimal number depends on your
185machine and operating system. Generally, using one less than the number
186of threads of your CPU works quite well.
187.
188.It Fl v
189Verbose mode: print some information during the search and print each solution
190as it is found instead of only printing them all together at the end.
191.
192.
193.El
194.
195.It Nm steps
196List all available
197.Ar steps
198for the
199.Ar solve
200command.
201.
202.It Nm twophase Ar scramble
203Find a solution using a two-phase method. This does not guarantee
204to return an optimal solution (and in fact most often it does not),
205but it is very fast.
206.
207.It Nm unniss Ar scramble
208Rewrite the scramble without using NISS.
209.
210.It Nm version
211Display version information.
212.
213.El
214.
215.Sh SCRAMBLES
216All the commands above that accept a scramble also accept a
217.Fl Nm i
218option with no arguments.
219If this option is given, multiple scrambles are read from standard
220input (one per line) until and EOF is found, at which point stdin is cleared.
221.
222.Sh ENVIRONMENT
223Data is stored in the folder pointed to by
224.Nm $NISSYDATA.
225If that variable is unset the folder
226.Nm $XDG_DATA_HOME/nissy
227or
228.Nm $HOME/.nissy
229is used instead. If none of this environment variables is defined
230(e.g. in a non-UNIX system), the current folder is used.
231.
232.Sh EXAMPLES
233.Pp
234The command:
235.Dl nissy solve -v -O 1 \(dqR\(aqU\(aqFD2L2FR2U2R2BD2LB2D\(aqB2L\(aqR\(aqBD2BU2LU2R\(aqU\(aqF\(dq
236Returns:
237.Dl Searching depth 0
238.Dl Searching depth 1
239.Dl (some more lines)
240.Dl Searching depth 16
241.Dl D2 F\(aq U2 D2 F\(aq L2 D R2 D F B2 R\(aq L2 F\(aq U\(aq D
242.Dl Searching depth 17
243.Dl D2 F\(aq U2 D2 F\(aq L2 D R2 D F B2 R\(aq L2 F\(aq U\(aq D (16)
244Notice that the solution is printed twice: the first time it is printed as soon
245as it is found as requested by the -v option.
246.Pp
247The command:
248.Dl nissy solve eofb -m 4 -M 5 -N -n 6 \(dqR\(aqU\(aqFD2L2 FR2 U2R2BD2 L B2 D\(aq B2 L\(aq R\(aq\(dq
249Returns:
250.Dl U B U\(aq B (4)
251.Dl U (B R\(aq B) (4)
252.Dl (U B R\(aq B) (4)
253.Dl U2 F R2 F (4)
254.Dl U2 B U2 B (4)
255.Dl (U2 B R\(aq B) (4)
256.Pp
257On a UNIX shell, the composite command
258.Dl nissy scramble -n 2 | nissy solve -i > file.txt
259Generates two random scrambles, solves them and saves the result to file.txt.
260The file will look something like this:
261.Dl >>> Line: D U2 F D B\(aq F L2 D\(aq F2 R2 L B2 L\(aq U2 B2 R F2 L\(aq D2
262.Dl U2 R2 F2 L B2 D\(aq R2 D\(aq F U L2 B\(aq U\(aq R2 D2 R2 U (17)
263.Dl >>> Line: D B R U\(aq B\(aq L2 U L U D2 R L B2 U2 L2 U2 R U2 B2 L F2
264.Dl D\(aq F R\(aq D B L2 B R2 L U L U2 B D\(aq U R U F2 (18)
265.
266.Sh AUTHORS
267.An Sebastiano Tronto Aq Mt sebastiano@tronto.net
268.
269.Sh SOURCE CODE
270Source code is available at
271.Lk https://nissy.tronto.net

Generated with cgit - Back to sebastiano.tronto.net