rivet is hosted by Hepforge, IPPP Durham

Rivet analyses reference

MC_PHOTONINC

Monte Carlo validation observables for single isolated photon production
Experiment: ()
Status: VALIDATED
Authors:
  • Frank Siegert
No references listed
Beams: * *
Beam energies: ANY
Run details:
  • Tevatron Run II ppbar -> gamma + jets.

Monte Carlo validation observables for single isolated photon production

Source code: MC_PHOTONINC.cc
  1// -*- C++ -*-
  2#include "Rivet/Analysis.hh"
  3#include "Rivet/Projections/LeadingParticlesFinalState.hh"
  4#include "Rivet/Projections/VetoedFinalState.hh"
  5
  6namespace Rivet {
  7
  8  
  9
 10
 11  /// @brief MC validation analysis for single photon events
 12  class MC_PHOTONINC : public Analysis {
 13  public:
 14
 15    /// Default constructor
 16    MC_PHOTONINC()
 17      : Analysis("MC_PHOTONINC")
 18    {    }
 19
 20
 21    /// @name Analysis methods
 22    //@{
 23
 24    /// Book histograms
 25    void init() {
 26      // General FS
 27      FinalState fs((Cuts::etaIn(-5.0, 5.0)));
 28      declare(fs, "FS");
 29
 30      // Get leading photon
 31      LeadingParticlesFinalState photonfs(FinalState(Cuts::abseta < 2.5 && Cuts::pT >=  30*GeV));
 32      photonfs.addParticleId(PID::PHOTON);
 33      declare(photonfs, "LeadingPhoton");
 34
 35      // FS for isolation excludes the leading photon
 36      VetoedFinalState vfs(fs);
 37      vfs.addVetoOnThisFinalState(photonfs);
 38      declare(vfs, "JetFS");
 39
 40      book(_h_photon_pT ,"photon_pT", logspace(50, 30.0, 0.5*(sqrtS()>0.?sqrtS():14000.)));
 41      book(_h_photon_pT_lin ,"photon_pT_lin", 50, 0.0, 70.0);
 42      book(_h_photon_y ,"photon_y", 50, -5.0, 5.0);
 43    }
 44
 45
 46    /// Do the analysis
 47    void analyze(const Event& e) {
 48      // Get the photon
 49      const Particles photons = apply<FinalState>(e, "LeadingPhoton").particles();
 50      if (photons.size() != 1) {
 51        vetoEvent;
 52      }
 53      const FourMomentum photon = photons.front().momentum();
 54
 55      // Get all charged particles
 56      const FinalState& fs = apply<FinalState>(e, "JetFS");
 57      if (fs.empty()) {
 58        vetoEvent;
 59      }
 60
 61      // Passed cuts, so get the weight
 62      const double weight = 1.0;
 63
 64      // Isolate photon by ensuring that a 0.4 cone around it contains less than 7% of the photon's energy
 65      const double egamma = photon.E();
 66      double econe = 0.0;
 67      for (const Particle& p : fs.particles()) {
 68        if (deltaR(photon, p.momentum()) < 0.4) {
 69          econe += p.E();
 70          // Veto as soon as E_cone gets larger
 71          if (econe/egamma > 0.07) {
 72            vetoEvent;
 73          }
 74        }
 75      }
 76
 77      _h_photon_pT->fill(photon.pT(),weight);
 78      _h_photon_pT_lin->fill(photon.pT(),weight);
 79      _h_photon_y->fill(photon.rapidity(),weight);
 80    }
 81
 82
 83    // Finalize
 84    void finalize() {
 85      scale(_h_photon_pT, crossSectionPerEvent());
 86      scale(_h_photon_pT_lin, crossSectionPerEvent());
 87      scale(_h_photon_y, crossSectionPerEvent());
 88    }
 89
 90    //@}
 91
 92
 93  private:
 94
 95    /// @name Histograms
 96    //@{
 97    Histo1DPtr _h_photon_pT;
 98    Histo1DPtr _h_photon_pT_lin;
 99    Histo1DPtr _h_photon_y;
100    //@}
101
102  };
103
104
105
106  // The hook for the plugin system
107  RIVET_DECLARE_PLUGIN(MC_PHOTONINC);
108
109}