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