]> git.uio.no Git - u/mrichter/AliRoot.git/blob - EVGEN/AliGenFLUKAsource.h
Make-depend automatically generated if not there.
[u/mrichter/AliRoot.git] / EVGEN / AliGenFLUKAsource.h
1 #ifndef AliGenFLUKAsource_H
2 #define AliGenFLUKAsource_H
3 /////////////////////////////////////////////////////////
4 //  Manager and hits classes for set:MUON version 0    //
5 /////////////////////////////////////////////////////////
6 #include "AliGenerator.h"
7 #include "TNamed.h"
8 #include "TF1.h"
9 #include "TArrayF.h"
10 #include "TTree.h"
11
12 // Read background particles from a FLUKA boundary source file
13
14 class AliGenFLUKAsource : public AliGenerator
15 {
16  
17 protected:
18
19   Int_t fIkine;               //Flag to choose type of particles to be read in
20                               // 6 - all particles types
21                               // 7 - only gammas
22                               // 8 - only neutrons
23                               // 9 - only charged particles
24   Float_t     fAgeMax;        //Maximum age of particle
25   Float_t     fAddWeight;     //Add weight for neutrons 
26   Float_t     fZshift;        //Shift the Z of impact point by this quantity
27   Float_t     fFrac;
28   
29   const Text_t     *fFileName;          //Choose the file
30    
31   TTree           *fTreeFluka;        //pointer to the TTree
32 //Declaration of variables read from the file -- TTree type
33    Float_t         Ip;
34    Float_t         Ipp;
35    Float_t         Xi;
36    Float_t         Yi;
37    Float_t         Zi;
38    Float_t         Px;
39    Float_t         Py;
40    Float_t         Pz;
41    Float_t         Ekin;
42    Float_t         Zv;
43    Float_t         Rv;
44    Float_t         Itra;
45    Float_t         Igas;
46    Float_t         Wgt;
47    Float_t         Etag;
48    Float_t         Ptg;
49    Float_t         Age;
50
51 public:
52   AliGenFLUKAsource();
53   AliGenFLUKAsource(Int_t npart);
54   virtual ~AliGenFLUKAsource();
55   // Initialise 
56   virtual void Init() {}
57   // Initialise fluka data 
58   virtual void FlukaInit();
59   // choose particle type
60   virtual void SetPartFlag(Int_t ikine) {fIkine=ikine;}
61   // set time cut 
62   virtual void SetAgeMax(Float_t agemax) {fAgeMax=agemax;}
63   // use additional weight on neutrals
64   virtual void SetAddWeight(Float_t addwgt) {fAddWeight=addwgt;}
65   // z-shift of vertex
66   virtual void SetZshift(Float_t zshift) {fZshift=zshift;}
67   // set file name of data file
68   virtual void SetFileName(const Text_t *filname) {fFileName=filname;}
69   // read only fraction of data  
70   virtual void SetFraction(Float_t frac=1.){fFrac=frac;}
71   // generate event
72   virtual void Generate();
73
74   ClassDef(AliGenFLUKAsource,1) //Boundary source
75 };
76 #endif
77
78
79
80
81
82