Skip to content

Commit

Permalink
Passage to 3.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Winfried Bruns committed Nov 30, 2017
1 parent 8381156 commit 944c52b
Show file tree
Hide file tree
Showing 13 changed files with 79 additions and 100 deletions.
5 changes: 4 additions & 1 deletion CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
# ChangeLog

## [3.4.2] 2017-11-30 (planned)
## [3.5.0] 2017-12-10 (planned)

-- LLL reduced coordinates for coordinate dependent algorithms
-- Expansion of Hilbert series and weighted Ehrhart series
-- projection of cones
-- Euclidean volumes
-- Flint as an optional library
--Dockerfile
-- install scripts

## [3.4.1] 2017-11-15

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion Qsource/libQnormaliz/Qversion.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#define QNMZ_VERSION_MAJOR 3
#define QNMZ_VERSION_MINOR 2
#define QNMZ_VERSION_PATCH 1
#define QNMZ_VERSION 3.4.2
#define QNMZ_VERSION 3.5.0
#define QNMZ_RELEASE (QNMZ_VERSION_MAJOR * 10000 + QNMZ_VERSION_MINOR * 100 + QNMZ_VERSION_PATCH)

namespace libQnormaliz {
Expand Down
6 changes: 3 additions & 3 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
# Process this file with autoconf to produce a configure script.

AC_PREREQ(2.59)
AC_INIT(Normaliz, 3.4.2)
AC_INIT(Normaliz, 3.5.0)
AC_SUBST(LIBNORMALIZ_VERSION_MAJOR, 3)
AC_SUBST(LIBNORMALIZ_VERSION_MINOR, 4)
AC_SUBST(LIBNORMALIZ_VERSION_PATCH, 2)
AC_SUBST(LIBNORMALIZ_VERSION_MINOR, 5)
AC_SUBST(LIBNORMALIZ_VERSION_PATCH, 0)
AC_SUBST(LIBNORMALIZ_VERSION_STRING, "$PACKAGE_VERSION")
AC_SUBST(LIBQNORMALIZ_VERSION_MAJOR, 3)
AC_SUBST(LIBQNORMALIZ_VERSION_MINOR, 2)
Expand Down
Binary file modified doc/Normaliz.pdf
Binary file not shown.
17 changes: 11 additions & 6 deletions doc/Normaliz.tex
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@

\def\ttt{\texttt}

\def\version{3.4.2}
\def\version{3.5.0}
\def\NmzDir{normaliz-\version}


Expand Down Expand Up @@ -277,21 +277,22 @@ \subsection{Major changes relative to version 3.1.1}
\item limit of parallelization via libnormaliz,
\item floating point numbers in input,
\item project-and-lift algorithm for lattice points in polytopes, also with a floating point variant,
\item significantly improved subdivision, equivalent replacement for Scip.
\item significantly improved subdivision, equivalent replacement for Scip,
\item fast Gorenstein test,
\item restriction of number of significant coefficients of quasipolynomial,
\item definition of semi-open parallelepipeds in input and output of their lattice points.
\end{arab}

3.4.1 is a pure bugfix.

In 3.4.2:
In 3.5.0:

\begin{arab}
\item use of LLL reduced coordinates in project-and-lift,
\item Use of LLL reduced coordinates in project-and-lift,
\item expansion of Hilbert series and weghted Ehrhart series for a range of degrees,
\item projection of cones and polyhedra,
\item Euclidean volumes,
\item optional library Flint for univariate polynomial arithmetic,
\item Docker image,
\item install scripts.
\end{arab}
Expand Down Expand Up @@ -5629,7 +5630,7 @@ \subsection{Normaliz at a stroke}
\begin{Verbatim}
./install_normaliz_with_opt.sh
\end{Verbatim}
downloads the optional packages CoCoALib and Flint, installs them in a subdirectory of the Normaliz directory (details see below), and compiles Normaliz via \verb|autotools| with shared libraries. The executable \verb|normaliz| is placed ito the directory \verb|source|.
downloads the optional packages CoCoALib and Flint \cite{Flint}, installs them in a subdirectory of the Normaliz directory (details see below), and compiles Normaliz via \verb|autotools| with shared libraries. The executable \verb|normaliz| is placed ito the directory \verb|source|.

Optionally you can run
\begin{Verbatim}
Expand Down Expand Up @@ -5677,7 +5678,7 @@ \subsection{autotools}
./configure
make
\end{Verbatim}
This will compile Normaliz with CoCoALib and Flint, provided these are installed in a standard location like \verb|/usr/local|.
This will compile Normaliz with CoCoALib and Flint, provided these are installed in a standard location like \verb|/usr/local|. (It is possible to customize the paths for the optional libraries; see \verb|source/INSTALL| or have a look at \verb|install_normaliz.sh|.)
Now you will find \verb|normaliz| in the directory \verb|source| (and \verb|maxsimplex| in its directory). \verb|libnormaliz| is created as a shared library.

The last, optional, step is
Expand All @@ -5698,6 +5699,8 @@ \subsection{cmake}\label{cmake}
\end{Verbatim}
Then \verb|make| and, optionally, \verb|sudo make install| will finish the job. The executable normaliz resudes in \verb|BUILD| and maxsimplex in a subdirectory. \verb|libnormaliz| is created as a shared library.

What has been said about the location of optional libraries in connection with autotools, applies here as well.

The main advantage of \verb|cmake| is its GUI \verb|ccmake| that you can invoke by
\begin{Verbatim}
ccmake .
Expand Down Expand Up @@ -7456,6 +7459,8 @@ \subsection{Installation}
\emph{NormalizInterface for GAP}.
Available at \url{https://github.com/gap-packages/NormalizInterface}.

\bibitem{Flint} W. Hart, F. Johansson and S. Pancratz, \emph{FLINT: Fast Library for Number Theory.} Available at \url{ http://flintlib.org}.

\bibitem{KV} M. Köppe and S. Verdoolaege. {\em Computing
parametric rational generating functions with a primal
Barvinok algorithm.} Electron. J. Comb.
Expand Down
4 changes: 2 additions & 2 deletions source/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ set(CMAKE_LEGACY_CYGWIN_WIN32 0) # Remove when CMake >= 2.8.4 is required
# The project name and the type of project
PROJECT(libnormaliz)
SET(VERSION_MAJOR 3)
SET(VERSION_MINOR 4)
SET(VERSION_PATCH 2)
SET(VERSION_MINOR 5)
SET(VERSION_PATCH 0)
SET(VERSION_STRING ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH})
SET(VERSION ${VERSION_STRING})

Expand Down
110 changes: 35 additions & 75 deletions source/INSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,7 @@ CoCoALib first by running

sudo ./install_nmz_cocoa.sh

in the Normaliz directory. This copies the files needed by Normaliz to /usr/local.

The source files have been downloaded to the directory VocoA in your home directory.
Uf you have other preferences, edit install_nmz_cocoa.sh accordingly or do
the installation nstep by step.
in the Normaliz directory. This copies the files needed by Normaliz to nmz_opt_lib.

Without functional extension:

Expand Down Expand Up @@ -111,35 +107,25 @@ system (./bootstrap.sh) -- in this case, the system needs to have
autoconf, automake, libtool installed. This step is not necessary if
you started from a normaliz distribution.

We assune in the following that Boost and GMP are in standard locations. (It is
possible to customize the paths to them as well.)

We assume that you are in the directory in which source, doc etc. are subdirectories.

The first step is to configure the compilation. The simplest choice is

./configure

This is sufficient if you don't want SCIP or CoCoALib, provided libraries such
as GMP and Boost are in standard locations. If not, you must inform configure where to
find them:

./configure CPPFLAGS="-I /path/to/includedir $CPPFLAGS" LDFLAGS="-L/path/to/libdir $LDFLAGS"
This is sufficient if you don't want any optional library.

For example, on Fink (Mac OS X):

./configure CPPFLAGS="-I/sw/include -I/sw/opt/boost-1_58/include $CPPFLAGS" LDFLAGS="-L/sw/lib -L/sw/opt/boost-1_58/lib $LDFLAGS"

To configure normaliz for scipoptsuite compiled as above use:

./configure --with-scipoptsuite-src=/path/to/scipoptsuite-source-dir

Similarly, it may be necessary to show configure the path to CoCoALib if you want
to compile with it (and CoCoALib is not in a standard location):
If CoCoALib is not in a standard location, to show configure the path to CoCoALib if you want
to compile with it use the option --with-cocoalib. For example:

./configure --with-cocoalib=$HOME/CoCoA/CoCoALib-0.99550

If you want to use a GMP installation that is not at a standard location you can set
the path to your GMP by
Simlarly, you can set the path for Flint

./configure --with-gmp=path/to/GMP
./configure --with-flint=...

Some more configure options:

Expand Down Expand Up @@ -169,11 +155,24 @@ and then (if you want)
This will install normaliz, the libraries and header files in their chosen
location (usr/local by default).

Confuguration with Scip:

For example, on Fink (Mac OS X):

./configure CPPFLAGS="-I/sw/include -I/sw/opt/boost-1_58/include $CPPFLAGS" LDFLAGS="-L/sw/lib -L/sw/opt/boost-1_58/lib $LDFLAGS"

To configure normaliz for scipoptsuite compiled as above use:

./configure --with-scipoptsuite-src=/path/to/scipoptsuite-source-dir


***************
**** CMAKE ****
***************

This has better capabilities to find libraries and allowa to change settings with a nice interface. Furthermore it supports the compilation of the library as static and dynamic version, installation of the library.
This has better capabilities to find libraries and allows to change settings with a nice interface.
Furthermore it supports the compilation of the library as static and dynamic version, and the
installation of the library.

We assume you start in the normaliz root dir (with subdirs source, examples, ...).

Expand Down Expand Up @@ -216,7 +215,8 @@ This will install the produced libnormaliz, the header files for it and the nor

If you want to override system defaults you can change values with ccmake or set enviroment variables.

IMPORTANT NOTE: Be aware that some of these only work with the first call of cmake. If you want to change it later clean your build directory first, or use another fresh build directory.
IMPORTANT NOTE: Be aware that some of these only work with the first call of cmake.
If you want to change it later clean your build directory first, or use another fresh build directory.

Some examples:

Expand Down Expand Up @@ -281,56 +281,9 @@ The directories for Flint and MPFR can be set via

FLINT_DIR
MPFR_DIR

You need both of them.

**** CMAKE: Build for Intel Xeon Phi Mic ****

This section describes how to compile Normaliz with support for offloading to Intel Xeon Phi. Only the Intel compiler supports this offload.

First you need (as usual) the libraries boost and gmp. The libgmp and libgmpxx must be compiled twice, once for the host and once for the target-architecture of the mic. You will probably not find a compiled version for the mic, so we recommend to compile both yourself. Download the gmp sources and extract them.

The following description is based on gmp 6.0.0 and icc 15.0.2

Compile GMP with icc:

cd gmp-6.0.0
mkdir BUILD_native
cd BUILD_native
CC=icc CXX=icpc ../configure --enable-cxx --prefix=$HOME/local/
make
make install

Compile gmp with icc for the mic:

cd gmp-6.0.0
mkdir BUILD_mic
cd BUILD_mic
CC=icc CXX=icpc CFLAGS="-mmic" CXXFLAGS="-mmic" LDFLAGS="-mmic" ../configure --host=x86_64-k1om-linux --enable-cxx --disable-assembly --prefix=$HOME/mic_local/
make
make install

The intel compiler had problems with User-defined literals from c++11, so we had to comment out some lines (1925-1944) in $HOME/local/include/gmpxx.h and the same for the mic dir.

Now we are ready to compile Normaliz:

cd normaliz
mkdir BUILD_OFFLOAD
cd BUILD_OFFLOAD
CC=icc CXX=icpc GMP_DIR=$HOME/local MIC_GMP_DIR=$HOME/mic_local BOOST_ROOT=$HOME/boost_1_57_0 cmake -DNMZ_MIC_OFFLOAD=ON ../source/
make

If you get an error saying it cannot find boost/dynamic_bitset.hpp or similar, try to set BOOST_INCLUDE_DIR directly to a path which is not a system default path (e.g. by using "ccmake ." after the first configuration.)

For running the executable you also have to set the MIC_LD_LIBRARY_PATH, e.g. by an entry in the .profile

if [ $HOSTNAME == 'phi' ] ; then #only on the system with mics
export LD_LIBRARY_PATH=$HOME/local/lib/:$LD_LIBRARY_PATH
export MIC_LD_LIBRARY_PATH=$HOME/mic_local/lib/:$MIC_LD_LIBRARY_PATH
fi


If you want to compile Normaliz for running it NATIVELY on the Phi, give

CC=icc CXX=icpc GMP_DIR=$HOME/mic_local BOOST_ROOT=$HOME/boost_1_57_0 cmake -DCMAKE_CXX_FLAGS=-mmic ../source/

********************
**** plain MAKE ****
Expand All @@ -341,6 +294,13 @@ Under Linux one can still use our old simple plain Makefile. But the autotools a
This Makefile is mainly used for deveopment and debuggung. It builds statically linked binaries
with -g (can be changed in Makefile.configutaion).

It is assumed that the optional libraries are in

$/HOME)/nmz_opt_lib

So you should copy nmz_opt_lib from the Normaliz directory to your home directory.
(Intentionall we do not choose a standard location.)

1) Go to the source directory

