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