// -*- C++ -*- #include "Rivet/Analyses/MC_JetAnalysis.hh" #include "Rivet/Projections/ZFinder.hh" #include "Rivet/Projections/FastJets.hh" namespace Rivet { /// @brief MC validation analysis for Higgs [-> tau tau] + jets events class MC_HJETS1 : public MC_JetAnalysis { public: /// Default constructor MC_HJETS1() : MC_JetAnalysis("MC_HJETS1", 4, "Jets") { } /// @name Analysis methods //@{ /// Book histograms void init() { IdentifiedFinalState hfinder(FinalState(), 25); declare(hfinder, "Hfinder"); FastJets jetpro(VetoedFinalState(FinalState(),25), FastJets::ANTIKT, 0.4); declare(jetpro, "Jets"); book(_h_H_jet1_deta ,"H_jet1_deta", 50, -5.0, 5.0); book(_h_H_jet1_dR ,"H_jet1_dR", 25, 0.5, 7.0); MC_JetAnalysis::init(); } /// Do the analysis void analyze(const Event & e) { const FinalState& hfinder = apply(e, "Hfinder"); if (hfinder.size() != 1) vetoEvent; FourMomentum hmom(hfinder.particles()[0].momentum()); const Jets& jets = apply(e, "Jets").jetsByPt(_jetptcut); if (jets.size() > 0) { _h_H_jet1_deta->fill(hmom.eta()-jets[0].eta()); _h_H_jet1_dR->fill(deltaR(hmom, jets[0].momentum())); } MC_JetAnalysis::analyze(e); } /// Finalize void finalize() { normalize(_h_H_jet1_deta, crossSection()/picobarn); normalize(_h_H_jet1_dR, crossSection()/picobarn); MC_JetAnalysis::finalize(); } //@} private: /// @name Histograms //@{ Histo1DPtr _h_H_jet1_deta; Histo1DPtr _h_H_jet1_dR; //@} }; // The hook for the plugin system RIVET_DECLARE_PLUGIN(MC_HJETS1); }