Rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

ATLAS_2014_I1319490

W + jets
Experiment: ATLAS (LHC)
Inspire ID: 1319490
Status: VALIDATED
Authors:
  • Matthew Mondragon
References: Beams: p+ p+
Beam energies: (3500.0, 3500.0) GeV
Run details:
  • inclusive W production in the electron channel

Measurements of cross sections for the production of a $W$ boson in association with jets in protonproton collisions at $\sqrt{s} = 7$ TeV with the ATLAS experiment at the Large Hadron Collider. With an integrated luminosity of 4.6 $\text{fb}^{1}$, this data set allows for an exploration of a large kinematic range, including jet production up to a transverse momentum of 1 TeV and multiplicities up to seven associated jets. The production cross sections for W bosons are measured in both the electron and muon decay channels. Differential cross sections for many observables are also presented including measurements of the jet observables such as the rapidities and the transverse momenta as well as measurements of event observables such as the scalar sums of the transverse momenta of the jets. The default routine will pick up the electron decay channel of the $W$ boson and compare it to the combined (muon and electron channel) data. Individual channels (for data) are available as well, use ATLAS_2014_I1312627_EL and ATLAS_2014_I1312627_MU to specify the decay channel directly.

Source code: ATLAS_2014_I1319490.cc
  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
#include "Rivet/Analysis.hh"
#include "Rivet/Projections/FinalState.hh"
#include "Rivet/Projections/WFinder.hh"
#include "Rivet/Projections/FastJets.hh"
#include "Rivet/Projections/VetoedFinalState.hh"

namespace Rivet {


  class ATLAS_2014_I1319490 : public Analysis {
  public:

    ATLAS_2014_I1319490(string name = "ATLAS_2014_I1319490")
      : Analysis(name)
    {
      _mode = 0; // using electron channel for combined data by default
      setNeedsCrossSection(true);
    }


    // Book histograms and initialise projections before the run
    void init() {

      FinalState fs;

      Cut cuts;
      if (_mode == 2) { // muon channel
        cuts = (Cuts::pT > 25.0*GeV) & Cuts::etaIn(-2.4, 2.4);
      } else if (_mode) { // electron channel
        cuts = (Cuts::pT > 25.0*GeV) & ( Cuts::etaIn(-2.47, -1.52) | Cuts::etaIn(-1.37, 1.37) | Cuts::etaIn(1.52, 2.47) );
      } else { // combined data extrapolated to common phase space
        cuts = (Cuts::pT > 25.0*GeV) & Cuts::etaIn(-2.5, 2.5);
      }

      // bosons
      WFinder wfinder(fs, cuts, _mode > 1? PID::MUON : PID::ELECTRON, 40.0*GeV, MAXDOUBLE, 0.0*GeV, 0.1,
                      WFinder::CLUSTERNODECAY, WFinder::NOTRACK, WFinder::TRANSMASS);
      declare(wfinder, "WF");

      // jets
      VetoedFinalState jet_fs(fs);
      jet_fs.addVetoOnThisFinalState(getProjection<WFinder>("WF"));
      FastJets jets(jet_fs, FastJets::ANTIKT, 0.4);
      jets.useInvisibles(true);
      declare(jets, "Jets");

      // book histograms
      histos["h_N_incl"]            = bookHisto1D(1,1,_mode+1);
      histos["h_N"]                 = bookHisto1D(4,1,_mode+1);
      histos["h_pt_jet1_1jet"]      = bookHisto1D(5,1,_mode+1);
      histos["h_pt_jet1_1jet_excl"] = bookHisto1D(6,1,_mode+1);
      histos["h_pt_jet1_2jet"]      = bookHisto1D(7,1,_mode+1);
      histos["h_pt_jet1_3jet"]      = bookHisto1D(8,1,_mode+1);
      histos["h_pt_jet2_2jet"]      = bookHisto1D(9,1,_mode+1);
      histos["h_pt_jet3_3jet"]      = bookHisto1D(10,1,_mode+1);
      histos["h_pt_jet4_4jet"]      = bookHisto1D(11,1,_mode+1);
      histos["h_pt_jet5_5jet"]      = bookHisto1D(12,1,_mode+1);
      histos["h_y_jet1_1jet"]       = bookHisto1D(13,1,_mode+1);
      histos["h_y_jet2_2jet"]       = bookHisto1D(14,1,_mode+1);
      histos["h_HT_1jet"]           = bookHisto1D(15,1,_mode+1);
      histos["h_HT_1jet_excl"]      = bookHisto1D(16,1,_mode+1);
      histos["h_HT_2jet"]           = bookHisto1D(17,1,_mode+1);
      histos["h_HT_2jet_excl"]      = bookHisto1D(18,1,_mode+1);
      histos["h_HT_3jet"]           = bookHisto1D(19,1,_mode+1);
      histos["h_HT_3jet_excl"]      = bookHisto1D(20,1,_mode+1);
      histos["h_HT_4jet"]           = bookHisto1D(21,1,_mode+1);
      histos["h_HT_5jet"]           = bookHisto1D(22,1,_mode+1);
      histos["h_deltaPhi_jet12"]    = bookHisto1D(23,1,_mode+1);
      histos["h_deltaRap_jet12"]    = bookHisto1D(24,1,_mode+1);
      histos["h_deltaR_jet12"]      = bookHisto1D(25,1,_mode+1);
      histos["h_M_Jet12_2jet"]      = bookHisto1D(26,1,_mode+1);
      histos["h_y_jet3_3jet"]       = bookHisto1D(27,1,_mode+1);
      histos["h_y_jet4_4jet"]       = bookHisto1D(28,1,_mode+1);
      histos["h_y_jet5_5jet"]       = bookHisto1D(29,1,_mode+1);
      histos["h_ST_1jet"]           = bookHisto1D(30,1,_mode+1);
      histos["h_ST_2jet"]           = bookHisto1D(31,1,_mode+1);
      histos["h_ST_2jet_excl"]      = bookHisto1D(32,1,_mode+1);
      histos["h_ST_3jet"]           = bookHisto1D(33,1,_mode+1);
      histos["h_ST_3jet_excl"]      = bookHisto1D(34,1,_mode+1);
      histos["h_ST_4jet"]           = bookHisto1D(35,1,_mode+1);
      histos["h_ST_5jet"]           = bookHisto1D(36,1,_mode+1);
    }


