#include <HiBasicGenTest.h>
Definition at line 21 of file HiBasicGenTest.h.
HiBasicGenTest::~HiBasicGenTest |
( |
| ) |
|
|
override |
Definition at line 59 of file HiBasicGenTest.cc.
References b, begin, ALCARECOTkAlJpsiMuMu_cff::charge, DEFINE_FWK_MODULE, end, PVValHelper::eta, edm::Event::getByToken(), edm::HepMCProduct::GetEvent(), CaloTowersParam_cfi::mc, AlCaHLTBitMon_ParallelJobs::p, HiggsValidation_cfi::pdg_id, Pi, pi, and EnergyCorrector::pt.
65 const HepMC::HeavyIon *
hi = evt->heavy_ion();
72 double ip = hi->impact_parameter();
73 phi0 = hi->event_plane_angle();
80 if(ip < 5.045) cbin=0;
81 else if (ip < 7.145 && ip > 5.045) cbin=1;
82 else if (ip < 15.202 && ip > 14.283) cbin=2;
90 HepMC::GenEvent::particle_const_iterator
begin = evt->particles_begin();
91 HepMC::GenEvent::particle_const_iterator
end = evt->particles_end();
92 for(HepMC::GenEvent::particle_const_iterator it = begin; it !=
end; ++it){
95 if((*it)->status() != 1)
continue;
98 int pdg_id = (*it)->pdg_id();
100 int charge =
static_cast<int>(part->charge());
101 if(charge==0)
continue;
103 float eta = (*it)->momentum().eta();
104 float phi = (*it)->momentum().phi();
105 float pt = (*it)->momentum().perp();
112 if(p > pi) p = p - 2*
pi;
113 if(p < -1*pi) p = p + 2*
pi;
bool getByToken(EDGetToken token, Handle< PROD > &result) const
edm::EDGetTokenT< edm::HepMCProduct > generatorToken_
MonitorElement * dnchdpt[3]
edm::ESHandle< ParticleDataTable > pdt
MonitorElement * dnchdeta[3]
MonitorElement * dnchdphi[3]
HepPDT::ParticleData ParticleData
const HepMC::GenEvent * GetEvent() const
Setting the DQM top directories
Booking the ME's
Definition at line 25 of file HiBasicGenTest.cc.
References b, DQMStore::IBooker::book1D(), DQMStore::IBooker::setCurrentFolder(), and DQMStore::IBooker::tag().
32 for (
int ibin = 0; ibin < 3; ibin++) {
33 dnchdeta[ibin] = ibooker.
book1D(Form(
"dnchdeta%d", ibin),
";#eta;dN^{ch}/d#eta",
36 dnchdpt[ibin] = ibooker.
book1D(Form(
"dnchdpt%d", ibin),
";p_{T};dN^{ch}/dp_{T}",
39 b[ibin] = ibooker.
book1D(Form(
"b%d",ibin),
";b[fm];events", 100, 0.0, 20.0);
40 dnchdphi[ibin] = ibooker.
book1D(Form(
"dnchdphi%d", ibin),
";#phi;dN^{ch}/d#phi",
45 ibooker.
tag(
b[ibin], 3+ibin*4);
49 rp = ibooker.
book1D(
"phi0",
";#phi_{RP};events", 100, -3.2, 3.2);
MonitorElement * dnchdpt[3]
void setCurrentFolder(std::string const &fullpath)
MonitorElement * dnchdeta[3]
MonitorElement * dnchdphi[3]
MonitorElement * book1D(Args &&...args)
void tag(MonitorElement *, unsigned int)