2) Check the configuration in Makefile.configuration, especially the locations of
Expand All @@ -364,7 +324,7 @@ Makefile.classic accepts optional arguments (also simultaneously):
make -f Makefile.classic OPENMP=no # deactivates OpenMP
make -f Makefile.classic COCOA=no # deactivates CoCoALib
make -f Makefile.classic SCIP=yes # compile with SCIP
make -f Makefile.classic Flint=yes # compile with Flint
make -f Makefile.classic Flint=no # compile with Flint

You must make sure that everything is compiled with the same set of options!
In doubt use make clean before.
Expand Down
11 changes: 5 additions & 6 deletions source/Makefile.configuration
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,12 @@ CXXFLAGS += -g ## debugging

SCIPPATH = $(HOME)/SCIP/scipoptsuite-3.2.0

COCOA_ROOT=$(HOME)/CoCoA/CoCoALib-0.99550
COCOA_ROOT=$(HOME)/nmz_opt_lib
FLINT_ROOT = $(COCOA_ROOT)
MPFR_ROOT = $(FLINT_DIR)

INSTALLDIR= /usr/local

# COCOA_ROOT = $(INSTALLDIR)
FLINT_ROOT = $(INSTALLDIR)
MPFR_ROOT = $(INSTALLDIR)

## use OpenMP?
ifeq ($(OPENMP),no)
CXXFLAGS += -Wno-unknown-pragmas
Expand Down Expand Up @@ -60,7 +58,8 @@ else
endif

