Small changes to allow usage from out-of-source directories
[u/mrichter/AliRoot.git] / MUON / AliMUONVTrackReconstructor.h
CommitLineData
8d0843c6 1#ifndef ALIMUONVTRACKRECONSTRUCTOR_H
2#define ALIMUONVTRACKRECONSTRUCTOR_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
8/// \ingroup rec
9/// \class AliMUONVTrackReconstructor
10/// \brief Virtual class for the MUON track reconstruction
11///
c4ee792d 12// Author: Philippe Pillot
8d0843c6 13
14#include <TObject.h>
15
019df241 16class AliMUONTrack;
ea94c18b 17class AliMUONTrackParam;
96ebe67e 18class AliMUONVCluster;
8d0843c6 19class AliMUONTriggerTrack;
7771752e 20class AliMUONTrackHitPattern;
1fef78c8 21class AliMUONVClusterServer;
7ec3b9cf 22class AliMUONVClusterStore;
23class AliMUONVTrackStore;
24class AliMUONVTriggerTrackStore;
25class AliMUONVTriggerStore;
26class AliMUONGeometryTransformer;
27class AliMUONDigitMaker;
32ab62c9 28class AliMUONTriggerCircuit;
3304fa09 29class TClonesArray;
a0dc65b4 30class AliMUONRecoParam;
8d0843c6 31
32class AliMUONVTrackReconstructor : public TObject {
33
34 public:
a0dc65b4 35 AliMUONVTrackReconstructor(const AliMUONRecoParam* recoParam, AliMUONVClusterServer* clusterServer); // default Constructor
8d0843c6 36 virtual ~AliMUONVTrackReconstructor(); // Destructor
37
a0dc65b4 38
1fef78c8 39 void EventReconstruct(AliMUONVClusterStore& clusterStore,
7ec3b9cf 40 AliMUONVTrackStore& trackStore);
8d0843c6 41
32ab62c9 42 void EventReconstructTrigger(const AliMUONTriggerCircuit& triggerCircuit,
7ec3b9cf 43 const AliMUONVTriggerStore& triggerStore,
44 AliMUONVTriggerTrackStore& triggerTrackStore);
45
46 void ValidateTracksWithTrigger(AliMUONVTrackStore& trackStore,
47 const AliMUONVTriggerTrackStore& triggerTrackStore,
48 const AliMUONVTriggerStore& triggerStore,
49 const AliMUONTrackHitPattern& trackHitPattern);
a0dc65b4 50
21973f26 51 /// Return reco parameters
5a240757 52 const AliMUONRecoParam* GetRecoParam() const { return fkRecoParam; }
ea94c18b 53
21973f26 54 /// Re-fit the given track
b1fea02e 55 virtual Bool_t RefitTrack(AliMUONTrack &track, Bool_t enableImprovement = kTRUE) = 0;
7deb8eb0 56
ea94c18b 57
8d0843c6 58 protected:
59
8d0843c6 60 TClonesArray *fRecTracksPtr; ///< pointer to array of reconstructed tracks
61 Int_t fNRecTracks; ///< number of reconstructed tracks
62
b1fea02e 63 AliMUONVClusterServer* fClusterServer; ///< reference to our cluster server
ea94c18b 64
5a240757 65 const AliMUONRecoParam* fkRecoParam; ///< reference to reco parameters
a0dc65b4 66
8d0843c6 67 // Functions
68 AliMUONVTrackReconstructor (const AliMUONVTrackReconstructor& rhs); ///< copy constructor
69 AliMUONVTrackReconstructor& operator=(const AliMUONVTrackReconstructor& rhs); ///< assignment operator
70
9bf6860b 71 /// Make track candidates from clusters in stations(1..) 4 and 5
1fef78c8 72 virtual void MakeTrackCandidates(AliMUONVClusterStore& clusterStore) = 0;
9bf6860b 73 /// Make extra track candidates from clusters in stations(1..) 4 and 5
74 virtual void MakeMoreTrackCandidates(AliMUONVClusterStore& clusterStore) = 0;
ea94c18b 75 /// Follow tracks in stations(1..) 3, 2 and 1
1fef78c8 76 virtual void FollowTracks(AliMUONVClusterStore& clusterStore) = 0;
b709ac13 77 /// Complement the reconstructed tracks
96ebe67e 78 virtual void ComplementTracks(const AliMUONVClusterStore& clusterStore) = 0;
7332f213 79 void ImproveTracks();
80 /// Improve the given reconstructed track
81 virtual void ImproveTrack(AliMUONTrack &track) = 0;
82 void Finalize();
83 /// Finalize the given track
84 virtual void FinalizeTrack(AliMUONTrack &track) = 0;
ea94c18b 85
9bf6860b 86 TClonesArray* MakeSegmentsBetweenChambers(const AliMUONVClusterStore& clusterStore, Int_t ch1, Int_t ch2);
8d0843c6 87
ea94c18b 88 void RemoveIdenticalTracks();
89 void RemoveDoubleTracks();
c59f70b9 90 void RemoveConnectedTracks(Bool_t inSt345 = kFALSE);
ea94c18b 91
1fef78c8 92 void AskForNewClustersInStation(const AliMUONTrackParam &trackParam,
93 AliMUONVClusterStore& clusterStore, Int_t station);
9bf6860b 94 void AskForNewClustersInChamber(const AliMUONTrackParam &trackParam,
95 AliMUONVClusterStore& clusterStore, Int_t chamber);
1fef78c8 96
96ebe67e 97 Double_t TryOneCluster(const AliMUONTrackParam &trackParam, AliMUONVCluster* cluster,
98 AliMUONTrackParam &trackParamAtCluster, Bool_t updatePropagator = kFALSE);
5a240757 99 Bool_t TryOneClusterFast(const AliMUONTrackParam &trackParam, const AliMUONVCluster* cluster);
96ebe67e 100 Double_t TryTwoClustersFast(const AliMUONTrackParam &trackParamAtCluster1, AliMUONVCluster* cluster2,
101 AliMUONTrackParam &trackParamAtCluster2);
019df241 102
9bf6860b 103 Bool_t FollowLinearTrackInChamber(AliMUONTrack &trackCandidate, const AliMUONVClusterStore& clusterStore, Int_t nextChamber);
104 Bool_t FollowLinearTrackInStation(AliMUONTrack &trackCandidate, const AliMUONVClusterStore& clusterStore, Int_t nextStation);
ea94c18b 105
8d0843c6 106
107 private:
108
8d0843c6 109 // Functions
ea94c18b 110 void ResetTracks();
ea94c18b 111
8d0843c6 112
8d0843c6 113 ClassDef(AliMUONVTrackReconstructor, 0) // MUON track reconstructor in ALICE
208f139e 114};
8d0843c6 115
116#endif