| 
The purpose of the gridsynth program is to approximate a
z-rotation     up to
arbitrary ϵ. It takes one argument, which is the angle
θ. The angle can be specified symbolically, for example "pi/128";
the program will then automatically calculate π/128 to the
required number of digits. To distinguish negative numbers from
command line options, negative angles should be entered parenthesized
and in quotes, for example, "(-0.1)". Typical usage is like this:
     $ gridsynth pi/128
     SHTHTHTHTHTHTHTSHTHTHTHTSHTHTHTHTHTSHTSHTHTHTHTHTSHTHTHTSHTSHTHTSHTSHTSHTHTHTHTS
     HTHTHTHTHTSHTSHTHTSHTHTSHTSHTSHTSHTHTSHTSHTSHTSHTHTHTSHTSHTSHTHTHTHTSHTHTSHTHTHT
     SHTHTHTHTSHTHTSHTHTSHTSHTSHTHTHTHTHTHTHTSHTHTSHTHTHTSHTSHTHTHTSHTSHTSHTHTSHTHTHT
     HTSHTSHTSHSSSWWWWWWW
Here, "T", "S", "H", and "X" denote the usual quantum gates of the
same names, and "W" denotes the scalar ω =
eiπ/4. Operators are shown in
matrix order, not circuit order. This means they are meant to be
applied from right to left.
The default value for the precision is 10 decimal digits,
i.e., ϵ = 10-10. The precision ϵ
can also be specified by command line options:
-d for decimal digits, -b for binary digits,
or -e to specify ϵ directly. For example, to compute
a pi/1024 rotation up to ϵ = 10-100:
 
     $ gridsynth pi/1024 -d 100
You can see the output here.
Here is the full list of command line options:
 
Usage: gridsynth [OPTION...] 
Arguments:
 theta                     z-rotation angle. May be symbolic, e.g. pi/128
Options:
  -h        --help          print usage info and exit
  -d n      --digits=n      set precision in decimal digits (default: 10)
  -b n      --bits=n        set precision in bits
  -e n      --epsilon=n     set precision as epsilon (default: 1e-10)
  -p        --phase         decompose up to a global phase (default: no)
  -f "n"    --effort="n"    how hard to try to factor (default: 25)
  -x        --hex           output hexadecimal coding (default: ASCII)
  -s        --stats         output statistics
  -l        --latex         use LaTeX output format
  -t        --table         generate the table of results for the article
  -c n      --count=n       repeat count for --table mode (default: 50)
  -r "s"    --rseed="s"     set optional random seed (default: random)
 
 |