51 G4cout <<
"WARNING: model G4HELambdaInelastic is being deprecated and will\n"
52 <<
"disappear in Geant4 version 10.0" <<
G4endl;
58 outFile <<
"G4HELambdaInelastic is one of the High Energy Parameterized\n"
59 <<
"(HEP) models used to implement inelastic Lambda scattering\n"
60 <<
"from nuclei. It is a re-engineered version of the GHEISHA\n"
61 <<
"code of H. Fesefeldt. It divides the initial collision\n"
62 <<
"products into backward- and forward-going clusters which are\n"
63 <<
"then decayed into final state hadrons. The model does not\n"
64 <<
"conserve energy on an event-by-event basis. It may be\n"
65 <<
"applied to lambdas with initial energies above 20 GeV.\n";
89 G4double incidentKineticEnergy = incidentTotalEnergy - incidentMass;
91 if (incidentKineticEnergy < 1.)
92 G4cout <<
"GHELambdaInelastic: incident energy < 1 GeV" <<
G4endl;
95 G4cout <<
"G4HELambdaInelastic::ApplyYourself" <<
G4endl;
97 <<
"mass " << incidentMass
98 <<
"kinetic energy " << incidentKineticEnergy
100 G4cout <<
"target material with (A,Z) = ("
101 << atomicWeight <<
"," << atomicNumber <<
")" <<
G4endl;
105 atomicWeight, atomicNumber);
107 G4cout <<
"nuclear inelasticity = " << inelasticity <<
G4endl;
109 incidentKineticEnergy -= inelasticity;
115 atomicWeight, atomicNumber,
117 excitationEnergyDTA);
119 G4cout <<
"nuclear excitation = " << excitation << excitationEnergyGNP
120 << excitationEnergyDTA <<
G4endl;
122 incidentKineticEnergy -= excitation;
123 incidentTotalEnergy = incidentKineticEnergy + incidentMass;
136 G4double centerOfMassEnergy = std::sqrt(incidentMass*incidentMass
137 + targetMass*targetMass
138 + 2.0*targetMass*incidentTotalEnergy);
139 G4double availableEnergy = centerOfMassEnergy - targetMass - incidentMass;
145 G4cout <<
"ApplyYourself: CallFirstIntInCascade for particle "
146 << incidentCode <<
G4endl;
148 G4bool successful =
false;
151 incidentParticle, targetParticle, atomicWeight);
154 G4cout <<
"ApplyYourself::StrangeParticlePairProduction" <<
G4endl;
156 if ((
vecLength > 0) && (availableEnergy > 1.))
159 incidentParticle, targetParticle);
162 excitationEnergyGNP, excitationEnergyDTA,
163 incidentParticle, targetParticle,
164 atomicWeight, atomicNumber);
167 excitationEnergyGNP, excitationEnergyDTA,
168 incidentParticle, targetParticle,
169 atomicWeight, atomicNumber);
172 excitationEnergyGNP, excitationEnergyDTA,
173 incidentParticle, targetParticle,
174 atomicWeight, atomicNumber);
178 excitationEnergyGNP, excitationEnergyDTA,
179 incidentParticle, targetParticle,
180 atomicWeight, atomicNumber);
183 excitationEnergyGNP, excitationEnergyDTA,
184 incidentParticle, targetParticle,
185 atomicWeight, atomicNumber);
189 atomicWeight, atomicNumber);
192 G4cout <<
"GHEInelasticInteraction::ApplyYourself fails to produce final state particles"
219 static const G4double expxl = -expxu;
225 static const G4int numMul = 1200;
226 static const G4int numSec = 60;
232 static G4bool first =
true;
233 static G4double protmul[numMul], protnorm[numSec];
234 static G4double neutmul[numMul], neutnorm[numSec];
239 G4int i, counter, nt, npos, nneg, nzero;
243 for( i=0; i<numMul; i++ )protmul[i] = 0.0;
244 for( i=0; i<numSec; i++ )protnorm[i] = 0.0;
246 for (npos = 0; npos < (numSec/3); npos++) {
247 for (nneg = std::max(0,npos-2); nneg <= (npos+1); nneg++) {
248 for (nzero = 0; nzero < numSec/3; nzero++) {
249 if (++counter < numMul) {
250 nt = npos+nneg+nzero;
251 if ((nt>0) && (nt<=numSec) ) {
252 protmul[counter] =
pmltpc(npos,nneg,nzero,nt,protb,c);
253 protnorm[nt-1] += protmul[counter];
260 for( i=0; i<numMul; i++ )neutmul[i] = 0.0;
261 for( i=0; i<numSec; i++ )neutnorm[i] = 0.0;
263 for (npos = 0; npos < numSec/3; npos++) {
264 for( nneg=std::max(0,npos-1); nneg<=(npos+2); nneg++ )
266 for( nzero=0; nzero<numSec/3; nzero++ )
268 if( ++counter < numMul )
270 nt = npos+nneg+nzero;
271 if( (nt>0) && (nt<=numSec) )
273 neutmul[counter] =
pmltpc(npos,nneg,nzero,nt,neutb,c);
274 neutnorm[nt-1] += neutmul[counter];
280 for( i=0; i<numSec; i++ )
282 if( protnorm[i] > 0.0 )protnorm[i] = 1.0/protnorm[i];
283 if( neutnorm[i] > 0.0 )neutnorm[i] = 1.0/neutnorm[i];
287 pv[0] = incidentParticle;
288 pv[1] = targetParticle;
292 G4double cech[] = {0.50, 0.45, 0.40, 0.35, 0.30, 0.25, 0.06, 0.04, 0.005, 0.};
293 G4int iplab =
G4int( std::min( 9.0, incidentTotalMomentum*2.5 ) );
294 if (
G4UniformRand() < cech[iplab]/std::pow(atomicWeight,0.42) ) {
296 if (targetCode == protonCode) {
354 npos = 0; nneg = 0; nzero = 0;
358 G4double aleab = std::log(availableEnergy);
359 G4double n = 3.62567+aleab*(0.665843+aleab*(0.336514
360 + aleab*(0.117712+0.0136912*aleab))) - 2.0;
366 for (nt=1; nt<=numSec; nt++) {
367 test = std::exp( std::min( expxu, std::max( expxl, -(pi/4.0)*(nt*nt)/(n*n) ) ) );
368 dum = pi*nt/(2.0*n*n);
369 if (std::fabs(dum) < 1.0) {
370 if( test >= 1.0e-10 )anpn += dum*test;
378 if (targetCode == protonCode) {
380 for (npos = 0; npos < numSec/3; npos++) {
381 for (nneg=std::max(0,npos-2); nneg<=(npos+1); nneg++) {
382 for (nzero=0; nzero<numSec/3; nzero++) {
383 if (++counter < numMul) {
384 nt = npos+nneg+nzero;
385 if ( (nt>0) && (nt<=numSec) ) {
386 test = std::exp( std::min( expxu, std::max( expxl, -(pi/4.0)*(nt*nt)/(n*n) ) ) );
387 dum = (pi/anpn)*nt*protmul[counter]*protnorm[nt-1]/(2.0*n*n);
388 if (std::fabs(dum) < 1.0) {
389 if( test >= 1.0e-10 )excs += dum*test;
393 if (ran < excs)
goto outOfLoop;
406 for (npos=0; npos<numSec/3; npos++) {
407 for (nneg=std::max(0,npos-1); nneg<=(npos+2); nneg++) {
408 for (nzero=0; nzero<numSec/3; nzero++) {
409 if (++counter < numMul) {
410 nt = npos+nneg+nzero;
411 if ( (nt>=1) && (nt<=numSec) ) {
412 test = std::exp( std::min( expxu, std::max( expxl, -(pi/4.0)*(nt*nt)/(n*n) ) ) );
413 dum = (pi/anpn)*nt*neutmul[counter]*neutnorm[nt-1]/(2.0*n*n);
414 if (std::fabs(dum) < 1.0) {
415 if( test >= 1.0e-10 )excs += dum*test;
419 if (ran < excs)
goto outOfLoop;
433 if (targetCode == protonCode) {
447 }
else if (npos == (nneg+1)) {
461 }
else if (npos == (nneg-1)) {
478 }
else if (npos == (nneg-1)) {
492 }
else if (npos == (1+nneg)) {
500 nt = npos + nneg + nzero;
508 }
else if (rnd < (
G4double)(npos+nneg)/nt) {
519 nt = npos + nneg + nzero;
523 G4cout <<
"Particles produced: " ;
526 for (i = 2; i < vecLen; i++)
G4cout << pv[i].getName() <<
" " ;
G4DLLIMPORT std::ostream G4cout
G4double pmltpc(G4int np, G4int nm, G4int nz, G4int n, G4double b, G4double c)
void MediumEnergyClusterProduction(G4bool &successful, G4HEVector pv[], G4int &vecLen, G4double &excitationEnergyGNP, G4double &excitationEnergyDTA, const G4HEVector &incidentParticle, const G4HEVector &targetParticle, G4double atomicWeight, G4double atomicNumber)
void ElasticScattering(G4bool &successful, G4HEVector pv[], G4int &vecLen, const G4HEVector &incidentParticle, G4double atomicWeight, G4double atomicNumber)
void QuasiElasticScattering(G4bool &successful, G4HEVector pv[], G4int &vecLen, G4double &excitationEnergyGNP, G4double &excitationEnergyDTA, const G4HEVector &incidentParticle, const G4HEVector &targetParticle, G4double atomicWeight, G4double atomicNumber)
void FillParticleChange(G4HEVector pv[], G4int aVecLength)
void HighEnergyClusterProduction(G4bool &successful, G4HEVector pv[], G4int &vecLen, G4double &excitationEnergyGNP, G4double &excitationEnergyDTA, const G4HEVector &incidentParticle, const G4HEVector &targetParticle, G4double atomicWeight, G4double atomicNumber)
G4double NuclearExcitation(G4double incidentKineticEnergy, G4double atomicWeight, G4double atomicNumber, G4double &excitationEnergyCascade, G4double &excitationEnergyEvaporation)
void MediumEnergyCascading(G4bool &successful, G4HEVector pv[], G4int &vecLen, G4double &excitationEnergyGNP, G4double &excitationEnergyDTA, const G4HEVector &incidentParticle, const G4HEVector &targetParticle, G4double atomicWeight, G4double atomicNumber)
G4double NuclearInelasticity(G4double incidentKineticEnergy, G4double atomicWeight, G4double atomicNumber)
void StrangeParticlePairProduction(const G4double availableEnergy, const G4double centerOfMassEnergy, G4HEVector pv[], G4int &vecLen, const G4HEVector &incidentParticle, const G4HEVector &targetParticle)
void HighEnergyCascading(G4bool &successful, G4HEVector pv[], G4int &vecLen, G4double &excitationEnergyGNP, G4double &excitationEnergyDTA, const G4HEVector &incidentParticle, const G4HEVector &targetParticle, G4double atomicWeight, G4double atomicNumber)
G4HELambdaInelastic(const G4String &name="G4HELambdaInelastic")
virtual void ModelDescription(std::ostream &) const
void FirstIntInCasLambda(G4bool &inElastic, const G4double availableEnergy, G4HEVector pv[], G4int &vecLen, const G4HEVector &incidentParticle, const G4HEVector &targetParticle, const G4double atomicWeight)
G4HadFinalState * ApplyYourself(const G4HadProjectile &aTrack, G4Nucleus &targetNucleus)
G4double getEnergy() const
G4double getTotalMomentum() const
void setDefinition(G4String name)
void SetStatusChange(G4HadFinalStateStatus aS)
G4HadFinalState theParticleChange