1 #ifndef BASICHEPMCVALIDATION_H 2 #define BASICHEPMCVALIDATION_H 59 name +
"Number",
"Number of " +
name +
"'s per event", 20, 0, 20,
"No. of " +
name,
"Number of Events");
62 "Number of " +
name +
"'s per event",
66 "log_{10}(No. of " +
name +
")",
70 "log_{10}(P) of the " +
name +
"s",
74 "log_{10}(P) (log_{10}(GeV))",
77 eta_init =
dqm.book1dHisto(
name +
"Eta",
"#eta of the " +
name +
"s", 100, -5., 5.,
"#eta",
"Number of " +
name);
80 "#phi of the " +
name +
"s",
84 "Log_{10}(life-time^{final}) (log_{10}(s))",
88 "log_{10}(P^{final}) of " +
name +
"s at end of decay chain",
92 "log_{10}(P^{final}) (log_{10}(GeV))",
96 "Log_{10}(life-time^{final}) of " +
name +
"s at end of decay chain",
100 "Log_{10}(life-time^{final}) (log_{10}(s))",
101 "Number of " +
name);
107 if (
p->pdg_id() ==
pdgid) {
114 if (
p->production_vertex() &&
p->end_vertex()) {
115 TVector3
PV(
p->production_vertex()->point3d().x(),
116 p->production_vertex()->point3d().y(),
117 p->production_vertex()->point3d().z());
118 TVector3
SV(
p->end_vertex()->point3d().x(),
p->end_vertex()->point3d().y(),
p->end_vertex()->point3d().z());
119 TVector3 DL =
SV -
PV;
120 double c(2.99792458E8), Ltau(DL.Mag() / 100) ,
beta(
p->momentum().rho() /
p->momentum().m());
121 double lt = Ltau / (
c *
beta);
124 if (
pf->end_vertex()) {
126 pf->end_vertex()->point3d().x(),
pf->end_vertex()->point3d().y(),
pf->end_vertex()->point3d().z());
128 Ltau = DL.Mag() / 100;
129 lt = Ltau / (
c *
beta);
153 if (
p->production_vertex()) {
154 for (HepMC::GenVertex::particles_in_const_iterator
m =
p->production_vertex()->particles_in_const_begin();
155 m !=
p->production_vertex()->particles_in_const_end();
157 if (
abs((*m)->pdg_id()) ==
abs(
p->pdg_id()))
167 for (
unsigned int iMix = 0; iMix < 10; iMix++) {
168 bool foundSimilar =
false;
169 if (aPart->end_vertex()) {
170 if (aPart->end_vertex()->particles_out_size() != 0) {
171 for (HepMC::GenVertex::particles_out_const_iterator
d = aPart->end_vertex()->particles_out_const_begin();
172 d != aPart->end_vertex()->particles_out_const_end();
174 if (
abs((*d)->pdg_id()) ==
abs(aPart->pdg_id())) {
MonitorElement * genPtclStatus
MonitorElement * DeltaEcms
MonitorElement * genVrtxNumber
MonitorElement * unknownPDTNumber
MonitorElement * pdf_bbbar
MonitorElement * outVrtxPtclNumber
MonitorElement * pdf_dbar
MonitorElement * pdf_ccbar
bool isFirst(const HepMC::GenParticle *p)
MonitorElement * Bjorken_x
MonitorElement * otherPtclNumber
other ME's
void dqmBeginRun(const edm::Run &r, const edm::EventSetup &c) override
BasicHepMCValidation(const edm::ParameterSet &)
MonitorElement * parton2Id
MonitorElement * otherPtclMomentum
MonitorElement * stablePtclCharge
MonitorElement * partonNumber
edm::EDGetTokenT< edm::HepMCProduct > hepmcCollectionToken_
MonitorElement * lifetime_final
MonitorElement * vrtxRadius
~BasicHepMCValidation() override
MonitorElement * pdf_ubar
edm::ESHandle< HepPDT::ParticleDataTable > fPDGTable
PDT table.
MonitorElement * eta_init
void bookHistograms(DQMStore::IBooker &i, edm::Run const &, edm::EventSetup const &) override
MonitorElement * scalePDF
Abs< T >::type abs(const T &t)
MonitorElement * log10DeltaEcms
MonitorElement * partonpT
MonitorElement * stablePtclPhi
MonitorElement * stablePtclEta
const HepMC::GenParticle * GetFinal(const HepMC::GenParticle *p)
void analyze(edm::Event const &, edm::EventSetup const &) override
MonitorElement * stablePtclp
MonitorElement * status1ShortLived
MonitorElement * stablePtclpT
MonitorElement * stableChaNumber
ParticleMonitor(std::string name_, int pdgid_, DQMStore::IBooker &i, bool nlog_=false)
MonitorElement * stablePtclNumber
void FillCount(double weight)
bool Fill(const HepMC::GenParticle *p, double weight)
edm::ESGetToken< HepPDT::ParticleDataTable, edm::DefaultRecord > fPDGTableToken
MonitorElement * lifetime_init
MonitorElement * genPtclNumber
edm::InputTag hepmcCollection_
MonitorElement * outVrtxStablePtclNumber
MonitorElement * numberPerEvent
std::vector< ParticleMonitor > particles
MonitorElement * pdf_ssbar
MonitorElement * parton1Id