39 outFile <<
"G4LEAntiSigmaPlusInelastic is one of the Low Energy\n"
40 <<
"Parameterized (LEP) models used to implement inelastic\n"
41 <<
"antiSigma+ scattering from nuclei. It is a re-engineered\n"
42 <<
"version of the GHEISHA code of H. Fesefeldt. It divides the\n"
43 <<
"initial collision products into backward- and forward-going\n"
44 <<
"clusters which are then decayed into final state hadrons. The\n"
45 <<
"model does not conserve energy on an event-by-event basis. It\n"
46 <<
"may be applied to antiSigma+ with initial energies between 0\n"
68 G4cout <<
"G4LEAntiSigmaPlusInelastic::ApplyYourself called" <<
G4endl;
70 G4cout <<
"target material = " << targetMaterial->
GetName() <<
", ";
80 modifiedOriginal = *originalIncident;
86 G4double p = std::sqrt( std::abs((et-amas)*(et+amas)) );
98 p = std::sqrt( std::abs((et-amas)*(et+amas)) );
106 targetParticle = *originalTarget;
109 G4bool incidentHasChanged =
false;
110 G4bool targetHasChanged =
false;
111 G4bool quasiElastic =
false;
120 Cascade(vec, vecLen, originalIncident, currentParticle, targetParticle,
121 incidentHasChanged, targetHasChanged, quasiElastic);
124 modifiedOriginal, targetNucleus, currentParticle,
125 targetParticle, incidentHasChanged, targetHasChanged,
128 SetUpChange(vec, vecLen, currentParticle, targetParticle, incidentHasChanged);
132 delete originalTarget;
136void G4LEAntiSigmaPlusInelastic::Cascade(
142 G4bool &incidentHasChanged,
160 G4double centerofmassEnergy = std::sqrt( mOriginal*mOriginal +
161 targetMass*targetMass +
162 2.0*targetMass*etOriginal );
163 G4double availableEnergy = centerofmassEnergy-(targetMass+mOriginal);
165 static G4bool first =
true;
166 const G4int numMul = 1200;
167 const G4int numMulA = 400;
168 const G4int numSec = 60;
169 static G4double protmul[numMul], protnorm[numSec];
170 static G4double neutmul[numMul], neutnorm[numSec];
171 static G4double protmulA[numMulA], protnormA[numSec];
172 static G4double neutmulA[numMulA], neutnormA[numSec];
174 G4int counter, nt=0, npos=0, nneg=0, nzero=0;
182 for( i=0; i<numMul; ++i )protmul[i] = 0.0;
183 for( i=0; i<numSec; ++i )protnorm[i] = 0.0;
185 for( npos=0; npos<(numSec/3); ++npos )
187 for( nneg=std::max(0,npos-1); nneg<=(npos+1); ++nneg )
189 for( nzero=0; nzero<numSec/3; ++nzero )
191 if( ++counter < numMul )
193 nt = npos+nneg+nzero;
194 if( nt>0 && nt<=numSec )
196 protmul[counter] =
Pmltpc(npos,nneg,nzero,nt,b[0],c);
197 protnorm[nt-1] += protmul[counter];
203 for( i=0; i<numMul; ++i )neutmul[i] = 0.0;
204 for( i=0; i<numSec; ++i )neutnorm[i] = 0.0;
206 for( npos=0; npos<numSec/3; ++npos )
208 for( nneg=npos; nneg<=(npos+2); ++nneg )
210 for( nzero=0; nzero<numSec/3; ++nzero )
212 if( ++counter < numMul )
214 nt = npos+nneg+nzero;
215 if( nt>0 && nt<=numSec )
217 neutmul[counter] =
Pmltpc(npos,nneg,nzero,nt,b[1],c);
218 neutnorm[nt-1] += neutmul[counter];
224 for( i=0; i<numSec; ++i )
226 if( protnorm[i] > 0.0 )protnorm[i] = 1.0/protnorm[i];
227 if( neutnorm[i] > 0.0 )neutnorm[i] = 1.0/neutnorm[i];
232 for( i=0; i<numMulA; ++i )protmulA[i] = 0.0;
233 for( i=0; i<numSec; ++i )protnormA[i] = 0.0;
235 for( npos=1; npos<(numSec/3); ++npos )
238 for( nzero=0; nzero<numSec/3; ++nzero )
240 if( ++counter < numMulA )
242 nt = npos+nneg+nzero;
243 if( nt>1 && nt<=numSec )
245 protmulA[counter] =
Pmltpc(npos,nneg,nzero,nt,b[0],c);
246 protnormA[nt-1] += protmulA[counter];
251 for( i=0; i<numMulA; ++i )neutmulA[i] = 0.0;
252 for( i=0; i<numSec; ++i )neutnormA[i] = 0.0;
254 for( npos=0; npos<numSec/3; ++npos )
257 for( nzero=0; nzero<numSec/3; ++nzero )
259 if( ++counter < numMulA )
261 nt = npos+nneg+nzero;
262 if( nt>1 && nt<=numSec )
264 neutmulA[counter] =
Pmltpc(npos,nneg,nzero,nt,b[1],c);
265 neutnormA[nt-1] += neutmulA[counter];
270 for( i=0; i<numSec; ++i )
272 if( protnormA[i] > 0.0 )protnormA[i] = 1.0/protnormA[i];
273 if( neutnormA[i] > 0.0 )neutnormA[i] = 1.0/neutnormA[i];
287 const G4double anhl[] = {1.00,1.00,1.00,1.00,1.00,1.00,1.00,1.00,0.97,0.88,
288 0.85,0.81,0.75,0.64,0.64,0.55,0.55,0.45,0.47,0.40,
289 0.39,0.36,0.33,0.10,0.01};
291 if( iplab > 9 )iplab =
G4int( (pOriginal/GeV- 1.0)*5.0 ) + 10;
292 if( iplab > 14 )iplab =
G4int( pOriginal/GeV- 2.0 ) + 15;
293 if( iplab > 22 )iplab =
G4int( (pOriginal/GeV-10.0)/10.0 ) + 23;
294 if( iplab > 24 )iplab = 24;
297 if( availableEnergy <= aPiPlus->GetPDGMass()/MeV )
309 for( npos=0; npos<numSec/3 && ran>=excs; ++npos )
311 for( nneg=std::max(0,npos-1); nneg<=(npos+1) && ran>=excs; ++nneg )
313 for( nzero=0; nzero<numSec/3 && ran>=excs; ++nzero )
315 if( ++counter < numMul )
317 nt = npos+nneg+nzero;
318 if( (nt>0) && (nt<=numSec) )
320 test = std::exp( std::min( expxu, std::max( expxl, -(pi/4.0)*(nt*nt)/(n*n) ) ) );
321 dum = (
pi/anpn)*nt*protmul[counter]*protnorm[nt-1]/(2.0*n*n);
322 if( std::fabs(dum) < 1.0 )
324 if( test >= 1.0e-10 )excs += dum*test;
338 npos--; nneg--; nzero--;
339 G4int ncht = std::min( 3, std::max( 1, npos-nneg+2 ) );
347 incidentHasChanged =
true;
356 incidentHasChanged =
true;
359 targetHasChanged =
true;
363 targetHasChanged =
true;
370 for( npos=0; npos<numSec/3 && ran>=excs; ++npos )
372 for( nneg=npos; nneg<=(npos+2) && ran>=excs; ++nneg )
374 for( nzero=0; nzero<numSec/3 && ran>=excs; ++nzero )
376 if( ++counter < numMul )
378 nt = npos+nneg+nzero;
379 if( (nt>0) && (nt<=numSec) )
381 test = std::exp( std::min( expxu, std::max( expxl, -(pi/4.0)*(nt*nt)/(n*n) ) ) );
382 dum = (
pi/anpn)*nt*neutmul[counter]*neutnorm[nt-1]/(2.0*n*n);
383 if( std::fabs(dum) < 1.0 )
385 if( test >= 1.0e-10 )excs += dum*test;
399 npos--; nneg--; nzero--;
400 G4int ncht = std::min( 3, std::max( 1, npos-nneg+3 ) );
408 incidentHasChanged =
true;
410 targetHasChanged =
true;
418 incidentHasChanged =
true;
423 targetHasChanged =
true;
431 incidentHasChanged =
true;
436 targetHasChanged =
true;
447 if( centerofmassEnergy <= aPiPlus->GetPDGMass()/MeV+aKaonPlus->
GetPDGMass()/MeV )
459 for( npos=1; npos<numSec/3 && ran>=excs; ++npos )
462 for( nzero=0; nzero<numSec/3 && ran>=excs; ++nzero )
464 if( ++counter < numMulA )
466 nt = npos+nneg+nzero;
467 if( nt>1 && nt<=numSec )
469 test = std::exp( std::min( expxu, std::max( expxl, -(pi/4.0)*(nt*nt)/(n*n) ) ) );
470 dum = (
pi/anpn)*nt*protmulA[counter]*protnormA[nt-1]/(2.0*n*n);
471 if( std::fabs(dum) < 1.0 )
473 if( test >= 1.0e-10 )excs += dum*test;
491 for( npos=0; npos<numSec/3 && ran>=excs; ++npos )
494 for( nzero=0; nzero<numSec/3 && ran>=excs; ++nzero )
496 if( ++counter < numMulA )
498 nt = npos+nneg+nzero;
499 if( nt>1 && nt<=numSec )
501 test = std::exp( std::min( expxu, std::max( expxl, -(pi/4.0)*(nt*nt)/(n*n) ) ) );
502 dum = (
pi/anpn)*nt*neutmulA[counter]*neutnormA[nt-1]/(2.0*n*n);
503 if( std::fabs(dum) < 1.0 )
505 if( test >= 1.0e-10 )excs += dum*test;
565 currentParticle.
SetMass( 0.0 );
G4DLLIMPORT std::ostream G4cout
static G4AntiLambda * AntiLambda()
static G4AntiSigmaZero * AntiSigmaZero()
G4ParticleDefinition * GetDefinition() const
void SetElement(G4int anIndex, Type *anElement)
void Initialize(G4int items)
void SetStatusChange(G4HadFinalStateStatus aS)
void SetEnergyChange(G4double anEnergy)
void SetMomentumChange(const G4ThreeVector &aV)
const G4Material * GetMaterial() const
G4double GetTotalMomentum() const
const G4ParticleDefinition * GetDefinition() const
G4double GetKineticEnergy() const
const G4LorentzVector & Get4Momentum() const
G4double GetTotalEnergy() const
G4HadFinalState theParticleChange
G4double Pmltpc(G4int np, G4int nm, G4int nz, G4int n, G4double b, G4double c)
void GetNormalizationConstant(const G4double availableEnergy, G4double &n, G4double &anpn)
void SetUpPions(const G4int np, const G4int nm, const G4int nz, G4FastVector< G4ReactionProduct, GHADLISTSIZE > &vec, G4int &vecLen)
void CalculateMomenta(G4FastVector< G4ReactionProduct, GHADLISTSIZE > &vec, G4int &vecLen, const G4HadProjectile *originalIncident, const G4DynamicParticle *originalTarget, G4ReactionProduct &modifiedOriginal, G4Nucleus &targetNucleus, G4ReactionProduct ¤tParticle, G4ReactionProduct &targetParticle, G4bool &incidentHasChanged, G4bool &targetHasChanged, G4bool quasiElastic)
void DoIsotopeCounting(const G4HadProjectile *theProjectile, const G4Nucleus &aNucleus)
void SetUpChange(G4FastVector< G4ReactionProduct, GHADLISTSIZE > &vec, G4int &vecLen, G4ReactionProduct ¤tParticle, G4ReactionProduct &targetParticle, G4bool &incidentHasChanged)
static G4KaonMinus * KaonMinus()
static G4KaonPlus * KaonPlus()
static G4KaonZeroLong * KaonZeroLong()
virtual void ModelDescription(std::ostream &outFile) const
G4HadFinalState * ApplyYourself(const G4HadProjectile &aTrack, G4Nucleus &targetNucleus)
const G4String & GetName() const
static G4Neutron * Neutron()
G4double EvaporationEffects(G4double kineticEnergy)
G4double Cinema(G4double kineticEnergy)
G4DynamicParticle * ReturnTargetParticle() const
G4double GetPDGMass() const
const G4String & GetParticleName() const
static G4PionPlus * PionPlus()
static G4Proton * Proton()
void SetMomentum(const G4double x, const G4double y, const G4double z)
G4double GetTotalMomentum() const
G4double GetKineticEnergy() const
G4ThreeVector GetMomentum() const
void SetSide(const G4int sid)
void SetDefinitionAndUpdateE(G4ParticleDefinition *aParticleDefinition)
void SetKineticEnergy(const G4double en)
G4ParticleDefinition * GetDefinition() const
void SetDefinition(G4ParticleDefinition *aParticleDefinition)
void SetMass(const G4double mas)