9 #include "Pythia8/SigmaProcess.h"
24 const double SigmaProcess::CONVERT2MB = 0.389380;
27 const double SigmaProcess::MASSMARGIN = 0.1;
31 const double SigmaProcess::COMPRELERR = 1e-10;
32 const int SigmaProcess::NCOMPSTEP = 10;
38 void SigmaProcess::init(Info* infoPtrIn, Settings* settingsPtrIn,
39 ParticleData* particleDataPtrIn, Rndm* rndmPtrIn, BeamParticle* beamAPtrIn,
40 BeamParticle* beamBPtrIn, Couplings* couplingsPtrIn,
41 SigmaTotal* sigmaTotPtrIn, SLHAinterface* slhaInterfacePtrIn) {
45 settingsPtr = settingsPtrIn;
46 particleDataPtr = particleDataPtrIn;
48 beamAPtr = beamAPtrIn;
49 beamBPtr = beamBPtrIn;
50 couplingsPtr = couplingsPtrIn;
51 sigmaTotPtr = sigmaTotPtrIn;
54 slhaPtr = (slhaInterfacePtrIn != 0) ? &slhaInterfacePtrIn->slha : 0;
57 idA = (beamAPtr != 0) ? beamAPtr->id() : 0;
58 idB = (beamBPtr != 0) ? beamBPtr->id() : 0;
59 mA = (beamAPtr != 0) ? beamAPtr->m() : 0.;
60 mB = (beamBPtr != 0) ? beamBPtr->m() : 0.;
61 isLeptonA = (beamAPtr != 0) ? beamAPtr->isLepton() :
false;
62 isLeptonB = (beamBPtr != 0) ? beamBPtr->isLepton() :
false;
63 hasLeptonBeams = isLeptonA || isLeptonB;
66 Kfactor = settingsPtr->parm(
"SigmaProcess:Kfactor");
69 nQuarkIn = settingsPtr->mode(
"PDFinProcess:nQuarkIn");
72 mcME = (settingsPtr->flag(
"SigmaProcess:cMassiveME"))
73 ? particleDataPtr->m0(4) : 0.;
74 mbME = (settingsPtr->flag(
"SigmaProcess:bMassiveME"))
75 ? particleDataPtr->m0(5) : 0.;
76 mmuME = (settingsPtr->flag(
"SigmaProcess:muMassiveME"))
77 ? particleDataPtr->m0(13) : 0.;
78 mtauME = (settingsPtr->flag(
"SigmaProcess:tauMassiveME"))
79 ? particleDataPtr->m0(15) : 0.;
82 renormScale1 = settingsPtr->mode(
"SigmaProcess:renormScale1");
83 renormScale2 = settingsPtr->mode(
"SigmaProcess:renormScale2");
84 renormScale3 = settingsPtr->mode(
"SigmaProcess:renormScale3");
85 renormScale3VV = settingsPtr->mode(
"SigmaProcess:renormScale3VV");
86 renormMultFac = settingsPtr->parm(
"SigmaProcess:renormMultFac");
87 renormFixScale = settingsPtr->parm(
"SigmaProcess:renormFixScale");
90 factorScale1 = settingsPtr->mode(
"SigmaProcess:factorScale1");
91 factorScale2 = settingsPtr->mode(
"SigmaProcess:factorScale2");
92 factorScale3 = settingsPtr->mode(
"SigmaProcess:factorScale3");
93 factorScale3VV = settingsPtr->mode(
"SigmaProcess:factorScale3VV");
94 factorMultFac = settingsPtr->parm(
"SigmaProcess:factorMultFac");
95 factorFixScale = settingsPtr->parm(
"SigmaProcess:factorFixScale");
98 higgsH1parity = settingsPtr->mode(
"HiggsH1:parity");
99 higgsH1eta = settingsPtr->parm(
"HiggsH1:etaParity");
100 higgsH2parity = settingsPtr->mode(
"HiggsH2:parity");
101 higgsH2eta = settingsPtr->parm(
"HiggsH2:etaParity");
102 higgsA3parity = settingsPtr->mode(
"HiggsA3:parity");
103 higgsA3eta = settingsPtr->parm(
"HiggsA3:etaParity");
106 if (!settingsPtr->flag(
"Higgs:useBSM")){
119 bool SigmaProcess::initFlux() {
127 string fluxType = inFlux();
130 if (fluxType ==
"gg") {
137 else if (fluxType ==
"qg") {
138 for (
int i = -nQuarkIn; i <= nQuarkIn; ++i) {
139 int idNow = (i == 0) ? 21 : i;
143 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
151 else if (fluxType ==
"qq") {
152 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
157 for (
int id1Now = -nQuarkIn; id1Now <= nQuarkIn; ++id1Now)
159 for (
int id2Now = -nQuarkIn; id2Now <= nQuarkIn; ++id2Now)
161 addPair(id1Now, id2Now);
165 else if (fluxType ==
"qqbar") {
166 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
171 for (
int id1Now = -nQuarkIn; id1Now <= nQuarkIn; ++id1Now)
173 for (
int id2Now = -nQuarkIn; id2Now <= nQuarkIn; ++id2Now)
174 if (id2Now != 0 && id1Now * id2Now < 0)
175 addPair(id1Now, id2Now);
179 else if (fluxType ==
"qqbarSame") {
180 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
185 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
187 addPair(idNow, -idNow);
191 else if (fluxType ==
"ff") {
193 if ( isLeptonA && isLeptonB ) {
198 }
else if ( isLeptonA ) {
200 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
206 }
else if ( isLeptonB ) {
208 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
215 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
220 for (
int id1Now = -nQuarkIn; id1Now <= nQuarkIn; ++id1Now)
222 for (
int id2Now = -nQuarkIn; id2Now <= nQuarkIn; ++id2Now)
224 addPair(id1Now, id2Now);
229 else if (fluxType ==
"ffbar") {
231 if (isLeptonA && isLeptonB && idA * idB < 0) {
237 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
242 for (
int id1Now = -nQuarkIn; id1Now <= nQuarkIn; ++id1Now)
244 for (
int id2Now = -nQuarkIn; id2Now <= nQuarkIn; ++id2Now)
245 if (id2Now != 0 && id1Now * id2Now < 0)
246 addPair(id1Now, id2Now);
251 else if (fluxType ==
"ffbarSame") {
253 if ( idA + idB == 0 && isLeptonA ) {
259 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
264 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
266 addPair(idNow, -idNow);
271 else if (fluxType ==
"ffbarChg") {
273 if ( isLeptonA && isLeptonB && abs( particleDataPtr->chargeType(idA)
274 + particleDataPtr->chargeType(idB) ) == 3 ) {
280 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
285 for (
int id1Now = -nQuarkIn; id1Now <= nQuarkIn; ++id1Now)
287 for (
int id2Now = -nQuarkIn; id2Now <= nQuarkIn; ++id2Now)
288 if (id2Now != 0 && id1Now * id2Now < 0
289 && (abs(id1Now) + abs(id2Now))%2 == 1) addPair(id1Now, id2Now);
294 else if (fluxType ==
"fgm") {
300 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
311 for (
int idNow = -nQuarkIn; idNow <= nQuarkIn; ++idNow)
323 else if (fluxType ==
"ggm") {
333 else if (fluxType ==
"gmgm") {
341 infoPtr->errorMsg(
"Error in SigmaProcess::initFlux: "
342 "unrecognized inFlux type", fluxType);
353 double SigmaProcess::sigmaPDF() {
356 for (
int j = 0; j < sizeBeamA(); ++j)
357 inBeamA[j].pdf = beamAPtr->xfHard( inBeamA[j].id, x1Save, Q2FacSave);
358 for (
int j = 0; j < sizeBeamB(); ++j)
359 inBeamB[j].pdf = beamBPtr->xfHard( inBeamB[j].id, x2Save, Q2FacSave);
363 for (
int i = 0; i < sizePair(); ++i) {
366 inPair[i].pdfSigma = Kfactor
367 * sigmaHatWrap(inPair[i].idA, inPair[i].idB);
370 for (
int j = 0; j < sizeBeamA(); ++j)
371 if (inPair[i].idA == inBeamA[j].
id) {
372 inPair[i].pdfA = inBeamA[j].pdf;
373 inPair[i].pdfSigma *= inBeamA[j].pdf;
376 for (
int j = 0; j < sizeBeamB(); ++j)
377 if (inPair[i].idB == inBeamB[j].
id) {
378 inPair[i].pdfB = inBeamB[j].pdf;
379 inPair[i].pdfSigma *= inBeamB[j].pdf;
384 sigmaSumSave += inPair[i].pdfSigma;
396 void SigmaProcess::pickInState(
int id1in,
int id2in) {
399 if (id1in != 0 && id2in != 0) {
406 double sigmaRand = sigmaSumSave * rndmPtr->flat();
407 for (
int i = 0; i < sizePair(); ++i) {
408 sigmaRand -= inPair[i].pdfSigma;
409 if (sigmaRand <= 0.) {
412 pdf1Save = inPair[i].pdfA;
413 pdf2Save = inPair[i].pdfB;
424 bool SigmaProcess::setupForMEin() {
431 int id1Tmp = abs(id1);
432 if (id1Tmp == 4) mME[0] = mcME;
433 if (id1Tmp == 5) mME[0] = mbME;
434 if (id1Tmp == 13) mME[0] = mmuME;
435 if (id1Tmp == 15) mME[0] = mtauME;
437 int id2Tmp = abs(id2);
438 if (id2Tmp == 4) mME[1] = mcME;
439 if (id2Tmp == 5) mME[1] = mbME;
440 if (id2Tmp == 13) mME[1] = mmuME;
441 if (id2Tmp == 15) mME[1] = mtauME;
444 if (mME[0] + mME[1] >= mH) {
451 if (mME[0] == 0. && mME[1] == 0.) {
452 pME[0] = 0.5 * mH * Vec4( 0., 0., 1., 1.);
453 pME[1] = 0.5 * mH * Vec4( 0., 0., -1., 1.);
455 double e0 = 0.5 * (mH * mH + mME[0] * mME[0] - mME[1] * mME[1]) / mH;
456 double pz0 = sqrtpos(e0 * e0 - mME[0] * mME[0]);
457 pME[0] = Vec4( 0., 0., pz0, e0);
458 pME[1] = Vec4( 0., 0., -pz0, mH - e0);
470 double SigmaProcess::weightTopDecay(
Event& process,
int iResBeg,
474 if (iResEnd - iResBeg != 1)
return 1.;
476 int iB2 = iResBeg + 1;
477 int idW1 = process[iW1].idAbs();
478 int idB2 = process[iB2].idAbs();
483 if (idW1 != 24 || (idB2 != 1 && idB2 != 3 && idB2 != 5))
return 1.;
484 int iT = process[iW1].mother1();
485 if (iT <= 0 || process[iT].idAbs() != 6)
return 1.;
488 int iF = process[iW1].daughter1();
489 int iFbar = process[iW1].daughter2();
490 if (iFbar - iF != 1)
return 1.;
491 if (process[iT].
id() * process[iF].
id() < 0) swap(iF, iFbar);
494 double wt = (process[iT].p() * process[iFbar].p())
495 * (process[iF].p() * process[iB2].p());
496 double wtMax = ( pow4(process[iT].m()) - pow4(process[iW1].m()) ) / 8.;
508 double SigmaProcess::weightHiggsDecay(
Event& process,
int iResBeg,
512 if (iResEnd - iResBeg != 1)
return 1.;
514 int iZW2 = iResBeg + 1;
515 int idZW1 = process[iZW1].id();
516 int idZW2 = process[iZW2].id();
517 if (idZW1 < 0 || idZW2 == 22) {
521 if ( (idZW1 != 23 || idZW2 != 23) && (idZW1 != 24 || idZW2 != -24)
522 && (idZW1 != 22 || idZW2 != 23) )
return 1.;
525 int iH = process[iZW1].mother1();
526 if (iH <= 0)
return 1.;
527 int idH = process[iH].id();
528 if (idH != 25 && idH != 35 && idH !=36)
return 1.;
532 int i5 = process[iZW2].daughter1();
533 int i6 = process[iZW2].daughter2();
534 double pgmZ = process[iZW1].p() * process[iZW2].p();
535 double pgm5 = process[iZW1].p() * process[i5].p();
536 double pgm6 = process[iZW1].p() * process[i6].p();
537 return (pow2(pgm5) + pow2(pgm6)) / pow2(pgmZ);
541 int higgsParity = higgsH1parity;
542 double higgsEta = higgsH1eta;
544 higgsParity = higgsH2parity;
545 higgsEta = higgsH2eta;
546 }
else if (idH == 36) {
547 higgsParity = higgsA3parity;
548 higgsEta = higgsA3eta;
552 if (higgsParity == 0)
return 1.;
555 double wtMax = pow4(process[iH].m());
559 int i3 = process[iZW1].daughter1();
560 int i4 = process[iZW1].daughter2();
561 if (process[i3].
id() < 0) swap( i3, i4);
562 int i5 = process[iZW2].daughter1();
563 int i6 = process[iZW2].daughter2();
564 if (process[i5].
id() < 0) swap( i5, i6);
567 double p35 = 2. * process[i3].p() * process[i5].p();
568 double p36 = 2. * process[i3].p() * process[i6].p();
569 double p45 = 2. * process[i4].p() * process[i5].p();
570 double p46 = 2. * process[i4].p() * process[i6].p();
571 double p34 = 2. * process[i3].p() * process[i4].p();
572 double p56 = 2. * process[i5].p() * process[i6].p();
573 double mZW1 = process[iZW1].m();
574 double mZW2 = process[iZW2].m();
577 double epsilonProd = 0.;
578 if (higgsParity == 3) {
580 for (
int i = 0; i < 4; ++i) {
585 p[i][0] = process[ii].e();
586 p[i][1] = process[ii].px();
587 p[i][2] = process[ii].py();
588 p[i][3] = process[ii].pz();
591 = p[0][0]*p[1][1]*p[2][2]*p[3][3] - p[0][0]*p[1][1]*p[2][3]*p[3][2]
592 - p[0][0]*p[1][2]*p[2][1]*p[3][3] + p[0][0]*p[1][2]*p[2][3]*p[3][1]
593 + p[0][0]*p[1][3]*p[2][1]*p[3][2] - p[0][0]*p[1][3]*p[2][2]*p[3][1]
594 - p[0][1]*p[1][0]*p[2][2]*p[3][3] + p[0][1]*p[1][0]*p[2][3]*p[3][2]
595 + p[0][1]*p[1][2]*p[2][0]*p[3][3] - p[0][1]*p[1][2]*p[2][3]*p[3][0]
596 - p[0][1]*p[1][3]*p[2][0]*p[3][2] + p[0][1]*p[1][3]*p[2][2]*p[3][0]
597 + p[0][2]*p[1][0]*p[2][1]*p[3][3] - p[0][2]*p[1][0]*p[2][3]*p[3][1]
598 - p[0][2]*p[1][1]*p[2][0]*p[3][3] + p[0][2]*p[1][1]*p[2][3]*p[3][0]
599 + p[0][2]*p[1][3]*p[2][0]*p[3][1] - p[0][2]*p[1][3]*p[2][1]*p[3][0]
600 - p[0][3]*p[1][0]*p[2][1]*p[3][2] + p[0][3]*p[1][0]*p[2][2]*p[3][1]
601 + p[0][3]*p[1][1]*p[2][0]*p[3][2] - p[0][3]*p[1][1]*p[2][2]*p[3][0]
602 - p[0][3]*p[1][2]*p[2][0]*p[3][1] + p[0][3]*p[1][2]*p[2][1]*p[3][0];
607 double vf1 = couplingsPtr->vf(process[i3].idAbs());
608 double af1 = couplingsPtr->af(process[i3].idAbs());
609 double vf2 = couplingsPtr->vf(process[i5].idAbs());
610 double af2 = couplingsPtr->af(process[i5].idAbs());
611 double va12asym = 4. * vf1 * af1 * vf2 * af2
612 / ( (vf1*vf1 + af1*af1) * (vf2*vf2 + af2*af2) );
613 double etaMod = higgsEta / pow2( particleDataPtr->m0(23) );
616 if (higgsParity == 1) wt = 8. * (1. + va12asym) * p35 * p46
617 + 8. * (1. - va12asym) * p36 * p45;
620 else if (higgsParity == 2) wt = ( pow2(p35 + p46)
621 + pow2(p36 + p45) - 2. * p34 * p56
622 - 2. * pow2(p35 * p46 - p36 * p45) / (p34 * p56)
623 + va12asym * (p35 + p36 - p45 - p46) * (p35 + p45 - p36 - p46) )
627 else wt = 32. * ( 0.25 * ( (1. + va12asym) * p35 * p46
628 + (1. - va12asym) * p36 * p45 ) - 0.5 * etaMod * epsilonProd
629 * ( (1. + va12asym) * (p35 + p46) - (1. - va12asym) * (p36 + p45) )
630 + 0.0625 * etaMod * etaMod * (-2. * pow2(p34 * p56)
631 - 2. * pow2(p35 * p46 - p36 * p45)
632 + p34 * p56 * (pow2(p35 + p46) + pow2(p36 + p45))
633 + va12asym * p34 * p56 * (p35 + p36 - p45 - p46)
634 * (p35 + p45 - p36 - p46) ) ) / ( 1. + 2. * etaMod * mZW1 * mZW2
635 + 2. * pow2(etaMod * mZW1 * mZW2) * (1. + va12asym) );
638 }
else if (idZW1 == 24) {
639 double etaMod = higgsEta / pow2( particleDataPtr->m0(24) );
642 if (higgsParity == 1) wt = 16. * p35 * p46;
645 else if (higgsParity == 2) wt = 0.5 * ( pow2(p35 + p46)
646 + pow2(p36 + p45) - 2. * p34 * p56
647 - 2. * pow2(p35 * p46 - p36 * p45) / (p34 * p56)
648 + (p35 + p36 - p45 - p46) * (p35 + p45 - p36 - p46) );
651 else wt = 32. * ( 0.25 * 2. * p35 * p46
652 - 0.5 * etaMod * epsilonProd * 2. * (p35 + p46)
653 + 0.0625 * etaMod * etaMod * (-2. * pow2(p34 * p56)
654 - 2. * pow2(p35 * p46 - p36 * p45)
655 + p34 * p56 * (pow2(p35 + p46) + pow2(p36 + p45))
656 + p34 * p56 * (p35 + p36 - p45 - p46) * (p35 + p45 - p36 - p46) ) )
657 / ( 1. * 2. * etaMod * mZW1 * mZW2 + 2. * pow2(etaMod * mZW1 * mZW2) );
676 double Sigma1Process::sigmaHatWrap(
int id1in,
int id2in) {
680 double sigmaTmp = sigmaHat();
684 int idTmp = resonanceA();
685 double mTmp = particleDataPtr->m0(idTmp);
686 double GamTmp = particleDataPtr->mWidth(idTmp);
687 sigmaTmp *= 2. * mTmp * GamTmp / ( pow2(sH - mTmp * mTmp)
688 + pow2(mTmp * GamTmp) );
690 if (convert2mb()) sigmaTmp *= CONVERT2MB;
699 void Sigma1Process::store1Kin(
double x1in,
double x2in,
double sHin) {
712 Q2RenSave = renormMultFac * sH;
713 if (renormScale1 == 2) Q2RenSave = renormFixScale;
716 Q2FacSave = factorMultFac * sH;
717 if (factorScale1 == 2) Q2FacSave = factorFixScale;
720 alpS = couplingsPtr->alphaS(Q2RenSave);
721 alpEM = couplingsPtr->alphaEM(Q2RenSave);
729 bool Sigma1Process::setupForME() {
732 bool allowME = setupForMEin();
736 pME[2] = Vec4( 0., 0., 0., mH);
752 void Sigma2Process::store2Kin(
double x1in,
double x2in,
double sHin,
753 double tHin,
double m3in,
double m4in,
double runBW3in,
double runBW4in) {
763 bool masslessKin = (id3Mass() == 0) && (id4Mass() == 0);
779 uH = (masslessKin) ? -(sH + tH) : s3 + s4 - (sH + tH);
790 pT2 = (masslessKin) ? tH * uH / sH : (tH * uH - s3 * s4) / sH;
796 Q2RenSave = renormMultFac * sH;
797 if (renormScale1 == 2) Q2RenSave = renormFixScale;
800 Q2FacSave = factorMultFac * sH;
801 if (factorScale1 == 2) Q2FacSave = factorFixScale;
807 if (masslessKin) Q2RenSave = (renormScale2 < 4) ? pT2 : sH;
808 else if (renormScale2 == 1) Q2RenSave = pT2 + min(s3, s4);
809 else if (renormScale2 == 2) Q2RenSave = sqrt((pT2 + s3) * (pT2 + s4));
810 else if (renormScale2 == 3) Q2RenSave = pT2 + 0.5 * (s3 + s4);
812 Q2RenSave *= renormMultFac;
813 if (renormScale2 == 5) Q2RenSave = renormFixScale;
816 if (masslessKin) Q2FacSave = (factorScale2 < 4) ? pT2 : sH;
817 else if (factorScale2 == 1) Q2FacSave = pT2 + min(s3, s4);
818 else if (factorScale2 == 2) Q2FacSave = sqrt((pT2 + s3) * (pT2 + s4));
819 else if (factorScale2 == 3) Q2FacSave = pT2 + 0.5 * (s3 + s4);
821 Q2FacSave *= factorMultFac;
822 if (factorScale2 == 5) Q2FacSave = factorFixScale;
826 alpS = couplingsPtr->alphaS(Q2RenSave);
827 alpEM = couplingsPtr->alphaEM(Q2RenSave);
835 void Sigma2Process::store2KinMPI(
double x1in,
double x2in,
836 double sHin,
double tHin,
double uHin,
double alpSin,
double alpEMin,
837 bool needMasses,
double m3in,
double m4in) {
867 cosTheta = (tH - uH) / sH;
868 sinTheta = 2. * sqrtpos( tH * uH ) / sH;
876 sHMass = sH - s3 - s4;
877 sHBeta = sqrtpos(sHMass*sHMass - 4. * s3 * s4);
878 tH = -0.5 * (sHMass - sHBeta * cosTheta);
879 uH = -0.5 * (sHMass + sHBeta * cosTheta);
885 pT2Mass = 0.25 * sHBeta * pow2(sinTheta);
893 bool Sigma2Process::final2KinMPI(
int i1Res,
int i2Res, Vec4 p1Res, Vec4 p2Res,
894 double m1Res,
double m2Res) {
900 m3 = particleDataPtr->m0(idSave[3]);
901 m4 = particleDataPtr->m0(idSave[4]);
903 if (m3 + m4 + MASSMARGIN > mH)
return false;
908 double e1In = 0.5 * mH;
911 if (i1Res > 0 || i2Res > 0) {
912 double s1 = m1Res * m1Res;
913 double s2 = m2Res * m2Res;
914 e1In = 0.5 * (sH + s1 - s2) / mH;
915 e2In = 0.5 * (sH + s2 - s1) / mH;
916 pzIn = sqrtpos( e1In*e1In - s1 );
920 double e3 = 0.5 * (sH + s3 - s4) / mH;
921 double e4 = 0.5 * (sH + s4 - s3) / mH;
922 double pAbs = sqrtpos( e3*e3 - s3 );
923 phi = 2. * M_PI * rndmPtr->flat();
924 double pZ = pAbs * cosTheta;
925 pTFin = pAbs * sinTheta;
926 double pX = pTFin * sin(phi);
927 double pY = pTFin * cos(phi);
928 double scale = 0.5 * mH * sinTheta;
931 int status1 = (i1Res == 0) ? -31 : -34;
932 int status2 = (i2Res == 0) ? -31 : -34;
933 parton[1] = Particle( idSave[1], status1, 0, 0, 3, 4,
934 colSave[1], acolSave[1], 0., 0., pzIn, e1In, m1Res, scale);
935 parton[2] = Particle( idSave[2], status2, 0, 0, 3, 4,
936 colSave[2], acolSave[2], 0., 0., -pzIn, e2In, m2Res, scale);
937 parton[3] = Particle( idSave[3], 33, 1, 2, 0, 0,
938 colSave[3], acolSave[3], pX, pY, pZ, e3, m3, scale);
939 parton[4] = Particle( idSave[4], 33, 1, 2, 0, 0,
940 colSave[4], acolSave[4], -pX, -pY, -pZ, e4, m4, scale);
944 if (i1Res == 0 && i2Res == 0) {
945 double betaZ = (x1Save - x2Save) / (x1Save + x2Save);
946 for (
int i = 1; i <= 4; ++i) parton[i].bst(0., 0., betaZ);
950 M.fromCMframe( p1Res, p2Res);
951 for (
int i = 1; i <= 4; ++i) parton[i].rotbst(M);
963 bool Sigma2Process::setupForME() {
966 bool allowME = setupForMEin();
970 int id3Tmp = abs(id3Mass());
971 if (id3Tmp == 4) mME[2] = mcME;
972 if (id3Tmp == 5) mME[2] = mbME;
973 if (id3Tmp == 13) mME[2] = mmuME;
974 if (id3Tmp == 15) mME[2] = mtauME;
976 int id4Tmp = abs(id4Mass());
977 if (id4Tmp == 4) mME[3] = mcME;
978 if (id4Tmp == 5) mME[3] = mbME;
979 if (id4Tmp == 13) mME[3] = mmuME;
980 if (id4Tmp == 15) mME[3] = mtauME;
983 if (mME[2] + mME[3] >= mH) {
990 double sH34 = sqrtpos( pow2(sH - s3 - s4) - 4. * s3 * s4);
991 double cThe = (tH - uH) / sH34;
992 double sThe = sqrtpos(1. - cThe * cThe);
995 double s3ME = pow2(mME[2]);
996 double s4ME = pow2(mME[3]);
997 double sH34ME = sqrtpos( pow2(sH - s3ME - s4ME) - 4. * s3ME * s4ME);
998 double pAbsME = 0.5 * sH34ME / mH;
1001 if (id3Tmp == 0 || id3Tmp != id4Tmp) {
1002 pME[2] = Vec4( pAbsME * sThe, 0., pAbsME * cThe,
1003 0.5 * (sH + s3ME - s4ME) / mH);
1004 pME[3] = Vec4( -pAbsME * sThe, 0., -pAbsME * cThe,
1005 0.5 * (sH + s4ME - s3ME) / mH);
1009 mME[2] = sqrtpos(0.5 * (s3ME + s4ME) - 0.25 * pow2(s3ME - s4ME) / sH);
1011 pME[2] = Vec4( pAbsME * sThe, 0., pAbsME * cThe, 0.5 * mH);
1012 pME[3] = Vec4( -pAbsME * sThe, 0., -pAbsME * cThe, 0.5 * mH);
1029 void Sigma3Process::store3Kin(
double x1in,
double x2in,
double sHin,
1030 Vec4 p3cmIn, Vec4 p4cmIn, Vec4 p5cmIn,
double m3in,
double m4in,
1031 double m5in,
double runBW3in,
double runBW4in,
double runBW5in) {
1041 if (id3Mass() == 0 && id4Mass() == 0 && id5Mass() == 0) {
1074 Q2RenSave = renormMultFac * sH;
1075 if (renormScale1 == 2) Q2RenSave = renormFixScale;
1078 Q2FacSave = factorMultFac * sH;
1079 if (factorScale1 == 2) Q2RenSave = factorFixScale;
1082 }
else if ( idTchan1() != 23 && idTchan1() != 24 && idTchan2() != 23
1083 && idTchan2() != 24 ) {
1084 double mT3S = s3 + p3cm.pT2();
1085 double mT4S = s4 + p4cm.pT2();
1086 double mT5S = s5 + p5cm.pT2();
1089 if (renormScale3 == 1) Q2RenSave = min( mT3S, min(mT4S, mT5S) );
1090 else if (renormScale3 == 2) Q2RenSave = sqrt( mT3S * mT4S * mT5S
1091 / max( mT3S, max(mT4S, mT5S) ) );
1092 else if (renormScale3 == 3) Q2RenSave = pow( mT3S * mT4S * mT5S,
1094 else if (renormScale3 == 4) Q2RenSave = (mT3S + mT4S + mT5S) / 3.;
1095 else Q2RenSave = sH;
1096 Q2RenSave *= renormMultFac;
1097 if (renormScale3 == 6) Q2RenSave = renormFixScale;
1100 if (factorScale3 == 1) Q2FacSave = min( mT3S, min(mT4S, mT5S) );
1101 else if (factorScale3 == 2) Q2FacSave = sqrt( mT3S * mT4S * mT5S
1102 / max( mT3S, max(mT4S, mT5S) ) );
1103 else if (factorScale3 == 3) Q2FacSave = pow( mT3S * mT4S * mT5S,
1105 else if (factorScale3 == 4) Q2FacSave = (mT3S + mT4S + mT5S) / 3.;
1106 else Q2FacSave = sH;
1107 Q2FacSave *= factorMultFac;
1108 if (factorScale3 == 6) Q2FacSave = factorFixScale;
1112 double sV4 = pow2( particleDataPtr->m0(idTchan1()) );
1113 double sV5 = pow2( particleDataPtr->m0(idTchan2()) );
1114 double mT3S = s3 + p3cm.pT2();
1115 double mTV4S = sV4 + p4cm.pT2();
1116 double mTV5S = sV5 + p5cm.pT2();
1119 if (renormScale3VV == 1) Q2RenSave = max( sV4, sV5);
1120 else if (renormScale3VV == 2) Q2RenSave = sqrt( mTV4S * mTV5S );
1121 else if (renormScale3VV == 3) Q2RenSave = pow( mT3S * mTV4S * mTV5S,
1123 else if (renormScale3VV == 4) Q2RenSave = (mT3S * mTV4S * mTV5S) / 3.;
1124 else Q2RenSave = sH;
1125 Q2RenSave *= renormMultFac;
1126 if (renormScale3VV == 6) Q2RenSave = renormFixScale;
1129 if (factorScale3VV == 1) Q2FacSave = max( sV4, sV5);
1130 else if (factorScale3VV == 2) Q2FacSave = sqrt( mTV4S * mTV5S );
1131 else if (factorScale3VV == 3) Q2FacSave = pow( mT3S * mTV4S * mTV5S,
1133 else if (factorScale3VV == 4) Q2FacSave = (mT3S * mTV4S * mTV5S) / 3.;
1134 else Q2FacSave = sH;
1135 Q2FacSave *= factorMultFac;
1136 if (factorScale3VV == 6) Q2FacSave = factorFixScale;
1140 alpS = couplingsPtr->alphaS(Q2RenSave);
1141 alpEM = couplingsPtr->alphaEM(Q2RenSave);
1149 bool Sigma3Process::setupForME() {
1152 bool allowME = setupForMEin();
1156 int id3Tmp = abs(id3Mass());
1157 if (id3Tmp == 4) mME[2] = mcME;
1158 if (id3Tmp == 5) mME[2] = mbME;
1159 if (id3Tmp == 13) mME[2] = mmuME;
1160 if (id3Tmp == 15) mME[2] = mtauME;
1162 int id4Tmp = abs(id4Mass());
1163 if (id4Tmp == 4) mME[3] = mcME;
1164 if (id4Tmp == 5) mME[3] = mbME;
1165 if (id4Tmp == 13) mME[3] = mmuME;
1166 if (id4Tmp == 15) mME[3] = mtauME;
1168 int id5Tmp = abs(id5Mass());
1169 if (id5Tmp == 4) mME[4] = mcME;
1170 if (id5Tmp == 5) mME[4] = mbME;
1171 if (id5Tmp == 13) mME[4] = mmuME;
1172 if (id5Tmp == 15) mME[4] = mtauME;
1175 if (mME[2] + mME[3] + mME[4] >= mH) {
1183 if (id3Tmp != 0 && id4Tmp == id3Tmp && id5Tmp == id3Tmp) {
1184 double mAvg = (mME[2] + mME[3] + mME[4]) / 3.;
1188 }
else if (id3Tmp != 0 && id4Tmp == id3Tmp) {
1189 mME[2] = sqrtpos(0.5 * (pow2(mME[2]) + pow2(mME[3]))
1190 - 0.25 * pow2(pow2(mME[2]) - pow2(mME[3])) / sH);
1192 }
else if (id3Tmp != 0 && id5Tmp == id3Tmp) {
1193 mME[2] = sqrtpos(0.5 * (pow2(mME[2]) + pow2(mME[4]))
1194 - 0.25 * pow2(pow2(mME[2]) - pow2(mME[4])) / sH);
1196 }
else if (id4Tmp != 0 && id5Tmp == id4Tmp) {
1197 mME[3] = sqrtpos(0.5 * (pow2(mME[3]) + pow2(mME[4]))
1198 - 0.25 * pow2(pow2(mME[3]) - pow2(mME[4])) / sH);
1203 double m2ME3 = pow2(mME[2]);
1204 double m2ME4 = pow2(mME[3]);
1205 double m2ME5 = pow2(mME[4]);
1206 double p2ME3 = p3cm.pAbs2();
1207 double p2ME4 = p4cm.pAbs2();
1208 double p2ME5 = p5cm.pAbs2();
1209 double p2sum = p2ME3 + p2ME4 + p2ME5;
1210 double eME3 = sqrt(m2ME3 + p2ME3);
1211 double eME4 = sqrt(m2ME4 + p2ME4);
1212 double eME5 = sqrt(m2ME5 + p2ME5);
1213 double esum = eME3 + eME4 + eME5;
1214 double p2rat = p2ME3 / eME3 + p2ME4 / eME4 + p2ME5 / eME5;
1216 while ( abs(esum - mH) > COMPRELERR * mH && iStep < NCOMPSTEP ) {
1218 double compFac = 1. + 2. * (mH - esum) / p2rat;
1222 eME3 = sqrt(m2ME3 + p2ME3);
1223 eME4 = sqrt(m2ME4 + p2ME4);
1224 eME5 = sqrt(m2ME5 + p2ME5);
1225 esum = eME3 + eME4 + eME5;
1226 p2rat = p2ME3 / eME3 + p2ME4 / eME4 + p2ME5 / eME5;
1230 if (abs(esum - mH) > COMPRELERR * mH) allowME =
false;
1233 double totFac = sqrt( (p2ME3 + p2ME4 + p2ME5) / p2sum);
1234 pME[2] = totFac * p3cm;
1236 pME[3] = totFac * p4cm;
1238 pME[4] = totFac * p5cm;
1256 double SigmaLHAProcess::weightDecay(
Event& process,
int iResBeg,
1260 if (iResBeg < process.savedSizeValue())
return 1.;
1263 int idMother = process[process[iResBeg].mother1()].idAbs();
1266 if (idMother == 25 || idMother == 35 || idMother == 36)
1267 return weightHiggsDecay( process, iResBeg, iResEnd);
1271 return weightTopDecay( process, iResBeg, iResEnd);
1282 void SigmaLHAProcess::setScale() {
1285 double scaleLHA = lhaUpPtr->scale();
1286 if (scaleLHA < 0.) {
1291 for (
int i = 3; i < lhaUpPtr->sizePart(); ++i)
1292 if (lhaUpPtr->mother1(i) == 1) {
1294 pFinSum += Vec4( lhaUpPtr->px(i), lhaUpPtr->py(i),
1295 lhaUpPtr->pz(i), lhaUpPtr->e(i) );
1297 int nFin = iFin.size();
1298 sH = pFinSum * pFinSum;
1304 Q2RenSave = renormMultFac * sH;
1305 if (renormScale1 == 2) Q2RenSave = renormFixScale;
1306 Q2FacSave = factorMultFac * sH;
1307 if (factorScale1 == 2) Q2FacSave = factorFixScale;
1310 }
else if (nFin == 2) {
1311 double s3 = pow2(lhaUpPtr->m(iFin[0]));
1312 double s4 = pow2(lhaUpPtr->m(iFin[1]));
1313 double pT2 = pow2(lhaUpPtr->px(iFin[0])) + pow2(lhaUpPtr->py(iFin[0]));
1314 if (renormScale2 == 1) Q2RenSave = pT2 + min(s3, s4);
1315 else if (renormScale2 == 2) Q2RenSave = sqrt((pT2 + s3) * (pT2 + s4));
1316 else if (renormScale2 == 3) Q2RenSave = pT2 + 0.5 * (s3 + s4);
1317 else Q2RenSave = sH;
1318 Q2RenSave *= renormMultFac;
1319 if (renormScale2 == 5) Q2RenSave = renormFixScale;
1320 if (factorScale2 == 1) Q2FacSave = pT2 + min(s3, s4);
1321 else if (factorScale2 == 2) Q2FacSave = sqrt((pT2 + s3) * (pT2 + s4));
1322 else if (factorScale2 == 3) Q2FacSave = pT2 + 0.5 * (s3 + s4);
1323 else Q2FacSave = sH;
1324 Q2FacSave *= factorMultFac;
1325 if (factorScale2 == 5) Q2FacSave = factorFixScale;
1331 double mTSprod = 1.;
1333 for (
int i = 0; i < nFin; ++i) {
1334 double mTSnow = pow2(lhaUpPtr->m(iFin[i]))
1335 + pow2(lhaUpPtr->px(iFin[i])) + pow2(lhaUpPtr->py(iFin[i]));
1336 if (mTSnow < mTSlow) {mTSmed = mTSlow; mTSlow = mTSnow;}
1337 else if (mTSnow < mTSmed) mTSmed = mTSnow;
1341 if (renormScale3 == 1) Q2RenSave = mTSlow;
1342 else if (renormScale3 == 2) Q2RenSave = sqrt(mTSlow * mTSmed);
1343 else if (renormScale3 == 3) Q2RenSave = pow(mTSprod, 1. / nFin);
1344 else if (renormScale3 == 4) Q2RenSave = mTSsum / nFin;
1345 else Q2RenSave = sH;
1346 Q2RenSave *= renormMultFac;
1347 if (renormScale3 == 6) Q2RenSave = renormFixScale;
1348 if (factorScale3 == 1) Q2FacSave = mTSlow;
1349 else if (factorScale3 == 2) Q2FacSave = sqrt(mTSlow * mTSmed);
1350 else if (factorScale3 == 3) Q2FacSave = pow(mTSprod, 1. / nFin);
1351 else if (factorScale3 == 4) Q2FacSave = mTSsum / nFin;
1352 else Q2FacSave = sH;
1353 Q2FacSave *= factorMultFac;
1354 if (factorScale3 == 6) Q2FacSave = factorFixScale;
1359 if (lhaUpPtr->alphaQCD() < 0.001) {
1360 double Q2RenNow = (scaleLHA < 0.) ? Q2RenSave : pow2(scaleLHA);
1361 alpS = couplingsPtr->alphaS(Q2RenNow);
1363 if (lhaUpPtr->alphaQED() < 0.001) {
1364 double Q2RenNow = (scaleLHA < 0.) ? Q2RenSave : pow2(scaleLHA);
1365 alpEM = couplingsPtr->alphaEM(Q2RenNow);
1374 int SigmaLHAProcess::nFinal()
const {
1377 if (lhaUpPtr->sizePart() <= 0)
return 0;
1381 for (
int i = 3; i < lhaUpPtr->sizePart(); ++i)
1382 if (lhaUpPtr->mother1(i) == 1) ++nFin;