56     G4cout << 
"G4RPGKMinusInelastic::ApplyYourself called" << 
G4endl;
 
   58     G4cout << 
"target material = " << targetMaterial->
GetName() << 
", ";
 
   75   currentParticle.SetKineticEnergy( ek );
 
   77   G4double p = std::sqrt( std::abs((et-amas)*(et+amas)) );
 
   78   G4double pp = currentParticle.GetMomentum().mag();
 
   82     currentParticle.SetMomentum( momentum * (p/pp) );
 
   89   currentParticle.SetKineticEnergy( ek );
 
   91   p = std::sqrt( std::abs((et-amas)*(et+amas)) );
 
   92   pp = currentParticle.GetMomentum().mag();
 
   96     currentParticle.SetMomentum( momentum * (p/pp) );
 
  102   targetParticle.SetSide( -1 );  
 
  103   G4bool incidentHasChanged = 
false;
 
  104   G4bool targetHasChanged = 
false;
 
  105   G4bool quasiElastic = 
false;
 
  111   if( currentParticle.GetKineticEnergy() > cutOff )
 
  112     Cascade( vec, vecLen,
 
  113              originalIncident, currentParticle, targetParticle,
 
  114              incidentHasChanged, targetHasChanged, quasiElastic );
 
  117                     originalIncident, originalTarget, modifiedOriginal,
 
  118                     targetNucleus, currentParticle, targetParticle,
 
  119                     incidentHasChanged, targetHasChanged, quasiElastic );
 
  122                currentParticle, targetParticle,
 
  123                incidentHasChanged );
 
  125   delete originalTarget;
 
  130 void G4RPGKMinusInelastic::Cascade(
 
  136    G4bool &incidentHasChanged,
 
  154     G4double centerofmassEnergy = std::sqrt( mOriginal*mOriginal +
 
  155                                         targetMass*targetMass +
 
  156                                         2.0*targetMass*etOriginal );
 
  157     G4double availableEnergy = centerofmassEnergy-(targetMass+mOriginal);
 
  160     const G4int numMul = 1200;
 
  161     const G4int numSec = 60;
 
  165     G4int nt(0), np(0), nneg(0), nz(0);
 
  172       for( i=0; i<numMul; ++i )protmul[i] = 0.0;
 
  173       for( i=0; i<numSec; ++i )protnorm[i] = 0.0;
 
  175       for( np=0; np<(numSec/3); ++np )
 
  177         for( nneg=
std::max(0,np-1); nneg<=(np+1); ++nneg )
 
  179           for( nz=0; nz<numSec/3; ++nz )
 
  181             if( ++counter < numMul )
 
  184               if( (nt>0) && (nt<=numSec) )
 
  186                 protmul[counter] = 
Pmltpc(np,nneg,nz,nt,b[0],c);
 
  187                 protnorm[nt-1] += protmul[counter];
 
  193       for( i=0; i<numMul; ++i )neutmul[i] = 0.0;
 
  194       for( i=0; i<numSec; ++i )neutnorm[i] = 0.0;
 
  196       for( np=0; np<numSec/3; ++np )
 
  198         for( nneg=np; nneg<=(np+2); ++nneg )
 
  200           for( nz=0; nz<numSec/3; ++nz )
 
  202             if( ++counter < numMul )
 
  205               if( (nt>0) && (nt<=numSec) )
 
  207                 neutmul[counter] = 
Pmltpc(np,nneg,nz,nt,b[1],c);
 
  208                 neutnorm[nt-1] += neutmul[counter];
 
  214       for( i=0; i<numSec; ++i )
 
  216         if( protnorm[i] > 0.0 )protnorm[i] = 1.0/protnorm[i];
 
  217         if( neutnorm[i] > 0.0 )neutnorm[i] = 1.0/neutnorm[i];
 
  235     const G4double cech[] = {1.,1.,1.,0.70,0.60,0.55,0.35,0.25,0.18,0.15};
 
  239       np = nneg = nz = nt = 0;
 
  241       const G4double cnk0[] = {0.17,0.18,0.17,0.24,0.26,0.20,0.22,0.21,0.34,0.45,
 
  242                                0.58,0.55,0.36,0.29,0.29,0.32,0.32,0.33,0.33,0.33};
 
  249           incidentHasChanged = 
true;
 
  251           targetHasChanged = 
true;
 
  263             incidentHasChanged = 
true;
 
  264             targetHasChanged = 
true;
 
  267         else if( ran < 0.50 )  
 
  274           incidentHasChanged = 
true;
 
  275           targetHasChanged = 
true;
 
  277         else if( ran < 0.75 )  
 
  284           incidentHasChanged = 
true;
 
  285           targetHasChanged = 
true;
 
  294           incidentHasChanged = 
true;
 
  295           targetHasChanged = 
true;
 
  301       if( availableEnergy < aPiPlus->GetPDGMass() )
 
  313         for( np=0; np<numSec/3 && ran>=excs; ++np )
 
  315           for( nneg=
std::max(0,np-1); nneg<=(np+1) && ran>=excs; ++nneg )
 
  317             for( nz=0; nz<numSec/3 && ran>=excs; ++nz )
 
  319               if( ++counter < numMul )
 
  325                   dum = (
pi/anpn)*nt*protmul[counter]*protnorm[nt-1]/(2.0*n*n);
 
  326                   if( std::fabs(dum) < 1.0 )
 
  328                     if( test >= 1.0e-10 )excs += dum*
test;
 
  349             incidentHasChanged = 
true;
 
  350             targetHasChanged = 
true;
 
  353         else if( np == nneg+1 )
 
  356           targetHasChanged = 
true;
 
  361           incidentHasChanged = 
true;
 
  367         for( np=0; np<numSec/3 && ran>=excs; ++np )
 
  369           for( nneg=np; nneg<=(np+2) && ran>=excs; ++nneg )
 
  371             for( nz=0; nz<numSec/3 && ran>=excs; ++nz )
 
  373               if( ++counter < numMul )
 
  376                 if( (nt>=1) && (nt<=numSec) )
 
  379                   dum = (
pi/anpn)*nt*neutmul[counter]*neutnorm[nt-1]/(2.0*n*n);
 
  380                   if( std::fabs(dum) < 1.0 )
 
  382                     if( test >= 1.0e-10 )excs += dum*
test;
 
  402             targetHasChanged = 
true;
 
  407             incidentHasChanged = 
true;
 
  410         else if( np != nneg )
 
  413           incidentHasChanged = 
true;
 
  430               incidentHasChanged = 
true;
 
  431               targetHasChanged = 
true;
 
  437               incidentHasChanged = 
true;
 
  438               targetHasChanged = 
true;
 
  441           else if( ran < 0.84 )
 
  447               incidentHasChanged = 
true;
 
  448               targetHasChanged = 
true;
 
  454               incidentHasChanged = 
true;
 
  455               targetHasChanged = 
true;
 
  464               incidentHasChanged = 
true;
 
  465               targetHasChanged = 
true;
 
  471               incidentHasChanged = 
true;
 
  472               targetHasChanged = 
true;
 
  484             incidentHasChanged = 
true;
 
  485             targetHasChanged = 
true;
 
  487           else if( ran < 0.78 )
 
  491             incidentHasChanged = 
true;
 
  492             targetHasChanged = 
true;
 
  494           else if( ran < 0.89 )
 
  498             incidentHasChanged = 
true;
 
  499             targetHasChanged = 
true;
 
  505             incidentHasChanged = 
true;
 
  506             targetHasChanged = 
true;
 
  515       incidentHasChanged = 
true;
 
  522       targetHasChanged = 
true;
 
G4double EvaporationEffects(G4double kineticEnergy)
 
G4HadFinalState * ApplyYourself(const G4HadProjectile &aTrack, G4Nucleus &targetNucleus)
 
void SetUpChange(G4FastVector< G4ReactionProduct, 256 > &vec, G4int &vecLen, G4ReactionProduct ¤tParticle, G4ReactionProduct &targetParticle, G4bool &incidentHasChanged)
 
void SetMomentum(const G4double x, const G4double y, const G4double z)
 
const G4String & GetName() const 
 
static G4KaonZeroLong * KaonZeroLong()
 
void SetSide(const G4int sid)
 
void CalculateMomenta(G4FastVector< G4ReactionProduct, 256 > &vec, G4int &vecLen, const G4HadProjectile *originalIncident, const G4DynamicParticle *originalTarget, G4ReactionProduct &modifiedOriginal, G4Nucleus &targetNucleus, G4ReactionProduct ¤tParticle, G4ReactionProduct &targetParticle, G4bool &incidentHasChanged, G4bool &targetHasChanged, G4bool quasiElastic)
 
G4ParticleDefinition * GetDefinition() const 
 
void Initialize(G4int items)
 
G4DynamicParticle * ReturnTargetParticle() const 
 
const G4String & GetParticleName() const 
 
static G4SigmaZero * SigmaZero()
 
static G4KaonMinus * KaonMinus()
 
void SetStatusChange(G4HadFinalStateStatus aS)
 
G4double Pmltpc(G4int np, G4int nm, G4int nz, G4int n, G4double b, G4double c)
 
const G4ParticleDefinition * GetDefinition() const 
 
G4GLOB_DLL std::ostream G4cout
 
const G4ParticleDefinition * GetDefinition() const 
 
static G4KaonZeroShort * KaonZeroShort()
 
G4double GetKineticEnergy() const 
 
static G4Proton * Proton()
 
static G4PionPlus * PionPlus()
 
void SetDefinitionAndUpdateE(const G4ParticleDefinition *aParticleDefinition)
 
static G4Neutron * Neutron()
 
const G4LorentzVector & Get4Momentum() const 
 
static G4PionZero * PionZero()
 
static G4SigmaMinus * SigmaMinus()
 
G4double G4Exp(G4double initial_x)
Exponential Function double precision. 
 
void SetEnergyChange(G4double anEnergy)
 
G4double GetPDGMass() const 
 
T max(const T t1, const T t2)
brief Return the largest of the two arguments 
 
G4double Cinema(G4double kineticEnergy)
 
static G4PionMinus * PionMinus()
 
T min(const T t1, const T t2)
brief Return the smallest of the two arguments 
 
static constexpr double GeV
 
G4HadFinalState theParticleChange
 
static constexpr double MeV
 
const G4Material * GetMaterial() const 
 
static constexpr double pi
 
static G4SigmaPlus * SigmaPlus()
 
void GetNormalizationConstant(const G4double availableEnergy, G4double &n, G4double &anpn)
 
static G4Lambda * Lambda()
 
void SetUpPions(const G4int np, const G4int nm, const G4int nz, G4FastVector< G4ReactionProduct, 256 > &vec, G4int &vecLen)
 
void SetMomentumChange(const G4ThreeVector &aV)
 
G4double GetTotalMomentum() const 
 
G4double GetTotalEnergy() const