HEJ: Installation of the Programs

a High Energy Physics Monte Carlo generator for multi-jet analyses.
Authors: Jeppe R. Andersen and Jennifer M. Smillie

This page describes how to install and run the programs included in the HEJ generator package. As an example, we discuss the program for the generation and analysis of events with two or more hard jets (pure jets).

Content:

  • Download
  • Compilation and Running
  • Setup for Parallel Runs
  • PDFs (MSTW2008 and LHAPDF)
  • Download

    The generator (version 1.4.4, 20 Jun 2013) and a sample analysis for both pure dijets, W+dijets and H+dijets can be downloaded here and is distributed under the the conditions in the GNU General Public License (GNU GPL) and the MCnet guidelines for authors and users.

  • HEJv1.4.4.tar.gz: bug-release, correcting the weights which appear in the scale-uncertainty vector, weights, in JetGen.
  • HEJv1.4.3.tar.gz: bug-release, correcting the non-FKL matching for H+jets. Also, the numbering of scale choices is made uniform.
  • The package contains several files. However, for jet analysis, 'JetGen.C' and 'input_jets_vanilla' are the only files that the user need to worry about - this is where the events are analysed at the partonic level. For W-production in association with at least two jets, the corresponding files are called 'WJetGen.C' and 'input_vanilla'.

    Compilation and Running

    The program itself makes use of the following packages:

  • the Class Library for High Energy Physics
  • fastjet
  • ROOT
  • which all need to be installed for the program to compile and run. Root is only needed for the example analysis included in the package, so by removing the ROOT calls from the analysis and the linker statements in the Makefile, you can compile the package without installing ROOT. You can check whether the packages are already installed by issuing the following commands:
    clhep-config
    fastjet-config
    root-config
    
    If any of these commands return "Command not found" then the relevant package needs to be installed.

    When the dependencies have been installed, the program can be untared and compiled:

    mkdir Jets
    cd Jets
    tar xzvf ../HEJ_1.4.4.tar.gz
    make
    

    The event generator can now be run by executing the command

    ./JetGen input_jets_vanilla
    
    for the production and analysis of dijet events. The file 'input_jets_vanilla' control the basic behaviour of the program, and the values of parameters.
    ./WJetGen input_vanilla
    
    is the corresponding command for generating events of W+dijets.
    ./HJetGen input_h
    
    is the corresponding command for generating events of H+dijets.

    The standard form of the file 'input_jets_vanilla' is given below:

    extpartonptmin: 25.;
    jetptmin: 30.  // Minimum transverse momentum of jets
    jetrapmax: 4.5 // Maximum rapidity of jets
    ptbarmin: 0.  // Minimum average pt of tagging jets
    Ebeam: 3500.   // Energy of the particle beam
    scale: 30.    // The factorisation and renormalisation scale in GeV
    scalesetting: 2 //
    scalefactor: 1 // multiplicative factor for the scale when scalesetting \in {1,2}
    logcorrect: 1 // Whether or not to include higher order logs
    beam1: P       // The particle type of beam 1 (P: proton, -P: anti-proton)
    beam2: P       // The particle type of beam 2 (P: proton, -P: anti-proton)
    NEvents: 2000000 // 12000000 ~ 10min // The number of attempted events
    //NEvents: 120000000 // 12000000 ~ 10min // The number of attempted events
    Rparam: 0.6
    jetalgo: antikt
    LHoutput: n // Output events in Les Houches format (y: yes, n:no)
    LHoutputfile: LHEvents.dat // The name of the LH output file
    unweight: n // unweight events in the LH output (y: yes, n: no)
    resum: y       // Perform resummation
    match: y       // Match the LO W+2jet and W+3jet (y:yes, n:no)
    nonFKLmatch2j: y // Include 2j non-FKL matching
    nonFKLmatch3j: y // Include 3j non-FKL matching
    nonFKLmatch4j: y // Include 3j non-FKL matching
    rootevents: n // Save event record in root file?
    // PDFs:
    mstwpdffile: Grids/mstw2008nlo.00.dat
    // LHAPDFName: MSTW2008nlo90cl
    // LHAPDFsubset: 0
    // LHAPDFName: cteq61
    // LHAPDFsubset: 0
    useLHApdf: n
    

    The instruction scalesetting: 0 will tell HEJ to use as a renormalisation and factorisation scale the max transverse momentum of any of the jets. scalesetting: 1 tells HEJ to use the fixed value given by e.g. scale: 30.. scalesetting: 2 will tell HEJ to use the scalar sum of transverse momenta divided by 2 (ie. Ht/2). scalesetting: 3 will tell HEJ to use the geometric mean of the jet pt as the scale. The scale can furthermore be varied by the factor determined by scalefactor. Please note that the higher order corrections of HEJ prefer the scale choice of the max pt of any jet (scalesetting: 0), and that the result of using all the scale choices, including variations within a factor of two in either directions, is automatically saved to the ROOT event file.

    The line logcorrect: 1 instructs HEJ to take into account higher order logarithms, which stabilise the scale dependence.

    Setup for Parallel Runs

    The file "JetGen.C" contains a very simple analysis of events with multiple jets. The result of the analysis is saved in the file "output.root", which can be analysed using ROOT. The filename for the ROOT file can be set with the option e.g.

    rootfile: JetGen2.root
    
    in the inputs file.

    Furthermore, the package contains several files for the initialisation of the random number generator. This is to allow for several parallel runs of the generation and analysis. The random number generator is initialised by including a statement like

    raninitfile: ranlux_files/ranlux64.1
    
    in the input file. Each file in the directory ranlux_files can be used.

    By using separate root output files for several runs, initialised with separate ranlux files, the outputs can be combined by use of the hadd-command. The histograms filled with a wts (see JetGen.C) will then have to be rescaled with 1/N, where N is the number of runs.

    PDFs (MSTW2008 and LHAPDF)

    By default, the HEJ package makes use of the MSTW2008 class of pdfs, and the central mstw2008nlo grid is shipped with the HEJ package. However, any of the mstw2008 grids can be used, by downloading them from the mstw2008 web-page, installing them in e.g. the Grids-directory, and including in the inputs-file a line like
    mstwpdffile: Grids/mstw2008nlo.00.dat
    

    However, it is also possible to make use of the full LHApdf-package, if this is already installed. To do so, the first line of Jets.C

    #define USELHAPDF 0
    
    has to be modified to say
    #define USELHAPDF 1
    
    You can now compile with support for LHApdf by running:
    make
    
    If you now want to run with e.g. the NNPDF-set, it has to be first downloaded and installed in the correct LHApdf directory (use lhapdf-getdata). You can then use the sets by including the following lines in the input file:
    useLHApdf: y
    LHAPDFName: NNPDF20_100
    LHAPDFsubset: 0
    
    Obviously, any other set of pdfs included in the LHApdf distribution could be used as well.