]>
Commit | Line | Data |
---|---|---|
e806e863 | 1 | #ifndef AliMuonForwardTrackAnalysis_H |
2 | #define AliMuonForwardTrackAnalysis_H | |
3 | ||
4 | //==================================================================================================================================================== | |
5 | // | |
6 | // Class for the analysis of the ALICE muon forward tracks (MUON + MFT) | |
7 | // | |
8 | // Contact author: antonio.uras@cern.ch | |
9 | // | |
10 | //==================================================================================================================================================== | |
11 | ||
12 | #include "TObject.h" | |
13 | #include "TClonesArray.h" | |
14 | #include "AliMuonForwardTrack.h" | |
6240bf36 | 15 | #include "AliMuonForwardTrackPair.h" |
e806e863 | 16 | #include "TMatrixD.h" |
17 | #include "TTree.h" | |
18 | #include "TH1D.h" | |
19 | #include "TH2D.h" | |
6c24c9fd | 20 | #include "TH3D.h" |
e806e863 | 21 | #include "AliLog.h" |
22 | #include "TFile.h" | |
23 | #include "TParticle.h" | |
24 | #include "AliMUONTrackParam.h" | |
25 | #include "AliMUONTrackExtrap.h" | |
26 | #include "TDatabasePDG.h" | |
b5ab1ac4 | 27 | #include "TGraph.h" |
cd2f51d2 | 28 | #include "TAxis.h" |
e806e863 | 29 | |
30 | //==================================================================================================================================================== | |
31 | ||
32 | class AliMuonForwardTrackAnalysis : public TObject { | |
33 | ||
34 | public: | |
35 | ||
6240bf36 | 36 | enum {kNoOption, kResonanceOnly, kCharmOnly, kBeautyOnly, kBackground1mu, kBackground2mu, kNoResonances}; |
37 | enum {kSingleEvent, kMixedEvent}; | |
e806e863 | 38 | |
39 | AliMuonForwardTrackAnalysis(); | |
40 | ||
41 | virtual ~AliMuonForwardTrackAnalysis() {}; // destructor | |
42 | ||
43 | Bool_t Init(Char_t *inputFileName); | |
44 | Bool_t LoadNextEvent(); | |
45 | void Terminate(Char_t *outputFileName); | |
46 | ||
47 | void BookHistos(); | |
48 | ||
49 | void SetInputDir(Char_t *inputDir) { fInputDir = inputDir; } | |
50 | void SetOutputDir(Char_t *outputDir) { fOutputDir = outputDir; } | |
51 | ||
52 | Int_t GetNTracksAnalyzed() { return fNTracksAnalyzed; } | |
53 | ||
cabfe25b | 54 | void SetMassRange(Double_t min, Double_t max) { fMassMin=min; fMassMax=max; } |
55 | void SetTrueMass(Double_t mass) { fTrueMass = mass; } | |
e806e863 | 56 | void SetSingleMuonAnalysis(Bool_t singleMuonAnalysis) { fSingleMuonAnalysis = singleMuonAnalysis; } |
57 | void SetMuonPairAnalysis(Bool_t muonPairAnalysis) { fMuonPairAnalysis = muonPairAnalysis; } | |
cabfe25b | 58 | void SetMatchTrigger(Int_t triggerLevel) { fTriggerLevel = triggerLevel; } |
e806e863 | 59 | |
60 | Bool_t AnalyzeSingleMuon(); | |
6240bf36 | 61 | Bool_t AnalyzeMuonPair(Int_t opt); |
e806e863 | 62 | void BuildMuonPairs(); |
6240bf36 | 63 | void BuildMuonPairsMix(); |
e806e863 | 64 | |
789c2e43 | 65 | void EvalDimuonVtxResolution(Bool_t eval) { fEvalDimuonVtxResolution = eval; } |
66 | ||
7e3dd1af | 67 | Bool_t PassedCutSingleMuon(AliMuonForwardTrack *track); |
68 | Bool_t PassedCutMuonPair(AliMuonForwardTrackPair *pair); | |
69 | ||
e806e863 | 70 | void SetVertResMC(Double_t xRes, Double_t yRes, Double_t zRes) { fXVertResMC=xRes; fYVertResMC=yRes; fZVertResMC=zRes; } |
71 | ||
72 | void SetOption(Int_t option) { fOption = option; } | |
cabfe25b | 73 | |
e806e863 | 74 | void SetMaxNWrongClustersMC(Int_t nClusters) { fMaxNWrongClustersMC = nClusters; } |
6240bf36 | 75 | void SetMinPtSingleMuons(Double_t ptMin) { fMinPtSingleMuons = ptMin; } |
ca5d8012 | 76 | void SetEtaRangeSingleMuons(Double_t min, Double_t max) { fMinEtaSingleMuons=min; fMaxEtaSingleMuons=max; } |
cabfe25b | 77 | void SetMaxChi2SingleMuons(Double_t chi2Max) { fMaxChi2SingleMuons = chi2Max; } |
78 | void SetMaxOffsetSingleMuons(Double_t offsetMax) { fMaxOffsetSingleMuons = offsetMax; } | |
79 | void CorrelateCutOnOffsetChi2(Bool_t option) { fCorrelateCutOnOffsetChi2 = option; } | |
80 | ||
81 | void SetMaxWOffsetMuonPairsAtPrimaryVtx(Double_t wOffsetMax) { fMaxWOffsetMuonPairsAtPrimaryVtx = wOffsetMax; } | |
82 | void SetMaxWOffsetMuonPairsAtPCA(Double_t wOffsetMax) { fMaxWOffsetMuonPairsAtPCA = wOffsetMax; } | |
83 | void SetMaxDistancePrimaryVtxPCA(Double_t distanceMax) { fMaxDistancePrimaryVtxPCA = distanceMax; } | |
84 | void SetMinPCAQuality(Double_t minQuality) { fMinPCAQuality = minQuality; } | |
e806e863 | 85 | |
86 | void ReadEvents(Int_t firstEv, Int_t lastEv) { fFirstEvent = firstEv; fLastEvent = lastEv; } | |
87 | Int_t GetFirstEvent() { return fFirstEvent; } | |
88 | Int_t GetLastEvent() { return fLastEvent; } | |
89 | ||
7e3dd1af | 90 | void UseBransonForCut(Bool_t useBranson) { fUseBransonForCut = useBranson; } |
91 | void UseBransonForKinematics(Bool_t useBranson) { fUseBransonForKinematics = useBranson; } | |
7e3dd1af | 92 | |
cabfe25b | 93 | Double_t GetPseudoProperDecayLength(AliMuonForwardTrackPair *pair, Double_t trueMass); |
e806e863 | 94 | |
6240bf36 | 95 | void SetNEventsToMix(Int_t nEvents) { fNEventsToMix = nEvents; if (0<fNEventsToMix && fNEventsToMix<100) fMixing = kTRUE; } |
96 | ||
cabfe25b | 97 | private: |
e806e863 | 98 | |
99 | TString fInputDir, fOutputDir; | |
100 | ||
6240bf36 | 101 | TTree *fInputTreeWithBranson, *fInputTreeWithoutBranson; //! |
e806e863 | 102 | |
6240bf36 | 103 | TClonesArray *fMuonForwardTracksWithBranson, *fMuonForwardTracksWithBransonMix, *fMuonForwardTrackPairsWithBranson; //! |
104 | TClonesArray *fMuonForwardTracksWithoutBranson, *fMuonForwardTracksWithoutBransonMix, *fMuonForwardTrackPairsWithoutBranson; //! | |
7e3dd1af | 105 | AliMuonForwardTrack *fMFTTrackWithBranson, *fMFTTrackWithoutBranson, *fMFTTrack; //! |
106 | AliMuonForwardTrackPair *fMFTTrackPairWithBranson, *fMFTTrackPairWithoutBranson, *fMFTTrackPair; //! | |
107 | TParticle *fMCRefTrack; //! | |
e806e863 | 108 | |
6240bf36 | 109 | Int_t fEv, fEvMix, fFirstEvent, fLastEvent, fNTracksOfEvent, fNTracksAnalyzedOfEvent, fNTracksAnalyzed, fNPairsOfEvent, fNPairsAnalyzedOfEvent; |
d8c2cc3e | 110 | Int_t fNTracksAnalyzedOfEventAfterCut, fNPairsAnalyzedOfEventAfterCut; |
e806e863 | 111 | |
6c24c9fd | 112 | TH3D *fHistXOffsetSingleMuonsVsEtaVsP, *fHistYOffsetSingleMuonsVsEtaVsP, *fHistOffsetSingleMuonsVsEtaVsP, *fHistWOffsetSingleMuonsVsEtaVsP; //! |
113 | TH3D *fHistXOffsetSingleMuonsVsEtaVsPt, *fHistYOffsetSingleMuonsVsEtaVsPt, *fHistOffsetSingleMuonsVsEtaVsPt, *fHistWOffsetSingleMuonsVsEtaVsPt; //! | |
114 | TH3D *fHistXErrorSingleMuonsVsEtaVsP, *fHistYErrorSingleMuonsVsEtaVsP; //! | |
115 | TH3D *fHistXErrorSingleMuonsVsEtaVsPt, *fHistYErrorSingleMuonsVsEtaVsPt; //! | |
d8c2cc3e | 116 | TH1D *fHistZOriginSingleMuonsMC; |
117 | ||
cabfe25b | 118 | TH2D *fHistZROriginSingleMuonsMC, *fHistSingleMuonsPtRapidity, *fHistSingleMuonsOffsetChi2; //! |
119 | ||
6240bf36 | 120 | TH2D *fHistMassMuonPairsMCVsPt; //! |
121 | TH2D *fHistDimuonVtxResolutionXVsPt; //! | |
122 | TH2D *fHistDimuonVtxResolutionYVsPt; //! | |
123 | TH2D *fHistDimuonVtxResolutionZVsPt; //! | |
124 | ||
125 | TH2D *fHistRapidityPtMuonPairs[2]; //! | |
6c24c9fd | 126 | TH2D *fHistMassMuonPairsVsPt[2]; //! |
6240bf36 | 127 | TH2D *fHistMassMuonPairsWithoutMFTVsPt[2]; //! |
128 | TH2D *fHistMassMuonPairsVsPtLSp[2]; //! | |
129 | TH2D *fHistMassMuonPairsWithoutMFTVsPtLSp[2]; //! | |
130 | TH2D *fHistMassMuonPairsVsPtLSm[2]; //! | |
131 | TH2D *fHistMassMuonPairsWithoutMFTVsPtLSm[2]; //! | |
132 | ||
133 | TH2D *fHistWOffsetMuonPairsAtPrimaryVtxVsPt[2]; //! | |
134 | TH2D *fHistWOffsetMuonPairsAtPCAVsPt[2]; //! | |
135 | TH2D *fHistDistancePrimaryVtxPCAVsPt[2]; //! | |
136 | TH2D *fHistPCAQualityVsPt[2]; //! | |
137 | TH2D *fHistPseudoProperDecayLengthVsPt[2]; //! | |
138 | ||
789c2e43 | 139 | Bool_t fEvalDimuonVtxResolution; |
140 | ||
cabfe25b | 141 | Double_t fTrueMass, fMassMin, fMassMax; |
e806e863 | 142 | |
cabfe25b | 143 | Bool_t fSingleMuonAnalysis, fMuonPairAnalysis; |
144 | Int_t fOption, fTriggerLevel; | |
e806e863 | 145 | |
146 | Double_t fXVertResMC, fYVertResMC, fZVertResMC; | |
7e3dd1af | 147 | Double_t fPrimaryVtxX, fPrimaryVtxY, fPrimaryVtxZ; |
e806e863 | 148 | Int_t fMaxNWrongClustersMC; |
ca5d8012 | 149 | Double_t fMinPtSingleMuons, fMinEtaSingleMuons, fMaxEtaSingleMuons; |
e806e863 | 150 | |
cabfe25b | 151 | Bool_t fUseBransonForCut, fUseBransonForKinematics, fCorrelateCutOnOffsetChi2; |
7e3dd1af | 152 | |
cabfe25b | 153 | Double_t fMaxChi2SingleMuons, fMaxOffsetSingleMuons; |
154 | Double_t fMaxWOffsetMuonPairsAtPrimaryVtx, fMaxWOffsetMuonPairsAtPCA, fMaxDistancePrimaryVtxPCA, fMinPCAQuality; | |
7e3dd1af | 155 | |
6240bf36 | 156 | Bool_t fMixing; |
157 | Int_t fNEventsToMix; | |
158 | ||
e806e863 | 159 | ClassDef(AliMuonForwardTrackAnalysis, 1) |
160 | ||
161 | }; | |
162 | ||
163 | //==================================================================================================================================================== | |
164 | ||
165 | #endif | |
166 |