    void fillPlots(const Particle& lepton, const double& missET, Jets& all_jets, const double& weight) {
      // do jet-lepton overlap removal
      Jets jets;
      double ST = 0.0; // scalar pT sum of all selected jets
      foreach (const Jet &j, all_jets) {
        if (deltaR(j, lepton) > 0.5) {
          jets += j;
          ST += j.pT() / GeV;
        }
      }

      const size_t njets = jets.size();

      const double HT = ST + lepton.pT() / GeV + missET;

      histos["h_N"]->fill(njets + 0.5, weight);
      for (size_t i = 0; i <= njets; ++i) {
        histos["h_N_incl"]->fill(i + 0.5, weight);
      }

      if (njets) {
        const double pT1  = jets[0].pT() / GeV;
        const double rap1 = jets[0].absrap();
        histos["h_pt_jet1_1jet" ]->fill(pT1, weight);
        histos["h_y_jet1_1jet"]->fill(rap1, weight);
        histos["h_HT_1jet"]->fill(HT, weight);
        histos["h_ST_1jet"]->fill(ST, weight);
        if (njets == 1) {
          histos["h_pt_jet1_1jet_excl"]->fill(pT1, weight);
          histos["h_HT_1jet_excl"]->fill(HT, weight);
        } else {
          const double pT2  = jets[1].pT() / GeV;
          const double rap2 = jets[1].absrap();
          const double dR   = deltaR(jets[0], jets[1]);
          const double dRap = deltaRap(jets[0], jets[1]);
          const double dPhi = deltaPhi(jets[0], jets[1]);
          const double mjj  = (jets[0].momentum() + jets[1].momentum()).mass() / GeV;
          histos["h_pt_jet1_2jet"]->fill(pT1, weight);
          histos["h_pt_jet2_2jet"]->fill(pT2, weight);
          histos["h_y_jet2_2jet"]->fill(rap2, weight);
          histos["h_M_Jet12_2jet"]->fill(mjj, weight);
          histos["h_HT_2jet"]->fill(HT, weight);
          histos["h_ST_2jet"]->fill(ST, weight);
          histos["h_deltaPhi_jet12"]->fill(dPhi, weight);
          histos["h_deltaRap_jet12"]->fill(dRap, weight);
          histos["h_deltaR_jet12"]->fill(dR, weight);
          if (njets == 2) {
            histos["h_ST_2jet_excl"]->fill(ST, weight);
            histos["h_HT_2jet_excl"]->fill(HT, weight);
          } else {
            const double pT3  = jets[2].pT() / GeV;
            const double rap3 = jets[2].absrap();
            histos["h_pt_jet1_3jet"]->fill(pT1, weight);
            histos["h_pt_jet3_3jet"]->fill(pT3, weight);
            histos["h_y_jet3_3jet"]->fill(rap3, weight);
            histos["h_HT_3jet"]->fill(HT, weight);
            histos["h_ST_3jet"]->fill(ST, weight);
            if(njets == 3) {
              histos["h_ST_3jet_excl"]->fill(ST, weight);
              histos["h_HT_3jet_excl"]->fill(HT, weight);
            } else {
              const double pT4  = jets[3].pT() / GeV;
              const double rap4 = jets[3].absrap();
              histos["h_pt_jet4_4jet"]->fill(pT4, weight);
              histos["h_y_jet4_4jet"]->fill(rap4, weight);
              histos["h_HT_4jet"]->fill(HT, weight);
              histos["h_ST_4jet"]->fill(ST, weight);
              if (njets > 4) {
                const double pT5  = jets[4].pT() / GeV;
                const double rap5 = jets[4].absrap();
                histos["h_pt_jet5_5jet"]->fill(pT5, weight);
                histos["h_y_jet5_5jet"]->fill(rap5, weight);
                histos["h_HT_5jet"]->fill(HT, weight);
                histos["h_ST_5jet"]->fill(ST, weight);
              }
            }
          }
        }
      }
    }


