Make the Scan method public
[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;
9f164762 31class AliMUONLocalTrigger;
8d0843c6 32
33class AliMUONVTrackReconstructor : public TObject {
34
35 public:
a0dc65b4 36 AliMUONVTrackReconstructor(const AliMUONRecoParam* recoParam, AliMUONVClusterServer* clusterServer); // default Constructor
8d0843c6 37 virtual ~AliMUONVTrackReconstructor(); // Destructor
38
a0dc65b4 39
1fef78c8 40 void EventReconstruct(AliMUONVClusterStore& clusterStore,
7ec3b9cf 41 AliMUONVTrackStore& trackStore);
8d0843c6 42
32ab62c9 43 void EventReconstructTrigger(const AliMUONTriggerCircuit& triggerCircuit,
7ec3b9cf 44 const AliMUONVTriggerStore& triggerStore,
45 AliMUONVTriggerTrackStore& triggerTrackStore);
46
47 void ValidateTracksWithTrigger(AliMUONVTrackStore& trackStore,
48 const AliMUONVTriggerTrackStore& triggerTrackStore,
49 const AliMUONVTriggerStore& triggerStore,
50 const AliMUONTrackHitPattern& trackHitPattern);
a0dc65b4 51
21973f26 52 /// Return reco parameters
5a240757 53 const AliMUONRecoParam* GetRecoParam() const { return fkRecoParam; }
ea94c18b 54
21973f26 55 /// Re-fit the given track
b1fea02e 56 virtual Bool_t RefitTrack(AliMUONTrack &track, Bool_t enableImprovement = kTRUE) = 0;
7deb8eb0 57
9f164762 58 void TriggerToTrack(const AliMUONTriggerCircuit& circuit,
59 const AliMUONLocalTrigger& locTrg,
60 AliMUONTriggerTrack& triggerTrack,
61 UChar_t globalTriggerPattern = 0);
62
63
ea94c18b 64
8d0843c6 65 protected:
66
8d0843c6 67 TClonesArray *fRecTracksPtr; ///< pointer to array of reconstructed tracks
68 Int_t fNRecTracks; ///< number of reconstructed tracks
69
b1fea02e 70 AliMUONVClusterServer* fClusterServer; ///< reference to our cluster server
ea94c18b 71
5a240757 72 const AliMUONRecoParam* fkRecoParam; ///< reference to reco parameters
a0dc65b4 73
4663da9f 74 Double_t* fMaxMCSAngle2; ///< maximum angle dispersion due to MCS
6b191dea 75
8d0843c6 76 // Functions
77 AliMUONVTrackReconstructor (const AliMUONVTrackReconstructor& rhs); ///< copy constructor
78 AliMUONVTrackReconstructor& operator=(const AliMUONVTrackReconstructor& rhs); ///< assignment operator
79
9bf6860b 80 /// Make track candidates from clusters in stations(1..) 4 and 5
89c8d66d 81 virtual Bool_t MakeTrackCandidates(AliMUONVClusterStore& clusterStore) = 0;
9bf6860b 82 /// Make extra track candidates from clusters in stations(1..) 4 and 5
89c8d66d 83 virtual Bool_t MakeMoreTrackCandidates(AliMUONVClusterStore& clusterStore) = 0;
ea94c18b 84 /// Follow tracks in stations(1..) 3, 2 and 1
89c8d66d 85 virtual Bool_t FollowTracks(AliMUONVClusterStore& clusterStore) = 0;
b709ac13 86 /// Complement the reconstructed tracks
89c8d66d 87 virtual Bool_t ComplementTracks(const AliMUONVClusterStore& clusterStore) = 0;
7332f213 88 void ImproveTracks();
89 /// Improve the given reconstructed track
90 virtual void ImproveTrack(AliMUONTrack &track) = 0;
91 void Finalize();
92 /// Finalize the given track
4ea3f013 93 virtual Bool_t FinalizeTrack(AliMUONTrack &track) = 0;
ea94c18b 94
6b191dea 95 Bool_t IsAcceptable(AliMUONTrackParam &trackParam);
96
9bf6860b 97 TClonesArray* MakeSegmentsBetweenChambers(const AliMUONVClusterStore& clusterStore, Int_t ch1, Int_t ch2);
8d0843c6 98
89c8d66d 99 void RemoveUsedSegments(TClonesArray& segments);
ea94c18b 100 void RemoveIdenticalTracks();
101 void RemoveDoubleTracks();
5c15a68b 102 void RemoveConnectedTracks(Int_t stMin, Int_t stMax, Bool_t all);
103 void TagConnectedTracks(Int_t stMin, Int_t stMax, Bool_t all);
ea94c18b 104
1fef78c8 105 void AskForNewClustersInStation(const AliMUONTrackParam &trackParam,
106 AliMUONVClusterStore& clusterStore, Int_t station);
9bf6860b 107 void AskForNewClustersInChamber(const AliMUONTrackParam &trackParam,
108 AliMUONVClusterStore& clusterStore, Int_t chamber);
1fef78c8 109
96ebe67e 110 Double_t TryOneCluster(const AliMUONTrackParam &trackParam, AliMUONVCluster* cluster,
111 AliMUONTrackParam &trackParamAtCluster, Bool_t updatePropagator = kFALSE);
5a240757 112 Bool_t TryOneClusterFast(const AliMUONTrackParam &trackParam, const AliMUONVCluster* cluster);
96ebe67e 113 Double_t TryTwoClustersFast(const AliMUONTrackParam &trackParamAtCluster1, AliMUONVCluster* cluster2,
114 AliMUONTrackParam &trackParamAtCluster2);
019df241 115
9bf6860b 116 Bool_t FollowLinearTrackInChamber(AliMUONTrack &trackCandidate, const AliMUONVClusterStore& clusterStore, Int_t nextChamber);
117 Bool_t FollowLinearTrackInStation(AliMUONTrack &trackCandidate, const AliMUONVClusterStore& clusterStore, Int_t nextStation);
abc2458f 118
8d0843c6 119 private:
120
8d0843c6 121 // Functions
ea94c18b 122 void ResetTracks();
ea94c18b 123
8d0843c6 124
8d0843c6 125 ClassDef(AliMUONVTrackReconstructor, 0) // MUON track reconstructor in ALICE
208f139e 126};
8d0843c6 127
128#endif