New methods and data member added by M. Horner.
[u/mrichter/AliRoot.git] / TIsajet / TIsajet.cxx
CommitLineData
7dae8538 1#include "TParticle.h"
2#include "TSystem.h"
3#include "TIsajet.h"
4#include "Icommon.h"
eae0fe66 5#include "Riostream.h"
7dae8538 6#include "math.h"
7#include "TROOT.h"
8#include "TMath.h"
9
10ClassImp(TIsajet)
11
12/**************************************************************************/
13
14TIsajet::TIsajet() : TGenerator("Isajet", "Isajet")
15{
16// Default constructor
17// Set random number
18 if (!sRandom) sRandom=fRandom;
19
20// Initialising equivalence structures in FRGPAR :
21// EQUIVALENCE (PMIX1(1,1),PMIXX1(1))
22// EQUIVALENCE (PMIX2(1,1),PMIXX2(1))
23// EQUIVALENCE (FRPAR(1),PUD)
24
25 FRGPAR.pmixx1[0] = &FRGPAR.pmix1[0][0];
26 FRGPAR.pmixx2[0] = &FRGPAR.pmix2[0][0];
27 FRGPAR.frpar[0] = &FRGPAR.pud;
28
29 for (Int_t i = 1; i < 6; i++) {
30 FRGPAR.pmixx1[i] = FRGPAR.pmixx1[i-1] + 1;
31 FRGPAR.pmixx1[i] = FRGPAR.pmixx1[i-1] + 1;
32 }
33
34 for (Int_t i = 1; i < 32; i++) {
35 FRGPAR.frpar[i] = FRGPAR.frpar[i-1] +1;
36 }
37
38// Internal logical flags ensuring that theta and y limits are not simultaneously set :
39
40 DYLIM.ywset = DYLIM.thwset = false;
41
42// Defaults :
43
44 title = ("Default title.");
45 jobtype = ("TWOJET");
46
47 RestoreDefaults();
48}
49
50/**************************************************************************/
51
52TIsajet::~TIsajet()
53{
54 // No housekeeping required at the moment.
55}
56
57/**************************************************************************/
58
59void TIsajet::Initialise()
60{
61
62// Writes parameter file and stores common block variables in
63// data members, according to booleans.
64// If TIsajet is being used in online-control mode, the parameter file is
65// unnecessary, hence the output is echoed to the screen instead.
66
67 const char *fname = gSystem->ExpandPathName("$ALICE_ROOT/ISAJET/data/myjob.par");
68 ofstream Write(fname, ios::out);
69
70 ostream *Writer = &Write;
71
72 if (online) Writer = &cout;
73
74 *Writer << title << '\n';
75 *Writer << PRIMAR.ecm << ',' << PRIMAR.nevent << ",1,1/\n";
76 *Writer << jobtype << '\n';
77
78 center_energy = PRIMAR.ecm;
79
80 if (setBeams) {
81 beam1_type = PRIMAR.idin[0];
82 beam2_type = PRIMAR.idin[1];
83
84 *Writer << "BEAMS\n";
85 if (PRIMAR.idin[0] == -1120) *Writer << "AP,";
86 else if (PRIMAR.idin[0] == 1220) *Writer << "N,";
87 else if (PRIMAR.idin[0] == -1220) *Writer << "AN,";
88 else *Writer << "P,";
89
90 if (PRIMAR.idin[1] == -1120) *Writer << "AP/\n";
91 else if (PRIMAR.idin[1] == 1220) *Writer << "N/\n";
92 else if (PRIMAR.idin[1] == -1220) *Writer << "AN/\n";
93 else *Writer << "P/\n";
94 }
95
96 if (setCutjet) {
97 cutoff_mass = QCDPAR.cutjet;
98 *Writer << "CUTJET\n" << QCDPAR.cutjet << "/\n";
99 }
100
101 if (setFragment) {
102 for (Int_t i = 0; i < 32; i++) frag_params[i] = *FRGPAR.frpar[i];
103
104 *Writer << "FRAGMENT\n";
105 for (Int_t i = 0; i < 31; i++) *Writer << FRGPAR.frpar[i] << ',';
106 *Writer << FRGPAR.frpar[31] << "/\n";
107 }
108
109 if (setJettype1) {
110 for (Int_t i = 0; i < TYPES.njttyp[0]; i++) jet1_type[i] = XTYPES.jetyp[0][i];
111 num_jet_type[0] = TYPES.njttyp[0];
112
113 *Writer << "JETTYPE1\n";
114 for (Int_t i = 0; i < TYPES.njttyp[0]-1; i++) *Writer << XTYPES.jetyp[0][i] << ',';
115 *Writer << XTYPES.jetyp[0][TYPES.njttyp[0]-1] << "/\n";
116 }
117 if (setJettype2) {
118 for (Int_t i = 0; i < TYPES.njttyp[1]; i++) jet2_type[i] = XTYPES.jetyp[1][i];
119 num_jet_type[0] = TYPES.njttyp[0];
120
121 *Writer << "JETTYPE2\n";
122 for (Int_t i = 0; i < TYPES.njttyp[1]-1; i++) *Writer << XTYPES.jetyp[1][i] << ',';
123 *Writer << XTYPES.jetyp[1][TYPES.njttyp[1]-1] << "/\n";
124 }
125 if (setJettype3) {
126 for (Int_t i = 0; i < TYPES.njttyp[2]; i++) jet3_type[i] = XTYPES.jetyp[2][i];
127 num_jet_type[0] = TYPES.njttyp[0];
128
129 *Writer << "JETTYPE3\n";
130 for (Int_t i = 0; i < TYPES.njttyp[2]-1; i++) *Writer << XTYPES.jetyp[2][i] << ',';
131 *Writer << XTYPES.jetyp[2][TYPES.njttyp[2]-1] << "/\n";
132 }
133
134
135 if (setLambda) {
136 qcd_lambda = QCDPAR.alam;
137 *Writer << "LAMBDA\n" << QCDPAR.alam << "/\n";
138 }
139
140
141 if (setNodcay) {
142 forbid_decay = NODCAY.nodcay;
143
144 *Writer << "NODCAY\n";
145 if (NODCAY.nodcay) *Writer << "TRUE/\n";
146 else *Writer << "FALSE/\n";
147 }
148
149 if (setNoeta) {
150 forbid_eta = NODCAY.noeta;
151
152 *Writer << "NOETA\n";
153 if (NODCAY.noeta) *Writer << "TRUE/\n";
154 else *Writer << "FALSE/\n";
155 }
156
157 if (setNoevolve) {
158 forbid_evolve = NODCAY.noevol;
159
160 *Writer << "NOEVOLVE\n";
161 if (NODCAY.noevol) *Writer << "TRUE/\n";
162 else *Writer << "FALSE/\n";
163 }
164
165 if (setNohadron) {
166 forbid_hadron = NODCAY.nohadr;
167
168 *Writer << "NOHADRON\n";
169 if (NODCAY.nohadr) *Writer << "TRUE/\n";
170 else *Writer << "FALSE/\n";
171 }
172
173 if (setNopi0) {
174 forbid_pi0 = NODCAY.nopi0;
175
176 *Writer << "NOPI0\n";
177 if (NODCAY.nopi0) *Writer << "TRUE/\n";
178 else *Writer << "FALSE/\n";
179 }
180
181 if (setNsigma) {
182 generate_sigma = PRIMAR.nsigma;
183 *Writer << "NSIGMA\n" << PRIMAR.nsigma << "/\n";
184 }
185
186 if (setP) {
187 for (Int_t i = 0; i < 3; i++) {
188 p_limits[2 * i] = JETLIM.pmin[i];
189 p_limits[2 * i + 1] = JETLIM.pmax[i];
190 }
191
192 *Writer << "P\n";
193 *Writer << JETLIM.pmin[0] << ',' << JETLIM.pmax[0] << ',';
194 *Writer << JETLIM.pmin[1] << ',' << JETLIM.pmax[1] << ',';
195 *Writer << JETLIM.pmin[2] << ',' << JETLIM.pmax[2] << "/\n";
196 }
197
198 if (setPhi) {
199 for (Int_t i = 0; i < 3; i++) {
200 phi_limits[2 * i] = JETLIM.phimin[i];
201 phi_limits[2 * i + 1] = JETLIM.phimax[i];
202 }
203
204 *Writer << "PHI\n";
205 *Writer << JETLIM.phimin[0] << ',' << JETLIM.phimax[0] << ',';
206 *Writer << JETLIM.phimin[1] << ',' << JETLIM.phimax[1] << ',';
207 *Writer << JETLIM.phimin[2] << ',' << JETLIM.phimax[2] << "/\n";
208 }
209
210 if (setPt) {
211 for (Int_t i = 0; i < 3; i++) {
212 pt_limits[2 * i] = JETLIM.ptmin[i];
213 pt_limits[2 * i + 1] = JETLIM.ptmax[i];
214 }
215
216 *Writer << "PT\n";
217 *Writer << JETLIM.ptmin[0] << ',' << JETLIM.ptmax[0] << ',';
218 *Writer << JETLIM.ptmin[1] << ',' << JETLIM.ptmax[1] << ',';
219 *Writer << JETLIM.ptmin[2] << ',' << JETLIM.ptmax[2] << "/\n";
220 }
221
222 if (setTheta) {
223 for (Int_t i = 0; i < 3; i++) {
224 theta_limits[2 * i] = JETLIM.thmin[i];
225 theta_limits[2 * i + 1] = JETLIM.thmax[i];
226 }
227
228 *Writer << "THETA\n";
229 *Writer << JETLIM.thmin[0] << ',' << JETLIM.thmax[0] << ',';
230 *Writer << JETLIM.thmin[1] << ',' << JETLIM.thmax[1] << ',';
231 *Writer << JETLIM.thmin[2] << ',' << JETLIM.thmax[2] << "/\n";
232 }
233
234 if (setX) {
235 for (Int_t i = 0; i < 3; i++) {
236 x_limits[2 * i] = JETLIM.xjmin[i];
237 x_limits[2 * i + 1] = JETLIM.xjmax[i];
238 }
239
240 *Writer << "X\n";
241 *Writer << JETLIM.xjmin[0] << ',' << JETLIM.xjmax[0] << ',';
242 *Writer << JETLIM.xjmin[1] << ',' << JETLIM.xjmax[1] << ',';
243 *Writer << JETLIM.xjmin[2] << ',' << JETLIM.xjmax[2] << "/\n";
244 }
245
246 if (setY) {
247 for (Int_t i = 0; i < 3; i++) {
248 y_limits[2 * i] = JETLIM.yjmin[i];
249 y_limits[2 * i + 1] = JETLIM.yjmax[i];
250 }
251
252 *Writer << "Y\n";
253 *Writer << JETLIM.yjmin[0] << ',' << JETLIM.yjmax[0] << ',';
254 *Writer << JETLIM.yjmin[1] << ',' << JETLIM.yjmax[1] << ',';
255 *Writer << JETLIM.yjmin[2] << ',' << JETLIM.yjmax[2] << "/\n";
256 }
257
258 if (setXgen) {
259 for (Int_t i = 0; i < 8; i++) peter_jet_frag[i] = FRGPAR.xgen[i];
260
261 *Writer << "XGEN\n";
262 for (Int_t i = 0; i < 7; i++) *Writer << FRGPAR.xgen[i] << ',';
263 *Writer << FRGPAR.xgen[7] << "/\n";
264 }
265
266 if (setPdf) {
267 *Writer << "PDFLIB\n";
268 for (Int_t i = 0; i < num_Pdf; i++) *Writer << "\'" << pdfpar[i] << "\'" << ',' << pdfval[i] << "/\n";
269 }
270
271
272 *Writer << "END\n";
273 *Writer << "STOP\n";
274 Write.close();
275
276// Stuff for online-control mode :
277
278 if (online) {
279 KEYS.reac = jobtype;
280 KEYS.keyon = false;
281 for (Int_t i = 0; i < KEYS.mxkeys; i++) KEYS.keys[i] = false;
282
283 if (!strcmp(KEYS.reac, "TWOJET")) {
284 KEYS.keys[0] = true;
285 KEYS.ikey = 1;
286 PRIMAR.njet = 2;
287 }
288 else if (!strcmp(KEYS.reac, "MINBIAS")) {
289 KEYS.keys[3] = true;
290 KEYS.ikey = 4;
291 PRIMAR.njet = 0;
292 }
293 else {
294 printf("Error in TIsajet::Initialise :\n");
295 printf("Invalid job type %s.\n", KEYS.reac);
296 printf("Only TWOJET and MINBIAS are currently supported for online mode.\n");
297 return;
298 }
299
300 if (setPdf) {
301 PDFinit();
302 }
303 }
304}
305
306/**************************************************************************/
307
308void TIsajet::Reload()
309{
310//
311// Sets the common block variables to the data member values.
312//
313
314 SetECM(center_energy);
315
316 if (setBeams) {
317 SetIDIN(0, beam1_type);
318 SetIDIN(1, beam2_type);
319 }
320
321 if (setCutjet) SetCUTJET(cutoff_mass);
322
323 if (setFragment) SetAllFRPAR(frag_params, 32);
324
325 if (setJettype1) for (Int_t i = 0; i < num_jet_type[0]; i++) SetJETYP(0, jet1_type[i]);
326
327 if (setJettype2) for (Int_t i = 0; i < num_jet_type[1]; i++) SetJETYP(1, jet2_type[i]);
328
329 if (setJettype3) for (Int_t i = 0; i < num_jet_type[2]; i++) SetJETYP(2, jet3_type[i]);
330
331 if (setLambda) SetALAM(qcd_lambda);
332
333 if (setNodcay) SetNODCAY(forbid_decay);
334
335 if (setNoeta) SetNOETA(forbid_eta);
336
337 if (setNoevolve) SetNOEVOL(forbid_evolve);
338
339 if (setNohadron) SetNOHADR(forbid_hadron);
340
341 if (setNopi0) SetNOPI0(forbid_pi0);
342
343 if (setNsigma) SetNSIGMA(generate_sigma);
344
345 if (setP) {
346 for (Int_t i = 0; i < 3; i++) {
347 SetPMIN(p_limits[2 * i], i);
348 SetPMAX(p_limits[2 * i + 1], i);
349 }
350 }
351
352 if (setPhi) {
353 for (Int_t i = 0; i < 3; i++) {
354 SetPHIMIN(phi_limits[2 * i], i);
355 SetPHIMAX(phi_limits[2 * i + 1], i);
356 }
357 }
358
359 if (setPt) {
360 for (Int_t i = 0; i < 3; i++) {
361 SetPTMIN(pt_limits[2 * i], i);
362 SetPTMAX(pt_limits[2 * i + 1], i);
363 }
364 }
365
366 if (setTheta) {
367 for (Int_t i = 0; i < 3; i++) {
368 SetTHMIN(theta_limits[2 * i], i);
369 SetTHMAX(theta_limits[2 * i + 1], i);
370 }
371 }
372
373 if (setX) {
374 for (Int_t i = 0; i < 3; i++) {
375 SetXJMIN(x_limits[2 * i], i);
376 SetXJMAX(x_limits[2 * i + 1], i);
377 }
378 }
379
380 if (setY) {
381 for (Int_t i = 0; i < 3; i++) {
382 SetYJMIN(y_limits[2 * i], i);
383 SetYJMAX(y_limits[2 * i + 1], i);
384 }
385 }
386
387 if (setXgen) SetAllXGEN(peter_jet_frag, 8);
388}
389
390/**************************************************************************/
391
392void TIsajet::RestoreDefaults()
393{
394// Booleans indicating which keywords should be written into the parameter file.
395
396 setBeams = setCutjet = setFragment = setJettype1 = false;
397 setJettype2 = setJettype3 = setLambda = setNodcay = false;
398 setNoeta = setNoevolve = setNohadron = setNopi0 = false;
399 setNsigma = setP = setPhi = setPt = setTheta = false;
400 setX = setXgen = setY = setPdf = false;
401 num_Pdf = 0;
402
403// Calling on FORTRAN for initialisation of variables
404
405 Openfiles();
406 Int_t a, b, c, d, e;
407
408 a = -54;
409 b = 0;
410 c = 51;
411 d = 53;
412
413 Isaini(a, b, c, d);
414 e = 0;
415 Isabeg(e);
416}
417
418/**************************************************************************/
419
420Int_t TIsajet::ImportParticles(TClonesArray *particles, Option_t *option)
421{
422//
423// Default primary creation method. It reads the /HEPEVT/ common block which
424// has been filled by the GenerateEvent method. If the event generator does
425// not use the HEPEVT common block, this routine has to be overloaded by
426// the subclasses.
427// The function loops on the generated particles and stores them in
428// the TClonesArray pointed by the argument particles.
429// The default action is to store only the stable particles (ISTHEP = 1)
430// This can be demanded explicitly by setting the option = "Final"
431// If the option = "All", all the particles are stored.
432//
433 if (particles == 0) return 0;
434 TClonesArray &Particles = *particles;
435 Particles.Clear();
436 TDatabasePDG* converter = TDatabasePDG::Instance();
437 Int_t numpart = PARTCL.nptcl;
438 printf("\n TIsajet: ISAJET stack contains %d particles.", numpart);
439 printf("\n TIsajet: Total energy: %f ", PRIMAR.ecm);
440 Int_t nump = 0;
441 if ((!strcmp(option,"")) || (!strcmp(option,"Final"))) {
442 for (Int_t i = 0; i < numpart; i++) {
443
444 if (PARTCL.idcay[i] == 0) { // Check whether particle is stable.
445//
446// Use the common block values for the TParticle constructor
447//
448 nump++;
449 new(Particles[i]) TParticle(
450 converter->ConvertIsajetToPdg(PARTCL.ident[i]) , // PDG code
451 0 , // Status - currently a default
452
453 -1, // Mothers and daughters - not used for stable particles
454 -1,
455 -1,
456 -1,
457
458 PARTCL.pptcl[i][0] , // x, y, z and 0 momenta
459 PARTCL.pptcl[i][1] ,
460 PARTCL.pptcl[i][2] ,
461 PARTCL.pptcl[i][3] ,
462
463 0, // Velocities - currently not used.
464 0,
465 0,
466 0);
467 }
468 }
469 }
470 else if (!strcmp(option,"All")) {
471 nump=numpart;
472 for (Int_t i = 0; i < numpart; i++) {
473
474 // Determine mother particle. Set to -1 if the particle originates from
475 // a parton or is a beam particle.
476
477 Int_t origin = PARTCL.iorig[i];
478 Int_t jet = origin / PARTCL.ipack;
479 origin = origin - (jet * PARTCL.ipack);
480
481 if (origin < 0) origin = 0;
482
483 // Determine first and last decay products. Both are -1 if the particle is stable.
484 // Note this means they are set to 0, because one is subtracted after decoding;
485 // this avoid off-by-one errors relative to the FORTRAN.
486
487 Int_t first_Daughter = 0;
488 Int_t last_Daughter = 0;
489
490 if (PARTCL.idcay[i] != 0) {
491 first_Daughter = PARTCL.idcay[i] / PARTCL.ipack;
492 last_Daughter = PARTCL.idcay[i] - (first_Daughter * PARTCL.ipack);
493 }
494 new(Particles[i]) TParticle(
495 converter->ConvertIsajetToPdg(PARTCL.ident[i]) ,
496 0,
497
498 origin - 1,
499 -1,
500 first_Daughter - 1,
501 last_Daughter - 1,
502
503 PARTCL.pptcl[i][0] ,
504 PARTCL.pptcl[i][1] ,
505 PARTCL.pptcl[i][2] ,
506 PARTCL.pptcl[i][3] ,
507
508 0,
509 0,
510 0,
511 0);
512 }
513 }
514 return nump;
515}
516
517/**************************************************************************/
518
519void TIsajet::GenerateEvent()
520{
521 Int_t e, ok, done;
522
523// e = 0;
524
525// if (online) Isabg2(e);
526// else Isabeg(e);
527
528 e = 1;
529 Isaevt(e, ok, done);
530}
531
532/**************************************************************************/
533
534void TIsajet::SetJobtype(Char_t *val)
535{
536 if ((!strcmp(val, "TWOJET")) || (!strcmp(val, "E+E-")) ||
537 (!strcmp(val, "DRELLYAN")) || (!strcmp(val, "MINBIAS")) ||
538 (!strcmp(val, "SUSY")) || (!strcmp(val, "WPAIR")) ||
539 (!strcmp(val, "HIGGS")) || (!strcmp(val, "PHOTON")) ||
540 (!strcmp(val, "TCOLOR")) || (!strcmp(val, "WHIGGS")) ||
541 (!strcmp(val, "EXTRADIM")) || (!strcmp(val, "ZJJ"))) {
542 jobtype = val;
543 }
544 else {
545 printf("Error in TIsajet::SetJobtype :\n");
546 printf("Invalid reaction keyword %s.\n", val);
547 printf("Valid keywords are : TWOJET, E+E-, DRELLYAN,\n");
548 printf("MINBIAS, SUSY, WPAIR, HIGGS, PHOTON, TCOLOR,\n");
549 printf("WHIGGS, EXTRADIM and ZJJ.\n");
550 }
551}
552
553/**************************************************************************/
554
555void TIsajet::GetJobtype() const
556{
557 printf ("Current job type is %s.\n", jobtype);
558}
559
560/**************************************************************************/
561
562void TIsajet::SetOnline(Bool_t val)
563{
564 online = val;
565}
566
567/**************************************************************************/
568
569Bool_t TIsajet::GetOnline() const
570{
571 return online;
572}
573
574/**************************************************************************/
575
576void TIsajet::SetPDF(Char_t *name, Float_t val)
577{
578 if (num_Pdf < 19) {
579 pdfpar[num_Pdf] = name;
580 pdfval[num_Pdf] = val;
581 num_Pdf++;
582 setPdf = true;
583 }
584 else {
585 printf ("Error in TIsajet::SetPDF :\n");
586 printf ("Maximum of twenty PDF parameters may be set.\n");
587 }
588}
589
590/**************************************************************************/
591
592// Access routines for common blocks.
593// Begins DYLIM access.
594
595/**************************************************************************/
596
597void TIsajet::SetQMIN(Float_t val)
598{
599 if (val > DYLIM.qmax) {
600 printf("Error in TIsajet::SetQMIN : \n");
601 printf("You may not set QMIN to a value larger than QMAX = %f.\n", DYLIM.qmax);
602 return;
603 }
604
605 DYLIM.qmin = val;
606 if (!DYLIM.ywset) SetYWLIMS();
607}
608
609/**************************************************************************/
610
611Float_t TIsajet::GetQMIN() const
612{
613 return DYLIM.qmin;
614}
615
616/**************************************************************************/
617
618void TIsajet::SetQMAX(Float_t val)
619{
620 if (val < DYLIM.qmin) {
621 printf("Error in TIsajet::SetQMAX : \n");
622 printf("You may not set QMAX to a value less than QMIN = %f.\n", DYLIM.qmin);
623 return;
624 }
625
626 DYLIM.qmax = val;
627}
628
629/**************************************************************************/
630
631Float_t TIsajet::GetQMAX() const
632{
633 return DYLIM.qmax;
634}
635
636/**************************************************************************/
637
638void TIsajet::SetQTMIN(Float_t val)
639{
640 if (val > DYLIM.qtmax) {
641 printf("Error in TIsajet::SetQTMIN : \n");
642 printf("You may not set QTMIN to a value larger than QTMAX = %f.\n", DYLIM.qtmax);
643 return;
644 }
645 DYLIM.qtmin = val;
646 if (!DYLIM.ywset) SetYWLIMS();
647}
648
649/**************************************************************************/
650
651Float_t TIsajet::GetQTMIN() const
652{
653 return DYLIM.qtmin;
654}
655
656/**************************************************************************/
657
658void TIsajet::SetQTMAX(Float_t val)
659{
660 if (val < DYLIM.qtmin) {
661 printf("Error in TIsajet::SetQTMAX : \n");
662 printf("You may not set QTMAX to a value less than QTMIN = %f.\n", DYLIM.qtmin);
663 return;
664 }
665
666 DYLIM.qtmax = val;
667 if (!DYLIM.ywset) SetYWLIMS();
668}
669
670/**************************************************************************/
671
672Float_t TIsajet::GetQTMAX() const
673{
674 return DYLIM.qtmax;
675}
676
677/**************************************************************************/
678
679void TIsajet::SetYWMIN(Float_t val)
680{
681 if (val > DYLIM.ywmax) {
682 printf("Error in TIsajet::SetYWMIN : \n");
683 printf("You may not set YWMIN to a value larger than YWMAX = %f.\n", DYLIM.ywmax);
684 return;
685 }
686
687 if (DYLIM.thwset) {
688 printf("Error in TIsajet::SetYWMIN :\n");
689 printf("May not set both theta and y limits. Use SetTHWLIMS, then set YWMIN.\n");
690 }
691 else {
692 DYLIM.ywset = true;
693 DYLIM.ywmin = val;
694 }
695}
696
697/**************************************************************************/
698
699Float_t TIsajet::GetYWMIN() const
700{
701 return DYLIM.ywmin;
702}
703
704/**************************************************************************/
705
706void TIsajet::SetYWMAX(Float_t val)
707{
708 if (val < DYLIM.ywmin) {
709 printf("Error in TIsajet::SetYWMAX : \n");
710 printf("You may not set YWMAX to a value less than YWMIN = %f.\n", DYLIM.ywmin);
711 return;
712 }
713
714 if (DYLIM.thwset) {
715 printf("Error in TIsajet::SetYWMAX :\n");
716 printf("May not set both theta and y limits. Use SetTHWLIMS, then set YWMAX.\n");
717 }
718 else {
719 DYLIM.ywset = true;
720 DYLIM.ywmax = val;
721 }
722}
723
724/**************************************************************************/
725
726Float_t TIsajet::GetYWMAX() const
727{
728 return DYLIM.ywmax;
729}
730
731/**************************************************************************/
732
733void TIsajet::SetYWLIMS()
734{
735 Float_t rot = sqrt(DYLIM.qmin * DYLIM.qmin + DYLIM.qtmin * DYLIM.qtmin);
736 DYLIM.ywmax = acosh(PRIMAR.halfe / rot);
737 DYLIM.ywmin = -DYLIM.ywmax;
738 DYLIM.ywset = false;
739}
740
741/**************************************************************************/
742
743void TIsajet::SetXWMIN(Float_t val)
744{
745 if (val > DYLIM.xwmax) {
746 printf("Error in TIsajet::SetXWMIN : \n");
747 printf("You may not set XWMIN to a value larger than XWMAX = %f.\n", DYLIM.xwmax);
748 return;
749 }
750 DYLIM.xwmin = val;
751}
752
753/**************************************************************************/
754
755Float_t TIsajet::GetXWMIN() const
756{
757 return DYLIM.xwmin;
758}
759
760/**************************************************************************/
761
762void TIsajet::SetXWMAX(Float_t val)
763{
764 if (val < DYLIM.xwmin) {
765 printf("Error in TIsajet::SetXWMAX : \n");
766 printf("You may not set XWMAX to a value less than XWMIN = %f.\n", DYLIM.xwmin);
767 return;
768 }
769
770 DYLIM.xwmax = val;
771}
772
773/**************************************************************************/
774
775Float_t TIsajet::GetXWMAX() const
776{
777 return DYLIM.xwmax;
778}
779
780/**************************************************************************/
781
782void TIsajet::SetTHWMIN(Float_t val)
783{
784 if (val > DYLIM.thwmax) {
785 printf("Error in TIsajet::SetTHWMIN : \n");
786 printf("You may not set THWMIN to a value larger than THWMAX = %f.\n", DYLIM.thwmax);
787 return;
788 }
789
790 if (DYLIM.ywset) {
791 printf("Error in TIsajet::SetTHWMIN :\n");
792 printf("May not set both theta and y limits. Use SetYWLIMS, then set THWMIN.\n");
793 }
794 else {
795 DYLIM.thwset = true;
796 DYLIM.thwmin = val;
797 }
798}
799
800/**************************************************************************/
801
802Float_t TIsajet::GetTHWMIN() const
803{
804 return DYLIM.thwmin;
805}
806
807/**************************************************************************/
808
809void TIsajet::SetTHWMAX(Float_t val)
810{
811 if (val < DYLIM.thwmin) {
812 printf("Error in TIsajet::SetTHWMAX : \n");
813 printf("You may not set THWMAX to a value less than THWMIN = %f.\n", DYLIM.thwmin);
814 return;
815 }
816
817 if (DYLIM.ywset) {
818 printf("Error in TIsajet::SetTHWMAX :\n");
819 printf("May not set both theta and y limits. Use SetYWLIMS, then set THWMAX.\n");
820 }
821 else {
822 DYLIM.thwset = true;
823 DYLIM.thwmax = val;
824 }
825}
826
827/**************************************************************************/
828
829Float_t TIsajet::GetTHWMAX() const
830{
831 return DYLIM.thwmax;
832}
833
834/**************************************************************************/
835
836void TIsajet::SetTHWLIMS()
837{
838 DYLIM.thwmin = 0;
839 DYLIM.thwmax = TMath::Pi();
840 DYLIM.thwset = false;
841}
842
843/**************************************************************************/
844
845void TIsajet::SetPHWMIN(Float_t val)
846{
847 if (val > DYLIM.phwmax) {
848 printf("Error in TIsajet::SetPHWMIN : \n");
849 printf("You may not set PHWMIN to a value larger than PHWMAX = %f.\n", DYLIM.phwmax);
850 return;
851 }
852 DYLIM.phwmin = val;
853}
854
855/**************************************************************************/
856
857Float_t TIsajet::GetPHWMIN() const
858{
859 return DYLIM.phwmin;
860}
861
862/**************************************************************************/
863
864void TIsajet::SetPHWMAX(Float_t val)
865{
866 if (val < DYLIM.phwmin) {
867 printf("Error in TIsajet::SetPHWMAX : \n");
868 printf("You may not set PHWMAX to a value less than PHWMIN = %f.\n", DYLIM.phwmin);
869 return;
870 }
871
872 DYLIM.phwmax = val;
873}
874
875/**************************************************************************/
876
877Float_t TIsajet::GetPHWMAX() const
878{
879 return DYLIM.phwmax;
880}
881
882/**************************************************************************/
883
884Bool_t TIsajet::GetSETLMQ(Int_t index) const
885{
886 Int_t length = (sizeof DYLIM.setlmq / sizeof DYLIM.setlmq[0]);
887 if ((index < 0) || (index >= length)) {
888 printf ("Error in TIsajet::GetSETLMQ : \n");
889 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
890 return 0;
891 }
892
893 return DYLIM.setlmq[index];
894}
895
896/**************************************************************************/
897
898// End of DYLIM access.
899// Begins EEPAR access.
900
901/**************************************************************************/
902
903void TIsajet::SetPLEP(Float_t val)
904{
905 EEPAR.plep = val;
906}
907
908/**************************************************************************/
909
910Float_t TIsajet::GetPLEP() const
911{
912 return EEPAR.plep;
913}
914
915/**************************************************************************/
916
917void TIsajet::SetPLEM(Float_t val)
918{
919 EEPAR.plem = val;
920}
921
922/**************************************************************************/
923
924Float_t TIsajet::GetPLEM() const
925{
926 return EEPAR.plem;
927}
928
929/**************************************************************************/
930
931void TIsajet::SetRSHMIN(Float_t val)
932{
933 if (val > EEPAR.rshmax) {
934 printf("Error in TIsajet::SetRSHMIN : \n");
935 printf("You may not set RSHMIN to a value larger than RSHMAX = %f.\n", EEPAR.rshmax);
936 return;
937 }
938 EEPAR.rshmin = val;
939}
940
941/**************************************************************************/
942
943Float_t TIsajet::GetRSHMIN() const
944{
945 return EEPAR.rshmin;
946}
947
948/**************************************************************************/
949
950void TIsajet::SetRSHMAX(Float_t val)
951{
952 if (val < EEPAR.rshmin) {
953 printf("Error in TIsajet::SetRSHMAX : \n");
954 printf("You may not set RSHMAX to a value less than RSHMIN = %f.\n", EEPAR.rshmin);
955 return;
956 }
957
958 EEPAR.rshmax = val;
959}
960
961/**************************************************************************/
962
963Float_t TIsajet::GetRSHMAX() const
964{
965 return EEPAR.rshmax;
966}
967
968/**************************************************************************/
969
970void TIsajet::SetUPSLON(Float_t val)
971{
972 EEPAR.upslon = val;
973}
974
975/**************************************************************************/
976
977Float_t TIsajet::GetUPSLON() const
978{
979 return EEPAR.upslon;
980}
981
982/**************************************************************************/
983
984void TIsajet::SetSIGZ(Float_t val)
985{
986 EEPAR.sigz = val;
987}
988
989/**************************************************************************/
990
991Float_t TIsajet::GetSIGZ() const
992{
993 return EEPAR.sigz;
994}
995
996/**************************************************************************/
997
998Bool_t TIsajet::GetIBREM() const
999{
1000 return EEPAR.ibrem;
1001}
1002
1003/**************************************************************************/
1004
1005Bool_t TIsajet::GetIBEAM() const
1006{
1007 return EEPAR.ibeam;
1008}
1009
1010/**************************************************************************/
1011
1012Float_t TIsajet::GetSGMXEE() const
1013{
1014 return EEPAR.sgmxee;
1015}
1016
1017/**************************************************************************/
1018
1019// End of EEPAR access.
1020// Begins FORCE access.
1021
1022/**************************************************************************/
1023
1024Int_t TIsajet::GetNFORCE() const
1025{
1026 return FORCE.nforce;
1027}
1028
1029/**************************************************************************/
1030
1031void TIsajet::SetIFORCE(const Int_t val[], Int_t arraySize, Bool_t anti = true)
1032{
1033 if (GetNFORCE() >= FORCE.mxforc - anti) {
1034 printf ("ERROR in TIsajet::SetIFORCE :\n");
1035 printf ("Cannot have more than %d forced decays.\n", FORCE.mxforc );
1036 return;
1037 }
1038
1039 if ((arraySize > 6) || (arraySize < 2)) {
1040 printf ("Error in TIsajet::SetIFORCE : \n");
1041 printf ("Invalid array size %d; must be 2-6.\n", arraySize);
1042 return;
1043 }
1044
1045 for (Int_t i = 0; i < FORCE.nforce; i++) {
1046 if (FORCE.iforce[i] == val[0]) {
1047 printf ("Error in TIsajet::SetIFORCE : \n");
1048 printf ("Particle %d has already been forced, index %d.\n", val[0], i);
1049 return;
1050 }
1051 }
1052
1053
1054 FORCE.iforce[FORCE.nforce] = val[0];
1055 for (Int_t i = 1; i < arraySize; i++) {
1056 FORCE.mforce[FORCE.nforce][i-1] = val[i];
1057 }
1058
1059 FORCE.nforce++;
1060
1061 printf ("Decay channel %d -> ", val[0]);
1062 for (Int_t i = 1; i < arraySize; i++) {
1063 printf ("%d, ", val[i]);
1064 }
1065 printf ("set. \n");
1066
1067 if (anti) {
1068 Int_t antivals[arraySize];
1069 for (Int_t i = 0; i < arraySize; i++){
1070 antivals[i] = (0 - val[i]);
1071 }
1072 SetIFORCE(antivals, arraySize, false);
1073 }
1074}
1075
1076/**************************************************************************/
1077
1078void TIsajet::UnForce(Int_t index, Bool_t anti = true)
1079{
1080 if (FORCE.nforce == 0) {
1081 printf ("Error in TIsajet::UnForce : \n");
1082 printf ("No decays have been forced.\n");
1083 return;
1084 }
1085
1086 if ((index < 0) || (index >= FORCE.nforce)) {
1087 printf ("Error in TIsajet::UnForce : \n");
1088 printf ("Invalid decay index %d; range is 0-%d.\n", index, FORCE.nforce-1);
1089 return;
1090 }
1091
1092 Int_t particle_ID = FORCE.iforce[index];
1093
1094 for (Int_t i = index; i < FORCE.mxforc - 1; i++) {
1095 FORCE.iforce[i] = FORCE.iforce[i+1];
1096 for (Int_t j = 0; j < 5; j++) {
1097 FORCE.mforce[i][j] = FORCE.mforce[i+1][j];
1098 }
1099 }
1100 FORCE.iforce[FORCE.mxforc - 1] = 0;
1101 for (Int_t j = 0; j < 5; j++) {
1102 FORCE.mforce[FORCE.mxforc - 1][j] = 0;
1103 }
1104
1105 FORCE.nforce--;
1106
1107 printf ("Decay of %d unforced.\n", particle_ID);
1108
1109 if (anti) UnForceID(-particle_ID, false);
1110}
1111
1112/**************************************************************************/
1113
1114void TIsajet::UnForceID(Int_t particle_ID, Bool_t anti = true)
1115{
1116 if (FORCE.nforce == 0) {
1117 printf ("Error in TIsajet::UnForceID : \n");
1118 printf ("No decays have been forced.\n");
1119 return;
1120 }
1121
1122 for (Int_t i = 0; i < FORCE.nforce; i++) {
1123 if (FORCE.iforce[i] == particle_ID) {
1124 UnForce(i, anti);
1125 return;
1126 }
1127 }
1128
1129 printf ("Error in TIsajet::UnForceID : \n");
1130 printf ("Cannot find particle %d.\n", particle_ID);
1131}
1132
1133/**************************************************************************/
1134
1135Int_t* TIsajet::GetIFORCE(Int_t index) const
1136{
1137 if (FORCE.nforce == 0) {
1138 printf ("Error in TIsajet::GetIFORCE : \n");
1139 printf ("No decays have been forced.\n");
1140 return 0;
1141 }
1142
1143 if ((index < 0) || (index >= FORCE.nforce)) {
1144 printf ("Error in TIsajet::GetIFORCE : \n");
1145 printf ("Invalid decay index %d; range is 0-%d.\n", index, FORCE.nforce-1);
1146 return 0;
1147 }
1148
1149 Int_t decay[6];
1150 decay[0] = FORCE.iforce[index];
1151
1152 for (Int_t i = 1; i < 6; i++) {
1153 decay[i] = FORCE.mforce[index][i-1];
1154 }
1155
1156 return decay;
1157}
1158
1159/**************************************************************************/
1160
1161Int_t TIsajet::GetMEFORC(Int_t index) const
1162{
1163 if (FORCE.nforce == 0) {
1164 printf ("Error in TIsajet::GetMEFORCE : \n");
1165 printf ("No decays have been forced.\n");
1166 return 0;
1167 }
1168
1169 if ((index < 0) || (index >= FORCE.nforce)) {
1170 printf ("Error in TIsajet::GetMEFORC : \n");
1171 printf ("Invalid array index %d; range is 0-%d.\n", index, FORCE.nforce-1);
1172 return 0;
1173 }
1174
1175 return FORCE.meforc[index];
1176}
1177
1178/**************************************************************************/
1179
1180// End of FORCE access.
1181// Begins FRGPAR access.
1182
1183/**************************************************************************/
1184
1185void TIsajet::SetFRPAR(Float_t val, Int_t index)
1186{
1187 Int_t length = (sizeof FRGPAR.frpar / sizeof FRGPAR.frpar[0]);
1188 if ((index < 0) || (index >= length)) {
1189 printf ("Error in TIsajet::SetFRPAR : \n");
1190 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1191 return;
1192 }
1193
1194 *FRGPAR.frpar[index] = val;
1195 setFragment = true;
1196}
1197
1198/**************************************************************************/
1199
1200void TIsajet::SetAllFRPAR(const Float_t val[], Int_t arraySize)
1201{
1202 Int_t length = (sizeof FRGPAR.frpar / sizeof FRGPAR.frpar[0]);
1203 if (arraySize != length) {
1204 printf ("Error in TIsajet::SetAllFRPAR : \n");
1205 printf ("Array must have %d elements.\n", length);
1206 return;
1207 }
1208
1209 for (Int_t i = 0; i < arraySize; i++) {
1210 SetFRPAR(val[i], i);
1211 }
1212}
1213
1214/**************************************************************************/
1215
1216Float_t TIsajet::GetFRPAR(Int_t index) const
1217{
1218 Int_t length = (sizeof FRGPAR.frpar / sizeof FRGPAR.frpar[0]);
1219 if ((index < 0) || (index >= length)) {
1220 printf ("Error in TIsajet::GetFRPAR : \n");
1221 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1222 return 0;
1223 }
1224
1225 return *FRGPAR.frpar[index];
1226}
1227
1228/**************************************************************************/
1229
1230void TIsajet::SetPUD(Float_t val)
1231{
1232 SetFRPAR(val, 0);
1233}
1234
1235/**************************************************************************/
1236
1237Float_t TIsajet::GetPUD() const
1238{
1239 return GetFRPAR(0);
1240}
1241
1242/**************************************************************************/
1243
1244void TIsajet::SetPBARY(Float_t val)
1245{
1246 SetFRPAR(val, 1);
1247}
1248
1249/**************************************************************************/
1250
1251Float_t TIsajet::GetPBARY() const
1252{
1253 return GetFRPAR(1);
1254}
1255
1256/**************************************************************************/
1257
1258void TIsajet::SetSIGQT(Float_t val)
1259{
1260 SetFRPAR(val, 2);
1261}
1262
1263/**************************************************************************/
1264
1265Float_t TIsajet::GetSIGQT() const
1266{
1267 return GetFRPAR(2);
1268}
1269
1270/**************************************************************************/
1271
1272void TIsajet::SetPEND(Float_t val)
1273{
1274 SetFRPAR(val, 3);
1275}
1276
1277/**************************************************************************/
1278
1279Float_t TIsajet::GetPEND() const
1280{
1281 return GetFRPAR(3);
1282}
1283
1284/**************************************************************************/
1285
1286void TIsajet::SetXGEN(Float_t val, Int_t index)
1287{
1288 Int_t length = (sizeof FRGPAR.xgen / sizeof FRGPAR.xgen[0]);
1289 if ((index < 0) || (index >= length)) {
1290 printf ("Error in TIsajet::SetXGEN : \n");
1291 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1292 return;
1293 }
1294 SetFRPAR(val, index + 4);
1295 setXgen = true;
1296}
1297
1298/**************************************************************************/
1299
1300void TIsajet::SetAllXGEN(const Float_t val[], Int_t arraySize)
1301{
1302 Int_t length = (sizeof FRGPAR.xgen / sizeof FRGPAR.xgen[0]);
1303 if (arraySize != length) {
1304 printf ("Error in TIsajet::SetAllXGEN : \n");
1305 printf ("Array must have %d elements.\n", length);
1306 return;
1307 }
1308
1309 for (Int_t i = 0; i < arraySize; i++) {
1310 SetXGEN(val[i], i);
1311 }
1312}
1313
1314/**************************************************************************/
1315
1316Float_t TIsajet::GetXGEN(Int_t index) const
1317{
1318 Int_t length = (sizeof FRGPAR.xgen / sizeof FRGPAR.xgen[0]);
1319 if ((index < 0) || (index >= length)) {
1320 printf ("Error in TIsajet::GetXGEN : \n");
1321 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1322 return 0;
1323 }
1324
1325 return GetFRPAR(index + 4);
1326}
1327
1328/**************************************************************************/
1329
1330void TIsajet::SetPSPIN1(Float_t val, Int_t index)
1331{
1332 Int_t length = (sizeof FRGPAR.pspin1 / sizeof FRGPAR.pspin1[0]);
1333 if ((index < 0) || (index >= length)) {
1334 printf ("Error in TIsajet::SetPSPIN1 : \n");
1335 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1336 return;
1337 }
1338
1339 SetFRPAR(val, index + 12);
1340}
1341
1342/**************************************************************************/
1343
1344void TIsajet::SetAllPSPIN1(const Float_t val[], Int_t arraySize)
1345{
1346 Int_t length = (sizeof FRGPAR.pspin1 / sizeof FRGPAR.pspin1[0]);
1347 if (arraySize != length) {
1348 printf ("Error in TIsajet::SetAllPSPIN1 : \n");
1349 printf ("Array must have %d elements.\n", length);
1350 return;
1351 }
1352
1353 for (Int_t i = 0; i < arraySize; i++) {
1354 SetPSPIN1(val[i], i);
1355 }
1356}
1357
1358/**************************************************************************/
1359
1360Float_t TIsajet::GetPSPIN1(Int_t index) const
1361{
1362 Int_t length = (sizeof FRGPAR.xgen / sizeof FRGPAR.xgen[0]);
1363 if ((index < 0) || (index >= length)) {
1364 printf ("Error in TIsajet::GetPSPIN1 : \n");
1365 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1366 return 0;
1367 }
1368
1369 return GetFRPAR(index + 12);
1370}
1371
1372/**************************************************************************/
1373
1374void TIsajet::SetPMIX1(Float_t val, Int_t index1, Int_t index2)
1375{
1376 Int_t col_num = (sizeof FRGPAR.pmix1[0] / sizeof FRGPAR.pmix1[0][0]);
1377 Int_t row_num = (sizeof FRGPAR.pmix1 / (sizeof FRGPAR.pmix1[0][0] * col_num));
1378
1379 if ((index1 < 0) || (index1 >= row_num)) {
1380 printf ("Error in TIsajet::SetPMIX1 : \n");
1381 printf ("Invalid array row index %d; range is 0-%d.\n", index1, row_num-1);
1382 return;
1383 }
1384
1385 if ((index2 < 0) || (index2 >= col_num)) {
1386 printf ("Error in TIsajet::SetPMIX1 : \n");
1387 printf ("Invalid array column index %d; range is 0-%d.\n", index2, col_num-1);
1388 return;
1389 }
1390
1391 FRGPAR.pmix1[index1][index2] = val;
1392 setFragment = true;
1393}
1394
1395/**************************************************************************/
1396
1397void TIsajet::SetAllPMIX1(const Float_t val[2][3])
1398{
1399 for (Int_t i = 0; i < 2; i++) {
1400 for (Int_t j = 0; j < 3; j++) {
1401 SetPMIX1(val[i][j], i, j);
1402 }
1403 }
1404}
1405
1406/**************************************************************************/
1407
1408void TIsajet::SetColumnPMIX1(const Float_t val[], Int_t col)
1409{
1410 Int_t col_num = (sizeof FRGPAR.pmix1[0] / sizeof FRGPAR.pmix1[0][0]);
1411 Int_t row_num = (sizeof FRGPAR.pmix1 / (sizeof FRGPAR.pmix1[0][0] * col_num));
1412
1413 if ((col < 0) || (col >= col_num)) {
1414 printf ("Error in TIsajet::SetColumnPMIX1 : \n");
1415 printf ("Invalid column index %d, range is 0-%d.\n", col, col_num-1);
1416 return;
1417 }
1418
1419 for (Int_t i = 0; i < row_num; i++) {
1420 SetPMIX1(val[i], i, col);
1421 }
1422}
1423
1424/**************************************************************************/
1425
1426Float_t TIsajet::GetPMIX1(Int_t index1, Int_t index2) const
1427{
1428 Int_t col_num = (sizeof FRGPAR.pmix1[0] / sizeof FRGPAR.pmix1[0][0]);
1429 Int_t row_num = (sizeof FRGPAR.pmix1 / (sizeof FRGPAR.pmix1[0][0] * col_num));
1430
1431 if ((index1 < 0) || (index1 >= row_num)) {
1432 printf ("Error in TIsajet::GetPMIX1 : \n");
1433 printf ("Invalid array row index %d; range is 0-%d.\n", index1, row_num-1);
1434 return 0;
1435 }
1436
1437 if ((index2 < 0) || (index2 >= col_num)) {
1438 printf ("Error in TIsajet::GetPMIX1 : \n");
1439 printf ("Invalid array column index %d; range is 0-%d.\n", index2, col_num-1);
1440 return 0;
1441 }
1442
1443 return FRGPAR.pmix1[index1][index2];
1444}
1445
1446/**************************************************************************/
1447
1448void TIsajet::SetPMIX2(Float_t val, Int_t index1, Int_t index2)
1449{
1450 Int_t col_num = (sizeof FRGPAR.pmix2[0] / sizeof FRGPAR.pmix2[0][0]);
1451 Int_t row_num = (sizeof FRGPAR.pmix2 / (sizeof FRGPAR.pmix2[0][0] * col_num));
1452
1453 if ((index1 < 0) || (index1 >= row_num)) {
1454 printf ("Error in TIsajet::SetPMIX2 : \n");
1455 printf ("Invalid array row index %d; range is 0-%d.\n", index1, row_num-1);
1456 return;
1457 }
1458
1459 if ((index2 < 0) || (index2 >= col_num)) {
1460 printf ("Error in TIsajet::SetPMIX2 : \n");
1461 printf ("Invalid array column index %d; range is 0-%d.\n", index2, col_num-1);
1462 return;
1463 }
1464
1465 FRGPAR.pmix2[index1][index2] = val;
1466 setFragment = true;
1467}
1468
1469/**************************************************************************/
1470
1471void TIsajet::SetAllPMIX2(const Float_t val[2][3])
1472{
1473 for (Int_t i = 0; i < 2; i++) {
1474 for (Int_t j = 0; j < 3; j++) {
1475 SetPMIX2(val[i][j], i, j);
1476 }
1477 }
1478}
1479
1480/**************************************************************************/
1481
1482void TIsajet::SetColumnPMIX2(const Float_t val[], Int_t col)
1483{
1484 Int_t col_num = (sizeof FRGPAR.pmix2[0] / sizeof FRGPAR.pmix2[0][0]);
1485 Int_t row_num = (sizeof FRGPAR.pmix2 / (sizeof FRGPAR.pmix2[0][0] * col_num));
1486
1487 if ((col < 0) || (col >= col_num)) {
1488 printf ("Error in TIsajet::SetColumnPMIX2 : \n");
1489 printf ("Invalid column index %d, range is 0-%d.\n", col, col_num-1);
1490 return;
1491 }
1492
1493 for (Int_t i = 0; i < row_num; i++) {
1494 SetPMIX2(val[i], i, col);
1495 }
1496}
1497
1498/**************************************************************************/
1499
1500Float_t TIsajet::GetPMIX2(Int_t index1, Int_t index2) const
1501{
1502 Int_t col_num = (sizeof FRGPAR.pmix2[0] / sizeof FRGPAR.pmix2[0][0]);
1503 Int_t row_num = (sizeof FRGPAR.pmix2 / (sizeof FRGPAR.pmix2[0][0] * col_num));
1504
1505 if ((index1 < 0) || (index1 >= row_num)) {
1506 printf ("Error in TIsajet::GetPMIX2 : \n");
1507 printf ("Invalid array row index %d; range is 0-%d.\n", index1, row_num-1);
1508 return 0;
1509 }
1510
1511 if ((index2 < 0) || (index2 >= col_num)) {
1512 printf ("Error in TIsajet::GetPMIX2 : \n");
1513 printf ("Invalid array column index %d; range is 0-%d.\n", index2, col_num-1);
1514 return 0;
1515 }
1516
1517 return FRGPAR.pmix2[index1][index2];
1518}
1519
1520/**************************************************************************/
1521
1522void TIsajet::SetPMIXX1(Float_t val, Int_t index)
1523{
1524 Int_t length = (sizeof FRGPAR.pmixx1 / sizeof FRGPAR.pmixx1[0]);
1525 if ((index < 0) || (index >= length)) {
1526 printf ("Error in TIsajet::SetPMIXX1 : \n");
1527 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1528 return;
1529 }
1530
1531 *FRGPAR.pmixx1[index] = val;
1532 setFragment = true;
1533}
1534
1535/**************************************************************************/
1536
1537void TIsajet::SetAllPMIXX1(const Float_t val[], Int_t arraySize)
1538{
1539 Int_t length = (sizeof FRGPAR.pmixx1 / sizeof FRGPAR.pmixx1[0]);
1540 if (arraySize != length) {
1541 printf ("Error in TIsajet::SetAllPMIXX1 : \n");
1542 printf ("Array must have %d elements.\n", length);
1543 return;
1544 }
1545
1546 for (Int_t i = 0; i < arraySize; i++) {
1547 SetPMIXX1(val[i], i);
1548 }
1549}
1550
1551/**************************************************************************/
1552
1553Float_t TIsajet::GetPMIXX1(Int_t index) const
1554{
1555 Int_t length = (sizeof FRGPAR.pmixx1 / sizeof FRGPAR.pmixx1[0]);
1556 if ((index < 0) || (index >= length)) {
1557 printf ("Error in TIsajet::GetPMIXX1 : \n");
1558 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1559 return 0;
1560 }
1561
1562 return *FRGPAR.pmixx1[index];
1563}
1564
1565/**************************************************************************/
1566
1567void TIsajet::SetPMIXX2(Float_t val, Int_t index)
1568{
1569 Int_t length = (sizeof FRGPAR.pmixx2 / sizeof FRGPAR.pmixx2[0]);
1570 if ((index < 0) || (index >= length)) {
1571 printf ("Error in TIsajet::SetPMIXX2 : \n");
1572 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1573 return;
1574 }
1575
1576 *FRGPAR.pmixx2[index] = val;
1577 setFragment = true;
1578}
1579
1580/**************************************************************************/
1581
1582void TIsajet::SetAllPMIXX2(const Float_t val[], Int_t arraySize)
1583{
1584 Int_t length = (sizeof FRGPAR.pmixx2 / sizeof FRGPAR.pmixx2[0]);
1585 if (arraySize != length) {
1586 printf ("Error in TIsajet::SetAllPMIXX2 : \n");
1587 printf ("Array must have %d elements.\n", length);
1588 return;
1589 }
1590
1591 for (Int_t i = 0; i < arraySize; i++) {
1592 SetPMIXX2(val[i], i);
1593 }
1594}
1595
1596/**************************************************************************/
1597
1598Float_t TIsajet::GetPMIXX2(Int_t index) const
1599{
1600 Int_t length = (sizeof FRGPAR.pmixx2 / sizeof FRGPAR.pmixx2[0]);
1601 if ((index < 0) || (index >= length)) {
1602 printf ("Error in TIsajet::GetPMIXX2 : \n");
1603 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1604 return 0;
1605 }
1606
1607 return *FRGPAR.pmixx2[index];
1608}
1609
1610/**************************************************************************/
1611
1612void TIsajet::SetXGENSS(Float_t val, Int_t index)
1613{
1614 Int_t length = (sizeof FRGPAR.xgenss / sizeof FRGPAR.xgenss[0]);
1615 if ((index < 0) || (index >= length)) {
1616 printf ("Error in TIsajet::SetXGENSS : \n");
1617 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1618 return;
1619 }
1620
1621 FRGPAR.xgenss[index] = val;
1622}
1623
1624/**************************************************************************/
1625
1626void TIsajet::SetAllXGENSS(const Float_t val[], Int_t arraySize)
1627{
1628 Int_t length = (sizeof FRGPAR.xgenss / sizeof FRGPAR.xgenss[0]);
1629 if (arraySize != length) {
1630 printf ("Error in TIsajet::SetAllXGENSS : \n");
1631 printf ("Array must have %d elements.\n", length);
1632 return;
1633 }
1634
1635 for (Int_t i = 0; i < arraySize; i++) {
1636 SetXGENSS(val[i], i);
1637 }
1638}
1639
1640/**************************************************************************/
1641
1642Float_t TIsajet::GetXGENSS(Int_t index) const
1643{
1644 Int_t length = (sizeof FRGPAR.xgenss / sizeof FRGPAR.xgenss[0]);
1645 if ((index < 0) || (index >= length)) {
1646 printf ("Error in TIsajet::GetXGENSS : \n");
1647 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1648 return 0;
1649 }
1650
1651 return FRGPAR.xgenss[index];
1652}
1653
1654/**************************************************************************/
1655
1656// End of FRGPAR access.
1657// Begins HCON access.
1658
1659/**************************************************************************/
1660
1661Float_t TIsajet::GetANWWWW(Int_t index1, Int_t index2, Int_t index3) const
1662{
1663 Int_t elem_Size = sizeof HCON.anwwww[0][0][0];
1664 Int_t thd_Dim_Length = (sizeof HCON.anwwww[0][0] / elem_Size);
1665 Int_t sec_Dim_Length = (sizeof HCON.anwwww[0] / (elem_Size * thd_Dim_Length));
1666 Int_t fst_Dim_Length = (sizeof HCON.anwwww / (elem_Size * thd_Dim_Length * sec_Dim_Length));
1667
1668 if ((index1 < 0) || (index1 >= fst_Dim_Length)) {
1669 printf ("Error in TIsajet::GetANWWWW : \n");
1670 printf ("Invalid first index %d; range is 0-%d.\n", index1, fst_Dim_Length-1);
1671 return 0;
1672 }
1673
1674 if ((index2 < 0) || (index2 >= sec_Dim_Length)) {
1675 printf ("Error in TIsajet::GetANWWWW : \n");
1676 printf ("Invalid second index %d; range is 0-%d.\n", index2, sec_Dim_Length-1);
1677 return 0;
1678 }
1679
1680 if ((index3 < 0) || (index3 >= thd_Dim_Length)) {
1681 printf ("Error in TIsajet::GetANWWWW : \n");
1682 printf ("Invalid third index %d; range is 0-%d.\n", index3, thd_Dim_Length-1);
1683 return 0;
1684 }
1685
1686 return HCON.anwwww[index1][index2][index3];
1687}
1688
1689/**************************************************************************/
1690
1691Float_t TIsajet::GetADWWWW(Int_t index1, Int_t index2) const
1692{
1693 Int_t elem_Size = sizeof HCON.adwwww[0][0];
1694 Int_t sec_Dim_Length = (sizeof HCON.adwwww[0] / elem_Size);
1695 Int_t fst_Dim_Length = (sizeof HCON.adwwww / (elem_Size * sec_Dim_Length));
1696
1697 if ((index1 < 0) || (index1 >= fst_Dim_Length)) {
1698 printf ("Error in TIsajet::GetADWWWW : \n");
1699 printf ("Invalid first index %d; range is 0-%d.\n", index1, fst_Dim_Length-1);
1700 return 0;
1701 }
1702
1703 if ((index2 < 0) || (index2 >= sec_Dim_Length)) {
1704 printf ("Error in TIsajet::GetADWWWW : \n");
1705 printf ("Invalid second index %d; range is 0-%d.\n", index2, sec_Dim_Length-1);
1706 return 0;
1707 }
1708
1709 return HCON.adwwww[index1][index2];
1710}
1711
1712/**************************************************************************/
1713
1714Float_t TIsajet::GetAIWWWW(Int_t index) const
1715{
1716 Int_t length = (sizeof HCON.aiwwww / sizeof HCON.aiwwww[0]);
1717 if ((index < 0) || (index >= length)) {
1718 printf ("Error in TIsajet::GetAIWWWW : \n");
1719 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1720 return 0;
1721 }
1722
1723 return HCON.aiwwww[index];
1724}
1725
1726/**************************************************************************/
1727
1728Float_t TIsajet::GetHMASS() const
1729{
1730 return HCON.hmass;
1731}
1732
1733/**************************************************************************/
1734
1735Float_t TIsajet::GetHGAM() const
1736{
1737 return HCON.hgam;
1738}
1739
1740/**************************************************************************/
1741
1742Float_t TIsajet::GetHGAMS(Int_t index) const
1743{
1744 Int_t length = (sizeof HCON.hgams / sizeof HCON.hgams[0]);
1745 if ((index < 0) || (index >= length)) {
1746 printf ("Error in TIsajet::GetHGAMS : \n");
1747 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1748 return 0;
1749 }
1750
1751 return HCON.hgams[index];
1752}
1753
1754/**************************************************************************/
1755
1756Float_t TIsajet::GetETAHGG() const
1757{
1758 return HCON.etahgg;
1759}
1760
1761/**************************************************************************/
1762
1763Int_t TIsajet::GetMATCHH(Int_t index) const
1764{
1765 Int_t length = (sizeof HCON.matchh / sizeof HCON.matchh[0]);
1766 if ((index < 0) || (index >= length)) {
1767 printf ("Error in TIsajet::GetMATCHH : \n");
1768 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1769 return 0;
1770 }
1771
1772 return HCON.matchh[index];
1773}
1774
1775/**************************************************************************/
1776
1777Float_t TIsajet::GetZSTARS(Int_t index1, Int_t index2) const
1778{
1779 Int_t elem_Size = sizeof HCON.zstars[0][0];
1780 Int_t sec_Dim_Length = (sizeof HCON.zstars[0] / elem_Size);
1781 Int_t fst_Dim_Length = (sizeof HCON.zstars / (elem_Size * sec_Dim_Length));
1782
1783 if ((index1 < 0) || (index1 >= fst_Dim_Length)) {
1784 printf ("Error in TIsajet::GetZSTARS : \n");
1785 printf ("Invalid first index %d; range is 0-%d.\n", index1, fst_Dim_Length-1);
1786 return 0;
1787 }
1788
1789 if ((index2 < 0) || (index2 >= sec_Dim_Length)) {
1790 printf ("Error in TIsajet::GetZSTARS : \n");
1791 printf ("Invalid second index %d; range is 0-%d.\n", index2, sec_Dim_Length-1);
1792 return 0;
1793 }
1794
1795 return HCON.zstars[index1][index2];
1796}
1797
1798/**************************************************************************/
1799
1800void TIsajet::SetIHTYPE(Int_t val)
1801{
1802 if ((val < 82) || (val > 84)) {
1803 printf ("Error in TIsajet::SetIHTYPE : \n");
1804 printf ("Invalid input value %d. Possible values are 82, 83, 84.\n", val);
1805 return;
1806 }
1807
1808 HCON.ihtype = val;
1809}
1810
1811/**************************************************************************/
1812
1813void TIsajet::SetIHTYPE(Char_t val[])
1814{
1815 if (!strcmp("HL0", val)) {
1816 HCON.ihtype = 82;
1817 }
1818 else if (!strcmp("HH0", val)) {
1819 HCON.ihtype = 83;
1820 }
1821 else if (!strcmp("HA0", val)){
1822 HCON.ihtype = 84;
1823 }
1824 else {
1825 printf ("Error in TIsajet::SetIHTYPE : \n");
1826 printf ("Invalid input string %s. Possible strings are HL0, HH0, HA0.\n", val);
1827 }
1828}
1829
1830/**************************************************************************/
1831
1832Int_t TIsajet::GetIHTYPE() const
1833{
1834 return HCON.ihtype;
1835}
1836
1837/**************************************************************************/
1838
1839Float_t TIsajet::GetHGAMSS(Int_t index1, Int_t index2) const
1840{
1841 Int_t elem_Size = sizeof HCON.hgamss[0][0];
1842 Int_t sec_Dim_Length = (sizeof HCON.hgamss[0] / elem_Size);
1843 Int_t fst_Dim_Length = (sizeof HCON.hgamss / (elem_Size * sec_Dim_Length));
1844
1845 if ((index1 < 0) || (index1 >= fst_Dim_Length)) {
1846 printf ("Error in TIsajet::GetHGAMSS : \n");
1847 printf ("Invalid first index %d; range is 0-%d.\n", index1, fst_Dim_Length-1);
1848 return 0;
1849 }
1850
1851 if ((index2 < 0) || (index2 >= sec_Dim_Length)) {
1852 printf ("Error in TIsajet::GetHGAMSS : \n");
1853 printf ("Invalid second index %d; range is 0-%d.\n", index2, sec_Dim_Length-1);
1854 return 0;
1855 }
1856
1857 return HCON.hgamss[index1][index2];
1858}
1859
1860/**************************************************************************/
1861
1862// End of HCON access
1863// Begins JETLIM access
1864
1865/**************************************************************************/
1866
1867void TIsajet::SetPMIN(Float_t val, Int_t index)
1868{
1869 Int_t length = (sizeof JETLIM.pmin / sizeof JETLIM.pmin[0]);
1870 if ((index < 0) || (index >= length)) {
1871 printf ("Error in TIsajet::SetPMIN : \n");
1872 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1873 return;
1874 }
1875
1876 if (val > JETLIM.pmax[index]) {
1877 printf("Error in TIsajet::SetPMIN : \n");
1878 printf("You may not set PMIN to a value larger than PMAX = %f.\n", JETLIM.pmax[index]);
1879 return;
1880 }
1881
1882 JETLIM.pmin[index] = val;
1883 setP = true;
1884}
1885
1886/**************************************************************************/
1887
1888void TIsajet::SetAllPMIN(const Float_t val[], Int_t arraySize)
1889{
1890 Int_t length = (sizeof JETLIM.pmin / sizeof JETLIM.pmin[0]);
1891 if (arraySize != length) {
1892 printf ("Error in TIsajet::SetAllPMIN : \n");
1893 printf ("Array must have %d elements.\n", length);
1894 return;
1895 }
1896
1897 for (Int_t i = 0; i < arraySize; i++) {
1898 SetPMIN(val[i], i);
1899 }
1900}
1901
1902/**************************************************************************/
1903
1904Float_t TIsajet::GetPMIN(Int_t index) const
1905{
1906 Int_t length = (sizeof JETLIM.pmin / sizeof JETLIM.pmin[0]);
1907 if ((index < 0) || (index >= length)) {
1908 printf ("Error in TIsajet::GetPMIN : \n");
1909 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1910 return 0;
1911 }
1912
1913 return JETLIM.pmin[index];
1914}
1915
1916/**************************************************************************/
1917
1918void TIsajet::SetPMAX(Float_t val, Int_t index)
1919{
1920 Int_t length = (sizeof JETLIM.pmax / sizeof JETLIM.pmax[0]);
1921 if ((index < 0) || (index >= length)) {
1922 printf ("Error in TIsajet::SetPMAX : \n");
1923 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1924 return;
1925 }
1926
1927 if (val < JETLIM.pmin[index]) {
1928 printf("Error in TIsajet::SetPMAX : \n");
1929 printf("You may not set PMAX to a value larger than PMIN = %f.\n", JETLIM.pmin[index]);
1930 return;
1931 }
1932
1933 JETLIM.pmax[index] = val;
1934 setP = true;
1935}
1936
1937/**************************************************************************/
1938
1939void TIsajet::SetAllPMAX(const Float_t val[], Int_t arraySize)
1940{
1941 Int_t length = (sizeof JETLIM.pmax / sizeof JETLIM.pmax[0]);
1942 if (arraySize != length) {
1943 printf ("Error in TIsajet::SetAllPMAX : \n");
1944 printf ("Array must have %d elements.\n", length);
1945 return;
1946 }
1947
1948 for (Int_t i = 0; i < arraySize; i++) {
1949 SetPMAX(val[i], i);
1950 }
1951}
1952
1953/**************************************************************************/
1954
1955Float_t TIsajet::GetPMAX(Int_t index) const
1956{
1957 Int_t length = (sizeof JETLIM.pmax / sizeof JETLIM.pmax[0]);
1958 if ((index < 0) || (index >= length)) {
1959 printf ("Error in TIsajet::GetPMAX : \n");
1960 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1961 return 0;
1962 }
1963
1964 return JETLIM.pmax[index];
1965}
1966
1967/**************************************************************************/
1968
1969void TIsajet::SetPTMIN(Float_t val, Int_t index)
1970{
1971 Int_t length = (sizeof JETLIM.ptmin / sizeof JETLIM.ptmin[0]);
1972 if ((index < 0) || (index >= length)) {
1973 printf ("Error in TIsajet::SetPTMIN : \n");
1974 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
1975 return;
1976 }
1977/* andreas 7/8/2001
1978 if (val > JETLIM.ptmax[index]) {
1979 printf("Error in TIsajet::SetPTMIN : \n");
1980 printf("You may not set PTMIN to a value larger than PTMAX = %f.\n", JETLIM.ptmax[index]);
1981 return;
1982 }
1983*/
1984 JETLIM.ptmin[index] = val;
1985// if (!setY) SetYJLIMS();
1986// if (!setTheta) SetTHLIMS();
1987 setPt = true;
1988}
1989
1990/**************************************************************************/
1991
1992void TIsajet::SetAllPTMIN(const Float_t val[], Int_t arraySize)
1993{
1994 Int_t length = (sizeof JETLIM.ptmin / sizeof JETLIM.ptmin[0]);
1995 if (arraySize != length) {
1996 printf ("Error in TIsajet::SetAllPTMIN : \n");
1997 printf ("Array must have %d elements.\n", length);
1998 return;
1999 }
2000
2001 for (Int_t i = 0; i < arraySize; i++) {
2002 SetPTMIN(val[i], i);
2003 }
2004}
2005
2006/**************************************************************************/
2007
2008Float_t TIsajet::GetPTMIN(Int_t index) const
2009{
2010 Int_t length = (sizeof JETLIM.ptmin / sizeof JETLIM.ptmin[0]);
2011 if ((index < 0) || (index >= length)) {
2012 printf ("Error in TIsajet::GetPTMIN : \n");
2013 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2014 return 0;
2015 }
2016
2017 return JETLIM.ptmin[index];
2018}
2019
2020/**************************************************************************/
2021
2022void TIsajet::SetPTMAX(Float_t val, Int_t index)
2023{
2024 Int_t length = (sizeof JETLIM.ptmax / sizeof JETLIM.ptmax[0]);
2025 if ((index < 0) || (index >= length)) {
2026 printf ("Error in TIsajet::SetPTMAX : \n");
2027 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2028 return;
2029 }
2030
2031 if (val < JETLIM.ptmin[index]) {
2032 printf("Error in TIsajet::SetPTMAX : \n");
2033 printf("You may not set PTMAX to a value larger than PTMIN = %f.\n", JETLIM.ptmin[index]);
2034 return;
2035 }
2036
2037 JETLIM.ptmax[index] = val;
2038 setPt = true;
2039}
2040
2041/**************************************************************************/
2042
2043void TIsajet::SetAllPTMAX(const Float_t val[], Int_t arraySize)
2044{
2045 Int_t length = (sizeof JETLIM.ptmax / sizeof JETLIM.ptmax[0]);
2046 if (arraySize != length) {
2047 printf ("Error in TIsajet::SetAllPTMAX : \n");
2048 printf ("Array must have %d elements.\n", length);
2049 return;
2050 }
2051
2052 for (Int_t i = 0; i < arraySize; i++) {
2053 SetPTMAX(val[i], i);
2054 }
2055}
2056
2057/**************************************************************************/
2058
2059Float_t TIsajet::GetPTMAX(Int_t index) const
2060{
2061 Int_t length = (sizeof JETLIM.ptmax / sizeof JETLIM.ptmax[0]);
2062 if ((index < 0) || (index >= length)) {
2063 printf ("Error in TIsajet::GetPTMAX : \n");
2064 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2065 return 0;
2066 }
2067
2068 return JETLIM.ptmax[index];
2069}
2070
2071/**************************************************************************/
2072
2073void TIsajet::SetYJMIN(Float_t val, Int_t index)
2074{
2075 Int_t length = (sizeof JETLIM.yjmin / sizeof JETLIM.yjmin[0]);
2076 if ((index < 0) || (index >= length)) {
2077 printf ("Error in TIsajet::SetYJMIN : \n");
2078 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2079 return;
2080 }
2081
2082 if (val > JETLIM.yjmax[index]) {
2083 printf("Error in TIsajet::SetYJMIN : \n");
2084 printf("You may not set YJMIN to a value larger than YJMAX = %f.\n", JETLIM.yjmax[index]);
2085 return;
2086 }
2087
2088 if (setTheta) {
2089 printf("Error in TIsajet::SetYJMIN :\n");
2090 printf("May not set both theta and y limits. Use SetTHLIMS, then set YJMIN.\n");
2091 return;
2092 }
2093
2094 setY = true;
2095 JETLIM.yjmin[index] = val;
2096}
2097
2098/**************************************************************************/
2099
2100void TIsajet::SetAllYJMIN(const Float_t val[], Int_t arraySize)
2101{
2102 Int_t length = (sizeof JETLIM.yjmin / sizeof JETLIM.yjmin[0]);
2103 if (arraySize != length) {
2104 printf ("Error in TIsajet::SetAllYJMIN : \n");
2105 printf ("Array must have %d elements.\n", length);
2106 return;
2107 }
2108
2109 for (Int_t i = 0; i < arraySize; i++) {
2110 SetYJMIN(val[i], i);
2111 }
2112}
2113
2114/**************************************************************************/
2115
2116Float_t TIsajet::GetYJMIN(Int_t index) const
2117{
2118 Int_t length = (sizeof JETLIM.yjmin / sizeof JETLIM.yjmin[0]);
2119 if ((index < 0) || (index >= length)) {
2120 printf ("Error in TIsajet::GetYJMIN : \n");
2121 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2122 return 0;
2123 }
2124
2125 return JETLIM.yjmin[index];
2126}
2127
2128/**************************************************************************/
2129
2130void TIsajet::SetYJMAX(Float_t val, Int_t index)
2131{
2132 Int_t length = (sizeof JETLIM.yjmax / sizeof JETLIM.yjmax[0]);
2133 if ((index < 0) || (index >= length)) {
2134 printf ("Error in TIsajet::SetYJMAX : \n");
2135 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2136 return;
2137 }
2138
2139 if (val < JETLIM.yjmin[index]) {
2140 printf("Error in TIsajet::SetYJMAX : \n");
2141 printf("You may not set YJMAX to a value larger than YJMIN = %f.\n", JETLIM.yjmin[index]);
2142 return;
2143 }
2144
2145 if (setTheta) {
2146 printf("Error in TIsajet::SetYJMAX :\n");
2147 printf("May not set both theta and y limits. Use SetTHLIMS, then set YJMAX.\n");
2148 return;
2149 }
2150
2151 setY = true;
2152 JETLIM.yjmax[index] = val;
2153}
2154
2155/**************************************************************************/
2156
2157void TIsajet::SetAllYJMAX(const Float_t val[], Int_t arraySize)
2158{
2159 Int_t length = (sizeof JETLIM.yjmax / sizeof JETLIM.yjmax[0]);
2160 if (arraySize != length) {
2161 printf ("Error in TIsajet::SetAllYJMAX : \n");
2162 printf ("Array must have %d elements.\n", length);
2163 return;
2164 }
2165
2166 for (Int_t i = 0; i < arraySize; i++) {
2167 SetYJMAX(val[i], i);
2168 }
2169}
2170
2171/**************************************************************************/
2172
2173Float_t TIsajet::GetYJMAX(Int_t index) const
2174{
2175 Int_t length = (sizeof JETLIM.yjmax / sizeof JETLIM.yjmax[0]);
2176 if ((index < 0) || (index >= length)) {
2177 printf ("Error in TIsajet::GetYJMAX : \n");
2178 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2179 return 0;
2180 }
2181
2182 return JETLIM.yjmax[index];
2183}
2184
2185/**************************************************************************/
2186
2187void TIsajet::SetYJLIMS()
2188{
2189 for (Int_t i = 0; i < JETLIM.mxlim; i++) {
2190 JETLIM.yjmax[i] = acosh(PRIMAR.halfe / JETLIM.ptmin[i]);
2191 JETLIM.yjmax[i] = -JETLIM.yjmin[i];
2192 }
2193 setY = false;
2194}
2195
2196/**************************************************************************/
2197
2198void TIsajet::SetPHIMIN(Float_t val, Int_t index)
2199{
2200 Int_t length = (sizeof JETLIM.phimin / sizeof JETLIM.phimin[0]);
2201 if ((index < 0) || (index >= length)) {
2202 printf ("Error in TIsajet::SetPHIMIN : \n");
2203 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2204 return;
2205 }
2206
2207 if (val > JETLIM.phimax[index]) {
2208 printf("Error in TIsajet::SetPHIMIN : \n");
2209 printf("You may not set PHIMIN to a value larger than PHIMAX = %f.\n", JETLIM.phimax[index]);
2210 return;
2211 }
2212
2213 JETLIM.phimin[index] = val;
2214 setPhi = true;
2215}
2216
2217/**************************************************************************/
2218
2219void TIsajet::SetAllPHIMIN(const Float_t val[], Int_t arraySize)
2220{
2221 Int_t length = (sizeof JETLIM.phimin / sizeof JETLIM.phimin[0]);
2222 if (arraySize != length) {
2223 printf ("Error in TIsajet::SetAllPHIMIN : \n");
2224 printf ("Array must have %d elements.\n", length);
2225 return;
2226 }
2227
2228 for (Int_t i = 0; i < arraySize; i++) {
2229 SetPHIMIN(val[i], i);
2230 }
2231}
2232
2233/**************************************************************************/
2234
2235Float_t TIsajet::GetPHIMIN(Int_t index) const
2236{
2237 Int_t length = (sizeof JETLIM.phimin / sizeof JETLIM.phimin[0]);
2238 if ((index < 0) || (index >= length)) {
2239 printf ("Error in TIsajet::GetPHIMIN : \n");
2240 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2241 return 0;
2242 }
2243
2244 return JETLIM.phimin[index];
2245}
2246
2247/**************************************************************************/
2248
2249void TIsajet::SetPHIMAX(Float_t val, Int_t index)
2250{
2251 Int_t length = (sizeof JETLIM.phimax / sizeof JETLIM.phimax[0]);
2252 if ((index < 0) || (index >= length)) {
2253 printf ("Error in TIsajet::SetPHIMAX : \n");
2254 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2255 return;
2256 }
2257
2258 if (val < JETLIM.phimin[index]) {
2259 printf("Error in TIsajet::SetPHIMAX : \n");
2260 printf("You may not set PHIMAX to a value larger than PHIMIN = %f.\n", JETLIM.phimin[index]);
2261 return;
2262 }
2263
2264 JETLIM.phimax[index] = val;
2265 setPhi = true;
2266}
2267
2268/**************************************************************************/
2269
2270void TIsajet::SetAllPHIMAX(const Float_t val[], Int_t arraySize)
2271{
2272 Int_t length = (sizeof JETLIM.phimax / sizeof JETLIM.phimax[0]);
2273 if (arraySize != length) {
2274 printf ("Error in TIsajet::SetAllPHIMAX : \n");
2275 printf ("Array must have %d elements.\n", length);
2276 return;
2277 }
2278
2279 for (Int_t i = 0; i < arraySize; i++) {
2280 SetPHIMAX(val[i], i);
2281 }
2282}
2283
2284/**************************************************************************/
2285
2286Float_t TIsajet::GetPHIMAX(Int_t index) const
2287{
2288 Int_t length = (sizeof JETLIM.phimax / sizeof JETLIM.phimax[0]);
2289 if ((index < 0) || (index >= length)) {
2290 printf ("Error in TIsajet::GetPHIMAX : \n");
2291 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2292 return 0;
2293 }
2294
2295 return JETLIM.phimax[index];
2296}
2297
2298/**************************************************************************/
2299
2300void TIsajet::SetXJMIN(Float_t val, Int_t index)
2301{
2302 Int_t length = (sizeof JETLIM.xjmin / sizeof JETLIM.xjmin[0]);
2303 if ((index < 0) || (index >= length)) {
2304 printf ("Error in TIsajet::SetXJMIN : \n");
2305 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2306 return;
2307 }
2308 if (val > JETLIM.xjmax[index]) {
2309 printf("Error in TIsajet::SetXJMIN : \n");
2310 printf("You may not set XJMIN to a value larger than XJMAX = %f.\n", JETLIM.xjmax[index]);
2311 return;
2312 }
2313
2314 JETLIM.xjmin[index] = val;
2315 setX = true;
2316}
2317
2318/**************************************************************************/
2319
2320void TIsajet::SetAllXJMIN(const Float_t val[], Int_t arraySize)
2321{
2322 Int_t length = (sizeof JETLIM.xjmin / sizeof JETLIM.xjmin[0]);
2323 if (arraySize != length) {
2324 printf ("Error in TIsajet::SetAllXJMIN : \n");
2325 printf ("Array must have %d elements.\n", length);
2326 return;
2327 }
2328
2329 for (Int_t i = 0; i < arraySize; i++) {
2330 SetXJMIN(val[i], i);
2331 }
2332}
2333
2334/**************************************************************************/
2335
2336Float_t TIsajet::GetXJMIN(Int_t index) const
2337{
2338 Int_t length = (sizeof JETLIM.xjmin / sizeof JETLIM.xjmin[0]);
2339 if ((index < 0) || (index >= length)) {
2340 printf ("Error in TIsajet::GetXJMIN : \n");
2341 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2342 return 0;
2343 }
2344
2345 return JETLIM.xjmin[index];
2346}
2347
2348/**************************************************************************/
2349
2350void TIsajet::SetXJMAX(Float_t val, Int_t index)
2351{
2352 Int_t length = (sizeof JETLIM.xjmax / sizeof JETLIM.xjmax[0]);
2353 if ((index < 0) || (index >= length)) {
2354 printf ("Error in TIsajet::SetXJMAX : \n");
2355 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2356 return;
2357 }
2358
2359 if (val < JETLIM.xjmin[index]) {
2360 printf("Error in TIsajet::SetXJMAX : \n");
2361 printf("You may not set XJMAX to a value larger than XJMIN = %f.\n", JETLIM.xjmin[index]);
2362 return;
2363 }
2364
2365 JETLIM.xjmax[index] = val;
2366 setX = true;
2367}
2368
2369/**************************************************************************/
2370
2371void TIsajet::SetAllXJMAX(const Float_t val[], Int_t arraySize)
2372{
2373 Int_t length = (sizeof JETLIM.xjmax / sizeof JETLIM.xjmax[0]);
2374 if (arraySize != length) {
2375 printf ("Error in TIsajet::SetAllXJMAX : \n");
2376 printf ("Array must have %d elements.\n", length);
2377 return;
2378 }
2379
2380 for (Int_t i = 0; i < arraySize; i++) {
2381 SetXJMAX(val[i], i);
2382 }
2383}
2384
2385/**************************************************************************/
2386
2387Float_t TIsajet::GetXJMAX(Int_t index) const
2388{
2389 Int_t length = (sizeof JETLIM.xjmax / sizeof JETLIM.xjmax[0]);
2390 if ((index < 0) || (index >= length)) {
2391 printf ("Error in TIsajet::GetXJMAX : \n");
2392 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2393 return 0;
2394 }
2395
2396 return JETLIM.xjmax[index];
2397}
2398
2399/**************************************************************************/
2400
2401void TIsajet::SetTHMIN(Float_t val, Int_t index)
2402{
2403 Int_t length = (sizeof JETLIM.thmin / sizeof JETLIM.thmin[0]);
2404 if ((index < 0) || (index >= length)) {
2405 printf ("Error in TIsajet::SetTHMIN : \n");
2406 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2407 return;
2408 }
2409
2410 if (val > JETLIM.thmax[index]) {
2411 printf("Error in TIsajet::SetTHMIN : \n");
2412 printf("You may not set THMIN to a value larger than THMAX = %f.\n", JETLIM.thmax[index]);
2413 return;
2414 }
2415
2416 if (setY) {
2417 printf("Error in TIsajet::SetTHMIN :\n");
2418 printf("May not set both theta and y limits. Use SetYJLIMS, then set THMIN.\n");
2419 return;
2420 }
2421
2422 setTheta = true;
2423 JETLIM.thmin[index] = val;
2424
2425}
2426
2427/**************************************************************************/
2428
2429void TIsajet::SetAllTHMIN(const Float_t val[], Int_t arraySize)
2430{
2431 Int_t length = (sizeof JETLIM.thmin / sizeof JETLIM.thmin[0]);
2432 if (arraySize != length) {
2433 printf ("Error in TIsajet::SetAllTHMIN : \n");
2434 printf ("Array must have %d elements.\n", length);
2435 return;
2436 }
2437
2438 for (Int_t i = 0; i < arraySize; i++) {
2439 SetTHMIN(val[i], i);
2440 }
2441}
2442
2443/**************************************************************************/
2444
2445Float_t TIsajet::GetTHMIN(Int_t index) const
2446{
2447 Int_t length = (sizeof JETLIM.thmin / sizeof JETLIM.thmin[0]);
2448 if ((index < 0) || (index >= length)) {
2449 printf ("Error in TIsajet::GetTHMIN : \n");
2450 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2451 return 0;
2452 }
2453
2454 return JETLIM.thmin[index];
2455}
2456
2457/**************************************************************************/
2458
2459void TIsajet::SetTHMAX(Float_t val, Int_t index)
2460{
2461 Int_t length = (sizeof JETLIM.thmax / sizeof JETLIM.thmax[0]);
2462 if ((index < 0) || (index >= length)) {
2463 printf ("Error in TIsajet::SetTHMAX : \n");
2464 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2465 return;
2466 }
2467
2468 if (val < JETLIM.thmin[index]) {
2469 printf("Error in TIsajet::SetTHMAX : \n");
2470 printf("You may not set THMAX to a value larger than THMIN = %f.\n", JETLIM.thmin[index]);
2471 return;
2472 }
2473
2474 if (setY) {
2475 printf("Error in TIsajet::SetTHMAX :\n");
2476 printf("May not set both theta and y limits. Use SetYJLIMS, then set THMAX.\n");
2477 return;
2478 }
2479
2480 setTheta = true;
2481 JETLIM.thmax[index] = val;
2482}
2483
2484/**************************************************************************/
2485
2486void TIsajet::SetAllTHMAX(const Float_t val[], Int_t arraySize)
2487{
2488 Int_t length = (sizeof JETLIM.thmax / sizeof JETLIM.thmax[0]);
2489 if (arraySize != length) {
2490 printf ("Error in TIsajet::SetAllTHMAX : \n");
2491 printf ("Array must have %d elements.\n", length);
2492 return;
2493 }
2494
2495 for (Int_t i = 0; i < arraySize; i++) {
2496 SetTHMAX(val[i], i);
2497 }
2498}
2499
2500/**************************************************************************/
2501
2502Float_t TIsajet::GetTHMAX(Int_t index) const
2503{
2504 Int_t length = (sizeof JETLIM.thmax / sizeof JETLIM.thmax[0]);
2505 if ((index < 0) || (index >= length)) {
2506 printf ("Error in TIsajet::GetTHMAX : \n");
2507 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2508 return 0;
2509 }
2510
2511 return JETLIM.thmax[index];
2512}
2513
2514/**************************************************************************/
2515
2516void TIsajet::SetTHLIMS()
2517{
2518 Float_t tmin;
2519 for (Int_t i = 0; i < JETLIM.mxlim; i++) {
2520 tmin = acosh(PRIMAR.halfe / JETLIM.ptmin[i]);
2521 JETLIM.thmin[i] = 2*atan(exp(tmin));
2522 JETLIM.thmax[i] = 2*atan(exp(-tmin));
2523 }
2524 setTheta = false;
2525}
2526
2527/**************************************************************************/
2528
2529Bool_t TIsajet::GetSETLMJ(Int_t index) const
2530{
2531 Int_t length = (sizeof JETLIM.setlmj / sizeof JETLIM.setlmj[0]);
2532 if ((index < 0) || (index >= length)) {
2533 printf ("Error in TIsajet::GetSETLMJ : \n");
2534 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2535 return 0;
2536 }
2537
2538 return JETLIM.setlmj[index];
2539}
2540
2541/**************************************************************************/
2542
2543// Ends JETLIM access.
2544// Begins JETPAR access.
2545
2546/**************************************************************************/
2547
2548Float_t TIsajet::GetP(Int_t index) const
2549{
2550 Int_t length = (sizeof JETPAR.p / sizeof JETPAR.p[0]);
2551 if ((index < 0) || (index >= length)) {
2552 printf ("Error in TIsajet::GetP : \n");
2553 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2554 return 0;
2555 }
2556
2557 return JETPAR.p[index];
2558}
2559
2560/**************************************************************************/
2561
2562Float_t TIsajet::GetPT(Int_t index) const
2563{
2564 Int_t length = (sizeof JETPAR.pt / sizeof JETPAR.pt[0]);
2565 if ((index < 0) || (index >= length)) {
2566 printf ("Error in TIsajet::GetPT : \n");
2567 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2568 return 0;
2569 }
2570
2571 return JETPAR.pt[index];
2572}
2573
2574/**************************************************************************/
2575
2576Float_t TIsajet::GetYJ(Int_t index) const
2577{
2578 Int_t length = (sizeof JETPAR.yj / sizeof JETPAR.yj[0]);
2579 if ((index < 0) || (index >= length)) {
2580 printf ("Error in TIsajet::GetYJ : \n");
2581 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2582 return 0;
2583 }
2584
2585 return JETPAR.yj[index];
2586}
2587
2588/**************************************************************************/
2589
2590Float_t TIsajet::GetPHI(Int_t index) const
2591{
2592 Int_t length = (sizeof JETPAR.phi / sizeof JETPAR.phi[0]);
2593 if ((index < 0) || (index >= length)) {
2594 printf ("Error in TIsajet::GetPHI : \n");
2595 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2596 return 0;
2597 }
2598
2599 return JETPAR.phi[index];
2600}
2601
2602/**************************************************************************/
2603
2604Float_t TIsajet::GetXJ(Int_t index) const
2605{
2606 Int_t length = (sizeof JETPAR.xj / sizeof JETPAR.xj[0]);
2607 if ((index < 0) || (index >= length)) {
2608 printf ("Error in TIsajet::GetXJ : \n");
2609 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2610 return 0;
2611 }
2612
2613 return JETPAR.xj[index];
2614}
2615
2616/**************************************************************************/
2617
2618Float_t TIsajet::GetTH(Int_t index) const
2619{
2620 Int_t length = (sizeof JETPAR.th / sizeof JETPAR.th[0]);
2621 if ((index < 0) || (index >= length)) {
2622 printf ("Error in TIsajet::GetTH : \n");
2623 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2624 return 0;
2625 }
2626
2627 return JETPAR.th[index];
2628}
2629
2630/**************************************************************************/
2631
2632Float_t TIsajet::GetCTH(Int_t index) const
2633{
2634 Int_t length = (sizeof JETPAR.cth / sizeof JETPAR.cth[0]);
2635 if ((index < 0) || (index >= length)) {
2636 printf ("Error in TIsajet::GetCTH : \n");
2637 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2638 return 0;
2639 }
2640
2641 return JETPAR.cth[index];
2642}
2643
2644/**************************************************************************/
2645
2646Float_t TIsajet::GetSTH(Int_t index) const
2647{
2648 Int_t length = (sizeof JETPAR.sth / sizeof JETPAR.sth[0]);
2649 if ((index < 0) || (index >= length)) {
2650 printf ("Error in TIsajet::GetSTH : \n");
2651 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2652 return 0;
2653 }
2654
2655 return JETPAR.sth[index];
2656}
2657
2658/**************************************************************************/
2659
2660Int_t TIsajet::GetJETTYP(Int_t index) const
2661{
2662 Int_t length = (sizeof JETPAR.jettyp / sizeof JETPAR.jettyp[0]);
2663 if ((index < 0) || (index >= length)) {
2664 printf ("Error in TIsajet::GetJETTYP : \n");
2665 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2666 return 0;
2667 }
2668
2669 return JETPAR.jettyp[index];
2670}
2671
2672/**************************************************************************/
2673
2674Float_t TIsajet::GetSHAT() const
2675{
2676 return JETPAR.shat;
2677}
2678
2679/**************************************************************************/
2680
2681Float_t TIsajet::GetTHAT() const
2682{
2683 return JETPAR.that;
2684}
2685
2686/**************************************************************************/
2687
2688Float_t TIsajet::GetUHAT() const
2689{
2690 return JETPAR.uhat;
2691}
2692
2693/**************************************************************************/
2694
2695Float_t TIsajet::GetQSQ() const
2696{
2697 return JETPAR.qsq;
2698}
2699
2700/**************************************************************************/
2701
2702Float_t TIsajet::GetX1() const
2703{
2704 return JETPAR.x1;
2705}
2706
2707/**************************************************************************/
2708
2709Float_t TIsajet::GetX2() const
2710{
2711 return JETPAR.x2;
2712}
2713
2714/**************************************************************************/
2715
2716Float_t TIsajet::GetPBEAM(Int_t index) const
2717{
2718 Int_t length = (sizeof JETPAR.pbeam / sizeof JETPAR.pbeam[0]);
2719 if ((index < 0) || (index >= length)) {
2720 printf ("Error in TIsajet::GetPBEAM : \n");
2721 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2722 return 0;
2723 }
2724
2725 return JETPAR.pbeam[index];
2726}
2727
2728/**************************************************************************/
2729
2730Float_t TIsajet::GetQMW() const
2731{
2732 return JETPAR.qmw;
2733}
2734
2735/**************************************************************************/
2736
2737Float_t TIsajet::GetQW() const
2738{
2739 return JETPAR.qw;
2740}
2741
2742/**************************************************************************/
2743
2744Float_t TIsajet::GetQTW() const
2745{
2746 return JETPAR.qtw;
2747}
2748
2749/**************************************************************************/
2750
2751Float_t TIsajet::GetYW() const
2752{
2753 return JETPAR.yw;
2754}
2755
2756/**************************************************************************/
2757
2758Float_t TIsajet::GetXW() const
2759{
2760 return JETPAR.xw;
2761}
2762
2763/**************************************************************************/
2764
2765Float_t TIsajet::GetTHW() const
2766{
2767 return JETPAR.thw;
2768}
2769
2770/**************************************************************************/
2771
2772Float_t TIsajet::GetQTMW() const
2773{
2774 return JETPAR.qtmw;
2775}
2776
2777/**************************************************************************/
2778
2779Float_t TIsajet::GetPHIW() const
2780{
2781 return JETPAR.phiw;
2782}
2783
2784/**************************************************************************/
2785
2786Float_t TIsajet::GetSHAT1() const
2787{
2788 return JETPAR.shat1;
2789}
2790
2791/**************************************************************************/
2792
2793Float_t TIsajet::GetTHAT1() const
2794{
2795 return JETPAR.that1;
2796}
2797
2798/**************************************************************************/
2799
2800Float_t TIsajet::GetUHAT1() const
2801{
2802 return JETPAR.uhat1;
2803}
2804
2805/**************************************************************************/
2806
2807void TIsajet::SetJWTYP(Int_t val)
2808{
2809 if ((val < 1) || (val > 4) || (val == 2))
2810 {
2811 printf ("Error in TIsajet::SetJWTYP : \n");
2812 printf ("Invalid value %d; range is 1, 3, and 4.\n", val);
2813 return;
2814 }
2815
2816 JETPAR.jwtyp = val;
2817}
2818
2819/**************************************************************************/
2820
2821void TIsajet::SetJWTYP(Char_t val[])
2822{
2823 Int_t value;
2824
2825 if (!strcmp(val, "GM")) value = 1;
2826 else if (!strcmp(val, "W+")) value = 3;
2827 else if (!strcmp(val, "W-")) value = 3;
2828 else if (!strcmp(val, "Z0")) value = 4;
2829 else
2830 {
2831 printf ("Error in TIsajet::SetJWTYP : \n");
2832 printf ("Invalid value %s; possible are GM, Z0, W+ and W-.\n", val);
2833 return;
2834 }
2835
2836
2837 JETPAR.jwtyp = value;
2838}
2839
2840/**************************************************************************/
2841
2842Int_t TIsajet::GetJWTYP() const
2843{
2844 return JETPAR.jwtyp;
2845}
2846
2847/**************************************************************************/
2848
2849Float_t TIsajet::GetALFQSQ() const
2850{
2851 return JETPAR.alfqsq;
2852}
2853
2854/**************************************************************************/
2855
2856Float_t TIsajet::GetCTHW() const
2857{
2858 return JETPAR.cthw;
2859}
2860
2861/**************************************************************************/
2862
2863Float_t TIsajet::GetSTHW() const
2864{
2865 return JETPAR.sthw;
2866}
2867
2868/**************************************************************************/
2869
2870Float_t TIsajet::GetQ0W() const
2871{
2872 return JETPAR.q0w;
2873}
2874
2875/**************************************************************************/
2876
2877Int_t TIsajet::GetINITYP(Int_t index) const
2878{
2879 Int_t length = (sizeof JETPAR.inityp / sizeof JETPAR.inityp[0]);
2880 if ((index < 0) || (index >= length)) {
2881 printf ("Error in TIsajet::GetINITYP : \n");
2882 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2883 return 0;
2884 }
2885
2886 return JETPAR.inityp[index];
2887}
2888
2889/**************************************************************************/
2890
2891Int_t TIsajet::GetISIGS() const
2892{
2893 return JETPAR.isigs;
2894}
2895
2896/**************************************************************************/
2897
2898Float_t TIsajet::GetPBEAMS(Int_t index) const
2899{
2900 Int_t length = (sizeof JETPAR.pbeams / sizeof JETPAR.pbeams[0]);
2901 if ((index < 0) || (index >= length)) {
2902 printf ("Error in TIsajet::GetPBEAMS : \n");
2903 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2904 return 0;
2905 }
2906
2907 return JETPAR.pbeams[index];
2908}
2909
2910/**************************************************************************/
2911
2912// Ends JETPAR access.
2913// Begins KKGRAV access.
2914
2915/**************************************************************************/
2916
2917void TIsajet::SetNEXTRAD(Int_t val)
2918{
2919 KKGRAV.nextrad = val;
2920}
2921
2922/**************************************************************************/
2923
2924Int_t TIsajet::GetNEXTRAD() const
2925{
2926 return KKGRAV.nextrad;
2927}
2928
2929/**************************************************************************/
2930
2931void TIsajet::SetMASSD(Float_t val)
2932{
2933 KKGRAV.massd = val;
2934}
2935
2936/**************************************************************************/
2937
2938Float_t TIsajet::GetMASSD() const
2939{
2940 return KKGRAV.massd;
2941}
2942
2943/**************************************************************************/
2944
2945Float_t TIsajet::GetKKGSD() const
2946{
2947 return KKGRAV.kkgsd;
2948}
2949
2950/**************************************************************************/
2951
2952Float_t TIsajet::GetSURFD() const
2953{
2954 return KKGRAV.surfd;
2955}
2956
2957/**************************************************************************/
2958
2959void TIsajet::SetUVCUT(Bool_t val)
2960{
2961 KKGRAV.uvcut = val;
2962}
2963
2964/**************************************************************************/
2965
2966Bool_t TIsajet::GetUVCUT() const
2967{
2968 return KKGRAV.uvcut;
2969}
2970
2971/**************************************************************************/
2972
2973// Ends KKGRAV access.
2974// Begins MBGEN access.
2975
2976/**************************************************************************/
2977
2978Float_t TIsajet::GetPOMWT(Int_t index) const
2979{
2980 Int_t length = (sizeof MBGEN.pomwt / sizeof MBGEN.pomwt[0]);
2981 if ((index < 0) || (index >= length)) {
2982 printf ("Error in TIsajet::GetPOMWT : \n");
2983 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2984 return 0;
2985 }
2986
2987 return MBGEN.pomwt[index];
2988}
2989
2990/**************************************************************************/
2991
2992Float_t TIsajet::GetPOMGEN(Int_t index) const
2993{
2994 Int_t length = (sizeof MBGEN.pomgen / sizeof MBGEN.pomgen[0]);
2995 if ((index < 0) || (index >= length)) {
2996 printf ("Error in TIsajet::GetPOMGEN : \n");
2997 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
2998 return 0;
2999 }
3000
3001 return MBGEN.pomgen[index];
3002}
3003
3004/**************************************************************************/
3005
3006void TIsajet::SetMNPOM(Int_t val)
3007{
3008 if (val > MBGEN.mxpom) {
3009 printf("Error in TIsajet::SetMNPOM : \n");
3010 printf("You may not set MNPOM to a value larger than MXPOM = %d.\n", MBGEN.mxpom);
3011 return;
3012 }
3013
3014 MBGEN.mnpom = val;
3015}
3016
3017/**************************************************************************/
3018
3019Int_t TIsajet::GetMNPOM() const
3020{
3021 return MBGEN.mnpom;
3022}
3023
3024/**************************************************************************/
3025
3026void TIsajet::SetMXPOM(Int_t val)
3027{
3028 if (val < MBGEN.mnpom) {
3029 printf("Error in TIsajet::SetMXPOM : \n");
3030 printf("You may not set MXPOM to a value less than MNPOM = %d.\n", MBGEN.mnpom);
3031 return;
3032 }
3033
3034 MBGEN.mxpom = val;
3035}
3036
3037/**************************************************************************/
3038
3039Int_t TIsajet::GetMXPOM() const
3040{
3041 return MBGEN.mxpom;
3042}
3043
3044/**************************************************************************/
3045
3046Float_t TIsajet::GetPDIFFR() const
3047{
3048 return MBGEN.pdiffr;
3049}
3050
3051/**************************************************************************/
3052
3053Int_t TIsajet::GetNPOM() const
3054{
3055 return MBGEN.npom;
3056}
3057
3058/**************************************************************************/
3059
3060Float_t TIsajet::GetXBARY(Int_t index) const
3061{
3062 Int_t length = (sizeof MBGEN.xbary / sizeof MBGEN.xbary[0]);
3063 if ((index < 0) || (index >= length)) {
3064 printf ("Error in TIsajet::GetXBARY : \n");
3065 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
3066 return 0;
3067 }
3068
3069 return MBGEN.xbary[index];
3070}
3071
3072/**************************************************************************/
3073
3074Float_t TIsajet::GetDXBARY(Int_t index) const
3075{
3076 Int_t length = (sizeof MBGEN.dxbary / sizeof MBGEN.dxbary[0]);
3077 if ((index < 0) || (index >= length)) {
3078 printf ("Error in TIsajet::GetDXBARY : \n");
3079 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
3080 return 0;
3081 }
3082
3083 return MBGEN.dxbary[index];
3084}
3085
3086/**************************************************************************/
3087
3088Float_t TIsajet::GetXPOM(Int_t index1, Int_t index2) const
3089{
3090 Int_t elem_Size = sizeof MBGEN.xpom[0][0];
3091 Int_t sec_Dim_Length = (sizeof MBGEN.xpom[0] / elem_Size);
3092 Int_t fst_Dim_Length = (sizeof MBGEN.xpom / (elem_Size * sec_Dim_Length));
3093
3094 if ((index1 < 0) || (index1 >= fst_Dim_Length)) {
3095 printf ("Error in TIsajet::GetXPOM : \n");
3096 printf ("Invalid first index %d; range is 0-%d.\n", index1, fst_Dim_Length-1);
3097 return 0;
3098 }
3099
3100 if ((index2 < 0) || (index2 >= sec_Dim_Length)) {
3101 printf ("Error in TIsajet::GetXPOM : \n");
3102 printf ("Invalid second index %d; range is 0-%d.\n", index2, sec_Dim_Length-1);
3103 return 0;
3104 }
3105
3106 return MBGEN.xpom[index1][index2];
3107}
3108
3109/**************************************************************************/
3110
3111// Ends MBGEN access.
3112// Begins MGLIMS access.
3113
3114/**************************************************************************/
3115
3116void TIsajet::SetEHMGMN(Float_t val)
3117{
3118 if (val > MGLIMS.ehmgmx) {
3119 printf("Error in TIsajet::SetEHMGMN : \n");
3120 printf("You may not set EHMGMN to a value larger than EHMGMX = %f.\n", MGLIMS.ehmgmx);
3121 return;
3122 }
3123
3124 MGLIMS.ehmgmn = val;
3125}
3126
3127/**************************************************************************/
3128
3129Float_t TIsajet::GetEHMGMN() const
3130{
3131 return MGLIMS.ehmgmn;
3132}
3133
3134/**************************************************************************/
3135
3136void TIsajet::SetEHMGMX(Float_t val)
3137{
3138 if (val < MGLIMS.ehmgmn) {
3139 printf("Error in TIsajet::SetEHMGMX : \n");
3140 printf("You may not set EHMGMX to a value less than EHMGMN = %f.\n", MGLIMS.ehmgmn);
3141 return;
3142 }
3143
3144 MGLIMS.ehmgmx = val;
3145}
3146
3147/**************************************************************************/
3148
3149Float_t TIsajet::GetEHMGMX() const
3150{
3151 return MGLIMS.ehmgmx;
3152}
3153
3154/**************************************************************************/
3155
3156Float_t TIsajet::GetYHMGMN() const
3157{
3158 return MGLIMS.yhmgmn;
3159}
3160
3161/**************************************************************************/
3162
3163Float_t TIsajet::GetYHMGMX() const
3164{
3165 return MGLIMS.yhmgmx;
3166}
3167
3168/**************************************************************************/
3169
3170void TIsajet::SetAMIJMN(Float_t val, Int_t index1, Int_t index2)
3171{
3172 Int_t col_num = (sizeof MGLIMS.amijmn[0] / sizeof MGLIMS.amijmn[0][0]);
3173 Int_t row_num = (sizeof MGLIMS.amijmn / (sizeof MGLIMS.amijmn[0][0] * col_num));
3174
3175 if ((index1 < 0) || (index1 >= row_num)) {
3176 printf ("Error in TIsajet::SetAMIJMN : \n");
3177 printf ("Invalid array row index %d; range is 0-%d.\n", index1, row_num-1);
3178 return;
3179 }
3180
3181 if ((index2 < 0) || (index2 >= col_num)) {
3182 printf ("Error in TIsajet::SetAMIJMN : \n");
3183 printf ("Invalid array column index %d; range is 0-%d.\n", index2, col_num-1);
3184 return;
3185 }
3186
3187 if (val > MGLIMS.amijmx[index1][index2]) {
3188 printf("Error in TIsajet::SetAMIJMN : \n");
3189 printf("You may not set AMIJMN to a value larger than AMIJMX = %f.\n", MGLIMS.amijmx[index1][index2]);
3190 return;
3191 }
3192
3193 MGLIMS.amijmn[index1][index2] = val;
3194}
3195
3196/**************************************************************************/
3197
3198void TIsajet::SetAllAMIJMN(const Float_t val[MGLIMS.mxlim][MGLIMS.mxlim])
3199{
3200 for (Int_t i = 0; i < 2; i++) {
3201 for (Int_t j = 0; j < 3; j++) {
3202 SetAMIJMN(val[i][j], i, j);
3203 }
3204 }
3205}
3206
3207/**************************************************************************/
3208
3209void TIsajet::SetColumnAMIJMN(const Float_t val[], Int_t col)
3210{
3211 Int_t col_num = (sizeof MGLIMS.amijmn[0] / sizeof MGLIMS.amijmn[0][0]);
3212 Int_t row_num = (sizeof MGLIMS.amijmn / (sizeof MGLIMS.amijmn[0][0] * col_num));
3213
3214 if ((col < 0) || (col >= col_num)) {
3215 printf ("Error in TIsajet::SetColumnAMIJMN : \n");
3216 printf ("Invalid column index %d, range is 0-%d.\n", col, col_num-1);
3217 return;
3218 }
3219
3220 for (Int_t i = 0; i < row_num; i++) {
3221 SetAMIJMN(val[i], i, col);
3222 }
3223}
3224
3225/**************************************************************************/
3226
3227Float_t TIsajet::GetAMIJMN(Int_t index1, Int_t index2) const
3228{
3229 Int_t col_num = (sizeof MGLIMS.amijmn[0] / sizeof MGLIMS.amijmn[0][0]);
3230 Int_t row_num = (sizeof MGLIMS.amijmn / (sizeof MGLIMS.amijmn[0][0] * col_num));
3231
3232 if ((index1 < 0) || (index1 >= row_num)) {
3233 printf ("Error in TIsajet::GetAMIJMN : \n");
3234 printf ("Invalid array row index %d; range is 0-%d.\n", index1, row_num-1);
3235 return 0;
3236 }
3237
3238 if ((index2 < 0) || (index2 >= col_num)) {
3239 printf ("Error in TIsajet::GetAMIJMN : \n");
3240 printf ("Invalid array column index %d; range is 0-%d.\n", index2, col_num-1);
3241 return 0;
3242 }
3243
3244 return MGLIMS.amijmn[index1][index2];
3245}
3246
3247/**************************************************************************/
3248
3249void TIsajet::SetAMIJMX(Float_t val, Int_t index1, Int_t index2)
3250{
3251 Int_t col_num = (sizeof MGLIMS.amijmx[0] / sizeof MGLIMS.amijmx[0][0]);
3252 Int_t row_num = (sizeof MGLIMS.amijmx / (sizeof MGLIMS.amijmx[0][0] * col_num));
3253
3254 if ((index1 < 0) || (index1 >= row_num)) {
3255 printf ("Error in TIsajet::SetAMIJMX : \n");
3256 printf ("Invalid array row index %d; range is 0-%d.\n", index1, row_num-1);
3257 return;
3258 }
3259
3260 if ((index2 < 0) || (index2 >= col_num)) {
3261 printf ("Error in TIsajet::SetAMIJMX : \n");
3262 printf ("Invalid array column index %d; range is 0-%d.\n", index2, col_num-1);
3263 return;
3264 }
3265
3266 if (val < MGLIMS.amijmn[index1][index2]) {
3267 printf("Error in TIsajet::SetAMIJMX : \n");
3268 printf("You may not set AMIJMX to a value less than AMIJMN = %f.\n", MGLIMS.amijmn[index1][index2]);
3269 return;
3270 }
3271
3272 MGLIMS.amijmx[index1][index2] = val;
3273}
3274
3275/**************************************************************************/
3276
3277void TIsajet::SetAllAMIJMX(const Float_t val[MGLIMS.mxlim][MGLIMS.mxlim])
3278{
3279 for (Int_t i = 0; i < 2; i++) {
3280 for (Int_t j = 0; j < 3; j++) {
3281 SetAMIJMX(val[i][j], i, j);
3282 }
3283 }
3284}
3285
3286/**************************************************************************/
3287
3288void TIsajet::SetColumnAMIJMX(const Float_t val[], Int_t col)
3289{
3290 Int_t col_num = (sizeof MGLIMS.amijmx[0] / sizeof MGLIMS.amijmx[0][0]);
3291 Int_t row_num = (sizeof MGLIMS.amijmx / (sizeof MGLIMS.amijmx[0][0] * col_num));
3292
3293 if ((col < 0) || (col >= col_num)) {
3294 printf ("Error in TIsajet::SetColumnAMIJMX : \n");
3295 printf ("Invalid column index %d, range is 0-%d.\n", col, col_num-1);
3296 return;
3297 }
3298
3299 for (Int_t i = 0; i < row_num; i++) {
3300 SetAMIJMX(val[i], i, col);
3301 }
3302}
3303
3304/**************************************************************************/
3305
3306Float_t TIsajet::GetAMIJMX(Int_t index1, Int_t index2) const
3307{
3308 Int_t col_num = (sizeof MGLIMS.amijmx[0] / sizeof MGLIMS.amijmx[0][0]);
3309 Int_t row_num = (sizeof MGLIMS.amijmx / (sizeof MGLIMS.amijmx[0][0] * col_num));
3310
3311 if ((index1 < 0) || (index1 >= row_num)) {
3312 printf ("Error in TIsajet::GetAMIJMX : \n");
3313 printf ("Invalid array row index %d; range is 0-%d.\n", index1, row_num-1);
3314 return 0;
3315 }
3316
3317 if ((index2 < 0) || (index2 >= col_num)) {
3318 printf ("Error in TIsajet::GetAMIJMX : \n");
3319 printf ("Invalid array column index %d; range is 0-%d.\n", index2, col_num-1);
3320 return 0;
3321 }
3322
3323 return MGLIMS.amijmx[index1][index2];
3324}
3325
3326/**************************************************************************/
3327
3328Bool_t TIsajet::GetFIXMIJ(Int_t index1, Int_t index2) const
3329{
3330 Int_t elem_Size = sizeof MGLIMS.fixmij[0][0];
3331 Int_t sec_Dim_Length = (sizeof MGLIMS.fixmij[0] / elem_Size);
3332 Int_t fst_Dim_Length = (sizeof MGLIMS.fixmij / (elem_Size * sec_Dim_Length));
3333
3334 if ((index1 < 0) || (index1 >= fst_Dim_Length)) {
3335 printf ("Error in TIsajet::GetFIXMIJ : \n");
3336 printf ("Invalid first index %d; range is 0-%d.\n", index1, fst_Dim_Length-1);
3337 return 0;
3338 }
3339
3340 if ((index2 < 0) || (index2 >= sec_Dim_Length)) {
3341 printf ("Error in TIsajet::GetFIXMIJ : \n");
3342 printf ("Invalid second index %d; range is 0-%d.\n", index2, sec_Dim_Length-1);
3343 return 0;
3344 }
3345
3346 return MGLIMS.fixmij[index1][index2];
3347}
3348
3349/**************************************************************************/
3350
3351// Ends MGLIMS access.
3352// Begins NODCAY access.
3353
3354/**************************************************************************/
3355
3356void TIsajet::SetNODCAY(Bool_t val)
3357{
3358 NODCAY.nodcay = val;
3359 setNodcay = true;
3360}
3361
3362/**************************************************************************/
3363
3364Bool_t TIsajet::GetNODCAY() const
3365{
3366 return NODCAY.nodcay;
3367}
3368
3369/**************************************************************************/
3370
3371void TIsajet::SetNOETA(Bool_t val)
3372{
3373 NODCAY.noeta = val;
3374 setNoeta = true;
3375}
3376
3377/**************************************************************************/
3378
3379Bool_t TIsajet::GetNOETA() const
3380{
3381 return NODCAY.noeta;
3382}
3383
3384/**************************************************************************/
3385
3386void TIsajet::SetNOPI0(Bool_t val)
3387{
3388 NODCAY.nopi0 = val;
3389 setNopi0 = true;
3390}
3391
3392/**************************************************************************/
3393
3394Bool_t TIsajet::GetNOPI0() const
3395{
3396 return NODCAY.nopi0;
3397}
3398
3399/**************************************************************************/
3400
3401void TIsajet::SetNONUNU(Bool_t val)
3402{
3403 NODCAY.nonunu = val;
3404}
3405
3406/**************************************************************************/
3407
3408Bool_t TIsajet::GetNONUNU() const
3409{
3410 return NODCAY.nonunu;
3411}
3412
3413/**************************************************************************/
3414
3415void TIsajet::SetNOEVOL(Bool_t val)
3416{
3417 NODCAY.noevol = val;
3418 setNoevolve = true;
3419}
3420
3421/**************************************************************************/
3422
3423Bool_t TIsajet::GetNOEVOL() const
3424{
3425 return NODCAY.noevol;
3426}
3427
3428/**************************************************************************/
3429
3430void TIsajet::SetNOHADR(Bool_t val)
3431{
3432 NODCAY.nohadr = val;
3433 setNohadron = true;
3434}
3435
3436/**************************************************************************/
3437
3438Bool_t TIsajet::GetNOHADR() const
3439{
3440 return NODCAY.nohadr;
3441}
3442
3443/**************************************************************************/
3444
3445void TIsajet::SetNOGRAV(Bool_t val)
3446{
3447 NODCAY.nograv = val;
3448}
3449
3450/**************************************************************************/
3451
3452Bool_t TIsajet::GetNOGRAV() const
3453{
3454 return NODCAY.nograv;
3455}
3456
3457/**************************************************************************/
3458
3459// Ends NODCAY access.
3460// Begins PARTCL access.
3461
3462/**************************************************************************/
3463
3464Int_t TIsajet::GetNPTCL() const
3465{
3466 return PARTCL.nptcl;
3467}
3468
3469/**************************************************************************/
3470
3471Float_t TIsajet::GetPX(Int_t index) const
3472{
3473 if ((index < 0) || (index >= PARTCL.nptcl)) {
3474 printf ("Error in TIsajet::GetPX : \n");
3475 printf ("Invalid array index %d; range is 0-%d.\n", index, PARTCL.nptcl-1);
3476 return 0;
3477 }
3478
3479 return PARTCL.pptcl[index][0];
3480}
3481
3482/**************************************************************************/
3483
3484Float_t TIsajet::GetPY(Int_t index) const
3485{
3486 if ((index < 0) || (index >= PARTCL.nptcl)) {
3487 printf ("Error in TIsajet::GetPY : \n");
3488 printf ("Invalid array index %d; range is 0-%d.\n", index, PARTCL.nptcl-1);
3489 return 0;
3490 }
3491
3492 return PARTCL.pptcl[index][1];
3493}
3494
3495/**************************************************************************/
3496
3497Float_t TIsajet::GetPZ(Int_t index) const
3498{
3499 if ((index < 0) || (index >= PARTCL.nptcl)) {
3500 printf ("Error in TIsajet::GetPZ : \n");
3501 printf ("Invalid array index %d; range is 0-%d.\n", index, PARTCL.nptcl-1);
3502 return 0;
3503 }
3504
3505 return PARTCL.pptcl[index][2];
3506}
3507
3508/**************************************************************************/
3509
3510Float_t TIsajet::GetP0(Int_t index) const
3511{
3512 if ((index < 0) || (index >= PARTCL.nptcl)) {
3513 printf ("Error in TIsajet::GetP0 : \n");
3514 printf ("Invalid array index %d; range is 0-%d.\n", index, PARTCL.nptcl-1);
3515 return 0;
3516 }
3517
3518 return PARTCL.pptcl[index][3];
3519}
3520
3521/**************************************************************************/
3522
3523Float_t TIsajet::GetMASS(Int_t index) const
3524{
3525 if ((index < 0) || (index >= PARTCL.nptcl)) {
3526 printf ("Error in TIsajet::GetMASS : \n");
3527 printf ("Invalid array index %d; range is 0-%d.\n", index, PARTCL.nptcl-1);
3528 return 0;
3529 }
3530
3531 return PARTCL.pptcl[index][4];
3532}
3533
3534/**************************************************************************/
3535
3536Float_t TIsajet::GetORIG(Int_t index) const
3537{
3538 if ((index < 0) || (index >= PARTCL.nptcl)) {
3539 printf ("Error in TIsajet::GetORIG : \n");
3540 printf ("Invalid array index %d; range is 0-%d.\n", index, PARTCL.nptcl-1);
3541 return 0;
3542 }
3543
3544 return PARTCL.iorig[index];
3545}
3546
3547/**************************************************************************/
3548
3549Float_t TIsajet::GetIDENT(Int_t index) const
3550{
3551 if ((index < 0) || (index >= PARTCL.nptcl)) {
3552 printf ("Error in TIsajet::GetIDENT : \n");
3553 printf ("Invalid array index %d; range is 0-%d.\n", index, PARTCL.nptcl-1);
3554 return 0;
3555 }
3556
3557 return PARTCL.ident[index];
3558}
3559
3560/**************************************************************************/
3561
3562Float_t TIsajet::GetIDCAY(Int_t index) const
3563{
3564 if ((index < 0) || (index >= PARTCL.nptcl)) {
3565 printf ("Error in TIsajet::GetIDCAY : \n");
3566 printf ("Invalid array index %d; range is 0-%d.\n", index, PARTCL.nptcl-1);
3567 return 0;
3568 }
3569
3570 return PARTCL.idcay[index];
3571}
3572
3573/**************************************************************************/
3574
3575// Ends PARTCL access.
3576// Begins PRIMAR access.
3577
3578/**************************************************************************/
3579
3580Int_t TIsajet::GetNJET() const
3581{
3582 return PRIMAR.njet;
3583}
3584
3585/**************************************************************************/
3586
3587Float_t TIsajet::GetSCM() const
3588{
3589 return PRIMAR.scm;
3590}
3591
3592/**************************************************************************/
3593
3594Float_t TIsajet::GetHALFE() const
3595{
3596 return PRIMAR.halfe;
3597}
3598
3599/**************************************************************************/
3600
3601void TIsajet::SetECM(Float_t val)
3602{
3603 if (val < 0) {
3604 printf ("Error in TIsajet::SetECM :\n");
3605 printf ("Cannot set energy to a negative value.\n");
3606 return;
3607 }
3608
3609 PRIMAR.ecm = val;
3610 PRIMAR.scm = val*val;
3611 PRIMAR.halfe = val / 2;
3612}
3613
3614/**************************************************************************/
3615
3616Float_t TIsajet::GetECM() const
3617{
3618 return PRIMAR.ecm;
3619}
3620
3621/**************************************************************************/
3622
3623void TIsajet::SetIDIN(Int_t val, Int_t index)
3624{
3625 Int_t length = (sizeof PRIMAR.idin / sizeof PRIMAR.idin[0]);
3626 if ((index < 0) || (index >= length)) {
3627 printf ("Error in TIsajet::SetIDIN : \n");
3628 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
3629 return;
3630 }
3631
3632 if ((val = 1120) || (val = 1220) || (val = -1120) || (val = -1220)) {
3633 PRIMAR.idin[index] = val;
3634 }
3635 else {
3636 printf ("Error in TIsajet::SetIDIN : \n");
3637 printf ("Invalid input value %d. Possible values are 1120, 1220, -1120, -1220.\n", val);
3638 return;
3639 }
3640
3641 setBeams = true;
3642}
3643
3644/**************************************************************************/
3645
3646void TIsajet::SetIDIN(const Char_t val[], Int_t index)
3647{
3648 Int_t length = (sizeof PRIMAR.idin / sizeof PRIMAR.idin[0]);
3649 if ((index < 0) || (index >= length)) {
3650 printf ("Error in TIsajet::SetIDIN : \n");
3651 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
3652 return;
3653 }
3654
3655 if (!strcmp("P", val)) {
3656 PRIMAR.idin[index] = 1120;
3657 }
3658 else if (!strcmp("AP", val)) {
3659 PRIMAR.idin[index] = -1120;
3660 }
3661 else if (!strcmp("N", val)) {
3662 PRIMAR.idin[index] = 1220;
3663 }
3664 else if (!strcmp("AN", val)) {
3665 PRIMAR.idin[index] = -1220;
3666 }
3667 else {
3668 printf ("Error in TIsajet::SetIDIN : \n");
3669 printf ("Invalid input string %s. Possible strings are P, AP, N, and AN.\n", val);
3670 return;
3671 }
3672}
3673
3674/**************************************************************************/
3675
3676Int_t TIsajet::GetIDIN(Int_t index) const
3677{
3678 Int_t length = (sizeof PRIMAR.idin / sizeof PRIMAR.idin[0]);
3679 if ((index < 0) || (index >= length)) {
3680 printf ("Error in TIsajet::GetIDIN : \n");
3681 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
3682 return 0;
3683 }
3684
3685 return PRIMAR.idin[index];
3686}
3687
3688/**************************************************************************/
3689
3690Int_t TIsajet::GetNEVENT() const
3691{
3692 return PRIMAR.nevent;
3693}
3694
3695/**************************************************************************/
3696
3697void TIsajet::SetNTRIES(Int_t val)
3698{
3699 PRIMAR.ntries = val;
3700}
3701
3702/**************************************************************************/
3703
3704Int_t TIsajet::GetNTRIES() const
3705{
3706 return PRIMAR.ntries;
3707}
3708
3709/**************************************************************************/
3710
3711void TIsajet::SetNSIGMA(Int_t val)
3712{
3713 PRIMAR.nsigma = val;
3714 setNsigma = true;
3715}
3716
3717/**************************************************************************/
3718
3719Int_t TIsajet::GetNSIGMA() const
3720{
3721 return PRIMAR.nsigma;
3722}
3723
3724/**************************************************************************/
3725
3726// Ends PRIMAR access.
3727// Begins QCDPAR access.
3728
3729/**************************************************************************/
3730
3731void TIsajet::SetALAM(Float_t val)
3732{
3733 QCDPAR.alam = val;
3734 QCDPAR.alam2 = val*val;
3735 setLambda = true;
3736}
3737
3738/**************************************************************************/
3739
3740Float_t TIsajet::GetALAM() const
3741{
3742 return QCDPAR.alam;
3743}
3744
3745/**************************************************************************/
3746
3747Float_t TIsajet::GetALAM2() const
3748{
3749 return QCDPAR.alam2;
3750}
3751
3752/**************************************************************************/
3753
3754void TIsajet::SetCUTJET(Float_t val)
3755{
3756 QCDPAR.cutjet = val;
3757 setCutjet = true;
3758}
3759
3760/**************************************************************************/
3761
3762Float_t TIsajet::GetCUTJET() const
3763{
3764 return QCDPAR.cutjet;
3765}
3766
3767/**************************************************************************/
3768
3769void TIsajet::SetISTRUC(Int_t val)
3770{
3771 if ((val < 1) || (val > 6)) {
3772 printf ("Error in TIsajet::SetISTRUC : \n");
3773 printf ("Invalid input value %d. Possible values are 1 through 6.\n", val);
3774 return;
3775 }
3776 QCDPAR.istruc = val;
3777}
3778
3779/**************************************************************************/
3780
3781void TIsajet::SetISTRUC(const Char_t val[])
3782{
3783 if (!strcmp("OWENS", val)) {
3784 QCDPAR.istruc = 1;
3785 }
3786 else if (!strcmp("BAIER", val)) {
3787 QCDPAR.istruc = 2;
3788 }
3789 else if ((!strcmp("EICHTEN", val)) || (!strcmp("EHLQ", val))) {
3790 QCDPAR.istruc = 3;
3791 }
3792 else if ((!strcmp("DUKE", val)) || (!strcmp("DO", val))) {
3793 QCDPAR.istruc = 4;
3794 }
3795 else if (!strcmp("CTEQ2L", val)) {
3796 QCDPAR.istruc = 5;
3797 }
3798 else if ((!strcmp("CTEQ", val)) || (!strcmp("CTEQ3L", val))) {
3799 QCDPAR.istruc = 6;
3800 }
3801 else {
3802 printf ("Error in TIsajet::SetISTRUC : \n");
3803 printf ("Invalid input string %s. Possible strings are OWENS, BAIER, EICHTEN, \n", val);
3804 printf ("EHLQ, DUKE, DO, CTEQ2L, CTEQ, and CTEQ3L.\n");
3805 return;
3806 }
3807}
3808
3809/**************************************************************************/
3810
3811Int_t TIsajet::GetISTRUC() const
3812{
3813 return QCDPAR.istruc;
3814}
3815
3816/**************************************************************************/
3817
3818// Ends QCDPAR access.
3819// Begins QLMASS access.
3820
3821/**************************************************************************/
3822
3823void TIsajet::SetAMLEP(Float_t val, Int_t index)
3824{
3825 Int_t length = (sizeof QLMASS.amlep / sizeof QLMASS.amlep[0]);
3826 if ((index < 0) || (index >= length)) {
3827 printf ("Error in TIsajet::SetAMLEP : \n");
3828 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
3829 return;
3830 }
3831
3832 if (((index < 5) && (index > 7)) &&
3833 ((index < 21) && (index > 26)) &&
3834 ((index < 29) && (index > 36)) &&
3835 ((index < 39) && (index > 40)) &&
3836 ((index < 63) && (index > 71)))
3837 {
3838 printf ("Error in TIsajet::SetAMLEP : \n");
3839 printf ("Index %d may not be set by the user. Valid indices are : \n", index);
3840 printf ("5-7, 21-26, 29-36, 39-40 and 63-71.\n");
3841 return;
3842 }
3843
3844 QLMASS.amlep[index] = val;
3845}
3846
3847/**************************************************************************/
3848
3849Float_t TIsajet::GetAMLEP(Int_t index) const
3850{
3851 Int_t length = (sizeof QLMASS.amlep / sizeof QLMASS.amlep[0]);
3852 if ((index < 0) || (index >= length)) {
3853 printf ("Error in TIsajet::GetAMLEP : \n");
3854 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
3855 return 0;
3856 }
3857 if ((index < 5) || (index > 71) ||
3858 ((index > 7) && (index < 21)) ||
3859 ((index > 26) && (index < 29)) ||
3860 ((index > 36) && (index < 39)) ||
3861 ((index > 40) && (index < 63)))
3862 {
3863 printf ("Possible error in TIsajet::GetAMLEP : \n");
3864 printf ("Index %d may not be set by the user. Valid indices are : \n", index);
3865 printf ("5-7, 21-26, 29-36, 39-40 and 63-71. \n");
3866 printf ("To return the value of this index, use GetAnyAMLEP(Int_t index).\n");
3867 return 0;
3868 }
3869
3870
3871 return QLMASS.amlep[index];
3872}
3873
3874/**************************************************************************/
3875
3876Float_t TIsajet::GetAnyAMLEP(Int_t index) const
3877{
3878 Int_t length = (sizeof QLMASS.amlep / sizeof QLMASS.amlep[0]);
3879 if ((index < 0) || (index >= length)) {
3880 printf ("Error in TIsajet::GetAnyAMLEP : \n");
3881 printf ("Invalid array index %d; range is 0-%d.\n", index, length-1);
3882 return 0;
3883 }
3884
3885 return QLMASS.amlep[index];
3886}
3887
3888/**************************************************************************/
3889
3890void TIsajet::SetTquarkMass(Float_t val)
3891{
3892 QLMASS.amlep[5] = val;
3893}
3894
3895/**************************************************************************/
3896
3897Float_t TIsajet::GetTquarkMass() const
3898{
3899 return QLMASS.amlep[5];
3900}
3901
3902/**************************************************************************/
3903
3904void TIsajet::SetXquarkMass(Float_t val)
3905{
3906 QLMASS.amlep[6] = val;
3907}
3908
3909/**************************************************************************/
3910
3911Float_t TIsajet::GetXquarkMass() const
3912{
3913 return QLMASS.amlep[6];
3914}
3915
3916/**************************************************************************/
3917
3918void TIsajet::SetYquarkMass(Float_t val)
3919{
3920 QLMASS.amlep[7] = val;
3921}
3922
3923/**************************************************************************/
3924
3925Float_t TIsajet::GetYquarkMass() const
3926{
3927 return QLMASS.amlep[7];
3928}
3929
3930/**************************************************************************/
3931
3932void TIsajet::SetUtildeMass(Float_t val)
3933{
3934 QLMASS.amlep[21] = val;
3935}
3936
3937/**************************************************************************/
3938
3939Float_t TIsajet::GetUtildeMass() const
3940{
3941 return QLMASS.amlep[21];
3942}
3943
3944/**************************************************************************/
3945
3946void TIsajet::SetDtildeMass(Float_t val)
3947{
3948 QLMASS.amlep[22] = val;
3949}
3950
3951/**************************************************************************/
3952
3953Float_t TIsajet::GetDtildeMass() const
3954{
3955 return QLMASS.amlep[22];
3956}
3957
3958/**************************************************************************/
3959
3960void TIsajet::SetStildeMass(Float_t val)