CMS 3D CMS Logo

HeavyChHiggsToTauNuSkim.h
Go to the documentation of this file.
1 #ifndef HeavyChHiggsToTauNuSkim_h
2 #define HeavyChHiggsToTauNuSkim_h
3 
16 // system include files
17 #include <memory>
18 
19 // user include files
22 
29 
30 #include <cmath>
31 
33 public:
35  ~HeavyChHiggsToTauNuSkim() override;
36 
37  bool filter(edm::Event&, const edm::EventSetup&) override;
38 
39 private:
40  double deltaPhi(double phi1, double phi2) {
41  const double PI = 3.1415926535;
42  // in ORCA phi = [0,2pi], in TLorentzVector phi = [-pi,pi].
43  // With the conversion below deltaPhi works ok despite the
44  // 2*pi difference in phi definitions.
45  if (phi1 < 0)
46  phi1 += 2 * PI;
47  if (phi2 < 0)
48  phi2 += 2 * PI;
49 
50  double dphi = fabs(phi1 - phi2);
51 
52  if (dphi > PI)
53  dphi = 2 * PI - dphi;
54  return dphi;
55  }
56 
57  double deltaR(double eta1, double eta2, double phi1, double phi2) {
58  double dphi = deltaPhi(phi1, phi2);
59  double deta = fabs(eta1 - eta2);
60  return sqrt(dphi * dphi + deta * deta);
61  }
62 
63  bool debug;
64 
68  double jetEtMin;
69  double jetEtaMin;
70  double jetEtaMax;
71  double minDRFromTau;
72 
74 };
75 #endif
HeavyChHiggsToTauNuSkim
Definition: HeavyChHiggsToTauNuSkim.h:32
PI
Definition: PayloadInspector.h:20
CaloJetCollection.h
HeavyChHiggsToTauNuSkim::jetEtMin
double jetEtMin
Definition: HeavyChHiggsToTauNuSkim.h:68
HeavyChHiggsToTauNuSkim::minNumberOfjets
int minNumberOfjets
Definition: HeavyChHiggsToTauNuSkim.h:67
HeavyChHiggsToTauNuSkim::debug
bool debug
Definition: HeavyChHiggsToTauNuSkim.h:63
PI
#define PI
Definition: QcdUeDQM.h:37
edm::EDGetTokenT< reco::IsolatedTauTagInfoCollection >
HeavyChHiggsToTauNuSkim::minDRFromTau
double minDRFromTau
Definition: HeavyChHiggsToTauNuSkim.h:71
HeavyChHiggsToTauNuSkim::deltaR
double deltaR(double eta1, double eta2, double phi1, double phi2)
Definition: HeavyChHiggsToTauNuSkim.h:57
EDFilter.h
HeavyChHiggsToTauNuSkim::jetToken
edm::EDGetTokenT< reco::CaloJetCollection > jetToken
Definition: HeavyChHiggsToTauNuSkim.h:66
MakerMacros.h
HeavyChHiggsToTauNuSkim::nEvents
int nEvents
Definition: HeavyChHiggsToTauNuSkim.h:73
mathSSE::sqrt
T sqrt(T t)
Definition: SSEVec.h:19
HLT_FULL_cff.eta2
eta2
Definition: HLT_FULL_cff.py:9542
HLT_FULL_cff.eta1
eta1
Definition: HLT_FULL_cff.py:9541
HeavyChHiggsToTauNuSkim::deltaPhi
double deltaPhi(double phi1, double phi2)
Definition: HeavyChHiggsToTauNuSkim.h:40
edm::ParameterSet
Definition: ParameterSet.h:47
HeavyChHiggsToTauNuSkim::jetEtaMin
double jetEtaMin
Definition: HeavyChHiggsToTauNuSkim.h:69
Event.h
HeavyChHiggsToTauNuSkim::hltTauToken
edm::EDGetTokenT< reco::IsolatedTauTagInfoCollection > hltTauToken
Definition: HeavyChHiggsToTauNuSkim.h:65
HeavyChHiggsToTauNuSkim::HeavyChHiggsToTauNuSkim
HeavyChHiggsToTauNuSkim(const edm::ParameterSet &)
Definition: HeavyChHiggsToTauNuSkim.cc:25
edm::EDFilter
Definition: EDFilter.h:38
edm::EventSetup
Definition: EventSetup.h:57
InputTag.h
HeavyChHiggsToTauNuSkim::filter
bool filter(edm::Event &, const edm::EventSetup &) override
Definition: HeavyChHiggsToTauNuSkim.cc:47
HeavyChHiggsToTauNuSkim::~HeavyChHiggsToTauNuSkim
~HeavyChHiggsToTauNuSkim() override
Definition: HeavyChHiggsToTauNuSkim.cc:41
Frameworkfwd.h
HeavyChHiggsToTauNuSkim::nSelectedEvents
int nSelectedEvents
Definition: HeavyChHiggsToTauNuSkim.h:73
ParameterSet.h
IsolatedTauTagInfo.h
HeavyChHiggsToTauNuSkim::jetEtaMax
double jetEtaMax
Definition: HeavyChHiggsToTauNuSkim.h:70
edm::Event
Definition: Event.h:73