StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
SigmaProcess.h
1 // SigmaProcess.h is a part of the PYTHIA event generator.
2 // Copyright (C) 2014 Torbjorn Sjostrand.
3 // PYTHIA is licenced under the GNU GPL version 2, see COPYING for details.
4 // Please respect the MCnet Guidelines, see GUIDELINES for details.
5 
6 // Header file for hard-process differential cross sections.
7 // SigmaProcess: base class for cross sections.
8 // Sigma0Process: base class for unresolved processes, derived from above.
9 // Sigma1Process: base class for 2 -> 1 processes, derived from above.
10 // Sigma2Process: base class for 2 -> 2 processes, derived from above.
11 // Sigma3Process: base class for 2 -> 3 processes, derived from above.
12 // SigmaLHAProcess: wrapper class for Les Houches Accord external input.
13 // Actual physics processes are found in separate files:
14 // SigmaQCD for QCD processes;
15 // SigmaEW for electroweak processes (including photon production);
16 // SigmaOnia for charmonium and bottomonium processes;
17 // SigmaHiggs for Higgs processes;
18 // SigmaSUSY for supersymmetric production;
19 // SigmaLeftRightSym for processes in left-right-symmetric scenarios;
20 // SigmaLeptoquark for leptoquark production.
21 // SigmaExtraDim for processes in scenarios for extra dimensions;
22 // SigmaGeneric for generic scalar/fermion/vector pair production.
23 
24 #ifndef Pythia8_SigmaProcess_H
25 #define Pythia8_SigmaProcess_H
26 
27 #include "Pythia8/Basics.h"
28 #include "Pythia8/BeamParticle.h"
29 #include "Pythia8/Event.h"
30 #include "Pythia8/Info.h"
31 #include "Pythia8/LesHouches.h"
32 #include "Pythia8/ParticleData.h"
33 #include "Pythia8/PartonDistributions.h"
34 #include "Pythia8/PythiaComplex.h"
35 #include "Pythia8/PythiaStdlib.h"
36 #include "Pythia8/ResonanceWidths.h"
37 #include "Pythia8/Settings.h"
38 #include "Pythia8/SigmaTotal.h"
39 #include "Pythia8/StandardModel.h"
40 #include "Pythia8/SLHAinterface.h"
41 #include "Pythia8/SusyLesHouches.h"
42 
43 namespace Pythia8 {
44 
45 //==========================================================================
46 
47 // InBeam is a simple helper class for partons and their flux in a beam.
48 
49 class InBeam {
50 
51 public:
52 
53  // Constructor.
54  InBeam( int idIn = 0) : id(idIn), pdf(0.) {}
55 
56  // Values.
57  int id;
58  double pdf;
59 
60 };
61 
62 //==========================================================================
63 
64 // InPair is a simple helper class for colliding parton pairs and their flux.
65 
66 class InPair {
67 
68 public:
69 
70  // Constructor.
71  InPair( int idAIn = 0, int idBIn = 0) : idA(idAIn), idB(idBIn),
72  pdfA(0.), pdfB(0.), pdfSigma(0.) {}
73 
74  // Values.
75  int idA, idB;
76  double pdfA, pdfB, pdfSigma;
77 
78 };
79 
80 //==========================================================================
81 
82 // SigmaProcess is the base class for cross section calculations.
83 
84 class SigmaProcess {
85 
86 public:
87 
88  // Destructor.
89  virtual ~SigmaProcess() {}
90 
91  // Perform simple initialization and store pointers.
92  void init(Info* infoPtrIn, Settings* settingsPtrIn,
93  ParticleData* particleDataPtrIn, Rndm* rndmPtrIn,
94  BeamParticle* beamAPtrIn, BeamParticle* beamBPtrIn, Couplings* couplings,
95  SigmaTotal* sigmaTotPtrIn = 0, SLHAinterface* slhaInterfacePtrIn = 0);
96 
97  // Store or replace Les Houches pointer.
98  void setLHAPtr( LHAup* lhaUpPtrIn) {lhaUpPtr = lhaUpPtrIn;}
99 
100  // Initialize process. Only used for some processes.
101  virtual void initProc() {}
102 
103  // Set up allowed flux of incoming partons. Default is no flux.
104  virtual bool initFlux();
105 
106  // Input and complement kinematics for resolved 2 -> 1 process.
107  // Usage: set1Kin( x1in, x2in, sHin).
108  virtual void set1Kin( double , double , double ) {}
109 
110  // Input and complement kinematics for resolved 2 -> 2 process.
111  // Usage: set2Kin( x1in, x2in, sHin, tHin, m3in, m4in, runBW3in, runBW4in).
112  virtual void set2Kin( double , double , double , double , double ,
113  double, double, double ) {}
114 
115  // Ditto, but for Multiparton Interactions applications, so different input.
116  // Usage: set2KinMPI( x1in, x2in, sHin, tHin, uHin,
117  // alpSin, alpEMin, needMasses, m3in, m4in)
118  virtual void set2KinMPI( double , double , double , double ,
119  double , double , double , bool , double , double ) {}
120 
121  // Input and complement kinematics for resolved 2 -> 3 process.
122  // Usage: set3Kin( x1in, x2in, sHin, p3prel, p4prel, p5prel,
123  // m3in, m4in, m5in, runBW3in, runBW4in, runBW5in);
124  virtual void set3Kin( double , double , double , Vec4 , Vec4 , Vec4 ,
125  double , double , double , double , double , double ) {}
126 
127  // Calculate flavour-independent parts of cross section.
128  virtual void sigmaKin() {}
129 
130  // Evaluate sigma for unresolved, sigmaHat(sHat) for 2 -> 1 processes,
131  // d(sigmaHat)/d(tHat) for (resolved) 2 -> 2 processes, and |M|^2 for
132  // 2 -> 3 processes. Answer in "native" units, either mb or GeV^-2.
133  virtual double sigmaHat() {return 0.;}
134 
135  // Wrapper to sigmaHat, to (a) store current incoming flavours and
136  // (b) convert from GeV^-2 to mb where required.
137  // For 2 -> 1/2 also (c) convert from from |M|^2 to d(sigmaHat)/d(tHat).
138  virtual double sigmaHatWrap(int id1in = 0, int id2in = 0) {
139  id1 = id1in; id2 = id2in;
140  return ( convert2mb() ? CONVERT2MB * sigmaHat() : sigmaHat() ); }
141 
142  // Convolute above with parton flux and K factor. Sum over open channels.
143  virtual double sigmaPDF();
144 
145  // Select incoming parton channel and extract parton densities (resolved).
146  void pickInState(int id1in = 0, int id2in = 0);
147 
148  // Select flavour, colour and anticolour.
149  virtual void setIdColAcol() {}
150 
151  // Perform kinematics for a Multiparton Interaction, in its rest frame.
152  virtual bool final2KinMPI( int = 0, int = 0, Vec4 = 0., Vec4 = 0.,
153  double = 0., double = 0.) {return true;}
154 
155  // Evaluate weight for simultaneous flavours (only gamma*/Z0 gamma*/Z0).
156  // Usage: weightDecayFlav( process).
157  virtual double weightDecayFlav( Event&) {return 1.;}
158 
159  // Evaluate weight for decay angular configuration.
160  // Usage: weightDecay( process, iResBeg, iResEnd), where
161  // iResBeg <= i < iResEnd is range of sister partons to test decays of.
162  virtual double weightDecay( Event&, int, int) {return 1.;}
163 
164  // Set scale, when that is missing for an external LHA process.
165  virtual void setScale() {}
166 
167  // Process name and code, and the number of final-state particles.
168  virtual string name() const {return "unnamed process";}
169  virtual int code() const {return 0;}
170  virtual int nFinal() const {return 2;}
171 
172  // Need to know which incoming partons to set up interaction for.
173  virtual string inFlux() const {return "unknown";}
174 
175  // Need to know whether to convert cross section answer from GeV^-2 to mb.
176  virtual bool convert2mb() const {return true;}
177 
178  // For 2 -> 2 process optional conversion from |M|^2 to d(sigmaHat)/d(tHat).
179  virtual bool convertM2() const {return false;}
180 
181  // Special treatment needed for Les Houches processes.
182  virtual bool isLHA() const {return false;}
183 
184  // Special treatment needed for elastic and diffractive processes.
185  virtual bool isNonDiff() const {return false;}
186  virtual bool isResolved() const {return true;}
187  virtual bool isDiffA() const {return false;}
188  virtual bool isDiffB() const {return false;}
189  virtual bool isDiffC() const {return false;}
190 
191  // Special treatment needed for SUSY processes.
192  virtual bool isSUSY() const {return false;}
193 
194  // Special treatment needed if negative cross sections allowed.
195  virtual bool allowNegativeSigma() const {return false;}
196 
197  // Flavours in 2 -> 2/3 processes where masses needed from beginning.
198  // (For a light quark masses will be used in the final kinematics,
199  // but not at the matrix-element level. For a gluon no masses at all.)
200  virtual int id3Mass() const {return 0;}
201  virtual int id4Mass() const {return 0;}
202  virtual int id5Mass() const {return 0;}
203 
204  // Special treatment needed if process contains an s-channel resonance.
205  virtual int resonanceA() const {return 0;}
206  virtual int resonanceB() const {return 0;}
207 
208  // 2 -> 2 and 2 -> 3 processes only through s-channel exchange.
209  virtual bool isSChannel() const {return false;}
210 
211  // NOAM: Insert an intermediate resonance in 2 -> 1 -> 2 (or 3) listings.
212  virtual int idSChannel() const {return 0;}
213 
214  // QCD 2 -> 3 processes need special phase space selection machinery.
215  virtual bool isQCD3body() const {return false;}
216 
217  // Special treatment in 2 -> 3 with two massive propagators.
218  virtual int idTchan1() const {return 0;}
219  virtual int idTchan2() const {return 0;}
220  virtual double tChanFracPow1() const {return 0.3;}
221  virtual double tChanFracPow2() const {return 0.3;}
222  virtual bool useMirrorWeight() const {return false;}
223 
224  // Special process-specific gamma*/Z0 choice if >=0 (e.g. f fbar -> H0 Z0).
225  virtual int gmZmode() const {return -1;}
226 
227  // Tell whether tHat and uHat are swapped (= same as swap 3 and 4).
228  bool swappedTU() const {return swapTU;}
229 
230  // Give back particle properties: flavours, colours, masses, or all.
231  int id(int i) const {return idSave[i];}
232  int col(int i) const {return colSave[i];}
233  int acol(int i) const {return acolSave[i];}
234  double m(int i) const {return mSave[i];}
235  Particle getParton(int i) const {return parton[i];}
236 
237  // Give back couplings and parton densities.
238  // Not all known for nondiffractive.
239  double Q2Ren() const {return Q2RenSave;}
240  double alphaEMRen() const {return alpEM;}
241  double alphaSRen() const {return alpS;}
242  double Q2Fac() const {return Q2FacSave;}
243  double pdf1() const {return pdf1Save;}
244  double pdf2() const {return pdf2Save;}
245 
246  // Give back angles; relevant only for multipe-interactions processes.
247  double thetaMPI() const {return atan2( sinTheta, cosTheta);}
248  double phiMPI() const {return phi;}
249  double sHBetaMPI() const {return sHBeta;}
250  double pT2MPI() const {return pT2Mass;}
251  double pTMPIFin() const {return pTFin;}
252 
253  // Save and load kinematics for trial interactions
254  void saveKin() {
255  for (int i = 0; i < 6; i++) { partonT[i] = parton[i];
256  mSaveT[i] = mSave[i]; }
257  pTFinT = pTFin; phiT = phi; cosThetaT = cosTheta; sinThetaT = sinTheta; }
258  void loadKin() {
259  for (int i = 0; i < 6; i++) { parton[i] = partonT[i];
260  mSave[i] = mSaveT[i]; }
261  pTFin = pTFinT; cosTheta = cosThetaT; sinTheta = sinThetaT; phi = phiT;
262  }
263  void swapKin() {
264  for (int i = 0; i < 6; i++) { swap(parton[i], partonT[i]);
265  swap(mSave[i], mSaveT[i]); }
266  swap(pTFin, pTFinT); swap(cosTheta, cosThetaT);
267  swap(sinTheta, sinThetaT); swap(phi, phiT); }
268 
269 protected:
270 
271  // Constructor.
272  SigmaProcess() : infoPtr(0), settingsPtr(0), particleDataPtr(0),
273  rndmPtr(0), beamAPtr(0), beamBPtr(0), couplingsPtr(0), sigmaTotPtr(0),
274  slhaPtr(0), lhaUpPtr(0) {for (int i = 0; i < 6; ++i) mSave[i] = 0.;
275  Q2RenSave = alpEM = alpS = Q2FacSave = pdf1Save = pdf2Save = 0.; }
276 
277  // Constants: could only be changed in the code itself.
278  static const double CONVERT2MB, MASSMARGIN, COMPRELERR;
279  static const int NCOMPSTEP;
280 
281  // Pointer to various information on the generation.
282  Info* infoPtr;
283 
284  // Pointer to the settings database.
285  Settings* settingsPtr;
286 
287  // Pointer to the particle data table.
288  ParticleData* particleDataPtr;
289 
290  // Pointer to the random number generator.
291  Rndm* rndmPtr;
292 
293  // Pointers to incoming beams.
294  BeamParticle* beamAPtr;
295  BeamParticle* beamBPtr;
296 
297  // Pointer to Standard Model couplings, including alphaS and alphaEM.
298  Couplings* couplingsPtr;
299 
300  // Pointer to the total/elastic/diffractive cross section object.
301  SigmaTotal* sigmaTotPtr;
302 
303  // Pointer to an SLHA object.
304  SusyLesHouches* slhaPtr;
305 
306  // Pointer to LHAup for generating external events.
307  LHAup* lhaUpPtr;
308 
309  // Initialization data, normally only set once.
310  int nQuarkIn, renormScale1, renormScale2, renormScale3, renormScale3VV,
311  factorScale1, factorScale2, factorScale3, factorScale3VV;
312  double Kfactor, mcME, mbME, mmuME, mtauME, renormMultFac, renormFixScale,
313  factorMultFac, factorFixScale;
314 
315  // CP violation parameters for Higgs sector, normally only set once.
316  int higgsH1parity, higgsH2parity, higgsA3parity;
317  double higgsH1eta, higgsH2eta, higgsA3eta;
318 
319  // Information on incoming beams.
320  int idA, idB;
321  double mA, mB;
322  bool isLeptonA, isLeptonB, hasLeptonBeams;
323 
324  // Partons in beams, with PDF's.
325  vector<InBeam> inBeamA;
326  vector<InBeam> inBeamB;
327  void addBeamA(int idIn) {inBeamA.push_back(InBeam(idIn));}
328  void addBeamB(int idIn) {inBeamB.push_back(InBeam(idIn));}
329  int sizeBeamA() const {return inBeamA.size();}
330  int sizeBeamB() const {return inBeamB.size();}
331 
332  // Allowed colliding parton pairs, with pdf's.
333  vector<InPair> inPair;
334  void addPair(int idAIn, int idBIn) {
335  inPair.push_back(InPair(idAIn, idBIn));}
336  int sizePair() const {return inPair.size();}
337 
338  // Store common subprocess kinematics quantities.
339  double mH, sH, sH2;
340 
341  // Store Q2 renormalization and factorization scales, and related values.
342  double Q2RenSave, alpEM, alpS, Q2FacSave, x1Save, x2Save, pdf1Save,
343  pdf2Save, sigmaSumSave;
344 
345  // Store flavour, colour, anticolour, mass, angles and the whole particle.
346  int id1, id2, id3, id4, id5;
347  int idSave[6], colSave[6], acolSave[6];
348  double mSave[6], cosTheta, sinTheta, phi, sHMass, sHBeta, pT2Mass, pTFin;
349  Particle parton[6];
350 
351  // Minimal set of saved kinematics for trial interactions when
352  // using the x-dependent matter profile of multiparton interactions.
353  Particle partonT[6];
354  double mSaveT[6], pTFinT, cosThetaT, sinThetaT, phiT;
355 
356  // Calculate and store all modified masses and four-vectors
357  // intended for matrix elements. Return false if failed.
358  virtual bool setupForME() {return true;}
359  bool setupForMEin();
360  double mME[5];
361  Vec4 pME[5];
362 
363  // Store whether tHat and uHat are swapped (= same as swap 3 and 4).
364  bool swapTU;
365 
366  // Set flavour, colour and anticolour.
367  void setId( int id1in = 0, int id2in = 0, int id3in = 0, int id4in = 0,
368  int id5in = 0) {idSave[1] = id1in; idSave[2] = id2in; idSave[3] = id3in;
369  idSave[4] = id4in; idSave[5] = id5in;}
370  void setColAcol( int col1 = 0, int acol1 = 0,
371  int col2 = 0, int acol2 = 0, int col3 = 0, int acol3 = 0,
372  int col4 = 0, int acol4 = 0, int col5 = 0, int acol5 = 0) {
373  colSave[1] = col1; acolSave[1] = acol1; colSave[2] = col2;
374  acolSave[2] = acol2; colSave[3] = col3; acolSave[3] = acol3;
375  colSave[4] = col4; acolSave[4] = acol4; colSave[5] = col5;
376  acolSave[5] = acol5; }
377  void swapColAcol() { swap(colSave[1], acolSave[1]);
378  swap(colSave[2], acolSave[2]); swap(colSave[3], acolSave[3]);
379  swap(colSave[4], acolSave[4]); swap(colSave[5], acolSave[5]);}
380  void swapCol1234() { swap(colSave[1], colSave[2]);
381  swap(colSave[3], colSave[4]); swap(acolSave[1], acolSave[2]);
382  swap(acolSave[3], acolSave[4]);}
383  void swapCol12() { swap(colSave[1], colSave[2]);
384  swap(acolSave[1], acolSave[2]);}
385  void swapCol34() { swap(colSave[3], colSave[4]);
386  swap(acolSave[3], acolSave[4]);}
387 
388  // Common code for top and Higgs secondary decay angular weights.
389  double weightTopDecay( Event& process, int iResBeg, int iResEnd);
390  double weightHiggsDecay( Event& process, int iResBeg, int iResEnd);
391 
392 };
393 
394 //==========================================================================
395 
396 // Sigma0Process is the base class for unresolved and minimum-bias processes.
397 // It is derived from SigmaProcess.
398 
399 class Sigma0Process : public SigmaProcess {
400 
401 public:
402 
403  // Destructor.
404  virtual ~Sigma0Process() {}
405 
406  // Number of final-state particles.
407  virtual int nFinal() const {return 2;};
408 
409  // No partonic flux to be set up.
410  virtual bool initFlux() {return true;}
411 
412  // Evaluate sigma for unresolved processes.
413  virtual double sigmaHat() {return 0.;}
414 
415  // Since no PDF's there is no difference from above.
416  virtual double sigmaPDF() {return sigmaHat();}
417 
418  // Answer for these processes already in mb, so do not convert.
419  virtual bool convert2mb() const {return false;}
420 
421 protected:
422 
423  // Constructor.
424  Sigma0Process() {}
425 
426 };
427 
428 //==========================================================================
429 
430 // Sigma1Process is the base class for 2 -> 1 processes.
431 // It is derived from SigmaProcess.
432 
433 class Sigma1Process : public SigmaProcess {
434 
435 public:
436 
437  // Destructor.
438  virtual ~Sigma1Process() {}
439 
440  // Number of final-state particles.
441  virtual int nFinal() const {return 1;};
442 
443  // Input and complement kinematics for resolved 2 -> 1 process.
444  virtual void set1Kin( double x1in, double x2in, double sHin) {
445  store1Kin( x1in, x2in, sHin); sigmaKin();}
446 
447  // Evaluate sigmaHat(sHat) for resolved 2 -> 1 processes.
448  virtual double sigmaHat() {return 0.;}
449 
450  // Wrapper to sigmaHat, to (a) store current incoming flavours,
451  // (b) convert from GeV^-2 to mb where required, and
452  // (c) convert from |M|^2 to d(sigmaHat)/d(tHat) where required.
453  virtual double sigmaHatWrap(int id1in = 0, int id2in = 0);
454 
455 protected:
456 
457  // Constructor.
458  Sigma1Process() {}
459 
460  // Store kinematics and set scales for resolved 2 -> 1 process.
461  virtual void store1Kin( double x1in, double x2in, double sHin);
462 
463  // Calculate modified masses and four-vectors for matrix elements.
464  virtual bool setupForME();
465 
466 };
467 
468 //==========================================================================
469 
470 // Sigma2Process is the base class for 2 -> 2 processes.
471 // It is derived from SigmaProcess.
472 
473 class Sigma2Process : public SigmaProcess {
474 
475 public:
476 
477  // Destructor.
478  virtual ~Sigma2Process() {}
479 
480  // Number of final-state particles.
481  virtual int nFinal() const {return 2;};
482 
483  // Input and complement kinematics for resolved 2 -> 2 process.
484  virtual void set2Kin( double x1in, double x2in, double sHin,
485  double tHin, double m3in, double m4in, double runBW3in,
486  double runBW4in) { store2Kin( x1in, x2in, sHin, tHin, m3in, m4in,
487  runBW3in, runBW4in); sigmaKin();}
488 
489  // Ditto, but for Multiparton Interactions applications, so different input.
490  virtual void set2KinMPI( double x1in, double x2in, double sHin,
491  double tHin, double uHin, double alpSin, double alpEMin,
492  bool needMasses, double m3in, double m4in) {
493  store2KinMPI( x1in, x2in, sHin, tHin, uHin, alpSin, alpEMin,
494  needMasses, m3in, m4in); sigmaKin();}
495 
496  // Evaluate d(sigmaHat)/d(tHat) for resolved 2 -> 2 processes.
497  virtual double sigmaHat() {return 0.;}
498 
499  // Wrapper to sigmaHat, to (a) store current incoming flavours,
500  // (b) convert from GeV^-2 to mb where required, and
501  // (c) convert from |M|^2 to d(sigmaHat)/d(tHat) where required.
502  virtual double sigmaHatWrap(int id1in = 0, int id2in = 0) {
503  id1 = id1in; id2 = id2in; double sigmaTmp = sigmaHat();
504  if (convertM2()) sigmaTmp /= 16. * M_PI * sH2;
505  if (convert2mb()) sigmaTmp *= CONVERT2MB; return sigmaTmp;}
506 
507  // Perform kinematics for a Multiparton Interaction, in its rest frame.
508  virtual bool final2KinMPI( int i1Res = 0, int i2Res = 0, Vec4 p1Res = 0.,
509  Vec4 p2Res = 0., double m1Res = 0., double m2Res = 0.);
510 
511 protected:
512 
513  // Constructor.
514  Sigma2Process() : tH(0.), uH(0.), tH2(0.), uH2(0.), m3(0.), s3(0.),
515  m4(0.), s4(0.), pT2(0.), runBW3(0.), runBW4(0.) {}
516 
517  // Store kinematics and set scales for resolved 2 -> 2 process.
518  virtual void store2Kin( double x1in, double x2in, double sHin,
519  double tHin, double m3in, double m4in, double runBW3in,
520  double runBW4in);
521  virtual void store2KinMPI( double x1in, double x2in, double sHin,
522  double tHin, double uHin, double alpSin, double alpEMin,
523  bool needMasses, double m3in, double m4in);
524 
525  // Calculate modified masses and four-vectors for matrix elements.
526  virtual bool setupForME();
527 
528  // Store subprocess kinematics quantities.
529  double tH, uH, tH2, uH2, m3, s3, m4, s4, pT2, runBW3, runBW4;
530 
531 };
532 
533 //==========================================================================
534 
535 // Sigma3Process is the base class for 2 -> 3 processes.
536 // It is derived from SigmaProcess.
537 
538 class Sigma3Process : public SigmaProcess {
539 
540 public:
541 
542  // Destructor.
543  virtual ~Sigma3Process() {}
544 
545  // Number of final-state particles.
546  virtual int nFinal() const {return 3;};
547 
548  // Input and complement kinematics for resolved 2 -> 3 process.
549  virtual void set3Kin( double x1in, double x2in, double sHin,
550  Vec4 p3cmIn, Vec4 p4cmIn, Vec4 p5cmIn, double m3in, double m4in,
551  double m5in, double runBW3in, double runBW4in, double runBW5in) {
552  store3Kin( x1in, x2in, sHin, p3cmIn, p4cmIn, p5cmIn, m3in, m4in, m5in,
553  runBW3in, runBW4in, runBW5in); sigmaKin();}
554 
555  // Evaluate d(sigmaHat)/d(tHat) for resolved 2 -> 3 processes.
556  virtual double sigmaHat() {return 0.;}
557 
558 protected:
559 
560  // Constructor.
561  Sigma3Process() {}
562 
563  // Store kinematics and set scales for resolved 2 -> 3 process.
564  virtual void store3Kin( double x1in, double x2in, double sHin,
565  Vec4 p3cmIn, Vec4 p4cmIn, Vec4 p5cmIn, double m3in, double m4in,
566  double m5in, double runBW3in, double runBW4in, double runBW5in);
567 
568  // Calculate modified masses and four-vectors for matrix elements.
569  virtual bool setupForME();
570 
571  // Store subprocess kinematics quantities.
572  double m3, s3, m4, s4, m5, s5, runBW3, runBW4, runBW5;
573  Vec4 p3cm, p4cm, p5cm;
574 
575 };
576 
577 //==========================================================================
578 
579 // SigmaLHAProcess is a wrapper class for Les Houches Accord external input.
580 // It is derived from SigmaProcess.
581 
582 class SigmaLHAProcess : public SigmaProcess {
583 
584 public:
585 
586  // Constructor.
587  SigmaLHAProcess() {}
588 
589  // Destructor.
590  virtual ~SigmaLHAProcess() {}
591 
592  // No partonic flux to be set up.
593  virtual bool initFlux() {return true;}
594 
595  // Dummy function: action is put in PhaseSpaceLHA.
596  virtual double sigmaPDF() {return 1.;}
597 
598  // Evaluate weight for decay angular configuration, where relevant.
599  virtual double weightDecay( Event& process, int iResBeg, int iResEnd);
600 
601  // Set scale, when that is missing for an external LHA process.
602  virtual void setScale();
603 
604  // Info on the subprocess.
605  virtual string name() const {return "Les Houches User Process(es)";}
606  virtual int code() const {return 9999;}
607 
608  // Number of final-state particles depends on current process choice.
609  virtual int nFinal() const;
610 
611  // Answer for these processes not in GeV^-2, so do not do this conversion.
612  virtual bool convert2mb() const {return false;}
613 
614  // Ensure special treatment of Les Houches processes.
615  virtual bool isLHA() const {return true;}
616 
617  // Special treatment needed if negative cross sections allowed.
618  virtual bool allowNegativeSigma() const {
619  return (lhaUpPtr->strategy() < 0);}
620 
621 private:
622 
623 };
624 
625 //==========================================================================
626 
627 } // end namespace Pythia8
628 
629 #endif // Pythia8_SigmaProcess_H
630 
Definition: AgUStep.h:26