Prerequisites of the Herwig program

The Herwig program is a large framework which incorporates many third party libraries. If you are Using the Herwig bootstrap script you do not need to take care of the installation of these packages. However, it may be that you want to install some of these packages manually or have them already installed on your machine. To make sure that Herwig works correctly make sure that all installations are performed with parameters such as outlined below.

We start with the numerical tools underlying Herwig. In the second section we describe the the different tools Herwig uses to compute the matrix elements.

Note: If you have already running ThePEG or Herwig++ installations on your system, make sure that while installing the programs no leftovers of these are present in your LD_LIBRARY_PATH.

Tools

BOOST

Boost is a collection of widely used C++ libraries and headers for numerical computation. However, the Boost package will only work with Herwig if installed with --layout=tagged and the libraries are installed. To have only the headers (e.g. Rivet’s default) is not enough. This means your Boost installation should look similar to the following (use the --with-python if you also like to use Boost libraries within python code)

cd /where/to/build/boost
wget -O boost_1_58_0.tar.gz "http://sourceforge.net/projects/boost/files/boost/1.58.0/boost_1_58_0.tar.gz/download"
tar -xvf boost_1_58_0.tar.gz
cd boost_1_58_0
./bootstrap.sh --prefix=/where/to/install/boost --with-python=$(which python)
./b2 install --layout=tagged

Note: without this tag wrong BOOST installs might get linked against the build, which leads to an error during make.

Note: this is not necessary if you are Using the Herwig bootstrap script.

Note: the above BOOST version is the most current one at the time of writing. You may find newer versions and additional information on the BOOST web-page.

RIVET

RIVET is a standardized HEP analysis tool. A thorough installation guide can be found on the Rivet web-page. However, make sure to NOT install BOOST with RIVET as this will not work for Herwig. Using the rivet-bootstrap this means your installation might look like

INSTALL_PREFIX=/where/to/install/rivet INSTALL_BOOST=0 BOOSTPATH=/where/you/installed/boost MAKE="make -j $(nproc)" ./rivet-bootstrap

If not configured differently RIVET automatically will install GSL, FastJet and HepMC. If you want to install these packages yourself (which we do not recommend) here is a short guide to installing each of them.

HEPMC

HepMC is a widely used event format:

cd /where/to/build/hepmc
wget "http://lcgapp.cern.ch/project/simu/HepMC/download/HepMC-2.06.09.tar.gz"
tar -xvf HepMC-2.06.09.tar.gz
cd HepMC-2.06.09
./configure --prefix=/where/to/install/hepmc –-with-momentum=GEV -–with-length=MM
make -j$(nproc)
make check
make install

Note: the above HepMC version is the most current one at the time of writing. You might find newer versions and additional information on the HepMC web-page.

GSL

The Gnu Scientific Library (GSL) collects numerical standard tools. To install a local version follow these steps

cd /where/to/build/gsl
wget "http://ftp.heanet.ie/mirrors/gnu/gsl/gsl-1.16.tar.gz"
tar -xvf gsl-1.16.tar.gz
cd gsl-1.16
./configure --prefix=/where/to/install/gsl
make -j$(nproc)
make check
make install

Note: the above GSL version is the most current one at the time of writing. You might find newer versions and additional information on the GSL web-page.

FastJet

The FastJet package provides implementation of all the common jet algorithms. To install a local version follow these steps:

cd /where/to/build/fastjet
wget http://fastjet.fr/repo/fastjet-3.1.2.tar.gz
tar -xvf fastjet-3.1.2.tar.gz
cd fastjet-3.1.2
./configure --prefix=/where/to/install/fastjet --enable-allplugins
make -j$(nproc)
make check
make install

Note: the above FastJet version is the most current one at the time of writing. You might find newer versions and additional information on the FastJet web-page.

LHAPDF

LHAPDF is a HEP tool to compute and interface the parton density functions. A local installation might look like

cd /where/to/build/lhapdf

wget "http://www.hepforge.org/archive/lhapdf/LHAPDF-6.1.5.tar.gz"
tar -xvf LHAPDF-6.1.5.tar.gz
cd LHAPDF-6.1.5
./configure --prefix=/where/to/install/lhapdf --with-boost=/where/you/installed/boost
make -j$(nproc)
make check
make install

The pdf sets themselves have to be installed manually with lhapdf install <PDFSET>. As Herwig is using the MMHT 2014 PDF sets by default it is a good idea to install these using

lhapdf install MMHT2014nlo68cl
lhapdf install MMHT2014lo68cl

