rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

ATLAS_2014_I1315949

Distributions sensitive to the underlying event in inclusive Z-boson production at 7 TeV
Experiment: ATLAS (LHC)
Inspire ID: 1315949
Status: VALIDATED
Authors:
  • Deepak Kar
References: Beams: p+ p+
Beam energies: (3500.0, 3500.0) GeV
Run details:
  • p + p -> Z + X ( Z -> mu^+ mu^- or e^+ e^- ) at 7 TeV

Charged-particle distributions sensitive to the properties of the underlying event are measured for an inclusive sample of events containing a $Z$-boson, decaying to an electron or muon pair. The measurement is based on data collected using the ATLAS detector at the LHC in proton--proton collisions at a centre-of-mass energy of 7 TeV with an integrated luminosity of 4.6 fb$^{-1}$. Distributions of the charged particle multiplicity and of the charged particle transverse momentum are measured in regions of azimuthal angle defined with respect to the $Z$-boson direction.

Source code: ATLAS_2014_I1315949.cc
  1// -*- C++ -*-
  2#include "Rivet/Analysis.hh"
  3#include "Rivet/Projections/FinalState.hh"
  4#include "Rivet/Projections/ChargedFinalState.hh"
  5#include "Rivet/Projections/DileptonFinder.hh"
  6
  7namespace Rivet {
  8
  9
 10  class ATLAS_2014_I1315949 : public Analysis {
 11  public:
 12
 13    /// Constructor
 14    RIVET_DEFAULT_ANALYSIS_CTOR(ATLAS_2014_I1315949);
 15
 16    void init() {
 17
 18      DileptonFinder zfinder(91.2*GeV, 0.1, Cuts::abseta < 2.4 && Cuts::pT > 20*GeV && Cuts::abspid == PID::MUON, Cuts::massIn(66*GeV, 116*GeV));
 19      declare(zfinder, "DileptonFinder");
 20
 21      ChargedFinalState cfs( zfinder.remainingFinalState() );
 22      declare(cfs, "cfs");
 23
 24
 25      book(_h_pTsum_tow    , 67, 1, 1);
 26      book(_h_pTsum_trv    , 68, 1, 1);
 27      book(_h_pTsum_away   , 69, 1, 1);
 28      book(_h_pTsum_tmin   , 70, 1, 1);
 29      book(_h_pTsum_tmax   , 71, 1, 1);
 30      book(_h_pTsum_tdif   ,125, 1, 1);
 31
 32      book(_h_Nchg_tow     , 72, 1, 1);
 33      book(_h_Nchg_trv     , 73, 1, 1);
 34      book(_h_Nchg_away    , 74, 1, 1);
 35      book(_h_Nchg_tmin    , 75, 1, 1);
 36      book(_h_Nchg_tmax    , 82, 1, 1);
 37      book(_h_Nchg_tdif    ,126, 1, 1);
 38
 39      book(_h_pTavg_tow    ,113, 1, 1);
 40      book(_h_pTavg_trv    ,114, 1, 1);
 41      book(_h_pTavg_away   ,115, 1, 1);
 42
 43      book(_h_pTavgvsmult_tow , 116, 1, 1);
 44      book(_h_pTavgvsmult_trv , 117, 1, 1);
 45      book(_h_pTavgvsmult_away, 118, 1, 1);
 46
 47
 48      // Book sumpt and nch histos
 49      for (size_t id = 0; id < 6.; ++id) {
 50        book(_h_ptSum_1D[0][id], 76 + id, 1, 1);
 51        book(_h_ptSum_1D[1][id],107 + id, 1, 1);
 52        book(_h_ptSum_1D[2][id],119 + id, 1, 1);
 53        book(_h_ptSum_1D[3][id],127 + id, 1, 1);
 54        book(_h_Nchg_1D[0][id],  83 + id, 1, 1);
 55        book(_h_Nchg_1D[1][id],  89 + id, 1, 1);
 56        book(_h_Nchg_1D[2][id],  95 + id, 1, 1);
 57        book(_h_Nchg_1D[3][id], 101 + id, 1, 1);
 58      }
 59    }
 60
 61
 62    /// Perform the per-event analysis
 63    void analyze(const Event& event) {
 64
 65      const DileptonFinder& zfinder = apply<DileptonFinder>(event, "DileptonFinder");
 66
 67      if (zfinder.bosons().size() != 1) vetoEvent;
 68
 69      double  Zpt   = zfinder.bosons()[0].momentum().pT()/GeV;
 70      double  Zphi  = zfinder.bosons()[0].momentum().phi(MINUSPI_PLUSPI);
 71      double  Zmass = zfinder.bosons()[0].momentum().mass()/GeV;
 72      if(Zmass < 66. || Zmass > 116.) vetoEvent;
 73
 74      // Initialise counters for Nch and sumPt for all regions
 75      int nTowards(0), nTransverse(0), nLeft(0), nRight(0), nTrmin(0), nTrmax(0), nAway(0);
 76      double ptSumTowards(0.0), ptSumTransverse(0.0), ptSumLeft(0.0), ptSumRight(0.0),
 77             ptSumTrmin(0.0), ptSumTrmax(0.0), ptSumAway(0.0);
 78
 79      // The charged particles
 80      Particles particles = apply<ChargedFinalState>(event, "cfs").particlesByPt(
 81          Cuts::pT > 0.5*GeV && Cuts::abseta <2.5);
 82
 83      // Loop over charged particles with pT>500 MeV and |eta|<2.5
 84      for (const Particle& p : particles) {
 85        double dphi = p.momentum().phi(MINUSPI_PLUSPI) - Zphi;
 86        double pT   = p.momentum().pT();
 87
 88        // Get multiples of 2pi right
 89        for(; std::fabs(dphi) > M_PI; dphi += (dphi > 0. ? -2.*M_PI : 2.*M_PI) );
 90
 91        // Towards region
 92        if( std::fabs(dphi) < M_PI/3. ) {
 93          nTowards++;
 94          ptSumTowards += pT;
 95        }
 96        // Transverse region
 97        else if( std::fabs(dphi) < 2.*M_PI/3. ) {
 98          nTransverse++;
 99          ptSumTransverse += pT;
100          if(dphi > 0.) {
101            nRight++;
102            ptSumRight += pT;
103          }
104          else {
105            nLeft++;
106            ptSumLeft += pT;
107          }
108        }
109        // Away region
110        else {
111          nAway++;
112          ptSumAway += pT;
113        }
114      }
115
116      // TransMAX, TransMIN regions
117      if (ptSumLeft > ptSumRight) {
118        ptSumTrmax = ptSumLeft;
119        ptSumTrmin = ptSumRight;
120        nTrmax     = nLeft;
121        nTrmin     = nRight;
122      }
123      else {
124        ptSumTrmax = ptSumRight;
125        ptSumTrmin = ptSumLeft;
126        nTrmax     = nRight;
127        nTrmin     = nLeft;
128      }
129
130      // min max regions have difference are than all other regions
131      const double area = 5.*2./3.*M_PI;
132
133      // Fill sumPt vs. Zpt region profiles
134      _h_pTsum_tow->fill( Zpt, ptSumTowards/area);
135      _h_pTsum_trv->fill( Zpt, ptSumTransverse/area);
136      _h_pTsum_away->fill(Zpt, ptSumAway/area);
137      _h_pTsum_tmin->fill(Zpt, ptSumTrmin/(0.5*area));
138      _h_pTsum_tmax->fill(Zpt, ptSumTrmax/(0.5*area));
139      _h_pTsum_tdif->fill(Zpt, (ptSumTrmax - ptSumTrmin)/(0.5*area));
140
141      // Fill Nch vs. Zpt region profiles
142      _h_Nchg_tow->fill( Zpt, nTowards/area);
143      _h_Nchg_trv->fill( Zpt, nTransverse/area);
144      _h_Nchg_away->fill(Zpt, nAway/area);
145      _h_Nchg_tmin->fill(Zpt, nTrmin/(0.5*area));
146      _h_Nchg_tmax->fill(Zpt, nTrmax/(0.5*area));
147      _h_Nchg_tdif->fill(Zpt, (nTrmax - nTrmin)/(0.5*area));
148
149
150      // Fill <pT> vs. ZpT profiles
151      _h_pTavg_tow->fill( Zpt, nTowards    > 0.? ptSumTowards/nTowards       : 0.);
152      _h_pTavg_trv->fill( Zpt, nTransverse > 0.? ptSumTransverse/nTransverse : 0.);
153      _h_pTavg_away->fill(Zpt, nAway       > 0.? ptSumAway/nAway             : 0.);
154
155      // Fill <Nch> vs. ZpT profiles
156      _h_pTavgvsmult_tow->fill( nTowards,    nTowards    > 0.? ptSumTowards/nTowards       : 0.);
157      _h_pTavgvsmult_trv->fill( nTransverse, nTransverse > 0.? ptSumTransverse/nTransverse : 0.);
158      _h_pTavgvsmult_away->fill(nAway,       nAway       > 0.? ptSumAway/nAway             : 0.);
159
160      // Determine Zpt region histo to fill
161      int i_bin(0);
162      if (inRange(Zpt,0,5)        ) i_bin=0;
163      if (inRange(Zpt,5,10)       ) i_bin=1;
164      if (inRange(Zpt,10,20)      ) i_bin=2;
165      if (inRange(Zpt,20,50)      ) i_bin=3;
166      if (inRange(Zpt,50,110)     ) i_bin=4;
167      if (Zpt>110) i_bin=5;
168
169      // SumPt histos for Zpt region
170      _h_ptSum_1D[0][i_bin]->fill(ptSumTowards/area);
171      _h_ptSum_1D[1][i_bin]->fill(ptSumTransverse/area);
172      _h_ptSum_1D[2][i_bin]->fill(ptSumTrmin/(0.5*area));
173      _h_ptSum_1D[3][i_bin]->fill(ptSumTrmax/(0.5*area));
174
175      // Nch histos for Zpt region
176      _h_Nchg_1D[0][i_bin]->fill(nTowards/area);
177      _h_Nchg_1D[1][i_bin]->fill(nTransverse/area);
178      _h_Nchg_1D[2][i_bin]->fill(nTrmin/(0.5*area));
179      _h_Nchg_1D[3][i_bin]->fill(nTrmax/(0.5*area));
180    }
181
182
183    /// Normalise histograms etc., after the run
184    void finalize() {
185      for(int i_reg = 0; i_reg < 4; i_reg++) {
186        for(int i_bin = 0; i_bin < 6; i_bin++) {
187          normalize( _h_ptSum_1D[i_reg][i_bin] );
188          normalize( _h_Nchg_1D[ i_reg][i_bin] );
189        }
190      }
191    }
192
193
194  private:
195
196    Profile1DPtr _h_pTsum_tow,
197                 _h_pTsum_trv,
198                 _h_pTsum_away,
199                 _h_pTsum_tmin,
200                 _h_pTsum_tmax,
201                 _h_pTsum_tdif,
202
203                 _h_Nchg_tow,
204                 _h_Nchg_trv,
205                 _h_Nchg_away,
206                 _h_Nchg_tmin,
207                 _h_Nchg_tmax,
208                 _h_Nchg_tdif,
209
210                 _h_pTavg_tow,
211                 _h_pTavg_trv,
212                 _h_pTavg_away,
213                 _h_pTavgvsmult_tow,
214                 _h_pTavgvsmult_trv,
215                 _h_pTavgvsmult_away;
216
217    Histo1DPtr   _h_ptSum_1D[4][6], _h_Nchg_1D[4][6];
218
219
220  };
221
222
223  RIVET_DECLARE_PLUGIN(ATLAS_2014_I1315949);
224
225}