]> git.uio.no Git - u/mrichter/AliRoot.git/blame - STEER/ESD/AliESDMuonGlobalTrack.h
remove the setting of the maximum number of super modules from the class, recover...
[u/mrichter/AliRoot.git] / STEER / ESD / AliESDMuonGlobalTrack.h
CommitLineData
d3eabe96 1#ifndef AliESDMuonGlobalTrack_H
2#define AliESDMuonGlobalTrack_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7//====================================================================================================================================================
8//
9// ESD description of an ALICE muon forward track, combining the information of the Muon Spectrometer and the Muon Forward Tracker
10//
11// Contact author: antonio.uras@cern.ch
12//
13//====================================================================================================================================================
14
15#include "TMath.h"
16#include "TMatrixD.h"
17#include "TDatabasePDG.h"
18#include "TArrayI.h"
19#include "TLorentzVector.h"
393f6a0d 20#include "AliESDVertex.h"
21#include "TRef.h"
d3eabe96 22
23#include "AliVParticle.h"
24
25class AliESDEvent;
26class TClonesArray;
27
28//====================================================================================================================================================
29
30class AliESDMuonGlobalTrack : public AliVParticle {
31
32public:
33
34 AliESDMuonGlobalTrack();
35 AliESDMuonGlobalTrack(Double_t px, Double_t py, Double_t pz);
36 virtual ~AliESDMuonGlobalTrack() {;}
37 AliESDMuonGlobalTrack(const AliESDMuonGlobalTrack& esdTrack);
38 AliESDMuonGlobalTrack& operator=(const AliESDMuonGlobalTrack& esdTrack);
39 virtual void Copy(TObject &obj) const;
40
41 void SetCharge(Int_t charge) { fCharge = charge; }
42 Short_t GetCharge() const { return fCharge; }
43
44 /* Double_t GetOffset(Double_t x, Double_t y, Double_t z); */
45 /* Double_t GetOffsetX(Double_t x, Double_t z); */
46 /* Double_t GetOffsetY(Double_t y, Double_t z); */
47
48 // Set and Get methods for kinematics at primary vertex
49 void SetPxPyPz(Double_t px, Double_t py, Double_t pz);
50
51 // Get and Set methods for global tracking info
f7cc8591 52 Double_t GetChi2OverNdf() const { return fChi2OverNdf; } // chi2/ndf
53 void SetChi2OverNdf(Double_t chi2) { fChi2OverNdf = chi2; } // chi2/ndf
54
55 Double_t GetChi2MatchTrigger() const { return fChi2MatchTrigger; }
56 void SetChi2MatchTrigger(Double_t chi2MatchTrigger) { fChi2MatchTrigger = chi2MatchTrigger; }
57
58 // Get and Set methods for various info copied and pasted from the MUON track
59 UShort_t GetHitsPatternInTrigCh() const {return fHitsPatternInTrigCh;}
60 void SetHitsPatternInTrigCh(UShort_t hitsPatternInTrigCh) {fHitsPatternInTrigCh = hitsPatternInTrigCh;}
61 UInt_t GetHitsPatternInTrigChTrk() const {return fHitsPatternInTrigChTrk;}
62 void SetHitsPatternInTrigChTrk(UInt_t hitsPatternInTrigChTrk) {fHitsPatternInTrigChTrk = hitsPatternInTrigChTrk;}
63 UInt_t GetMuonClusterMap() const {return fMuonClusterMap;}
64 void SetMuonClusterMap(UInt_t muonClusterMap) {fMuonClusterMap = muonClusterMap;}
65 Int_t GetLoCircuit() const { return fLoCircuit; }
66 void SetLoCircuit(Int_t loCircuit) { fLoCircuit = loCircuit; }
67 Bool_t IsConnected() const { return fIsConnected; }
68 void Connected(Bool_t flag) { fIsConnected = flag; }
69
d3eabe96 70 // Get and Set methods for trigger matching
71 void SetMatchTrigger(Int_t matchTrigger) { fMatchTrigger = matchTrigger; }
72 Int_t GetMatchTrigger() { return fMatchTrigger; }
73
f7cc8591 74 void SetNMFTClusters(Int_t nMFTClusters) { fNMFTClusters = nMFTClusters; }
75 Short_t GetNMFTClusters() { return fNMFTClusters; }
76
77 void SetNWrongMFTClustersMC(Int_t nWrongMFTClustersMC) { fNWrongMFTClustersMC = nWrongMFTClustersMC; }
78 Short_t GetNWrongMFTClustersMC() { return fNWrongMFTClustersMC; }
79
80 void SetMFTClusterPattern(ULong_t mftClusterPattern) { fMFTClusterPattern = mftClusterPattern; }
81 ULong_t GetMFTClusterPattern() { return fMFTClusterPattern; }
82
d3eabe96 83 // Kinematics
84 Double_t Pt() const { return fPt; }
85 Double_t Eta() const { return fEta; }
86 Double_t Rapidity() const { return fRapidity; }
87 Double_t Px() const { return fPx; }
88 Double_t Py() const { return fPy; }
89 Double_t Pz() const { return fPz; }
90 Double_t P() const { return fP; }
91
92 Bool_t PxPyPz(Double_t p[3]) const { p[0] = Px(); p[1] = Py(); p[2] = Pz(); return kTRUE; }
93
f7cc8591 94 void SetFirstTrackingPoint(Double_t x, Double_t y, Double_t z) {fFirstTrackingPointX = x; fFirstTrackingPointY = y; fFirstTrackingPointZ = z; }
95 void GetFirstTrackingPoint(Double_t x[3]) { x[0] = fFirstTrackingPointX; x[1] = fFirstTrackingPointY; x[2] = fFirstTrackingPointZ; }
96
97 void SetXYAtVertex(Double_t x, Double_t y) { fXAtVertex = x; fYAtVertex = y; }
98 void GetXYAtVertex(Double_t x[2]) { x[0] = fXAtVertex; x[1] = fYAtVertex; }
99
100 Double_t GetRAtAbsorberEnd() { return fRAtAbsorberEnd; }
101 void SetRAtAbsorberEnd(Double_t r) { fRAtAbsorberEnd = r; }
102
d3eabe96 103 // Additional methods to comply with AliVParticle
104 Double_t Xv() const {return -999.;} // put reasonable values here
105 Double_t Yv() const {return -999.;} //
106 Double_t Zv() const {return -999.;} //
107 Bool_t XvYvZv(Double_t x[3]) const { x[0] = Xv(); x[1] = Yv(); x[2] = Zv(); return kTRUE; }
108 Double_t OneOverPt() const { return (Pt() != 0.) ? 1./Pt() : FLT_MAX; }
109 Double_t Phi() const { return TMath::Pi()+TMath::ATan2(-Py(), -Px()); }
110 Double_t Theta() const { return TMath::ATan2(Pt(), Pz()); }
111 Double_t E() const { return TMath::Sqrt(M()*M() + P()*P()); }
112 Double_t M() const { return TDatabasePDG::Instance()->GetParticle("mu-")->Mass(); }
113 Double_t Y() const { return Rapidity(); }
114 Short_t Charge() const { return fCharge; }
115
f7cc8591 116 // Return kTRUE if the track contain tracker data
117 Bool_t ContainTrackerData() const {return (fMuonClusterMap>0) ? kTRUE : kFALSE;}
118
d3eabe96 119 // Dummy
120 const Double_t *PID() const { return (Double_t*)0x0; }
121 Int_t PdgCode() const { return 0; }
122
123 // Set the corresponding MC track number
124 void SetLabel(Int_t label) { fLabel = label; }
125 // Return the corresponding MC track number
126 Int_t GetLabel() const { return fLabel; }
127
393f6a0d 128 void SetProdVertexXYZ(Double_t x, Double_t y, Double_t z) { fProdVertexXYZ[0]=x; fProdVertexXYZ[1]=y; fProdVertexXYZ[2]=z; }
129 void GetProdVertexXYZ(Double_t *vertex) { vertex[0]=fProdVertexXYZ[0]; vertex[1]=fProdVertexXYZ[1]; vertex[2]=fProdVertexXYZ[2]; }
130
9562d53c 131 const TMatrixD& GetCovariances() const;
132 void SetCovariances(const TMatrixD& covariances);
133
d3eabe96 134 AliESDEvent* GetESDEvent() const { return fESDEvent; }
135 void SetESDEvent(AliESDEvent* evt) { fESDEvent = evt; }
136
137protected:
138
f7cc8591 139 Short_t fCharge, fMatchTrigger, fNMFTClusters, fNWrongMFTClustersMC;
140 ULong_t fMFTClusterPattern; // Tells us which MFT clusters are contained in the track, and which one is a good one (if MC)
d3eabe96 141
142 // kinematics at vertex
143 Double_t fPx, fPy, fPz, fPt, fP, fEta, fRapidity;
144
f7cc8591 145 // coordinates of the first tracking point
146 Double_t fFirstTrackingPointX, fFirstTrackingPointY, fFirstTrackingPointZ;
147
148 // transverse coordinates at DCA to the primary vertex (offset)
149 Double_t fXAtVertex, fYAtVertex;
150
151 Double_t fRAtAbsorberEnd;
152
9562d53c 153 mutable TMatrixD *fCovariances; // Covariance matrix of track parameters (see AliMUONTrackParam)
154
d3eabe96 155 // global tracking info
f7cc8591 156 Double_t fChi2OverNdf; // chi2/ndf in the MUON+MFT track fit
157 Double_t fChi2MatchTrigger; // chi2 of trigger/track matching
d3eabe96 158
f7cc8591 159 Int_t fLabel; // point to the corresponding MC track
d3eabe96 160
f7cc8591 161 UInt_t fMuonClusterMap; // Map of clusters in MUON tracking chambers
162 UShort_t fHitsPatternInTrigCh; // Word containing info on the hits left in trigger chambers
163 UInt_t fHitsPatternInTrigChTrk; // Trigger hit map from tracker track extrapolation
164 Int_t fLoCircuit;
165 Bool_t fIsConnected;
166
393f6a0d 167 Double_t fProdVertexXYZ[3]; // vertex of origin
168
f7cc8591 169 AliESDEvent *fESDEvent; //! Pointer back to event to which the track belongs
d3eabe96 170
9562d53c 171 ClassDef(AliESDMuonGlobalTrack,4) // MUON+MFT ESD track class
d3eabe96 172
173};
174
175//====================================================================================================================================================
176
177#endif