e422d068de7a52591112f2f1b156590188253b82
[u/mrichter/AliRoot.git] / TFluka / TFlukaConfigOption.h
1 #ifndef TFLUKACONFIGOPTION
2 #define TFLUKACONFIGOPTION
3
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5  * See cxx source for full Copyright notice                               */
6
7 /* $Id$ */
8
9 ///////////////////////////////////////////////////////////////////////////////
10 //                                                                           //
11 //                                                                           //
12 // Class to store FLUKA and VMC configuration options:                       // 
13 // Cuts, Processes, User Scoring                                             // 
14 //                                                                           //
15 //                                                                           //
16 // Author: andreas.morsch@cern.ch                                            // 
17 //                                                                           //  
18 //                                                                           //
19 ///////////////////////////////////////////////////////////////////////////////
20 //
21
22
23 //
24
25 #include <TObject.h>
26
27 typedef enum {kDCAY, kPAIR, kCOMP, kPHOT, kPFIS, kDRAY, kANNI, kBREM,
28               kMUNU, kCKOV, kHADR, kLOSS, kMULS, kRAYL, kSTRA} FlukaProcessOption_t;
29 typedef enum {kCUTGAM, kCUTELE, kCUTNEU, kCUTHAD, kCUTMUO, kBCUTE, kBCUTM, kDCUTE, kDCUTM, kPPCUTM, kTOFMAX}  FlukaCutOption_t;
30 class TFlukaMCGeometry;
31
32 class TFlukaConfigOption : public TObject
33 {
34 public:
35     // Constructors
36     TFlukaConfigOption();
37     TFlukaConfigOption(Int_t imed);
38     // Getters
39     Double_t Cut(FlukaCutOption_t i)      const {return fCutValue[i];}
40     Int_t    Flag(FlukaProcessOption_t i) const {return fProcessFlag[i];}
41     Int_t    Medium()                     const {return fMedium;}    
42     // Setters
43     void     SetCut(const char* flagname, Double_t val);
44     void     SetProcess(const char* flagname, Int_t flagValue);
45     void     SetMedium(Int_t imed)       {fMedium = imed;}
46     //
47     void     WriteFlukaInputCards();
48     void     ProcessDCAY();
49     void     ProcessPAIR();
50     void     ProcessBREM();
51     void     ProcessCOMP();
52     void     ProcessPHOT();
53     void     ProcessANNI();
54     void     ProcessPFIS();
55     void     ProcessMUNU();
56     void     ProcessRAYL();
57     void     ProcessCKOV();
58     void     ProcessHADR();
59     void     ProcessMULS();
60     void     ProcessLOSS();
61     void     ProcessSTRA();
62     
63     
64     void     ProcessCUTGAM();
65     void     ProcessCUTELE();
66     void     ProcessCUTNEU();
67     void     ProcessCUTHAD();
68     void     ProcessCUTMUO();
69     void     ProcessTOFMAX();
70     
71     //
72     static void SetStaticInfo(FILE* file, Float_t matMin, Float_t matMax, TFlukaMCGeometry* geom)
73         {fgFile = file; fgMatMin = matMin; fgMatMax = matMax; fgGeom = geom;}
74     static Double_t DefaultCut(FlukaCutOption_t i) {return fgDCutValue[i];}
75  protected:
76     Double_t fCutValue[11];            // User cut
77     Int_t    fProcessFlag[15];         // User flag assigned to processes
78     Int_t    fMedium;                  // Material assigned to user settings
79     Float_t  fCMatMin;                 // Minimum material number used for current card 
80     Float_t  fCMatMax;                 // Maximum material number used for current card
81     
82     // static
83     static Double_t  fgDCutValue[11];     // User default cut
84     static Int_t     fgDProcessFlag[15];  // User default flag assigned to processes
85     static Float_t   fgMatMin;            // Minimum material number 
86     static Float_t   fgMatMax;            // Maximum meterial number
87     static FILE*     fgFile;              // Output file
88     static TFlukaMCGeometry* fgGeom;      // Pointer to geometry     
89     ClassDef(TFlukaConfigOption, 1)    // Fluka Configuration Option
90 };
91         
92 #endif
93