]> git.uio.no Git - u/mrichter/AliRoot.git/blame - ITS/AliITStrackerSA.h
Coding conventions
[u/mrichter/AliRoot.git] / ITS / AliITStrackerSA.h
CommitLineData
13918578 1#ifndef ALIITSTRACKERSA_H
2#define ALIITSTRACKERSA_H
3
4
5
e43c066c 6#include "AliITStrackerMI.h"
13918578 7
8/* Copyright(c) 1998-2003, ALICE Experiment at CERN, All rights reserved. *
9 * See cxx source for full Copyright notice */
10
11////////////////////////////////////////////////////
12// Stand alone tracker class //
13// Origin: Elisabetta Crescio //
14// e-mail: crescio@to.infn.it //
15////////////////////////////////////////////////////
16
17class AliITSclusterTable;
18class AliITStrackSA;
d681bb2d 19class AliESDVertex;
13918578 20class AliITSVertexer;
2257f27e 21class TTree;
7e5bf5af 22class TArrayD;
13918578 23
e43c066c 24class AliITStrackerSA : public AliITStrackerMI {
13918578 25
26
27 public:
28
29 AliITStrackerSA();
2257f27e 30 AliITStrackerSA(AliITSgeom *geom);
d681bb2d 31 AliITStrackerSA(AliITSgeom *geom,AliESDVertex *vert);
13918578 32 AliITStrackerSA(AliITSgeom *geom,AliITSVertexer *vertexer);
7d62fb64 33 AliITStrackerSA(const AliITStrackerSA& tracker);
e399f961 34 AliITStrackerSA& operator=(const AliITStrackerSA& source);
13918578 35 virtual ~AliITStrackerSA();
e43c066c 36 virtual Int_t Clusters2Tracks(AliESD *event){Int_t rc = AliITStrackerMI::Clusters2Tracks(event); if(!rc) rc=FindTracks(event); return rc;}
2257f27e 37 Int_t FindTracks(AliESD* event);
13918578 38
7e5bf5af 39 AliITStrackV2* FitTrack(AliITStrackSA* tr,Double_t* primaryVertex);
40
41 Int_t FindTrackLowChiSquare(TObjArray* tracklist, Int_t dim) const;
e43c066c 42 Int_t LoadClusters(TTree *cf) {Int_t rc=AliITStrackerMI::LoadClusters(cf); SetClusterTree(cf);SetSixPoints(kTRUE); return rc;}
d681bb2d 43 void SetVertex(AliESDVertex *vtx){fVert = vtx;}
2257f27e 44 void SetClusterTree(TTree * itscl){fITSclusters = itscl;}
7e5bf5af 45 void SetSixPoints(Bool_t sp = kFALSE){fSixPoints = sp;}
2257f27e 46 Bool_t GetSixPoints() const {return fSixPoints;}
13918578 47 void SetWindowSizes(Int_t n=46, Double_t *phi=0, Double_t *lam=0);
13918578 48
627b6db6 49 enum {kSAflag=0x8000}; //flag to mark clusters used in the SA tracker
50
13918578 51 protected:
52
13918578 53 //Initialization
54 void Init();
4e05ab9a 55 void ResetForFinding();
56 void UpdatePoints();
13918578 57
58 static Double_t Curvature(Double_t x1,Double_t y1,Double_t x2,Double_t y2,
bef31448 59 Double_t x3,Double_t y3);
13918578 60
61 Double_t ChoosePoint(Double_t p1, Double_t p2, Double_t pp);
62
63 static Int_t FindIntersection(Float_t a1, Float_t b1, Float_t c1, Float_t c2,
64 Float_t& x1,Float_t& y1, Float_t& x2, Float_t& y2);
65 static Int_t FindEquation(Float_t x1, Float_t y1, Float_t x2, Float_t y2,
66 Float_t x3, Float_t y3,Float_t& a, Float_t& b,
67 Float_t& c);
68
69 static Int_t FindLabel(Int_t l1, Int_t l2, Int_t l3, Int_t l4, Int_t l5, Int_t l6);
70 static Int_t Label(Int_t gl1, Int_t gl2, Int_t gl3, Int_t gl4, Int_t gl5,
71 Int_t gl6,Int_t gl7, Int_t gl8, Int_t gl9, Int_t gl10,Int_t gl11,
72 Int_t gl12, Int_t gl13, Int_t gl14,Int_t gl15, Int_t gl16,
73 Int_t gl17, Int_t gl18, Int_t numberofpoints=6);
bef31448 74
13918578 75 Int_t SearchClusters(Int_t layer,Double_t phiwindow,Double_t lambdawindow,
cfe729e0 76 AliITStrackSA* trs,Double_t zvertex,Int_t flagp);
7e5bf5af 77
00a7cc50 78 void GetCoorAngles(AliITSRecPoint* cl,Int_t module,Double_t &phi,Double_t &lambda,Float_t &x,Float_t &y,Float_t &z,Double_t* vertex);
79 void GetCoorErrors(AliITSRecPoint* cl, Int_t module,Float_t &sx,Float_t &sy, Float_t &sz);
7e5bf5af 80
81 AliITSclusterTable* GetClusterCoord(Int_t layer,Int_t n) const {return (AliITSclusterTable*)fCluCoord[layer]->UncheckedAt(n);}
82 void RemoveClusterCoord(Int_t layer, Int_t n) {fCluCoord[layer]->RemoveAt(n);fCluCoord[layer]->Compress();}
83
84
13918578 85 Double_t fPhiEstimate; //Estimation of phi angle on next layer
4e05ab9a 86 Float_t fPoint1[2]; //! coord. of 1-st point to evaluate the curvature
87 Float_t fPoint2[2]; //! coord. of 2-nd point to evaluate the curvature
88 Float_t fPoint3[2]; //! coord. of 3-rd point to evaluate the curvature
89 Float_t fPointc[2]; //! current point coord (for curvature eval.)
13918578 90 Double_t fLambdac; //! current value of the Lambda angle in the window
91 Double_t fPhic; //! current value of the Phi angle in the window
92 Float_t fCoef1; //! param. of the equation of the circ. approx a layer
93 Float_t fCoef2; //! param. of the equation of the circ. approx a layer
94 Float_t fCoef3; //! param. of the equation of the circ. approx a layer
95 Int_t fNloop; // Number of iterqations on phi and lambda windows
96 Double_t *fPhiWin; // phi window sizes
97 Double_t *fLambdaWin; // lambda window sizes
d681bb2d 98 AliESDVertex *fVert; //! primary vertex
13918578 99 AliITSVertexer *fVertexer; //! vertexer
100 AliITSgeom *fGeom; //! ITS geometry
4e05ab9a 101 TObjArray *fListOfTracks; //! container for found tracks
2257f27e 102 TTree *fITSclusters; //! pointer to ITS tree of clusters
2257f27e 103 Bool_t fSixPoints; // If true 6/6 points are required (default). 5/6 otherwise
7e5bf5af 104
105 TClonesArray** fCluLayer; //! array with clusters
106 TClonesArray** fCluCoord; //! array with cluster info
107
108 ClassDef(AliITStrackerSA,2)
13918578 109};
110
111#endif
112