001
002
003
004
005
006
007
008
009
010
011
012
013 #ifndef _HEAVYQUARKGENMODULE_H_
014 #define _HEAVYQUARKGENMODULE_H_
015
016 #include "generatorMods/AbsGenModule.hh"
017 #include "Framework/AbsParmGeneral.hh"
018 typedef AbsParmGeneral<long> AbsParmGeneral_long;
019
020 class HeavyQuarkGenModule;
021
022
023
024
025
026
027 class HQDefineCommand : public APPCommand
028 {
029 public:
030
031 HQDefineCommand(const char* comd, HeavyQuarkGenModule* targ);
032
033
034 virtual int handle(int argc, char* argv[]);
035 virtual void show() const;
036 virtual bool isShowable() const;
037 virtual std::string description () const;
038
039 private:
040 std::string _cmd;
041 int _idhep;
042 std::string _name;
043 std::string _spec_file;
044 std::string _spec_name;
045 double _mass;
046 double _lifetime;
047 double _epsilon;
048 };
049
050
051
052
053
054
055
056
057 class HQSetFractionCommand : public APPCommand
058 {
059 private:
060 std::string _cmd;
061 int _hepfrom;
062 int _hepto;
063 double _fraction;
064 int _anti;
065
066
067 public:
068
069 HQSetFractionCommand(const char* cmd, HeavyQuarkGenModule* targ);
070
071
072 virtual int handle(int argc, char* argv[]);
073 virtual void show() const;
074 virtual bool isShowable() const;
075 virtual std::string description () const;
076
077 };
078
079
080
081
082
083
084
085
086
087 class HQSetDMixtureCommand : public APPCommand
088 {
089 private:
090 std::string _cmd;
091 double _mixu;
092 double _mixd;
093 double _mixs;
094 double _mixl;
095 double _mixustar;
096 double _mixdstar;
097
098
099 public:
100
101 HQSetDMixtureCommand(const char* cmd, HeavyQuarkGenModule* targ);
102
103
104 virtual int handle(int argc, char* argv[]);
105 virtual void show() const;
106 virtual bool isShowable() const;
107 virtual std::string description () const;
108 };
109
110
111
112
113
114
115
116
117
118 class HQSetBMixtureCommand : public APPCommand
119 {
120 private:
121 std::string _cmd;
122 double _mixu;
123 double _mixd;
124 double _mixs;
125 double _mixc;
126 double _mixl;
127
128
129 public:
130
131 HQSetBMixtureCommand(const char* cmd, HeavyQuarkGenModule* targ);
132
133
134 virtual int handle(int argc, char* argv[]);
135 virtual void show() const;
136 virtual bool isShowable() const;
137 virtual std::string description () const;
138 };
139
140
141
142
143
144
145
146
147 class HQSetDEpsCommand : public APPCommand
148 {
149 private:
150 std::string _cmd;
151 double _epsu;
152 double _epsd;
153 double _epss;
154 double _epsl;
155 double _epsustar;
156 double _epsdstar;
157
158 public:
159
160 HQSetDEpsCommand(const char* cmd, HeavyQuarkGenModule* targ);
161
162
163 virtual int handle(int argc, char* argv[]);
164 virtual void show() const;
165 virtual bool isShowable() const;
166 virtual std::string description () const;
167 };
168
169
170
171
172
173
174
175
176
177 class HQSetBEpsCommand : public APPCommand
178 {
179 private:
180 std::string _cmd;
181 double _epsu;
182 double _epsd;
183 double _epsc;
184 double _epss;
185 double _epsl;
186
187
188 public:
189
190 HQSetBEpsCommand(const char* cmd, HeavyQuarkGenModule* targ);
191
192
193 virtual int handle(int argc, char* argv[]);
194 virtual void show() const;
195 virtual bool isShowable() const;
196 virtual std::string description () const;
197 };
198
199
200
201
202
203
204
205
206 class HQMixesCommand : public APPCommand
207 {
208 private:
209 std::string _cmd;
210 int _idhep;
211 double _delta_m;
212 int _mixes_to;
213
214
215 public:
216
217 HQMixesCommand(const char* cmd, HeavyQuarkGenModule* targ);
218
219
220 virtual int handle(int argc, char* argv[]);
221 virtual void show() const;
222 virtual bool isShowable() const;
223 virtual std::string description () const;
224
225 };
226
227
228
229
230
231
232 class HQGenerateCommand : public APPCommand {
233
234 private:
235 std::string _cmd;
236 int _idhep;
237 double _fraction;
238 double _pt_min;
239 double _pt_max;
240 double _rap_min;
241 double _rap_max;
242
243 public:
244
245 HQGenerateCommand(const char* comd, HeavyQuarkGenModule* targ);
246
247
248 virtual int handle(int argc, char* argv[]);
249 virtual void show() const;
250 virtual bool isShowable() const;
251 virtual std::string description () const;
252 };
253
254 class HeavyQuarkGenModule : public AbsGenModule {
255
256 protected:
257
258
259
260 APPMenu _HQgMenu;
261
262 AbsParmGeneral<int> _Debug;
263 AbsParmGeneral<int> _Verbose;
264
265 AbsParmGeneral<bool> _doFrag;
266 AbsParmGeneral<bool> _doMix;
267 HQDefineCommand _Define;
268 HQGenerateCommand _Generate;
269 HQMixesCommand _Mixes;
270 HQSetFractionCommand _SetFraction;
271 HQSetDMixtureCommand _SetDMixture;
272 HQSetBMixtureCommand _SetBMixture;
273 HQSetDEpsCommand _SetDEps;
274 HQSetBEpsCommand _SetBEps;
275
276
277 APPMenu _randomNumberMenu;
278 AbsParmGeneral<long> _rndmSeed1;
279 AbsParmGeneral<long> _rndmSeed2;
280
281 static const long _defaultRandomSeed1;
282 static const long _defaultRandomSeed2;
283
284 public:
285
286
287 HeavyQuarkGenModule(const char* name = "HeavyQuarkGen",
288 const char* desc = "HeavyQuarkGen Module");
289
290
291 virtual ~HeavyQuarkGenModule( );
292
293 const char* rcsId () const;
294
295 int callGenerator (AbsEvent* event);
296 AppResult genBeginJob ();
297 AppResult genBeginRun (AbsEvent* run);
298 AppResult genEndRun (AbsEvent* job);
299 AppResult genEndJob ();
300
301 void fillHepevt();
302 };
303 #endif
Send problems or questions to cdfcode@fnal.gov