\documentclass[12pt,a4paper]{article}

\usepackage{geometry}
\usepackage{hyperref}
\usepackage[T1]{fontenc}
\usepackage{mathptmx}
\usepackage{graphicx}

\setlength{\parskip}{0.5\baselineskip}
\setlength{\parindent}{0pt}

\title{TOPCOM User Manual\\ \normalsize version 1.2.0}
\author{J\"org Rambau\\Universt\"at Bayreuth, Germany}



\begin{document}
\maketitle

\begin{verbatim}
\end{verbatim}

\section{Introductory Remark}
\label{sec:remark}

The new version 1.2.0 now supports checkpointing for enumerations of
triangulations, circuits, and cocircuits.

Versions starting at 1.1.0 use vastly improved enumeration methods for
\begin{itemize}
\item enumeration of all triangulations,
\item enumeration of circuits from points,
\item enumeration of cocircuits from points.
\end{itemize}
Moreover, lock-free multithreading is used on demand for enumeration
and/or symmetry processing.

For really large problem instances (co-dimension above 13), the
exploration-by-flipping of the regular component of the flip-graph in
TOPCOM's \texttt{points2(n)triangs} takes a lot of memory. The
exploration of the (in general smaller) subregular component of the
flip graph can be done with less memory consumption by using MPTOPCOM
by Jordan, Joswig, and Kastner
(\url{https://polymake.org/doku.php/mptopcom}).  The enumeration of
\emph{all} triangulations, however, can be done with similar memory
consumption much faster now than before by the TOPCOM client
\texttt{points2(n)alltriangs}.  This client, for the time being, is
the fastest method in TOPCOM to enumerate all triangulations of point
configurations.


\section{What is TOPCOM?}
\label{sec:whatis}

TOPCOM is a collection of clients to compute \emph{Triangulations Of Point
Configurations and Oriented Matroids}, resp.

The algorithms use only combinatorial data of the point configuration as is
given by its oriented matroid.  Some basic commands for computing and
manipulating oriented matroids can also be accessed by the user.


\section{How do I use TOPCOM?}
\label{sec:howto}

All programs read the input from \texttt{stdin} and write the result
to \texttt{stdout} so that you can pipe the results to the next
command.  Up to four units of data input are read: a point
configuration; the symmetries of the configuration; the symmetries
required for triangulations; a seed triangulation, where, e.g., the
flip-graph exploration starts.

A point configuration is given by a matrix (enclosed in square
brackets) whose columns (enclosed in square brackets) are the
homogeneous coordinates (seperated by commas) of the points in the
configuration.  A square could be specified as follows.

\begin{verbatim}
    [[0,0,1],[0,1,1],[1,0,1],[1,1,1]]
\end{verbatim}

The symmetries of a configuration with $n$ elements are given by a
list of permutations, where a permutation is given as a list of the
images of 0, $0, 1, \ldots, n - 1$.  Each permutation must represent a
combinatorial symmetry of the configuration.  That is: it must map
signed cocircuits to signed cocircuits.  The symmetry generators of
the square read as follows (observe that the count starts at 0):

\begin{verbatim}
    [[3,2,1,0],[2,3,0,1],[0,2,1,3]]
\end{verbatim}

The required symmetries for the resulting triangulations are given in
the same way.  They are only observed if the command-line option
\texttt{-}\texttt{-triangsymmetries} is used. To generate only
triangulations of the square symmetric w.r.t.{} the diagonal of the
first quadrant, add the following line:

\begin{verbatim}
    [[3,1,2,0]]
\end{verbatim}

A seed triangulation can be given by a set of sets of numbers, where
elements of a set are enclosed in curly brackets and separated by
commas.  For example, for the square:

\begin{verbatim}
    {{0,1,2},{1,2,3}}
\end{verbatim}

A given seed is only observed if the command-line option
\texttt{-}\texttt{-triangseed} is used. (This is new compared to
versions of TOPCOM earlier than 1.2.0.)  If you want to prescribe a
seed but no (required) symmetries, specify \verb|[]| for the
(required) symmetries.

Before, inbetween, and after the data units comments may be added:
Whenever the hash symbol ``$\#$'' is detected, the rest of the line is
ignored.  Note that inside the data units comments are not allowed.


\section{Commands}
\label{sec:commands}

The following commands are provided:
\begin{description}
\item[\texttt{points2prettyprint}] (New.) Displays the point and their
  symmetry generators in a more readable form.
\item[\texttt{checktriangproperties}] (New.) Checks properties
  depending on the command line options for a list of seed
  triangulations.
\item[\texttt{points2chiro}] Computes the chirotope of a point
  configuration.
\item[\texttt{chiro2dual}] Computes the dual of a chirotope.
\item[\texttt{chiro2circuits}] Computes the circuits of a chirotope.
\item[\texttt{points2circuits}] Dto.\ for point configurations
  (using a faster method).
\item[\texttt{chiro2cocircuits}] Computes the cocircuits of a chirotope.
\item[\texttt{points2cocircuits}] Dto.\ for point configurations
  (using a faster method).
\item[\texttt{cocircuits2facets}] Computes the facets of a set of cocircuits.

\item[\texttt{points2gale}] Computes a Gale transform of a point configuration.
\item[\texttt{chiro2circuits}] Computes the circuits of a point configuration.
\item[\texttt{chiro2cocircuits}] Computes the cocircuits of a point configuration.
\item[\texttt{points2facets}] Computes the facets of a point configuration.
\item[\texttt{points2vertices}] Computes the vertices of a point configuration.

\item[\texttt{points2nflips}] Computes the number of flips of a point
  configurations and the seed triangulation.
\item[\texttt{points2flips}] Computes all flips of a point configurations and the
  seed triangulation.

\item[\texttt{chiro2placingtriang}] Computes the placing triangulation of a
  chirotope given by the numbering of the elements.
\item[\texttt{points2placingtriang}] Dto.\ for point configurations.

\item[\texttt{chiro2finetriang}] Computes a full (i.e., using all points)
  triangulation by placing and pushing (obsolete; use --full instead).
\item[\texttt{points2finetriang}] Dto.\ for point configurations.

\item[\texttt{chiro2triangs}] Computes all triangulations of a chirotope that
  are connected by bistellar flips to the seed, which is a regular
  triangulation if no seed is given in the input file.
\item[\texttt{points2triangs}] Dto.\ for point configurations.

\item[\texttt{chiro2ntriangs}] Computes the number of all
  triangulations of a chirotope that are connected by bistellar flips
  to the seed, which is a regular triangulation if no seed is given in
  the input file.

\item[\texttt{points2ntriangs}] Dto.\ for point configurations.

\item[\texttt{chiro2finetriangs}] Computes all full triangulations
  (i.e., using all points) of a chirotope that are connected by
  bistellar flips to a full seed triangulation (obsolete; use --full
  instead).
\item[\texttt{points2finetriangs}] Dto.\ for point configurations.

\item[\texttt{chiro2nfinetriangs}] Computes the number of all full
  triangulations (i.e., using all points) of a chirotope that are
  connected by bistellar flips to a full seed triangulation (obsolete;
  use --full instead).
\item[\texttt{points2nfinetriangs}] Dto.\ for point configurations.

\item[\texttt{chiro2alltriangs}] Computes all triangulations of a chirotope.
\item[\texttt{points2alltriangs}] Dto.\ for point configurations.

\item[\texttt{chiro2nalltriangs}] Computes the number of all
  triangulations of a chirotope.
\item[\texttt{points2nalltriangs}] Dto.\ for point configurations.

\item[\texttt{chiro2allfinetriangs}] Computes all full triangulations
  (i.e., using all points) of a chirotope (obsolete;
  use --full instead).
\item[\texttt{points2allfinetriangs}] Dto.\ for point configurations.
  
\item[\texttt{chiro2nallfinetriangs}] Computes the number of all full
  triangulations (i.e., using all points) of a chirotope (obsolete;
  use --full instead).
\item[\texttt{points2nallfinetriangs}] Dto.\ for point configurations.

\item[\texttt{chiro2mintriang}] Computes a triangulation of a
  chirotope with a minimum number of simplices.
\item[\texttt{points2mintriang}] Dto.\ for point configurations.
  
\item[\texttt{B\_S n}] Computes the points and symmetry generators of
  the permutation polytope of the symmetric group of degree~$n$, also
  known as the Birkhoff polytope.
\item[\texttt{B\_A n}] Computes the points and symmetry generators of
  the permutation polytope of the alternating group of degree~$n$, also
  known as the even Birkhoff polytope.
\item[\texttt{B\_D n}] Computes the points and symmetry generators of
  the permutation polytope of the dihedral group of degree~$n$.
\item[\texttt{B\_S\_center n}] Computes \texttt{B\_S n} with an additional
  center point.
\item[\texttt{B\_A\_center n}] Computes \texttt{B\_A n} with an additional
  center point.
\item[\texttt{B\_D\_center n}] Computes \texttt{B\_D n} with an additional
  center point.
\item[\texttt{cube d}] Computes the points and symmetry generators of a
  $d$-cube.
\item[\texttt{cyclic n d}] Computes the points and symmetry generators of
  the cyclic $d$-polytope with $n$ vertices.
\item[\texttt{cross d}] Computes the points and symmetry generators
  of the $d$-dimensional cross-polytope.
\item[\texttt{kDn k n}] Computes the points and symmetry generators
  of the $k$-times dilated $n$-simplex with all interior lattice points.
\item[\texttt{Dnxk n k}] Computes the points and symmetry generators
  of $k$ copies of the $n$-simplex.
\item[\texttt{lattice n m}] Computes the $nm$ two-dimensional lattice
  points with non-negative coordinates at most $(n - 1, m - 1)$ and
  their symmetry generators.
\item[\texttt{hypersimplex d k $[\ell]$}] Computes the points and
  symmetry generators of the $k$-th hypersimplex in dimension~$d$.  A
  third parameter makes it the $S$-hypersimplex with coordinate sums
  equal to $k$ or~$\ell$.
\item[\texttt{santos\_triang}] Computes the point configuration, the symmetry,
  and the Santos triangulation (without flips).
\end{description}

\section{Command Line Options}
\label{sec:options}

The following command line options are supported.  Note that not all
options are sensible for all clients.

\subsection*{Options concerning input/output from files}
\begin{description}
\item[\texttt{-i [filename]}:] read input from [filename] instead of
  stdin.
\item[\texttt{-}\texttt{-nosymmetries}] Ignore the symmetries in the
  input.
\item[\texttt{-}\texttt{-triangsymmetries}] (New.) Observe the
  prescribed symmetries in the input for triangulations in the result.
\item[\texttt{-}\texttt{-triangseed}] (New.) Observe the
  prescribed seed in the input for flip-graph exploration or in the
  input for property checking.  In the latter case, more than one seed
  may be given.
\end{description}

\subsection*{Options for checking input}
\begin{description}
\item[\texttt{-}\texttt{-checktriang}] Check seed triangulation for
  correctness.
\item[\texttt{-}\texttt{-checksymmetries}] (New.) Check given
  symmetries for correctness by testing invariance on cocircuits.
\end{description}

\subsection*{Options concerning output of information}
\begin{description}
\item[\texttt{-h} or \texttt{-}\texttt{-help}] Print a usage message.

\item[\texttt{-d}] Debug.
   
\item[\texttt{-v}] Verbose.
  
\item[\texttt{-}\texttt{-reportfrequency [n]} ] In enumerations,
  report intermediate results after (at least) \texttt{[n]} discovered
  nodes.

\item[\texttt{-}\texttt{-heights}] Output a height vector for every
  regular triangulation (only in connection with
  \texttt{-}\texttt{-[find]regular}).
  
\item[\texttt{-}\texttt{-gkzvecs}] (New.) Output the GKZ-vector for every
  triangulation..

\item[\texttt{-}\texttt{-flips}] Output all flips in terms of IDs of
  adjacent triangulations.  (Can be used to generate the flip graph.)
  
\item[\texttt{-}\texttt{-flipconnectivity}] When checking for
  flip-graph connectivity, output flip-paths to regular triangulations
  in terms of sequences of flips.
  
\item[\texttt{-}\texttt{-asy}] Write asymptote graphics commands into
  file (in rank-3 triangulations, points are drawn as well).  The
  graphics contains a view of the point configuration (only in
  rank~3), the enumeration tree with a classification of enumeration
  nodes into solutions, non-canonical nodes, deadends, and early
  detected deadends, as well a statistics file showing a histogram of
  enumeration node types.  The output file has to be processed by the
  computer graphics compiler \texttt{asy}
  (\url{https://asymptote.sourceforge.io}) using the
  \texttt{asy}-library \texttt{Combinatorial\_Geometry.asy} and the
  \LaTeX-macroes in \texttt{triangbook\_macroes.sty} inside
  \texttt{share/asy/}.
\end{description}

\subsection*{Options for reporting properties of discovered/given
  triangulations:}
\begin{description}
\item[\texttt{-}\texttt{-flipdeficiency}] Check triangulations for
  flip deficiency during flip-graph exploration.
  
\item[\texttt{-}\texttt{-findregular}] (New form.) Check for
  regularity and stop if a regular one is found during flip-graph
  exploration.
\end{description}

\subsection*{Options concerning which triangulations are output (no
  influence on flip-graph exploration)}
\begin{description}
\item[\texttt{-}\texttt{-noorbitcount}] Only count symmetry classes,
  not the total number.
  
\item[\texttt{-}\texttt{-cardinality $[k]$}] Count/output only
  triangulations with exactly $k$ simplices.
  
\item[\texttt{-}\texttt{-maxcardinality $[k]$}] Count/oputput only
  triangulations with at most $k$ simplices.
  
\item[\texttt{-}\texttt{-unimodular}] (New.) Output unimodular
  triangulations only; while this does not reduce the effort of
  flip graph exploration, since unimodular triangulations are in
  general not connected by themselves, it does reduce the effort of
  extension graph exploration like in \texttt{points2nalltriangs}.
  
\item[\texttt{-}\texttt{-requirepoint $[k]$}] Count/oputput only
  triangulations with simplices containing point~$k$ (currently only
  supported by \texttt{points2(n)alltriangs}).  Note that in this
  case only symmetries stabilizing that point are considered.
  
\item[\texttt{-}\texttt{-flag}] Output flag triangulations only; while
  this does not reduce the effort of flip graph exploration, since
  flag triangulations are in general not connected by themselves, it
  does reduce the effort of extension graph exploration like in
  \texttt{points2nalltriangs}.
  
\item[\texttt{-}\texttt{-nonregular}] Output non-regular
  triangulations only; note that this does neither reduce the effort
  of flip-graph exploration, since non-regular triangulations are in
  general not connected by themselves, nor the effort of extension
  graph exploration, since non-regularity depends on the combination
  of simplices in a triangulation.

\item[\texttt{-}\texttt{-nonsubregular}] Output non-subregular
  triangulations only, i.e., those that cannot be gkz-increasingly
  flipped to a regular triangulation.

\item[\texttt{-}\texttt{-nonsupregular}] Output non-superregular
  triangulations only, i.e., those that cannot be gkz-decreasingly
  flipped to a regular triangulation.
  
\item[\texttt{-}\texttt{-nonregularcomp}] (New.) Output non-regular
  triangulations only if they are not connected to the flip-graph
  component of the regular triangulations.  (Each such triangulation
  constitutes a significant mathematical result.)

\item[\texttt{-}\texttt{-possnonregularcomp}] (New.) Output
  non-regular triangulations only if they are possibly not connected
  to the flip-graph component of the regular triangulations.  This is
  checked by lex-GKZ-monotone flipping w.r.t.\ a random permutation.
\end{description}


\subsection*{Options concerning which triangulations are explored}
\begin{description}
  
\item[\texttt{-}\texttt{-regular}] Search for regular triangulations
  only (checked liftings are w.r.t.\ the last homogeneous coordinate,
  e.g., last coordinates all ones is fine); note that this may reduce
  the effort of flip-graph exploration, since regular triangulations
  are connected by themselves.  In particular, if the optional given
  seed is non-regular, the exploration will stop immediately with no
  triangulations counted, since non-regular triangulations are not
  followed. 
    
\item[\texttt{-}\texttt{-regularearly}] Search for regular partial
  triangulations only; note that this may reduce the effort of
  extension-graph exploration, since no non-regular partial
  triangulation can be completed to a regular triangulation.

\item[\texttt{-}\texttt{-full}] Search for full triangulations (i.e.,
  using all points) only.

\item[\texttt{-}\texttt{-noinsertion}] Never flip-in a point that is
  unused in the seed triangulation.
  
\item[\texttt{-}\texttt{-reducepoints}] Try to greedily minimize the
  number of points used while flipping; keep a global upper bound on
  the current minimal number of points and do not accept
  triangulations with more points.

\item[\texttt{-}\texttt{-keepcard}] Never change the cardinality of
  triangulations by flipping.
\end{description}


\subsection*{Options concerning symmetries}
\begin{description}
  
\item[\texttt{-}\texttt{-affinesymmetries}] (New form.) Assume that
  the symmetries are affine, in particular, that they conserve
  regularity.
  
\item[\texttt{-}\texttt{-isometricsymmetries}] (New.) Assume that the
  symmetries are isometric, in particular, that they preserve volume.
  
\item[\texttt{-}\texttt{-notriangsymmetries}] (New; currently the
  default.) Ignore the prescribed symmetries for triangulations in the
  result (option supported for backwards-compatibility).
\end{description}


\subsection*{Options controlling the internals of the clients}
\begin{description}
\item[\texttt{-}\texttt{-memopt}] Save memory by using caching
  techniques.
\item[\texttt{-}\texttt{-iterativedfs}] (New.) Use an iterative version of
  the depth-first-search enumeration algorithms (avoids
  potential call-stack overflows on small machines).
  
\item[\texttt{-}\texttt{-recursivedfs}] (New.) Use a recursive version of
  the depth-first-search enumeration algorithms (default).
  
\item[\texttt{-}\texttt{-usegkz}] (New.) Use GKZ vectors as a finger
  print in symmetry handling (only for points with isometric
  symmetries).
  
\item[\texttt{-}\texttt{-usenaivesymmetries}] (New.) Use naive full
  traversal of all symmetries for symmetry handling.

\item[\texttt{-}\texttt{-usecritelmtables}] (New.) Use
  critical-element tables for symmetry handling (default for
  triangulations).
  
\item[\texttt{-}\texttt{-useswitchtables}] (New.) Use
  Jordan-Joswig-Kastner switch tables for symmetry handling (default
  for (co-)circuits).
  
\item[\texttt{-}\texttt{-usesymmetrytables}] (New.) Use tables of
  classified symmetries for symmetry handling.  Obsolete, since
  slower than the other options.
  
\item[\texttt{-}\texttt{-symtables [n]}](New.)  Use \texttt{[n]}
  symtables for preprocessing symmetries.  Obsolete, since slower than
  the other options.
  
\item[\texttt{-}\texttt{-preprocesschiro}] (New.) Preprocess the
  chirotope (default for \texttt{points2[n]alltriangs}).
  
\item[\texttt{-}\texttt{-preprocesspoints}] (New.) Heuristically
  transform points.
  
\item[\texttt{-}\texttt{-simpidxsymmetries}] (New.) Preprocess a
  representation of the symmetry group on simplex indices (only
  relevant for triangulation enumeration).
  
\item[\texttt{-}\texttt{-userandomorder}] (New.) Sort simplices in
  preprocessed index table randomly (only for points with isometric
  symmetries).
  
\item[\texttt{-}\texttt{-usevolumeorder}] (New.) Sort simplices in
  preprocessed index table by volume (only for points with isometric
  symmetries).
  
\item[\texttt{-}\texttt{-usevolumes}] (New.) Use volumes to check
  extendability of partial triangulations (only for points with
  isometric symmetries).
  
\item[\texttt{-}\texttt{-fullextensioncheck}] (New.) Put more effort
  in the check of extendability of a partial triangulation.
  
\item[\texttt{-}\texttt{-noextensioncheck}] (New.) Skip the check of
  extendability of a partial triangulation.
  
\item[\texttt{-}\texttt{-extensioncheckfirst}] (New.) Check
  extendability prior to symmetry.

\item[\texttt{-}\texttt{-chirocache $[n]$}] Set the chirotope cache to
  $n$ elements.

\item[\texttt{-}\texttt{-localcache $[n]$}] Set the cache for local
  operations.

\item[\texttt{-}\texttt{-qsoptex}] Use \texttt{QSopt\_ex} for
  regularity checks (not thread-safe).
   
\item[\texttt{-}\texttt{-soplex}] Use \texttt{soplex} for regularity
  checks (requires separate installation of \texttt{soplex}).
\end{description}

\subsection*{Options concerning multi-threading}

\begin{description}
\item[\texttt{-}\texttt{-parallelenumeration}] Use multiple threads
  for enumeration.

\item[\texttt{-}\texttt{-workbuffercontrol}] (Currently the default.)
  Control the interrupt of workers by size of the current workbuffer.

\item[\texttt{-}\texttt{-noworkbuffercontrol}] Control the interrupt of
  workers by node budgets.

\item[\texttt{-}\texttt{-parallelsymmetries}] Use multiple threads
  only locally for symmetry checks.

\item[\texttt{-}\texttt{-threads [n]}] Use \texttt{[n]} threads (if possible).

\item[\texttt{-}\texttt{-minnodebudget [n]}] Let each thread process
  at least \texttt{[n]} nodes (to avoid multi-threading overhead).

\item[\texttt{-}\texttt{-maxnodebudget [n]}] Let each thread process
  at most \texttt{[n]} nodes (to avoid thread starving).

\item[\texttt{-}\texttt{-scalenodebudget [n]}] Scale the default node
  budget by \texttt{[n]} percent (n integer)

\item[\texttt{-}\texttt{-minworkbuffer [n]}] (Currently unused.) Try
  to keep the work buffer above \texttt{[n]} nodes (to balance
  overhead and thread starving).

\item[\texttt{-}\texttt{-maxworkbuffer [n]}] (Currently unused.) Try
  to keep the work buffer below \texttt{[n]} node (to balance
  overhead and thread starving).

\end{description}


\subsection*{Options for warm starts from previous calculations}
These options currently work for the clients
\texttt{points2(n)triangs}, \texttt{chiro2(n)triangs},
\texttt{points2(n)alltriangs}, \texttt{chiro2(n)alltriangs}, and
\texttt{points2(n)(co)circuits}.
\label{sec:options-warm-starts}
\begin{description}
\item[\texttt{-}\texttt{-dump}] Write intermediate results into a
  file; a symbolic link with the basename will be placed pointing to
  the most recent actual dump file.
\item[\texttt{-}\texttt{-dumprotations $[k]$}] Dump into $k$ different
  rotating files indicated by numerical postfixes.
\item[\texttt{-}\texttt{-dumpfile $[$dumpfilename$]$}] Write
  intermediate results into files with basename \texttt{dumpfilename}
  (default: \texttt{TOPCOM.dump}); a symbolic link with the basename
  will be placed pointing to the most recent actual dump file.
\item[\texttt{-}\texttt{-dumpfrequency $[k]$}] Dump the results at
  each $k$th ``object'' (what object means, depends on the kind of
  enumeration)
\item[\texttt{-}\texttt{-read}] Read intermediate results from a file.
\item[\texttt{-}\texttt{-readfile $[$readfilename$]$}] Read
  intermediate results from file \texttt{dumpfilename} (default:
  \texttt{TOPCOM.dump}).
\end{description}


\section{Examples}
\label{sec:examples}

In the subdirectory \texttt{examples} you find some example inputs for
TOPCOM routines.

If you want to see the input in a prettier way, then you can type the
following:

\begin{verbatim}
  points2prettyprint < cube_3.dat
\end{verbatim}

It prints the matrix of point coordinates and the symmetry generators in
tabular form.

Or:

\begin{verbatim}
  points2chiro < lattice_3_3.dat
\end{verbatim}

outputs the sign string of the chirotope of the sub-lattice of integer
points $(i,j)$ with $i, j = 0, 1, 2$.

\begin{verbatim}
  points2chiro < lattice_3_3.dat | chiro2ntriangs
\end{verbatim}

or 

\begin{verbatim}
  points2ntriangs < lattice_3_3.dat
\end{verbatim}

yields the number of triangulations that are connected to the regular
ones by bistellar flips.

\begin{verbatim}
  points2ntriangs --regular --affinesymmetries < moae.dat
\end{verbatim}

counts all regular triangulations of the ``mother of all examples'',
two nested triangles in the plane.

\begin{verbatim}
  points2nalltriangs < lattice_3_3.dat
\end{verbatim}

yields the number of all triangulations via a new algorithm
\emph{symmetric lex-subset reverse-search} on partial triangulations.
It is mostly faster than flip-graph exploration and much faster than
in older versions of TOPCOM; moreover, it does not take a lot of
memory.

The example \texttt{r12.chiro} is the chirotope of the oriented
matroid $R12$ with disconnected realization space, constructed by
J\"urgen Richter-Gebert.  If you want to compute, e.g., a placing
triangulation of $R12$ then type

\begin{verbatim}
  chiro2placingtriang < r12.chiro
\end{verbatim}

The facets of a $4$-cube can be computed by

\begin{verbatim}
  cube 4 | points2facets
\end{verbatim}

but be aware of the fact that this is not an efficient way of
computing facets of a point configuration.  It is, however,
numerically stable because rational arithmetics is used.

Most notably, you can check the Santos triangulation by

\begin{verbatim}
  santos_triang | points2nflips -v --memopt --checktriang
\end{verbatim}

Recall that the options mean:

\begin{description}
\item[\texttt{-v}] verbose;
\item[\texttt{-}\texttt{-memopt}] save memory;
\item[\texttt{-}\texttt{-checktriang}] check seed triangulation.
\end{description}

A new result as of version 1.0.10 is that TOPCOM can now
enumerate \emph{all} triangulations of larger point configurations
like the $4$-cube in reasonable time.  The speed depends on the
computational environment and the options:

\begin{verbatim}
  cube 4 | points2nalltriangs -v --parallelenumeration
\end{verbatim}

uses verbose output and multi-threaded symmetry processing with
load-balancing based on work buffer control, i.e., the workers stop
and push the open nodes into the job list whenever the master's job
list contains fewer elements than there are workers.

Since not every point configuration can be represented in rational
coordinates, it is useful to enumerate triangulations from the
chirotope data.  This way you can compute, e.g., all triangulations of
the regular icosahedron:

\begin{verbatim}
  chiro2nalltriangs -i icosahedron.chiro -v 
\end{verbatim}

Note the newly supported alternative syntax \texttt{-i [filename]} for
the specification of the input file.

Enumerating all triangulations can be restricted to regular,
unimodular, flag, and symmetric triangulations.  For example, assume
the input \texttt{moae.dat} for the ``mother of all examples''
contains a permutation (rotation by 120 degrees) generating the
symmetries required for the triangulations as follows (note the use of
comments):

\begin{verbatim}
  # content of moae.dat:
  # the points:
  [[4,0,0],[0,4,0],[0,0,4],[2,1,1],[1,2,1],[1,1,2]]
  # the symmetries:
  [[1,0,2,4,3,5],[0,2,1,3,5,4]]
  # the required symmetries generated by 120-degree rotations:
  [[1,2,0,4,5,3]]
  # no seed.
\end{verbatim}

Then (with ``\'' just indicating a split line):

\begin{verbatim}
  points2alltriangs -i moae.dat --triangsymmetries \
  --regular --heights --gkzvecs
\end{verbatim}

enumerates all regular triangulations that have C3-rotational symmetry
and outputs their regularity-heights and GKZ vectors.  The result:

\begin{verbatim}
  [triangID:0,workerID:0,runID:0,inorbitID:0,triang:{{0,1,2}}, \
  has_required_syms:true,is_regular:true,is_flag:true, \
  heights:[0,0,0,1,1,1],gkzvec:[64,64,64,0,0,0]]
\end{verbatim}

Consequently, only the triangulation with one big simplex consisting
of the vertices of the configuration is counted.

\begin{verbatim}
  points2alltriangs -i moae.dat --triangsymmetries --regular
\end{verbatim}


Moreover:

\begin{verbatim}
  points2alltriangs -i moae.dat --flag -v
\end{verbatim}

shows that there are only three flag (sometimes known as
``quadratic''' or ``clique'') triangulations.

The enumeration of circuits and cocircuits up to symmetry is now a
non-trivial part of TOPCOM.  For example:

\begin{verbatim}
  cube 4 | points2ncircuits -v --parallelenumeration
\end{verbatim}

enumerates the symmetry classed of all the circuits of the 4-cube.

Moreover, the clients to explore the flip graph for points can now use
the GKZ vector as a fingerprint to detect known triangulation classes
in case all symmetries are isometric.  This is faster, but needs some
more memory for storing all the known GKZ vectors.  Moreover, a basic
multi-threaded symmetry check can be used.  You can activate all of
this by:

\begin{verbatim}
  cube 4 | points2ntriangs --parallelsymmetries \
  --usegkz --isometricsymmetries
\end{verbatim}

As an example for the graphics output the 2-by-3 lattice in dimension
two is presented.  Graphics output is supported by the enumeration of
all triangulations, circuits and cocircuits.  The files
\texttt{Combinatorial\_Geometry.asy} and
\texttt{triangbook\_macroes.sty} (to be found under \texttt{share/asy}
in the TOPCOM home directory) must be present in the working directory
where \texttt{TOPCOM\_graphics.asy} is compiled via \texttt{asy}.  For
example, if \texttt{3D2.dat} contains the input data for the 3-times
dilated 2-simplex with 120-degree rotations as required symmetries,
then

\begin{verbatim}
  points2nalltriangs -i 3D2.dat -v --parallelenumeration --asy \
  --triangsymmetries --flag --unimodular
\end{verbatim}

followed by

\begin{verbatim}
  asy TOPCOM_graphics.asy
\end{verbatim}

yields -- besides the numerical result -- three graphics files in
pdf-format.

The point configuration can be found in \texttt{TOPCOM\_points.pdf}
(see Figure~\ref{fig:points}).
\begin{figure}[htb]
  \begin{center}
    \includegraphics[width=0.2\linewidth,keepaspectratio=true]{TOPCOM_points.pdf}
  \end{center}
  \caption{The points}\label{fig:points}
\end{figure}
The enumeration tree can be found in \texttt{TOPCOM\_tree\_graph.pdf}
(see Figure~\ref{fig:tree}).
\begin{figure}[htb]
  \begin{center}
    \includegraphics[width=\linewidth,keepaspectratio=true]{TOPCOM_tree_graph.pdf}
  \end{center}
  \caption{The enumeration tree with classified nodes -- here with
    three threads and workbuffercontrol (best viewed on a screen with
    zooming abilities)}\label{fig:tree}
\end{figure}
Here, a \emph{clover icon} means a triangulation in a new symmetry
class, a \emph{recycling icon} means a node in an old symmetry class,
a \emph{stop-sign icon} means a deadend with no possible admissible
lex-larger extension, a \emph{bulb icon} means an early detected
deadend with an uncoverable interior facet, a \emph{lightning-sign
  icon} means that no further extension option can prevent an
uncoverable interior facet, and, finally, a \emph{red-traffic-light
  icon} means a node with unavoidable non-facial cliques in the edge
graph.  Statistics can be found in \texttt{TOPCOM\_statistics.pdf}
(see Figure~\ref{fig:stats}).
\begin{figure}[htb]
  \begin{center}
    \includegraphics[width=0.5\linewidth,keepaspectratio=true]{TOPCOM_statistics.pdf}
  \end{center}
  \caption{\label{fig:stats}The statistics of classified nodes}
\end{figure}


\end{document}

%%% Local Variables: 
%%% mode: latex
%%% TeX-master: t
%%% End: 
