13 particleID(iConfig.getParameter<int>(
"ParticleID")),
14 chargeconju(iConfig.getParameter<bool>(
"ChargeConjugation")),
15 ndaughters(iConfig.getParameter<int>(
"NumberDaughters")),
16 dauIDs(iConfig.getParameter<std::vector<int> >(
"DaughterIDs")),
17 minptcut(iConfig.getParameter<double>(
"MinPt")),
18 maxptcut(iConfig.getParameter<double>(
"MaxPt")),
19 minetacut(iConfig.getParameter<double>(
"MinEta")),
20 maxetacut(iConfig.getParameter<double>(
"MaxEta"))
40 for ( HepMC::GenEvent::particle_const_iterator
p = evt->particles_begin();
41 p != evt->particles_end(); ++
p ) {
47 if ( (*p)->end_vertex() ) {
48 for ( HepMC::GenVertex::particle_iterator
49 des=(*p)->end_vertex()->particles_begin(HepMC::children);
50 des != (*p)->end_vertex()->particles_end(HepMC::children);
54 for(
unsigned int i=0;
i<
dauIDs.size(); ++
i) {
55 if( (*des)->pdg_id() !=
dauIDs[
i] )
continue ;
56 if( (*des)->momentum().perp() >
minptcut &&
57 (*des)->momentum().perp() <
maxptcut &&
76 for ( HepMC::GenEvent::particle_const_iterator
p = evt->particles_begin();
77 p != evt->particles_end(); ++
p ) {
82 if ( (*p)->end_vertex() ) {
83 for ( HepMC::GenVertex::particle_iterator
84 des=(*p)->end_vertex()->particles_begin(HepMC::children);
85 des != (*p)->end_vertex()->particles_end(HepMC::children);
88 for(
unsigned int i=0;
i<
dauIDs.size(); ++
i) {
91 if( (*des)->pdg_id() != IDanti )
continue ;
92 if( (*des)->momentum().perp() >
minptcut &&
93 (*des)->momentum().perp() <
maxptcut &&
virtual bool filter(const HepMC::GenEvent *evt)
std::vector< int > dauIDs
GenericDauHepMCFilter(const edm::ParameterSet &)