92 G4cout <<
"---------------------------- Annihilation----------------" <<
G4endl;
95 CommonVariables common;
100 if ( ProjectilePDGcode > 0 ) {
104 G4double M0projectile2 = common.Pprojectile.mag2();
112 G4cout <<
"PDG codes " << ProjectilePDGcode <<
" " << TargetPDGcode <<
G4endl
113 <<
"Pprojec " << common.Pprojectile <<
" " << common.Pprojectile.mag() <<
G4endl
114 <<
"Ptarget " << common.Ptarget <<
" " << common.Ptarget.mag() <<
G4endl
115 <<
"M0 proj target " << std::sqrt( M0projectile2 )
116 <<
" " << std::sqrt( M0target2 ) <<
G4endl;
121 common.S = Psum.
mag2();
122 common.SqrtS = std::sqrt( common.S );
124 G4cout <<
"Psum SqrtS S " << Psum <<
" " << common.SqrtS <<
" " << common.S <<
G4endl;
132 common.toLab = toCms.
inverse();
135 common.RotateStrings =
true;
143 ( 2.0*140.0 + 16.0 )*MeV;
145 - 2.0*( common.S*(M0projectile2 + M0target2) + M0projectile2*M0target2 );
147 G4double X_a = 0.0, X_b = 0.0, X_c = 0.0, X_d = 0.0;
148 if ( Prel2 <= 0.0 ) {
155 G4cout <<
"Annih at Rest X a b c d " << X_a <<
" " << X_b <<
" " << X_c <<
" " << X_d
159 G4double FlowF = 1.0 / std::sqrt( Prel2 )*GeV;
162 if ( common.SqrtS < MesonProdThreshold ) {
165 X_b = 6.8*GeV / common.SqrtS;
175 X_d = 23.3*GeV*GeV / common.S;
177 G4cout <<
"Annih in Flight X a b c d " << X_a <<
" " << X_b <<
" " << X_c <<
" " << X_d
178 <<
G4endl <<
"SqrtS MesonProdThreshold " << common.SqrtS <<
" " << MesonProdThreshold
184 if ( TargetPDGcode == 2212 || TargetPDGcode == 2214 ) {
185 if ( ProjectilePDGcode == -2212 || ProjectilePDGcode == -2214 ) {
186 X_b *= 5.0; X_c *= 5.0; X_d *= 6.0;
187 }
else if ( ProjectilePDGcode == -2112 || ProjectilePDGcode == -2114 ) {
188 X_b *= 4.0; X_c *= 4.0; X_d *= 4.0;
189 }
else if ( ProjectilePDGcode == -3122 ) {
190 X_b *= 3.0; X_c *= 3.0; X_d *= 2.0;
191 }
else if ( ProjectilePDGcode == -3112 ) {
192 X_b *= 2.0; X_c *= 2.0; X_d *= 0.0;
193 }
else if ( ProjectilePDGcode == -3212 ) {
194 X_b *= 3.0; X_c *= 3.0; X_d *= 2.0;
195 }
else if ( ProjectilePDGcode == -3222 ) {
196 X_b *= 4.0; X_c *= 4.0; X_d *= 2.0;
197 }
else if ( ProjectilePDGcode == -3312 ) {
198 X_b *= 1.0; X_c *= 1.0; X_d *= 0.0;
199 }
else if ( ProjectilePDGcode == -3322 ) {
200 X_b *= 2.0; X_c *= 2.0; X_d *= 0.0;
201 }
else if ( ProjectilePDGcode == -3334 ) {
202 X_b *= 0.0; X_c *= 0.0; X_d *= 0.0;
206 }
else if ( TargetPDGcode == 2112 || TargetPDGcode == 2114 ) {
207 if ( ProjectilePDGcode == -2212 || ProjectilePDGcode == -2214 ) {
208 X_b *= 4.0; X_c *= 4.0; X_d *= 4.0;
209 }
else if ( ProjectilePDGcode == -2112 || ProjectilePDGcode == -2114 ) {
210 X_b *= 5.0; X_c *= 5.0; X_d *= 6.0;
211 }
else if ( ProjectilePDGcode == -3122 ) {
212 X_b *= 3.0; X_c *= 3.0; X_d *= 2.0;
213 }
else if ( ProjectilePDGcode == -3112 ) {
214 X_b *= 4.0; X_c *= 4.0; X_d *= 2.0;
215 }
else if ( ProjectilePDGcode == -3212 ) {
216 X_b *= 3.0; X_c *= 3.0; X_d *= 2.0;
217 }
else if ( ProjectilePDGcode == -3222 ) {
218 X_b *= 2.0; X_c *= 2.0; X_d *= 0.0;
219 }
else if ( ProjectilePDGcode == -3312 ) {
220 X_b *= 2.0; X_c *= 2.0; X_d *= 0.0;
221 }
else if ( ProjectilePDGcode == -3322 ) {
222 X_b *= 1.0; X_c *= 1.0; X_d *= 0.0;
223 }
else if ( ProjectilePDGcode == -3334 ) {
224 X_b *= 0.0; X_c *= 0.0; X_d *= 0.0;
232 G4cout <<
"Unknown anti-baryon for FTF annihilation: PDGcodes - "
233 << ProjectilePDGcode <<
" " << TargetPDGcode <<
G4endl;
236 G4cout <<
"Annih Actual X a b c d " << X_a <<
" " << X_b <<
" " << X_c <<
" " << X_d <<
G4endl;
239 G4double Xannihilation = X_a + X_b + X_c + X_d;
242 UnpackBaryon( ProjectilePDGcode, common.AQ[0], common.AQ[1], common.AQ[2] );
245 UnpackBaryon( TargetPDGcode, common.Q[0], common.Q[1], common.Q[2] );
249 if ( Ksi < X_a / Xannihilation ) {
250 return Create3QuarkAntiQuarkStrings( projectile, target, AdditionalString, theParameters, common );
253 G4int resultCode = 99;
254 if ( Ksi < (X_a + X_b) / Xannihilation ) {
255 resultCode = Create1DiquarkAntiDiquarkString( projectile, target, common );
256 if ( resultCode == 0 ) {
258 }
else if ( resultCode == 99 ) {
263 if ( Ksi < ( X_a + X_b + X_c ) / Xannihilation ) {
264 resultCode = Create2QuarkAntiQuarkStrings( projectile, target, theParameters, common );
265 if ( resultCode == 0 ) {
267 }
else if ( resultCode == 99 ) {
272 if ( Ksi < ( X_a + X_b + X_c + X_d ) / Xannihilation ) {
273 return Create1QuarkAntiQuarkString( projectile, target, theParameters, common );
286 G4FTFAnnihilation::CommonVariables& common )
const {
294 G4int SampledCase = G4RandFlat::shootInt(
G4long( 6 ) );
295 G4int Tmp1 = 0, Tmp2 = 0;
296 switch ( SampledCase ) {
297 case 1 : Tmp1 = common.AQ[1]; common.AQ[1] = common.AQ[2]; common.AQ[2] = Tmp1;
break;
298 case 2 : Tmp1 = common.AQ[0]; common.AQ[0] = common.AQ[1]; common.AQ[1] = Tmp1;
break;
299 case 3 : Tmp1 = common.AQ[0]; Tmp2 = common.AQ[1]; common.AQ[0] = common.AQ[2];
300 common.AQ[1] = Tmp1; common.AQ[2] = Tmp2;
break;
301 case 4 : Tmp1 = common.AQ[0]; Tmp2 = common.AQ[1]; common.AQ[0] = Tmp2;
302 common.AQ[1] = common.AQ[2]; common.AQ[2] = Tmp1;
break;
303 case 5 : Tmp1 = common.AQ[0]; Tmp2 = common.AQ[1]; common.AQ[0] = common.AQ[2];
304 common.AQ[1] = Tmp2; common.AQ[2] = Tmp1;
break;
311 G4int NewCode = 0, antiQuark = 0, quark = 0;
313 for (
G4int iString = 0; iString < 3; ++iString ) {
314 if ( iString == 0 ) {
315 antiQuark = common.AQ[0]; quark = common.Q[0];
320 }
else if ( iString == 1 ) {
321 quark = common.Q[1]; antiQuark = common.AQ[1];
327 antiQuark = common.AQ[2]; quark = common.Q[2];
329 G4int absAntiQuark = std::abs( antiQuark ), absQuark = std::abs( quark );
331 if ( absAntiQuark == absQuark ) {
332 if ( absAntiQuark != 3 ) {
347 if ( absAntiQuark > absQuark ) {
348 NewCode = absAntiQuark*100 + absQuark*10 + 1; NewCode *= absAntiQuark/antiQuark;
350 NewCode = absQuark*100 + absAntiQuark*10 + 1; NewCode *= absQuark/quark;
355 if ( ! TestParticle )
return false;
356 if ( iString == 0 ) {
360 }
else if ( iString == 1 ) {
378 G4double AveragePt2 = 200.0*200.0, maxPtSquare = common.S, SumMt = 0.0, MassQ2 = 0.0,
380 G4int NumberOfTries = 0, loopCounter = 0;
381 const G4int maxNumberOfLoops = 1000;
384 if ( NumberOfTries == 100*(NumberOfTries/100) ) {
387 AveragePt2 *= ScaleFactor;
390 for (
G4int i = 0; i < 6; ++i ) {
391 Quark_Mom [i] = GaussianPt( AveragePt2, maxPtSquare );
392 PtSum += Quark_Mom[i];
396 for (
G4int i = 0; i < 6; ++i ) {
397 Quark_Mom[i] -= PtSum;
398 ModMom2[i] = Quark_Mom[i].
mag2();
399 SumMt += std::sqrt( ModMom2[i] + MassQ2 );
401 }
while ( ( SumMt > common.SqrtS ) &&
402 ++loopCounter < maxNumberOfLoops );
403 if ( loopCounter >= maxNumberOfLoops ) {
408 G4double WminusTarget = 0.0, WplusProjectile = 0.0;
409 G4double Alfa_R = 0.5; ScaleFactor = 1.0;
411 NumberOfTries = 0; loopCounter = 0;
415 if ( NumberOfTries == 100*(NumberOfTries/100) ) {
420 for (
G4int iCase = 0; iCase < 2; ++iCase ) {
423 if ( Alfa_R == 1.0 ) {
424 x1 = 1.0 - std::sqrt( r1 );
425 x2 = (1.0 - x1) * r2;
428 x2 = (1.0 - x1) *
sqr( std::sin( pi/2.0*r2 ) );
431 G4int index = iCase*3;
432 Quark_Mom[index].
setZ( x1 ); Quark_Mom[index+1].
setZ( x2 ); Quark_Mom[index+2].
setZ( x3 );
433 for (
G4int i = 0; i < 3; ++i ) {
434 if ( Quark_Mom[index+i].getZ() != 0.0 ) {
435 G4double val = ( ScaleFactor * ModMom2[index+i] + MassQ2 ) / Quark_Mom[index+i].getZ();
446 if ( ! Success )
continue;
447 if ( std::sqrt( Alfa ) + std::sqrt( Beta ) > common.SqrtS ) {
452 - 2.0*( common.S*(Alfa + Beta) + Alfa*Beta );
453 WminusTarget = ( common.S - Alfa + Beta + std::sqrt( DecayMomentum2 ) ) / 2.0 / common.SqrtS;
454 WplusProjectile = common.SqrtS - Beta/WminusTarget;
455 }
while ( ( ! Success ) &&
456 ++loopCounter < maxNumberOfLoops );
457 if ( loopCounter >= maxNumberOfLoops ) {
461 G4double SqrtScaleF = std::sqrt( ScaleFactor );
462 for (
G4int iCase = 0; iCase < 2; ++iCase ) {
463 G4int index = iCase*3;
465 if ( iCase == 1 ) w = - WminusTarget;
466 for (
G4int i = 0; i < 3; ++i ) {
468 ( ScaleFactor * ModMom2[index+i] + MassQ2 ) /
469 ( 2.0 * w * Quark_Mom[index+i].getZ() );
470 Quark_Mom[index+i].
setZ( Pz );
471 if ( ScaleFactor != 1.0 ) {
472 Quark_Mom[index+i].
setX( SqrtScaleF * Quark_Mom[index+i].getX() );
473 Quark_Mom[index+i].
setY( SqrtScaleF * Quark_Mom[index+i].getY() );
478 G4double YstringMax = 0.0, YstringMin = 0.0;
479 for (
G4int i = 0; i < 3; ++i ) {
481 G4LorentzVector Pstring( tmp, std::sqrt( Quark_Mom[i].mag2() + MassQ2 ) +
482 std::sqrt( Quark_Mom[i+3].mag2() + MassQ2 ) );
486 if ( Pstring.e() > 1.0e-30 ) {
487 if ( Pstring.e() + Pstring.pz() < 1.0e-30 ) {
489 if ( Pstring.e() - Pstring.pz() < 1.0e-30 ) {
492 Ystring = Pstring.rapidity();
498 Pstring1 = Pstring; YstringMax = Ystring;
499 }
else if ( i == 1 ) {
500 if ( Ystring > YstringMax ) {
501 Pstring2 = Pstring1; YstringMin = YstringMax;
502 Pstring1 = Pstring; YstringMax = Ystring;
504 Pstring2 = Pstring; YstringMin = Ystring;
507 if ( Ystring > YstringMax ) {
511 }
else if ( Ystring > YstringMin ) {
519 common.Pprojectile = Pstring1;
520 common.Ptarget = Pstring3;
523 if ( common.RotateStrings ) {
524 common.Pprojectile *= common.RandomRotation;
525 LeftString *= common.RandomRotation;
526 common.Ptarget *= common.RandomRotation;
529 common.Pprojectile.transform( common.toLab );
530 LeftString.transform( common.toLab );
531 common.Ptarget.transform( common.toLab );
552G4int G4FTFAnnihilation::
555 G4FTFAnnihilation::CommonVariables& common )
const {
563 G4cout <<
"Process b, quark - anti-quark annihilation, di-q - anti-di-q string" <<
G4endl;
566 G4int CandidatsN = 0, CandAQ[9][2] = {}, CandQ[9][2] = {};
567 for (
G4int iAQ = 0; iAQ < 3; ++iAQ ) {
568 for (
G4int iQ = 0; iQ < 3; ++iQ ) {
569 if ( -common.AQ[iAQ] == common.Q[iQ] ) {
572 if ( iAQ == 0 ) { CandAQ[CandidatsN][0] = 1; CandAQ[CandidatsN][1] = 2; }
573 if ( iAQ == 1 ) { CandAQ[CandidatsN][0] = 0; CandAQ[CandidatsN][1] = 2; }
574 if ( iAQ == 2 ) { CandAQ[CandidatsN][0] = 0; CandAQ[CandidatsN][1] = 1; }
575 if ( iQ == 0 ) { CandQ[CandidatsN][0] = 1; CandQ[CandidatsN][1] = 2; }
576 if ( iQ == 1 ) { CandQ[CandidatsN][0] = 0; CandQ[CandidatsN][1] = 2; }
577 if ( iQ == 2 ) { CandQ[CandidatsN][0] = 0; CandQ[CandidatsN][1] = 1; }
584 G4int LeftAQ1 = 0, LeftAQ2 = 0, LeftQ1 = 0, LeftQ2 = 0;
585 if ( CandidatsN != 0 ) {
586 G4int SampledCase = G4RandFlat::shootInt(
G4long( CandidatsN ) );
587 LeftAQ1 = common.AQ[ CandAQ[SampledCase][0] ];
588 LeftAQ2 = common.AQ[ CandAQ[SampledCase][1] ];
589 LeftQ1 = common.Q[ CandQ[SampledCase][0] ];
590 LeftQ2 = common.Q[ CandQ[SampledCase][1] ];
595 G4int Anti_DQ = 0, DQ = 0;
596 if ( std::abs( LeftAQ1 ) > std::abs( LeftAQ2 ) ) {
597 Anti_DQ = 1000*LeftAQ1 + 100*LeftAQ2 - 3;
599 Anti_DQ = 1000*LeftAQ2 + 100*LeftAQ1 - 3;
601 if ( std::abs( LeftQ1 ) > std::abs( LeftQ2 ) ) {
602 DQ = 1000*LeftQ1 + 100*LeftQ2 + 3;
604 DQ = 1000*LeftQ2 + 100*LeftQ1 + 3;
612 if ( common.RotateStrings ) {
614 Pquark *= common.RandomRotation;
616 Paquark *= common.RandomRotation;
623 common.Pprojectile.setPx( 0.0 );
624 common.Pprojectile.setPy( 0.0 );
625 common.Pprojectile.setPz( 0.0 );
626 common.Pprojectile.setE( common.SqrtS );
627 common.Pprojectile.transform( common.toLab );
645G4int G4FTFAnnihilation::
649 G4FTFAnnihilation::CommonVariables& common )
const {
657 G4cout <<
"Process c, quark - anti-quark and string junctions annihilation, 2 strings left."
661 G4int CandidatsN = 0, CandAQ[9][2] = {}, CandQ[9][2] = {};
662 G4int LeftAQ1 = 0, LeftAQ2 = 0, LeftQ1 = 0, LeftQ2 = 0;
663 for (
G4int iAQ = 0; iAQ < 3; ++iAQ ) {
664 for (
G4int iQ = 0; iQ < 3; ++iQ ) {
665 if ( -common.AQ[iAQ] == common.Q[iQ] ) {
668 if ( iAQ == 0 ) { CandAQ[CandidatsN][0] = 1; CandAQ[CandidatsN][1] = 2; }
669 if ( iAQ == 1 ) { CandAQ[CandidatsN][0] = 0; CandAQ[CandidatsN][1] = 2; }
670 if ( iAQ == 2 ) { CandAQ[CandidatsN][0] = 0; CandAQ[CandidatsN][1] = 1; }
671 if ( iQ == 0 ) { CandQ[CandidatsN][0] = 1; CandQ[CandidatsN][1] = 2; }
672 if ( iQ == 1 ) { CandQ[CandidatsN][0] = 0; CandQ[CandidatsN][1] = 2; }
673 if ( iQ == 2 ) { CandQ[CandidatsN][0] = 0; CandQ[CandidatsN][1] = 1; }
679 if ( CandidatsN != 0 ) {
680 G4int SampledCase = G4RandFlat::shootInt(
G4long( CandidatsN ) );
681 LeftAQ1 = common.AQ[ CandAQ[SampledCase][0] ];
682 LeftAQ2 = common.AQ[ CandAQ[SampledCase][1] ];
684 LeftQ1 = common.Q[ CandQ[SampledCase][0] ];
685 LeftQ2 = common.Q[ CandQ[SampledCase][1] ];
687 LeftQ2 = common.Q[ CandQ[SampledCase][0] ];
688 LeftQ1 = common.Q[ CandQ[SampledCase][1] ];
695 G4int NewCode = 0, antiQuark = 0, quark = 0;
697 for (
G4int iString = 0; iString < 2; ++iString ) {
698 if ( iString == 0 ) {
699 antiQuark = LeftAQ1; quark = LeftQ1;
705 quark = LeftQ2; antiQuark = LeftAQ2;
711 G4int absAntiQuark = std::abs( antiQuark ), absQuark = std::abs( quark );
713 if ( absAntiQuark == absQuark ) {
714 if ( absAntiQuark != 3 ) {
729 if ( absAntiQuark > absQuark ) {
730 NewCode = absAntiQuark*100 + absQuark*10 + 1; NewCode *= absAntiQuark/antiQuark;
732 NewCode = absQuark*100 + absAntiQuark*10 + 1; NewCode *= absQuark/quark;
736 if ( ! TestParticle )
return 99;
737 if ( iString == 0 ) {
751 G4double AveragePt2 = 200.0*200.0, maxPtSquare = common.S, SumMt = 0.0, MassQ2 = 0.0,
753 G4int NumberOfTries = 0, loopCounter = 0;
754 const G4int maxNumberOfLoops = 1000;
757 if ( NumberOfTries == 100*(NumberOfTries/100) ) {
760 AveragePt2 *= ScaleFactor;
763 for(
G4int i = 0; i < 4; ++i ) {
764 Quark_Mom[i] = GaussianPt( AveragePt2, maxPtSquare );
765 PtSum += Quark_Mom[i];
769 for (
G4int i = 0; i < 4; ++i ) {
770 Quark_Mom[i] -= PtSum;
771 ModMom2[i] = Quark_Mom[i].
mag2();
772 SumMt += std::sqrt( ModMom2[i] + MassQ2 );
774 }
while ( ( SumMt > common.SqrtS ) &&
775 ++loopCounter < maxNumberOfLoops );
776 if ( loopCounter >= maxNumberOfLoops ) {
781 G4double WminusTarget = 0.0, WplusProjectile = 0.0, Alfa_R = 0.5; ScaleFactor = 1.0;
783 NumberOfTries = 0, loopCounter = 0;
787 if ( NumberOfTries == 100*(NumberOfTries/100) ) {
792 for (
G4int iCase = 0; iCase < 2; ++iCase ) {
794 if ( Alfa_R == 1.0 ) {
798 x = 1.0 - std::sqrt( r);
801 x =
sqr( std::sin( pi/2.0*r ) );
803 G4int index = iCase*2;
804 Quark_Mom[index].
setZ( x ); Quark_Mom[index+1].
setZ( 1.0 - x );
805 for (
G4int i = 0; i < 2; ++i ) {
806 if ( Quark_Mom[i].getZ() != 0.0 ) {
807 G4double val = ( ScaleFactor * ModMom2[index+i] + MassQ2 ) / Quark_Mom[index+i].getZ();
818 if ( ! Success )
continue;
819 if ( std::sqrt( Alfa ) + std::sqrt( Beta ) > common.SqrtS ) {
824 - 2.0*( common.S*(Alfa + Beta) + Alfa*Beta );
825 WminusTarget = ( common.S - Alfa + Beta + std::sqrt( DecayMomentum2 ) ) / 2.0 / common.SqrtS;
826 WplusProjectile = common.SqrtS - Beta/WminusTarget;
827 }
while ( ( ! Success ) &&
828 ++loopCounter < maxNumberOfLoops );
829 if ( loopCounter >= maxNumberOfLoops ) {
833 G4double SqrtScaleF = std::sqrt( ScaleFactor );
835 G4double Ystring1 = 0.0, Ystring2 = 0.0;
836 for (
G4int iCase = 0; iCase < 2; ++iCase ) {
837 G4int index = iCase*2;
838 for (
G4int i = 0; i < 2; ++i ) {
840 if ( iCase == 1 ) w = - WminusTarget;
842 - ( ScaleFactor * ModMom2[index+i] + MassQ2 ) /
843 ( 2.0 * w * Quark_Mom[index+i].getZ() );
844 Quark_Mom[index+i].
setZ( Pz );
845 if ( ScaleFactor != 1.0 ) {
846 Quark_Mom[index+i].
setX( SqrtScaleF * Quark_Mom[index+i].getX() );
847 Quark_Mom[index+i].
setY( SqrtScaleF * Quark_Mom[index+i].getY() );
851 for (
G4int iCase = 0; iCase < 2; ++iCase ) {
853 G4LorentzVector Pstring( tmp, std::sqrt( Quark_Mom[iCase].mag2() + MassQ2 ) +
854 std::sqrt( Quark_Mom[iCase+2].mag2() + MassQ2 ) );
858 if ( Pstring.e() > 1.0e-30 ) {
859 if ( Pstring.e() + Pstring.pz() < 1.0e-30 ) {
861 if ( Pstring.e() - Pstring.pz() < 1.0e-30 ) {
864 Ystring = Pstring.rapidity();
869 Pstring1 = Pstring; Ystring1 = Ystring;
871 Pstring2 = Pstring; Ystring2 = Ystring;
874 if ( Ystring1 > Ystring2 ) {
875 common.Pprojectile = Pstring1; common.Ptarget = Pstring2;
877 common.Pprojectile = Pstring2; common.Ptarget = Pstring1;
880 if ( common.RotateStrings ) {
881 common.Pprojectile *= common.RandomRotation;
882 common.Ptarget *= common.RandomRotation;
885 common.Pprojectile.
transform( common.toLab );
886 common.Ptarget.
transform( common.toLab );
909 G4FTFAnnihilation::CommonVariables& common )
const {
913 G4cout <<
"Process d, only 1 quark - anti-quark string" <<
G4endl;
919 G4int CandidatsN = 0, CandAQ[36], CandQ[36];
920 G4int LeftAQ = 0, LeftQ = 0;
921 for (
G4int iAQ1 = 0; iAQ1 < 3; ++iAQ1 ) {
922 for (
G4int iAQ2 = 0; iAQ2 < 3; ++iAQ2 ) {
923 if ( iAQ1 != iAQ2 ) {
924 for (
G4int iQ1 = 0; iQ1 < 3; ++iQ1 ) {
925 for (
G4int iQ2 = 0; iQ2 < 3; ++iQ2 ) {
927 if ( -common.AQ[iAQ1] == common.Q[iQ1] && -common.AQ[iAQ2] == common.Q[iQ2] ) {
928 if ( ( iAQ1 == 0 && iAQ2 == 1 ) || ( iAQ1 == 1 && iAQ2 == 0 ) ) {
929 CandAQ[CandidatsN] = 2;
930 }
else if ( ( iAQ1 == 0 && iAQ2 == 2 ) || ( iAQ1 == 2 && iAQ2 == 0 ) ) {
931 CandAQ[CandidatsN] = 1;
932 }
else if ( ( iAQ1 == 1 && iAQ2 == 2 ) || ( iAQ1 == 2 && iAQ2 == 1 ) ) {
933 CandAQ[CandidatsN] = 0;
935 if ( ( iQ1 == 0 && iQ2 == 1 ) || ( iQ1 == 1 && iQ2 == 0 ) ) {
936 CandQ[CandidatsN] = 2;
937 }
else if ( ( iQ1 == 0 && iQ2 == 2 ) || ( iQ1 == 2 && iQ2 == 0 ) ) {
938 CandQ[CandidatsN] = 1;
939 }
else if ( ( iQ1 == 1 && iQ2 == 2 ) || ( iQ1 == 2 && iQ2 == 1 ) ) {
940 CandQ[CandidatsN] = 0;
951 if ( CandidatsN != 0 ) {
952 G4int SampledCase = G4RandFlat::shootInt(
G4long( CandidatsN ) );
953 LeftAQ = common.AQ[ CandAQ[SampledCase] ];
954 LeftQ = common.Q[ CandQ[SampledCase] ];
961 G4int aAQ = std::abs( LeftAQ ), aQ = std::abs( LeftQ );
983 NewCode = aAQ*100 + aQ*10 + 1; NewCode *= aAQ/LeftAQ;
985 NewCode = aQ*100 + aAQ*10 + 1; NewCode *= aQ/LeftQ;
990 if ( ! TestParticle )
return false;
996 common.Pprojectile.setPx( 0.0 );
997 common.Pprojectile.setPy( 0.0 );
998 common.Pprojectile.setPz( 0.0 );
999 common.Pprojectile.setE( common.SqrtS );
1000 common.Pprojectile.transform( common.toLab );
1004 if ( common.RotateStrings ) {
1005 Pquark *= common.RandomRotation; Paquark *= common.RandomRotation;
1041 if ( AveragePt2 <= 0.0 ) {
1045 (
G4Exp( -maxPtSquare/AveragePt2 ) -1.0 ) );
1049 return G4ThreeVector ( Pt*std::cos( phi ), Pt*std::sin( phi ), 0.0 );
1056 G4int AbsId = std::abs( IdPDG );
1058 Q2 = ( AbsId % 1000 ) / 100;
1059 Q3 = ( AbsId % 100 ) / 10;
1060 if ( IdPDG < 0 ) { Q1 = -Q1; Q2 = -Q2; Q3 = -Q3; }
1069 "G4FTFAnnihilation copy constructor not meant to be called" );
1077 "G4FTFAnnihilation = operator not meant to be called" );
1085 "G4FTFAnnihilation == operator not meant to be called" );
1093 "G4DiffractiveExcitation != operator not meant to be called" );
G4double G4Exp(G4double initial_x)
Exponential Function double precision.
G4double G4Log(G4double x)
CLHEP::HepLorentzVector G4LorentzVector
CLHEP::Hep3Vector G4ThreeVector
G4GLOB_DLL std::ostream G4cout
HepLorentzRotation & rotateY(double delta)
HepLorentzRotation & rotateZ(double delta)
HepLorentzRotation inverse() const
Hep3Vector boostVector() const
HepLorentzVector & transform(const HepRotation &)
virtual ~G4FTFAnnihilation()
virtual G4bool Annihilate(G4VSplitableHadron *aPartner, G4VSplitableHadron *bPartner, G4VSplitableHadron *&AdditionalString, G4FTFParameters *theParameters) const
void SetTarMinNonDiffMass(const G4double aValue)
void SetProjMinDiffMass(const G4double aValue)
void SetTarMinDiffMass(const G4double aValue)
void SetProjMinNonDiffMass(const G4double aValue)
G4double GetPDGMass() const
G4int GetPDGEncoding() const
G4ParticleDefinition * FindParticle(G4int PDGEncoding)
static G4ParticleTable * GetParticleTable()
void Set4Momentum(const G4LorentzVector &aMomentum)
static G4Pow * GetInstance()
G4double powA(G4double A, G4double y) const
void SetTimeOfCreation(G4double aTime)
void SetStatus(const G4int aStatus)
const G4ParticleDefinition * GetDefinition() const
G4double GetTimeOfCreation()
void Set4Momentum(const G4LorentzVector &a4Momentum)
virtual G4Parton * GetNextParton()=0
virtual void SetSecondParton(G4int PDGcode)=0
virtual G4Parton * GetNextAntiParton()=0
void SetDefinition(const G4ParticleDefinition *aDefinition)
const G4LorentzVector & Get4Momentum() const
const G4ThreeVector & GetPosition() const
void IncrementCollisionCount(G4int aCount)
virtual void SetFirstParton(G4int PDGcode)=0
void SetPosition(const G4ThreeVector &aPosition)