]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PMD/AliPMDDigitizer.h
mev2adc defined to be const
[u/mrichter/AliRoot.git] / PMD / AliPMDDigitizer.h
1 #ifndef ALIPMDDIGITIZER_H
2 #define ALIPMDDIGITIZER_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice                               */
5 //-----------------------------------------------------//
6 //                                                     //
7 //  Header File : PMDDigitization.h, Version 00        //
8 //                                                     //
9 //  Date   : September 20 2002                         //
10 //                                                     //
11 //-----------------------------------------------------//
12
13 class TClonesArray;
14 class TFile;
15 class TMath;
16 class TObjArray;
17 class TParticle;
18 class TTree;
19 class TNtuple;
20
21 class AliLoader;
22 class AliRunLoader;
23 class AliRun;
24 class AliDetector;
25 class AliPMDhit;
26 class AliHit;
27 class AliHeader;
28
29 class AliPMDcell;
30 class AliPMDsdigit;
31 class AliPMDdigit;
32 class AliPMDClustering;
33
34 class AliPMDDigitizer
35 {
36  public:
37
38   AliPMDDigitizer();
39   virtual ~AliPMDDigitizer();
40
41   void OpengAliceFile(char *file, Option_t *option);
42
43   void Hits2SDigits(Int_t ievt);
44   void Hits2Digits(Int_t ievt);
45   void SDigits2Digits(Int_t ievt);
46   void TrackAssignment2Cell();
47   void MeV2ADC(Float_t mev, Float_t & adc) const;
48   void AddSDigit(Int_t trnumber, Int_t det, Int_t smnumber, 
49                  Int_t cellnumber, Float_t adc);
50   void AddDigit(Int_t trnumber, Int_t det, Int_t smnumber, 
51                 Int_t cellnumber, Float_t adc);
52   void  SetZPosition(Float_t zpos);
53   Float_t GetZPosition() const;
54   void ResetCell();
55   void ResetSDigit();
56   void ResetDigit();
57   void ResetCellADC();
58   void UnLoad(Option_t * /* option */);
59
60  protected:
61   AliRunLoader *fRunLoader;  // Pointer to Run Loader
62   AliPMDhit    *fPMDHit;     // Pointer to specific detector hits
63   AliDetector  *fPMD;        // Get pointers to Alice detectors 
64                              // and Hits containers 
65   AliLoader    *fPMDLoader;  // Pointer to specific detector loader
66
67   TClonesArray *fHits;       // Pointer to hits array
68   TObjArray    *fPArray;     // Pointer to particle array
69   TParticle    *fParticle;   // Pointer to a given particle
70
71   TTree        *fTreeH;      // Hits tree
72   TTree        *fTreeS;      // Summable Digits tree
73   TTree        *fTreeD;      // Digits tree
74
75   TClonesArray *fSDigits;    // List of summable digits
76   TClonesArray *fDigits;     // List of digits
77
78   TObjArray    *fCell;       // List of pmd cells
79   AliPMDcell   *fPMDcell;    // Pointer to a PMD cell
80
81   Int_t   fNsdigit;          // Summable digits counter
82   Int_t   fNdigit;           // Digits counter
83   Int_t   fDetNo;            // Detector Number (0:PRE, 1:CPV)
84   Float_t fZPos;             // z-position of the detector
85
86   static const Int_t fgkTotUM = 24; // Total Unit modules in one detector
87   static const Int_t fgkRow   = 48; // Total number of rows in one unitmodule
88   static const Int_t fgkCol   = 96; // Total number of cols in one unitmodule
89   Float_t fCPV[fgkTotUM][fgkRow][fgkCol]; // CPV Array containing total edep
90   Float_t fPRE[fgkTotUM][fgkRow][fgkCol]; // PRE Array containing total edep
91   Int_t   fPRECounter[fgkTotUM][fgkRow][fgkCol]; // Number of times each cell
92                                                  // is fired in PMD
93   Int_t   fPRETrackNo[fgkTotUM][fgkRow][fgkCol]; // PRE Array containing track number
94   Int_t   fCPVTrackNo[fgkTotUM][fgkRow][fgkCol]; // CPV Array containing track number
95
96
97   ClassDef(AliPMDDigitizer,2)    // To digitize PMD Hits
98 };
99 #endif
100