void B2DBach(TString filenamearg, Bool_t plotOthers = true, Bool_t cutOnDaughters = true, Bool_t cutOnDMass = true, Bool_t cutOnEventNr = true){ ////////////////////////////////////////////////////////////////// TFile *f = (TFile*)gROOT->GetListOfFiles()->FindObject("B2DX_UP_FromHadron_6_7_2010.root");//B2DX_All_7_6_2010.root"); //if (!f) f = new TFile("/home/hep/uoh35620/stuff/stripping/MC/down/all/Bu2DStarplusX.root");//B2DX_All_7_6_2010.root"); if (!f) f = new TFile(filenamearg);//B2DX_All_7_6_2010.root"); // if (!f) f = new TFile("B2DX_UP_FromHadron_6_7_2010.root");//B2DX_All_7_6_2010.root"); // if (!f) f = new TFile("/home/hep/uoh35620/stuff/analyse-n-tuple/generated/B2DX_Up_MC_2010.root"); // if (!f) f = new TFile("/home/hep/uoh35620/stuff/analyse-n-tuple/generated/B2DX_Down_MC_2010.root"); // if (!f) f = new TFile("/home/hep/uoh35620/stuff/analyse-n-tuple/generated/B2DX_Down_FromHadron_6_7_2010_Wed Jul 14 09:08:00 BST 2010.root"); // if (!f) f = new TFile("/home/hep/uoh35620/stuff/analyse-n-tuple/given/B2DX_Down_FromHadron_18_5_2010.root"); fChain = (TTree*)gDirectory->Get("BachelorDecayTreeTuple/DecayTree"); // Declaration of leaf types Float_t B_MINIP; Float_t B_MINIPCHI2; Float_t B_OWNPV_X; Float_t B_OWNPV_Y; Float_t B_OWNPV_Z; Float_t B_OWNPV_XERR; Float_t B_OWNPV_YERR; Float_t B_OWNPV_ZERR; Float_t B_OWNPV_CHI2; Int_t B_OWNPV_NDOF; Float_t B_OWNPV_COV_[3][3]; Float_t B_IP_OWNPV; Float_t B_IPCHI2_OWNPV; Float_t B_FD_OWNPV; Float_t B_FDCHI2_OWNPV; Float_t B_DIRA_OWNPV; Float_t B_ENDVERTEX_X; Float_t B_ENDVERTEX_Y; Float_t B_ENDVERTEX_Z; Float_t B_ENDVERTEX_XERR; Float_t B_ENDVERTEX_YERR; Float_t B_ENDVERTEX_ZERR; Float_t B_ENDVERTEX_CHI2; Int_t B_ENDVERTEX_NDOF; Float_t B_ENDVERTEX_COV_[3][3]; Float_t B_P; Float_t B_PT; Float_t B_PE; Float_t B_PX; Float_t B_PY; Float_t B_PZ; Float_t B_MM; Float_t B_MMERR; Float_t B_M; Int_t B_ID; Float_t Bachelor_CosTheta; Float_t Bachelor_MINIP; Float_t Bachelor_MINIPCHI2; Float_t Bachelor_OWNPV_X; Float_t Bachelor_OWNPV_Y; Float_t Bachelor_OWNPV_Z; Float_t Bachelor_OWNPV_XERR; Float_t Bachelor_OWNPV_YERR; Float_t Bachelor_OWNPV_ZERR; Float_t Bachelor_OWNPV_CHI2; Int_t Bachelor_OWNPV_NDOF; Float_t Bachelor_OWNPV_COV_[3][3]; Float_t Bachelor_IP_OWNPV; Float_t Bachelor_IPCHI2_OWNPV; Float_t Bachelor_ORIVX_X; Float_t Bachelor_ORIVX_Y; Float_t Bachelor_ORIVX_Z; Float_t Bachelor_ORIVX_XERR; Float_t Bachelor_ORIVX_YERR; Float_t Bachelor_ORIVX_ZERR; Float_t Bachelor_ORIVX_CHI2; Int_t Bachelor_ORIVX_NDOF; Float_t Bachelor_ORIVX_COV_[3][3]; Float_t Bachelor_P; Float_t Bachelor_PT; Float_t Bachelor_PE; Float_t Bachelor_PX; Float_t Bachelor_PY; Float_t Bachelor_PZ; Float_t Bachelor_MM; Float_t Bachelor_M; Int_t Bachelor_ID; Float_t Bachelor_PIDe; Float_t Bachelor_PIDmu; Float_t Bachelor_PIDK; Float_t Bachelor_PIDp; Float_t Bachelor_CaloEcalE; Float_t Bachelor_CaloHcalE; Int_t Bachelor_hasMuon; Int_t Bachelor_isMuon; Int_t Bachelor_hasRich; Int_t Bachelor_hasCalo; Int_t Bachelor_TRACK_Type; Float_t Bachelor_TRACK_CHI2NDOF; Float_t Bachelor_TRACK_PCHI2; Float_t Bachelor_TRACK_GhostProb; Float_t Bachelor_TRACK_CloneDist; Float_t D_CosTheta; Float_t D_MINIP; Float_t D_MINIPCHI2; Float_t D_OWNPV_X; Float_t D_OWNPV_Y; Float_t D_OWNPV_Z; Float_t D_OWNPV_XERR; Float_t D_OWNPV_YERR; Float_t D_OWNPV_ZERR; Float_t D_OWNPV_CHI2; Int_t D_OWNPV_NDOF; Float_t D_OWNPV_COV_[3][3]; Float_t D_IP_OWNPV; Float_t D_IPCHI2_OWNPV; Float_t D_FD_OWNPV; Float_t D_FDCHI2_OWNPV; Float_t D_DIRA_OWNPV; Float_t D_ORIVX_X; Float_t D_ORIVX_Y; Float_t D_ORIVX_Z; Float_t D_ORIVX_XERR; Float_t D_ORIVX_YERR; Float_t D_ORIVX_ZERR; Float_t D_ORIVX_CHI2; Int_t D_ORIVX_NDOF; Float_t D_ORIVX_COV_[3][3]; Float_t D_FD_ORIVX; Float_t D_FDCHI2_ORIVX; Float_t D_DIRA_ORIVX; Float_t D_ENDVERTEX_X; Float_t D_ENDVERTEX_Y; Float_t D_ENDVERTEX_Z; Float_t D_ENDVERTEX_XERR; Float_t D_ENDVERTEX_YERR; Float_t D_ENDVERTEX_ZERR; Float_t D_ENDVERTEX_CHI2; Int_t D_ENDVERTEX_NDOF; Float_t D_ENDVERTEX_COV_[3][3]; Float_t D_P; Float_t D_PT; Float_t D_PE; Float_t D_PX; Float_t D_PY; Float_t D_PZ; Float_t D_MM; Float_t D_MMERR; Float_t D_M; Int_t D_ID; Float_t Negative_D_Daughter_CosTheta; Float_t Negative_D_Daughter_MINIP; Float_t Negative_D_Daughter_MINIPCHI2; Float_t Negative_D_Daughter_OWNPV_X; Float_t Negative_D_Daughter_OWNPV_Y; Float_t Negative_D_Daughter_OWNPV_Z; Float_t Negative_D_Daughter_OWNPV_XERR; Float_t Negative_D_Daughter_OWNPV_YERR; Float_t Negative_D_Daughter_OWNPV_ZERR; Float_t Negative_D_Daughter_OWNPV_CHI2; Int_t Negative_D_Daughter_OWNPV_NDOF; Float_t Negative_D_Daughter_OWNPV_COV_[3][3]; Float_t Negative_D_Daughter_IP_OWNPV; Float_t Negative_D_Daughter_IPCHI2_OWNPV; Float_t Negative_D_Daughter_ORIVX_X; Float_t Negative_D_Daughter_ORIVX_Y; Float_t Negative_D_Daughter_ORIVX_Z; Float_t Negative_D_Daughter_ORIVX_XERR; Float_t Negative_D_Daughter_ORIVX_YERR; Float_t Negative_D_Daughter_ORIVX_ZERR; Float_t Negative_D_Daughter_ORIVX_CHI2; Int_t Negative_D_Daughter_ORIVX_NDOF; Float_t Negative_D_Daughter_ORIVX_COV_[3][3]; Float_t Negative_D_Daughter_P; Float_t Negative_D_Daughter_PT; Float_t Negative_D_Daughter_PE; Float_t Negative_D_Daughter_PX; Float_t Negative_D_Daughter_PY; Float_t Negative_D_Daughter_PZ; Float_t Negative_D_Daughter_MM; Float_t Negative_D_Daughter_M; Int_t Negative_D_Daughter_ID; Float_t Negative_D_Daughter_PIDe; Float_t Negative_D_Daughter_PIDmu; Float_t Negative_D_Daughter_PIDK; Float_t Negative_D_Daughter_PIDp; Float_t Negative_D_Daughter_CaloEcalE; Float_t Negative_D_Daughter_CaloHcalE; Int_t Negative_D_Daughter_hasMuon; Int_t Negative_D_Daughter_isMuon; Int_t Negative_D_Daughter_hasRich; Int_t Negative_D_Daughter_hasCalo; Int_t Negative_D_Daughter_TRACK_Type; Float_t Negative_D_Daughter_TRACK_CHI2NDOF; Float_t Negative_D_Daughter_TRACK_PCHI2; Float_t Negative_D_Daughter_TRACK_GhostProb; Float_t Negative_D_Daughter_TRACK_CloneDist; Float_t Positive_D_Daughter_CosTheta; Float_t Positive_D_Daughter_MINIP; Float_t Positive_D_Daughter_MINIPCHI2; Float_t Positive_D_Daughter_OWNPV_X; Float_t Positive_D_Daughter_OWNPV_Y; Float_t Positive_D_Daughter_OWNPV_Z; Float_t Positive_D_Daughter_OWNPV_XERR; Float_t Positive_D_Daughter_OWNPV_YERR; Float_t Positive_D_Daughter_OWNPV_ZERR; Float_t Positive_D_Daughter_OWNPV_CHI2; Int_t Positive_D_Daughter_OWNPV_NDOF; Float_t Positive_D_Daughter_OWNPV_COV_[3][3]; Float_t Positive_D_Daughter_IP_OWNPV; Float_t Positive_D_Daughter_IPCHI2_OWNPV; Float_t Positive_D_Daughter_ORIVX_X; Float_t Positive_D_Daughter_ORIVX_Y; Float_t Positive_D_Daughter_ORIVX_Z; Float_t Positive_D_Daughter_ORIVX_XERR; Float_t Positive_D_Daughter_ORIVX_YERR; Float_t Positive_D_Daughter_ORIVX_ZERR; Float_t Positive_D_Daughter_ORIVX_CHI2; Int_t Positive_D_Daughter_ORIVX_NDOF; Float_t Positive_D_Daughter_ORIVX_COV_[3][3]; Float_t Positive_D_Daughter_P; Float_t Positive_D_Daughter_PT; Float_t Positive_D_Daughter_PE; Float_t Positive_D_Daughter_PX; Float_t Positive_D_Daughter_PY; Float_t Positive_D_Daughter_PZ; Float_t Positive_D_Daughter_MM; Float_t Positive_D_Daughter_M; Int_t Positive_D_Daughter_ID; Float_t Positive_D_Daughter_PIDe; Float_t Positive_D_Daughter_PIDmu; Float_t Positive_D_Daughter_PIDK; Float_t Positive_D_Daughter_PIDp; Float_t Positive_D_Daughter_CaloEcalE; Float_t Positive_D_Daughter_CaloHcalE; Int_t Positive_D_Daughter_hasMuon; Int_t Positive_D_Daughter_isMuon; Int_t Positive_D_Daughter_hasRich; Int_t Positive_D_Daughter_hasCalo; Int_t Positive_D_Daughter_TRACK_Type; Float_t Positive_D_Daughter_TRACK_CHI2NDOF; Float_t Positive_D_Daughter_TRACK_PCHI2; Float_t Positive_D_Daughter_TRACK_GhostProb; Float_t Positive_D_Daughter_TRACK_CloneDist; Int_t nCandidate; Int_t totCandidates; Int_t EventInSequence; Int_t runNumber; Int_t eventNumber; Int_t BCID; Int_t OdinTCK; Int_t L0DUTCK; Int_t HLTTCK; Int_t nPV; Float_t PVX[40]; //[nPV] Float_t PVY[40]; //[nPV] Float_t PVZ[40]; //[nPV] Float_t PVXERR[40]; //[nPV] Float_t PVYERR[40]; //[nPV] Float_t PVZERR[40]; //[nPV] Float_t PVCHI2[40]; //[nPV] Float_t PVNDOF[40]; //[nPV] Float_t PVNTRACKS[40]; //[nPV] // List of branches TBranch *b_B_MINIP; //! TBranch *b_B_MINIPCHI2; //! TBranch *b_B_OWNPV_X; //! TBranch *b_B_OWNPV_Y; //! TBranch *b_B_OWNPV_Z; //! TBranch *b_B_OWNPV_XERR; //! TBranch *b_B_OWNPV_YERR; //! TBranch *b_B_OWNPV_ZERR; //! TBranch *b_B_OWNPV_CHI2; //! TBranch *b_B_OWNPV_NDOF; //! TBranch *b_B_OWNPV_COV_; //! TBranch *b_B_IP_OWNPV; //! TBranch *b_B_IPCHI2_OWNPV; //! TBranch *b_B_FD_OWNPV; //! TBranch *b_B_FDCHI2_OWNPV; //! TBranch *b_B_DIRA_OWNPV; //! TBranch *b_B_ENDVERTEX_X; //! TBranch *b_B_ENDVERTEX_Y; //! TBranch *b_B_ENDVERTEX_Z; //! TBranch *b_B_ENDVERTEX_XERR; //! TBranch *b_B_ENDVERTEX_YERR; //! TBranch *b_B_ENDVERTEX_ZERR; //! TBranch *b_B_ENDVERTEX_CHI2; //! TBranch *b_B_ENDVERTEX_NDOF; //! TBranch *b_B_ENDVERTEX_COV_; //! TBranch *b_B_P; //! TBranch *b_B_PT; //! TBranch *b_B_PE; //! TBranch *b_B_PX; //! TBranch *b_B_PY; //! TBranch *b_B_PZ; //! TBranch *b_B_MM; //! TBranch *b_B_MMERR; //! TBranch *b_B_M; //! TBranch *b_B_ID; //! TBranch *b_Bachelor_CosTheta; //! TBranch *b_Bachelor_MINIP; //! TBranch *b_Bachelor_MINIPCHI2; //! TBranch *b_Bachelor_OWNPV_X; //! TBranch *b_Bachelor_OWNPV_Y; //! TBranch *b_Bachelor_OWNPV_Z; //! TBranch *b_Bachelor_OWNPV_XERR; //! TBranch *b_Bachelor_OWNPV_YERR; //! TBranch *b_Bachelor_OWNPV_ZERR; //! TBranch *b_Bachelor_OWNPV_CHI2; //! TBranch *b_Bachelor_OWNPV_NDOF; //! TBranch *b_Bachelor_OWNPV_COV_; //! TBranch *b_Bachelor_IP_OWNPV; //! TBranch *b_Bachelor_IPCHI2_OWNPV; //! TBranch *b_Bachelor_ORIVX_X; //! TBranch *b_Bachelor_ORIVX_Y; //! TBranch *b_Bachelor_ORIVX_Z; //! TBranch *b_Bachelor_ORIVX_XERR; //! TBranch *b_Bachelor_ORIVX_YERR; //! TBranch *b_Bachelor_ORIVX_ZERR; //! TBranch *b_Bachelor_ORIVX_CHI2; //! TBranch *b_Bachelor_ORIVX_NDOF; //! TBranch *b_Bachelor_ORIVX_COV_; //! TBranch *b_Bachelor_P; //! TBranch *b_Bachelor_PT; //! TBranch *b_Bachelor_PE; //! TBranch *b_Bachelor_PX; //! TBranch *b_Bachelor_PY; //! TBranch *b_Bachelor_PZ; //! TBranch *b_Bachelor_MM; //! TBranch *b_Bachelor_M; //! TBranch *b_Bachelor_ID; //! TBranch *b_Bachelor_PIDe; //! TBranch *b_Bachelor_PIDmu; //! TBranch *b_Bachelor_PIDK; //! TBranch *b_Bachelor_PIDp; //! TBranch *b_Bachelor_CaloEcalE; //! TBranch *b_Bachelor_CaloHcalE; //! TBranch *b_Bachelor_hasMuon; //! TBranch *b_Bachelor_isMuon; //! TBranch *b_Bachelor_hasRich; //! TBranch *b_Bachelor_hasCalo; //! TBranch *b_Bachelor_TRACK_Type; //! TBranch *b_Bachelor_TRACK_CHI2NDOF; //! TBranch *b_Bachelor_TRACK_PCHI2; //! TBranch *b_Bachelor_TRACK_GhostProb; //! TBranch *b_Bachelor_TRACK_CloneDist; //! TBranch *b_D_CosTheta; //! TBranch *b_D_MINIP; //! TBranch *b_D_MINIPCHI2; //! TBranch *b_D_OWNPV_X; //! TBranch *b_D_OWNPV_Y; //! TBranch *b_D_OWNPV_Z; //! TBranch *b_D_OWNPV_XERR; //! TBranch *b_D_OWNPV_YERR; //! TBranch *b_D_OWNPV_ZERR; //! TBranch *b_D_OWNPV_CHI2; //! TBranch *b_D_OWNPV_NDOF; //! TBranch *b_D_OWNPV_COV_; //! TBranch *b_D_IP_OWNPV; //! TBranch *b_D_IPCHI2_OWNPV; //! TBranch *b_D_FD_OWNPV; //! TBranch *b_D_FDCHI2_OWNPV; //! TBranch *b_D_DIRA_OWNPV; //! TBranch *b_D_ORIVX_X; //! TBranch *b_D_ORIVX_Y; //! TBranch *b_D_ORIVX_Z; //! TBranch *b_D_ORIVX_XERR; //! TBranch *b_D_ORIVX_YERR; //! TBranch *b_D_ORIVX_ZERR; //! TBranch *b_D_ORIVX_CHI2; //! TBranch *b_D_ORIVX_NDOF; //! TBranch *b_D_ORIVX_COV_; //! TBranch *b_D_FD_ORIVX; //! TBranch *b_D_FDCHI2_ORIVX; //! TBranch *b_D_DIRA_ORIVX; //! TBranch *b_D_ENDVERTEX_X; //! TBranch *b_D_ENDVERTEX_Y; //! TBranch *b_D_ENDVERTEX_Z; //! TBranch *b_D_ENDVERTEX_XERR; //! TBranch *b_D_ENDVERTEX_YERR; //! TBranch *b_D_ENDVERTEX_ZERR; //! TBranch *b_D_ENDVERTEX_CHI2; //! TBranch *b_D_ENDVERTEX_NDOF; //! TBranch *b_D_ENDVERTEX_COV_; //! TBranch *b_D_P; //! TBranch *b_D_PT; //! TBranch *b_D_PE; //! TBranch *b_D_PX; //! TBranch *b_D_PY; //! TBranch *b_D_PZ; //! TBranch *b_D_MM; //! TBranch *b_D_MMERR; //! TBranch *b_D_M; //! TBranch *b_D_ID; //! TBranch *b_Negative_D_Daughter_CosTheta; //! TBranch *b_Negative_D_Daughter_MINIP; //! TBranch *b_Negative_D_Daughter_MINIPCHI2; //! TBranch *b_Negative_D_Daughter_OWNPV_X; //! TBranch *b_Negative_D_Daughter_OWNPV_Y; //! TBranch *b_Negative_D_Daughter_OWNPV_Z; //! TBranch *b_Negative_D_Daughter_OWNPV_XERR; //! TBranch *b_Negative_D_Daughter_OWNPV_YERR; //! TBranch *b_Negative_D_Daughter_OWNPV_ZERR; //! TBranch *b_Negative_D_Daughter_OWNPV_CHI2; //! TBranch *b_Negative_D_Daughter_OWNPV_NDOF; //! TBranch *b_Negative_D_Daughter_OWNPV_COV_; //! TBranch *b_Negative_D_Daughter_IP_OWNPV; //! TBranch *b_Negative_D_Daughter_IPCHI2_OWNPV; //! TBranch *b_Negative_D_Daughter_ORIVX_X; //! TBranch *b_Negative_D_Daughter_ORIVX_Y; //! TBranch *b_Negative_D_Daughter_ORIVX_Z; //! TBranch *b_Negative_D_Daughter_ORIVX_XERR; //! TBranch *b_Negative_D_Daughter_ORIVX_YERR; //! TBranch *b_Negative_D_Daughter_ORIVX_ZERR; //! TBranch *b_Negative_D_Daughter_ORIVX_CHI2; //! TBranch *b_Negative_D_Daughter_ORIVX_NDOF; //! TBranch *b_Negative_D_Daughter_ORIVX_COV_; //! TBranch *b_Negative_D_Daughter_P; //! TBranch *b_Negative_D_Daughter_PT; //! TBranch *b_Negative_D_Daughter_PE; //! TBranch *b_Negative_D_Daughter_PX; //! TBranch *b_Negative_D_Daughter_PY; //! TBranch *b_Negative_D_Daughter_PZ; //! TBranch *b_Negative_D_Daughter_MM; //! TBranch *b_Negative_D_Daughter_M; //! TBranch *b_Negative_D_Daughter_ID; //! TBranch *b_Negative_D_Daughter_PIDe; //! TBranch *b_Negative_D_Daughter_PIDmu; //! TBranch *b_Negative_D_Daughter_PIDK; //! TBranch *b_Negative_D_Daughter_PIDp; //! TBranch *b_Negative_D_Daughter_CaloEcalE; //! TBranch *b_Negative_D_Daughter_CaloHcalE; //! TBranch *b_Negative_D_Daughter_hasMuon; //! TBranch *b_Negative_D_Daughter_isMuon; //! TBranch *b_Negative_D_Daughter_hasRich; //! TBranch *b_Negative_D_Daughter_hasCalo; //! TBranch *b_Negative_D_Daughter_TRACK_Type; //! TBranch *b_Negative_D_Daughter_TRACK_CHI2NDOF; //! TBranch *b_Negative_D_Daughter_TRACK_PCHI2; //! TBranch *b_Negative_D_Daughter_TRACK_GhostProb; //! TBranch *b_Negative_D_Daughter_TRACK_CloneDist; //! TBranch *b_Positive_D_Daughter_CosTheta; //! TBranch *b_Positive_D_Daughter_MINIP; //! TBranch *b_Positive_D_Daughter_MINIPCHI2; //! TBranch *b_Positive_D_Daughter_OWNPV_X; //! TBranch *b_Positive_D_Daughter_OWNPV_Y; //! TBranch *b_Positive_D_Daughter_OWNPV_Z; //! TBranch *b_Positive_D_Daughter_OWNPV_XERR; //! TBranch *b_Positive_D_Daughter_OWNPV_YERR; //! TBranch *b_Positive_D_Daughter_OWNPV_ZERR; //! TBranch *b_Positive_D_Daughter_OWNPV_CHI2; //! TBranch *b_Positive_D_Daughter_OWNPV_NDOF; //! TBranch *b_Positive_D_Daughter_OWNPV_COV_; //! TBranch *b_Positive_D_Daughter_IP_OWNPV; //! TBranch *b_Positive_D_Daughter_IPCHI2_OWNPV; //! TBranch *b_Positive_D_Daughter_ORIVX_X; //! TBranch *b_Positive_D_Daughter_ORIVX_Y; //! TBranch *b_Positive_D_Daughter_ORIVX_Z; //! TBranch *b_Positive_D_Daughter_ORIVX_XERR; //! TBranch *b_Positive_D_Daughter_ORIVX_YERR; //! TBranch *b_Positive_D_Daughter_ORIVX_ZERR; //! TBranch *b_Positive_D_Daughter_ORIVX_CHI2; //! TBranch *b_Positive_D_Daughter_ORIVX_NDOF; //! TBranch *b_Positive_D_Daughter_ORIVX_COV_; //! TBranch *b_Positive_D_Daughter_P; //! TBranch *b_Positive_D_Daughter_PT; //! TBranch *b_Positive_D_Daughter_PE; //! TBranch *b_Positive_D_Daughter_PX; //! TBranch *b_Positive_D_Daughter_PY; //! TBranch *b_Positive_D_Daughter_PZ; //! TBranch *b_Positive_D_Daughter_MM; //! TBranch *b_Positive_D_Daughter_M; //! TBranch *b_Positive_D_Daughter_ID; //! TBranch *b_Positive_D_Daughter_PIDe; //! TBranch *b_Positive_D_Daughter_PIDmu; //! TBranch *b_Positive_D_Daughter_PIDK; //! TBranch *b_Positive_D_Daughter_PIDp; //! TBranch *b_Positive_D_Daughter_CaloEcalE; //! TBranch *b_Positive_D_Daughter_CaloHcalE; //! TBranch *b_Positive_D_Daughter_hasMuon; //! TBranch *b_Positive_D_Daughter_isMuon; //! TBranch *b_Positive_D_Daughter_hasRich; //! TBranch *b_Positive_D_Daughter_hasCalo; //! TBranch *b_Positive_D_Daughter_TRACK_Type; //! TBranch *b_Positive_D_Daughter_TRACK_CHI2NDOF; //! TBranch *b_Positive_D_Daughter_TRACK_PCHI2; //! TBranch *b_Positive_D_Daughter_TRACK_GhostProb; //! TBranch *b_Positive_D_Daughter_TRACK_CloneDist; //! TBranch *b_nCandidate; //! TBranch *b_totCandidates; //! TBranch *b_EventInSequence; //! TBranch *b_runNumber; //! TBranch *b_eventNumber; //! TBranch *b_BCID; //! TBranch *b_OdinTCK; //! TBranch *b_L0DUTCK; //! TBranch *b_HLTTCK; //! TBranch *b_nPV; //! TBranch *b_PVX; //! TBranch *b_PVY; //! TBranch *b_PVZ; //! TBranch *b_PVXERR; //! TBranch *b_PVYERR; //! TBranch *b_PVZERR; //! TBranch *b_PVCHI2; //! TBranch *b_PVNDOF; //! TBranch *b_PVNTRACKS; //! fChain->SetBranchAddress("B_MINIP", &B_MINIP, &b_B_MINIP); fChain->SetBranchAddress("B_MINIPCHI2", &B_MINIPCHI2, &b_B_MINIPCHI2); fChain->SetBranchAddress("B_OWNPV_X", &B_OWNPV_X, &b_B_OWNPV_X); fChain->SetBranchAddress("B_OWNPV_Y", &B_OWNPV_Y, &b_B_OWNPV_Y); fChain->SetBranchAddress("B_OWNPV_Z", &B_OWNPV_Z, &b_B_OWNPV_Z); fChain->SetBranchAddress("B_OWNPV_XERR", &B_OWNPV_XERR, &b_B_OWNPV_XERR); fChain->SetBranchAddress("B_OWNPV_YERR", &B_OWNPV_YERR, &b_B_OWNPV_YERR); fChain->SetBranchAddress("B_OWNPV_ZERR", &B_OWNPV_ZERR, &b_B_OWNPV_ZERR); fChain->SetBranchAddress("B_OWNPV_CHI2", &B_OWNPV_CHI2, &b_B_OWNPV_CHI2); fChain->SetBranchAddress("B_OWNPV_NDOF", &B_OWNPV_NDOF, &b_B_OWNPV_NDOF); fChain->SetBranchAddress("B_OWNPV_COV_", B_OWNPV_COV_, &b_B_OWNPV_COV_); fChain->SetBranchAddress("B_IP_OWNPV", &B_IP_OWNPV, &b_B_IP_OWNPV); fChain->SetBranchAddress("B_IPCHI2_OWNPV", &B_IPCHI2_OWNPV, &b_B_IPCHI2_OWNPV); fChain->SetBranchAddress("B_FD_OWNPV", &B_FD_OWNPV, &b_B_FD_OWNPV); fChain->SetBranchAddress("B_FDCHI2_OWNPV", &B_FDCHI2_OWNPV, &b_B_FDCHI2_OWNPV); fChain->SetBranchAddress("B_DIRA_OWNPV", &B_DIRA_OWNPV, &b_B_DIRA_OWNPV); fChain->SetBranchAddress("B_ENDVERTEX_X", &B_ENDVERTEX_X, &b_B_ENDVERTEX_X); fChain->SetBranchAddress("B_ENDVERTEX_Y", &B_ENDVERTEX_Y, &b_B_ENDVERTEX_Y); fChain->SetBranchAddress("B_ENDVERTEX_Z", &B_ENDVERTEX_Z, &b_B_ENDVERTEX_Z); fChain->SetBranchAddress("B_ENDVERTEX_XERR", &B_ENDVERTEX_XERR, &b_B_ENDVERTEX_XERR); fChain->SetBranchAddress("B_ENDVERTEX_YERR", &B_ENDVERTEX_YERR, &b_B_ENDVERTEX_YERR); fChain->SetBranchAddress("B_ENDVERTEX_ZERR", &B_ENDVERTEX_ZERR, &b_B_ENDVERTEX_ZERR); fChain->SetBranchAddress("B_ENDVERTEX_CHI2", &B_ENDVERTEX_CHI2, &b_B_ENDVERTEX_CHI2); fChain->SetBranchAddress("B_ENDVERTEX_NDOF", &B_ENDVERTEX_NDOF, &b_B_ENDVERTEX_NDOF); fChain->SetBranchAddress("B_ENDVERTEX_COV_", B_ENDVERTEX_COV_, &b_B_ENDVERTEX_COV_); fChain->SetBranchAddress("B_P", &B_P, &b_B_P); fChain->SetBranchAddress("B_PT", &B_PT, &b_B_PT); fChain->SetBranchAddress("B_PE", &B_PE, &b_B_PE); fChain->SetBranchAddress("B_PX", &B_PX, &b_B_PX); fChain->SetBranchAddress("B_PY", &B_PY, &b_B_PY); fChain->SetBranchAddress("B_PZ", &B_PZ, &b_B_PZ); fChain->SetBranchAddress("B_MM", &B_MM, &b_B_MM); fChain->SetBranchAddress("B_MMERR", &B_MMERR, &b_B_MMERR); fChain->SetBranchAddress("B_M", &B_M, &b_B_M); fChain->SetBranchAddress("B_ID", &B_ID, &b_B_ID); fChain->SetBranchAddress("Bachelor_CosTheta", &Bachelor_CosTheta, &b_Bachelor_CosTheta); fChain->SetBranchAddress("Bachelor_MINIP", &Bachelor_MINIP, &b_Bachelor_MINIP); fChain->SetBranchAddress("Bachelor_MINIPCHI2", &Bachelor_MINIPCHI2, &b_Bachelor_MINIPCHI2); fChain->SetBranchAddress("Bachelor_OWNPV_X", &Bachelor_OWNPV_X, &b_Bachelor_OWNPV_X); fChain->SetBranchAddress("Bachelor_OWNPV_Y", &Bachelor_OWNPV_Y, &b_Bachelor_OWNPV_Y); fChain->SetBranchAddress("Bachelor_OWNPV_Z", &Bachelor_OWNPV_Z, &b_Bachelor_OWNPV_Z); fChain->SetBranchAddress("Bachelor_OWNPV_XERR", &Bachelor_OWNPV_XERR, &b_Bachelor_OWNPV_XERR); fChain->SetBranchAddress("Bachelor_OWNPV_YERR", &Bachelor_OWNPV_YERR, &b_Bachelor_OWNPV_YERR); fChain->SetBranchAddress("Bachelor_OWNPV_ZERR", &Bachelor_OWNPV_ZERR, &b_Bachelor_OWNPV_ZERR); fChain->SetBranchAddress("Bachelor_OWNPV_CHI2", &Bachelor_OWNPV_CHI2, &b_Bachelor_OWNPV_CHI2); fChain->SetBranchAddress("Bachelor_OWNPV_NDOF", &Bachelor_OWNPV_NDOF, &b_Bachelor_OWNPV_NDOF); fChain->SetBranchAddress("Bachelor_OWNPV_COV_", Bachelor_OWNPV_COV_, &b_Bachelor_OWNPV_COV_); fChain->SetBranchAddress("Bachelor_IP_OWNPV", &Bachelor_IP_OWNPV, &b_Bachelor_IP_OWNPV); fChain->SetBranchAddress("Bachelor_IPCHI2_OWNPV", &Bachelor_IPCHI2_OWNPV, &b_Bachelor_IPCHI2_OWNPV); fChain->SetBranchAddress("Bachelor_ORIVX_X", &Bachelor_ORIVX_X, &b_Bachelor_ORIVX_X); fChain->SetBranchAddress("Bachelor_ORIVX_Y", &Bachelor_ORIVX_Y, &b_Bachelor_ORIVX_Y); fChain->SetBranchAddress("Bachelor_ORIVX_Z", &Bachelor_ORIVX_Z, &b_Bachelor_ORIVX_Z); fChain->SetBranchAddress("Bachelor_ORIVX_XERR", &Bachelor_ORIVX_XERR, &b_Bachelor_ORIVX_XERR); fChain->SetBranchAddress("Bachelor_ORIVX_YERR", &Bachelor_ORIVX_YERR, &b_Bachelor_ORIVX_YERR); fChain->SetBranchAddress("Bachelor_ORIVX_ZERR", &Bachelor_ORIVX_ZERR, &b_Bachelor_ORIVX_ZERR); fChain->SetBranchAddress("Bachelor_ORIVX_CHI2", &Bachelor_ORIVX_CHI2, &b_Bachelor_ORIVX_CHI2); fChain->SetBranchAddress("Bachelor_ORIVX_NDOF", &Bachelor_ORIVX_NDOF, &b_Bachelor_ORIVX_NDOF); fChain->SetBranchAddress("Bachelor_ORIVX_COV_", Bachelor_ORIVX_COV_, &b_Bachelor_ORIVX_COV_); fChain->SetBranchAddress("Bachelor_P", &Bachelor_P, &b_Bachelor_P); fChain->SetBranchAddress("Bachelor_PT", &Bachelor_PT, &b_Bachelor_PT); fChain->SetBranchAddress("Bachelor_PE", &Bachelor_PE, &b_Bachelor_PE); fChain->SetBranchAddress("Bachelor_PX", &Bachelor_PX, &b_Bachelor_PX); fChain->SetBranchAddress("Bachelor_PY", &Bachelor_PY, &b_Bachelor_PY); fChain->SetBranchAddress("Bachelor_PZ", &Bachelor_PZ, &b_Bachelor_PZ); fChain->SetBranchAddress("Bachelor_MM", &Bachelor_MM, &b_Bachelor_MM); fChain->SetBranchAddress("Bachelor_M", &Bachelor_M, &b_Bachelor_M); fChain->SetBranchAddress("Bachelor_ID", &Bachelor_ID, &b_Bachelor_ID); fChain->SetBranchAddress("Bachelor_PIDe", &Bachelor_PIDe, &b_Bachelor_PIDe); fChain->SetBranchAddress("Bachelor_PIDmu", &Bachelor_PIDmu, &b_Bachelor_PIDmu); fChain->SetBranchAddress("Bachelor_PIDK", &Bachelor_PIDK, &b_Bachelor_PIDK); fChain->SetBranchAddress("Bachelor_PIDp", &Bachelor_PIDp, &b_Bachelor_PIDp); fChain->SetBranchAddress("Bachelor_CaloEcalE", &Bachelor_CaloEcalE, &b_Bachelor_CaloEcalE); fChain->SetBranchAddress("Bachelor_CaloHcalE", &Bachelor_CaloHcalE, &b_Bachelor_CaloHcalE); fChain->SetBranchAddress("Bachelor_hasMuon", &Bachelor_hasMuon, &b_Bachelor_hasMuon); fChain->SetBranchAddress("Bachelor_isMuon", &Bachelor_isMuon, &b_Bachelor_isMuon); fChain->SetBranchAddress("Bachelor_hasRich", &Bachelor_hasRich, &b_Bachelor_hasRich); fChain->SetBranchAddress("Bachelor_hasCalo", &Bachelor_hasCalo, &b_Bachelor_hasCalo); fChain->SetBranchAddress("Bachelor_TRACK_Type", &Bachelor_TRACK_Type, &b_Bachelor_TRACK_Type); fChain->SetBranchAddress("Bachelor_TRACK_CHI2NDOF", &Bachelor_TRACK_CHI2NDOF, &b_Bachelor_TRACK_CHI2NDOF); fChain->SetBranchAddress("Bachelor_TRACK_PCHI2", &Bachelor_TRACK_PCHI2, &b_Bachelor_TRACK_PCHI2); fChain->SetBranchAddress("Bachelor_TRACK_GhostProb", &Bachelor_TRACK_GhostProb, &b_Bachelor_TRACK_GhostProb); fChain->SetBranchAddress("Bachelor_TRACK_CloneDist", &Bachelor_TRACK_CloneDist, &b_Bachelor_TRACK_CloneDist); fChain->SetBranchAddress("D_CosTheta", &D_CosTheta, &b_D_CosTheta); fChain->SetBranchAddress("D_MINIP", &D_MINIP, &b_D_MINIP); fChain->SetBranchAddress("D_MINIPCHI2", &D_MINIPCHI2, &b_D_MINIPCHI2); fChain->SetBranchAddress("D_OWNPV_X", &D_OWNPV_X, &b_D_OWNPV_X); fChain->SetBranchAddress("D_OWNPV_Y", &D_OWNPV_Y, &b_D_OWNPV_Y); fChain->SetBranchAddress("D_OWNPV_Z", &D_OWNPV_Z, &b_D_OWNPV_Z); fChain->SetBranchAddress("D_OWNPV_XERR", &D_OWNPV_XERR, &b_D_OWNPV_XERR); fChain->SetBranchAddress("D_OWNPV_YERR", &D_OWNPV_YERR, &b_D_OWNPV_YERR); fChain->SetBranchAddress("D_OWNPV_ZERR", &D_OWNPV_ZERR, &b_D_OWNPV_ZERR); fChain->SetBranchAddress("D_OWNPV_CHI2", &D_OWNPV_CHI2, &b_D_OWNPV_CHI2); fChain->SetBranchAddress("D_OWNPV_NDOF", &D_OWNPV_NDOF, &b_D_OWNPV_NDOF); fChain->SetBranchAddress("D_OWNPV_COV_", D_OWNPV_COV_, &b_D_OWNPV_COV_); fChain->SetBranchAddress("D_IP_OWNPV", &D_IP_OWNPV, &b_D_IP_OWNPV); fChain->SetBranchAddress("D_IPCHI2_OWNPV", &D_IPCHI2_OWNPV, &b_D_IPCHI2_OWNPV); fChain->SetBranchAddress("D_FD_OWNPV", &D_FD_OWNPV, &b_D_FD_OWNPV); fChain->SetBranchAddress("D_FDCHI2_OWNPV", &D_FDCHI2_OWNPV, &b_D_FDCHI2_OWNPV); fChain->SetBranchAddress("D_DIRA_OWNPV", &D_DIRA_OWNPV, &b_D_DIRA_OWNPV); fChain->SetBranchAddress("D_ORIVX_X", &D_ORIVX_X, &b_D_ORIVX_X); fChain->SetBranchAddress("D_ORIVX_Y", &D_ORIVX_Y, &b_D_ORIVX_Y); fChain->SetBranchAddress("D_ORIVX_Z", &D_ORIVX_Z, &b_D_ORIVX_Z); fChain->SetBranchAddress("D_ORIVX_XERR", &D_ORIVX_XERR, &b_D_ORIVX_XERR); fChain->SetBranchAddress("D_ORIVX_YERR", &D_ORIVX_YERR, &b_D_ORIVX_YERR); fChain->SetBranchAddress("D_ORIVX_ZERR", &D_ORIVX_ZERR, &b_D_ORIVX_ZERR); fChain->SetBranchAddress("D_ORIVX_CHI2", &D_ORIVX_CHI2, &b_D_ORIVX_CHI2); fChain->SetBranchAddress("D_ORIVX_NDOF", &D_ORIVX_NDOF, &b_D_ORIVX_NDOF); fChain->SetBranchAddress("D_ORIVX_COV_", D_ORIVX_COV_, &b_D_ORIVX_COV_); fChain->SetBranchAddress("D_FD_ORIVX", &D_FD_ORIVX, &b_D_FD_ORIVX); fChain->SetBranchAddress("D_FDCHI2_ORIVX", &D_FDCHI2_ORIVX, &b_D_FDCHI2_ORIVX); fChain->SetBranchAddress("D_DIRA_ORIVX", &D_DIRA_ORIVX, &b_D_DIRA_ORIVX); fChain->SetBranchAddress("D_ENDVERTEX_X", &D_ENDVERTEX_X, &b_D_ENDVERTEX_X); fChain->SetBranchAddress("D_ENDVERTEX_Y", &D_ENDVERTEX_Y, &b_D_ENDVERTEX_Y); fChain->SetBranchAddress("D_ENDVERTEX_Z", &D_ENDVERTEX_Z, &b_D_ENDVERTEX_Z); fChain->SetBranchAddress("D_ENDVERTEX_XERR", &D_ENDVERTEX_XERR, &b_D_ENDVERTEX_XERR); fChain->SetBranchAddress("D_ENDVERTEX_YERR", &D_ENDVERTEX_YERR, &b_D_ENDVERTEX_YERR); fChain->SetBranchAddress("D_ENDVERTEX_ZERR", &D_ENDVERTEX_ZERR, &b_D_ENDVERTEX_ZERR); fChain->SetBranchAddress("D_ENDVERTEX_CHI2", &D_ENDVERTEX_CHI2, &b_D_ENDVERTEX_CHI2); fChain->SetBranchAddress("D_ENDVERTEX_NDOF", &D_ENDVERTEX_NDOF, &b_D_ENDVERTEX_NDOF); fChain->SetBranchAddress("D_ENDVERTEX_COV_", D_ENDVERTEX_COV_, &b_D_ENDVERTEX_COV_); fChain->SetBranchAddress("D_P", &D_P, &b_D_P); fChain->SetBranchAddress("D_PT", &D_PT, &b_D_PT); fChain->SetBranchAddress("D_PE", &D_PE, &b_D_PE); fChain->SetBranchAddress("D_PX", &D_PX, &b_D_PX); fChain->SetBranchAddress("D_PY", &D_PY, &b_D_PY); fChain->SetBranchAddress("D_PZ", &D_PZ, &b_D_PZ); fChain->SetBranchAddress("D_MM", &D_MM, &b_D_MM); fChain->SetBranchAddress("D_MMERR", &D_MMERR, &b_D_MMERR); fChain->SetBranchAddress("D_M", &D_M, &b_D_M); fChain->SetBranchAddress("D_ID", &D_ID, &b_D_ID); fChain->SetBranchAddress("Negative_D_Daughter_CosTheta", &Negative_D_Daughter_CosTheta, &b_Negative_D_Daughter_CosTheta); fChain->SetBranchAddress("Negative_D_Daughter_MINIP", &Negative_D_Daughter_MINIP, &b_Negative_D_Daughter_MINIP); fChain->SetBranchAddress("Negative_D_Daughter_MINIPCHI2", &Negative_D_Daughter_MINIPCHI2, &b_Negative_D_Daughter_MINIPCHI2); fChain->SetBranchAddress("Negative_D_Daughter_OWNPV_X", &Negative_D_Daughter_OWNPV_X, &b_Negative_D_Daughter_OWNPV_X); fChain->SetBranchAddress("Negative_D_Daughter_OWNPV_Y", &Negative_D_Daughter_OWNPV_Y, &b_Negative_D_Daughter_OWNPV_Y); fChain->SetBranchAddress("Negative_D_Daughter_OWNPV_Z", &Negative_D_Daughter_OWNPV_Z, &b_Negative_D_Daughter_OWNPV_Z); fChain->SetBranchAddress("Negative_D_Daughter_OWNPV_XERR", &Negative_D_Daughter_OWNPV_XERR, &b_Negative_D_Daughter_OWNPV_XERR); fChain->SetBranchAddress("Negative_D_Daughter_OWNPV_YERR", &Negative_D_Daughter_OWNPV_YERR, &b_Negative_D_Daughter_OWNPV_YERR); fChain->SetBranchAddress("Negative_D_Daughter_OWNPV_ZERR", &Negative_D_Daughter_OWNPV_ZERR, &b_Negative_D_Daughter_OWNPV_ZERR); fChain->SetBranchAddress("Negative_D_Daughter_OWNPV_CHI2", &Negative_D_Daughter_OWNPV_CHI2, &b_Negative_D_Daughter_OWNPV_CHI2); fChain->SetBranchAddress("Negative_D_Daughter_OWNPV_NDOF", &Negative_D_Daughter_OWNPV_NDOF, &b_Negative_D_Daughter_OWNPV_NDOF); fChain->SetBranchAddress("Negative_D_Daughter_OWNPV_COV_", Negative_D_Daughter_OWNPV_COV_, &b_Negative_D_Daughter_OWNPV_COV_); fChain->SetBranchAddress("Negative_D_Daughter_IP_OWNPV", &Negative_D_Daughter_IP_OWNPV, &b_Negative_D_Daughter_IP_OWNPV); fChain->SetBranchAddress("Negative_D_Daughter_IPCHI2_OWNPV", &Negative_D_Daughter_IPCHI2_OWNPV, &b_Negative_D_Daughter_IPCHI2_OWNPV); fChain->SetBranchAddress("Negative_D_Daughter_ORIVX_X", &Negative_D_Daughter_ORIVX_X, &b_Negative_D_Daughter_ORIVX_X); fChain->SetBranchAddress("Negative_D_Daughter_ORIVX_Y", &Negative_D_Daughter_ORIVX_Y, &b_Negative_D_Daughter_ORIVX_Y); fChain->SetBranchAddress("Negative_D_Daughter_ORIVX_Z", &Negative_D_Daughter_ORIVX_Z, &b_Negative_D_Daughter_ORIVX_Z); fChain->SetBranchAddress("Negative_D_Daughter_ORIVX_XERR", &Negative_D_Daughter_ORIVX_XERR, &b_Negative_D_Daughter_ORIVX_XERR); fChain->SetBranchAddress("Negative_D_Daughter_ORIVX_YERR", &Negative_D_Daughter_ORIVX_YERR, &b_Negative_D_Daughter_ORIVX_YERR); fChain->SetBranchAddress("Negative_D_Daughter_ORIVX_ZERR", &Negative_D_Daughter_ORIVX_ZERR, &b_Negative_D_Daughter_ORIVX_ZERR); fChain->SetBranchAddress("Negative_D_Daughter_ORIVX_CHI2", &Negative_D_Daughter_ORIVX_CHI2, &b_Negative_D_Daughter_ORIVX_CHI2); fChain->SetBranchAddress("Negative_D_Daughter_ORIVX_NDOF", &Negative_D_Daughter_ORIVX_NDOF, &b_Negative_D_Daughter_ORIVX_NDOF); fChain->SetBranchAddress("Negative_D_Daughter_ORIVX_COV_", Negative_D_Daughter_ORIVX_COV_, &b_Negative_D_Daughter_ORIVX_COV_); fChain->SetBranchAddress("Negative_D_Daughter_P", &Negative_D_Daughter_P, &b_Negative_D_Daughter_P); fChain->SetBranchAddress("Negative_D_Daughter_PT", &Negative_D_Daughter_PT, &b_Negative_D_Daughter_PT); fChain->SetBranchAddress("Negative_D_Daughter_PE", &Negative_D_Daughter_PE, &b_Negative_D_Daughter_PE); fChain->SetBranchAddress("Negative_D_Daughter_PX", &Negative_D_Daughter_PX, &b_Negative_D_Daughter_PX); fChain->SetBranchAddress("Negative_D_Daughter_PY", &Negative_D_Daughter_PY, &b_Negative_D_Daughter_PY); fChain->SetBranchAddress("Negative_D_Daughter_PZ", &Negative_D_Daughter_PZ, &b_Negative_D_Daughter_PZ); fChain->SetBranchAddress("Negative_D_Daughter_MM", &Negative_D_Daughter_MM, &b_Negative_D_Daughter_MM); fChain->SetBranchAddress("Negative_D_Daughter_M", &Negative_D_Daughter_M, &b_Negative_D_Daughter_M); fChain->SetBranchAddress("Negative_D_Daughter_ID", &Negative_D_Daughter_ID, &b_Negative_D_Daughter_ID); fChain->SetBranchAddress("Negative_D_Daughter_PIDe", &Negative_D_Daughter_PIDe, &b_Negative_D_Daughter_PIDe); fChain->SetBranchAddress("Negative_D_Daughter_PIDmu", &Negative_D_Daughter_PIDmu, &b_Negative_D_Daughter_PIDmu); fChain->SetBranchAddress("Negative_D_Daughter_PIDK", &Negative_D_Daughter_PIDK, &b_Negative_D_Daughter_PIDK); fChain->SetBranchAddress("Negative_D_Daughter_PIDp", &Negative_D_Daughter_PIDp, &b_Negative_D_Daughter_PIDp); fChain->SetBranchAddress("Negative_D_Daughter_CaloEcalE", &Negative_D_Daughter_CaloEcalE, &b_Negative_D_Daughter_CaloEcalE); fChain->SetBranchAddress("Negative_D_Daughter_CaloHcalE", &Negative_D_Daughter_CaloHcalE, &b_Negative_D_Daughter_CaloHcalE); fChain->SetBranchAddress("Negative_D_Daughter_hasMuon", &Negative_D_Daughter_hasMuon, &b_Negative_D_Daughter_hasMuon); fChain->SetBranchAddress("Negative_D_Daughter_isMuon", &Negative_D_Daughter_isMuon, &b_Negative_D_Daughter_isMuon); fChain->SetBranchAddress("Negative_D_Daughter_hasRich", &Negative_D_Daughter_hasRich, &b_Negative_D_Daughter_hasRich); fChain->SetBranchAddress("Negative_D_Daughter_hasCalo", &Negative_D_Daughter_hasCalo, &b_Negative_D_Daughter_hasCalo); fChain->SetBranchAddress("Negative_D_Daughter_TRACK_Type", &Negative_D_Daughter_TRACK_Type, &b_Negative_D_Daughter_TRACK_Type); fChain->SetBranchAddress("Negative_D_Daughter_TRACK_CHI2NDOF", &Negative_D_Daughter_TRACK_CHI2NDOF, &b_Negative_D_Daughter_TRACK_CHI2NDOF); fChain->SetBranchAddress("Negative_D_Daughter_TRACK_PCHI2", &Negative_D_Daughter_TRACK_PCHI2, &b_Negative_D_Daughter_TRACK_PCHI2); fChain->SetBranchAddress("Negative_D_Daughter_TRACK_GhostProb", &Negative_D_Daughter_TRACK_GhostProb, &b_Negative_D_Daughter_TRACK_GhostProb); fChain->SetBranchAddress("Negative_D_Daughter_TRACK_CloneDist", &Negative_D_Daughter_TRACK_CloneDist, &b_Negative_D_Daughter_TRACK_CloneDist); fChain->SetBranchAddress("Positive_D_Daughter_CosTheta", &Positive_D_Daughter_CosTheta, &b_Positive_D_Daughter_CosTheta); fChain->SetBranchAddress("Positive_D_Daughter_MINIP", &Positive_D_Daughter_MINIP, &b_Positive_D_Daughter_MINIP); fChain->SetBranchAddress("Positive_D_Daughter_MINIPCHI2", &Positive_D_Daughter_MINIPCHI2, &b_Positive_D_Daughter_MINIPCHI2); fChain->SetBranchAddress("Positive_D_Daughter_OWNPV_X", &Positive_D_Daughter_OWNPV_X, &b_Positive_D_Daughter_OWNPV_X); fChain->SetBranchAddress("Positive_D_Daughter_OWNPV_Y", &Positive_D_Daughter_OWNPV_Y, &b_Positive_D_Daughter_OWNPV_Y); fChain->SetBranchAddress("Positive_D_Daughter_OWNPV_Z", &Positive_D_Daughter_OWNPV_Z, &b_Positive_D_Daughter_OWNPV_Z); fChain->SetBranchAddress("Positive_D_Daughter_OWNPV_XERR", &Positive_D_Daughter_OWNPV_XERR, &b_Positive_D_Daughter_OWNPV_XERR); fChain->SetBranchAddress("Positive_D_Daughter_OWNPV_YERR", &Positive_D_Daughter_OWNPV_YERR, &b_Positive_D_Daughter_OWNPV_YERR); fChain->SetBranchAddress("Positive_D_Daughter_OWNPV_ZERR", &Positive_D_Daughter_OWNPV_ZERR, &b_Positive_D_Daughter_OWNPV_ZERR); fChain->SetBranchAddress("Positive_D_Daughter_OWNPV_CHI2", &Positive_D_Daughter_OWNPV_CHI2, &b_Positive_D_Daughter_OWNPV_CHI2); fChain->SetBranchAddress("Positive_D_Daughter_OWNPV_NDOF", &Positive_D_Daughter_OWNPV_NDOF, &b_Positive_D_Daughter_OWNPV_NDOF); fChain->SetBranchAddress("Positive_D_Daughter_OWNPV_COV_", Positive_D_Daughter_OWNPV_COV_, &b_Positive_D_Daughter_OWNPV_COV_); fChain->SetBranchAddress("Positive_D_Daughter_IP_OWNPV", &Positive_D_Daughter_IP_OWNPV, &b_Positive_D_Daughter_IP_OWNPV); fChain->SetBranchAddress("Positive_D_Daughter_IPCHI2_OWNPV", &Positive_D_Daughter_IPCHI2_OWNPV, &b_Positive_D_Daughter_IPCHI2_OWNPV); fChain->SetBranchAddress("Positive_D_Daughter_ORIVX_X", &Positive_D_Daughter_ORIVX_X, &b_Positive_D_Daughter_ORIVX_X); fChain->SetBranchAddress("Positive_D_Daughter_ORIVX_Y", &Positive_D_Daughter_ORIVX_Y, &b_Positive_D_Daughter_ORIVX_Y); fChain->SetBranchAddress("Positive_D_Daughter_ORIVX_Z", &Positive_D_Daughter_ORIVX_Z, &b_Positive_D_Daughter_ORIVX_Z); fChain->SetBranchAddress("Positive_D_Daughter_ORIVX_XERR", &Positive_D_Daughter_ORIVX_XERR, &b_Positive_D_Daughter_ORIVX_XERR); fChain->SetBranchAddress("Positive_D_Daughter_ORIVX_YERR", &Positive_D_Daughter_ORIVX_YERR, &b_Positive_D_Daughter_ORIVX_YERR); fChain->SetBranchAddress("Positive_D_Daughter_ORIVX_ZERR", &Positive_D_Daughter_ORIVX_ZERR, &b_Positive_D_Daughter_ORIVX_ZERR); fChain->SetBranchAddress("Positive_D_Daughter_ORIVX_CHI2", &Positive_D_Daughter_ORIVX_CHI2, &b_Positive_D_Daughter_ORIVX_CHI2); fChain->SetBranchAddress("Positive_D_Daughter_ORIVX_NDOF", &Positive_D_Daughter_ORIVX_NDOF, &b_Positive_D_Daughter_ORIVX_NDOF); fChain->SetBranchAddress("Positive_D_Daughter_ORIVX_COV_", Positive_D_Daughter_ORIVX_COV_, &b_Positive_D_Daughter_ORIVX_COV_); fChain->SetBranchAddress("Positive_D_Daughter_P", &Positive_D_Daughter_P, &b_Positive_D_Daughter_P); fChain->SetBranchAddress("Positive_D_Daughter_PT", &Positive_D_Daughter_PT, &b_Positive_D_Daughter_PT); fChain->SetBranchAddress("Positive_D_Daughter_PE", &Positive_D_Daughter_PE, &b_Positive_D_Daughter_PE); fChain->SetBranchAddress("Positive_D_Daughter_PX", &Positive_D_Daughter_PX, &b_Positive_D_Daughter_PX); fChain->SetBranchAddress("Positive_D_Daughter_PY", &Positive_D_Daughter_PY, &b_Positive_D_Daughter_PY); fChain->SetBranchAddress("Positive_D_Daughter_PZ", &Positive_D_Daughter_PZ, &b_Positive_D_Daughter_PZ); fChain->SetBranchAddress("Positive_D_Daughter_MM", &Positive_D_Daughter_MM, &b_Positive_D_Daughter_MM); fChain->SetBranchAddress("Positive_D_Daughter_M", &Positive_D_Daughter_M, &b_Positive_D_Daughter_M); fChain->SetBranchAddress("Positive_D_Daughter_ID", &Positive_D_Daughter_ID, &b_Positive_D_Daughter_ID); fChain->SetBranchAddress("Positive_D_Daughter_PIDe", &Positive_D_Daughter_PIDe, &b_Positive_D_Daughter_PIDe); fChain->SetBranchAddress("Positive_D_Daughter_PIDmu", &Positive_D_Daughter_PIDmu, &b_Positive_D_Daughter_PIDmu); fChain->SetBranchAddress("Positive_D_Daughter_PIDK", &Positive_D_Daughter_PIDK, &b_Positive_D_Daughter_PIDK); fChain->SetBranchAddress("Positive_D_Daughter_PIDp", &Positive_D_Daughter_PIDp, &b_Positive_D_Daughter_PIDp); fChain->SetBranchAddress("Positive_D_Daughter_CaloEcalE", &Positive_D_Daughter_CaloEcalE, &b_Positive_D_Daughter_CaloEcalE); fChain->SetBranchAddress("Positive_D_Daughter_CaloHcalE", &Positive_D_Daughter_CaloHcalE, &b_Positive_D_Daughter_CaloHcalE); fChain->SetBranchAddress("Positive_D_Daughter_hasMuon", &Positive_D_Daughter_hasMuon, &b_Positive_D_Daughter_hasMuon); fChain->SetBranchAddress("Positive_D_Daughter_isMuon", &Positive_D_Daughter_isMuon, &b_Positive_D_Daughter_isMuon); fChain->SetBranchAddress("Positive_D_Daughter_hasRich", &Positive_D_Daughter_hasRich, &b_Positive_D_Daughter_hasRich); fChain->SetBranchAddress("Positive_D_Daughter_hasCalo", &Positive_D_Daughter_hasCalo, &b_Positive_D_Daughter_hasCalo); fChain->SetBranchAddress("Positive_D_Daughter_TRACK_Type", &Positive_D_Daughter_TRACK_Type, &b_Positive_D_Daughter_TRACK_Type); fChain->SetBranchAddress("Positive_D_Daughter_TRACK_CHI2NDOF", &Positive_D_Daughter_TRACK_CHI2NDOF, &b_Positive_D_Daughter_TRACK_CHI2NDOF); fChain->SetBranchAddress("Positive_D_Daughter_TRACK_PCHI2", &Positive_D_Daughter_TRACK_PCHI2, &b_Positive_D_Daughter_TRACK_PCHI2); fChain->SetBranchAddress("Positive_D_Daughter_TRACK_GhostProb", &Positive_D_Daughter_TRACK_GhostProb, &b_Positive_D_Daughter_TRACK_GhostProb); fChain->SetBranchAddress("Positive_D_Daughter_TRACK_CloneDist", &Positive_D_Daughter_TRACK_CloneDist, &b_Positive_D_Daughter_TRACK_CloneDist); fChain->SetBranchAddress("nCandidate", &nCandidate, &b_nCandidate); fChain->SetBranchAddress("totCandidates", &totCandidates, &b_totCandidates); fChain->SetBranchAddress("EventInSequence", &EventInSequence, &b_EventInSequence); fChain->SetBranchAddress("runNumber", &runNumber, &b_runNumber); fChain->SetBranchAddress("eventNumber", &eventNumber, &b_eventNumber); fChain->SetBranchAddress("BCID", &BCID, &b_BCID); fChain->SetBranchAddress("OdinTCK", &OdinTCK, &b_OdinTCK); fChain->SetBranchAddress("L0DUTCK", &L0DUTCK, &b_L0DUTCK); fChain->SetBranchAddress("HLTTCK", &HLTTCK, &b_HLTTCK); fChain->SetBranchAddress("nPV", &nPV, &b_nPV); fChain->SetBranchAddress("PVX", PVX, &b_PVX); fChain->SetBranchAddress("PVY", PVY, &b_PVY); fChain->SetBranchAddress("PVZ", PVZ, &b_PVZ); fChain->SetBranchAddress("PVXERR", PVXERR, &b_PVXERR); fChain->SetBranchAddress("PVYERR", PVYERR, &b_PVYERR); fChain->SetBranchAddress("PVZERR", PVZERR, &b_PVZERR); fChain->SetBranchAddress("PVCHI2", PVCHI2, &b_PVCHI2); fChain->SetBranchAddress("PVNDOF", PVNDOF, &b_PVNDOF); fChain->SetBranchAddress("PVNTRACKS", PVNTRACKS, &b_PVNTRACKS); ////////////////////////////////////////////////////////////////// std::cout << "Book" << std::endl; TH1D* h1 = new TH1D("B mass","",30,5200,5500); TH1D* h5 = new TH1D(" D (K#pi) mass","",30,1800,1900); TH1D* h4 = new TH1D(" B mass","",30,5225,5325); TH1D* h2 = new TH1D("D (K#pi) mass","",30,1835,1895); TH1D* b1 = new TH1D("B mass","",30,5200,5500); TH1D* b2 = new TH1D("B p","",30,-10,10); TH1D* b3 = new TH1D("B pt","",30,-10,10); TH1D* d1 = new TH1D("D mass","",30,1800,1900); TH1D* d2 = new TH1D("D p","",30,0,50000); TH1D* d3 = new TH1D("D pt","",30,0,50000); TH1D* ba1 = new TH1D("ba mass","",30,0,600); TH1D* ba2 = new TH1D("ba p","",30,0,50000); TH1D* ba3 = new TH1D("ba pt","",30,0,50000); TH1D* dap1 = new TH1D("da+ mass","",30,0,600); TH1D* dap2 = new TH1D("da+ p","",30,0,50000); TH1D* dap3 = new TH1D("da+ pt","",30,0,50000); TH1D* dan1 = new TH1D("da- mass","",30,0,600); TH1D* dan2 = new TH1D("da- p","",30,0,50000); TH1D* dan3 = new TH1D("da- pt","",30,0,50000); ////////////////////////////////////////////////////////////////// std::cout << "Loop" << std::endl; Long64_t nentries = fChain->GetEntriesFast(); Long64_t nbytes = 0, nb = 0; Int_t oldEvtNr = 999; Int_t counter1 = 0; Int_t counter2 = 0; Int_t counter3 = 0; Int_t counter4 = 0; Int_t counter5 = 0; Int_t counter6 = 0; Int_t counter7 = 0; Int_t counter8 = 0; Int_t counter9 = 0; for (Long64_t jentry=0; jentryGetEntry(jentry); nbytes += nb; Float_t BD_Dist = (sqrt((D_ENDVERTEX_X - B_ENDVERTEX_X)*(D_ENDVERTEX_X - B_ENDVERTEX_X) + (D_ENDVERTEX_Y - B_ENDVERTEX_Y)*(D_ENDVERTEX_Y - B_ENDVERTEX_Y) + (D_ENDVERTEX_Z - B_ENDVERTEX_Z)*(D_ENDVERTEX_Z - B_ENDVERTEX_Z))); Float_t Z_Dist = ((D_ENDVERTEX_Z - B_ENDVERTEX_Z)/sqrt((D_ENDVERTEX_Z - B_ENDVERTEX_Z)*(D_ENDVERTEX_Z - B_ENDVERTEX_Z)))* (sqrt((D_ENDVERTEX_X - B_ENDVERTEX_X)*(D_ENDVERTEX_X - B_ENDVERTEX_X) + (D_ENDVERTEX_Y - B_ENDVERTEX_Y)*(D_ENDVERTEX_Y - B_ENDVERTEX_Y) + (D_ENDVERTEX_Z - B_ENDVERTEX_Z)*(D_ENDVERTEX_Z - B_ENDVERTEX_Z))); counter1++; //D if((D_FDCHI2_OWNPV > 100) && (Z_Dist > -1)){ if(D_ENDVERTEX_CHI2/D_ENDVERTEX_NDOF < 6){ if((D_IPCHI2_OWNPV > 4) && (D_PT > 1000)){ counter2++; //D daughters if(!cutOnDaughters || ( (Positive_D_Daughter_PT > 300) && (Positive_D_Daughter_MINIPCHI2 > 4) && (Negative_D_Daughter_PT > 300) && (Negative_D_Daughter_MINIPCHI2 > 4) && (Negative_D_Daughter_P > 2000) && (Positive_D_Daughter_P > 2000))){ counter3++; //PID if(!cutOnDaughters || ( ((((Negative_D_Daughter_ID == 211) || (Negative_D_Daughter_ID == -211)) && (Negative_D_Daughter_PIDK < 10)) && (((Positive_D_Daughter_ID == 321) || (Positive_D_Daughter_ID == -321)) && (Positive_D_Daughter_PIDK > 10))) || (((((Negative_D_Daughter_ID == 321) || (Negative_D_Daughter_ID == -321)) &&(Negative_D_Daughter_PIDK > 10))) && (((Positive_D_Daughter_ID == 211)||(Positive_D_Daughter_ID==-211))&&(Positive_D_Daughter_PIDK < 10))))){ counter4++; //B if(B_FDCHI2_OWNPV > 100){ if(B_ENDVERTEX_CHI2/B_ENDVERTEX_NDOF < 9){ if(B_IPCHI2_OWNPV < 3.5*3.5){ if(B_DIRA_OWNPV > 0.9998){ counter5++; //Bachelor if(!cutOnDaughters || ( (Bachelor_PT > 350) && (Bachelor_MINIPCHI2 > 4) && (Bachelor_P > 2000) && (((Bachelor_ID == 211) || (Bachelor_ID == -211)) && (Bachelor_PIDK < 10)) || (((Bachelor_ID == 321) || (Bachelor_ID == -321)) && (Bachelor_PIDK > 10)) ) ){ counter6++; if(!cutOnDMass || ((D_M > 1839) && (D_M < 1889))){ counter7++; if(!cutOnEventNr || (oldEvtNr != eventNumber)){ counter8++; oldEvtNr = eventNumber; h1->Fill(B_M); h5->Fill(D_M); } if((B_M > 5225) && (B_M < 5325)){ counter9++; h4->Fill(B_M); h2->Fill(D_M); cout << "There " << eventNumber << " B and D masses " << B_M << " " << D_M << endl; if (plotOthers) { b1->Fill(B_M); b2->Fill(B_P); b3->Fill(B_PT); d1->Fill(D_M); d2->Fill(D_P); d3->Fill(D_PT); ba1->Fill(Bachelor_M); ba2->Fill(Bachelor_P); ba3->Fill(Bachelor_PT); dap1->Fill(Positive_D_Daughter_M); dap2->Fill(Positive_D_Daughter_P); dap3->Fill(Positive_D_Daughter_PT); dan1->Fill(Negative_D_Daughter_M); dan2->Fill(Negative_D_Daughter_P); dan3->Fill(Negative_D_Daughter_PT); } } } } } } } } } } // } // } // } } } } } ///////////////////////////////////////////////////////////////// // Now Draw cout << "Draw" << endl; TString fullFileName = f->GetEndpointUrl()->GetFile(); TCanvas* c1 = new TCanvas("c1","B and D masses in "+fullFileName,1200,800); c1->SetFillColor(0); c1->SetBorderMode(0); c1->Divide(2,3); c1->cd(1); h1->Draw(); c1->cd(2); h5->Draw(); c1->cd(3); h4->Draw(); c1->cd(4); h2->Draw(); c1->cd(5); // --- Fraction of Signal --- RooRealVar my_B("my_B","m_{D#pi} (MeV)",4900,5800); RooRealVar fsig("fsig","signal fraction",0.15,0.0,1.0); //RooRealVar nsig("nsig","#signal events",20,0,160); //RooRealVar nback("nback","#background events",100,0,160); // --- Building Gaussian Signal PDF --- RooRealVar SigMean("sigmamean","B^- mass",5276.,5226,5326); RooRealVar SigWidth("sigwidth","B^- mass width",25.,0.,100.); RooGaussian gauss("gaus","gaussian PDF",my_B,SigMean,SigWidth); // --- Building Polynomial Background PDF --- RooRealVar slope("slope","slope",0.1,-1.0,1.0); RooPolynomial bk("flat","flat",my_B,RooArgList(slope)); // --- Construct signal + Background Pdf --- RooAddPdf model("model","model",RooArgList(gauss,bk),fsig); //RooAddPdf model("model","model",RooArgList(gauss,bk),RooArgList(nsig,nback)); // RooArgList mydata("my Data"); RooDataHist datafromhist("data","data",RooArgList(my_B),h1,1); model.fitTo(datafromhist); // --- Plot the Data and the fit to the data --- RooPlot* Bframe = my_B.frame(); Bframe->SetTitle("B #to D#pi"); datafromhist->plotOn(Bframe); model.plotOn(Bframe); Bframe->Draw(); TCanvas* c2 = new TCanvas("c2","M,P and PT for everything in "+fullFileName,1200,800); c2->SetFillColor(0); c2->SetBorderMode(0); c2->Divide(5,3); c2->cd(1); b1->Draw(); c2->cd(2); d1->Draw(); c2->cd(3); ba1->Draw(); c2->cd(4); dap1->Draw(); c2->cd(5); dan1->Draw(); c2->cd(6); b2->Draw(); c2->cd(7); d2->Draw(); c2->cd(8); ba2->Draw(); c2->cd(9); dap2->Draw(); c2->cd(10); dan2->Draw(); c2->cd(11); b3->Draw(); c2->cd(12); d3->Draw(); c2->cd(13); ba3->Draw(); c2->cd(14); dap3->Draw(); c2->cd(15); dan3->Draw(); // decided to start from 2 not one as counter is the second one Float_t eff2 = ((Float_t)counter2)/((Float_t)counter1); Float_t eff3 = ((Float_t)counter3)/((Float_t)counter2); Float_t eff4 = ((Float_t)counter4)/((Float_t)counter3); Float_t eff5 = ((Float_t)counter5)/((Float_t)counter4); Float_t eff6 = ((Float_t)counter6)/((Float_t)counter5); Float_t eff7 = ((Float_t)counter7)/((Float_t)counter6); Float_t eff8 = ((Float_t)counter8)/((Float_t)counter7); Float_t eff9 = ((Float_t)counter9)/((Float_t)counter8); Float_t overalleff = ((Float_t)counter9)/((Float_t)counter1); Float_t efferr2 = sqrt( (eff2*(1-eff2)) / ((Float_t)counter1) ); Float_t efferr3 = sqrt( (eff3*(1-eff3)) / ((Float_t)counter2) ); Float_t efferr4 = sqrt( (eff4*(1-eff4)) / ((Float_t)counter3) ); Float_t efferr5 = sqrt( (eff5*(1-eff5)) / ((Float_t)counter4) ); Float_t efferr6 = sqrt( (eff6*(1-eff6)) / ((Float_t)counter5) ); Float_t efferr7 = sqrt( (eff7*(1-eff7)) / ((Float_t)counter6) ); Float_t efferr8 = sqrt( (eff8*(1-eff8)) / ((Float_t)counter7) ); Float_t efferr9 = sqrt( (eff9*(1-eff9)) / ((Float_t)counter8) ); Float_t overallefferr = sqrt( (overalleff*(1-overalleff)) / ((Float_t)counter1) ); cout << endl << endl << "Cut info: " << endl; // cout << "1 before cuts: " << counter1 << endl; // using printf and not cout due to cint bug with setw() and other iomanip functs printf("%-3i before cuts: %8i\n", 1, counter1); printf("%-3i after D cut: %8i %6.2f%% +/- %6.2f%%\n", 2, counter2, 100.*eff2, 100.*efferr2); printf("%-3i D daughter : %8i %6.2f%% +/- %6.2f%%\n", 3, counter3, 100.*eff3, 100.*efferr3); printf("%-3i after PID : %8i %6.2f%% +/- %6.2f%%\n", 4, counter4, 100.*eff4, 100.*efferr4); printf("%-3i after B cut: %8i %6.2f%% +/- %6.2f%%\n", 5, counter5, 100.*eff5, 100.*efferr5); printf("%-3i bachelor : %8i %6.2f%% +/- %6.2f%%\n", 6, counter6, 100.*eff6, 100.*efferr6); printf("%-3i D mass : %8i %6.2f%% +/- %6.2f%%\n", 7, counter7, 100.*eff7, 100.*efferr7); printf("%-3i event num: %8i %6.2f%% +/- %6.2f%%\n", 8, counter8, 100.*eff8, 100.*efferr8); printf("%-3i B mass : %8i %6.2f%% +/- %6.2f%%\n", 9, counter9, 100.*eff9, 100.*efferr9); printf(" Overall Eff: %15.2f%% +/- %6.2f%%\n", 100.*overalleff, 100.*overallefferr); // cout << "2 after D cut: " << counter2 << endl; // cout << " Eff: " << 100.*eff2 << "% +/- " << 100.*efferr2 << endl; // cout << "3 D daughter : " << counter3 << endl; // cout << " Eff: " << 100.*eff3 << "% +/- " << 100.*efferr3 << endl; // cout << "4 after PID : " << counter4 << endl; // cout << " Eff: " << 100.*eff4 << "% +/- " << 100.*efferr4 << endl; // cout << "5 after B cut: " << counter5 << endl; // cout << " Eff: " << 100.*eff5 << "% +/- " << 100.*efferr5 << endl; // cout << "6 bachelor : " << counter6 << endl; // cout << " Eff: " << 100.*eff6 << "% +/- " << 100.*efferr6 << endl; // cout << "7 D mass : " << counter7 << endl; // cout << " Eff: " << 100.*eff7 << "% +/- " << 100.*efferr7 << endl; // cout << "8 event num: " << counter8 << endl; // cout << " Eff: " << 100.*eff8 << "% +/- " << 100.*efferr8 << endl; // cout << "9 B mass : " << counter9 << endl; // cout << " Eff: " << 100.*eff9 << "% +/- " << 100.*efferr9 << endl; // cout << " Overall Eff: " << 100.*overalleff << "% +/- " << 100.*overallefferr << endl; }