CMS 3D CMS Logo

PFTau3ProngSummary.h
Go to the documentation of this file.
1 #ifndef DataFormats_TauReco_PFTau3ProngSummary_h
2 #define DataFormats_TauReco_PFTau3ProngSummary_h
3 
4 /* class PFTau3ProngSummary
5  *
6  * Stores information on the 3 prong summary for a fully reconstructed tau lepton
7  *
8  * author: Ian M. Nugent
9  * The idea of the fully reconstructing the tau using a kinematic fit comes from
10  * Lars Perchalla and Philip Sauerland Theses under Achim Stahl supervision. This
11  * code is a result of the continuation of this work by Ian M. Nugent and Vladimir Cherepanov.
12  */
20 #include "TVector3.h"
21 #include "TLorentzVector.h"
22 #include "TMath.h"
23 
24 namespace reco {
26  public:
28  enum { dimension = 3 };
29  enum { covarianceSize = dimension * (dimension + 1) / 2 };
33 
37  TLorentzVector a1,
38  double vertex_chi2,
39  double vertex_ndf);
41  TLorentzVector a1,
42  double vertex_chi2,
43  double vertex_ndf,
44  TVector3 sv,
45  CovMatrix svcov);
46 
47  virtual ~PFTau3ProngSummary() {}
48 
49  PFTau3ProngSummary* clone() const;
50 
51  virtual bool AddSolution(unsigned int solution,
52  const TLorentzVector& tau,
53  const std::vector<TLorentzVector>& daughter_p4,
54  const std::vector<int>& daughter_charge,
55  const std::vector<int>& daughter_PDGID,
56  bool has3ProngSolution,
57  double solutionChi2,
58  double thetaGJsig);
59 
61  // interface for relevant TIP functions;
62  const VertexRef& primaryVertex() const { return TIP_->primaryVertex(); }
63  CovMatrix primaryVertexCov() const { return TIP_->primaryVertexCov(); }
64  bool hasSecondaryVertex() const { return TIP_->hasSecondaryVertex(); }
65  const VertexRef& secondaryVertex() const { return TIP_->secondaryVertex(); }
66  CovMatrix secondaryVertexCov() const { return TIP_->secondaryVertexCov(); }
67  const Vector& flightLength() const { return TIP_->flightLength(); }
68  double flightLengthSig() const { return TIP_->flightLengthSig(); }
69  CovMatrix flightLenghtCov() const { return TIP_->flightLengthCov(); }
70 
71  // Tau 3 prong functions
72  const TLorentzVector& A1_LV() const { return a1_; }
73  double M_A1() const { return a1_.M(); }
74  double M_12() const; //pi-pi-
75  double M_13() const; //pi-pi+ Dalitz masses
76  double M_23() const; //pi-pi+ Dalitz masses
77  int Tau_Charge() const;
78  const TVector3& HelixFitSecondaryVertex() const { return sv_; }
79  const CovMatrix& HelixFitSecondaryVertexCov() const { return svcov_; }
80  double Vertex_chi2() const { return vertex_chi2_; }
81  double Vertex_ndf() const { return vertex_ndf_; }
82  double Vertex_Prob() const { return TMath::Prob(vertex_chi2_, vertex_ndf_); }
83  bool has3ProngSolution(unsigned int i) const { return has3ProngSolution_[i]; }
84  double Solution_Chi2(unsigned int i) const { return solution_Chi2_[i]; }
85  double SignificanceOfThetaGJ(unsigned int i) const {
86  return thetaGJsig_[i];
87  } // 0 or less means the theta_GF has
88  // a physical solution
89  const TLorentzVector& Tau(unsigned int i) const { return tau_p4_[i]; }
90  const std::vector<int>& Daughter_PDGID(unsigned int i) const { return daughter_PDGID_[i]; }
91  const std::vector<int>& Daughter_Charge(unsigned int i) const { return daughter_charge_[i]; }
92  const std::vector<TLorentzVector>& Daughter_P4(unsigned int i) const { return daughter_p4_[i]; }
93 
94  private:
96  TLorentzVector a1_;
97  TVector3 sv_;
99  double vertex_chi2_;
100  double vertex_ndf_;
101  std::vector<bool> has3ProngSolution_;
102  std::vector<double> solution_Chi2_;
103  std::vector<double> thetaGJsig_;
104  std::vector<TLorentzVector> tau_p4_;
105  std::vector<std::vector<int> > daughter_PDGID_;
106  std::vector<std::vector<int> > daughter_charge_;
107  std::vector<std::vector<TLorentzVector> > daughter_p4_;
108  };
109 } // namespace reco
110 
111 #endif
reco::PFTau3ProngSummary::TIP_
reco::PFTauTransverseImpactParameterRef TIP_
Definition: PFTau3ProngSummary.h:95
reco::PFTau3ProngSummary::flightLenghtCov
CovMatrix flightLenghtCov() const
Definition: PFTau3ProngSummary.h:69
reco::PFTau3ProngSummary::Vertex_Prob
double Vertex_Prob() const
Definition: PFTau3ProngSummary.h:82
reco::PFTau3ProngSummary::M_A1
double M_A1() const
Definition: PFTau3ProngSummary.h:73
mps_fire.i
i
Definition: mps_fire.py:428
reco::PFTau3ProngSummary::Daughter_PDGID
const std::vector< int > & Daughter_PDGID(unsigned int i) const
Definition: PFTau3ProngSummary.h:90
reco::PFTau3ProngSummary::has3ProngSolution_
std::vector< bool > has3ProngSolution_
Definition: PFTau3ProngSummary.h:101
metsig::tau
Definition: SignAlgoResolutions.h:49
reco::PFTau3ProngSummary::hasSecondaryVertex
bool hasSecondaryVertex() const
Definition: PFTau3ProngSummary.h:64
reco::PFTau3ProngSummary::solution_Chi2_
std::vector< double > solution_Chi2_
Definition: PFTau3ProngSummary.h:102
reco::PFTau3ProngSummary::daughter_p4_
std::vector< std::vector< TLorentzVector > > daughter_p4_
Definition: PFTau3ProngSummary.h:107
reco::PFTau3ProngSummary::daughter_charge_
std::vector< std::vector< int > > daughter_charge_
Definition: PFTau3ProngSummary.h:106
reco::PFTau3ProngSummary::thetaGJsig_
std::vector< double > thetaGJsig_
Definition: PFTau3ProngSummary.h:103
reco::PFTau3ProngSummary::nsolutions
Definition: PFTau3ProngSummary.h:27
reco
fixed size matrix
Definition: AlignmentAlgorithmBase.h:45
reco::PFTau3ProngSummary::clone
PFTau3ProngSummary * clone() const
Definition: PFTau3ProngSummary.cc:63
reco::PFTau3ProngSummary::a1_
TLorentzVector a1_
Definition: PFTau3ProngSummary.h:96
reco::PFTau3ProngSummary
Definition: PFTau3ProngSummary.h:25
edm::Ref< PFTauTransverseImpactParameterCollection >
reco::PFTau3ProngSummary::covarianceSize
Definition: PFTau3ProngSummary.h:29
reco::PFTau3ProngSummary::minus
Definition: PFTau3ProngSummary.h:27
reco::PFTau3ProngSummary::Tau_Charge
int Tau_Charge() const
Definition: PFTau3ProngSummary.cc:158
reco::PFTau3ProngSummary::HelixFitSecondaryVertex
const TVector3 & HelixFitSecondaryVertex() const
Definition: PFTau3ProngSummary.h:78
pfDeepBoostedJetPreprocessParams_cfi.sv
sv
Definition: pfDeepBoostedJetPreprocessParams_cfi.py:352
reco::PFTau3ProngSummary::svcov_
CovMatrix svcov_
Definition: PFTau3ProngSummary.h:98
reco::PFTau3ProngSummary::tau_p4_
std::vector< TLorentzVector > tau_p4_
Definition: PFTau3ProngSummary.h:104
reco::PFTau3ProngSummary::Daughter_P4
const std::vector< TLorentzVector > & Daughter_P4(unsigned int i) const
Definition: PFTau3ProngSummary.h:92
PFTauTransverseImpactParameterFwd.h
reco::PFTau3ProngSummary::flightLength
const Vector & flightLength() const
Definition: PFTau3ProngSummary.h:67
reco::PFTau3ProngSummary::Vertex_ndf
double Vertex_ndf() const
Definition: PFTau3ProngSummary.h:81
Vertex.h
PFTauTransverseImpactParameter.h
reco::PFTau3ProngSummary::Daughter_Charge
const std::vector< int > & Daughter_Charge(unsigned int i) const
Definition: PFTau3ProngSummary.h:91
Error.h
reco::PFTau3ProngSummary::flightLengthSig
double flightLengthSig() const
Definition: PFTau3ProngSummary.h:68
math::XYZPoint
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12
reco::PFTau3ProngSummary::M_12
double M_12() const
Definition: PFTau3ProngSummary.cc:86
math::XYZVector
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:31
reco::PFTau3ProngSummary::Tau
const TLorentzVector & Tau(unsigned int i) const
Definition: PFTau3ProngSummary.h:89
reco::PFTau3ProngSummary::Solution_Chi2
double Solution_Chi2(unsigned int i) const
Definition: PFTau3ProngSummary.h:84
reco::PFTau3ProngSummary::~PFTau3ProngSummary
virtual ~PFTau3ProngSummary()
Definition: PFTau3ProngSummary.h:47
reco::PFTau3ProngSummary::PFTau3ProngSummary
PFTau3ProngSummary()
constructor from values
Definition: PFTau3ProngSummary.cc:51
reco::PFTau3ProngSummary::vertex_ndf_
double vertex_ndf_
Definition: PFTau3ProngSummary.h:100
reco::PFTau3ProngSummary::primaryVertex
const VertexRef & primaryVertex() const
Definition: PFTau3ProngSummary.h:62
reco::PFTau3ProngSummary::dimension
Definition: PFTau3ProngSummary.h:28
reco::PFTau3ProngSummary::SignificanceOfThetaGJ
double SignificanceOfThetaGJ(unsigned int i) const
Definition: PFTau3ProngSummary.h:85
reco::PFTau3ProngSummary::Vertex_chi2
double Vertex_chi2() const
Definition: PFTau3ProngSummary.h:80
reco::PFTau3ProngSummary::ambiguity
Definition: PFTau3ProngSummary.h:27
reco::PFTau3ProngSummary::M_13
double M_13() const
Definition: PFTau3ProngSummary.cc:100
VertexFwd.h
reco::PFTau3ProngSummary::A1_LV
const TLorentzVector & A1_LV() const
Definition: PFTau3ProngSummary.h:72
reco::PFTau3ProngSummary::Point
math::XYZPoint Point
Definition: PFTau3ProngSummary.h:31
reco::PFTau3ProngSummary::vertex_chi2_
double vertex_chi2_
Definition: PFTau3ProngSummary.h:99
reco::PFTau3ProngSummary::primaryVertexCov
CovMatrix primaryVertexCov() const
Definition: PFTau3ProngSummary.h:63
reco::PFTau3ProngSummary::secondaryVertexCov
CovMatrix secondaryVertexCov() const
Definition: PFTau3ProngSummary.h:66
math::Error::type
ErrorD< N >::type type
Definition: Error.h:32
reco::PFTau3ProngSummary::PFTauTIP
const reco::PFTauTransverseImpactParameterRef & PFTauTIP() const
Definition: PFTau3ProngSummary.h:60
reco::PFTau3ProngSummary::Vector
math::XYZVector Vector
Definition: PFTau3ProngSummary.h:32
reco::PFTau3ProngSummary::M_23
double M_23() const
Definition: PFTau3ProngSummary.cc:129
Point3D.h
reco::PFTau3ProngSummary::has3ProngSolution
bool has3ProngSolution(unsigned int i) const
Definition: PFTau3ProngSummary.h:83
reco::PFTau3ProngSummary::daughter_PDGID_
std::vector< std::vector< int > > daughter_PDGID_
Definition: PFTau3ProngSummary.h:105
reco::PFTau3ProngSummary::CovMatrix
math::Error< dimension >::type CovMatrix
Definition: PFTau3ProngSummary.h:30
reco::PFTau3ProngSummary::sv_
TVector3 sv_
Definition: PFTau3ProngSummary.h:97
reco::PFTau3ProngSummary::plus
Definition: PFTau3ProngSummary.h:27
Vector3D.h
reco::PFTau3ProngSummary::AddSolution
virtual bool AddSolution(unsigned int solution, const TLorentzVector &tau, const std::vector< TLorentzVector > &daughter_p4, const std::vector< int > &daughter_charge, const std::vector< int > &daughter_PDGID, bool has3ProngSolution, double solutionChi2, double thetaGJsig)
Definition: PFTau3ProngSummary.cc:65
reco::PFTau3ProngSummary::secondaryVertex
const VertexRef & secondaryVertex() const
Definition: PFTau3ProngSummary.h:65
reco::PFTau3ProngSummary::HelixFitSecondaryVertexCov
const CovMatrix & HelixFitSecondaryVertexCov() const
Definition: PFTau3ProngSummary.h:79