    // Perform the per-event analysis
    void analyze(const Event& event) {
      // Retrieve boson candidate
      const WFinder& wf = apply<WFinder>(event, "WF");
      if (wf.empty()) vetoEvent;

      // Retrieve jets
      const JetAlg& jetfs = apply<JetAlg>(event, "Jets");
      Jets all_jets = jetfs.jetsByPt(Cuts::pT > 30.0*GeV && Cuts::absrap < 4.4);

      const Particles& leptons = wf.constituentLeptons();
      const double missET = wf.constituentNeutrino().pT() / GeV;
      if (leptons.size() == 1 && missET > 25.0 && wf.mT() > 40.0*GeV) {
        const Particle& lep = leptons[0];
        fillPlots(lep, missET, all_jets, event.weight());
      }
    }


    void finalize() {
      const double scalefactor(crossSection() / sumOfWeights());
      /// @todo Update to use C++11 range-for
      for (map<string, Histo1DPtr>::iterator hit = histos.begin(); hit != histos.end(); ++hit) {
        scale(hit->second, scalefactor);
      }
    }


  protected:

    size_t _mode;


  private:

    map<string, Histo1DPtr> histos;

  };


  class ATLAS_2014_I1319490_EL : public ATLAS_2014_I1319490 {
  public:
    ATLAS_2014_I1319490_EL()
      : ATLAS_2014_I1319490("ATLAS_2014_I1319490_EL")
    {
      _mode = 1;
    }
  };


  class ATLAS_2014_I1319490_MU : public ATLAS_2014_I1319490 {
  public:
    ATLAS_2014_I1319490_MU()
      : ATLAS_2014_I1319490("ATLAS_2014_I1319490_MU")
    {
      _mode = 2;
    }
  };


  // The hooks for the plugin system
  DECLARE_RIVET_PLUGIN(ATLAS_2014_I1319490);
  DECLARE_RIVET_PLUGIN(ATLAS_2014_I1319490_EL);
  DECLARE_RIVET_PLUGIN(ATLAS_2014_I1319490_MU);

}