LHAPDF6 is documented in more detail in http://arxiv.org/abs/1412.7420
The source files can be downloaded from https://lhapdf.hepforge.org/downloads/
Full installation and troubleshooting details are given at Installation instructions .
The following link takes you to the PDF sets which are currently available and officially supported:
/cvmfs/sft.cern.ch/lcg/external/lhapdfsets/current/. Many users will find it easiest to just set their
LHAPDF_DATA_PATH environment variable to point at this distributed filesystem area and use the preinstalled latest sets there.
lhapdf which can be used to query the catalogue of PDF sets and to install and update them from the command line. The user interface of this script is inspired by the Debian Linux
apt package management system – it accepts commands
upgrade. Please run
lhapdf help for full usage instructions. Please note that this script currently requires the LHAPDF library to have been built and installed with Python support.
.info files) and manage the indexing and distribution of the new files. We reserve the right to not incorporate PDFs unsuitable for public use. Thanks for your support!
Please follow this process to make the submission as smooth as possible:
SetIndexflag in its
.infofile, and set the
1if a new release, otherwise increment by one.
.tar.gzextension such that it will expand to the set directory (and its contents) only:
tar czf MySet.tar.gz MySet/.
$prefix/share/LHAPDF/ directory (i.e. the PDF dirs are at the same level as the global
lhapdf.conf file). To make use of PDF sets installed in other places, those search paths should be listed in the
LHAPDF_DATA_PATH environment variable. [
LHAPDF_DATA_PATH is an extension of the old
LHAPATH variable which supports multiple search paths separated by colon (
:) characters, cf. standard system paths like
Many code usage examples are collected here:
lhapdf-config script which can among other things produce the compiler flags needed to use LHAPDF. These include the
-I/path/to/include flag to indicate the position of installed LHAPDF header files, and
-L/path/to/lib -lLHAPDF flags for the library linker. The script is used in a compilation/linking command like this:
g++ mycode.cc -o myexe `lhapdf-config --cflags --ldflags`
gfortran mycode.f90 -o myexe `lhapdf-config --ldflags` -lstdc++
.dylib (Mac) rather than a static
.a library. The dynamic library needs to be found at runtime as well as at compile/link time.
LD_LIBRARY_PATH environment variable (or
DYLD_LIBRARY_PATH on Macs):
.dat files from the PDF set directory. It will work fine, as long as you don't try to load one of the missing members of course! In grid job submissions this can reduce the tarball of data that you send with your job by a large amount, since PDF sets often dominate such job tarballs.
LD_PRELOAD. This environment variable specifies libraries to be loaded before starting a process, and is a mechanism for replacing system library functions with modified versions.
open("foo") function with a version which will attempt to transparently read
foo.gz, uncompressed into the
/tmp directory, by setting
LD_PRELOAD=/lib/uncompress.so in your job. See the zlibc documentation for more details. LHAPDF6 itself needs no modification, but you will need to
cd into your PDF sets and run
for i in *.dat; do gzip $i; done in each one that you want to compress.
make &> makelog.txt or
bash sysdebug.sh &> sysdebug.txt (you may prefer to use a redirection like
|& tee foolog.txt but probably you don't need our advice if you have such preferences!)
See the following pages: