47 G4cout <<
"G4RPGLambdaInelastic::ApplyYourself called" <<
G4endl;
49 G4cout <<
"target material = " << targetMaterial->
GetName() <<
", ";
60 modifiedOriginal = *originalIncident;
80 p = std::sqrt(
std::abs((et-amas)*(et+amas)) );
90 targetParticle = *originalTarget;
93 G4bool incidentHasChanged =
false;
94 G4bool targetHasChanged =
false;
95 G4bool quasiElastic =
false;
103 originalIncident, currentParticle, targetParticle,
104 incidentHasChanged, targetHasChanged, quasiElastic );
107 originalIncident, originalTarget, modifiedOriginal,
108 targetNucleus, currentParticle, targetParticle,
109 incidentHasChanged, targetHasChanged, quasiElastic );
112 currentParticle, targetParticle,
113 incidentHasChanged );
115 delete originalTarget;
126 G4bool &incidentHasChanged,
143 G4double centerofmassEnergy = std::sqrt( mOriginal*mOriginal +
144 targetMass*targetMass +
145 2.0*targetMass*etOriginal );
146 G4double availableEnergy = centerofmassEnergy-(targetMass+mOriginal);
153 const G4int numMul = 1200;
154 const G4int numSec = 60;
160 G4int counter, nt=0, np=0, nneg=0, nz=0;
167 for( i=0; i<numMul; ++i )protmul[i] = 0.0;
168 for( i=0; i<numSec; ++i )protnorm[i] = 0.0;
170 for( np=0; np<(numSec/3); ++np ) {
171 for( nneg=
std::max(0,np-2); nneg<=(np+1); ++nneg ) {
172 for( nz=0; nz<numSec/3; ++nz ) {
173 if( ++counter < numMul ) {
175 if( nt>0 && nt<=numSec ) {
176 protmul[counter] =
Pmltpc(np,nneg,nz,nt,b[0],c);
177 protnorm[nt-1] += protmul[counter];
183 for( i=0; i<numMul; ++i )neutmul[i] = 0.0;
184 for( i=0; i<numSec; ++i )neutnorm[i] = 0.0;
186 for( np=0; np<numSec/3; ++np ) {
187 for( nneg=
std::max(0,np-1); nneg<=(np+2); ++nneg ) {
188 for( nz=0; nz<numSec/3; ++nz ) {
189 if( ++counter < numMul ) {
191 if( nt>0 && nt<=numSec ) {
192 neutmul[counter] =
Pmltpc(np,nneg,nz,nt,b[1],c);
193 neutnorm[nt-1] += neutmul[counter];
199 for( i=0; i<numSec; ++i ) {
200 if( protnorm[i] > 0.0 )protnorm[i] = 1.0/protnorm[i];
201 if( neutnorm[i] > 0.0 )neutnorm[i] = 1.0/neutnorm[i];
222 for( np=0; np<numSec/3 && ran>=excs; ++np ) {
223 for( nneg=
std::max(0,np-2); nneg<=(np+1) && ran>=excs; ++nneg ) {
224 for( nz=0; nz<numSec/3 && ran>=excs; ++nz ) {
225 if( ++counter < numMul ) {
227 if( nt>0 && nt<=numSec ) {
229 dum = (
pi/anpn)*nt*protmul[counter]*protnorm[nt-1]/(2.0*n*n);
230 if( std::fabs(dum) < 1.0 ) {
231 if( test >= 1.0
e-10 )excs += dum*
test;
250 incidentHasChanged =
true;
256 incidentHasChanged =
true;
260 incidentHasChanged =
true;
262 targetHasChanged =
true;
269 incidentHasChanged =
true;
272 targetHasChanged =
true;
275 incidentHasChanged =
true;
280 incidentHasChanged =
true;
282 targetHasChanged =
true;
289 for( np=0; np<numSec/3 && ran>=excs; ++np ) {
290 for( nneg=
std::max(0,np-1); nneg<=(np+2) && ran>=excs; ++nneg ) {
291 for( nz=0; nz<numSec/3 && ran>=excs; ++nz ) {
292 if( ++counter < numMul ) {
294 if( nt>0 && nt<=numSec ) {
296 dum = (
pi/anpn)*nt*neutmul[counter]*neutnorm[nt-1]/(2.0*n*n);
297 if( std::fabs(dum) < 1.0 ) {
298 if( test >= 1.0
e-10 )excs += dum*
test;
317 incidentHasChanged =
true;
319 targetHasChanged =
true;
325 incidentHasChanged =
true;
328 targetHasChanged =
true;
331 incidentHasChanged =
true;
338 incidentHasChanged =
true;
342 incidentHasChanged =
true;
344 targetHasChanged =
true;
349 incidentHasChanged =
true;