Transition to NewIO
[u/mrichter/AliRoot.git] / TMEVSIM / TMevSim.h
CommitLineData
1a2762e8 1#ifndef ROOT_TMevSim
2#define ROOT_TMevSim
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// TMevSim //
12// //
13// This class implements an interface to the MevSim event generator. //
14// //
15//////////////////////////////////////////////////////////////////////////
16
17#include "TGenerator.h"
18#include "MevSimCommon.h"
19#include "TMevSimPartTypeParams.h"
20#include "TObjArray.h"
21
22class TMevSim : public TGenerator {
23
24protected:
25
26 Int_t fNEvents;
27 Int_t fModelType;
28 Int_t fReacPlaneCntrl;
29 Float_t fPsiRMean, fPsiRStDev;
30 Float_t fMultFacMean, fMultFacStDev;
31 Float_t fPtCutMin, fPtCutMax;
32 Float_t fEtaCutMin, fEtaCutMax;
33 Float_t fPhiCutMin, fPhiCutMax;
34 Float_t fNStDevMult, fNStDevTemp, fNStDevSigma, fNStDevExpVel, fNStdDevPSIr, fNStDevVn, fNStDevMultFac;
35 Int_t fNIntegPts;
36 Int_t fNScanPts;
37 Int_t firand;
38 TClonesArray *fParticleTypeParameters;
39
40// Copied from AliGeant
41 enum {kMaxParticles = 35};
42
43 Int_t fNPDGCodes; // Number of PDG codes known by G3
44
45 Int_t fPDGCode[kMaxParticles]; // Translation table of PDG codes
46
47 public:
48 // Constructors and destructors
49
50 TMevSim(Int_t nEvents = 1, Int_t modelType=1, Int_t reacPlaneCntrl=4,
51 Float_t psiRMean=0.0, Float_t psiRStDev=0.0, Float_t multFacMean=1.0, Float_t multFacStDev=0.05,
52 Float_t ptCutMin = 0.01, Float_t ptCutMax = 3.0, Float_t etaCutMin=(-4.5), Float_t etaCutMax = 4.5,
53 Float_t phiCutMin=0.0, Float_t phiCutMax=360.0, Int_t irand=87266);
54
55 TMevSim(TMevSim& mevsim); // copy constructor
56
57 virtual ~TMevSim();
58
59 // Assignment operator
60
61 virtual TMevSim& operator=(TMevSim& mevsim);
62
63 // Mandatory TGenerator functions
64
65 virtual void Initialize();
66
67 virtual void GenerateEvent();
68
69 virtual Int_t ImportParticles(TClonesArray *particles, Option_t *option="");
70
71 //Parameters for the generation:
72
73 virtual void SetNEvents(Int_t nEvents );
74 virtual Int_t GetNEvents() const;
75
76 virtual Int_t GetNPidTypes() const;
77
78 virtual void SetModelType(Int_t modelType);
79 virtual Int_t GetModelType() const;
80
81 virtual void SetReacPlaneCntrl(Int_t reacPlaneCntrl);
82 virtual Int_t GetReacPlaneCntrl() const;
83
84 virtual void SetPsiRParams(Float_t psiRMean, Float_t psiRStDev);
85 virtual Float_t GetPsiRMean() const;
86 virtual Float_t GetPsiRStDev() const;
87
88 virtual void SetMultFacParams(Float_t multFacMean, Float_t multFacStDev);
89 virtual Float_t GetMultFacMean() const;
90 virtual Float_t GetMultFacStDev() const;
91
92 // Pt and geometry cut
93
94 virtual void SetPtCutRange(Float_t ptCutMin, Float_t ptCutMax);
95 virtual Float_t GetPtCutMin() const;
96 virtual Float_t GetPtCutMax() const;
97
98 virtual void SetEtaCutRange(Float_t etaCutMin, Float_t etaCutMax);
99 virtual Float_t GetEtaCutMin() const;
100 virtual Float_t GetEtaCutMax() const;
101
102 virtual void SetPhiCutRange(Float_t phiCutMin, Float_t phiCutMax);
103 virtual Float_t GetPhiCutMin() const;
104 virtual Float_t GetPhiCutMax() const;
105
106 // StDev
107
108 virtual void SetNStDevMult(Float_t nStDevMult);
109 virtual Float_t GetNStDevMult() const;
110
111 virtual void SetNStDevTemp(Float_t nStDevTemp);
112 virtual Float_t GetNStDevTemp() const;
113
114 virtual void SetNStDevSigma(Float_t nStDevSigma);
115 virtual Float_t GetNStDevSigma() const;
116
117 virtual void SetNStDevExpVel(Float_t nStDevExpVel);
118 virtual Float_t GetNStDevExpVel() const;
119
120 virtual void SetNStDevPSIr(Float_t nStDevPSIr);
121 virtual Float_t GetNStDevPSIr() const;
122
123 virtual void SetNStDevVn(Float_t nStDevVn);
124 virtual Float_t GetNStDevVn() const;
125
126 virtual void SetNStDevMultFac(Float_t nStDevMultFac);
127 virtual Float_t GetNStDevMultFac() const;
128
129 // grid
130
131 virtual void SetNIntegPts(Int_t nIntegPts);
132 virtual Int_t GetNintegPts() const;
133
134 virtual void SetNScanPts(Int_t nScanPts);
135 virtual Int_t GetNScanPts() const;
136
137 // adding particles
138
139 virtual void AddPartTypeParams(TMevSimPartTypeParams *params);
140 virtual void SetPartTypeParams(Int_t index, TMevSimPartTypeParams *params);
141 virtual void GetPartTypeParamsByIndex(Int_t index, TMevSimPartTypeParams *params);
142 virtual void GetPartTypeParamsByGPid(Int_t gpid, TMevSimPartTypeParams *params);
143
144 // conversion
145
146 virtual Int_t PDGFromId(Int_t gpid) const;
147 virtual void DefineParticles();
148
149
150 ClassDef(TMevSim,1) //Interface to MevSim Event Generator
151
152};
153
154#endif
155
156
157
158
159
160