##use FLINT?
ifeq ($(FLINT),yes)
ifeq ($(FLINT),no)
else
CXXFLAGS += -DNMZ_FLINT
CXXFLAGS += -I $(FLINT_ROOT)/include/
FLINTFLAGS = -L $(FLINT_ROOT)/lib -lflint -L $(MPFR_ROOT)/lib -lmpfr
Expand Down
6 changes: 3 additions & 3 deletions source/libnormaliz/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
#define NMZ_VERSION_H

#define NMZ_VERSION_MAJOR 3
#define NMZ_VERSION_MINOR 4
#define NMZ_VERSION_PATCH 2
#define NMZ_VERSION 3.4.2
#define NMZ_VERSION_MINOR 5
#define NMZ_VERSION_PATCH 0
#define NMZ_VERSION 3.5.0
#define NMZ_RELEASE (NMZ_VERSION_MAJOR * 10000 + NMZ_VERSION_MINOR * 100 + NMZ_VERSION_PATCH)

namespace libnormaliz {
Expand Down
2 changes: 1 addition & 1 deletion source/normaliz.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ void printHeader() {
<< " \\....|"<<endl;
cout << " \\...|"<<endl;
cout << " (C) The Normaliz Team, University of Osnabrueck \\..|"<<endl;
cout << " November 2017 \\.|"<<endl;
cout << " December 2017 \\.|"<<endl;
cout << " \\|"<<endl;
bool with_optional_packages=false;
string optional_packages;
Expand Down
Loading

0 comments on commit 944c52b

Please sign in to comment.