evalue.c: reorder_terms: fix typo
[barvinok.git] / README
blobb1375dcdc6ebe3b14dcf1db38bde564395b4742b
1 barvinok is a library for counting the number of integer points
2 in parametric and non-parametric polytopes as well as projections
3 of such sets.
4 For parametric polytopes the count is represented by either
5 an explicit function or a generating function.
6 The first comes in the shape of a piece-wise step-polynomial.
7 This is a generalization of both Ehrhart quasi-polynomials
8 and vector partition functions.
9 The second is a generalization of an Ehrhart series.
11 This library shares some functionality with LattE
12 (http://www.math.ucdavis.edu/~latte/)
13 and uses PolyLib (http://icps.u-strasbg.fr/polylib/ or
14 http://www.kotnet.org/~skimo/polylib/) and
15 NTL (http://shoup.net/ntl/).
17 Additionally, the following packages can optionally be used
18 - PIP (http://www.piplib.org/)
19 - Omega (http://www.cs.umd.edu/projects/omega/ or 
20     http://www.liacs.nl/~sverdool/gitweb.cgi?p=omega.git;a=summary)
21 - GLPK (http://www.gnu.org/software/glpk/)
22 - GiNaC (http://www.ginac.de/) (needed for the bernstein library)
24 Both NTL and PolyLib need to have been compiled with GMP
25 support.
26 For NTL this means you have to specify
27     NTL_GMP_LIP=on
29 Suppose you want to put everything in /opt,
30 Then you configure/compile PolyLib using
32 ./configure --with-libgmp=/path/to/gmp --prefix=/opt
33 make
34 make install
36 For NTL,
38 cd src
39 ./configure NTL_GMP_LIP=on PREFIX=/opt GMP_PREFIX=/path/to/gmp
40 make
41 make install
43 For Omega,
45 vi -c '/DESTDIR=/|s/=.*$/=\/opt/|wq' Makefile.config
46 make libomega.a libcode_gen.a
47 make install
49 For piplib,
51 ./configure --with-gmp=/path/to/gmp --prefix=/opt
52 make
53 make install
55 Configure this library using
57 ./configure --prefix=/opt --with-polylib=/opt --with-ntl=/opt
61 ./configure --prefix=/opt --with-polylib=/opt --with-ntl=/opt --disable-fractional
63 If you want shared libraries, then configure with the --enable-shared option.
64 Note that this doesn't work on some systems because we link in libntl, which
65 is only available as a static library.
66 Also note that if you have previously installed a shared library of an older
67 version of barvinok, and you do not install one for this version, then the
68 linker may pick up the old shared library rather than the new static library.
70 Then
72 make
73 make check
74 make install
76 If you want to put any one of these packages in the default location
77 (typically /usr/local), then the prefix argument can be omitted.
78 For more information on other arguments,
80 ./configure --help
82 Please use PolyLib version 5.21.0 or later.
84 The input format of barvinok_enumerate is the same as that
85 of testehrhart from the PolyLib distribution.
86 See the PolyLib manual, barvinok_enumerate.c or the
87 examples in tests/ehrhart/ .
89 Note that the fractional representation is subject to change.
91 The library supports three specialization algorithms.
92 The first performs a direct specialization using a random vector.
93 The second performs a "depth-first" incremental specialization.
94 The third performs a "breadth-first" incremental specialization.
96 The first is usually the fastest, but can fail if the random
97 vector happens to be chosen incorrectly.
98 The incremental algorithms should never fail, but can be slower,
99 in some cases by quite a bit.  The breadth-first version should
100 be faster than the depth-first version, especially on polytopes
101 of moderate dimension with a lot of "structure", but can require
102 more memory.
104 Sven Verdoolaege <skimo@kotnet.org>