]> git.uio.no Git - u/mrichter/AliRoot.git/blob - TRD/AliTRDv1.h
Introduce segmented geometry
[u/mrichter/AliRoot.git] / TRD / AliTRDv1.h
1 #ifndef ALITRDV1_H
2 #define ALITRDV1_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 ////////////////////////////////////////////////////////
9 //  Manager and hits classes for set:TRD version 1    //
10 ////////////////////////////////////////////////////////
11
12 // Energy spectrum of the delta-rays 
13 Double_t Ermilova(Double_t *x, Double_t *par);
14 Double_t IntSpecGeant(Double_t *x, Double_t *par);
15  
16 #include "AliTRD.h"
17
18 class TF1;
19 class TTree;
20 class TFile;
21 class AliTRDsim;
22
23 //_____________________________________________________________________________
24 class AliTRDv1 : public AliTRD {
25
26  public:
27
28   AliTRDv1();
29   AliTRDv1(const char *name, const char *title);
30   AliTRDv1(const AliTRDv1 &trd);
31   virtual ~AliTRDv1();
32   AliTRDv1 &operator=(const AliTRDv1 &trd);
33
34   virtual void       Copy(TObject &trd) const;
35   virtual void       CreateGeometry();
36   virtual void       CreateMaterials();
37   virtual void       CreateTRhit(Int_t det);
38   virtual Int_t      IsVersion() const          { return 1; };
39   virtual void       StepManager();
40   virtual void       Init();
41
42           void       StepManagerErmilova();
43           void       StepManagerGeant();
44           void       StepManagerFixedStep();
45           void       SelectStepManager(Int_t t);
46           void       SetStepSize(Double_t s)    { fStepSize = s; };
47
48           void       SetSensPlane(Int_t iplane = 0);
49           void       SetSensChamber(Int_t ichamber = 0);
50           void       SetSensSector(Int_t isector);
51           void       SetSensSector(Int_t isector, Int_t nsector);
52
53           void       SetTR(Bool_t kTRUE)        { fTRon = kTRUE; };
54
55           Int_t      GetSensPlane() const       { return fSensPlane;       };
56           Int_t      GetSensChamber() const     { return fSensChamber;     };
57           Int_t      GetSensSector() const      { return fSensSector;      };
58           Int_t      GetSensSectorRange() const { return fSensSectorRange; };
59
60           Bool_t     GetTR() const              { return fTRon;            };
61           AliTRDsim *GetTRDsim() const          { return fTR;              };
62
63  protected:
64
65   void        *StepManagerEntity();
66
67   Int_t        fSensSelect;             // Switch to select only parts of the detector
68   Int_t        fSensPlane;              // Sensitive detector plane
69   Int_t        fSensChamber;            // Sensitive detector chamber
70   Int_t        fSensSector;             // Sensitive detector sector 
71   Int_t        fSensSectorRange;        // Sensitive detector range
72
73   Bool_t       fTRon;                   // Switch for TR simulation
74   AliTRDsim   *fTR;                     // TR simulator
75
76   Int_t        fTypeOfStepManager;      // Type of Step Manager.
77   Double_t     fStepSize;               // Used for the fixed step size
78
79  private:
80
81   Double_t     BetheBloch(Double_t bg);
82   Double_t     BetheBlochGeant(Double_t bg);
83   void         Stepping();
84   
85   TF1         *fDeltaE;                 // Energy distribution of the delta-electrons (Ermilova)
86   TF1         *fDeltaG;                 // Energy distribution of the
87                                         // Delta-electrons (GEANT) for StepManagerGeant
88   Float_t      fTrackLength0;           // Save the track length at chamber entrance  
89   Int_t        fPrimaryTrackPid;        // Save the id of the primary track  
90
91   ClassDef(AliTRDv1,4)                  // Transition Radiation Detector version 1 (slow simulator)
92
93 };
94
95 #endif