Note: the above LHAPDF version is the most current one at the time of writing. You may find newer versions and additional information on the LHAPDF web-page.

ThePEG

ThePEG is the standardized event generator frame work Herwig relies on. Therefore, it has mostly the same prerequisites as Herwig itself. In addition it provides the interface to the parton density functions (pdf’s) via the LHAPDF tool. The code can be downloaded using

wget "http://www.hepforge.org/archive/thepeg/ThePEG-2.0.0.tar.bz2"
tar xjf ThePEG-2.0.0.tar.bz2

Alternatively advanced users may wish to checkout the code from the Mercurial repository

The code can then be configured and built

 cd ThePEG-2.0.0
 ./configure --prefix=/where/to/install/thepeg --with-fastjet=/where/fastjet/was/installed \
             --with-gsl=/where/gsl/was/installed --with-rivet=/where/rivet/was/installed \
             --with-hepmc=/where/hepmc/was/installed --with-lhapdf=/where/lhapdf/was/installed
make -j$(nproc)
make check
make install

External amplitude providers

You do not need to install any of these packages for Herwig to work for simple processes. However, for more complicated processes we would recommend installing at least Madgraph and one of the general one-loop programs.

GoSam

GoSam is a general package for the calculation of tree-level and one-loop amplitudes. It can be installed by first downloading the GoSam installer and then running it. It is advisable to do this in a new directory

mkdir gosam
cd gosam
wget "http://gosam.hepforge.org/gosam_installer.py"
chmod 0755 ./gosam_installer.py
./gosam_installer.py -b -v --prefix=/where/to/install/gosam

This will install the latest version. You can find additional information at the GoSam web-page.

MadGraph

Madgraph/aMC@NLO is a general program which can calculate both tree-level and one-loop amplitudes. Unlike some of the other programs the Madgraph code does not need to be configured, compiled and installed just downloaded

wget "https://launchpad.net/mg5amcnlo/2.0/2.2.0/+download/MG5_aMC_v2.3.0.beta.tar.gz"
tar xzf MG5_aMC_v2.3.0.beta.tar.gz

Note: the above Madgraph/aMC@NLO version is the most current one at the time of writing. You may find newer versions and additional information on the MadGraph/aMC@NLO web-page.

Note:

  • As Madgraph is not compiled and installed when specifying the path later to link it with Herwig you must supply the fullpath, i.e.

    /where/you/extracted/the/tarball/MG5_aMC_v2_3_0_beta
    
  • To calculate NLO processes you need an installed version of golem. We recommend that you install GoSam as described above. If you install golem yourself make sure that the libary is in your LD_LIBRARY_PATH.

NJet

NJet is a program for the calculation of jets, W+jets, Z+jets, A+jets and AA+jets processes. It can be downloaded and compiled using

wget https://bitbucket.org/njet/njet/downloads/njet-2.0.0.tar.gz
tar xzf njet-2.0.0.tar.gz
cd njet-2.0.0
./configure --prefix=/where/to/install/njet --disable-autoflags
make -j$(nproc)
make check
make install

Note:

  • The above NJet version is the most current one at the time of writing. You may find newer versions and additional information on the NJet web-page.
  • Configure with –disable-autoflags, otherwise NJet is compiled with -march=native and -mtune=native which results in SIGILL coredumps on non-compatible CPUs.

OpenLoops

The OpenLoops program can calculate a wide range of one-loop ampiltudes. It can be downloaded using

svn co http://openloops.hepforge.org/svn/OpenLoops/branches/public OpenLoops

There are a qwide range of processses available, here we will only install the processes for \(q\bar{q}\to \gamma/Z^0\to \ell^+\ell^-\)

cd OpenLoops
./openloops libinstall ppll

The full list of available processes can be found on the OpenLoops web-page.

Note:

  • As OpenLoops is not installed when specifying the path later to link it with Herwig you must supply the fullpath, i.e.

    /where/you/checkedout/openloops/OpenLoops
    
  • OpenLoops needs to be complied with either gfortran 4.6 or later or ifort.

VBFNLO

The VBFNLO program simulates vector-boson fusion processes at both leading and next-to-leading order. It can be downloaded and installed using

wget "http://www.itp.kit.edu/~vbfnloweb/archive/vbfnlo-3.0.0beta1.tgz"
tar xzf vbfnlo-3.0.0beta1.tgz
cd VBFNLO-3.0.0beta1
./configure --prefix=/where/to/install/vbfnlo
make -s -j$(nproc)
make -s install

More information can be found on the VBFNLO web-page.