CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PartonHadronDecayGenEvtSelector.h
Go to the documentation of this file.
1 #ifndef _HI_PartonHadronDecayGenEvtSelector_h__
2 #define _HI_PartonHadronDecayGenEvtSelector_h__
3 
4 #include <vector>
6 
8 {
9  public:
12 
13  bool filter(HepMC::GenEvent *);
14  bool selectParticle(HepMC::GenParticle* par, int status, int pdg /*Absolute*/, double ptMin, double etaMax){
15  return (par->status() == status && abs(par->pdg_id()) == pdg && par->momentum().perp() > ptMin && fabs(par->momentum().eta()) < etaMax);
16  }
17  bool selectParticle(HepMC::GenParticle* par, int status, int pdg /*Absolute*/, double etaMax, double etaMin, double pMin, double ptMax, double ptMin){
18  return (par->status() == status &&
19  abs(par->pdg_id()) == pdg &&
20  par->momentum().eta() < etaMax && par->momentum().eta() > etaMin &&
21  par->momentum().rho() > pMin &&
22  par->momentum().perp() < ptMax && par->momentum().perp() > ptMin);
23  }
24 
25  private:
26 
27  std::vector<int> partonId_;
28  std::vector<int> partonStatus_;
29  std::vector<double> partonEtaMax_;
30  std::vector<double> partonPtMin_;
31 
32  std::vector<int> hadronId_;
33  std::vector<int> hadronStatus_;
34  std::vector<double> hadronEtaMax_;
35  std::vector<double> hadronEtaMin_;
36  std::vector<double> hadronPMin_;
37  std::vector<double> hadronPtMax_;
38  std::vector<double> hadronPtMin_;
39 
40  int decayId_;
42  double decayEtaMax_;
43  double decayEtaMin_;
44  double decayPMin_;
45  double decayPtMax_;
46  double decayPtMin_;
48 
49 };
50 
51 #endif
PartonHadronDecayGenEvtSelector(const edm::ParameterSet &pset)
bool selectParticle(HepMC::GenParticle *par, int status, int pdg, double etaMax, double etaMin, double pMin, double ptMax, double ptMin)
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
bool selectParticle(HepMC::GenParticle *par, int status, int pdg, double ptMin, double etaMax)
tuple status
Definition: mps_update.py:57