Bug in DQM agent resetting solved
[u/mrichter/AliRoot.git] / MUON / AliMUONTrackHitPattern.h
CommitLineData
7771752e 1#ifndef ALIMUONTRACKHITPATTERN_H
2#define ALIMUONTRACKHITPATTERN_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
ea94c18b 6/*$Id$*/
7
7771752e 8/// \ingroup rec
9/// \class AliMUONTrackHitPattern
10/// \brief Class for the MUON track hit pattern
11///
12// Author: Diego Stocco
13
14#include <TObject.h>
683cb6c5 15#include <TMatrixD.h>
16#include <TArrayI.h>
17#include <TArrayF.h>
7771752e 18
7ec3b9cf 19class AliMUONVTrackStore;
20class AliMUONVTriggerStore;
683cb6c5 21class AliMUONVTriggerTrackStore;
7771752e 22class AliMUONTrackParam;
a721d89c 23class AliMUONDigitMaker;
7771752e 24class AliMUONGeometryTransformer;
7ec3b9cf 25class AliMUONVDigitStore;
683cb6c5 26class AliMUONTriggerTrack;
27class AliMUONTrack;
a0dc65b4 28class AliMUONRecoParam;
7771752e 29
7ec3b9cf 30class AliMUONTrackHitPattern : public TObject
31{
7771752e 32public:
7ec3b9cf 33
a0dc65b4 34 AliMUONTrackHitPattern(const AliMUONRecoParam* recoParam,
35 const AliMUONGeometryTransformer& transformer,
7ec3b9cf 36 const AliMUONDigitMaker& digitMaker);
37 virtual ~AliMUONTrackHitPattern(); // Destructor
7ec3b9cf 38
9b1e069f 39 void ExecuteValidation(const AliMUONVTrackStore& trackStore,
683cb6c5 40 const AliMUONVTriggerTrackStore& triggerTrackStore,
41 const AliMUONVTriggerStore& triggerStore) const;
42
43 AliMUONTriggerTrack* MatchTriggerTrack(AliMUONTrack* track,
44 AliMUONTrackParam& trackParam,
45 const AliMUONVTriggerTrackStore& triggerTrackStore,
46 const AliMUONVTriggerStore& triggerStore) const;
67c201be 47
54355f2c 48 UShort_t GetHitPattern(AliMUONTriggerTrack* matchedTriggerTrack,
67c201be 49 AliMUONVDigitStore& digitStore) const;
50
51 UShort_t GetHitPattern(AliMUONTrackParam* trackParam,
52 AliMUONVDigitStore& digitStore) const;
683cb6c5 53
683cb6c5 54protected:
55 void ApplyMCSCorrections(AliMUONTrackParam& trackParam) const;
56
683cb6c5 57 // Methods for hit pattern from tracker track
9b1e069f 58 void FindPadMatchingTrack(const AliMUONVDigitStore& digitStore,
683cb6c5 59 const AliMUONTrackParam& trackParam,
60 Bool_t isMatch[2], Int_t iChamber) const;
61
62 Float_t MinDistanceFromPad(Float_t xPad, Float_t yPad, Float_t zPad,
63 Float_t dpx, Float_t dpy,
64 const AliMUONTrackParam& trackParam) const;
7771752e 65
683cb6c5 66 // Methods for hit pattern from matched trigger track
67 Bool_t PerformTrigTrackMatch(UShort_t &pattern,
9b1e069f 68 const AliMUONTriggerTrack* matchedTrigTrack,
683cb6c5 69 AliMUONVDigitStore& digitStore) const;
70
9b1e069f 71 Int_t FindPadMatchingTrig(const AliMUONVDigitStore& digitStore, Int_t &detElemId, Float_t coor[2],
683cb6c5 72 Bool_t isMatch[2], TArrayI nboard[2],
73 TArrayF &zRealMatch, Float_t y11) const;
74
75 Float_t PadMatchTrack(Float_t xPad, Float_t yPad, Float_t dpx, Float_t dpy,
76 Float_t xTrackAtPad, Float_t yTrackAtPad) const;
77
78 Int_t DetElemIdFromPos(Float_t x, Float_t y, Int_t chamber, Int_t cathode) const;
79
80 void LocalBoardFromPos(Float_t x, Float_t y, Int_t detElemId,
81 Int_t cathode, Int_t localBoard[4]) const;
7771752e 82
21973f26 83 /// Return reco parameters
9b1e069f 84 const AliMUONRecoParam* GetRecoParam() const { return fkRecoParam; }
a0dc65b4 85
7771752e 86private:
683cb6c5 87 /// Not implemented
88 AliMUONTrackHitPattern(const AliMUONTrackHitPattern& rhs);
89 /// Not implemented
90 AliMUONTrackHitPattern& operator = (const AliMUONTrackHitPattern& rhs);
91
92 void CheckConstants() const;
683cb6c5 93
9b1e069f 94 const AliMUONRecoParam* fkRecoParam; //!< pointer to reco parameters
95 const AliMUONGeometryTransformer& fkTransformer; //!< geometry transformer
96 const AliMUONDigitMaker& fkDigitMaker; //!< pointer to digit maker
683cb6c5 97
683cb6c5 98 const Float_t fkMaxDistance; //!< Maximum distance for reference
99 static const Int_t fgkNcathodes=2; //!<Number of cathodes
100 static const Int_t fgkNchambers=4; //!<Number of chambers
101 static const Int_t fgkNplanes=8; //!<Number of planes
102 static const Int_t fgkNlocations=4; //!<Number of locations
a0dc65b4 103
683cb6c5 104 ClassDef(AliMUONTrackHitPattern, 0) // MUON track hit pattern
7771752e 105};
106
107#endif