LCOV - code coverage report
Current view: top level - ITS/ITSbase - AliITSRecPoint.h (source / functions) Hit Total Coverage
Test: coverage.info Lines: 21 42 50.0 %
Date: 2016-06-14 17:26:59 Functions: 21 45 46.7 %

          Line data    Source code
       1             : #ifndef ALIITSRECPOINT_H
       2             : #define ALIITSRECPOINT_H 
       3             : /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
       4             :  * See cxx source for full Copyright notice                               */
       5             : 
       6             : /*
       7             :   $Id$
       8             : */
       9             : 
      10             : ///////////////////////////////////////////////////////////////////////////////
      11             : //  Reconstructed space point class for set:ITS   
      12             : //  Reconstructed points are expressed simultaneously in two different 
      13             : //  reference frames, both differing from the global system.
      14             : //  The first is referred to the sensor (see AliITSsegmentation for the
      15             : //  definition) and each point is represented by two coordinates: fXloc and
      16             : //  fZloc. This system in the code is referred to as "local"
      17             : //  The second is used for tracking (V2, SA and MI versions) and the X axis 
      18             : //  represents the radial coordinate (this system is, in the bending plane, 
      19             : //  a rotated system w.r.t. the global reference system). 
      20             : //  Each reaconstructed point is represented by two coordinates: fY and fZ, 
      21             : //  inherited from AliCluster. This system in the code is referred to as 
      22             : //  "trackingV2".
      23             : ///////////////////////////////////////////////////////////////////////////////
      24             : 
      25             : #include <AliCluster.h>
      26             : #include <TMath.h>
      27             : #include <iosfwd>
      28             : 
      29             : using std::ostream;
      30             : using std::istream;
      31             : 
      32             : class AliITSRecPoint : public AliCluster {
      33             :  public:
      34             :   AliITSRecPoint();
      35             :   AliITSRecPoint(Int_t *lab,Float_t *hit, Int_t *info, Bool_t local = kFALSE);
      36             :   AliITSRecPoint(const AliITSRecPoint& pt);
      37             :   AliITSRecPoint& operator=(const AliITSRecPoint &source);
      38             :   
      39        7208 :   virtual ~AliITSRecPoint() {}; // distructor
      40           0 :   Bool_t  IsSortable() const {return kTRUE;} // allows for sorting
      41         438 :   Float_t GetDetLocalX() const {return fXloc;} // gets fX
      42         730 :   Float_t GetDetLocalZ() const {return fZloc;} // gets fZ
      43           0 :   Float_t GetdEdX() const {return fdEdX;} // gets fdEdX
      44           0 :   Float_t GetSigmaDetLocX2() const {return GetSigmaY2();} // gets fSigmaX2
      45           0 :   void    SetdEdX(Float_t dedx){fdEdX=dedx;} // sets fdEdX
      46           0 :   Int_t Compare(const TObject *) const {return 0;} //to be defined
      47             :   void Print(ostream *os); 
      48             :   // Reads in the content of this class in the format of Print
      49             :   void Read(istream *is);
      50           0 :   virtual void Print(Option_t *option="") const {TObject::Print(option);}
      51           0 :   virtual Int_t Read(const char *name) {return TObject::Read(name);}
      52             :   
      53           0 :   void Use(Int_t = 0) {fQ=-fQ;}
      54           0 :   void UnUse() {fQ=TMath::Abs(fQ);}
      55           0 :   void SetQ(Float_t q) {fQ=q;}
      56           0 :   void SetDetectorIndex(Int_t i) { fIndex=i; }
      57           0 :   void SetLayer(Int_t layer) {fLayer=layer;}
      58           0 :   void SetNz(Int_t nz) {fNz =nz;}
      59           0 :   void SetNy(Int_t ny){fNy=ny;}
      60        1040 :   void SetChargeRatio(Float_t ratio) { fChargeRatio = ratio;}
      61           0 :   void SetPhiR(Float_t y) { fChargeRatio=y; }
      62        1360 :   void SetType(Int_t type){ fType=type;}
      63           0 :   void SetDeltaProbability(Float_t prob){fDeltaProb = prob;}
      64         456 :   void SetDriftTime(Float_t tim) {fDriftTime=tim;}
      65         456 :   void SetDriftSide(Int_t sid) {fDriftSide=sid;}
      66             :  
      67        4756 :   Int_t IsUsed() const {return (fQ<0)?1:0;}
      68      102434 :   Float_t GetQ() const {return TMath::Abs(fQ);}
      69       34306 :   Int_t GetDetectorIndex() const { return 0x3FF&fIndex; }
      70         634 :   Int_t GetLayer() const {return fLayer;}
      71       68570 :   Int_t GetNz() const {return fNz;}
      72       64564 :   Int_t GetNy() const {return fNy;}
      73         534 :   Float_t GetChargeRatio() const {return fChargeRatio;}
      74           0 :   Float_t GetPhiR() const {return fChargeRatio;}
      75           0 :   Int_t GetPindex() const { return 0xFFF00000&fIndex; }  //SSD clusters only
      76           0 :   Int_t GetNindex() const { return 0xFFC00&fIndex; }  //SSD clusters only
      77           0 :   Int_t GetType() const {return fType;}  // type of the cluster (for SPD the number of pixels in the cluster)
      78       10968 :   Float_t GetDeltaProbability() const{return fDeltaProb;} //probability to belong to the delta ray
      79         534 :   Float_t GetDriftTime() const{return  fDriftTime;}
      80           0 :   Int_t GetDriftSide() const {return fDriftSide;}
      81             :   Int_t GetNpixels() const; // for SPD returns fType, i.e. the number of pixels in the cluster (-1 for SDD and SSD)
      82             :   Int_t GetSPDclusterType() const; // for SPD returns cluster type according to conventional numbering (-1 for SDD and SSD)
      83             :   Int_t GetSDDclusterType() const; 
      84             :   Int_t GetSSDclusterType() const; 
      85             :   static void DecodeSDDclusterType(Int_t cluType, Int_t &cluSizAn, Int_t& cluSizTb, Int_t &drSide);
      86             : 
      87             :   Int_t GetClusterType() const {
      88         601 :     if(fLayer<=1) return GetSPDclusterType();
      89         452 :     if(fLayer==2 || fLayer==3) return GetSDDclusterType();
      90         101 :     return GetSSDclusterType();
      91         267 :   }
      92             :  protected:
      93             : 
      94             :   Float_t   fXloc ;        //X of cluster (local coordinates)
      95             :   Float_t   fZloc ;        //Z of cluster (local coordinates)
      96             :   Float_t   fdEdX;      //dE/dX inside this cluster
      97             : 
      98             :   Int_t    fIndex;    // detector index
      99             :   Float_t  fQ ;       // Q of cluster (in ADC counts)
     100             :   Char_t   fLayer;    // layer number
     101             :   Short_t  fNz;       //number of digits in Z direction
     102             :   Short_t  fNy;       //number of digits in y direction 
     103             :   Float_t  fChargeRatio; //charge ratio
     104             :   Int_t    fType;         //quality factor of the cluster
     105             :   Float_t  fDeltaProb;    // probability to be delta electron
     106             :   Float_t  fDriftTime;    // drift time in SDD
     107             :   Char_t   fDriftSide;    // drift region in SDD (0=left=positive xlocal, 1=right)
     108             :     
     109         126 :   ClassDef(AliITSRecPoint,7)  // AliITSRecPoint class
     110             : };
     111             : // Input and output function for standard C++ input/output.
     112             : ostream& operator<<(ostream &os,AliITSRecPoint &source);
     113             : istream& operator>>(istream &is,AliITSRecPoint &source);
     114             : #endif

Generated by: LCOV version 1.11