]> git.uio.no Git - u/mrichter/AliRoot.git/blob - ITS/AliITSNeuralPoint.h
2fea18e4cc855713ebc6ec1f5f73ca10535d4601
[u/mrichter/AliRoot.git] / ITS / AliITSNeuralPoint.h
1 #ifndef ALIITSNEURALPOINT_H
2 #define ALIITSNEURALPOINT_H
3 ///////////////////////////////////////////////////////////////
4 // AliITSneuralPoint                                         //
5 //                                                           //
6 // A class which resumes the information of ITS clusters     //
7 // in the global reference frame.                            //
8 // Author: A. Pulvirenti                                     //
9 ///////////////////////////////////////////////////////////////
10 class AliITSgeom;
11 class AliITSgeomMatrix;
12 class AliITSRecPoint;
13 class AliITSclusterV2;
14
15 class AliITSNeuralPoint : public TObject {
16
17 public:
18
19         AliITSNeuralPoint();
20         AliITSNeuralPoint(AliITSNeuralPoint *p);
21         AliITSNeuralPoint(AliITSRecPoint *rp, AliITSgeomMatrix *gm);
22         AliITSNeuralPoint(AliITSclusterV2 *rp, AliITSgeom *geom, Short_t module, Short_t index);
23
24         virtual ~AliITSNeuralPoint() { }
25
26         Double_t& X()    {return fX;}   // reference to X coord
27         Double_t& Y()    {return fY;}   // reference to Y coord
28         Double_t& Z()    {return fZ;}   // reference to Z coord
29         Double_t& ErrX() {return fEX;}  // reference to X error
30         Double_t& ErrY() {return fEY;}  // reference to Y error
31         Double_t& ErrZ() {return fEZ;}  // reference to Z error
32                 
33         Double_t  GetR2()    const  {return TMath::Sqrt(GetR2sq());} // xy radius
34         Double_t  GetR3()    const  {return TMath::Sqrt(GetR3sq());} // 3D radius
35         Double_t  GetR2sq()  const  {return fX*fX+fY*fY;}            // xy rad. square
36         Double_t  GetR3sq()  const  {return GetR2sq()+fZ*fZ;}        // 3D rad. square
37         Double_t  GetPhi()   const;
38         Double_t  GetTheta() const  {return TMath::ATan2(GetR2(),fZ);} // polar angle
39         Double_t  GetConfX() const  {return fConfX;}
40         Double_t  GetConfY() const  {return fConfY;}
41         Double_t  GetError(Option_t *opt);
42         void      ConfMap(Double_t vx, Double_t vy);
43
44         Double_t  GetCharge()       const {return fCharge;}        // ADC signal
45         Short_t   GetIndex()        const {return fIndex;}         // Reference in TreeR
46         Long_t    GetLabel(Int_t i) const {return fLabel[Chk(i)];} // GEANT owner particle
47         Short_t   GetLayer()        const {return fLayer;}         // ITS layer
48         Short_t   GetModule()       const {return fModule;}        // ITS module 
49         Short_t   GetUser()         const {return fUser;}          // Found track owner
50                                 
51         void      SetCharge(Double_t val)       {fCharge = val;}
52         void      SetIndex(Short_t val)         {fIndex = val;}
53         void      SetLabel(Int_t i, Long_t val) {fLabel[Chk(i)] = val;}
54         void      SetLayer(Short_t val)         {fLayer = val;}
55         void      SetModule(Short_t val)        {fModule = val;}
56         void      SetUser(Short_t val)          {fUser = val;}
57         
58         Bool_t    HasID (Int_t ID) const;
59         Int_t*    SharedID(AliITSNeuralPoint *p) const;
60
61 protected:
62         
63         Int_t     Chk(Int_t i) const {if(i<0)i=0;if(i>=3)i=3;return i;}
64
65         Double_t  fX;   // position 
66         Double_t  fY;   // position
67         Double_t  fZ;   // position
68         
69         Double_t  fConfX; // conformal mapping X
70         Double_t  fConfY; // conformal mapping Y
71                 
72         Double_t  fEX;  // position error
73         Double_t  fEY;  // position error
74         Double_t  fEZ;  // position error
75
76         Double_t  fCharge;   // total charge signal in cluster
77
78         Short_t   fModule;   // ITS module containing the point (0 - 2197)
79         Short_t   fIndex;    // index as TClonesArray entry in TreeR (usually not > 600)
80         Short_t   fLayer;    // ITS layer containing the point
81         Short_t   fUser;     // owner recognized track or flag to evidence using
82         Short_t   fZSort;    // order as a function of local Z
83
84         Int_t     fLabel[3]; // GEANT labels of the owner tracks
85
86         ClassDef(AliITSNeuralPoint, 1) // AliITSNeuralPoints class
87 };
88
89 #endif