2 // Main author: Davide Caffarri 2009
3 // Base header class to HF visualization
5 /**************************************************************************
6 * Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
7 * See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
8 * full copyright notice. *
9 **************************************************************************/
14 #include "AliAODRecoDecay.h"
15 #include "AliEveTrack.h"
17 #include <TEveVSDStructs.h>
18 #include <TPolyLine3D.h>
29 class AliEveHF : public TEvePointSet
31 friend class AliEveHFList; //friend class for the list of HF in the same event
32 friend class AliEveHFEditor; //friend class for the list of HF visualization
36 AliEveHF(TEveRecTrack* tNeg, TEveRecTrack* tPos, Double_t primVtx[3], AliAODRecoDecay* aodObj, TEveTrackPropagator* rs);
41 virtual void SetMainColor(Color_t col)
43 TEvePointSet::SetMainColor(col);
44 fPointingLine->SetLineColor(fMarkerColor);
47 void SetRnrStyle(TEveTrackPropagator* rs) { fRnrStyle = rs; }
51 Float_t GetPhi() { return fRecDecayHF.Phi(); }
52 Float_t GetEta() { return fRecDecayMomHF.Eta(); }
53 Float_t GetRadius() { return fRecDecayHF.Perp(); }
54 Float_t GetPt() { return fRecDecayMomHF.Perp(); }
56 Double_t GetInvariantMassPart() { CalculateInvMass(fDecay); return fInvariantMassPart; }
57 Double_t GetInvariantMassAntiPart() { CalculateInvMass(fDecay); return fInvariantMassAntiPart; }
59 Float_t GetChi2Vtx() const { return fChi2SecondVtx; }
60 Float_t GetCosPointingAngle() const {return fPointingAngleHF; }
62 AliAODRecoDecay *GetAODobj() const {return fAODobj; }
64 Int_t GetAODIndex() const { return fAODIndex; }
65 void SetAODIndex(Int_t ind) { fAODIndex = ind;}
67 virtual const Text_t* GetName() const { return Form("AOD_HF_%i",fAODIndex); }
68 virtual const Text_t* GetTitle() const { return Form("AOD_HF_%i",fAODIndex); }
72 Double_t GetProngDCA(Int_t iProng)const { return fProngDCA[iProng]; }
73 void SetProngDCA() const ;
75 Double_t Getd0Prong(Int_t iProng)const { return fProngd0[iProng]; }
76 void Setd0Prong() const ;
78 void CalculateInvMass(Int_t decay);
80 Bool_t SelectInvMass(Int_t decay, Float_t decayCuts);
82 void SetMaxProbPdgPid();
83 Int_t GetPdgProngMaxProb(Int_t iProng)const { return fProngMaxProbPdg[iProng]; }
84 Double_t GetPidProngMaxProb(Int_t iProng)const { return fProngMaxProbPid[iProng]; }
86 TEveTrackPropagator* GetPropagator() const { return fRnrStyle; }
88 TEveTrack* GetNegTrack()const { return fNegTrack; }
89 TEveTrack* GetPosTrack()const { return fPosTrack; }
91 TEveLine* GetPointingLine()const { return fPointingLine; }
95 AliAODRecoDecay *fAODobj; //AOD object of the HF decay.
97 TEveVector fRecBirthHF; // Reconstucted birth point of neutral particle
98 TEveVector fRecDecayHF; // Point of closest approach
99 TEveVector fRecDecayMomHF; // Momentum of the HF
100 Double_t fPointingAngleHF; // Track Pointing Angle
102 TEveTrack *fNegTrack; //Negative daughter of the HF
103 TEveTrack *fPosTrack; //Positive daughter of the HF
105 TEveTrackPropagator *fRnrStyle; //Eve propagator for the track
107 TEveLine *fPointingLine; //Flight Line of the HF
109 Int_t fnProng; // Number of Prong.
110 Int_t fAODIndex; // Index in HF loop array.
111 Double_t fChi2SecondVtx; //Secondary Vertex Chi-square.
113 Double_t *fProngDCA;//[fnProng] Distance at the point of closest approach.
114 Double_t *fProngd0;//[fnProng] Impact Paramter if each prong.
115 Int_t *fProngMaxProbPdg;//[fnProng] Maximum PDG probability for the negative daughter
116 Double_t *fProngMaxProbPid;//[fnProng] Maximum PID probability for the negative daughter
118 Double_t fInvariantMassPart; //Invariant Mass of the particle
119 Double_t fInvariantMassAntiPart; //Invariant Mass of the Antiparticle
121 Int_t fDecay; //Index for the type of decay
124 AliEveHF(const AliEveHF&); // Not implemented
125 AliEveHF& operator=(const AliEveHF&); // Not implemented
127 ClassDef(AliEveHF,0); // Visual representation of a AliEveHF.
131 /******************************************************************************/
133 /******************************************************************************/
134 class AliEveHFList : public TEveElementList
136 friend class AliEveHFListEditor; //Class for the list of HF visualization
141 AliEveHFList(TEveTrackPropagator* rs);
142 AliEveHFList(const Text_t* name, TEveTrackPropagator* rs=0);
143 virtual ~AliEveHFList() {}
145 virtual const Text_t* GetTitle() const { return fTitle; }
146 virtual void SetTitle(const Text_t* t) { fTitle = t; }
147 virtual void SetTracksColor(Color_t cNeg, Color_t cPos, Int_t ip)
148 {fProngColor[ip] = cNeg; fProngColor[ip++] = cPos;}
150 virtual Bool_t CanEditMainColor() const { return kTRUE; }
152 void SetRnrStyle(TEveTrackPropagator* rst) { fRnrStyle = rst; }
153 TEveTrackPropagator* GetPropagator() { return fRnrStyle; }
155 Bool_t GetRnrHFvtx() const { return fRnrHFvtx; }
156 Bool_t GetRnrHFpath() const { return fRnrHFpath; }
157 Bool_t GetRnrDaughters() const { return fRnrDaughters; }
161 void FilterByPt(Float_t minPt, Float_t maxPt);
162 void FilterByRadius(Float_t minR, Float_t maxR);
163 void FilterByCosPointingAngle(Float_t minCosPointingAngle, Float_t maxCosPointingAngle);
164 void FilterByDCA(Float_t minDaughterDCA, Float_t maxDaughterDCA);
165 void FilterByd0(Float_t mind0, Float_t maxd0);
166 //void FilterByCheckedPidMinProb(Int_t rFlag, Int_t rDaughter, Int_t rPid, Float_t rProb);
168 // void SetProngCheckedPid(Int_t rProngCheckedPid) const;
169 Int_t GetProngCheckedPid(Int_t iProng) {return fProngCheckedPid[iProng];}
170 // void SetProngCheckedProb(Float_t rProngCheckedProb) const;
171 // Float_t GetProngCheckedProb(Int_t iProng) const { return fProngCheckedProb[iProng]; }
173 void FilterByInvariantMass (Int_t decay, Float_t deltaInvariantMass);
178 TEveTrackPropagator *fRnrStyle;
180 Bool_t fRnrDaughters; //variable for HF daughters visualization
181 Bool_t fRnrHFvtx; //variable for the HF vertex visualization
182 Bool_t fRnrHFpath; //variable for the visualization of the HF line
184 Color_t* fProngColor;//[fnProng]
186 Float_t fMinRCut; //minimum cut for the radius
187 Float_t fMaxRCut; //maximum cut for the radius
189 Float_t fMinDaughterDCA; //minimum cut for the DCA of the daughter particles
190 Float_t fMaxDaughterDCA; //maximum cut for the DCA of the daughter particles
192 Float_t fMinPt; //minimum cut for the Pt
193 Float_t fMaxPt; //maximum cut for the Pt
195 Float_t fMinCosPointingAngle; //minimum cut for the cosine of the pointing angle
196 Float_t fMaxCosPointingAngle; //maximum cut for the cosine of the pointing angle
198 Float_t fMind0; //minimum cut for the impact parameter
199 Float_t fMaxd0; //maximum cut for the impact parameter
201 Int_t* fProngCheckedPid;//[fnProng]
203 Float_t* fProngCheckedProb;//[fnProng]
205 Float_t fDeltaInvariantMass; //invariant mass window to select the candidate
206 Int_t fDecay; //index for the type of decay
211 AliEveHFList(const AliEveHFList&); // Not implemented
212 AliEveHFList& operator=(const AliEveHFList&); // Not implemented
214 ClassDef(AliEveHFList,0); // A list of AliEveHF objecs.