1 #ifndef JetCombinatorics_h
2 #define JetCombinatorics_h
15 #include "TLorentzVector.h"
47 void SetWp(
const TLorentzVector& Wp) {
Wp_ = Wp; }
48 void SetWq(
const TLorentzVector& Wq) {
Wq_ = Wq; }
65 hdisc_b_ = (TH1F*) gDirectory->Get(
"hdiscNorm_b");
66 hdisc_cl_ = (TH1F*) gDirectory->Get(
"hdiscNorm_cl");
123 chi2_ = chiHadW*chiHadW + chiHadt*chiHadt + chiLept*chiLept;
137 double LR_Wp;
double LR_Wq;
138 double LR_Hadb;
double LR_Lepb;
142 if (LR_den == 0 ) LR_Wp = 1
e-5;
146 if (LR_den == 0 ) LR_Wq = 1
e-5;
150 if (LR_den == 0 ) LR_Hadb = 1
e-5;
154 if (LR_den == 0 ) LR_Lepb = 1
e-5;
157 double btag_norm = (-0.25-TMath::Log(4)/2);
158 double btag_N2LL = btag_norm*4.*( LR_Wp * TMath::Log(LR_Wp/4) + LR_Wq*TMath::Log(LR_Wq/4) + LR_Hadb*TMath::Log(LR_Hadb/4) + LR_Lepb*TMath::Log(LR_Lepb/4) );
160 chi2_ += btag_N2LL + gauss_norm;
187 std::cout <<
" jet Wp : px = " <<
Wp_.Px() <<
" py = " <<
Wp_.Py() <<
" pz = " <<
Wp_.Pz() <<
" e = " <<
Wp_.E() << std::endl;
188 std::cout <<
" jet Wq : px = " <<
Wq_.Px() <<
" py = " <<
Wq_.Py() <<
" pz = " <<
Wq_.Pz() <<
" e = "<<
Wq_.E() << std::endl;
196 if ( flavor ==
"b" ) hpdf =
hdisc_b_;
198 int bin = hpdf->GetXaxis()->FindBin( disc );
199 pdf = hpdf->GetBinContent( bin );
200 if ( disc < -10 || disc >50 )
return 0;
312 std::vector< TLorentzVector >
TwoCombos();
void SetMinMassHadW(double mass)
void UseMtopConstraint(bool option=true)
bool operator()(const Combo &s1, const Combo &s2) const
void SetLeptonicW(const TLorentzVector &LepW)
static const std::string LepW
void UsebTagging(bool option=true)
std::vector< double > flavorCorrections_
void FourJetsCombinations(const std::vector< TLorentzVector > &jets, const std::vector< double > &bdiscriminators)
void SetLepb_disc(double disc)
void SetMaxMassLepW(double mass)
std::map< int, std::string > Template5jCombos_
void SetbDiscPdf(const TString &filename)
void SetMinMassLepTop(double mass)
std::map< int, std::string > Combinatorics(int k, int max=6)
bool operator()(const Combo &s1, const Combo &s2) const
TLorentzVector GetTopPair()
void ApplyFlavorCorrections(bool option=true)
std::vector< TLorentzVector > GetComposites()
std::map< Combo, int, minChi2 > allCombos_
std::vector< TLorentzVector > ThreeCombos()
void SetFlvCorrLepb(double corr)
void UseMtopConstraint(bool option=true)
std::vector< TLorentzVector > TwoCombos()
void SetFlavorCorrections(const std::vector< double > &vector)
std::vector< TLorentzVector > cand3_
void SetWp_disc(double disc)
void ApplyFlavorCorrection(bool option=true)
void SetMaxMassLepW(double mass)
void SetHadb_disc(double disc)
void SetFlvCorrWq(double corr)
std::vector< TLorentzVector > cand1_
std::map< int, std::string > NestedCombinatorics()
void SetLepb(const TLorentzVector &Lepb)
const T & max(const T &a, const T &b)
void SetWq(const TLorentzVector &Wq)
void SetMaxMassHadW(double mass)
TLorentzVector GetHadTop()
Combo GetCombination(int n=0)
void RemoveDuplicates(bool option)
void SetHadb(const TLorentzVector &Hadb)
void SetMinMassLepW(double mass)
void SetMinMassLepTop(double mass)
std::map< Combo, int, maxSumEt > allCombosSumEt_
std::map< int, std::string > Template4jCombos_
void SetFlvCorrWp(double corr)
Combo GetCombinationSumEt(int n=0)
void SetMaxMassLepTop(double mass)
void SetMaxMassLepTop(double mass)
double getPdfValue(std::string flavor, double disc)
void SetWq_disc(double disc)
void SetbTagPdf(const TString &name)
void SetFlvCorrHadb(double corr)
void SetMinMassLepW(double mass)
void SetLepW(const TLorentzVector &LepW)
TLorentzVector GetLepTop()
void Usebtagging(bool option=true)
void SetMinMassHadW(double mass)
std::map< int, std::string > Template7jCombos_
void SetSigmas(int type=0)
std::vector< TLorentzVector > cand2_
std::map< int, std::string > Template6jCombos_
void SetSigmas(int type=0)
void SetWp(const TLorentzVector &Wp)
void SetMaxMassHadW(double mass)