Rivet: /Users/chrisg/software/rivet/include/Rivet/Projections/AtlasCommon.hh Source File

| Rivet 3.1.9

AtlasCommon.hh
1// -*- C++ -*-
2#ifndef RIVET_ATLAS_COMMON_HH
3#define RIVET_ATLAS_COMMON_HH
4
5#include "Rivet/Projections/FinalState.hh"
6#include "Rivet/Projections/ChargedFinalState.hh"
7#include "Rivet/Projections/SingleValueProjection.hh"
8#include "Rivet/Projections/TriggerProjection.hh"
9
10namespace Rivet {
12
13 namespace ATLAS {
14
15
17 class SumET_PB_Centrality: public SingleValueProjection {
18 public:
19
21 SumET_PB_Centrality() {
22 declare(FinalState(Cuts::eta < -3.2 && Cuts::eta > -4.9 && Cuts::pT > 0.1*GeV),
23 "SumET_PB_Centrality");
24 }
25
27 DEFAULT_RIVET_PROJ_CLONE(SumET_PB_Centrality);
28
30 using Projection::operator =;
31
32 protected:
33
35 void project(const Event& e) {
36 clear();
37 const FinalState & fsfwd =
38 apply<FinalState>(e, "SumET_PB_Centrality");
39 double estimate = 0.0;
40 for ( const Particle & p : fsfwd.particles() ) {
41 estimate += p.Et();
42 }
43 set(estimate);
44 }
45
47 CmpState compare(const Projection& p) const {
48 return mkNamedPCmp(p, "SumET_PB_Centrality");
49 }
50
51 };
52
53
54
56 class SumET_PBPB_Centrality: public SingleValueProjection {
57 public:
58
60 SumET_PBPB_Centrality() {
61 declare(FinalState(Cuts::abseta > 3.2 && Cuts::abseta < 4.9 && Cuts::pT > 0.1*GeV),
62 "SumET_PBPB_Centrality");
63 }
64
66 DEFAULT_RIVET_PROJ_CLONE(SumET_PBPB_Centrality);
67
69 using Projection::operator =;
70
71 protected:
72
74 void project(const Event& e) {
75 clear();
76 const FinalState & fsfwd =
77 apply<FinalState>(e, "SumET_PBPB_Centrality");
78 double estimate = 0.0;
79 for ( const Particle & p : fsfwd.particles() ) {
80 estimate += p.Et();
81 }
82 set(estimate);
83 }
84
86 CmpState compare(const Projection& p) const {
87 return mkNamedPCmp(p, "SumET_PBPB_Centrality");
88 }
89
90 };
91
92
93
95 class MinBiasTrigger: public TriggerProjection {
96 public:
97
99 MinBiasTrigger() {
100 declare(ChargedFinalState(Cuts::eta > 2.09 && Cuts::eta < 3.84 &&
101 Cuts::pT > 0.1*GeV), "MBB");
102 declare(ChargedFinalState(Cuts::eta < -2.09 && Cuts::eta > -3.84 &&
103 Cuts::pT > 0.1*GeV), "MBF");
104 }
105
107 DEFAULT_RIVET_PROJ_CLONE(MinBiasTrigger);
108
110 using Projection::operator =;
111
112 protected:
113
115 void project(const Event& event) {
116 pass();
117 if ( applyProjection<FinalState>(event,"MBF").particles().empty() ||
118 applyProjection<FinalState>(event,"MBB").particles().empty() )
119 fail();
120 }
121
123 CmpState compare(const Projection& p) const {
124 return mkNamedPCmp(p, "MBF") || mkNamedPCmp(p, "MBB");
125 }
126
127 };
128
129
130 }
131}
132
133#endif
Rivet::ATLAS::MinBiasTrigger
ATLAS min bias trigger conditions.
Definition AtlasCommon.hh:95
Rivet::ATLAS::MinBiasTrigger::compare
CmpState compare(const Projection &p) const
Compare projections.
Definition AtlasCommon.hh:123
Rivet::ATLAS::MinBiasTrigger::MinBiasTrigger
MinBiasTrigger()
Constructor.
Definition AtlasCommon.hh:99
Rivet::ATLAS::MinBiasTrigger::project
void project(const Event &event)
Perform the projection on the Event.
Definition AtlasCommon.hh:115
Rivet::ATLAS::MinBiasTrigger::DEFAULT_RIVET_PROJ_CLONE
DEFAULT_RIVET_PROJ_CLONE(MinBiasTrigger)
Clone on the heap.
Rivet::ATLAS::SumET_PBPB_Centrality
Centrality projection for PbPb collisions (two sided)
Definition AtlasCommon.hh:56
Rivet::ATLAS::SumET_PBPB_Centrality::SumET_PBPB_Centrality
SumET_PBPB_Centrality()
Constructor.
Definition AtlasCommon.hh:60
Rivet::ATLAS::SumET_PBPB_Centrality::project
void project(const Event &e)
Perform the projection on the Event.
Definition AtlasCommon.hh:74
Rivet::ATLAS::SumET_PBPB_Centrality::compare
CmpState compare(const Projection &p) const
Compare projections.
Definition AtlasCommon.hh:86
Rivet::ATLAS::SumET_PBPB_Centrality::DEFAULT_RIVET_PROJ_CLONE
DEFAULT_RIVET_PROJ_CLONE(SumET_PBPB_Centrality)
Clone on the heap.
Rivet::ATLAS::SumET_PB_Centrality
Centrality projection for pPb collisions (one sided)
Definition AtlasCommon.hh:17
Rivet::ATLAS::SumET_PB_Centrality::compare
CmpState compare(const Projection &p) const
Compare projections.
Definition AtlasCommon.hh:47
Rivet::ATLAS::SumET_PB_Centrality::SumET_PB_Centrality
SumET_PB_Centrality()
Constructor.
Definition AtlasCommon.hh:21
Rivet::ATLAS::SumET_PB_Centrality::project
void project(const Event &e)
Perform the projection on the Event.
Definition AtlasCommon.hh:35
Rivet::ATLAS::SumET_PB_Centrality::DEFAULT_RIVET_PROJ_CLONE
DEFAULT_RIVET_PROJ_CLONE(SumET_PB_Centrality)
Clone on the heap.
Rivet::ChargedFinalState
Project only charged final state particles.
Definition ChargedFinalState.hh:11
Rivet::Event
Representation of a HepMC event, and enabler of Projection caching.
Definition Event.hh:22
Rivet::FinalState
Project out all final-state particles in an event. Probably the most important projection in Rivet!
Definition FinalState.hh:12
Rivet::ParticleFinder::particles
virtual const Particles & particles() const
Get the particles in no particular order, with no cuts.
Definition ParticleFinder.hh:52
Rivet::Particle
Particle representation, either from a HepMC::GenEvent or reconstructed.
Definition Particle.hh:53
Rivet::ProjectionApplier::declare
const PROJ & declare(const PROJ &proj, const std::string &name)
Register a contained projection (user-facing version)
Definition ProjectionApplier.hh:170
Rivet::Projection
Base class for all Rivet projections.
Definition Projection.hh:29
Rivet::Projection::mkNamedPCmp
Cmp< Projection > mkNamedPCmp(const Projection &otherparent, const std::string &pname) const
Rivet::SingleValueProjection
Base class for projections returning a single floating point value.
Definition SingleValueProjection.hh:17
Rivet::SingleValueProjection::set
void set(double v)
Definition SingleValueProjection.hh:55
Rivet::SingleValueProjection::clear
void clear()
Unset the value.
Definition SingleValueProjection.hh:58
Rivet::TriggerProjection
Base class for projections returning a bool corresponding to a trigger.
Definition TriggerProjection.hh:17
Rivet::TriggerProjection::fail
void fail()
Indicate that the event has failed the trigger.
Definition TriggerProjection.hh:56
Rivet::TriggerProjection::pass
void pass()
Indicate that the event has passed the trigger.
Definition TriggerProjection.hh:46
Rivet::Kin::p
double p(const ParticleBase &p)
Unbound function access to p.
Definition ParticleBaseUtils.hh:684
Rivet
Definition MC_Cent_pPb.hh:10