]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PHOS/AliPHOSvFast.h
Included new data member to change patch size in calorimeters trigger (Gustavo)
[u/mrichter/AliRoot.git] / PHOS / AliPHOSvFast.h
1 #ifndef ALIPHOSVFAST_H
2 #define ALIPHOSVFAST_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 /* History of cvs commits:
9  *
10  * $Log$
11  * Revision 1.25  2005/05/28 14:19:05  schutz
12  * Compilation warnings fixed by T.P.
13  *
14  */
15
16 //_________________________________________________________________________
17 // Implementation of the PHOS manager class for fast simulations     
18 // Tracks particles until the reach a grossly designed PHOS module
19 // Modify the particles property (momentum, energy, type) according to
20 //  the PHOS response function. The result is called a virtual reconstructed
21 //  particle.                                
22 //                  
23 //*-- Author: Yves Schutz (SUBATECH)
24
25 // --- ROOT system ---
26 //#include "TClonesArray.h"
27 #include "TRandom.h"
28
29 class TVector3 ;
30 class TFile;
31
32 // --- AliRoot header files ---
33 #include "AliPHOS.h"
34 class AliPHOSGeometry ;
35 class AliPHOSFastRecParticle ;
36
37 class AliPHOSvFast : public AliPHOS {
38
39 public:
40
41   AliPHOSvFast() ;
42   AliPHOSvFast(const char *name, const char *title="") ;
43   AliPHOSvFast(AliPHOSvFast & fast);
44   
45   virtual ~AliPHOSvFast(void) ;
46
47   virtual void Copy(TObject &fast) const; 
48   void           AddRecParticle(const AliPHOSFastRecParticle & rp) ; // adds primary particle to the RecParticles list
49   virtual void   BuildGeometry(void) ;                               // creates the geometry for the ROOT display
50   virtual void   CreateGeometry(void) ;                              // creates the geometry for GEANT
51   Float_t        GetBigBox(Int_t index) const;                             
52   virtual void   Init(void) ;                                        // does nothing
53   virtual Int_t  IsVersion(void) const {
54     // Gives the version number 
55     return 99 ; 
56   }
57
58   void    MakeBranch(Option_t* opt);
59   Double_t MakeEnergy(Double_t energy) ;                       // makes the detected energy    
60   TVector3 MakePosition(Double_t energy, TVector3 pos, Double_t th, Double_t ph) ; 
61                                                                      // makes the detected position
62   void MakeRecParticle(Int_t modid, TVector3 pos, AliPHOSFastRecParticle & rp) ;  // makes a reconstructes particle from primary
63   Int_t   MakeType(AliPHOSFastRecParticle & rp) ;                    // gets the detected type of particle
64   // gets TClonesArray of reconstructed particles
65   TClonesArray * FastRecParticles() const { return fFastRecParticles ; } 
66   virtual void ResetPoints() ; 
67   void         ResetFastRecParticles() ; 
68   void         SetBigBox(Int_t index, Float_t value) ;                             
69   Double_t     SigmaE(Double_t energy) ;    // calulates the energy resolution at a given Energy                           
70   Double_t     SigmaP(Double_t energy, Double_t inc) ; // calulates the position resolution at a given Energy at a given incidence                           
71   virtual void StepManager(void) ;          // does the tracking through PHOS and a preliminary digitalization
72   virtual const TString Version(void)const { 
73     // As IsVersion
74     return TString("vFast") ; 
75   }
76
77   AliPHOSvFast & operator = (const AliPHOSvFast & )  {
78     Fatal("operator =", "not implemented") ; return *this ; 
79   }
80   
81 private:
82   
83   Float_t fBigBoxX ;                         // main box containing all PHOS (EMC+PPSD)
84   Float_t fBigBoxY ;                         // main box containing all PHOS (EMC+PPSD)
85   Float_t fBigBoxZ ;                         // main box containing all PHOS (EMC+PPSD)
86   TClonesArray * fFastRecParticles ;         // list of particles modified by the response function 
87   Int_t fNRecParticles ;                     // number of detected particles
88   TRandom fRan ;                             // random number generator
89   Double_t fResPara1 ;                       // parameter for the energy resolution dependence  
90   Double_t fResPara2 ;                       // parameter for the energy resolution dependence  
91   Double_t fResPara3 ;                       // parameter for the energy resolution dependence 
92   Double_t fPosParaA0 ;                      // parameter for the position resolution
93   Double_t fPosParaA1 ;                      // parameter for the position resolution 
94   Double_t fPosParaB0 ;                      // parameter for the position resolution 
95   Double_t fPosParaB1 ;                      // parameter for the position resolution 
96   Double_t fPosParaB2 ;                      // parameter for the position resolution
97
98   ClassDef(AliPHOSvFast,1)  //  Implementation of the PHOS manager class for fast simulations  
99
100 };
101
102 #endif // AliPHOSVFAST_H